init: import production code mss.nahaichuan.com (exclude Runtime/Uploads/backups/logs)
这个提交包含在:
48
Public/js/component-operator.js
可执行文件
48
Public/js/component-operator.js
可执行文件
@@ -0,0 +1,48 @@
|
||||
/**
|
||||
* @description 操作人选择器
|
||||
*/
|
||||
Vue.component('component-operator', {
|
||||
template: `
|
||||
<div id="component-operator">
|
||||
<el-select v-model="operatorId" placeholder="请选择操作人" @change="operatorChange">
|
||||
<el-option v-for="option in options" :key="option.id" :label="option.name" :value="option.id">
|
||||
</el-option>
|
||||
</el-select>
|
||||
</div>
|
||||
`,
|
||||
data() {
|
||||
return {
|
||||
requestUrl: { //各个角色的记录获取路径
|
||||
1: 'Admin/AdminRoles/getOperatorList',
|
||||
2: 'Agent/AgentRoles/getOperatorList',
|
||||
3: 'Retail/MerchantRoles/getOperatorList'
|
||||
},
|
||||
options: [],
|
||||
operatorId: ''
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
/**
|
||||
* @description 获取操作人列表
|
||||
*/
|
||||
getOperator() {
|
||||
this.sendRequest(this.requestUrl[this.type], {
|
||||
success: (response) => {
|
||||
if (response.status == 1) {
|
||||
this.options = response.data.list
|
||||
}
|
||||
}
|
||||
});
|
||||
},
|
||||
/**
|
||||
* @description 操作人选择变化
|
||||
*/
|
||||
operatorChange(id) {
|
||||
this.$emit('update:id', id)
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getOperator()
|
||||
},
|
||||
props: ['type', 'id']
|
||||
})
|
||||
在新工单中引用
屏蔽一个用户