openyida 2026.3.22-2 → 2026.3.23-3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (42) hide show
  1. package/bin/yida.js +16 -12
  2. package/lib/app/compile.js +41 -0
  3. package/lib/app/create-page.js +11 -7
  4. package/lib/app/publish.js +10 -5
  5. package/lib/core/locales/ar.js +77 -2
  6. package/lib/core/locales/de.js +77 -2
  7. package/lib/core/locales/en.js +78 -2
  8. package/lib/core/locales/es.js +77 -2
  9. package/lib/core/locales/fr.js +77 -2
  10. package/lib/core/locales/hi.js +77 -2
  11. package/lib/core/locales/ja.js +77 -2
  12. package/lib/core/locales/ko.js +77 -2
  13. package/lib/core/locales/pt.js +77 -2
  14. package/lib/core/locales/vi.js +77 -2
  15. package/lib/core/locales/zh-TW.js +77 -2
  16. package/lib/core/locales/zh.js +78 -2
  17. package/lib/core/query-data.js +324 -109
  18. package/lib/integration/integration-create.js +63 -62
  19. package/package.json +1 -1
  20. package/yida-skills/SKILL.md +23 -44
  21. package/yida-skills/skills/yida-chart/SKILL.md +9 -0
  22. package/yida-skills/skills/yida-create-app/SKILL.md +2 -0
  23. package/yida-skills/skills/yida-create-form-page/SKILL.md +14 -0
  24. package/yida-skills/skills/yida-create-page/SKILL.md +2 -0
  25. package/yida-skills/skills/yida-create-process/SKILL.md +11 -0
  26. package/yida-skills/skills/yida-create-report/SKILL.md +2 -0
  27. package/yida-skills/skills/yida-custom-page/SKILL.md +336 -685
  28. package/yida-skills/skills/yida-custom-page/examples/yida-custom-page.js +87 -0
  29. package/yida-skills/skills/yida-custom-page/jsx-compile-checklist.md +113 -0
  30. package/yida-skills/skills/yida-custom-page/yida-assets-guide.md +93 -0
  31. package/yida-skills/skills/yida-data-management/SKILL.md +2 -0
  32. package/yida-skills/skills/yida-density/SKILL.md +11 -0
  33. package/yida-skills/skills/yida-get-schema/SKILL.md +2 -7
  34. package/yida-skills/skills/yida-integration/SKILL.md +21 -0
  35. package/yida-skills/skills/yida-login/SKILL.md +7 -0
  36. package/yida-skills/skills/yida-logout/SKILL.md +2 -0
  37. package/yida-skills/skills/yida-page-config/SKILL.md +12 -8
  38. package/yida-skills/skills/yida-ppt-slider/SKILL.md +11 -0
  39. package/yida-skills/skills/yida-process-rule/SKILL.md +10 -1
  40. package/yida-skills/skills/yida-publish-page/SKILL.md +2 -0
  41. package/yida-skills/skills/yida-report/SKILL.md +25 -0
  42. package/lib/data-management.js +0 -362
package/bin/yida.js CHANGED
@@ -21,6 +21,7 @@
21
21
  * openyida create-form create <appType> "<表单名>" <字段JSON> [--layout <布局>] [--theme <主题>] [--label-align <对齐>] 创建表单页面
22
22
  * openyida create-form update <appType> <formUuid> <修改JSON> 更新表单页面
23
23
  * openyida get-schema <appType> <formUuid> 获取表单 Schema
24
+ * openyida compile <源文件路径> 仅编译自定义页面(不发布,产物输出到 pages/dist/)
24
25
  * openyida publish <源文件路径> <appType> <formUuid> 编译并发布自定义页面
25
26
  * openyida verify-short-url <appType> <formUuid> <url> 验证短链接 URL 是否可用
26
27
  * openyida save-share-config <appType> <formUuid> <url> <isOpen> [openAuth] 保存公开访问/分享配置
@@ -265,6 +266,18 @@ async function main() {
265
266
  break;
266
267
  }
267
268
 
269
+ case 'compile': {
270
+ // 参数顺序:<源文件路径>
271
+ if (args.length < 1) {
272
+ console.error(t('cli.compile_usage'));
273
+ console.error(t('cli.compile_example'));
274
+ process.exit(1);
275
+ }
276
+ const { run: runCompile } = require('../lib/app/compile');
277
+ await runCompile(args);
278
+ break;
279
+ }
280
+
268
281
  case 'publish': {
269
282
  // 参数顺序:<源文件路径> <appType> <formUuid>
270
283
  // publish.js 内部读取顺序:argv[2]=appType, argv[3]=formUuid, argv[4]=sourceFile
@@ -275,7 +288,8 @@ async function main() {
275
288
  }
276
289
  const [sourceFile, appType, formUuid] = args;
277
290
  process.argv = [process.argv[0], process.argv[1], appType, formUuid, sourceFile];
278
- require('../lib/app/publish');
291
+ const { main: publishMain } = require('../lib/app/publish');
292
+ await publishMain();
279
293
  break;
280
294
  }
