return axios.get('/chainindustryapply/index', {params}) | return axios.get('/chainindustryapply/index', {params}) | ||||
}, | }, | ||||
editItem(params){ | editItem(params){ | ||||
return axios.post('/chainindustryapply/applyDept',params) | |||||
return axios.put('/chainindustryapply/checkApply',params) | |||||
} | } | ||||
} | } |
prop="cooperateDeptName" | prop="cooperateDeptName" | ||||
></el-table-column> | ></el-table-column> | ||||
<el-table-column label="操作" align="center" width="100"> | <el-table-column label="操作" align="center" width="100"> | ||||
<el-link | |||||
@click="edit" | |||||
icon="el-icon-edit" | |||||
type="primary" | |||||
:underline="false" | |||||
>申请</el-link | |||||
> | |||||
<template slot-scope="{ row }"> | |||||
<el-link | |||||
@click="edit(row)" | |||||
icon="el-icon-edit" | |||||
type="primary" | |||||
:underline="false" | |||||
:disabled="judge(row)" | |||||
>申请</el-link | |||||
> | |||||
</template> | |||||
</el-table-column> | </el-table-column> | ||||
</el-table> | </el-table> | ||||
<el-pagination | <el-pagination | ||||
<script> | <script> | ||||
import search from "../search"; | import search from "../search"; | ||||
import { mapGetters } from "vuex"; | |||||
import api from '@/api/chain/assessmentContent' | import api from '@/api/chain/assessmentContent' | ||||
import applyApi from '@/api/chain/coordinationManage/applyCooperation' | |||||
import { mergeSpan } from "@/utils/mixin"; | import { mergeSpan } from "@/utils/mixin"; | ||||
export default { | export default { | ||||
components: { | components: { | ||||
showEdit: false, | showEdit: false, | ||||
}; | }; | ||||
}, | }, | ||||
computed: { | |||||
...mapGetters(["user"]), | |||||
}, | |||||
created(){ | created(){ | ||||
this.getDataList(); | this.getDataList(); | ||||
}, | }, | ||||
methods: { | methods: { | ||||
judge(row) { | |||||
// console.log(row, this.user.user.deptId); | |||||
// let arr = [].concat( | |||||
// row.cooperateDept.split(",").map((item) => parseInt(item)), | |||||
// row.leaderDept.split(",").map((item) => parseInt(item)) | |||||
// ); | |||||
// let bool = arr.includes(this.user.user.deptId); | |||||
// return bool; | |||||
}, | |||||
getDataList() { | getDataList() { | ||||
api.getList(Object.assign({},this.searchParams)).then(res=>{ | api.getList(Object.assign({},this.searchParams)).then(res=>{ | ||||
this.startList = res.data.data | this.startList = res.data.data | ||||
this.loading=false; | this.loading=false; | ||||
}) | }) | ||||
}, | }, | ||||
edit() { | |||||
edit(row) { | |||||
this.showEdit = true; | this.showEdit = true; | ||||
this.form.chainIndustryId = row.id | |||||
}, | |||||
save(){ | |||||
applyApi | |||||
.applyCooperate(Object.assign({}, this.form)) | |||||
.then((res) => { | |||||
this.showEdit = false; | |||||
this.$message({ | |||||
type: "success", | |||||
message: "提交申请成功", | |||||
}); | |||||
this.getDataList(); | |||||
}) | |||||
.catch((e) => { | |||||
this.showEdit = false; | |||||
this.$message({ | |||||
type: "error", | |||||
message: "提交申请失败", | |||||
}); | |||||
}); | |||||
}, | }, | ||||
save(){}, | |||||
}, | }, | ||||
}; | }; | ||||
</script> | </script> |
<el-table-column | <el-table-column | ||||
label="申请部门" | label="申请部门" | ||||
align="center" | align="center" | ||||
min-width="150" | |||||
></el-table-column | |||||
><el-table-column | |||||
width="150" | |||||
prop="applyDeptList" | |||||
></el-table-column> | |||||
<el-table-column | |||||
label="申请时间" | label="申请时间" | ||||
align="center" | align="center" | ||||
min-width="150" | |||||
width="150" | |||||
prop="createTime" | |||||
></el-table-column | ></el-table-column | ||||
><el-table-column | ><el-table-column | ||||
label="申请理由" | label="申请理由" | ||||
align="center" | align="center" | ||||
min-width="150" | |||||
width="150" | |||||
prop="note" | |||||
></el-table-column> | ></el-table-column> | ||||
<el-table-column | <el-table-column | ||||
label="产业链名称" | label="产业链名称" | ||||
align="center" | align="center" | ||||
min-width="150" | |||||
width="150" | |||||
prop="name" | |||||
></el-table-column> | ></el-table-column> | ||||
<el-table-column | <el-table-column | ||||
label="类型" | label="类型" | ||||
align="center" | align="center" | ||||
min-width="100" | |||||
width="100" | |||||
prop="type" | prop="type" | ||||
></el-table-column> | ></el-table-column> | ||||
<el-table-column | <el-table-column | ||||
label="指标名称" | label="指标名称" | ||||
align="center" | align="center" | ||||
min-width="100" | |||||
width="100" | |||||
prop="content" | |||||
></el-table-column> | ></el-table-column> | ||||
<el-table-column | <el-table-column | ||||
label="分值" | label="分值" | ||||
align="center" | align="center" | ||||
min-width="100" | |||||
width="80" | |||||
prop="points" | |||||
></el-table-column> | ></el-table-column> | ||||
<el-table-column | <el-table-column | ||||
label="牵头部门" | label="牵头部门" | ||||
align="center" | align="center" | ||||
min-width="100" | |||||
width="150" | |||||
prop="leaderDeptList" | |||||
></el-table-column> | ></el-table-column> | ||||
<el-table-column | <el-table-column | ||||
label="配合部门" | label="配合部门" | ||||
align="center" | align="center" | ||||
min-width="100" | |||||
width="150" | |||||
prop="cooperateDeptList" | |||||
></el-table-column> | ></el-table-column> | ||||
<el-table-column label="操作" align="center" min-width="120"> | <el-table-column label="操作" align="center" min-width="120"> | ||||
<el-link @click="edit(true)" type="primary" :underline="false" | |||||
>同意</el-link | |||||
> | |||||
<el-link @click="edit(false)" type="primary" :underline="false" | |||||
>不同意</el-link | |||||
> | |||||
<template slot-scope="{ row }"> | |||||
<el-link @click="edit(row, true)" type="primary" :underline="false" | |||||
:disabled="judge(row)" | |||||
>同意</el-link | |||||
> | |||||
<el-link @click="edit(row, false)" type="primary" :underline="false" | |||||
:disabled="judge(row)" | |||||
>不同意</el-link | |||||
> | |||||
</template> | |||||
</el-table-column> | </el-table-column> | ||||
</el-table> | </el-table> | ||||
<el-pagination | <el-pagination | ||||
<script> | <script> | ||||
import search from "../search"; | import search from "../search"; | ||||
import { mapGetters } from "vuex"; | |||||
import api from '@/api/chain/coordinationManage/approvalCooperation' | |||||
export default { | export default { | ||||
components: { | components: { | ||||
search, | search, | ||||
}, | }, | ||||
data() { | data() { | ||||
return { | return { | ||||
dataList: [[]], | |||||
searchParams: {}, | |||||
dataList: [], | |||||
count: 0, | count: 0, | ||||
page: { | page: { | ||||
page: 1, | page: 1, | ||||
}, | }, | ||||
}; | }; | ||||
}, | }, | ||||
computed: { | |||||
...mapGetters(['user']), | |||||
}, | |||||
created() { | |||||
this.getDataList() | |||||
}, | |||||
methods: { | methods: { | ||||
getDataList() {}, | |||||
edit(flag) { | |||||
judge(row) { | |||||
if(row.status == 0) { | |||||
return false | |||||
} else if (row.status == 1 || row.status == 2) { | |||||
return true | |||||
} | |||||
}, | |||||
updateParams(data) { | |||||
this.searchParams = data; | |||||
this.resetCurrentPage(); | |||||
this.getDataList(); | |||||
}, | |||||
resetCurrentPage() { | |||||
let page = this.page; | |||||
page.page = 1; | |||||
this.page = page; | |||||
}, | |||||
getDataList() { | |||||
api.getDataList(Object.assign({}, this.page, this.searchParams)).then((res)=> { | |||||
let data = res.data.data | |||||
this.count = data.total; | |||||
this.dataList = data.records; | |||||
}).catch((e)=>{ | |||||
this.dataList = []; | |||||
this.count = 0; | |||||
}).finally(()=>{ | |||||
this.loading = false | |||||
}) | |||||
}, | |||||
edit(row, flag) { | |||||
this.showEdit = true; | this.showEdit = true; | ||||
this.form.id = row.id | |||||
this.form.itemId = row.id | |||||
this.form.leaderDept = row.leaderDept | |||||
this.form.cooperateDept = row.cooperateDept | |||||
if (flag) { | if (flag) { | ||||
this.form.status = 1 | |||||
this.warning = { | this.warning = { | ||||
title: "确定同意此申请?", | title: "确定同意此申请?", | ||||
info: "点击确定后,该部门将添加至考核任务配合部门中", | info: "点击确定后,该部门将添加至考核任务配合部门中", | ||||
}; | }; | ||||
} else { | } else { | ||||
this.form.status = 2 | |||||
this.warning = { | this.warning = { | ||||
title: "确定不同意此申请?", | title: "确定不同意此申请?", | ||||
info: | info: |
:height="tableHeight" | :height="tableHeight" | ||||
v-loading="loading" | v-loading="loading" | ||||
> | > | ||||
<el-table-column | |||||
<el-table-column | |||||
type="index" | type="index" | ||||
width="50" | width="50" | ||||
align="center" | align="center" | ||||
label="序号" | label="序号" | ||||
></el-table-column> | ></el-table-column> | ||||
<el-table-column | <el-table-column | ||||
label="产业链名称" | |||||
label="申请部门" | |||||
align="center" | align="center" | ||||
min-width="150" | |||||
width="150" | |||||
prop="applyDeptList" | |||||
></el-table-column> | ></el-table-column> | ||||
<el-table-column | <el-table-column | ||||
label="申请部门" | |||||
align="center" | |||||
min-width="150" | |||||
></el-table-column | |||||
><el-table-column | |||||
label="申请时间" | label="申请时间" | ||||
align="center" | align="center" | ||||
min-width="150" | |||||
width="150" | |||||
prop="createTime" | |||||
></el-table-column | ></el-table-column | ||||
><el-table-column | ><el-table-column | ||||
label="申请理由" | label="申请理由" | ||||
align="center" | align="center" | ||||
min-width="150" | |||||
width="150" | |||||
prop="note" | |||||
></el-table-column> | |||||
<el-table-column | |||||
label="产业链名称" | |||||
align="center" | |||||
width="150" | |||||
prop="name" | |||||
></el-table-column> | ></el-table-column> | ||||
<el-table-column | <el-table-column | ||||
label="类型" | label="类型" | ||||
align="center" | align="center" | ||||
min-width="100" | |||||
width="100" | |||||
prop="type" | prop="type" | ||||
></el-table-column> | ></el-table-column> | ||||
<el-table-column | <el-table-column | ||||
label="指标名称" | label="指标名称" | ||||
align="center" | align="center" | ||||
min-width="100" | |||||
width="100" | |||||
prop="content" | |||||
></el-table-column> | ></el-table-column> | ||||
<el-table-column | <el-table-column | ||||
label="分值" | label="分值" | ||||
align="center" | align="center" | ||||
min-width="100" | |||||
width="80" | |||||
prop="points" | |||||
></el-table-column> | ></el-table-column> | ||||
<el-table-column | <el-table-column | ||||
label="牵头部门" | label="牵头部门" | ||||
align="center" | align="center" | ||||
min-width="100" | |||||
width="150" | |||||
prop="leaderDeptList" | |||||
></el-table-column> | ></el-table-column> | ||||
<el-table-column | <el-table-column | ||||
label="配合部门" | label="配合部门" | ||||
align="center" | align="center" | ||||
min-width="100" | |||||
width="150" | |||||
prop="cooperateDeptList" | |||||
></el-table-column> | ></el-table-column> | ||||
<el-table-column label="操作" align="center" min-width="100"> | |||||
<el-link | |||||
@click="edit" | |||||
icon="el-icon-edit" | |||||
type="primary" | |||||
:underline="false" | |||||
>申请</el-link | |||||
> | |||||
<el-table-column label="操作" align="center" min-width="120"> | |||||
<template slot-scope="{ row }"> | |||||
<el-link type="primary" v-if="row.status == 0">审核中</el-link> | |||||
<el-link type="primary" v-if="row.status == 1">审核通过</el-link> | |||||
<el-link type="primary" v-if="row.status == 2">已驳回</el-link> | |||||
</template> | |||||
</el-table-column> | </el-table-column> | ||||
</el-table> | </el-table> | ||||
<el-pagination | <el-pagination | ||||
<script> | <script> | ||||
import search from "../search"; | import search from "../search"; | ||||
import { mapGetters } from "vuex"; | |||||
import api from '@/api/chain/coordinationManage/approvalCooperation' | |||||
export default { | export default { | ||||
components: { | components: { | ||||
search, | search, | ||||
}, | }, | ||||
data() { | data() { | ||||
return { | return { | ||||
dataList: [[]], | |||||
searchParams: {}, | |||||
dataList: [], | |||||
count: 0, | count: 0, | ||||
page: { | page: { | ||||
page: 1, | page: 1, | ||||
showEdit: false, | showEdit: false, | ||||
}; | }; | ||||
}, | }, | ||||
computed: { | |||||
...mapGetters(['user']), | |||||
}, | |||||
created() { | |||||
this.getDataList() | |||||
}, | |||||
methods: { | methods: { | ||||
getDataList() {}, | |||||
edit() { | |||||
this.showEdit = true; | |||||
updateParams(data) { | |||||
this.searchParams = data; | |||||
this.resetCurrentPage(); | |||||
this.getDataList(); | |||||
}, | |||||
resetCurrentPage() { | |||||
let page = this.page; | |||||
page.page = 1; | |||||
this.page = page; | |||||
}, | |||||
getDataList() { | |||||
api.getDataList(Object.assign({}, this.page, this.searchParams)).then((res)=> { | |||||
let data = res.data.data | |||||
this.count = data.total; | |||||
this.dataList = data.records; | |||||
}).catch((e)=>{ | |||||
this.dataList = []; | |||||
this.count = 0; | |||||
}).finally(()=>{ | |||||
this.loading = false | |||||
}) | |||||
}, | }, | ||||
save() {}, | |||||
}, | }, | ||||
}; | }; | ||||
</script> | </script> |
this.form.leaderDept = row.leaderDept; | this.form.leaderDept = row.leaderDept; | ||||
}, | }, | ||||
save() { | save() { | ||||
console.log(this.form); | |||||
applyApi | applyApi | ||||
.applyCooperate(Object.assign({}, this.form)) | .applyCooperate(Object.assign({}, this.form)) | ||||
.then((res) => { | .then((res) => { |