diff --git a/src/request/systemapi.js b/src/request/systemapi.js index c09e1f4..ce7c489 100644 --- a/src/request/systemapi.js +++ b/src/request/systemapi.js @@ -116,9 +116,9 @@ export const examinationgender = (data) => { }); }; //性别修改 -export const modifygender = (SexId, data) => { +export const modifygender = (ID, data) => { return request({ - url: `/api/app/sex?SexId=${SexId}`, + url: `/api/app/sex/update=${ID}`, method: "put", data, }); @@ -280,7 +280,7 @@ export const statusaddition = (data) => { //状态列表修改 export const statusmodification = (id, data) => { return request({ - url: `/api/app/result-status?ResultStatusId=${id}`, + url: `/api/app/result-status?Id=${id}`, method: "put", data, }); diff --git a/src/views/Home.vue b/src/views/Home.vue index d1e2566..b6c0dbd 100644 --- a/src/views/Home.vue +++ b/src/views/Home.vue @@ -279,13 +279,13 @@ label-width="100px" > - + - + - + diff --git a/src/views/basic-dictionary/CustomerOrgType.vue b/src/views/basic-dictionary/CustomerOrgType.vue index 37b8f07..e1be31f 100644 --- a/src/views/basic-dictionary/CustomerOrgType.vue +++ b/src/views/basic-dictionary/CustomerOrgType.vue @@ -288,9 +288,11 @@ export default { }) .then(() => { customerdelat(this.form.id).then((res) => { - this.$message.success("删除成功"); - this.getlist(); - this.form = {}; + if (res.code == 0) { + this.$message.success("删除成功"); + this.getlist(); + this.form = {}; + } }); }) .catch(() => {}); @@ -346,9 +348,9 @@ export default { this.title = 1; this.dialogVisible = true; this.form = {}; - this.$nextTick(()=>{ - this.$refs.refinput.focus() - }) + this.$nextTick(() => { + this.$refs.refinput.focus(); + }); }, //点击列表通过id查询 rowick(row) { diff --git a/src/views/basic-dictionary/DiagnosisLevel.vue b/src/views/basic-dictionary/DiagnosisLevel.vue index de8407d..2ed9b71 100644 --- a/src/views/basic-dictionary/DiagnosisLevel.vue +++ b/src/views/basic-dictionary/DiagnosisLevel.vue @@ -328,13 +328,17 @@ export default { this.dialogVisible = false; }); } else if (this.title == 2) { - diagnosisedit(this.form.id, { - displayName: this.form.displayName, - }).then((res) => { - this.$message.success("修改成功"); - this.getlist(); - this.dialogVisible = false; - }); + if (this.form.displayName == "") { + this.$message.warning("请输入名称"); + } else { + diagnosisedit(this.form.id, { + displayName: this.form.displayName, + }).then((res) => { + this.$message.success("修改成功"); + this.getlist(); + this.dialogVisible = false; + }); + } } } }, @@ -343,9 +347,9 @@ export default { this.title = 1; this.dialogVisible = true; this.form = {}; - this.$nextTick(()=>{ - this.$refs.refinput.focus() - }) + this.$nextTick(() => { + this.$refs.refinput.focus(); + }); }, //点击列表通过id查询 rowick(row) { diff --git a/src/views/basic-dictionary/ResultStatus.vue b/src/views/basic-dictionary/ResultStatus.vue index 58650ec..846f432 100644 --- a/src/views/basic-dictionary/ResultStatus.vue +++ b/src/views/basic-dictionary/ResultStatus.vue @@ -103,42 +103,59 @@ prop="reportBackgroundColor" > {{ form.reportBackgroundColor }} + > - + {{ form.reportFontColor }} - - - - + @change="reportFontColorchange" + > - - + + + @@ -151,10 +168,16 @@ > @@ -166,8 +189,10 @@ -
- 编辑 +
+ 编辑
@@ -242,6 +267,33 @@ export default { this.rowDrop(); }, methods: { + //数据录入字体 + dataInputFontColorchange(v) { + var hexColor = v; + hexColor = hexColor.substring(1); + this.form.dataInputFontColor = parseInt(hexColor, 16); + }, + //数据录入背景 + dataInputBackgroundColorchange(v) { + var hexColor = v; + hexColor = hexColor.substring(1); + this.form.dataInputBackgroundColor = parseInt(hexColor, 16); + }, + //报告单字体色 + reportFontColorchange(v) { + var hexColor = v; + hexColor = hexColor.substring(1); + this.form.reportFontColor = parseInt(hexColor, 16); + }, + //报告单背景色 + reportBackgroundColorchange(v) { + var hexColor = v; + // 去除开头的#号 + hexColor = hexColor.substring(1); + // 转换为十进制 + this.form.reportBackgroundColor = parseInt(hexColor, 16); + console.log(this.form.reportBackgroundColor); + }, rowclick(row) { this.form = row; console.log(row); @@ -347,12 +399,10 @@ export default { // displayName: this.form.displayName, dataInputPrompt: this.form.dataInputPrompt, reportPrompt: this.form.reportPrompt, - reportBackgroundColor: Number(this.form.reportBackgroundColor), - reportFontColor: Number(this.form.reportFontColor), - dataInputBackgroundColor: Number( - this.form.dataInputBackgroundColor - ), - dataInputFontColor: Number(this.form.dataInputFontColor), + reportBackgroundColor: this.form.reportBackgroundColor, + reportFontColor: this.form.reportFontColor, + dataInputBackgroundColor: this.form.dataInputBackgroundColor, + dataInputFontColor: this.form.dataInputFontColor, }; statusmodification(this.form.id, obj).then((res) => { this.$message.success("修改成功"); diff --git a/src/views/basic-dictionary/SampleContainer.vue b/src/views/basic-dictionary/SampleContainer.vue index 2b8c723..f793e46 100644 --- a/src/views/basic-dictionary/SampleContainer.vue +++ b/src/views/basic-dictionary/SampleContainer.vue @@ -71,7 +71,7 @@ - + @@ -93,7 +93,12 @@ prop="containerColor" style="width: 90%; margin-top: -40px" > - + @@ -231,8 +236,17 @@ export default { }, methods: { colorchange(v) { - this.form.containerColor = parseInt(v) + var hexColor = v; + + // 去除开头的#号 + hexColor = hexColor.substring(1); + + // 转换为十进制 + this.form.containerColor = parseInt(hexColor, 16); + console.log(this.form.containerColor); + // this.form.containerColor = parseInt(v) + // console.log(this.form.containerColor); }, //取消排序 cancellation() { @@ -360,7 +374,7 @@ export default { newlyspecimen({ displayName: this.form.displayName, containerColorName: this.form.containerColorName, - containerColor: Number(this.form.containerColor), + containerColor: this.form.containerColor, }).then((res) => { this.$message.success("新增成功"); this.getlist(); @@ -370,7 +384,7 @@ export default { specimenediting(this.form.id, { displayName: this.form.displayName, containerColorName: this.form.containerColorName, - containerColor: Number(this.form.containerColor), + containerColor: this.form.containerColor, }).then((res) => { this.$message.success("修改成功"); this.getlist(); diff --git a/src/views/basic-dictionary/Sex.vue b/src/views/basic-dictionary/Sex.vue index 6f6e4bb..75e04f4 100644 --- a/src/views/basic-dictionary/Sex.vue +++ b/src/views/basic-dictionary/Sex.vue @@ -35,7 +35,12 @@
- + @@ -95,6 +100,7 @@ import { genderbottomtotop, modifydraganddrop, } from "../../request/systemapi"; +import { postapi } from "@/api/api"; export default { data() { return { @@ -114,6 +120,13 @@ export default { this.rowDrop(); }, methods: { + handleClose(done) { + this.$confirm("确认关闭?") + .then((_) => { + done(); + }) + .catch((_) => {}); + }, rowick(row) { this.form = row; }, @@ -194,14 +207,32 @@ export default { }, //确定修改 confirmmodification() { - modifygender(this.form.id, { - displayName: this.form.displayName, - simpleCode: this.form.simpleCode, - }).then((res) => { - this.$message.success("修改成功"); - this.getlist(); - this.dialogVisible = false; - }); + if (this.form.displayName == "") { + this.$message.warning("请输入名称"); + } else if (this.form.simpleCode == "") { + this.$message.warning("请输入快捷码"); + } else { + // modifygender(this.form.id, { + // displayName: this.form.displayName, + // simpleCode: this.form.simpleCode, + // }).then((res) => { + // if (res.code == 1) { + // this.$message.success("修改成功"); + // this.getlist(); + // this.dialogVisible = false; + // } + // }); + postapi(`/api/app/sex/update/${this.form.id}`, { + displayName: this.form.displayName, + simpleCode: this.form.simpleCode, + }).then((res) => { + if (res.code == 1) { + this.$message.success("修改成功"); + this.getlist(); + this.dialogVisible = false; + } + }); + } }, //编辑弹框 eddte() { @@ -209,6 +240,7 @@ export default { this.$message.warning("请选择操作的数据"); } else { let obj = Object.assign({}, this.form); + console.log(obj); this.form = obj; this.dialogVisible = true; } diff --git a/src/views/fee-settings/Item.vue b/src/views/fee-settings/Item.vue index c25d9c1..c494c3d 100644 --- a/src/views/fee-settings/Item.vue +++ b/src/views/fee-settings/Item.vue @@ -261,7 +261,7 @@ - + - + - - -