|
@@ -110,7 +110,6 @@ import BloodPressTagGroup from './BloodPressTagGroup';
|
|
|
import SymptomPush from './SymptomPush';
|
|
|
import api from '@api/icss.js';
|
|
|
import utils from '@api/utils.js';
|
|
|
-import { constants } from 'fs';
|
|
|
|
|
|
export default {
|
|
|
name: 'NoiseTemplateWrapper',
|
|
@@ -223,84 +222,84 @@ export default {
|
|
|
this.showDelDialog(param)
|
|
|
},
|
|
|
showDelDialog(param) {
|
|
|
- this.showConfirmDialog('是否保存该标签组?', () => {
|
|
|
- api.saveOrUpdate(param).then((res) => {
|
|
|
- if (res.data.code === '0') {
|
|
|
- this.warning(res.data.msg || '保存成功', 'success','1000')
|
|
|
- setTimeout(() => {
|
|
|
- this.$router.push({
|
|
|
- path:'/admin/LT-YXSJWH-BQZWH'
|
|
|
- })
|
|
|
- }, 1000);
|
|
|
- } else {
|
|
|
- this.warning(res.data.msg)
|
|
|
- }
|
|
|
- }).catch((err) => {
|
|
|
- this.warning(err);
|
|
|
- })
|
|
|
- });
|
|
|
- // const h = this.$createElement;
|
|
|
- // const {isEdit} = this.$route.params;
|
|
|
- // const addMsg = h('div',{style:'padding-bottom:10px'},[
|
|
|
- // h('p',{style:'font-size:15px;margin-bottom:10px'},'是否保存该标签组?')
|
|
|
- // ])
|
|
|
- // const modMsg = h('div',{style:'padding-bottom:10px'},[
|
|
|
- // h('p',{style:'font-size:15px;margin-bottom:10px'},'是否保存该标签组?'),
|
|
|
- // h('span',{style:'color:red;font-size:12px'},'若标签系统名称已经改变,请去别名维护中修改相关信息'),
|
|
|
- // ])
|
|
|
- // this.$msgbox({
|
|
|
- // title:'提示',
|
|
|
- // message:isEdit?modMsg:addMsg,
|
|
|
- // showCancelButton: true,
|
|
|
- // distinguishCancelAndClose:true,
|
|
|
- // confirmButtonText: '确认并前往别名维护',
|
|
|
- // cancelButtonText:'确认',
|
|
|
- // // type: 'warning',
|
|
|
- // cancelButtonClass:'toast-cancel'
|
|
|
- // }).then(()=>{
|
|
|
+ // this.showConfirmDialog('是否保存该标签组?', () => {
|
|
|
// api.saveOrUpdate(param).then((res) => {
|
|
|
// if (res.data.code === '0') {
|
|
|
- // this.warning(res.data.msg || '保存成功', 'success');
|
|
|
- // // 判断是否已有别名--有(修改),无(新增)
|
|
|
- // const item = {'questionId':param.questionWrapper.id,'questionName':param.questionWrapper.tagName};
|
|
|
- // api.similarNameDetl(item).then((res)=>{
|
|
|
- // if(res.data.code=='0'){
|
|
|
- // this.$router.push({
|
|
|
- // name:'AddSimilarName',
|
|
|
- // params: {id:param.questionWrapper.id,name:param.questionWrapper.tagName}
|
|
|
- // })
|
|
|
- // }else{
|
|
|
- // this.$router.push({
|
|
|
- // name:'AddSimilarName',
|
|
|
- // params: {}
|
|
|
- // })
|
|
|
- // }
|
|
|
- // })
|
|
|
+ // this.warning(res.data.msg || '保存成功', 'success','1000')
|
|
|
+ // setTimeout(() => {
|
|
|
+ // this.$router.push({
|
|
|
+ // path:'/admin/LT-YXSJWH-BQZWH'
|
|
|
+ // })
|
|
|
+ // }, 1000);
|
|
|
// } else {
|
|
|
// this.warning(res.data.msg)
|
|
|
// }
|
|
|
// }).catch((err) => {
|
|
|
// this.warning(err);
|
|
|
// })
|
|
|
- // }).catch((action)=>{
|
|
|
- // // action :cancel--取消,close--关闭
|
|
|
- // if(action=='cancel'){
|
|
|
- // api.saveOrUpdate(param).then((res) => {
|
|
|
- // if (res.data.code === '0') {
|
|
|
- // this.warning(res.data.msg || '保存成功', 'success');
|
|
|
- // setTimeout(() => {
|
|
|
- // this.$router.push({
|
|
|
- // path:'/admin/LT-YXSJWH-BQZWH'
|
|
|
- // })
|
|
|
- // }, 1000);
|
|
|
- // } else {
|
|
|
- // this.warning(res.data.msg)
|
|
|
- // }
|
|
|
- // }).catch((err) => {
|
|
|
- // this.warning(err);
|
|
|
- // })
|
|
|
- // }
|
|
|
- // })
|
|
|
+ // });
|
|
|
+ const h = this.$createElement;
|
|
|
+ const {isEdit} = this.$route.params;
|
|
|
+ const addMsg = h('div',{style:'padding-bottom:10px'},[
|
|
|
+ h('p',{style:'font-size:15px;margin-bottom:10px'},'是否保存该标签组?')
|
|
|
+ ])
|
|
|
+ const modMsg = h('div',{style:'padding-bottom:10px'},[
|
|
|
+ h('p',{style:'font-size:15px;margin-bottom:10px'},'是否保存该标签组?'),
|
|
|
+ h('span',{style:'color:red;font-size:12px'},'若标签系统名称已经改变,请去别名维护中修改相关信息'),
|
|
|
+ ])
|
|
|
+ this.$msgbox({
|
|
|
+ title:'提示',
|
|
|
+ message:isEdit?modMsg:addMsg,
|
|
|
+ showCancelButton: true,
|
|
|
+ distinguishCancelAndClose:true,
|
|
|
+ confirmButtonText: '确认并前往别名维护',
|
|
|
+ cancelButtonText:'确认',
|
|
|
+ // type: 'warning',
|
|
|
+ cancelButtonClass:'toast-cancel'
|
|
|
+ }).then(()=>{
|
|
|
+ api.saveOrUpdate(param).then((res) => {
|
|
|
+ if (res.data.code === '0') {
|
|
|
+ this.warning(res.data.msg || '保存成功', 'success');
|
|
|
+ // 判断是否已有别名--有(修改),无(新增)
|
|
|
+ const item = {'questionId':param.questionWrapper.id,'questionName':param.questionWrapper.tagName};
|
|
|
+ api.similarNameDetl(item).then((res)=>{
|
|
|
+ if(res.data.code=='0'){
|
|
|
+ this.$router.push({
|
|
|
+ name:'AddSimilarName',
|
|
|
+ params: {id:param.questionWrapper.id,name:param.questionWrapper.tagName}
|
|
|
+ })
|
|
|
+ }else{
|
|
|
+ this.$router.push({
|
|
|
+ name:'AddSimilarName',
|
|
|
+ params: {}
|
|
|
+ })
|
|
|
+ }
|
|
|
+ })
|
|
|
+ } else {
|
|
|
+ this.warning(res.data.msg)
|
|
|
+ }
|
|
|
+ }).catch((err) => {
|
|
|
+ this.warning(err);
|
|
|
+ })
|
|
|
+ }).catch((action)=>{
|
|
|
+ // action :cancel--取消,close--关闭
|
|
|
+ if(action=='cancel'){
|
|
|
+ api.saveOrUpdate(param).then((res) => {
|
|
|
+ if (res.data.code === '0') {
|
|
|
+ this.warning(res.data.msg || '保存成功', 'success');
|
|
|
+ setTimeout(() => {
|
|
|
+ this.$router.push({
|
|
|
+ path:'/admin/LT-YXSJWH-BQZWH'
|
|
|
+ })
|
|
|
+ }, 1000);
|
|
|
+ } else {
|
|
|
+ this.warning(res.data.msg)
|
|
|
+ }
|
|
|
+ }).catch((err) => {
|
|
|
+ this.warning(err);
|
|
|
+ })
|
|
|
+ }
|
|
|
+ })
|
|
|
},
|
|
|
showConfirmDialog(msg, resolve) {
|
|
|
this.$alert(msg, '提示', {
|