Hello. The is problem (or may be it just not documented?).
For example i want to get ui_actions script & condition
If set up config like this:
"ui_actions": { "table": "sys_ui_action", "key": "name", "fields": { "js": "script", "condition.js": "condition" }, "subDirPattern": "table/client_<client>", "_custom": true },
on next --resync all *.condition.js files' content is overridden with content of UI action script. For example if i had 'Move Equipment.condition.js' and 'Move Equipment.js' both of them will have code of 'Move Equipment.js'.
Putting js field as last field solves the problem. So
"ui_actions": { "table": "sys_ui_action", "key": "name", "fields": { "condition.js": "condition", "js": "script" }, "subDirPattern": "table/client_<client>", "_custom": true }, + --resync will get everything back to normal.
Good finding.
This happens when the same suffix is used multiple times. Then there is an "order race" issue. I've fixed this now by ensuring the more specific suffixes are processed first.
Hello. The is problem (or may be it just not documented?).
For example i want to get ui_actions script & condition If set up config like this:
"ui_actions": { "table": "sys_ui_action", "key": "name", "fields": { "js": "script", "condition.js": "condition" }, "subDirPattern": "table/client_<client>", "_custom": true },
on next --resync all *.condition.js files' content is overridden with content of UI action script. For example if i had 'Move Equipment.condition.js' and 'Move Equipment.js' both of them will have code of 'Move Equipment.js'.Putting js field as last field solves the problem. So
"ui_actions": { "table": "sys_ui_action", "key": "name", "fields": { "condition.js": "condition", "js": "script" }, "subDirPattern": "table/client_<client>", "_custom": true },
+ --resync will get everything back to normal.