详情审批bug修改

main
liuyiliang 12 months ago
parent 9b3446fe68
commit d158bfa6b0
  1. 56
      src/views/leger/equipmentledgerDetail.vue
  2. 56
      src/views/leger/toolinventoryrecordDetail.vue
  3. 2
      src/views/smart/workorder.vue
  4. 51
      src/views/smart/workorderDetail.vue

@ -100,7 +100,7 @@
<!-- https://avuejs.com/form/form-rules.html#%E5%A4%96%E7%BD%AE%E9%AA%8C%E8%AF%81-->
</template>
<script>
import {getList, getDetail, add, update, remove} from "@/api/leger/equipmentledger";
import {getList, getDetail, add, update, remove, reject, auditing} from "@/api/leger/equipmentledger";
import {
parameters_add,
parameters_update,
@ -958,8 +958,7 @@
cancelButtonText: "取消",
type: "warning"
}).then(() => {
this.tab1_form.checkStatus="2"
this.submitRejectOrauditing();
this.submitRejectOrauditing('2');
});
},
reject() {
@ -968,26 +967,45 @@
cancelButtonText: "取消",
type: "warning"
}).then(() => {
this.tab1_form.checkStatus="3"
this.submitRejectOrauditing();
this.submitRejectOrauditing('3');
});
},
submitRejectOrauditing() {
update(this.tab1_form).then(() => {
this.$router.push({
path: "/leger/equipmentledger",
query: {},
});
this.$message({
type: "success",
message: "操作成功!"
submitRejectOrauditing(status) {
if (status === '2') {
auditing(this.tab1_form.id).then(() => {
this.$router.push({
path: "/leger/equipmentledger",
query: {},
});
this.$message({
type: "success",
message: "操作成功!"
});
}).catch((error) => {
console.log(error);
this.$message({
type: "error",
message: "操作失败!"
});
});
}).catch((error) => {
this.$message({
type: "error",
message: "操作失败!"
} else if (status === '3') {
reject(this.tab1_form.id).then(() => {
this.$router.push({
path: "/leger/equipmentledger",
query: {},
});
this.$message({
type: "success",
message: "操作成功!"
});
}).catch((error) => {
console.log(error);
this.$message({
type: "error",
message: "操作失败!"
});
});
});
}
},
del() {
this.$confirm("是否将选择数据删除?", {

@ -146,7 +146,7 @@
<!-- https://avuejs.com/form/form-rules.html#%E5%A4%96%E7%BD%AE%E9%AA%8C%E8%AF%81-->
</template>
<script>
import {getList, getDetail, add, update, remove} from "@/api/leger/toolinventoryrecord";
import {getList, getDetail, add, update, remove, reject, auditing} from "@/api/leger/toolinventoryrecord";
import {
inspection_add,
inspection_update,
@ -951,8 +951,7 @@ export default {
cancelButtonText: "取消",
type: "warning"
}).then(() => {
this.tab1_form.checkStatus = "2"
this.submitRejectOrauditing();
this.submitRejectOrauditing('2');
});
},
reject() {
@ -961,26 +960,45 @@ export default {
cancelButtonText: "取消",
type: "warning"
}).then(() => {
this.tab1_form.checkStatus = "3"
this.submitRejectOrauditing();
this.submitRejectOrauditing('3');
});
},
submitRejectOrauditing() {
update(this.tab1_form).then(() => {
this.$router.push({
path: "/leger/toolinventoryrecord",
query: {},
});
this.$message({
type: "success",
message: "操作成功!"
submitRejectOrauditing(status) {
if (status === '2') {
auditing(this.tab1_form.id).then(() => {
this.$router.push({
path: "/leger/toolinventoryrecord",
query: {},
});
this.$message({
type: "success",
message: "操作成功!"
});
}).catch((error) => {
console.log(error);
this.$message({
type: "error",
message: "操作失败!"
});
});
}).catch((error) => {
this.$message({
type: "error",
message: "操作失败!"
} else if (status === '3') {
reject(this.tab1_form.id).then(() => {
this.$router.push({
path: "/leger/toolinventoryrecord",
query: {},
});
this.$message({
type: "success",
message: "操作成功!"
});
}).catch((error) => {
console.log(error);
this.$message({
type: "error",
message: "操作失败!"
});
});
});
}
},
del() {
this.$confirm("是否将选择数据删除?", {

@ -625,11 +625,11 @@
});
},
submitForm() {
debugger
this.$refs['dialogForm'].validate((valid) => {
if (valid) {
this.loading = true;
var formData = {...this.dialogForm};
formData.approvalStatus = 1;
update(formData).then(() => {
this.onLoad(this.page);
this.$message({

@ -32,7 +32,7 @@
</basic-container>
</template>
<script>
import {getDetail, add, update, remove} from "@/api/smart/workorder";
import {getDetail, add, update, remove, reject, auditing} from "@/api/smart/workorder";
import {mapGetters} from "vuex";
export default {
@ -440,6 +440,7 @@
cancelButtonText: "取消",
type: "warning"
}).then(() => {
this.tab1_form.approvalStatus = 1;
update(this.tab1_form).then(() => {
this.$router.push({
path: "/smart/workorder",
@ -482,23 +483,41 @@
});
},
submitRejectOrauditing(status) {
var formData = {id: this.tab1_form.id, approvalStatus: status};
update(formData).then(() => {
this.$router.push({
path: "/smart/workorder",
query: {},
});
this.$message({
type: "success",
message: "操作成功!"
if (status === '2') {
auditing(this.tab1_form.id).then(() => {
this.$router.push({
path: "/smart/workorder",
query: {},
});
this.$message({
type: "success",
message: "操作成功!"
});
}).catch((error) => {
console.log(error);
this.$message({
type: "error",
message: "操作失败!"
});
});
}).catch((error) => {
console.log(error);
this.$message({
type: "error",
message: "操作失败!"
} else if (status === '3') {
reject(this.tab1_form.id).then(() => {
this.$router.push({
path: "/smart/workorder",
query: {},
});
this.$message({
type: "success",
message: "操作成功!"
});
}).catch((error) => {
console.log(error);
this.$message({
type: "error",
message: "操作失败!"
});
});
});
}
},
seachToUpdate() {
this.tab1_option.column[1].disabled = true;

Loading…
Cancel
Save