Commit bffbb00d authored by 黄自鹏's avatar 黄自鹏

履职管理增加按钮完成,取消完成

parent a29c0bed
...@@ -51,7 +51,20 @@ export function doAddDtl(query) { ...@@ -51,7 +51,20 @@ export function doAddDtl(query) {
}) })
} }
export function lzwc(query) {
return request({
url: 'aqgl/rcgl/lzrw/lzwc',
method: 'post',
data: query||{}
})
}
export function qxwc(query) {
return request({
url: 'aqgl/rcgl/lzrw/qxwc',
method: 'post',
data: query||{}
})
}
...@@ -38,7 +38,7 @@ ...@@ -38,7 +38,7 @@
<AttachFileButton :app='app'></AttachFileButton> <AttachFileButton :app='app'></AttachFileButton>
<FieldButton :app='app'></FieldButton> <FieldButton :app='app'></FieldButton>
<ExcelButton :app='app'></ExcelButton> <ExcelButton :app='app'></ExcelButton>
<WorkFlowButton :app='this'></WorkFlowButton> <!--<WorkFlowButton :app='this'></WorkFlowButton>-->
<!-- 额外按钮--> <!-- 额外按钮-->
<!-- 表头设置 --> <!-- 表头设置 -->
...@@ -56,7 +56,7 @@ ...@@ -56,7 +56,7 @@
<!-- tabs --> <!-- tabs -->
<el-tabs v-model="activeName" @tab-click="handleClick" > <el-tabs v-model="activeName" @tab-click="handleClick" >
<el-tab-pane label="履职报告" name="first" > <el-tab-pane label="履职报告" name="first" >
<Report ref="report" /> <Report :mapp="app" ref="report" />
</el-tab-pane> </el-tab-pane>
</el-tabs> </el-tabs>
</div> </div>
......
...@@ -34,7 +34,10 @@ ...@@ -34,7 +34,10 @@
<AttachFileButton :app='app' ></AttachFileButton> <AttachFileButton :app='app' ></AttachFileButton>
<FieldButton :app='app'></FieldButton> <FieldButton :app='app'></FieldButton>
<ExcelButton :app='app'></ExcelButton> <ExcelButton :app='app'></ExcelButton>
<!-- 额外按钮--> <!-- 额外按钮-->
<el-button @click="lzwc" size='mini' type="primary">履职完成</el-button>
<el-button @click="qxwc" size='mini' type="primary">取消完成</el-button>
<!-- 表头设置 --> <!-- 表头设置 -->
<!-- 权限--> <!-- 权限-->
...@@ -71,6 +74,7 @@ ...@@ -71,6 +74,7 @@
async mounted() { async mounted() {
this.$refs['TablePager'].pageQuery() this.$refs['TablePager'].pageQuery()
}, },
props:['mapp'],
data() { data() {
return { return {
/*需要的额外参数 */ /*需要的额外参数 */
...@@ -95,6 +99,70 @@ ...@@ -95,6 +99,70 @@
} }
}, },
methods: { methods: {
lzwc(){
//console.log(this.mapp.singleItem)
/*if (this.app.selectOne || this.app.clickOne) {
this.$confirm('确定发布该题库吗, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
publish({id:this.singleItem.id}).then(res=>{
if(res.success){
this.$success('该题库发布成功!')
this.$refs.TablePager.pageQuery()
}
})
// let id=this.singleItem.id
// this.$router.push({path: '/paper/'+id,query: { singleItem: this.singleItem}})
})
} else {
this.$warning('请选中一行操作');
}*/
if (this.mapp.selectOne || this.mapp.clickOne) {
this.$confirm('确认完成履职报告, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
lzwc({id:this.mapp.singleItem.id}).then(res=>{
if(res.success){
this.$success('履职报告已完成!')
this.$refs.TablePager.pageQuery()
}
})
// let id=this.singleItem.id
// this.$router.push({path: '/paper/'+id,query: { singleItem: this.singleItem}})
})
}else {
this.$warning('请选中一行操作');
}
},
qxwc(){
if (this.mapp.selectOne || this.mapp.clickOne) {
this.$confirm('取消完成履职报告, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
qxwc({id:this.mapp.singleItem.id}).then(res=>{
if(res.success){
this.$success('已取消!')
this.$refs.TablePager.pageQuery()
}
})
// let id=this.singleItem.id
// this.$router.push({path: '/paper/'+id,query: { singleItem: this.singleItem}})
})
}else {
this.$warning('请选中一行操作');
}
},
/* 基础查询*/ /* 基础查询*/
query: doQueryDtl, query: doQueryDtl,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment