@bytenew/bn-bus-ui 1.1.461 → 1.1.463
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/install.js +134 -0
- package/package.json +20 -4
- package/packages/BnAddress/index.vue +141 -0
- package/packages/BnAddressParse/index.vue +75 -0
- package/packages/BnAdvancedFilter/BnFilterView.vue +145 -0
- package/packages/BnAdvancedFilter/index.vue +345 -0
- package/packages/BnAdvancedFilter/util.js +171 -0
- package/packages/BnCascader/BnCascader.vue +543 -0
- package/packages/BnCascader/BnCascaderPanel.vue +1331 -0
- package/packages/BnCascader/cascaderDisplay.js +102 -0
- package/packages/BnCheck/BnCheck.vue +253 -0
- package/packages/BnColumnConfig/columnConfigDialog.vue +134 -0
- package/packages/BnColumnConfig/component/childrenFormSetting/assocTable.vue +143 -0
- package/packages/BnColumnConfig/component/childrenFormSetting/assocTableSearch.vue +314 -0
- package/packages/BnColumnConfig/component/childrenFormSetting/index.vue +243 -0
- package/packages/BnColumnConfig/component/defaultSet/defaultSet.vue +114 -0
- package/packages/BnColumnConfig/component/defaultSet/stringDefault.vue +210 -0
- package/packages/BnColumnConfig/component/funcExprDialog/funcExprDialog.vue +126 -0
- package/packages/BnColumnConfig/component/packageFilter/index.vue +141 -0
- package/packages/BnColumnConfig/component/paraExplainSet/index.vue +156 -0
- package/packages/BnColumnConfig/component/setOption/setOption.vue +321 -0
- package/packages/BnColumnConfig/component/setRelationOption/ConditionList.vue +277 -0
- package/packages/BnColumnConfig/component/setRelationOption/LevelHeader.vue +144 -0
- package/packages/BnColumnConfig/component/setRelationOption/setRelationOption.vue +642 -0
- package/packages/BnColumnConfig/data.js +129 -0
- package/packages/BnColumnConfig/index.scss +23 -0
- package/packages/BnColumnConfig/index.vue +309 -0
- package/packages/BnCondVal/BnCondVal.vue +112 -0
- package/packages/BnCondVal/itemVal/dateRegVal.vue +39 -0
- package/packages/BnCondVal/itemVal/dateVal.vue +39 -0
- package/packages/BnCondVal/itemVal/numRegVal.vue +67 -0
- package/packages/BnCondVal/itemVal/numVal.vue +44 -0
- package/packages/BnCondVal/itemVal/relationVal.vue +73 -0
- package/packages/BnCondVal/itemVal/selectColumnVal.vue +58 -0
- package/packages/BnCondVal/itemVal/selectVal.vue +59 -0
- package/packages/BnCondVal/itemVal/stringVal.vue +156 -0
- package/packages/BnCondition/index.vue +551 -0
- package/packages/BnCondition/util.js +232 -0
- package/packages/BnDatePicker/BnDatePicker.vue +194 -0
- package/packages/BnDrop/BnDrop.vue +917 -0
- package/packages/BnEmptyTip/BnEmptyTip.vue +107 -0
- package/packages/BnExportOrder/BnExportOrder.vue +241 -0
- package/packages/BnExportOrder/validatorCode.vue +94 -0
- package/packages/BnFileView/BnFileView.vue +271 -0
- package/packages/BnFileView/FileDetail.vue +125 -0
- package/packages/BnFileView/videoPreview.vue +70 -0
- package/packages/BnFilterOption/BnFilterOption.vue +160 -0
- package/packages/BnFunExpr/BnFunExpr.vue +608 -0
- package/packages/BnImportOrder/BnImportOrder.vue +323 -0
- package/packages/BnImportTemplate/BnImportTemplate.vue +866 -0
- package/packages/BnImportTemplate/assets/merge_tip_img.png +0 -0
- package/packages/BnImportTemplate/assets/sheet_tip.png +0 -0
- package/packages/BnImportTemplate/assets/xls.png +0 -0
- package/packages/BnImportTemplate/components/ImportTemplateTrigger.vue +198 -0
- package/packages/BnImportTemplate/components/TemplateEditDialog.vue +340 -0
- package/packages/BnImportTemplate/components/TemplateFieldsConfig.vue +401 -0
- package/packages/BnImportTemplate/components/TemplateListDialog.vue +297 -0
- package/packages/BnInpNum/BnInpNum.vue +165 -0
- package/packages/BnMenus/BnMenus.vue +502 -0
- package/packages/BnMenus/MenuItem.vue +321 -0
- package/packages/BnOrderCard/BnOrderCard.vue +389 -0
- package/packages/BnOrderCard/orderRemark.vue +178 -0
- package/packages/BnOrderCard/util.js +94 -0
- package/packages/BnOrderDetail/BnOrderDetail.vue +338 -0
- package/packages/BnOrderDetail/filterLogByUser.vue +108 -0
- package/packages/BnOrderDetail/orderLogs.vue +53 -0
- package/packages/BnOrderDetail/showSubForm/index.vue +41 -0
- package/packages/BnOrderDetail/showSubForm/showChildTable.vue +61 -0
- package/packages/BnOrderDetail/showSubForm/showTimeLine.vue +131 -0
- package/packages/BnOrderDetail/showSubForm/tableCellCopy.vue +84 -0
- package/packages/BnOrderShare/index.vue +378 -0
- package/packages/BnOrderShare/shareUrlInp.vue +54 -0
- package/packages/BnRadio/BnRadio.vue +181 -0
- package/packages/BnRelation/BnRelation.vue +120 -0
- package/packages/BnSelect/BnSelect.vue +485 -0
- package/packages/BnSmartForm/BnBatchForm.vue +334 -0
- package/packages/BnSmartForm/BnBatchFormDialog.vue +423 -0
- package/packages/BnSmartForm/BnSmartElf/elfLog/index.vue +57 -0
- package/packages/BnSmartForm/BnSmartElf/index.vue +95 -0
- package/packages/BnSmartForm/BnSmartFormPsychic.js +629 -0
- package/packages/BnSmartForm/BnSmartFormUtil.js +524 -0
- package/packages/BnSmartForm/addressForm/index.vue +73 -0
- package/packages/BnSmartForm/checkboxForm/index.vue +99 -0
- package/packages/BnSmartForm/childrenForm/childFormFile.vue +237 -0
- package/packages/BnSmartForm/childrenForm/childrenFormBody.vue +260 -0
- package/packages/BnSmartForm/childrenForm/index.vue +110 -0
- package/packages/BnSmartForm/childrenForm/searchInventory.vue +115 -0
- package/packages/BnSmartForm/chooseAssocTable/chooseAssocTable.vue +451 -0
- package/packages/BnSmartForm/chooseAssocTable/chooseChildGood.vue +229 -0
- package/packages/BnSmartForm/chooseAssocTable/tableCellCopy.vue +84 -0
- package/packages/BnSmartForm/chooseChildOrder/chooseChildOrder.vue +158 -0
- package/packages/BnSmartForm/chooseIPaasData/chooseIPaasData.vue +307 -0
- package/packages/BnSmartForm/chooseIPaasData/tableCellCopy.vue +84 -0
- package/packages/BnSmartForm/choosePackage/choosePackage.vue +361 -0
- package/packages/BnSmartForm/dateDualForm/index.vue +37 -0
- package/packages/BnSmartForm/dateForm/index.vue +38 -0
- package/packages/BnSmartForm/fileForm/fileFormData.js +50 -0
- package/packages/BnSmartForm/fileForm/index.vue +240 -0
- package/packages/BnSmartForm/formItemFooter/formItemFooter.vue +38 -0
- package/packages/BnSmartForm/formItemTop/formItemTop.vue +42 -0
- package/packages/BnSmartForm/index.vue +1201 -0
- package/packages/BnSmartForm/numberForm/index.vue +63 -0
- package/packages/BnSmartForm/radioForm/index.vue +72 -0
- package/packages/BnSmartForm/receiveForm/index.vue +112 -0
- package/packages/BnSmartForm/relationForm/index.vue +82 -0
- package/packages/BnSmartForm/scoreForm/index.vue +39 -0
- package/packages/BnSmartForm/selectForm/index.vue +55 -0
- package/packages/BnSmartForm/showValForm/index.vue +42 -0
- package/packages/BnSmartForm/showValForm/showValFormTable.vue +104 -0
- package/packages/BnSmartForm/smartFormsCommon.scss +43 -0
- package/packages/BnSmartForm/stringForm/index.vue +170 -0
- package/packages/BnVirtPopover/index.vue +319 -0
- package/packages/BnWebLog/BnWebLog.vue +140 -0
- package/packages/BnWorkSettingDrop/advancedOptions.js +112 -0
- package/packages/BnWorkSettingDrop/benBenAIUtil.js +89 -0
- package/packages/BnWorkSettingDrop/index.vue +292 -0
- package/packages/font/iconfont.css +243 -0
- package/packages/font/iconfont.ttf +0 -0
- package/packages/font/iconfont.woff +0 -0
- package/packages/font/iconfont.woff2 +0 -0
- package/utils/addressParse-old.js +645 -0
- package/utils/addressParse.js +735 -0
- package/utils/config.js +68 -0
- package/utils/index.js +1171 -0
- package/dist/assocTableSearch-C14i_zJO.js +0 -349
- package/dist/assocTableSearch.css +0 -1
- package/dist/bn-bus-ui.es.js +0 -65
- package/dist/bn-bus-ui.umd.js +0 -49
- package/dist/chooseIPaasData-Cl_5qkFA.js +0 -391
- package/dist/chooseIPaasData.css +0 -1
- package/dist/defaultSet-I4xpf8a4.js +0 -297
- package/dist/defaultSet.css +0 -1
- package/dist/fileFormData-D_Q1vylE.js +0 -53
- package/dist/formItemFooter-CTA7rDtV.js +0 -108
- package/dist/formItemFooter.css +0 -1
- package/dist/funcExprDialog-Cm5BiRM3.js +0 -139
- package/dist/funcExprDialog.css +0 -1
- package/dist/index-B6b4uj8v.js +0 -51
- package/dist/index-BWdkDTbz.js +0 -109
- package/dist/index-BdZ1zOap.js +0 -89
- package/dist/index-BdzNjjMC.js +0 -64
- package/dist/index-BfpZqab2.js +0 -66
- package/dist/index-BmkiB4hr.js +0 -66
- package/dist/index-Br1sqCoo.js +0 -58
- package/dist/index-C9qrl-yc.js +0 -183
- package/dist/index-CXFJXCn5.js +0 -746
- package/dist/index-DF114jZq.js +0 -135
- package/dist/index-DFPfZ_Il.js +0 -178
- package/dist/index-DSEtu7TN.js +0 -44
- package/dist/index-Did0UUWV.js +0 -221
- package/dist/index-DrPj-tmI.js +0 -45
- package/dist/index-DzDf9s2W.js +0 -89
- package/dist/index-LnjudNEI.js +0 -118
- package/dist/index-ObCfCmDT.js +0 -45
- package/dist/index.css +0 -1
- package/dist/index2.css +0 -1
- package/dist/index3.css +0 -1
- package/dist/index4.css +0 -1
- package/dist/index5.css +0 -1
- package/dist/index6.css +0 -1
- package/dist/index7.css +0 -1
- package/dist/install-C-scqkds.js +0 -23103
- package/dist/install.css +0 -1
- package/dist/setOption-CSnWzOny.js +0 -329
- package/dist/setOption.css +0 -1
- package/dist/setRelationOption-CJcHdfaa.js +0 -5217
- package/dist/setRelationOption.css +0 -1
|
@@ -0,0 +1,178 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<el-dialog v-model="show" :title="`${postData.type=='create'?'新建':'修改'}订单备注`"
|
|
3
|
+
top="18px" width="680" destroy-on-close align-center>
|
|
4
|
+
<div class="orderRemark">
|
|
5
|
+
<el-form :model="postData" label-width="auto">
|
|
6
|
+
<el-form-item label="备注旗帜:" prop="name">
|
|
7
|
+
<el-radio-group v-model="postData.flag">
|
|
8
|
+
<el-radio v-for="(flag) in flagList[postData.sellerType || 1]"
|
|
9
|
+
:value="flag.key" >
|
|
10
|
+
<span class="bnUIcon bnUIcon-flag w-font16" :class="`flag-color-${flag.className}`"></span>
|
|
11
|
+
</el-radio>
|
|
12
|
+
</el-radio-group>
|
|
13
|
+
</el-form-item>
|
|
14
|
+
<el-form-item label="备注内容:" prop="desc">
|
|
15
|
+
<el-input v-model="postData.sellerMemo" type="textarea" :autosize="{minRows:6,maxRows:8}" resize="none" />
|
|
16
|
+
</el-form-item>
|
|
17
|
+
</el-form>
|
|
18
|
+
</div>
|
|
19
|
+
<template #footer>
|
|
20
|
+
<div class="w-flex-right w-flex-center">
|
|
21
|
+
<span class="w-font13 w-color-gray w-margin-right8">已输入
|
|
22
|
+
<span class="w-color-blue">{{ changeContent(postData.sellerMemo) }}</span>/1000</span>
|
|
23
|
+
<el-button @click="show = false">取消</el-button>
|
|
24
|
+
<el-button type="primary" @click="sure()" :loading="loading">确认</el-button>
|
|
25
|
+
</div>
|
|
26
|
+
</template>
|
|
27
|
+
</el-dialog>
|
|
28
|
+
</template>
|
|
29
|
+
<script>
|
|
30
|
+
import {cloneDeep} from "lodash";
|
|
31
|
+
import {flagList} from "./util.js";
|
|
32
|
+
|
|
33
|
+
export default {
|
|
34
|
+
name: 'orderRemark',
|
|
35
|
+
props: {
|
|
36
|
+
// 接口请求外部转发
|
|
37
|
+
postFunc: Function,
|
|
38
|
+
// 扩展参数
|
|
39
|
+
extendPost: Object,
|
|
40
|
+
},
|
|
41
|
+
data() {
|
|
42
|
+
return {
|
|
43
|
+
show: false,
|
|
44
|
+
flagList: flagList,
|
|
45
|
+
postData:{flag:'',sellerMemo:''},
|
|
46
|
+
loading: false,
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
methods: {
|
|
50
|
+
/**
|
|
51
|
+
* 打开选择弹框,处理数据回显
|
|
52
|
+
* */
|
|
53
|
+
open(postData) {
|
|
54
|
+
this.postData = cloneDeep(postData)
|
|
55
|
+
this.show = true;
|
|
56
|
+
},
|
|
57
|
+
/**
|
|
58
|
+
* 手动备注内容转字节提示
|
|
59
|
+
* */
|
|
60
|
+
changeContent(val) {
|
|
61
|
+
let length = val.replace(/[\u0391-\uFFE5]/g, "aa").length;
|
|
62
|
+
if (length > 1000) {
|
|
63
|
+
//根据字节截取字符串
|
|
64
|
+
this.postData.sellerMemo = this.cutStr(val, 1000)
|
|
65
|
+
}
|
|
66
|
+
return length;
|
|
67
|
+
},
|
|
68
|
+
/**
|
|
69
|
+
* 根据字节截取字符串
|
|
70
|
+
* @param {String} str 要截取的字符串
|
|
71
|
+
* @param {Number} L 要截取的字节长度,注意是字节不是字符,一个汉字两个字节
|
|
72
|
+
* @return {String} 截取后的字符串
|
|
73
|
+
*/
|
|
74
|
+
cutStr(str, L) {
|
|
75
|
+
let result = '',
|
|
76
|
+
strlen = str.length, // 字符串长度
|
|
77
|
+
chrlen = str.replace(/[\u0391-\uFFE5]/g, "aa").length; // 字节长度
|
|
78
|
+
if (chrlen <= L) {
|
|
79
|
+
return str;
|
|
80
|
+
}
|
|
81
|
+
for (let i = 0, j = 0; i < strlen; i++) {
|
|
82
|
+
let chr = str.charAt(i);
|
|
83
|
+
if (/[\x00-\xff]/.test(chr)) {
|
|
84
|
+
j++; // ascii码为0-255,一个字符就是一个字节的长度
|
|
85
|
+
} else {
|
|
86
|
+
j += 2; // ascii码为0-255以外,一个字符就是两个字节的长度
|
|
87
|
+
}
|
|
88
|
+
if (j <= L) { // 当加上当前字符以后,如果总字节长度小于等于L,则将当前字符真实的+在result后
|
|
89
|
+
result += chr;
|
|
90
|
+
} else { // 反之则说明result已经是不拆分字符的情况下最接近L的值了,直接返回
|
|
91
|
+
return result;
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
},
|
|
95
|
+
/**
|
|
96
|
+
* 确认
|
|
97
|
+
* */
|
|
98
|
+
sure() {
|
|
99
|
+
this.loading = true;
|
|
100
|
+
this.postFunc('/v2/trade/saveTradeMark', this.postData).then(res=>{
|
|
101
|
+
this.loading = false;
|
|
102
|
+
if(!res.code){
|
|
103
|
+
this.$emit('overRemark',this.postData)
|
|
104
|
+
this.show=false;
|
|
105
|
+
}
|
|
106
|
+
})
|
|
107
|
+
},
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
</script>
|
|
111
|
+
|
|
112
|
+
<style scoped lang="scss">
|
|
113
|
+
@import "../font/iconfont.css";
|
|
114
|
+
// 班牛旗帜颜色
|
|
115
|
+
// 灰色
|
|
116
|
+
.flag-color-gray {
|
|
117
|
+
color: #999999;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
// 红色
|
|
121
|
+
.flag-color-red {
|
|
122
|
+
color: #EA3D3D;
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
// 黄色
|
|
126
|
+
.flag-color-yellow {
|
|
127
|
+
color: #FFC60B;
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
// 绿色
|
|
131
|
+
.flag-color-green {
|
|
132
|
+
color: #3ACB36;
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
// 蓝色
|
|
136
|
+
.flag-color-blue {
|
|
137
|
+
color: #0664F0;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
// 紫色
|
|
141
|
+
.flag-color-purple {
|
|
142
|
+
color: #BA2FFF;
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
// 橙色
|
|
146
|
+
.flag-color-orange {
|
|
147
|
+
color: #F48804;
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
// 浅蓝色
|
|
151
|
+
.flag-color-lightBlue {
|
|
152
|
+
color: #41B4FA;
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
// 浅粉色
|
|
156
|
+
.flag-color-lightPink {
|
|
157
|
+
color: #E5B6B6;
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
// 深绿色
|
|
161
|
+
.flag-color-bottleGreen {
|
|
162
|
+
color: #9BA217;
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
// 桃红色
|
|
166
|
+
.flag-color-peach {
|
|
167
|
+
color: #E4248E;
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
// 青色(抖音的,在班牛没有这个颜色,班牛这边是深绿色)
|
|
171
|
+
.flag-color-cyan {
|
|
172
|
+
color: #9BA217;
|
|
173
|
+
}
|
|
174
|
+
.orderRemark {
|
|
175
|
+
height: 100%;
|
|
176
|
+
overflow: hidden;
|
|
177
|
+
}
|
|
178
|
+
</style>
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
export const flagList = {
|
|
2
|
+
// 淘宝 sellerType为1 旗帜颜色 和 key值对应
|
|
3
|
+
1: [
|
|
4
|
+
{value: "grey", className: "gray", key: '0'}, // 灰色
|
|
5
|
+
{value: "red", className: "red", key: '1'}, // 红色
|
|
6
|
+
{value: "yellow", className: "orange", key: '2'}, // 橙色 (因为旧版的原因做兼容,旧版的yellow展示的是橙色)PS:布奇、乔巴
|
|
7
|
+
{value: "green", className: "green", key: '3'}, // 绿色
|
|
8
|
+
{value: "blue", className: "blue", key: '4'}, // 蓝色
|
|
9
|
+
{value: "purple", className: "purple", key: '5'}, // 紫色
|
|
10
|
+
{value: "yellow2", className: "yellow", key: '6'}, // 黄色 (因为旧版的原因做兼容,旧版的yellow展示的是橙色)
|
|
11
|
+
{value: "lightBlue", className: "lightBlue", key: '7'}, // 浅蓝色
|
|
12
|
+
{value: "lightPink", className: "lightPink", key: '8'}, // 浅粉色
|
|
13
|
+
{value: "bottleGreen", className: "bottleGreen", key: '9'}, // 深绿色
|
|
14
|
+
{value: "peach", className: "peach", key: '10'}, // 桃红色
|
|
15
|
+
],
|
|
16
|
+
// 天猫 sellerType为8 旗帜颜色 和 key值对应
|
|
17
|
+
8: [
|
|
18
|
+
{value: "grey", className: "gray", key: '0'}, // 灰色
|
|
19
|
+
{value: "red", className: "red", key: '1'}, // 红色
|
|
20
|
+
{value: "yellow", className: "orange", key: '2'}, // 橙色 (因为旧版的原因做兼容,旧版的yellow展示的是橙色)PS:布奇、乔巴
|
|
21
|
+
{value: "green", className: "green", key: '3'}, // 绿色
|
|
22
|
+
{value: "blue", className: "blue", key: '4'}, // 蓝色
|
|
23
|
+
{value: "purple", className: "purple", key: '5'}, // 紫色
|
|
24
|
+
{value: "yellow2", className: "yellow", key: '6'}, // 黄色 (因为旧版的原因做兼容,旧版的yellow展示的是橙色)
|
|
25
|
+
{value: "lightBlue", className: "lightBlue", key: '7'}, // 浅蓝色
|
|
26
|
+
{value: "lightPink", className: "lightPink", key: '8'}, // 浅粉色
|
|
27
|
+
{value: "bottleGreen", className: "bottleGreen", key: '9'}, // 深绿色
|
|
28
|
+
{value: "peach", className: "peach", key: '10'}, // 桃红色
|
|
29
|
+
],
|
|
30
|
+
// 京东 sellerType为3 旗帜颜色 和 key值对应
|
|
31
|
+
3: [
|
|
32
|
+
{value: "grey", className: "gray", key: '0'}, // 灰色
|
|
33
|
+
{value: "red", className: "red", key: '1'}, // 红色
|
|
34
|
+
{value: "yellow", className: "orange", key: '2'}, // 橙色 (因为旧版的原因做兼容,旧版的yellow展示的是橙色)
|
|
35
|
+
{value: "green", className: "green", key: '3'}, // 绿色
|
|
36
|
+
{value: "blue", className: "blue", key: '4'}, // 蓝色
|
|
37
|
+
{value: "purple", className: "purple", key: '5'}, // 紫色
|
|
38
|
+
],
|
|
39
|
+
// 拼多多 sellerType为29 旗帜颜色 和 key值对应
|
|
40
|
+
29: [
|
|
41
|
+
// {value: "grey", className: "gray", key: '0'}, // 灰色
|
|
42
|
+
{value: "red", className: "red", key: '1'}, // 红色
|
|
43
|
+
{value: "yellow", className: "orange", key: '2'}, // 橙色 (因为旧版的原因做兼容,旧版的yellow展示的是橙色)
|
|
44
|
+
{value: "green", className: "green", key: '3'}, // 绿色
|
|
45
|
+
{value: "blue", className: "blue", key: '4'}, // 蓝色
|
|
46
|
+
{value: "purple", className: "purple", key: '5'}, // 紫色
|
|
47
|
+
],
|
|
48
|
+
// 抖音 sellerType为37 旗帜颜色 和 key值对应
|
|
49
|
+
37: [
|
|
50
|
+
{value: "grey", className: "gray", key: '0'}, // 灰色
|
|
51
|
+
{value: "red", className: "red", key: '5'}, // 红色
|
|
52
|
+
{value: "yellow", className: "orange", key: '4'}, // 橙色 (因为旧版的原因做兼容,旧版的yellow展示的是橙色)
|
|
53
|
+
{value: "green", className: "green", key: '3'}, // 绿色
|
|
54
|
+
{value: "blue", className: "blue", key: '2'}, // 蓝色
|
|
55
|
+
{value: "purple", className: "purple", key: '1'}, // 紫色
|
|
56
|
+
],
|
|
57
|
+
// 快手 sellerType为36 旗帜颜色 和 key值对应
|
|
58
|
+
36: [
|
|
59
|
+
{value: "grey", className: "gray", key: '6'}, // 灰色
|
|
60
|
+
{value: "red", className: "red", key: '1'}, // 红色
|
|
61
|
+
{value: "yellow", className: "orange", key: '2'}, // 橙色 (因为旧版的原因做兼容,旧版的yellow展示的是橙色)
|
|
62
|
+
{value: "green", className: "green", key: '3'}, // 绿色
|
|
63
|
+
{value: "blue", className: "blue", key: '4'}, // 蓝色
|
|
64
|
+
{value: "purple", className: "purple", key: '5'}, // 紫色
|
|
65
|
+
],
|
|
66
|
+
// EASTBUY sellerType为43 旗帜颜色 和 key值对应
|
|
67
|
+
43: [
|
|
68
|
+
{value: "grey", className: "gray", key: '0'}, // 灰色
|
|
69
|
+
{value: "red", className: "red", key: '1'}, // 红色
|
|
70
|
+
{value: "yellow", className: "orange", key: '2'}, // 橙色(因为旧版的原因做兼容,旧版的yellow展示的是橙色)
|
|
71
|
+
{value: "green", className: "green", key: '3'}, // 绿色
|
|
72
|
+
{value: "blue", className: "blue", key: '4'}, // 蓝色
|
|
73
|
+
{value: "purple", className: "purple", key: '5'}, // 紫色
|
|
74
|
+
],
|
|
75
|
+
// 得物 sellerType为44 旗帜颜色 和 key值对应
|
|
76
|
+
44: [
|
|
77
|
+
{value: "red", className: "red", key: '1'}, // 红色
|
|
78
|
+
{value: "yellow", className: "orange", key: '2'}, // 橙色
|
|
79
|
+
{value: "green", className: "green", key: '3'}, // 绿色
|
|
80
|
+
{value: "blue", className: "blue", key: '4'}, // 蓝色
|
|
81
|
+
{value: "purple", className: "purple", key: '5'}, // 紫色
|
|
82
|
+
{value: "yellow2", className: "yellow", key: '6'}, // 黄色
|
|
83
|
+
],
|
|
84
|
+
// 小红书 sellerType为25 旗帜颜色 和 key值对应
|
|
85
|
+
25: [
|
|
86
|
+
{value: "grey", className: "gray", key: '0'}, // 灰色
|
|
87
|
+
{value: "red", className: "red", key: '1'}, // 红色
|
|
88
|
+
{value: "yellow", className: "orange", key: '2'}, // 橙色
|
|
89
|
+
{value: "green", className: "green", key: '3'}, // 绿色
|
|
90
|
+
{value: "blue", className: "blue", key: '4'}, // 蓝色
|
|
91
|
+
{value: "purple", className: "purple", key: '5'}, // 紫色
|
|
92
|
+
// {value: "yellow2", className: "yellow", key: '6'}, // 黄色
|
|
93
|
+
]
|
|
94
|
+
}
|
|
@@ -0,0 +1,338 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="BnOrderDetail" id="BnOrderDetail" v-if="show" @click="show=false">
|
|
3
|
+
<div class="BnOrderDetail-main" @click.stop="">
|
|
4
|
+
<div class="BnOrderDetail-main-top">
|
|
5
|
+
<slot name="top" :taskDetail="taskDetail" :components="componentList" :id="id"></slot>
|
|
6
|
+
<div class="BnOrderDetail-main-top-btn w-flex-center">
|
|
7
|
+
<template v-for="item in operateList">
|
|
8
|
+
<el-button plain size="small" class="w-margin-left0" @click="operate(item.type)">
|
|
9
|
+
{{ item.title }}
|
|
10
|
+
</el-button>
|
|
11
|
+
</template>
|
|
12
|
+
<span class="bnUIcon bnUIcon-copy w-color-blue" v-if="!noPower.includes('copy')" title="复制" @click="operate('copy')"></span>
|
|
13
|
+
<span class="bnUIcon bnUIcon-edit w-color-blue" v-if="!noPower.includes('edit')" @click="operate('edit')"></span>
|
|
14
|
+
<el-tooltip :content="showEmpty?'隐藏空值':'显示空值'" placement="top">
|
|
15
|
+
<span class="bnUIcon" :class="[showEmpty?'bnUIcon-notLookEmpty w-color-red':'bnUIcon-lookEmpty w-color-blue']"
|
|
16
|
+
@click="toggleEmpty"></span>
|
|
17
|
+
</el-tooltip>
|
|
18
|
+
<span class="bnUIcon bnUIcon-close" @click="show=false"></span>
|
|
19
|
+
</div>
|
|
20
|
+
</div>
|
|
21
|
+
<div class="BnOrderDetail-main-body" v-loading="loading">
|
|
22
|
+
<div class="BnOrderDetail-main-detail">
|
|
23
|
+
<BnEmptyTip v-if="!taskDetail.id"></BnEmptyTip>
|
|
24
|
+
<template v-for="(item,index) in componentList" :key="index">
|
|
25
|
+
<div class="BnOrderDetail-item" v-if="showEmpty || !isEmpty(taskDetail[item.columnCode])">
|
|
26
|
+
<div class="BnOrderDetail-item-header">{{ item.name }}
|
|
27
|
+
<div class="w-margin-top4" v-if="isAiMarkingColumn(item)">
|
|
28
|
+
<img style="width: 72px;height: 16px"
|
|
29
|
+
src="https://banniu-work.oss-cn-zhangjiakou.aliyuncs.com/125_10030158_10c0871f0e3550f1297a850a1a9ecabd.jpg">
|
|
30
|
+
</div>
|
|
31
|
+
</div>
|
|
32
|
+
<div class="BnOrderDetail-item-content" v-if="!isEmpty(taskDetail[item.columnCode])">
|
|
33
|
+
<slot :name="'columnDetail_' + item.columnCode" :item="item" :value="taskDetail[item.columnCode]" :row="taskDetail">
|
|
34
|
+
<div class="BnOrderDetail-item-content-text" v-if="item.behaviorType != 13 && item.behaviorType != 10">
|
|
35
|
+
{{ taskDetail[item.columnCode] }}
|
|
36
|
+
<span class="w-color-blue w-cursor-pointer" @click="copyVal(taskDetail[item.columnCode])">复制</span>
|
|
37
|
+
</div>
|
|
38
|
+
<div class="BnOrderDetail-item-content-sub" v-else-if="item.behaviorType == 10">
|
|
39
|
+
<BnFileView :file-list="taskDetail.inside[item.columnCode]" :is-mini="true" :no-warp="true"
|
|
40
|
+
width="50px"/>
|
|
41
|
+
</div>
|
|
42
|
+
<div class="BnOrderDetail-item-content-sub" v-else-if="item.behaviorType == 13">
|
|
43
|
+
<showSubForm :column="item" :row="taskDetail" :maxHeight="300"></showSubForm>
|
|
44
|
+
</div>
|
|
45
|
+
</slot>
|
|
46
|
+
</div>
|
|
47
|
+
</div>
|
|
48
|
+
</template>
|
|
49
|
+
<BnOrderCard v-if="taskDetail.tid" :postFunc="postFunc" :extendPost="{tid:taskDetail.tid,taskId:id,appId:tableInfo.appId,projectId:tableInfo.tableId}"></BnOrderCard>
|
|
50
|
+
</div>
|
|
51
|
+
<div class="BnOrderDetail-main-other">
|
|
52
|
+
<el-affix target=".BnOrderDetail-main-other" :offset="30">
|
|
53
|
+
<div class="w-flex-center w-flex-between" style="background: #fff">
|
|
54
|
+
<el-tabs v-model="defaultTab" class="e-clear-tabs-border">
|
|
55
|
+
<el-tab-pane name="1" label="操作记录"/>
|
|
56
|
+
<el-tab-pane :name="item.name" :label="item.label" v-for="item in tabPaneList" />
|
|
57
|
+
</el-tabs>
|
|
58
|
+
<filterLogByUser v-model="filterUsers" v-if="defaultTab == 1" v-bind="$props"></filterLogByUser>
|
|
59
|
+
</div>
|
|
60
|
+
</el-affix>
|
|
61
|
+
<orderLogs :table-info="tableInfo" :filterUsers="filterUsers" :id="id" :postFunc="postFunc" v-if="defaultTab == 1"></orderLogs>
|
|
62
|
+
<slot name="tabPane" :chooseTab="defaultTab" :taskDetail="taskDetail" :id="id" :components="componentList"></slot>
|
|
63
|
+
</div>
|
|
64
|
+
<el-backtop :right="30" :bottom="100" target=".BnOrderDetail-main-body"/>
|
|
65
|
+
</div>
|
|
66
|
+
</div>
|
|
67
|
+
</div>
|
|
68
|
+
</template>
|
|
69
|
+
<script>
|
|
70
|
+
import {isEmpty} from "lodash";
|
|
71
|
+
import showSubForm from "./showSubForm/index.vue";
|
|
72
|
+
import orderLogs from "./orderLogs.vue";
|
|
73
|
+
import {getWatchComponents,userConst} from "../../utils/index.js";
|
|
74
|
+
import filterLogByUser from "./filterLogByUser.vue";
|
|
75
|
+
|
|
76
|
+
export default {
|
|
77
|
+
name: 'BnOrderDetail',
|
|
78
|
+
components: {showSubForm, orderLogs,filterLogByUser},
|
|
79
|
+
props: {
|
|
80
|
+
// 表信息
|
|
81
|
+
tableInfo: Object,
|
|
82
|
+
// 组件列表
|
|
83
|
+
watchComponents: Array,
|
|
84
|
+
// 没有权限的默认操作 copy edit
|
|
85
|
+
noPower: {
|
|
86
|
+
type:Array,
|
|
87
|
+
default(){
|
|
88
|
+
return []
|
|
89
|
+
}
|
|
90
|
+
},
|
|
91
|
+
// 根据成员过滤操作记录时要不要考虑工作表权限
|
|
92
|
+
userByTable:Boolean,
|
|
93
|
+
// 操作列表
|
|
94
|
+
operateList: {
|
|
95
|
+
type:Array,
|
|
96
|
+
default(){
|
|
97
|
+
return []
|
|
98
|
+
}
|
|
99
|
+
},
|
|
100
|
+
// 底部tabList
|
|
101
|
+
tabPaneList: {
|
|
102
|
+
type:Array,
|
|
103
|
+
default(){
|
|
104
|
+
return []
|
|
105
|
+
}
|
|
106
|
+
},
|
|
107
|
+
// 接口请求外部转发
|
|
108
|
+
postUrl: {},
|
|
109
|
+
postFunc: Function,
|
|
110
|
+
},
|
|
111
|
+
computed:{
|
|
112
|
+
componentList(){
|
|
113
|
+
return this.watchComponents || this.components
|
|
114
|
+
}
|
|
115
|
+
},
|
|
116
|
+
data() {
|
|
117
|
+
return {
|
|
118
|
+
userConst,
|
|
119
|
+
show: false,
|
|
120
|
+
loading: false,
|
|
121
|
+
// 默认看板 操作日志、售后记录
|
|
122
|
+
defaultTab: '1',
|
|
123
|
+
showEmpty: localStorage.getItem('workOrderDetail_showEmpty') === 'true' || false,
|
|
124
|
+
// 任务id
|
|
125
|
+
id: '',
|
|
126
|
+
// 任务详情
|
|
127
|
+
taskDetail: {},
|
|
128
|
+
// 当没有传入组件列表时通过接口获取组件列表
|
|
129
|
+
components:[],
|
|
130
|
+
// 根据成员过滤操作日志
|
|
131
|
+
filterUsers:[],
|
|
132
|
+
}
|
|
133
|
+
},
|
|
134
|
+
methods: {
|
|
135
|
+
isEmpty,
|
|
136
|
+
/**
|
|
137
|
+
* 判断字段是否被 AI 打标(beneben_ai_marking 为逗号分隔的 columnId 字符串)
|
|
138
|
+
*/
|
|
139
|
+
isAiMarkingColumn(item) {
|
|
140
|
+
const marking = this.taskDetail.beneben_ai_marking;
|
|
141
|
+
if (!marking) return false;
|
|
142
|
+
const columnId = String(item.id);
|
|
143
|
+
if (typeof marking === 'string') {
|
|
144
|
+
return marking.split(',').some(id => id.trim() === columnId);
|
|
145
|
+
}
|
|
146
|
+
if (Array.isArray(marking)) {
|
|
147
|
+
return marking.some(id => String(id) === columnId);
|
|
148
|
+
}
|
|
149
|
+
return Boolean(marking[columnId]);
|
|
150
|
+
},
|
|
151
|
+
/**
|
|
152
|
+
* 打开编辑弹框
|
|
153
|
+
* */
|
|
154
|
+
async open(id) {
|
|
155
|
+
this.loading = true;
|
|
156
|
+
this.defaultTab = '1';
|
|
157
|
+
this.id = id;
|
|
158
|
+
this.taskDetail = {};
|
|
159
|
+
this.show = true;
|
|
160
|
+
if(!this.watchComponents){
|
|
161
|
+
await this.getTableInfo()
|
|
162
|
+
}
|
|
163
|
+
this.getTaskDetail()
|
|
164
|
+
},
|
|
165
|
+
/**
|
|
166
|
+
* 是否可查看空值
|
|
167
|
+
* */
|
|
168
|
+
toggleEmpty() {
|
|
169
|
+
this.showEmpty = !this.showEmpty;
|
|
170
|
+
localStorage.setItem('workOrderDetail_showEmpty', this.showEmpty);
|
|
171
|
+
},
|
|
172
|
+
/**
|
|
173
|
+
* 操作
|
|
174
|
+
* @param object row 行数据
|
|
175
|
+
* */
|
|
176
|
+
operate(type) {
|
|
177
|
+
this.$emit('orderOperate', type, this.taskDetail)
|
|
178
|
+
this.show = false;
|
|
179
|
+
},
|
|
180
|
+
|
|
181
|
+
/**
|
|
182
|
+
* 查询表信息
|
|
183
|
+
* */
|
|
184
|
+
async getTableInfo() {
|
|
185
|
+
let tableData = await this.postFunc(`/biztable/definition/table?tableCode=${this.tableInfo.tableCode}&columns=1`, null, 'get')
|
|
186
|
+
if (!tableData.code) {
|
|
187
|
+
this.components = getWatchComponents(tableData.data.columns, tableData.data.appId, tableData.data.tableId);
|
|
188
|
+
}
|
|
189
|
+
},
|
|
190
|
+
/**
|
|
191
|
+
* 查询工单详情
|
|
192
|
+
* */
|
|
193
|
+
getTaskDetail() {
|
|
194
|
+
let postData = {
|
|
195
|
+
tableCode: this.tableInfo.tableCode,
|
|
196
|
+
id: this.id
|
|
197
|
+
}
|
|
198
|
+
this.loading = true;
|
|
199
|
+
// 获取工单详情
|
|
200
|
+
this.postFunc(this.postUrl || '/biztable/content/get',postData).then(res => {
|
|
201
|
+
this.loading = false;
|
|
202
|
+
if (!res.code) {
|
|
203
|
+
let taskDetail = {...res.data.view, inside: res.data.inside};
|
|
204
|
+
if(!taskDetail.tid){
|
|
205
|
+
// 获取订单号的columnCode
|
|
206
|
+
const matchedItem = this.componentList.find(item => {
|
|
207
|
+
if (item.outDataSourceInfo && item.outDataSourceInfo[0]) {
|
|
208
|
+
let {field, table, platform} = item.outDataSourceInfo[0]
|
|
209
|
+
return field == 'tid' && platform == 'CRM' && table == 'TRADE'
|
|
210
|
+
}
|
|
211
|
+
return false
|
|
212
|
+
})
|
|
213
|
+
if (matchedItem) {
|
|
214
|
+
taskDetail.tid = taskDetail[matchedItem.columnCode]
|
|
215
|
+
}
|
|
216
|
+
}
|
|
217
|
+
this.taskDetail = taskDetail;
|
|
218
|
+
}
|
|
219
|
+
})
|
|
220
|
+
},
|
|
221
|
+
/**
|
|
222
|
+
* 复制
|
|
223
|
+
* */
|
|
224
|
+
copyVal(val) {
|
|
225
|
+
const textarea = document.createElement('textarea');
|
|
226
|
+
textarea.value = val;
|
|
227
|
+
document.body.appendChild(textarea);
|
|
228
|
+
textarea.select();
|
|
229
|
+
document.execCommand('copy');
|
|
230
|
+
document.body.removeChild(textarea);
|
|
231
|
+
this.$message.success('复制成功');
|
|
232
|
+
}
|
|
233
|
+
},
|
|
234
|
+
}
|
|
235
|
+
</script>
|
|
236
|
+
|
|
237
|
+
<style scoped lang="scss">
|
|
238
|
+
.BnOrderDetail {
|
|
239
|
+
position: fixed;
|
|
240
|
+
justify-items: right;
|
|
241
|
+
top: 0;
|
|
242
|
+
left: 0;
|
|
243
|
+
bottom: 0;
|
|
244
|
+
right: 0;
|
|
245
|
+
background: rgba(0, 0, 0, .3);
|
|
246
|
+
z-index: 999;
|
|
247
|
+
|
|
248
|
+
&-main {
|
|
249
|
+
position: relative;
|
|
250
|
+
height: 100%;
|
|
251
|
+
width: 60%;
|
|
252
|
+
background: #fff;
|
|
253
|
+
|
|
254
|
+
&-top {
|
|
255
|
+
position: relative;
|
|
256
|
+
display: flex;
|
|
257
|
+
justify-content: space-between;
|
|
258
|
+
align-items: center;
|
|
259
|
+
padding: 0 20px;
|
|
260
|
+
height: 42px;
|
|
261
|
+
border-bottom: 1px solid #eee;
|
|
262
|
+
color: #666;
|
|
263
|
+
|
|
264
|
+
&-btn {
|
|
265
|
+
display: flex;
|
|
266
|
+
gap: 10px;
|
|
267
|
+
|
|
268
|
+
span {
|
|
269
|
+
cursor: pointer;
|
|
270
|
+
}
|
|
271
|
+
}
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
&-body {
|
|
275
|
+
display: flex;
|
|
276
|
+
flex-wrap: wrap;
|
|
277
|
+
position: relative;
|
|
278
|
+
width: 100%;
|
|
279
|
+
height: calc(100% - 42px);
|
|
280
|
+
overflow-y: auto;
|
|
281
|
+
}
|
|
282
|
+
|
|
283
|
+
&-detail {
|
|
284
|
+
display: flex;
|
|
285
|
+
flex-wrap: wrap;
|
|
286
|
+
align-content: start;
|
|
287
|
+
position: relative;
|
|
288
|
+
width: 100%;
|
|
289
|
+
padding: 10px 20px;
|
|
290
|
+
}
|
|
291
|
+
|
|
292
|
+
&-other {
|
|
293
|
+
position: relative;
|
|
294
|
+
width: 100%;
|
|
295
|
+
padding: 0 20px;
|
|
296
|
+
}
|
|
297
|
+
}
|
|
298
|
+
|
|
299
|
+
&-item {
|
|
300
|
+
display: flex;
|
|
301
|
+
width: 100%;
|
|
302
|
+
margin-bottom: 10px;
|
|
303
|
+
|
|
304
|
+
&-header {
|
|
305
|
+
width: 140px;
|
|
306
|
+
font-size: 14px;
|
|
307
|
+
height: 32px;
|
|
308
|
+
padding: 8px 0;
|
|
309
|
+
color: #888;
|
|
310
|
+
}
|
|
311
|
+
|
|
312
|
+
&-content {
|
|
313
|
+
width: calc(100% - 140px);
|
|
314
|
+
padding: 8px 0 0 18px;
|
|
315
|
+
|
|
316
|
+
&-text {
|
|
317
|
+
font-size: 14px;
|
|
318
|
+
line-height: 22px;
|
|
319
|
+
color: #333;
|
|
320
|
+
|
|
321
|
+
span {
|
|
322
|
+
display: none;
|
|
323
|
+
}
|
|
324
|
+
|
|
325
|
+
&:hover {
|
|
326
|
+
span {
|
|
327
|
+
display: inline;
|
|
328
|
+
}
|
|
329
|
+
}
|
|
330
|
+
}
|
|
331
|
+
|
|
332
|
+
&-sub {
|
|
333
|
+
padding-left: 3px;
|
|
334
|
+
}
|
|
335
|
+
}
|
|
336
|
+
}
|
|
337
|
+
}
|
|
338
|
+
</style>
|