Commit 5228cf74 by 无尘

fix: 修改已选值显示

parent dc7a2752
<!DOCTYPE html><html><head><meta charset=utf-8><link rel="shortcut icon" href=./favicon.ico><title>GIC-会员标签</title><link href=./static/css/app.aff8a55a950ca98e4d5f26f141fe1b6f.css rel=stylesheet></head><body style="background-color: #f0f2f5;min-width: 1400px;"><div id=app></div><script type=text/javascript src=./static/js/manifest.dd9ff418c965b22b5c99.js></script><script type=text/javascript src=./static/js/vendor.4ac54fd03099c45beefc.js></script><script type=text/javascript src=./static/js/app.02d90a4902d64f39bb04.js></script></body></html>
\ No newline at end of file
<!DOCTYPE html><html><head><meta charset=utf-8><link rel="shortcut icon" href=./favicon.ico><title>GIC-会员标签</title><link href=./static/css/app.4e8dddd4328bdba2b578ca61e913c2f2.css rel=stylesheet></head><body style="background-color: #f0f2f5;min-width: 1400px;"><div id=app></div><script type=text/javascript src=./static/js/manifest.57df288a0f63cc30a5e5.js></script><script type=text/javascript src=./static/js/vendor.4ac54fd03099c45beefc.js></script><script type=text/javascript src=./static/js/app.02d90a4902d64f39bb04.js></script></body></html>
\ No newline at end of file
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
!function(e){var c=window.webpackJsonp;window.webpackJsonp=function(n,o,a){for(var f,d,i,u=0,b=[];u<n.length;u++)d=n[u],r[d]&&b.push(r[d][0]),r[d]=0;for(f in o)Object.prototype.hasOwnProperty.call(o,f)&&(e[f]=o[f]);for(c&&c(n,o,a);b.length;)b.shift()();if(a)for(u=0;u<a.length;u++)i=t(t.s=a[u]);return i};var n={},r={26:0};function t(c){if(n[c])return n[c].exports;var r=n[c]={i:c,l:!1,exports:{}};return e[c].call(r.exports,r,r.exports,t),r.l=!0,r.exports}t.e=function(e){var c=r[e];if(0===c)return new Promise(function(e){e()});if(c)return c[2];var n=new Promise(function(n,t){c=r[e]=[n,t]});c[2]=n;var o=document.getElementsByTagName("head")[0],a=document.createElement("script");a.type="text/javascript",a.charset="utf-8",a.async=!0,a.timeout=12e4,t.nc&&a.setAttribute("nonce",t.nc),a.src=t.p+"static/js/"+e+"."+{0:"72123e3de0997d5b69ce",1:"d1b66d4bf3d45b2621dd",2:"344d5c61c44868322e7e",3:"88a303fc10feb8b51091",4:"f6a8f25f4e8cc458879d",5:"464a7564c7b7ba2790b3",6:"2ad8c664bf590ca3399c",7:"705594fccf9031ef2581",8:"5527b3fe40f876e119c5",9:"fd6cd78284ce40bbd146",10:"c71c26ffe9e929740644",11:"e85b90356083e5b3e250",12:"c0e6361ebccd622f756e",13:"e29aa5893a93a16c34bc",14:"9e2a6743137628654ca9",15:"e32139e15d4fcfa0d5c6",16:"f4036a24000959bd38c8",17:"83e469d672229c638715",18:"129d150ebd1fce6ee6e0",19:"4f681127cc3b6c7e3765",20:"d26c039b11e406222a2d",21:"972da6998dbc9266146f",22:"e91d8f3111c8c501ab9d",25:"9ceafa4ee79176c87d81"}[e]+".js";var f=setTimeout(d,12e4);function d(){a.onerror=a.onload=null,clearTimeout(f);var c=r[e];0!==c&&(c&&c[1](new Error("Loading chunk "+e+" failed.")),r[e]=void 0)}return a.onerror=a.onload=d,o.appendChild(a),n},t.m=e,t.c=n,t.d=function(e,c,n){t.o(e,c)||Object.defineProperty(e,c,{configurable:!1,enumerable:!0,get:n})},t.n=function(e){var c=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(c,"a",c),c},t.o=function(e,c){return Object.prototype.hasOwnProperty.call(e,c)},t.p="./",t.oe=function(e){throw console.error(e),e}}([]);
//# sourceMappingURL=manifest.dd9ff418c965b22b5c99.js.map
\ No newline at end of file
!function(e){var c=window.webpackJsonp;window.webpackJsonp=function(n,o,a){for(var f,d,i,u=0,b=[];u<n.length;u++)d=n[u],r[d]&&b.push(r[d][0]),r[d]=0;for(f in o)Object.prototype.hasOwnProperty.call(o,f)&&(e[f]=o[f]);for(c&&c(n,o,a);b.length;)b.shift()();if(a)for(u=0;u<a.length;u++)i=t(t.s=a[u]);return i};var n={},r={26:0};function t(c){if(n[c])return n[c].exports;var r=n[c]={i:c,l:!1,exports:{}};return e[c].call(r.exports,r,r.exports,t),r.l=!0,r.exports}t.e=function(e){var c=r[e];if(0===c)return new Promise(function(e){e()});if(c)return c[2];var n=new Promise(function(n,t){c=r[e]=[n,t]});c[2]=n;var o=document.getElementsByTagName("head")[0],a=document.createElement("script");a.type="text/javascript",a.charset="utf-8",a.async=!0,a.timeout=12e4,t.nc&&a.setAttribute("nonce",t.nc),a.src=t.p+"static/js/"+e+"."+{0:"72123e3de0997d5b69ce",1:"d1b66d4bf3d45b2621dd",2:"344d5c61c44868322e7e",3:"88a303fc10feb8b51091",4:"f6a8f25f4e8cc458879d",5:"464a7564c7b7ba2790b3",6:"cc668657b720bd411ebf",7:"4879d0128af9b6795acc",8:"5527b3fe40f876e119c5",9:"f54c71972a97de37a8da",10:"c71c26ffe9e929740644",11:"e85b90356083e5b3e250",12:"c0e6361ebccd622f756e",13:"e29aa5893a93a16c34bc",14:"9e2a6743137628654ca9",15:"e32139e15d4fcfa0d5c6",16:"f4036a24000959bd38c8",17:"83e469d672229c638715",18:"129d150ebd1fce6ee6e0",19:"4f681127cc3b6c7e3765",20:"d26c039b11e406222a2d",21:"972da6998dbc9266146f",22:"e91d8f3111c8c501ab9d",25:"9ceafa4ee79176c87d81"}[e]+".js";var f=setTimeout(d,12e4);function d(){a.onerror=a.onload=null,clearTimeout(f);var c=r[e];0!==c&&(c&&c[1](new Error("Loading chunk "+e+" failed.")),r[e]=void 0)}return a.onerror=a.onload=d,o.appendChild(a),n},t.m=e,t.c=n,t.d=function(e,c,n){t.o(e,c)||Object.defineProperty(e,c,{configurable:!1,enumerable:!0,get:n})},t.n=function(e){var c=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(c,"a",c),c},t.o=function(e,c){return Object.prototype.hasOwnProperty.call(e,c)},t.p="./",t.oe=function(e){throw console.error(e),e}}([]);
//# sourceMappingURL=manifest.57df288a0f63cc30a5e5.js.map
\ No newline at end of file
......@@ -949,7 +949,7 @@
if (code === 'tag003' && that.templateData.length ===1) {
tagValue.val[0].data.compute = that.templateData[0].postCompute;
tagValue.val[0].data.value = that.templateData[0].numRange.join(',')
that.postTemplateData.selectedVal = [that.templateData[0].numRange[0]+'<='+ that.tagData.tagName +'<='+ that.templateData[0].numRange[1]];
that.postTemplateData.selectedVal.push(`${that.templateData[0].numRange[0]} <= ${that.tagData.tagName} <= ${that.templateData[0].numRange[1]}`);
}
/* 输入添加值 */
......@@ -960,7 +960,7 @@
if (code === 'tag007' && that.templateData.length ===1 ){
tagValue.val[0].data.compute = that.templateData[0].postCompute;;
tagValue.val[0].data.value = that.templateData[0].addTags.map(item=>item.value).join(',')
that.postTemplateData.selectedVal = that.templateData[0].addTags.map(item=>item.value)
that.postTemplateData.selectedVal.push(that.templateData[0].addTags.map(item=>item.value).join(','))
}
// 全部/已选
......@@ -970,7 +970,7 @@
}
if (code === 'tag009' && that.templateData.length ===1 ){
tagValue.val[0].data.value = that.templateData[0].selectedOptions.map(item=>item.key).join(',')
that.postTemplateData.selectedVal = that.templateData[0].selectedOptions.map(item=>item.value)
that.postTemplateData.selectedVal.push(that.templateData[0].selectedOptions.map(item=>item.value).join(','))
}
// 多选项(城市选择) ( 全部选项/已选选项 )
......@@ -979,8 +979,8 @@
return false;
}
if (code === 'tag010' && that.templateData.length ===1 ){
tagValue.val[0].data.value = that.templateData[0].citySelectedOptions.map(item=>item.cityId).join(',')
that.postTemplateData.selectedVal = that.templateData[0].citySelectedOptions.map(item=>item.selected)
tagValue.val[0].data.value = that.templateData[0].citySelectedOptions.map(item=>item.cityId).join(',');
that.postTemplateData.selectedVal.push(that.templateData[0].citySelectedOptions.map(item=>item.selected).join(','))
}
/* 多选异步 */
......@@ -1014,7 +1014,7 @@
tagValue.val[0].data.compute = that.templateData[0].postCompute;
}
tagValue.val[0].data.value = that.templateData[0].dateRangeValue.join(',')
that.postTemplateData.selectedVal = [that.templateData[0].dateRangeValue[0]+'至'+that.templateData[0].dateRangeValue[1]]
that.postTemplateData.selectedVal.push(`${that.templateData[0].dateRangeValue[0]}${that.templateData[0].dateRangeValue[1]}`)
}
if ((code === 'tag014' || code === 'tag017') && that.templateData.length === 1 && that.templateData[0].radio == 2){
// 天
......@@ -1144,7 +1144,7 @@
tagValue.val[0].data.compute = that.templateData[0].postCompute;
}
tagValue.val[0].data.value = that.templateData[0].monthDayRange.join(',')
that.postTemplateData.selectedVal = [that.templateData[0].monthDayRange[0]+'至'+that.templateData[0].monthDayRange[1]]
that.postTemplateData.selectedVal.push(`${that.templateData[0].monthDayRange[0]}${that.templateData[0].monthDayRange[1]}`)
}
if (code === 'tag015' && that.templateData.length === 1 && that.templateData[0].radio == 2){
// 天
......@@ -1227,7 +1227,6 @@
// that.templateData.forEach(function(ele,index){
for (let ele of that.templateData) {
// 选项
if (ele.templateCode === 'tag001') {
if (!ele.checkeditems.length) { returnFlag = false }
......@@ -1256,7 +1255,7 @@
}
tagValue.val[0].data.compute = ele.postCompute;
tagValue.val[0].data.value = ele.numRange.join(',')
that.postTemplateData.selectedVal.push([ele.numRange[0]+'<='+ that.tagData.tagName +'<='+ ele.numRange[1]]);
that.postTemplateData.selectedVal.push(`${ele.numRange[0]} <= ${that.tagData.tagName} <= ${ele.numRange[1]}`);
}
// 固定/最近
if (ele.templateCode === 'tag004') {
......@@ -1265,13 +1264,13 @@
if (ele.fixedRecentRadio == 1) {
tagValue.time[0].type = 'between';
tagValue.time[0].value = ele.fixedRecentRangeValue.join(',')
that.postTemplateData.selectedVal.push([ele.fixedRecentRangeValue[0]+'至'+ele.fixedRecentRangeValue[1]]);
that.postTemplateData.selectedVal.push(`时间范围为${ele.fixedRecentRangeValue[0]}${ele.fixedRecentRangeValue[1]}`);
}
// tagValue.val[0].data.compute = ele.postCompute;
if (ele.fixedRecentRadio == 2) {
tagValue.time[0].type = 'lastday';
tagValue.time[0].value = String(ele.fixedRecentTimeRecent);
that.postTemplateData.selectedVal.push(`最近 ${ele.fixedRecentTimeRecent} 天`);
that.postTemplateData.selectedVal.push(`时间范围为最近 ${ele.fixedRecentTimeRecent} 天`);
}
}
......@@ -1280,28 +1279,28 @@
if (ele.timeRecent === '') { returnFlag = false }
tagValue.time[0].type = ele.timeType;
tagValue.time[0].value = String(ele.timeRecent);
that.postTemplateData.selectedVal.push( `最近 ${ele.timeRecent} 天`);
that.postTemplateData.selectedVal.push( `时间范围为最近 ${ele.timeRecent} 天`);
}
// 之后 天
if (ele.templateCode === 'tag006') {
if (ele.timeAfter === '') { returnFlag = false }
tagValue.time[0].type = ele.timeType;
tagValue.time[0].value = String(ele.timeAfter);
that.postTemplateData.selectedVal.push( `之后 ${ele.timeAfter} 天`);
that.postTemplateData.selectedVal.push( `时间范围为之后 ${ele.timeAfter} 天`);
}
// 下拉搜索添加值
if (ele.templateCode === 'tag008') {
if (!ele.addSelectTags.length) { returnFlag = false }
tagValue.val[0].data.value = ele.addSelectTags.map(item=>item.key).join(',')
that.postTemplateData.selectedVal.push(ele.addSelectTags.map(item=>item.value))
tagValue.val[0].data.value = ele.addSelectTags.map(item=>item.key).join(',');
that.postTemplateData.selectedVal.push(ele.addSelectTags.map(item=>item.value).join(','));
}
// 多选项(城市选择) ( 全部选项/已选选项 )
if (ele.templateCode === 'tag010'){
console.log(ele.citySelectedOptions)
if (!ele.citySelectedOptions.length) { returnFlag = false }
tagValue.val[0].data.value = ele.citySelectedOptions.map(item=>item.cityId).join(',')
that.postTemplateData.selectedVal = ele.citySelectedOptions.map(item=>item.selected)
tagValue.val[0].data.value = ele.citySelectedOptions.map(item=>item.cityId).join(',');
that.postTemplateData.selectedVal.push(ele.citySelectedOptions.map(item=>item.selected).join(','))
}
// 门店
if (ele.templateCode === 'tag011') {
......@@ -1339,12 +1338,13 @@
that.postTemplateData.selectedVal.push(el.value)
}
})
that.postTemplateData.selectedVal.push(that.postTemplateData.selectedVal.join(','))
}
}
//
// })
}
console.log(returnFlag)
// console.log(returnFlag)
if (!returnFlag) {
that.$message.error({ message: '请完善标签值'})
return false;
......
......@@ -209,7 +209,8 @@
let newTagVal = JSON.parse(ele.tagParams)
if (newTagVal.selectedVal != '') {
ele.newTagVal = newTagVal.selectedVal
console.log(newTagVal.selectedVal)
ele.newTagVal = JSON.stringify(newTagVal.selectedVal).replace(/"/g, '');
}else{
ele.newTagVal = ''
}
......
......@@ -266,7 +266,7 @@
<div class="multiple-select-wrap__tab">
<el-tabs v-model="parent.citySelectActive">
<el-tab-pane label="全部选项" name="first">
<div class="all-select-options">
<div class="all-select-options all-select-options__city">
<div class="city-checkbox city-checkbox-all border-box">
<el-checkbox :indeterminate="parent.isIndeterminateCity" v-model="parent.checkAllCity" @change="cityCheckAllChange($event,parent)">全选</el-checkbox>
</div>
......@@ -887,7 +887,7 @@ import qs from 'qs';
if (code === 'tag003' && that.templateData.length ===1) {
tagValue.val[0].data.compute = that.templateData[0].postCompute;
tagValue.val[0].data.value = that.templateData[0].numRange.join(',')
that.postTemplateData.selectedVal = [that.templateData[0].numRange[0]+'<='+ that.tagData.tagName +'<='+ that.templateData[0].numRange[1]];
that.postTemplateData.selectedVal.push(`${that.templateData[0].numRange[0]} <= ${that.tagData.tagName} <= ${that.templateData[0].numRange[1]}`);
}
/* 输入添加值 */
......@@ -898,7 +898,7 @@ import qs from 'qs';
if (code === 'tag007' && that.templateData.length ===1 ){
tagValue.val[0].data.compute = that.templateData[0].postCompute;;
tagValue.val[0].data.value = that.templateData[0].addTags.map(item=>item.value).join(',')
that.postTemplateData.selectedVal = that.templateData[0].addTags.map(item=>item.value)
that.postTemplateData.selectedVal.push(that.templateData[0].addTags.map(item=>item.value).join(','))
}
// 全部/已选
......@@ -908,7 +908,7 @@ import qs from 'qs';
}
if (code === 'tag009' && that.templateData.length ===1 ){
tagValue.val[0].data.value = that.templateData[0].selectedOptions.map(item=>item.key).join(',')
that.postTemplateData.selectedVal = that.templateData[0].selectedOptions.map(item=>item.value)
that.postTemplateData.selectedVal.push(that.templateData[0].selectedOptions.map(item=>item.value).join(','))
}
// 多选项(城市选择) ( 全部选项/已选选项 )
......@@ -918,7 +918,7 @@ import qs from 'qs';
}
if (code === 'tag010' && that.templateData.length ===1 ){
tagValue.val[0].data.value = that.templateData[0].citySelectedOptions.map(item=>item.cityId).join(',')
that.postTemplateData.selectedVal = that.templateData[0].citySelectedOptions.map(item=>item.selected)
that.postTemplateData.selectedVal.push(that.templateData[0].citySelectedOptions.map(item=>item.selected).join(','))
}
/* 多选异步 */
......@@ -952,7 +952,7 @@ import qs from 'qs';
tagValue.val[0].data.compute = that.templateData[0].postCompute;
}
tagValue.val[0].data.value = that.templateData[0].dateRangeValue.join(',')
that.postTemplateData.selectedVal = [that.templateData[0].dateRangeValue[0]+'至'+that.templateData[0].dateRangeValue[1]]
that.postTemplateData.selectedVal.push(`${that.templateData[0].dateRangeValue[0]}${that.templateData[0].dateRangeValue[1]}`)
}
if ((code === 'tag014' || code === 'tag017') && that.templateData.length === 1 && that.templateData[0].radio == 2){
// 天
......@@ -1082,7 +1082,7 @@ import qs from 'qs';
tagValue.val[0].data.compute = that.templateData[0].postCompute;
}
tagValue.val[0].data.value = that.templateData[0].monthDayRange.join(',')
that.postTemplateData.selectedVal = [that.templateData[0].monthDayRange[0]+'至'+that.templateData[0].monthDayRange[1]]
that.postTemplateData.selectedVal.push(`${that.templateData[0].monthDayRange[0]}${that.templateData[0].monthDayRange[1]}`)
}
if (code === 'tag015' && that.templateData.length === 1 && that.templateData[0].radio == 2){
// 天
......@@ -1194,7 +1194,7 @@ import qs from 'qs';
}
tagValue.val[0].data.compute = ele.postCompute;
tagValue.val[0].data.value = ele.numRange.join(',')
that.postTemplateData.selectedVal.push([ele.numRange[0]+'<='+ that.tagData.tagName +'<='+ ele.numRange[1]]);
that.postTemplateData.selectedVal.push(`${ele.numRange[0]} <= ${that.tagData.tagName} <= ${ele.numRange[1]}`);
}
// 固定/最近
if (ele.templateCode === 'tag004') {
......@@ -1203,13 +1203,13 @@ import qs from 'qs';
if (ele.fixedRecentRadio == 1) {
tagValue.time[0].type = 'between';
tagValue.time[0].value = ele.fixedRecentRangeValue.join(',')
that.postTemplateData.selectedVal.push([ele.fixedRecentRangeValue[0]+'至'+ele.fixedRecentRangeValue[1]]);
that.postTemplateData.selectedVal.push(`时间范围为${ele.fixedRecentRangeValue[0]}${ele.fixedRecentRangeValue[1]}`);
}
// tagValue.val[0].data.compute = ele.postCompute;
if (ele.fixedRecentRadio == 2) {
tagValue.time[0].type = 'lastday';
tagValue.time[0].value = String(ele.fixedRecentTimeRecent);
that.postTemplateData.selectedVal.push(`最近 ${ele.fixedRecentTimeRecent} 天`);
that.postTemplateData.selectedVal.push(`时间范围为最近 ${ele.fixedRecentTimeRecent} 天`);
}
}
......@@ -1218,20 +1218,20 @@ import qs from 'qs';
if (ele.timeRecent === '') { returnFlag = false }
tagValue.time[0].type = ele.timeType;
tagValue.time[0].value = String(ele.timeRecent);
that.postTemplateData.selectedVal.push( `最近 ${ele.timeRecent} 天`);
that.postTemplateData.selectedVal.push( `时间范围为最近 ${ele.timeRecent} 天`);
}
// 之后 天
if (ele.templateCode === 'tag006') {
if (ele.timeAfter === '') { returnFlag = false }
tagValue.time[0].type = ele.timeType;
tagValue.time[0].value = String(ele.timeAfter);
that.postTemplateData.selectedVal.push( `之后 ${ele.timeAfter} 天`);
that.postTemplateData.selectedVal.push( `时间范围为之后 ${ele.timeAfter} 天`);
}
// 下拉搜索添加值
if (ele.templateCode === 'tag008') {
if (!ele.addSelectTags.length) { returnFlag = false }
tagValue.val[0].data.value = ele.addSelectTags.map(item=>item.key).join(',')
that.postTemplateData.selectedVal.push(ele.addSelectTags.map(item=>item.value))
that.postTemplateData.selectedVal.push(ele.addSelectTags.map(item=>item.value).join(','))
}
// 多选项(城市选择) ( 全部选项/已选选项 )
......@@ -1239,7 +1239,7 @@ import qs from 'qs';
console.log(ele.citySelectedOptions)
if (!ele.citySelectedOptions.length) { returnFlag = false }
tagValue.val[0].data.value = ele.citySelectedOptions.map(item=>item.cityId).join(',')
that.postTemplateData.selectedVal = ele.citySelectedOptions.map(item=>item.selected)
that.postTemplateData.selectedVal.push(ele.citySelectedOptions.map(item=>item.selected).join(','))
}
// 门店
if (ele.templateCode === 'tag011') {
......@@ -1277,12 +1277,13 @@ import qs from 'qs';
that.postTemplateData.selectedVal.push(el.value)
}
})
that.postTemplateData.selectedVal.push(that.postTemplateData.selectedVal.join(','))
}
}
//
// })
}
console.log(returnFlag)
// console.log(returnFlag)
if (!returnFlag) {
that.$message.error({ message: '请完善标签值'})
return false;
......@@ -2274,8 +2275,17 @@ import qs from 'qs';
margin-left: 0;
}
}
&.all-select-options__city {
.el-checkbox-group {
max-height: 500px;
overflow-y: auto;
}
}
}
.slected-opyions {
.el-tag {
background: none;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment