Browse Source

车辆外采流程办理

master
yxt_djz 3 years ago
parent
commit
ad3d6cb3c8
  1. 2
      anrui-scm/anrui-scm-ui/src/api/anruiscm/scmotherinbound.js
  2. 51
      anrui-scm/anrui-scm-ui/src/api/baseoutsourcingapplication/baseoutsourcingapplication.js
  3. 36
      anrui-scm/anrui-scm-ui/src/views/baseoutsourcingapplication/baseoutsourcingapplication.vue
  4. 138
      anrui-scm/anrui-scm-ui/src/views/baseoutsourcingapplication/workflow/baseoutsourcingapplication.vue
  5. 66
      anrui-scm/anrui-scm-ui/src/views/baseoutsourcingapplication/workflow/baseoutsourcingapplicationAdd.vue
  6. 39
      anrui-scm/anrui-scm-ui/src/views/baseoutsourcingapplication/workflow/baseoutsourcingapplicationInfo.vue
  7. 36
      anrui-system-ui/src/views/flow/todoList.vue
  8. 2
      anrui-system-ui/src/views/organizationManage/organizationManage.vue
  9. 2
      anrui-system-ui/src/views/system-admin/orgsetup/index.vue

2
anrui-scm/anrui-scm-ui/src/api/anruiscm/scmotherinbound.js

@ -129,7 +129,7 @@ export default {
})
},
// 获取组织(单选组织架构)
getOrg: function(data) {
getOrg: function(data) {WWWW
return request({
url: '/portal/v1/sysorganization/getListOrg',
method: 'get',

51
anrui-scm/anrui-scm-ui/src/api/baseoutsourcingapplication/baseoutsourcingapplication.js

@ -32,6 +32,13 @@ export default {
url: '/base/baseoutsourcingapplication/fetchBySid/' + sid
})
},
// 根据业务sid提交外采申请审批流程
doSubmitBySid: function(sid,userSid) {
return request({
url: '/base/baseoutsourcingapplication/submitBaseOutSourcingApplicationBySid/' + sid+'/'+userSid,
method: 'post'
})
},
// 提交
doSubmit: function(params) {
return request({
@ -55,5 +62,49 @@ export default {
method: 'post',
data: params
})
},
// 同意任务
agreeTask: function(params) {
return request({
url: '/base/baseoutsourcingapplication/complete',
method: 'post',
data: params,
headers: {
'Content-Type': 'application/json'
}
})
},
// 驳回任务
rejectTask: function(params) {
return request({
url: '/base/baseoutsourcingapplication/' + params.businessSid,
method: 'post',
data: params,
headers: {
'Content-Type': 'application/json'
}
})
},
// 终止任务
breakTask: function(params) {
return request({
url: '/base/baseoutsourcingapplication/' + params.businessSid,
method: 'post',
data: params,
headers: {
'Content-Type': 'application/json'
}
})
},
// 撤回任务
revokeTask: function(params) {
return request({
url: '/base/baseoutsourcingapplication/' + params.userSid + '/' + params.businessSid,
method: 'post',
data: params,
headers: {
'Content-Type': 'application/json'
}
})
}
}

36
anrui-scm/anrui-scm-ui/src/views/baseoutsourcingapplication/baseoutsourcingapplication.vue

@ -37,15 +37,15 @@
<el-table-column width="50px" label="序号" type="index" :index="indexMethod" align="center" />
<el-table-column width="150px" label="操作" align="center" >
<template slot-scope="scope">
<el-button v-if="scope.row.nodeState==''" type="primary" size="mini" @click="edit(scope.row)">办理</el-button>
<el-button v-if="scope.row.nodeState==''||(scope.row.nodeState!=''&&scope.row.nodeState=='外采申请')" type="primary" size="mini" @click="edit(scope.row)">办理</el-button>
<el-button v-else type="info" size="mini">办理</el-button>
<el-button type="primary" size="mini" @click="toInfo(scope.row)">查看</el-button></template>
</el-table-column>
<el-table-column prop="applicationCode" width="130px;" label="申请编号" align="center" />
<el-table-column prop="nodeState" width="80px;" label="状态" align="center" >
<el-table-column prop="nodeState" width="100px;" label="状态" align="center" >
<template slot-scope="scope">
<span v-if="scope.row.nodeState==''">待提交</span>
<span v-else >scope.row.nodeState</span>
<span v-else >{{scope.row.nodeState}}</span>
</template>
</el-table-column>
<el-table-column prop="applicationDate" width="110px;" label="申请日期" align="center" />
@ -189,14 +189,23 @@ export default {
this.viewState = 3
this.$refs['divadd'].showEdit(row)
},
doSubmit(row) {
doSubmit() {
const row = this.multipleSelection[0]
req
.doSubmitBySid(row.sid,this.queryParams.params.userSid)
.then( resp => {
if(resp.success){
alert(123);
}
});
//
this.btndisabled = true
/* this.submitdisabled = true
this.formobj.userSid = window.sessionStorage.getItem('userSid');
this.formobj.orgSid = this.$store.getters.orgSid;
req
.doSubmit(this.queryParams.params)
.doSubmit(this.formobj)
.then(resp => {
console.log(resp)
this.btndisabled = false
this.submitdisabled = false
if (resp.success) {
//
} else {
@ -204,8 +213,8 @@ export default {
}
})
.catch(() => {
this.btndisabled = false
})
this.submitdisabled = false
})*/
},
doDel(row) {
if (this.multipleSelection.length === 0) {
@ -290,10 +299,9 @@ export default {
this.loadList()
},
resetQuery() {
this.queryParams.params = {
staffSid: window.sessionStorage.getItem('staffSid'),
userSid:window.sessionStorage.getItem('userSid'),
}
this.queryParams.params = {}
this.queryParams.params.sid = '' // sid
this.queryParams.params.name = '' //
this.dosearch()
},
loadList() {

138
anrui-scm/anrui-scm-ui/src/views/baseoutsourcingapplication/workflow/baseoutsourcingapplication.vue

@ -13,8 +13,8 @@
<!-- end 详情按钮 -->
</div>
<!-- 标题按钮部分结束 -->
<div class="listconadd">
<el-form ref="form_obj" :model="formobj" label-position="right" class="formadd"> <div class="wlInfo" style="text-align: center;"><span style="font-size:28px;">外采申请表</span></div>
<div>
<el-form ref="form_obj" :model="formobj" label-position="right" class="formadd" >
<el-row >
<el-col :span="3" class="tleftb" >申请编号</el-col>
<el-col :span="5" class="trightb"><el-form-item prop="applicationCode">
@ -63,7 +63,7 @@
<el-col :span="8" class="trightb"><el-form-item prop="useOrg"><span>{{ formobj.expenseName }}</span></el-form-item></el-col>
</el-row>
<el-row> <el-col :span="3" class="tleftb">费用金额合计</el-col>
<el-col :span="9" class="trightb"><el-form-item prop="useOrg"><span>{{ formobj.totalExpenseAmount }}</span></el-form-item></el-col>
<el-col :span="21" class="trightb"><el-form-item prop="useOrg"><span>{{ formobj.totalExpenseAmount }}</span></el-form-item></el-col>
</el-row>
<div class="listcon" v-show="formobj.externalMiningTypeKey==2">
<div style="border:1px solid #c0c0c0;padding:5px 5px 5px 5px;">
@ -75,7 +75,6 @@
</el-table>
</div>
</el-form>
</div>
</div>
</template>
@ -107,9 +106,56 @@ export default {
totalExpenseAmount: '', //
orgSid: '', // sid
baseOutsourcingApplicationVehicleDtos:[]
},
agreeList: { //
businessSid: '',
comment: '',
instanceId: '',
taskId: '',
userSid: window.sessionStorage.getItem('userSid')
},
regectList: { //
businessSid: '',
comment: '',
instanceId: '',
taskId: '',
userSid: window.sessionStorage.getItem('userSid')
},
stopList: { //
businessSid: '',
comment: '',
instanceId: '',
taskId: '',
userSid: window.sessionStorage.getItem('userSid')
}
}
},
created() {
// ===sid
var a = window.location.href.indexOf('?') + 1 // ?
var b = window.location.href.indexOf('#data') // #data
const info = window.location.href.slice(a, b)
var sid = info.substr(info.indexOf('=') + 1)
this.showInfo(sid)
// ===
var one = window.location.href.lastIndexOf('#') + 1
var two = window.location.href.lastIndexOf('}') + 1
const data = decodeURI(window.location.href.slice(one, two)) // urlunescape()web,使
var tar = data.substr(data.indexOf('=') + 1)
const obj = JSON.parse(tar)
//
this.agreeList.businessSid = sid
this.agreeList.instanceId = obj.instanceId
this.agreeList.taskId = obj.taskId
//
this.regectList.businessSid = sid
this.regectList.instanceId = obj.instanceId
this.regectList.taskId = obj.taskId
//
this.stopList.businessSid = sid
this.stopList.instanceId = obj.instanceId
this.stopList.taskId = obj.taskId
},
methods: {
//
openStop() {
@ -155,7 +201,8 @@ export default {
.then(() => {
this.handleAgree()
})
.catch(() => {
.catch((e) => {
console.log(e);
this.$message({
type: 'info',
message: '已取消同意'
@ -165,13 +212,13 @@ export default {
handleReturn() {
this.$emit('doback')
},
showInfo(row) {
showInfo(sid) {
this.$nextTick(() => {
this.$refs['form_obj'].clearValidate()
})
const _this = this
req
.fetchBySid(row.sid)
.fetchBySid(sid)
.then(resp => {
if (resp.success) {
const vdata = resp.data
@ -197,11 +244,84 @@ export default {
}
})
.catch(e => {
_this.formobj = row
_this.formobj = {}
})
},
/** 同意任务 */
handleAgree() {
this.agreeList.comment = "同意"; this.comment
req.agreeTask(this.agreeList).then((response) => {
if (response.code === '200') {
this.$notify({
title: '提示',
message: '执行成功',
type: 'success',
duration: 2000
})
// this.refreshIt()
} else {
this.$notify({
title: '提示',
message: '执行失败',
type: 'error',
duration: 2000
})
}
})
},
/** 驳回任务 */
handleReject() {
this.regectList.comment = this.comment
req.rejectTask(this.regectList).then((response) => {
if (response.code === '200') {
this.$notify({
title: '提示',
message: '执行成功',
type: 'success',
duration: 2000
})
// this.refreshIt()
} else {
this.$notify({
title: '提示',
message: '执行失败',
type: 'error',
duration: 2000
})
}
})
} ,
/** 终止任务 */
handleStop() {
this.stopList.comment = this.comment
req.breakTask(this.stopList).then((response) => {
if (response.code === '200') {
this.$notify({
title: '提示',
message: '执行成功',
type: 'success',
duration: 2000
})
// this.refreshIt()
} else {
this.$notify({
title: '提示',
message: '执行失败',
type: 'error',
duration: 2000
})
}
})
}
}
}
</script>
<style scoped></style>
<style scoped>
.tleftb{
font-size: 12px;
}
.trightb{
font-size: 12px;
}
</style>

66
anrui-scm/anrui-scm-ui/src/views/baseoutsourcingapplication/workflow/baseoutsourcingapplicationAdd.vue

@ -16,10 +16,8 @@
</div>
<!-- 标题按钮部分结束 -->
<!-- Start 新增修改部分 -->
<div class="listconadd">
<div>
<el-form ref="form_obj" :model="formobj" :rules="rules" label-position="right" class="formadd">
<div class="wlInfo" style="text-align: center;"><span style="font-size:28px;">外采申请表</span></div>
<br><br>
<el-row style="border-left: none;">
<el-col :span="3" class="tleftb">
<span><span class="icon">*</span>申请编号</span>
@ -194,6 +192,7 @@ export default {
viewTitle: '',
formobj: {
sid: '',
staffSid: window.sessionStorage.getItem('staffSid'),
applicationCode: '', //
createByName: window.sessionStorage.getItem('name'), //
applicationDate: '', //
@ -212,7 +211,17 @@ export default {
expenseName: '', //
totalExpenseAmount: '', //
orgSid: '', // sid
baseOutsourcingApplicationVehicleDtos:[]
baseOutsourcingApplicationVehicleDtos:[],
taskId: '',
businessSid: '',
instanceId: ''
},
stopList: { //
businessSid: '',
comment: '',
instanceId: '',
taskId: '',
userSid: window.sessionStorage.getItem('userSid')
},
rules: {
createByName: [{ required: true, message: '申请人姓名不能为空', trigger: 'blur' }], //
@ -233,25 +242,48 @@ export default {
}
},
created() {
// ===sid
var a = window.location.href.indexOf('?') + 1 // ?
var b = window.location.href.indexOf('#data') // #data
const info = window.location.href.slice(a, b)
var sid = info.substr(info.indexOf('=') + 1)
this.showEdit(sid)
// ===
var one = window.location.href.lastIndexOf('#') + 1
var two = window.location.href.lastIndexOf('}') + 1
const data = decodeURI(window.location.href.slice(one, two)) // urlunescape()web,使
var tar = data.substr(data.indexOf('=') + 1)
const obj = JSON.parse(tar)
if (obj.taskName == '已完结' || '已终止') {
this.isBtnShow = false
}
//
this.stopList.businessSid = sid
this.stopList.instanceId = obj.instanceId
this.stopList.taskId = obj.taskId
this.formobj.businessSid = sid
this.formobj.instanceId = obj.instanceId
this.formobj.taskId = obj.taskId
},
methods: {
handleSubmit() {
const _this = this
this.$refs['form_obj'].validate(valid => {
if (valid) {
//
this.submitdisabled = true
req.submitVehicleReturn(this.formobj).then(resp => {
this.formobj.userSid = window.sessionStorage.getItem('userSid');
this.formobj.orgSid = this.$store.getters.orgSid;
req
.doSubmit(this.formobj)
.then(resp => {
this.submitdisabled = false
if (resp.success) {
_this.handleReturn('true')
}
}).catch(() => {
this.submitdisabled = false
})
//
} else {
return false
// resp.code
}
})
.catch(() => {
this.submitdisabled = false
})
},
quedingVehicle(){
var obj = this.$refs['vehicle'].getSids();
@ -340,15 +372,15 @@ export default {
})
this.viewTitle = '【新增】外采申请表'
},
showEdit(row) {
showEdit(sid) {
this.$nextTick(() => {
this.$refs['form_obj'].clearValidate()
})
this.viewTitle = '【修改】外采申请表'
const _this = this
_this.formobj.sid = row.sid // SID
_this.formobj.sid = sid // SID
req
.fetchBySid(row.sid)
.fetchBySid(sid)
.then(resp => {
if (resp.success) {
const vdata = resp.data

39
anrui-scm/anrui-scm-ui/src/views/baseoutsourcingapplication/workflow/baseoutsourcingapplicationInfo.vue

@ -8,13 +8,10 @@
<div v-show="isBtnShow">
<el-button type="danger" @click="openRevoke"> </el-button>
</div>
<!-- start 详情按钮 -->
<div><el-button itype="info" size="small" @click="handleReturn()">返回</el-button></div>
<!-- end 详情按钮 -->
</div>
<!-- 标题按钮部分结束 -->
<div class="listconadd">
<el-form ref="form_obj" :model="formobj" label-position="right" class="formadd"> <div class="wlInfo" style="text-align: center;"><span style="font-size:28px;">外采申请表</span></div>
<el-form ref="form_obj" :model="formobj" label-position="right" class="formadd">
<el-row>
<el-col :span="3" class="tleftb">申请编号</el-col>
<el-col :span="5" class="trightb"><el-form-item prop="applicationCode">
@ -87,6 +84,7 @@ export default {
name: 'BaseOutsourcingApplicationInfo',
data() {
return {
isBtnShow: true,
formobj: {
sid: '',
applicationCode: '123456', //
@ -108,8 +106,35 @@ export default {
totalExpenseAmount: '', //
orgSid: '', // sid
baseOutsourcingApplicationVehicleDtos:[]
},
revokeList: {//
businessSid: '',
instanceId: '',
taskId: '',
userSid: window.sessionStorage.getItem('userSid')
}
}
},
created() {
// ===sid
var a = window.location.href.indexOf('?') + 1 // ?
var b = window.location.href.indexOf('#data') // #data
const info = window.location.href.slice(a, b)
var sid = info.substr(info.indexOf('=') + 1)
this.showInfo(sid)
// ===
var one = window.location.href.lastIndexOf('#') + 1
var two = window.location.href.lastIndexOf('}') + 1
const data = decodeURI(window.location.href.slice(one, two)) // urlunescape()web,使
var tar = data.substr(data.indexOf('=') + 1)
const obj = JSON.parse(tar)
if (obj.taskName == '已完结' || '已终止') {
// this.isBtnShow = false
}
//
this.revokeList.businessSid = sid
this.revokeList.instanceId = obj.instanceId
this.revokeList.taskId = obj.taskId
},
methods: {
//
@ -128,7 +153,7 @@ export default {
})
},
/** 撤回任务 */
handleRevoke() {
handleRevoke() {alert(1);
request.revokeTask(this.revokeList).then((response) => {
if (response.code === '200') {
this.$notify({
@ -150,13 +175,13 @@ export default {
handleReturn() {
this.$emit('doback')
},
showInfo(row) {
showInfo(sid) {
this.$nextTick(() => {
this.$refs['form_obj'].clearValidate()
})
const _this = this
req
.fetchBySid(row.sid)
.fetchBySid(sid)
.then(resp => {
if (resp.success) {
const vdata = resp.data

36
anrui-system-ui/src/views/flow/todoList.vue

@ -94,15 +94,17 @@
title=""
:visible.sync="centerDialogVisible"
width="78%"
height="100%"
height="80%"
:before-close="closeIt"
center>
<div class="scroll_div">
<iframe height="1000px" width="100%"
<!-- <div class="scroll_div">-->
<iframe frameborder="0"
style="height:600px;width:100%;"
:src="this.centerDialogVisible === true ? url :''"
scrolling="no"></iframe>
scrolling="no"
></iframe>
<!--意见要移进具体的表单页面里-->
<div class="diaTitle"><i class="el-icon-chat-line-square"></i><span>审批意见</span></div>
<!-- <div class="diaTitle"><i class="el-icon-chat-line-square"></i><span>审批意见</span></div>
<el-form :model="dialogList" :inline="true" label-width="80px">
<el-form-item label="审批意见" class="searchlist">
<el-input v-model="dialogList.comment" type="textarea" maxlength="20" placeholder="请输入审批意见"
@ -147,14 +149,14 @@
</div>
</el-col>
</el-card>
</div>
</div>
<span slot="footer" class="dialog-footer"> <!---->
</div>-->
<!--</div>-->
<!-- <span slot="footer" class="dialog-footer"> -->
<!-- <el-button type="primary" v-show="this.taskName_now == '发起订单'?false:true" @click="openAgree"> </el-button>-->
<!-- <el-button type="danger" v-show="this.taskName_now == '发起订单'?false:true" @click="openReject"> </el-button>-->
<!-- <el-button type="danger" @click="openStop"> </el-button>-->
<!-- <el-button type="info" @click="centerDialogVisible = false"> </el-button>-->
</span>
<!-- </span>-->
</el-dialog>
<!-- End办理页面-->
@ -329,13 +331,12 @@
instanceId: row.procInsId,
taskId: row.taskId,
taskName: row.taskName,
transactState: '00', //
userSid:this.loginInfo.sid, // sid
transactState: '00' //
}
selectUrl(this.selectUrl_list).then((response) => {
if (response.code === '200') {
// this.url = 'http://120.46.131.15' + response.data.url + '?row=' + row.processVariables.businessSid + '#data=' + JSON.stringify(parameter_list) + '?token=' + getStorage()
this.url = 'http://192.168.1.118:9531' + response.data.url + '?row=' + row.processVariables.businessSid + '#data=' + JSON.stringify(parameter_list) + '?token=123456abc'
this.url = 'http://localhost:9531' + response.data.url + '?row=' + row.processVariables.businessSid + '#data=' + JSON.stringify(parameter_list) + '?token=' + getStorage()
} else {
this.$notify({
title: '提示',
@ -402,17 +403,18 @@
this.agreeList.comment = this.dialogList.comment
businessAgree(this.agreeList).then((response) => {
if (response.code === '200') {
this.$notify({
alert("操作成功!");
/* this.$notify({
title: '提示',
message: '执行成功',
message: '操作成功',
type: 'success',
duration: 2000,
})
})*/
this.refreshIt()
} else {
this.$notify({
title: '提示',
message: '执行失败',
message: '操作失败',
type: 'error',
duration: 2000,
})
@ -546,7 +548,7 @@
<style scoped>
.scroll_div {
height: 500px;
height: auto;
overflow-y: scroll;
}

2
anrui-system-ui/src/views/organizationManage/organizationManage.vue

@ -163,9 +163,7 @@
<div class="ewm" style="display: flex;justify-content: center; align-items: center;" ref="print">
<img style="width: 200px; height: 200px;" :src="ewmForm.qrFilePath" alt="">
<ul style="list-style:none; line-height: 32px; font-size: 16px;">
<li><label for="">单位名称: </label><span>{{ ewmForm.organizationName }}</span></li>
<li><label for="">部门名称: </label><span>{{ ewmForm.departmentName }}</span></li>
<li><label for="">部门地址: </label><span>{{ ewmForm.address }}</span></li>
</ul>
</div>
</div>

2
anrui-system-ui/src/views/system-admin/orgsetup/index.vue

@ -121,9 +121,7 @@
<div class="ewm" style="display: flex;justify-content: center; align-items: center;" ref="print">
<img style="width: 200px; height: 200px;" :src="ewmForm.qrFilePath" alt="">
<ul style="list-style:none; line-height: 32px; font-size: 16px;">
<li><label for="">单位名称: </label><span>{{ewmForm.organizationName}}</span></li>
<li><label for="">部门名称: </label><span>{{ewmForm.departmentName}}</span></li>
<li><label for="">部门地址: </label><span>{{ewmForm.address}}</span></li>
</ul>
</div>
</div>

Loading…
Cancel
Save