neo-cmp-cli 1.10.16 → 1.10.18

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 (39) hide show
  1. package/dist/main2.js +1 -1
  2. package/dist/neo/neoRequire.js +1 -1
  3. package/dist/neo/pushCmp.js +1 -1
  4. package/dist/package.json.js +1 -1
  5. package/package.json +3 -2
  6. package/template/antd-custom-cmp-template/package.json +1 -1
  7. package/template/antd-custom-cmp-template/src/components/dataDashboard__c/model.ts +9 -0
  8. package/template/antd-custom-cmp-template/src/components/searchWidget__c/model.ts +9 -0
  9. package/template/develop//345/215/225/345/205/203/346/265/213/350/257/225/344/275/277/347/224/250/350/257/264/346/230/216.md +1139 -0
  10. package/template/echarts-custom-cmp-template/package.json +1 -1
  11. package/template/neo-bi-cmps/neo.config.js +3 -0
  12. package/template/neo-bi-cmps/package.json +1 -1
  13. package/template/neo-bi-cmps/src/components/targetNumber__c/customStyleConfig/index.tsx +2 -0
  14. package/template/neo-bi-cmps/src/components/targetNumber__c/index.tsx +1 -0
  15. package/template/neo-bi-cmps/src/components/targetNumber__c/model.ts +3 -4
  16. package/template/neo-bi-cmps/src/components/targetNumber__c/style.scss +6 -0
  17. package/template/neo-custom-cmp-template/package.json +1 -1
  18. package/template/neo-custom-cmp-template/src/components/entityCardList__c/model.ts +2 -2
  19. package/template/neo-custom-cmp-template/src/components/entityDetail__c/model.ts +11 -5
  20. package/template/neo-custom-cmp-template/src/components/entityForm__c/model.ts +9 -3
  21. package/template/neo-custom-cmp-template/src/components/entityTable__c/model.ts +5 -5
  22. package/template/neo-custom-cmp-template/src/components/simpleCmp__c/model.ts +7 -7
  23. package/template/neo-h5-cmps/package.json +1 -1
  24. package/template/neo-h5-cmps/src/components/entityList__c/index.tsx +0 -3
  25. package/template/neo-h5-cmps/src/components/entityList__c/model.ts +51 -5
  26. package/template/neo-h5-cmps/src/components/simpleTable__c/model.ts +1 -1
  27. package/template/neo-order-cmps/package.json +1 -1
  28. package/template/neo-order-cmps/src/components/entityInfoCard__c/model.ts +9 -0
  29. package/template/neo-order-cmps/src/components/simpleTable__c/model.ts +1 -1
  30. package/template/react-custom-cmp-template/package.json +1 -1
  31. package/template/react-ts-custom-cmp-template/package.json +1 -1
  32. package/template/vue2-custom-cmp-template/package.json +1 -1
  33. package/template/neo-bi-cmps/lib/customStyleConfig.css +0 -15
  34. package/template/neo-bi-cmps/lib/customStyleConfig.js +0 -2
  35. package/template/neo-bi-cmps/lib/customStyleConfig.js.LICENSE.txt +0 -61
  36. package/template/neo-bi-cmps/lib/img/unlink.99e3018.99e3018.svg +0 -8
  37. package/template/neo-bi-cmps/lib/targetNumber.css +0 -7
  38. package/template/neo-bi-cmps/lib/targetNumber.js +0 -2
  39. package/template/neo-bi-cmps/lib/targetNumber.js.LICENSE.txt +0 -9
@@ -48,7 +48,7 @@
48
48
  "@commitlint/config-conventional": "^9.1.1",
49
49
  "@types/react": "^16.9.11",
50
50
  "@types/react-dom": "^16.9.15",
51
- "neo-cmp-cli": "^1.10.13",
51
+ "neo-cmp-cli": "^1.10.18",
52
52
  "husky": "^4.2.5",
53
53
  "lint-staged": "^10.2.9",
54
54
  "prettier": "^2.0.5",
@@ -86,6 +86,7 @@ module.exports = {
86
86
  },
