Jelajahi Sumber

标签组维护,诊断维护基本完成

Luolei 6 tahun lalu
induk
melakukan
f5b005a17d

+ 256 - 0
src/components/icss/DiagnosisList.vue

@@ -0,0 +1,256 @@
+<template>
+    <div>
+        <crumbs title="诊断标签维护" style="min-width: 980px">
+            <el-form :inline="true" class="demo-form-inline">
+                <!-- <el-form-item label="标签类型:">
+                    <el-select size="mini" v-model="filter.tagType[0]" placeholder="标签类型" clearable>
+                        <el-option v-for="item in tagTypes" :label="item.name" :value="item.val" :key="item.id"></el-option>
+                    </el-select>
+                </el-form-item> -->
+                <el-form-item label="诊断归属:">
+                    <el-select size="mini" v-model="filter.tagAdscription" @change="getValue"  placeholder="诊断归属" clearable>
+                        <el-option v-for="item in Adscriptions" :label="item.name" :value="item.val" :key="item.id"></el-option>
+                    </el-select>
+                </el-form-item>
+                <el-form-item label="标签系统名称:">
+                    <el-input size="mini" v-model="filter.tagSysName" placeholder="标签系统名称" clearable></el-input>
+                </el-form-item>
+                <el-form-item>
+                    <el-button size="mini" @click="filterDatas">确认</el-button>
+                    <el-button size="mini" type="warning" @click="addTagGroup">添加诊断标签</el-button>
+                </el-form-item>
+            </el-form>
+        </crumbs>
+        <div class="contents">
+            <el-table
+                :data="list"
+                border
+                style="width: 100%">
+                <el-table-column
+                    :resizable = "false"
+                    type="index"
+                    :index = 'indexMethod'
+                    label="编号"
+                    width="60">
+                </el-table-column>
+                <el-table-column
+                    :resizable = "false"
+                    prop="gmtModified"
+                    label="操作时间"
+                    width="180">
+                </el-table-column>
+                <el-table-column
+                    :resizable = "false"
+                    prop="typeCn"
+                    label="诊断归属">
+                </el-table-column>
+                <el-table-column
+                    :resizable = "false"
+                    prop="tagTypeCn"
+                    label="标签类型">
+                </el-table-column>
+                <el-table-column
+                    :resizable = "false"
+                    prop="tagName"
+                    label="标签系统名称">
+                </el-table-column>
+                <el-table-column
+                    :resizable = "false"
+                    prop="modifier"
+                    label="操作人">
+                </el-table-column>
+                <el-table-column
+                    :resizable = "false"
+                    prop="operate"
+                    label="操作">
+                    <template slot-scope="scope">
+                        <el-button  @click="modifyTagGroup(scope.row)" type="text" size="small">修改</el-button>
+                        <el-button @click="showDelDialog(scope.row.id,scope.row.type)" class="delete" type="text" size="small">删除</el-button>
+                    </template>
+                </el-table-column>
+            </el-table>
+        <div class="pagination">
+            <el-pagination v-if="total>pageSize"
+                       :current-page.sync="currentPage"
+                       @current-change="currentChange"
+                       background
+                       :page-size="pageSize"
+                       layout="total,prev, pager, next, jumper"
+                       :total="total">
+            </el-pagination>
+        </div>
+        
+        </div>
+       <!--  <div class="pagination">
+           <el-pagination v-if="total>pageSize"
+                      :current-page.sync="currentPage"
+                      @current-change="currentChange"
+                      background
+                      :page-size="pageSize"
+                      layout="total,prev, pager, next, jumper"
+                      :total="total">
+           </el-pagination>
+       </div> -->
+        
+    </div>
+</template>
+
+<script>
+import api from '@api/icss.js';
+
+export default {
+    name: 'DiagnosisList',
+    data: function() {
+        return {
+            list: [],
+            tagTypes: [],
+            Adscriptions: [],   //标签归属列表
+            tagTypesList: [],   //标签类型列表
+            filter: {
+                tagType: [], //标签类型
+                tagAdscription: '', //标签归属
+                tagSysName: '', //标签系统名称
+            },
+            currentPage: 1,
+            pageSize: 10,
+            total: 0,
+        }
+    },
+    created() {
+        this.getDropList().then(() => {
+            this.getDataList()
+        })
+        
+    },
+    methods: {
+        getValue(val) {
+            console.log('changeVal', val, this.filter.tagAdscription)
+        },
+        getDropList() {
+            return api.getDropList().then((res) =>{
+                // console.log('dropList', res)
+                if(res.data.code === '0') {
+                    this.Adscriptions = res.data.data[7];
+                    this.tagTypes =  res.data.data[3];
+                    for (var i = 0; i < this.tagTypes.length; i++) {
+                        this.tagTypesList.push(this.tagTypes[i].val)
+                    }
+                }
+                 
+            })
+        },
+        getDataList() {
+            const param = this.getFilterItems();
+            api.getTagList(param).then((res) => {
+                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].disType == this.Adscriptions[z].val) {
+                            list[i].typeCn = this.Adscriptions[z].name
+                        }
+                    }
+                   
+                }
+                this.list = list;
+                this.total = res.data.data.total;
+            })
+        },
+        filterDatas() {
+            this.currentPage = 1;
+            this.getDataList();
+        },
+        addTagGroup() {
+            this.$router.push({path:'LT-YXSJWH-ZDBQTJ'})
+        },
+        modifyTagGroup(row) {
+            api.detailsTag({id:row.id}).then((res)=>{
+                const {code,data,msg} = res.data;
+                if(code=='0'){
+                    const item = Object.assign({},row,data);
+                    // console.log('item', item)
+                    this.$router.push({name:'DiagnosisTemplate',params:{isEdit:true,data:item}});
+                }else{
+                    this.$message({
+                    message: msg,
+                    type: 'warning'
+                    });
+                }
+            });
+        },
+        currentChange(next) {
+            this.currentPage = next;
+            this.getDataList();
+            // if (this.cacheData[next]) {       //如果已请求过该页数据,则使用缓存不重复请求
+            //     this.list = this.cacheData[next];
+            // } else {
+            //     this.getDataList();
+            // }
+        },
+        getFilterItems() {
+            const param = {
+                tagTypeList: ['9'],
+                current: this.currentPage,
+                size: this.pageSize,
+                type: '7',
+                disType:this.filter.tagAdscription,
+                tagName: this.filter.tagSysName,
+            };
+            return param;
+        },
+        indexMethod(index) {
+            return ((this.currentPage - 1) * this.pageSize) + index + 1;
+        },
+        getTagType(val) {
+            return val
+        },
+        warning(msg,type){
+          this.$message({
+            showClose: true,
+            message:msg,
+            type:type||'warning'
+          })
+        },
+        showConfirmDialog(msg,resolve){
+          this.$alert(msg, '提示', {
+            confirmButtonText: '确定',
+            type: 'warning'
+          }).then(() => {
+            resolve();
+          }).catch(() => {});
+        },
+        showDelDialog(id,type){
+          this.showConfirmDialog('是否删除该标签组?',()=>{
+            api.deleteTagGroup({ids:id,type:type}).then((res)=>{
+              if(res.data.code=='0'){
+                this.getDataList();
+                this.warning(res.data.msg || '操作成功','success');
+              }else{
+                this.warning(res.data.msg);
+              }
+            }).catch((error)=>{
+              this.warning(error);
+            })
+          });
+        }
+    }
+}
+</script>
+
+
+<style lang="less">
+    @import "../../less/admin.less";
+    .delete{
+       color: red;
+    }
+    .delete:hover {
+        color: red;
+    } 
+    .pagination {
+        min-width: 1010px;
+    }
+</style>

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

