Merge branch 'bd-dev' of 47.94.45.65:angelo/web-base-admin into bd-test
This commit is contained in:
commit
79ff2f4b3c
|
@ -318,3 +318,27 @@ export function getBenefitsRuleLogList(params) {
|
|||
})
|
||||
}
|
||||
|
||||
// 消费赠送
|
||||
export function consumeRuleConfigSubmit(data) {
|
||||
return request({
|
||||
url: '/sale/manage/consume-rule-config/submit',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
// 会员消费赠送:
|
||||
export function memberConsumeRuleSubmit(data) {
|
||||
return request({
|
||||
url: '/sale/manage/member-consume-rule/submit',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
// 商品赠送:
|
||||
export function waresRuleConfigSubmit(data) {
|
||||
return request({
|
||||
url: '/sale/manage/wares-rule-config/submit',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
|
|
@ -466,10 +466,9 @@ export const constantRoutes = [
|
|||
path: 'deleteDeadLock',
|
||||
name: 'DeleteDeadLock',
|
||||
component: () => import('@/views/information/specialBusiness/deleteDeadLock/index'),
|
||||
meta: {title: '删除死点'}
|
||||
meta: { title: '删除死点' }
|
||||
}
|
||||
|
||||
|
||||
]
|
||||
},
|
||||
|
||||
|
@ -1858,13 +1857,6 @@ export const constantRoutes = [
|
|||
component: () => import('@/views/marketing/giftGoods/setGiftGoodsInfo'),
|
||||
meta: { title: '规则设置' },
|
||||
hidden: true
|
||||
},
|
||||
{
|
||||
path: 'giftGoodsZxqc',
|
||||
name: 'GiftGoodsZxqc',
|
||||
component: () => import('@/views/marketing/giftGoods/giftGoodsZxqc'),
|
||||
meta: { title: '在线签呈' },
|
||||
hidden: true
|
||||
}
|
||||
]
|
||||
},
|
||||
|
@ -1892,14 +1884,8 @@ export const constantRoutes = [
|
|||
component: () => import('@/views/marketing/consumptionGift/setConsumptionInfo'),
|
||||
meta: { title: '规则设置' },
|
||||
hidden: true
|
||||
},
|
||||
{
|
||||
path: 'consumptionGiftZxqc',
|
||||
name: 'ConsumptionGiftZxqc',
|
||||
component: () => import('@/views/marketing/consumptionGift/consumptionGiftZxqc'),
|
||||
meta: { title: '在线签呈' },
|
||||
hidden: true
|
||||
}
|
||||
|
||||
]
|
||||
},
|
||||
{
|
||||
|
@ -1926,13 +1912,6 @@ export const constantRoutes = [
|
|||
component: () => import('@/views/marketing/memberConsumptionGift/setConsumptionInfo'),
|
||||
meta: { title: '规则设置' },
|
||||
hidden: true
|
||||
},
|
||||
{
|
||||
path: 'memberConsumptionGiftZxqc',
|
||||
name: 'MemberConsumptionGiftZxqc',
|
||||
component: () => import('@/views/marketing/memberConsumptionGift/consumptionGiftZxqc'),
|
||||
meta: { title: '在线签呈' },
|
||||
hidden: true
|
||||
}
|
||||
]
|
||||
},
|
||||
|
|
|
@ -10,8 +10,13 @@
|
|||
:topList="topList"
|
||||
:moren="moren"></topBar> -->
|
||||
<div class="topbox">
|
||||
<div class="levelList_i" :class="tabActive == item.id ? 'act' : ''" v-for="(item, index) in topList" :key="index"
|
||||
@click.prevent="handleLink(item.id)">
|
||||
<div
|
||||
v-for="(item, index) in topList"
|
||||
:key="index"
|
||||
class="levelList_i"
|
||||
:class="tabActive == item.id ? 'act' : ''"
|
||||
@click.prevent="handleLink(item.id)"
|
||||
>
|
||||
{{ item.name }}
|
||||
</div>
|
||||
</div>
|
||||
|
@ -20,12 +25,12 @@
|
|||
<div class="main">
|
||||
<div v-show="tabActive == 0">
|
||||
<div class="tit">{{ '基本信息' }}</div>
|
||||
<div class="xian"></div>
|
||||
<el-form :model="ruleForm" :rules="rules" ref="ruleForm" label-width="auto" class="demo-ruleForm">
|
||||
<div class="xian" />
|
||||
<el-form ref="ruleForm" :model="ruleForm" :rules="rules" label-width="auto" class="demo-ruleForm">
|
||||
<el-row>
|
||||
<el-col :span="8">
|
||||
<el-form-item :label="'活动名称'" prop="actName">
|
||||
<el-input clearable v-model="ruleForm.actName" :disabled="lookOver"></el-input>
|
||||
<el-input v-model="ruleForm.actName" clearable :disabled="lookOver" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
@ -36,8 +41,13 @@
|
|||
type="textarea"
|
||||
v-model="ruleForm.actExplain"
|
||||
:disabled="lookOver"></el-input> -->
|
||||
<editor ref="sptwEditor" :readOnly="lookOver" v-model="ruleForm.actExplain" :min-height="196"
|
||||
:uploadUrl="uploadImgUrl" />
|
||||
<editor
|
||||
ref="sptwEditor"
|
||||
v-model="ruleForm.actExplain"
|
||||
:read-only="lookOver"
|
||||
:min-height="196"
|
||||
:upload-url="uploadImgUrl"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
@ -52,27 +62,33 @@
|
|||
<el-col :span="24">
|
||||
<el-form-item :label="'目标用户群体'" required>
|
||||
<div class="flexed">
|
||||
<el-checkbox class="flexed_l" @change="getCheckTit($event, 1)" v-model="ruleForm.checked1">{{
|
||||
'注册等级' }}</el-checkbox>
|
||||
<el-checkbox v-model="ruleForm.checked1" class="flexed_l" @change="getCheckTit($event, 1)">{{
|
||||
'注册等级' }}</el-checkbox>
|
||||
<el-checkbox-group v-model="ruleForm.levelList" @change="getCheck">
|
||||
<el-checkbox v-for="item in gradeList" :key="item.pkId" :label="item.pkId">{{ item.gradeName
|
||||
}}</el-checkbox>
|
||||
}}</el-checkbox>
|
||||
</el-checkbox-group>
|
||||
</div>
|
||||
<div class="flexed">
|
||||
<el-checkbox class="flexed_l" @change="getCheckTit($event, 2)"
|
||||
v-model="ruleForm.checked2">{{ '真实奖衔' }}</el-checkbox>
|
||||
<el-checkbox
|
||||
v-model="ruleForm.checked2"
|
||||
class="flexed_l"
|
||||
@change="getCheckTit($event, 2)"
|
||||
>{{ '真实奖衔' }}</el-checkbox>
|
||||
<el-checkbox-group v-model="ruleForm.realList" @change="getCheck">
|
||||
<el-checkbox v-for="item in awardsList" :key="item.pkId" :label="item.pkId">{{ item.awardsName
|
||||
}}</el-checkbox>
|
||||
}}</el-checkbox>
|
||||
</el-checkbox-group>
|
||||
</div>
|
||||
<div class="flexed">
|
||||
<el-checkbox class="flexed_l" @change="getCheckTit($event, 3)"
|
||||
v-model="ruleForm.checked3">{{ '权限中心' }}</el-checkbox>
|
||||
<el-checkbox
|
||||
v-model="ruleForm.checked3"
|
||||
class="flexed_l"
|
||||
@change="getCheckTit($event, 3)"
|
||||
>{{ '权限中心' }}</el-checkbox>
|
||||
<el-checkbox-group v-model="ruleForm.centerList" @change="getCheck">
|
||||
<el-checkbox v-for="item in registList" :key="item.value" :label="item.value">{{ item.label
|
||||
}}</el-checkbox>
|
||||
}}</el-checkbox>
|
||||
</el-checkbox-group>
|
||||
</div>
|
||||
</el-form-item>
|
||||
|
@ -81,20 +97,32 @@
|
|||
<el-row>
|
||||
<el-col :span="8">
|
||||
<el-form-item :label="'活动时间'" prop="ruleFormTime">
|
||||
<el-date-picker :disabled="lookOver" v-model="ruleForm.ruleFormTime" @change="changeTime"
|
||||
value-format="yyyy-MM-dd HH:mm:ss" type="datetimerange" :range-separator="'至'"
|
||||
:start-placeholder="'开始日期'" :end-placeholder="'结束日期'">
|
||||
</el-date-picker>
|
||||
<el-date-picker
|
||||
v-model="ruleForm.ruleFormTime"
|
||||
:disabled="lookOver"
|
||||
value-format="yyyy-MM-dd HH:mm:ss"
|
||||
type="datetimerange"
|
||||
:range-separator="'至'"
|
||||
:start-placeholder="'开始日期'"
|
||||
:end-placeholder="'结束日期'"
|
||||
@change="changeTime"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="8">
|
||||
<el-form-item :label="'展示时间'" prop="ruleFormTime1">
|
||||
<el-date-picker :disabled="lookOver" v-model="ruleForm.ruleFormTime1" @change="changeTime1"
|
||||
value-format="yyyy-MM-dd HH:mm:ss" type="datetimerange" :range-separator="'至'"
|
||||
:start-placeholder="'开始日期'" :end-placeholder="'结束日期'">
|
||||
</el-date-picker>
|
||||
<el-date-picker
|
||||
v-model="ruleForm.ruleFormTime1"
|
||||
:disabled="lookOver"
|
||||
value-format="yyyy-MM-dd HH:mm:ss"
|
||||
type="datetimerange"
|
||||
:range-separator="'至'"
|
||||
:start-placeholder="'开始日期'"
|
||||
:end-placeholder="'结束日期'"
|
||||
@change="changeTime1"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
@ -102,13 +130,13 @@
|
|||
</el-form>
|
||||
</div>
|
||||
|
||||
<setConsumptionInfo v-show="tabActive == 1" ref="setConsumptionInfo"></setConsumptionInfo>
|
||||
<shieldConsumption v-show="tabActive == 2" ref="shieldConsumption"></shieldConsumption>
|
||||
<setConsumptionInfo v-show="tabActive == 1" ref="setConsumptionInfo" />
|
||||
<shieldConsumption v-show="tabActive == 2" ref="shieldConsumption" />
|
||||
|
||||
</div>
|
||||
<div class="footer" v-show="controlType != 4">
|
||||
<el-button size="small" class="cancelBtn"> {{ '取消' }}</el-button>
|
||||
<el-button size="small" @click="submit('ruleForm')" class="sureBtn"> {{ '确认' }}</el-button>
|
||||
<div v-show="controlType != 4" class="footer">
|
||||
<el-button size="small" class="cancelBtn" @click="$router.back()"> {{ '取消' }}</el-button>
|
||||
<el-button size="small" class="sureBtn" @click="submit('ruleForm')"> {{ '确认' }}</el-button>
|
||||
</div>
|
||||
<!-- </div> -->
|
||||
|
||||
|
@ -138,16 +166,16 @@ export default {
|
|||
topList: [
|
||||
{
|
||||
name: '基本信息',
|
||||
id: 0,
|
||||
id: 0
|
||||
},
|
||||
{
|
||||
name: '规则设置',
|
||||
id: 1,
|
||||
id: 1
|
||||
},
|
||||
{
|
||||
name: '屏蔽设置',
|
||||
id: 2,
|
||||
},
|
||||
id: 2
|
||||
}
|
||||
],
|
||||
uploadImgUrl: process.env.VUE_APP_BASE_API + '/system/upload',
|
||||
ruleForm: {
|
||||
|
@ -157,27 +185,27 @@ export default {
|
|||
levelList: [],
|
||||
realList: [],
|
||||
centerList: [],
|
||||
goalMemberConfigList: [],
|
||||
goalMemberConfigList: []
|
||||
},
|
||||
rules: {
|
||||
actName: [
|
||||
{ required: true, message: '请输入活动名称', trigger: 'blur' },
|
||||
{ required: true, message: '请输入活动名称', trigger: 'blur' }
|
||||
],
|
||||
actExplain: [
|
||||
{ required: true, message: '请输入活动说明', trigger: 'blur' },
|
||||
{ required: true, message: '请输入活动说明', trigger: 'blur' }
|
||||
],
|
||||
actCover: [
|
||||
{ required: true, message: '请上传活动封面', trigger: 'change' },
|
||||
{ required: true, message: '请上传活动封面', trigger: 'change' }
|
||||
],
|
||||
goalMemberConfigList: [
|
||||
{ required: true, message: '请选择目标用户群体', trigger: 'change' },
|
||||
{ required: true, message: '请选择目标用户群体', trigger: 'change' }
|
||||
],
|
||||
ruleFormTime: [
|
||||
{ required: true, message: '请选择活动时间', trigger: 'change' },
|
||||
{ required: true, message: '请选择活动时间', trigger: 'change' }
|
||||
],
|
||||
ruleFormTime1: [
|
||||
{ required: true, message: '请选择展示时间', trigger: 'change' },
|
||||
],
|
||||
{ required: true, message: '请选择展示时间', trigger: 'change' }
|
||||
]
|
||||
},
|
||||
lookOver: false,
|
||||
gradeList: [],
|
||||
|
@ -186,7 +214,7 @@ export default {
|
|||
pkId: '',
|
||||
waresConfigParam: [],
|
||||
consumeShieldConfigList: [],
|
||||
controlType:''
|
||||
controlType: ''
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
|
@ -219,7 +247,7 @@ export default {
|
|||
getDetails() {
|
||||
api
|
||||
.consumeDetails({
|
||||
pkId: this.pkId,
|
||||
pkId: this.pkId
|
||||
})
|
||||
.then((res) => {
|
||||
this.waresConfigParam = res.data.consumeRuleConfigParamList
|
||||
|
@ -235,15 +263,15 @@ export default {
|
|||
this.ruleForm.disEndDate = res.data.disEndDate
|
||||
this.$set(this.ruleForm, 'ruleFormTime', [
|
||||
res.data.actStartDate,
|
||||
res.data.actEndDate,
|
||||
res.data.actEndDate
|
||||
])
|
||||
this.$set(this.ruleForm, 'ruleFormTime1', [
|
||||
res.data.disStartDate,
|
||||
res.data.disEndDate,
|
||||
res.data.disEndDate
|
||||
])
|
||||
let arr1 = [],
|
||||
arr2 = [],
|
||||
arr3 = []
|
||||
const arr1 = []
|
||||
const arr2 = []
|
||||
const arr3 = []
|
||||
res.data.goalMemberConfigList.forEach((item) => {
|
||||
if (item.memberType == 1) {
|
||||
arr1.push(item.pkLevel)
|
||||
|
@ -262,7 +290,7 @@ export default {
|
|||
this.$refs.shieldConsumption.getPage(
|
||||
res.data.consumeShieldConfigList || ''
|
||||
)
|
||||
let that = this
|
||||
const that = this
|
||||
setTimeout(() => {
|
||||
that.getCheck()
|
||||
}, 50)
|
||||
|
@ -283,15 +311,15 @@ export default {
|
|||
this.ruleForm.disEndDate = this.addData.activityParam.disEndDate
|
||||
this.$set(this.ruleForm, 'ruleFormTime', [
|
||||
this.addData.activityParam.actStartDate,
|
||||
this.addData.activityParam.actEndDate,
|
||||
this.addData.activityParam.actEndDate
|
||||
])
|
||||
this.$set(this.ruleForm, 'ruleFormTime1', [
|
||||
this.addData.activityParam.disStartDate,
|
||||
this.addData.activityParam.disEndDate,
|
||||
this.addData.activityParam.disEndDate
|
||||
])
|
||||
let arr1 = [],
|
||||
arr2 = [],
|
||||
arr3 = []
|
||||
const arr1 = []
|
||||
const arr2 = []
|
||||
const arr3 = []
|
||||
this.addData.activityParam.goalMemberConfigList.forEach((item) => {
|
||||
if (item.memberType == 1) {
|
||||
arr1.push(item.pkLevel)
|
||||
|
@ -310,7 +338,7 @@ export default {
|
|||
this.$refs.shieldConsumption.getPage(
|
||||
this.addData.activityParam.consumeShieldConfigList || ''
|
||||
)
|
||||
let that = this
|
||||
const that = this
|
||||
setTimeout(() => {
|
||||
that.getCheck()
|
||||
}, 500)
|
||||
|
@ -327,28 +355,28 @@ export default {
|
|||
},
|
||||
// 单选
|
||||
getCheck() {
|
||||
let arr1 = []
|
||||
let arr2 = []
|
||||
let arr3 = []
|
||||
const arr1 = []
|
||||
const arr2 = []
|
||||
const arr3 = []
|
||||
// 等级
|
||||
this.ruleForm.levelList.forEach((item) => {
|
||||
arr1.push({
|
||||
memberType: 1,
|
||||
pkLevel: item,
|
||||
pkLevel: item
|
||||
})
|
||||
})
|
||||
// 奖衔
|
||||
this.ruleForm.realList.forEach((item) => {
|
||||
arr2.push({
|
||||
memberType: 2,
|
||||
pkLevel: item,
|
||||
pkLevel: item
|
||||
})
|
||||
})
|
||||
// 权限
|
||||
this.ruleForm.centerList.forEach((item) => {
|
||||
arr3.push({
|
||||
memberType: 3,
|
||||
pkLevel: item,
|
||||
pkLevel: item
|
||||
})
|
||||
})
|
||||
this.ruleForm.goalMemberConfigList = [...arr1, ...arr2, ...arr3]
|
||||
|
@ -442,44 +470,53 @@ export default {
|
|||
// })
|
||||
// }
|
||||
// })
|
||||
let a = Object.assign({}, this.ruleForm, {
|
||||
const a = Object.assign({}, this.ruleForm, {
|
||||
consumeRuleConfigParamList: this.$refs.setConsumptionInfo.allData,
|
||||
consumeShieldConfigList:
|
||||
this.$refs.shieldConsumption.consumeShieldConfigList,
|
||||
this.$refs.shieldConsumption.consumeShieldConfigList
|
||||
})
|
||||
let obj = Object.assign({
|
||||
const obj = Object.assign({
|
||||
controlType: this.controlType,
|
||||
activityParam: a,
|
||||
activityParam: a
|
||||
})
|
||||
if (this.controlType == 1) {
|
||||
this.$router.push({
|
||||
path: 'consumptionGiftZxqc',
|
||||
query: {
|
||||
data: JSON.stringify(obj),
|
||||
approvalBusiness: 738,
|
||||
},
|
||||
})
|
||||
} else if (this.controlType == 2) {
|
||||
this.$router.push({
|
||||
path: 'consumptionGiftZxqc',
|
||||
query: {
|
||||
data: JSON.stringify(obj),
|
||||
approvalBusiness: 739,
|
||||
},
|
||||
})
|
||||
} else if (this.controlType == 3) {
|
||||
this.$router.push({
|
||||
path: 'consumptionGiftZxqc',
|
||||
query: {
|
||||
data: JSON.stringify(obj),
|
||||
approvalBusiness: 740,
|
||||
},
|
||||
})
|
||||
}
|
||||
api.consumeRuleConfigSubmit(obj).then((res) => {
|
||||
if (res.code === 200) {
|
||||
this.$message({
|
||||
message: res.msg || '操作成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.$router.back()
|
||||
}
|
||||
})
|
||||
// if (this.controlType == 1) {
|
||||
// this.$router.push({
|
||||
// path: 'consumptionGiftZxqc',
|
||||
// query: {
|
||||
// data: JSON.stringify(obj),
|
||||
// approvalBusiness: 738
|
||||
// }
|
||||
// })
|
||||
// } else if (this.controlType == 2) {
|
||||
// this.$router.push({
|
||||
// path: 'consumptionGiftZxqc',
|
||||
// query: {
|
||||
// data: JSON.stringify(obj),
|
||||
// approvalBusiness: 739
|
||||
// }
|
||||
// })
|
||||
// } else if (this.controlType == 3) {
|
||||
// this.$router.push({
|
||||
// path: 'consumptionGiftZxqc',
|
||||
// query: {
|
||||
// data: JSON.stringify(obj),
|
||||
// approvalBusiness: 740
|
||||
// }
|
||||
// })
|
||||
// }
|
||||
}
|
||||
})
|
||||
},
|
||||
},
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
|
|
|
@ -1,547 +0,0 @@
|
|||
<!--
|
||||
* @Descripttion:
|
||||
* @version:
|
||||
* @Author: 王三华
|
||||
* @Date: 2024-03-13 10:32:48
|
||||
-->
|
||||
<!--
|
||||
* @Descripttion:
|
||||
* @version:
|
||||
* @Author: 王三华
|
||||
* @Date: 2023-05-09 10:57:15
|
||||
-->
|
||||
<template>
|
||||
<div class="page">
|
||||
<topBar
|
||||
v-if="topList.length > 0"
|
||||
:top-list="topList"
|
||||
:moren="moren"
|
||||
/>
|
||||
<div class="main">
|
||||
<div class="thetable">
|
||||
<div class="fontTitle"> {{ '在线签呈' }}</div>
|
||||
<div class="titleflex">
|
||||
<div>{{ '编号' }} :</div>
|
||||
<div>
|
||||
<el-radio-group v-model="allData.signType">
|
||||
<el-radio
|
||||
v-for="ctem in checkList"
|
||||
:key="ctem.value"
|
||||
:label="ctem.value"
|
||||
>{{ ctem.label }}</el-radio>
|
||||
</el-radio-group>
|
||||
</div>
|
||||
</div>
|
||||
<table
|
||||
id="tfhover"
|
||||
class="tftable"
|
||||
border="1"
|
||||
>
|
||||
<tr>
|
||||
<td
|
||||
colspan="1"
|
||||
width="190px"
|
||||
align="center"
|
||||
> {{ '发起部门' }} :</td>
|
||||
<td
|
||||
v-if="allData.signData"
|
||||
colspan="1"
|
||||
width="435px"
|
||||
>{{ allData.signData.deptName }}</td>
|
||||
<td
|
||||
colspan="1"
|
||||
width="140px"
|
||||
align="center"
|
||||
> {{ '发起人' }} :</td>
|
||||
<td
|
||||
v-if="allData.signData"
|
||||
colspan="1"
|
||||
>{{ allData.signData.userName }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td
|
||||
colspan="1"
|
||||
align="center"
|
||||
> {{ '主旨' }} :</td>
|
||||
<td
|
||||
v-if="allData.signData"
|
||||
colspan="1"
|
||||
>{{ allData.signData.approvalBusinessVal }}</td>
|
||||
<td
|
||||
colspan="1"
|
||||
align="center"
|
||||
> {{ '日期' }} :</td>
|
||||
<td
|
||||
v-if="allData.signData"
|
||||
colspan="1"
|
||||
>{{ allData.signData.creationTime }}</td>
|
||||
</tr>
|
||||
<!-- // 审批流程 -->
|
||||
<tr>
|
||||
<td
|
||||
colspan="1"
|
||||
align="center"
|
||||
> {{ '审批流程' }}</td>
|
||||
<td colspan="3">
|
||||
<div class="disflex">
|
||||
<span
|
||||
v-for="(ctem, cndex) in allData.signData.detailList"
|
||||
style="margin:0 5px 5px 0"
|
||||
>
|
||||
<el-select
|
||||
v-model="ctem.pkApprover"
|
||||
filterable
|
||||
size="mini"
|
||||
:placeholder="'请选择'"
|
||||
@change="getApprover"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in approbalList"
|
||||
:key="item.userId"
|
||||
:label="item.nickName + '(' +item.deptName+')'"
|
||||
:value="item.userId"
|
||||
/>
|
||||
</el-select>
|
||||
</span>
|
||||
<span style="margin:0 5px 5px 0">
|
||||
<i
|
||||
v-show="allData.signData.detailList.length>0"
|
||||
class="el-icon-remove-outline"
|
||||
style="font-size:18px;margin-right:5px"
|
||||
@click.stop="delData"
|
||||
/>
|
||||
<i
|
||||
class="el-icon-circle-plus-outline"
|
||||
style="font-size:18px"
|
||||
@click.stop="addData"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td
|
||||
colspan="1"
|
||||
align="center"
|
||||
>{{ '抄送人' }}</td>
|
||||
<td colspan="3">
|
||||
<div class="disflex">
|
||||
<span
|
||||
v-for="(ctem, cndex) in allData.signData.sendList"
|
||||
style="margin:0 5px 5px 0"
|
||||
>
|
||||
<el-select
|
||||
v-model="ctem.pkSend"
|
||||
filterable
|
||||
size="mini"
|
||||
:placeholder="'请选择'"
|
||||
@change="getApprover"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in userAllList"
|
||||
:key="item.userId"
|
||||
:label="item.nickName + '(' +item.deptName+')'"
|
||||
:value="item.userId"
|
||||
/>
|
||||
</el-select>
|
||||
</span>
|
||||
<span style="margin:0 5px 5px 0">
|
||||
<i
|
||||
v-show="allData.signData.sendList.length>0"
|
||||
class="el-icon-remove-outline"
|
||||
style="font-size:18px;margin-right:5px"
|
||||
@click.stop="delData1"
|
||||
/>
|
||||
<i
|
||||
class="el-icon-circle-plus-outline"
|
||||
style="font-size:18px"
|
||||
@click.stop="addData1"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td
|
||||
style="height: 190px"
|
||||
align="center"
|
||||
>{{ '情况说明' }}</td>
|
||||
<td
|
||||
colspan="3"
|
||||
style="padding: 0"
|
||||
>
|
||||
<div>
|
||||
<!-- <el-input type="textarea"
|
||||
:rows="6"
|
||||
:placeholder="'请输入'"
|
||||
v-model="allData.remark">
|
||||
</el-input> -->
|
||||
<noImgEditor
|
||||
v-model="allData.remark"
|
||||
:min-height="190"
|
||||
/>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td
|
||||
style="height: 193px"
|
||||
align="center"
|
||||
> {{ '业务诉求' }}</td>
|
||||
<td
|
||||
colspan="3"
|
||||
style="padding: 0;vertical-align: top;"
|
||||
>
|
||||
<div>
|
||||
<el-table
|
||||
:data="allData.updateParentParamList"
|
||||
style="width: 100%"
|
||||
:header-cell-style="{ background: '#EEEEEE' }"
|
||||
>
|
||||
<el-table-column
|
||||
v-for="ctem in allData.tableTit"
|
||||
:key="ctem.value"
|
||||
align="center"
|
||||
:prop="ctem.value"
|
||||
:label="ctem.label"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<div v-show="ctem.value== 'actExplain'">
|
||||
<div
|
||||
style="color: #48B2FD;text-decoration:underline;cursor: pointer"
|
||||
@click="details"
|
||||
>
|
||||
{{ '查看详情' }}
|
||||
</div>
|
||||
</div>
|
||||
<div v-show="ctem.value!= 'actExplain'">
|
||||
<div>
|
||||
{{ scope.row[ctem.value] }}
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td
|
||||
style="height: 190px"
|
||||
align="center"
|
||||
>{{ '附件' }}</td>
|
||||
<td
|
||||
colspan="3"
|
||||
style="padding: 0"
|
||||
>
|
||||
<div style="height: 100%;padding: 10px 20px">
|
||||
<el-upload
|
||||
class="upload-demo"
|
||||
:action="uploadImgUrl"
|
||||
:on-success="handleUploadSuccess"
|
||||
:on-remove="removeFile"
|
||||
multiple
|
||||
:headers="headers"
|
||||
:file-list="fileList"
|
||||
>
|
||||
<el-button
|
||||
size="small"
|
||||
type="primary"
|
||||
>{{ '点击上传' }}</el-button>
|
||||
</el-upload>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<div class="footer">
|
||||
<div style="margin: 0 auto">
|
||||
<el-button
|
||||
class="thebtn"
|
||||
@click="cancelCz"
|
||||
> {{ '取消' }}</el-button>
|
||||
<el-button
|
||||
type="primary"
|
||||
class="thebtn"
|
||||
@click="saveDate"
|
||||
> {{ '确认' }}</el-button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import topBar from '@/components/topBar'
|
||||
import * as man from '@/api/manage'
|
||||
import onlineSign from '../../dashboard/onlineSign.json'
|
||||
import { getToken } from '@/utils/auth'
|
||||
export default {
|
||||
name: 'Zxqc',
|
||||
components: {
|
||||
topBar
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
uploadImgUrl: process.env.VUE_APP_BASE_API + '/system/upload', // 上传的图片服务器地址
|
||||
headers: {
|
||||
Authorization: getToken()
|
||||
},
|
||||
onlineSign,
|
||||
moren: 'consumptionGiftZxqc',
|
||||
topList: [
|
||||
{
|
||||
name: '在线签呈',
|
||||
path: 'consumptionGiftZxqc'
|
||||
}
|
||||
],
|
||||
checkList: [],
|
||||
allData: {
|
||||
remark: '',
|
||||
signType: 1,
|
||||
fileList: [],
|
||||
signData: {
|
||||
detailList: [],
|
||||
sendList: []
|
||||
},
|
||||
approvalBusiness: ''
|
||||
},
|
||||
signDataList: [],
|
||||
fileList: [],
|
||||
approbalList: [],
|
||||
// 审批流程
|
||||
userAllList: [],
|
||||
allObj: {},
|
||||
controlType: '' // (1=新增,2=修改,3=删除)
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
// 业务诉求
|
||||
this.allObj = JSON.parse(this.$route.query.data)
|
||||
// let controlType = this.$route.query.controlType
|
||||
// if (controlType == 1) {
|
||||
// this.controlTypeVal = '新增'
|
||||
// } else if (controlType == 2) {
|
||||
// this.controlTypeVal = '修改'
|
||||
// } else {
|
||||
// this.controlTypeVal = '删除'
|
||||
// }
|
||||
this.allData.updateParentParamList = [this.allObj.activityParam]
|
||||
// 签呈类型
|
||||
this.allData.approvalBusiness = this.$route.query.approvalBusiness
|
||||
this.getSignData([this.allData.approvalBusiness])
|
||||
},
|
||||
methods: {
|
||||
details(code) {
|
||||
this.$router.push({
|
||||
path: '/marketing/consumptionGift/addConsumptionInfo',
|
||||
query: {
|
||||
controlType: 4,
|
||||
data: JSON.stringify(this.allObj)
|
||||
}
|
||||
})
|
||||
},
|
||||
getSignData(arr) {
|
||||
man.signData(arr).then((res) => {
|
||||
this.allData.signData = res.data[0]
|
||||
// 签呈表头数据添加到数组
|
||||
this.$set(this.allData, 'signType', 1)
|
||||
this.$set(this.allData, 'remark', '')
|
||||
this.$set(this.allData, 'fileList', [])
|
||||
// table表头添加到数组
|
||||
this.onlineSign.forEach((ctem) => {
|
||||
if (this.allData.approvalBusiness == ctem.id) {
|
||||
this.allData.tableTit = ctem.textList
|
||||
}
|
||||
})
|
||||
this.$forceUpdate()
|
||||
this.getApprove()
|
||||
this.getSignType()
|
||||
})
|
||||
},
|
||||
getApprove() {
|
||||
// 审批流程
|
||||
man.approvalUser().then((res) => {
|
||||
this.approbalList = res.data
|
||||
})
|
||||
man.userAll().then((res) => {
|
||||
this.userAllList = res.data
|
||||
})
|
||||
},
|
||||
getSignType() {
|
||||
man.signType().then((res) => {
|
||||
this.checkList = res.data
|
||||
})
|
||||
},
|
||||
saveDate() {
|
||||
// 审批流程
|
||||
this.allData.userIdList = this.allData.signData.detailList.map((item) => {
|
||||
return item.pkApprover
|
||||
})
|
||||
this.allData.userIdList = this.allData.userIdList.filter((item) => item)
|
||||
|
||||
// 抄送流程
|
||||
this.allData.sendIdList = this.allData.signData.sendList.map((item) => {
|
||||
return item.pkSend
|
||||
})
|
||||
this.allData.sendIdList = this.allData.sendIdList.filter((item) => item)
|
||||
|
||||
this.allData.fileList = this.fileList.map((item) => {
|
||||
return item.url
|
||||
})
|
||||
|
||||
const obj = {
|
||||
activityParam: this.allObj.activityParam,
|
||||
controlType: this.allObj.controlType,
|
||||
signType: this.allData.signType, // 普通件,急件,密件
|
||||
remark: this.allData.remark, // 备注
|
||||
fileList: this.allData.fileList, // 附件[]
|
||||
userIdList: this.allData.userIdList, // 审批流程[]
|
||||
sendIdList: this.allData.sendIdList // 审批流程[]
|
||||
}
|
||||
|
||||
man.consumeOnline(obj).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.$message({
|
||||
message: res.msg,
|
||||
type: 'success'
|
||||
})
|
||||
this.$router.push({
|
||||
path: '/marketing/consumptionGift/consumptionGiftList'
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
cancelCz() {
|
||||
this.$router.go(-1)
|
||||
},
|
||||
// 审批流程
|
||||
getApprover() {
|
||||
this.$nextTick(() => {
|
||||
this.$forceUpdate()
|
||||
})
|
||||
},
|
||||
// 审批流程
|
||||
addData() {
|
||||
const arr = JSON.parse(JSON.stringify(this.allData.signData.detailList))
|
||||
arr.push({
|
||||
pkApprover: ''
|
||||
})
|
||||
this.$set(this.allData.signData, 'detailList', arr)
|
||||
this.$forceUpdate()
|
||||
},
|
||||
// 审批流程
|
||||
addData1() {
|
||||
const arr = JSON.parse(JSON.stringify(this.allData.signData.sendList))
|
||||
arr.push({
|
||||
pkSend: ''
|
||||
})
|
||||
this.$set(this.allData.signData, 'sendList', arr)
|
||||
this.$forceUpdate()
|
||||
},
|
||||
// 抄送
|
||||
delData1() {
|
||||
this.allData.signData.sendList.pop()
|
||||
this.$forceUpdate()
|
||||
},
|
||||
// 审批流程
|
||||
delData() {
|
||||
this.allData.signData.detailList.pop()
|
||||
this.$forceUpdate()
|
||||
},
|
||||
|
||||
handleUploadSuccess(res) {
|
||||
if (res.code == 200) {
|
||||
this.fileList.push(res.data)
|
||||
} else {
|
||||
this.$message({
|
||||
type: 'error',
|
||||
message: '上传失败'
|
||||
})
|
||||
}
|
||||
},
|
||||
removeFile(file, fileList) {
|
||||
this.fileList.forEach((item, index) => {
|
||||
if (file.uid == item.uid) {
|
||||
this.fileList.splice(index, 1)
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
::v-deep .el-table thead {
|
||||
color: #000000;
|
||||
}
|
||||
.page {
|
||||
padding: 20px;
|
||||
background: #f9f9f9;
|
||||
font-size: 14px;
|
||||
.main {
|
||||
// margin-top: 20px;
|
||||
background: #ffffff;
|
||||
border-radius: 8px;
|
||||
box-shadow: 0px 2px 20px 0px rgba(238, 238, 238, 0.5);
|
||||
display: flex;
|
||||
margin: 0 auto;
|
||||
width: 100%;
|
||||
padding: 20px;
|
||||
flex-direction: column;
|
||||
}
|
||||
.thetable {
|
||||
margin: 0 auto;
|
||||
margin-bottom: 20px;
|
||||
.fontTitle {
|
||||
font-weight: bold;
|
||||
font-size: 24px;
|
||||
text-align: center;
|
||||
}
|
||||
.titleflex {
|
||||
display: flex;
|
||||
margin-top: 10px;
|
||||
margin-bottom: 10px;
|
||||
justify-content: space-between;
|
||||
}
|
||||
}
|
||||
.tftable {
|
||||
font-size: 14px;
|
||||
border-collapse: collapse;
|
||||
border-radius: 10px;
|
||||
width: 1060px;
|
||||
border: 1px solid #cccccc;
|
||||
.spbox {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: flex-end;
|
||||
}
|
||||
th {
|
||||
font-size: 14px;
|
||||
// padding: 20px;
|
||||
}
|
||||
tr td {
|
||||
font-size: 14px;
|
||||
padding: 10px 20px;
|
||||
height: 60px;
|
||||
}
|
||||
}
|
||||
.footer {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
padding: 15px 0;
|
||||
.thebtn {
|
||||
width: 120px;
|
||||
height: 38px;
|
||||
}
|
||||
}
|
||||
}
|
||||
// 审批流程
|
||||
.disflex {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
</style>
|
|
@ -10,11 +10,13 @@
|
|||
:topList="topList"
|
||||
:moren="moren"></topBar> -->
|
||||
<div class="topbox">
|
||||
<div class="levelList_i"
|
||||
:class="tabActive == item.id ? 'act' : ''"
|
||||
v-for="(item, index) in topList"
|
||||
:key="index"
|
||||
@click.prevent="handleLink(item.id)">
|
||||
<div
|
||||
v-for="(item, index) in topList"
|
||||
:key="index"
|
||||
class="levelList_i"
|
||||
:class="tabActive == item.id ? 'act' : ''"
|
||||
@click.prevent="handleLink(item.id)"
|
||||
>
|
||||
{{ item.name }}
|
||||
</div>
|
||||
</div>
|
||||
|
@ -22,82 +24,114 @@
|
|||
<!-- <div class="main_a"> -->
|
||||
<div class="main">
|
||||
<div v-show="tabActive==0">
|
||||
<div class="tit">{{'基本信息'}}</div>
|
||||
<div class="xian"></div>
|
||||
<el-form :model="ruleForm"
|
||||
:rules="rules"
|
||||
ref="ruleForm"
|
||||
label-width="auto"
|
||||
class="demo-ruleForm">
|
||||
<div class="tit">{{ '基本信息' }}</div>
|
||||
<div class="xian" />
|
||||
<el-form
|
||||
ref="ruleForm"
|
||||
:model="ruleForm"
|
||||
:rules="rules"
|
||||
label-width="auto"
|
||||
class="demo-ruleForm"
|
||||
>
|
||||
<el-row>
|
||||
<el-col :span="8">
|
||||
<el-form-item :label="'活动名称'"
|
||||
prop="actName">
|
||||
<el-input clearable
|
||||
v-model="ruleForm.actName"
|
||||
:disabled="lookOver"></el-input>
|
||||
<el-form-item
|
||||
:label="'活动名称'"
|
||||
prop="actName"
|
||||
>
|
||||
<el-input
|
||||
v-model="ruleForm.actName"
|
||||
clearable
|
||||
:disabled="lookOver"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="16">
|
||||
<el-form-item :label="'活动说明'"
|
||||
prop="actExplain">
|
||||
<el-form-item
|
||||
:label="'活动说明'"
|
||||
prop="actExplain"
|
||||
>
|
||||
<!-- <el-input clearable
|
||||
type="textarea"
|
||||
v-model="ruleForm.actExplain"
|
||||
:disabled="lookOver"></el-input> -->
|
||||
<editor ref="sptwEditor"
|
||||
:readOnly="lookOver"
|
||||
v-model="ruleForm.actExplain"
|
||||
:min-height="196"
|
||||
:uploadUrl="uploadImgUrl" />
|
||||
<editor
|
||||
ref="sptwEditor"
|
||||
v-model="ruleForm.actExplain"
|
||||
:read-only="lookOver"
|
||||
:min-height="196"
|
||||
:upload-url="uploadImgUrl"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="8">
|
||||
<el-form-item :label="'活动封面'"
|
||||
prop="actCover">
|
||||
<el-form-item
|
||||
:label="'活动封面'"
|
||||
prop="actCover"
|
||||
>
|
||||
<imageUpload v-model="ruleForm.actCover" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<el-form-item :label="'目标用户群体'"
|
||||
required>
|
||||
<el-form-item
|
||||
:label="'目标用户群体'"
|
||||
required
|
||||
>
|
||||
<div class="flexed">
|
||||
<el-checkbox class="flexed_l"
|
||||
@change="getCheckTit($event,1)"
|
||||
v-model="ruleForm.checked1">{{ '注册等级' }}</el-checkbox>
|
||||
<el-checkbox-group v-model="ruleForm.levelList"
|
||||
@change="getCheck">
|
||||
<el-checkbox v-for="item in gradeList"
|
||||
:key="item.pkId"
|
||||
:label="item.pkId">{{ item.gradeName }}</el-checkbox>
|
||||
<el-checkbox
|
||||
v-model="ruleForm.checked1"
|
||||
class="flexed_l"
|
||||
@change="getCheckTit($event,1)"
|
||||
>{{ '注册等级' }}</el-checkbox>
|
||||
<el-checkbox-group
|
||||
v-model="ruleForm.levelList"
|
||||
@change="getCheck"
|
||||
>
|
||||
<el-checkbox
|
||||
v-for="item in gradeList"
|
||||
:key="item.pkId"
|
||||
:label="item.pkId"
|
||||
>{{ item.gradeName }}</el-checkbox>
|
||||
</el-checkbox-group>
|
||||
</div>
|
||||
<div class="flexed">
|
||||
<el-checkbox class="flexed_l"
|
||||
@change="getCheckTit($event,2)"
|
||||
v-model="ruleForm.checked2">{{'真实奖衔'}}</el-checkbox>
|
||||
<el-checkbox-group v-model="ruleForm.realList"
|
||||
@change="getCheck">
|
||||
<el-checkbox v-for="item in awardsList"
|
||||
:key="item.pkId"
|
||||
:label="item.pkId">{{ item.awardsName }}</el-checkbox>
|
||||
<el-checkbox
|
||||
v-model="ruleForm.checked2"
|
||||
class="flexed_l"
|
||||
@change="getCheckTit($event,2)"
|
||||
>{{ '真实奖衔' }}</el-checkbox>
|
||||
<el-checkbox-group
|
||||
v-model="ruleForm.realList"
|
||||
@change="getCheck"
|
||||
>
|
||||
<el-checkbox
|
||||
v-for="item in awardsList"
|
||||
:key="item.pkId"
|
||||
:label="item.pkId"
|
||||
>{{ item.awardsName }}</el-checkbox>
|
||||
</el-checkbox-group>
|
||||
</div>
|
||||
<div class="flexed">
|
||||
<el-checkbox class="flexed_l"
|
||||
@change="getCheckTit($event,3)"
|
||||
v-model="ruleForm.checked3">{{'权限中心'}}</el-checkbox>
|
||||
<el-checkbox-group v-model="ruleForm.centerList"
|
||||
@change="getCheck">
|
||||
<el-checkbox v-for="item in registList"
|
||||
:key="item.value"
|
||||
:label="item.value">{{ item.label }}</el-checkbox>
|
||||
<el-checkbox
|
||||
v-model="ruleForm.checked3"
|
||||
class="flexed_l"
|
||||
@change="getCheckTit($event,3)"
|
||||
>{{ '权限中心' }}</el-checkbox>
|
||||
<el-checkbox-group
|
||||
v-model="ruleForm.centerList"
|
||||
@change="getCheck"
|
||||
>
|
||||
<el-checkbox
|
||||
v-for="item in registList"
|
||||
:key="item.value"
|
||||
:label="item.value"
|
||||
>{{ item.label }}</el-checkbox>
|
||||
</el-checkbox-group>
|
||||
</div>
|
||||
</el-form-item>
|
||||
|
@ -105,34 +139,40 @@
|
|||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="8">
|
||||
<el-form-item required
|
||||
:label="'活动时间'"
|
||||
prop="ruleFormTime">
|
||||
<el-date-picker :disabled="lookOver"
|
||||
v-model="ruleForm.ruleFormTime"
|
||||
@change="changeTime"
|
||||
value-format="yyyy-MM-dd HH:mm:ss"
|
||||
type="datetimerange"
|
||||
:range-separator="'至'"
|
||||
:start-placeholder="'开始日期'"
|
||||
:end-placeholder="'结束日期'">
|
||||
</el-date-picker>
|
||||
<el-form-item
|
||||
required
|
||||
:label="'活动时间'"
|
||||
prop="ruleFormTime"
|
||||
>
|
||||
<el-date-picker
|
||||
v-model="ruleForm.ruleFormTime"
|
||||
:disabled="lookOver"
|
||||
value-format="yyyy-MM-dd HH:mm:ss"
|
||||
type="datetimerange"
|
||||
:range-separator="'至'"
|
||||
:start-placeholder="'开始日期'"
|
||||
:end-placeholder="'结束日期'"
|
||||
@change="changeTime"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="8">
|
||||
<el-form-item :label="'展示时间'"
|
||||
prop="ruleFormTime1">
|
||||
<el-date-picker :disabled="lookOver"
|
||||
v-model="ruleForm.ruleFormTime1"
|
||||
@change="changeTime1"
|
||||
value-format="yyyy-MM-dd HH:mm:ss"
|
||||
type="datetimerange"
|
||||
:range-separator="'至'"
|
||||
:start-placeholder="'开始日期'"
|
||||
:end-placeholder="'结束日期'">
|
||||
</el-date-picker>
|
||||
<el-form-item
|
||||
:label="'展示时间'"
|
||||
prop="ruleFormTime1"
|
||||
>
|
||||
<el-date-picker
|
||||
v-model="ruleForm.ruleFormTime1"
|
||||
:disabled="lookOver"
|
||||
value-format="yyyy-MM-dd HH:mm:ss"
|
||||
type="datetimerange"
|
||||
:range-separator="'至'"
|
||||
:start-placeholder="'开始日期'"
|
||||
:end-placeholder="'结束日期'"
|
||||
@change="changeTime1"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
@ -140,17 +180,26 @@
|
|||
</el-form>
|
||||
</div>
|
||||
|
||||
<setGiftGoodsInfo v-show="tabActive==1"
|
||||
ref="setGiftGoodsInfo"></setGiftGoodsInfo>
|
||||
<setGiftGoodsInfo
|
||||
v-show="tabActive==1"
|
||||
ref="setGiftGoodsInfo"
|
||||
/>
|
||||
|
||||
</div>
|
||||
<div class="footer"
|
||||
v-show="controlType!=4">
|
||||
<el-button size="small"
|
||||
class="cancelBtn"> {{ '取消' }}</el-button>
|
||||
<el-button size="small"
|
||||
@click="submit('ruleForm')"
|
||||
class="sureBtn"> {{ '确认' }}</el-button>
|
||||
<div
|
||||
v-show="controlType!=4"
|
||||
class="footer"
|
||||
>
|
||||
<el-button
|
||||
size="small"
|
||||
class="cancelBtn"
|
||||
@click="$router.back()"
|
||||
> {{ '取消' }}</el-button>
|
||||
<el-button
|
||||
size="small"
|
||||
class="sureBtn"
|
||||
@click="submit('ruleForm')"
|
||||
> {{ '确认' }}</el-button>
|
||||
</div>
|
||||
<!-- </div> -->
|
||||
|
||||
|
@ -170,21 +219,21 @@ export default {
|
|||
Editor,
|
||||
topBar,
|
||||
ImageUpload,
|
||||
setGiftGoodsInfo,
|
||||
setGiftGoodsInfo
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
controlType:'',
|
||||
controlType: '',
|
||||
tabActive: 0,
|
||||
topList: [
|
||||
{
|
||||
name: '基本信息',
|
||||
id: 0,
|
||||
id: 0
|
||||
},
|
||||
{
|
||||
name: '规则设置',
|
||||
id: 1,
|
||||
},
|
||||
id: 1
|
||||
}
|
||||
],
|
||||
uploadImgUrl: process.env.VUE_APP_BASE_API + '/system/upload',
|
||||
ruleForm: {
|
||||
|
@ -194,34 +243,34 @@ export default {
|
|||
levelList: [],
|
||||
realList: [],
|
||||
centerList: [],
|
||||
goalMemberConfigList: [],
|
||||
goalMemberConfigList: []
|
||||
},
|
||||
rules: {
|
||||
actName: [
|
||||
{ required: true, message: '请输入活动名称', trigger: 'blur' },
|
||||
{ required: true, message: '请输入活动名称', trigger: 'blur' }
|
||||
],
|
||||
actExplain: [
|
||||
{ required: true, message: '请输入活动说明', trigger: 'blur' },
|
||||
{ required: true, message: '请输入活动说明', trigger: 'blur' }
|
||||
],
|
||||
actCover: [
|
||||
{ required: true, message: '请上传活动封面', trigger: 'change' },
|
||||
{ required: true, message: '请上传活动封面', trigger: 'change' }
|
||||
],
|
||||
goalMemberConfigList: [
|
||||
{ required: true, message: '请选择目标用户群体', trigger: 'change' },
|
||||
{ required: true, message: '请选择目标用户群体', trigger: 'change' }
|
||||
],
|
||||
ruleFormTime: [
|
||||
{ required: true, message: '请选择活动时间', trigger: 'change' },
|
||||
{ required: true, message: '请选择活动时间', trigger: 'change' }
|
||||
],
|
||||
ruleFormTime1: [
|
||||
{ required: true, message: '请选择展示时间', trigger: 'change' },
|
||||
],
|
||||
{ required: true, message: '请选择展示时间', trigger: 'change' }
|
||||
]
|
||||
},
|
||||
lookOver: false,
|
||||
gradeList: [],
|
||||
awardsList: [],
|
||||
registList: [],
|
||||
pkId: '',
|
||||
waresConfigParam: [],
|
||||
waresConfigParam: []
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
|
@ -259,7 +308,7 @@ export default {
|
|||
getDetails() {
|
||||
api
|
||||
.activityDetails({
|
||||
pkId: this.pkId,
|
||||
pkId: this.pkId
|
||||
})
|
||||
.then((res) => {
|
||||
this.waresConfigParam = res.data.waresConfigParam
|
||||
|
@ -274,15 +323,15 @@ export default {
|
|||
this.ruleForm.disEndDate = res.data.disEndDate
|
||||
this.$set(this.ruleForm, 'ruleFormTime', [
|
||||
res.data.actStartDate,
|
||||
res.data.actEndDate,
|
||||
res.data.actEndDate
|
||||
])
|
||||
this.$set(this.ruleForm, 'ruleFormTime1', [
|
||||
res.data.disStartDate,
|
||||
res.data.disEndDate,
|
||||
res.data.disEndDate
|
||||
])
|
||||
let arr1 = [],
|
||||
arr2 = [],
|
||||
arr3 = []
|
||||
const arr1 = []
|
||||
const arr2 = []
|
||||
const arr3 = []
|
||||
res.data.goalMemberConfigList.forEach((item) => {
|
||||
if (item.memberType == 1) {
|
||||
arr1.push(item.pkLevel)
|
||||
|
@ -297,8 +346,8 @@ export default {
|
|||
this.$set(this.ruleForm, 'centerList', arr3)
|
||||
this.$refs.setGiftGoodsInfo.getPage(
|
||||
res.data.waresConfigParam || ''
|
||||
)
|
||||
let that = this
|
||||
)
|
||||
const that = this
|
||||
setTimeout(() => {
|
||||
that.getCheck()
|
||||
}, 50)
|
||||
|
@ -319,15 +368,15 @@ export default {
|
|||
this.ruleForm.disEndDate = this.addData.activityParam.disEndDate
|
||||
this.$set(this.ruleForm, 'ruleFormTime', [
|
||||
this.addData.activityParam.actStartDate,
|
||||
this.addData.activityParam.actEndDate,
|
||||
this.addData.activityParam.actEndDate
|
||||
])
|
||||
this.$set(this.ruleForm, 'ruleFormTime1', [
|
||||
this.addData.activityParam.disStartDate,
|
||||
this.addData.activityParam.disEndDate,
|
||||
this.addData.activityParam.disEndDate
|
||||
])
|
||||
let arr1 = [],
|
||||
arr2 = [],
|
||||
arr3 = []
|
||||
const arr1 = []
|
||||
const arr2 = []
|
||||
const arr3 = []
|
||||
this.addData.activityParam.goalMemberConfigList.forEach((item) => {
|
||||
if (item.memberType == 1) {
|
||||
arr1.push(item.pkLevel)
|
||||
|
@ -343,7 +392,7 @@ export default {
|
|||
this.$refs.setGiftGoodsInfo.getPage(
|
||||
this.addData.activityParam.waresConfigParam || ''
|
||||
)
|
||||
let that = this
|
||||
const that = this
|
||||
setTimeout(() => {
|
||||
that.getCheck()
|
||||
}, 500)
|
||||
|
@ -360,28 +409,28 @@ export default {
|
|||
// 单选
|
||||
// 单选
|
||||
getCheck() {
|
||||
let arr1 = []
|
||||
let arr2 = []
|
||||
let arr3 = []
|
||||
const arr1 = []
|
||||
const arr2 = []
|
||||
const arr3 = []
|
||||
// 等级
|
||||
this.ruleForm.levelList.forEach((item) => {
|
||||
arr1.push({
|
||||
memberType: 1,
|
||||
pkLevel: item,
|
||||
pkLevel: item
|
||||
})
|
||||
})
|
||||
// 奖衔
|
||||
this.ruleForm.realList.forEach((item) => {
|
||||
arr2.push({
|
||||
memberType: 2,
|
||||
pkLevel: item,
|
||||
pkLevel: item
|
||||
})
|
||||
})
|
||||
// 权限
|
||||
this.ruleForm.centerList.forEach((item) => {
|
||||
arr3.push({
|
||||
memberType: 3,
|
||||
pkLevel: item,
|
||||
pkLevel: item
|
||||
})
|
||||
})
|
||||
this.ruleForm.goalMemberConfigList = [...arr1, ...arr2, ...arr3]
|
||||
|
@ -452,42 +501,53 @@ export default {
|
|||
submit() {
|
||||
this.$refs['ruleForm'].validate((valid) => {
|
||||
if (valid) {
|
||||
let a = Object.assign({}, this.ruleForm, {
|
||||
waresConfigParam: this.$refs.setGiftGoodsInfo.allData,
|
||||
const a = Object.assign({}, this.ruleForm, {
|
||||
waresConfigParam: this.$refs.setGiftGoodsInfo.allData
|
||||
})
|
||||
let obj = Object.assign({
|
||||
const obj = Object.assign({
|
||||
controlType: this.controlType,
|
||||
activityParam: a,
|
||||
activityParam: a
|
||||
})
|
||||
if (this.controlType == 1) {
|
||||
this.$router.push({
|
||||
path: 'giftGoodsZxqc',
|
||||
query: {
|
||||
data: JSON.stringify(obj),
|
||||
approvalBusiness: 729,
|
||||
},
|
||||
})
|
||||
} else if (this.controlType == 2) {
|
||||
this.$router.push({
|
||||
path: 'giftGoodsZxqc',
|
||||
query: {
|
||||
data: JSON.stringify(obj),
|
||||
approvalBusiness: 730,
|
||||
},
|
||||
})
|
||||
} else if (this.controlType == 3) {
|
||||
this.$router.push({
|
||||
path: 'giftGoodsZxqc',
|
||||
query: {
|
||||
data: JSON.stringify(obj),
|
||||
approvalBusiness: 731,
|
||||
},
|
||||
})
|
||||
}
|
||||
// const approvalBusinessEnumList = [729, 730, 731]
|
||||
// const approvalBusiness = approvalBusinessEnumList[this.controlType - 1]
|
||||
api.waresRuleConfigSubmit(obj).then((res) => {
|
||||
if (res.code === 200) {
|
||||
this.$message({
|
||||
message: res.msg || '操作成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.$router.back()
|
||||
}
|
||||
})
|
||||
// if (this.controlType == 1) {
|
||||
// this.$router.push({
|
||||
// path: 'giftGoodsZxqc',
|
||||
// query: {
|
||||
// data: JSON.stringify(obj),
|
||||
// approvalBusiness: 729
|
||||
// }
|
||||
// })
|
||||
// } else if (this.controlType == 2) {
|
||||
// this.$router.push({
|
||||
// path: 'giftGoodsZxqc',
|
||||
// query: {
|
||||
// data: JSON.stringify(obj),
|
||||
// approvalBusiness: 730
|
||||
// }
|
||||
// })
|
||||
// } else if (this.controlType == 3) {
|
||||
// this.$router.push({
|
||||
// path: 'giftGoodsZxqc',
|
||||
// query: {
|
||||
// data: JSON.stringify(obj),
|
||||
// approvalBusiness: 731
|
||||
// }
|
||||
// })
|
||||
// }
|
||||
}
|
||||
})
|
||||
},
|
||||
},
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
|
|
|
@ -1,541 +0,0 @@
|
|||
<!--
|
||||
* @Descripttion:
|
||||
* @version:
|
||||
* @Author: 王三华
|
||||
* @Date: 2023-05-09 10:57:15
|
||||
-->
|
||||
<template>
|
||||
<div class="page">
|
||||
<topBar
|
||||
v-if="topList.length > 0"
|
||||
:top-list="topList"
|
||||
:moren="moren"
|
||||
/>
|
||||
<div class="main">
|
||||
<div class="thetable">
|
||||
<div class="fontTitle"> {{ '在线签呈' }}</div>
|
||||
<div class="titleflex">
|
||||
<div>{{ '编号' }} :</div>
|
||||
<div>
|
||||
<el-radio-group v-model="allData.signType">
|
||||
<el-radio
|
||||
v-for="ctem in checkList"
|
||||
:key="ctem.value"
|
||||
:label="ctem.value"
|
||||
>{{ ctem.label }}</el-radio>
|
||||
</el-radio-group>
|
||||
</div>
|
||||
</div>
|
||||
<table
|
||||
id="tfhover"
|
||||
class="tftable"
|
||||
border="1"
|
||||
>
|
||||
<tr>
|
||||
<td
|
||||
colspan="1"
|
||||
width="190px"
|
||||
align="center"
|
||||
> {{ '发起部门' }} :</td>
|
||||
<td
|
||||
v-if="allData.signData"
|
||||
colspan="1"
|
||||
width="435px"
|
||||
>{{ allData.signData.deptName }}</td>
|
||||
<td
|
||||
colspan="1"
|
||||
width="140px"
|
||||
align="center"
|
||||
> {{ '发起人' }} :</td>
|
||||
<td
|
||||
v-if="allData.signData"
|
||||
colspan="1"
|
||||
>{{ allData.signData.userName }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td
|
||||
colspan="1"
|
||||
align="center"
|
||||
> {{ '主旨' }} :</td>
|
||||
<td
|
||||
v-if="allData.signData"
|
||||
colspan="1"
|
||||
>{{ allData.signData.approvalBusinessVal }}</td>
|
||||
<td
|
||||
colspan="1"
|
||||
align="center"
|
||||
> {{ '日期' }} :</td>
|
||||
<td
|
||||
v-if="allData.signData"
|
||||
colspan="1"
|
||||
>{{ allData.signData.creationTime }}</td>
|
||||
</tr>
|
||||
<!-- // 审批流程 -->
|
||||
<tr>
|
||||
<td
|
||||
colspan="1"
|
||||
align="center"
|
||||
> {{ '审批流程' }}</td>
|
||||
<td colspan="3">
|
||||
<div class="disflex">
|
||||
<span
|
||||
v-for="(ctem, cndex) in allData.signData.detailList"
|
||||
style="margin:0 5px 5px 0"
|
||||
>
|
||||
<el-select
|
||||
v-model="ctem.pkApprover"
|
||||
filterable
|
||||
size="mini"
|
||||
:placeholder="'请选择'"
|
||||
@change="getApprover"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in approbalList"
|
||||
:key="item.userId"
|
||||
:label="item.nickName + '(' +item.deptName+')'"
|
||||
:value="item.userId"
|
||||
/>
|
||||
</el-select>
|
||||
</span>
|
||||
<span style="margin:0 5px 5px 0">
|
||||
<i
|
||||
v-show="allData.signData.detailList.length>0"
|
||||
class="el-icon-remove-outline"
|
||||
style="font-size:18px;margin-right:5px"
|
||||
@click.stop="delData"
|
||||
/>
|
||||
<i
|
||||
class="el-icon-circle-plus-outline"
|
||||
style="font-size:18px"
|
||||
@click.stop="addData"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td
|
||||
colspan="1"
|
||||
align="center"
|
||||
>{{ '抄送人' }}</td>
|
||||
<td colspan="3">
|
||||
<div class="disflex">
|
||||
<span
|
||||
v-for="(ctem, cndex) in allData.signData.sendList"
|
||||
style="margin:0 5px 5px 0"
|
||||
>
|
||||
<el-select
|
||||
v-model="ctem.pkSend"
|
||||
filterable
|
||||
size="mini"
|
||||
:placeholder="'请选择'"
|
||||
@change="getApprover"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in userAllList"
|
||||
:key="item.userId"
|
||||
:label="item.nickName + '(' +item.deptName+')'"
|
||||
:value="item.userId"
|
||||
/>
|
||||
</el-select>
|
||||
</span>
|
||||
<span style="margin:0 5px 5px 0">
|
||||
<i
|
||||
v-show="allData.signData.sendList.length>0"
|
||||
class="el-icon-remove-outline"
|
||||
style="font-size:18px;margin-right:5px"
|
||||
@click.stop="delData1"
|
||||
/>
|
||||
<i
|
||||
class="el-icon-circle-plus-outline"
|
||||
style="font-size:18px"
|
||||
@click.stop="addData1"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td
|
||||
style="height: 190px"
|
||||
align="center"
|
||||
>{{ '情况说明' }}</td>
|
||||
<td
|
||||
colspan="3"
|
||||
style="padding: 0"
|
||||
>
|
||||
<div>
|
||||
<!-- <el-input type="textarea"
|
||||
:rows="6"
|
||||
:placeholder="'请输入'"
|
||||
v-model="allData.remark">
|
||||
</el-input> -->
|
||||
<noImgEditor
|
||||
v-model="allData.remark"
|
||||
:min-height="190"
|
||||
/>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td
|
||||
style="height: 193px"
|
||||
align="center"
|
||||
> {{ '业务诉求' }}</td>
|
||||
<td
|
||||
colspan="3"
|
||||
style="padding: 0;vertical-align: top;"
|
||||
>
|
||||
<div>
|
||||
<el-table
|
||||
:data="allData.updateParentParamList"
|
||||
style="width: 100%"
|
||||
:header-cell-style="{ background: '#EEEEEE' }"
|
||||
>
|
||||
<el-table-column
|
||||
v-for="ctem in allData.tableTit"
|
||||
:key="ctem.value"
|
||||
align="center"
|
||||
:prop="ctem.value"
|
||||
:label="ctem.label"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<div v-show="ctem.value== 'actExplain'">
|
||||
<div
|
||||
style="color: #48B2FD;text-decoration:underline;cursor: pointer"
|
||||
@click="details"
|
||||
>
|
||||
{{ '查看详情' }}
|
||||
</div>
|
||||
</div>
|
||||
<div v-show="ctem.value!= 'actExplain'">
|
||||
<div>
|
||||
{{ scope.row[ctem.value] }}
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td
|
||||
style="height: 190px"
|
||||
align="center"
|
||||
>{{ '附件' }}</td>
|
||||
<td
|
||||
colspan="3"
|
||||
style="padding: 0"
|
||||
>
|
||||
<div style="height: 100%;padding: 10px 20px">
|
||||
<el-upload
|
||||
class="upload-demo"
|
||||
:action="uploadImgUrl"
|
||||
:on-success="handleUploadSuccess"
|
||||
:on-remove="removeFile"
|
||||
multiple
|
||||
:headers="headers"
|
||||
:file-list="fileList"
|
||||
>
|
||||
<el-button
|
||||
size="small"
|
||||
type="primary"
|
||||
>{{ '点击上传' }}</el-button>
|
||||
</el-upload>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<div class="footer">
|
||||
<div style="margin: 0 auto">
|
||||
<el-button
|
||||
class="thebtn"
|
||||
@click="cancelCz"
|
||||
> {{ '取消' }}</el-button>
|
||||
<el-button
|
||||
type="primary"
|
||||
class="thebtn"
|
||||
@click="saveDate"
|
||||
> {{ '确认' }}</el-button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import topBar from '@/components/topBar'
|
||||
import * as man from '@/api/manage'
|
||||
import onlineSign from '../../dashboard/onlineSign.json'
|
||||
import { getToken } from '@/utils/auth'
|
||||
export default {
|
||||
name: 'Zxqc',
|
||||
components: {
|
||||
topBar
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
uploadImgUrl: process.env.VUE_APP_BASE_API + '/system/upload', // 上传的图片服务器地址
|
||||
headers: {
|
||||
Authorization: getToken()
|
||||
},
|
||||
onlineSign,
|
||||
moren: 'giftGoodsZxqc',
|
||||
topList: [
|
||||
{
|
||||
name: '在线签呈',
|
||||
path: 'giftGoodsZxqc'
|
||||
}
|
||||
],
|
||||
checkList: [],
|
||||
allData: {
|
||||
remark: '',
|
||||
signType: 1,
|
||||
fileList: [],
|
||||
signData: {
|
||||
detailList: [],
|
||||
sendList: []
|
||||
},
|
||||
approvalBusiness: ''
|
||||
},
|
||||
signDataList: [],
|
||||
fileList: [],
|
||||
approbalList: [],
|
||||
// 审批流程
|
||||
userAllList: [],
|
||||
allObj: {},
|
||||
controlType: '' // (1=新增,2=修改,3=删除)
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
// 业务诉求
|
||||
this.allObj = JSON.parse(this.$route.query.data)
|
||||
// let controlType = this.$route.query.controlType
|
||||
// if (controlType == 1) {
|
||||
// this.controlTypeVal = '新增'
|
||||
// } else if (controlType == 2) {
|
||||
// this.controlTypeVal = '修改'
|
||||
// } else {
|
||||
// this.controlTypeVal = '删除'
|
||||
// }
|
||||
this.allData.updateParentParamList = [this.allObj.activityParam]
|
||||
// 签呈类型
|
||||
this.allData.approvalBusiness = this.$route.query.approvalBusiness
|
||||
this.getSignData([this.allData.approvalBusiness])
|
||||
},
|
||||
methods: {
|
||||
details(code) {
|
||||
this.$router.push({
|
||||
path: '/marketing/giftGoods/addGiftGoodsInfo',
|
||||
query: {
|
||||
controlType: 4,
|
||||
data: JSON.stringify(this.allObj)
|
||||
}
|
||||
})
|
||||
},
|
||||
getSignData(arr) {
|
||||
man.signData(arr).then((res) => {
|
||||
this.allData.signData = res.data[0]
|
||||
// 签呈表头数据添加到数组
|
||||
this.$set(this.allData, 'signType', 1)
|
||||
this.$set(this.allData, 'remark', '')
|
||||
this.$set(this.allData, 'fileList', [])
|
||||
// table表头添加到数组
|
||||
this.onlineSign.forEach((ctem) => {
|
||||
if (this.allData.approvalBusiness == ctem.id) {
|
||||
this.allData.tableTit = ctem.textList
|
||||
}
|
||||
})
|
||||
this.$forceUpdate()
|
||||
this.getApprove()
|
||||
this.getSignType()
|
||||
})
|
||||
},
|
||||
getApprove() {
|
||||
// 审批流程
|
||||
man.approvalUser().then((res) => {
|
||||
this.approbalList = res.data
|
||||
})
|
||||
man.userAll().then((res) => {
|
||||
this.userAllList = res.data
|
||||
})
|
||||
},
|
||||
getSignType() {
|
||||
man.signType().then((res) => {
|
||||
this.checkList = res.data
|
||||
})
|
||||
},
|
||||
saveDate() {
|
||||
// 审批流程
|
||||
this.allData.userIdList = this.allData.signData.detailList.map((item) => {
|
||||
return item.pkApprover
|
||||
})
|
||||
this.allData.userIdList = this.allData.userIdList.filter((item) => item)
|
||||
|
||||
// 抄送流程
|
||||
this.allData.sendIdList = this.allData.signData.sendList.map((item) => {
|
||||
return item.pkSend
|
||||
})
|
||||
this.allData.sendIdList = this.allData.sendIdList.filter((item) => item)
|
||||
|
||||
this.allData.fileList = this.fileList.map((item) => {
|
||||
return item.url
|
||||
})
|
||||
|
||||
const obj = {
|
||||
activityParam: this.allObj.activityParam,
|
||||
controlType: this.allObj.controlType,
|
||||
signType: this.allData.signType, // 普通件,急件,密件
|
||||
remark: this.allData.remark, // 备注
|
||||
fileList: this.allData.fileList, // 附件[]
|
||||
userIdList: this.allData.userIdList, // 审批流程[]
|
||||
sendIdList: this.allData.sendIdList // 审批流程[]
|
||||
}
|
||||
|
||||
man.waresOnline(obj).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.$message({
|
||||
message: res.msg,
|
||||
type: 'success'
|
||||
})
|
||||
this.$router.push({
|
||||
path: '/marketing/giftGoods/giftGoodsList'
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
cancelCz() {
|
||||
this.$router.go(-1)
|
||||
},
|
||||
// 审批流程
|
||||
getApprover() {
|
||||
this.$nextTick(() => {
|
||||
this.$forceUpdate()
|
||||
})
|
||||
},
|
||||
// 审批流程
|
||||
addData() {
|
||||
const arr = JSON.parse(JSON.stringify(this.allData.signData.detailList))
|
||||
arr.push({
|
||||
pkApprover: ''
|
||||
})
|
||||
this.$set(this.allData.signData, 'detailList', arr)
|
||||
this.$forceUpdate()
|
||||
},
|
||||
// 审批流程
|
||||
addData1() {
|
||||
const arr = JSON.parse(JSON.stringify(this.allData.signData.sendList))
|
||||
arr.push({
|
||||
pkSend: ''
|
||||
})
|
||||
this.$set(this.allData.signData, 'sendList', arr)
|
||||
this.$forceUpdate()
|
||||
},
|
||||
// 抄送
|
||||
delData1() {
|
||||
this.allData.signData.sendList.pop()
|
||||
this.$forceUpdate()
|
||||
},
|
||||
// 审批流程
|
||||
delData() {
|
||||
this.allData.signData.detailList.pop()
|
||||
this.$forceUpdate()
|
||||
},
|
||||
|
||||
handleUploadSuccess(res) {
|
||||
if (res.code == 200) {
|
||||
this.fileList.push(res.data)
|
||||
} else {
|
||||
this.$message({
|
||||
type: 'error',
|
||||
message: '上传失败'
|
||||
})
|
||||
}
|
||||
},
|
||||
removeFile(file, fileList) {
|
||||
this.fileList.forEach((item, index) => {
|
||||
if (file.uid == item.uid) {
|
||||
this.fileList.splice(index, 1)
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
::v-deep .el-table thead {
|
||||
color: #000000;
|
||||
}
|
||||
.page {
|
||||
padding: 20px;
|
||||
background: #f9f9f9;
|
||||
font-size: 14px;
|
||||
.main {
|
||||
// margin-top: 20px;
|
||||
background: #ffffff;
|
||||
border-radius: 8px;
|
||||
box-shadow: 0px 2px 20px 0px rgba(238, 238, 238, 0.5);
|
||||
display: flex;
|
||||
margin: 0 auto;
|
||||
width: 100%;
|
||||
padding: 20px;
|
||||
flex-direction: column;
|
||||
}
|
||||
.thetable {
|
||||
margin: 0 auto;
|
||||
margin-bottom: 20px;
|
||||
.fontTitle {
|
||||
font-weight: bold;
|
||||
font-size: 24px;
|
||||
text-align: center;
|
||||
}
|
||||
.titleflex {
|
||||
display: flex;
|
||||
margin-top: 10px;
|
||||
margin-bottom: 10px;
|
||||
justify-content: space-between;
|
||||
}
|
||||
}
|
||||
.tftable {
|
||||
font-size: 14px;
|
||||
border-collapse: collapse;
|
||||
border-radius: 10px;
|
||||
width: 1060px;
|
||||
border: 1px solid #cccccc;
|
||||
.spbox {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: flex-end;
|
||||
}
|
||||
th {
|
||||
font-size: 14px;
|
||||
// padding: 20px;
|
||||
}
|
||||
tr td {
|
||||
font-size: 14px;
|
||||
padding: 10px 20px;
|
||||
height: 60px;
|
||||
}
|
||||
}
|
||||
.footer {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
padding: 15px 0;
|
||||
.thebtn {
|
||||
width: 120px;
|
||||
height: 38px;
|
||||
}
|
||||
}
|
||||
}
|
||||
// 审批流程
|
||||
.disflex {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
</style>
|
|
@ -162,7 +162,7 @@
|
|||
/>
|
||||
</div>
|
||||
<div v-show="controlType != 4" class="footer">
|
||||
<el-button size="small" class="cancelBtn">
|
||||
<el-button size="small" class="cancelBtn" @click="$router.back()">
|
||||
{{ '取消' }}</el-button>
|
||||
<el-button size="small" class="sureBtn" @click="submit('ruleForm')">
|
||||
{{ '确认' }}</el-button>
|
||||
|
@ -477,32 +477,40 @@ export default {
|
|||
mcrList: this.$refs.setConsumptionInfo.mcrList
|
||||
}
|
||||
)
|
||||
console.log(obj, '111111111111111111111')
|
||||
if (this.controlType == 1) {
|
||||
this.$router.push({
|
||||
path: 'memberConsumptionGiftZxqc',
|
||||
query: {
|
||||
data: JSON.stringify(obj),
|
||||
approvalBusiness: 749
|
||||
}
|
||||
})
|
||||
} else if (this.controlType == 2) {
|
||||
this.$router.push({
|
||||
path: 'memberConsumptionGiftZxqc',
|
||||
query: {
|
||||
data: JSON.stringify(obj),
|
||||
approvalBusiness: 750
|
||||
}
|
||||
})
|
||||
} else if (this.controlType == 3) {
|
||||
this.$router.push({
|
||||
path: 'memberConsumptionGiftZxqc',
|
||||
query: {
|
||||
data: JSON.stringify(obj),
|
||||
approvalBusiness: 751
|
||||
}
|
||||
})
|
||||
}
|
||||
api.memberConsumeRuleSubmit(obj).then((res) => {
|
||||
if (res.code === 200) {
|
||||
this.$message({
|
||||
message: res.msg || '操作成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.$router.back()
|
||||
}
|
||||
})
|
||||
// if (this.controlType == 1) {
|
||||
// this.$router.push({
|
||||
// path: 'memberConsumptionGiftZxqc',
|
||||
// query: {
|
||||
// data: JSON.stringify(obj),
|
||||
// approvalBusiness: 749
|
||||
// }
|
||||
// })
|
||||
// } else if (this.controlType == 2) {
|
||||
// this.$router.push({
|
||||
// path: 'memberConsumptionGiftZxqc',
|
||||
// query: {
|
||||
// data: JSON.stringify(obj),
|
||||
// approvalBusiness: 750
|
||||
// }
|
||||
// })
|
||||
// } else if (this.controlType == 3) {
|
||||
// this.$router.push({
|
||||
// path: 'memberConsumptionGiftZxqc',
|
||||
// query: {
|
||||
// data: JSON.stringify(obj),
|
||||
// approvalBusiness: 751
|
||||
// }
|
||||
// })
|
||||
// }
|
||||
}
|
||||
})
|
||||
}
|
||||
|
|
|
@ -1,487 +0,0 @@
|
|||
<template>
|
||||
<div class="page">
|
||||
<topBar
|
||||
v-if="topList.length > 0"
|
||||
:top-list="topList"
|
||||
:moren="moren"
|
||||
/>
|
||||
<div class="main">
|
||||
<div class="thetable">
|
||||
<div class="fontTitle">{{ '在线签呈' }}</div>
|
||||
<div class="titleflex">
|
||||
<div>{{ '编号' }} :</div>
|
||||
<div>
|
||||
<el-radio-group v-model="allData.signType">
|
||||
<el-radio
|
||||
v-for="ctem in checkList"
|
||||
:key="ctem.value"
|
||||
:label="ctem.value"
|
||||
>{{ ctem.label }}</el-radio>
|
||||
</el-radio-group>
|
||||
</div>
|
||||
</div>
|
||||
<table id="tfhover" class="tftable" border="1">
|
||||
<tr>
|
||||
<td colspan="1" width="190px" align="center">
|
||||
{{ '发起部门' }} :
|
||||
</td>
|
||||
<td v-if="allData.signData" colspan="1" width="435px">
|
||||
{{ allData.signData.deptName }}
|
||||
</td>
|
||||
<td colspan="1" width="140px" align="center">
|
||||
{{ '发起人' }} :
|
||||
</td>
|
||||
<td v-if="allData.signData" colspan="1">
|
||||
{{ allData.signData.userName }}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="1" align="center">{{ '主旨' }} :</td>
|
||||
<td v-if="allData.signData" colspan="1">
|
||||
{{ allData.signData.approvalBusinessVal }}
|
||||
</td>
|
||||
<td colspan="1" align="center">{{ '日期' }} :</td>
|
||||
<td v-if="allData.signData" colspan="1">
|
||||
{{ allData.signData.creationTime }}
|
||||
</td>
|
||||
</tr>
|
||||
<!-- // 审批流程 -->
|
||||
<tr>
|
||||
<td colspan="1" align="center">{{ '审批流程' }}</td>
|
||||
<td colspan="3">
|
||||
<div class="disflex">
|
||||
<span
|
||||
v-for="(ctem, cndex) in allData.signData.detailList"
|
||||
style="margin: 0 5px 5px 0"
|
||||
>
|
||||
<el-select
|
||||
v-model="ctem.pkApprover"
|
||||
filterable
|
||||
size="mini"
|
||||
:placeholder="'请选择'"
|
||||
@change="getApprover"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in approbalList"
|
||||
:key="item.userId"
|
||||
:label="item.nickName + '(' + item.deptName + ')'"
|
||||
:value="item.userId"
|
||||
/>
|
||||
</el-select>
|
||||
</span>
|
||||
<span style="margin: 0 5px 5px 0">
|
||||
<i
|
||||
v-show="allData.signData.detailList.length > 0"
|
||||
class="el-icon-remove-outline"
|
||||
style="font-size: 18px; margin-right: 5px"
|
||||
@click.stop="delData"
|
||||
/>
|
||||
<i
|
||||
class="el-icon-circle-plus-outline"
|
||||
style="font-size: 18px"
|
||||
@click.stop="addData"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="1" align="center">{{ '抄送人' }}</td>
|
||||
<td colspan="3">
|
||||
<div class="disflex">
|
||||
<span
|
||||
v-for="(ctem, cndex) in allData.signData.sendList"
|
||||
style="margin: 0 5px 5px 0"
|
||||
>
|
||||
<el-select
|
||||
v-model="ctem.pkSend"
|
||||
filterable
|
||||
size="mini"
|
||||
:placeholder="'请选择'"
|
||||
@change="getApprover"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in userAllList"
|
||||
:key="item.userId"
|
||||
:label="item.nickName + '(' + item.deptName + ')'"
|
||||
:value="item.userId"
|
||||
/>
|
||||
</el-select>
|
||||
</span>
|
||||
<span style="margin: 0 5px 5px 0">
|
||||
<i
|
||||
v-show="allData.signData.sendList.length > 0"
|
||||
class="el-icon-remove-outline"
|
||||
style="font-size: 18px; margin-right: 5px"
|
||||
@click.stop="delData1"
|
||||
/>
|
||||
<i
|
||||
class="el-icon-circle-plus-outline"
|
||||
style="font-size: 18px"
|
||||
@click.stop="addData1"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="height: 190px" align="center">{{ '情况说明' }}</td>
|
||||
<td colspan="3" style="padding: 0">
|
||||
<div>
|
||||
<!-- <el-input type="textarea"
|
||||
:rows="6"
|
||||
:placeholder="'请输入'"
|
||||
v-model="allData.remark">
|
||||
</el-input> -->
|
||||
<noImgEditor v-model="allData.remark" :min-height="190" />
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="height: 193px" align="center">{{ '业务诉求' }}</td>
|
||||
<td colspan="3" style="padding: 0; vertical-align: top">
|
||||
<div>
|
||||
<el-table
|
||||
:data="allData.updateParentParamList"
|
||||
style="width: 100%"
|
||||
:header-cell-style="{ background: '#EEEEEE' }"
|
||||
>
|
||||
<el-table-column
|
||||
v-for="ctem in allData.tableTit"
|
||||
:key="ctem.value"
|
||||
align="center"
|
||||
:prop="ctem.value"
|
||||
:label="ctem.label"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<div v-show="ctem.value == 'actExplain'">
|
||||
<div
|
||||
style="
|
||||
color: #48b2fd;
|
||||
text-decoration: underline;
|
||||
cursor: pointer;
|
||||
"
|
||||
@click="details"
|
||||
>
|
||||
{{ '查看详情' }}
|
||||
</div>
|
||||
</div>
|
||||
<div v-show="ctem.value != 'actExplain'">
|
||||
<div>
|
||||
{{ scope.row[ctem.value] }}
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="height: 190px" align="center">{{ '附件' }}</td>
|
||||
<td colspan="3" style="padding: 0">
|
||||
<div style="height: 100%; padding: 10px 20px">
|
||||
<el-upload
|
||||
class="upload-demo"
|
||||
:action="uploadImgUrl"
|
||||
:on-success="handleUploadSuccess"
|
||||
:on-remove="removeFile"
|
||||
multiple
|
||||
:headers="headers"
|
||||
:file-list="fileList"
|
||||
>
|
||||
<el-button size="small" type="primary">{{
|
||||
'点击上传'
|
||||
}}</el-button>
|
||||
</el-upload>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<div class="footer">
|
||||
<div style="margin: 0 auto">
|
||||
<el-button class="thebtn" @click="cancelCz">
|
||||
{{ '取消' }}</el-button>
|
||||
<el-button type="primary" class="thebtn" @click="saveDate">
|
||||
{{ '确认' }}</el-button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import topBar from '@/components/topBar'
|
||||
import * as man from '@/api/manage'
|
||||
import onlineSign from '../../dashboard/onlineSign.json'
|
||||
import { getToken } from '@/utils/auth'
|
||||
export default {
|
||||
name: 'Zxqc',
|
||||
components: {
|
||||
topBar
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
uploadImgUrl: process.env.VUE_APP_BASE_API + '/system/upload', // 上传的图片服务器地址
|
||||
headers: {
|
||||
Authorization: getToken()
|
||||
},
|
||||
onlineSign,
|
||||
moren: 'memberConsumptionGiftZxqc',
|
||||
topList: [
|
||||
{
|
||||
name: '在线签呈',
|
||||
path: 'memberConsumptionGiftZxqc'
|
||||
}
|
||||
],
|
||||
checkList: [],
|
||||
allData: {
|
||||
remark: '',
|
||||
signType: 1,
|
||||
fileList: [],
|
||||
signData: {
|
||||
detailList: [],
|
||||
sendList: []
|
||||
},
|
||||
approvalBusiness: ''
|
||||
},
|
||||
signDataList: [],
|
||||
fileList: [],
|
||||
approbalList: [],
|
||||
// 审批流程
|
||||
userAllList: [],
|
||||
allObj: {},
|
||||
controlType: '' // (1=新增,2=修改,3=删除)
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
// 业务诉求
|
||||
this.allObj = JSON.parse(this.$route.query.data)
|
||||
// let controlType = this.$route.query.controlType
|
||||
// if (controlType == 1) {
|
||||
// this.controlTypeVal = '新增'
|
||||
// } else if (controlType == 2) {
|
||||
// this.controlTypeVal = '修改'
|
||||
// } else {
|
||||
// this.controlTypeVal = '删除'
|
||||
// }
|
||||
this.allData.updateParentParamList = [this.allObj.activityParam]
|
||||
// 签呈类型
|
||||
this.allData.approvalBusiness = this.$route.query.approvalBusiness
|
||||
this.getSignData([this.allData.approvalBusiness])
|
||||
},
|
||||
methods: {
|
||||
details(code) {
|
||||
this.$router.push({
|
||||
path: 'memberAddConsumptionInfo',
|
||||
query: {
|
||||
controlType: 4,
|
||||
data: JSON.stringify(this.allObj)
|
||||
}
|
||||
})
|
||||
},
|
||||
getSignData(arr) {
|
||||
man.signData(arr).then((res) => {
|
||||
this.allData.signData = res.data[0]
|
||||
// 签呈表头数据添加到数组
|
||||
this.$set(this.allData, 'signType', 1)
|
||||
this.$set(this.allData, 'remark', '')
|
||||
this.$set(this.allData, 'fileList', [])
|
||||
// table表头添加到数组
|
||||
this.onlineSign.forEach((ctem) => {
|
||||
if (this.allData.approvalBusiness == ctem.id) {
|
||||
this.allData.tableTit = ctem.textList
|
||||
}
|
||||
})
|
||||
this.$forceUpdate()
|
||||
this.getApprove()
|
||||
this.getSignType()
|
||||
})
|
||||
},
|
||||
getApprove() {
|
||||
// 审批流程
|
||||
man.approvalUser().then((res) => {
|
||||
this.approbalList = res.data
|
||||
})
|
||||
man.userAll().then((res) => {
|
||||
this.userAllList = res.data
|
||||
})
|
||||
},
|
||||
getSignType() {
|
||||
man.signType().then((res) => {
|
||||
this.checkList = res.data
|
||||
})
|
||||
},
|
||||
saveDate() {
|
||||
// 审批流程
|
||||
this.allData.userIdList = this.allData.signData.detailList.map((item) => {
|
||||
return item.pkApprover
|
||||
})
|
||||
this.allData.userIdList = this.allData.userIdList.filter((item) => item)
|
||||
|
||||
// 抄送流程
|
||||
this.allData.sendIdList = this.allData.signData.sendList.map((item) => {
|
||||
return item.pkSend
|
||||
})
|
||||
this.allData.sendIdList = this.allData.sendIdList.filter((item) => item)
|
||||
|
||||
this.allData.fileList = this.fileList.map((item) => {
|
||||
return item.url
|
||||
})
|
||||
|
||||
const obj = {
|
||||
activityParam: this.allObj.activityParam,
|
||||
mcrList: this.allObj.mcrList,
|
||||
controlType: this.allObj.controlType,
|
||||
signType: this.allData.signType, // 普通件,急件,密件
|
||||
remark: this.allData.remark, // 备注
|
||||
fileList: this.allData.fileList, // 附件[]
|
||||
userIdList: this.allData.userIdList, // 审批流程[]
|
||||
sendIdList: this.allData.sendIdList // 审批流程[]
|
||||
}
|
||||
|
||||
man.consumeOnlinePetition(obj).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.$message({
|
||||
message: res.msg,
|
||||
type: 'success'
|
||||
})
|
||||
this.$router.push({
|
||||
path: 'memberConsumptionGiftList'
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
cancelCz() {
|
||||
this.$router.go(-1)
|
||||
},
|
||||
// 审批流程
|
||||
getApprover() {
|
||||
this.$nextTick(() => {
|
||||
this.$forceUpdate()
|
||||
})
|
||||
},
|
||||
// 审批流程
|
||||
addData() {
|
||||
const arr = JSON.parse(JSON.stringify(this.allData.signData.detailList))
|
||||
arr.push({
|
||||
pkApprover: ''
|
||||
})
|
||||
this.$set(this.allData.signData, 'detailList', arr)
|
||||
this.$forceUpdate()
|
||||
},
|
||||
// 审批流程
|
||||
addData1() {
|
||||
const arr = JSON.parse(JSON.stringify(this.allData.signData.sendList))
|
||||
arr.push({
|
||||
pkSend: ''
|
||||
})
|
||||
this.$set(this.allData.signData, 'sendList', arr)
|
||||
this.$forceUpdate()
|
||||
},
|
||||
// 抄送
|
||||
delData1() {
|
||||
this.allData.signData.sendList.pop()
|
||||
this.$forceUpdate()
|
||||
},
|
||||
// 审批流程
|
||||
delData() {
|
||||
this.allData.signData.detailList.pop()
|
||||
this.$forceUpdate()
|
||||
},
|
||||
|
||||
handleUploadSuccess(res) {
|
||||
if (res.code == 200) {
|
||||
this.fileList.push(res.data)
|
||||
} else {
|
||||
this.$message({
|
||||
type: 'error',
|
||||
message: '上传失败'
|
||||
})
|
||||
}
|
||||
},
|
||||
removeFile(file, fileList) {
|
||||
this.fileList.forEach((item, index) => {
|
||||
if (file.uid == item.uid) {
|
||||
this.fileList.splice(index, 1)
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
::v-deep .el-table thead {
|
||||
color: #000000;
|
||||
}
|
||||
.page {
|
||||
padding: 20px;
|
||||
background: #f9f9f9;
|
||||
font-size: 14px;
|
||||
.main {
|
||||
// margin-top: 20px;
|
||||
background: #ffffff;
|
||||
border-radius: 8px;
|
||||
box-shadow: 0px 2px 20px 0px rgba(238, 238, 238, 0.5);
|
||||
display: flex;
|
||||
margin: 0 auto;
|
||||
width: 100%;
|
||||
padding: 20px;
|
||||
flex-direction: column;
|
||||
}
|
||||
.thetable {
|
||||
margin: 0 auto;
|
||||
margin-bottom: 20px;
|
||||
.fontTitle {
|
||||
font-weight: bold;
|
||||
font-size: 24px;
|
||||
text-align: center;
|
||||
}
|
||||
.titleflex {
|
||||
display: flex;
|
||||
margin-top: 10px;
|
||||
margin-bottom: 10px;
|
||||
justify-content: space-between;
|
||||
}
|
||||
}
|
||||
.tftable {
|
||||
font-size: 14px;
|
||||
border-collapse: collapse;
|
||||
border-radius: 10px;
|
||||
width: 1060px;
|
||||
border: 1px solid #cccccc;
|
||||
.spbox {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: flex-end;
|
||||
}
|
||||
th {
|
||||
font-size: 14px;
|
||||
// padding: 20px;
|
||||
}
|
||||
tr td {
|
||||
font-size: 14px;
|
||||
padding: 10px 20px;
|
||||
height: 60px;
|
||||
}
|
||||
}
|
||||
.footer {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
padding: 15px 0;
|
||||
.thebtn {
|
||||
width: 120px;
|
||||
height: 38px;
|
||||
}
|
||||
}
|
||||
}
|
||||
// 审批流程
|
||||
.disflex {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
</style>
|
Loading…
Reference in New Issue