87
87
  pushCmp: {
88
88
  // 用于构建并发布至 NeoCRM 的相关配置
89
+ // 备注:pushCmp 会服用量 build2lib 中的配置,执行 neo push cmp 时最好注释掉 build2lib 中的配置。
89
90
  /*
90
91
  【特别说明】以下配置项都自带默认值,非必填。如需自定义请自行配置。
91
92
  NODE_ENV: 'production',
@@ -97,6 +98,7 @@ module.exports = {
97
98
  assetsRoot: resolve('dist') // 上传指定目录下的脚本文件
98
99
  */
99
100
  },
101
+ /*
100
102
  build2lib: {
101
103
  entry: {
102
104
  targetNumber: './src/components/targetNumber__c/index.tsx',
@@ -118,4 +120,5 @@ module.exports = {
118
120
  productionGzipExtensions: ['js', 'css', 'json'],
119
121
  bundleAnalyzerReport: false,
120
122
  },
123
+ */
121
124
  };
@@ -50,7 +50,7 @@
50
50
  "@types/react": "^16.9.11",
51
51
  "@types/react-dom": "^16.9.15",
52
52
  "@types/axios": "^0.14.0",
53
- "neo-cmp-cli": "^1.10.13",
53
+ "neo-cmp-cli": "^1.10.18",
54
54
  "husky": "^4.2.5",
55
55
  "lint-staged": "^10.2.9",
56
56
  "prettier": "^2.0.5"
@@ -89,6 +89,8 @@ export default class CustomStyleConfigRenderer extends React.Component<
89
89
  render() {
90
90
  const { disabled, viewStyle, wideScreen, value } = this.props;
91
91
  const { isModalVisible } = this.state;
92
+ console.log('customStyleConfig:', this.props);
93
+ console.log('test1:', this.props.data['__NeoPageInfo'])
92
94
 
93
95
  return (
94
96
  <div className="properties-panel-custom-style-config">
@@ -135,6 +135,7 @@ class TargetNumber extends BaseCmp<TargetNumberProps, TargetNumberState> {
135
135
  }
136
136
 
137
137
  // 监听一个广播事件
138
+ console.log('TargetNumber 注册了一个广播事件 SavePageEvent');
138
139
  NeoEvent.listen('SavePageEvent', (eventData: any) => {
139
140
  console.log('TargetNumber 监听到了一个广播事件 SavePageEvent: ', eventData);
140
141
  });
@@ -1,5 +1,6 @@
1
1
  // 导入自定义配置项(用于对接复杂自定义配置)
2
- // import './customStyleConfig';
2
+ import './customStyleConfig';
3
+
3
4
  /**
4
5
  * @file 数值指标组件对接编辑器的描述文件
5
6
  * @description 定义组件在 Neo 平台编辑器中的配置信息
@@ -111,7 +112,6 @@ export class TargetNumberModel {
111
112
  label: '绑定字段',
112
113
  placeholder: '请至少选择一个要显示的字段',
113
114
  },
114
- /*
115
115
  {
116
116
  type: 'customStyleConfig',
117
117
  name: 'targetNumberStyle',
@@ -119,8 +119,7 @@ export class TargetNumberModel {
119
119
  viewStyle: 'tabs', // 'tabs'、'fold'
120
120
  wideScreen: false, // 是否开启宽屏展示模式
121
121
  },
122
- */
123
122
  ];
124
123
  }
125
124
 
126
- export default TargetNumberModel;
125
+ export default TargetNumberModel;
@@ -164,3 +164,9 @@
164
164
  }
165
165
  }
166
166
  }
167
+
168
+ .target-number {
169
+ background-color: red;
170
+ }
171
+
172
+
@@ -55,7 +55,7 @@
55
55
  "@types/react": "^16.9.11",
56
56
  "@types/react-dom": "^16.9.15",
57
57
  "@types/axios": "^0.14.0",
58
- "neo-cmp-cli": "^1.10.13",
58
+ "neo-cmp-cli": "^1.10.18",
59
59
  "husky": "^4.2.5",
60
60
  "lint-staged": "^10.2.9",
61
61
  "prettier": "^2.0.5"
