diff --git a/src/api/contract/contract.js b/src/api/contract/contract.js index 8dea8d6..8a093ed 100644 --- a/src/api/contract/contract.js +++ b/src/api/contract/contract.js @@ -32,10 +32,10 @@ export function delContract(params){ }) } -export function editorContract(post){ +export function editorContract(data){ return request({ method:'post', url:'/api/admin/contract/save', - post + data }) } diff --git a/src/views/budget/budgetList.vue b/src/views/budget/budgetList.vue index ce70c66..13124c3 100644 --- a/src/views/budget/budgetList.vue +++ b/src/views/budget/budgetList.vue @@ -45,12 +45,13 @@ + *项目名称 - - + + @@ -112,7 +113,8 @@ - + + *项目名称 @@ -125,7 +127,7 @@ *预算类型 - + {{ item.label }} @@ -135,7 +137,7 @@ *项目所属年份 - form.year = e"> + editorForm.year = e"> @@ -344,21 +346,28 @@ export default { //修改 editorTable(){ - editorBudget({ - id:this.editorForm.id, - type:this.editorForm.type, - year:this.editorForm.year, - content:this.editorForm.content, - money:this.editorForm.money, - remark:this.editorForm.remark, - plan_department_id:this.editorForm.department - }).then(res=>{ - this.isShowEditor = false - Message({ - message:'操作成功', - type:'success' + this.$refs['editorDialog'].$refs['elForm'].validate().then(res=>{ + editorBudget({ + id:this.editorForm.id, + type:this.editorForm.type, + year:this.editorForm.year, + content:this.editorForm.content, + money:this.editorForm.money, + remark:this.editorForm.remark, + plan_department_id:this.editorForm.department + }).then(res=>{ + this.isShowEditor = false + Message({ + message:'操作成功', + type:'success' + }) + this.getBudgets() + }) + }).catch(err=>{ + this.$message({ + message:'请填写完整信息', + type:'error' }) - this.getBudgets() }) }, showEditor(row){ @@ -376,6 +385,7 @@ export default { remark:res.remark } this.isShowEditor = true + console.log(this.editorForm) }) }, }, diff --git a/src/views/contract/components/editorContract.vue b/src/views/contract/components/editorContract.vue new file mode 100644 index 0000000..13268bf --- /dev/null +++ b/src/views/contract/components/editorContract.vue @@ -0,0 +1,323 @@ + + + + + + + *项目名称 + + + + + + + + *项目类型 + + + {{ item.label }} + + + + + + + *采购类型 + + + {{ item.value }} + + + + + + + *采购形式 + + + {{ item.value }} + + + + + + + *合同预算价 + + + + (万) + + + + + *资金渠道 + + + {{ item.value }} + + + + + + + *是否预算 + + + + + + + + *关联预算计划 + + + + + {{item.label}} + + + + 请选择关联计划 + + + + + + + + + + + + + + + + + scope.row.useMoney = e"/> + + + + + + + + + + + + 确定 + + + + + + + + diff --git a/src/views/contract/contractList.vue b/src/views/contract/contractList.vue index 8ef1c3f..7f74a83 100644 --- a/src/views/contract/contractList.vue +++ b/src/views/contract/contractList.vue @@ -82,7 +82,17 @@ - deleteContract(row.id)"> + deleteContract(row.id)"> + + + + deleteContract(scope.row.id)" ghost>删除 + 查看 + 编辑 + + + + @@ -244,7 +254,7 @@ - {{item.label}} + {{item.label}} @@ -261,7 +271,7 @@ - + @@ -281,6 +291,8 @@ + + @@ -360,17 +372,22 @@