Kaynağa Gözat

Merge branch 'test'

zhouna 6 yıl önce
ebeveyn
işleme
9156036cbc
69 değiştirilmiş dosya ile 1693 ekleme ve 659 silme
  1. 1 0
      src/api/config.js
  2. 4 1
      src/api/icss.js
  3. 6 2
      src/api/utils.js
  4. 1 1
      src/components/admin/AddAdmin.vue
  5. 1 1
      src/components/admin/AddOrganization.vue
  6. 1 1
      src/components/admin/AddProductLine.vue
  7. 1 1
      src/components/admin/ModifinedOrga.vue
  8. 1 1
      src/components/admin/ProductDetail.vue
  9. 3 3
      src/components/common/Crumbs.vue
  10. 5 2
      src/components/icss/AddAssaySon.vue
  11. 35 33
      src/components/icss/AddChemicalAndCommonMapping.vue
  12. 9 5
      src/components/icss/AddChronicAndIndexRelation.vue
  13. 1 1
      src/components/icss/AddCommonSymptom.vue
  14. 19 7
      src/components/icss/AddConceptRelation.vue
  15. 1 1
      src/components/icss/AddDeptInfo.vue
  16. 1 1
      src/components/icss/AddDisAndScaleRelation.vue
  17. 4 3
      src/components/icss/AddDisclInfo.vue
  18. 29 74
      src/components/icss/AddIndeptLabel.vue
  19. 1 1
      src/components/icss/AddMedicalInfo.vue
  20. 7 4
      src/components/icss/AddMedicalMultRelation.vue
  21. 100 23
      src/components/icss/AddMedicalName.vue
  22. 5 3
      src/components/icss/AddMedicalRelation.vue
  23. 11 4
      src/components/icss/AddMedicinePrompt.vue
  24. 7 7
      src/components/icss/AddPhysicalExamTemp.vue
  25. 1 1
      src/components/icss/AddPromptInfo.vue
  26. 1 1
      src/components/icss/AddSimilarName.vue
  27. 7 3
      src/components/icss/AddVersion.vue
  28. 59 16
      src/components/icss/AssaySon.vue
  29. 52 7
      src/components/icss/ChemicalAndCommonMapping.vue
  30. 52 13
      src/components/icss/ChronicAndIndexRelation.vue
  31. 7 5
      src/components/icss/ChronicDiseaseAdd.vue
  32. 1 1
      src/components/icss/ChronicDiseaseManageAdd.vue
  33. 59 11
      src/components/icss/ChronicDiseaseStructureList.vue
  34. 57 11
      src/components/icss/ConceptRelation.vue
  35. 1 1
      src/components/icss/DeptInfoDetail.vue
  36. 0 47
      src/components/icss/DiagnosisPubTag.vue
  37. 2 2
      src/components/icss/DiagnosisTemplate.vue
  38. 1 1
      src/components/icss/DiscInfoDetail.vue
  39. 53 13
      src/components/icss/DisclaimerInformation.vue
  40. 63 8
      src/components/icss/IndeptLabel.vue
  41. 56 7
      src/components/icss/LabelGroup.vue
  42. 58 10
      src/components/icss/MedicalMultRelation.vue
  43. 132 43
      src/components/icss/MedicalName.vue
  44. 74 36
      src/components/icss/MedicalRelation.vue
  45. 13 1
      src/components/icss/MedicineInfoPg.vue
  46. 59 13
      src/components/icss/MedicinePrompt.vue
  47. 8 6
      src/components/icss/NoiseTemplate.vue
  48. 52 13
      src/components/icss/PhysicalExamTemplate.vue
  49. 1 1
      src/components/icss/PromptDetail.vue
  50. 31 16
      src/components/icss/PubIndeptTag.vue
  51. 1 41
      src/components/icss/PubTagGroup.vue
  52. 2 2
      src/components/icss/PubTemplateGroup.vue
  53. 79 3
      src/components/icss/SingleSelect.vue
  54. 68 23
      src/components/icss/TemplateMaintenance.vue
  55. 8 6
      src/components/icss/TemplateMaintenanceWrap.vue
  56. 1 1
      src/components/icss/VersionDetail.vue
  57. 34 6
      src/components/icss/VersionInfo.vue
  58. 11 8
      src/components/preTreat/AddCombinQuestion.vue
  59. 4 3
      src/components/preTreat/AddQuestionModules.vue
  60. 24 12
      src/components/preTreat/AddSimpleQuestion.vue
  61. 53 13
      src/components/preTreat/CombinQuestion.vue
  62. 28 14
      src/components/preTreat/PubIndeptQa.vue
  63. 62 28
      src/components/preTreat/PubSelect.vue
  64. 51 11
      src/components/preTreat/QuestionModules.vue
  65. 30 5
      src/components/preTreat/QuestionTagGroup.vue
  66. 69 11
      src/components/preTreat/SimpleQuestion.vue
  67. 8 1
      src/less/common.less
  68. 4 2
      src/routes.js
  69. 2 2
      vue.config.js

+ 1 - 0
src/api/config.js

@@ -213,6 +213,7 @@ export default {
     'removeRelationContact': 'api/knowledgeman/multContact/removeRelationContact', //知识库标准化-医学术语多层关联维护-删除或者恢复
     'relationContactDetail': 'api/knowledgeman/multContact/relationContactDetail', //知识库标准化-医学术语多层关联维护-详情
     'addMultRelation': 'api/knowledgeman/multContact/addRelation', //知识库标准化-医学术语多层关联维护-添加或者编辑
+    'reloadLib': 'api/knowledgeman/reload/createFile', //术语命名-加载词库
 	  /*********预问诊相关接口**********/
 	  'questionList':'/api/precman/questionInfo_prec/page',     //预问诊-填写单列表
     'questionAdd':'/api/precman/questionInfo_prec/saveOrUpdate',      //预问诊-填写单添加

+ 4 - 1
src/api/icss.js

@@ -417,5 +417,8 @@ export default {
     },
     addMultRelation(param) {    //知识库标准化-医学术语多层关联维护-添加或者编辑
         return axios.post(urls.addMultRelation, param)
-    }
+    },
+    reloadLib() {    //医学术语命名维护-加载词库
+        return axios.post(urls.reloadLib)
+    },
 }

+ 6 - 2
src/api/utils.js

