three-trees-ui 1.0.57 → 1.0.59
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/lib/three-trees-ui.common.js +259 -26
- package/lib/three-trees-ui.css +1 -1
- package/lib/three-trees-ui.umd.js +259 -26
- package/lib/three-trees-ui.umd.min.js +1 -1
- package/package.json +1 -1
- package/packages/Table/src/Table.vue +4 -0
- package/src/mixins/onlineSubtable.js +283 -0
- package/src/mixins/templatePreview.js +31 -54
- package/src/utils.js +32 -1
|
@@ -1249,7 +1249,7 @@ var utils = {
|
|
|
1249
1249
|
}
|
|
1250
1250
|
const keyPath = config[key];
|
|
1251
1251
|
// 获取当前组件所在的表单
|
|
1252
|
-
const formInst = utils.getOnlineFormInstance(inst
|
|
1252
|
+
const formInst = utils.getOnlineFormInstance(inst);
|
|
1253
1253
|
// 获取当前组件是否在子表中的某一行
|
|
1254
1254
|
const {
|
|
1255
1255
|
subScopeEl,
|
|
@@ -1527,6 +1527,37 @@ Date.prototype.format = function (format) {
|
|
|
1527
1527
|
}
|
|
1528
1528
|
return format;
|
|
1529
1529
|
};
|
|
1530
|
+
|
|
1531
|
+
//精确四舍五入
|
|
1532
|
+
Number.prototype.toFixedRound = function (d) {
|
|
1533
|
+
d = Number(d);
|
|
1534
|
+
var s = this + '';
|
|
1535
|
+
if (!d) d = 0;
|
|
1536
|
+
if (s.indexOf('.') == -1) s += '.';
|
|
1537
|
+
s += new Array(d + 1).join('0');
|
|
1538
|
+
if (new RegExp('^(-|\\+)?(\\d+(\\.\\d{0,' + (d + 1) + '})?)\\d*$').test(s)) {
|
|
1539
|
+
var s = '0' + RegExp.$2,
|
|
1540
|
+
pm = RegExp.$1,
|
|
1541
|
+
a = RegExp.$3.length,
|
|
1542
|
+
b = true;
|
|
1543
|
+
if (a == d + 2) {
|
|
1544
|
+
a = s.match(/\d/g);
|
|
1545
|
+
if (parseInt(a[a.length - 1]) > 4) {
|
|
1546
|
+
for (var i = a.length - 2; i >= 0; i--) {
|
|
1547
|
+
a[i] = parseInt(a[i]) + 1;
|
|
1548
|
+
if (a[i] == 10) {
|
|
1549
|
+
a[i] = 0;
|
|
1550
|
+
b = i != 1;
|
|
1551
|
+
} else break;
|
|
1552
|
+
}
|
|
1553
|
+
}
|
|
1554
|
+
s = a.join('').replace(new RegExp('(\\d+)(\\d{' + d + '})\\d$'), '$1.$2');
|
|
1555
|
+
}
|
|
1556
|
+
if (b) s = s.substr(1);
|
|
1557
|
+
return (pm + s).replace(/\.$/, '');
|
|
1558
|
+
}
|
|
1559
|
+
return this + '';
|
|
1560
|
+
};
|
|
1530
1561
|
/* harmony default export */ __webpack_exports__["a"] = (utils);
|
|
1531
1562
|
|
|
1532
1563
|
/***/ }),
|
|
@@ -8816,17 +8847,6 @@ var component = Object(componentNormalizer["a" /* default */])(
|
|
|
8816
8847
|
|
|
8817
8848
|
/* harmony default export */ var main = __webpack_exports__["default"] = (component.exports);
|
|
8818
8849
|
|
|
8819
|
-
/***/ }),
|
|
8820
|
-
|
|
8821
|
-
/***/ "2257":
|
|
8822
|
-
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
8823
|
-
|
|
8824
|
-
"use strict";
|
|
8825
|
-
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_sass_loader_dist_cjs_js_ref_8_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_Table_vue_vue_type_style_index_0_id_5c781f91_prod_lang_scss_scoped_true__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("3431");
|
|
8826
|
-
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_sass_loader_dist_cjs_js_ref_8_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_Table_vue_vue_type_style_index_0_id_5c781f91_prod_lang_scss_scoped_true__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_mini_css_extract_plugin_dist_loader_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_sass_loader_dist_cjs_js_ref_8_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_Table_vue_vue_type_style_index_0_id_5c781f91_prod_lang_scss_scoped_true__WEBPACK_IMPORTED_MODULE_0__);
|
|
8827
|
-
/* unused harmony reexport * */
|
|
8828
|
-
|
|
8829
|
-
|
|
8830
8850
|
/***/ }),
|
|
8831
8851
|
|
|
8832
8852
|
/***/ "22ea":
|
|
@@ -11629,13 +11649,6 @@ var component = Object(componentNormalizer["a" /* default */])(
|
|
|
11629
11649
|
/* unused harmony reexport * */
|
|
11630
11650
|
|
|
11631
11651
|
|
|
11632
|
-
/***/ }),
|
|
11633
|
-
|
|
11634
|
-
/***/ "3431":
|
|
11635
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
11636
|
-
|
|
11637
|
-
// extracted by mini-css-extract-plugin
|
|
11638
|
-
|
|
11639
11652
|
/***/ }),
|
|
11640
11653
|
|
|
11641
11654
|
/***/ "3465":
|
|
@@ -12547,9 +12560,12 @@ var SubPagination = __webpack_require__("1639");
|
|
|
12547
12560
|
|
|
12548
12561
|
// CONCATENATED MODULE: ./src/mixins/onlineSubtable.js
|
|
12549
12562
|
|
|
12563
|
+
|
|
12550
12564
|
/* harmony default export */ var onlineSubtable = ({
|
|
12551
12565
|
data() {
|
|
12552
12566
|
return {
|
|
12567
|
+
searchVal: '',
|
|
12568
|
+
//搜索关键字
|
|
12553
12569
|
fillOrg: {},
|
|
12554
12570
|
fillOrgConfMap: {},
|
|
12555
12571
|
transitionIndex: -1,
|
|
@@ -12599,6 +12615,200 @@ var SubPagination = __webpack_require__("1639");
|
|
|
12599
12615
|
}
|
|
12600
12616
|
},
|
|
12601
12617
|
methods: {
|
|
12618
|
+
//合计计算
|
|
12619
|
+
getSummaries(param, list) {
|
|
12620
|
+
let CancelTheCalculation = sessionStorage.getItem('Cancel_The_Calculation') ? JSON.parse(sessionStorage.getItem('Cancel_The_Calculation')) : {};
|
|
12621
|
+
//
|
|
12622
|
+
let listChange = JSON.parse(Base64.decode(list, 'utf-8'));
|
|
12623
|
+
|
|
12624
|
+
//
|
|
12625
|
+
|
|
12626
|
+
if (listChange.length < 1) {
|
|
12627
|
+
return;
|
|
12628
|
+
}
|
|
12629
|
+
const {
|
|
12630
|
+
columns,
|
|
12631
|
+
data
|
|
12632
|
+
} = param;
|
|
12633
|
+
this.tableData = data;
|
|
12634
|
+
const sums = [];
|
|
12635
|
+
let calcProp = [];
|
|
12636
|
+
let columnsDep = _.cloneDeep(columns);
|
|
12637
|
+
listChange.forEach((item, idex) => {
|
|
12638
|
+
if (item.addFunc == 'calcFunc') {
|
|
12639
|
+
columnsDep.forEach((column, index) => {
|
|
12640
|
+
if (item.mathExp && item.mathExp.indexOf('.' + column.property) > -1) {
|
|
12641
|
+
calcProp.push(column.property);
|
|
12642
|
+
}
|
|
12643
|
+
});
|
|
12644
|
+
}
|
|
12645
|
+
columnsDep.forEach((column, index) => {
|
|
12646
|
+
if (item.columnField == column.property) {
|
|
12647
|
+
column.combinedOption = item;
|
|
12648
|
+
}
|
|
12649
|
+
});
|
|
12650
|
+
});
|
|
12651
|
+
columnsDep.forEach((column, index) => {
|
|
12652
|
+
if (index === 0 && columnsDep[0].type == 'index') {
|
|
12653
|
+
sums[index] = '';
|
|
12654
|
+
return;
|
|
12655
|
+
}
|
|
12656
|
+
//当有需要才合计
|
|
12657
|
+
if (column.combinedOption) {
|
|
12658
|
+
let {
|
|
12659
|
+
addFunc,
|
|
12660
|
+
columnField,
|
|
12661
|
+
name,
|
|
12662
|
+
unit,
|
|
12663
|
+
showType,
|
|
12664
|
+
num,
|
|
12665
|
+
tag,
|
|
12666
|
+
mainTarget
|
|
12667
|
+
} = column.combinedOption;
|
|
12668
|
+
let Bol = tag && CancelTheCalculation && CancelTheCalculation[tag] && CancelTheCalculation[tag].length > 0;
|
|
12669
|
+
const values = data.map(item => Number(item[column.property]));
|
|
12670
|
+
let depValues = _.cloneDeep(values);
|
|
12671
|
+
if (Bol) {
|
|
12672
|
+
let delMin = [];
|
|
12673
|
+
depValues.forEach((item, i) => {
|
|
12674
|
+
if (!CancelTheCalculation[tag].includes(i)) {
|
|
12675
|
+
delMin.push(item);
|
|
12676
|
+
}
|
|
12677
|
+
});
|
|
12678
|
+
depValues = delMin;
|
|
12679
|
+
}
|
|
12680
|
+
let units = unit ? unit : '';
|
|
12681
|
+
//求和
|
|
12682
|
+
if (addFunc === 'add') {
|
|
12683
|
+
if (!depValues.every(value => isNaN(value))) {
|
|
12684
|
+
sums[index] = depValues.reduce((prev, curr) => {
|
|
12685
|
+
const value = Number(curr);
|
|
12686
|
+
if (!isNaN(value)) {
|
|
12687
|
+
return prev + curr;
|
|
12688
|
+
} else {
|
|
12689
|
+
return prev;
|
|
12690
|
+
}
|
|
12691
|
+
}, 0);
|
|
12692
|
+
sums[index] = this.dealWithDataHtml(name, sums[index], showType, num, units, mainTarget);
|
|
12693
|
+
} else {
|
|
12694
|
+
sums[index] = this.dealWithDataHtml(name, 0, showType, num, units, mainTarget);
|
|
12695
|
+
}
|
|
12696
|
+
}
|
|
12697
|
+
//计数
|
|
12698
|
+
if (addFunc === 'count') {
|
|
12699
|
+
let numCount = values.length;
|
|
12700
|
+
if (Bol) {
|
|
12701
|
+
numCount = values.length - CancelTheCalculation[tag].length;
|
|
12702
|
+
}
|
|
12703
|
+
sums[index] = this.dealWithDataHtml(name, numCount, showType, num, units, mainTarget);
|
|
12704
|
+
}
|
|
12705
|
+
//平均值
|
|
12706
|
+
if (addFunc === 'average') {
|
|
12707
|
+
let sum = 0;
|
|
12708
|
+
var average = 0;
|
|
12709
|
+
for (var i = 0; i < depValues.length; i++) {
|
|
12710
|
+
sum += depValues[i];
|
|
12711
|
+
}
|
|
12712
|
+
depValues.length > 0 ? average = sum / depValues.length : average = 0;
|
|
12713
|
+
sums[index] = this.dealWithDataHtml(name, average, showType, num, units, mainTarget);
|
|
12714
|
+
}
|
|
12715
|
+
//最大值
|
|
12716
|
+
if (addFunc === 'max') {
|
|
12717
|
+
let maxNum = Math.max.apply(null, depValues.length > 0 ? depValues : [0]);
|
|
12718
|
+
sums[index] = this.dealWithDataHtml(name, maxNum, showType, num, units, mainTarget);
|
|
12719
|
+
}
|
|
12720
|
+
//最小值
|
|
12721
|
+
if (addFunc === 'min') {
|
|
12722
|
+
let minNum = Math.min.apply(null, depValues.length > 0 ? depValues : [0]);
|
|
12723
|
+
sums[index] = this.dealWithDataHtml(name, minNum, showType, num, units, mainTarget);
|
|
12724
|
+
}
|
|
12725
|
+
|
|
12726
|
+
//公式计算
|
|
12727
|
+
if (addFunc === 'calcFunc') {
|
|
12728
|
+
const calcVal = this.dealCustomCalc(data, column.combinedOption);
|
|
12729
|
+
sums[index] = this.dealWithDataHtml(name, calcVal, showType, num, units, mainTarget);
|
|
12730
|
+
}
|
|
12731
|
+
} else if (calcProp.indexOf(column.property) > -1) {
|
|
12732
|
+
const values = data.map(item => Number(item[column.property]));
|
|
12733
|
+
}
|
|
12734
|
+
});
|
|
12735
|
+
return sums;
|
|
12736
|
+
},
|
|
12737
|
+
//合计行
|
|
12738
|
+
handleSummary(summary) {
|
|
12739
|
+
return summary && !this.searchVal ? true : false;
|
|
12740
|
+
},
|
|
12741
|
+
dealWithDataHtml(name, type, showType, num, units, mainTarget) {
|
|
12742
|
+
let {
|
|
12743
|
+
data,
|
|
12744
|
+
monCap
|
|
12745
|
+
} = this.dealWithData(type, showType, num, mainTarget);
|
|
12746
|
+
if (monCap) {
|
|
12747
|
+
return name + ':' + data + units + '\n' + monCap;
|
|
12748
|
+
}
|
|
12749
|
+
return name + ':' + data + units;
|
|
12750
|
+
},
|
|
12751
|
+
//处理数据
|
|
12752
|
+
dealWithData(data, showType, numfix = 0, mainTarget) {
|
|
12753
|
+
data = Number(data);
|
|
12754
|
+
let list = showType;
|
|
12755
|
+
let num = {
|
|
12756
|
+
data: 0,
|
|
12757
|
+
monCap: ''
|
|
12758
|
+
};
|
|
12759
|
+
// 保留小数位
|
|
12760
|
+
if (list.includes('keepSmall')) {
|
|
12761
|
+
const fixData = data.toFixedRound(numfix);
|
|
12762
|
+
num.data = fixData;
|
|
12763
|
+
if (mainTarget) {
|
|
12764
|
+
mainTarget = !mainTarget.startsWith('data.') ? 'data.' + mainTarget : mainTarget;
|
|
12765
|
+
utils["a" /* default */].setValueByConfigKey(this, {
|
|
12766
|
+
trget: mainTarget
|
|
12767
|
+
}, 'trget', data);
|
|
12768
|
+
}
|
|
12769
|
+
} else {
|
|
12770
|
+
if (mainTarget && data != null) {
|
|
12771
|
+
mainTarget = !mainTarget.startsWith('data.') ? 'data.' + mainTarget : mainTarget;
|
|
12772
|
+
utils["a" /* default */].setValueByConfigKey(this, {
|
|
12773
|
+
trget: mainTarget
|
|
12774
|
+
}, 'trget', data.toFixedRound(4));
|
|
12775
|
+
}
|
|
12776
|
+
}
|
|
12777
|
+
|
|
12778
|
+
//百分比
|
|
12779
|
+
if (list.includes('percentage')) {
|
|
12780
|
+
num.data = Number(data * 100) + '%';
|
|
12781
|
+
}
|
|
12782
|
+
// 千分位
|
|
12783
|
+
if (list.includes('Micrometer')) {
|
|
12784
|
+
num.data = utils["a" /* default */].thousandBit(data);
|
|
12785
|
+
}
|
|
12786
|
+
if (list.includes('keepSmall') && list.includes('percentage') && list.includes('Micrometer')) {
|
|
12787
|
+
num.data = utils["a" /* default */].thousandBit(Number(data * 100).toFixedRound(numfix)) + '%';
|
|
12788
|
+
return num;
|
|
12789
|
+
}
|
|
12790
|
+
if (list.includes('keepSmall') && list.includes('percentage')) {
|
|
12791
|
+
num.data = Number(data * 100).toFixedRound(numfix) + '%';
|
|
12792
|
+
return num;
|
|
12793
|
+
}
|
|
12794
|
+
if (list.includes('Micrometer') && list.includes('percentage')) {
|
|
12795
|
+
num.data = utils["a" /* default */].thousandBit(Number(data * 100)) + '%';
|
|
12796
|
+
return num;
|
|
12797
|
+
}
|
|
12798
|
+
if (list.includes('keepSmall') && list.includes('Micrometer')) {
|
|
12799
|
+
num.data = utils["a" /* default */].thousandBit(data.toFixedRound(numfix));
|
|
12800
|
+
}
|
|
12801
|
+
|
|
12802
|
+
// 货币大写
|
|
12803
|
+
if (list.includes('monCap')) {
|
|
12804
|
+
num = {
|
|
12805
|
+
data: data,
|
|
12806
|
+
monCap: utils["a" /* default */].convertCurrency(data)
|
|
12807
|
+
};
|
|
12808
|
+
return num;
|
|
12809
|
+
}
|
|
12810
|
+
return num;
|
|
12811
|
+
},
|
|
12602
12812
|
getExpandArr(data, type) {
|
|
12603
12813
|
if (type === 'expand' && data) {
|
|
12604
12814
|
let arr = [];
|
|
@@ -15141,12 +15351,12 @@ var component = Object(componentNormalizer["a" /* default */])(
|
|
|
15141
15351
|
// ESM COMPAT FLAG
|
|
15142
15352
|
__webpack_require__.r(__webpack_exports__);
|
|
15143
15353
|
|
|
15144
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"2283df13-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/Table/src/Table.vue?vue&type=template&id=
|
|
15354
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"2283df13-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/Table/src/Table.vue?vue&type=template&id=c26fbdf8&scoped=true
|
|
15145
15355
|
var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('el-main',{ref:"tablePanel",staticClass:"ht-table-panel"},[(!_vm.noHeader && !_vm.justShowSearch)?_c('div',{ref:"toolbarPanel",staticClass:"toolbar-panel"},[(!_vm.justShowSearch)?_c('div',{staticClass:"toolbar-panel__search",class:{ 'ht-quick__search': !_vm.hideTableSearch }},[(_vm.quickSearchConfig && _vm.quickSearchConfig.length > 0)?_c('ht-input',{ref:"quickSearch",staticClass:"quick-search",staticStyle:{"margin-right":"20px"},style:(_vm.quickSearchWidthStyle),attrs:{"placeholder":_vm.quickSearchPlaceholder,"autofocus":true,"disabled":_vm.loading || _vm.showAdvancedSearch,"debounce":2000,"suffix-icon":"el-icon-search"},nativeOn:{"keydown":function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"enter",13,$event.key,"Enter")){ return null; }return _vm.doQuickSearch($event)},"click":function($event){return _vm.clickQuickSearch($event)}},model:{value:(_vm.quickSearchWord),callback:function ($$v) {_vm.quickSearchWord=$$v},expression:"quickSearchWord"}}):_vm._e(),_c('div',{staticClass:"common-tools"},[(_vm.hasSearchPanel && !_vm.justShowSearch)?_c('el-button',{staticClass:"advance-search__button",on:{"click":function($event){_vm.showAdvancedSearch = !_vm.showAdvancedSearch}}},[_vm._v("\n "+_vm._s(_vm.showAdvancedSearch ? '基础搜索' : '高级搜索')+"\n "),_c('i',{class:_vm.showAdvancedSearch ? 'el-icon-arrow-up' : 'el-icon-arrow-down'})]):_vm._e(),(_vm.showExport)?_c('el-tooltip',{attrs:{"content":"导出数据","placement":"top"}},[_c('el-button',{on:{"click":function($event){return _vm.$emit('export')}}},[_c('ht-icon',{attrs:{"name":"arrow"}})],1)],1):_vm._e(),(_vm.showRefresh)?_c('el-tooltip',{attrs:{"content":"刷新数据","placement":"top"}},[_c('el-button',{staticClass:"refresh-btn-icon",attrs:{"icon":"el-icon-refresh"},on:{"click":function($event){return _vm.load(true)}}})],1):_vm._e(),(_vm.showCustomColumn && !_vm.isCardView)?_c('el-tooltip',{attrs:{"content":"自定义列","placement":"top"}},[_c('el-button',{on:{"click":function($event){_vm.customColumnDialogVisible = true}}},[_c('ht-icon',{attrs:{"name":"setting"}})],1)],1):_vm._e(),(_vm.multiViewSwitch)?_c('el-button-group',{staticClass:"multiview-switcher"},[_c('el-tooltip',{attrs:{"content":"卡片视图","placement":"top"}},[_c('el-button',{attrs:{"type":_vm.isCardView ? 'primary' : 'default'},on:{"click":function($event){_vm.isCardView = true}}},[_c('ht-icon',{attrs:{"name":"block"}})],1)],1),_c('el-tooltip',{attrs:{"content":"表格视图","placement":"top"}},[_c('el-button',{attrs:{"type":_vm.isCardView ? 'default' : 'primary'},on:{"click":function($event){_vm.isCardView = false}}},[_c('ht-icon',{attrs:{"name":"line"}})],1)],1)],1):_vm._e()],1)],1):_vm._e()]):_vm._e(),_c('el-collapse-transition',[_c('div',{directives:[{name:"show",rawName:"v-show",value:(_vm.showAdvancedSearch || _vm.justShowSearch),expression:"showAdvancedSearch || justShowSearch"}],ref:"searchPanel",staticClass:"search-panel"},[_vm._t("search")],2)]),(_vm.hasToolBar)?_c('div',{ref:"toolbarContainer",staticClass:"toolbar-container"},[_vm._t("toolbar")],2):_vm._e(),(!_vm.isCardView)?_c('el-table',{directives:[{name:"loading",rawName:"v-loading",value:(_vm.isLoading),expression:"isLoading"}],ref:"htTable",staticClass:"ht-table",class:{ 'no-data-table': _vm.data.length < 1 },attrs:{"stripe":_vm.stripe,"border":"","data":_vm.data,"size":_vm.size,"empty-text":_vm.emptyText,"show-header":_vm.showHeader,"max-height":_vm.tableMaxHeight ? _vm.tableMaxHeight : 400,"tooltip-effect":_vm.tooltipEffect,"default-querys":_vm.defaultQuerys,"header-row-class-name":_vm.headerRowClassName,"header-cell-class-name":_vm.headerCellClassName,"highlight-current-row":_vm.highlightCurrentRow,"row-class-name":_vm.rowClassName,"cell-class-name":_vm.cellClassName,"height":("" + (_vm.tableMaxHeight ? _vm.tableMaxHeight : 400)),"row-key":_vm.rowKey,"show-summary":_vm.showSummary,"summary-method":_vm.getSummaries},on:{"row-click":_vm.handleRowClick,"select":_vm.handleTableSelect,"select-all":_vm.handleTableSelect,"sort-change":_vm.handleSortChange,"filter-change":_vm.handleFilterChange,"selection-change":function (selection) { return _vm.$emit('selection-change', selection); }}},[(_vm.selectable)?_c('el-table-column',{attrs:{"type":"selection","align":"center","reserve-selection":_vm.reserveSelection,"width":"45"}}):_vm._e(),_vm._t("default"),_c('template',{slot:"empty"},[_c('el-image',{attrs:{"src":_vm.tableNoDataImg}}),_c('p',{staticClass:"no-data-text"},[_vm._v(_vm._s(_vm.emptyText || _vm.t('el.table.emptyText')))])],1)],2):_c('div',{directives:[{name:"loading",rawName:"v-loading",value:(_vm.isLoading),expression:"isLoading"}],staticClass:"ht-card",style:({ height: "" + _vm.tableMaxHeight + 'px' })},[(_vm.loading || (_vm.data && _vm.data.length > 0))?[(_vm.cardItemMode)?_c('div',{staticClass:"ht-card__container"},_vm._l((_vm.data),function(item,index){return _c('el-card',{key:index,attrs:{"shadow":"hover"},nativeOn:{"click":function($event){return _vm.$emit('card-click', item)}}},[_vm._t("card",null,{"item":item})],2)}),1):_c('div',[_vm._t("card",null,{"data":_vm.data})],2)]:_c('div',{staticClass:"el-table__empty-block"},[(_vm.data.length < 1 && !_vm.emptyText)?[_vm._t("empty-card")]:(_vm.emptyText)?_c('span',{staticClass:"el-table__empty-text"},[_vm._v("\n "+_vm._s(_vm.emptyText || _vm.t('el.table.emptyText'))+"\n ")]):_vm._e()],2)],2),(!_vm.nopagination)?_c('div',{ref:"paginationPanel",staticClass:"pagination-panel"},[_c('el-row',{attrs:{"type":"flex","justify":_vm.tablePaginationJustify}},[_c('el-pagination',{class:{ 'page-sizes__hidden': _vm.hidePageSizes },attrs:{"small":_vm.small,"disabled":_vm.loading,"current-page":_vm.pagination.page,"page-sizes":_vm.pageSizes,"page-size":_vm.pagination.pageSize,"pager-count":_vm.pagerCount,"background":_vm.$paginationBackground,"layout":_vm.layout,"total":_vm.pagination.total},on:{"size-change":_vm.handleSizeChange,"current-change":_vm.handleCurrentChange}})],1)],1):_vm._e(),_c('custom-column',{attrs:{"custom-columns":_vm.customColumns,"visible":_vm.customColumnDialogVisible},on:{"update:visible":function($event){_vm.customColumnDialogVisible=$event},"apply-custom-column":_vm.handleApplyCustomColumn}})],1)}
|
|
15146
15356
|
var staticRenderFns = []
|
|
15147
15357
|
|
|
15148
15358
|
|
|
15149
|
-
// CONCATENATED MODULE: ./packages/Table/src/Table.vue?vue&type=template&id=
|
|
15359
|
+
// CONCATENATED MODULE: ./packages/Table/src/Table.vue?vue&type=template&id=c26fbdf8&scoped=true
|
|
15150
15360
|
|
|
15151
15361
|
// EXTERNAL MODULE: ./src/mixins/locale.js
|
|
15152
15362
|
var locale = __webpack_require__("b255");
|
|
@@ -16085,6 +16295,10 @@ const METHOD_MAP = {
|
|
|
16085
16295
|
oldTableField,
|
|
16086
16296
|
fieldDesc
|
|
16087
16297
|
} = tableFieldItem;
|
|
16298
|
+
if (!summaryMethod) {
|
|
16299
|
+
sums[index] = '';
|
|
16300
|
+
return;
|
|
16301
|
+
}
|
|
16088
16302
|
let field = '';
|
|
16089
16303
|
if (oldTableField) {
|
|
16090
16304
|
// 数据列表
|
|
@@ -16150,8 +16364,8 @@ const METHOD_MAP = {
|
|
|
16150
16364
|
});
|
|
16151
16365
|
// CONCATENATED MODULE: ./packages/Table/src/Table.vue?vue&type=script&lang=js
|
|
16152
16366
|
/* harmony default export */ var src_Tablevue_type_script_lang_js = (Tablevue_type_script_lang_js);
|
|
16153
|
-
// EXTERNAL MODULE: ./packages/Table/src/Table.vue?vue&type=style&index=0&id=
|
|
16154
|
-
var
|
|
16367
|
+
// EXTERNAL MODULE: ./packages/Table/src/Table.vue?vue&type=style&index=0&id=c26fbdf8&prod&lang=scss&scoped=true
|
|
16368
|
+
var Tablevue_type_style_index_0_id_c26fbdf8_prod_lang_scss_scoped_true = __webpack_require__("5820");
|
|
16155
16369
|
|
|
16156
16370
|
// EXTERNAL MODULE: ./node_modules/vue-loader/lib/runtime/componentNormalizer.js
|
|
16157
16371
|
var componentNormalizer = __webpack_require__("2877");
|
|
@@ -16171,7 +16385,7 @@ var component = Object(componentNormalizer["a" /* default */])(
|
|
|
16171
16385
|
staticRenderFns,
|
|
16172
16386
|
false,
|
|
16173
16387
|
null,
|
|
16174
|
-
"
|
|
16388
|
+
"c26fbdf8",
|
|
16175
16389
|
null
|
|
16176
16390
|
|
|
16177
16391
|
)
|
|
@@ -19688,6 +19902,17 @@ _src_main_vue__WEBPACK_IMPORTED_MODULE_0__["default"].install = function (Vue) {
|
|
|
19688
19902
|
/* unused harmony reexport * */
|
|
19689
19903
|
|
|
19690
19904
|
|
|
19905
|
+
/***/ }),
|
|
19906
|
+
|
|
19907
|
+
/***/ "5820":
|
|
19908
|
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
19909
|
+
|
|
19910
|
+
"use strict";
|
|
19911
|
+
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_sass_loader_dist_cjs_js_ref_8_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_Table_vue_vue_type_style_index_0_id_c26fbdf8_prod_lang_scss_scoped_true__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("a9a8");
|
|
19912
|
+
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_sass_loader_dist_cjs_js_ref_8_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_Table_vue_vue_type_style_index_0_id_c26fbdf8_prod_lang_scss_scoped_true__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_mini_css_extract_plugin_dist_loader_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_sass_loader_dist_cjs_js_ref_8_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_Table_vue_vue_type_style_index_0_id_c26fbdf8_prod_lang_scss_scoped_true__WEBPACK_IMPORTED_MODULE_0__);
|
|
19913
|
+
/* unused harmony reexport * */
|
|
19914
|
+
|
|
19915
|
+
|
|
19691
19916
|
/***/ }),
|
|
19692
19917
|
|
|
19693
19918
|
/***/ "5877":
|
|
@@ -33464,7 +33689,7 @@ _main_vue__WEBPACK_IMPORTED_MODULE_0__["default"].register({
|
|
|
33464
33689
|
/***/ "9224":
|
|
33465
33690
|
/***/ (function(module) {
|
|
33466
33691
|
|
|
33467
|
-
module.exports = JSON.parse("{\"a\":\"1.0.
|
|
33692
|
+
module.exports = JSON.parse("{\"a\":\"1.0.59\"}");
|
|
33468
33693
|
|
|
33469
33694
|
/***/ }),
|
|
33470
33695
|
|
|
@@ -37194,6 +37419,13 @@ _src_main_vue__WEBPACK_IMPORTED_MODULE_0__["default"].install = function (Vue) {
|
|
|
37194
37419
|
/* unused harmony reexport * */
|
|
37195
37420
|
|
|
37196
37421
|
|
|
37422
|
+
/***/ }),
|
|
37423
|
+
|
|
37424
|
+
/***/ "a9a8":
|
|
37425
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
37426
|
+
|
|
37427
|
+
// extracted by mini-css-extract-plugin
|
|
37428
|
+
|
|
37197
37429
|
/***/ }),
|
|
37198
37430
|
|
|
37199
37431
|
/***/ "aa99":
|
|
@@ -54690,7 +54922,8 @@ const req = function (url, data = {}, option = {}) {
|
|
|
54690
54922
|
this.printDetail(parameter.templateId, parameter.id, parameter.action);
|
|
54691
54923
|
} else if (btnAlias == 'sub' && this.checkSelect()) {
|
|
54692
54924
|
this.showSubList(this.tableData.selectRows[0].id_, parameter);
|
|
54693
|
-
} else if (btnAlias == 'js'
|
|
54925
|
+
} else if (btnAlias == 'js') {
|
|
54926
|
+
if (parameter.needValidateSelect && !this.checkSelect()) return;
|
|
54694
54927
|
this.customEvilJS(this.tableData.selectRows[0], parameter.jsValue);
|
|
54695
54928
|
} else if (btnAlias == 'startFlow' && parameter.defId && !parameter.isStartFlow) {
|
|
54696
54929
|
this.operating(parameter.templateId, parameter.id, parameter.action, parameter.defId, parameter.isStartFlow, parameter.openType, parameter.quitAfterSaving);
|