281
295
 
@@ -329,7 +343,7 @@ async function main() {
329
343
  console.error(t('cli.data_example'));
330
344
  process.exit(1);
331
345
  }
332
- const { run: runDataManagement } = require('../lib/data-management');
346
+ const { run: runDataManagement } = require('../lib/core/query-data');
333
347
  await runDataManagement(args);
334
348
  break;
335
349
  }
@@ -475,16 +489,6 @@ async function main() {
475
489
  break;
476
490
  }
477
491
 
478
- case 'query-data': {
479
- if (args.length < 2) {
480
- console.error(t('cli.query_data_usage'));
481
- process.exit(1);
482
- }
483
- const { run: runQueryData } = require('../lib/core/query-data');
484
- await runQueryData(args);
485
- break;
486
- }
487
-
488
492
  case 'integration': {
489
493
  const subCommand = args[0];
490
494
 
@@ -0,0 +1,41 @@
1
+ 'use strict';
2
+
3
+ /**
4
+ * compile.js - 宜搭自定义页面仅编译工具(不发布)
5
+ *
6
+ * 用法:
7
+ * openyida compile <源文件路径>
8
+ *
9
+ * 示例:
10
+ * openyida compile pages/src/demo.js
11
+ *
12
+ * 编译逻辑复用 publish.js 中的 compileSource,产物输出到 project/pages/dist/<name>.js。
13
+ */
14
+
15
+ const fs = require('fs');
16
+ const path = require('path');
17
+ const { compileSource } = require('./publish');
18
+ const { t } = require('../core/i18n');
19
+
20
+ /**
21
+ * 主流程:编译源文件,产物已由 compileSource 写入 dist 目录
22
+ * @param {string[]} args - CLI 参数,args[0] 为源文件路径
23
+ */
24
+ async function run(args) {
25
+ const sourceFile = args[0];
26
+ if (!sourceFile) {
27
+ console.error(t('compile.usage'));
28
+ console.error(t('compile.example'));
29
+ process.exit(1);
30
+ }
31
+
32
+ const sourcePath = path.resolve(sourceFile);
33
+ if (!fs.existsSync(sourcePath)) {
34
+ console.error(t('compile.source_not_found', sourcePath));
35
+ process.exit(1);
36
+ }
37
+
38
+ compileSource(sourcePath);
39
+ }
40
+
41
+ module.exports = { run };
@@ -22,9 +22,10 @@ const { t } = require('../core/i18n');
22
22
  const { buildDataSourceList, parseDatasourceArg, extractDatasourceArg } = require('./datasource-utils');
23
23
 
24
24
  async function run(args) {
25
- // 从参数中提取 --datasource 选项(会原地修改 args 数组)
25
+ // 从参数中提取 --datasource 选项,解构返回值并更新 mutableArgs
26
26
  const mutableArgs = [...args];
27
- const datasourceArg = extractDatasourceArg(mutableArgs);
27
+ const { datasourceValue, remainingArgs } = extractDatasourceArg(mutableArgs);
28
+ mutableArgs.splice(0, mutableArgs.length, ...remainingArgs);
28
29
 
29
30
  if (mutableArgs.length < 2) {
30
31
  console.error(t('create_page.usage'));
@@ -84,13 +85,16 @@ async function run(args) {
84
85
  process.exit(1);
85
86
  }
86
87
 
87
- const pageId = response.content.formUuid || response.content;
88
+ const rawContent = response.content;
89
+ const pageId = (typeof rawContent === 'object' && rawContent !== null)
90
+ ? rawContent.formUuid || rawContent.pageId || String(rawContent)
91
+ : String(rawContent);
88
92
  const pageUrl = `${authRef.baseUrl}/${appType}/workbench/${pageId}`;
89
93
 
90
94
  // Step 3: 注入连接器数据源(如果提供了 --datasource 参数)
91
- const datasourceDefinitions = parseDatasourceArg(datasourceArg);
95
+ const datasourceDefinitions = parseDatasourceArg(datasourceValue);
92
96
  if (datasourceDefinitions.length > 0) {
93
- console.error(`[datasource] 正在注入 ${datasourceDefinitions.length} 个连接器数据源...`);
97
+ console.error(t('create_page.datasource_injecting', datasourceDefinitions.length));
94
98
 
95
99
  const dataSourceList = buildDataSourceList(datasourceDefinitions);
96
100
  const schema = {
@@ -115,12 +119,12 @@ async function run(args) {
115
119
  }, authRef);
116
120
 
117
121
  if (saveSchemaResponse && saveSchemaResponse.success) {
118
- console.error('[datasource] 数据源注入成功');
122
+ console.error(t('create_page.datasource_success'));
119
123
  } else {
120
124
  const schemaErrorMsg = saveSchemaResponse
121
125
  ? saveSchemaResponse.errorMsg || t('common.unknown_error')
122
126
  : t('common.request_failed');
123
- console.error(`[datasource] 数据源注入失败:${schemaErrorMsg}`);
127
+ console.error(t('create_page.datasource_failed', schemaErrorMsg));
124
128
  }
125
129
  }
126
130
 
@@ -119,7 +119,7 @@ function compileSource(sourcePath) {
119
119
  fs.writeFileSync(compiledPath, uglifyResult.code, 'utf-8');
120
120
  console.error(t('publish.compile_done', compiledPath));
121
121
 
122
- return { sourceCode, compiledCode: uglifyResult.code };
122
+ return { sourceCode, compiledCode: uglifyResult.code, compiledPath };
123
123
  }
124
124
 
125
125
  // ── ID 生成工具 ──────────────────────────────────────
@@ -623,7 +623,12 @@ async function main() {
623
623
  console.error(SEP2);
624
624
  }
625
625
 
626
- main().catch((error) => {
627
- console.error(t('publish.exception', error.message));
628
- process.exit(1);
629
- });
626
+ // 仅在直接执行时运行主流程,require 时只导出函数
627
+ if (require.main === module) {
628
+ main().catch((error) => {
629
+ console.error(t('publish.exception', error.message));
630
+ process.exit(1);
631
+ });
632
+ }
633
+
634
+ module.exports = { compileSource, main };
@@ -21,6 +21,7 @@ Commands:
21
21
  create-form create <appType> "<formName>" <fieldsJSON> [opt] Create a form page
22
22
  create-form update <appType> <formUuid> <changesJSON> Update a form page
23
23
  get-schema <appType> <formUuid> Get form Schema
24
+ compile <sourceFile> تجميع JSX فقط (بدون نشر، الإخراج في pages/dist/)
24
25
  publish <sourceFile> <appType> <formUuid> Compile and publish a custom page
25
26
  verify-short-url <appType> <formUuid> <url> Verify if a short URL is available
26
27
  save-share-config <appType> <formUuid> <url> <isOpen> [auth] Save public access / share config
@@ -43,7 +44,6 @@ Commands:
43
44
  cdn-config [options] Configure CDN image upload
44
45
  cdn-upload <image-path> [options] Upload images to CDN
45
46
  cdn-refresh [options] Refresh CDN cache
46
- query-data <appType> <formUuid> [options] Query form instance data
47
47
 
48
48
  Examples:
49
49
  openyida login
@@ -118,7 +118,6 @@ Use openyida connector <subcommand> --help for detailed help
118
118
  openyida integration create APP_XXX FORM-XXX "إشعار سجل جديد" --receivers user123 --publish`,
119
119
  integration_unknown: 'أمر فرعي integration غير معروف: {0}',
120
120
  integration_help_hint: 'استخدم openyida integration --help لرؤية الأوامر الفرعية المتاحة',
121
- query_data_usage: 'Usage: openyida query-data <appType> <formUuid> [--page N] [--size N] [--search-json JSON] [--inst-id ID]',
122
121
  auth_usage: 'Usage: openyida auth <status|login|refresh|logout>',
123
122
  auth_example: 'Example: openyida auth status',
124
123
  org_usage: 'Usage: openyida org <list|switch> [options]',
@@ -325,6 +324,9 @@ Available colors:`,
325
324
  page_id_label: ' pageId: {0}',
326
325
  url_label: ' URL: {0}',
327
326
  failed: ' ❌ فشل الإنشاء: {0}',
327
+ datasource_injecting: ' [datasource] جارٍ حقن {0} مصدر/مصادر بيانات الموصّل...',
328
+ datasource_success: ' [datasource] تم حقن مصدر البيانات بنجاح',
329
+ datasource_failed: ' [datasource] فشل حقن مصدر البيانات: {0}',
328
330
  },
329
331
 
330
332
  // ── lib/get-schema.js ───────────────────────────────
@@ -629,6 +631,16 @@ Examples:`,
629
631
  🎉 إصدار جديد متاح: {0} → {1}`,
630
632
  },
631
633
 
634
+ // ── lib/compile.js ─────────────────────────────────
635
+ compile: {
636
+ usage: 'الاستخدام: openyida compile <ملف-المصدر>',
637
+ example: 'مثال: openyida compile pages/src/demo.js',
638
+ source_not_found: '❌ ملف المصدر غير موجود: {0}',
639
+ success: '✅ اكتمل التجميع!',
640
+ output_file: ' ملف الإخراج: {0}',
641
+ exception: '\n❌ خطأ في التجميع: {0}',
642
+ },
643
+
632
644
  // ── lib/publish.js ─────────────────────────────────
633
645
  publish: {
634
646
  title: ' yida-publish - أداة نشر صفحات Yida',
@@ -761,6 +773,69 @@ Examples:`,
761
773
  footer2: ' 💬 المجتمع: انضم إلى مجتمع OpenYida على DingTalk',
762
774
  },
763
775
 
776
+ // ── lib/integration/integration-create.js ─────────
777
+ integration: {
778
+ create_usage: 'Usage: openyida integration create <appType> <formUuid> <flowName> [options]',
779
+ create_args_title: 'Arguments:',
780
+ create_arg_app_type: ' appType App ID, e.g. APP_XXXX',
781
+ create_arg_form_uuid: ' formUuid Trigger form UUID, e.g. FORM-XXXX',
782
+ create_arg_flow_name: ' flowName Logic flow name',
783
+ create_options_title: 'Options:',
784
+ create_opt_process_code: ' --process-code <code> Existing processCode (LPROC-xxx), creates new if omitted',
785
+ create_opt_receivers: ' --receivers <userId,...> DingTalk notification receiver user IDs, comma-separated',
786
+ create_opt_title: ' --title <title> Notification title, supports #{fieldId-ComponentType}# field refs',
787
+ create_opt_content: ' --content <content> Notification content, supports #{fieldId-ComponentType}# field refs',
788
+ create_opt_events: ' --events <insert,update,...> Trigger events: insert/update/delete/comment, default insert',
789
+ create_opt_data_form_uuid: ' --data-form-uuid <formUuid> Target form UUID for get-data node',
790
+ create_opt_data_condition: ' --data-condition <b:bName:a[:type]> Filter condition for get-data node, repeatable',
791
+ create_opt_add_data_form_uuid: ' --add-data-form-uuid <formUuid> Target form UUID for add-data node',
792
+ create_opt_add_data_assignment: ' --add-data-assignment <col:type:val> Field assignment for add-data node, repeatable',
793
+ create_opt_publish: ' --publish Publish after save, otherwise save as draft',
794
+ create_examples_title: 'Examples:',
795
+ create_example1: ' openyida integration create APP_XXX FORM-XXX "New record notification" \\',
796
+ create_example2: ' --receivers user123 --title "New record submitted" --content "Please handle" --publish',
797
+ create_unknown_sub: 'Unknown integration subcommand: {0}',
798
+ create_missing_args: 'Error: missing required arguments appType, formUuid or flowName',
799
+ create_invalid_events: 'Error: invalid --events value, valid options: insert / update / delete / comment (or create)',
800
+ create_no_receivers: 'Warning: --receivers not specified, notification receivers are empty, flow will be created but cannot send notifications',
801
+ create_title: '🔗 Creating Integration & Automation (Logic Flow)',
802
+ create_app_type: ' App ID: {0}',
803
+ create_form_uuid: ' Trigger form: {0}',
804
+ create_flow_name: ' Flow name: {0}',
805
+ create_mode_update: ' Mode: Update existing logic flow',
806
+ create_mode_new: ' Mode: Create new logic flow',
807
+ create_process_code: ' processCode: {0}',
808
+ create_events: ' Trigger events: {0}',
809
+ create_receivers: ' Notification receivers: {0}',
810
+ create_receivers_empty: '(not set)',
811
+ create_notify_title: ' Notification title: {0}',
812
+ create_notify_content: ' Notification content: {0}',
813
+ create_data_form: ' Get-data form: {0}',
814
+ create_data_conditions: ' Filter conditions count: {0}',
815
+ create_op_mode_publish: ' Operation mode: Save and publish',
816
+ create_op_mode_draft: ' Operation mode: Save as draft only',
817
+ create_step: '\n[{0}/{1}] {2}',
818
+ create_step_login: 'Reading login state...',
819
+ create_no_cache: ' No login cache found, triggering login...',
820
+ create_login_ok: ' ✅ Login ready, baseUrl: {0}',
821
+ create_step_new_flow: 'Creating new logic flow binding...',
822
+ create_new_flow_ok: ' ✅ Created successfully, processCode: {0}',
823
+ create_new_flow_failed: ' ❌ {0}',
824
+ create_step_get_schema: ' 📋 Fetching target form schema...',
825
+ create_get_schema_ok: ' ✅ Got {0} fields',
826
+ create_get_schema_warn: ' ⚠️ Failed to fetch target form schema (using empty field list): {0}',
827
+ create_step_save: 'Saving logic flow...',
828
+ create_save_failed: ' ❌ Failed to save logic flow: {0}',
829
+ create_save_ok: ' ✅ Logic flow saved successfully (draft)',
830
+ create_step_publish: 'Publishing logic flow...',
831
+ create_publish_warn: ' ⚠️ Failed to publish logic flow: {0}',
832
+ create_publish_draft_hint: ' (Logic flow saved as draft, you can publish manually on the Yida platform)',
833
+ create_published_ok: ' ✅ Logic flow published successfully (enabled)',
834
+ create_done_published: '✅ Integration & Automation created and published',
835
+ create_done_draft: '✅ Integration & Automation saved as draft',
836
+ create_draft_hint: ' Tip: use --publish to publish immediately when creating',
837
+ },
838
+
764
839
  // ── lib/cdn-*.js ───────────────────────────────────
765
840
  cdn: {
766
841
  config_load_error: 'فشل تحميل إعدادات CDN: {0}',
@@ -21,6 +21,7 @@ Commands:
21
21
  create-form create <appType> "<formName>" <fieldsJSON> [opt] Create a form page
22
22
  create-form update <appType> <formUuid> <changesJSON> Update a form page
23
23
  get-schema <appType> <formUuid> Get form Schema
24
+ compile <Quelldatei> Nur JSX kompilieren (kein Publish, Ausgabe in pages/dist/)
24
25
  publish <sourceFile> <appType> <formUuid> Compile and publish a custom page
25
26
  verify-short-url <appType> <formUuid> <url> Verify if a short URL is available
26
27
  save-share-config <appType> <formUuid> <url> <isOpen> [auth] Save public access / share config
@@ -43,7 +44,6 @@ Commands:
43
44
  cdn-config [options] Configure CDN image upload
44
45
  cdn-upload <image-path> [options] Upload images to CDN
45
46
  cdn-refresh [options] Refresh CDN cache
46
- query-data <appType> <formUuid> [options] Query form instance data
47
47
 
48
48
  Examples:
49
49
  openyida login
@@ -118,7 +118,6 @@ Beispiele:
118
118
  openyida integration create APP_XXX FORM-XXX "Neue Datensatz-Benachrichtigung" --receivers user123 --publish`,
119
119
  integration_unknown: 'Unbekannter integration-Unterbefehl: {0}',
120
120
  integration_help_hint: 'Verwenden Sie openyida integration --help, um verfügbare Unterbefehle anzuzeigen',
121
- query_data_usage: 'Usage: openyida query-data <appType> <formUuid> [--page N] [--size N] [--search-json JSON] [--inst-id ID]',
122
121
  auth_usage: 'Usage: openyida auth <status|login|refresh|logout>',
123
122
  auth_example: 'Example: openyida auth status',
124
123
  org_usage: 'Usage: openyida org <list|switch> [options]',
@@ -325,6 +324,9 @@ Available colors:`,
325
324
  page_id_label: ' pageId: {0}',
326
325
  url_label: ' URL: {0}',
327
326
  failed: ' ❌ Erstellung fehlgeschlagen: {0}',
327
+ datasource_injecting: ' [datasource] {0} Connector-Datenquelle(n) werden injiziert...',
328
+ datasource_success: ' [datasource] Datenquelle erfolgreich injiziert',
329
+ datasource_failed: ' [datasource] Datenquelleninjektion fehlgeschlagen: {0}',
328
330
  },
329
331
 
330
332
  // ── lib/get-schema.js ───────────────────────────────
@@ -629,6 +631,16 @@ Examples:`,
629
631
  🎉 Neue Version verfügbar: {0} → {1}`,
630
632
  },
631
633
 
634
+ // ── lib/compile.js ─────────────────────────────────
635
+ compile: {
636
+ usage: 'Verwendung: openyida compile <Quelldatei>',
637
+ example: 'Beispiel: openyida compile pages/src/demo.js',
638
+ source_not_found: '❌ Quelldatei nicht gefunden: {0}',
639
+ success: '✅ Kompilierung abgeschlossen!',
640
+ output_file: ' Ausgabedatei: {0}',
641
+ exception: '\n❌ Kompilierungsfehler: {0}',
642
+ },
643
+
632
644
  // ── lib/publish.js ─────────────────────────────────
633
645
  publish: {
634
646
  title: ' yida-publish - Yida-Seitenveröffentlichungstool',
@@ -761,6 +773,69 @@ Examples:`,
761
773
  footer2: ' 💬 Community: OpenYida-Community auf DingTalk beitreten',
762
774
  },
763
775
 
776
+ // ── lib/integration/integration-create.js ─────────
777
+ integration: {
778
+ create_usage: 'Usage: openyida integration create <appType> <formUuid> <flowName> [options]',
779
+ create_args_title: 'Arguments:',
780
+ create_arg_app_type: ' appType App ID, e.g. APP_XXXX',
781
+ create_arg_form_uuid: ' formUuid Trigger form UUID, e.g. FORM-XXXX',
782
+ create_arg_flow_name: ' flowName Logic flow name',
783
+ create_options_title: 'Options:',
784
+ create_opt_process_code: ' --process-code <code> Existing processCode (LPROC-xxx), creates new if omitted',
785
+ create_opt_receivers: ' --receivers <userId,...> DingTalk notification receiver user IDs, comma-separated',
786
+ create_opt_title: ' --title <title> Notification title, supports #{fieldId-ComponentType}# field refs',
787
+ create_opt_content: ' --content <content> Notification content, supports #{fieldId-ComponentType}# field refs',
788
+ create_opt_events: ' --events <insert,update,...> Trigger events: insert/update/delete/comment, default insert',
789
+ create_opt_data_form_uuid: ' --data-form-uuid <formUuid> Target form UUID for get-data node',
790
+ create_opt_data_condition: ' --data-condition <b:bName:a[:type]> Filter condition for get-data node, repeatable',
791
+ create_opt_add_data_form_uuid: ' --add-data-form-uuid <formUuid> Target form UUID for add-data node',
792
+ create_opt_add_data_assignment: ' --add-data-assignment <col:type:val> Field assignment for add-data node, repeatable',
793
+ create_opt_publish: ' --publish Publish after save, otherwise save as draft',
794
+ create_examples_title: 'Examples:',
795
+ create_example1: ' openyida integration create APP_XXX FORM-XXX "New record notification" \\',
796
+ create_example2: ' --receivers user123 --title "New record submitted" --content "Please handle" --publish',
797
+ create_unknown_sub: 'Unknown integration subcommand: {0}',
798
+ create_missing_args: 'Error: missing required arguments appType, formUuid or flowName',
799
+ create_invalid_events: 'Error: invalid --events value, valid options: insert / update / delete / comment (or create)',
800
+ create_no_receivers: 'Warning: --receivers not specified, notification receivers are empty, flow will be created but cannot send notifications',
801
+ create_title: '🔗 Creating Integration & Automation (Logic Flow)',
802
+ create_app_type: ' App ID: {0}',
803
+ create_form_uuid: ' Trigger form: {0}',
804
+ create_flow_name: ' Flow name: {0}',
805
+ create_mode_update: ' Mode: Update existing logic flow',
806
+ create_mode_new: ' Mode: Create new logic flow',
807
+ create_process_code: ' processCode: {0}',
808
+ create_events: ' Trigger events: {0}',
809
+ create_receivers: ' Notification receivers: {0}',
810
+ create_receivers_empty: '(not set)',
811
+ create_notify_title: ' Notification title: {0}',
812
+ create_notify_content: ' Notification content: {0}',
813
+ create_data_form: ' Get-data form: {0}',
814
+ create_data_conditions: ' Filter conditions count: {0}',
815
+ create_op_mode_publish: ' Operation mode: Save and publish',
816
+ create_op_mode_draft: ' Operation mode: Save as draft only',
817
+ create_step: '\n[{0}/{1}] {2}',
818
+ create_step_login: 'Reading login state...',
819
+ create_no_cache: ' No login cache found, triggering login...',
820
+ create_login_ok: ' ✅ Login ready, baseUrl: {0}',
821
+ create_step_new_flow: 'Creating new logic flow binding...',
822
+ create_new_flow_ok: ' ✅ Created successfully, processCode: {0}',
823
+ create_new_flow_failed: ' ❌ {0}',
824
+ create_step_get_schema: ' 📋 Fetching target form schema...',
825
+ create_get_schema_ok: ' ✅ Got {0} fields',
826
+ create_get_schema_warn: ' ⚠️ Failed to fetch target form schema (using empty field list): {0}',
827
+ create_step_save: 'Saving logic flow...',
828
+ create_save_failed: ' ❌ Failed to save logic flow: {0}',
829
+ create_save_ok: ' ✅ Logic flow saved successfully (draft)',
830
+ create_step_publish: 'Publishing logic flow...',
831
+ create_publish_warn: ' ⚠️ Failed to publish logic flow: {0}',
832
+ create_publish_draft_hint: ' (Logic flow saved as draft, you can publish manually on the Yida platform)',
833
+ create_published_ok: ' ✅ Logic flow published successfully (enabled)',
834
+ create_done_published: '✅ Integration & Automation created and published',
835
+ create_done_draft: '✅ Integration & Automation saved as draft',
836
+ create_draft_hint: ' Tip: use --publish to publish immediately when creating',
837
+ },
838
+
764
839
  // ── lib/cdn-*.js ───────────────────────────────────
765
840
  cdn: {
766
841
  config_load_error: 'CDN-Konfiguration konnte nicht geladen werden: {0}',
@@ -24,6 +24,7 @@ Commands:
24
24
  create-form create <appType> "<formName>" <fieldsJSON> [opt] Create a form page
25
25
  create-form update <appType> <formUuid> <changesJSON> Update a form page
26
26
  get-schema <appType> <formUuid> Get form Schema
27
+ compile <sourceFile> Compile JSX only (no publish, output to pages/dist/)
27
28
  publish <sourceFile> <appType> <formUuid> Compile and publish a custom page
28
29
  verify-short-url <appType> <formUuid> <url> Verify if a short URL is available
29
30
  save-share-config <appType> <formUuid> <url> <isOpen> [auth] Save public access / share config
@@ -46,13 +47,13 @@ Commands:
46
47
  cdn-config [options] Configure CDN image upload
47
48
  cdn-upload <image-path> [options] Upload images to CDN
48
49
  cdn-refresh [options] Refresh CDN cache
49
- query-data <appType> <formUuid> [options] Query form instance data
50
50
 
51
51
  Examples:
52
52
  openyida login
53
53
  openyida create-app "Attendance"
54
54
  openyida create-form create APP_XXX "Employee Info" fields.json
55
55
  openyida get-schema APP_XXX FORM-XXX
56
+ openyida compile pages/src/home.jsx
56
57
  openyida publish pages/src/home.jsx APP_XXX FORM-XXX
57
58
  openyida data query form APP_XXX FORM-XXX --page 1 --size 20
58
59
  openyida export APP_XXX
@@ -121,7 +122,6 @@ Examples:
121
122
  openyida integration create APP_XXX FORM-XXX "New record notification" --receivers user123 --publish`,
122
123
  integration_unknown: 'Unknown integration subcommand: {0}',
123
124
  integration_help_hint: 'Use openyida integration --help to see available subcommands',
124
- query_data_usage: 'Usage: openyida query-data <appType> <formUuid> [--page N] [--size N] [--search-json JSON] [--inst-id ID]',
125
125
  auth_usage: 'Usage: openyida auth <status|login|refresh|logout>',
126
126
  auth_example: 'Example: openyida auth status',
127
127
  org_usage: 'Usage: openyida org <list|switch> [options]',
@@ -328,6 +328,9 @@ Available colors:`,
328
328
  page_id_label: ' pageId: {0}',
329
329
  url_label: ' URL: {0}',
330
330
  failed: ' ❌ Creation failed: {0}',
331
+ datasource_injecting: ' [datasource] Injecting {0} connector data source(s)...',
332
+ datasource_success: ' [datasource] Data source injected successfully',
333
+ datasource_failed: ' [datasource] Data source injection failed: {0}',
331
334
  },
332
335
 
333
336
  // ── lib/get-schema.js ──────────────────────────────
@@ -634,6 +637,16 @@ Examples:`,
634
637
  `,
635
638
  },
