Pārlūkot izejas kodu

Merge branch 'dev' into ChronicMag_zxc

zhangxc 6 gadi atpakaļ
vecāks
revīzija
c77b66314f

+ 1 - 1
src/api/config.js

@@ -142,7 +142,7 @@ export default {
     'updateVersInfo': 'api/icssman/versionInfo/updateVersionInfoAlls', //版本信息-修改
     'delVersionInfo': 'api/icssman/versionDetail/cancelVersionDetails', //版本信息-删除版本说明
     'addVersionInfo': 'api/icssman/versionDetail/addVersionDetails', //版本信息-添加版本说明
-    'modiVersionInfo': 'api/icssman/versionDetail/upgetConceptKnowledgedateVersionDetails', //版本信息-修改版本说明
+    'modiVersionInfo': 'api/icssman/versionDetail/updateVersionDetails', //版本信息-修改版本说明
     'getVersionDetlInfo': 'api/icssman/versionDetail/getDetailById', //版本信息-版本说明列表获取
     'promptServer':'/api/knowledgeman/file/uploadImage',    //静态知识富文本图片上传
     /**************医学术语维护****************/

+ 12 - 0
src/components/icss/AddMedicalName.vue

@@ -403,6 +403,18 @@ import pinyin from '../../js/Convert_Pinyin.js';
           this.warning('请先选择标准词');
           return
         }