@@ -0,0 +1,525 @@
+<template>
+  <div class="PubTagGroupWrapper">
+    <el-form
+      class="groups"
+      :rules="rules"
+      ref="groups"
+      :model="form"
+      label-width="150px"
+    >
+      <el-form-item
+        label="选择归属:"
+        prop="region1"
+      >
+        <el-select
+          :disabled="true"
+          v-model="form.region1"
+          placeholder="请选择归属"
+          @change="(e)=>readyChangeSelect(e,1)"
+        >
+          <el-option
+            v-for="item in Adscriptions"
+            :label="item.name"
+            :value="item.val"
+            :key="item.id"
+          ></el-option>
+        </el-select>
+      </el-form-item>
+      <el-form-item
+        label="选择填写单类型:"
+        prop="region2"
+      >
+        <el-select
+          :disabled="true"
+          v-model="form.region2"
+          placeholder="请选择填写单类型"
+          @change="(e)=>readyChangeSelect(e,2)"
+        >
+          <el-option
+            v-for="item in labelTypes"
+            :label="item.name"
+            :value="item.val"
+            :key="item.id"
+          ></el-option>
+        </el-select>
+      </el-form-item>
+      <el-form-item
+        label="性别:"
+        prop="region7"
+      >
+        <el-select
+          v-model="form.region7"
+          :disabled="!!editData.id || !form.region1 || form.region2 == 11"
+          @change="(e)=>readyChangeSelect(e,3)"
+        >
+          <el-option
+            label="通用"
+            value="3"
+          ></el-option>
+          <el-option
+            label="男"
+            value="1"
+          ></el-option>
+          <el-option
+            label="女"
+            value="2"
+          ></el-option>
+        </el-select>
+      </el-form-item>
+      <el-form-item
+        label="标签系统名称:"
+        prop="region3"
+      >
+        <el-input
+          v-model="form.region3"
+          :disabled="!form.region1"
+          maxLength="30"
+          placeholder="请输入标签系统名称"
+          @change="sendData"
+        ></el-input>
+      </el-form-item>
+      <el-form-item
+        label="标签界面名称:"
+        prop="region4"
+      >
+        <el-input
+          v-model="form.region4"
+          :disabled="!form.region1"
+          maxLength="30"
+          placeholder="请输入标签界面名称"
+          @change="sendData"
+        ></el-input>
+      </el-form-item>
+      <el-form-item
+        label="诊断归属:"
+        prop="region2"
+      >
+        <el-select
+          :disabled="!!editData.id"
+          v-model="form.region13"
+          placeholder="请选择诊断归属"
+          @change="(e)=>readyChangeSelect(e,2)"
+        >
+          <el-option
+            v-for="item in DiagnosislabelTypes"
+            :label="item.name"
+            :value="item.val"
+            :key="item.id"
+          ></el-option>
+        </el-select>
+      </el-form-item>
+      <!-- <el-form-item
+        label="选择项之间链接:"
+        prop="region5"
+      >
+        <el-input
+          v-model="form.region5"
+          maxLength="30"
+          placeholder="请输入选择项之间链接"
+          @change="sendData"
+        ></el-input>
+      </el-form-item> -->
+      <!-- <el-form-item
+        label="能否当项目检索:"
+        prop="region6"
+      >
+        <el-select
+          v-model="form.region6"
+          :disabled="!form.region1 || form.region2 == 11"
+          @change="sendData"
+        >
+          <el-option
+            label="不可以"
+            value="1"
+          ></el-option>
+          <el-option
+            label="可以"
+            value="0"
+          ></el-option>
+        </el-select>
+      </el-form-item> -->
+      <el-form-item
+        v-if="form.region1 == 1 && form.region2 ==4"
+        label="是否为症状"
+        prop="region12"
+      >
+        <el-select
+          v-model="form.region12"
+          @change="sendData"
+        >
+          <el-option
+            label="是"
+            value="0"
+          ></el-option>
+          <el-option
+            label="不是"
+            value="1"
+          ></el-option>
+        </el-select>
+      </el-form-item>
+      <el-form-item
+        label="年龄:"
+        prop="region8"
+        class="ages"
+      >
+        <el-input
+          v-model.number="form.region8"
+          :disabled="!form.region1 || form.region2 == 11"
+          ref="valage1"
+          type="number"
+          @input="sendData"
+        ></el-input>
+      </el-form-item> ~
+      <el-form-item
+        prop="region9"
+        class="ages maxAges"
+      > 
+        <el-input
+          v-model.number="form.region9"
+          :disabled="!form.region1 || form.region2 == 11"
+          type="number"
+          ref="valage2"
+          @input="sendData"
+        ></el-input>
+      </el-form-item>
+      <el-form-item class="verticalMiddle" label="选择子项时是否复制主项标签:" prop="region10" v-if="form.region2 == 6">
+        <el-select v-model="form.region10" :disabled="!form.region1 || form.region2 == 11">
+          <el-option label="不可以" value="0"></el-option>
+          <el-option label="可以" value="1"></el-option>
+        </el-select>
+      </el-form-item>
+      <el-form-item label="是否显示加号:" prop="region11" v-if="form.region2 == 2 || form.region2 == 3">
+        <el-select v-model="form.region11" :disabled="!form.region1 || form.region2 == 11">
+          <el-option label="显示" value="1"></el-option>
+          <el-option label="不显示" value="0"></el-option>
+        </el-select>
+      </el-form-item>
+    </el-form>
+  </div>
+</template>
+<script>
+import api from '@api/icss.js';
+import utils from '@api/utils.js';
+
+export default {
+  props:['editData'],
+  data() {
+    var validatePass2 = (rule, value, callback) => {
+        const editData = this.$props.editData;
+        if(editData.id && value == editData.tagName){ //修改系统名称没变就不再校验
+          callback();    
+        }else{
+          this.validateSystomName(value,callback)
+        }
+    };
+    return {
+      form: {
+        region1: '7',    //归属
+        region2: '9',     //填写单类型
+        region3: '',      //系统名称
+        region4: '',      //界面名称
+        region5: '',      //选项之间的链接
+        // region6: '0',      //是否可以检索
+        region7: '3',       //性别
+        region8: '0',          //最小年龄
+        region9: '200',         //最大年龄
+        region10: '1',        //是否复制主标签
+        region11: '0',       //是否复制当前模块
+        region12:'1',        //是否为症状
+        region13:'',        //诊断归属
+        tagPool:[],          //标签池数据
+        order:[],            //排序方式
+        tipLis:[],           //提示列表
+      },
+      labelTypesMaps: {       //// 归属和填写单类型限制
+        '7':['9'],
+      },
+      rules: {
+        region1: [
+          { required: true, message: '请选择归属', trigger: 'change' }
+        ],
+        region2: [
+          { required: true, message: '请选择填写单类型', trigger: 'change' }
+        ],
+        region3: [
+          { required: true, message: '请输入标签系统名称', trigger: 'change' },
+          { validator: validatePass2, trigger: 'blur' },
+        ],
+        region4: [
+          { required: true, message: '请输入标签界面名称', trigger: 'change' }
+        ],
+        region6: [
+          { required: true, message: '请输入能否当项目检索', trigger: 'change' }
+        ],
+        region7: [
+          { required: true, message: '请选择性别', trigger: 'change' }
+        ],
+        region8: [
+          { required: true, message: '请输入最小年龄', trigger: 'change' }
+        ],
+        region9: [
+          { required: true, message: '请输入最大年龄', trigger: 'change' }
+        ],
+        region10: [
+          { required: true, message: '选择子项时是否复制主项标签', trigger: 'change' }
+        ],
+        region11: [
+          { required: true, message: '是否复制当前模块', trigger: 'change' }
+        ],
+        region12: [
+          { required: true, message: '是否为症状', trigger: 'change' }
+        ],
+        region13: [
+          { required: true, message: '请选择诊断归属', trigger: 'change' }
+        ],
+      },
+      tmpSex: '通用',
+      tmpOwn: '',
+      tmpType: '',
+      Adscriptions: [
+        {
+          id:6,
+          name:"诊断",
+          remark:"标签归属",
+          val:"7",
+        }
+      ],
+      labelTypes: [],
+      DiagnosislabelTypes: [],
+      labelTypesList: [],
+      tagTypes: [],        //标签池数据
+      type:'',
+      systom:null,      //标签系统名称存在与否
+    }
+  },
+  computed: {
+    newType() {
+      return this.form.region1;
+    },
+  },
+  mounted() {
+    const editData = this.$props.editData;
+    if(editData.id){
+      const trans = utils.transformKeys(editData,2); //(2是标签组类型)
+      // console.log('editData1', editData)
+      this.form = Object.assign({},this.form,trans);
+    }
+    this.$emit('submitForm', 'groups', false);
+    this.getDropList();
+    this.$emit('changeVal', this.form, false)
+  },
+  watch: {
+    newType(nextVal, prevVal) {
+      this.tmpOwn = prevVal;
+    },
+  },
+  methods: {
+    getDropList() {
+      return api.getDropList().then((res) => {
+        if (res.data.code === '0') {
+          this.AdscriptionsList = res.data.data[1];
+          this.labelTypesList = res.data.data[2];
+          this.form.order = res.data.data[5];
+          this.form.tipLis = res.data.data[6];
+          this.labelTypes = this.labelTypesList;
+          this.DiagnosislabelTypes = res.data.data[7];
+          // console.log('labelTypes', this.labelTypes)
+          this.Adscriptions = this.AdscriptionsList.filter(item => Object.keys(this.labelTypesMaps).indexOf(item.val) > -1);
+        }
+      })
+    },
+    searchTagList() {
+      const editData = this.$props.editData;
+      if(editData.id){
+        return;
+      }
+      let region1 = this.form.region1, region2 = this.form.region2;
+      let paramFst = !!region2 ? api.getGroupParams(region2): {};
+      let paramSec = {
+        "type": region1,
+        "sexType": this.form.region7,
+        "tagName":'',
+        "notIds": [],
+      }
+      // console.log(paramFst,paramSec,7787)
+      let params = Object.assign({},paramFst,paramSec)
+      api.searchTagList(params).then((res) => {
+        if (res.data.code === '0') {
+          this.form.tagPool = res.data.data
+        }
+      })
+    },
+    validateSystomName(name,callback) {
+      if(this.form.region3.trim() == ''){ return }
+      let param = {
+        "existName": this.form.region3,     
+        "type": this.form.region1,  
+        "notTagType":[8,10],        //去掉文字标签查重
+      }
+      api.validateSystomName(param).then((res) => {
+        if (res.data.code === '0') {
+          if(res.data.data && res.data.data.length != 0){
+            callback(new Error('该系统名称已存在'));
+          }else{
+            callback();
+          }
+        }
+      })
+    },
+    sendData() {
+      this.$emit('changeVal', this.form, false)
+    },
+    changeType(type){
+      this.$emit('changeVal', this.form, false)
+      this.$emit('changeType', type, false)
+    },
+    changeSex(data) {   //改变性别清空数据
+      this.$emit('changeVal', this.form, false)
+      this.$emit('changeSex', data, false)
+    },
+    readyChangeSelect(tmpData,type) {
+      if(type === 1) {
+        this.form.region2 = '';
+        this.labelTypes = this.labelTypesList.filter(item => this.labelTypesMaps[tmpData].indexOf(item.val) > -1)
+      }
+      if(type === 2) {
+        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) => {
+        if (valid) {
+          this.$emit('validatePass', this.form, false)
+        } else {
+          console.log('error submit!!');
+          return false;
+        }
+      });
+    },
+    warning(msg, type) {
+      this.$message({
+        showClose: true,
+        message: msg,
+        type: type || 'warning'
+      })
+    },
+    initForm() {
+      this.form.region12 = '1'
+      this.form.region10 = '1'
+      this.form.region11 = '0'
+    }
+  }
+}
+</script>
+<style lang="less">
+.PubTagGroupWrapper {
+  .groups {
+  background-color: #fff;
+  padding: 20px;
+  margin: 20px 20px -20px 20px;
+  .el-form-item__content,
+  .el-input__inner {
+    height: 30px;
+    line-height: 30px;
+    width: 200px;
+  }
+  .el-form-item {
+    margin-bottom: 20px;
+  }
+  .el-form-item__error {
+    top: 28px;
+  }
+  .el-form-item__label {
+    line-height: 30px;
+    text-align: left;
+  }
+  .el-input__icon {
+    line-height: 30px;
+  }
+  .verticalMiddle .el-form-item__content {
+    position: relative;
+    top: 16px;
+  }
+  .maxAges {
+    margin-left: -125px;
+  }
+  .ages {
+    display: inline-block;
+    .el-form-item__content {
+      width: auto;
+    }
+    .el-input {
+      display: inline-block;
+      width: auto;
+      .el-input__inner {
+        width: 60px;
+        padding: 0 5px;
+        margin-right: 25px;
+        text-align: center;
+      }
+
+      .el-input__inner::-webkit-outer-spin-button,
+      .el-input__inner::-webkit-inner-spin-button {
+        -webkit-appearance: none;
+      }
+
+      .el-input__inner[type="number"] {
+        -moz-appearance: textfield;
+      }
+    }
+  }
+  .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>
+

+ 221 - 0
src/components/icss/DiagnosisTemplate.vue

@@ -0,0 +1,221 @@
+<template>
+  <div class="NoiseTemplateWrapper TemplateWrapper">
+    <div class="groupTitle"><i
+        class="el-icon-back"
+        @click="back"
+      ></i> {{txt}}</div>
+    <DiagnosisPubTag
+      :editData="editData"
+      @changeVal="changeVal"
+      @changeSex="changeSex"
+      @changeType="changeType"
+      @validatePass="validatePass"
+      ref="submitForm"
+    ></DiagnosisPubTag>
+    <div class="main">
+      <div class="btn">
+        <el-button
+          type="primary"
+          @click="submitForm"
+        >确 定</el-button>
+      </div>
+    </div>
+  </div>
+</template>
+<script>
+/**
+ * dataPub.region2  判断底部显示哪些
+ */
+import DiagnosisPubTag from './DiagnosisPubTag';
+import api from '@api/icss.js';
+
+export default {
+  name: 'NoiseTemplateWrapper',
+  data() {
+    return {
+      txt:'诊断标签维护--添加诊断标签',
+      dataPub: {},      //公用组件传的值都在这
+      editData:{},                    //编辑数据
+      form: {
+        currentOrder: '0',     //标签成文顺序
+      },
+      rules: {
+        currentOrder: [
+          { required: true, message: '选择标签成文顺序', trigger: 'change' }
+        ]
+      },
+      sendIds: [[], [], [], [], [], []],           //标签明细右侧操作数据
+    }
+  },
+  beforeMount:function(){
+    const {isEdit,data} = this.$route.params;
+    if(isEdit){
+      this.txt = '诊断标签维护--修改诊断标签';
+      this.editData = data;
+      // console.log('回读数据', this.editData)
+    }
+  },
+  computed: {
+    newSign() {
+      return this.dataPub.region2;
+    },
+  },
+  watch: {
+    newSign(nextVal, prevVal) {
+      if (nextVal != prevVal) {
+        this.form.currentOrder = '0'
+      }
+    },
+  },
+  methods: {
+    back() { this.$router.go(-1) },
+    changeVal(val) {    //子组件数据改变传递到父组件
+      this.dataPub = val
+      // console.log('公用组件传的值都在这', val)
+    },
+    changeSex(sex) {       //性别改变,清空标签明细
+      // console.log(sex)
+    },
+    changeType(type) {        //填写单类型改变,标签明细左侧更新,右侧清空
+      // console.log(type)
+    },
+    changeActionData(arr) {          //标签明细右侧数据id
+      this.sendIds = arr
+    },
+    submitForm() {       // 调用子组件的方法验证公用部分
+      this.$refs.submitForm.submitForm('groups');
+    },
+    validatePass() {      //验证成功回调,调取接口
+      //仍需验证标签明细是否选择
+      let type = this.dataPub.region1;
+      if (JSON.stringify(this.sendIds) == '[[],[],[],[],[],[]]' && type != 6 && type != 7 && type != 8 && type != 9 && type != 10 && type != 11) {
+        this.$message({
+          message: '请选择标签明细',
+          type: 'warning'
+        });
+        return;
+      }
+      if(parseInt(this.dataPub.region8) >= parseInt(this.dataPub.region9)) {
+          this.$message({
+            message: '最小年龄不能大于或等于最大年龄',
+            type: 'warning'
+          });
+          return;
+      }
+     
+
+      let param = {
+        "disTypeVO": {
+          "type": this.dataPub.region13
+        },
+        "questionWrapper": {
+          "controlType": 0,                            //控件类型(0:默认值 1:下拉单选 2:下拉多选 6:文本框 7:数字键盘文本框 99:联合推送)
+          "id": this.editData.id || '',                //新增id空
+          "type": this.dataPub.region1,                //标签归属
+          // "itemType":0,                                //0:是症状,1:不是症状
+          "tagType": this.dataPub.region2,             //标签类型
+          "tagName": this.dataPub.region3,             //系统名称
+          "name": this.dataPub.region4,                //界面名称
+          "joint": this.dataPub.region5,               //标签间的连接符
+          // "subType": this.dataPub.region6,   	         //0:可以,1:不可以(当项目检索)
+          "sexType": this.dataPub.region7,             //1:男,2:女,3:通用
+          "ageBegin": this.dataPub.region8,       		 //最小年龄
+          "ageEnd": this.dataPub.region9,              //最大年龄
+          "textGenerate": this.form.currentOrder,      //成文顺序 默认0
+          "copyType": this.dataPub.region10,           //是否复制
+          "showAdd": this.dataPub.region11,            //是否显示加号血压
+          "itemType" :this.dataPub.region12,
+          "showInfo": 0,
+          "questionDetails": [],
+          "questionMappings": []       //映射关系,
+        }
+      }
+      if((this.dataPub.region2 == 2 || this.dataPub.region2 == 3)&& detailLis.length == 0) {
+         this.warning('请选择标签明细')
+         return
+      }
+      this.showDelDialog(param)
+    },
+    showDelDialog(param) {
+      this.showConfirmDialog('是否保存该诊断标签?', () => {
+        api.saveOrUpdate(param).then((res) => {
+          if (res.data.code === '0') {
+            this.warning(res.data.msg || '保存成功', 'success','1000')
+            setTimeout(() => {
+              this.$router.push({
+                path:'/admin/LT-YXSJWH-ZDBQWH'
+              })
+            }, 1000);
+          } else {
+            this.warning(res.data.msg)
+          }
+        }).catch((err) => {
+          this.warning(err);
+        })
+      });
+    },
+    showConfirmDialog(msg, resolve) {
+      this.$alert(msg, '提示', {
+        confirmButtonText: '确定',
+        type: 'warning'
+      }).then(() => {
+        resolve();
+      }).catch(() => {});
+    },
+    warning(msg, type,time) {
+      this.$message({
+        showClose: true,
+        message: msg,
+        type: type || 'warning',
+        duration:time || '3000'
+      })
+    },
+  },
+  components: {
+    DiagnosisPubTag
+  }
+}
+</script>
+<style lang="less">
+@import "../../less/common.less";
+.NoiseTemplateWrapper {
+  .groupTitle {
+    background-color: #fff;
+    height: 40px;
+    line-height: 40px;
+    padding-left: 20px;
+  }
+  .main {
+    background-color: #fff;
+    margin: 0 20px 20px;
+    padding: 20px;
+    border-top: 1px solid @icssBorder;
+    box-sizing: border-box;
+    font-size: 14px;
+    color: #606266;
+    .title {
+      margin-bottom: 20px;
+      min-width: 915px;
+      i {
+        color: #f56c6c;
+      }
+      span {
+        color:#22ccc8;
+        font-size: 12px;
+      }
+    }
+  }
+  .btn {
+    text-align: right;
+    margin-top: 10px;
+  }
+  .order {
+    margin-bottom: 20px;
+    .el-input__inner {
+      line-height: 30px;
+      height: 30px;
+    }
+  }
+}
+</style>
+

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

@@ -65,7 +65,7 @@
                     label="操作">
                     <template slot-scope="scope">
                         <el-button  @click="modifyTagGroup(scope.row)" type="text" size="small">修改</el-button>
-                        <el-button @click="showDelDialog(scope.row.id)" class="delete" type="text" size="small">删除</el-button>
+                        <el-button @click="showDelDialog(scope.row.id,scope.row.type)" class="delete" type="text" size="small">删除</el-button>
                     </template>
                 </el-table-column>
             </el-table>
@@ -130,7 +130,10 @@ export default {
             return api.getDropList().then((res) =>{
                 // console.log('dropList', res)
                 if(res.data.code === '0') {
-                    this.Adscriptions = res.data.data[1];
+                    // this.Adscriptions = res.data.data[1];
+                    let tmpLis = res.data.data[1]
+                    this.Adscriptions = tmpLis.filter(item => item.val != 7);
+
                     this.tagTypes =  res.data.data[3];
                     for (var i = 0; i < this.tagTypes.length; i++) {
                         this.tagTypesList.push(this.tagTypes[i].val)
@@ -197,7 +200,8 @@ export default {
                 current: this.currentPage,
                 size: this.pageSize,
                 type: this.filter.tagAdscription,
-                tagName: this.filter.tagSysName
+                tagName: this.filter.tagSysName,
+                notTypeList: [7]
             };
             return param;
         },
@@ -222,9 +226,9 @@ export default {
             resolve();
           }).catch(() => {});
         },
-        showDelDialog(id){
+        showDelDialog(id,type){
           this.showConfirmDialog('是否删除该标签组?',()=>{
-            api.deleteTagGroup({ids:id}).then((res)=>{
+            api.deleteTagGroup({ids:id,type:type}).then((res)=>{
               if(res.data.code=='0'){
                 this.getDataList();
                 this.warning(res.data.msg || '操作成功','success');

File diff ditekan karena terlalu besar
+ 6 - 2
src/components/icss/NoiseTemplate.vue


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

@@ -242,9 +242,11 @@ export default {
         '4':['2','3'],
         '5':['7'],
         '6':['9'],
-        '7':['9'],
+        // '7':['9'],
         '8':['9'],
-        '9':['9']
+        '9':['9'],
+        '10':['9'],
+        '11':['9']
       },
       rules: {
         region1: [
@@ -463,7 +465,6 @@ export default {
       this.form.region12 = '1'
       this.form.region10 = '1'
       this.form.region11 = '0'
-
     }
   }
 }

+ 4 - 0
src/routes.js

@@ -63,6 +63,8 @@ import MedicalRelation from '@components/icss/MedicalRelation.vue'//医学术语
 import AddMedicalRelation from '@components/icss/AddMedicalRelation.vue'//医学术语维护-关系维护-添加
 import MedicalInfo from '@components/icss/MedicalInfo.vue'//医学术语维护-信息维护(属性维护)
 import AddMedicalInfo from '@components/icss/AddMedicalInfo.vue'//医学术语维护-信息维护(属性维护)-添加
+import DiagnosisList from '@components/icss/DiagnosisList.vue'//诊断标签维护 -- 列表显示
+import DiagnosisTemplate from '@components/icss/DiagnosisTemplate.vue';//诊断标签维护 -- 添加
 export default [
   {
     path: '/',
@@ -192,6 +194,8 @@ export default [
       {path:'LT-YXSYKWH-TJYXSYGX',component:AddMedicalRelation,name:'AddMedicalRelation'},     //医学术语--关系维护-添加
       {path:'LT-YXSYKWH-SYYXSXWH',component:MedicalInfo,name:'MedicalInfo'},  //医学术语维护-信息维护(属性维护)
       {path:'LT-YXSYKWH-TJYXSYXX',component:AddMedicalInfo,name:'AddMedicalInfo'},  //医学术语维护-信息维护(属性维护) -- 添加
+      {path:'LT-YXSJWH-ZDBQWH',component:DiagnosisList,name:'DiagnosisList'},  //诊断标签维护 -- 列表显示
+      {path:'LT-YXSJWH-ZDBQTJ',component:DiagnosisTemplate,name:'DiagnosisTemplate'},  //诊断标签维护 -- 添加
     ]
   }
 ]