|
@@ -49,7 +49,8 @@
|
|
align="center"
|
|
align="center"
|
|
>
|
|
>
|
|
<template slot-scope="{row}">
|
|
<template slot-scope="{row}">
|
|
- <span>{{row.ClassifyNameFirst}}</span>
|
|
|
|
|
|
+ <span>{{row.ClassifyNameRoot}}</span>
|
|
|
|
+ <span v-if="row.ClassifyNameFirst">/{{row.ClassifyNameFirst}}</span>
|
|
<span v-if="row.ClassifyNameSecond">/{{row.ClassifyNameSecond}}</span>
|
|
<span v-if="row.ClassifyNameSecond">/{{row.ClassifyNameSecond}}</span>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
@@ -260,8 +261,21 @@
|
|
>
|
|
>
|
|
<div class="send-email-wrap">
|
|
<div class="send-email-wrap">
|
|
<el-form ref="form" :model="popEmailData" label-width="100px">
|
|
<el-form ref="form" :model="popEmailData" label-width="100px">
|
|
- <el-form-item label="收件人:">
|
|
|
|
|
|
+ <el-form-item label="邮件主题:">
|
|
<div>
|
|
<div>
|
|
|
|
+ <el-input
|
|
|
|
+ placeholder="请输入邮件主题"
|
|
|
|
+ v-model="popEmailData.theme"
|
|
|
|
+ type="textarea"
|
|
|
|
+ maxlength="100"
|
|
|
|
+ show-word-limit
|
|
|
|
+ :autosize="{ minRows: 3, maxRows: 5}"
|
|
|
|
+ ></el-input>
|
|
|
|
+ </div>
|
|
|
|
+ </el-form-item>
|
|
|
|
+ <el-form-item label="收件人:">
|
|
|
|
+ <div class="addressee-box">
|
|
|
|
+ <div class="addressee-cancel-box">
|
|
<!-- <el-radio v-model="popEmailData.radio" label="1">默认全部</el-radio> -->
|
|
<!-- <el-radio v-model="popEmailData.radio" label="1">默认全部</el-radio> -->
|
|
<el-cascader
|
|
<el-cascader
|
|
v-if="popEmailData.show"
|
|
v-if="popEmailData.show"
|
|
@@ -276,55 +290,84 @@
|
|
children:'Child'
|
|
children:'Child'
|
|
}"
|
|
}"
|
|
placeholder="请选择品种权限"
|
|
placeholder="请选择品种权限"
|
|
|
|
+ style="margin-bottom: 10px;"
|
|
/>
|
|
/>
|
|
- <el-checkbox v-model="popEmailData.checkUser" style="margin-left:20px">指定人员</el-checkbox>
|
|
|
|
- </div>
|
|
|
|
- <div v-if="popEmailData.checkUser" class="user-box">
|
|
|
|
|
|
+ <div class="user-box-hint">取消发送客户信息:</div>
|
|
<el-select
|
|
<el-select
|
|
- v-model="popEmailData.value"
|
|
|
|
- multiple
|
|
|
|
- filterable
|
|
|
|
- collapse-tags
|
|
|
|
- placeholder="请选择客户"
|
|
|
|
- value-key="Id"
|
|
|
|
- >
|
|
|
|
|
|
+ v-model="popEmailData.customValue"
|
|
|
|
+ multiple
|
|
|
|
+ filterable
|
|
|
|
+ collapse-tags
|
|
|
|
+ placeholder="请选择客户"
|
|
|
|
+ value-key="CompanyId">
|
|
<el-option
|
|
<el-option
|
|
|
|
+ v-for="item in popEmailData.customOptions"
|
|
|
|
+ :key="item.CompanyId"
|
|
|
|
+ :label="item.CompanyName"
|
|
|
|
+ :value="item">
|
|
|
|
+ </el-option>
|
|
|
|
+ </el-select>
|
|
|
|
+ <div class="user-box">
|
|
|
|
+ <div style="margin-top:10px" class="box">
|
|
|
|
+ <!-- <el-tooltip
|
|
|
|
+ effect="dark"
|
|
|
|
+ :content="item.CompanyName"
|
|
|
|
+ placement="top"
|
|
|
|
+ v-for="(item,index) in popEmailData.customValue"
|
|
|
|
+ :key="item.CompanyId"
|
|
|
|
+ > -->
|
|
|
|
+ <el-tag
|
|
|
|
+ closable
|
|
|
|
+ v-for="(item,index) in popEmailData.customValue"
|
|
|
|
+ :key="item.CompanyId"
|
|
|
|
+ style="margin:0 10px 10px 0"
|
|
|
|
+ @close="handleDelSelectCompany(item,index)">
|
|
|
|
+ {{item.CompanyName}}
|
|
|
|
+ </el-tag>
|
|
|
|
+ <!-- </el-tooltip> -->
|
|
|
|
+ </div>
|
|
|
|
+ </div>
|
|
|
|
+ </div>
|
|
|
|
+ <div class="addressee-append-box">
|
|
|
|
+ <el-checkbox v-model="popEmailData.checkUser" style="margin:0 0 10px 20px;width: 100px;">指定人员</el-checkbox>
|
|
|
|
+ <div class="user-box-hint" v-show="popEmailData.checkUser">指定发送人员信息:</div>
|
|
|
|
+ <el-select
|
|
|
|
+ v-show="popEmailData.checkUser"
|
|
|
|
+ v-model="popEmailData.value"
|
|
|
|
+ multiple
|
|
|
|
+ filterable
|
|
|
|
+ collapse-tags
|
|
|
|
+ placeholder="请选择人员"
|
|
|
|
+ value-key="Id">
|
|
|
|
+ <el-option
|
|
v-for="item in popEmailData.options"
|
|
v-for="item in popEmailData.options"
|
|
:key="item.Id"
|
|
:key="item.Id"
|
|
:label="item.Name"
|
|
:label="item.Name"
|
|
- :value="item">
|
|
|
|
|
|
+ :value="item"
|
|
|
|
+ :disabled="item.Enabled===0">
|
|
<span>{{item.Name}} <{{item.Email}}></span>
|
|
<span>{{item.Name}} <{{item.Email}}></span>
|
|
- </el-option>
|
|
|
|
|
|
+ </el-option>
|
|
</el-select>
|
|
</el-select>
|
|
- <div style="margin-top:10px" class="box">
|
|
|
|
|
|
+ <div class="user-box" v-show="popEmailData.checkUser">
|
|
|
|
+ <div style="margin-top:10px" class="box">
|
|
<el-tooltip
|
|
<el-tooltip
|
|
- effect="dark"
|
|
|
|
- :content="item.Email"
|
|
|
|
- placement="top"
|
|
|
|
- v-for="(item,index) in popEmailData.value"
|
|
|
|
- :key="item.Id"
|
|
|
|
- >
|
|
|
|
|
|
+ effect="dark"
|
|
|
|
+ :content="item.Email"
|
|
|
|
+ placement="top"
|
|
|
|
+ v-for="(item,index) in popEmailData.value"
|
|
|
|
+ :key="item.Id"
|
|
|
|
+ >
|
|
<el-tag
|
|
<el-tag
|
|
- closable
|
|
|
|
- style="margin:0 10px 10px 0"
|
|
|
|
- @close="handleDelSelectCustom(item,index)">
|
|
|
|
- {{item.Name}}
|
|
|
|
|
|
+ closable
|
|
|
|
+ style="margin:0 10px 10px 0"
|
|
|
|
+ @close="handleDelSelectCustom(item,index)">
|
|
|
|
+ {{item.Name}}
|
|
</el-tag>
|
|
</el-tag>
|
|
</el-tooltip>
|
|
</el-tooltip>
|
|
|
|
+ </div>
|
|
</div>
|
|
</div>
|
|
- </div>
|
|
|
|
- </el-form-item>
|
|
|
|
- <el-form-item label="邮件主题:">
|
|
|
|
- <div>
|
|
|
|
- <el-input
|
|
|
|
- placeholder="请输入邮件主题"
|
|
|
|
- v-model="popEmailData.theme"
|
|
|
|
- type="textarea"
|
|
|
|
- maxlength="100"
|
|
|
|
- show-word-limit
|
|
|
|
- :autosize="{ minRows: 3, maxRows: 5}"
|
|
|
|
- ></el-input>
|
|
|
|
- </div>
|
|
|
|
|
|
+ </div>
|
|
|
|
+ </div>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
<div style="text-align:center;margin-bottom:30px;margin-top:40px">
|
|
<div style="text-align:center;margin-bottom:30px;margin-top:40px">
|
|
<el-button type="primary" plain style="margin-right:10px" @click="popEmailData.show=false">取消</el-button>
|
|
<el-button type="primary" plain style="margin-right:10px" @click="popEmailData.show=false">取消</el-button>
|
|
@@ -339,7 +382,7 @@
|
|
<script>
|
|
<script>
|
|
import { videoENInterface,PVDetailList } from '@/api/modules/reportEnApi'
|
|
import { videoENInterface,PVDetailList } from '@/api/modules/reportEnApi'
|
|
import * as reportEnInterface from '@/api/modules/reportEnApi';
|
|
import * as reportEnInterface from '@/api/modules/reportEnApi';
|
|
-import {customInterence,videoInterface,departInterence,reportVarietyENInterence} from '@/api/api.js'
|
|
|
|
|
|
+import {customInterence,videoInterface,reportVarietyENInterence} from '@/api/api.js'
|
|
export default {
|
|
export default {
|
|
filters:{
|
|
filters:{
|
|
formatDuration(e){
|
|
formatDuration(e){
|
|
@@ -401,6 +444,8 @@ export default {
|
|
checkUser:false,//是否选择指定人员
|
|
checkUser:false,//是否选择指定人员
|
|
options: [],
|
|
options: [],
|
|
value: [],
|
|
value: [],
|
|
|
|
+ customOptions:[],
|
|
|
|
+ customValue:[],
|
|
theme:'',
|
|
theme:'',
|
|
videoId:0,
|
|
videoId:0,
|
|
varietyOpt:[],
|
|
varietyOpt:[],
|
|
@@ -693,17 +738,18 @@ export default {
|
|
VideoId:this.popEmailData.videoId
|
|
VideoId:this.popEmailData.videoId
|
|
}).then(res=>{
|
|
}).then(res=>{
|
|
if(res.Ret===200){
|
|
if(res.Ret===200){
|
|
- const arr=res.Data||[]
|
|
|
|
- this.popEmailData.varietyOpt=arr.filter(e=>{
|
|
|
|
- e.Child&&e.Child.forEach(_e=>delete _e.Child)
|
|
|
|
- return e.Child&&e.Child.length>0
|
|
|
|
- })
|
|
|
|
- // 设置全部选中
|
|
|
|
- this.popEmailData.varietyOpt.forEach(e=>{
|
|
|
|
- e.Child.forEach(_e=>{
|
|
|
|
- this.popEmailData.varietyVal.push([e.EnPermissionId,_e.EnPermissionId])
|
|
|
|
|
|
+ const arr=res.Data||[]
|
|
|
|
+ this.popEmailData.varietyOpt=arr.filter(e=>{
|
|
|
|
+ e.Child&&e.Child.forEach(_e=>delete _e.Child)
|
|
|
|
+ return e.Child&&e.Child.length>0
|
|
})
|
|
})
|
|
- })
|
|
|
|
|
|
+ // 设置全部选中
|
|
|
|
+ this.popEmailData.varietyOpt.forEach(e=>{
|
|
|
|
+ e.Child.forEach(_e=>{
|
|
|
|
+ this.popEmailData.varietyVal.push([e.EnPermissionId,_e.EnPermissionId])
|
|
|
|
+ })
|
|
|
|
+ })
|
|
|
|
+ this.getCustomListEnFun()
|
|
}
|
|
}
|
|
})
|
|
})
|
|
},
|
|
},
|
|
@@ -719,16 +765,45 @@ export default {
|
|
this.popEmailData.options=arr
|
|
this.popEmailData.options=arr
|
|
}
|
|
}
|
|
},
|
|
},
|
|
|
|
+ // 获取英文客户列表
|
|
|
|
+ getCustomListEnFun(){
|
|
|
|
+ let arr=[]
|
|
|
|
+ this.popEmailData.varietyVal&&this.popEmailData.varietyVal.forEach(_e => {
|
|
|
|
+ arr.push(_e[1])
|
|
|
|
+ });
|
|
|
|
+ if(!(arr.length>0)){
|
|
|
|
+ this.popEmailData.customOptions=[]
|
|
|
|
+ return
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ customInterence.getCustomListEn({
|
|
|
|
+ PageSize:100000,
|
|
|
|
+ CurrentIndex:1,
|
|
|
|
+ EnPermissionIds:arr.join(',')
|
|
|
|
+ }).then(res=>{
|
|
|
|
+ if(res.Ret!==200) return
|
|
|
|
+ this.popEmailData.customOptions = res.Data.List || []
|
|
|
|
+ })
|
|
|
|
+ },
|
|
//删除选中的群发客户
|
|
//删除选中的群发客户
|
|
handleDelSelectCustom(item,index){
|
|
handleDelSelectCustom(item,index){
|
|
this.popEmailData.value.splice(index,1)
|
|
this.popEmailData.value.splice(index,1)
|
|
},
|
|
},
|
|
|
|
+ //删除选中的英文客户
|
|
|
|
+ handleDelSelectCompany(item,index){
|
|
|
|
+ this.popEmailData.customValue.splice(index,1)
|
|
|
|
+ },
|
|
//发送邮件
|
|
//发送邮件
|
|
handleConfirmSendEmail(){
|
|
handleConfirmSendEmail(){
|
|
let ids=[]
|
|
let ids=[]
|
|
this.popEmailData.value.forEach(item=>{
|
|
this.popEmailData.value.forEach(item=>{
|
|
ids.push(item.Id)
|
|
ids.push(item.Id)
|
|
})
|
|
})
|
|
|
|
+ let customIds=[]
|
|
|
|
+ this.popEmailData.customValue.forEach(item=>{
|
|
|
|
+ customIds.push(item.CompanyId)
|
|
|
|
+ })
|
|
|
|
+
|
|
if(this.popEmailData.checkUser&&ids.length===0){//指定人员
|
|
if(this.popEmailData.checkUser&&ids.length===0){//指定人员
|
|
this.$message.warning('请选择需要发送邮件的人员')
|
|
this.$message.warning('请选择需要发送邮件的人员')
|
|
return
|
|
return
|
|
@@ -753,7 +828,8 @@ export default {
|
|
ReportId:this.popEmailData.videoId,
|
|
ReportId:this.popEmailData.videoId,
|
|
EmailIds:ids.join(','),
|
|
EmailIds:ids.join(','),
|
|
Theme:this.popEmailData.theme,
|
|
Theme:this.popEmailData.theme,
|
|
- EnPermissions:arr
|
|
|
|
|
|
+ EnPermissions:arr,
|
|
|
|
+ NoCompanyIds:customIds,
|
|
}).then(res=>{
|
|
}).then(res=>{
|
|
if(res.Ret===200){
|
|
if(res.Ret===200){
|
|
this.$message.success('发送成功')
|
|
this.$message.success('发送成功')
|
|
@@ -868,14 +944,28 @@ export default {
|
|
}
|
|
}
|
|
}
|
|
}
|
|
.send-email-wrap{
|
|
.send-email-wrap{
|
|
- .user-box{
|
|
|
|
- border: 1px dashed #DCDFE6;
|
|
|
|
- border-radius: 4px;
|
|
|
|
- padding: 20px;
|
|
|
|
- margin-top: 20px;
|
|
|
|
- .box{
|
|
|
|
- max-height: 200px;
|
|
|
|
- overflow-y: auto;
|
|
|
|
|
|
+ .addressee-box{
|
|
|
|
+ display: flex;
|
|
|
|
+ align-items: flex-start;
|
|
|
|
+ justify-content: space-between;
|
|
|
|
+ .addressee-cancel-box,.addressee-append-box{
|
|
|
|
+ display: flex;
|
|
|
|
+ flex-direction: column;
|
|
|
|
+ justify-content: flex-start;
|
|
|
|
+ width: calc(50% - 12px);
|
|
|
|
+ }
|
|
|
|
+ .user-box-hint{
|
|
|
|
+ color: #999999;
|
|
|
|
+ }
|
|
|
|
+ .user-box{
|
|
|
|
+ border: 1px dashed #DCDFE6;
|
|
|
|
+ border-radius: 4px;
|
|
|
|
+ padding: 20px;
|
|
|
|
+ margin-top: 20px;
|
|
|
|
+ .box{
|
|
|
|
+ max-height: 200px;
|
|
|
|
+ overflow-y: auto;
|
|
|
|
+ }
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|