Browse Source

完善销售订单--流程审批增加转办、加签功能

master
yunuo970428 2 years ago
parent
commit
d0a93bba83
  1. 24
      anrui-buscenter/anrui-buscenter-ui/src/api/salesManagement/orderManagement.js
  2. 131
      anrui-buscenter/anrui-buscenter-ui/src/views/workflow/xiaoshouguanliFlow/xiaoshoudingdanFlow/xiaoshoudingdan.vue
  3. 129
      anrui-buscenter/anrui-buscenter-ui/src/views/workflow/xiaoshouguanliFlow/xiaoshoudingdanFlow/xiaoshoudingdanByCaiGou.vue
  4. 128
      anrui-buscenter/anrui-buscenter-ui/src/views/workflow/xiaoshouguanliFlow/xiaoshoudingdanFlow/xiaoshoudingdanByJinRong.vue

24
anrui-buscenter/anrui-buscenter-ui/src/api/salesManagement/orderManagement.js

@ -99,6 +99,30 @@ export function complete(params) {
})
}
// 流程审批(加签)
export function delegate(params) {
return request({
url: '/buscenter/v1/bussalesorder/delegate',
method: 'put',
data: params,
headers: {
'Content-Type': 'application/json'
}
})
}
// 流程审批(转办)
export function assignTask(params) {
return request({
url: '/buscenter/v1/bussalesorder/assignTask',
method: 'put',
data: params,
headers: {
'Content-Type': 'application/json'
}
})
}
// 流程审批(同意--可选择采购系统)
export function completeBy(params) {
return request({

131
anrui-buscenter/anrui-buscenter-ui/src/views/workflow/xiaoshouguanliFlow/xiaoshoudingdanFlow/xiaoshoudingdan.vue

@ -4,6 +4,8 @@
<div class="tab-header webtop">
<div>{{ viewTitle }}</div>
<div>
<el-button type="primary" size="small" @click="openTurnDo('转办')"> </el-button>
<el-button type="primary" size="small" @click="openCountersign('加签')"> </el-button>
<el-button type="primary" size="small" @click="openAgree('同意')"> </el-button>
<el-button type="danger" size="small" @click="openReject('驳回')"> </el-button>
<el-button type="danger" size="small" @click="openStop('终止')"> </el-button>
@ -309,6 +311,22 @@
<!-- 选择待办人 的弹出框-->
<el-dialog title="填写审批意见" :visible.sync="nodeDialogVisible" width="80%">
<el-form class="formadd" >
<el-row v-show="countersignLink" style="border-top: 1px solid #e0e3eb">
<el-col :span="4" class="tleftb">
<span>
<span v-show="operation == '加签'" class="icon">*</span>加签人员:
<span v-show="operation == '转办'" class="icon">*</span>转办人员:
</span>
</el-col>
<el-col :span="20">
<el-form-item>
<el-select v-model="countersign.assignee" placeholder="请选择" filterable>
<el-option v-for="item in options" :key="item.userSid" :label="item.staffName" :value="item.userSid">
</el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
<el-row v-show="currentLink" style="border-top: 1px solid #e0e3eb">
<el-col :span="4" class="tleftb">
<span>当前环节:</span>
@ -335,8 +353,9 @@
</div>
</template>
<script>
import { fetchDetailsBySid, complete, breakProcess, reject, getNextNodesForSubmit, getPreviousNodesForReject } from '@/api/salesManagement/orderManagement'
import { fetchDetailsBySid, complete, breakProcess, reject, getNextNodesForSubmit, getPreviousNodesForReject, delegate, assignTask } from '@/api/salesManagement/orderManagement'
import financialschemeInfo from '../../publicPage/financialschemeInfo'
import { selectStaffListss } from '@/api/dictcommons/dictcommons'
export default {
name: 'XiaoShouDingDanDaiBanInfo',
@ -393,6 +412,7 @@ export default {
useOrgSid: '',
finPlanState: false
},
options: [],
operation: '', //
dialogList: {
comment: ''
@ -414,6 +434,14 @@ export default {
orgSidPath: '',
taskDefKey: '',
userSid: ''
},
//
countersign: {
taskId: '',
assignee: '',
userSid: '',
instanceId: '',
views: ''
}
}
},
@ -432,6 +460,10 @@ export default {
this.linkByParameter.userSid = window.sessionStorage.getItem('userSid')
this.current.taskDefKey = obj.taskDefKey
this.current.taskName = obj.taskName
//
this.countersign.taskId = obj.taskId
this.countersign.userSid = window.sessionStorage.getItem('userSid')
this.countersign.instanceId = obj.instanceId
//
this.showInfo(obj.businessSid)
},
@ -462,6 +494,11 @@ export default {
}
}
})
selectStaffListss().then((res) => {
if (res.success) {
this.options = res.data
}
})
},
handleLook() {
this.viewState = 2
@ -506,12 +543,41 @@ export default {
})
return sums
},
//
openTurnDo(val) {
this.operation = val
this.currentLink = false
this.countersignLink = true
this.dialogList.comment = ''
getNextNodesForSubmit({ taskDefKey: this.current.taskDefKey, businessSid: this.linkByParameter.businessSid }).then((resp) => {
if (resp.success) {
var arr = resp.data
this.nextNode = arr[0]
this.nodeDialogVisible = true
}
this.submitdisabled = false
})
},
//
openCountersign(val) {
this.operation = val
this.currentLink = true
this.countersignLink = true
this.dialogList.comment = ''
getNextNodesForSubmit({ taskDefKey: this.current.taskDefKey, businessSid: this.linkByParameter.businessSid }).then((resp) => {
if (resp.success) {
var arr = resp.data
this.nextNode = arr[0]
this.nodeDialogVisible = true
}
this.submitdisabled = false
})
},
//
openAgree(val) {
this.operation = val
this.currentLink = true
this.dialogList.comment = '同意'
console.log(this.current, 9898)
getNextNodesForSubmit({ taskDefKey: this.current.taskDefKey, businessSid: this.linkByParameter.businessSid }).then((resp) => {
if (resp.success) {
var arr = resp.data
@ -557,8 +623,69 @@ export default {
} else {
this.handleStop()
}
} else if (this.operation === '加签') {
this.handleCountersign()
} else if (this.operation === '转办') {
this.handleAssignTask()
}
},
//
handleAssignTask() {
if (this.countersign.assignee === '') {
this.$message({ showClose: true, type: 'error', message: '请选择转办人员' })
return
}
assignTask(this.countersign).then((response) => {
if (response.success) {
this.$notify({
title: '提示',
message: '执行成功',
type: 'success',
duration: 2000
})
this.nodeDialogVisible = false
//
window.parent.postMessage({
cmd: 'returnHeight',
params: {
//
code: 1
}
}, '*')
}
})
},
/** 加签 */
handleCountersign() {
if (this.countersign.assignee === '') {
this.$message({ showClose: true, type: 'error', message: '请选择加签人员' })
return
}
if (this.dialogList.comment === '') {
this.$message({ showClose: true, type: 'error', message: '请填写审批意见' })
return
}
this.countersign.views = this.dialogList.comment
delegate(this.countersign).then((response) => {
if (response.success) {
this.$notify({
title: '提示',
message: '执行成功',
type: 'success',
duration: 2000
})
this.nodeDialogVisible = false
//
window.parent.postMessage({
cmd: 'returnHeight',
params: {
//
code: 1
}
}, '*')
}
})
},
/** 同意任务 */
handleAgree() {
this.linkByParameter.comment = this.dialogList.comment

129
anrui-buscenter/anrui-buscenter-ui/src/views/workflow/xiaoshouguanliFlow/xiaoshoudingdanFlow/xiaoshoudingdanByCaiGou.vue

@ -4,6 +4,8 @@
<div class="tab-header webtop">
<div>{{ viewTitle }}</div>
<div>
<el-button type="primary" size="small" @click="openTurnDo('转办')"> </el-button>
<el-button type="primary" size="small" @click="openCountersign('加签')"> </el-button>
<el-button type="primary" size="small" @click="openAgree('同意')"> </el-button>
<el-button type="danger" size="small" @click="openReject('驳回')"> </el-button>
<el-button type="danger" size="small" @click="openStop('终止')"> </el-button>
@ -309,6 +311,20 @@
<!-- 选择待办人 的弹出框-->
<el-dialog title="填写审批意见" :visible.sync="nodeDialogVisible" width="80%">
<el-form class="formadd" >
<el-row v-show="countersignLink" style="border-top: 1px solid #e0e3eb">
<el-col :span="4" class="tleftb">
<span v-show="operation == '加签'" class="icon">*</span>加签人员:
<span v-show="operation == '转办'" class="icon">*</span>转办人员:
</el-col>
<el-col :span="20">
<el-form-item>
<el-select v-model="countersign.assignee" placeholder="请选择" filterable>
<el-option v-for="item in options" :key="item.userSid" :label="item.staffName" :value="item.userSid">
</el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
<el-row v-show="currentLink" style="border-top: 1px solid #e0e3eb">
<el-col :span="4" class="tleftb">
<span>当前环节:</span>
@ -355,8 +371,8 @@
</div>
</template>
<script>
import { fetchDetailsBySid, completeBy, breakProcess, reject, getNextNodesForSubmit, getPreviousNodesForReject } from '@/api/salesManagement/orderManagement'
import { getOrgSidByPath, fetchDetailsByUseOrgSid } from '@/api/dictcommons/dictcommons'
import { fetchDetailsBySid, completeBy, breakProcess, reject, getNextNodesForSubmit, getPreviousNodesForReject, delegate, assignTask } from '@/api/salesManagement/orderManagement'
import { getOrgSidByPath, fetchDetailsByUseOrgSid, selectStaffListss } from '@/api/dictcommons/dictcommons'
import financialschemeInfo from '../../publicPage/financialschemeInfo'
export default {
@ -420,6 +436,7 @@ export default {
finPlanState: false,
nowCarUnknownVinNum: ''
},
options: [],
operation: '', //
dialogList: {
comment: ''
@ -444,6 +461,14 @@ export default {
userSid: '',
purchaseSystemName: '',
purchaseSystemSid: ''
},
//
countersign: {
taskId: '',
assignee: '',
userSid: '',
instanceId: '',
views: ''
}
}
},
@ -462,6 +487,10 @@ export default {
this.linkByParameter.userSid = window.sessionStorage.getItem('userSid')
this.current.taskDefKey = obj.taskDefKey
this.current.taskName = obj.taskName
//
this.countersign.taskId = obj.taskId
this.countersign.userSid = window.sessionStorage.getItem('userSid')
this.countersign.instanceId = obj.instanceId
//
this.showInfo(obj.businessSid)
},
@ -501,6 +530,11 @@ export default {
})
}
})
selectStaffListss().then((res) => {
if (res.success) {
this.options = res.data
}
})
},
handleLook() {
this.viewState = 2
@ -549,6 +583,36 @@ export default {
const choose = this.purchase_list.filter((item) => item.purchaseSystemName === value)
this.purchaseSid = choose[0].deptSid
},
//
openTurnDo(val) {
this.operation = val
this.currentLink = false
this.countersignLink = true
this.dialogList.comment = ''
getNextNodesForSubmit({ taskDefKey: this.current.taskDefKey, businessSid: this.linkByParameter.businessSid }).then((resp) => {
if (resp.success) {
var arr = resp.data
this.nextNode = arr[0]
this.nodeDialogVisible = true
}
this.submitdisabled = false
})
},
//
openCountersign(val) {
this.operation = val
this.currentLink = true
this.countersignLink = true
this.dialogList.comment = ''
getNextNodesForSubmit({ taskDefKey: this.current.taskDefKey, businessSid: this.linkByParameter.businessSid }).then((resp) => {
if (resp.success) {
var arr = resp.data
this.nextNode = arr[0]
this.nodeDialogVisible = true
}
this.submitdisabled = false
})
},
//
openAgree(val) {
this.operation = val
@ -629,7 +693,68 @@ export default {
} else {
this.handleStop()
}
} else if (this.operation === '加签') {
this.handleCountersign()
} else if (this.operation === '转办') {
this.handleAssignTask()
}
},
//
handleAssignTask() {
if (this.countersign.assignee === '') {
this.$message({ showClose: true, type: 'error', message: '请选择转办人员' })
return
}
assignTask(this.countersign).then((response) => {
if (response.success) {
this.$notify({
title: '提示',
message: '执行成功',
type: 'success',
duration: 2000
})
this.nodeDialogVisible = false
//
window.parent.postMessage({
cmd: 'returnHeight',
params: {
//
code: 1
}
}, '*')
}
})
},
/** 加签 */
handleCountersign() {
if (this.countersign.assignee === '') {
this.$message({ showClose: true, type: 'error', message: '请选择加签人员' })
return
}
if (this.dialogList.comment === '') {
this.$message({ showClose: true, type: 'error', message: '请填写审批意见' })
return
}
this.countersign.views = this.dialogList.comment
delegate(this.countersign).then((response) => {
if (response.success) {
this.$notify({
title: '提示',
message: '执行成功',
type: 'success',
duration: 2000
})
this.nodeDialogVisible = false
//
window.parent.postMessage({
cmd: 'returnHeight',
params: {
//
code: 1
}
}, '*')
}
})
},
/** 同意任务 */
handleAgree() {

128
anrui-buscenter/anrui-buscenter-ui/src/views/workflow/xiaoshouguanliFlow/xiaoshoudingdanFlow/xiaoshoudingdanByJinRong.vue

@ -4,6 +4,8 @@
<div class="tab-header webtop">
<div>{{ viewTitle }}</div>
<div>
<el-button type="primary" size="small" @click="openTurnDo('转办')"> </el-button>
<el-button type="primary" size="small" @click="openCountersign('加签')"> </el-button>
<el-button type="primary" size="small" @click="openAgree('同意')"> </el-button>
<el-button type="danger" size="small" @click="openReject('驳回')"> </el-button>
<el-button type="danger" size="small" @click="openStop('终止')"> </el-button>
@ -309,6 +311,20 @@
<!-- 选择待办人 的弹出框-->
<el-dialog title="填写审批意见" :visible.sync="nodeDialogVisible" width="80%">
<el-form class="formadd" >
<el-row v-show="countersignLink" style="border-top: 1px solid #e0e3eb">
<el-col :span="4" class="tleftb">
<span v-show="operation == '加签'" class="icon">*</span>加签人员:
<span v-show="operation == '转办'" class="icon">*</span>转办人员:
</el-col>
<el-col :span="20">
<el-form-item>
<el-select v-model="countersign.assignee" placeholder="请选择" filterable>
<el-option v-for="item in options" :key="item.userSid" :label="item.staffName" :value="item.userSid">
</el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
<el-row v-show="currentLink" style="border-top: 1px solid #e0e3eb">
<el-col :span="4" class="tleftb">
<span>当前环节:</span>
@ -335,8 +351,9 @@
</div>
</template>
<script>
import { fetchDetailsBySid, complete, breakProcess, reject, getNextNodesForSubmit, getPreviousNodesForReject } from '@/api/salesManagement/orderManagement'
import { fetchDetailsBySid, complete, breakProcess, reject, getNextNodesForSubmit, getPreviousNodesForReject, delegate, assignTask } from '@/api/salesManagement/orderManagement'
import financialschemeEdit from '../../publicPage/financialschemeEdit'
import { selectStaffListss } from '@/api/dictcommons/dictcommons'
export default {
name: 'xiaoshoudingdanByJinRong',
@ -393,6 +410,7 @@ export default {
useOrgSid: '',
finPlanState: false
},
options: [],
operation: '', //
dialogList: {
comment: ''
@ -414,6 +432,14 @@ export default {
orgSidPath: '',
taskDefKey: '',
userSid: ''
},
//
countersign: {
taskId: '',
assignee: '',
userSid: '',
instanceId: '',
views: ''
}
}
},
@ -432,6 +458,10 @@ export default {
this.linkByParameter.userSid = window.sessionStorage.getItem('userSid')
this.current.taskDefKey = obj.taskDefKey
this.current.taskName = obj.taskName
//
this.countersign.taskId = obj.taskId
this.countersign.userSid = window.sessionStorage.getItem('userSid')
this.countersign.instanceId = obj.instanceId
//
this.showInfo(obj.businessSid)
},
@ -462,6 +492,11 @@ export default {
}
}
})
selectStaffListss().then((res) => {
if (res.success) {
this.options = res.data
}
})
},
handleLook() {
this.viewState = 2
@ -506,6 +541,36 @@ export default {
})
return sums
},
//
openTurnDo(val) {
this.operation = val
this.currentLink = false
this.countersignLink = true
this.dialogList.comment = ''
getNextNodesForSubmit({ taskDefKey: this.current.taskDefKey, businessSid: this.linkByParameter.businessSid }).then((resp) => {
if (resp.success) {
var arr = resp.data
this.nextNode = arr[0]
this.nodeDialogVisible = true
}
this.submitdisabled = false
})
},
//
openCountersign(val) {
this.operation = val
this.currentLink = true
this.countersignLink = true
this.dialogList.comment = ''
getNextNodesForSubmit({ taskDefKey: this.current.taskDefKey, businessSid: this.linkByParameter.businessSid }).then((resp) => {
if (resp.success) {
var arr = resp.data
this.nextNode = arr[0]
this.nodeDialogVisible = true
}
this.submitdisabled = false
})
},
//
openAgree(val) {
this.operation = val
@ -557,8 +622,69 @@ export default {
} else {
this.handleStop()
}
} else if (this.operation === '加签') {
this.handleCountersign()
} else if (this.operation === '转办') {
this.handleAssignTask()
}
},
//
handleAssignTask() {
if (this.countersign.assignee === '') {
this.$message({ showClose: true, type: 'error', message: '请选择转办人员' })
return
}
assignTask(this.countersign).then((response) => {
if (response.success) {
this.$notify({
title: '提示',
message: '执行成功',
type: 'success',
duration: 2000
})
this.nodeDialogVisible = false
//
window.parent.postMessage({
cmd: 'returnHeight',
params: {
//
code: 1
}
}, '*')
}
})
},
/** 加签 */
handleCountersign() {
if (this.countersign.assignee === '') {
this.$message({ showClose: true, type: 'error', message: '请选择加签人员' })
return
}
if (this.dialogList.comment === '') {
this.$message({ showClose: true, type: 'error', message: '请填写审批意见' })
return
}
this.countersign.views = this.dialogList.comment
delegate(this.countersign).then((response) => {
if (response.success) {
this.$notify({
title: '提示',
message: '执行成功',
type: 'success',
duration: 2000
})
this.nodeDialogVisible = false
//
window.parent.postMessage({
cmd: 'returnHeight',
params: {
//
code: 1
}
}, '*')
}
})
},
/** 同意任务 */
handleAgree() {
this.linkByParameter.comment = this.dialogList.comment

Loading…
Cancel
Save