Bladeren bron

新需求改动

zhangli 1 jaar geleden
bovenliggende
commit
a37a9a62d6

BIN
src/assets/img/warehouse/myKnowledge.png


+ 1 - 1
src/layouts/MainHead.vue

@@ -117,7 +117,7 @@ export default {
                   {'key':4,'title':'知识专辑','component':'/knowledgePage/albumIndex','menuNavType':2,
                   'initArr':['albumDetail','albumIndex']},
                   {'key':5,'title':'知识学习','component':'http://www.hkcqjy.com.cn:8088/learning/','menuNavType':2,'initArr':[]},
-                  {'key':6,'title':'统计分析','component':'/knowledgePage/analysis','menuNavType':2,'initArr':['analysis']},
+                  //{'key':6,'title':'统计分析','component':'/knowledgePage/analysis','menuNavType':2,'initArr':['analysis']},
                   {'key':7,'title':'管理后台','component':'/knowledge/knowledge','menuNavType':2,'initArr':[]},
                 ], //系统应用
       appSystemMore: [],

+ 2 - 2
src/permission.js

@@ -22,9 +22,9 @@ router.beforeEach((to, from, next) => {
             data.ussd='{"id":"'+to.query.pkId+'","type":""}'
         }
         if(to.meta.subModule!='详情'||to.query.pkId){
-            analysis.pageTrack(data).then((res) => {
+            /*analysis.pageTrack(data).then((res) => {
 
-            })
+            })*/
         }
     }
     // next();

+ 5 - 3
src/views/modules/knowledge/aJs/getClassifyTree.js

@@ -16,9 +16,11 @@ export function getCategory(data) {
 export function getCategoryId(data) {
   const result = []
   const _getParentCategoryName = (info) => {
-    result.push(info.pkId)
-    if(info.parents) {
-      _getParentCategoryName(info.parents)
+    if(info!=null){
+      result.push(info.pkId)
+      if(info.parents) {
+        _getParentCategoryName(info.parents)
+      }
     }
   }
   _getParentCategoryName(data)

+ 1 - 1
src/views/modules/knowledge/album/detail.vue

@@ -349,7 +349,7 @@ export default {
       classifyListAdd:[],
       knowledgeList: [
         {value: '1', label: '文档知识'},
-        {value: '2', label: '维基知识'}
+       // {value: '2', label: '维基知识'}
       ],
       addDataShow:false,
       categoryValue:'',

+ 2 - 2
src/views/modules/knowledge/components/albumList.vue

@@ -173,9 +173,9 @@ export default {
             page:datares.url,
             platform:datares.systemName,
           }
-          analysis.pageTrack(data).then((res) => {
+          /*analysis.pageTrack(data).then((res) => {
 
-          })
+          })*/
          // window.open(res.data)
         })
       }

+ 5 - 3
src/views/modules/knowledge/warehouse/aJs/getClassifyTree.js

@@ -15,9 +15,11 @@ export function getCategory(data) {
 export function getCategoryId(data) {
   const result = []
   const _getParentCategoryName = (info) => {
-    result.push(info.pkId)
-    if(info.parents) {
-      _getParentCategoryName(info.parents)
+    if(info!=null){
+      result.push(info.pkId)
+      if(info.parents) {
+        _getParentCategoryName(info.parents)
+      }
     }
   }
   _getParentCategoryName(data)

+ 12 - 6
src/views/modules/knowledge/warehouse/components/card.vue

@@ -1,9 +1,9 @@
 <template>
    <div class="content" :style="{'background': isDocument ? '#406CC4' : '#00C8DC'}"  @click="handleGoAddClick">
-    <img :src="isDocument ? documentKnowledge : wikiKnowledge" alt="">
-    <div>{{ isDocument ? '新增文档知识' : '新增维基知识' }}</div>
+    <img :src="isDocument ? documentKnowledge : myKnowledge" alt="">
+    <div>{{ isDocument ? '新增知识' : '我的知识' }}</div>
     <div>
-      <span>去新增</span>
+      <span>{{ isDocument ? '去新增' : '点击查看' }}</span>
       <img :src="rightGray" alt="">
     </div>
   </div>
@@ -12,6 +12,7 @@
 <script>
 import documentKnowledge from  '@/assets/img/warehouse/documentKnowledge.png'
 import wikiKnowledge from  '@/assets/img/warehouse/wikiKnowledge.png'
+import myKnowledge from  '@/assets/img/warehouse/myKnowledge.png'
 import rightGray from  '@/assets/img/warehouse/rightGray.png'
 export default {
   props: {
@@ -24,18 +25,23 @@ export default {
     return {
       documentKnowledge,
       wikiKnowledge,
-      rightGray
+      rightGray,
+      myKnowledge
     }
   },
   methods: {
     // 去新增
     handleGoAddClick() {
-      this.$router.push({
+      if(this.isDocument){
+        this.$router.push({
           name: "knowledgeAddUpdate",
           query: {
             type: this.isDocument? '1' : '2'
           }
-      })
+       })
+      }else{
+        this.$router.push({ path: 'contentData?type=0&showMy=1' });
+      }
     }
   }
 }

+ 18 - 6
src/views/modules/knowledge/warehouse/knowledgeAddUpdate.vue

@@ -159,7 +159,7 @@ export default {
       summaryNum:100,
       knowledgeForm: {
         categoryId: [],
-        type: undefined,
+        type: '1',
         bastype:undefined,
         titles: '',
         summary: '',
@@ -168,7 +168,11 @@ export default {
         attachmentName: '',
         createBy: '',
         author: '',
-        organizationIds: {}
+        organizationIds: {
+          organizationId: ["C0000"],
+          organizationName: ["惠科集团"],
+          organizationTree: ["惠科集团"]
+        }
       },
       options: [
         {
@@ -195,7 +199,7 @@ export default {
       classifyList: [],
       knowledgeList: [
         {value: '1', label: '文档知识'},
-        {value: '2', label: '维基知识'}
+        //{value: '2', label: '维基知识'}
       ],
       showOnlyOffice: false,
       knowledgeRules: {
@@ -267,9 +271,13 @@ export default {
       headers: {},
       isSubmit:false,
       widthVar: 800,
-      authName: undefined,
+      authName: '组织:[惠科集团]',
       checkedTarget: {},
-      checkedTargets: {},
+      checkedTargets: {
+        organizationId:["C0000"],
+        organizationName:["惠科集团"],
+        organizationTree:["惠科集团"]
+      },
       // 职系
       sequencesInfo: {},
       // 职等
@@ -447,7 +455,11 @@ export default {
     },
     //  简介修改限制数量
     summaryChange(){
-      this.summaryNum=100-this.knowledgeForm.summary.length
+      if(this.knowledgeForm.summary!=null){
+        this.summaryNum=100-this.knowledgeForm.summary.length
+      }else{
+        this.summaryNum=100
+      }
     },
     //  提交数据
     handleSaveClick(type) {

+ 2 - 2
src/views/modules/knowledge/warehouse/knowledgeContentInfo.vue

@@ -100,9 +100,9 @@ export default {
           }
           //console.log(postData)
           if(this.$route.query.type==1||this.$route.query.type==2){
-            analysis.pageTrack(postData).then((res) => {
+            /*analysis.pageTrack(postData).then((res) => {
 
-            })
+            })*/
           }
         }
       })