@@ -28,7 +28,7 @@ export class EntityCardListModel {
28
28
  targetPage: string[] = ['all'];
29
29
 
30
30
  // 适配终端类型
31
- targetDevice: string = 'all';
31
+ targetDevice: string = 'web';
32
32
 
33
33
  // 组件图标,用于设置在编辑器左侧组件面板中展示的图标
34
34
  iconUrl: string = 'https://custom-widgets.bj.bcebos.com/data-list.svg';
@@ -60,7 +60,7 @@ export class EntityCardListModel {
60
60
  type: 'textarea',
61
61
  name: 'title',
62
62
  label: '组件标题',
63
- value: '数据卡片列表'
63
+ value: '数据卡片列表',
64
64
  },
65
65
  {
66
66
  type: 'xObjectDataApi', // 用于获取实体业务数据列表的配置项
@@ -29,8 +29,14 @@ export class EntityDetailModel {
29
29
  */
30
30
  // targetPage: string[] = ['all'];
31
31
 
32
- // 适配终端类型
33
- targetDevice: string = 'all';
32
+ /**
33
+ * 用于设置组件支持的终端类型
34
+ *
35
+ * 当前 NeoCRM 平台存在的终端类型:
36
+ * web: 网页端
37
+ * mobile: 移动端
38
+ */
39
+ targetDevice: string = 'web';
34
40
 
35
41
  /** 组件图标,用于设置在编辑器左侧组件面板中展示的图标 */
36
42
  iconUrl: string = 'https://custom-widgets.bj.bcebos.com/detail.svg';
@@ -56,13 +62,13 @@ export class EntityDetailModel {
56
62
  name: 'title',
57
63
  label: '标题',
58
64
  value: '实体数据详情',
59
- placeholder: '请输入标题'
65
+ placeholder: '请输入标题',
60
66
  },
61
67
  {
62
68
  type: 'panelSwitch',
63
69
  name: 'showTitle',
64
70
  label: '显示标题栏',
65
- value: true
71
+ value: true,
66
72
  },
67
73
  {
68
74
  type: 'xObjectDetailApi', // 用于选取对象业务详情数据的配置项
@@ -110,7 +116,7 @@ export class EntityDetailModel {
110
116
  label: '4列',
111
117
  value: 4,
112
118
  },
113
- ]
119
+ ],
114
120
  },
115
121
  ];
116
122
  }
@@ -31,8 +31,14 @@ export class EntityFormModel {
31
31
  */
32
32
  targetPage: string[] = ['all'];
33
33
 
34
- // 适配终端类型
35
- targetDevice: string = 'all';
34
+ /**
35
+ * 用于设置组件支持的终端类型
36
+ *
37
+ * 当前 NeoCRM 平台存在的终端类型:
38
+ * web: 网页端
39
+ * mobile: 移动端
40
+ */
41
+ targetDevice: string = 'web';
36
42
 
37
43
  enableDuplicate: boolean = true;
38
44
 
@@ -116,7 +122,7 @@ export class EntityFormModel {
116
122
  type: 'panelSwitch',
117
123
  name: 'showResetButton',
118
124
  label: '显示重置按钮',
119
- defaultChecked: true
125
+ defaultChecked: true,
120
126
  },
121
127
  ];
122
128
  }
