Commit 3dfa2583 authored by miaojiale's avatar miaojiale

1. 修改切换筛查提示图片

2. 修改临时保存按钮位置
3. 去除接口所传的formRecordId
parent c6ac0b41
...@@ -271,44 +271,45 @@ export default { ...@@ -271,44 +271,45 @@ export default {
}, },
// 临时保存 // 临时保存
temporarySave() { temporarySave() {
//? 只传数据 //? 只传数据 获取当前步数,如果个人信息已经提交可以临时保存
this.$refs.form.validate((valid) => {
if (valid) { // this.$refs.form.validate((valid) => {
const data = {} // if (valid) {
const form = this.deepClone(this.form) const data = {}
Object.keys(form).forEach((k) => { const form = this.deepClone(this.form)
if (form[k] === undefined) { Object.keys(form).forEach((k) => {
data[k] = "" if (form[k] === undefined) {
return false data[k] = ""
} return false
if (k === "YZZKJC") { }
// 牙周表格 if (k === "YZZKJC") {
data[k] = JSON.stringify(form[k]) // 牙周表格
} else if ( data[k] = JSON.stringify(form[k])
Array.isArray(form[k]) && } else if (
form[k][0] && Array.isArray(form[k]) &&
isObject(form[k][0]) form[k][0] &&
) { isObject(form[k][0])
// 子表单 去除前端添加的显隐辅助数据($_)和 删除按钮辅助数据(showDelBtn) ) {
data[k] = form[k].map((item) => { // 子表单 去除前端添加的显隐辅助数据($_)和 删除按钮辅助数据(showDelBtn)
for (let key in item) { data[k] = form[k].map((item) => {
if (["$_keyField", "$_hidden", "showDelBtn"].includes(key)) for (let key in item) {
delete item[key] if (["$_keyField", "$_hidden", "showDelBtn"].includes(key))
} delete item[key]
return item
})
} else {
data[k] = form[k]
} }
}) return item
this.$emit("temporaryConfirm", data, () => {
// 完成之后的回调
this.loading = false
}) })
} else { } else {
this.loading = false data[k] = form[k]
} }
}) })
this.$emit("temporaryConfirm", data, () => {
// 完成之后的回调
this.loading = false
})
// } else {
// this.loading = false
// }
// })
}, },
handleConfirm() { handleConfirm() {
this.loading = true this.loading = true
...@@ -461,6 +462,7 @@ export default { ...@@ -461,6 +462,7 @@ export default {
} }
.form-footer { .form-footer {
margin-top: 20px; margin-top: 20px;
margin-bottom: 20px;
text-align: center; text-align: center;
} }
} }
......
...@@ -569,12 +569,18 @@ export default { ...@@ -569,12 +569,18 @@ export default {
} }
.right { .right {
flex: 1; flex: 1;
.r_col_item:nth-child(4) {
img {
align-self: flex-start;
}
}
.r_col_item { .r_col_item {
min-height: 72px; min-height: 72px;
display: flex; display: flex;
justify-content: flex-start; justify-content: flex-start;
align-items: center; align-items: center;
padding: 20px 0 20px 20px; padding: 20px 0 20px 20px;
img { img {
width: 26px; width: 26px;
height: 26px; height: 26px;
......
<template> <template>
<div <div
id="publicContent" id="publicContent"
:style="{ :class="[
padding: activeName == 'index0' && formClass ? formClass : '',
$route.path == '/screening/draft' $route.path === '/screening/draft' ? 'p_padding' : '',
? ' 10px 24px 60px;' ]"
: ' 32px 24px 60px;',
}"
:class="activeName == 'index0' && formClass ? formClass : ''"
> >
<div v-if="formTabs && formTabs.length > 0"> <div v-if="formTabs && formTabs.length > 0" style="position: relative">
<el-button <el-button
v-if="!disabled" v-if="!disabled"
class="draftButton" class="draftButton"
...@@ -31,6 +28,7 @@ ...@@ -31,6 +28,7 @@
:key="form.id" :key="form.id"
:label="form.label" :label="form.label"
:name="'index' + index" :name="'index' + index"
disabled
> >
<!-- disabled --> <!-- disabled -->
<transition mode="out-in" name="fade-transform"> <transition mode="out-in" name="fade-transform">
...@@ -148,7 +146,7 @@ export default { ...@@ -148,7 +146,7 @@ export default {
watch: { watch: {
activeName(val) { activeName(val) {
if (!this.disabled) { if (!this.disabled) {
if (!["index0"].includes(val)) { if (!["index0", "index1"].includes(val)) {
this.infoCompelete = true this.infoCompelete = true
} else { } else {
this.infoCompelete = false this.infoCompelete = false
...@@ -277,9 +275,10 @@ export default { ...@@ -277,9 +275,10 @@ export default {
<style lang="scss" scoped> <style lang="scss" scoped>
#publicContent { #publicContent {
position: relative; position: relative;
padding: 32px 24px 32px;
.draftButton { .draftButton {
position: absolute; position: absolute;
top: 46px; top: 0px;
right: 40px; right: 40px;
z-index: 999; z-index: 999;
border-radius: 4px; border-radius: 4px;
...@@ -293,6 +292,9 @@ export default { ...@@ -293,6 +292,9 @@ export default {
} }
} }
} }
#publicContent.p_padding {
padding: 10px 24px 32px;
}
::v-deep .el-dialog__body { ::v-deep .el-dialog__body {
.title { .title {
font-size: 22px; font-size: 22px;
......
...@@ -180,7 +180,7 @@ export default { ...@@ -180,7 +180,7 @@ export default {
data, data,
formId: this.form.formId, // 每个大表单的id formId: this.form.formId, // 每个大表单的id
patientId: this.patientId || this.patientStandbyId, patientId: this.patientId || this.patientStandbyId,
formRecordId: this.formData.formRecordId || this.newformRecordId, // 是否为编辑的表单id // formRecordId: this.formData.formRecordId || this.newformRecordId, // 是否为编辑的表单id
statusMap: { statusMap: {
patient_from: this.$store.getters["table/selectedIndex"], patient_from: this.$store.getters["table/selectedIndex"],
is_draft: 1, //是否为草稿 is_draft: 1, //是否为草稿
...@@ -204,7 +204,7 @@ export default { ...@@ -204,7 +204,7 @@ export default {
data, data,
formId: this.form.formId, // 每个大表单的id formId: this.form.formId, // 每个大表单的id
patientId: this.patientId || this.patientStandbyId, patientId: this.patientId || this.patientStandbyId,
formRecordId: this.formData.formRecordId || this.newformRecordId, // 是否为编辑的表单id // formRecordId: this.formData.formRecordId || this.newformRecordId, // 是否为编辑的表单id
statusMap: { statusMap: {
patient_from: this.$store.getters["table/selectedIndex"], patient_from: this.$store.getters["table/selectedIndex"],
is_draft: 0, //是否为草稿 is_draft: 0, //是否为草稿
...@@ -421,7 +421,7 @@ export default { ...@@ -421,7 +421,7 @@ export default {
z-index: 9; z-index: 9;
} }
.header { .header {
height: 36px; height: 5px;
box-shadow: 0 5px 4px rgb(0 21 41 / 8%); box-shadow: 0 5px 4px rgb(0 21 41 / 8%);
padding-right: 20px; padding-right: 20px;
position: relative; position: relative;
......
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