+        // 年龄为必填项--2019-6-5需求
+        if(this.showMore == 1){
+          if(!this.minAge && this.minAge != 0 || !this.maxAge){
+            this.warning('年龄不能为空,区间为0-200');
+            return
+          }
+          if(this.minAge < 0 || this.minAge > 200 || this.maxAge < 0 || this.maxAge > 200){
+            this.warning('年龄必须是0-200');
+            return
+          }
+        }
+        
         // 过滤同义词空数据
         let realData=[];
         if(this.id){//修改用暂存的列表

+ 16 - 4
src/components/icss/AddVersion.vue

@@ -6,7 +6,7 @@
         <!-- <el-form ref="form" :label-position="labelPosition" label-width="95px" class="add-admin-form" :model="form" :rules="rules"> -->
         <el-form ref="form" :label-position="labelPosition" label-width="95px" class="add-version-form" :model="form" :rules="rules">
           <el-form-item label="版本号:" prop="name" class="version-num">
-              <el-input v-model="form.name" placeholder="请输入版本号" maxlength="20"></el-input>
+              <el-input v-model="form.name" placeholder="请输入版本号" maxlength="21"></el-input>
           </el-form-item>
           <el-form-item label="版本时间:" prop="refreshTime">
             <el-date-picker
@@ -19,7 +19,7 @@
             </el-date-picker>
           </el-form-item>
           <el-form-item label="版本备注:" prop="remark" class="discDesc">
-              <el-input type="textarea" :rows="3" placeholder="请输入版本备注" v-model="form.remark" maxlength="120"></el-input>
+              <el-input type="textarea" :rows="3" placeholder="请输入版本备注" v-model="form.remark" maxlength="121"></el-input>
           </el-form-item>
           <el-form-item label="版本说明:" v-if="list&&list.length>0">
           </el-form-item>
@@ -42,12 +42,23 @@
         if (!value) {
           return callback(new Error('请输入版本号'));
         }
-        if (value.length >= 20) {
+        if (value.length > 20) {
            this.form.name = value.substr(0, 20);
            this.$message({
              showClose: true,
              type: 'warning',
-             message: '已超过最大字数限制'
+             message: '版本号已超过最大限制20字'
+           })
+        }
+        callback();
+      };
+      const remarkVaild = (rule, value, callback) => {
+        if (value.length > 120) {
+           this.form.remark = value.substr(0, 120);
+           this.$message({
+             showClose: true,
+             type: 'warning',
+             message: '版本备注已超过最大限制120字'
            })
         }
         callback();
@@ -67,6 +78,7 @@
         rules:{
           name:[{ required: true, validator: titleVaild, trigger: [ 'change'] },
                 { required: true, message: '请输入版本号',trigger: ['blur', 'change'] }],
+          remark:{ required: false, validator: remarkVaild, trigger: [ 'change'] },
           refreshTime:{ required: true, message: '请选择时间', trigger: ['blur', 'change'] }
         },
         pickerOptions1:{

+ 2 - 3
src/components/icss/ChronicDiseaseAdd.vue

@@ -38,7 +38,7 @@
             ></span></p>
           <p><span
               class="el-icon-arrow-left"
-              @click="toLeftPool"
+              @click="toLeftPool" 
             ></span></p>
         </div>
         <div class="ChronicDiseaseRight">
@@ -47,7 +47,7 @@
             <div class="contentDetail clearfix" v-for="(item,idx) in contentPool" :class="selectRightPart.order == item.order?'selectDom':null" :key="item.order" @click="selectPart(item,2)">
               <span>{{item.name}}:</span>
               <div class="contentDetails">
-                <quillEditor v-model="item.content" :options="editorOption" v-if="item.val == 1" class="ql-editor"></quillEditor>
+                <quillEditor v-model="item.content" :options="editorOption" v-if="item.val == 0" class="ql-editor"></quillEditor>
               </div>
             </div>
           </div>
@@ -193,7 +193,6 @@ export default {
       this.contentPool = tmpPool
     },
     selectPart(part,dir){
-      console.log(part,dir)
       if(dir == 1){
         if(this.selectLeftPart.val == part.val){
           this.selectLeftPart = {}

+ 6 - 6
src/components/icss/MedicalName.vue

@@ -115,7 +115,7 @@
           {id:'Y',name:'已删除'},
         ],
         isState:'',
-        cacheData: {},
+        cacheData: {}, //因为删除和恢复要及时更新,所以不做缓存
         currentPage: 1,
         pageSize: 10,
         total: 0,
@@ -148,7 +148,7 @@
           if (res.data.code == '0') {
             const data = res.data.data;
             this.list = data.records;
-            this.cacheData[param.current] = data.records;
+            // this.cacheData[param.current] = data.records;
             this.total = data.total;
           }
         }).catch((error) => {
@@ -185,11 +185,11 @@
       },
       currentChange(next) {
         this.currentPage = next;
-        if (this.cacheData[next]) {       //如果已请求过该页数据,则使用缓存不重复请求
-          this.list = this.cacheData[next];
-        } else {
+        // if (this.cacheData[next]) {       //如果已请求过该页数据,则使用缓存不重复请求
+        //   this.list = this.cacheData[next];
+        // } else {
           this.getDataList();
-        }
+        // }
       },
       warning(msg,type){
         this.$message({

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

@@ -50,7 +50,7 @@
       </el-form-item>
       <el-form-item
         v-show="(form.region1 == 1 && form.region2 ==4) || (form.region1 == 4) || (form.region1 == 5)"
-        :label="(form.region1 == 5)?'是否当化验推送项':(form.region1 == 4)?'是否当查体推送项':'是否为症状'"
+        :label="(form.region1 == 5)?'是否当化验推送项':(form.region1 == 4)?'当查体推送项时,需要检索标准术语':'是否为症状'"
         prop="region12"
       >
         <span

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

@@ -50,11 +50,11 @@
           </p>
           <el-form-item label="标题:" prop="title">
             <p v-if="showDesc" class="cont">{{form.title}}</p>
-            <el-input v-else v-model="form.title" placeholder="请输入标题" maxlength="30"></el-input>
+            <el-input v-else v-model="form.title" placeholder="请输入标题" maxlength="31"></el-input>
           </el-form-item>
           <el-form-item label="内容:" prop="description" class="discDesc">
             <p v-if="showDesc" v-html="form.description" class="cont">{{form.description}}</p>
-            <el-input v-else type="textarea" :rows="3" placeholder="请输入内容" v-model="form.description" maxlength="500" @keydown.native="contentInp"></el-input>
+            <el-input v-else type="textarea" :rows="3" placeholder="请输入内容" v-model="form.description" maxlength="501" @keydown.native="contentInp"></el-input>
           </el-form-item>
           <el-button class="disclButn1" size="small" type="primary" @click="comfirn('form')">确定</el-button>
           <!-- <el-button class="disclButn can" size="small" type="primary" @click="cancel">取消</el-button> -->
@@ -71,26 +71,26 @@
         if (!value) {
           return callback(new Error('请输入标题'));
         }
-        if (value.length >= 30) {
+        if (value.length > 30) {
            this.form.title = value.substr(0, 30);
            this.$message({
              showClose: true,
              type: 'warning',
-             message: '已超过最大字数限制'
+             message: '标题已超过最大限制30字'
            })
         }
         callback();
       };
       const descVaild = (rule,value,callback) => {
         if(!value){
-          return callback(new Error('请输入标题'));
+          return callback(new Error('请输入内容'));
         }
-        if (value.length >= 500) {
+        if (value.length > 500) {
            this.form.description = value.substr(0, 500);
            this.$message({
              showClose: true,
              type: 'warning',
-             message: '已超过最大字数限制'
+             message: '内容已超过最大限制500字'
            })
         }
         callback();

+ 9 - 3
src/components/icss/VersionInfo.vue

@@ -45,9 +45,9 @@
                 <el-table-column
                         label="操作">
                     <template slot-scope="scope">
-                        <el-button type="text" size="small" :class="{forbid:scope.row.id !=list[0].id}" @click="scope.row.id ==list[0].id?toEditVersion(scope.row,false):''">修改</el-button>
+                        <el-button type="text" size="small" :class="{forbid:scope.row.id != canModiId}" @click="scope.row.id ==canModiId?toEditVersion(scope.row,false):''">修改</el-button>
                         <span style="margin:0 3px;">|</span>
-                        <el-button type="text" size="small" :class="{forbid:scope.row.id !=list[0].id}" @click="scope.row.id ==list[0].id?toEditVersion(scope.row,true):''">复制</el-button>
+                        <el-button type="text" size="small" :class="{forbid:scope.row.id != canModiId}" @click="scope.row.id ==canModiId?toEditVersion(scope.row,true):''">复制</el-button>
                     </template>
                 </el-table-column>
                 <el-table-column
@@ -84,7 +84,9 @@
         total: 0,
         filter: {
           name: ''
-        }
+        },
+        canModiId:null, //标识列表中的第一个可修改和复制项,区分分页和搜索
+        flag:true
       }
     },
     created() {
@@ -116,6 +118,10 @@
             this.list = data.records;
             this.cacheData[param.current] = data.records;
             this.total = data.total;
+            if(this.flag){
+              this.canModiId = this.list[0].id;
+            }
+            this.flag = false;
           }
         }).catch((error) => {
           console.log(error);