@zgfe/business-lib 1.2.32 → 1.2.33-beiming.2

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 (106) hide show
  1. package/README.md +12 -12
  2. package/config.js +41 -41
  3. package/es/AUMFormulaTarget/components/formula/index.js +45 -4
  4. package/es/AUMFormulaTarget/components/formula/index.less +82 -82
  5. package/es/AUMFormulaTarget/components/formula/types.d.ts +2 -1
  6. package/es/AUMFormulaTarget/components/panel/index.less +269 -269
  7. package/es/AUMFormulaTarget/components/symbol/index.less +49 -49
  8. package/es/AUMFormulaTarget/index.js +6 -3
  9. package/es/AUMFormulaTarget/styles/index.less +74 -74
  10. package/es/AUMFormulaTarget/types.d.ts +1 -0
  11. package/es/addToPanel/styles/addPanel.less +25 -25
  12. package/es/addToPanel/styles/index.less +17 -17
  13. package/es/addToPanel/styles/style.less +66 -66
  14. package/es/addToScene/styles/index.less +30 -30
  15. package/es/assets/colorIcon/demo.css +539 -539
  16. package/es/assets/colorIcon/demo_index.html +741 -741
  17. package/es/assets/colorIcon/iconfont.css +112 -112
  18. package/es/assets/colorIcon/iconfont.json +177 -177
  19. package/es/assets/colorIcon/iconfont.svg +67 -67
  20. package/es/assets/iconfont/demo.css +539 -539
  21. package/es/assets/iconfont/demo_index.html +4512 -4512
  22. package/es/assets/iconfont/iconfont.css +767 -767
  23. package/es/assets/iconfont/iconfont.json +1325 -1325
  24. package/es/assets/styles/chunks.less +183 -183
  25. package/es/assets/styles/inner.less +3 -3
  26. package/es/assets/styles/resetAntd.less +550 -550
  27. package/es/assets/styles/variable.less +21 -21
  28. package/es/attrCondition/styles/index.less +101 -101
  29. package/es/attrConditions/styles/group.less +49 -49
  30. package/es/attrConditions/styles/index.less +151 -151
  31. package/es/attributeSelector/styles/index.less +141 -141
  32. package/es/chart/styles/index.less +68 -68
  33. package/es/chart/util/data/china.js +17 -17
  34. package/es/cycleTime/styles/index.less +24 -24
  35. package/es/cycleTime/styles/month.less +95 -95
  36. package/es/dataSetGroup/styles/index.less +146 -146
  37. package/es/datePicker/styles/index.less +53 -53
  38. package/es/demoWrapper/index.less +3 -3
  39. package/es/dialog/styles/index.less +22 -22
  40. package/es/dnd/demo/styles/index.less +34 -34
  41. package/es/dnd/styles/index.less +19 -19
  42. package/es/eventSelector/styles/index.less +107 -107
  43. package/es/formulaTarget/components/formula/index.less +76 -76
  44. package/es/formulaTarget/components/panel/index.less +139 -139
  45. package/es/formulaTarget/components/symbol/index.less +49 -49
  46. package/es/formulaTarget/styles/index.less +74 -74
  47. package/es/hooks/types/subject.d.ts +14 -14
  48. package/es/icon/demo/list.less +32 -32
  49. package/es/layout/analysisLayout/demo/index.less +12 -12
  50. package/es/layout/analysisLayout/index.less +118 -118
  51. package/es/layout/columnLayout/demo/index.less +15 -15
  52. package/es/layout/columnLayout/index.less +81 -81
  53. package/es/layout/detail/index.less +27 -27
  54. package/es/layout/optionTitle/components/btnMenu/index.less +18 -18
  55. package/es/layout/optionTitle/components/changePanelModal/styles/index.less +92 -92
  56. package/es/layout/optionTitle/components/title/index.less +43 -43
  57. package/es/layout/optionTitle/demo/index.less +12 -12
  58. package/es/layout/optionTitle/styles/index.less +30 -30
  59. package/es/layout/optionTitle/styles/layout.less +90 -90
  60. package/es/layout/optionTitle/styles/search.less +27 -27
  61. package/es/loading/styles/index.less +20 -20
  62. package/es/loginForm/index.less +7 -7
  63. package/es/productCondition/conditions/styles/cdpCondition.less +31 -31
  64. package/es/productCondition/conditions/styles/cdpCshCondition.less +41 -41
  65. package/es/productCondition/conditions/styles/eventCondition.less +51 -51
  66. package/es/productCondition/conditions/styles/periodCondition.less +26 -26
  67. package/es/productCondition/conditions/styles/propCondition.less +43 -43
  68. package/es/productCondition/conditions/styles/runTimesCondition.less +19 -19
  69. package/es/productCondition/conditions/styles/tagsCondition.less +20 -20
  70. package/es/productCondition/conditions/styles/textDesc.less +17 -17
  71. package/es/productCondition/styles/conditionTypeList.less +30 -30
  72. package/es/productCondition/styles/conditionWrap.less +18 -18
  73. package/es/productCondition/styles/index.less +33 -33
  74. package/es/productCondition/styles/orConditions.less +34 -34
  75. package/es/productCondition/styles/relationLabel.less +19 -19
  76. package/es/quickDatePicker/styles/index.less +138 -138
  77. package/es/select/handle.js +2 -2
  78. package/es/select/styles/handle.less +193 -193
  79. package/es/select/styles/index.less +129 -129
  80. package/es/socket/demo/index.less +27 -27
  81. package/es/table/styles/index.less +5 -5
  82. package/es/targetConditionGroup/demo/styles/index.less +29 -29
  83. package/es/targetConditionGroup/styles/index.less +53 -53
  84. package/es/targetSelector/styles/index.less +110 -110
  85. package/es/userCondition/conditions/styles/cdpCondition.less +31 -31
  86. package/es/userCondition/conditions/styles/cdpCshCondition.less +41 -41
  87. package/es/userCondition/conditions/styles/eventCondition.less +51 -51
  88. package/es/userCondition/conditions/styles/periodCondition.less +26 -26
  89. package/es/userCondition/conditions/styles/propCondition.less +43 -43
  90. package/es/userCondition/conditions/styles/runTimesCondition.less +19 -19
  91. package/es/userCondition/conditions/styles/tagsCondition.less +20 -20
  92. package/es/userCondition/conditions/styles/textDesc.less +17 -17
  93. package/es/userCondition/styles/conditionTypeList.less +30 -30
  94. package/es/userCondition/styles/conditionWrap.less +18 -18
  95. package/es/userCondition/styles/index.less +33 -33
  96. package/es/userCondition/styles/orConditions.less +34 -34
  97. package/es/userCondition/styles/relationLabel.less +19 -19
  98. package/es/userGroup/styles/index.less +146 -146
  99. package/es/userGroupHeader/styles/index.less +31 -31
  100. package/es/userTagsSelector/components/search/index.less +6 -6
  101. package/es/userTagsSelector/components/tagList/index.less +13 -13
  102. package/es/userTagsSelector/groups/styles/option.less +55 -55
  103. package/es/userTagsSelector/multipleCheckPanel/styles/option.less +40 -40
  104. package/es/userTagsSelector/styles/cascaderOverlay.less +34 -34
  105. package/es/userTagsSelector/styles/index.less +10 -10
  106. package/package.json +2 -2
package/README.md CHANGED
@@ -1,12 +1,12 @@
1
- ## 规范
2
-
3
- ### 样式命名规范
4
-
5
- biz-组件名或缩写-具体样式比如 layout 组件的左侧栏命名: biz-layout-left
6
-
7
- ## 注意事项
8
-
9
- ### 样式命名
10
-
11
- 1. 命名上注意语义化,尽量减少语义不明的命名,比如 left、main、center 之类的
12
- 2. className 的命名,统一采用 class-name,不要用驼峰命名
1
+ ## 规范
2
+
3
+ ### 样式命名规范
4
+
5
+ biz-组件名或缩写-具体样式比如 layout 组件的左侧栏命名: biz-layout-left
6
+
7
+ ## 注意事项
8
+
9
+ ### 样式命名
10
+
11
+ 1. 命名上注意语义化,尽量减少语义不明的命名,比如 left、main、center 之类的
12
+ 2. className 的命名,统一采用 class-name,不要用驼峰命名
package/config.js CHANGED
@@ -1,41 +1,41 @@
1
- const fs = require('fs');
2
- const path = require('path');
3
-
4
- /**
5
- * 对关键配置信息进行本地化存储,避免多人项目配置代码冲突
6
- * @param defaultConfig
7
- * @returns
8
- */
9
- function getConfig(defaultConfig, basePath) {
10
- const configPath = path.resolve(basePath, '.config.json');
11
- let resConfig = defaultConfig;
12
- try {
13
- if (fs.existsSync(configPath)) {
14
- const config = fs.readFileSync(configPath, 'utf-8');
15
- if (!config || config === '{}') {
16
- throw new Error('配置文件为空');
17
- }
18
- const configObj = JSON.parse(config);
19
- // 如果读取的配置文件,数据结构与默认配置不一致,则更新配置文件,更新规则:以默认配置为准,保留用户自定义配置
20
- const isSame = Object.keys(defaultConfig).every((key) => {
21
- return configObj.hasOwnProperty(key);
22
- });
23
- if (!isSame) {
24
- resConfig = Object.assign({}, defaultConfig, configObj);
25
- throw new Error('配置文件数据结构不一致');
26
- }
27
- resConfig = configObj;
28
- } else {
29
- throw new Error('配置文件不存在');
30
- }
31
- } catch (e) {
32
- console.log(e.message);
33
- fs.writeFileSync(configPath, JSON.stringify(resConfig, null, 2));
34
- }
35
- console.log('配置详情', resConfig);
36
- return resConfig;
37
- }
38
-
39
- module.exports = {
40
- getConfig,
41
- };
1
+ const fs = require('fs');
2
+ const path = require('path');
3
+
4
+ /**
5
+ * 对关键配置信息进行本地化存储,避免多人项目配置代码冲突
6
+ * @param defaultConfig
7
+ * @returns
8
+ */
9
+ function getConfig(defaultConfig, basePath) {
10
+ const configPath = path.resolve(basePath, '.config.json');
11
+ let resConfig = defaultConfig;
12
+ try {
13
+ if (fs.existsSync(configPath)) {
14
+ const config = fs.readFileSync(configPath, 'utf-8');
15
+ if (!config || config === '{}') {
16
+ throw new Error('配置文件为空');
17
+ }
18
+ const configObj = JSON.parse(config);
19
+ // 如果读取的配置文件,数据结构与默认配置不一致,则更新配置文件,更新规则:以默认配置为准,保留用户自定义配置
20
+ const isSame = Object.keys(defaultConfig).every((key) => {
21
+ return configObj.hasOwnProperty(key);
22
+ });
23
+ if (!isSame) {
24
+ resConfig = Object.assign({}, defaultConfig, configObj);
25
+ throw new Error('配置文件数据结构不一致');
26
+ }
27
+ resConfig = configObj;
28
+ } else {
29
+ throw new Error('配置文件不存在');
30
+ }
31
+ } catch (e) {
32
+ console.log(e.message);
33
+ fs.writeFileSync(configPath, JSON.stringify(resConfig, null, 2));
34
+ }
35
+ console.log('配置详情', resConfig);
36
+ return resConfig;
37
+ }
38
+
39
+ module.exports = {
40
+ getConfig,
41
+ };
@@ -28,13 +28,17 @@ var FormulaContainer = /*#__PURE__*/React.forwardRef(function (props, ref) {
28
28
  _useState6 = _slicedToArray(_useState5, 2),
29
29
  fieldValue = _useState6[0],
30
30
  setFieldValue = _useState6[1];
31
+ var _useState7 = useState(),
32
+ _useState8 = _slicedToArray(_useState7, 2),
33
+ fieldMaxValue = _useState8[0],
34
+ setFieldMaxValue = _useState8[1];
31
35
  useEffect(function () {
32
36
  init();
33
37
  }, []);
34
38
  useEffect(function () {
35
39
  var item = formatTarget(targetList, 1);
36
- props.onChange && props.onChange(item.formulaList, item.formula, operator === null || operator === void 0 ? void 0 : operator.value, fieldValue);
37
- }, [targetList, operator, fieldValue]);
40
+ props.onChange && props.onChange(item.formulaList, item.formula, operator === null || operator === void 0 ? void 0 : operator.value, fieldValue, fieldMaxValue);
41
+ }, [targetList, operator, fieldValue, fieldMaxValue]);
38
42
  useImperativeHandle(ref, function () {
39
43
  return {
40
44
  reset: init
@@ -45,6 +49,7 @@ var FormulaContainer = /*#__PURE__*/React.forwardRef(function (props, ref) {
45
49
  value: props.operator
46
50
  });
47
51
  setFieldValue(props.fieldValue);
52
+ setFieldMaxValue(props.fieldMaxValue);
48
53
  setTargetList(targetsFormat(props.formula, props.value, 1));
49
54
  };
50
55
  var _onChange = function onChange(index, data) {
@@ -138,14 +143,18 @@ var FormulaContainer = /*#__PURE__*/React.forwardRef(function (props, ref) {
138
143
  overlayWidth: 96,
139
144
  value: operator,
140
145
  onChange: onOperateChange
141
- }), /*#__PURE__*/React.createElement(Input, {
146
+ }), operator && operator.value === 'between' ? /*#__PURE__*/React.createElement("span", {
147
+ style: {
148
+ display: 'flex'
149
+ }
150
+ }, /*#__PURE__*/React.createElement(Input, {
142
151
  style: {
143
152
  marginLeft: 16,
144
153
  borderWidth: 0
145
154
  },
146
155
  type: "number",
147
156
  value: fieldValue,
148
- placeholder: "\u8BF7\u8F93\u5165",
157
+ placeholder: "\u8BF7\u8F93\u5165\u6700\u5C0F\u503C",
149
158
  onChange: function onChange(e) {
150
159
  var _e$target$value;
151
160
  e.persist();
@@ -154,6 +163,38 @@ var FormulaContainer = /*#__PURE__*/React.forwardRef(function (props, ref) {
154
163
  var dealStr = xsStr ? str.split('.')[0] + '.' + xsStr : str;
155
164
  setFieldValue(dealStr);
156
165
  }
166
+ }), /*#__PURE__*/React.createElement(Input, {
167
+ style: {
168
+ marginLeft: 16,
169
+ borderWidth: 0
170
+ },
171
+ type: "number",
172
+ value: fieldMaxValue,
173
+ placeholder: "\u8BF7\u8F93\u5165\u6700\u5927\u503C",
174
+ onChange: function onChange(e) {
175
+ var _e$target$value2;
176
+ e.persist();
177
+ var str = (_e$target$value2 = e.target.value) === null || _e$target$value2 === void 0 ? void 0 : _e$target$value2.slice(0, 20);
178
+ var xsStr = str.split('.')[1] ? str.split('.')[1].slice(0, 2) : '';
179
+ var dealStr = xsStr ? str.split('.')[0] + '.' + xsStr : str;
180
+ setFieldMaxValue(dealStr);
181
+ }
182
+ })) : /*#__PURE__*/React.createElement(Input, {
183
+ style: {
184
+ marginLeft: 16,
185
+ borderWidth: 0
186
+ },
187
+ type: "number",
188
+ value: fieldValue,
189
+ placeholder: "\u8BF7\u8F93\u5165",
190
+ onChange: function onChange(e) {
191
+ var _e$target$value3;
192
+ e.persist();
193
+ var str = (_e$target$value3 = e.target.value) === null || _e$target$value3 === void 0 ? void 0 : _e$target$value3.slice(0, 20);
194
+ var xsStr = str.split('.')[1] ? str.split('.')[1].slice(0, 2) : '';
195
+ var dealStr = xsStr ? str.split('.')[0] + '.' + xsStr : str;
196
+ setFieldValue(dealStr);
197
+ }
157
198
  }), /*#__PURE__*/React.createElement(IconFont, {
158
199
  style: {
159
200
  marginLeft: 16
@@ -1,82 +1,82 @@
1
- @import '../../../assets/styles/inner.less';
2
-
3
- .aum-formula-container {
4
- display: flex;
5
- flex-wrap: wrap;
6
- align-items: center;
7
- line-height: 48px;
8
- &-target {
9
- display: flex;
10
- &:hover {
11
- .formula-container-option:not(.active) {
12
- display: flex;
13
- color: #b9ceff;
14
- &.disabled {
15
- color: #ccd0d4;
16
- }
17
- }
18
- }
19
- &-handle {
20
- min-width: 88px;
21
- // min-width: 184px;
22
- &.focus {
23
- .biz-select-handle-input {
24
- border-color: @primary-color;
25
- }
26
- }
27
- &-icon {
28
- margin-left: 4px;
29
- color: @text-color-middle;
30
- }
31
- &-name {
32
- margin-left: 4px;
33
- }
34
- }
35
- }
36
-
37
- &-format {
38
- display: flex;
39
- align-items: center;
40
- margin-left: 16px;
41
- & > span {
42
- margin-right: 12px;
43
- }
44
- & > span:hover {
45
- color: @error-color;
46
- }
47
-
48
- .biz-select-handle {
49
- min-width: 136px;
50
- }
51
- }
52
- &-add {
53
- margin-left: 16px;
54
- color: @primary-color;
55
- font-size: 18px !important;
56
- cursor: pointer;
57
- }
58
- &-option {
59
- display: flex;
60
- align-items: center;
61
- color: transparent;
62
- cursor: pointer;
63
- &.active {
64
- display: flex;
65
- color: #354354;
66
- }
67
- &.disabled {
68
- cursor: not-allowed;
69
- }
70
-
71
- &:first-child {
72
- margin-right: 4px;
73
- }
74
- &:last-child {
75
- margin-left: 4px;
76
- }
77
- }
78
-
79
- &-symbol {
80
- margin: 0 12px;
81
- }
82
- }
1
+ @import '../../../assets/styles/inner.less';
2
+
3
+ .aum-formula-container {
4
+ display: flex;
5
+ flex-wrap: wrap;
6
+ align-items: center;
7
+ line-height: 48px;
8
+ &-target {
9
+ display: flex;
10
+ &:hover {
11
+ .formula-container-option:not(.active) {
12
+ display: flex;
13
+ color: #b9ceff;
14
+ &.disabled {
15
+ color: #ccd0d4;
16
+ }
17
+ }
18
+ }
19
+ &-handle {
20
+ min-width: 88px;
21
+ // min-width: 184px;
22
+ &.focus {
23
+ .biz-select-handle-input {
24
+ border-color: @primary-color;
25
+ }
26
+ }
27
+ &-icon {
28
+ margin-left: 4px;
29
+ color: @text-color-middle;
30
+ }
31
+ &-name {
32
+ margin-left: 4px;
33
+ }
34
+ }
35
+ }
36
+
37
+ &-format {
38
+ display: flex;
39
+ align-items: center;
40
+ margin-left: 16px;
41
+ & > span {
42
+ margin-right: 12px;
43
+ }
44
+ & > span:hover {
45
+ color: @error-color;
46
+ }
47
+
48
+ .biz-select-handle {
49
+ min-width: 136px;
50
+ }
51
+ }
52
+ &-add {
53
+ margin-left: 16px;
54
+ color: @primary-color;
55
+ font-size: 18px !important;
56
+ cursor: pointer;
57
+ }
58
+ &-option {
59
+ display: flex;
60
+ align-items: center;
61
+ color: transparent;
62
+ cursor: pointer;
63
+ &.active {
64
+ display: flex;
65
+ color: #354354;
66
+ }
67
+ &.disabled {
68
+ cursor: not-allowed;
69
+ }
70
+
71
+ &:first-child {
72
+ margin-right: 4px;
73
+ }
74
+ &:last-child {
75
+ margin-left: 4px;
76
+ }
77
+ }
78
+
79
+ &-symbol {
80
+ margin: 0 12px;
81
+ }
82
+ }
@@ -6,7 +6,8 @@ export declare namespace FormulaContainerTypes {
6
6
  resultFormat?: string;
7
7
  operator?: string;
8
8
  fieldValue?: string;
9
- onChange?: (formulaList: TargetConditionTypes.Value[], formula: string, operator?: string, fieldValue?: string) => void;
9
+ fieldMaxValue?: string;
10
+ onChange?: (formulaList: TargetConditionTypes.Value[], formula: string, operator?: string, fieldValue?: string, fieldMaxValue?: string) => void;
10
11
  }
11
12
  type Value = null | string | TargetConditionTypes.Value;
12
13
  interface FormulaItemValue {