Merge remote-tracking branch 'origin/master'
¶Ô±ÈÐÂÎļþ |
| | |
| | | import request from '@/router/axios'; |
| | | |
| | | // 人å设置åå§å |
| | | export const personnelInit = (params) => { |
| | | return request({ |
| | | url: '/api/ubcs-flow/taskUser/list', |
| | | method: 'get', |
| | | params: params |
| | | }) |
| | | } |
| | | // 人å设置æ¶è |
| | | export const personnelCollect = (params) => { |
| | | return request({ |
| | | url: '/api/ubcs-flow/taskUser/su', |
| | | method: 'get', |
| | | params: params |
| | | }) |
| | | } |
| | | // 人åè®¾ç½®åæ¶æ¶è |
| | | export const cancelCollect = (params) => { |
| | | return request({ |
| | | url: '/api/ubcs-flow/taskUser/du', |
| | | method: 'get', |
| | | params: params |
| | | }) |
| | | } |
| | | // 人å设置ä¿å |
| | | export const personnelSave = (params) => { |
| | | return request({ |
| | | url: '/api/', |
| | | method: 'post', |
| | | data: params |
| | | }) |
| | | } |
| | | |
| | |
| | | { |
| | | label: '模æ¿key', |
| | | prop: 'modelKey', |
| | | width:120, |
| | | sortable: true, |
| | | type: 'tree', |
| | | dicData: [], |
| | |
| | | label: '模æ¿åç§°', |
| | | prop: 'modelName', |
| | | sortable: true, |
| | | width:220, |
| | | addDisabled: true, |
| | | editDisabled: true, |
| | | }, |
| | | { |
| | | label: 'æµç¨æ¨¡æ¿ç¨é', |
| | | label: '模æ¿ç¨é', |
| | | prop: 'buttonTypeKey', |
| | | type: 'tree', |
| | | width:120, |
| | | dicUrl: '/api/ubcs-flow/processTS/tt', |
| | | dicMethod: 'post', |
| | | props: { |
| | | value: "codee", |
| | | label: "namee", |
| | | }, |
| | | }, |
| | | { |
| | | label: 'æ¨¡æ¿æè¿°', |
| | | prop: 'description', |
| | | type:'textarea' |
| | | }, |
| | | ] |
| | | }, |
| | |
| | | // ç¼è¾ |
| | | async handleEdit(row, index, done, loading) { |
| | | console.log(row) |
| | | const { modelName, modelKey, buttonTypeKey, id } = row |
| | | let param = { modelName, modelKey, buttonTypeKey, id } |
| | | const { modelName, modelKey, buttonTypeKey, id ,description} = row |
| | | let param = { modelName, modelKey, buttonTypeKey, id,description } |
| | | const response = await flowpathSave({ ...param, ...{ templateId: this.code } }) |
| | | if (response.status === 200) { |
| | | loading() |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <el-dialog :title="title" :visible.sync="dialogVisible" append-to-body="true" width="30%"> |
| | | <el-tag v-for="tag in tags" :key="tag" closable effect="dark" @click="handleClickTag(tag)" |
| | | @close="handleCloseTag(tag)"> |
| | | <span> {{ tag }}</span> |
| | | </el-tag> |
| | | <el-divider></el-divider> |
| | | <el-form :model="formInline" class="demo-form-inline" label-position="left"> |
| | | <el-form-item :label="item.taskName" v-for="(item,index) in initFrom" :key="index"> |
| | | <el-select v-model="formInline[index].userId" :placeholder="item.taskName"> |
| | | <el-option label="åºåä¸" value="shanghai"></el-option> |
| | | <el-option label="åºåäº" value="beijing"></el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div slot="footer" class="dialog-footer"> |
| | | <el-button @click="handleCancel">å æ¶</el-button> |
| | | <el-button type="primary" @click="handleConfirm">ç¡® å®</el-button> |
| | | </div> |
| | | </el-dialog> |
| | | </template> |
| | | <script> |
| | | import { personnelInit, personnelCollect, cancelCollect, personnelSave } from '@/api/template/setPersonnel.js' |
| | | export default { |
| | | name: 'SetPersonnel', |
| | | props: { |
| | | // æ¯å¦æå¼ |
| | | visible: { |
| | | typeof: Boolean, |
| | | default: false |
| | | }, |
| | | title: { |
| | | typeof: String, |
| | | default: '人å设置' |
| | | }, |
| | | code:{ |
| | | typeof: String, |
| | | default: '' |
| | | } |
| | | }, |
| | | watch: { |
| | | visible(n) { |
| | | this.dialogVisible = n; |
| | | }, |
| | | dialogVisible(n) { |
| | | this.$emit('update:visible', n) |
| | | }, |
| | | }, |
| | | data() { |
| | | return { |
| | | dialogVisible: this.visible, |
| | | initFrom: [], |
| | | tags: ['æ ç¾1', 'æ ç¾2', 'æ ç¾3', 'æ ç¾4'], |
| | | formInline: [] |
| | | |
| | | } |
| | | }, |
| | | mounted() { |
| | | this.apiInit() |
| | | }, |
| | | methods: { |
| | | async apiInit() { |
| | | const response = await personnelInit({type:'PUBLIC',templateId:'8b5e2017-990f-454a-9c39-4c4eeeb57553'}) |
| | | if (response.status === 200) { |
| | | console.log(response) |
| | | this.initFrom = response.data.data.user |
| | | this.formInline = response.data.data.user |
| | | } |
| | | }, |
| | | async apiCollect() { |
| | | const response = await personnelCollect() |
| | | if (response.status === 200) { |
| | | console.log(response) |
| | | } |
| | | }, |
| | | async canCollect(id) { |
| | | const response = await cancelCollect() |
| | | if (response.status === 200) { |
| | | console.log(response) |
| | | } |
| | | }, |
| | | async apiSave() { |
| | | const response = await personnelSave() |
| | | if (response.status === 200) { |
| | | console.log(response) |
| | | } |
| | | }, |
| | | handleClickTag(event) { |
| | | console.log(event) |
| | | }, |
| | | handleCloseTag(event) { |
| | | console.log(event) |
| | | this.canCollect(event) |
| | | }, |
| | | done() { |
| | | this.dialogVisible = false |
| | | }, |
| | | handleCancel() { |
| | | this.done() |
| | | }, |
| | | handleConfirm() { |
| | | // this.done() |
| | | console.log(this.formInline) |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | <style lang="scss"> |
| | | .el-tag+.el-tag { |
| | | margin-left: 10px; |
| | | } |
| | | |
| | | .button-new-tag { |
| | | margin-left: 10px; |
| | | height: 32px; |
| | | line-height: 30px; |
| | | padding-top: 0; |
| | | padding-bottom: 0; |
| | | } |
| | | |
| | | .input-new-tag { |
| | | width: 90px; |
| | | margin-left: 10px; |
| | | vertical-align: bottom; |
| | | } |
| | | </style> |
| | |
| | | <template> |
| | | <div> |
| | | <el-button @click="outerVisible = true">æµç¨æµè¯</el-button> |
| | | <el-button @click="visibleStage = true">模æ¿é¶æ®µ</el-button> |
| | | <el-button @click="handleTable">tableç©¿æ¢æ¡</el-button> |
| | | <el-button @click="handleTable">人å设置</el-button> |
| | | <flow-business :visible.sync="outerVisible"></flow-business> |
| | | <stage code="8b5e2017-990f-454a-9c39-4c4eeeb57553"></stage> |
| | | <table-transfer :visible.sync="visibleTable" v-model="value" :dataList="list" :columns="columns" keyName="id" |
| | | @save="handleSave"></table-transfer> |
| | | <set-personnel :visible.sync="visibleFlow"></set-personnel> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import FlowBusiness from '@/components/template/Business' |
| | | import FlowPath from '@/components/template/FlowPath' |
| | | import Stage from '@/components/template/Stage' |
| | | import TableTransfer from '@/components/template/TableTransfer' |
| | | import SetPersonnel from '@/components/template/SetPersonnel' |
| | | export default { |
| | | components: { |
| | | FlowBusiness, |
| | | FlowPath, |
| | | Stage, |
| | | TableTransfer |
| | | SetPersonnel |
| | | }, |
| | | data() { |
| | | const getTables = () => { |
| | | let data = [] |
| | | for (let i = 0; i < 5; i++) { |
| | | let item = { |
| | | id: `${i + 1}`, |
| | | name: 'name', |
| | | address: `éå¢ç ${i + 1}`, |
| | | data: '', |
| | | checked: i === 1 ? true : false, |
| | | } |
| | | data.push(item) |
| | | } |
| | | return data |
| | | } |
| | | return { |
| | | list: getTables(), |
| | | value: ['2'], |
| | | outerVisible: false, |
| | | visibleFlow: false, |
| | | visibleStage: false, |
| | | visibleTable: false, |
| | | |
| | | columns: [ |
| | | { |
| | | key: "id", |
| | | label: "id", |
| | | visible: false, |
| | | }, |
| | | { |
| | | key: "name", |
| | | label: "屿§ç¼å·", |
| | | visible: true, |
| | | }, |
| | | { |
| | | key: "address", |
| | | label: "屿§åç§°", |
| | | visible: true, |
| | | }, |
| | | { |
| | | key: "address", |
| | | label: "屿§åç»", |
| | | visible: true, |
| | | }, |
| | | ], |
| | | |
| | | } |
| | | }, |
| | |
| | | console.log(event) |
| | | }, |
| | | handleTable(){ |
| | | this.visibleTable = true |
| | | // this.$nextTick(()=>{ |
| | | |
| | | // }) |
| | | this.visibleFlow = true |
| | | } |
| | | } |
| | | } |