@@ -34,14 +34,14 @@ export class EntityTableModel {
34
34
  */
35
35
  targetPage: string[] = ['all'];
36
36
 
37
- /**
37
+ /**
38
38
  * 用于设置组件支持的终端类型
39
- *
39
+ *
40
40
  * 当前 NeoCRM 平台存在的终端类型:
41
41
  * web: 网页端
42
42
  * mobile: 移动端
43
43
  */
44
- targetDevice: string = 'all';
44
+ targetDevice: string = 'web';
45
45
 
46
46
  /** 初次插入页面的默认属性数据 */
47
47
  defaultComProps = {
@@ -142,7 +142,7 @@ export class EntityTableModel {
142
142
  {
143
143
  type: 'panelSwitch',
144
144
  name: 'showAddButton',
145
- label: '显示新增按钮'
145
+ label: '显示新增按钮',
146
146
  },
147
147
  {
148
148
  type: 'panelSwitch',
@@ -153,7 +153,7 @@ export class EntityTableModel {
153
153
  {
154
154
  type: 'panelSwitch',
155
155
  name: 'showDeleteButton',
156
- label: '显示删除按钮'
156
+ label: '显示删除按钮',
157
157
  },
158
158
  ];
159
159
  }
@@ -11,9 +11,9 @@ export class CmpModel {
11
11
  // 分类标签,用于设置在编辑器左侧组件面板哪个分类中展示
12
12
  // tags: string[] = ['自定义组件'];
13
13
 
14
- /**
14
+ /**
15
15
  * 用于设置组件支持的页面类型
16
- *
16
+ *
17
17
  * 当前 NeoCRM 平台存在的页面类型:
18
18
  * all: 1 全页面
19
19
  * entityFormPage: 4 实体表单页
@@ -21,22 +21,22 @@ export class CmpModel {
21
21
  */
22
22
  targetPage: string[] = ['all'];
23
23
 
24
- /**
24
+ /**
25
25
  * 用于设置组件支持的终端类型
26
- *
26
+ *
27
27
  * 当前 NeoCRM 平台存在的终端类型:
28
28
  * web: 网页端
29
29
  * mobile: 移动端
30
30
  */
31
- targetDevice: string = 'all';
32
-
31
+ targetDevice: string = 'web';
33
32
 
34
33
  // 组件图标,用于设置在编辑器左侧组件面板中展示的图标
35
34
  iconUrl: string = 'https://neo-widgets.bj.bcebos.com/custom-widget.svg';
36
35
 
37
36
  // 初次插入页面的默认属性数据
38
37
  defaultComProps = {
39
- description: '营销服全场景智能CRM,帮助企业搭建数字化客户经营平台,实现业绩高质量增长。'
38
+ description:
39
+ '营销服全场景智能CRM,帮助企业搭建数字化客户经营平台,实现业绩高质量增长。',
40
40
  };
41
41
 
42
42
  /**
@@ -46,7 +46,7 @@
46
46
  "@types/react": "^16.9.11",
47
47
  "@types/react-dom": "^16.9.15",
48
48
  "@types/axios": "^0.14.0",
49
- "neo-cmp-cli": "^1.10.13",
49
+ "neo-cmp-cli": "^1.10.18",
50
50
  "husky": "^4.2.5",
51
51
  "lint-staged": "^10.2.9",
52
52
  "prettier": "^2.0.5"
@@ -16,9 +16,6 @@ interface EntityListProps {
16
16
  export default class EntityListCmp extends React.PureComponent<EntityListProps> {
17
17
  constructor(props: EntityListProps) {
18
18
  super(props);
19
-
20
- // 实例化 EntityListStore
21
- // this.entityListStore = EntityListStore.create({});
22
19
  }
23
20
 
24
21
  render() {
@@ -43,7 +43,17 @@ export class EntityListModel {
43
43
  // 初次插入页面的默认属性数据
44
44
  defaultComProps = {
45
45
  entityApiKey: 'account',
46
- disableSearch: true,
46
+ disableTitleView: true, // 隐藏头部view(含视图切换)
47
+ isShowTitlePicker: false, // 视图列表选择器
48
+ disableSearch: false,
49
+ disabledSort: false,
50
+ disabledFilter: false,
51
+ disabledOperationBtn: false,
52
+ showShortcutBtn: false,
53
+ initialListSize: 3,
54
+ tableType: 'list', // list 列表,lookup 下拉框,dashboardList BI 列表
55
+ isNoRefresh: true, // 禁用下拉刷新和上拉加载
56
+ skipExt: true, // 禁用 Nex 扩展
47
57
  };
48
58
 
49
59
  /* 当前数据列表支持的配置属性
@@ -69,23 +79,59 @@ export class EntityListModel {
69
79
  name: 'entityApiKey',
70
80
  label: '实体对象',
71
81
  },
82
+ {
83
+ type: 'dataViewIdSelect',
84
+ name: 'dataViewId',
85
+ xObjectApiKey: 'entityApiKey',
86
+ label: '列表视图',
87
+ },
72
88
  {
73
89
  type: 'panelSwitch',
74
- name: 'disableSearch',
75
- label: '隐藏全局搜索',
90
+ name: 'disableTitleView',
91
+ label: '隐藏头部view(含视图切换)',
76
92
  defaultChecked: true,
77
93
  },
94
+ {
95
+ type: 'panelSwitch',
96
+ name: 'isShowTitlePicker',
97
+ label: 'designer.components.857e98', '显示视图切换',
98
+ defaultChecked: false,
99
+ },
100
+ {
101
+ type: 'panelSwitch',
102
+ name: 'disableSearch',
103
+ label: '隐藏搜索',
104
+ defaultChecked: false,
105
+ },
78
106
  {
79
107
  type: 'panelSwitch',
80
108
  name: 'disabledSort',
81
109
  label: '隐藏排序功能',
82
- defaultChecked: true,
110
+ defaultChecked: false,
83
111
  },
84
112
  {
85
113
  type: 'panelSwitch',
86
114
  name: 'disabledFilter',
87
115
  label: '隐藏过滤功能',
88
- defaultChecked: true,
116
+ defaultChecked: false,
117
+ },
118
+ {
119
+ type: 'panelSwitch',
120
+ name: 'disabledOperationBtn',
121
+ label: '隐藏按钮操作区(含新建、批量操作等)',
122
+ defaultChecked: false,
123
+ },
124
+ {
125
+ type: 'panelSwitch',
126
+ name: 'disabledShortcutBtn',
127
+ label: '隐藏快捷按钮',
128
+ defaultChecked: false,
129
+ },
130
+ {
131
+ type: 'panelNumber',
132
+ name: 'initialListSize',
133
+ label: '初始化展示条数',
134
+ value: 3,
89
135
  },
90
136
  ];
91
137
  }
@@ -42,7 +42,7 @@ export class SimpleTableModel {
42
42
  * web: 网页端
43
43
  * mobile: 移动端
44
44
  */
45
- targetDevice: string = 'all';
45
+ targetDevice: string = 'web';
46
46
 
47
47
  /** 初次插入页面的默认属性数据 */
48
48
  defaultComProps = {
@@ -47,7 +47,7 @@
47
47
  "@types/react": "^16.9.11",
48
48
  "@types/react-dom": "^16.9.15",
49
49
  "@types/axios": "^0.14.0",
50
- "neo-cmp-cli": "^1.10.13",
50
+ "neo-cmp-cli": "^1.10.18",
51
51
  "husky": "^4.2.5",
52
52
  "lint-staged": "^10.2.9",
53
53
  "prettier": "^2.0.5"
@@ -29,6 +29,15 @@ export class EntityInfoCardModel {
29
29
  */
30
30
  // targetPage: string[] = ['all'];
31
31
 
32
+ /**
33
+ * 用于设置组件支持的终端类型
34
+ *
35
+ * 当前 NeoCRM 平台存在的终端类型:
36
+ * web: 网页端
37
+ * mobile: 移动端
38
+ */
39
+ targetDevice: string = 'web';
40
+
32
41
  /** 组件图标,用于设置在编辑器左侧组件面板中展示的图标 */
33
42
  iconUrl: string = 'https://custom-widgets.bj.bcebos.com/detail.svg';
34
43
 
@@ -41,7 +41,7 @@ export class SimpleTableModel {
41
41
  * web: 网页端
42
42
  * mobile: 移动端
43
43
  */
44
- targetDevice: string = 'all';
44
+ targetDevice: string = 'web';
45
45
 
46
46
  /** 初次插入页面的默认属性数据 */
47
47
  defaultComProps = {
@@ -45,7 +45,7 @@
45
45
  "devDependencies": {
46
46
  "@commitlint/cli": "^8.3.5",
47
47
  "@commitlint/config-conventional": "^9.1.1",
48
- "neo-cmp-cli": "^1.10.13",
48
+ "neo-cmp-cli": "^1.10.18",
49
49
  "husky": "^4.2.5",
50
50
  "lint-staged": "^10.2.9",
51
51
  "prettier": "^2.0.5"
@@ -47,7 +47,7 @@
47
47
  "@commitlint/config-conventional": "^9.1.1",
48
48
  "@types/react": "^16.9.11",
49
49
  "@types/react-dom": "^16.9.15",
50
- "neo-cmp-cli": "^1.10.13",
50
+ "neo-cmp-cli": "^1.10.18",
51
51
  "husky": "^4.2.5",
52
52
  "lint-staged": "^10.2.9",
53
53
  "prettier": "^2.0.5"
@@ -45,7 +45,7 @@
45
45
  "devDependencies": {
46
46
  "@commitlint/cli": "^8.3.5",
47
47
  "@commitlint/config-conventional": "^9.1.1",
48
- "neo-cmp-cli": "^1.10.13",
48
+ "neo-cmp-cli": "^1.10.18",
49
49
  "husky": "^4.2.5",
50
50
  "lint-staged": "^10.2.9",
51
51
  "prettier": "^2.0.5",