636
639
 
640
+ // ── lib/compile.js ─────────────────────────────────
641
+ compile: {
642
+ usage: 'Usage: openyida compile <source-file>',
643
+ example: 'Example: openyida compile pages/src/demo.js',
644
+ source_not_found: '❌ Source file not found: {0}',
645
+ success: '✅ Compile complete!',
646
+ output_file: ' Output: {0}',
647
+ exception: '\n❌ Compile error: {0}',
648
+ },
649
+
637
650
  // ── lib/publish.js ─────────────────────────────────
638
651
  publish: {
639
652
  title: ' yida-publish - Yida Page Publishing Tool',
@@ -766,6 +779,69 @@ Examples:`,
766
779
  footer2: ' 💬 Community: Join OpenYida community on DingTalk',
767
780
  },
768
781
 
782
+ // ── lib/integration/integration-create.js ─────────
783
+ integration: {
784
+ create_usage: 'Usage: openyida integration create <appType> <formUuid> <flowName> [options]',
785
+ create_args_title: 'Arguments:',
786
+ create_arg_app_type: ' appType App ID, e.g. APP_XXXX',
787
+ create_arg_form_uuid: ' formUuid Trigger form UUID, e.g. FORM-XXXX',
788
+ create_arg_flow_name: ' flowName Logic flow name',
789
+ create_options_title: 'Options:',
790
+ create_opt_process_code: ' --process-code <code> Existing processCode (LPROC-xxx), creates new if omitted',
791
+ create_opt_receivers: ' --receivers <userId,...> DingTalk notification receiver user IDs, comma-separated',
792
+ create_opt_title: ' --title <title> Notification title, supports #{fieldId-ComponentType}# field refs',
793
+ create_opt_content: ' --content <content> Notification content, supports #{fieldId-ComponentType}# field refs',
794
+ create_opt_events: ' --events <insert,update,...> Trigger events: insert/update/delete/comment, default insert',
795
+ create_opt_data_form_uuid: ' --data-form-uuid <formUuid> Target form UUID for get-data node',
796
+ create_opt_data_condition: ' --data-condition <b:bName:a[:type]> Filter condition for get-data node, repeatable',
797
+ create_opt_add_data_form_uuid: ' --add-data-form-uuid <formUuid> Target form UUID for add-data node',
798
+ create_opt_add_data_assignment: ' --add-data-assignment <col:type:val> Field assignment for add-data node, repeatable',
799
+ create_opt_publish: ' --publish Publish after save, otherwise save as draft',
800
+ create_examples_title: 'Examples:',
801
+ create_example1: ' openyida integration create APP_XXX FORM-XXX "New record notification" \\',
802
+ create_example2: ' --receivers user123 --title "New record submitted" --content "Please handle" --publish',
803
+ create_unknown_sub: 'Unknown integration subcommand: {0}',
804
+ create_missing_args: 'Error: missing required arguments appType, formUuid or flowName',
805
+ create_invalid_events: 'Error: invalid --events value, valid options: insert / update / delete / comment (or create)',
806
+ create_no_receivers: 'Warning: --receivers not specified, notification receivers are empty, flow will be created but cannot send notifications',
807
+ create_title: '🔗 Creating Integration & Automation (Logic Flow)',
808
+ create_app_type: ' App ID: {0}',
809
+ create_form_uuid: ' Trigger form: {0}',
810
+ create_flow_name: ' Flow name: {0}',
811
+ create_mode_update: ' Mode: Update existing logic flow',
812
+ create_mode_new: ' Mode: Create new logic flow',
813
+ create_process_code: ' processCode: {0}',
814
+ create_events: ' Trigger events: {0}',
815
+ create_receivers: ' Notification receivers: {0}',
816
+ create_receivers_empty: '(not set)',
817
+ create_notify_title: ' Notification title: {0}',
818
+ create_notify_content: ' Notification content: {0}',
819
+ create_data_form: ' Get-data form: {0}',
820
+ create_data_conditions: ' Filter conditions count: {0}',
821
+ create_op_mode_publish: ' Operation mode: Save and publish',
822
+ create_op_mode_draft: ' Operation mode: Save as draft only',
823
+ create_step: '\n[{0}/{1}] {2}',
824
+ create_step_login: 'Reading login state...',
825
+ create_no_cache: ' No login cache found, triggering login...',
826
+ create_login_ok: ' ✅ Login ready, baseUrl: {0}',
827
+ create_step_new_flow: 'Creating new logic flow binding...',
828
+ create_new_flow_ok: ' ✅ Created successfully, processCode: {0}',
829
+ create_new_flow_failed: ' ❌ {0}',
830
+ create_step_get_schema: ' 📋 Fetching target form schema...',
831
+ create_get_schema_ok: ' ✅ Got {0} fields',
832
+ create_get_schema_warn: ' ⚠️ Failed to fetch target form schema (using empty field list): {0}',
833
+ create_step_save: 'Saving logic flow...',
834
+ create_save_failed: ' ❌ Failed to save logic flow: {0}',
835
+ create_save_ok: ' ✅ Logic flow saved successfully (draft)',
836
+ create_step_publish: 'Publishing logic flow...',
837
+ create_publish_warn: ' ⚠️ Failed to publish logic flow: {0}',
838
+ create_publish_draft_hint: ' (Logic flow saved as draft, you can publish manually on the Yida platform)',
839
+ create_published_ok: ' ✅ Logic flow published successfully (enabled)',
840
+ create_done_published: '✅ Integration & Automation created and published',
841
+ create_done_draft: '✅ Integration & Automation saved as draft',
842
+ create_draft_hint: ' Tip: use --publish to publish immediately when creating',
843
+ },
844
+
769
845
  // ── lib/cdn-*.js ───────────────────────────────────
770
846
  cdn: {
771
847
  config_load_error: 'Failed to load CDN config: {0}',