@@ -203,7 +203,8 @@ export default {
       "labelPrefix":'prefix',                                 //前缀
       "labelSuffix":'suffix',                                 //后缀
       "maxValue":'maxNormalVal',                                 //前缀
-      "minValue":'minNormalVal'                                 //后缀
+      "minValue":'minNormalVal',                                 //后缀
+      "specFlag": 'specFlag' //标记状态(0:没有标记,1:主诉高亮,2:诱因记录)
     };
     if (tagFlag == 2) {
       maps["tagType"] = 'region2'
@@ -272,12 +273,15 @@ export default {
       //controlType:isDpt?'region2':'',
       type:'region1',
       url:'region13',
+      specFlag:'specFlag',
+      required: 'required',
+      explains:'explains',
     };
     isDpt?maps.controlType = 'region2':maps.tagType = 'region2';
     let obj = {};
     for(let i in org){
       if(maps[i]){
-        obj[maps[i]] = org[i]+'';
+        obj[maps[i]] = org[i]+''==='null'?'':org[i]+'';
       }
     }
     return obj;

+ 1 - 1
src/components/admin/AddAdmin.vue

@@ -121,7 +121,7 @@
         orgList: [],
         isEdit:false,
         userId:'',
-        link:'/admin/LT-KHZX-CGXX',
+        link:'superAdmin',
         curPage:'1',
         orgName:'',
         form: {

+ 1 - 1
src/components/admin/AddOrganization.vue

@@ -1,7 +1,7 @@
 <!-- 添加机构信息 By_liucf -->
 <template>
     <div>
-        <crumbs title="机构信息-添加机构" linkTo="/admin/LT-KHZX-JGXX">
+        <crumbs title="机构信息-添加机构" linkTo="organizationInfo">
         </crumbs>
         <div class="contents">
           <!--<img src="../../images/return.png" height="18" width="18" class="back" @click="back">-->

+ 1 - 1
src/components/admin/AddProductLine.vue

@@ -1,7 +1,7 @@
 <template>
     <div>
         <!-------------面包屑-------------->
-        <crumbs :title="`产品线管理-${isEdit?'修改':'添加'}产品线`" linkTo="/admin/LT-CPXGL">
+        <crumbs :title="`产品线管理-${isEdit?'修改':'添加'}产品线`" linkTo="productDetail">
         </crumbs>
         <!--------------表单--------------->
         <div class="contents">

+ 1 - 1
src/components/admin/ModifinedOrga.vue

@@ -1,7 +1,7 @@
 <!-- 添加机构信息 By_liucf -->
 <template>
     <div>
-        <crumbs title="机构信息-修改机构" linkTo="/admin/LT-KHZX-JGXX">
+        <crumbs title="机构信息-修改机构" linkTo="organizationInfo">
         </crumbs>
         <div class="contents">
             <el-form ref="form" :model="form" :rules="rules" label-width="110px" class="add-admin-form">

+ 1 - 1
src/components/admin/ProductDetail.vue

@@ -1,6 +1,6 @@
 <template>
     <div>
-        <crumbs title="产品线管理-产品线详情" linkTo="/admin/LT-CPXGL">
+        <crumbs title="产品线管理-产品线详情" linkTo="productDetail">
             <el-form :inline="true" class="demo-form-inline">
                 <el-form-item label="机构名称:">
                     <el-input size="mini" v-model="filter.orgName" placeholder="机构名称"></el-input>

+ 3 - 3
src/components/common/Crumbs.vue

@@ -11,15 +11,15 @@
 <script>
   export default {
     name: 'crumbs',
-    props: ['title','linkTo','minWidth'],//minWidth-有些头部选项比较多,最小宽度需要调整
+    props: ['title','linkTo','minWidth','param'],//minWidth-有些头部选项比较多,最小宽度需要调整
     data: function () {
       return {}
     },
     methods:{
       goBack(){
         this.$router.push({
-          path:this.linkTo,
-          query:this.curPage
+          name:this.linkTo,
+          params:this.param
         });
       }
     }

+ 5 - 2
src/components/icss/AddAssaySon.vue

@@ -3,7 +3,8 @@
         <crumbs
           :title="'化验子项维护-'+titleText"
           class="topBack"
-          linkTo="/admin/LT-YXSYKWH-HYZXWH"
+          :param="$route.params"
+          linkTo="AssaySon"
         ></crumbs>
         <el-form :model="form" ref="ruleForm"  class="addDepartForm">
             <p class="assayTitle">添加化验标准术语</p>
@@ -192,8 +193,10 @@
               if (res.data.code  === '0') {
                   this.warning(res.data.msg || '关联成功', 'success','1000')
                   setTimeout(() => {
+                    //返回带搜索条件的首页
                   this.$router.push({
-                      path:'/admin/LT-YXSYKWH-HYZXWH'
+                      name:'AssaySon',
+                    params: Object.assign({}, this.$route.params, {currentPage: 1})
                   })
                   }, 1000);
               } else {

+ 35 - 33
src/components/icss/AddChemicalAndCommonMapping.vue

@@ -5,15 +5,42 @@
                 @click="back"
         ></i> 化验大小项与公表项对应维护--添加关联</div> -->
         <crumbs
-          title="化验大小项与公表项对应维护--添加关联"
-          class="topBack"
-          linkTo="/admin/LT-YXSJWH-HYDXXYGBXDY"
+                title="化验大小项与公表项对应维护--添加关联"
+                class="topBack"
+                :param="$route.params"
+                linkTo="ChemicalAndCommonMapping"
         ></crumbs>
         <div class="AddChemicalAndCommonMappingBox clearfix">
             <div class="titleBox clearfix">
                 <p class="title">关联公表项</p>
                 <p class="title">关联化验项</p> 
             </div>
+            <div class="rightBox">
+                <div class="itemLabel">
+                    <label  class="itemLabelName">选择公表项:</label>
+                    <input class="searchInput"  @focus="focuInput" type="text" v-model = "uniqueText"> 
+                    <span class="searchName" @click="searchMealItem(3)">搜索</span>
+                    <ul class="itemList uniqueNameList" ref="uniqueNameList">
+                      <li 
+                        v-for="item in uniqueNameList" 
+                        class="mealNameItem ellipsis"
+                        :title="item.conceptName"
+                        @click="selectUniqueName(item)"
+                        :key="item.conceptName">
+                        {{item.conceptName}}
+                      </li>
+                    </ul>
+                </div>
+                <div class="itemLabel">
+                    <label  class="itemLabelName isRequired">已选择公表项:</label>
+                    <span class="selectItemName">{{form.uniqueName}}</span>
+                </div>
+            </div>
+            
+            <div class="midBox">
+                <img class="midLogo" src="../../images/relation.png" alt="">
+                <p class="midTitle">相互关联</p>
+            </div>
             <div class="leftBox clearfix" >
                 
                 <div class="itemLabel clearfix">
@@ -56,31 +83,6 @@
                     <span class="selectItemName">{{form.itemName}}</span>
                 </div>
             </div>
-            <div class="midBox">
-                <img class="midLogo" src="../../images/relation.png" alt="">
-                <p class="midTitle">相互关联</p>
-            </div>
-            <div class="rightBox">
-                <div class="itemLabel">
-                    <label  class="itemLabelName">选择公表项:</label>
-                    <input class="searchInput"  @focus="focuInput" type="text" v-model = "uniqueText"> 
-                    <span class="searchName" @click="searchMealItem(3)">搜索</span>
-                    <ul class="itemList uniqueNameList" ref="uniqueNameList">
-                      <li 
-                        v-for="item in uniqueNameList" 
-                        class="mealNameItem ellipsis"
-                        :title="item.conceptName"
-                        @click="selectUniqueName(item)"
-                        :key="item.conceptName">
-                        {{item.conceptName}}
-                      </li>
-                    </ul>
-                </div>
-                <div class="itemLabel">
-                    <label  class="itemLabelName isRequired">已选择公表项:</label>
-                    <span class="selectItemName">{{form.uniqueName}}</span>
-                </div>
-            </div>
         </div>
        <div class="btn">
            <!-- <span class="sumbit" @click="submitForm">建立关联</span> -->
@@ -135,9 +137,6 @@ export default {
             this.$refs['itemNameList'].style.display='none';
             this.$refs['uniqueNameList'].style.display='none';
         },
-        back() {
-            this.$router.go(-1)
-        },
         searchMealItem(type) {
             if( type == '1' || type == '2') {
                 this.getTagList(type)
@@ -206,7 +205,10 @@ export default {
             this.itemNameList = []
         },
         selectUniqueName(item) {
-             this.form.uniqueName = item.conceptName
+            this.form.uniqueName = item.conceptName
+            let nameArr = item.conceptName.split('--');
+            this.form.mealName = nameArr[0]
+            this.form.itemName = nameArr[1]
             this.$refs['uniqueNameList'].style.display='none'
             this.uniqueText = ''
             this.uniqueNameList = []
@@ -389,7 +391,7 @@ export default {
         z-index: 2;
         overflow-y: auto;
     }
-    .itemNameList {
+    .itemList {
         width: calc(100% - 131px);
     }
     .mealNameItem {

+ 9 - 5
src/components/icss/AddChronicAndIndexRelation.vue

@@ -8,7 +8,8 @@
         <crumbs
           :title="'慢病指标值关联维护-'+titleText"
           class="topBack"
-          linkTo="/admin/LT-YXSYKWH-MBZBZGLWH"
+          :param="$route.params"
+          linkTo="ChronicAndIndexRelation"
         ></crumbs>
         <el-form :model="form" ref="ruleForm"  class="addDepartForm">
             <el-form-item  class="addDepartFormItem"  v-if="!isEdit" label="选择慢病标准术语(概念ID):" prop="department">
@@ -148,9 +149,10 @@
             this.diagList=[]
         },
         focuInput() {
-            this.$refs['diagList'].style.display='none'
-             this.$refs['indexList'].style.display='none'
-            
+          if(this.$refs){
+            this.$refs['diagList'].style.display='none';
+            this.$refs['indexList'].style.display='none';
+          }
         },
         searchIndex() {
              const param = {
@@ -216,8 +218,10 @@
                 if (res.data.code  === '0') {
                     this.warning(res.data.msg || '关联成功', 'success','1000')
                     setTimeout(() => {
+                      //返回带搜索条件的首页
                     this.$router.push({
-                        path:'/admin/LT-YXSYKWH-MBZBZGLWH'
+                        name:'ChronicAndIndexRelation',
+                      params: Object.assign({}, this.$route.params, {currentPage: 1})
                     })
                     }, 1000);
                 } else {

+ 1 - 1
src/components/icss/AddCommonSymptom.vue

@@ -4,7 +4,7 @@
          <crumbs
           :title="'常见选项维护系统-' + titleText"
           class="topBack"
-          linkTo="/admin/LT-YXSJWH-CJXXWH"
+          linkTo="CommonSymptom"
         ></crumbs>
         <el-form :model="form" ref="ruleForm" :rules="rules" class="addDepartForm">
            

+ 19 - 7
src/components/icss/AddConceptRelation.vue

@@ -3,7 +3,8 @@
     <crumbs
     :title="'医学术语关联维护-'+titleText"
     class="topBack"
-    linkTo="/admin/LT-YXSYKWH-YXSYGLWH"
+    :param="$route.params"
+    linkTo="ConceptRelation"
     ></crumbs>
     <el-form :model="form" ref="ruleForm"  class="addDepartForm">
       <p class="assayTitle">选择医学标准术语</p>
@@ -123,7 +124,7 @@ export default {
       styles:{
         background:'#eae7e7'
       },
-      type:'',
+      type:null,
       typeList:[],
       nodeList:[],
       saveDisable: false  //保存按钮禁止点击
@@ -186,8 +187,17 @@ export default {
         },
         getTagList(flag) {
           const notIds = this.selectedTags();
-          let param;
-          if(flag){
+          //2019-8-15 需求修改:搜索结果与类型关联bug2045
+          let param = {
+              "name": this.searchTagVal,
+              "relationId": 17,
+              "relationPosition": 2,
+              "typeId": this.type, //选中类型的id
+              "relationConceptId":this.form.conceptId,
+              "excludedConceptIds":notIds
+            }
+          // let param;
+          /*if(flag){
             param = {
               "name": this.searchTagVal,
               "relationId": 17,
@@ -204,7 +214,7 @@ export default {
               "relationConceptId":this.form.conceptId,
               "excludedConceptIds":notIds
             }
-          }
+          }*/
           api.getConceptInfoAssay(param).then((res)=>{
            if(res.data.code === '0') {
              this.leftTagsList = res.data.data
@@ -314,13 +324,15 @@ export default {
           "sonRelationId": 17
         }
         this.showConfirmDialog('是否建立该关联?', () => {
-          this.saveDisable = true  //提交保存按钮不可点击,返回结果时才可点击,防止频繁发送请求
+          this.saveDisable = true;  //提交保存按钮不可点击,返回结果时才可点击,防止频繁发送请求
           api.addConceptRelation(param).then((res) => {
             if (res.data.code  === '0') {
               this.warning(res.data.msg || '关联成功', 'success','1000')
               setTimeout(() => {
+                //返回带搜索条件的首页
                 this.$router.push({
-                  path:'/admin/LT-YXSYKWH-YXSYGLWH'
+                  name:'ConceptRelation',
+                  params: Object.assign({}, this.$route.params, {currentPage: 1})
                 })
               }, 1000);
             } else {

+ 1 - 1
src/components/icss/AddDeptInfo.vue

@@ -1,7 +1,7 @@
 <!-- 添加机构信息 By_liucf -->
 <template>
     <div>
-        <crumbs :title="topInfo" linkTo="/admin/LT-YXSJWH-KSWH">
+        <crumbs :title="topInfo" linkTo="deptInfo">
         </crumbs>
         <div class="contents">
             <el-form ref="form" :label-position="labelPosition" :model="form" :rules="rules" label-width="100px" class="add-depart-form">

+ 1 - 1
src/components/icss/AddDisAndScaleRelation.vue

@@ -8,7 +8,7 @@
         <crumbs
           :title="'量表关联维护-'+titleText"
           class="topBack"
-          linkTo="/admin/LT-YXSJWH-LBGLWH"
+          linkTo="DisAndScaleRelation"
         ></crumbs>
         <el-form :model="form" ref="ruleForm"  class="addDepartForm">
             <el-form-item  v-if="!isEdit" label="选择诊断标签:" prop="department">

+ 4 - 3
src/components/icss/AddDisclInfo.vue

@@ -1,7 +1,8 @@
 <!-- 免责声明修改 By_liucf -->
 <template>
     <div>
-        <crumbs :title="topInfo" linkTo="/admin/LT-YXSJKWH-MZSMWH">
+        <crumbs :title="topInfo"
+                :param="$route.params" linkTo="DisclaimerInformation">
         </crumbs>
         <div class="contents">
             <el-form ref="form" :label-position="labelPosition" :model="form" :rules="rules" label-width="65px" class="add-discl-form">
@@ -143,7 +144,7 @@
               api.modifDiscInformation(param).then((res) => {
                 if (res.data.code == '0') {
                   this.$message({showClose: true,message: this.toast, type: 'success'});
-                  this.$router.push({path: 'LT-YXSJKWH-MZSMWH'});
+                  this.$router.push({name: 'DisclaimerInformation',params: Object.assign({}, this.$route.params, {currentPage: 1})});
                 } else {
                   this.$message({
                     showClose: true,
@@ -169,7 +170,7 @@
               api.addDiscInformation(param).then((res) => {
                 if (res.data.code == '0') {
                   this.$message({showClose: true,message: this.toast, type: 'success'});
-                  this.$router.push({path: 'LT-YXSJKWH-MZSMWH'});
+                  this.$router.push({name: 'DisclaimerInformation',params: Object.assign({}, this.$route.params, {currentPage: 1})});
                 } else {
                   this.$message({
                     showClose: true,

+ 29 - 74
src/components/icss/AddIndeptLabel.vue

@@ -1,9 +1,10 @@
 <template>
     <div class="NoiseTemplateWrapper TemplateWrapper">
         <crumbs
-          :title="txt"
-          class="topBack"
-          linkTo="/admin/LT-YXSJWH-DLLXBQWH"
+                :title="txt"
+                class="topBack"
+                :param="$route.params"
+                linkTo="IndeptLabel"
         ></crumbs>
         <PubIndeptTag
                 @changeVal="changeVal"
@@ -11,14 +12,15 @@
                 @changeType="changeType"
                 @validatePass="validatePass"
                 :editData="editData"
+                :isEditOrCopy="isEditOrCopy"
                 ref="submitForm"
         ></PubIndeptTag>
         <div class="main">
             <p class="title" v-if="dataPub.region2==1||dataPub.region2==2|| dataPub.region2==11">
                 <i>*</i> 标签明细:
-                <i v-if='dataPub.region2==2' style="margin-left:70px;color: #22ccc8; font-size: 12px;">所有选项必须都有或者都没有同“伴”/“无”标记</i>
+                <i v-if='dataPub.region2==2' style="margin-left:70px;color: #48C5D7; font-size: 12px;">所有选项必须都有或者都没有同“伴”/“无”标记</i>
             </p>
-            <SingleSelect v-if="dataPub.region2==1 || dataPub.region2==2 || dataPub.region2==11" :ascription="dataPub.region1" :sexType="dataPub.region7" :type="dataPub.region2" @pushValues="pushValues" :options="editData.questionDetailList"></SingleSelect>
+            <SingleSelect v-if="dataPub.region2==1 || dataPub.region2==2 || dataPub.region2==11" :ascription="dataPub.region1" :sexType="dataPub.region7" :type="dataPub.region2" @pushValues="pushValues" :isEditOrCopy="isEditOrCopy" :options="editData.questionDetailList"></SingleSelect>
             <div class="btn">
                 <el-button
                         type="primary"
@@ -55,14 +57,25 @@
           ]
         },
         options: [],           //标签明细右侧操作数据
-        saveDisable: false
+        saveDisable: false,
+        isEditOrCopy: false //
       }
     },
     beforeMount:function(){
-      const {isEdit,data} = this.$route.params;
+      const {isEdit,isCopy,data} = this.$route.params;
+     
       if(isEdit){
-        this.txt = '独立标签维护-修改独立标签'
-        this.editData = data;
+      this.txt = '独立标签维护-修改独立标签';
+      this.isEditOrCopy = true
+      this.editData = data;
+      } else if(isCopy) {
+        this.txt = '独立标签维护-复制独立标签';
+        this.isEditOrCopy = true
+        const copyData = JSON.parse(JSON.stringify(data))
+        copyData.id = ""
+        copyData.name=""  
+        copyData.tagName=""
+        this.editData = copyData;
       }
     },
     computed: {
@@ -72,7 +85,8 @@
     },
     watch: {
       newSign(nextVal, prevVal) {
-        if (nextVal != prevVal) {
+         const {isEdit,isCopy} = this.$route.params;
+        if (nextVal != prevVal && !isEdit&&!isCopy) {
           this.form.currentOrder = '0'
         }
       },
@@ -87,7 +101,9 @@
         //console.log(sex)
       },
       changeType(type) {        //填写单类型改变,标签明细左侧更新,右侧清空
-        // console.log('type',type)
+        if(this.isEditOrCopy&&type=='2') {
+          return
+        }
         this.options = [];
       },
       pushValues(its){
@@ -157,6 +173,7 @@
             "labelSuffix":this.dataPub.suffix,                                 //后缀
             "minValue": this.dataPub.minNormalVal,        //化验最小正常值
             "maxValue": this.dataPub.maxNormalVal,         //化验最大正常值
+            "specFlag": this.dataPub.specFlag,  //标记状态(0:没有标记,1:主诉高亮,2:诱因记录)
             "questionDetails": this.options,
             "questionMappings": [],      //映射关系,
             "formulaCode": isEdit?data.formulaCode : ''
@@ -170,7 +187,7 @@
           api.saveOrUpdate(param).then((res) => {
             if (res.data.code === '0') {
               this.warning(res.data.msg || '保存成功', 'success');
-              this.$router.push("/admin/LT-YXSJWH-DLLXBQWH");
+              this.$router.push({name: 'IndeptLabel', params: Object.assign({}, this.$route.params, {currentPage: 1})});
             } else {
               this.warning(res.data.msg)
             }
@@ -181,64 +198,6 @@
             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');
-      //           this.$router.push("/admin/LT-YXSJWH-DLLXBQWH");
-      //         } else {
-      //           this.warning(res.data.msg)
-      //         }
-      //       }).catch((err) => {
-      //         this.warning(err);
-      //       })
-      //     }
-      //   })
       },
       showConfirmDialog(msg, resolve) {
         this.$alert(msg, '提示', {
@@ -297,9 +256,5 @@
     }
     }
     }
-    .toast-cancel{
-      color: #22ccc8 !important;
-      // background: #22ccc8;
-    }
 </style>
 

+ 1 - 1
src/components/icss/AddMedicalInfo.vue

@@ -7,7 +7,7 @@
         <crumbs
           :title=" isEdit? '术语医学属性-修改':'术语医学属性-添加'"
           class="topBack"
-          linkTo="/admin/LT-YXSYKWH-SYYXSXWH"
+          linkTo="MedicalInfo"
         ></crumbs>
         <div class="info-container">
             <el-form :rules="rules"

+ 7 - 4
src/components/icss/AddMedicalMultRelation.vue

@@ -1,6 +1,6 @@
 <template>
   <div class="addMedicalMultRelationWrapper">
-    <crumbs :title="minTitle" linkTo="/admin/LT-YXSYKWH-YXSYDCGLWH"></crumbs>
+    <crumbs :title="minTitle" :param="$route.params" linkTo="MedicalMultRelation"></crumbs>
     <div class="contents">
       <div class="content">
         <div class="addBtn" v-if="list.length == 0">
@@ -33,7 +33,7 @@
             default-expand-all
             :expand-on-click-node="false">
             <span class="custom-tree-node" slot-scope="{ node, data }">
-                <span class="custom-tree-node-name ellipsis" :title="node.label">{{ node.label }}</span>
+                <span class="custom-tree-node-name ellipsis" :class="{colorGray: data.isDeletedConcept == 'Y'}" :title="node.label">{{ node.label }}</span>
                 <span class="btn-box">
                   <el-button
                       class="btn-add fl"
@@ -176,7 +176,8 @@ import api from '@api/icss.js';
           if(data.code == '0') {
             this.message(res.data.msg||'术语建立成功','success');
             setTimeout(() => {
-              this.$router.push({name:'MedicalMultRelation'});
+              //返回带搜索条件的首页
+              this.$router.push({name:'MedicalMultRelation',params:Object.assign({},this.$route.params,{currentPage:1})});
             }, 2000);
           } else {
             this.message(data.msg);
@@ -375,5 +376,7 @@ import api from '@api/icss.js';
   display: inline-block;
   width: 270px;
 }
-  
+.colorGray {
+  color: #c1c1c1;
+} 
 </style>

+ 100 - 23
src/components/icss/AddMedicalName.vue

@@ -1,6 +1,8 @@
 <template>
   <div>
-    <crumbs :title="minTitle" linkTo="/admin/LT-YXSYKWH-YXSYMMWH"></crumbs>
+    <crumbs :title="minTitle"
+            :param="$route.params"
+            linkTo="MedicalName"></crumbs>
     <div class="contents">
       <div class="content">
         <h3>添加术语:</h3>
@@ -22,17 +24,31 @@
               <input v-else type="text" v-model="data.name" placeholder="请输入术语" maxlength="50" @blur="handleBlur(1)">
             </td>
             <td>
-              <input type="text" v-model="data.spell" placeholder="请输入拼音" maxlength="50"  @input="handlePinyin">
+              <input type="text" v-model="data.spell" placeholder="请输入拼音" maxlength="50"  @input="handlePinyin($event,1)">
             </td>
             <td>
-              <el-select v-if="!id" v-model="data.type" filterable placeholder="请选择" size="small" @change="selectType">
+              <!-- <el-select v-if="!id" v-model="data.type" filterable placeholder="请选择" size="small" @change="selectType">
                 <el-option
                   v-for="item in typeList"
                   :key="item.id"
                   :label="item.name"
                   :value="item.name">
                 </el-option>
-              </el-select>
+              </el-select> -->
+              <template v-if="!id">
+                <el-select v-model="data.type" filterable clearable placeholder="请选择" size="small" @change="selectType">
+                  <el-option-group
+                    v-for="group in options"
+                    :key="group.label">
+                    <el-option
+                      v-for="item in group.options"
+                      :key="item.id"
+                      :label="item.name"
+                      :value="item.name">
+                    </el-option>
+                  </el-option-group>
+                </el-select>
+              </template>
               <span v-else>{{data.type}}</span>
             </td>
             <td class="desc">
@@ -56,16 +72,32 @@
               <td :title="item.name&&item.name.length>9?item.name:''">
                 <!-- 使用原生input,输入限制 -->
                 <!-- <el-input v-model="item.name" placeholder="请输入术语" maxlength="30" size="small" @input.native="handleInput(2,index)"></el-input> -->
-                <input type="text" v-model="item.name" :title="item.name" placeholder="请输入术语" maxlength="50" @blur="handleBlur(2,index,99)" :disabled="!item.isEdit">
+                <input type="text" v-model="item.name" :title="item.name" placeholder="请输入术语" maxlength="50" @blur="handleBlur(2,index,99)" >
               </td>
-              <td v-if="!item.isEdit">
+              <!-- <td v-if="!item.isEdit">
                 {{item.spell}}
               </td>
-              <td v-else>
-                <input type="text" v-model="item.spell" placeholder="请输入拼音" maxlength="50"  @input="handlePinyin" class="spell">
+              <td v-else> -->
+              <td>
+                <input type="text" v-model="item.spell" placeholder="请输入拼音" maxlength="50"  @input="handlePinyin($event,2,index)" class="spell">
               </td>
               <td>
-                {{data.type}}
+                <!-- {{data.type}} -->
+                <template v-if="index==0&&copy">
+                  <el-select v-model="data.type" filterable placeholder="请选择" size="small" @change="selectType">
+                    <el-option-group
+                      v-for="group in options"
+                      :key="group.label">
+                      <el-option
+                        v-for="item in group.options"
+                        :key="item.id"
+                        :label="item.name"
+                        :value="item.name">
+                      </el-option>
+                    </el-option-group>
+                  </el-select>
+                </template>
+                <span v-else>{{data.type}}</span>
               </td>
               <td class="desc">
                 <input v-model="item.remark" placeholder="请输入术语说明" maxlength="120"></input>
@@ -83,11 +115,11 @@
             </tr>
           </table>
           <div class="actionDo">
-            <div class="btnWrap">
+            <!-- <div class="btnWrap"> -->
               <!-- <el-button type="primary" size="mini" v-if="show" @click="comfirn(14)">确认修改</el-button> -->
-              <el-button plain size="mini" v-if="show" @click="toggleShow(1)">放弃修改</el-button>
-              <el-button plain size="mini" @click="toggleShow(2)" v-if="!show">修改标准词</el-button>
-            </div>
+              <!-- <el-button plain size="mini" v-if="show" @click="toggleShow(1)">放弃修改</el-button>
+              <el-button plain size="mini" @click="toggleShow(2)" v-if="!show">修改标准词</el-button> -->
+            <!-- </div> -->
             <div class="radioWrap" v-if="show">
               <el-radio-group v-model="radioVal" size="mini">
                 <el-radio v-for="(item,index) in allwords" :label="index" :disabled="index == 0">选为标准词</el-radio>
@@ -113,7 +145,7 @@
               <input type="text" v-model="item.name" placeholder="请输入术语" maxlength="50" @blur="handleBlur(2,index)">
             </td>
             <td>
-              <input type="text" v-model="item.spell" placeholder="请输入拼音" maxlength="50"  @input="handlePinyin">
+              <input type="text" v-model="item.spell" placeholder="请输入拼音" maxlength="50"  @input="handlePinyin($event,3,index)">
             </td>
             <td>
               {{data.type}}
@@ -209,14 +241,18 @@ import pinyin from '../../js/Convert_Pinyin.js';
           }
         ],
         unfit:false, //点确认时是否弹提示,
-        saveDisable: false  //保存按钮禁止点击
+        saveDisable: false,  //保存按钮禁止点击
+        options:[],
+        copy:null
       }
     },
     created(){
       this.getTypeList();
       const id = this.$route.params.id || '';
+      const copy = this.$route.params.copy || '';
+      this.copy = copy;
       if(id){
-        this.minTitle = '医学术语命名维护-修改';
+        this.minTitle = copy?'医学术语命名维护-复制':'医学术语命名维护-修改';
         this.id = id;
         this.colspan = 5;
         this.getDetail(id);
@@ -285,6 +321,23 @@ import pinyin from '../../js/Convert_Pinyin.js';
           if(data.code==0){
             // this.typeList = data.data.records;
             this.typeList = data.data;
+            // 类型改成平铺
+            if(data.data.length>0){
+              const total = data.data.length;
+              const average = parseInt(total/3);
+              const mod = total%3; //余数
+              const firstGroup = data.data.slice(0,average);
+              let secGroup = [];
+              let thirdGroup = [];
+              if(mod == 2){
+                secGroup = data.data.slice(average,average*2+1);
+                thirdGroup = data.data.slice(average*2+1,total);
+              }else{
+                secGroup = data.data.slice(average,average*2);
+                thirdGroup = data.data.slice(average*2,total);
+              }
+              this.options.push({label:1,options:firstGroup},{label:2,options:secGroup},{label:3,options:thirdGroup});
+            }
           }else{
             this.$message({
               message:data.msg,
@@ -327,16 +380,17 @@ import pinyin from '../../js/Convert_Pinyin.js';
         }else if(type==2){
           // 修改时术语名称、拼音和类型均不能修改
           if(flg == 99){
-              if(this.synonymous[index-1].name && !pattern.test(this.synonymous[index-1].name)){
+              // if(this.synonymous[index-1].name && !pattern.test(this.synonymous[index-1].name)){
+              if(this.allwords[index].name && !pattern.test(this.allwords[index].name)){
               this.$message({
-                // message:'无法输入纯数字或者纯字符,请输入正确数据!',
                 message:'无法输入纯数字,请输入正确数据!',
                 type:'warning'
               });
               // this.synonymous[index-1].name = '';
               this.unfit = true;
             }else{
-              let current = this.synonymous[index-1];
+              // let current = this.synonymous[index-1];
+              let current = this.allwords[index];
               current.spell = pinyin.getCamelChars(current.name);
               this.unfit = false;
             }
@@ -356,8 +410,17 @@ import pinyin from '../../js/Convert_Pinyin.js';
           }
         }
       },
-      handlePinyin(e){//只能输入英文
+      handlePinyin(e,flag,index){//只能输入英文
         e.target.value = e.target.value.replace(/[^a-zA-Z]/g,'');
+        // 解决输入数字不触发更新
+        if(flag==1){//标准词
+          this.data.spell = e.target.value;
+        }else if(flag==2){//同义词-修改
+          this.allwords[index].spell = e.target.value;
+        }else if(flag==3){//同义词-新增
+          this.synonymous[index].spell = e.target.value;
+        }
+        // e.target.value = e.target.value.replace(/[^a-zA-Z]/g,'');
       },
       addSpan(type){
         let singleSpan = {
@@ -484,7 +547,7 @@ import pinyin from '../../js/Convert_Pinyin.js';
             'name':this.data.name,
             'type':this.data.type,
             'detailList':detailList,
-            'conceptId':this.id,
+            'conceptId':this.copy?'':this.id,//复制当新增,把id置空
             'sexType':sexCode,
             'maxAge':this.maxAge,
             'minAge':this.minAge
@@ -494,7 +557,7 @@ import pinyin from '../../js/Convert_Pinyin.js';
             'name':this.data.name,
             'type':this.data.type,
             'detailList':detailList,
-            'conceptId':this.id
+            'conceptId':this.copy?'':this.id
           }
         }
         this.saveDisable = true  //提交保存按钮不可点击,返回结果时才可点击,防止频繁发送请求
@@ -502,7 +565,8 @@ import pinyin from '../../js/Convert_Pinyin.js';
           const result = res.data;
           if(result.code==0){
             this.warning(res.data.msg||'操作成功','success');
-            this.$router.push({name:'MedicalName'});
+            //返回带搜索条件的首页
+            this.$router.push({name:'MedicalName',params:Object.assign({},this.$route.params,{currentPage:1})});
             /*if(flg == 14){
               this.getDetail(this.id)
               this.radioVal = ''
@@ -538,6 +602,19 @@ import pinyin from '../../js/Convert_Pinyin.js';
      text-align: right;
      margin-left: 0;
    }
+   // 饿了么分组下拉
+    .el-scrollbar{
+     .el-select-dropdown__list{
+       .el-select-group__wrap{
+        min-width: 160px !important;
+        display: inline-block !important;
+        vertical-align: top !important;
+      }
+    }
+   }
+   .el-select-group__wrap::after{
+    background:#fff !important;
+   } 
    .displayColor {
      color: #ccc;
      cursor:not-allowed;

+ 5 - 3
src/components/icss/AddMedicalRelation.vue

@@ -1,6 +1,7 @@
 <template>
   <div>
-    <crumbs title="医学术语关系-添加" linkTo="/admin/LT-YXSYKWH-YXSYGXWH"></crumbs>
+    <crumbs title="医学术语关系-添加"
+            :param="$route.params" linkTo="MedicalRelation"></crumbs>
     <div class="contents">
       <div class="content" @click="closeSearch">
         <p>明细</p>
@@ -126,8 +127,9 @@
             this.$message({
               type:'success',
               message:result.msg||'添加成功'
-            })
-            this.$router.push({path: 'LT-YXSYKWH-YXSYGXWH'});
+            });
+            //返回带搜索条件的首页
+            this.$router.push({name: 'MedicalRelation',params: Object.assign({}, this.$route.params, {currentPage: 1})});
           }else{
             this.$message({
               type:'warning',

+ 11 - 4
src/components/icss/AddMedicinePrompt.vue

@@ -1,9 +1,10 @@
 <template>
     <div class="NoiseTemplateWrapper TemplateWrapper">
         <crumbs
-          :title=" isEdit? '医学术语静态知识维护-修改':'医学术语静态知识维护-添加'"
+          :title="'医学术语静态知识维护-'+title"
           class="topBack"
-          linkTo="/admin/LT-YXSYKWH-YXSYJTZSWH"
+          :param="$route.params"
+          linkTo="MedicinePrompt"
         ></crumbs>
         <div class="info-container">
             <el-form :rules="rules"
@@ -66,6 +67,7 @@
       return {
         isEdit:false,
         isCopy:false,
+        title:'添加',
         termTypes:[],
         terms:[],              //术语列表
         editData:{
@@ -108,6 +110,7 @@
       if(isEdit||isCopy){
         this.isEdit = isEdit;
         this.isCopy = isCopy;
+        this.title = isEdit?'编辑':(isCopy?'复制':'添加');
         this.changeWord(data);
         //this.form.selectedTerm = data;
         //this.form.selectedTermName = data.libName;
@@ -189,9 +192,12 @@
       },
       back() { this.$router.go(-1) },
       searchTerms(query){
+        if(!query.trim()){
+            return;
+        }
         //搜索术语列表
         this.showDrop = true;
-        api.getAllConcept({name:query}).then((res) =>{
+        api.getAllConcept({name:query.trim()}).then((res) =>{
           this.showDrop = false;
           if(res.data.code === '0') {
             this.terms = res.data.data;
@@ -243,7 +249,8 @@
           api.saveTermPrompts(param).then((res) => {
             if (res.data.code === '0') {
               this.warning(res.data.msg || '保存成功', 'success');
-              this.$router.push("/admin/LT-YXSYKWH-YXSYJTZSWH");
+              //返回带搜索条件的首页
+              this.$router.push({name:'MedicinePrompt',params:Object.assign({},this.$route.params,{currentPage:1})});
             } else {
               this.warning(res.data.msg)
             }

+ 7 - 7
src/components/icss/AddPhysicalExamTemp.vue

@@ -2,9 +2,10 @@
 <template>
     <div class="AddPhysicalExamTempWrapper">
         <crumbs
-          :title="'查体模板维护系统-'+titleText"
-          class="topBack"
-          linkTo="/admin/LT-YXSJWH-CTMBWH"
+                :title="'查体模板维护-'+titleText"
+                class="topBack"
+                :param="$route.params"
+                linkTo="PhysicalExamTemplate"
         ></crumbs>
         <el-form :model="form" ref="ruleForm" :rules="rules" class="addDepartForm">
             <el-form-item label="模板归属:"  >
@@ -137,9 +138,6 @@
         }
     },
     methods: {
-        back(){
-            this.$router.go(-1);
-        },
         getDepartmentList() {
             api.getPhysicalExamTempDepartList().then((res)=>{
                if(res.data.code === '0') {
@@ -275,8 +273,10 @@
                 if (res.data.code  === '0') {
                     this.warning(res.data.msg || '保存成功', 'success','1000')
                     setTimeout(() => {
+                      //返回带搜索条件的首页
                     this.$router.push({
-                        path:'/admin/LT-YXSJWH-CTMBWH'
+                      name: 'PhysicalExamTemplate',
+                      params: Object.assign({}, this.$route.params, {currentPage: 1})
                     })
                     }, 1000);
                 } else {

+ 1 - 1
src/components/icss/AddPromptInfo.vue

@@ -2,7 +2,7 @@
     <div class="NoiseTemplateWrapper TemplateWrapper">
         <crumbs :title="isEdit?'提示信息维护-修改':'提示信息维护-添加'"
                 class="topBack"
-                linkTo="/admin/LT-YXSJWH-TSXXWH"></crumbs>
+                linkTo="PromptInfo"></crumbs>
         <div class="pinfo-container">
             <el-form :rules="rules"
                      :model="form"

+ 1 - 1
src/components/icss/AddSimilarName.vue

@@ -1,6 +1,6 @@
 <template>
   <div>
-    <crumbs :title="minTitle" linkTo="/admin/LT-YXSJWH-BMWH"></crumbs>
+    <crumbs :title="minTitle" linkTo="SimilarName"></crumbs>
     <div class="contents">
       <div class="content" @click="close">
         <h3>选择标签</h3>

+ 7 - 3
src/components/icss/AddVersion.vue

@@ -1,6 +1,6 @@
 <template>
   <div>
-    <crumbs :title="title" linkTo="/admin/LT-YXSJWH-BBXXWH"></crumbs>
+    <crumbs :title="title" :param="$route.params" linkTo="VersionInfo"></crumbs>
     <div class="contents">
       <div class="content">
         <!-- <el-form ref="form" :label-position="labelPosition" label-width="95px" class="add-admin-form" :model="form" :rules="rules"> -->
@@ -137,8 +137,12 @@
                   this.$message({
                     message:"修改成功",
                     type:'success'
-                  })
-                  this.$router.push({path: 'LT-YXSJWH-BBXXWH'});
+                  });
+                  //返回带搜索条件的首页
+                  this.$router.push({
+                    name: 'VersionInfo',
+                    params: Object.assign({}, this.$route.params, {currentPage: 1})
+                  });
                 }else{
                   this.$message({
                     message:res.data.msg,

+ 59 - 16
src/components/icss/AssaySon.vue

@@ -3,7 +3,7 @@
         <crumbs title="化验子项维护" style="min-width: 980px">
             <el-form :inline="true" class="demo-form-inline">
                 <el-form-item label="标准术语:">
-                    <el-input size="mini" v-model="conceptName" placeholder="术语名称" clearable></el-input>
+                    <el-input size="mini" v-model="filter.conceptName" placeholder="术语名称" clearable></el-input>
                 </el-form-item>
                 <el-form-item>
                     <el-button size="mini" @click="filterDatas">确认</el-button>
@@ -81,29 +81,50 @@
 </template>
 
 <script>
-import api from '@api/icss.js';
+  import api from '@api/icss.js';
 
-export default {
+  export default {
     name: 'AssaySon',   //慢病指标值关联维护
     data: function() {
         return {
             list: [],
-            conceptName:'',
+            searched: false,
+            filter:{
+              conceptName:'',
+            },
             currentPage: 1,
             pageSize: 10,
             total: 0,
         }
     },
     created() {
-        this.getDataList()
-        
+      const that = this;
+      //返回时避免参数未赋值就获取列表
+      setTimeout(function(){
+        that.getDataList();
+      });
     },
+  watch: {
+    'filter': {
+      handler: function () {
+        this.searched = false;
+      },
+      deep: true
+    }
+  },
+  beforeRouteEnter(to, from, next) {
+    next(vm => {
+      //const pm = to.param;
+      Object.assign(vm, to.params);
+    })
+  },
     methods: {
-        getDataList() {
-            const param = this.getFilterItems();
+        getDataList(isTurnPage) {
+            const param = this.getFilterItems(isTurnPage);
+            this.searched = true;
             api.getAssaySon(param).then((res) => {
                 if(res.data.code == '0') {
-                    this.list = res.data.data.records
+                    this.list = res.data.data.records;
                     this.total = res.data.data.total;
                 }
             })
@@ -113,7 +134,11 @@ export default {
             this.getDataList();
         },
         addRelation() {
-            this.$router.push({name:'AddAssaySon'})
+          const pam = this.searched ? {
+            currentPage: this.currentPage,
+            filter: this.filter
+          } : {currentPage: this.currentPage};
+            this.$router.push({name:'AddAssaySon', params: pam})
         },
         modifyRelation(row) {
             const param = {
@@ -122,21 +147,29 @@ export default {
             }
             api.getAssaySonDetail(param).then((res) => {
                 if(res.data.code == '0') {
+                  const pam = this.searched ? {
+                    currentPage: this.currentPage,
+                    filter: this.filter
+                  } : {currentPage: this.currentPage};
                     // const item = Object.assign({},row,{data: res.data.data});
                     const item = res.data.data;
-                    this.$router.push({name:'AddAssaySon',params:{isEdit:true,data:item}});
+                    this.$router.push({name:'AddAssaySon',params:Object.assign(pam, {isEdit:true,data:item})});
                 }
             })
         },
         currentChange(next) {
             this.currentPage = next;
-            this.getDataList();
+            this.getDataList(true);
         },
-        getFilterItems() {
+        getFilterItems(isTurnPage) {
+          //翻页时筛选条件没点确定则清空
+          if(isTurnPage&&!this.searched){
+            this.filter.conceptName='';
+          };
             const param = {
                 current: this.currentPage,
                 size: this.pageSize,
-                name:this.conceptName
+                name:this.filter.conceptName
             };
             return param;
         },
@@ -166,10 +199,20 @@ export default {
             "conceptId": row.conceptId,
             "isDeleted": row.isDeleted=== 'N'?'Y':'N',
             "relationId": 18
-          }
-          this.showConfirmDialog('是否删除该关联?',()=>{
+          };
+          const txt = row.isDeleted=== 'N'?'是否删除该关联?':'是否重新启用该关联?';
+          this.showConfirmDialog(txt,()=>{
             api.delAssaySon(param).then((res)=>{
               if(res.data.code=='0'){
+                if(!this.searched){
+                  //未点确认时清空搜索条件
+                  this.filter={
+                    conceptName:'',
+                  };
+                }
+                if(row.isDeleted !== 'N'){       //恢复成功后跳转到筛选条件的首页
+                  this.currentPage = 1;
+                }
                 this.getDataList();
                 this.warning(res.data.msg || '操作成功','success');
               }else{

+ 52 - 7
src/components/icss/ChemicalAndCommonMapping.vue

@@ -103,6 +103,7 @@ export default {
     data: function() {
         return {
             list: [],
+          searched: false,
             filter: {
                 mealName:'',
                 itemName:'',
@@ -117,9 +118,24 @@ export default {
         this.getDataList()
         
     },
+  watch: {
+    'filter': {
+      handler: function () {
+        this.searched = false;
+      },
+      deep: true
+    }
+  },
+  beforeRouteEnter(to, from, next) {
+    next(vm => {
+      //const pm = to.param;
+      Object.assign(vm, to.params);
+    })
+  },
     methods: {
-        getDataList() {
-            const param = this.getFilterItems();
+        getDataList(isTurnPage) {
+            const param = this.getFilterItems(isTurnPage);
+          this.searched = true;
             api.getLisMappingPage(param).then((res) => {
                 if(res.data.code == '0') {
                     this.list = res.data.data.records
@@ -132,23 +148,44 @@ export default {
             this.getDataList();
         },
         addRelation() {
-            this.$router.push({name:'AddChemicalAndCommonMapping'})
+          const pam = this.searched ? {
+            currentPage: this.currentPage,
+            filter: this.filter
+          } : {currentPage: this.currentPage};
+          this.$router.push({name: 'AddChemicalAndCommonMapping', params: pam})
         },
         modifyRelation(row) {
-            console.log(row,'row')
             const item = Object.assign({},row);
-            this.$router.push({name:'AddChemicalAndCommonMapping',params:{isEdit:true,data:item}});
+          const pam = this.searched ? {
+            currentPage: this.currentPage,
+            filter: this.filter
+          } : {currentPage: this.currentPage};
+          this.$router.push({
+            name: 'AddChemicalAndCommonMapping',
+            params: Object.assign(pam, {isEdit: true, data: item})
+          });
         },
         currentChange(next) {
             this.currentPage = next;
-            this.getDataList();
+            this.getDataList(true);
             // if (this.cacheData[next]) {       //如果已请求过该页数据,则使用缓存不重复请求
             //     this.list = this.cacheData[next];
             // } else {
             //     this.getDataList();
             // }
         },
-        getFilterItems() {
+      clearFilter(){
+        this.filter={
+          mealName:'',
+          itemName:'',
+          uniqueName:''
+        };
+      },
+        getFilterItems(isTurnPage) {
+          //翻页时筛选条件没点确定则清空
+          if(isTurnPage&&!this.searched){
+            this.clearFilter();
+          };
             const param = {
                 current: this.currentPage,
                 size: this.pageSize,
@@ -183,6 +220,14 @@ export default {
           this.showConfirmDialog('是否删除该关联?',()=>{
             api.delLisMappingById({id:id}).then((res)=>{
               if(res.data.code=='0'){
+                if(!this.searched){
+                  //未点确认时清空搜索条件
+                  this.clearFilter();
+                }
+                if(this.list.length==1){
+                  //当前在最后一页且只有一条数据时,删除后跳到前一页
+                  this.currentPage = this.currentPage===1?1:this.currentPage-1;
+                }
                 this.getDataList();
                 this.warning(res.data.msg || '操作成功','success');
               }else{

+ 52 - 13
src/components/icss/ChronicAndIndexRelation.vue

@@ -88,13 +88,14 @@
 </template>
 
 <script>
-import api from '@api/icss.js';
+  import api from '@api/icss.js';
 
-export default {
+  export default {
     name: 'ChronicAndIndexRelation',   //慢病指标值关联维护
     data: function() {
         return {
             list: [],
+            searched: false,
             filter: {
                 diseaseName: ''
             },
@@ -104,15 +105,32 @@ export default {
         }
     },
     created() {
-        this.getDataList()
-        
+      const that = this;
+      setTimeout(function(){
+        that.getDataList();
+      });
     },
+  watch: {
+    'filter': {
+      handler: function () {
+        this.searched = false;
+      },
+      deep: true
+    }
+  },
+  beforeRouteEnter(to, from, next) {
+    next(vm => {
+      //const pm = to.param;
+      Object.assign(vm, to.params);
+    })
+  },
     methods: {
-        getDataList() {
-            const param = this.getFilterItems();
+        getDataList(isTurnPage) {
+            const param = this.getFilterItems(isTurnPage);
+            this.searched = true;
             api.queryIndexConfigPages(param).then((res) => {
                 if(res.data.code == '0') {
-                    this.list = res.data.data.records
+                    this.list = res.data.data.records;
                     this.total = res.data.data.total;
                 }
             })
@@ -122,29 +140,41 @@ export default {
             this.getDataList();
         },
         addRelation() {
-            this.$router.push({name:'AddChronicAndIndexRelation'})
+          const pam = this.searched ? {
+            currentPage: this.currentPage,
+            filter: this.filter
+          } : {currentPage: this.currentPage};
+            this.$router.push({name:'AddChronicAndIndexRelation', params: pam})
         },
         modifyRelation(row) {
             const param = {
                 diseaseId: row.diseaseId
-            }
+            };
             api.getIndexConfigLists(param).then((res) => {
                 if(res.data.code == '0') {
+                    const pam = this.searched ? {
+                        currentPage: this.currentPage,
+                        filter: this.filter
+                      } : {currentPage: this.currentPage};
                     const item = Object.assign({},row,{data: res.data.data});
-                    this.$router.push({name:'AddChronicAndIndexRelation',params:{isEdit:true,data:item}});
+                    this.$router.push({name:'AddChronicAndIndexRelation',params:Object.assign(pam, {isEdit:true,data:item})});
                 }
             })
         },
         currentChange(next) {
             this.currentPage = next;
-            this.getDataList();
+            this.getDataList(true);
             // if (this.cacheData[next]) {       //如果已请求过该页数据,则使用缓存不重复请求
             //     this.list = this.cacheData[next];
             // } else {
             //     this.getDataList();
             // }
         },
-        getFilterItems() {
+        getFilterItems(isTurnPage) {
+          //翻页时筛选条件没点确定则清空
+          if(isTurnPage&&!this.searched){
+            this.filter.diseaseName='';
+          };
             const param = {
                 current: this.currentPage,
                 size: this.pageSize,
@@ -178,10 +208,19 @@ export default {
               diseaseId:row.diseaseId,
               state:row.state === 'N'?'Y':'N',
           }
-          let warntTxt = row.state === 'N' ? '是否删除该关联?': '是否恢复该关联?'
+          let warntTxt = row.state === 'N' ? '是否删除该关联?': '是否恢复该关联?';
           this.showConfirmDialog(warntTxt,()=>{
             api.cancelIndexConfigAlls(param).then((res)=>{
               if(res.data.code=='0'){
+                if(!this.searched){
+                  //未点确认时清空搜索条件
+                  this.filter={
+                    diseaseName: ''
+                  };
+                }
+                if(row.state !== 'N'){       //恢复成功后跳转到筛选条件的首页
+                  this.currentPage = 1;
+                }
                 this.getDataList();
                 this.warning(res.data.msg || '操作成功','success');
               }else{

+ 7 - 5
src/components/icss/ChronicDiseaseAdd.vue

@@ -3,7 +3,8 @@
     <crumbs
       :title="minTitle"
       class="topBack"
-      linkTo="/admin/LT-YXSYKWH-LBJGWH"
+      :param="$route.params"
+      linkTo="ChronicDiseaseStructureList"
     ></crumbs>
     <div class="ChronicDiseaseAddWrap" @click="close">
       <div class="ChronicDisease">
@@ -38,7 +39,7 @@
             ></span></p>
           <p><span
               class="el-icon-arrow-left"
-              @click="toLeftPool" 
+              @click="toLeftPool"
             ></span></p>
         </div>
         <div class="ChronicDiseaseRight">
@@ -239,7 +240,7 @@ export default {
       let tmpPool = JSON.parse(JSON.stringify(this.contentPool))
       for(let i = 0;i < tmpPool.length;i++){
         if(tmpPool[i].val == 0 && !tmpPool[i].content){
-          
+
         }else{
           let tmpObj = {
             "content": "",
@@ -280,13 +281,14 @@ export default {
             this.warning(res.data.msg || '保存成功', 'success');
             setTimeout(() => {
               this.$router.push({
-                path:'/admin/LT-YXSYKWH-LBJGWH'
+                name:'ChronicDiseaseStructureList',
+                params: Object.assign({}, this.$route.params, {currentPage: 1})
               })
             }, 1000);
           }
           this.saveDisable = false
         })
-        
+
       })
     },
     showConfirmDialog(msg, resolve) {

+ 1 - 1
src/components/icss/ChronicDiseaseManageAdd.vue

@@ -3,7 +3,7 @@
     <crumbs
       :title="minTitle"
       class="topBack"
-      linkTo="/admin/LT-YXSJWH-MBGLYPG"
+      linkTo="ChronicDiseaseManage"
     ></crumbs>
     <div class="ChronicDiseaseAddWrap">
       <div class="ChronicDisease">

+ 59 - 11
src/components/icss/ChronicDiseaseStructureList.vue

@@ -6,7 +6,7 @@
                     <el-input size="mini" v-model="filter.tagSysName" placeholder="量表名称" clearable></el-input>
                 </el-form-item>
                 <el-form-item label="状态:">
-                <el-select v-model="isState" clearable placeholder="请选择" size="mini">
+                <el-select v-model="filter.isState" clearable placeholder="请选择" size="mini">
                   <el-option
                     v-for="item in stateSelect"
                     :key="item.id"
@@ -95,12 +95,14 @@
           {id:'N',name:'启用中'},
           {id:'Y',name:'已删除'},
         ],
-        isState:'',
+
         tagTypes: [],
         AdscriptionsType:[],
         AdscriptionsOwnTo:[],
         tagTypesList: [],
+        searched: false,
         filter: {
+          isState:'',
           tagType: [], //标签类型
           tagSysName: '', //标签系统名称
         },
@@ -114,10 +116,24 @@
         this.getDataList()
       })
     },
+    watch: {
+      'filter': {
+        handler: function () {
+          this.searched = false;
+        },
+        deep: true
+      }
+    },
+    beforeRouteEnter(to, from, next) {
+      next(vm => {
+        //const pm = to.param;
+        Object.assign(vm, to.params);
+      })
+    },
     methods: {
       getDropList() {
         let templateType = localStorage.getItem('icssEnumsData') ? JSON.parse(localStorage.getItem('icssEnumsData')).moduleInfoTypeEnum : []
-        this.AdscriptionsType = templateType
+        this.AdscriptionsType = templateType;
         return api.getknowledgeList().then((res) =>{
           if(res.data.code === '0') {
             localStorage.setItem('DiseaseManage',JSON.stringify(res.data.data[1]))
@@ -128,10 +144,11 @@
           }
         })
       },
-      getDataList() {
-        const param = this.getFilterItems();
+      getDataList(isTurnPage) {
+        const param = this.getFilterItems(isTurnPage);
+        this.searched = true;
         api.scaleContentStructure(param).then((res) => {
-          const list = res.data.data.records
+          const list = res.data.data.records;
           // for (var i = 0; i < list.length; i++) {
           //   for (var j =  0; j < this.tagTypes.length; j++) {
           //     if(list[i].tagType === this.tagTypes[j].val) {
@@ -148,13 +165,21 @@
         this.getDataList();
       },
       addIndeptTag() {
-        this.$router.push({name:'ChronicDiseaseAdd'})
+        const pam = this.searched ? {
+          currentPage: this.currentPage,
+          filter: this.filter
+        } : {currentPage: this.currentPage};
+        this.$router.push({name:'ChronicDiseaseAdd', params: pam})
       },
       modifyIndeptTag(row) {
         api.rebuildOrUpdate({conceptId:row.conceptId}).then((res)=>{
           const {code,data,msg} = res.data;
             if(code=='0'){
-              this.$router.push({name:'ChronicDiseaseAdd',params:{isEdit:true,data:data,row:row}});
+              const pam = this.searched ? {
+                currentPage: this.currentPage,
+                filter: this.filter
+              } : {currentPage: this.currentPage};
+              this.$router.push({name:'ChronicDiseaseAdd',params:Object.assign(pam, {isEdit:true,data:data,row:row})});
             }else{
               this.$message({
                 message: msg,
@@ -165,14 +190,18 @@
       },
       currentChange(next) {
         this.currentPage = next;
-        this.getDataList();
+        this.getDataList(true);
       },
-      getFilterItems() {
+      getFilterItems(isTurnPage) {
+        //翻页时筛选条件没点确定则清空
+        if(isTurnPage&&!this.searched){
+          this.clearFilter();
+        };
         const param = {
           current: this.currentPage,
           size: this.pageSize,
           name: this.filter.tagSysName,
-          status:this.isState
+          status:this.filter.isState
         };
         return param;
       },
@@ -194,6 +223,13 @@
           resolve();
         }).catch(() => {});
       },
+      clearFilter(){
+        this.filter={
+          isState:'',
+          tagType: [], //标签类型
+          tagSysName: '', //标签系统名称
+        };
+      },
       showDelDialog(item){
         let tmpArr = []
         tmpArr.push(item.conceptId)
@@ -205,6 +241,18 @@
         this.showConfirmDialog(waringTxt,()=>{
           api.deleteScale(param).then((res)=>{
             if(res.data.code=='0'){
+              if(!this.searched){
+                //未点确认时清空搜索条件
+                this.clearFilter();
+              }
+              if(item.isDeleted !== 'N'){       //恢复成功后跳转到筛选条件的首页
+                this.currentPage = 1;
+              } else {
+                if (this.filter.isState!==''&&this.list.length === 1){
+                  //有启用状态筛选条件且当前页只有最后一条数据删除时,删除成功后跳转到前一页
+                  this.currentPage = this.currentPage===1?1:this.currentPage-1;
+                }
+              }
               this.warning(res.data.msg||'操作成功','success');
               this.getDataList();
             }else{

+ 57 - 11
src/components/icss/ConceptRelation.vue

@@ -3,7 +3,7 @@
         <crumbs title="医学术语关联维护" style="min-width: 980px">
             <el-form :inline="true" class="demo-form-inline">
                 <el-form-item label="标准术语名称:">
-                    <el-input size="mini" v-model="conceptName" placeholder="术语名称" clearable></el-input>
+                    <el-input size="mini" v-model="filter.conceptName" placeholder="术语名称" clearable></el-input>
                 </el-form-item>
                 <el-form-item>
                     <el-button size="mini" @click="filterDatas">确认</el-button>
@@ -87,18 +87,40 @@ export default {
     data: function() {
         return {
           list: [],
-          conceptName:'',
+          searched: false,
+          filter:{
+            conceptName:''
+          },
           currentPage: 1,
           pageSize: 10,
           total: 0,
         }
     },
     created() {
-        this.getDataList()    
+      const that = this;
+      //返回时避免参数未赋值就获取列表
+      setTimeout(function(){
+        that.getDataList();
+      });
     },
+  watch: {
+    'filter': {
+      handler: function () {
+        this.searched = false;
+      },
+      deep: true
+    }
+  },
+  beforeRouteEnter(to, from, next) {
+    next(vm => {
+      //const pm = to.param;
+      Object.assign(vm, to.params);
+    })
+  },
     methods: {
-        getDataList() {
-            const param = this.getFilterItems();
+        getDataList(isTurnPage) {
+            const param = this.getFilterItems(isTurnPage);
+            this.searched = true;
             api.getConceptRelation(param).then((res) => {
               if(res.data.code == '0') {
                 this.list = res.data.data.records
@@ -111,17 +133,25 @@ export default {
             this.getDataList();
         },
         addRelation() {
-            this.$router.push({name:'AddConceptRelation'})
+          const pam = this.searched ? {
+            currentPage: this.currentPage,
+            filter: this.filter
+          } : {currentPage: this.currentPage};
+          this.$router.push({name:'AddConceptRelation',params:pam})
         },
         modifyRelation(row) {
             const param = {
               "conceptId": row.conceptId,
               "relationId":17
             }
+          const pam = this.searched ? {
+            currentPage: this.currentPage,
+            filter: this.filter
+          } : {currentPage: this.currentPage};
             api.getConceptRelationDet(param).then((res) => {
               if(res.data.code=='0'){
-                const { data } = res.data
-                this.$router.push({name:'AddConceptRelation',params:{isEdit:true,data:data}});
+                const { data } = res.data;
+                this.$router.push({name:'AddConceptRelation',params:Object.assign(pam, {isEdit: true, data: data})});
               } else {
                 this.warning(res.data.msg);
               }
@@ -132,13 +162,19 @@ export default {
         },
         currentChange(next) {
             this.currentPage = next;
-            this.getDataList();
+            this.getDataList(true);
         },
-        getFilterItems() {
+        getFilterItems(isTurnPage) {
+          //翻页时筛选条件没点确定则清空
+          if(isTurnPage&&!this.searched){
+            this.filter={
+              conceptName:''
+            };
+          };
             const param = {
                 current: this.currentPage,
                 size: this.pageSize,
-                name:this.conceptName
+                name:this.filter.conceptName
             };
             return param;
         },
@@ -172,6 +208,16 @@ export default {
             }
             api.delConceptRelation(param).then((res)=>{
               if(res.data.code=='0'){
+                if(!this.searched){
+                  //未点确认时清空搜索条件
+                  this.filter={
+                    conceptName:''
+                  };
+                }
+                if(this.list.length==1){
+                  //当前在最后一页且只有一条数据时,删除后跳到前一页
+                  this.currentPage = this.currentPage===1?1:this.currentPage-1;
+                }
                 this.getDataList();
                 this.warning(res.data.msg || '操作成功','success');
               }else{

+ 1 - 1
src/components/icss/DeptInfoDetail.vue

@@ -1,6 +1,6 @@
 <template>
   <div>
-    <crumbs title="icss科室维护系统-详情" linkTo="/admin/LT-YXSJWH-KSWH"></crumbs>
+    <crumbs title="icss科室维护系统-详情" linkTo="deptInfo"></crumbs>
     <div class="contents">
       <table class="deptbox">
         <tr>

+ 0 - 47
src/components/icss/DiagnosisPubTag.vue

@@ -392,43 +392,6 @@ export default {
         this.initForm()
       }
       this.changeSex(tmpData);
-      // if(type == 3){
-      //   this.form.region7 = this.tmpSex;
-      //   this.$alert('改变性别后,标签明细将会恢复到默认状态?', '提示', {
-      //     confirmButtonText: '确定',
-      //     cancelButtonClass: 'cancelColor',
-      //     type: 'warning'
-      //   }).then(() => {
-      //     this.form.region7 = tmpData
-      //     this.changeSex(tmpData);
-      //   }).catch(() => {
-      //     // this.form.region7 = this.tmpSex;
-      //   });
-      // }else if(type == 2){
-      //   this.form.region2 = this.tmpType
-      //   this.$alert('改变类型后,标签明细将会恢复到默认状态?', '提示', {
-      //     confirmButtonText: '确定',
-      //     cancelButtonClass: 'cancelColor',
-      //     type: 'warning'
-      //   }).then(() => {
-      //     this.form.region2 = tmpData;
-      //     this.changeSex(tmpData);
-      //   }).catch(() => {
-      //     // this.form.region2 = this.tmpType;
-      //   });
-      // }else if(type == 1){
-      //   this.form.region1 = this.tmpOwn;
-      //   this.$alert('改变归属后,标签明细将会恢复到默认状态?', '提示', {
-      //     confirmButtonText: '确定',
-      //     cancelButtonClass: 'cancelColor',
-      //     type: 'warning'
-      //   }).then(() => {
-      //     this.form.region1 = tmpData;
-      //     this.changeSex(tmpData);
-      //   }).catch(() => {
-      //     // this.form.region1 = this.tmpOwn;
-      //   });
-      // }
     },
     submitForm(formName) {
       this.$refs[formName].validate((valid) => {
@@ -515,16 +478,6 @@ export default {
   .el-message-box__btns .el-button--default {
     color: #606266 !important;
   }
-  .cancelColor {
-    color: #22ccc8 !important;
-  }
-  .changeTips {
-    position: absolute;
-    left: 220px;
-    // min-width: 300px;
-    color: #22ccc8;
-    font-size: 12px;
-  }
 }
 }
 </style>

+ 2 - 2
src/components/icss/DiagnosisTemplate.vue

@@ -3,7 +3,7 @@
     <crumbs
       :title="txt"
       class="topBack"
-      linkTo="/admin/LT-YXSJWH-ZDBQWH"
+      linkTo="DiagnosisList"
     ></crumbs>
     <DiagnosisPubTag
       :editData="editData"
@@ -201,7 +201,7 @@ export default {
         color: #f56c6c;
       }
       span {
-        color:#22ccc8;
+        color:@adminBase;
         font-size: 12px;
       }
     }

+ 1 - 1
src/components/icss/DiscInfoDetail.vue

@@ -1,6 +1,6 @@
 <template>
   <div>
-    <crumbs title="免责声明维护-详情" linkTo="/admin/LT-YXSJKWH-MZSMWH"></crumbs>
+    <crumbs title="免责声明维护-详情" linkTo="DisclaimerInformation"></crumbs>
     <div class="contents">
       <div class="deptbox">
         <p class="titl">标题</p>

+ 53 - 13
src/components/icss/DisclaimerInformation.vue

@@ -7,9 +7,7 @@
                 </el-form-item>
                 <el-form-item>
                     <el-button size="mini" @click="filterDatas">确认</el-button>
-                    <router-link to="/admin/LT-YXSJWH-TJMZSM" style="margin:0 10px">
-                        <el-button size="mini" type="warning">添加</el-button>
-                    </router-link>
+                    <el-button size="mini" type="warning" @click="addDisclInfo" style="margin:0 10px">添加</el-button>
                 </el-form-item>
             </el-form>
         </crumbs>
@@ -79,7 +77,6 @@
 
 <script>
   import api from '@api/icss.js';
-  import utils from '@api/utils.js';
 
   export default {
     name: 'DisclaimerInformation',
@@ -92,27 +89,58 @@
         total: 0,
         linkIn:[],
         pays:[],
+        searched: false,
         filter: {
           title: ''
         }
       }
     },
     created() {
-      this.getDataList();
+      const that = this;
+      //返回时避免参数未赋值就获取列表
+      setTimeout(function(){
+        that.getDataList();
+      });
+    },
+    watch: {
+      'filter': {
+        handler: function () {
+          this.searched = false;
+        },
+        deep: true
+      }
+    },
+    beforeRouteEnter(to, from, next) {
+      next(vm => {
+        //const pm = to.param;
+        Object.assign(vm, to.params);
+      })
     },
     methods: {
+      addDisclInfo(){
+        const pam = this.searched ? {
+          currentPage: this.currentPage,
+          filter: this.filter
+        } : {currentPage: this.currentPage};
+        this.$router.push({name: 'AddDisclInfo', params: pam});
+      },
       toEditDiscl(row){
+        const pam = this.searched ? {
+          currentPage: this.currentPage,
+          filter: this.filter
+        } : {currentPage: this.currentPage};
         this.$router.push({
           name:'AddDisclInfo',
-          params: {info:row}
+          params: Object.assign(pam, {info:row})
         })
       },
       filterDatas(){
         this.currentPage = 1;
         this.getDataList();
       },
-      getDataList() {
-        const param = this.getFilterItems();
+      getDataList(isTurnPage) {
+        const param = this.getFilterItems(isTurnPage);
+        this.searched = true;
         api.discInformation(param).then((res) => {
           if (res.data.code == '0') {
             const data = res.data.data;
@@ -127,7 +155,11 @@
       getDetail(item) {
         this.$router.push({name:'DiscInfoDetail', params:{info: item}})
       },
-      getFilterItems() {
+      getFilterItems(isTurnPage) {
+        //翻页时筛选条件没点确定则清空
+        if(isTurnPage&&!this.searched){
+          this.filter.title='';
+        };
         const param = {
           title: this.filter.title,
           current: this.currentPage,
@@ -140,11 +172,11 @@
       },
       currentChange(next) {
         this.currentPage = next;
-        if (this.cacheData[next]) {       //如果已请求过该页数据,则使用缓存不重复请求
+        /*if (this.cacheData[next]) {       //如果已请求过该页数据,则使用缓存不重复请求
           this.list = this.cacheData[next];
-        } else {
-          this.getDataList();
-        }
+        } else {*/
+          this.getDataList(true);
+        //}
       },
       warning(msg,type){
         this.$message({
@@ -167,6 +199,12 @@
         this.showConfirmDialog('是否删除该免责声明?',()=>{
           api.delDiscInformation({id:item.id}).then((res)=>{
             if(res.data.code=='0'){
+              if(!this.searched){
+                //未点确认时清空搜索条件
+                this.filter={
+                  title: ''
+                };
+              }
               this.warning(res.data.msg||'操作成功','success');
               this.getDataList();
             }else{
@@ -183,6 +221,8 @@
           this.showConfirmDialog('是否启用该免责声明?',()=>{
             api.openInformation({id:item.id}).then((res)=>{
               if(res.data.code==0){
+                //恢复成功后跳转到筛选条件的首页
+                this.currentPage = 1;
                 this.$message({
                   type:'success',
                   message:res.data.msg ||"启用成功"

+ 63 - 8
src/components/icss/IndeptLabel.vue

@@ -76,7 +76,9 @@
                         prop="operate"
                         label="操作">
                     <template slot-scope="scope">
-                        <el-button  @click="modifyIndeptTag(scope.row)" type="text" size="small">修改</el-button>
+                        <el-button  @click="modifyIndeptTag(scope.row, 'modify')" type="text" size="small">修改</el-button>
+                        <span style="margin:0 3px;">|</span>
+                        <el-button @click="modifyIndeptTag(scope.row, 'copy')" class="text" type="text" size="small">复制</el-button>
                         <span style="margin:0 3px;">|</span>
                         <el-button @click="showDelDialog(scope.row)" class="delete" type="text" size="small">删除</el-button>
                     </template>
@@ -116,6 +118,7 @@
         tagTypes: [],
         Adscriptions: [],
         tagTypesList:[],
+        searched: false,
         filter: {
           tagType: [], //标签类型
           controlType: [],
@@ -133,6 +136,20 @@
       })
 
     },
+    watch: {
+      'filter': {
+        handler: function () {
+          this.searched = false;
+        },
+        deep: true
+      }
+    },
+    beforeRouteEnter(to, from, next) {
+      next(vm => {
+        //const pm = to.param;
+        Object.assign(vm, to.params);
+      })
+    },
     methods: {
       getValue(val) {
         console.log('changeVal', val, this.filter.tagAdscription)
@@ -148,8 +165,9 @@
 
         })
       },
-      getDataList() {
-        const param = this.getFilterItems();
+      getDataList(isTurnPage) {
+        const param = this.getFilterItems(isTurnPage);
+        this.searched = true;
         api.getTagList(param).then((res) => {
           const list = [...res.data.data.records];
           for (var i = 0; i < list.length; i++) {
@@ -174,14 +192,31 @@
         this.getDataList();
       },
       addIndeptTag() {
-        this.$router.push({path:'LT-YXSJWH-TJDLBQ'})
+        const pam = this.searched ? {
+          currentPage: this.currentPage,
+          filter: this.filter
+        } : {currentPage: this.currentPage};
+        this.$router.push({
+          name: 'AddIndeptLabel',
+          params: pam
+        })
       },
-      modifyIndeptTag(row) {
+      modifyIndeptTag(row, type) {
         api.detailsTag({id:row.id}).then((res)=>{
           const {code,data,msg} = res.data;
           if(code=='0'){
             const item = Object.assign({},row,data);
-            this.$router.push({name:'AddIndeptLabel',params:{isEdit:true,data:item}});
+            const pam = this.searched ? {
+              currentPage: this.currentPage,
+              filter: this.filter
+            } : {currentPage: this.currentPage};
+            if(type == 'modify') {
+              this.$router.push({name: 'AddIndeptLabel', params: Object.assign(pam, {isEdit: true, data: item})});
+            } else if( type == 'copy') {
+              this.$router.push({name: 'AddIndeptLabel', params: Object.assign(pam, {isCopy: true, data: item})});
+            } else {
+                return
+            }
           }else{
             this.$message({
               message: msg,
@@ -193,14 +228,26 @@
       },
       currentChange(next) {
         this.currentPage = next;
-        this.getDataList();
+        this.getDataList(true);
         // if (this.cacheData[next]) {       //如果已请求过该页数据,则使用缓存不重复请求
         //     this.list = this.cacheData[next];
         // } else {
         //     this.getDataList();
         // }
       },
-      getFilterItems() {
+      clearFilter(){
+        this.filter={
+          tagType: [], //标签类型
+          controlType: [],
+          tagAdscription: '', //标签归属
+          tagSysName: '', //标签系统名称
+        };
+      },
+      getFilterItems(isTurnPage) {
+        //翻页时筛选条件没点确定则清空
+        if(isTurnPage&&!this.searched){
+          this.clearFilter();
+        };
         const param = {
           tagTypeList: [1],
           current: this.currentPage,
@@ -240,6 +287,14 @@
         this.showConfirmDialog('是否删除该标签?',()=>{
           api.deleteTagGroup(param).then((res)=>{
             if(res.data.code=='0'){
+              if(!this.searched){
+                //未点确认时清空搜索条件
+                this.clearFilter();
+              }
+              if(this.list.length==1){
+                //当前在最后一页且只有一条数据时,删除后跳到前一页
+                this.currentPage = this.currentPage===1?1:this.currentPage-1;
+              }
               this.getDataList();
               this.warning(res.data.msg || '操作成功','success');
             }else{

+ 56 - 7
src/components/icss/LabelGroup.vue

@@ -119,6 +119,7 @@ export default {
             tagTypes: [],
             Adscriptions: [],   //标签归属列表
             tagTypesList: [],   //标签类型列表
+            searched: false,
             filter: {
                 tagType: [], //标签类型
                 tagAdscription: '', //标签归属
@@ -135,6 +136,20 @@ export default {
         })
         
     },
+  watch: {
+    'filter': {
+      handler: function () {
+        this.searched = false;
+      },
+      deep: true
+    }
+  },
+  beforeRouteEnter(to, from, next) {
+    next(vm => {
+      //const pm = to.param;
+      Object.assign(vm, to.params);
+    })
+  },
     methods: {
         getValue(val) {
             // console.log('changeVal', val, this.filter.tagAdscription)
@@ -155,8 +170,9 @@ export default {
                  
             })
         },
-        getDataList() {
-            const param = this.getFilterItems();
+        getDataList(isTurnPage) {
+            const param = this.getFilterItems(isTurnPage);
+          this.searched = true;
             api.getTagList(param).then((res) => {
                 const list = res.data.data.records
                 for (var i = 0; i < list.length; i++) {
@@ -181,18 +197,32 @@ export default {
             this.getDataList();
         },
         addTagGroup() {
-            this.$router.push({path:'LT-YXSJWH-TJBQZ'})
+          const pam = this.searched ? {
+            currentPage: this.currentPage,
+            filter: this.filter
+          } : {currentPage: this.currentPage};
+          this.$router.push({name: 'AddLabelGroup', params: pam});
         },
         modifyTagGroup(row, type) {
             api.detailsTag({id:row.id}).then((res)=>{
                 const {code,data,msg} = res.data;
                 if(code=='0'){
                     const item = Object.assign({},row,data);
+                  const pam = this.searched ? {
+                    currentPage: this.currentPage,
+                    filter: this.filter
+                  } : {currentPage: this.currentPage};
                     // console.log('item', item)
                     if(type == 'modify') {
-                        this.$router.push({name:'AddLabelGroup',params:{isEdit:true,data:item}});
+                      this.$router.push({
+                        name: 'AddLabelGroup',
+                        params: Object.assign(pam, {isEdit: true, data: item})
+                      });
                     } else if( type == 'copy') {
-                        this.$router.push({name:'AddLabelGroup',params:{isCopy:true,data:item}});
+                      this.$router.push({
+                        name: 'AddLabelGroup',
+                        params: Object.assign(pam, {isCopy: true, data: item})
+                      });
                     } else {
                         return
                     }
@@ -206,14 +236,18 @@ export default {
         },
         currentChange(next) {
             this.currentPage = next;
-            this.getDataList();
+            this.getDataList(true);
             // if (this.cacheData[next]) {       //如果已请求过该页数据,则使用缓存不重复请求
             //     this.list = this.cacheData[next];
             // } else {
             //     this.getDataList();
             // }
         },
-        getFilterItems() {
+        getFilterItems(isTurnPage) {
+          //翻页时筛选条件没点确定则清空
+          if(isTurnPage&&!this.searched){
+            this.clearFilter();
+          };
             const param = {
                 tagTypeList: this.filter.tagType[0] && this.filter.tagType|| this.tagTypesList,
                 current: this.currentPage,
@@ -245,10 +279,25 @@ export default {
             resolve();
           }).catch(() => {});
         },
+      clearFilter(){
+        this.filter={
+          tagType: [], //标签类型
+          tagAdscription: '', //标签归属
+          tagSysName: '', //标签系统名称
+        };
+      },
         showDelDialog(id,type){
           this.showConfirmDialog('是否删除该标签组?',()=>{
             api.deleteTagGroup({ids:id,type:type}).then((res)=>{
               if(res.data.code=='0'){
+                if(!this.searched){
+                  //未点确认时清空搜索条件
+                  this.clearFilter();
+                }
+                if(this.list.length==1){
+                  //当前在最后一页且只有一条数据时,删除后跳到前一页
+                  this.currentPage = this.currentPage===1?1:this.currentPage-1;
+                }
                 this.getDataList();
                 this.warning(res.data.msg || '操作成功','success');
               }else{

+ 58 - 10
src/components/icss/MedicalMultRelation.vue

@@ -7,9 +7,7 @@
                 </el-form-item>
                 <el-form-item>
                     <el-button size="mini" @click="filterDatas">确认</el-button>
-                    <router-link to="/admin/LT-YXSYKWH-TJYXSYDCGL" style="margin:0 10px">
-                        <el-button size="mini" type="warning">添加</el-button>
-                    </router-link>
+                    <el-button size="mini" type="warning" style="margin:0 10px"  @click="addMedicalMultR">添加</el-button>
                 </el-form-item>
             </el-form>
         </crumbs>
@@ -89,6 +87,7 @@
         currentPage: 1,
         pageSize: 10,
         total: 0,
+        searched: false,
         filter: {
           term:'',
           type:''
@@ -97,20 +96,50 @@
       }
     },
     created() {
-      this.getDataList();
+      const that = this;
+      //返回时避免参数未赋值就获取列表
+      setTimeout(function(){
+        that.getDataList();
+      });
       this.getTypeList();
     },
+    watch: {
+      'filter': {
+        handler: function () {
+          this.searched = false;
+        },
+        deep: true
+      }
+    },
+    beforeRouteEnter(to, from, next){
+      next(vm => {
+        //const pm = to.param;
+        Object.assign(vm,to.params);
+      })
+    },
     methods: {
+      addMedicalMultR(){
+        const pam = this.searched ? {
+          currentPage: this.currentPage,
+          filter: this.filter
+        } : {currentPage: this.currentPage};
+        this.$router.push({name:'AddMedicalMultRelation',
+          params:pam});
+      },
       toEditProduct(row){
         const param = {
           conceptId: row.conceptId,
           relationId: 17
-        }
+        };
+        const pam = this.searched ? {
+          currentPage: this.currentPage,
+          filter: this.filter
+        } : {currentPage: this.currentPage};
         api.relationContactDetail(param).then((res) => {
           const {code,data,msg} = res.data;
           if(code=='0'){
               const item = Object.assign({},row,data);
-              this.$router.push({name:'AddMedicalMultRelation',params:{isEdit:true,data:item}});
+              this.$router.push({name:'AddMedicalMultRelation',params:Object.assign(pam, {isEdit: true, data: item})});
           }else{
               this.$message({
               message: msg,
@@ -123,8 +152,9 @@
         this.currentPage = 1;
         this.getDataList();
       },
-      getDataList() {
-        const param = this.getFilterItems();
+      getDataList(isTurnPage) {
+        const param = this.getFilterItems(isTurnPage);
+        this.searched = true;
         api.multContactList(param).then((res) => {
           if (res.data.code == '0') {
             const data = res.data.data;
@@ -151,7 +181,11 @@
       /*getDetailList(id) {
         this.$router.push({name:'DeptInfoDetail', params:{id: id}})
       },*/
-      getFilterItems() {
+      getFilterItems(isTurnPage) {
+        //翻页时筛选条件没点确定则清空
+        if(isTurnPage&&!this.searched){
+          this.clearFilter();
+        };
         const param = {
           name: this.filter.term,
           current: this.currentPage,
@@ -169,7 +203,7 @@
         if (this.cacheData[next]) {       //如果已请求过该页数据,则使用缓存不重复请求
           this.list = this.cacheData[next];
         } else {
-          this.getDataList();
+          this.getDataList(true);
         }
       },
       warning(msg,type){
@@ -202,6 +236,14 @@
         this.showConfirmDialog(waringTxt,()=>{
           api.removeRelationContact(param).then((res)=>{
             if(res.data.code=='0'){
+              if(!this.searched){
+                //未点确认时清空搜索条件
+                this.clearFilter();
+              }
+              if(this.list.length==1){
+                //当前在最后一页且只有一条数据时,删除后跳到前一页
+                this.currentPage = this.currentPage===1?1:this.currentPage-1;
+              }
               this.warning(res.data.msg||'操作成功','success');
               this.getDataList();
             }else{
@@ -212,6 +254,12 @@
           })
         });
       },
+      clearFilter(){
+        this.filter={
+          term:'',
+          type:''
+        };
+      },
       uploadClick(){
         let inp = document.getElementById("upFile");
         inp.click();

+ 132 - 43
src/components/icss/MedicalName.vue

@@ -1,29 +1,32 @@
 <template>
     <div>
-        <crumbs title="医学术语命名维护" minWidth="995px">
+        <crumbs title="医学术语命名维护" minWidth="995px" class="knowledgeTitle">
             <el-form :inline="true" class="demo-form-inline">
-                <el-form-item label="医学标准术语:">
-                    <el-input size="mini" v-model="filter.term" placeholder="输入术语"></el-input>
-                </el-form-item>
-                <el-form-item label="术语类型:">
-                  <el-select v-model="filter.type"
-                  clearable 
-                  filterable 
-                  placeholder="请选择" 
-                  size="mini">
-                    <el-option
-                      v-for="item in typeList"
-                      :key="item.id"
-                      :label="item.name"
-                      :value="item.name">
-                    </el-option>
-                  </el-select>
-                </el-form-item>
-                <el-form-item label="同义词:">
-                    <el-input size="mini" v-model="filter.libName" placeholder="输入同义词"></el-input>
-                </el-form-item>
-              <!--<el-form-item label="状态:">
-                <el-select v-model="isState" clearable placeholder="请选择" size="mini">
+              <el-form-item>
+                <el-button size="mini" :type="reloadFlag?'danger':'info'"  @click="reloadLib" style="margin:0 10px">加载词库</el-button>
+              </el-form-item>
+              <el-form-item label="医学标准术语:">
+                  <el-input size="mini" v-model="filter.term" placeholder="输入术语"></el-input>
+              </el-form-item>
+              <el-form-item label="术语类型:">
+                <el-select v-model="filter.type"
+                clearable 
+                filterable 
+                placeholder="请选择" 
+                size="mini">
+                  <el-option
+                    v-for="item in typeList"
+                    :key="item.id"
+                    :label="item.name"
+                    :value="item.name">
+                  </el-option>
+                </el-select>
+              </el-form-item>
+              <el-form-item label="同义词:">
+                  <el-input size="mini" v-model="filter.libName" placeholder="输入同义词"></el-input>
+              </el-form-item>
+              <el-form-item label="状态:">
+                <el-select v-model="filter.isState" clearable placeholder="请选择" size="mini">
                   <el-option
                     v-for="item in stateSelect"
                     :key="item.id"
@@ -31,18 +34,23 @@
                     :value="item.id">
                   </el-option>
                 </el-select>
-              </el-form-item>-->
+              </el-form-item>
                 <el-form-item>
-                    <el-button size="mini" @click="filterDatas">确认</el-button>
-                    <el-button size="mini" @click="uploadClick">导入</el-button>
-                    <input type="file" name="uploadfile " id="upFile" @change="uploadFile($event)" accept=".csv, application/vnd.ms-excel, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet">
-                    <router-link to="/admin/LT-YXSYKWH-TJYXSY" style="margin:0 10px">
-                        <el-button size="mini" type="warning">添加医学标准术语</el-button>
-                    </router-link>
+                  <el-button size="mini" @click="filterDatas">确认</el-button>
                 </el-form-item>
             </el-form>
+            <el-form class="secLine">
+              <el-form-item>
+                  <el-button size="mini" @click="uploadClick">导入</el-button>
+                  <input type="file" name="uploadfile " id="upFile" @change="uploadFile($event)" accept=".csv, application/vnd.ms-excel, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet">
+                  <!-- <router-link to="/admin/LT-YXSYKWH-TJYXSY" style="margin:0 10px">
+                      <el-button size="mini" type="warning">添加医学标准术语</el-button>
+                  </router-link> -->
+                  <el-button size="mini" type="warning"  @click="addMedicalName" style="margin:0 10px">添加医学标准术语</el-button>
+              </el-form-item>
+            </el-form>
         </crumbs>
-        <div class="contents">
+        <div class="contents knowledgeContents">
             <el-table :data="list"
                       border
                       style="width: 100%">
@@ -89,6 +97,8 @@
                     <template slot-scope="scope">
                         <el-button type="text" size="small" :disabled="scope.row.isDeleted != 'N'" @click="toEditProduct(scope.row)">修改</el-button>
                         <span style="margin:0 3px;">|</span>
+                        <el-button type="text" size="small" :disabled="scope.row.isDeleted != 'N'" @click="toEditProduct(scope.row,true)">复制</el-button>
+                        <span style="margin:0 3px;">|</span>
                         <el-button type="text" size="small" :class="scope.row.isDeleted == 'N'?'delete':'review'" @click="showDelDialog(scope.row)">{{scope.row.isDeleted == 'N'?'删除':'恢复'}}</el-button>
                     </template>
                 </el-table-column>
@@ -108,6 +118,7 @@
 
 <script>
   import api from '@api/icss.js';
+
   export default {
     name: 'MedicalName',
     data: function () {
@@ -117,37 +128,78 @@
           {id:'N',name:'启用中'},
           {id:'Y',name:'已删除'},
         ],
-        isState:'',
+        // isState:'',
         cacheData: {}, //因为删除和恢复要及时更新,所以不做缓存
         currentPage: 1,
         pageSize: 10,
         total: 0,
+        searched:false,
         filter: {
           term:'',
           type:'',
-          libName:''
+          libName:'',
+          isState:'',
         },
-        typeList:[]
+        typeList:[],
+        reloadFlag:true
       }
     },
     created() {
-      this.getDataList();
+      // this.getDataList();
       this.getTypeList();
+      const that = this;
+      //返回时避免参数未赋值就获取列表
+      setTimeout(function(){
+        that.getDataList();
+      });
+    },
+    watch:{
+      'filter':{
+        handler:function(){
+          this.searched = false;
+        },
+        deep:true
+      }
+    },
+    beforeRouteEnter(to, from, next){
+      next(vm => {
+        //const pm = to.param;
+        Object.assign(vm,to.params);
+      })
     },
     methods: {
-      toEditProduct(row){
+      reloadLib(){
+        if(this.reloadFlag){
+          this.reloadFlag = false;
+          api.reloadLib().then((res)=>{
+            if (res.data.code == 0) {
+              this.reloadFlag = true;
+            }
+          })
+        }  
+      },
+      addMedicalName(){
+        const pam = this.searched?{currentPage:this.currentPage,
+          filter:this.filter}:{currentPage:this.currentPage};
+        this.$router.push({name:'AddMedicalName',
+          params:pam});
+      },
+      toEditProduct(row,copy){
+        const pam = this.searched?{currentPage:this.currentPage,
+          filter:this.filter}:{currentPage:this.currentPage};
         this.$router.push({
           name:'AddMedicalName',
           // params: {info:row}
-          params: {id:row.conceptId}
+          params: Object.assign(pam,{id:row.conceptId,copy:copy})
         })
       },
       filterDatas(){
         this.currentPage = 1;
         this.getDataList();
       },
-      getDataList() {
-        const param = this.getFilterItems();
+      getDataList(isTurnPage) {
+        const param = this.getFilterItems(isTurnPage);
+        this.searched = true;
         api.knowledgeName(param).then((res) => {
           if (res.data.code == '0') {
             const data = res.data.data;
@@ -174,13 +226,18 @@
       /*getDetailList(id) {
         this.$router.push({name:'DeptInfoDetail', params:{id: id}})
       },*/
-      getFilterItems() {
+      getFilterItems(isTurnPage) {
+        //翻页时筛选条件没点确定则清空
+        if(isTurnPage&&!this.searched){
+          this.clearFilter();
+        };
         const param = {
           name: this.filter.term,
           current: this.currentPage,
           size: this.pageSize,
           type:this.filter.type,
-          libName:this.filter.libName
+          libName:this.filter.libName,
+          isDeleted:this.filter.isState
         };
         return param;
       },
@@ -192,7 +249,7 @@
         // if (this.cacheData[next]) {       //如果已请求过该页数据,则使用缓存不重复请求
         //   this.list = this.cacheData[next];
         // } else {
-          this.getDataList();
+          this.getDataList(true);
         // }
       },
       warning(msg,type){
@@ -223,7 +280,19 @@
         let waringTxt = (item.isDeleted === 'N'?'是否删除该标准术语?':'是否重新启用该条数据?')
         this.showConfirmDialog(waringTxt,()=>{
           api.deletMedicalName(param).then((res)=>{
-            if(res.data.code=='0'){
+            if(res.data.code=='0') {
+              if (!this.searched) {
+                //未点确认时清空搜索条件
+                this.clearFilter();
+              }
+              if (item.isDeleted !== 'N') {       //恢复成功后跳转到筛选条件的首页
+                this.currentPage = 1;
+              } else {
+                if (this.filter.isState!==''&&this.list.length === 1){
+                  //有启用状态筛选条件且当前页只有最后一条数据删除时,删除成功后跳转到前一页
+                  this.currentPage = this.currentPage===1?1:this.currentPage-1;
+                  }
+                }
               this.warning(res.data.msg||'操作成功','success');
               this.getDataList();
             }else{
@@ -234,6 +303,14 @@
           })
         });
       },
+      clearFilter(){
+        this.filter = {
+          term:'',
+          type:'',
+          libName:'',
+          isState:'',
+        };
+      },
       uploadClick(){
         let inp = document.getElementById("upFile");
         inp.click();
@@ -284,6 +361,18 @@
 
 <style lang="less" scoped>
     @import "../../less/admin.less";
+    /deep/ .container.knowledgeTitle {
+      height: 80px;
+    }
+    /deep/ .contents.knowledgeContents {
+      padding: 104px 20px 0;
+    }
+    /deep/ .secLine.el-form {
+      float: right;
+      display: block;
+      position: relative;
+      top: -5px;
+    }
     .delete{
         color: red;
     }

+ 74 - 36
src/components/icss/MedicalRelation.vue

@@ -6,7 +6,7 @@
                   <span>{{total}}条</span>
               </el-form-item>
               <el-form-item label="术语关系:">
-                <el-select v-model="type" clearable placeholder="请选择" size="mini">
+                <el-select v-model="filter.type" clearable placeholder="请选择" size="mini">
                   <el-option
                     v-for="item in typeList"
                     :key="item.key"
@@ -16,13 +16,13 @@
                 </el-select>
               </el-form-item>
               <el-form-item label="起始术语:">
-                  <el-input size="mini" v-model="startName" placeholder="输入术语"></el-input>
+                  <el-input size="mini" v-model="filter.startName" placeholder="输入术语"></el-input>
               </el-form-item>
               <el-form-item label="终点术语:">
-                  <el-input size="mini" v-model="endName" placeholder="输入术语"></el-input>
+                  <el-input size="mini" v-model="filter.endName" placeholder="输入术语"></el-input>
               </el-form-item>
               <el-form-item label="状态:">
-                <el-select v-model="isState" clearable placeholder="请选择" size="mini">
+                <el-select v-model="filter.isState" clearable placeholder="请选择" size="mini">
                   <el-option
                     v-for="item in stateSelect"
                     :key="item.id"
@@ -39,9 +39,7 @@
               <el-form-item>
                   <el-button size="mini" @click="uploadClick">导入</el-button>
                   <input type="file" name="uploadfile " id="upFile" @change="uploadFile($event)" accept=".csv, application/vnd.ms-excel, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet">
-                  <router-link to="/admin/LT-YXSYKWH-TJYXSYGX" style="margin:0 10px">
-                      <el-button size="mini" type="warning">添加医学术语关系</el-button>
-                  </router-link>
+                  <el-button size="mini" @click="addMedicalR" type="warning" style="margin:0 10px">添加医学术语关系</el-button>
               </el-form-item>
             </el-form>
         </crumbs>
@@ -121,6 +119,7 @@
 
 <script>
   import api from '@api/icss.js';
+
   export default {
     name: 'MedicalRelation',
     data: function () {
@@ -130,48 +129,62 @@
           {id:'N',name:'启用中'},
           {id:'Y',name:'已删除'},
         ],
-        isState:'',
+        searched: false,
+        filter:{
+          isState:'',
+          startName:'',
+          endName:'',
+          type:'',
+        },
         cacheData: {},
         currentPage: 1,
         pageSize: 10,
         total: 0,
-        startName:'',
-        endName:'',
-        type:'',
         typeList:[],
         titleWidth:'1070px' //头部最小宽度
       }
     },
     created() {
-      this.getDataList();
       // this.getRelationList();
       const typeList = JSON.parse(localStorage.getItem("knowledgeEnumsData"));
       if(typeList){
         this.typeList = typeList.lexiconRSTypeEnum;
       }
+      const that = this;
+      //返回时避免参数未赋值就获取列表
+      setTimeout(function(){
+        that.getDataList();
+      });
+    },
+    watch: {
+      'filter': {
+        handler: function () {
+          this.searched = false;
+        },
+        deep: true
+      }
+    },
+    beforeRouteEnter(to, from, next) {
+      next(vm => {
+        //const pm = to.param;
+        Object.assign(vm, to.params);
+      })
     },
     methods: {
-      toEditProduct(row){
-        // this.$router.push({
-        //   name:'AddSimilarName',
-        //   params: {id:row.questionId,name:row.questionName}
-        // })
+      addMedicalR(){
+        const pam = this.searched ? {
+          currentPage: this.currentPage,
+          filter: this.filter
+        } : {currentPage: this.currentPage};
+        this.$router.push({name: 'AddMedicalRelation', params: pam});
       },
       filterDatas(){
         this.currentPage = 1;
         this.getDataList(1);
       },
-      getDataList(flag) {
-        const param = this.getFilterItems();
-        const param1 = {
-          "current": this.currentPage,
-          "endName": this.endName,
-          "relationId": this.type,
-          "size": this.pageSize,
-          "startName": this.startName,
-          "isDeleted":this.isState
-        }
-        const params = this.type?param1:param;
+      getDataList(flag,isTurnPage) {
+        const params = this.getFilterItems(isTurnPage);
+        this.searched = true;
         api.knowledgeRelation(params).then((res) => {
           if (res.data.code == '0') {
             const data = res.data.data;
@@ -207,13 +220,18 @@
           }
         })
       },*/
-      getFilterItems() {
+      getFilterItems(isTurnPage) {
+        //翻页时筛选条件没点确定则清空
+        if(isTurnPage&&!this.searched){
+          this.clearFilter();
+        };
         const param = {
           current: this.currentPage,
           size: this.pageSize,
-          startName: this.startName,
-          endName: this.endName,
-          isDeleted:this.isState
+          relationId: this.filter.type,
+          startName: this.filter.startName,
+          endName: this.filter.endName,
+          isDeleted:this.filter.isState
         };
         return param;
       },
@@ -222,11 +240,11 @@
       },
       currentChange(next) {
         this.currentPage = next;
-        if (this.cacheData[next]) {       //如果已请求过该页数据,则使用缓存不重复请求
+        /*if (this.cacheData[next]) {       //如果已请求过该页数据,则使用缓存不重复请求
           this.list = this.cacheData[next];
-        } else {
-          this.getDataList();
-        }
+        } else {*/
+          this.getDataList(1,true);
+        //}
       },
       warning(msg,type){
         this.$message({
@@ -252,6 +270,18 @@
         this.showConfirmDialog(warningTxt,()=>{
           api.delKnowledgeRelation(params).then((res)=>{
             if(res.data.code=='0'){
+              if(!this.searched){
+                //未点确认时清空搜索条件
+                this.clearFilter();
+              }
+              if(item.isDeleted !== 'N'){       //恢复成功后跳转到筛选条件的首页
+                this.currentPage = 1;
+              } else {
+                if (this.filter.isState!==''&&this.list.length === 1){
+                  //有启用状态筛选条件且当前页只有最后一条数据删除时,删除成功后跳转到前一页
+                  this.currentPage = this.currentPage===1?1:this.currentPage-1;
+                }
+              }
               this.warning(res.data.msg||'操作成功','success');
               this.getDataList();
             }else{
@@ -262,6 +292,14 @@
           })
         });
       },
+      clearFilter(){
+        this.filter={
+          isState:'',
+          startName:'',
+          endName:'',
+          type:'',
+        };
+      },
       uploadClick(){
         let inp = document.getElementById("upFile");
         inp.click();

+ 13 - 1
src/components/icss/MedicineInfoPg.vue

@@ -48,6 +48,15 @@
     },
     data(){
       return {
+        toolbars: [[
+          ['bold','underline', 'strike'],
+          [{'list': 'ordered'}, {'list': 'bullet'}],
+          [{'script': 'sub'}, {'script': 'super'}],
+          [{'color': []}, {'background': []}],
+          [{'align': []}],
+          ['image']
+        ]],
+        toolbarMode:0,
         editorOption: {
           modules: {
             ImageExtend: {
@@ -80,7 +89,7 @@
                 'image': function () {
                   QuillWatch.emit(this.quill.id)
                 }
-              }
+              },
             }
           }
         },
@@ -116,6 +125,9 @@
         this.data.text = this.$refs.quillEditor.quill.root.innerText;
       }
     },
+    created(){
+      this.editorOption.modules.toolbar.container = this.toolbars[this.toolbarMode]
+    },
     mounted(){
       //显示位置枚举列表
       const pos = localStorage.getItem("knowledgeEnumsData");

+ 59 - 13
src/components/icss/MedicinePrompt.vue

@@ -7,9 +7,7 @@
                 </el-form-item>
                 <el-form-item>
                     <el-button size="mini" @click="filterDatas">确认</el-button>
-                    <router-link to="/admin/LT-YXSYKWH-TJYXSYJTZS" style="margin:0 10px">
-                        <el-button size="mini" type="warning">添加静态知识</el-button>
-                    </router-link>
+                    <el-button size="mini" type="warning" style="margin:0 10px" @click="addMedicalPrompt">添加静态知识</el-button>
                 </el-form-item>
             </el-form>
         </crumbs>
@@ -56,7 +54,8 @@
                         <el-button v-if="scope.row.isDeleted=='Y'" type="text" size="small" class="is-disabled">修改</el-button>
                         <el-button v-if="scope.row.isDeleted=='N'" type="text" size="small" @click="toEditProduct(scope.row)">修改</el-button>
                         <span style="margin:0 3px;">|</span>
-                        <el-button type="text" size="small" @click="toCopyProduct(scope.row)">复制</el-button>
+                        <el-button v-if="scope.row.isDeleted=='Y'" type="text" size="small" class="is-disabled">复制</el-button>
+                        <el-button v-if="scope.row.isDeleted=='N'" type="text" size="small" @click="toCopyProduct(scope.row)">复制</el-button>
                         <span style="margin:0 3px;">|</span>
                         <el-button v-if="scope.row.isDeleted=='Y'" type="text" size="small" @click="showReuseDialog(scope.row)">恢复</el-button>
                         <el-button v-if="scope.row.isDeleted=='N'" type="text" size="small" class="delete" @click="showDelDialog(scope.row)">删除</el-button>
@@ -90,6 +89,7 @@
         total: 0,
         linkIn:[],
         pays:[],
+        searched: false,
         filter: {
           term: '',
           title:''
@@ -97,13 +97,43 @@
       }
     },
     created() {
-      this.getDataList();
+      const that = this;
+      //返回时避免参数未赋值就获取列表
+      setTimeout(function(){
+        that.getDataList();
+      });
+    },
+    watch: {
+      'filter': {
+        handler: function () {
+          this.searched = false;
+        },
+        deep: true
+      }
+    },
+    beforeRouteEnter(to, from, next){
+      next(vm => {
+        //const pm = to.param;
+        Object.assign(vm,to.params);
+      })
     },
     methods: {
+      addMedicalPrompt(){
+        const pam = this.searched ? {
+          currentPage: this.currentPage,
+          filter: this.filter
+        } : {currentPage: this.currentPage};
+        this.$router.push({name:'AddMedicinePrompt',
+          params:pam});
+      },
       toEditProduct(row){
+        const pam = this.searched ? {
+          currentPage: this.currentPage,
+          filter: this.filter
+        } : {currentPage: this.currentPage};
         this.$router.push({
           name:'AddMedicinePrompt',
-          params: {data:row,isEdit:true}
+          params: Object.assign(pam, {data:row,isEdit:true})
         })
       },
       toCopyProduct(row){
@@ -116,8 +146,9 @@
         this.currentPage = 1;
         this.getDataList();
       },
-      getDataList() {
-        const param = this.getFilterItems();
+      getDataList(isTurnPage) {
+        const param = this.getFilterItems(isTurnPage);
+        this.searched = true;
         api.getConceptKnowledgeList(param).then((res) => {
           if (res.data.code == '0') {
             const data = res.data.data;
@@ -129,7 +160,17 @@
           console.log(error);
         });
       },
-      getFilterItems() {
+      clearFilter(){
+        this.filter={
+          term: '',
+          title:''
+        };
+      },
+      getFilterItems(isTurnPage) {
+        //翻页时筛选条件没点确定则清空
+        if(isTurnPage&&!this.searched){
+          this.clearFilter();
+        };
         const param = {
           conceptName:this.filter.term,
           title:this.filter.title,
@@ -143,11 +184,11 @@
       },
       currentChange(next) {
         this.currentPage = next;
-        if (this.cacheData[next]) {       //如果已请求过该页数据,则使用缓存不重复请求
+        /*if (this.cacheData[next]) {       //如果已请求过该页数据,则使用缓存不重复请求
           this.list = this.cacheData[next];
-        } else {
-          this.getDataList();
-        }
+        } else {*/
+          this.getDataList(true);
+        //}
       },
       warning(msg,type){
         this.$message({
@@ -170,6 +211,10 @@
         this.showConfirmDialog('是否删除该静态知识?',()=>{
           api.delConceptInfo({conceptId:[row.conceptId],status:'Y'}).then((res)=>{
             if(res.data.code=='0'){
+              if(!this.searched){
+                //未点确认时清空搜索条件
+                this.clearFilter();
+              }
               this.warning(res.data.msg||'操作成功','success');
               this.getDataList();
             }else{
@@ -184,6 +229,7 @@
         this.showConfirmDialog('是否重新启用该条数据?',()=>{
           api.delConceptInfo({conceptId:[row.conceptId],status:"N"}).then((res)=>{
             if(res.data.code=='0'){
+              this.currentPage = 1;         //恢复数据跳转到筛选条件下首页
               this.warning(res.data.msg||'操作成功','success');
               this.getDataList();
             }else{

+ 8 - 6
src/components/icss/NoiseTemplate.vue

@@ -1,9 +1,10 @@
 <template>
   <div class="NoiseTemplateWrapper TemplateWrapper">
       <crumbs
-      :title="txt"
-      class="topBack"
-      linkTo="/admin/LT-YXSJWH-BQZWH"
+              :title="txt"
+              class="topBack"
+              :param="$route.params"
+              linkTo="labelGroup"
     ></crumbs>
     <PubTagGroup
       :editData="editData"
@@ -166,7 +167,6 @@ export default {
     },
   },
   methods: {
-    back() { this.$router.go(-1) },
     changeVal(val) {    //子组件数据改变传递到父组件
       this.dataPub = val
       // console.log('公用组件传的值都在这', val)
@@ -249,8 +249,10 @@ export default {
           if (res.data.code === '0') {
             this.warning(res.data.msg || '保存成功', 'success','1000')
             setTimeout(() => {
+              //返回带搜索条件的首页
               this.$router.push({
-                path:'/admin/LT-YXSJWH-BQZWH'
+                name: 'labelGroup',
+                params: Object.assign({}, this.$route.params, {currentPage: 1})
               })
             }, 1000);
           } else {
@@ -379,7 +381,7 @@ export default {
         color: #f56c6c;
       }
       span {
-        color:#22ccc8;
+        color:@adminBase;
         font-size: 12px;
       }
     }

+ 52 - 13
src/components/icss/PhysicalExamTemplate.vue

@@ -14,9 +14,7 @@
                 </el-form-item>
                 <el-form-item>
                     <el-button size="mini" @click="filterDatas">确认</el-button>
-                    <router-link to="/admin/LT-YXSJWH-TJCTMB" style="margin:0 10px">
-                        <el-button size="mini" type="warning">添加模板</el-button>
-                    </router-link>
+                    <el-button size="mini" type="warning" @click="addModule" style="margin:0 10px">添加模板</el-button>
                 </el-form-item>
             </el-form>
         </crumbs>
@@ -95,16 +93,41 @@
         total: 0,
         linkIn:[],
         pays:[],
+        searched: false,
         filter: {
           deptId: ''
         }
       }
     },
     created() {
-      this.getDeptShortListSearh()
-      this.getDataList();
+      this.getDeptShortListSearh();
+      const that = this;
+      setTimeout(function () {
+        that.getDataList();
+      }, 200);
+    },
+    watch: {
+      'filter': {
+        handler: function () {
+          this.searched = false;
+        },
+        deep: true
+      }
+    },
+    beforeRouteEnter(to, from, next) {
+      next(vm => {
+        //const pm = to.param;
+        Object.assign(vm, to.params);
+      })
     },
     methods: {
+      addModule() {
+        const pam = this.searched ? {
+          currentPage: this.currentPage,
+          filter: this.filter
+        } : {currentPage: this.currentPage};
+        this.$router.push({name: 'AddPhysicalExamTemp', params: pam});
+      },
       toEditProduct(row){
         this.getPhysicalExamTempByDepId('isEdit', row)
       },
@@ -113,8 +136,12 @@
         api.getPhysicalExamTempByDepId(param).then((res)=>{
             const {code,data,msg} = res.data;
             if(code=='0'){
+              const pam = this.searched ? {
+                currentPage: this.currentPage,
+                filter: this.filter
+              } : {currentPage: this.currentPage};
                 const item = Object.assign({},row,data);
-                this.$router.push({name:'AddPhysicalExamTemp',params:{[type]:true,data:item}});
+              this.$router.push({name: 'AddPhysicalExamTemp', params: Object.assign(pam, {[type]: true, data: item})});
             }else{
                 this.$message({
                 message: msg,
@@ -136,11 +163,9 @@
           }
         })
       },
-      getDataList() {
-        const param = this.getFilterItems();
-        // const param = {
-        //   'name':''
-        // };
+      getDataList(isTurnPage) {
+        const param = this.getFilterItems(isTurnPage);
+        this.searched = true;
         api.getPhysicalExamTempList(param).then((res) => {
           if (res.data.code == '0') {
             const data = res.data.data;
@@ -154,7 +179,11 @@
       getDetailList(row) {
          this.getPhysicalExamTempByDepId('isDetail', row)
       },
-      getFilterItems() {
+      getFilterItems(isTurnPage) {
+        //翻页时筛选条件没点确定则清空
+        if(isTurnPage&&!this.searched){
+          this.filter.deptId='';
+        };
         const param = {
           deptId: this.filter.deptId,
           current: this.currentPage,
@@ -170,7 +199,7 @@
         if (this.cacheData[next]) {       //如果已请求过该页数据,则使用缓存不重复请求
           this.list = this.cacheData[next];
         } else {
-          this.getDataList();
+          this.getDataList(true);
         }
       },
       warning(msg,type){
@@ -192,6 +221,16 @@
         this.showConfirmDialog('是否删除该科室查体模板?',()=>{
           api.delPhysicalExamTemp({'deptId':deptId}).then((res)=>{
             if(res.data.code=='0'){
+              if(!this.searched){
+                //未点确认时清空搜索条件
+                this.filter={
+                  deptId: ''
+                };
+              }
+              if(this.list.length==1){
+                //当前在最后一页且只有一条数据时,删除后跳到前一页
+                this.currentPage = this.currentPage===1?1:this.currentPage-1;
+              }
               this.warning(res.data.msg||'操作成功','success');
               this.getDataList();
             }else{

+ 1 - 1
src/components/icss/PromptDetail.vue

@@ -1,6 +1,6 @@
 <template>
     <div class="NoiseTemplateWrapper TemplateWrapper">
-        <crumbs title="提示信息维护--详情" class="topBack" linkTo="/admin/LT-YXSJWH-TSXXWH">
+        <crumbs title="提示信息维护--详情" class="topBack" linkTo="PromptInfo">
         </crumbs>
         <div class="info-container">
             <el-form label-width="130px"

+ 31 - 16
src/components/icss/PubIndeptTag.vue

@@ -17,7 +17,7 @@
                 <el-select
                         v-model="form.region1"
                         placeholder="请选择归属"
-                        :disabled="!!editData.id"
+                        :disabled="isEditOrCopy"
                         @change="(e)=>readyChangeSelect(e,1)"
                 >
                     <el-option
@@ -36,7 +36,7 @@
                 <el-select
                         v-model="form.region2"
                         placeholder="请选择填写单类型"
-                        :disabled="!!editData.id  || !form.region1"
+                        :disabled="isEditOrCopy&&(form.region2!= '1'&&form.region2!= '2' ) || !form.region1"
                         @change="(e)=>readyChangeSelect(e,2)"
                 >
                     <el-option
@@ -150,6 +150,19 @@
                   v-if="form.region1 == 5"
                   class="changeTips changeTipsName"
                 >标签界面名称需要与医学标准术语内容相对应,如果没有可以先在医学标准术语中建立相关信息!未建立相关信息可能会影响系统使用!当为化验推送项时标签界面名称应当检索医学术语库内容;</span>
+                <!-- 诱因记录暂时不做 -->
+                <!-- <span
+                  v-if="form.region1 == '1'&&form.region2 == '1'"
+                  class="changeTips changeTipsName checkSpecFlag"
+                >
+                   <el-checkbox v-model="form.specFlag"  label="诱因记录" true-label="2" false-label="0"  @change="sendData"></el-checkbox>
+                </span> -->
+                <span
+                  v-if="form.region1=='1'&&form.region2=='5'"
+                  class="changeTips changeTipsName checkSpecFlag"
+                >
+                   <el-checkbox v-model="form.specFlag" label="是否高亮" true-label="1" false-label="0"  @change="sendData"></el-checkbox>
+                </span>
             </el-form-item>
             <el-form-item
                     label="标签前后缀:"
@@ -213,7 +226,7 @@
                 <span class="changeTips">改变性别后,标签明细将会恢复到默认状态</span>
                 <el-select
                         v-model="form.region7"
-                        :disabled="!!editData.id || !form.region1 || form.region2 == '99'"
+                        :disabled="isEditOrCopy || !form.region1 || form.region2 == '99'"
                         @change="(e)=>readyChangeSelect(e,3)"
                 >
                     <el-option
@@ -319,7 +332,7 @@
 // 化验(val:5):化验数字键盘(val:7)、化验单选(val:1)
 
   export default {
-    props:['editData'],
+    props:['editData','isEditOrCopy'],
     data() { 
       var validatePass1 = (rule, value, callback) => {
           this.validateSystomName(value,callback,1)
@@ -347,6 +360,7 @@
           maxNormalVal: '',       //化验正常值最大值
           region12: '0',        //是否为查体推送   
           region13:'',
+          specFlag :'0',        //标记状态(0:没有标记,1:主诉高亮,2:诱因记录)
           prefix:'',            //前缀
           suffix:'',            //后缀
           tipLis:[],           //提示列表
@@ -434,7 +448,8 @@
       this.getDropList();
       //编辑时赋值
       const editData = this.$props.editData;
-      if(editData.id){
+       const isEditOrCopy = this.$props.isEditOrCopy;
+      if(isEditOrCopy){
         const trans = utils.transformKeys(editData);
         this.form = Object.assign({},this.form,trans);
       }
@@ -450,13 +465,13 @@
       },
       newType(nextVal, prevVal) {
         const editData = this.$props.editData;
-        if(!editData.id) {
+        if(!this.isEditOrCopy) {
           this.initForm()
         }
       },
       newSign(nextVal, prevVal) {
         const editData = this.$props.editData;
-        if(!editData.id) {
+        if(!this.isEditOrCopy) {
           this.initForm()
         }
       },
@@ -478,7 +493,11 @@
             this.AdscriptionsList = res.data.data[1]
             this.labelTypesList = res.data.data[6];
             this.form.tipLis = res.data.data[6];
-            this.labelTypes = this.labelTypesList;
+            if(this.isEditOrCopy && (this.form.region2=='1'||this.form.region2=='2')) {
+              this.labelTypes = this.labelTypesList.filter(item => (item.val=='1'||item.val=='2'));
+            } else {
+              this.labelTypes = this.labelTypesList;
+            }
             this.Adscriptions = this.AdscriptionsList.filter(item => Object.keys(this.labelTypesMaps).indexOf(item.val) > -1)
           }
         })
@@ -637,6 +656,7 @@
         this.form.maxNormalVal = ''
         this.form.region5 = ''
         this.form.region12 = '0'
+        this.form.specFlag = '0'
         this.systemNameShow = false
         this.interfaceNameShow = false
       },
@@ -707,16 +727,11 @@
     .el-message-box__btns .el-button--default {
         color: #606266 !important;
     }
-    .cancelColor {
-        color: #22ccc8 !important;
-    }
     .changeTips {
-        position: absolute;
-        left: 220px;
-        // min-width: 300px;
         width: 200%;
-        color: #ea7777;
-        font-size: 12px;
+    }
+    .checkSpecFlag {
+      top: 5px;
     }
     }
 </style>

+ 1 - 41
src/components/icss/PubTagGroup.vue

@@ -565,43 +565,6 @@ export default {
         this.initForm()
       }
       this.changeSex(tmpData);
-      // if(type == 3){
-      //   this.form.region7 = this.tmpSex;
-      //   this.$alert('改变性别后,标签明细将会恢复到默认状态?', '提示', {
-      //     confirmButtonText: '确定',
-      //     cancelButtonClass: 'cancelColor',
-      //     type: 'warning'
-      //   }).then(() => {
-      //     this.form.region7 = tmpData
-      //     this.changeSex(tmpData);
-      //   }).catch(() => {
-      //     // this.form.region7 = this.tmpSex;
-      //   });
-      // }else if(type == 2){
-      //   this.form.region2 = this.tmpType
-      //   this.$alert('改变类型后,标签明细将会恢复到默认状态?', '提示', {
-      //     confirmButtonText: '确定',
-      //     cancelButtonClass: 'cancelColor',
-      //     type: 'warning'
-      //   }).then(() => {
-      //     this.form.region2 = tmpData;
-      //     this.changeSex(tmpData);
-      //   }).catch(() => {
-      //     // this.form.region2 = this.tmpType;
-      //   });
-      // }else if(type == 1){
-      //   this.form.region1 = this.tmpOwn;
-      //   this.$alert('改变归属后,标签明细将会恢复到默认状态?', '提示', {
-      //     confirmButtonText: '确定',
-      //     cancelButtonClass: 'cancelColor',
-      //     type: 'warning'
-      //   }).then(() => {
-      //     this.form.region1 = tmpData;
-      //     this.changeSex(tmpData);
-      //   }).catch(() => {
-      //     // this.form.region1 = this.tmpOwn;
-      //   });
-      // }
     },
     submitForm(formName) {
       this.$refs[formName].validate((valid) => {
@@ -690,14 +653,11 @@ export default {
     .el-message-box__btns .el-button--default {
       color: #606266 !important;
     }
-    .cancelColor {
-      color: #22ccc8 !important;
-    }
     .changeTips {
       position: absolute;
       left: 220px;
       // min-width: 300px;
-      color: #22ccc8;
+      color: #48C5D7;
       font-size: 12px;
     }
     .changeTipsName {

+ 2 - 2
src/components/icss/PubTemplateGroup.vue

@@ -349,13 +349,13 @@ export default {
     color: #606266 !important;
   }
   .cancelColor {
-    color: #22ccc8 !important;
+    color: #48C5D7 !important;
   }
   .changeTips {
     position: absolute;
     left: 220px;
     // min-width: 300px;
-    color: #22ccc8;
+    color: #48C5D7;
     font-size: 12px;
   }
 }

+ 79 - 3
src/components/icss/SingleSelect.vue

@@ -11,7 +11,7 @@
                 <el-checkbox-group size="small" v-for="(it,i) in rows" v-if="type!=1&&(focusOn==i||(focusOn==-1&&i==0))" :key="3+i" v-model="rows[i].isBan" @change="emitValues(i,'hasBan',rows[i].isBan)">
                     <el-checkbox-button v-if=" !(ascription == 5 && type == 1 || type == 11)" :label="i" :disabled="rows[i].isNone || hasError==i||focusOn==-1">同“伴”类型</el-checkbox-button>
                 </el-checkbox-group>
-                <el-checkbox-group size="small" v-for="(it,i) in rows" v-if="focusOn==i||(focusOn==-1&&i==0)" :key="4+i" v-model="rows[i].isError" @change="emitValues(i,'hasError',rows[i].isError)">
+                <el-checkbox-group size="small" v-for="(it,i) in rows" v-if="ascription==5&&(focusOn==i||(focusOn==-1&&i==0))" :key="4+i" v-model="rows[i].isError" @change="emitValues(i,'hasError',rows[i].isError)">
                     <el-checkbox-button v-if="ascription==5 && (type == 1 || type != 11)" :label="i" :disabled="hasDefault==i||hasBan==i ||hasNone==i ||focusOn==-1">标记异常选项</el-checkbox-button>
                 </el-checkbox-group>
                  <span v-if="type == 11" class="tip">可输入中文全角括号"()", 当作可输入内容的占位符</span>
@@ -19,6 +19,13 @@
                
             </div>
             <div class="main-area">
+                <div class="buttonBox"> 
+             
+                    <div class="bottomPartMid bottomPartMidss fl">
+                        <p><span class="el-icon-arrow-up" @click="toggleTopDownList(1)"></span></p>
+                        <p><span class="el-icon-arrow-down" @click="toggleTopDownList(2)"></span></p>
+                    </div>
+                </div>
                 <el-col v-for="(it,i) in rows" :key="i">
                     <el-input v-model="rows[i].name"
                               v-bind:class="{select:focusOn==i}"
@@ -30,6 +37,10 @@
                 </el-col>
                 <el-button @click="addRow">+</el-button>
             </div>
+            
+
+            
+
         </el-form>
     </div>
 </template>
@@ -81,6 +92,30 @@
                 }
             }
         }
+        .buttonBox {
+            width: 10%;
+            position: absolute;
+            right: 170px;
+            margin-top: 20px;
+        }
+        .bottomPartMid {
+            width: 8%;
+            p {
+            width: 100%;
+            text-align: center;
+            span {
+                cursor: pointer;
+                display: inline-block;
+                width: 30px;
+                height: 40px;
+                line-height: 40px;
+                margin: 0 auto;
+                border: 1px solid @icssBorder;
+                margin-bottom: 15px;
+                font-size: 18px;
+            }
+            }
+        }
         
         .el-button{
             width: 200px;
@@ -91,7 +126,7 @@
   import utils from '@api/utils.js';
   import Vue from 'vue';
     export default {
-      props:['type','options','ascription','sexType'],
+      props:['type','options','ascription','sexType','isEditOrCopy'],
       data(){
         return {
           maps:{isBan:'同“伴”',isNone:'同“无”',defaultSelect:'默认选中',isError:'异常选项'},
@@ -161,7 +196,16 @@
         type(newVal, preVal) {
             if (newVal != preVal) {
                 if (JSON.stringify(newVal) != JSON.stringify(preVal)) {
+                  if(this.isEditOrCopy) {
+                    for(let i = 0, len = this.rows.length; i < len; i++) {
+                      this.rows[i].defaultSelect = ''
+                      this.rows[i].isBan = ''
+                      this.rows[i].isNone = ''
+                      this.rows[i].isError = ''
+                    }
+                  } else {
                     this.rows = [{name:'',defaultSelect:'',isBan:'',isNone:'',isError:''},{name:'',defaultSelect:'',isBan:'',isNone:'',isError:''},{name:'',defaultSelect:'',isBan:'',isNone:'',isError:''},{name:'',defaultSelect:'',isBan:'',isNone:'',isError:''}];
+                  }
                 }
             }
         },
@@ -179,7 +223,6 @@
         },
         selectRow(index){
           this.focusOn = index;
-
         },
         emitValues(i,type,flag){
           if(typeof i =='number'&&this.focusOn == -1){
@@ -206,6 +249,39 @@
           }
           
         },
+        toggleTopDownList(type){
+          if(this.focusOn == '-1') {
+            return
+          }
+          const rows = JSON.parse(JSON.stringify(this.rows))
+          if(type == '1') {
+            if(this.focusOn == '0') {
+              return
+            } else {
+              let i = this.focusOn
+              let tmp1 = rows[i]
+              let tmp2 = rows[i-1]
+              rows.splice(i-1,1,tmp1)
+              rows.splice(i,1,tmp2)
+              this.rows = [...rows]
+              this.focusOn = i-1
+            }
+          } else if(type == '2') {
+            if(this.focusOn == this.rows.length-1) {
+              return
+            } else {
+               let i = this.focusOn
+              let tmp1 = rows[i]
+              let tmp2 = rows[i+1]
+              rows.splice(i,1,tmp2)
+              rows.splice(i+1,1,tmp1)
+              this.rows = [...rows]
+              this.focusOn = i+1
+            }
+          }
+           const items = utils.simpleOptionData(this.rows);
+          this.$emit('pushValues',items);
+        },
         delRow(){
           if(this.focusOn==-1){
             this.$message({

+ 68 - 23
src/components/icss/TemplateMaintenance.vue

@@ -106,18 +106,15 @@
     data: function() {
       return {
         list: [],
-        tagTypes: [],
         Adscriptions: [],
         tmpAdscriptions: [],
         AdscriptionsType:[],
         AdscriptionsOwnTo:[],
-        tagTypesList: [],
+        searched: false,
         filter: {
-          tagType: [], //标签类型
           templateType: '', //模板类型
           ownTo: '', //属于科室、慢病
           tagAdscription: '', //标签归属
-          tagSysName: '', //标签系统名称
         },
         currentPage: 1,
         pageSize: 10,
@@ -137,6 +134,12 @@
       }
     },
     watch: {
+      'filter': {
+        handler: function () {
+          this.searched = false;
+        },
+        deep: true
+      },
       tmpType(newVal, preVal){
         this.filter.tagAdscription = ''
         //根据类型不同删选归属
@@ -156,11 +159,12 @@
           this.Adscriptions = this.tmpAdscriptions
         }
         if((newVal+'') != preVal){
+
           if(newVal == 1){
-            this.AdscriptionsOwnTo = this.deptAndDisInfo.deptDTOS
+            this.AdscriptionsOwnTo = this.deptAndDisInfo.deptDTOS;
             this.filter.ownTo = ''
           }else if(newVal == 2){
-            this.AdscriptionsOwnTo = this.deptAndDisInfo.disDTOS
+            this.AdscriptionsOwnTo = this.deptAndDisInfo.disDTOS;
             this.filter.ownTo = ''
           }else{
             this.AdscriptionsOwnTo = []
@@ -169,6 +173,21 @@
         }
       }
     },
+    beforeRouteEnter(to, from, next) {
+      next(vm => {
+        //const pm = to.param;
+        const flt = to.params.filter;
+        vm.currentPage = to.params.currentPage;
+        vm.deptAndDisInfo = JSON.parse(localStorage.getItem('deptDis')||null);
+        if(flt){
+          vm.filter.templateType = flt.templateType;
+          setTimeout(function(){
+            vm.filter.tagAdscription = flt.tagAdscription;
+              vm.filter.ownTo = flt.ownTo;
+            });
+        }
+      })
+    },
     methods: {
       getSubTemplate() {
         api.getAllDeptAndDisInfo({}).then((res) => {
@@ -184,27 +203,19 @@
         this.AdscriptionsType = templateType
         return api.getDropList().then((res) =>{
           if(res.data.code === '0') {
-            this.tagTypes =  res.data.data[6];
             this.Adscriptions = res.data.data[4];
             this.tmpAdscriptions = res.data.data[4];
             localStorage.setItem('typeLis',JSON.stringify(res.data.data[4]))
-            for (var i = 0; i < this.tagTypes.length; i++) {
-              this.tagTypesList.push(this.tagTypes[i].val)
-            }
           }
         })
       },
-      getDataList() {
-        const param = this.getFilterItems();
+      getDataList(isTurnPage) {
+        const param = this.getFilterItems(isTurnPage);
+        this.searched = true;
         api.getModuleInfoList(param).then((res) => {
           if(res.data.code == 0){
-            const list = res.data.data.records
+            const list = res.data.data.records;
             for (var i = 0; i < list.length; i++) {
-              for (var j =  0; j < this.tagTypes.length; j++) {
-                if(list[i].tagType === this.tagTypes[j].val) {
-                  list[i].tagTypeCn = this.tagTypes[j].name;
-                }
-              }
               for (var z =  0; z < this.Adscriptions.length; z++) {
                 if(list[i].type === this.Adscriptions[z].val) {
                   list[i].typeCn = this.Adscriptions[z].name
@@ -221,7 +232,11 @@
         this.getDataList();
       },
       addIndeptTag() {
-        this.$router.push({path:'LT-YXSJWH-TJMBWH'})
+        const pam = this.searched ? {
+          currentPage: this.currentPage,
+          filter: this.filter
+        } : {currentPage: this.currentPage};
+        this.$router.push({name: 'TemplateMaintenanceWrap', params: pam})
       },
       modifyIndeptTag(row) {
         // api.detailsTag({ids:row.id}).then((res) => {
@@ -243,15 +258,30 @@
           if(data1.code == 0){
             rightMsg = Object.assign({},data1);
           }
-          allData = Object.assign({},topMsg,rightMsg)
-          this.$router.push({name:'TemplateMaintenanceWrap',params:{isEdit:true,data:allData}});
+          allData = Object.assign({}, topMsg, rightMsg);
+          const pam = this.searched ? {
+            currentPage: this.currentPage,
+            filter: this.filter
+          } : {currentPage: this.currentPage};
+          this.$router.push({
+            name: 'TemplateMaintenanceWrap',
+            params: Object.assign(pam, {isEdit: true, data: allData})
+          });
         })
       },
       currentChange(next) {
         this.currentPage = next;
-        this.getDataList();
+        this.getDataList(true);
       },
-      getFilterItems() {
+      getFilterItems(isTurnPage) {
+        //翻页时筛选条件没点确定则清空
+        if(isTurnPage&&!this.searched){
+          this.filter={
+            templateType: '', //模板类型
+            ownTo: '', //属于科室、慢病
+            tagAdscription: '', //标签归属
+          };
+        };
         const param = {
           current: this.currentPage,
           size: this.pageSize,
@@ -279,10 +309,25 @@
           resolve();
         }).catch(() => {});
       },
+      clearfilter(){
+        this.filter={
+          templateType: '', //模板类型
+          ownTo: '', //属于科室、慢病
+          tagAdscription: '', //标签归属
+        };
+      },
       showDelDialog(id,type){
         this.showConfirmDialog('是否删除该标签?',()=>{
           api.delTemplate({ids:id,type:type}).then((res)=>{
             if(res.data.code=='0'){
+              if(!this.searched){
+                //未点确认时清空搜索条件
+                this.clearfilter();
+              }
+              if(this.list.length==1){
+                //当前在最后一页且只有一条数据时,删除后跳到前一页
+                this.currentPage = this.currentPage===1?1:this.currentPage-1;
+              }
               this.getDataList();
               this.warning(res.data.msg || '操作成功','success');
             }else{

+ 8 - 6
src/components/icss/TemplateMaintenanceWrap.vue

@@ -1,9 +1,10 @@
 <template>
   <div class="NoiseTemplateWrapper TemplateWrapper">
     <crumbs
-      :title="txt"
-      class="topBack"
-      linkTo="/admin/LT-YXSJWH-MBWH"
+            :title="txt"
+            class="topBack"
+            :param="$route.params"
+            linkTo="TemplateMaintenance"
     ></crumbs>
     <PubTemplateGroup
       :editData="editData"
@@ -65,7 +66,6 @@ export default {
     }
   },
   methods: {
-    back() { this.$router.go(-1) },
     staticOwn(val){
       this.staticOwnTo = val
     },
@@ -150,10 +150,12 @@ export default {
           this.saveDisable = false  //提交保存按钮不可点击,返回结果时才可点击,防止频繁发送请求
           api.updateModuleInfo(param).then((res) => {
             if (res.data.code === '0') {
-              this.warning(res.data.msg || '修改成功', 'success','1000')
+              this.warning(res.data.msg || '修改成功', 'success', '1000');
+              //返回带搜索条件的首页
               setTimeout(() => {
                 this.$router.push({
-                  path:'/admin/LT-YXSJWH-MBWH'
+                  name: 'TemplateMaintenance',
+                  params: Object.assign({}, this.$route.params, {currentPage: 1})
                 })
               }, 1000);
             } else {

+ 1 - 1
src/components/icss/VersionDetail.vue

@@ -1,6 +1,6 @@
 <template>
   <div>
-    <crumbs title="版本信息维护-明细" linkTo="/admin/LT-YXSJWH-BBXXWH"></crumbs>
+    <crumbs title="版本信息维护-明细" linkTo="VersionInfo"></crumbs>
     <div class="contents">
       <div class="content">
         <el-form ref="form" :label-position="labelPosition" label-width="85px" class="add-admin-form">

+ 34 - 6
src/components/icss/VersionInfo.vue

@@ -82,6 +82,7 @@
         currentPage: 1,
         pageSize: 10,
         total: 0,
+        searched: false,
         filter: {
           name: ''
         },
@@ -92,26 +93,49 @@
     created() {
       this.getDataList();
     },
+    watch: {
+      'filter': {
+        handler: function () {
+          this.searched = false;
+        },
+        deep: true
+      }
+    },
+    beforeRouteEnter(to, from, next) {
+      next(vm => {
+        //const pm = to.param;
+        Object.assign(vm, to.params);
+      })
+    },
     methods: {
       addVersion(){
         // 添加版本信息
+        const pam = this.searched ? {
+          currentPage: this.currentPage,
+          filter: this.filter
+        } : {currentPage: this.currentPage};
         this.$router.push({
           name:'AddVersion',
-          params: {copy:true}
+          params: pam
         })
       },
       toEditVersion(row,flag){
+        const pam = this.searched ? {
+          currentPage: this.currentPage,
+          filter: this.filter
+        } : {currentPage: this.currentPage};
         this.$router.push({
           name:'AddVersion',
-          params: {info:row,copy:flag}
+          params: Object.assign(pam, {info: row, copy: flag})
         })
       },
       filterDatas(){
         this.currentPage = 1;
         this.getDataList();
       },
-      getDataList() {
-        const param = this.getFilterItems();
+      getDataList(isTurnPage) {
+        const param = this.getFilterItems(isTurnPage);
+        this.searched = true;
         api.versionInfo(param).then((res) => {
           if (res.data.code == '0') {
             const data = res.data.data;
@@ -132,7 +156,11 @@
         let isFirst = false;
         this.$router.push({name:'VersionDetail', params:{info:item,isFirst}});
       },
-      getFilterItems() {
+      getFilterItems(isTurnPage) {
+        //翻页时筛选条件没点确定则清空
+        if(isTurnPage&&!this.searched){
+          this.filter.name='';
+        };
         const param = {
           name: this.filter.name,
           current: this.currentPage,
@@ -148,7 +176,7 @@
         if (this.cacheData[next]) {       //如果已请求过该页数据,则使用缓存不重复请求
           this.list = this.cacheData[next];
         } else {
-          this.getDataList();
+          this.getDataList(true);
         }
       }
     }

+ 11 - 8
src/components/preTreat/AddCombinQuestion.vue

@@ -3,19 +3,21 @@
         <crumbs
                 :title="txt"
                 class="topBack"
-                linkTo="/admin/LT-YWZSJWH-ZHTXDWH"
+                :param="$route.params"
+                linkTo="CombinQuestion"
         ></crumbs>
         <PubIndeptQa
                 @changeVal="changeVal"
                 @changeType="changeType"
                 @validatePass="validatePass"
                 qaType="2"
+                :isEdit="$route.params.isEdit"
                 :editData="editData"
                 ref="submitForm"
         ></PubIndeptQa>
         <div class="main">
             <p class="title" v-if="dataPub.region2">
-                填写单明细:<span>(互斥项与其他明细内容互斥,互斥项同时只可选择一个)</span>
+                填写单明细:<span v-if="dataPub.region2!='4'">(互斥项与其他明细内容互斥,互斥项同时只可选择一个)</span>
             </p>
             <QuestionTagGroup v-if="dataPub.region2" qaType="2" :ascription="dataPub.region1" :sexType="dataPub.region7" :type="dataPub.region2" @changeActionData="pushValues" :options="editData.questionMapping"></QuestionTagGroup>
             <div class="btn">
@@ -49,14 +51,13 @@
       }
     },
     beforeMount:function(){
-      const {isEdit,data} = this.$route.params;
-      if(isEdit){
-        this.txt = '组合填写单维护-修改组合填写单';
-        this.editData = data;console.log(data)
+      const {isEdit,isCopy,data} = this.$route.params;
+      if(isEdit||isCopy){
+        this.txt = isCopy?'组合填写单维护-复制组合填写单':'组合填写单维护-修改组合填写单';
+        this.editData = data;
       }
     },
     methods: {
-      back() { this.$router.go(-1) },
       changeVal(val) {    //子组件数据改变传递到父组件
         this.dataPub = val;
         console.log('公用组件传的值都在这', val);
@@ -106,6 +107,7 @@
             "ageEnd": this.dataPub.region9,              //最大年龄
             "itemType" :this.dataPub.region12,           //是否为主要内容
             "url":this.dataPub.region13,                  //上传图片
+            'explains':this.dataPub.explains,           //症状解释
             //"questionDetails": this.options,                //明细项
             "questionMappings": this.options,      //映射关系,
           }
@@ -117,7 +119,8 @@
           api.questionAdd(param).then((res) => {
             if (res.data.code === '0') {
               this.warning(res.data.msg || '保存成功', 'success');
-              this.$router.push("/admin/LT-YWZSJWH-ZHTXDWH");
+              //返回带搜索条件的首页
+              this.$router.push({name:'CombinQuestion',params:Object.assign({},this.$route.params,{currentPage:1})});
             } else {
               this.warning(res.data.msg)
             }

+ 4 - 3
src/components/preTreat/AddQuestionModules.vue

@@ -3,7 +3,8 @@
         <crumbs
                 :title="txt"
                 class="topBack"
-                linkTo="/admin/LT-YWZSJWH-MBWH"
+                :param="$route.params"
+                linkTo="QuestionModules"
         ></crumbs>
         <div class="PubTagGroupWrapper">
         <el-form class="groups"
@@ -180,7 +181,6 @@
       },
     },
     methods: {
-      back() { this.$router.go(-1) },
       getAvailibleType(){
         api.getModuleType({moduleType:this.form.moduleType,relationId:this.form.relationId}).then((res) =>{
           if(res.data.code === '0') {
@@ -266,7 +266,8 @@
           api.addModule(param).then((res) => {
             if (res.data.code === '0') {
               this.warning(res.data.msg || '保存成功', 'success');
-              this.$router.push("/admin/LT-YWZSJWH-MBWH");
+              //返回带搜索条件的首页
+              this.$router.push({name:'QuestionModules',params:Object.assign({},this.$route.params,{currentPage:1})});
             } else {
               this.warning(res.data.msg)
             }

+ 24 - 12
src/components/preTreat/AddSimpleQuestion.vue

@@ -3,7 +3,8 @@
         <crumbs
                 :title="txt"
                 class="topBack"
-                linkTo="/admin/LT-YWZSJWH-DLTXDWH"
+                :param="param"
+                linkTo="SimpleQuestion"
         ></crumbs>
         <PubIndeptQa
                 @changeVal="changeVal"
@@ -13,11 +14,11 @@
                 ref="submitForm"
         ></PubIndeptQa>
         <div class="main">
-            <p class="title" v-if="dataPub.region2==1||dataPub.region2==2|| dataPub.region2==3|| dataPub.region2==11">
+            <p class="title" v-if="dataPub.region2==1||dataPub.region2==2|| dataPub.region2==3|| dataPub.region2==11|| dataPub.region2==8">
                 填写单明细:<span v-if="dataPub.region2==2">(互斥项与其他明细内容互斥,互斥项同时只可选择一个)</span>
             </p>
             <PubSelect
-                    v-if="dataPub.region2==1 || dataPub.region2==2 || dataPub.region2==3 || dataPub.region2==11"
+                    v-if="dataPub.region2==1 || dataPub.region2==2 || dataPub.region2==3 || dataPub.region2==11|| dataPub.region2==8"
                     :ascription="dataPub.region1"
                     :sexType="dataPub.region7"
                     :type="dataPub.region2"
@@ -46,22 +47,22 @@
     data() {
       return {
         txt:'独立填写单维护-添加独立填写单',
+        param:this.$route.params,
         imgList:[],
         dataPub: {},      //公用组件传的值都在这
-        itemsTypes:[1,2],            //有明细的类型
+        itemsTypes:[1,2,8],            //有明细的类型
         editData:{},                    //编辑数据
         options: [],           //标签明细右侧操作数据
       }
     },
     beforeMount:function(){
-      const {isEdit,data} = this.$route.params;
-      if(isEdit){
-        this.txt = '独立填写单维护-修改独立填写单';
+      const {isEdit,isCopy,data} = this.$route.params;
+      if(isEdit||isCopy){
+        this.txt = isCopy?'独立填写单维护-复制独立填写单':'独立填写单维护-修改独立填写单';
         this.editData = data;
       }
     },
     methods: {
-      back() { this.$router.go(-1) },
       changeVal(val) {   //子组件数据改变传递到父组件
         this.dataPub = val;
         //console.log('公用组件传的值都在这', val);
@@ -84,9 +85,10 @@
         let options2 = [];
         const opts = this.options;
         let pureName='',pureDesc = '';
+        const reg = /(\$\{number_\S*?\})|(\$\{input_\S*?\})/g;
         for (let i = 0; i < opts.length; i++) {
-          pureName=opts[i].name.replace(/(\$\{number_\S*?\})|(\$\{input_\S*?\})/g,'');
-          pureDesc = opts[i].description.replace(/(\$\{number_\S*?\})|(\$\{input_\S*?\})/g,'');
+          pureName=opts[i].name.replace(reg,'');
+          pureDesc = opts[i].description.replace(reg,'');
           if(pureName.length>30){
             this.warning('医生界面展示内容不能超过30个字');
             return ;
@@ -95,7 +97,14 @@
             this.warning('患者界面展示内容不能超过30个字');
             return ;
           }
-
+          if(this.dataPub.region2=='3'&&(opts[i].name&&!reg.test(opts[i].name))){
+            this.$message({
+              message: '请添加数字输入框或者文本输入框',
+              type: 'warning',
+              showClose: true,
+            });
+            return;
+          }
           if(opts[i].name.trim() != '') {
               options2.push(this.options[i]);
           }else if(opts[i].description.trim() != ''){           //患者填了,医生没填,提示医生必填
@@ -130,6 +139,8 @@
             "ageEnd": this.dataPub.region9,              //最大年龄
             "itemType" :this.dataPub.region12,           //是否为主要内容
             "url":this.dataPub.region13,                  //上传图片
+            "specFlag": this.dataPub.specFlag,            //是否拼接到主诉
+            "required": this.dataPub.required,             //必填
             "questionDetails": this.options,                //明细项
             //"questionMappings": [],      //映射关系,
           }
@@ -141,7 +152,8 @@
           api.questionAdd(param).then((res) => {
             if (res.data.code === '0') {
               this.warning(res.data.msg || '保存成功', 'success');
-              this.$router.push("/admin/LT-YWZSJWH-DLTXDWH");
+              //返回带搜索条件的首页
+              this.$router.push({name:"SimpleQuestion",params:Object.assign({},this.param,{currentPage:1})});
             } else {
               this.warning(res.data.msg)
             }

+ 53 - 13
src/components/preTreat/CombinQuestion.vue

@@ -3,7 +3,7 @@
         <crumbs title="组合填写单维护">
             <el-form :inline="true" class="demo-form-inline">
                 <el-form-item label="归属:">
-                    <el-select size="mini" v-model="filter.tagAdscription" @change="getValue"  placeholder="归属" clearable>
+                    <el-select size="mini" v-model="filter.tagAdscription"  placeholder="归属" clearable>
                         <el-option v-if="item.val!=6&&item.val!=7&&item.val!=8&&item.val!=9&&item.val!=10&&item.val!=21&&item.val!=22" v-for="item in Adscriptions" :label="item.name" :value="item.val" :key="item.id" ></el-option>
                     </el-select>
                 </el-form-item>
@@ -65,10 +65,12 @@
                         :resizable = "false"
                         prop="operate"
                         label="操作"
-                        width="120">
+                        width="140">
                     <template slot-scope="scope">
                         <el-button  @click="modifyIndeptTag(scope.row)" type="text" size="small">修改</el-button>
                         <span style="margin:0 3px;">|</span>
+                        <el-button  @click="modifyIndeptTag(scope.row,true)" type="text" size="small">复制</el-button>
+                        <span style="margin:0 3px;">|</span>
                         <el-button @click="showDelDialog(scope.row)" class="delete" type="text" size="small">删除</el-button>
                     </template>
                 </el-table-column>
@@ -96,6 +98,7 @@
         tagTypes: [],
         Adscriptions: [],
         tagTypesList:[],
+        searched:false,
         filter: {
           tagType: [], //标签类型
           tagAdscription: '', //标签归属
@@ -109,10 +112,21 @@
     created() {
       this.getDropList();
     },
+    watch:{
+      'filter':{
+        handler:function(){
+          this.searched = false;
+        },
+        deep:true
+      }
+    },
+    beforeRouteEnter(to, from, next){
+      next(vm => {
+        //const pm = to.param;
+        Object.assign(vm,to.params);
+      })
+    },
     methods: {
-      getValue(val) {
-        console.log('changeVal', val, this.filter.tagAdscription)
-      },
       getDropList() {
         api.getPreTypeList().then((res) =>{
           this.getDataList();
@@ -125,8 +139,9 @@
 
         })
       },
-      getDataList() {
-        const param = this.getFilterItems();
+      getDataList(isTurnPage) {
+        const param = this.getFilterItems(isTurnPage);
+        this.searched = true;
         api.getQuestionList(param).then((res) => {
           const list = [...res.data.data.records];
           for (var i = 0; i < list.length; i++) {
@@ -151,14 +166,19 @@
         this.getDataList();
       },
       addIndeptTag() {
-        this.$router.push({path:'LT-YWZSJWH-TJZHTXD'});
+        const pam = this.searched?{currentPage:this.currentPage,
+          filter:this.filter}:{currentPage:this.currentPage};
+        this.$router.push({name:'AddCombinQuestion',
+          params:pam});
       },
-      modifyIndeptTag(row) {
+      modifyIndeptTag(row,isCopy) {
         api.questionDetail({id:row.id}).then((res)=>{
           const {code,data,msg} = res.data;
           if(code=='0'){
             const infos = Object.assign({},row,data);
-            this.$router.push({name:'AddCombinQuestion',params:{isEdit:true,data:infos}});
+            const pam = this.searched?{currentPage:this.currentPage,
+              filter:this.filter}:{currentPage:this.currentPage};
+            this.$router.push({name:'AddCombinQuestion',params:Object.assign(pam,{[isCopy?'isCopy':'isEdit']:true,data:infos})});
           }else{
             this.$message({
               message: msg,
@@ -169,10 +189,18 @@
       },
       currentChange(next) {
         this.currentPage = next;
-        this.getDataList();
+        this.getDataList(true);
       },
-      getFilterItems() {
-        const param = {
+      getFilterItems(isTurnPage) {
+        //翻页时筛选条件没点确定则清空
+        if(isTurnPage&&!this.searched){
+          this.filter = {
+            tagType: [], //标签类型
+            tagAdscription: '', //标签归属
+            tagSysName: '', //标签系统名称
+          }
+        };
+        let param = {
           tagTypeList: this.filter.tagType[0] ? this.filter.tagType: [4,6],
           current: this.currentPage,
           size: this.pageSize,
@@ -210,6 +238,18 @@
         this.showConfirmDialog('是否删除该填写单?',()=>{
           api.questionDel(param).then((res)=>{
             if(res.data.code=='0'){
+              if(!this.searched){
+                //未点确认时清空搜索条件
+                this.filter={
+                  tagType: [], //标签类型
+                  tagAdscription: '', //标签归属
+                  tagSysName: '', //标签系统名称
+                };
+              }
+              if(this.list.length==1){
+                //当前在最后一页且只有一条数据时,删除后跳到前一页
+                this.currentPage = this.currentPage===1?1:this.currentPage-1;
+              }
               this.getDataList();
               this.warning(res.data.msg || '操作成功','success');
             }else{

+ 28 - 14
src/components/preTreat/PubIndeptQa.vue

@@ -53,7 +53,7 @@
             >
                 <el-select
                         v-model="form.region12"
-                        :disabled="!form.region1||!!editData.id"
+                        :disabled="!form.region1||isEdit"
                         @change="sendData"
                 >
                     <el-option
@@ -100,6 +100,19 @@
                         @change="sendData"
                 ></el-input>
             </el-form-item>
+          <el-form-item  v-if="qaType =='1'&& form.region1 == '1' && form.region2 != '4'">
+            <span
+                  v-if="qaType =='1' && form.region1 == '1'  && form.region2 != '4'"
+                >
+                   <el-checkbox v-model="form.required"  label="必填" true-label="1" false-label="0"  @change="sendData"></el-checkbox>
+                </span>
+                <span
+                 class = "flagBox"
+                  v-if="qaType =='1' &&form.region1=='1'&&form.region2=='1'"
+                >
+                   <el-checkbox v-model="form.specFlag" label="拼接到主诉" true-label="1" false-label="0"  @change="sendData"></el-checkbox>
+                </span>
+          </el-form-item>
             <el-form-item
                     v-if="qaType==2"
                     label="填写单患者界面展示通俗内容:"
@@ -179,6 +192,13 @@
                     <el-button slot="trigger" size="small" type="primary">上传图片</el-button>
                 </el-upload>
             </el-form-item>
+            <el-form-item
+                    v-if="qaType==2&&form.region1=='1'&&form.region2=='4'"
+                    label="医学教育说明:"
+                    prop="explains"
+            >
+                <el-input type="textarea" @input="sendData" v-model="form.explains" style="width: 500px;"></el-input>
+            </el-form-item>
         </el-form>
     </div>
 </template>
@@ -207,7 +227,7 @@
 // 补充内容(val:52):单选(val:1)、多选(val:2)、多列填写(val:3)、输入框(val:6)、数字输入框(val:7)、文本域(val:5)
 
   export default {
-    props:['editData','qaType'],      //qaType:独立1/组合2填写单
+    props:['editData','qaType','isEdit'],      //qaType:独立1/组合2填写单
     data() {
       var validatePass1 = (rule, value, callback) => {
         this.validateSystomName(value,callback,1)
@@ -276,13 +296,15 @@
           region9: '200',         //最大年龄
           region12: '0',        //是否为主要内容
           region13:'',          //上传图片
+          specFlag:'0',         //拼接到主诉
+          required: '0',        //必填
         },
         //isNeedSearch: false, //是否需要查询(系统名称)
         imgList:[],
         showFileList:false,
         uploadUrl:config.urls.uploadImg,        //图片上传地址
         labelTypesMaps: {       // 归属和填写单类型限制
-          '1':['1','2','3','5','6','7'], //症状情况
+          '1':['1','2','3','5','6','7','8'], //症状情况
           '51':['1','2','3','4','5','6','7'],    //诊疗情况
           '3':['1','2','3','5','6','7'],         //其他史
           '52':['1','2','3','5','6','7']            //补充内容
@@ -570,17 +592,6 @@
     .el-message-box__btns .el-button--default {
         color: #606266 !important;
     }
-    .cancelColor {
-        color: #22ccc8 !important;
-    }
-    .changeTips {
-        position: absolute;
-        left: 220px;
-    // min-width: 300px;
-        width: 200%;
-        color: #ea7777;
-        font-size: 12px;
-    }
     }
     .el-upload-list{
         float: left;
@@ -588,5 +599,8 @@
     .upload-hide .el-upload--picture{
         display: none;
     }
+    .flagBox {
+      margin-left: 20px;
+    }
 </style>
 

+ 62 - 28
src/components/preTreat/PubSelect.vue

@@ -3,12 +3,12 @@
         <el-form>
             <div class="operation-row">
                 <el-checkbox-group size="small">
-                    <el-checkbox-button :label="0" :disabled="disableBtn" @change="handlePlaceholder(0)">文字输入框占位符</el-checkbox-button>
+                    <el-checkbox-button :label="0" v-if="type!=8" :disabled="disableBtn" @change="handlePlaceholder(0)">文字输入框占位符</el-checkbox-button>
                 </el-checkbox-group>
                 <el-checkbox-group size="small">
-                    <el-checkbox-button :label="0" :disabled="disableBtn" @change="handlePlaceholder(1)">数字输入框占位符</el-checkbox-button>
+                    <el-checkbox-button :label="0" v-if="type!=8" :disabled="disableBtn" @change="handlePlaceholder(1)">数字输入框占位符</el-checkbox-button>
                 </el-checkbox-group>
-                <el-checkbox-group size="small" v-if="type==2">
+                <el-checkbox-group size="small" v-if="type==2" v-model="checkedExc">
                     <el-checkbox-button :label="0" @change="handleExclu">互斥项</el-checkbox-button>
                 </el-checkbox-group>
                 <el-button type="danger" size="small" class="del" @click="delRow">删除</el-button>
@@ -19,6 +19,7 @@
                     <span><i>*</i>填写单医生界面展示标准内容</span>
                     <span>填写单患者界面展示通俗内容</span>
                 </el-col>
+                <p class="static-tip" v-if="type==8">默认展示有/无</p>
                 <el-col v-for="(it,i) in rows" :key="i">
                     <div class="inps">
                         <el-input v-model="rows[i].name"
@@ -42,11 +43,11 @@
                 <el-col v-for="(it,i) in rows" :key="i">
                     <div class="inps">
                         <el-input v-model="rows[i].name"
-                                  v-bind:class="{select:focusOn==i}"
+                                  v-bind:class="{'red':noHolder.indexOf(i)!==-1, 'select':focusOn==i}"
                                   @focus="selectRow(i,'name')"
                                   ref = "inputName"
                                   @input="HandleInputName(i, rows[i].name,true)"
-                                  @blur="emitValues"></el-input>
+                                  @blur="emitValues(i)"></el-input>
                     </div>
                     <el-tag v-if="it.exclusion" type="info" size="mini">互斥项</el-tag>
                 </el-col>
@@ -57,6 +58,22 @@
 </template>
 <style lang="less">
     @import "../../less/common.less";
+    .main-area{
+        position: relative;
+    }
+    .main-area .static-tip{
+        border:1px solid #dcdfe6;
+        height: 38px;
+        width: 150px;
+        position: absolute;
+        top:29px;
+        left: -150px;
+        line-height: 38px;
+        text-align: center;
+    }
+    .main-area .el-col .el-input.red .el-input__inner{
+        border-color: red;
+    }
     .el-checkbox-button--small .el-checkbox-button__inner{
         font-size: 14px;
     }
@@ -86,7 +103,7 @@
         margin-left: 150px;
     }
     .tip {
-        color: #22ccc8;
+        color: #48C5D7;
     }
     }
     .main-area{
@@ -146,9 +163,12 @@
     data(){
       return {
         rows:[...initRows],
+        checkedExc:false,
         focusOn:-1,         //聚焦的行index
         focusName:'name',        //是否聚焦医生界面输入框
         disableBtn:false,       //占位符是否禁用
+        noHolder:'',            //是否有占位符-仅多列使用
+        msgTimer:null,          //占位符必填提示延时
       }
     },
     mounted(){
@@ -163,20 +183,13 @@
         this.initData();
       }
     },
-    computed:{
-      showTag:function(){
-        return function(it){
-          let name = Object.keys(this.maps).find((item)=>{
-            return it[item];
-          });
-          return this.maps[name];
-        }
-      },
-    },
     watch: {
       /*ascription(newVal, preVal) {        //永远检测不到,因为归属修改时类型被清空,本组件被销毁
         this.rows = [...utils.getInitRow(initRow,4)];
       },*/
+      focusOn(newVal){
+        this.checkedExc = this.rows[newVal].exclusion===1;
+      },
       type() {
         this.initData();
       },
@@ -203,6 +216,7 @@
       },
       handlePlaceholder(type){          //占位符类型,type=0文本输入框,type=1数字输入框
         const i = this.focusOn;
+        clearTimeout(this.msgTimer);
         if(i==-1){
           this.$message({
             message: '请先选中要操作的行',
@@ -213,9 +227,12 @@
         }
         const maps = {0:'${input_输入}',1:'${number_输入}'};
         const key = this.focusName;
-        this.rows[i][key] = this.rows[i][key]+maps[type];
+        this.noHolder = this.noHolder.replace(','+i,'');
+        this.rows[i].name = this.rows[i].name+maps[type];
+        if(this.type!='3'){
+          this.rows[i].description = this.rows[i].description+maps[type];
+        }
         this.disableBtn = true;
-        //this.rows[i].description = this.rows[i].description+maps[type];
       },
       handleExclu(){
         const i = this.focusOn;
@@ -227,6 +244,10 @@
           });
           return ;
         }
+        if(this.rows[i].exclusion===1){
+          this.rows[i].exclusion=0;
+          return ;
+        }
         this.rows.map((it,x)=>{
           if(x===i){
             it.exclusion = 1;
@@ -235,24 +256,37 @@
           }
         });
       },
-      emitValues(i,type,flag){
-        if(typeof i =='number'&&this.focusOn == -1){
-          this.$message({
-            message: '请先选择要操作的行',
-            type: 'warning',
-            showClose: true,
-          });
-          return;
+      emitValues(i){
+        if(typeof i ==='number'){
+          const reg = /(\$\{number_\S*?\})|(\$\{input_\S*?\})/g;
+          const name = this.rows[i].name;
+          if(name&&!reg.test(name)){
+            this.noHolder = this.noHolder.indexOf(i)!=-1?this.noHolder:this.noHolder+","+i;
+            const that = this;
+            this.msgTimer = setTimeout(function(){
+              that.$message({
+                message: '请添加数字输入框或者文本输入框',
+                type: 'warning',
+                showClose: true,
+              });
+            },500);
+
+            this.$emit('pushValues',this.rows);
+            return;
+          }
+          this.noHolder = this.noHolder.replace(','+i,'');
         }
         const items = this.rows;
         this.$emit('pushValues',items);
       },
       HandleInputName(i, name, isName) {
-        const pureName=name.replace(/(\$\{number_\S*?\})|(\$\{input_\S*?\})/g,'');
-        const hasPlace = /(\$\{number_\S*?\})|(\$\{input_\S*?\})/g.test(name);
+        const reg = /(\$\{number_\S*?\})|(\$\{input_\S*?\})/g;
+        const pureName=name.replace(reg,'');
+        const hasPlace = reg.test(name);
         if(hasPlace&&this.disableBtn==false){
           this.disableBtn = true;
         }else if(!hasPlace&&this.disableBtn==true){
+          this.rows[i][isName?'description':'name'] = this.rows[i][isName?'description':'name'].replace(reg,'');
           this.disableBtn = false;
         }
         if(pureName.length > 30) {

+ 51 - 11
src/components/preTreat/QuestionModules.vue

@@ -6,7 +6,7 @@
                     <el-input size="mini" v-model="filter.name" placeholder="模板名称" clearable></el-input>
                 </el-form-item>
                 <el-form-item label="归属:">
-                    <el-select size="mini" v-model="filter.type" @change="getValue"  placeholder="归属" clearable>
+                    <el-select size="mini" v-model="filter.type"  placeholder="归属" clearable>
                         <el-option v-if="item.val!=6&&item.val!=7&&item.val!=8&&item.val!=9&&item.val!=10&&item.val!=21&&item.val!=22" v-for="item in Adscriptions" :label="item.name" :value="item.val" :key="item.id" ></el-option>
                     </el-select>
                 </el-form-item>
@@ -16,7 +16,7 @@
                     </el-select>
                 </el-form-item>
                 <el-form-item label="归属科室:" v-if="filter.moduleType==1">
-                    <el-select size="mini" v-model="filter.relationId" @change="getValue"  placeholder="归属" clearable>
+                    <el-select size="mini" v-model="filter.relationId"  placeholder="归属" clearable>
                         <el-option v-for="item in deptList" :label="item.name" :value="item.conceptId" :key="item.conceptId" ></el-option>
                     </el-select>
                 </el-form-item>
@@ -104,6 +104,7 @@
       return {
         list: [],
         tagTypes: [],
+        searched:false,
         Adscriptions: [],
         deptList:[],
         filter: {
@@ -120,10 +121,21 @@
     created() {
       this.getDropList();
     },
+    watch:{
+      'filter':{
+        handler:function(){
+          this.searched = false;
+        },
+        deep:true
+      }
+    },
+    beforeRouteEnter(to, from, next){
+      next(vm => {
+        //const pm = to.param;
+        Object.assign(vm,to.params);
+      })
+    },
     methods: {
-      getValue(val) {
-        console.log('changeVal', val, this.filter.tagAdscription)
-      },
       getDropList() {
         api.getPreTypeList().then((res) =>{
           this.getDataList();
@@ -148,8 +160,9 @@
           }
         });
       },
-      getDataList() {
-        const param = this.getFilterItems();
+      getDataList(isTurnPage) {
+        const param = this.getFilterItems(isTurnPage);
+        this.searched = true;
         api.getModuleList(param).then((res) => {
           if (res.data.code === '0') {
             const list = res.data.data&&res.data.data.records?[...res.data.data.records]:[];
@@ -182,14 +195,19 @@
         this.getDataList();
       },
       addModule() {
-        this.$router.push({path:'LT-YWZSJWH-TJMBWH'});
+        const pam = this.searched?{currentPage:this.currentPage,
+          filter:this.filter}:{currentPage:this.currentPage};
+        this.$router.push({name:'AddQuestionModules',
+          params:pam});
       },
       modifyModule(row) {
         api.getModuleDetail({moduleId:row.id,type:row.type}).then((res)=>{
           const {code,data,msg} = res.data;
           if(code=='0'){
             const item = Object.assign({},row,data);
-            this.$router.push({name:'AddQuestionModules',params:{isEdit:true,data:item}});
+            const pam = this.searched?{currentPage:this.currentPage,
+              filter:this.filter}:{currentPage:this.currentPage};
+            this.$router.push({name:'AddQuestionModules',params:Object.assign(pam,{isEdit:true,data:item})});
           }else{
             this.$message({
               message: msg,
@@ -200,9 +218,18 @@
       },
       currentChange(next) {
         this.currentPage = next;
-        this.getDataList();
+        this.getDataList(true);
       },
-      getFilterItems() {
+      getFilterItems(isTurnPage) {
+        //翻页时筛选条件没点确定则清空
+        if(isTurnPage&&!this.searched){
+          this.filter = {
+            name: '', //模板名称
+            type: '', //模板归属
+            moduleType: '', //模板类型
+            relationId:'',  //归属科室
+          }
+        };
         const param = {
           name: this.filter.name,
           type:this.filter.type,
@@ -241,6 +268,19 @@
         this.showConfirmDialog('是否删除该模板?',()=>{
           api.delModule(param).then((res)=>{
             if(res.data.code=='0'){
+              if(!this.searched){
+                //未点确认时清空搜索条件
+                this.filter={
+                  name: '', //模板名称
+                  type: '', //模板归属
+                  moduleType: '', //模板类型
+                  relationId:'',  //归属科室
+                };
+              }
+              if(this.list.length==1){
+                //当前在最后一页且只有一条数据时,删除后跳到前一页
+                this.currentPage = this.currentPage===1?1:this.currentPage-1;
+              }
               this.getDataList();
               this.warning(res.data.msg || '操作成功','success');
             }else{

+ 30 - 5
src/components/preTreat/QuestionTagGroup.vue

@@ -1,7 +1,7 @@
 <template>
     <div class="symptomTagGroupWrapper commomSymptom clearfix">
         <div class="operation-row">
-            <el-checkbox-group size="small" v-if="qaType==2">
+            <el-checkbox-group size="small" v-if="qaType==2&&type!='4'" v-model="checkedExc">
                 <el-checkbox-button :label="0" @change="handleExclu">互斥项</el-checkbox-button>
             </el-checkbox-group>
         </div>
@@ -21,11 +21,14 @@
             <li v-for="(item, index) in leftTagsList"
                 class = "tagItem"
                 :key='item.id'
-                :title="'[ '+item.tagName+' ]'"
+                :title="'[ '+item.tagName+' ]('+sex[item.sexType]+(item.required?'、必':'')+(item.specFlag?'、跟主':'')+')'"
                 :style="getStyle(item)?styles:null"
                 @click='selectLeftTag(item, index, $event)'
             >
-                <p class="tagName ellipsis" >{{item.tagName}} </p>
+                <p class="ellipsis" >
+                    <span class="tagName">{{item.tagName}}</span>
+                    <span>({{sex[item.sexType]}}{{item.required?'、必':''}}{{item.specFlag?'、跟主':''}})</span>
+                </p>
             </li>
         </ul>
       </div>
@@ -43,7 +46,10 @@
                 :style="getStyle2(item)?styles:null"
                 @click='selectRightTag(item)'
             >
-                <p class="tagName  ellipsis" :title="'[ '+item.tagName+' ]'">{{item.tagName}} </p>
+                <p class="ellipsis" :title="'[ '+item.tagName+' ]('+sex[item.sexType]+(item.required?'、必':'')+(item.specFlag?'、跟主':'')+')'">
+                    <span class="tagName">{{item.tagName}}</span>
+                    <span>({{sex[item.sexType]}}{{item.required?'、必':''}}{{item.specFlag?'、跟主':''}})</span>
+                </p>
                 <el-tag class="exclu" v-if="item.exclusionType==1" type="info" size="mini">互斥项</el-tag>
             </li>
         </ul>
@@ -64,11 +70,17 @@ export default {
     props: ['ascription','sexType','options','type','qaType','relationId'],
     data() {
         return {
+            checkedExc:false,
             leftTagsList: [],
             selectLeftTagsList: [],
             rightTagsList: [],
             selectRightTagsList: [],
             searchVal: '',
+            sex:{
+              1:'男',
+              2:'女',
+              3:'通'
+            },
             styles:{
                 background:'#eae7e7'
             },
@@ -106,6 +118,12 @@ export default {
         relationId(newVal, preVal){
           this.ifReflashTagList(newVal, preVal);
         },
+        'selectRightTagsList':{
+          handler:function(newVal){
+            this.checkedExc = newVal[0]&&newVal[0].exclusionType===1;
+          },
+          deep:true
+        }
     },
     methods: {
         handleExclu(){
@@ -119,7 +137,11 @@ export default {
             }
             const arr = this.rightTagsList.map((it)=>{
               if(it.id==this.selectRightTagsList[0].id){
-                it.exclusionType=1;
+                if(it.exclusionType===1){
+                  it.exclusionType = 0
+                }else{
+                  it.exclusionType=1;
+                }
               }else{
                 it.exclusionType=0;
               }
@@ -363,6 +385,9 @@ export default {
         min-height: 300px;
         padding: 10px 0;
     }
+    .tagName{
+        margin-right: 10px;
+    }
     .tagName:before {
         content: '['
     }

+ 69 - 11
src/components/preTreat/SimpleQuestion.vue

@@ -3,7 +3,7 @@
         <crumbs title="独立填写单维护">
             <el-form :inline="true" class="demo-form-inline">
                 <el-form-item label="归属:">
-                    <el-select size="mini" v-model="filter.tagAdscription" @change="getValue"  placeholder="归属" clearable>
+                    <el-select size="mini" v-model="filter.tagAdscription"  placeholder="归属" clearable>
                         <el-option v-if="item.val!=6&&item.val!=7&&item.val!=8&&item.val!=9&&item.val!=10&&item.val!=21&&item.val!=22" v-for="item in Adscriptions" :label="item.name" :value="item.val" :key="item.id" ></el-option>
                     </el-select>
                 </el-form-item>
@@ -65,10 +65,12 @@
                         :resizable = "false"
                         prop="operate"
                         label="操作"
-                        width="120">
+                        width="140">
                     <template slot-scope="scope">
                         <el-button  @click="modifyIndeptTag(scope.row)" type="text" size="small">修改</el-button>
                         <span style="margin:0 3px;">|</span>
+                        <el-button  @click="copyIndeptTag(scope.row)" type="text" size="small">复制</el-button>
+                        <span style="margin:0 3px;">|</span>
                         <el-button @click="showDelDialog(scope.row)" class="delete" type="text" size="small">删除</el-button>
                     </template>
                 </el-table-column>
@@ -96,6 +98,7 @@
         tagTypes: [],
         Adscriptions: [],
         tagTypesList:[],
+        searched:false,
         filter: {
           tagType: [], //标签类型
           controlType: [],
@@ -110,10 +113,21 @@
     created() {
       this.getDropList();
     },
+    watch:{
+      'filter':{
+        handler:function(){
+          this.searched = false;
+        },
+        deep:true
+      }
+    },
+    beforeRouteEnter(to, from, next){
+      next(vm => {
+        //const pm = to.param;
+        Object.assign(vm,to.params);
+      })
+    },
     methods: {
-      getValue(val) {
-        console.log('changeVal', val, this.filter.tagAdscription)
-      },
       getDropList() {
         api.getPreTypeList().then((res) =>{
           this.getDataList();
@@ -126,8 +140,9 @@
 
         })
       },
-      getDataList() {
-        const param = this.getFilterItems();
+      getDataList(isTurnPage) {
+        const param = this.getFilterItems(isTurnPage);
+        this.searched = true;
         api.getQuestionList(param).then((res) => {
           const list = [...res.data.data.records];
           for (var i = 0; i < list.length; i++) {
@@ -152,14 +167,35 @@
         this.getDataList();
       },
       addIndeptTag() {
-        this.$router.push({path:'LT-YWZSJWH-TJDLTXD'})
+        const pam = this.searched?{currentPage:this.currentPage,
+            filter:this.filter}:{currentPage:this.currentPage};
+        this.$router.push({name:'AddSimpleQuestion',
+                            params:pam})
+      },
+      copyIndeptTag(row){
+        api.questionDetail({id:row.id}).then((res)=>{
+          const {code,data,msg} = res.data;
+          if(code=='0'){
+            const item = Object.assign({},row,data);
+            const pam = this.searched?{currentPage:this.currentPage,
+              filter:this.filter}:{currentPage:this.currentPage};
+            this.$router.push({name:'AddSimpleQuestion',params:Object.assign(pam,{isCopy:true,data:item})});
+          }else{
+            this.$message({
+              message: msg,
+              type: 'warning'
+            });
+          }
+        });
       },
       modifyIndeptTag(row) {
         api.questionDetail({id:row.id}).then((res)=>{
           const {code,data,msg} = res.data;
           if(code=='0'){
             const item = Object.assign({},row,data);
-            this.$router.push({name:'AddSimpleQuestion',params:{isEdit:true,data:item}});
+            const pam = this.searched?{currentPage:this.currentPage,
+              filter:this.filter}:{currentPage:this.currentPage};
+            this.$router.push({name:'AddSimpleQuestion',params:Object.assign(pam,{isEdit:true,data:item})});
           }else{
             this.$message({
               message: msg,
@@ -171,14 +207,23 @@
       },
       currentChange(next) {
         this.currentPage = next;
-        this.getDataList();
+        this.getDataList(true);
         // if (this.cacheData[next]) {       //如果已请求过该页数据,则使用缓存不重复请求
         //     this.list = this.cacheData[next];
         // } else {
         //     this.getDataList();
         // }
       },
-      getFilterItems() {
+      getFilterItems(isTurnPage) {
+        //翻页时筛选条件没点确定则清空
+        if(isTurnPage&&!this.searched){
+          this.filter = {
+            tagType: [], //标签类型
+            controlType: [],
+            tagAdscription: '', //标签归属
+            tagSysName: '', //标签系统名称
+          }
+        };
         const param = {
           tagTypeList: [1],
           current: this.currentPage,
@@ -218,6 +263,19 @@
         this.showConfirmDialog('是否删除该填写单?',()=>{
           api.questionDel(param).then((res)=>{
             if(res.data.code=='0'){
+              if(!this.searched){
+                //未点确认时清空搜索条件
+                this.filter={
+                    tagType: [], //标签类型
+                    controlType: [],
+                    tagAdscription: '', //标签归属
+                    tagSysName: '', //标签系统名称
+                };
+              }
+              if(this.list.length==1){
+                //当前在最后一页且只有一条数据时,删除后跳到前一页
+                this.currentPage = this.currentPage===1?1:this.currentPage-1;
+              }
               this.getDataList();
               this.warning(res.data.msg || '操作成功','success');
             }else{

+ 8 - 1
src/less/common.less

@@ -16,7 +16,7 @@
 @borderWidth: 2px;
 
 /*朗通后台基本颜色*/
-@adminBase: #22ccc8;
+@adminBase: #48C5D7;
 @icssBorder: #c0c4cc;
 @icssHeight:240px;
 
@@ -115,6 +115,13 @@
 .el-button--mini, .el-button--mini.is-round {
   padding: 5px 15px 4px;
 }
+.el-button--warning.el-button--mini{
+  background: @adminBase;
+  border:1px @adminBase solid;
+}
+.el-form-item.is-success .el-input__inner, .el-form-item.is-success .el-input__inner:focus, .el-form-item.is-success .el-textarea__inner, .el-form-item.is-success .el-textarea__inner:focus{
+  border-color:@adminBase;
+}
 
 .el-table td {
   padding: 0;

+ 4 - 2
src/routes.js

@@ -150,6 +150,7 @@ export default [
         component: AuthedAdmin
       },
     	{
+    	  name:'organizationInfo',
     	  path: 'LT-KHZX-JGXX',//机构信息
         component: OrganizationInfo,
         meta:{
@@ -165,6 +166,7 @@ export default [
         component: ModifinedOrga
       },
       {
+        name:'superAdmin',
         path: 'LT-KHZX-CGXX',
         component: SuperAdmin
       },
@@ -190,9 +192,9 @@ export default [
       {path: 'LT-CPXGL', component: ProductLinesManage},
       {path: 'LT-CPXGL-TJCPX', component: AddProductLine,name:'editProductLine'},
       {path: 'LT-GRZX/CHANGE',component: ChangePwd}, //个人中心--修改密码
-      {path: 'LT-YXSJWH-BQZWH',component: LabelGroup}, //医学数据维护--标签组维护
+      {path: 'LT-YXSJWH-BQZWH',component: LabelGroup,name:'labelGroup'}, //医学数据维护--标签组维护
       {path:'LT-YXSJWH-TJBQZ',component:NoiseTemplate,name:'AddLabelGroup'},     //医学数据维护--标签组维护--添加标签组
-      {path:'LT-YXSJWH-KSWH',component:DeptInfo},     //医学数据维护--科室维护
+      {path:'LT-YXSJWH-KSWH',component:DeptInfo,name:'deptInfo'},     //医学数据维护--科室维护
       {path:'LT-YXSJWH-KSXQ',component:DeptInfoDetail,name:'DeptInfoDetail'},     //科室维护--详情
       {path:'LT-YXSJWH-TJKS',component:AddDeptInfo,name:'AddDeptInfo'},     //科室维护--添加
       {path:'LT-YXSJWH-DLLXBQWH',component:IndeptLabel,name:'IndeptLabel'},     //独立标签维护--详情

+ 2 - 2
vue.config.js

@@ -1,7 +1,7 @@
 const path = require('path');
 // const proxy_path = 'http://192.168.2.236:80';
-const proxy_path = 'http://192.168.2.241:88';
-// const proxy_path = 'http://192.168.2.236:88';
+// const proxy_path = 'http://192.168.2.241:88';
+const proxy_path = 'http://192.168.2.236:88';
 // const proxy_path = 'http://192.168.3.101:5050';
 // const proxy_path = 'http://192.168.3.117:5050';//周铁刚
 // const proxy_path = 'http://192.168.3.115:5050';