Commit 487f5944 by liuchenxi

Merge branch 'feature/4月会员分组'

# Conflicts:
#	dist/index.html
#	dist/static/css/app.86dadc94fb716b5388f4dd4fab6de48a.css
#	dist/static/css/app.90aefd93a5af9fd111a7b0a697d9701c.css
#	dist/static/css/app.e6e700968c954dd3c0e2c667bd8ada51.css
#	dist/static/js/0.70593a1410b475fd2f9a.js
#	dist/static/js/0.9c95a8e1fa273411aa0d.js
#	dist/static/js/0.ee8213667463b1cfa618.js
#	dist/static/js/3.455cb5dcc438275910ee.js
#	dist/static/js/app.030ec1407d3e185b47d0.js
#	dist/static/js/app.8deb904c0bd80066dd28.js
#	dist/static/js/app.d2b294503428f3d76dd9.js
#	dist/static/js/manifest.150fe99f19bc86991dda.js
#	src/components/tagDetail/mixin/index.js
parents e7a2ba9c 0e16c9b2
<<<<<<< HEAD
<!DOCTYPE html><html><head><meta charset=utf-8><link rel="shortcut icon" href=./static/img/favicon.ico><title></title><link rel=stylesheet href=//at.alicdn.com/t/font_688955_99jmfacmlpp.css><link rel=stylesheet href=//at.alicdn.com/t/font_3276801_mkhlaisq2aq.css><script src=//at.alicdn.com/t/font_3276801_w3vkjjmzzz.js></script><link rel="shortcut icon" href=./favicon.ico><link href=./static/css/app.86dadc94fb716b5388f4dd4fab6de48a.css rel=stylesheet></head><body style="background-color: #f0f2f5;min-width: 1400px;"><div id=app><div class=el-loading-spinner style="width: 98%;"><svg viewBox="25 25 50 50" class=circular><circle cx=50 cy=50 r=20 fill=none class=path></circle></svg></div></div><script>(function() {
=======
<!DOCTYPE html><html><head><meta charset=utf-8><link rel="shortcut icon" href=./static/img/favicon.ico><title></title><link rel=stylesheet href=//at.alicdn.com/t/font_688955_99jmfacmlpp.css><link rel=stylesheet href=//at.alicdn.com/t/font_3276801_mkhlaisq2aq.css><script src=//at.alicdn.com/t/font_3276801_w3vkjjmzzz.js></script><link rel="shortcut icon" href=./favicon.ico><link href=./static/css/app.90aefd93a5af9fd111a7b0a697d9701c.css rel=stylesheet></head><body style="background-color: #f0f2f5;min-width: 1400px;"><div id=app><div class=el-loading-spinner style="width: 98%;"><svg viewBox="25 25 50 50" class=circular><circle cx=50 cy=50 r=20 fill=none class=path></circle></svg></div></div><script>(function() {
>>>>>>> feature/4月会员分组
var src = '/component/static/import-component.js?timestrap='+ new Date().getTime();
var host = window.location.host;
host = host.indexOf('localhost') > -1 || host.indexOf('192.168') > -1 ? 'gicdev.demogic.com' : host;
document.write('<script src="//'+ host + src +'"><\/script>')
})()</script><script src=//web-1251519181.file.myqcloud.com/components/track.1.0.4.js></script><script src=//web-1251519181.file.myqcloud.com/components/pagination.1.0.8.js></script><script type=text/javascript src=./static/js/manifest.150fe99f19bc86991dda.js></script><script type=text/javascript src=./static/js/vendor.ecce21da6a46da8c2fc4.js></script><script type=text/javascript src=./static/js/app.030ec1407d3e185b47d0.js></script></body></html>
\ No newline at end of file
<<<<<<< HEAD
})()</script><script src=//web-1251519181.file.myqcloud.com/components/track.1.0.4.js></script><script src=//web-1251519181.file.myqcloud.com/components/pagination.1.0.8.js></script><script type=text/javascript src=./static/js/manifest.150fe99f19bc86991dda.js></script><script type=text/javascript src=./static/js/vendor.ecce21da6a46da8c2fc4.js></script><script type=text/javascript src=./static/js/app.030ec1407d3e185b47d0.js></script></body></html>
=======
})()</script><script src=//web-1251519181.file.myqcloud.com/components/track.1.0.4.js></script><script src=//web-1251519181.file.myqcloud.com/components/pagination.1.0.8.js></script><script type=text/javascript src=./static/js/manifest.61219aab2da47cd7b339.js></script><script type=text/javascript src=./static/js/vendor.ecce21da6a46da8c2fc4.js></script><script type=text/javascript src=./static/js/app.d2b294503428f3d76dd9.js></script></body></html>
>>>>>>> feature/4月会员分组
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.
webpackJsonp([19],{AtEn:function(t,e){},YPWR:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o={name:"App",data:function(){return{projectName:"member-tag",contentHeight:"0px",collapseFlag:!1,leftModulesName:"会员标签"}},methods:{toRouterView:function(t){this.$router.push({path:t.path})},collapseTag:function(t){this.collapseFlag=t}},watch:{},mounted:function(){this.pathName=window.location.hash.split("/")[1],this.contentHeight=(document.documentElement.clientHeight||document.body.clientHeight)-64+"px"},components:{}},i={render:function(){var t=this.$createElement,e=this._self._c||t;return e("div",{attrs:{id:"index"}},[e("vue-gic-header",{attrs:{projectName:this.projectName,collapseFlag:this.collapseFlag},on:{collapseTag:this.collapseTag,toRouterView:this.toRouterView}}),this._v(" "),e("div",{staticClass:"content",attrs:{id:"content"}},[e("div",{staticClass:"content-body",style:{height:this.contentHeight}},[e("transition",{attrs:{name:"fade",mode:"out-in"}},[e("router-view")],1)],1)])],1)},staticRenderFns:[]};var a=n("VU/8")(o,i,!1,function(t){n("AtEn")},null,null);e.default=a.exports}});
\ No newline at end of file
webpackJsonp([20],{AtEn:function(t,e){},YPWR:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o={name:"App",data:function(){return{projectName:"member-tag",contentHeight:"0px",collapseFlag:!1,leftModulesName:"会员标签"}},methods:{toRouterView:function(t){this.$router.push({path:t.path})},collapseTag:function(t){this.collapseFlag=t}},watch:{},mounted:function(){this.pathName=window.location.hash.split("/")[1],this.contentHeight=(document.documentElement.clientHeight||document.body.clientHeight)-64+"px"},components:{}},i={render:function(){var t=this.$createElement,e=this._self._c||t;return e("div",{attrs:{id:"index"}},[e("vue-gic-header",{attrs:{projectName:this.projectName,collapseFlag:this.collapseFlag},on:{collapseTag:this.collapseTag,toRouterView:this.toRouterView}}),this._v(" "),e("div",{staticClass:"content",attrs:{id:"content"}},[e("div",{staticClass:"content-body",style:{height:this.contentHeight}},[e("transition",{attrs:{name:"fade",mode:"out-in"}},[e("router-view")],1)],1)])],1)},staticRenderFns:[]};var a=n("VU/8")(o,i,!1,function(t){n("AtEn")},null,null);e.default=a.exports}});
\ No newline at end of file
webpackJsonp([20],{"6Qob":function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var s=i("mvHQ"),n=i.n(s),o=i("5reh"),a=i("l6IN");function r(t){return t?(a.Message.warning(t),!1):(a.Message.warning("操作失败"),!1)}function l(t){return"cancel"==t?(a.Message.info(t||"cancel"),!1):!!t.hasOwnProperty("response")&&(401==t.response.status?(a.Message.error("登录过期"),!1):500==t.response.status?(a.Message.error("服务器错误500"),!1):void 0)}var c=i("mw3O"),u={name:"login",data:function(){return{redirect:this.$route.query.redirect,token:"",form:{loginName:"HAZZYS",password:"EA48576F30BE1669971699C09AD05C94",eid:"ff8080816494494b0164a76b553a00e5"}}},computed:{imgHeight:function(){return document.body.clientHeight},imgWidth:function(){return document.body.clientWidth}},methods:{loginAnimate:function(){new LoginAnimate(loginwrap,{length:90,LineWeight:.1,clicked:!0,moveon:!0}).Run()},submitLogin:function(){var t=this;this.axios.post("/api-auth/do-login",c.stringify({loginName:this.form.loginName,password:this.form.password,eid:"ff8080816494494b0164a76b553a00e5"})).then(function(e){if(e.data.success){(s=e.data.message)?a.Message.success(s):a.Message.success("操作成功");var i=decodeURIComponent(t.$route.query.redirect||"/index");t.$router.push({path:i})}else r(e.data.message);var s}).catch(function(t){l(t)})},getMenu:function(){var t=this;this.axios.get("/gic/get-menu").then(function(e){if(e.data.success){t.menuList=e.data.list,sessionStorage.setItem("menuList",n()(t.menuList));var i=t.$route.query.redirect||"/index";t.$router.push({path:i})}else r(e.data.errorMessage)}).catch(function(t){l(t)})}},mounted:function(){this.$store.commit(o.d,"login"),document.title=this.$store.state.title,this.loginAnimate()}},m={render:function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",{staticClass:"loginwrap",style:{height:t.imgHeight+"px"}},[i("div",{staticStyle:{position:"absolute",left:"0",height:"0",width:"100%"}},[i("canvas",{attrs:{id:"loginwrap",width:t.imgWidth,height:t.imgHeight}})]),t._v(" "),t._m(0),t._v(" "),i("div",{staticClass:"login_contetnt"},[i("h3",{staticClass:"login-top"},[t._v("让信息连接一切")]),t._v(" "),i("h4",{staticClass:"login-bottom"},[t._v("GIC商户后台")]),t._v(" "),i("div",{staticClass:"formlogin"},[i("el-form",{ref:"form",attrs:{model:t.form,"label-width":""}},[i("el-form-item",{attrs:{label:""}},[i("el-input",{staticClass:"forminput",attrs:{placeholder:"账号"},model:{value:t.form.loginName,callback:function(e){t.$set(t.form,"loginName",e)},expression:"form.loginName"}})],1),t._v(" "),i("el-form-item",{attrs:{label:""}},[i("el-input",{attrs:{type:"password",placeholder:"密码"},nativeOn:{keyup:function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"enter",13,e.key,"Enter")?null:t.submitLogin("form")}},model:{value:t.form.password,callback:function(e){t.$set(t.form,"password",e)},expression:"form.password"}})],1),t._v(" "),i("el-form-item",[i("button",{staticClass:"submit",on:{click:function(e){return e.preventDefault(),t.submitLogin("form")}}},[t._v("立即登录")])])],1)],1)])])},staticRenderFns:[function(){var t=this.$createElement,e=this._self._c||t;return e("div",{staticClass:"logintop"},[e("div",{staticClass:"fl loginlogo"},[e("a",{staticClass:"fr logo",attrs:{href:"#"}},[this._v("login_logo.png")])]),this._v(" "),e("a",{staticClass:"home-link fr",attrs:{href:"http://www.demogic.com/"}},[this._v("返回首页")])])}]};var d=i("VU/8")(u,m,!1,function(t){i("i8uS")},null,null);e.default=d.exports},i8uS:function(t,e){}});
\ No newline at end of file
webpackJsonp([21],{"6Qob":function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var s=i("mvHQ"),n=i.n(s),o=i("5reh"),a=i("l6IN");function r(t){return t?(a.Message.warning(t),!1):(a.Message.warning("操作失败"),!1)}function l(t){return"cancel"==t?(a.Message.info(t||"cancel"),!1):!!t.hasOwnProperty("response")&&(401==t.response.status?(a.Message.error("登录过期"),!1):500==t.response.status?(a.Message.error("服务器错误500"),!1):void 0)}var c=i("mw3O"),u={name:"login",data:function(){return{redirect:this.$route.query.redirect,token:"",form:{loginName:"HAZZYS",password:"EA48576F30BE1669971699C09AD05C94",eid:"ff8080816494494b0164a76b553a00e5"}}},computed:{imgHeight:function(){return document.body.clientHeight},imgWidth:function(){return document.body.clientWidth}},methods:{loginAnimate:function(){new LoginAnimate(loginwrap,{length:90,LineWeight:.1,clicked:!0,moveon:!0}).Run()},submitLogin:function(){var t=this;this.axios.post("/api-auth/do-login",c.stringify({loginName:this.form.loginName,password:this.form.password,eid:"ff8080816494494b0164a76b553a00e5"})).then(function(e){if(e.data.success){(s=e.data.message)?a.Message.success(s):a.Message.success("操作成功");var i=decodeURIComponent(t.$route.query.redirect||"/index");t.$router.push({path:i})}else r(e.data.message);var s}).catch(function(t){l(t)})},getMenu:function(){var t=this;this.axios.get("/gic/get-menu").then(function(e){if(e.data.success){t.menuList=e.data.list,sessionStorage.setItem("menuList",n()(t.menuList));var i=t.$route.query.redirect||"/index";t.$router.push({path:i})}else r(e.data.errorMessage)}).catch(function(t){l(t)})}},mounted:function(){this.$store.commit(o.d,"login"),document.title=this.$store.state.title,this.loginAnimate()}},m={render:function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",{staticClass:"loginwrap",style:{height:t.imgHeight+"px"}},[i("div",{staticStyle:{position:"absolute",left:"0",height:"0",width:"100%"}},[i("canvas",{attrs:{id:"loginwrap",width:t.imgWidth,height:t.imgHeight}})]),t._v(" "),t._m(0),t._v(" "),i("div",{staticClass:"login_contetnt"},[i("h3",{staticClass:"login-top"},[t._v("让信息连接一切")]),t._v(" "),i("h4",{staticClass:"login-bottom"},[t._v("GIC商户后台")]),t._v(" "),i("div",{staticClass:"formlogin"},[i("el-form",{ref:"form",attrs:{model:t.form,"label-width":""}},[i("el-form-item",{attrs:{label:""}},[i("el-input",{staticClass:"forminput",attrs:{placeholder:"账号"},model:{value:t.form.loginName,callback:function(e){t.$set(t.form,"loginName",e)},expression:"form.loginName"}})],1),t._v(" "),i("el-form-item",{attrs:{label:""}},[i("el-input",{attrs:{type:"password",placeholder:"密码"},nativeOn:{keyup:function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"enter",13,e.key,"Enter")?null:t.submitLogin("form")}},model:{value:t.form.password,callback:function(e){t.$set(t.form,"password",e)},expression:"form.password"}})],1),t._v(" "),i("el-form-item",[i("button",{staticClass:"submit",on:{click:function(e){return e.preventDefault(),t.submitLogin("form")}}},[t._v("立即登录")])])],1)],1)])])},staticRenderFns:[function(){var t=this.$createElement,e=this._self._c||t;return e("div",{staticClass:"logintop"},[e("div",{staticClass:"fl loginlogo"},[e("a",{staticClass:"fr logo",attrs:{href:"#"}},[this._v("login_logo.png")])]),this._v(" "),e("a",{staticClass:"home-link fr",attrs:{href:"http://www.demogic.com/"}},[this._v("返回首页")])])}]};var d=i("VU/8")(u,m,!1,function(t){i("i8uS")},null,null);e.default=d.exports},i8uS:function(t,e){}});
\ No newline at end of file
webpackJsonp([23],{EHeP:function(t,a,e){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("BdFv"),i=(e("Mk6G"),e("3E4D"),e("Ch4/"),e("PI0u"),e("P9l9"),{name:"myTagLib",data:function(){return{tagCategory:"myTagList"}},methods:{toAddMyTagLib:function(){}},mounted:function(){},components:{tagLib:n.a}}),s={render:function(){var t=this.$createElement,a=this._self._c||t;return a("div",{staticClass:"myTagLib-wrap common-wrap"},[a("div",{staticClass:"right-content"},[a("div",{staticClass:"right-box"},[a("tag-lib",{attrs:{tagCategory:this.tagCategory}})],1)])])},staticRenderFns:[]};var o=e("VU/8")(i,s,!1,function(t){e("NXvq")},"data-v-628de2d0",null);a.default=o.exports},NXvq:function(t,a){}});
\ No newline at end of file
webpackJsonp([24],{EHeP:function(t,a,e){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("BdFv"),i=(e("Mk6G"),e("3E4D"),e("Ch4/"),e("PI0u"),e("P9l9"),{name:"myTagLib",data:function(){return{tagCategory:"myTagList"}},methods:{toAddMyTagLib:function(){}},mounted:function(){},components:{tagLib:n.a}}),s={render:function(){var t=this.$createElement,a=this._self._c||t;return a("div",{staticClass:"myTagLib-wrap common-wrap"},[a("div",{staticClass:"right-content"},[a("div",{staticClass:"right-box"},[a("tag-lib",{attrs:{tagCategory:this.tagCategory}})],1)])])},staticRenderFns:[]};var o=e("VU/8")(i,s,!1,function(t){e("NXvq")},"data-v-628de2d0",null);a.default=o.exports},NXvq:function(t,a){}});
\ No newline at end of file
!function(e){var c=window.webpackJsonp;window.webpackJsonp=function(a,r,t){for(var b,o,d,i=0,u=[];i<a.length;i++)o=a[i],f[o]&&u.push(f[o][0]),f[o]=0;for(b in r)Object.prototype.hasOwnProperty.call(r,b)&&(e[b]=r[b]);for(c&&c(a,r,t);u.length;)u.shift()();if(t)for(i=0;i<t.length;i++)d=n(n.s=t[i]);return d};var a={},f={42:0};function n(c){if(a[c])return a[c].exports;var f=a[c]={i:c,l:!1,exports:{}};return e[c].call(f.exports,f,f.exports,n),f.l=!0,f.exports}n.e=function(e){var c=f[e];if(0===c)return new Promise(function(e){e()});if(c)return c[2];var a=new Promise(function(a,n){c=f[e]=[a,n]});c[2]=a;var r=document.getElementsByTagName("head")[0],t=document.createElement("script");t.type="text/javascript",t.charset="utf-8",t.async=!0,t.timeout=12e4,n.nc&&t.setAttribute("nonce",n.nc),t.src=n.p+"static/js/"+e+"."+{0:"ee8213667463b1cfa618",1:"a5b1143fb090193afa6f",2:"363b5142f0be0ffe6f9a",3:"455cb5dcc438275910ee",4:"fad46d33156e6afeecbf",5:"0f395a886b33ffa77a9a",6:"84144a26d97167c03b89",7:"cbfb1c1422fe6c812024",8:"891bbc4365b8362d5195",9:"7cc1b38988e254182ad8",10:"1cbc7e505ef918253196",11:"cfa61640d1a3d8d26b48",12:"627b84a8deefd3515526",13:"a7457f18ef15d320b80c",14:"ea35b721a975949e21f9",15:"7f3864d659b15b05f7ea",16:"fd8e0aca022b16e268de",17:"edc3cc3dd7cd59974a35",18:"cfdc70af6a4d0ba00e02",19:"2b51bcd6bcb234699455",20:"98315f191344b8c65188",21:"1f6367e5dcf6de69a5bd",22:"4985a38ec89a12ab291d",23:"60311edadffd29177d1f",24:"ee5a8baed163b78150c1",25:"5ac24c863c71cc9e9d97",26:"6b02cfff60b50e5fc4f1",27:"739a35f148a9eb505125",28:"c1335f07037eb9226047",29:"14f81ba933c5f226b3e1",30:"b94d7e8d819f8d860023",31:"1b6daea2c89c92c8aa77",32:"0b93cbabeb545ac94ca1",33:"94cb64e271f6c931f454",34:"34bc9f66094e5019fbd6",35:"8ac5700a552e1de85952",36:"02247c7a9eccdb1b9dee",37:"fd86faa4c3c1209b3d18",38:"4eb49e066fba130c61f9",39:"b99f2a7f59ecc2da15aa"}[e]+".js";var b=setTimeout(o,12e4);function o(){t.onerror=t.onload=null,clearTimeout(b);var c=f[e];0!==c&&(c&&c[1](new Error("Loading chunk "+e+" failed.")),f[e]=void 0)}return t.onerror=t.onload=o,r.appendChild(t),a},n.m=e,n.c=a,n.d=function(e,c,a){n.o(e,c)||Object.defineProperty(e,c,{configurable:!1,enumerable:!0,get:a})},n.n=function(e){var c=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(c,"a",c),c},n.o=function(e,c){return Object.prototype.hasOwnProperty.call(e,c)},n.p="./",n.oe=function(e){throw console.error(e),e}}([]);
\ No newline at end of file
......@@ -4,9 +4,9 @@
<meta charset="utf-8">
<link rel="shortcut icon" href="./static/img/favicon.ico"/>
<title></title>
<link rel="stylesheet" href="//at.alicdn.com/t/font_688955_99jmfacmlpp.css">
<link rel="stylesheet" href="//at.alicdn.com/t/font_3276801_mkhlaisq2aq.css">
<script src="//at.alicdn.com/t/font_3276801_w3vkjjmzzz.js"></script>
<link rel="stylesheet" href="//at.alicdn.com/t/font_688955_2dxzdzrb3a7.css">
<link rel="stylesheet" href="//at.alicdn.com/t/font_3276801_5bjk41qthxj.css">
<script src="//at.alicdn.com/t/font_3276801_5bjk41qthxj.js"></script>
</head>
<body style="background-color: #f0f2f5;min-width: 1400px;">
......
......@@ -36,9 +36,12 @@ export default {
if (res.data.errorCode == 0) {
const uId = res.data.result && res.data.result.userId;
const isSuperAdmin = res.data.result && res.data.result.superAdmin;
// 部门权限,1可见本人,2可见部门,3可见所有
const departAuth = res.data.result && res.data.result.departAuth;
const enableAccessControl = res.data.result && res.data.result.enableAccessControl;
this.$store.commit('changeSuperAdmin', isSuperAdmin);
this.$store.commit('changeEnableAccess', enableAccessControl);
this.$store.commit('changeSuperAdmin', isSuperAdmin);
this.$store.commit('changeDepartAuth', departAuth);
if (this.uniqueId === '') {
this.$store.commit('changeUniqueId', uId);
}
......
......@@ -3,9 +3,10 @@
<el-popover placement="top-start" trigger="hover" content="一键清除废弃标签值">
<div slot="reference" class="trash" @click="dialogVisible = true">
<!-- $store.state.delTrashNum 该值在活动标签和手工标签列表删除里也有更新 -->
<el-badge :value="$store.state.delTrashNum > 99 ? '99+' : $store.state.delTrashNum" class="badge">
<el-badge v-if="$store.state.delTrashNum != 0" :value="$store.state.delTrashNum > 99 ? '99+' : $store.state.delTrashNum" class="badge">
<i class="iconfont icon-delete trashIcon"></i>
</el-badge>
<i v-else class="iconfont icon-delete trashIcon" />
</div>
</el-popover>
<el-dialog title="删除标签" :visible.sync="dialogVisible" width="600px" @open="dialogOpen" @closed="dialogClosed">
......@@ -119,7 +120,7 @@ export default {
.trash {
position: fixed;
right: 29px;
bottom: 370px;
bottom: 335px;
height: 44px;
z-index: 10;
display: flex;
......
<template>
<div class="flex m-t-20 tags">
<div class="flex tags">
<div v-for="(tags, index) in tagsListFilter" :key="tags" :style="`width: ${100 / tagsList.length}%`" class="tag-group">
<ul class="tag-list">
<li class="tag-item" v-for="tag in tags" :key="tag.tagId">
......
<template>
<el-dialog title="" width="400px" top="30vh" custom-class="cre-dialog" :visible.sync="batchDialog" center :modal-append-to-body="false" :before-close="closeBatch">
<el-dialog title="" width="416px" top="30vh" custom-class="cre-dialog" :visible.sync="batchDialog" center :modal-append-to-body="false" :before-close="closeBatch">
<p class="tips" slot="title">{{ operNum == 0 ? '批量失效' : operNum == 1 ? '批量删除' : '修改所属分类' }}</p>
<div class="batch-content">
<div v-if="operNum == 0">
<div class="el-message-box__status el-icon-warning"></div>
<p class="batch-txt">该分组失效后,不再更新数据,确认要失效吗?</p>
</div>
<div v-if="operNum == 1">
<div class="el-message-box__status el-icon-warning"></div>
<p class="batch-txt">一旦删除无法恢复,其对应的固化人群也会删除,确认要批量删除分组吗?</p>
</div>
<div v-if="operNum == 2">
<p class="title">
我的会员分组
</p>
<div v-if="[0,1].includes(operNum)" class="el-message-box__status el-alert__icon el-icon-warning is-big icon"></div>
<div v-loading="loading">
<div class="batch-content">
<div v-if="operNum == 0">
<p class="batch-txt">{{ list.length ? '存在分组正在被以下模块使用,失效后使用该分组的活动将匹配不到分组下的人群并且分组客户数据将同步清空,是否继续处理为失效?' : '失效后非实时分组客户数据将同步清空,是否继续处理为失效?'}}</p>
</div>
<div v-if="operNum == 1">
<p class="batch-txt">{{ list.length ? '存在分组正在被以下模块使用,请先删除对应的内容后再来删除分组。' : '删除后无法恢复,确认要删除该分组吗?' }}</p>
</div>
<div v-if="operNum == 2">
<p class="title">
我的会员分组
</p>
<ul class="batch-ul">
<li v-for="(item, i) in groupList" :key="item.memberTagGroupClassifyId" class="batch-li" :class="{'active-li': i == listIndex}" @click="chooseGroup(item, i)">
{{ item.classifyName }}
</li>
</ul>
<p class="group-name">选中的分组:{{ groupName }}</p>
<ul class="batch-ul">
<li v-for="(item, i) in groupList" :key="item.memberTagGroupClassifyId" class="batch-li" :class="{'active-li': i == listIndex}" @click="chooseGroup(item, i)">
{{ item.classifyName }}
</li>
</ul>
<p class="group-name">选中的分组:{{ groupName }}</p>
</div>
<template v-if="operNum == 0 || operNum == 1">
<p v-for="(item, index) in list" :key="index" class="item">
{{ item.groupName }}<a :href="item.businessLink" target="_blank" @click="isOpenPage = true">{{ item.businessModuleName }}-{{ item.businessName }}</a>
</p>
</template>
</div>
</div>
<div class="cre-btn">
<el-button @click="closeBatch">取 消</el-button>
<el-button type="primary" @click="confirmBatch">确 定</el-button>
<div class="cre-btn" v-if="!(operNum == 1 && list.length)">
<el-button @click="closeBatch">取 消</el-button>
<el-button type="primary" @click="confirmBatch">{{ !operNum ? '失 效' : operNum == 1 ? '删 除' : '确 定'}}</el-button>
</div>
</div>
<!-- <span slot="footer" class="dialog-footer">
<el-button @click="closeBatch">取 消</el-button>
<el-button type="primary" @click="confirmBatch">确 定</el-button>
</span> -->
</el-dialog>
</template>
<script>
import { memberGroupList, batchModifyEffective, batchDeleteGroup, batchChangeGroup, batchDeleteGroupVerify } from '@/request/api';
import { memberGroupList, getGroupUseList, batchModifyEffective, batchDeleteGroup, batchChangeGroup } from '@/request/api';
import errMsg from '@/common/js/error';
export default {
name: 'batch-list',
......@@ -54,13 +56,14 @@ export default {
operNum: -1,
groupList: [],
groupName: '',
listIndex: -1
listIndex: -1,
list: [],
loading: false
};
},
methods: {
confirmBatch() {
console.log(this.operateNumber);
let batchNum = this.operateNumber;
let tagIds = this.selectionList.map(el => el.memberTagGroupId);
const param = {
......@@ -77,23 +80,21 @@ export default {
message: '修改成功'
});
}
this.$emit('submit');
})
.catch(err => {
console.log(err);
});
} else if (batchNum == 1) {
batchDeleteGroupVerify(param).then(res => {
if (res.errorCode != 1) return;
if ((res.result || []).length) return this.$emit('after-del', res.result);
batchDeleteGroup(param).then(res => {
if (res.errorCode == 1) {
(res.result || []).length || this.$message.success({
message: '删除成功'
});
this.$emit('after-del', res.result);
}
});
})
batchDeleteGroup(param).then(res => {
if (res.errorCode == 1) {
(res.result || []).length || this.$message.success({
message: '删除成功'
});
this.$emit('after-del', res.result)
this.$emit('submit', res.result);
}
});
} else if (batchNum == 2) {
if (!this.groupName) {
this.$message.warning({
......@@ -110,6 +111,7 @@ export default {
message: '修改分类成功'
});
}
this.$emit('submit');
})
.catch(err => {
console.log(err);
......@@ -144,7 +146,26 @@ export default {
.catch(err => {
console.log(err);
});
}
},
checkGroup() {
this.loading = true;
let tagIds = this.multipleSelection;
const params = {
memberTagGroupIds: tagIds.map(el => el.memberTagGroupId).toString(),
requestProject: 'gic-member-tag-web',
operateType: this.operateNumber == 0 ? 1 : this.operateNumber == 1 ? 2 : null
};
getGroupUseList(params).then(res => {
const { errorCode, result } = res;
if (errorCode === 1) {
this.list = result || [];
return;
}
errMsg.errorMsg(res.data);
}).catch(err => {
console.log(err);
}).finally(() => this.loading = false);
},
},
created() {
......@@ -153,6 +174,7 @@ export default {
watch: {
batchVisiable(newval) {
newval && [1,0].includes(this.operateNumber) && this.checkGroup();
this.batchDialog = newval;
this.getMemberGroupList();
},
......@@ -173,6 +195,8 @@ export default {
.batch-txt {
padding-left: 35px;
padding-top: 7px;
color: #303133;
line-height: 20px;
}
.batch-title {
color: #333;
......@@ -182,6 +206,13 @@ export default {
font-size: 14px;
font-weight: bold;
}
.item {
padding-left: 34px;
margin-top: 16px;
}
a {
color: #2f54eb;
}
.batch-ul {
overflow-y: auto;
max-height: 200px;
......@@ -208,4 +239,17 @@ export default {
font-size: 14px;
color: #2F54EB;
}
.item:not(:last-of-type) {
margin-bottom: 10px;
}
a {
color: #2f54eb;
}
.icon {
font-size: 18px;
position: absolute;
color: #fa8c16;
left: 21px;
top: 74px;
}
</style>
......@@ -362,10 +362,13 @@ export default {
return false;
}
if (code === 'tag001' && that.templateData.length === 1) {
let value = that.templateData[0].checkeditems;
if (!Array.isArray(value)) value = new Array(value);
tagValue.val[0].data.compute = that.templateData[0].postCompute;
tagValue.val[0].data.value = that.templateData[0].checkeditems.join(' ');
tagValue.val[0].data.value = value.join(' ');
that.templateData[0].options.forEach(function(ele, index) {
if (that.templateData[0].checkeditems.indexOf(ele.key) != -1) {
console.log(value, ele);
if (value.includes(ele.key)) {
that.postTemplateData.selectedVal.push(ele.value);
}
});
......@@ -437,9 +440,9 @@ export default {
tagValue.val[0].data.compute = that.templateData[0].compute;
const checkeditems = this.templateData[0].checkeditems.map(el => el);
this.templateData[0].options.forEach((ele, index) =>{
if (checkeditems.indexOf(ele.memberTagGradeId) != -1) {
this.postTemplateData.selectedVal.push(ele.aliasName);
itemArr.push(ele.memberTagGradeId);
if (checkeditems.indexOf(ele.memberTagGroupId) != -1) {
this.postTemplateData.selectedVal.push(ele.groupName);
itemArr.push(ele.memberTagGroupId);
}
});
this.templateData[0].checkeditems = itemArr;
......@@ -541,7 +544,6 @@ export default {
if ((code === 'tag014' || code === 'tag017' || code === 'tag019' || code === 'tag020' || code === 'tag015')) {
for (let k of this.templateData) {
console.log(k);
if (!k.timeChecked && !k.timeAfterChecked && k.radio == 2) {
let tips = k.timeRadio == 1 ? '天' : k.timeRadio == 2 ? '月' : '年';
this.$message.warning({
......@@ -571,11 +573,18 @@ export default {
tagValue.val[0].data.value = that.templateData[0].dateRangeValue.join(',');
that.templateData[0].timeInput = '';
if (code === 'tag019' || code === 'tag020' || code === 'tag015') {
tagValue.val[0].data.value = that.templateData[0].dateRangeValue
.join(',')
.replace(/-/g, '')
.replace(/:/g, '')
.replace(/\s+/g, '');
if (code === 'tag020') {
tagValue.val[0].data.value = that.templateData[0].dateRangeValue.map(el => {
return el.split(' ')[0];
}).join(',').replace(/-/g, '')
console.log(tagValue.val[0].data.value);
} else {
tagValue.val[0].data.value = that.templateData[0].dateRangeValue
.join(',')
.replace(/-/g, '')
.replace(/:/g, '')
.replace(/\s+/g, '');
}
}
that.postTemplateData.selectedVal.push(that.templateData[0].dateRangeValue[0].split(' ')[0] + '至' + that.templateData[0].dateRangeValue[1].split(' ')[0]);
}
......@@ -863,8 +872,8 @@ export default {
}
/* 属于/不属于+ 选项 */
if (that.templateData.length == 2) {
if (that.templateData.length == 2) {
for (let ele of that.templateData) {
// 选项
if (ele.templateCode === 'tag001') {
......@@ -956,6 +965,7 @@ export default {
tagValue.val[0].data.value = '';
}else{
tagValue.val[0].data.value = ele.addSelectTags.map(item => item.key||item.id).join(' ');
tagValue.val[0].data.label = ele.addSelectTags.map(item => item.clerkName).join(' ');
that.postTemplateData.selectedVal.push(ele.addSelectTags.map(item => item.value).join(','));
}
}
......@@ -1251,9 +1261,11 @@ export default {
tagValue: JSON.stringify(tagValue), // 标签选择保存值
tagParams: JSON.stringify(tagParams) // 标签前端选择
};
const { type } = this.$route.query;
para.pageType = type === 'fixed' ? 2 : 1;
postRequest('/member-tag-value/add.json', para)
.then(res => {
let resData = res.data;
.then(res => {
let resData = res.data;
if (resData.errorCode == 1) {
this.successAdd = true;
if (that.tabActive != 'second') {
......@@ -1265,7 +1277,6 @@ export default {
that.closeTagShortDialog();
// 如果来源是 会员标签编辑的时候
// if (that.fromFlag == 'memberGroup') {
// console.log(tagParams, JSON.stringify(tagParams));
let sendObj = {
tagId: that.tagShortId || this.tagId,
tagValue: JSON.stringify(tagValue),
......@@ -1275,10 +1286,12 @@ export default {
templateCode: this.templateCode
};
this.$emit('returnTagData', sendObj);
}else {
this.$message.error(resData.message)
}
})
.catch(function(error) {
this.$message.error(error.message)
});
},
......@@ -1289,9 +1302,11 @@ export default {
if (val) {
item.checkeditems = [];
item.options.forEach(function(el, index) {
if (item.templateCode === 'tag021' || item.templateCode === 'tag022') {
if (item.templateCode === 'tag021') {
item.checkeditems.push(el.memberTagGroupId);
} else if (item.templateCode == 'tag022') {
item.checkeditems.push(el.memberTagGradeId);
} else {
}else {
item.checkeditems.push(el.key);
}
});
......@@ -1353,13 +1368,16 @@ export default {
*/
toEditInput(e, tag, item) {
let newNum;
newNum = !!parseInt(String(e.target.value).replace(/[^\d]/g, '')) ? parseInt(String(e.target.value).replace(/[^\d]/g, '')) : 1;
newNum = Number(e.target.value) ? Math.floor(e.target.value) : 1;
if (newNum <= 0) {
newNum = 1;
}
if (newNum > 365) {
if (tag != 'fixedRecentTimeRecent' && newNum > 365) {
newNum = 365;
}
if (tag == 'fixedRecentTimeRecent' && newNum > 730) {
newNum = 730;
}
item[tag] = newNum;
},
/**
......@@ -1390,15 +1408,19 @@ export default {
* 天/月/年输入
*/
toEditDateInput(e, radio, parent) {
const code = parent.templateCode;
let newNum;
newNum = !!parseInt(String(e.target.value).replace(/[^\d]/g, '')) ? parseInt(String(e.target.value).replace(/[^\d]/g, '')) : 1;
newNum = Number(e.target.value) ? Math.floor(e.target.value) : 1;
if (newNum <= 0) {
newNum = 1;
}
// 天
if (newNum > 365 && radio == 1) {
if (code != 'tag020' && newNum > 365 && radio == 1) {
newNum = 365;
}
if (code == 'tag020' && newNum > 730 && radio == 1) {
newNum = 730;
}
// 月
if (newNum > 24 && radio == 2) {
newNum = 24;
......@@ -1461,19 +1483,24 @@ export default {
},
/* eslint-disable */
changeRemoteMethod(item) {
// let tagsMap = null;
item.addSelectTags = item.searchOptions.filter(el => item.searchModel.includes(el.clerkId));
// if (!!item.addSelectTags.length) {
// tagsMap = item.addSelectTags.map(item => item.value);
// }
// item.searchOptions.forEach(function(ele, index) {
// if (!!tagsMap && tagsMap.indexOf(ele.value) != -1) {
// return false;
// }
// if (item.searchModel.indexOf(ele.key) != -1) {
// item.addSelectTags.push(ele);
// }
// });
const echoData = item.addSelectTags.filter(el => item.searchModel.includes(el.clerkName));
// 这一步的searchModel存的是回显的clerkName和新增的clerkId
const newData = item.searchOptions.filter(el => item.searchModel.includes(el.clerkId));
const map = {};
[].concat(echoData, newData).forEach(el => {
const clerkId = el.clerkId;
if (map[clerkId]) {
map[clerkId].count++;
} else {
map[clerkId] = {
count: 1,
origin: el
}
}
})
const resData = Object.values(map).filter(el => el.count == 1).map(el => el.origin);
item.addSelectTags = resData;
item.searchModel = resData.map(el => el.clerkName);
},
removeRemoteMethod(val, item) {
item.addSelectTags = item.addSelectTags.filter(el => el.clerkId != val);
......@@ -1887,7 +1914,7 @@ export default {
return false;
}
that.templateData.push(that[resData.result.templateCode]);
console.log('that.templateData===>',that.templateData)
/**
* 这里处理编辑回显数据
* 这里拿到编辑的数据 然后把tagValue的value值传解析传给模板的v-model
......@@ -1895,6 +1922,7 @@ console.log('that.templateData===>',that.templateData)
*/
setTimeout(_ => {
this.templateCode = this.templateData.map(el => el.templateCode);
if (this.templateDataList.editCondition) {
this.replaceTemplateValue();
} else {
......
......@@ -140,6 +140,14 @@ export const batchModifyEffective = params =>
params: params
});
// 失效分组引用校验
export const batchDeactiveGroupVerify = params =>
request({
url: '/member-tag-group/updateBatchVerify',
method: 'get',
params: params
});
// 删除分组校验
export const batchDeleteGroupVerify = params =>
request({
......@@ -156,6 +164,14 @@ export const batchDeleteGroup = params =>
params: params
});
// 获取引用列表
export const getGroupUseList = params =>
request({
url: '/member-tag-group/getGroupUseCondition ',
method: 'get',
params: params
});
// 分组归属
export const batchChangeGroup = params =>
request({
......
......@@ -133,7 +133,7 @@ export const constantRouterMap = [
title: '会员标签-会员分组',
keepAlive: true,
componentName: 'memberGroupList',
fromPath: ['/memberGroupEdit','/memberLevelDetail', '/memberGroupDetail']
fromPath: ['/memberGroupEdit','/memberLevelDetail', '/memberGroupDetail', '/memberGroupAdd']
}
},
{
......
......@@ -13,7 +13,8 @@ export default new Vuex.Store({
uniqueId: '',
isSuperAdmin: 0,
delTrashNum: 0,
enableAccessControl: 0
enableAccessControl: 0,
departAuth: 0
},
mutations: {
[types.LOGIN]: (state, data) => {
......@@ -45,5 +46,8 @@ export default new Vuex.Store({
['changeEnableAccess'](state, data) {
state.enableAccessControl = data;
},
['changeDepartAuth'](state, data) {
state.departAuth = data;
}
}
});
......@@ -209,7 +209,7 @@ export default {
components: {}
};
</script>
<style type="text/scss" lang="scss">
<style type="text/scss" lang="scss" scoped>
#index {
.content {
padding-top: 64px;
......
<template>
<el-dialog :visible.sync="visible" custom-class="delete-dialog" width="416px" :show-close="false">
<div class="content">
<div class="delete-dialog-content">
<i class="el-alert__icon el-icon-warning is-big icon" />
<h2>确认删除该标签吗?</h2>
<p class="desc">{{ desc }}</p>
......@@ -87,7 +87,7 @@ export default {
}
.delete-dialog {
position: relative;
.content {
.delete-dialog-content {
padding: 5px 10px 4px 50px;
h2 {
color: #303133;
......
......@@ -175,11 +175,11 @@
</template>
<!-- 开卡导购 -->
<template v-if="item.code == 'openClerkId'">
{{ scope.row.openClerkId }}
{{ scope.row.openClerkName || '--' }}
</template>
<!-- 专属导购 -->
<template v-if="item.code == 'clerkId'">
{{ scope.row.clerkId }}
{{ scope.row.clerkName || '--' }}
</template>
<!-- 会员状态 -->
<template v-if="item.code == 'frozenStatus'">
......
......@@ -76,7 +76,7 @@
></vue-gic-export-excel>
<!--表格字段-->
<dm-table-filed :visible.sync="tableFiledVisible" projectName="member-tag" pageName="memberTag" :max="20" :defaultDisabled="['memberName']" :checkedFields="checkFields" @submit="onSubmiTableFiled" />
<i id="aniIcon" class="iconfont icon-shougongbiaoqian aniIcon" :style="{ right: `${animationPos.x}px`, bottom: `${animationPos.y}px` }"></i>
<i id="aniIcon" class="iconfont icon-biaoqian aniIcon" :style="{ right: `${animationPos.x}px`, bottom: `${animationPos.y}px` }"></i>
<delete-tag-dialog :visible.sync="deleteTagDialog.visible" :data="deleteTagDialog.deleteData" @submit="delTagApi" />
</div>
</template>
......@@ -642,10 +642,23 @@ export default {
0% {
opacity: 1;
}
40% {
opacity: 1;
right: 37px;
bottom: 345px;
transform: scale(0.5);
}
50% {
opacity: 0.5;
right: 37px;
bottom: 345px;
transform: scale(1.2);
}
100% {
right: 30px;
bottom: 380px;
font-size: 12px;
opacity: 0.5;
right: 37px;
bottom: 345px;
transform: scale(0);
}
}
.tip {
......
......@@ -2151,6 +2151,7 @@ export default {
const para = {
widgetId: id
};
getRequest('/memberTag/findWidget', para)
.then(res => {
// console.log(res,res.data,res.data.errorCode)
......
......@@ -28,7 +28,7 @@
<el-input v-model="ruleForm.tagSort" placeholder="请输入1-100000之间的整数" class="w-full" @input="validateInputSort" @blur="blurSort" />
</el-form-item>
<el-form-item label="标签类型:" prop="tagType" v-if="currentType == 'manual'">
<el-radio-group v-model="ruleForm.tagType" :disabled="isEdit">
<el-radio-group v-model="ruleForm.tagType" :disabled="isEdit && isEchoCheck">
<el-radio :label="0">单选</el-radio>
<el-radio :label="1">多选</el-radio>
</el-radio-group>
......@@ -120,7 +120,8 @@ export default {
tagValTableData: [],
preSyncWmStatus: 0,
deleteList: [],
isEdit: false
isEdit: false,
isEchoCheck: false
};
},
watch: {
......@@ -287,6 +288,7 @@ export default {
this.ruleForm.tagSort = result.sort;
this.ruleForm.tagType = result.isMultiple;
this.ruleForm.tagValue = result.itemList || [];
this.isEchoCheck = result.isMultiple;
if (result.itemList.length) {
this.ruleForm.tagValue = result.itemList.map(el => {
el.id = GenNonDuplicateID();
......
......@@ -5,7 +5,7 @@
<i v-if="currentLength < 50" class="iconfont plus icon margin icon-PlusOutlined" @click="add" />
<i v-else class="icon margin" />
</template>
<i v-if="currentLength > 1" class="iconfont delete icon icon-delete" @click="del" />
<i v-if="currentLength > 1 && !item.tagItemId" class="iconfont delete icon icon-delete" @click="del" />
</div>
</template>
......
<template>
<div class="card-item">
<div class="card-item" @click="$emit('toDetail', data, index)">
<div class="left">
<p class="title">{{ title }}</p>
<span class="count" @click="$emit('toDetail', data, index)">
<span class="count">
{{ formatCount }}
<span></span>
</span>
......@@ -42,12 +42,16 @@ export default {
justify-content: space-between;
align-items: center;
min-width: 0;
cursor: pointer;
&:hover {
box-shadow: 0px 4px 8px 0px rgba(220, 223, 230, 0.6);
}
.count {
font-weight: bold;
color: #2f54eb;
font-size: 22px;
white-space: nowrap;
cursor: pointer;
font-family: DINAlternate-Bold, DINAlternate;
span {
font-size: 14px;
color: #303133;
......
<template>
<!-- 具体标签 -->
<div class="tag-some-list">
<el-table :data="tableData">
<el-table-column label="标签名称" prop="tagName" min-width="120">
<template slot-scope="scope">
<span class="tag-name">{{ scope.row.tagName }}</span>
<el-tooltip class="item" effect="dark" content="添加标签" placement="top">
<i class="iconfont icon-tag-name icon-PlusOutlined" v-if="getCodeAuth" :limit-code="getCode" v-track:common.click="handleTrackParam('addTag', scope.row)" @click="addTag(scope.row)"></i>
</el-tooltip>
</template>
</el-table-column>
<el-table-column v-if="type != 'system'" label="覆盖人数" prop="memberCount" min-width="140" show-overflow-tooltip>
<template slot="header">
覆盖人数
<el-popover width="260" trigger="hover" placement="top">
<div style="color: #303133;">
标签下不同标签值可能覆盖相同的会员,因此此处“标签”覆盖人数去重显示(如“喜欢的颜色-白、红、黑、蓝”,某会员身上可能同时具备“白、黑”二种标签值)
</div>
<i slot="reference" class="iconfont icon-QuestionCircleOutlined refresh"></i>
</el-popover>
</template>
<template slot-scope="scope">
{{ scope.row.memberCount ? (scope.row.memberCount | formatNum) + '人' : '--' }}
</template>
</el-table-column>
<el-table-column v-else label="是否实时" prop="isActive" min-width="40">
<template slot-scope="scope">
<span> {{ scope.row.isActive == 1 ? '实时' : '非实时' }} </span>
</template>
</el-table-column>
<el-table-column min-width="200" label="标签描述" prop="tagDescribe" show-overflow-tooltip>
<template slot-scope="scope">
{{ scope.row.tagDescribe || '--'}}
</template>
</el-table-column>
</el-table>
</div>
</template>
<script>
import Emitter from '@/mixins/emitter';
import tagDetails from '@/components/tagDetail/mixin/index';
export default {
name: 'tag-container',
mixins: [tagDetails, Emitter],
props: {
data: {
type: Array,
default() {
return [];
}
},
type: String,
refersh: Object
},
data() {
return {
tableData: [],
tagData: {}
};
},
methods: {
addTag(list) {
this.$emit('addTag', list);
},
handleTrackParam(type, data) {
let fn = {
addTag: () => {
return {
data: { id: data.tagId, name: data.tagName }
};
}
}[type];
return { fn: () => {}, data: fn ? fn() : {} };
}
},
watch: {
data: {
immediate: true,
handler(newval) {
this.tableData = newval;
}
},
refersh: {
immediate: true,
handler(newval) {
// 刷新
if (newval.changeRefersh) {
let index = this.tableData.findIndex(el => newval.tagId === el.tagId);
this.tableData[index].refersh = true;
}
}
}
},
computed: {
getCodeAuth() {
let code = 'memberTagCreateGroup';
return this.$getButtonLimit(this.$buttonCode[code]);
},
getCode() {
let code = 'memberTagCreateGroup';
return this.$buttonCode[code];
}
}
};
</script>
<style lang="scss" scoped>
.tag-some-list {
height: 430px !important;
margin-left: 20px;
overflow-y: auto;
}
.icon-tag-name {
display: inline-block;
vertical-align: bottom;
font-size: 16px;
cursor: pointer;
color: #303133;
transition: all 0.3s;
color: #2f54eb;
&:hover {
transform: scale(1.25);
}
}
.refresh {
color: #606266;
position: relative;
top: 1px;
}
</style>
<template>
<el-dialog :visible.sync="visible" custom-class="delete-dialog" width="416px" @close="onClose">
<div class="dialog-content">
<i class="el-alert__icon el-icon-warning is-big icon" />
<h2>{{ title }}</h2>
<div v-loading="loading">
<p class="desc">{{ desc }}</p>
<p v-for="(item, index) in list" :key="index" class="item">
<a :href="item.businessLink" target="_blank" @click="isOpenPage = true">{{ item.businessModuleName }}-{{ item.businessName }}</a>
</p>
<footer class="footer" v-if="!(type == 'delete' && list.length)">
<el-button class="ml10" @click="$emit('update:visible',false)">取消</el-button>
<el-button type="primary" @click="onSubmit">{{ type == 'deactive' ? '失效' : '删除' }}</el-button>
</footer>
</div>
</div>
</el-dialog>
</template>
<script>
import errMsg from '@/common/js/error';
import {
getGroupUseList
} from '@/request/api';;
export default {
props: {
visible: Boolean,
data: {
type: Object,
default: () => ({})
},
type: String,
title: String
},
data() {
return {
list: [],
isOpenPage: false,
loading: true
};
},
computed: {
desc() {
if (this.type == "deactive") {
return this.list.length ? '当前分组正在被以下模块使用,失效后使用该分组的活动将匹配不到分组下的人群并且分组客户数据将同步清空,是否继续处理为失效?' : '失效后非实时分组客户数据将同步清空,是否继续处理为失效?';
} else {
return this.list.length ? '当前分组正在被以下模块使用,请先删除对应的内容后再来删除分组。' : '删除后无法恢复,确认要删除该分组吗?';
}
}
},
methods: {
checkGroup() {
this.loading = true;
const params = {
memberTagGroupIds: this.data.memberTagGroupId,
requestProject: 'gic-member-tag-web',
operateType: this.type == 'deactive' ? 1 : 2
};
getGroupUseList(params).then(res => {
const { errorCode, result } = res;
if (errorCode === 1) {
this.list = result || [];
return;
}
errMsg.errorMsg(res.data);
}).finally(() => this.loading = false);
},
onClose() {
this.$emit('update:visible', false);
this.$emit('close');
},
onSubmit() {
this.$emit('update:visible', false);
this.$emit('submit', this.data, this.type);
},
subWindowChange() {
addEventListener('visibilitychange', this.visibleityWindowFn)
},
visibleityWindowFn() {
if (!document.hidden && this.isOpenPage) this.checkGroup();
}
},
watch: {
visible(newVal) {
newVal && this.checkGroup();
this.subWindowChange();
if (!newVal) {
removeEventListener('visibilitychange', this.visibleityWindowFn);
this.isOpenPage = false;
};
}
}
};
</script>
<style scoped lang="scss">
/deep/ .el-dialog__header {
padding: 0;
}
/deep/ .el-dialog__body {
padding-bottom: 20px;
}
.delete-dialog {
position: relative;
.dialog-content {
padding: 5px 10px 4px 50px;
h2 {
color: #303133;
font-weight: bold;
font-size: 16px;
margin-bottom: 9px;
}
.desc {
font-size: 14px;
font-weight: 400;
color: #303133;
line-height: 20px;
margin-bottom: 16px;
}
.item:not(:last-of-type) {
margin-bottom: 10px;
}
a {
color: #2f54eb;
}
.footer {
margin-top: 24px;
text-align: right;
}
}
}
.ml10 {
margin-left: 10px;
}
.icon {
font-size: 21px;
position: absolute;
color: #fa8c16;
left: 30px;
top: 22px;
}
</style>
......@@ -21,9 +21,10 @@
</div>
<span slot="footer" class="dialog-footer">
<el-button @click="handleClose">取 消</el-button>
<el-button type="primary" @click="handleSave" style="margin-bottom: 14px">确 定</el-button>
<el-button ref="animationStart" type="primary" @click="handleSave" style="margin-bottom: 14px">确 定</el-button>
</span>
</el-dialog>
<i id="aniIcon" class="iconfont icon-biaoqian aniIcon" :style="{ right: `${animationPos.x}px`, bottom: `${animationPos.y}px` }"></i>
</div>
</template>
......@@ -57,7 +58,8 @@ export default {
templateData: [],
tagDataAssgin: {},
templateObj: {},
isAddFlag: false
isAddFlag: false,
animationPos: {},
};
},
watch: {
......@@ -72,6 +74,16 @@ export default {
this.templateObj = newval;
}, 20);
}
},
showEditTagPop(newVal) {
if (!newVal) {
try {
const getStore = this.$refs.tagConfig.$refs.storeNew;
if (Array.isArray(getStore) && getStore[0].$children[1]) getStore[0].$children[1].popoverShow = false;
} catch(e) {
console.error(e);
}
}
}
},
// mixins: [tagDetails],
......@@ -79,21 +91,38 @@ export default {
handleClose() {
this.$emit('update:showEditTagPop', false);
},
handleSave() {
handleSave($event) {
const ret = this.$refs.tagConfig.getTemplateData();
this.templateData = JSON.parse(JSON.stringify(ret));
this.tagId = this.tagDataAssgin.tagId;
this.$refs.tagConfig.saveConfirm().then(res => {
if (res) {
this.startAnimation($event);
this.$emit('update:showEditTagPop', false);
this.$emit('refersh', this.tagDataAssgin);
}
});
}).catch(err => {
this.$message.error({
duration: 1000,
message: err.message
});
})
},
returnTagData(list) {
this.$emit('returnTagData', list);
}
},
startAnimation(e) {
this.animationPos = {
x: document.body.offsetWidth - e.pageX,
y: document.body.offsetHeight - e.pageY
}
console.log(document.body.offsetWidth, e.pageX);
document.querySelector('#aniIcon').style.display = 'block'
setTimeout(_ => {
document.querySelector('#aniIcon').style.display = 'none'
}, 1800)
},
}
};
</script>
......@@ -112,7 +141,10 @@ export default {
color: #303133;
.tag-flag {
margin-left: 6px;
padding: 3px 10px;
width: 44px;
height: 18px;
line-height: 18px;
text-align: center;
font-size: 12px;
border-top-right-radius: 5px;
border-bottom-left-radius: 5px;
......@@ -155,6 +187,38 @@ export default {
border-top: 1px solid #ebeef5;
}
}
.aniIcon {
display: none;
position: absolute;
z-index: 99999;
color: #2F54EB;
font-size: 26px;
animation: toTrash 3s;
opacity: 0;
}
@keyframes toTrash {
0% {
opacity: 1;
}
40% {
opacity: 1;
right: 35px;
bottom: 280px;
transform: scale(0.5);
}
50% {
opacity: 0.5;
right: 35px;
bottom: 280px;
transform: scale(1.2);
}
100% {
opacity: 0.5;
right: 35px;
bottom: 280px;
transform: scale(0);
}
}
</style>
<style>
/* tooltip */
......
<template>
<div id="index">
<!-- <div id="index"> -->
<transition name="fade" mode="out-in">
<!-- 缓存已经填好内容的页面 -->
<router-view></router-view>
</transition>
</div>
<!-- </div> -->
</template>
<script>
......@@ -193,85 +193,83 @@ export default {
};
</script>
<style type="text/scss" lang="scss">
#index {
.content {
padding-top: 64px;
/* height: calc(100% - 64px);
overflow-y: auto;*/
min-width: 1400px;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
.content-body {
display: flex;
overflow: hidden;
.right-wrap {
flex: 1;
overflow: auto;
.content {
padding-top: 64px;
/* height: calc(100% - 64px);
overflow-y: auto;*/
min-width: 1400px;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
.content-body {
display: flex;
overflow: hidden;
.right-wrap {
flex: 1;
overflow: auto;
width: 100%;
.right-content {
width: 100%;
.right-content {
width: 100%;
padding: 24px;
min-height: 615px;
.right-box {
/*background: #fff;*/
/*padding: 24px;*/
}
}
&.near-store-contain {
.right-content {
min-height: 570px;
}
padding: 24px;
min-height: 615px;
.right-box {
/*background: #fff;*/
/*padding: 24px;*/
}
/deep/ .el-tabs__nav {
z-index: 1;
}
&.near-store-contain {
.right-content {
min-height: 570px;
}
}
.content-body .left-menu {
-ms-flex: 0 0 200px;
flex: 0 0 200px;
width: 200px;
height: 100%;
background: #020b21;
transition: all 0.2s ease;
position: fixed;
z-index: 5;
/deep/ .el-tabs__nav {
z-index: 1;
}
}
.common-wrap {
position: relative;
width: 100%;
height: 100%;
overflow-y: auto;
.content-body .left-menu {
-ms-flex: 0 0 200px;
flex: 0 0 200px;
width: 200px;
height: 100%;
background: #020b21;
transition: all 0.2s ease;
position: fixed;
z-index: 5;
}
.right-content {
/*width: 100%;*/
padding: 24px;
min-height: calc(100% - 100px);
.common-wrap {
position: relative;
width: 100%;
height: 100%;
overflow-y: auto;
.right-box {
background: #fff;
padding: 24px;
}
.right-content {
/*width: 100%;*/
padding: 24px;
min-height: calc(100% - 100px);
.right-box {
background: #fff;
padding: 24px;
}
}
}
}
}
/deep/ .el-submenu__title {
height: 40px;
line-height: 40px;
}
/deep/ .el-submenu__title {
height: 40px;
line-height: 40px;
}
/* 表格为空 */
/deep/ .el-table__empty-block {
height: 256px;
}
/* 表格为空 */
/deep/ .el-table__empty-block {
height: 256px;
}
/* 隐藏 头部 */
......
.table-header__handle {
padding-right: 0 !important;
&.cell {
position: absolute !important;
top: 0;
......@@ -10,7 +11,6 @@
display: flex !important;
align-items: center;
justify-content: space-between;
.el-icon-setting {
display: flex;
justify-content: center;
......
......@@ -39,7 +39,7 @@
<span class="tips">开启后,立即更新至好办小程序</span>
<p>
<span v-for="item in haobanList" :key="item.memberTagGradeId" class="switch-item">
<span>{{ item.aliasName }}</span>
<span class="name">{{ item.aliasName }}</span>
<el-switch class="switch" v-model="item.hanbanShow" active-color="#2f54eb" @change="onChangeSwitch(item)" />
</span>
</p>
......@@ -71,26 +71,26 @@ export default {
methods: {
getTableHeader() {
this.tableHeader = [
{ label: '指标说明', prop: 'gradeDesc', minWidth: 160 },
{ label: '0-30(高活跃)', minWidth: 130, formatter(row) { return `<span style="color:#2f54eb;cursor:pointer">${row.itemList[0].memberCount }人</span>` }},
{ label: '31-90(活跃)', minWidth: 130, formatter(row) { return `<span style="color: #2f54eb;cursor:pointer">${row.itemList[1].memberCount }人</span>` } },
{ label: '91-180(边缘)', minWidth: 130, formatter(row) { return `<span style="color: #2f54eb;cursor:pointer">${row.itemList[2].memberCount }人</span>` } },
{ label: '181-1年(沉睡)', minWidth: 130, formatter(row) { return `<span style="color: #2f54eb;cursor:pointer">${row.itemList[3].memberCount }人</span>` } },
{ label: '1年-2年(流失)', minWidth: 130, formatter(row) { return `<span style="color: #2f54eb;cursor:pointer">${row.itemList[4].memberCount }人</span>` } },
{ label: '2年以上(Lost+)', minWidth: 140, formatter(row) { return `<span style="color: #2f54eb;cursor:pointer">${row.itemList[5].memberCount }人</span>` } },
{ label: '指标说明', prop: 'gradeDesc', minWidth: 180 },
{ label: '0-30(高活跃)', minWidth: 130, formatter(row) { return `<span style="color:#2f54eb;cursor:pointer;font-size:16px">${row.itemList[0].memberCount }人</span>` }},
{ label: '31-90(活跃)', minWidth: 130, formatter(row) { return `<span style="color: #2f54eb;cursor:pointer;font-size:16px">${row.itemList[1].memberCount }人</span>` } },
{ label: '91-180(边缘)', minWidth: 130, formatter(row) { return `<span style="color: #2f54eb;cursor:pointer;font-size:16px">${row.itemList[2].memberCount }人</span>` } },
{ label: '181-1年(沉睡)', minWidth: 130, formatter(row) { return `<span style="color: #2f54eb;cursor:pointer;font-size:16px">${row.itemList[3].memberCount }人</span>` } },
{ label: '1年-2年(流失)', minWidth: 130, formatter(row) { return `<span style="color: #2f54eb;cursor:pointer;font-size:16px">${row.itemList[4].memberCount }人</span>` } },
{ label: '2年以上(Lost+)', minWidth: 140, formatter(row) { return `<span style="color: #2f54eb;cursor:pointer;font-size:16px">${row.itemList[5].memberCount }人</span>` } },
]
},
async getHaoBanData() {
const res = await getRequest('/memberTagGrade/gradeListNew', {});
const { result } = res.data;
const { result = [] } = res.data;
this.haobanList = result;
},
async getTableList() {
this.loading = true;
const res = await getRequest('/memberTagGrade/gradeGroupListNew', {});
const { result } = res.data;
this.tableList = result.result.filter(el => el.gradeName != '未消费');
this.consumeList = result.result.find(el => el.gradeName == '未消费');
const { result = [] } = res.data;
this.tableList = result.result.filter(el => el.gradeName != '未消费') || [];
this.consumeList = result.result.find(el => el.gradeName == '未消费') || {};
this.loading = false;
},
async onChangeSwitch(item) {
......@@ -129,9 +129,11 @@ export default {
span:first-child {
text-align: right;
margin-right: 6px;
font-weight: bold;
}
span:last-of-type {
margin-left: 16px;
font-weight: bold;
}
.line {
position: absolute;
......@@ -168,7 +170,7 @@ export default {
margin-top: 16px;
& > span {
margin-left: 10px;
margin-right: 56px;
margin-right: 85px;
font-size: 14px;
}
}
......@@ -185,6 +187,10 @@ export default {
display: inline-block;
margin-right: 30px;
margin-bottom: 20px;
.name {
font-size: 14px;
color: #303133;
}
.switch {
margin-left: 14px;
}
......
<template>
<div :class="{ 'm-l-60': selectedTagsData.length > 1 }">
<tags-group
v-for="(item, index) in selectedTagsData"
:key="item"
:tagsData="item"
:showTagsRelation="index != selectedTagsData.length - 1"
:tagsGroupIndex="index"
:tagsRelation="tagsGroupRelation[index]"
:showAddMenu="showAddMenu"
:show-del-menu="selectedTagsData.length > 1"
:active="activeTagsGroupIndex === index"
@addTags="addTags"
@delTags="delTags"
@editTags="editTags"
@delTagsGroup="delTagsGroup"
@changeTagsGroupRelation="changeTagsGroupRelation"
@checkTagsGroup="checkTagsGroup"
@dragTag="dragTag"
/>
<el-button class="m-t-10 w-400 el-icon-plus color-blue add-group-btn" v-show="selectedTagsData.length < group" @click="addTagsGroup">
&nbsp;&nbsp;添加
<div>
<div :class="{ 'm-l-60': selectedTagsData.length > 1 }">
<tags-group
v-for="(item, index) in selectedTagsData"
:key="item"
:tagsData="item"
:showTagsRelation="index != selectedTagsData.length - 1"
:tagsGroupIndex="index"
:tagsRelation="tagsGroupRelation[index]"
:showAddMenu="showAddMenu"
:show-del-menu="selectedTagsData.length > 1"
:active="activeTagsGroupIndex === index"
@addTags="addTags"
@delTags="delTags"
@editTags="editTags"
@delTagsGroup="delTagsGroup"
@changeTagsGroupRelation="changeTagsGroupRelation"
@checkTagsGroup="checkTagsGroup"
@dragTag="dragTag"
/>
</div>
<el-button class="m-t-20 m-b-10 el-icon-plus color-blue add-group-btn" v-show="selectedTagsData.length < group" @click="addTagsGroup">
&nbsp;&nbsp;添加标签框
</el-button>
</div>
</template>
......@@ -139,6 +141,8 @@ export default {
.add-group-btn {
border-style: dashed;
width: 100%;
border-color: #c4c6cf;
}
.page-box {
......
<template>
<div class="w-400 border-box">
<div class="box">
<div :class="['tags-group', { 'tags-group--active': active }]" @click="checkTagsGroup">
<!--右上角的下拉菜单-->
<el-dropdown class="tags-group__dropdown" placement="bottom-end" v-if="showAddMenu || showDelMenu">
<el-popover width="200" placement="top" v-model="showDelPop" trigger="manual">
<p class="m-b-20">确认删除输入框及内部所有标签?</p>
<div class="text-right">
<el-button @click="showDelPop = false">取消</el-button>
<el-button type="primary" @click="delTagsGroup">确认</el-button>
</div>
<i slot="reference" class="el-icon-more more"></i>
</el-popover>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item v-if="showAddMenu" @click.native="addTags">添加标签</el-dropdown-item>
<el-dropdown-item v-if="showDelMenu" @click.native="handleDelTagsGroup">删除</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
<!--展示选中的标签-->
<div class="tags-group__show">
<div class="tags-group__show" :style="{paddingBottom: !showAddMenu && !tagsData.length ? '0' : '16px'}">
<draggable v-model="tagsData" group="article" style="height: 100%" @end="dragTag" :move="checkMove" :sort="false" :data-index="tagsGroupIndex">
<div class="tags-group__tag" v-for="(item, index) in tagsData" :key="item.tagId">
<el-tooltip>
<el-tooltip style="padding-right: 10px" v-if="item.newTagVal.replace(/\$\^/g,' ').length > 20">
<span>{{ item.tagName }} 【选择:{{ item.newTagVal.replace(/\$\^/g,' ') }}</span>
<div style="max-width: 400px;font-size: 14px" slot="content">{{ item.tagName }} 【选择:{{ item.newTagVal.replace(/\$\^/g,' ') }}</div>
</el-tooltip>
<i class="iconfont icon-bianji1 edit" @click="editTags(index)"></i>
<i class="iconfont icon-guanbi" @click="delTags(index)"></i>
<div v-else style="max-width: 400px;font-size: 14px;padding-right: 10px">{{ item.tagName }} 【选择:{{ item.newTagVal.replace(/\$\^/g,' ') }}</div>
<i class="iconfont icon-bianji6 edit icon m-r-8" @click="editTags(index)"></i>
<i class="iconfont icon-delete icon" @click="delTags(index)"></i>
</div>
<div class="btn-options">
<span></span>
<!--分组编辑添加按钮-->
<el-button v-if="showAddMenu" type="text" class="add-btn" @click="addTags">
<i class="iconfont icon-PlusOutlined"/>
添加标签
</el-button>
<!--删除按钮-->
<el-popover width="200" placement="left" v-model="showDelPop" trigger="click">
<p class="m-b-20">确认删除输入框及内部所有标签?</p>
<div class="text-right">
<el-button @click="showDelPop = false">取消</el-button>
<el-button type="primary" @click="delTagsGroup">确认</el-button>
</div>
<span class="tag-del" slot="reference" v-if="showDelMenu" @click="handleDelTagsGroup">删除</span>
</el-popover>
</div>
</draggable>
</div>
<div class="text-tips empty" v-show="!showAddMenu && !tagsData.length">
请在页面左侧添加所需的客户标签到此处
</div>
</div>
<!--标签组之间的关系-->
<div class="tags-group__relation" v-show="showTagsRelation">
<el-tooltip content="点击切换运算符" placement="bottom-start">
<el-button type="btn btn-default tags-group__btn" @click="changeTagsGroupRelation">
{{ tagsRelation === 'or' ? '或者' : tagsRelation === 'andNot' ? '剔除' : '' }}
</el-button>
</el-tooltip>
<span class="text-tips">点击切换运算符</span>
</div>
</div>
</template>
......@@ -157,7 +162,7 @@ export default {
<style lang="less" scoped>
.tags-group {
position: relative;
padding: 12px 0;
padding: 16px 0;
border: 1px solid #dcdfe6;
border-radius: 5px;
......@@ -178,8 +183,8 @@ export default {
}
.tags-group__show {
padding: 0 12px;
height: 120px;
padding: 0 12px 16px 20px;
min-height: 6px;
overflow-y: scroll;
}
......@@ -188,15 +193,14 @@ export default {
display: inline-block;
vertical-align: top;
padding: 0 50px 0 10px;
margin-right: 8px;
margin-bottom: 8px;
max-width: 100%;
margin-bottom: 12px;
width: 100%;
height: 32px;
line-height: 32px;
background: #f3f6f9;
background: #f2f3f5;
border-radius: 2px;
font-size: 14px;
color: #606266;
color: #303133;
cursor: pointer;
&:hover {
......@@ -223,23 +227,39 @@ export default {
align-items: center;
padding: 0 2px;
height: 100%;
color: #999;
color: #303133;
cursor: pointer;
}
i.icon-bianji1 {
i.icon-bianji6 {
right: 25px;
color: #c0c4cc;
&:hover {
color: #2F54EB;
}
}
i.icon-guanbi {
i.icon-delete {
right: 5px;
&:hover {
color: #f56c6c;
}
}
}
.btn-options {
width: 100%;
position: absolute;
bottom: 16px;
display: flex;
align-items: center;
justify-content: space-between;
left: 0;
padding: 0 16px;
font-size: 14px;
height: 18px;
}
.tag-del {
color: #f5222d;
cursor: pointer;
line-height: 17px;
}
}
.tags-group--active {
......@@ -258,6 +278,7 @@ export default {
line-height: 40px;
border-radius: 40px;
border: none;
margin-right: 14px;
background: #f3f6f9;
}
......@@ -269,18 +290,21 @@ export default {
left: 15px;
z-index: 1;
width: 40px;
height: 60px;
height: 20px;
border-left: 1px solid #dcdfe6;
}
&::before {
top: -65px;
top: -20px;
border-top: 1px solid #dcdfe6;
}
&::after {
bottom: -65px;
bottom: -20px;
border-bottom: 1px solid #dcdfe6;
}
}
.empty {
text-align: center;
}
</style>
......@@ -2100,6 +2100,7 @@ export default {
const para = {
widgetId: id
};
getRequest('/memberTag/findWidget', para)
.then(res => {
let resData = res.data;
......
......@@ -2,7 +2,7 @@
<!-- 具体标签 -->
<div class="tag-some-list">
<el-table :data="tableData" style="width: 100%">
<el-table-column label="标签名称" prop="tagName" min-width="230" fixed="left">
<el-table-column label="标签名称" prop="tagName" min-width="170" fixed="left">
<template slot-scope="scope">
<span class="tag-name">{{ scope.row.tagName }}</span>
<el-tooltip class="item" effect="dark" content="添加标签" placement="bottom">
......@@ -49,12 +49,13 @@
<div class="font-0">
<el-button class="m-r-12" type="text" @click="editActiveTag(scope.row)">编辑</el-button>
<el-button class="m-r-12" type="text" @click="editActiveTagValue(scope.row)">详情</el-button>
<el-button class="m-r-12" type="text" @click="deleteActiveTag(scope.row, scope.$index, e)">删除</el-button>
<el-button class="m-r-12" type="text" @click="deleteActiveTag(scope.row, scope.$index, $event)">删除</el-button>
</div>
</template>
</el-table-column>
</el-table>
<delete-tag-dialog :visible.sync="deleteTagDialog.visible" :data="deleteTagDialog.deleteData" @submit="doDelete" />
<i id="activeAniIcon" class="iconfont icon-biaoqian activeAniIcon" :style="{ right: `${animationPos.x}px`, bottom: `${animationPos.y}px` }"></i>
</div>
</template>
......@@ -90,6 +91,7 @@ export default {
visible: false,
deleteData: {}
},
animationPos: {}
};
},
methods: {
......@@ -162,9 +164,9 @@ export default {
const { errorCode } = res.data;
if (errorCode === 1) {
item.delStatus = 0;
this.startAnimation(e)
this.$store.commit('changeDelTrashNum', this.$store.state.delTrashNum + 1);
this.$message.success('添加成功,请点击右侧「垃圾桶」图标进行删除');
// this.startAnimation(e)
return;
}
errMsg.errorMsg(res.data);
......@@ -175,6 +177,16 @@ export default {
});
});
},
startAnimation(e) {
this.animationPos = {
x: document.body.offsetWidth - e.pageX,
y: document.body.offsetHeight - e.pageY
}
document.getElementById('activeAniIcon').style.display = 'block';
setTimeout(() => {
document.getElementById('activeAniIcon').style.display = 'none';
}, 1800)
},
},
watch: {
data: {
......@@ -212,9 +224,14 @@ export default {
margin: 0 20px;
overflow-y: auto;
}
.tag-name {
display: inline-block;
word-break: break-all;
max-width: 120px;
}
.icon-tag-name {
display: inline-block;
vertical-align: bottom;
vertical-align: top;
font-size: 16px;
cursor: pointer;
color: #303133;
......@@ -227,4 +244,36 @@ export default {
.refresh {
color: #606266;
}
#activeAniIcon {
display: none;
position: fixed;
z-index: 99999;
color: #2F54EB;
font-size: 26px;
animation: toTrash 2s;
opacity: 0;
}
@keyframes toTrash {
0% {
opacity: 1;
}
40% {
opacity: 1;
right: 38px;
bottom: 345px;
transform: scale(0.5);
}
50% {
opacity: 0.5;
right: 37px;
bottom: 345px;
transform: scale(1.2);
}
100% {
opacity: 0.5;
right: 37px;
bottom: 345px;
transform: scale(0);
}
}
</style>
......@@ -2,7 +2,7 @@
<!-- 具体标签 -->
<div class="tag-some-list">
<el-table :data="tableData" style="width: 100%">
<el-table-column label="标签名称" prop="tagName" min-width="230" fixed>
<el-table-column label="标签名称" prop="tagName" min-width="170" fixed>
<template slot-scope="scope">
<span class="tag-name">{{ scope.row.tagName }}</span>
<el-tooltip class="item" effect="dark" content="添加标签" placement="top">
......@@ -117,9 +117,14 @@ export default {
margin: 0 20px;
overflow-y: auto;
}
.tag-name {
display: inline-block;
word-break: break-all;
max-width: 120px;
}
.icon-tag-name {
display: inline-block;
vertical-align: bottom;
vertical-align: top;
font-size: 16px;
cursor: pointer;
color: #303133;
......
......@@ -2,7 +2,7 @@
<!-- 具体标签 -->
<div class="tag-some-list">
<el-table :data="tableData" style="width: 100%" @sort-change="sortChange">
<el-table-column label="标签名称" prop="tagName" min-width="230" fixed>
<el-table-column label="标签名称" prop="tagName" min-width="170" fixed>
<template slot-scope="scope">
<span class="tag-name">{{ scope.row.tagName }}</span>
<el-tooltip class="item" effect="dark" content="添加标签" placement="bottom">
......@@ -67,14 +67,15 @@
<el-table-column label="操作" v-if="((getCodeAuth('edit') || getCodeAuth('setValue') || getCodeAuth('delete')) && resource != 'memberGroupEdit')" min-width="200" fixed="right">
<template slot-scope="scope">
<div class="font-0">
<el-button class="m-r-12" type="text" v-if="!isWeim && getCodeAuth('edit')" :limit-code="getCode('edit')" @click="editHandTag(scope.row)">编辑</el-button>
<el-button class="m-r-12" type="text" v-if="!isWeim && getCodeAuth('edit') && !weimId.includes(scope.row.tagLevelGroupId)" :limit-code="getCode('edit')" @click="editHandTag(scope.row)">编辑</el-button>
<el-button class="m-r-12" type="text" v-if="getCodeAuth('setValue')" :limit-code="getCode('setValue')" @click="editHandTagValue(scope.row)">详情</el-button>
<el-button class="m-r-12" type="text" v-if="!isWeim && getCodeAuth('delete')" :limit-code="getCode('delete')" @click="deleteHandTag(scope.row, scope.$index, $event)">删除</el-button>
<el-button class="m-r-12" type="text" v-if="!isWeim && getCodeAuth('delete') && !weimId.includes(scope.row.tagLevelGroupId)" :limit-code="getCode('delete')" @click="deleteHandTag(scope.row, scope.$index, $event)">删除</el-button>
</div>
</template>
</el-table-column>
</el-table>
<delete-tag-dialog :visible.sync="deleteTagDialog.visible" :data="deleteTagDialog.deleteData" @submit="doDelete" />
<delete-tag-dialog :visible.sync="deleteTagDialog.visible" :data="deleteTagDialog.deleteData" @submit="doDelete" />
<i id="tagAniIcon" class="iconfont icon-biaoqian tagAniIcon" :style="{ right: `${animationPos.x}px`, bottom: `${animationPos.y}px` }"></i>
</div>
</template>
......@@ -112,6 +113,8 @@ export default {
visible: false,
deleteData: {}
},
weimId: ['3d11ac15963b4c0790762e6147ea9315', '5bdac971673b4f40a9af981e3c9215bf'],
animationPos: {}
};
},
methods: {
......@@ -167,7 +170,6 @@ export default {
},
// 加入到垃圾桶
intoTrash(item, index, e) {
console.log(item);
const para = {
itemId: item.tagId,
type: 1
......@@ -176,10 +178,9 @@ export default {
const { errorCode } = res.data;
if (errorCode === 1) {
item.delStatus = 0;
console.log(this.$store.state.delTrashNum + 1);
this.startAnimation(e);
this.$store.commit('changeDelTrashNum', this.$store.state.delTrashNum + 1);
this.$message.success('添加成功,请点击右侧「垃圾桶」图标进行删除');
// this.startAnimation(e)
return;
}
errMsg.errorMsg(res.data);
......@@ -190,6 +191,16 @@ export default {
});
});
},
startAnimation(e) {
this.animationPos = {
x: document.body.offsetWidth - e.pageX - 30,
y: document.body.offsetHeight - e.pageY
}
document.getElementById('tagAniIcon').style.display = 'block';
setTimeout(() => {
document.getElementById('tagAniIcon').style.display = 'none';
}, 1800)
},
handleTrackParam(type, data) {
let fn = {
addTag: () => {
......@@ -271,9 +282,14 @@ export default {
.tag-some-list {
margin: 0 20px;
}
.tag-name {
display: inline-block;
word-break: break-all;
max-width: 120px;
}
.icon-tag-name {
display: inline-block;
vertical-align: bottom;
vertical-align: top;
font-size: 16px;
cursor: pointer;
transition: all .3s;
......@@ -288,11 +304,6 @@ export default {
top: 1px;
}
.sort {
// /deep/ .el-input__inner {
// height: 24px;
// width: 24px;
// padding: 0 7px;
// }
height: 24px;
padding: 0 7px;
display: inline-block;
......@@ -303,4 +314,36 @@ export default {
color: #303133;
border: 1px dashed #C4C6CF;
}
#tagAniIcon {
display: none;
position: fixed;
z-index: 99999;
color: #2F54EB;
font-size: 26px;
animation: toTrash 2s infinite;
opacity: 0;
}
@keyframes toTrash {
0% {
opacity: 1;
}
40% {
opacity: 1;
right: 38px;
bottom: 345px;
transform: scale(0.5);
}
50% {
opacity: 0.5;
right: 37px;
bottom: 345px;
transform: scale(1.2);
}
100% {
opacity: 0.5;
right: 37px;
bottom: 345px;
transform: scale(0);
}
}
</style>
......@@ -75,7 +75,7 @@
.cre-dialog {
.el-dialog__body {
padding: 10px 20px;
padding: 10px 20px 24px;
}
.cre-btn {
padding-top: 20px;
......@@ -102,7 +102,7 @@
height: 100%;
}
.right-content {
padding-top: 12px;
// padding-top: 12px;
min-height: calc(100vh - 256px);
}
.right-box {
......@@ -124,3 +124,9 @@
color: #1D39C4 !important;
}
}
// 提示样式
.text-tips {
font-size: 12px;
color: #909399;
line-height: 17px;
}
......@@ -82,6 +82,8 @@ summary,
time,
mark,
audio,
textarea,
input,
video {
margin: 0;
padding: 0;
......@@ -316,9 +318,15 @@ input:focus {
.m-l-4 {
margin-left: 4px;
}
.m-l-5 {
margin-left: 5px;
}
.m-l-8 {
margin-left: 8px;
}
.m-l-10 {
margin-left: 10px;
}
.m-l-16 {
margin-left: 16px;
}
......@@ -331,15 +339,27 @@ input:focus {
.m-t-05 {
margin-top: -5px;
}
.m-t-8 {
margin-top: 8px;
}
.m-t-10 {
margin-top: 10px;
}
.m-t-12 {
margin-top: 12px;
}
.m-t-18 {
margin-top: 18px;
}
.m-t-16 {
margin-top: 16px;
}
.m-t-20 {
margin-top: 20px;
}
.m-t-34 {
margin-top: 34px;
}
.m-r-6 {
margin-right: 6px;
}
......@@ -355,15 +375,30 @@ input:focus {
.m-r-20 {
margin-right: 20px;
}
.m-b-0 {
margin-bottom: 0px !important;
}
.m-b-5 {
margin-bottom: 5px;
}
.m-b-10 {
margin-bottom: 10px;
}
.m-b-15 {
margin-bottom: 15px !important;
}
.m-b-20 {
margin-bottom: 20px;
}
.m-b-24 {
margin-bottom: 24px;
}
.m-b-26 {
margin-bottom: 26px;
}
.m-b-30 {
margin-bottom: 30px;
}
.p-20 {
padding: 20px;
}
......@@ -948,7 +983,7 @@ input:-webkit-autofill, textarea:-webkit-autofill, select:-webkit-autofill {
/* 分页 */
.common-wrap__page {
padding: 24px 0 30px 0;
padding: 24px 0 20px 0;
}
.common-wrap__page .el-input {
font-size: 12px;
......
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