cnhis-design-vue 0.1.79-beta → 0.1.83-beta
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.
- package/es/age/index.js +2 -2
- package/es/big-table/index.js +21 -21
- package/es/button/index.js +2 -2
- package/es/captcha/index.js +3 -3
- package/es/checkbox/index.js +1 -1
- package/es/color-picker/index.js +1 -1
- package/es/drag-layout/index.js +3 -3
- package/es/editor/index.js +1 -1
- package/es/fabric-chart/index.js +9 -9
- package/es/img/no-data2.0ca9388b.png +0 -0
- package/es/index/index.js +618 -493
- package/es/index/style.css +1 -1
- package/es/input/index.js +1 -1
- package/es/map/index.js +1 -1
- package/es/multi-chat/index.js +185 -135
- package/es/multi-chat/style.css +1 -1
- package/es/multi-chat-client/index.js +97 -66
- package/es/multi-chat-client/style.css +1 -1
- package/es/multi-chat-history/index.js +4 -4
- package/es/multi-chat-record/index.js +4 -4
- package/es/multi-chat-setting/index.js +51 -38
- package/es/multi-chat-setting/style.css +1 -1
- package/es/multi-chat-sip/index.js +1 -1
- package/es/radio/index.js +1 -1
- package/es/scale-view/index.js +100 -73
- package/es/scale-view/style.css +1 -1
- package/es/select/index.js +3 -3
- package/es/select-label/index.js +2 -2
- package/es/select-person/index.js +2 -2
- package/es/table-filter/index.js +228 -185
- package/es/table-filter/style.css +1 -1
- package/es/tag/index.js +1 -1
- package/es/utils/vexutils.js +93 -0
- package/es/verification-code/index.js +2 -2
- package/lib/cui.common.js +940 -726
- package/lib/cui.umd.js +940 -726
- package/lib/cui.umd.min.js +65 -65
- package/lib/img/no-data2.0ca9388b.png +0 -0
- package/package.json +2 -2
- package/packages/multi-chat/chat/chatFooter.vue +18 -5
- package/packages/multi-chat/chat/index.vue +2 -1
- package/packages/multi-chat/chat/scrollList.vue +56 -28
- package/packages/multi-chat/img/no-data2.png +0 -0
- package/packages/multi-chat/setting/baseInfo/index.vue +5 -0
- package/packages/scale-view/formitem/r-choice.vue +8 -1
- package/packages/scale-view/scaleView.vue +19 -5
- package/packages/table-filter/src/components/multi-select/multi-select.vue +52 -33
- package/packages/table-filter/src/components/out-quick-search/out-quick-search.vue +6 -39
- package/packages/table-filter/src/mixins/wordBookutils.js +99 -0
- package/packages/table-filter/src/quick-search/QuickSearch.vue +6 -41
- package/src/utils/vexutils.js +70 -0
|
@@ -715,6 +715,7 @@ import multiSelect from '../components/multi-select/multi-select';
|
|
|
715
715
|
import resize from 'vue-resize-directive';
|
|
716
716
|
import { durationMixin, $utils, filterApiFn } from '../mixins/mixins';
|
|
717
717
|
import vexutils from '@/utils/vexutils';
|
|
718
|
+
import wordBookutils from '../mixins/wordBookutils';
|
|
718
719
|
import create from '@/core/create';
|
|
719
720
|
export default create({
|
|
720
721
|
name: "quick-search",
|
|
@@ -1114,47 +1115,11 @@ export default create({
|
|
|
1114
1115
|
});
|
|
1115
1116
|
},
|
|
1116
1117
|
handleWordbookData(item, data, params) {
|
|
1117
|
-
|
|
1118
|
-
|
|
1119
|
-
|
|
1120
|
-
|
|
1121
|
-
|
|
1122
|
-
myName: defaultValue,
|
|
1123
|
-
showKeys: defaultValueTitle
|
|
1124
|
-
};
|
|
1125
|
-
}
|
|
1126
|
-
if (data && data.result) {
|
|
1127
|
-
let { page, hasNextPage } = data.map;
|
|
1128
|
-
item.searchPageConfig = Object.assign(item.searchPageConfig, {
|
|
1129
|
-
page,
|
|
1130
|
-
hasNextPage,
|
|
1131
|
-
isRequest: true,
|
|
1132
|
-
keyword: params?.keyword || undefined
|
|
1133
|
-
});
|
|
1134
|
-
// 数组赋值并添加唯一name
|
|
1135
|
-
let rows = data.map.rows.map(row => {
|
|
1136
|
-
let showKeysStr = [];
|
|
1137
|
-
showKeys.forEach(ren => {
|
|
1138
|
-
let str = vexutils.stringToValue(row[ren],'change_text')
|
|
1139
|
-
showKeysStr.push(str);
|
|
1140
|
-
});
|
|
1141
|
-
let name = vexutils.stringToValue(row[item.setting.wordbook.field_key],'value')
|
|
1142
|
-
return Object.assign(row, {
|
|
1143
|
-
myName: name,
|
|
1144
|
-
showKeys: showKeysStr.join("")
|
|
1145
|
-
});
|
|
1146
|
-
});
|
|
1147
|
-
// 数组对象去重
|
|
1148
|
-
let obj = {};
|
|
1149
|
-
let arr = rows.reduce((cur, next) => {
|
|
1150
|
-
obj[next.myName] ? "" : (obj[next.myName] = true && cur.push(next));
|
|
1151
|
-
return cur;
|
|
1152
|
-
}, []);
|
|
1153
|
-
if (defaultItem) {
|
|
1154
|
-
arr.unshift(defaultItem);
|
|
1155
|
-
}
|
|
1156
|
-
this.$set(item, "dataSource", arr);
|
|
1157
|
-
}
|
|
1118
|
+
this.$set(item, "hasFieldList", false);
|
|
1119
|
+
const {rows,hasFieldList,searchPageConfig} = wordBookutils.handleWordbookData(item,data,params);
|
|
1120
|
+
this.$set(item, "hasFieldList", hasFieldList);
|
|
1121
|
+
this.$set(item, "dataSource", rows);
|
|
1122
|
+
item.searchPageConfig = Object.assign(item.searchPageConfig, searchPageConfig);
|
|
1158
1123
|
},
|
|
1159
1124
|
filterChange() {},
|
|
1160
1125
|
maxTagPlaceholder(item) {
|
package/src/utils/vexutils.js
CHANGED
|
@@ -698,6 +698,76 @@ XEUtils.mixin({
|
|
|
698
698
|
}
|
|
699
699
|
return item;
|
|
700
700
|
},
|
|
701
|
+
|
|
702
|
+
notEmpty(text) {
|
|
703
|
+
return XEUtils.isBoolean(text) || String(text) === "0" || !!text;
|
|
704
|
+
},
|
|
705
|
+
|
|
706
|
+
/**
|
|
707
|
+
* 变量转换
|
|
708
|
+
* @param {string} str
|
|
709
|
+
* @param {object} obj
|
|
710
|
+
* @param {string | number} noval // 没有值,默认赋值
|
|
711
|
+
*/
|
|
712
|
+
handleSysParams(str, obj = {}, noval = "") {
|
|
713
|
+
let p = {
|
|
714
|
+
...obj
|
|
715
|
+
};
|
|
716
|
+
const that = this;
|
|
717
|
+
// 解析变量
|
|
718
|
+
const getValList = (plsList = [], obj = {}) => {
|
|
719
|
+
var l = [];
|
|
720
|
+
var o = obj;
|
|
721
|
+
plsList.forEach(v => {
|
|
722
|
+
let c = v;
|
|
723
|
+
// xx.xx
|
|
724
|
+
if (v.includes(".")) {
|
|
725
|
+
try {
|
|
726
|
+
// 使用 eval 解析 'result.map.map.filed'
|
|
727
|
+
eval(`c=o.${v}`);
|
|
728
|
+
} catch (error) {
|
|
729
|
+
c = "";
|
|
730
|
+
}
|
|
731
|
+
}
|
|
732
|
+
if (XEUtils.notEmpty(c)) {
|
|
733
|
+
l.push(c);
|
|
734
|
+
}
|
|
735
|
+
});
|
|
736
|
+
return l;
|
|
737
|
+
};
|
|
738
|
+
const getVal = (t, r, k) => {
|
|
739
|
+
return t.replace(r, function() {
|
|
740
|
+
var pKey = arguments[1];
|
|
741
|
+
// 切割
|
|
742
|
+
var pls = pKey.split("!");
|
|
743
|
+
// 取值
|
|
744
|
+
var l = getValList(pls, p);
|
|
745
|
+
var f = l.find(v => XEUtils.notEmpty(v));
|
|
746
|
+
var res = f;
|
|
747
|
+
res = XEUtils.notEmpty(res) ? res : noval;
|
|
748
|
+
return res;
|
|
749
|
+
});
|
|
750
|
+
};
|
|
751
|
+
if (typeof str === "string") {
|
|
752
|
+
if (str.includes("form")) {
|
|
753
|
+
str = getVal(str, /\${(.*?)\}/g, "form");
|
|
754
|
+
}
|
|
755
|
+
if (str.includes("sys")) {
|
|
756
|
+
str = getVal(str, /\${(.*?)\}/g, "sys");
|
|
757
|
+
}
|
|
758
|
+
if (str.includes("db")) {
|
|
759
|
+
str = getVal(str, /\${(.*?)\}/g, "db");
|
|
760
|
+
}
|
|
761
|
+
if (str.includes("table")) {
|
|
762
|
+
str = getVal(str, /\${(.*?)\}/g, "table");
|
|
763
|
+
}
|
|
764
|
+
if (str.includes("result")) {
|
|
765
|
+
str = getVal(str, /\${(.*?)\}/g, "result");
|
|
766
|
+
}
|
|
767
|
+
}
|
|
768
|
+
return str;
|
|
769
|
+
},
|
|
770
|
+
|
|
701
771
|
});
|
|
702
772
|
|
|
703
773
|
export default XEUtils;
|