Selaa lähdekoodia

Merge branch 'develop3.0' of http://106.12.23.251:10080/TEAMMODEL/TEAMModelOS into develop3.0

CrazyIter 5 vuotta sitten
vanhempi
commit
23c6636e3e
40 muutettua tiedostoa jossa 239 lisäystä ja 3839 poistoa
  1. 16 15
      TEAMModelOS/ClientApp/src/api/knowledge.js
  2. 19 17
      TEAMModelOS/ClientApp/src/api/learnActivity.js
  3. 11 11
      TEAMModelOS/ClientApp/src/api/newEvaluation.js
  4. 1 1
      TEAMModelOS/ClientApp/src/api/schoolSetting.js
  5. 18 24
      TEAMModelOS/ClientApp/src/api/syllabus.js
  6. 4 4
      TEAMModelOS/ClientApp/src/api/teachContent.js
  7. 5 0
      TEAMModelOS/ClientApp/src/common/BaseQuestionList.vue
  8. 1 1
      TEAMModelOS/ClientApp/src/components/learnactivity/BaseHwTable.vue
  9. 4 4
      TEAMModelOS/ClientApp/src/components/learnactivity/ChooseContent.vue
  10. 7 7
      TEAMModelOS/ClientApp/src/components/syllabus/DragTree.vue
  11. 0 323
      TEAMModelOS/ClientApp/src/components/syllabus/KnowTree.vue
  12. 0 58
      TEAMModelOS/ClientApp/src/components/syllabus/SelectModule.vue
  13. 0 271
      TEAMModelOS/ClientApp/src/components/syllabus/SelectSchool.vue
  14. 0 497
      TEAMModelOS/ClientApp/src/components/syllabus/Tree.vue
  15. 1 1
      TEAMModelOS/ClientApp/src/store/module/schoolBaseInfo.js
  16. 8 8
      TEAMModelOS/ClientApp/src/view/evaluation/bank/ExerciseList.vue
  17. 3 3
      TEAMModelOS/ClientApp/src/view/evaluation/bank/TestPaperList.vue
  18. 1 1
      TEAMModelOS/ClientApp/src/view/evaluation/components/BaseEditExercise.vue
  19. 0 1
      TEAMModelOS/ClientApp/src/view/evaluation/components/BaseExerciseList.vue
  20. 7 5
      TEAMModelOS/ClientApp/src/view/evaluation/components/BaseFilter.vue
  21. 3 3
      TEAMModelOS/ClientApp/src/view/evaluation/components/BasePoints.vue
  22. 1 1
      TEAMModelOS/ClientApp/src/view/evaluation/index/CreateExercises.vue
  23. 4 10
      TEAMModelOS/ClientApp/src/view/evaluation/index/CreatePaper.vue
  24. 0 627
      TEAMModelOS/ClientApp/src/view/evaluation/index/PickExercise.vue
  25. 14 15
      TEAMModelOS/ClientApp/src/view/knowledge-point/index/Index.vue
  26. 1 1
      TEAMModelOS/ClientApp/src/view/knowledge-point/index/operation/AddBlock.vue
  27. 1 1
      TEAMModelOS/ClientApp/src/view/knowledge-point/index/operation/AddPoint.vue
  28. 2 2
      TEAMModelOS/ClientApp/src/view/knowledge-point/index/operation/ComposeBlock.vue
  29. 1 1
      TEAMModelOS/ClientApp/src/view/learnactivity/ManualCreate.vue
  30. 1 1
      TEAMModelOS/ClientApp/src/view/learnactivity/ManualPaper.vue
  31. 88 9
      TEAMModelOS/ClientApp/src/view/newcourse/NewAdminCourse.vue
  32. 0 267
      TEAMModelOS/ClientApp/src/view/syllabus/index/KnowPoint.css
  33. 0 695
      TEAMModelOS/ClientApp/src/view/syllabus/index/KnowPoint.vue
  34. 0 263
      TEAMModelOS/ClientApp/src/view/syllabus/index/Syllabus.css
  35. 0 569
      TEAMModelOS/ClientApp/src/view/syllabus/index/Syllabus.vue
  36. 0 105
      TEAMModelOS/ClientApp/src/view/syllabus/index/index.vue
  37. 11 11
      TEAMModelOS/ClientApp/src/view/syllabus/newSyllabus/Index.vue
  38. 1 1
      TEAMModelOS/ClientApp/src/view/syllabus/newSyllabus/operation/AddEditors.vue
  39. 2 2
      TEAMModelOS/ClientApp/src/view/syllabus/newSyllabus/operation/AddVolume.vue
  40. 3 3
      TEAMModelOS/ClientApp/src/view/syllabus/newSyllabus/operation/BaseKnowledge.vue

+ 16 - 15
TEAMModelOS/ClientApp/src/api/knowledge.js

@@ -1,38 +1,39 @@
 import { post } from '@/filters/http'
 export default {
-    // ��ȡ��׼֪ʶ��
+    // 获取标准知识点
     GetStantardPoints: function(data) {
-        return post('/api/Knowledge/FindKnowledgePointByDict', data)
+        return post('/api/Knowledge/findStdPoint', data)
     },
-    // ��ȡ��׼֪ʶ��
+    // 获取标准的知识块及包含的知识点
     GetStantardBlocks: function(data) {
-        return post('/api/Knowledge/FindKnowledgeBlockAndPointByDict', data)
+        return post('/api/Knowledge/findStdBlockPoint', data)
     },
-    // ��ȡѧУ֪ʶ��
+    // 获取知识块知识点
     GetSchoolPoints: function(data) {
-        return post('/api/Knowledge/FindKnowledge', data)
+        return post('/api/Knowledge/find', data)
     },
-    // ��ȡѧУ֪ʶ��
+    // 获取知识块知识点
     GetSchoolBlocks: function(data) {
-        return post('/api/Knowledge/FindKnowledge', data)
+        return post('/api/Knowledge/find', data)
     },
-    // ��������ѧУ֪ʶ�鼰֪ʶ��
+    // 批量更新保存知识点知识块
     SaveOrUpdateKnowledge: function(data) {
-        return post('/api/Knowledge/SaveOrUpdateKnowledge', data)
+        return post('/api/Knowledge/upsertAll', data)
     },
     // �ֶ�����ѧУ��˽��֪ʶ��
     SaveOrUpdateSchoolPoint: function(data) {
         return post('/api/Knowledge/SaveOrUpdateAllSchoolPoint', data)
     },
-    // ɾ��֪ʶ�����֪ʶ��
+    // 删除知识点知识块
     DeleteSchoolPoint: function(data) {
-        return post('/api/Knowledge/DeleteKnowledge', data)
+        return post('/api/Knowledge/delete', data)
     },
-    // ɾ��֪ʶ��
+    // 删除知识点知识块
     DeleteSchoolBlock: function(data) {
-        return post('/api/Knowledge/DeleteKnowledge', data)
+        return post('/api/Knowledge/delete', data)
     },
+    // 根据id集合获取知识点知识块
     FindKnowledgebyId: function(data) {
-        return post('/api/Knowledge/FindKnowledgebyId', data)
+        return post('/api/Knowledge/findByIds', data)
     },
 }

+ 19 - 17
TEAMModelOS/ClientApp/src/api/learnActivity.js

@@ -4,19 +4,19 @@ export default {
      *保存试卷
      */
     SaveExamPaper: function (data) {
-        return post('/api/Exam/SaveExamPaper', data)
+        return post('/api/Paper/upsert', data)
     },
     /*
      *查询试卷
      */
     FindExamPaper: function (data) {
-        return post('/api/Exam/FindExamPaper', data)
+        return post('/api/Paper/find', data)
     },
     /*
      *删除试卷
      */
     DeleteExamPaper: function (data) {
-        return post('/api/Exam/DeleteExamPaper', data)
+        return post('/api/Paper/delete', data)
     },
     /*
      *删除评测信息
@@ -64,13 +64,13 @@ export default {
     *根据id数组查询资源文件
     */
     FindSyllabusResourceById: function (data) {
-        return post('/api/Resource/FindSyllabusResourceById', data)
+        return post('/api/Resource/findById', data)
     },
     /*
     *根据id数组查询资源文件
     */
     FindQuestionById: function (data) {
-        return post('/api/ItemInfo/FindById', data)
+        return post('/api/ItemInfo/findByIds', data)
     },
     /*
     *保存编序式学习活动
@@ -84,29 +84,31 @@ export default {
     FindOrderLearn: function (data) {
         return post('/api/Learn/FindLeanProcess', data)
     },
+
+
     /*
     *查询作业活动
     */
     SaveorUpdataHomeWork: function (data) {
-        return post('/api/HomeWork/SaveorUpdataHomeWork', data)
+        return post('/api/HomeWork/upsert', data)
     },
     /*
     *新增或者编辑作业活动
     */
     FindHomeWork: function (data) {
-        return post('/api/HomeWork/FindHomeWork', data)
+        return post('/api/HomeWork/find', data)
     },
     /*
     * 撤销发布作业
     */
     RevokeHomeWork: function (data) {
-        return post('/api/HomeWork/RevokeHomeWork', data)
+        return post('/api/HomeWork/cancel', data)
     },
     /*
     * 删除作业
     */
     DeleteHomeWork: function (data) {
-        return post('/api/HomeWork/DeleteHomeWork', data)
+        return post('/api/HomeWork/delete', data)
     },
     /*
     * 查询老师课程下的所有班级
@@ -118,26 +120,26 @@ export default {
     * 查询作业下的所有学生数据
     */
     FindStudentByHwId: function (data) {
-        return post('/api/HomeWork/FindStudent', data)
+        return post('/api/HomeWork/findStudent', data)
     },
 
     /*
      * 查询老师的评语罐头
      */
     FindTeacherComments: function (data) {
-        return post('/api/HomeWork/FindTeacherComments', data)
+        return post('/api/HomeWork/findComments', data)
     },
     /*
      * 新增老师的评语罐头
      */
     SaveOrUpdateTeacherComments: function (data) {
-        return post('/api/HomeWork/SaveOrUpdateTeacherComments', data)
+        return post('/api/HomeWork/upsertComments', data)
     },
     /*
      * 删除老师的评语罐头
      */
     DeleteTeacherComments: function (data) {
-        return post('/api/HomeWork/DeleteTeacherComments', data)
+        return post('/api/HomeWork/deleteComments', data)
     },
 
     /*
@@ -180,24 +182,24 @@ export default {
     * 新增或者修改投票活动
     */
     SaveorUpdataVote: function (data) {
-        return post('/api/Vote/SaveorUpdataVote', data)
+        return post('/api/Vote/upsert', data)
     },
     /*
     * 查询投票活动
     */
     FindVote: function (data) {
-        return post('/api/Vote/FindVote', data)
+        return post('/api/Vote/find', data)
     },
     /*
     * 删除投票活动
     */
     DeleteVote: function (data) {
-        return post('/api/Vote/DeleteVote', data)
+        return post('/api/Vote/delete', data)
     },
     /*
     * 查询学生投票活动数据
     */
     FindStudentByVoteId: function (data) {
-        return post('/api/Vote/FindStudent', data)
+        return post('/api/Vote/findStudent', data)
     },
 }

+ 11 - 11
TEAMModelOS/ClientApp/src/api/newEvaluation.js

@@ -4,30 +4,30 @@ export default {
         return post('/api/ImportExercise/AnalyzeHtml', data)
     },
     /**
-     * �������浥������
+     * 更新保存试题
      * @param {any} data
      */
     SaveSingleExercise: function(data) {
-        return post('/api/ItemInfo/Save', data)
+        return post('/api/ItemInfo/upsert', data)
     },
     /**
-     * �������浥������
+     * 批量更新保存试题
      * @param {any} data
      */
     SaveAllExercise: function(data) {
-        return post('/api/ItemInfo/SaveAll', data)
+        return post('/api/ItemInfo/upsertAll', data)
     },
 
     /**
-     * ��ѯ����б�
+     * 根据条件手动挑题
      * @param {any} data
      */
     FindExerciseList: function(data) {
-        return post('/api/ItemInfo/Find', data)
+        return post('/api/ItemInfo/find', data)
     },
 
     /**
-     * ������ѯ�������
+     * 查找总数
      * @param {any} data
      */
     FindCount: function(data) {
@@ -35,19 +35,19 @@ export default {
     },
 
     /**
-     * ��ѯ������Ŀ����ϸ����
+     * 根据试题id集合获取题目
      * @param {any} data
      */
     FindExerciseById: function(data) {
-        return post('/api/ItemInfo/FindById', data)
+        return post('/api/ItemInfo/findByIds', data)
     },
 
     /**
-     * ɾ��������Ŀ
+     * 删除试题
      * @param {any} data
      */
     DeleteExamItem: function(data) {
-        return post('/api/ItemInfo/DeleteExamItem', data)
+        return post('/api/ItemInfo/delete', data)
     }
 
 }

+ 1 - 1
TEAMModelOS/ClientApp/src/api/schoolSetting.js

@@ -4,7 +4,7 @@ export default {
         return post('/api/School/SaveOrUpdateAll', data)
     },
     findSchoolSystem: function(data) {
-        return post('/api/School/FindSchool', data)
+        return post('/api/School/find', data)
     },
     findClassInfo: function(data) {
         return post('/api/Classroom/FindClassInfo', data)

+ 18 - 24
TEAMModelOS/ClientApp/src/api/syllabus.js

@@ -1,45 +1,39 @@
 import { post } from '@/filters/http'
 export default {
-    // ����������ȡѧУ����
-    GetSchoolInfo: function(data) {
-        return post('/api/School/FindSchool', data)
-    },
-    // �������¿θٲ��
+    // 更新册别
     SaveOrUpdateVolume: function(data) {
-        return post('/api/Volume/SaveOrUpdate', data)
+        return post('/api/Volume/upsert', data)
     },
-    // ���ҿθٲ��
+    // 查找册别
     GetVolumes: function(data) {
-        return post('/api/Volume/Find', data)
+        return post('/api/Volume/find', data)
     },
-    // ɾ���θٲ��
+    // 删除册别
     DeleteVolume: function(data) {
-        return post('/api/Volume/Delete', data)
+        return post('/api/Volume/delete', data)
     },
-    // ���ݲ����ҿθ�����
+    // 根据册别查找树形课纲
     GetTreeByVolume: function(data) {
-        return post('/api/Syllabus/Find', data)
+        return post('/api/Syllabus/find', data)
     },
-    // �������α��������θ�
+    // 更新课纲树形结构
     SaveOrUpdateAsTree: function(data) {
-        return post('/api/Syllabus/SaveOrUpdateAsTree', data)
-    },
-    // ����������������ڵ�
-    SaveOrUpdateAsNodes: function(data) {
-        return post('/api/Syllabus/SaveOrUpdateAsNodes', data)
+        return post('/api/Syllabus/upsertTree', data)
     },
-    // ����������������ڵ�
+    // 更新节点
     SaveOrUpdateAsNodes: function(data) {
-        return post('/api/Syllabus/SaveOrUpdateAsNodes', data)
+        return post('/api/Syllabus/upsertNodes', data)
     },
-    // ͨ�ü��ϲ�ѯ�ӿ�
+    // 查找集合
     FindCollection: function(data) {
         return post('/api/Common/FindCollection', data)
-    },// ͨ�ü��ϲ�ѯ�ӿ�
+    },
+    // 查找册别数量
     FindSyllabusCount: function(data) {
-        return post('/api/Volume/FindSyllabusCount', data)
+        return post('/api/Volume/count', data)
     },
+    // 查找知识块数量
     FindBlockCount: function (data) {
-        return post('/api/Knowledge/FindKnowlegeCount', data)
+        return post('/api/Knowledge/count', data)
     },
 }

+ 4 - 4
TEAMModelOS/ClientApp/src/api/teachContent.js

@@ -1,15 +1,15 @@
 import { fetch, post } from '@/filters/http'
 export default {
     saveOrUpdateResource: function(data) {
-        return post('/api/Resource/SaveOrUpdateSyllabusResource', data)
+        return post('/api/Resource/upsertAll', data)
     },
     findResourceByDict: function(data) {
-        return post('/api/Resource/FindSyllabusResourceByDict', data)
+        return post('/api/Resource/find', data)
     },
     deleteResource: function(data) {
-        return post('/api/Resource/DeleteSyllabusResource', data)
+        return post('/api/Resource/delete', data)
     },
     FindSyllabusResourceById: function (data) {
-        return post('/api/Resource/FindSyllabusResourceById', data)
+        return post('/api/Resource/findById', data)
     },
 }

+ 5 - 0
TEAMModelOS/ClientApp/src/common/BaseQuestionList.vue

@@ -90,8 +90,13 @@
             color: rgb(4, 216, 164);
         }
 
+            .base-list-box .exercise-item .item-explain .explain-title {
+                color: rgb(4, 216, 164);
+            }
+
             .base-list-box .exercise-item .item-explain .item-explain-details {
                 display: inline-block;
+                width:80%;
             }
 </style>
 

+ 1 - 1
TEAMModelOS/ClientApp/src/components/learnactivity/BaseHwTable.vue

@@ -489,7 +489,7 @@
         },
 
         mounted() {
-            this.findTeacherComments('habook#0001').then(res => {
+            this.findTeacherComments(this.$store.state.userInfo.TEAMModelId).then(res => {
                 this.usedCommentList = res.length ? res[0].comment : []
             })
         },

+ 4 - 4
TEAMModelOS/ClientApp/src/components/learnactivity/ChooseContent.vue

@@ -411,7 +411,7 @@
              */
             getResultCount() {
                 let findCountParams = {
-                    "collectionName": "ExamItem",
+                    "collectionName": "ItemInfo",
                     "queryDict": {
                         'scopeCode': this.deleteAll(this.questionFilter.scopeCode),
                         'periodCode': this.questionFilter.periodCode == "" ? []:[this.questionFilter.periodCode],
@@ -632,7 +632,7 @@
             },
             getVolumes() {
                 this.currentVolumeIndex = 0
-                this.syllabusFilter.scopeCode = this.syllabusFilter.type == 1 ? this.demoLoginInfo.TEAMModelId : this.demoLoginInfo.schoolCode
+                this.syllabusFilter.code = this.syllabusFilter.type == 1 ? this.demoLoginInfo.TEAMModelId : this.demoLoginInfo.schoolCode
                 this.$api.syllabus.GetVolumes(this.syllabusFilter).then(
                     (res) => {
                         if (res.error == null) {
@@ -644,11 +644,11 @@
                                 this.getSyllabus()
                             }
                         } else {
-                            alert('API error!')
+                            alert('API error111!')
                         }
                     },
                     (err) => {
-                        alert('API error!')
+                        alert('API error222!')
                     }
                 )
             },

+ 7 - 7
TEAMModelOS/ClientApp/src/components/syllabus/DragTree.vue

@@ -143,7 +143,7 @@
                     remark: '',
                     nodeKey: '',
                     pid: '',
-                    volumeCode: '',
+                    code: '',
                     status: 1,
                     parent: ''
                 }
@@ -237,11 +237,11 @@
                         if (!res.error) {
                             this.currentResources = res.result.data
                         } else {
-                            this.$Message.error("API ERROR!")
+                            this.$Message.error("API ERROR")
                         }
                     },
                     err => {
-                        this.$Message.error("API ERROR!")
+                        this.$Message.error("API ERROR")
 
                     }
                 )
@@ -256,11 +256,11 @@
                         if (!res.error) {
                             this.currentItems = res.result.data
                         } else {
-                            this.$Message.error("API ERROR!")
+                            this.$Message.error("API ERROR")
                         }
                     },
                     err => {
-                        this.$Message.error("API ERROR!")
+                        this.$Message.error("API ERROR")
 
                     }
                 )
@@ -281,7 +281,7 @@
                     newChild.id = Math.uuid()
                     newChild.nodeKey = newChild.id
                     newChild.pid = parentNode.id
-                    newChild.volumeCode = parentNode.volumeCode
+                    newChild.code = parentNode.code
                     newChild.children = []
                     newChild.resources = []
                     newChild.knowledges = []
@@ -340,7 +340,7 @@
                     let volumeParent = {
                         title: this.volume.volumeName,
                         id: this.volume.volumeCode,
-                        volumeCode: this.volume.volumeCode,
+                        code: this.volume.volumeCode,
                         pid: 'Root',
                         children: []
                     }

+ 0 - 323
TEAMModelOS/ClientApp/src/components/syllabus/KnowTree.vue

@@ -1,323 +0,0 @@
-<template>
-  <div class="tree-main">
-    <Tree :data="treeData" :render="renderContent" ref="tree"></Tree>
-  </div>
-</template>
-<script>
-  export default {
-    props: ['treeDatas', 'volumeCode'],
-    data() {
-      return {
-        treeData: [],
-        schoolInfo: {},
-        inputValue: '',
-        editValue: '',
-        modalFlag: false,
-        editFlag: false,
-        addBookFlag: false,
-        nodeType: '章节',
-        currentNode: '',
-        currentLiNode: ''
-      }
-    },
-    created() {
-      this.treeData = this.treeDatas
-      this.schoolInfo = JSON.parse(localStorage.getItem('c_role_info')).roleClaim[0] // 默认选中第一个学校
-      let schoolClaims = this.schoolInfo.claim
-      for (let i in schoolClaims) {
-        if (schoolClaims[i].claimType === 'SchoolCode') {
-          this.schoolInfo = schoolClaims[i]
-        }
-      }
-    },
-
-    // 监听树形数据源变化
-    watch: {
-      treeDatas: {
-        handler(newValue) {
-          this.treeData = newValue
-        },
-        deep: true
-      }
-    },
-    methods: {
-      // 自定义渲染树形工具
-       renderContent(h, { root, node, data }) {
-        // let that = this
-        return h(
-          'span',
-          {
-            domProps: {
-              className: 'singleClass'
-            },
-            on: {
-              click: () => {
-                this.titleClick(root, node, data, event)
-              },
-              mouseover: e => {
-                e.stopPropagation()
-                this.handleLiOver(event)
-              },
-              mouseleave: e => {
-                e.stopPropagation()
-                this.handleLiLeave(node, event)
-              }
-            }
-          },
-          [
-            h('span', [
-              h('Icon', {
-                props: {
-                  type:
-                    data.children && data.children.length > 0
-                      ? 'md-albums'
-                      : 'ios-paper-outline'
-                },
-                style: {
-                  marginRight: '5px'
-                }
-              }),
-              h('span', data.name)
-            ]),
-            h(
-              'span',
-              {
-                style: {
-                  float: 'right',
-                  top: '6px',
-                  display: 'none'
-                },
-                on: {
-                  mouseleave: e => {
-                    e.stopPropagation()
-                    // this.hideTools(event);
-                  }
-                },
-                domProps: {
-                  className: 'tools'
-                }
-              },
-              [
-                h(
-                  'span',
-                  {
-                    style: {
-                      fontSize: '10px'
-                      // color:"#339aef"
-                    },
-                    domProps: {
-                      innerHTML: "<i class='ivu-icon ivu-icon-md-cloud-download' style='margin-bottom: 5px;margin-right: 2px;color:#339aef;font-size:20px'></i> 引入至私有知识块 / 知识点库"
-                    },
-                    on: {
-                      click: e => {
-                        e.stopPropagation()
-                        this.saveKnowledge(data)
-                      }
-                    }
-                  }
-                )
-              ]
-            )
-          ]
-        )
-      },
-      // 引入到私有知识库
-      saveKnowledge(data) {
-        this.$Modal.confirm({
-          title: '温馨提示',
-          content: '<p>确认将<span style="color:#339aef;font-weight:bold"> ' + data.name + ' </span> 添加到 私有知识块 / 知识点库 吗?</p>',
-          okText: '确认',
-          cancelText: '取消',
-          onOk: () => {
-            let params = {
-              KnowledgeId: data.rowKey,
-              SchoolCode: this.schoolInfo.claimCode,
-              SubjectCode: 'Subject_Chinese',
-              PartitionKey: this.schoolInfo.partitionKey
-            }
-            this.$api.SaveOrUpdateSchoolKnowledgeAsStdKnowledge(params).then(res => {
-              this.$Message.success('导入成功!')
-            })
-          }
-        })
-      },
-      // 标题点击收缩展开
-      titleClick(root, node, data, event) {
-        data.expand = !data.expand
-        console.log(data)
-      },
-      // 根目录点击事件
-      rootClick(data) {
-        data.expand = !data.expand
-      },
-
-      // 更多操作
-      handleTools(root, node, data, event) {
-        let toolsDom = event.currentTarget.nextElementSibling
-        const parentKey = root.find(el => el === node).parent
-        // const parent = root.find(el => el.nodeKey === parentKey).node
-        let list = document.getElementsByClassName('tools')
-        let cFlag = toolsDom.style.display
-        for (let i = 0; i < list.length; i++) {
-          list[i].style.display = 'none'
-        }
-        // 判断TOOL显示与隐藏
-        if (cFlag === 'none') {
-          toolsDom.style.display = 'inline-flex'
-          toolsDom.classList.add('animated')
-          toolsDom.classList.add('slideInDown')
-        } else {
-          toolsDom.style.display = 'none'
-        }
-      },
-      // 鼠标从工具条移开的时候隐藏
-      hideTools(event) {
-        event.currentTarget.style.display = 'none'
-      },
-      handleLiOver(event) {
-        event.currentTarget.lastElementChild.style.display = 'block'
-        event.currentTarget.style.backgroundColor = 'rgba(255, 255, 255, 0.68)'
-        event.currentTarget.style.border = '1px solid #000'
-      },
-      handleLiLeave(node, event) {
-        event.currentTarget.lastElementChild.style.display = 'none'
-        if (this.currentLiNode.nodeKey !== node.nodeKey) {
-          event.currentTarget.style.backgroundColor = 'transparent'
-          event.currentTarget.style.border = '0'
-        }
-      }
-
-    }
-  }
-</script>
-<style scoped>
-  .tree-main {
-    margin-left: 5%;
-    width: 90%;
-  }
-
-    .tree-main /deep/ .ivu-icon-ios-paper-outline {
-      font-size: 16px;
-    }
-
-    .tree-main /deep/ .ivu-select {
-      width: 80% !important;
-    }
-
-  .slideSelect .ivu-select-selection {
-    height: 40px;
-    background: #d8d8d870;
-    border: 1px solid #808080;
-  }
-
-  .slideSelect, .slideSelect .ivu-icon {
-    color: rgba(255,255,255,.8);
-  }
-
-  .tree-main /deep/ .ivu-select-single .ivu-select-selection .ivu-select-selected-value {
-    height: 40px;
-    line-height: 40px;
-    font-size: 14px;
-  }
-  /* .ivu-tree ul li {
-    margin: 18px 0;
-  } */
-  .tree-main /deep/ .ivu-tree ul {
-    font-size: 14px;
-  }
-
-    .tree-main /deep/ .ivu-tree ul li {
-      margin: 8px 0;
-    }
-
-  .ivu-tree .ivu-tree-arrow {
-    width: 2%;
-  }
-
-  .ivu-input-wrapper {
-    width: 80% !important;
-  }
-
-  .modelRow {
-    margin: 20px;
-    font-size: 14px;
-  }
-
-  .tree-main /deep/ .tools {
-    position: absolute;
-    right: 60px;
-    bottom: 5px;
-    display: inline-flex;
-    z-index: 999;
-  }
-
-    .tree-main /deep/ .tools .ivu-icon {
-      margin-right: 15px;
-      font-size: 16px;
-      font-weight: 200;
-      color: #808080;
-    }
-
-  .btn_more {
-    background: #fff;
-    border: 1px solid rgb(248,248,248);
-  }
-
-  .animated {
-    animation-duration: 0.5s;
-  }
-
-  @-webkit-keyframes slideInDown {
-    from {
-      -webkit-transform: translate3d(0,-10%, 0);
-      transform: translate3d(0, -10%, 0) !important;
-      visibility: visible;
-    }
-
-    to {
-      -webkit-transform: translate3d(0, 0%, 0);
-      transform: translate3d(0, 0%, 0);
-    }
-  }
-
-  @keyframes slideInDown {
-    from {
-      -webkit-transform: translate3d(0, -10%, 0);
-      transform: translate3d(0, -10%, 0) !important;
-      visibility: visible;
-    }
-
-    to {
-      -webkit-transform: translate3d(0, 0%, 0);
-      transform: translate3d(0, 0%, 0);
-    }
-  }
-
-  .slideInDown {
-    -webkit-animation-name: slideInDown;
-    animation-name: slideInDown;
-  }
-
-  .tree-main /deep/ .singleClass {
-    position: relative;
-    display: inline-flex !important;
-    flex-direction: row;
-    align-items: center;
-    height: 40px;
-    width:95%;
-    text-align: left;
-    padding-left: 2%;
-    cursor: pointer;
-    box-sizing: border-box;
-  }
-
-  .btn-addClass {
-    width: 16%;
-    padding: 10px 6px !important;
-  }
-
-  .ivu-tabs-nav-scroll {
-    display: flex;
-    justify-content: center;
-  }
-</style>

+ 0 - 58
TEAMModelOS/ClientApp/src/components/syllabus/SelectModule.vue

@@ -1,58 +0,0 @@
-<template>
-  <div class="center">
-    <div class="main-btn centerCol" v-for="(item,index) in moduleList" :key="index" @click="handleRouter(item.link)">
-      <Icon :type="item.icon" size="80" />
-      <h4 class="color1">{{item.name}}</h4>
-    </div>
-  </div>
-</template>
-
-<script>
-  export default {
-    name: 'selectModule',
-    props: ['moduleList'],
-    methods: {
-      handleRouter(path) {
-        this.$router.replace(path)
-      }
-    }
-  }
-</script>
-
-<style scoped>
-  .main-btn {
-    height: 210px;
-    width: 210px;
-    cursor: pointer;
-    font-size: 16px;
-    font-weight: 200;
-    background-color: rgba(179,179,179,.15);
-    border: 0;
-    margin: 0 10px;
-    color: #ccc;
-  }
-
-  .main-btn:hover {
-    background: rgba(179,179,179,.42);
-    color: #fff !important;
-  }
-
-  .center {
-    display: flex;
-    flex-direction: row;
-    justify-content: center;
-    align-items: center;
-  }
-
-  .centerCol {
-    display: flex;
-    flex-direction: column;
-    justify-content: center;
-    align-items: center;
-  }
-
-  .color1 {
-    margin-top: 20px;
-    font-weight: 200;
-  }
-</style>

+ 0 - 271
TEAMModelOS/ClientApp/src/components/syllabus/SelectSchool.vue

@@ -1,271 +0,0 @@
-<template>
-  <div style="width:50%">
-    <div class="selection-component row">
-      <label class="selection-label">{{$t('formConfigP.school')+':'}}</label>
-      <Row style="width:90%;">
-
-        <Col :xs="18" :sm="6" :md="5" :lg="4">
-        <Select v-model="schoolInfo.country.countryId" class="my-select" :placeholder="$t('formConfigP.country')" @on-change="getSelctValue('country',$event)" :disabled="$i18n.locale.indexOf('en') != -1">
-          <Option v-for="item in countryData" :value="item.countryId" :key="item.sysAddID">{{ item.countryName }}</Option>
-        </Select>
-        </Col>
-        <Col :xs="18" :sm="6" :md="5" :lg="4">
-        <Select v-model="schoolInfo.province.provinceId" v-show="schoolInfo.country.countryId != 'TW'" class="my-select" :placeholder="$t('formConfigP.province')" :disabled="checkCountry == 2 || $i18n.locale.indexOf('en') != -1" clearable ref="province" @on-change="getSelctValue('province',$event)">
-          <Option v-for="item in provinceData" :value="item.provinceId" :key="item.sysAddID">{{ item.provinceName }}</Option>
-        </Select>
-        </Col>
-        <Col :xs="18" :sm="6" :md="5" :lg="4">
-        <Select v-model="schoolInfo.city.cityId" class="my-select" :placeholder="$t('formConfigP.city')" :disabled="checkCountry == 2 || $i18n.locale.indexOf('en') != -1" clearable ref="city" @on-change="getSelctValue('city',$event)">
-          <Option v-for="item in cityData" :value="item.cityId" :key="item.sysAddID">{{ item.cityName }}</Option>
-        </Select>
-        </Col>
-        <Col :xs="18" :sm="6" :md="5" :lg="12">
-        <Select v-model="schoolInfo.school.name" class="my-select" :placeholder="$t('formConfigP.school')" :disabled="checkCountry == 2 || $i18n.locale.indexOf('en') != -1" clearable ref="school" @on-change="getSelctValue('school',$event)" filterable :loading="loading" not-found-text="">
-          <Option v-for="item in schoolData" :value="item.name" :key="item.sysAddID">{{ item.name }}</Option>
-        </Select>
-        </Col>
-      </Row>
-    </div>
-    <div class="selection-component ">
-      <label class="selection-label"></label>
-      <Row style="width:90%; margin-top:20px;" v-if="checkCountry == 2 || $i18n.locale.indexOf('en') != -1">
-        <Col :xs="24" :sm="6" :md="5" :lg="6">
-        <Input v-model="schoolInfoInput.country" class="my-select" placeholder="country" style="width: 95%;" />
-        </Col>
-        <Col :xs="24" :sm="6" :md="5" :lg="6">
-
-        <Input v-model="schoolInfoInput.city" class="my-select" placeholder="city" style="width: 95%" />
-        </Col>
-        <Col :xs="24" :sm="6" :md="5" :lg="12">
-        <Input v-model="schoolInfoInput.school" class="my-select" placeholder="school" style="width: 90%;" @on-change="getInputValue" />
-        </Col>
-      </Row>
-    </div>
-
-  </div>
-</template>
-
-<script>
-  export default {
-    props: {
-
-    },
-    data() {
-      return {
-        model: '',
-        zhCnData: [],
-        zhTwData: [],
-        enUsData: [],
-        schoolData: [],
-        schoolInfoInput: {
-          country: '',
-          province: '',
-          city: '',
-          school: ''
-        },
-        schoolInfo: {
-          country: {},
-          province: {},
-          city: {},
-          school: {}
-        },
-        loading: false
-      }
-    },
-    methods: {
-      getValue() {
-        this.$emit('get-value', [
-          this.model,
-          this.selections.field
-        ])
-      },
-      getCountryInfo(data) {
-        let result = []
-        let currentCountry = ''
-        for (let i = 0; i < data.length; i++) {
-          if (currentCountry != data[i].countryName && data[i].countryName != null && data[i].provinceName == null && data[i].cityName == null) {
-            currentCountry = data[i].countryName
-            result.push(data[i])
-          }
-        }
-        return result
-      },
-      getProvinceInfo(data, country) {
-        let result = []
-        let currentProvince = ''
-        for (let i = 0; i < data.length; i++) {
-          if (currentProvince != data[i].provinceName && data[i].provinceName != null && data[i].countryId == country.countryId) {
-            currentProvince = data[i].provinceName
-            result.push(data[i])
-          }
-        }
-        return result
-      },
-      getCityInfo(data, province) {
-        let result = []
-        let currentCity = ''
-        if (province != undefined) {
-          for (let i = 0; i < data.length; i++) {
-            if (currentCity != data[i].cityName && data[i].cityName != null && data[i].provinceId == province.provinceId) {
-              currentCity = data[i].cityName
-              result.push(data[i])
-            }
-          }
-        }
-
-        return result
-      },
-      getSchoolInfo(CountryId, ProvinceId, CityId) {
-        let params = {
-          CountryId: CountryId,
-          ProvinceId: ProvinceId,
-          CityId: CityId
-        }
-        this.loading = true
-
-        // 发送请求获取学校列表
-        this.$api.getSchoolList(params).then(
-          (res) => {
-            if (res.error == null) {
-              if (res.result.data.length == 0 || !res.result.data) {
-                alert('暂未收录此地区学校,请手动输入!')
-              } else {
-                this.schoolData = res.result.data
-                // this.schoolInfo.school = res.result.data[0];
-              }
-            } else {
-              alert('服务器错误!')
-            }
-            this.loading = false
-          },
-          (err) => {
-            this.loading = false
-          }
-        )
-      },
-      getSelctValue(flag, value) {
-        if (flag == 'country') {
-          this.$refs.school.clearSingleSelect()
-          this.$refs.city.clearSingleSelect()
-          this.$refs.province.clearSingleSelect()
-          this.schoolInfo.province = {}
-          this.schoolInfo.city = {}
-          this.schoolInfo.school = {}
-        } else if (flag == 'province') {
-          this.$refs.school.clearSingleSelect()
-          this.$refs.city.clearSingleSelect()
-          this.schoolInfo.city = {}
-          this.schoolInfo.school = {}
-        } else if (flag == 'city') {
-          this.$refs.school.clearSingleSelect()
-          this.schoolInfo.school = {}
-          this.getSchoolInfo(this.schoolInfo.country.countryId, this.schoolInfo.province.provinceId, this.schoolInfo.city.cityId)
-        } else if (flag == 'school') {
-          this.schoolInfo['checkCountry'] = this.checkCountry
-          this.$emit('school-info', this.schoolInfo)
-          console.log(this.schoolInfo)
-        }
-      },
-      getInputValue() {
-        this.schoolInfoInput['checkCountry'] = this.checkCountry
-        this.$emit('school-info', this.schoolInfoInput)
-        console.log(this.schoolInfo)
-      }
-    },
-    computed: {
-      countryData() {
-        let countryInfo = []
-        if (this.$i18n.locale == 'zh-CN') {
-          countryInfo = this.getCountryInfo(this.zhCnData)
-        } else if (this.$i18n.locale == 'zh-TW') {
-          countryInfo = this.getCountryInfo(this.zhTwData)
-        } else if (this.$i18n.locale.indexOf('en') != -1) {
-          countryInfo = this.getCountryInfo(this.enUsData)
-        }
-        return countryInfo
-      },
-      provinceData() {
-        let provinceInfo = []
-        if (this.$i18n.locale == 'zh-CN') {
-          provinceInfo = this.getProvinceInfo(this.zhCnData, this.schoolInfo.country)
-        } else if (this.$i18n.locale == 'zh-TW') {
-          provinceInfo = this.getProvinceInfo(this.zhTwData, this.schoolInfo.country)
-        } else if (this.$i18n.locale.indexOf('en') != -1) {
-          provinceInfo = this.getProvinceInfo(this.enUsData, this.schoolInfo.country)
-        }
-        return provinceInfo
-      },
-      cityData() {
-        let cityInfo = []
-        if (this.$i18n.locale == 'zh-CN') {
-          cityInfo = this.getCityInfo(this.zhCnData, this.schoolInfo.province)
-        } else if (this.$i18n.locale == 'zh-TW') {
-          cityInfo = this.getCityInfo(this.zhTwData, this.schoolInfo.province)
-        } else if (this.$i18n.locale.indexOf('en') != -1) {
-          cityInfo = this.getCityInfo(this.enUsData, this.schoolInfo.province)
-        }
-        return cityInfo
-      },
-      checkCountry() {
-        if (this.schoolInfo.country.countryId == undefined) {
-          return 0
-        }
-        if (this.schoolInfo.country.countryId == 'CN' || this.schoolInfo.country.countryId == 'TW') {
-          return 1
-        } else {
-          return 2
-        }
-      }
-    },
-    mounted() {
-      let area = require('@/static/area.json')
-      for (let i = 0; i < area.length; i++) {
-        if (area[i].lang == 'en-us') {
-          this.enUsData.push(area[i])
-        } else if (area[i].lang == 'zh-tw') {
-          this.zhTwData.push(area[i])
-        } else if (area[i].lang == 'zh-cn') {
-          this.zhCnData.push(area[i])
-        }
-      };
-    }
-  }
-</script>
-
-<style scoped>
-  .selection-component {
-    width: 100%;
-    position: relative;
-    display: flex;
-    flex-direction: row;
-    align-items: center;
-  }
-
-  .ivu-select-selection {
-    width: 150px !important;
-  }
-
-  .selection-label {
-    width: 120px;
-    font-size: 15px;
-    color: #67B6E5;
-  }
-
-  .my-select {
-    width: 90%;
-  }
-
-    .my-select > > > .ivu-select-selection {
-      border: 1px solid #67B6E5;
-    }
-
-    .my-select > > > .ivu-select-selected-value {
-      color: #67B6E5;
-      font-size: 15px;
-    }
-
-    .my-select > > > .ivu-select-input {
-      color: #67B6E5;
-      font-size: 13px;
-    }
-</style>

+ 0 - 497
TEAMModelOS/ClientApp/src/components/syllabus/Tree.vue

@@ -1,497 +0,0 @@
-<template>
-    <div class="tree-main">
-
-        <Tree :data="treeData" :render="renderContent" ref="tree"></Tree>
-        <Modal v-model="modalFlag" title="添加新节点" ok-text="确认" cancel-text="取消" @on-ok="handleAddNode">
-            <Row class="modelRow">
-                <span>
-                    当前章节:
-                    <span style="margin-left:10px;">{{currentNode.title}}</span>
-                </span>
-            </Row>
-            <Row class="modelRow">
-                <span>节点名称:</span>
-                <Input v-model="inputValue" placeholder="输入新节点名称" style="width: 100%" />
-            </Row>
-        </Modal>
-        <Modal v-model="editFlag" title="修改节点" ok-text="确认" cancel-text="取消" @on-ok="handleUpdateNode">
-            <Row class="modelRow">
-                <span>
-                    当前名称:
-                    <span style="margin-left:10px;">{{currentNode.title}}</span>
-                </span>
-            </Row>
-            <Row class="modelRow">
-                <span>修改名称:</span>
-                <Input v-model="editValue" placeholder="输入节点新名称" style="width: 100%" />
-            </Row>
-        </Modal>
-    </div>
-</template>
-<script>
-    export default {
-        props: ['treeDatas', 'volumeCode'],
-        data() {
-            return {
-                treeData: [],
-                inputValue: '',
-                editValue: '',
-                modalFlag: false,
-                editFlag: false,
-                addBookFlag: false,
-                nodeType: '章节',
-                currentNode: '',
-                currentLiNode: ''
-            }
-        },
-        created() {
-            this.treeData = this.treeDatas
-        },
-        watch: {
-            treeDatas: {
-                handler(newValue, oldValue) {
-                    this.treeData = newValue
-                },
-                deep: true
-            }
-        },
-        methods: {
-            renderContent(h, { root, node, data }) {
-                // let that = this
-                return h(
-                    'span',
-                    {
-                        style: {
-                            display: 'inline-block',
-                            width: '95%',
-                            textAlign: 'left',
-                            paddingLeft: '2%',
-                            cursor: 'pointer',
-                            position: 'relative',
-                            boxSizing: 'border-box'
-                        },
-                        domProps: {
-                            className: 'singleClass'
-                        },
-                        on: {
-                            click: () => {
-                                this.titleClick(data)
-                            },
-                            mouseover: e => {
-                                e.stopPropagation()
-                                this.handleLiOver(event)
-                            },
-                            mouseleave: e => {
-                                e.stopPropagation()
-                                this.handleLiLeave(node, event)
-                            }
-                        }
-                    },
-                    [
-                        h('span', [
-                            h('Icon', {
-                                props: {
-                                    type:
-                                        data.children && data.children.length > 0
-                                            ? 'md-albums'
-                                            : 'ios-paper-outline'
-                                },
-                                style: {
-                                    marginRight: '5px',
-                                    display: 'none'
-                                }
-                            }),
-                            h('span', data.title)
-                        ]),
-                        h(
-                            'span',
-                            {
-                                style: {
-                                    float: 'right',
-                                    top: '6px',
-                                    display: 'none'
-                                },
-                                on: {
-                                    mouseleave: e => {
-                                        e.stopPropagation()
-                                        // this.hideTools(event);
-                                    }
-                                },
-                                domProps: {
-                                    className: 'tools'
-                                }
-                            },
-                            [
-                                h(
-                                    'Icon',
-                                    {
-                                        props: {
-                                            type: 'md-add',
-                                            title: '添加'
-                                        },
-                                        on: {
-                                            click: e => {
-                                                e.stopPropagation()
-                                                this.appendClick(data)
-                                            }
-                                        }
-                                    }
-                                ),
-                                h(
-                                    'Icon',
-                                    {
-                                        props: {
-                                            type: 'md-remove'
-                                        },
-                                        on: {
-                                            click: e => {
-                                                e.stopPropagation()
-                                                this.remove(root, node, data)
-                                            }
-                                        }
-                                    }
-                                ),
-                                h(
-                                    'Icon',
-                                    {
-                                        props: {
-                                            type: 'md-arrow-round-up'
-                                        },
-                                        on: {
-                                            click: e => {
-                                                e.stopPropagation()
-                                                this.moveUp(root, node, data)
-                                            }
-                                        }
-                                    }
-                                ),
-                                h(
-                                    'Icon',
-                                    {
-                                        props: {
-                                            type: 'md-arrow-round-down'
-                                        },
-                                        on: {
-                                            click: e => {
-                                                e.stopPropagation()
-                                                this.moveDown(root, node, data)
-                                            }
-                                        }
-                                    }
-                                ),
-                                h(
-                                    'Icon',
-                                    {
-                                        props: {
-                                            type: 'md-create'
-                                        },
-                                        on: {
-                                            click: e => {
-                                                e.stopPropagation()
-                                                this.editClick(node, data)
-                                            }
-                                        }
-                                    }
-                                )
-                            ]
-                        )
-                    ]
-                )
-            },
-            // 添加节点
-            append(data, value) {
-                const children = data.children || []
-                let newChild = {
-                    title: value,
-                    order: children.length,
-                    pid: data.rowKey,
-                    children: [],
-                    expand: true,
-                    type: data.type,
-                    volumeCode: this.volumeCode,
-                    remark: '备注'
-                }
-                children.push(newChild)
-                this.$set(data, 'children', children)
-                this.$api.SaveOrUpdateSingleNode(newChild).then(res => {
-                    this.$Message.success('添加成功')
-                    this.$api.FindSyllabusByVolumeCode({ VolumeCode: this.volumeCode, Status: 1 }).then(res => {
-                        this.treeData = res.result.data
-                    })
-                })
-            },
-            // 删除节点
-            remove(root, node, data) {
-                data.status = 0
-                this.$api.SaveOrUpdateSingleNode(data).then(res => {
-                    this.$Message.success('删除成功')
-                    this.$api.FindSyllabusByVolumeCode({ VolumeCode: this.volumeCode, Status: 1 }).then(res => {
-                        this.treeData = res.result.data
-                    })
-                })
-            },
-            // 点击编辑
-            editClick(node, data) {
-                this.currentNode = data
-                this.editFlag = true
-                this.editValue = ''
-            },
-            // 添加节点 弹出输入框
-            appendClick(data) {
-                this.currentNode = data
-                this.modalFlag = true
-                this.inputValue = ''
-            },
-            // 确认添加节点
-            handleAddNode() {
-                if (this.inputValue !== '') {
-                    this.append(this.currentNode, this.inputValue)
-                } else {
-                    this.modalFlag = false
-                }
-            },
-            // 修改节点
-            handleUpdateNode() {
-                if (this.editValue !== '') {
-                    this.$api.SaveOrUpdateSingleNode(this.currentNode).then(res => {
-                        this.$Message.success('修改成功')
-                        this.currentNode.title = this.editValue
-                    })
-                } else {
-                    this.editFlag = false
-                }
-            },
-            // 标题点击收缩展开
-            titleClick(data) {
-                data.expand = !data.expand
-            },
-            // 根目录点击事件
-            rootClick(data) {
-                data.expand = !data.expand
-            },
-            // 上移章节操作
-            moveUp(root, node, data) {
-                let that = this
-                let list = []
-                const parentKey = root.find(el => el === node).parent
-
-                // 判断是否存在父级
-                if (parentKey === null || parentKey === undefined) {
-                    list = that.treeData
-                } else {
-                    list = root.find(el => el.nodeKey === parentKey).node.children
-                }
-                const index = list.indexOf(data)
-                let currentOrder = data.order
-
-                // 第一个元素无法上移
-                if (index !== 0) {
-                    let preData = list[index - 1]
-                    if (data.order === preData.order) {
-                        data.order = data.order - 1
-                    } else {
-                        data.order = preData.order
-                        preData.order = currentOrder
-                    }
-                    // 更新两条数据
-                    that.$api.SaveOrUpdateSingleNode(data)
-                    that.$api.SaveOrUpdateSingleNode(preData)
-
-                    // 移动后刷新数据
-                    setTimeout(function() {
-                        that.$api.FindSyllabusByVolumeCode({ VolumeCode: that.volumeCode, Status: 1 }).then(res => {
-                            that.treeData = res.result.data
-                        })
-                    }, 500)
-                }
-            },
-            // 下移章节操作
-            moveDown(root, node, data) {
-                let that = this
-                let list = []
-                const parentKey = root.find(el => el === node).parent
-
-                // 判断是否存在父级
-                if (parentKey === null || parentKey === undefined) {
-                    list = that.treeData
-                } else {
-                    list = root.find(el => el.nodeKey === parentKey).node.children
-                }
-                const index = list.indexOf(data)
-                let currentOrder = data.order
-                // 最后一个元素无法下移
-                if (index !== (list.length - 1)) {
-                    let nextData = list[index + 1]
-                    if (data.order === nextData.order) {
-                        data.order = data.order + 1
-                    } else {
-                        data.order = nextData.order
-                        nextData.order = currentOrder
-                    }
-                    // 更新两条数据
-                    that.$api.SaveOrUpdateSingleNode(data)
-                    that.$api.SaveOrUpdateSingleNode(nextData)
-
-                    // 移动后刷新数据
-                    setTimeout(function() {
-                        that.$api.FindSyllabusByVolumeCode({ VolumeCode: that.volumeCode, Status: 1 }).then(res => {
-                            that.treeData = res.result.data
-                        })
-                    }, 500)
-                }
-            },
-            // 更多操作
-            handleTools(root, node, data, event) {
-                let toolsDom = event.currentTarget.nextElementSibling
-                const parentKey = root.find(el => el === node).parent
-                const parent = root.find(el => el.nodeKey === parentKey).node
-                // const index = parent.children.indexOf(data)
-                let list = document.getElementsByClassName('tools')
-                let cFlag = toolsDom.style.display
-                for (let i = 0; i < list.length; i++) {
-                    list[i].style.display = 'none'
-                }
-                // 判断TOOL显示与隐藏
-                if (cFlag === 'none') {
-                    toolsDom.style.display = 'inline-flex'
-                    toolsDom.classList.add('animated')
-                    toolsDom.classList.add('slideInDown')
-                } else {
-                    toolsDom.style.display = 'none'
-                }
-            },
-            // 鼠标从工具条移开的时候隐藏
-            hideTools(event) {
-                event.currentTarget.style.display = 'none'
-            },
-            handleLiOver(event) {
-                event.currentTarget.lastElementChild.style.display = 'block'
-                event.currentTarget.style.backgroundColor = 'rgba(255, 255, 255, 0.68)'
-                event.currentTarget.style.border = '1px solid #000'
-            },
-            handleLiLeave(node, event) {
-                event.currentTarget.lastElementChild.style.display = 'none'
-                if (this.currentLiNode.nodeKey !== node.nodeKey) {
-                    event.currentTarget.style.backgroundColor = 'transparent'
-                    event.currentTarget.style.border = '0'
-                }
-            }
-
-        }
-    }
-</script>
-<style scoped>
-      .tree-main {
-          margin-left: 5%;
-          width: 90%;
-      }
-
-          .tree-main /deep/ .ivu-icon-ios-paper-outline {
-              font-size: 16px;
-          }
-
-          .tree-main /deep/ .ivu-select {
-              width: 80% !important;
-          }
-
-      .slideSelect .ivu-select-selection {
-          height: 40px;
-          background: #d8d8d870;
-          border: 1px solid #808080;
-      }
-
-      .slideSelect, .slideSelect .ivu-icon {
-          color: rgba(255,255,255,.8);
-      }
-
-      .tree-main /deep/ .ivu-select-single .ivu-select-selection .ivu-select-selected-value {
-          height: 40px;
-          line-height: 40px;
-          font-size: 14px;
-      }
-      /* .ivu-tree ul li {
-      margin: 18px 0;
-    } */
-      .tree-main /deep/ .ivu-tree ul {
-          font-size: 14px;
-      }
-
-          .tree-main /deep/ .ivu-tree ul li {
-              margin: 8px 0;
-          }
-
-      .ivu-tree .ivu-tree-arrow {
-          width: 2%;
-      }
-
-      .ivu-input-wrapper {
-          width: 80% !important;
-      }
-
-      .modelRow {
-          margin: 20px;
-          font-size: 14px;
-      }
-
-      .tree-main /deep/ .tools {
-          position: absolute;
-          right: 60px;
-          bottom: 5px;
-          display: inline-flex;
-          z-index: 999;
-      }
-
-          .tree-main /deep/ .tools .ivu-icon {
-              margin-right: 15px;
-              font-size: 16px;
-              font-weight: 200;
-              color: #808080;
-          }
-
-      .btn_more {
-          background: #fff;
-          border: 1px solid rgb(248,248,248);
-      }
-
-      .animated {
-          animation-duration: 0.5s;
-      }
-
-      @-webkit-keyframes slideInDown {
-          from {
-              -webkit-transform: translate3d(0,-10%, 0);
-              transform: translate3d(0, -10%, 0) !important;
-              visibility: visible;
-          }
-
-          to {
-              -webkit-transform: translate3d(0, 0%, 0);
-              transform: translate3d(0, 0%, 0);
-          }
-      }
-
-      @keyframes slideInDown {
-          from {
-              -webkit-transform: translate3d(0, -10%, 0);
-              transform: translate3d(0, -10%, 0) !important;
-              visibility: visible;
-          }
-
-          to {
-              -webkit-transform: translate3d(0, 0%, 0);
-              transform: translate3d(0, 0%, 0);
-          }
-      }
-
-      .slideInDown {
-          -webkit-animation-name: slideInDown;
-          animation-name: slideInDown;
-      }
-
-      .tree-main /deep/ .singleClass {
-          display: inline-flex !important;
-          flex-direction: row;
-          align-items: center;
-          height: 40px;
-      }
-</style>

+ 1 - 1
TEAMModelOS/ClientApp/src/store/module/schoolBaseInfo.js

@@ -31,7 +31,7 @@ export default {
                 (resolve, reject) => {
                     if (context.state.schoolBaseInfo.period.length == 0) {
                         apiTools.schoolSetting.findSchoolSystem({
-                            schoolCode: context.state.demoLoginInfo.schoolCode
+                            code: context.state.demoLoginInfo.schoolCode
                         }).then(
                             res => {
                                 if (res.error == null) {

+ 8 - 8
TEAMModelOS/ClientApp/src/view/evaluation/bank/ExerciseList.vue

@@ -189,7 +189,7 @@
         },
         data() {
             return {
-                userId: 'habook#0001',
+                userId: '',
                 schoolCode: '',
                 dataLoading: false,
                 editExerciseModal: false,
@@ -208,7 +208,7 @@
                 exersicesDiff: ['容易', '较易', '一般', '较难', '困难'],
                 diffColors: ['#32CF74', '#E8BE15', '#F19300', '#EB5E00', '#D30000'],
                 filterType: ['all'],
-                filterOrigin: 'habook#0001',
+                filterOrigin: '',
                 filterDiff: ['all'],
                 filterField: ['all'],
                 filterSort: 'createTime',
@@ -240,6 +240,8 @@
                 this.$store.dispatch('schoolBaseInfo/getSchoolBaseData').then(res => {
                     this.schoolInfo = JSON.parse(JSON.stringify(res.data))
                     this.schoolCode = res.data.schoolCode
+                    this.userId = this.$store.state.userInfo.TEAMModelId
+                    this.filterOrigin = this.$store.state.userInfo.TEAMModelId
                     this.periodList = res.data.period
                     this.gradeList = res.data.period[0].grades
                     this.subjectList = res.data.period[0].subjects
@@ -256,11 +258,10 @@
                     '@CURRPAGE': this.pageNum,
                     '@PAGESIZE': this.pageSize,
                     '@DESC': this.filterSort,
-                    'scopeCode': this.filterOrigin,
+                    'code': this.filterOrigin,
                     'periodCode': [this.periodList[this.filterPeriod].periodCode],
                     'gradeCode': this.deleteFalse(this.filterGrade),
                     'subjectCode': [this.periodList[this.filterPeriod].subjects[this.filterSubject].subjectCode],
-                    'scopeCode': this.filterOrigin,
                     'level': this.deleteFalse(this.filterDiff),
                     'type': this.deleteFalse(this.filterType),
                     'field': this.deleteFalse(this.filterField)
@@ -268,13 +269,12 @@
 
                 /** 查询总数参数 */
                 let findCountParams = {
-                    'collectionName': 'ExamItem',
+                    'collectionName': 'ItemInfo',
                     'queryDict': {
-                        'scopeCode': this.filterOrigin,
+                        'code': this.filterOrigin,
                         'periodCode': [this.periodList[this.filterPeriod].periodCode],
                         'gradeCode': this.deleteFalse(this.filterGrade),
                         'subjectCode': [this.periodList[this.filterPeriod].subjects[this.filterSubject].subjectCode],
-                        'scopeCode': this.filterOrigin,
                         'level': this.deleteFalse(this.filterDiff),
                         'type': this.deleteFalse(this.filterType),
                         'field': this.deleteFalse(this.filterField)
@@ -575,7 +575,7 @@
                     cancelText: '取消',
                     onOk: () => {
                         this.isLoadPoints = true
-                        this.$api.newEvaluation.DeleteExamItem({ id: item.id, pk: item.scopeCode }).then(res => {
+                        this.$api.newEvaluation.DeleteExamItem({ id: item.id, pk: item.code }).then(res => {
                             if (!res.error && res.result.data) {
                                 this.$Message.success('删除成功')
                                 this.pageChange(1)

+ 3 - 3
TEAMModelOS/ClientApp/src/view/evaluation/bank/TestPaperList.vue

@@ -120,7 +120,7 @@
                     '@CURRPAGE': this.pageNum,
                     '@PAGESIZE': this.pageSize,
                     '@DESC': this.filterSort,
-                    'scopeCode': filterParams.scopeCode,
+                    'code': filterParams.code,
                     'periodCode': filterParams.periodCode,
                     'gradeCode': filterParams.gradeCode,
                     'subjectCode': filterParams.subjectCode
@@ -181,7 +181,7 @@
                     cancelText: '取消',
                     onOk: () => {
                         this.dataLoading = true
-                        this.$api.learnActivity.DeleteExamPaper({ id: item.id, pk: item.scopeCode }).then(res => {
+                        this.$api.learnActivity.DeleteExamPaper({ id: item.id, pk: item.code }).then(res => {
                             if (!res.error && res.result.data) {
                                 this.$Message.success('删除成功')
                                 this.pageChange(1)
@@ -204,7 +204,7 @@
                     })
                     console.log(res)
                     this.paperInfo.item = items
-                    this.paperInfo.scopeCode = this.filterParams.scopeCode,
+                    this.paperInfo.code = this.filterParams.code,
                         this.paperInfo.periodCode = this.filterParams.periodCode[0],
                         this.paperInfo.subjectCode = this.filterParams.subjectCode[0]
 

+ 1 - 1
TEAMModelOS/ClientApp/src/view/evaluation/components/BaseEditExercise.vue

@@ -248,7 +248,7 @@
                 exerciseItem.periodCode = this.schoolInfo.period[this.exercisePeriod].periodCode
                 exerciseItem.gradeCode = this.exerciseGrade
                 exerciseItem.subjectCode = this.schoolInfo.period[this.exercisePeriod].subjects[this.exerciseSubject].subjectCode
-                exerciseItem.scopeCode = this.exerciseScope === 0 ? 'habook#0001' : this.schoolInfo.schoolCode
+                exerciseItem.scopeCode = this.exerciseScope === 0 ? this.$store.state.userInfo.TEAMModelId : this.schoolInfo.schoolCode
 
                 // 判断获取的数据是否有空数据以及是否为空字符串
                 if (this.checkContent(exerciseItem) && this.getSimpleText(exerciseItem.question)  && exerciseItem.gradeCode.length) {

+ 0 - 1
TEAMModelOS/ClientApp/src/view/evaluation/components/BaseExerciseList.vue

@@ -141,7 +141,6 @@
         },
         data() {
             return {
-                userId: 'habook#0001',
                 schoolCode: '',
                 dataLoading: false,
                 exerciseList: [],

+ 7 - 5
TEAMModelOS/ClientApp/src/view/evaluation/components/BaseFilter.vue

@@ -86,7 +86,7 @@
         },
         data() {
             return {
-                userId: 'habook#0001',
+                userId: '',
                 schoolCode: '',
                 schoolInfo: {},
                 isShowUploadList: false,
@@ -101,7 +101,7 @@
                 exersicesDiff: ['容易', '较易', '一般', '较难', '困难'],
                 diffColors: ['#32CF74', '#E8BE15', '#F19300', '#EB5E00', '#D30000'],
                 filterType: ['all'],
-                filterOrigin: 'habook#0001',
+                filterOrigin: '',
                 filterDiff: ['all'],
                 filterField: ['all'],
                 filterSort: 'createTime',
@@ -124,6 +124,8 @@
                 this.$store.dispatch('schoolBaseInfo/getSchoolBaseData').then(res => {
                     this.schoolInfo = JSON.parse(JSON.stringify(res.data))
                     this.schoolCode = res.data.schoolCode
+                    this.userId = this.$store.state.userInfo.TEAMModelId
+                    this.filterOrigin = this.$store.state.userInfo.TEAMModelId
                     this.periodList = res.data.period
                     this.gradeList = res.data.period[0].grades
                     this.subjectList = res.data.period[0].subjects
@@ -135,7 +137,7 @@
             doFilter() {
                 /** 定义查询接口的参数规格 */
                 this.filterParams = {
-                    'scopeCode': this.filterOrigin,
+                    'code': this.filterOrigin,
                     'periodCode': [this.periodList[this.filterPeriod].periodCode],
                     'gradeCode': this.deleteFalse(this.filterGrade),
                     'subjectCode': [this.subjectList[this.filterSubject].subjectCode],
@@ -146,9 +148,9 @@
 
                 /** 查询总数参数 */
                 let findCountParams = {
-                    'collectionName': 'ExamPaper',
+                    'collectionName': 'Paper',
                     'queryDict': {
-                        'scopeCode': this.filterOrigin,
+                        'code': this.filterOrigin,
                         'periodCode': [this.periodList[this.filterPeriod].periodCode],
                         'gradeCode': this.deleteFalse(this.filterGrade),
                         'subjectCode': [this.subjectList[this.filterSubject].subjectCode],

+ 3 - 3
TEAMModelOS/ClientApp/src/view/evaluation/components/BasePoints.vue

@@ -92,7 +92,7 @@
                 originSchoolList: [],
                 originList:[],
                 defaultParams: {
-                    scopeCode: '',
+                    code: '',
                     period: null,
                     subjectCode: null,
                     type: 1
@@ -114,7 +114,7 @@
              */
             getPoints(type) {
                 if (this.pointList.length && this.schoolPointList.length) return
-                this.defaultParams.scopeCode = type === 0 ? 'habook#0001' : 'HBCN'
+                this.defaultParams.code = type === 0 ? this.$store.state.userInfo.TEAMModelId : this.$store.state.userInfo.schoolCode
                 this.defaultParams.period = this.period
                 this.defaultParams.subjectCode = this.subject
                 this.$api.knowledge.GetSchoolPoints(this.defaultParams).then(res => {
@@ -143,7 +143,7 @@
                         name: newName,
                         alias: newName,
                         subjectCode: this.subject,
-                        scopeCode: this.newPointType === 'school' ? 'HBCN' : 'habook#0001', // //判断当前添加为校本或者私有知识点
+                        code: this.newPointType === 'school' ? this.$store.state.userInfo.schoolCode : this.$store.state.userInfo.TEAMModelId, // //判断当前添加为校本或者私有知识点
                         order: 706,
                         status: 1,
                         knowledgeId: this.uuid,

+ 1 - 1
TEAMModelOS/ClientApp/src/view/evaluation/index/CreateExercises.vue

@@ -300,7 +300,7 @@
                 exerciseItem.periodCode = this.schoolInfo.period[this.exercisePeriod].periodCode
                 exerciseItem.gradeCode = this.exerciseGrade
                 exerciseItem.subjectCode = this.schoolInfo.period[this.exercisePeriod].subjects[this.exerciseSubject].subjectCode
-                exerciseItem.scopeCode = this.exerciseScope === 0 ? 'habook#0001' : this.schoolInfo.schoolCode
+                exerciseItem.code = this.exerciseScope === 0 ? this.$store.state.userInfo.TEAMModelId : this.schoolInfo.schoolCode
 
                 // 判断获取的数据是否有空数据以及是否为空字符串
                 if (this.checkContent(exerciseItem) && this.getSimpleText(exerciseItem.question) && this.getSimpleText(exerciseItem.explain) && exerciseItem.gradeCode.length) {

+ 4 - 10
TEAMModelOS/ClientApp/src/view/evaluation/index/CreatePaper.vue

@@ -129,12 +129,6 @@
                         { required: true, message: '发布方式不能为空!', trigger: 'change' }
                     ]
                 },
-                demoLoginInfo: {
-                    user: 'admin',
-                    TEAMModelId: 'habook#0001',
-                    school: '醍摩豆书院',
-                    schoolCode: 'HBCN'
-                },
                 deleteIndex: -1,
                 testSubjects: [],
                 activeTab: 'auto',
@@ -196,7 +190,7 @@
              * @param list
              */
             onImportFinish(list) {
-                list.forEach(i => { i.scopeCode = this.evaluationInfo.type === 'school' ? this.$store.state.userInfo.schoolCode : this.$store.state.userInfo.TEAMModelId })
+                list.forEach(i => { i.code = this.evaluationInfo.type === 'school' ? this.$store.state.userInfo.schoolCode : this.$store.state.userInfo.TEAMModelId })
                 this.evaluationInfo.item = this.evaluationInfo.item.concat([...list])
                 this.activeTab = 'preview'
             },
@@ -253,11 +247,11 @@
             /** 保存当前试卷数据 */
             saveTestPaper() {
                 if (this.evaluationInfo.item.length) {
-                    let scopeCode = this.evaluationInfo.type === 'school' ? this.$store.state.userInfo.schoolCode : this.$store.state.userInfo.TEAMModelId
+                    let code = this.evaluationInfo.type === 'school' ? this.$store.state.userInfo.schoolCode : this.$store.state.userInfo.TEAMModelId
                     this.isLoading = true
-                    this.evaluationInfo.item.forEach(i => { i.scopeCode = scopeCode })
+                    this.evaluationInfo.item.forEach(i => { i.code = code })
                     let requestData = {
-                        scopeCode: scopeCode,
+                        code: code,
                         gradeCode: this.evaluationInfo.paperGrade.length ? this.evaluationInfo.paperGrade : this.gradeList.map(i => i.gradeCode),
                         subjectCode: this.subjectList[this.evaluationInfo.paperSubject].subjectCode,
                         periodCode: this.schoolInfo.period[this.evaluationInfo.paperPeriod].periodCode,

+ 0 - 627
TEAMModelOS/ClientApp/src/view/evaluation/index/PickExercise.vue

@@ -1,627 +0,0 @@
-<template>
-    <div class="ev-list-container">
-        <div class="ev-header">
-            <Icon type="md-bookmarks" size="30" color="rgb(16, 171, 231)" />
-            <span class="ev-title">组卷中心</span>
-            <span class="ev-length">共 {{totalNum}} 道题</span>
-        </div>
-        <!-- 筛选部分 -->
-        <div class="filter-wrap">
-            <div class="filter-item">
-                <span class="filter-title">来源:</span>
-                <RadioGroup v-model="filterOrigin" type="button" @on-change="filterOriginChange">
-                    <Radio :label="userId">私有题库</Radio>
-                    <Radio :label="schoolCode">学校公用库</Radio>
-                </RadioGroup>
-            </div>
-            <div class="filter-item">
-                <span class="filter-title">学段:</span>
-                <RadioGroup v-model="filterPeriod" type="button" @on-change="filterPeriodChange">
-                    <Radio v-for="(item,index) in periodList" :key="index" :label="index">{{ item.periodName }}</Radio>
-                </RadioGroup>
-            </div>
-            <div class="filter-item">
-                <span class="filter-title">年级:</span>
-                <CheckboxGroup v-model="filterGrade" border @on-change="filterGradeChange">
-                    <Checkbox lable="all">全部</Checkbox>
-                    <Checkbox v-for="(item,index) in gradeList" :key="index" :label="item.gradeCode">{{ item.gradeName }}</Checkbox>
-                </CheckboxGroup>
-            </div>
-            <div class="filter-item">
-                <span class="filter-title">科目:</span>
-                <RadioGroup v-model="filterSubject" type="button" @on-change="filterSubjectChange">
-                    <Radio v-for="(item,index) in subjectList" :key="index" :label="index">{{ item.subjectName }}</Radio>
-                </RadioGroup>
-            </div>
-            <div class="filter-item">
-                <span class="filter-title">题型:</span>
-                <CheckboxGroup v-model="filterType" border @on-change="filterTypeChange">
-                    <Checkbox label="all">全部</Checkbox>
-                    <Checkbox label="Single">单选</Checkbox>
-                    <Checkbox label="Multiple">多选</Checkbox>
-                    <Checkbox label="Judge">判断</Checkbox>
-                    <Checkbox label="Complete">填空</Checkbox>
-                    <Checkbox label="Subjective">问答</Checkbox>
-                    <Checkbox label="Compose">综合</Checkbox>
-                </CheckboxGroup>
-            </div>
-            <div class="filter-item">
-                <span class="filter-title">难度:</span>
-                <CheckboxGroup v-model="filterDiff" border @on-change="filterDiffChange">
-                    <Checkbox label="all">全部</Checkbox>
-                    <Checkbox v-for="(item,index) in exersicesDiff" :key="index" :label="index + 1">{{ item }}</Checkbox>
-                </CheckboxGroup>
-            </div>
-            <div class="filter-item">
-                <span class="filter-title">层次:</span>
-                <CheckboxGroup v-model="filterField" border @on-change="filterFieldChange">
-                    <Checkbox label="all">全部</Checkbox>
-                    <Checkbox label="0">知识</Checkbox>
-                    <Checkbox label="1">理解</Checkbox>
-                    <Checkbox label="2">应用</Checkbox>
-                    <Checkbox label="3">分析</Checkbox>
-                    <Checkbox label="4">综合</Checkbox>
-                    <Checkbox label="5">评鉴</Checkbox>
-                </CheckboxGroup>
-            </div>
-            <div class="filter-item">
-                <span class="filter-title">排序:</span>
-                <RadioGroup v-model="filterSort" type="button" @on-change="filterSortChange">
-                    <Radio label="createTime">新增时间<Icon type="md-arrow-round-down" /></Radio>
-                    <Radio label="usageCount">使用次数<Icon type="md-arrow-round-down" /></Radio>
-                </RadioGroup>
-            </div>
-        </div>
-        <div class="ev-list-operation">
-            <div class="exercise-backet-wrap">
-                <span class="exercise-backet-item">当前已选:<span class="exercise-backet-num">{{ basketList.length }}</span> 道</span></span>
-                <span class="exercise-backet-item">单选题:<span class="exercise-backet-num">{{ basketList.filter(item => item.type === 'Single').length }}</span> 道</span>
-                <span class="exercise-backet-item">多选题:<span class="exercise-backet-num">{{ basketList.filter(item => item.type === 'Multiple').length }}</span> 道</span>
-                <span class="exercise-backet-item">判断题:<span class="exercise-backet-num">{{ basketList.filter(item => item.type === 'Judge').length }}</span> 道</span>
-                <span class="exercise-backet-item">填空题:<span class="exercise-backet-num">{{ basketList.filter(item => item.type === 'Complete').length }}</span> 道</span>
-                <span class="exercise-backet-item">问答题:<span class="exercise-backet-num">{{ basketList.filter(item => item.type === 'Subjective').length }}</span> 道</span>
-                <span class="exercise-backet-item">综合题:<span class="exercise-backet-num">{{ basketList.filter(item => item.type === 'Compose').length }}</span> 道</span>
-            </div>
-            <span class="import-exercise">
-                <Button type="info" @click="goToBank">试题/试卷库</Button>
-                <Badge :count="basketList.length" show-zero>
-                    <Button type="info" @click="onSetPaperInfo" class="exercise-backet" :style="{background: basketList.length ? '#0AAEE7' : '#acaaaa'}">进入组卷中心</Button>
-                </Badge>
-            </span>
-        </div>
-        <!-- 筛选部分结束 -->
-        <!-- 题目列表部分 -->
-        <div v-if="exerciseList.length === 0" class="no-data-text">
-            <img src="../../../assets/icon/no_data.svg" width="120" />
-            <span style="margin-top:15px;color:#808080">暂无数据</span>
-        </div>
-        <div class="content-wrap" v-else>
-            <Loading :top="100" v-show="dataLoading" type="1"></Loading>
-            <div class="exercise-item" v-for="(item,index) of exerciseList" :key="index" @click="onQuestionToggle(index,item.id,$event)">
-                <!-- 题干部分 -->
-                <div class="item-question" style="pointer-events:none">
-                    <p>{{ pageSize * (pageNum - 1) + index + 1 }} : <span v-html="item.question"></span></p>
-                    <span class="item-btn-toggle">
-                        <Icon :type="collapseList.indexOf(index) > -1 ? 'ios-arrow-dropup' : 'ios-arrow-dropdown'" />
-                        <!--<Button type="primary">选题</Button>-->
-                    </span>
-                </div>
-                <!-- 选项部分 -->
-                <div v-for="(option,optionIndex) in item.option" :key="optionIndex" class="item-options" style="pointer-events:none">
-                    <p class="item-option-content">{{String.fromCharCode(64 + parseInt(optionIndex+1))}} : <span v-html="option.value"></span></p>
-                </div>
-                <transition name="slide">
-                    <div v-show="collapseList.indexOf(index) > -1" class="toggle-area">
-                        <!-- 如果是组合题 -->
-                        <div v-for="(childQuestion,childIndex) in item.children" :key="childIndex">
-                            <div v-if="item.children.length">
-                                <div class="item-question">
-                                    <p>{{childIndex+1}} : <span v-html="childQuestion.question"></span></p>
-                                </div>
-                                <div v-for="(childOption,childOptionIndex) in childQuestion.option" :key="childOptionIndex">
-                                    <p>{{String.fromCharCode(64 + parseInt(childOptionIndex+1))}} : <span v-html="childOption.value"></span></p>
-                                </div>
-                                <div class="item-answer" v-show="isShowAnswer">
-                                    <span style="color:#01b4ef">【答案】:</span>
-                                    <span v-html="childQuestion.answer[0] || childQuestion.answer" v-if="childQuestion.type === 'Subjective'"></span>
-                                    <span :class="[ childQuestion.type === 'Complete' ? 'item-answer-item':'']" v-for="(answer,answerIndex) in childQuestion.answer" :key="answerIndex" v-else-if="childQuestion.type === 'Complete'" v-html="answer"></span>
-                                    <span :class="[ childQuestion.type === 'Complete' ? 'item-answer-item':'']" v-for="(answer,answerIndex) in childQuestion.answer" :key="answerIndex" v-else>{{answer}}</span>
-                                </div>
-                                <div class="item-explain" v-show="isShowAnswer">
-                                    <span style="color:#01b4ef">【解析】:</span>
-                                    <span v-html="childQuestion.explain || '暂无解析'"></span>
-                                </div>
-                            </div>
-                        </div>
-                        <!-- 组合题结束 -->
-                        <!-- 答案展示部分 -->
-                        <div class="item-explain" v-show="isShowAnswer">
-                            <span class="explain-title">【答案】</span>
-                            <div class="item-explain-details">
-                                <span v-html="item.answer" v-if="item.type === 'Subjective'"></span>
-                                <span :class="[ item.type === 'Complete' ? 'item-answer-item':'']" v-for="(answer,index) in item.answer" :key="index" v-else-if="item.type === 'Complete'" v-html="answer"></span>
-                                <span :class="[ item.type === 'Complete' ? 'item-answer-item':'']" v-for="(answer,index) in item.answer" :key="index" v-else>{{answer}}</span>
-                            </div>
-                        </div>
-                        <!-- 解析部分 -->
-                        <div class="item-explain" v-show="isShowAnswer">
-                            <span class="explain-title">【解析】</span>
-                            <div class="item-explain-details">
-                                <span v-html="item.explain || '暂无解析'"></span>
-                            </div>
-                        </div>
-                        <!-- 知识点部分 -->
-                        <div class="item-explain" v-show="isShowAnswer">
-                            <span class="explain-title">【知识点】</span>
-                            <div class="item-explain-details">
-                                <span v-html="item.points.length ? item.points : '暂未绑定知识点'"></span>
-                            </div>
-                        </div>
-
-                    </div>
-                </transition>
-
-                <!-- 底部题目操作栏 -->
-                <div class="item-tools">
-                    <span class="item-tools-info">题型:{{ exersicesType[item.type] }}</span>
-                    <span class="item-tools-info">难度:{{ exersicesDiff[item.level - 1] }}</span>
-                    <span class="item-tools-info" style="border:0">使用次数:{{ item.usageCount }} 次</span>
-                    <!--<span class="item-tools-info" style="border:0">更新时间:{{ formatDateTime(new Date(item.createTime * 1000)) }}</span>-->
-                    <!--<Button type="info" :style="{backgroundColor:basketList.all.indexOf(item) > -1 ? '#bbbbbb' : ''}" @click="handleChoose(item)">{{basketList.all.indexOf(item) > -1 ? '已选入' : '选题'}} </Button>-->
-
-                <Button type="info" :style="{background: basketList.map(item => item.id).indexOf(item.id) > -1 ? '#acaaaa' : '#14B6EF'}" @click.stop="selectExercise(item)" style="margin-right:10px">{{ basketList.map(item => item.id).indexOf(item.id) > -1 ? '移除' : '选题' }}</Button>
-                   <!-- <Button type="info" @click.stop="handleEdit(item)" style="margin-right:10px">编辑</Button>-->
-                </div>
-            </div>
-        </div>
-
-        <!-- 底部分页区域 -->
-        <Page :total="totalNum"
-              show-sizer
-              show-total
-              :page-size="pageSize"
-              :current="pageNum"
-              @on-page-size-change="pageSizeChange"
-              @on-change="pageChange"
-              :page-size-opts="[5,10,15,20]" />
-
-        <!-- 完善试卷信息 -->
-        <Modal v-model="setPaperInfoModal"
-               title="新建试卷"
-               footer-hide
-               width="600px">
-            <BasePaperInfo :exerciseList="basketList" :paperInfo="paperInfo" :grades="gradeList"></BasePaperInfo>
-        </Modal>
-    </div>
-</template>
-<script>
-    import Loading from '@/common/Loading.vue'
-    import BasePaperInfo from '../components/BasePaperInfo'
-    import { setTimeout } from 'core-js'
-    export default {
-        components: {
-            Loading, BasePaperInfo
-        },
-        data() {
-            return {
-                userId: 'habook#0001',
-                schoolCode: '',
-                dataLoading: false,
-                exerciseList: [],
-                schoolInfo: {},
-                isShowUploadList: false,
-                setPaperInfoModal: false,
-                exersicesType: {
-                    Single: '单选题',
-                    Multiple: '多选题',
-                    Judge: '判断题',
-                    Complete: '填空题',
-                    Subjective: '问答题',
-                    Compose: '综合题'
-                },
-                exersicesDiff: ['容易', '较易', '一般', '较难', '困难'],
-                diffColors: ['#32CF74', '#E8BE15', '#F19300', '#EB5E00', '#D30000'],
-                filterType: ['all'],
-                filterOrigin: 'habook#0001',
-                filterDiff: ['all'],
-                filterField: ['all'],
-                filterSort: 'createTime',
-                filterPeriod: 0,
-                filterGrade: [false],
-                filterSubject: 0,
-                totalNum: 0,
-                isShowAnswer: true,
-                importLoading: false,
-                pageSize: 5,
-                pageNum: 1,
-                currentPage: 1,
-                collapseList: [],
-                periodList: [],
-                gradeList: [],
-                subjectList: [],
-                basketList: [],
-                filterParams: {},
-                paperInfo: {}
-            }
-        },
-        created() {
-            this.getSchoolInfo()
-        },
-        methods: {
-            /** 获取区班校信息 */
-            getSchoolInfo() {
-                this.$store.dispatch('schoolBaseInfo/getSchoolBaseData').then(res => {
-                    this.schoolInfo = JSON.parse(JSON.stringify(res.data))
-                    this.schoolCode = res.data.schoolCode
-                    this.periodList = res.data.period
-                    this.gradeList = res.data.period[0].grades
-                    this.subjectList = res.data.period[0].subjects
-                    this.doFilter()
-                })
-            },
-
-            /** 执行筛选条件获取数据 */
-            doFilter() {
-                this.dataLoading = true
-                this.collapseList = [] // 所有详情都收起来
-               /** 定义查询接口的参数规格 */
-                this.filterParams = {
-                    '@CURRPAGE': this.pageNum,
-                    '@PAGESIZE': this.pageSize,
-                    '@DESC': this.filterSort,
-                    'scopeCode': this.filterOrigin,
-                    'periodCode': [this.periodList[this.filterPeriod].periodCode],
-                    'gradeCode': this.deleteFalse(this.filterGrade),
-                    'subjectCode': [this.periodList[this.filterPeriod].subjects[this.filterSubject].subjectCode],
-                    'scopeCode': this.filterOrigin,
-                    'level': this.deleteFalse(this.filterDiff),
-                    'type': this.deleteFalse(this.filterType),
-                    'field': this.deleteFalse(this.filterField)
-                }
-
-                /** 查询总数参数 */
-                let findCountParams = {
-                    'collectionName': 'ExamItem',
-                    'queryDict': {
-                        'scopeCode': this.filterOrigin,
-                        'periodCode': [this.periodList[this.filterPeriod].periodCode],
-                        'gradeCode': this.deleteFalse(this.filterGrade),
-                        'subjectCode': [this.periodList[this.filterPeriod].subjects[this.filterSubject].subjectCode],
-                        'scopeCode': this.filterOrigin,
-                        'level': this.deleteFalse(this.filterDiff),
-                        'type': this.deleteFalse(this.filterType),
-                        'field': this.deleteFalse(this.filterField)
-                    }
-                }
-
-                this.getExerciseList(this.filterParams)
-                this.getResultCount(findCountParams)
-            },
-
-            /**
-             * 获取最新题库列表
-             * @param data
-             */
-            getExerciseList(data) {
-                let that = this
-                this.$api.newEvaluation.FindExerciseList(data).then(res => {
-                    this.exerciseList = res.result.data
-                    setTimeout(() => {
-                        that.dataLoading = false
-                    }, 1000)
-                })
-            },
-
-            /**
-             * 获取筛选结果数量
-             * @param data
-             */
-            getResultCount(data) {
-                this.$api.newEvaluation.FindCount(data).then(res => {
-                    this.totalNum = res.result.data[0]
-                })
-            },
-
-            /**
-             * 根据ID获取试题详细数据
-             * @param id 试题ID
-             */
-            getDetailsById(id, index) {
-                this.$api.newEvaluation.FindExerciseById([id]).then(res => {
-                    /* 查询到详细数据则替换掉原数据 */
-                    this.exerciseList.splice(index, 1, res.result.data[0])
-                })
-            },
-
-            /**
-             * 题干展开与收缩
-             * @param index
-             * @param id
-             */
-            onQuestionToggle(index, id, e) {
-                e.stopPropagation()
-                let listIndex = this.collapseList.indexOf(index)
-                if (listIndex > -1) {
-                    this.collapseList.splice(listIndex, 1)
-                } else {
-                    this.collapseList.push(index)
-                    if (!this.exerciseList[index].answer.length) this.getDetailsById(id, index)
-                    this.pageScrollTo(e.target.offsetTop + 420) // content-wrap 距离顶部高度
-                }
-            },
-
-            /**
-             * 筛选学段条件
-             * @param val
-             */
-            filterPeriodChange(val) {
-                // this.filterPeriod = this.periodList[val].periodCode
-                this.gradeList = this.schoolInfo.period[val].grades
-                this.subjectList = this.schoolInfo.period[val].subjects
-                this.filterGrade = [false]
-                this.filterSubject = 0
-                this.pageChange(1)
-            },
-
-            /**
-             * 筛选年级
-             * @param val
-             */
-            filterGradeChange(val) {
-                if (val !== [false] && val.indexOf(false) === 0) {
-                    this.filterGrade.splice(val.indexOf(false), 1)
-                } else if (val.indexOf(false) > 0) {
-                    this.filterGrade = [false]
-                }
-                this.pageChange(1)
-            },
-
-            /**
-             * 筛选科目
-             * @param val
-             */
-            filterSubjectChange(val) {
-                this.pageChange(1)
-            },
-
-            /**
-             * 根据题库加载题目
-             * @param val
-             */
-            filterOriginChange(origin) {
-                this.filterOrigin = origin
-                this.pageChange(1)
-            },
-
-            /**
-             * 筛选题型
-             * @param val
-             */
-            filterTypeChange(val) {
-                if (val !== ['all'] && val.indexOf('all') === 0) {
-                    this.filterType.splice(val.indexOf('all'), 1)
-                } else if (val.indexOf('all') > 0) {
-                    this.filterType = ['all']
-                }
-                this.pageChange(1)
-            },
-
-            /**
-             * 筛选难度
-             * @param val
-             */
-            filterDiffChange(val) {
-                if (val !== ['all'] && val.indexOf('all') === 0) {
-                    this.filterDiff.splice(val.indexOf('all'), 1)
-                } else if (val.indexOf('all') > 0) {
-                    this.filterDiff = ['all']
-                }
-                this.pageChange(1)
-            },
-
-            /**
-             * 筛选认知层次
-             * @param val
-             */
-            filterFieldChange(val) {
-                if (val !== ['all'] && val.indexOf('all') === 0) {
-                    this.filterField.splice(val.indexOf('all'), 1)
-                } else if (val.indexOf('all') > 0) {
-                    this.filterField = ['all']
-                }
-                this.pageChange(1)
-            },
-
-            /**
-             * 排序条件更换
-             * @param val
-             */
-            filterSortChange(val) {
-                this.pageChange(1)
-            },
-
-            /**
-             * 删除筛选条件里面的False值与All值
-             * @param arr
-             */
-            deleteFalse(arr) {
-                let list = JSON.parse(JSON.stringify(arr))
-                list.forEach((item, index) => { if (!item || item === 'all') list.splice(index, 1) })
-                return list
-            },
-
-            /** 返回创建试题页面 */
-            goCreateExercise() {
-                this.$router.push({
-                    name: 'createExercises'
-                })
-            },
-
-            goToBank() {
-                this.$router.push({
-                    name: 'testPaperList'
-                })
-            },
-
-            /**
-             * 切换页码操作
-             * @param page
-             */
-            pageChange(page) {
-                this.pageNum = page
-                this.doFilter()
-                this.pageScrollTo(0)
-            },
-
-            /**
-             * 页面滚动事件
-             * @param scrollDistance 页面滚动距离
-             */
-            pageScrollTo(scrollDistance) {
-                let parentVm = this.$parent.$parent.$parent
-                parentVm.$refs['evScroll'].scrollTo(
-                    {
-                        y: scrollDistance
-                    },
-                    500, 'easeInQuad'
-                )
-            },
-
-            /**
-             * 切换每页显示数量
-             * @param val
-             */
-            pageSizeChange(val) {
-                this.pageSize = val
-                this.pageChange(1)
-            },
-
-            /**
-             * 更新时间日期格式化
-             * @param date
-             */
-            formatDateTime(date) {
-                var y = date.getFullYear()
-                var m = date.getMonth() + 1
-                m = m < 10 ? ('0' + m) : m
-                var d = date.getDate()
-                d = d < 10 ? ('0' + d) : d
-                var h = date.getHours()
-                h = h < 10 ? ('0' + h) : h
-                var minute = date.getMinutes()
-                minute = minute < 10 ? ('0' + minute) : minute
-                var second = date.getSeconds()
-                second = second < 10 ? ('0' + second) : second
-                return y + '-' + m + '-' + d + ' ' + h + ':' + minute + ':' + second
-            },
-
-            /**
-             * 选题
-             * @param item
-             */
-            selectExercise(item) {
-                console.log(item)
-                let index = this.basketList.map(item => item.id).indexOf(item.id)
-                if (index > -1) {
-                    this.basketList.splice(index, 1)
-                } else {
-                    this.$api.newEvaluation.FindExerciseById([item.id]).then(res => {
-                        this.basketList.push(res.result.data[0])
-                    })
-                }
-            },
-
-            // 编辑习题
-            handleEdit(item) {
-                item.options = item.option
-                item.level = item.level || 1
-                this.$router.push({
-                    name: 'createExercises',
-                    params: {
-                        item: item
-                    }
-                })
-            },
-
-            /** 填写试卷基本信息 */
-            onSetPaperInfo() {
-                let list = this.basketList
-                if (!list.length) {
-                    this.$Message.warning('请先选题再进行组卷操作!')
-                } else {
-                    this.setPaperInfoModal = true
-                }
-            },
-
-            // 导入试题
-            uploadSuccess(response, file, fileList) {
-                let that = this
-                this.importLoading = true
-                if (response.error === null) {
-                    let requestData = { htmlString: response.result.data.HtmlString }
-                    this.$api.SaveAnalyzeHtml(requestData).then(res => {
-                        if (res.error === null) {
-                            setTimeout(function() {
-                                that.$Message.success('文件上传解析成功!')
-                                that.exerciseList = res.result.data
-                                that.importLoading = false
-                            }, 1000)
-                            // this.saveItemBank(res.result.data);
-                        }
-                    })
-                } else {
-                    this.$Message.error('对不起,文档解析失败!')
-                }
-            },
-
-            // 保存试题到数据库
-            saveItemBank(list) {
-                this.$api.SaveItemBank(list).then(res => {
-                    console.log(res)
-                })
-            }
-
-        },
-        mounted() {
-            let paperInfo = this.$route.params.paperInfo
-            console.log(paperInfo)
-            if (paperInfo) {
-                this.basketList = paperInfo.item
-                this.paperInfo = paperInfo
-            }
-        },
-        computed: {
-            headers() {
-                let hd = {}
-                hd['Authorization'] = 'Bearer ' + localStorage.getItem('token')
-                return hd
-            }
-        }
-    }
-</script>
-<style scoped>
-    @import "../index/PickExercise.css";
-</style>
-
-<style>
-    .circle {
-        border: solid 1px red;
-        background-color: red;
-        border-radius: 50%;
-        width: 50px;
-        height: 50px;
-    }
-
-    .slide-enter-active {
-        transition: all .3s ease;
-    }
-
-    .slide-leave-active {
-        transition: all .3s ease;
-    }
-
-    .slide-enter, .slide-leave-to {
-        transform: translateY(10px);
-        opacity: 0;
-    }
-</style>

+ 14 - 15
TEAMModelOS/ClientApp/src/view/knowledge-point/index/Index.vue

@@ -113,9 +113,9 @@
                             <span style="margin-left:5px">知识点 ( {{ originPointList.length }} )</span>
                         </span>
                         <div>
-                            <Icon type="md-apps" title="切换到知识点视图" v-if="blockList.length !== 0 && !isShowPoints" color="#fff" size="20" style="cursor:pointer;margin-right:10px" @click="onChangeShowType" />
-                            <Icon type="ios-photos" title="切换到知识块视图" v-if="blockList.length !== 0 && isShowPoints" color="#fff" size="18" style="cursor:pointer;margin-right:10px" @click="onChangeShowType" />
-                            <Icon type="md-add" v-if="($access.can('admin.*|Point_Add') || tabIndex === 1 ) && blockList.length !== 0" color="#fff" size="18" style="cursor:pointer;margin-right:10px" @click="onAddPoint" />
+                            <Icon type="md-apps" title="切换到知识点视图" v-if="!isShowPoints" color="#fff" size="20" style="cursor:pointer;margin-right:10px" @click="onChangeShowType" />
+                            <Icon type="ios-photos" title="切换到知识块视图" v-if="isShowPoints" color="#fff" size="18" style="cursor:pointer;margin-right:10px" @click="onChangeShowType" />
+                            <Icon type="md-add" v-if="($access.can('admin.*|Point_Add') || tabIndex === 1 ) && (blockList.length !== 0 || isShowPoints)" color="#fff" size="18" style="cursor:pointer;margin-right:10px" @click="onAddPoint" />
                             <Icon type="ios-search" v-if="blockList.length !== 0" color="#fff" size="18" style="cursor:pointer" @click="isSearchPoint = true" />
                             <Button class="btn-compose-block" v-if="checkedPointList.length" @click="onComposeBlock">组成知识块</Button>
                         </div>
@@ -206,11 +206,10 @@
         data() {
             return {
                 schoolInfo: {
-                    schoolCode: 'HBCN',
-                    areaCode: '86'
+                    code: 'HBCN'
                 },
                 currentParams: {
-                    scopeCode: '',
+                    code: '',
                     subjectCode: '',
                     period: '',
                     type: 1
@@ -275,12 +274,12 @@
         methods: {
             // 获取当前学校学段学科等基本信息
             initSchoolData() {
-                this.$api.syllabus.GetSchoolInfo(this.schoolInfo).then(res => {
-                    if (!res.error && res.result.data.length) {
-                        this.originSchoolData = res.result.data[0] // 默认选择第一个
-                        this.originData = res.result.data[0] // 默认选择第一个
+                this.$store.dispatch('schoolBaseInfo/getSchoolBaseData').then(res => {
+                    if (res.data) {
+                        this.originSchoolData = res.data// 默认选择第一个
+                        this.originData = res.data // 默认选择第一个
                         this.periodList = this.originData.period
-                        this.currentParams.scopeCode = this.originData.schoolCode
+                        this.currentParams.code = this.originData.schoolCode
                         this.currentParams.period = this.originData.period[0].periodCode
                         this.currentPeriodIndex = 0 // 默认选择第一个学段
                         this.onPeriodChange(0)
@@ -296,7 +295,7 @@
                     this.schoolBlockCount = this.blockCounts[this.currentPeriodIndex].map(i => i[0])
                     this.privateBlockCount = this.blockCounts[this.currentPeriodIndex].map(i => i[1])
                 } else {
-                    this.$api.syllabus.FindBlockCount({ schoolCode: this.schoolInfo.schoolCode }).then(res => {
+                    this.$api.syllabus.FindBlockCount({ code: this.$store.state.userInfo.schoolCode }).then(res => {
                         if (!res.error) {
                             this.$nextTick(() => {
                                 this.blockCounts = res.result.data
@@ -352,12 +351,12 @@
                 this.tabIndex = index
                 switch (index) {
                     case 0:
-                        this.currentParams.scopeCode = this.originData.schoolCode
+                        this.currentParams.code = this.originData.schoolCode
                         //this.isShowPoints ? this.getPointsData() : this.getBlocksData()
                         this.pointOwn = 'school'
                         break
                     case 1:
-                        this.currentParams.scopeCode = 'habook#0001'
+                        this.currentParams.code = this.$store.state.userInfo.TEAMModelId
                         //this.isShowPoints ? this.getPointsData() : this.getBlocksData()
                         this.pointOwn = 'personal'
                         break
@@ -506,7 +505,7 @@
                             if (!res.error && res.result.data) {
                                 this.$Message.success('删除成功')
                                 this.originPointList.splice(this.originPointList.indexOf(data), 1)
-                                this.currentBlock.points.splice(this.currentBlock.points.indexOf(data.id), 1)
+                                if (!this.isShowPoints) this.currentBlock.points.splice(this.currentBlock.points.indexOf(data.id), 1)
                                 this.pageChange(this.currentPage)
                                 this.isLoadPoints = false
                             } else {

+ 1 - 1
TEAMModelOS/ClientApp/src/view/knowledge-point/index/operation/AddBlock.vue

@@ -55,7 +55,7 @@
                         name: this.formTop.name,
                         alias: this.formTop.name,
                         subjectCode: this.formTop.subject,
-                        scopeCode: this.addPointType === 'school' ? this.originDatas.schoolCode : 'habook#0001',
+                        code: this.addPointType === 'school' ? this.originDatas.schoolCode : this.$store.state.userInfo.TEAMModelID,
                         order: 706,
                         status: 1,
                         knowledgeId: this.uuid,

+ 1 - 1
TEAMModelOS/ClientApp/src/view/knowledge-point/index/operation/AddPoint.vue

@@ -54,7 +54,7 @@
                         name: newName,
                         alias: newName,
                         subjectCode: editPointItem ? editPointItem.subjectCode : this.schoolInfos.subjectCode,
-                        scopeCode: this.addPointType === 'school' ? this.schoolInfos.schoolCode : 'habook#0001', // //判断当前添加为校本或者私有知识点
+                        code: this.addPointType === 'school' ? this.schoolInfos.schoolCode : this.$store.state.userInfo.TEAMModelID, // //判断当前添加为校本或者私有知识点
                         order: 706,
                         status: 1,
                         knowledgeId: editPointItem ? editPointItem.knowledgeId : this.uuid,

+ 2 - 2
TEAMModelOS/ClientApp/src/view/knowledge-point/index/operation/ComposeBlock.vue

@@ -73,13 +73,13 @@
                             name: this.newBlockName,
                             alias: this.newBlockName,
                             subjectCode: this.currentParams.subjectCode,
-                            scopeCode: this.currentParams.scopeCode,
+                            code: this.currentParams.code,
                             order: 706,
                             status: 1,
                             knowledgeId: Math.uuid(),
                             period: this.currentParams.period,
                             points: this.checkedList.map(item => item.id),
-                            TEAMModelId: 'habook#000011',
+                            TEAMModelId: this.$store.state.userInfo.TEAMModelID,
                             source: 1
                         }
 

+ 1 - 1
TEAMModelOS/ClientApp/src/view/learnactivity/ManualCreate.vue

@@ -212,7 +212,7 @@
              */
             getResultCount() {
                 let findCountParams = {
-                    "collectionName": "ExamItem",
+                    "collectionName": "ItemInfo",
                     "queryDict": {
                         'scopeCode': this.deleteAll(this.manualFilter.scopeCode),
                         'periodCode': this.deleteAll(this.manualFilter.periodCode),

+ 1 - 1
TEAMModelOS/ClientApp/src/view/learnactivity/ManualPaper.vue

@@ -111,7 +111,7 @@
              */
             getResultCount() {
                 let findCountParams = {
-                    "collectionName": "ExamPaper",
+                    "collectionName": "Paper",
                     "queryDict": {
                         'scopeCode': this.deleteAll(this.manualFilter.scopeCode),
                         'periodCode': this.periodCode,

+ 88 - 9
TEAMModelOS/ClientApp/src/view/newcourse/NewAdminCourse.vue

@@ -219,8 +219,9 @@
                                     <p class="content">{{item.label}}</p>
                                 </div>
                                 <div class="time-action-item">
+                                    <Icon type="md-create" @click="editTimeNode(index)" class="action-btn-icon" color="#DDDDDD" size="18" />
                                     <Icon type="md-add-circle" @click="showAddTime(index)" class="action-btn-icon" color="#19be6b" size="20" />
-                                    <Icon type="md-remove-circle" class="action-btn-icon" color="#ed4014" size="20" />
+                                    <Icon type="md-remove-circle" @click="delTimeNode(index)" class="action-btn-icon" color="#ed4014" size="20" />
                                 </div>
                             </div>
                         </TimelineItem>
@@ -239,10 +240,21 @@
 
         </Modal>
         <Modal v-model="addTimeStatus"
-               title="添加节点"
-               class-name="dark-iview-modal"
-               @on-ok="confirmAddTime">
-
+               :title="status == 0 ? '添加节点' : '编辑节点'"
+               class-name="dark-iview-modal dark-iview-form"
+               @on-ok="confirmAddTime"
+               @on-cancel="cancelTimeNode">
+            <Form ref="timeNode" :model="timeNode" :label-width="100" label-colon :rules="ruleValidate">
+                <FormItem label="节点名称" prop="label">
+                    <Input v-model="timeNode.label" placeholder="输入节点名称......" style="width: 240px"></Input>
+                </FormItem>
+                <FormItem label="开始时间" prop="start">
+                    <TimePicker v-model="timeNode.start" format="HH:mm" placeholder="00:00" style="width: 240px"></TimePicker>
+                </FormItem>
+                <FormItem label="结束时间">
+                    <TimePicker v-model="timeNode.end" format="HH:mm" placeholder="00:00" style="width: 240px"></TimePicker>
+                </FormItem>
+            </Form>
         </Modal>
         <Modal v-model="customGroupStatus"
                :title="$t('courseManage.classroom.autoGroupBtn')"
@@ -445,6 +457,10 @@
                         label: '到校',
                         time:'7:00'
                     },
+                    {
+                        label: '早自习',
+                        time:'8:00 - 8:50'
+                    },
                     {
                         label: '离校',
                         time:'17:00'
@@ -452,20 +468,77 @@
                 ],
                 timeNode: {
                     label: '',
-                    time:''
+                    start: '',
+                    end:''
+                },
+                ruleValidate: {
+                    label: [
+                        { required: true, message: '请输入节点名称......', trigger: 'change' }
+                    ],
+                    start: [
+                        { required: true, message: '请设置时间', trigger: 'change' }
+                    ]
                 },
+                status:0, //0:新增节点 1:编辑节点
                 timeNodeIndex:0
             }
         },
         methods: {
+            //初始化节点数据
+            cancelTimeNode() {
+                this.timeNode.label = ''
+                this.timeNode.start = ''
+                this.timeNode.end = ''
+            },
+            //编辑时间节点
+            editTimeNode(index) {
+                this.status = 1
+                this.timeNodeIndex = index
+                let times = this.schoolTimeTable[index].time.split(' - ')
+                this.timeNode.label = this.schoolTimeTable[index].label
+                this.timeNode.start = times[0]
+                if (times.length > 1) {
+                    this.timeNode.end = times[1]
+                }
+                this.addTimeStatus = true
+            },
+            //删除时间节点
+            delTimeNode(index) {
+                this.schoolTimeTable.splice(index, 1)
+            },
             //显示添加时间节点
             showAddTime(index) {
                 this.addTimeStatus = true
                 this.timeNodeIndex = index
+                this.status = 0
             },
             //确认添加时间节点
             confirmAddTime() {
-                
+                console.log(this.timeNode)
+                this.$refs['timeNode'].validate((valid) => {
+                    if (valid) {
+                        if (this.status == 0) {
+                            let time = this.timeNode.start
+                            if (this.timeNode.end) {
+                                time = time + ' - ' + this.timeNode.end
+                            }
+                            this.schoolTimeTable.splice(this.timeNodeIndex + 1, 0, {
+                                label: this.timeNode.label,
+                                time: time
+                            })
+                        } else {
+                            let time = this.timeNode.start
+                            if (this.timeNode.end) {
+                                time = time + ' - ' + this.timeNode.end
+                            }
+                            this.schoolTimeTable[this.timeNodeIndex].label = this.timeNode.label
+                            this.schoolTimeTable[this.timeNodeIndex].time = time
+                        }
+                        this.cancelTimeNode()
+                    } else {
+                        this.$Message.error('请完善数据,再添加!');
+                    }
+                })
             },
             //显示抽屉设置学校时间安排
             showSettingTime() {
@@ -649,6 +722,7 @@
             closeSelectClassroom() {
                 this.selectSystemStatus = 0
             },
+            //设置分组
             comfirmCustomRules() {
                 if (this.groupNum === 0) {
                     this.$Message.warning('分组数量不能为0')
@@ -670,6 +744,7 @@
                     }
                 }
             },
+            //S分组算法
             orderGroupS() {
                 let surplus = this.classroomStudent.length % this.groupNum// 余数
                 let maxCount = surplus == 0 ? this.classroomStudent.length / this.groupNum : Math.ceil(this.classroomStudent.length / this.groupNum)// 每组最大人数
@@ -688,6 +763,7 @@
                     }
                 }
             },
+            //顺序分组算法
             orderGroup() {
                 let surplus = this.classroomStudent.length % this.groupNum// 余数
                 let maxCount = surplus == 0 ? this.classroomStudent.length / this.groupNum : Math.ceil(this.classroomStudent.length / this.groupNum)// 每组最大人数
@@ -712,6 +788,7 @@
                     }
                 }
             },
+            //随机分组算法
             randomGroup() {
                 let surplus = this.classroomStudent.length % this.groupNum// 余数
                 let surplusCount = surplus// 余数
@@ -748,6 +825,7 @@
             getSelections(selection) {
                 this.selections = selection
             },
+            //设置组别
             setGroup() {
                 if (this.currentGroup == '') {
                     this.$Message.warning('请设置组别')
@@ -771,6 +849,7 @@
             customGroup() {
                 this.customGroupStatus = true
             },
+            //获取系统教室列表
             getClassroomList() {
                 this.$store.dispatch('schoolBaseInfo/getClassroom').then(
                     (res) => {
@@ -788,7 +867,6 @@
             addClassroom(value) {
                 this.selectSystemStatus = value
             },
-
             selectSetIndex(index) {
                 this.currentSetIndex = index
                 if (!this.courseClassroomList[this.currentClassroomIndex].getStatus) {
@@ -902,7 +980,8 @@
         },
         created() {
             this.initData()
-            this.getClassroomList()
+            //this.getClassroomList()
+            this.getCourseInfo()
         },
         computed: {
             courseClassroomList() {

+ 0 - 267
TEAMModelOS/ClientApp/src/view/syllabus/index/KnowPoint.css

@@ -1,267 +0,0 @@
-.know-main {
-    width: 100%;
-    height: 100%;
-    background: #fff;
-    padding: 20px 20px 20px 0;
-    box-sizing: border-box;
-}
-
-
-.content-wrap {
-    width: 100%;
-    height: 100%;
-    border: 2px solid #464646;
-}
-
-.header-wrap {
-    position: relative;
-    width: 100%;
-    height: 50px;
-    display: flex;
-    flex-direction: row;
-    justify-content: space-between;
-    border-bottom: 2px solid #464646;
-}
-
-    .header-wrap .ivu-input {
-        height: 48px;
-        border: 0;
-        padding-left: 15px;
-        border-radius: 0 !important;
-        border-right: 2px solid #464646;
-        font-size: 14px;
-        font-weight: bold;
-        color: #464646;
-    }
-
-        .header-wrap .ivu-input::-webkit-input-placeholder {
-            color: #464646;
-        }
-
-    .header-wrap .ivu-input-suffix i {
-        line-height: 50px;
-    }
-
-.header-right {
-    height: 100%;
-    display: flex;
-    flex-direction: row;
-    justify-content: center;
-    align-items: center;
-}
-
-.header-right-item {
-    margin-right: 25px;
-    font-weight: 500;
-    font-size: 12px;
-    cursor: pointer;
-}
-
-.list-type .ivu-icon {
-    margin-left: 10px;
-    color: rgb(154,154,154);
-    cursor: pointer;
-}
-
-.list-type-active {
-    color: #fff !important;
-    background-color: rgb(154,154,154);
-    border-radius: 50%;
-    padding: 3px;
-}
-
-.sy-list-wrap {
-    width: 100%;
-    height: 100%;
-    display: flex;
-    flex-direction: column;
-    padding-bottom: 50px;
-}
-
-    .sy-list-wrap .knowpoints-filter {
-        width: 100%;
-        height: 50px;
-        border-bottom: 2px solid #464646;
-        margin-bottom: 10px;
-        display: flex;
-        flex-direction: row;
-        align-items: center;
-    }
-
-        .sy-list-wrap .knowpoints-filter span {
-            margin-left: 20px;
-            font-size: 14px;
-            color: rgb(78,78,78);
-            cursor: pointer;
-        }
-
-        .sy-list-wrap .knowpoints-filter .sort-active {
-            color: #000;
-            font-size: 18px;
-            font-weight: bold;
-        }
-
-.list-col {
-    overflow-y: auto;
-    height: 100%;
-}
-
-    .list-col  .ivu-input-wrapper {
-        width: 60%;
-    }
-
-.list-knowpoints {
-    /*padding-top:30px;*/
-}
-
-.sy-list-wrap .ivu-collapse > .ivu-collapse-item > .ivu-collapse-header {
-    height: 100px !important;
-    line-height: 100px !important;
-}
-
-.collapse-header {
-    display: flex;
-    flex-direction: column;
-    justify-content: center;
-}
-
-.know-block-item {
-    width: 100%;
-    display: flex;
-    flex-direction: column;
-    justify-content: center;
-    padding-left: 15px;
-    border-bottom: 1px solid #464646 !important;
-    cursor: pointer;
-}
-
-    .know-block-item:hover {
-        background: #fff;
-    }
-
-    .know-block-item .ivu-icon-ios-arrow-forward {
-        margin-bottom:6px;
-    }
-
-    .know-block-name {
-        font-size: 18px;
-        font-weight: 600;
-    }
-
-.know-block-builder {
-    margin-left: 15px;
-}
-
-.compose-block-tab  .ivu-input {
-    width: 90%;
-}
-
-.compose-block-tab  .ivu-tabs-bar {
-    display: flex;
-    flex-direction: row;
-    justify-content: center;
-}
-
-.compose-block-tab  .ivu-radio-group {
-    display: flex;
-    flex-direction: column;
-    padding-left: 15px;
-}
-
-.compose-block-tab .ivu-radio {
-    margin: 10px;
-}
-
-.compose-block-tab  .ivu-tabs-tabpane {
-    padding-left: 10px;
-    max-height:500px;
-    overflow-y:auto;
-    overflow-x:hidden;
-}
-
-.compose-block-tab .checked-points {
-    display: flex;
-    flex-direction: row;
-    flex-wrap: wrap;
-}
-
-    .compose-block-tab .checked-points .knowpoint-item {
-        padding: 5px 10px;
-        width:auto;
-    }
-
-.modal-title {
-    margin: 10px;
-}
-
-.list-col::-webkit-scrollbar { /*滚动条整体样式*/
-    width: 5px; /*高宽分别对应横竖滚动条的尺寸*/
-    height: 1px;
-}
-
-.list-col:hover .ztree_box::-webkit-scrollbar {
-    width: 5px;
-}
-
-.list-col::-webkit-scrollbar-thumb { /*滚动条里面小方块*/
-    border-radius: 50px;
-    -webkit-box-shadow: inset 0 0 5px rgba(0,0,0,0.2);
-    background: rgb(193,193,193);
-}
-
-.list-col::-webkit-scrollbar-track { /*滚动条里面轨道*/
-    background-color: rgba(244,244,0,0);
-}
-
-.knowpoints {
-    width: 100%;
-    display: flex;
-    flex-direction: row;
-    flex-wrap: wrap;
-    padding: 0 10px;
-}
-
-.knowpoint-item {
-    position: relative;
-    display: flex;
-    width:23%;
-    padding: 10px 20px;
-    margin: 5px;
-    background: rgb(255,255,255);
-    color: #464646;
-    border: 1px solid rgb(216, 216, 216);
-    border-radius: 100px;
-    font-size: 12px;
-    cursor: pointer;
-}
-
-    .knowpoint-item:hover, .knowpoint-item-active {
-        background: rgb(45, 140, 240);
-        color: #fff !important;
-    }
-
-    .knowpoint-item .ivu-icon {
-        margin-left: 5px;
-    }
-
-.k-tools {
-    visibility: hidden;
-}
-
-.k-block-tools {
-    margin-left: 20px;
-    visibility: hidden;
-}
-
-    .k-block-tools .ivu-icon {
-        margin-left: 15px;
-        font-size: 16px;
-    }
-
-.overflow-text {
-    display: inline-block;
-    width: 60%;
-    overflow: hidden;
-    white-space: nowrap;
-    text-overflow: ellipsis;
-}

+ 0 - 695
TEAMModelOS/ClientApp/src/view/syllabus/index/KnowPoint.vue

@@ -1,695 +0,0 @@
-
-<template>
-  <div class="know-main center">
-    <div class="content-wrap">
-      <div class="header-wrap">
-        <Input placeholder="关键词搜索知识点" style="width:25% !important;" />
-        <div class="list-type center">
-          <Icon type="md-menu" size="20" :class="listType==0?'list-type-active':''" @click="changeListType(0)" />
-          <Icon type="ios-keypad" size="20" :class="listType==2?'list-type-active':''" @click="changeListType(2)" />
-          <Icon type="md-cube" size="20" :class="listType==1?'list-type-active':''" @click="changeListType(1)" />
-
-        </div>
-        <div class="header-right">
-          <div class="header-right-item" @click="addPoint" v-show="listType === 2">
-            <Icon type="logo-buffer" size="18" />
-            <span>新增知识点</span>
-          </div>
-          <div class="header-right-item" @click="composeBlock" v-show="listType === 2">
-            <Icon type="logo-buffer" size="18" />
-            <span>组成知识块</span>
-          </div>
-          <div class="header-right-item" @click="addBlock" v-show="listType===0">
-            <Icon type="ios-browsers" size="18" />
-            <span>新增知识块</span>
-          </div>
-          <div class="header-right-item">
-            <Icon type="ios-cloud-download" size="18" />
-            <span>导入知识点</span>
-          </div>
-        </div>
-      </div>
-      <div class="sy-list-wrap">
-        <!-- 知识块 -->
-        <div class="list-col" v-if="listType === 0">
-          <Spin fix v-show="blockLoading"></Spin>
-          <!--<p style="font-size:20px;padding:10px 30px;font-weight:bold;border-bottom:1px solid #000">私有知识块仓库</p>-->
-          <Collapse simple accordion @on-change="collapseChange" v-if="knowBlockList.length > 1">
-            <Panel v-for="(item,index) in knowBlockList" class="know-block-item" :key="index" :name="item.period">
-              <Input v-if="item.knowledgeId===block_edit_id" :ref="'block'+item.knowledgeId" clearable type="text" v-model="item.alias"
-                     @on-blur="editKnowBlock(item)"
-                     @keyup.enter.native="$event.target.blur"
-                     @click.stop.native="inputFocus($event)" />
-              <span class="know-block-name" v-else>{{item.alias}} | {{item.children.length}}</span>
-
-              <span class="know-block-builder">建立者 | 郭大侠</span>
-              <span class="k-block-tools">
-                <Icon type="md-create" @click="handleEditBlock(item,$event)" title="编辑名称" />
-                <Icon type="md-add-circle" title="编辑知识点" @click.stop.native="editBlockPoint(item)" />
-                <Icon type="md-trash" @click="handleDeleteBlock(item)" title="删除" />
-              </span>
-              <div slot="content" class="knowpoints">
-                <div class="knowpoint-item" v-for="(point,index) in item.children" :key="index" @mouseover="knowMouseover" @mouseout="knowMouseout">
-                  <Input v-if="point.rowKey===point_edit_id" :ref="'point'+point.rowKey" clearable type="text" v-model="point.alias"
-                         @on-blur="editKnowPoint(point)"
-                         @keyup.enter.native="$event.target.blur"
-                         @click.stop.native="inputFocus($event)" />
-                  <span v-else class="overflow-text" :title="point.alias">{{point.alias}} </span>
-                  <span class="k-tools">
-                    <Icon type="md-create" @click="handleEditPoint(point,$event)" />
-                    <Icon type="md-trash" @click.stop.native="handleDeleteBlockPoint(point)" />
-                  </span>
-                </div>
-              </div>
-            </Panel>
-          </Collapse>
-          <div v-else class="no-data-text">暂无数据</div>
-        </div>
-
-        <!-- 标准知识块 -->
-        <div class="list-col" v-else-if="listType === 1">
-          <Spin fix v-show="standardLoading"></Spin>
-          <p style="font-size:20px;margin:20px 40px;font-weight:bold;">标准知识块数据</p>
-          <KnowTree :treeDatas="treeData" v-if="treeData.length > 0"></KnowTree>
-          <div v-else class="no-data-text">暂无数据</div>
-        </div>
-
-        <!-- 知识点仓库 -->
-        <div class="list-col list-knowpoints" v-else>
-          <Spin fix v-show="allPointsLoading"></Spin>
-          <p style="font-size:20px;margin:20px 30px;font-weight:bold;">私有知识点仓库</p>
-
-          <!--<div class="knowpoints-filter">
-      <span :class="filter_index == 0 ? 'sort-active':''" @click="filterSort(0)">综合排序</span>
-      <span :class="filter_index == 1 ? 'sort-active':''" @click="filterSort(1)">名称排序</span>
-      <span :class="filter_index == 2 ? 'sort-active':''" @click="filterSort(2)">创建时间排序</span>
-    </div>-->
-          <div class="knowpoints">
-            <div v-for="(item,index) in knowPointList" :key="index" :class="['knowpoint-item',pointCheckedList.indexOf(item) !== -1?'knowpoint-item-active':'']" :title="item.description" @mouseover="knowMouseover" @mouseout="knowMouseout" @click="pointClick(item)">
-              <Input v-if="item.knowledgeId===point_edit_id" :ref="'point'+item.knowledgeId" clearable type="text" v-model="item.alias"
-                     @on-blur="editSchoolPoint(item)"
-                     @keyup.enter.native="$event.target.blur"
-                     @click.stop.native="inputFocus($event)" />
-              <span v-else class="overflow-text" :title="item.alias">{{item.alias}} </span>
-              <!--<Icon type="ios-checkmark-circle" color="#00fa00" class="icon-checked"/>-->
-              <span class="k-tools">
-                <Icon type="md-create" @click="handleEditPoint(item,$event)" />
-                <Icon type="md-trash" @click.stop.native="handleDeleteSchoolPoint(item)" />
-              </span>
-            </div>
-          </div>
-          <Page show-total
-                :current="1"
-                :total="schoolAllPoint.length"
-                :page-size="pageSize"
-                class="center"
-                @on-change="pageChange"
-                style="margin:20px 0" />
-        </div>
-
-        <!-- 新增知识块弹窗 -->
-        <Modal v-model="addBlockModal"
-               title="新增知识块"
-               width="520"
-               ok-text="确认"
-               cancel-text="取消"
-               @on-ok="handleAddBlock">
-          <p class="modal-title">请输入知识块名称</p>
-          <Input v-model="newBlockName" placeholder="知识块 名称" style="margin:5px;width:90%" />
-        </Modal>
-
-        <!-- 新增知识点弹窗 -->
-        <Modal v-model="addPointModal"
-               title="新增知识点"
-               width="520"
-               ok-text="确认"
-               cancel-text="取消"
-               @on-ok="handleAddPoint">
-          <p class="modal-title">请输入知识点名称</p>
-          <Input v-model="newPointName" placeholder="输入名称" style="margin:5px" />
-        </Modal>
-
-        <!-- 编辑知识块弹窗 Transfer -->
-        <Modal v-model="editBlockPointModal"
-               title="编辑知识块"
-               width="600"
-               ok-text="确认"
-               cancel-text="取消"
-               class-name="transferModal"
-               @on-ok="handleTransferBlock">
-          <Transfer :data="data3"
-                    :target-keys="targetKeys"
-                    :list-style="listStyle"
-                    :render-format="renderTransfer"
-                    :operations="['撤回知识库','加入知识块']"
-                    filter-placeholder="请输入搜索内容"
-                    :titles="[transferStatus?'私有知识库':'标准知识库', '当前知识块']"
-                    not-found-text="列表为空"
-                    filterable
-                    :filter-method="filterMethod"
-                    @on-change="handleChangeTransfer">
-            <div :style="{float: 'right', margin: '5px'}">
-              <Button size="small" type="primary" @click="changePointData(!transferStatus)" class="transferBtn">{{ transferStatus ? '从标准库添加': "从私有库添加"}}</Button>
-              <Button size="small" @click="reloadPointData(transferStatus)">刷新</Button>
-            </div>
-          </Transfer>
-        </Modal>
-
-        <!-- 组成知识块弹窗 Tabs -->
-        <Modal v-model="composeBlockModal"
-               title="组成知识块"
-               width="400"
-               ok-text="确认"
-               cancel-text="取消"
-               @on-ok="handleComposeBlock">
-          <Tabs v-model="composeTabName" class="compose-block-tab">
-            <TabPane label="建立新的知识块" name="newBlock">
-              <p class="modal-title">请输入知识块名称</p>
-              <Input v-model="newComposeName" placeholder="请输入" style="margin:5px" />
-              <p class="modal-title">当前选中知识点</p>
-              <div class="checked-points">
-                <div v-for="(item,index) in pointCheckedList" :key="index" class="knowpoint-item knowpoint-item-active">{{item.name}}</div>
-              </div>
-            </TabPane>
-            <TabPane label="移动到现有知识块" name="moveToBlock">
-              <RadioGroup v-model="checkedBlock">
-                <Radio v-for="(item,index) in knowBlockList" :key="index"  :label="item.knowledgeId"  :name="item.rowKey">{{item.name}}</Radio>
-              </RadioGroup>
-            </TabPane>
-          </Tabs>
-        </Modal>
-
-      </div>
-    </div>
-  </div>
-</template>
-
-<script scoped>
-    import KnowTree from '@/components/syllabus/KnowTree.vue'
-  export default {
-    name: 'KnowPoint',
-    components: {
-      KnowTree
-    },
-    data() {
-      return {
-        treeData: [],
-        schoolInfo: {},
-        allPointList: [],
-        schoolAllPoint: [],
-        knowPointList: [],
-        knowBlockList: [],
-        pointCheckedList: [],
-        checkedBlock: '知识块名称0',
-        isShowBlock: false,
-        standardLoading: true,
-        allPointsLoading: true,
-        blockLoading: true,
-        listType: 0,
-        filter_index: 0,
-        pageSize: 52,
-        newBlockName: '',
-        newPointName: '',
-        newComposeName: '',
-        block_edit_id: null, // 当前知识块编辑索引
-        point_edit_id: null, // 当前知识点编辑索引
-        point_click_id: null,
-        addBlockModal: false, // 新增知识块开关
-        addPointModal: false, // 新增知识点开关
-        editBlockPointModal: false, // 编辑知识块开关
-        composeBlockModal: false, // 编辑知识块开关
-        composeTabName: 'newBlock',
-        currentEditBlock: {},
-        data3: [],
-        targetKeys: [],
-        listStyle: {
-          width: '220px',
-          height: '420px'
-        },
-        transferStatus: false
-      }
-    },
-    created() {
-      this.schoolInfo = JSON.parse(localStorage.getItem('c_role_info')).roleClaim[0] // 默认选中第一个学校
-      let schoolClaims = this.schoolInfo.claim
-      for (let i in schoolClaims) {
-        if (schoolClaims[i].claimType === 'SchoolCode') {
-          this.schoolInfo = schoolClaims[i]
-        }
-      }
-
-      // 获取标准知识块数据
-      this.getStandardList()
-      this.getAllPoints()
-      this.getSchoolBlocks()
-      this.getSchoolPoints()
-    },
-    methods: {
-      // 获取标准知识块数据
-      getStandardList() {
-        let data = {
-          periods: ['Period_21'],
-          pointParams: {
-              SubjectCode: 'Subject_Chinese',
-              PartitionKey: 'zh-CN'
-            }
-        }
-        this.$api.FindKnowledgeBlockAndPointByDict(data).then(res => {
-          let list = res.result.data
-          this.treeData = list
-          this.standardLoading = false
-        })
-      },
-
-      // 获取标准知识点仓库数据
-      getAllPoints() {
-         let data = {
-          pointParams: {
-              SubjectCode: 'Subject_Chinese',
-              PartitionKey: 'zh-CN'
-            }
-        }
-        this.$api.FindKnowledgePointByDict(data).then(res => {
-          this.allPointList = res.result.data
-        })
-      },
-
-      // 获取学校知识点仓库数据
-      getSchoolPoints() {
-        this.allPointsLoading = true
-         let data = {
-              SubjectCode: 'Subject_Chinese',
-              PartitionKey: 'zh-CN',
-              SchoolCode: this.schoolInfo.claimCode,
-              Status: 1
-        }
-        this.$api.FindSchoolPointByDict(data).then(res => {
-          this.schoolAllPoint = res.result.data
-          this.knowPointList = res.result.data.slice(0, this.pageSize)
-          this.allPointsLoading = false
-        })
-      },
-
-      // 获取学校知识块数据
-      getSchoolBlocks() {
-         this.blockLoading = true
-         let data = {
-          pointParams: {
-              SubjectCode: 'Subject_Chinese',
-             PartitionKey: this.schoolInfo.partitionKey,
-             SchoolCode: this.schoolInfo.claimCode,
-             Status: 1
-            }
-        }
-        this.$api.FindSchoolBlockAndPointByDict(data).then(res => {
-          this.knowBlockList = res.result.data
-          this.blockLoading = false
-        })
-      },
-
-      // 切换页码返回截取数据
-      pageChange(page) {
-        let start = this.pageSize * (page - 1)
-        let end = this.pageSize * page
-        this.knowPointList = this.schoolAllPoint.slice(start, end)
-      },
-
-      // 知识点与知识块切换
-      changeListType(status) {
-        this.listType = status
-        this.isShowBlock = status === 0
-        if (status === 0) {
-          this.getSchoolBlocks()
-        } else if (status === 1) {
-          this.getStandardList()
-        } else {
-          this.getSchoolPoints()
-        }
-      },
-      // 鼠标滑入事件显示操作选项
-      knowMouseover(e) {
-        e.stopPropagation()
-        e.currentTarget.lastElementChild.style.visibility = 'visible'
-      },
-      // 鼠标滑出事件隐藏操作选项
-      knowMouseout(e) {
-        e.stopPropagation()
-        e.currentTarget.lastElementChild.style.visibility = 'hidden'
-      },
-      // 折叠版切换回调
-      collapseChange(arr) {
-        this.block_edit_id = null
-          let list = document.getElementsByClassName('k-block-tools')
-          for (let i = 0; i < list.length; i++) {
-            if (arr.indexOf(i.toString()) !== -1) {
-              list[i].style.visibility = 'visible'
-            } else {
-              list[i].style.visibility = 'hidden'
-            }
-        }
-      },
-      // 知识点仓库排序操作
-      filterSort(index) {
-        this.filter_index = index
-      },
-
-      // 点击编辑知识块
-      handleEditBlock(data, e) {
-        e.stopPropagation()
-        this.block_edit_id = data.knowledgeId
-        this.$nextTick(() => {
-          this.$refs['block' + data.knowledgeId][0].focus()
-        })
-      },
-      // 编辑知识块input失焦
-      editKnowBlock(data) {
-        delete data.rowKey
-        this.$api.SaveOrUpdateSchoolBlock(data).then(res => {
-          if (res.result.message === 'Success') {
-            this.$Message.success('修改成功')
-          }
-        })
-        this.block_edit_id = null
-      },
-
-      // 点击编辑知识点
-      handleEditPoint(data, e) {
-        e.stopPropagation()
-        this.point_edit_id = data.knowledgeId
-        this.$nextTick(() => {
-          this.$refs['point' + data.knowledgeId][0].focus()
-        })
-      },
-      // 编辑知识块包含的知识点input失焦
-      editKnowPoint(data) {
-        this.$api.SaveOrUpdateAllSchoolBlockPoint([data]).then(res => {
-          if (res.result.message === 'Success') {
-            this.$Message.success('修改成功')
-          }
-        })
-        this.point_edit_id = null
-      },
-
-      // 编辑学校知识点input失焦
-      editSchoolPoint(data) {
-        this.$api.SaveOrUpdateAllSchoolPoint(data).then(res => {
-          if (res.result.message === 'Success') {
-            this.$Message.success('修改成功')
-          }
-        })
-        this.point_edit_id = null
-      },
-
-      // input聚焦
-      inputFocus(e) {
-        e.cancelBubble = true
-      },
-
-      // 点击新增知识块弹窗
-      addBlock() {
-        this.addBlockModal = true
-      },
-
-       // request新增知识块
-      handleAddBlock() {
-        if (this.newBlockName && this.newBlockName.replace(/\s*/g, '').length !== 0) {
-          let addBlockData = {
-            schoolCode: this.schoolInfo.claimCode,
-            subjectCode: 'Subject_Chinese',
-            partitionKey: this.schoolInfo.partitionKey,
-            knowledgeId: this.$tools.guid(),
-            name: this.newBlockName,
-            alias: this.newBlockName,
-            pid: 'Root',
-            order: 0,
-            type: 0,
-            source: 1
-          }
-          this.$api.SaveOrUpdateSchoolBlock(addBlockData).then(res => {
-            this.getSchoolBlocks()
-          })
-        } else {
-          this.$Message.warning('名称不能为空!')
-        }
-          this.newBlockName = ''
-      },
-
-      // 点击新增知识块弹窗
-      addPoint() {
-        this.addPointModal = true
-      },
-      // 点击组成知识块弹窗
-      composeBlock() {
-        if (this.pointCheckedList.length < 1) {
-          this.$Message.info('请先勾选需要操作的知识点!')
-        } else {
-          this.composeBlockModal = true
-          this.checkedBlock = this.knowBlockList[0].knowledgeId
-        }
-      },
-      // 点击编辑知识块弹窗
-      editBlockPoint(data) {
-        this.currentEditBlock = data
-        this.data3 = this.getPointList(this.transferStatus)
-        this.targetKeys = this.getTargetKeys()
-        this.editBlockPointModal = true
-        this.reloadPointData(this.transferStatus)
-        document.getElementsByClassName('transferBtn')[1].style.display = 'none'
-      },
-
-      // request-新增知识点
-      handleAddPoint() {
-        if (this.newPointName && this.newPointName.replace(/\s*/g, '').length !== 0) {
-        let addPointData = {
-          schoolCode: this.schoolInfo.claimCode,
-          subjectCode: 'Subject_Chinese',
-          partitionKey: this.schoolInfo.partitionKey,
-          knowledgeId: this.$tools.guid(),
-          name: this.newPointName,
-          alias: this.newPointName,
-          pid: 'Root',
-          order: 0,
-          type: 0,
-          source: 1
-        }
-        this.$api.SaveOrUpdateAllSchoolPoint(addPointData).then(res => {
-          this.getSchoolPoints()
-        })
-          } else {
-          this.$Message.warning('名称不能为空!')
-        }
-        this.newPointName = ''
-      },
-      // request-编辑知识块
-      handleEditBlockPoint() {
-        console.log(this.targetKeys)
-      },
-
-      // request-组成知识块
-      handleComposeBlock() {
-        let datas = []
-        let pointCheckedList = this.pointCheckedList
-        if (this.composeTabName === 'newBlock' && this.newComposeName && this.newComposeName.replace(/\s*/g, '').length !== 0) {
-          let addBlockData = {
-            schoolCode: this.schoolInfo.claimCode,
-            subjectCode: 'Subject_Chinese',
-            partitionKey: this.schoolInfo.partitionKey,
-            knowledgeId: this.$tools.guid(),
-            name: this.newComposeName,
-            alias: this.newComposeName,
-            pid: 'Root',
-            order: 0,
-            type: 0,
-            source: 1
-          }
-          this.$api.SaveOrUpdateSchoolBlock(addBlockData).then(res => {
-            for (let i in pointCheckedList) {
-              let point = pointCheckedList[i]
-              point.type = point.type || 1
-              point.knowledgeId = point.knowledgeId || point.rowKey
-              point.alias = point.alias || point.name
-              point.pid = res.result.data.knowledgeId
-              point.schoolCode = point.schoolCode || this.schoolInfo.claimCode
-              point.source = this.transferStatus ? '1' : '0'
-              point.status = 1
-              delete point.rowKey
-              datas.push(point)
-            }
-            this.$api.SaveOrUpdateAllSchoolBlockPoint(datas).then(res => {
-              if (res.result.message === 'Success') {
-                this.$Message.success('添加成功')
-                this.changeListType(0)
-              }
-            })
-          })
-        } else if (this.composeTabName === 'moveToBlock') {
-          for (let i in pointCheckedList) {
-            let point = pointCheckedList[i]
-            point.type = point.type || 1
-            point.knowledgeId = point.knowledgeId || point.rowKey
-            point.alias = point.alias || point.name
-            point.pid = this.checkedBlock
-            point.schoolCode = point.schoolCode || this.schoolInfo.claimCode
-            point.source = this.transferStatus ? '1' : '0'
-            point.status = 1
-            delete point.rowKey
-            datas.push(point)
-          }
-          this.$api.SaveOrUpdateAllSchoolBlockPoint(datas).then(res => {
-            if (res.result.message === 'Success') {
-              this.$Message.success('添加成功')
-              this.changeListType(0)
-            }
-          })
-        } else if (this.composeTabName === 'newBlock' && !this.newComposeName && this.newComposeName.replace(/\s*/g, '').length === 0) {
-            this.$Message.warning('名称不能为空!')
-        }
-        this.newComposeName = ''
-        this.pointCheckedList = []
-      },
-
-      pointClick(data) {
-        // this.point_click_id = data.id;
-        let list = this.pointCheckedList
-        if (list.indexOf(data) === -1) {
-          list.push(data)
-        } else {
-          list.splice(list.indexOf(data), 1)
-        }
-      },
-      // 获取transfer的知识点数据源
-      getPointList(status) {
-        let mockData = []
-        let list = status ? this.schoolAllPoint : this.allPointList
-        for (let i = 0; i < list.length; i++) {
-          mockData.push({
-            id: i,
-            key: i.toString(),
-            label: i.toString(),
-            name: list[i].name,
-            termNum: i + 5,
-            blockId: i + 1,
-            description: list[i].name
-          })
-        }
-        return mockData
-      },
-      getTargetKeys() {
-        let targetArr = []
-        return targetArr
-      },
-      handleChangeTransfer(newTargetKeys) {
-        this.targetKeys = newTargetKeys
-      },
-      renderTransfer(item) {
-        return item.name
-      },
-      // 重置数据
-      reloadPointData(status) {
-        this.data3 = this.getPointList(status)
-        this.targetKeys = this.getTargetKeys()
-      },
-      // 切换数据源
-      changePointData(status) {
-        this.data3 = this.getPointList(status)
-        this.targetKeys = this.getTargetKeys()
-        this.transferStatus = status
-      },
-      // 确认编辑知识块
-      handleTransferBlock() {
-        let datas = []
-        let list = this.transferStatus ? this.schoolAllPoint : this.allPointList
-        let keys = this.targetKeys
-        for (let i in keys) {
-          let point = list[keys[i]]
-          point.type = point.type || 1
-          point.knowledgeId = point.knowledgeId || point.rowKey
-          point.alias = point.alias || point.name
-          point.pid = this.currentEditBlock.knowledgeId
-          point.schoolCode = point.schoolCode || this.schoolInfo.claimCode
-          point.source = this.transferStatus ? '1' : '0'
-          point.status = 1
-          delete point.rowKey
-          datas.push(point)
-        }
-        this.$api.SaveOrUpdateAllSchoolBlockPoint(datas).then(res => {
-          this.$Message.success('添加成功')
-          this.getSchoolBlocks()
-        })
-      },
-      // transfer Input 筛选数据
-      filterMethod(data, query) {
-        let val = data.name
-        return val.toUpperCase().indexOf(query.toUpperCase()) > -1
-      },
-
-      // 删除知识块中的知识点
-      handleDeleteBlockPoint(data) {
-         this.$Modal.confirm({
-          title: '移除知识点',
-          content: '<p>确认移除该知识点吗?</p>',
-          okText: '确认',
-          cancelText: '取消',
-           onOk: () => {
-             let params = {
-               PartitionKey: data.partitionKey,
-               RowKey: data.rowKey,
-               KnowledgeId: data.knowledgeId,
-               SubjectCode: data.subjectCode,
-               SchoolCode: data.schoolCode
-             }
-            this.$api.RemoveSchoolBlockPoint(params).then(res => {
-              this.getSchoolBlocks()
-            })
-          },
-          onCancel: () => {
-            // this.$Message.info('Clicked cancel');
-          }
-        })
-      },
-
-      // 删除知识块
-      handleDeleteBlock(data) {
-         this.$Modal.confirm({
-          title: '移除知识块',
-          content: '<p>确认移除该知识块吗?</p>',
-          okText: '确认',
-          cancelText: '取消',
-           onOk: () => {
-             data.status = 0
-            this.$api.SaveOrUpdateSchoolBlock(data).then(res => {
-              if (res.result.message === 'Success') {
-                this.$Message.success('修改成功')
-                this.getSchoolBlocks()
-                }
-            })
-          },
-          onCancel: () => {
-            this.$Message.info('Clicked cancel')
-          }
-        })
-      },
-      // 删除知识块
-      handleDeleteSchoolPoint(data) {
-         this.$Modal.confirm({
-          title: '移除知识点',
-          content: '<p>确认移除该知识点吗?</p>',
-          okText: '确认',
-          cancelText: '取消',
-           onOk: () => {
-             data.status = 0
-            this.$api.SaveOrUpdateAllSchoolPoint(data).then(res => {
-              if (res.result.message === 'Success') {
-                this.$Message.success('修改成功')
-                this.getSchoolPoints()
-                }
-            })
-          },
-          onCancel: () => {
-            // this.$Message.info('Clicked cancel');
-          }
-        })
-      }
-    }
-  }
-</script>

+ 0 - 263
TEAMModelOS/ClientApp/src/view/syllabus/index/Syllabus.css

@@ -1,263 +0,0 @@
-.syllabus-main {
-    width: 100%;
-    height: 100%;
-    background: #fff;
-    padding: 20px;
-    box-sizing: border-box;
-}
-
-.subject-modal  .ivu-checkbox {
-    margin: 10px;
-}
-
-.subject-modal  .ivu-select {
-    margin: 0 10px;
-}
-
-.subject-modal .ivu-input {
-    margin: 0 10px;
-}
-
-.list-wrap {
-    width: 100%;
-    height: 100%;
-    display: flex;
-    flex-direction: row;
-    padding-bottom: 50px;
-}
-
-.list-col {
-    position: relative;
-    height: 100%;
-    overflow-y: auto;
-}
-
-    .list-col .ivu-input-wrapper {
-        width: 60%;
-    }
-
-.term-userNum  .ivu-input-wrapper {
-    width: 100%;
-}
-
-.pop-content .ivu-checkbox-group {
-    display: flex;
-    flex-direction: column;
-    margin-top: 20px;
-}
-
-.pop-content .ivu-checkbox-group-item {
-    margin: 5px 10px;
-}
-
-.pop-content .ivu-checkbox {
-    margin-right: 10px;
-}
-
-.pop-content .ivu-tabs-tabpane {
-    max-height: 300px;
-    overflow: auto;
-}
-
-.list-left {
-    width: 15%;
-    background-color: rgb(204,204,204);
-    margin-right: 0px;
-}
-
-.list-middle {
-    width: 25%;
-    background-color: rgb(230,230,230);
-    border-left: 2px solid #464646;
-    border-right: 1px solid #464646;
-}
-
-.list-right {
-    width: 60%;
-    background-color: rgb(242,242,242);
-}
-
-.subject-item {
-    width: 100%;
-    height: 80px;
-    display: flex;
-    flex-direction: column;
-    justify-content: center;
-    padding-left: 15px;
-    border-bottom: 1px solid #464646;
-    cursor: pointer;
-}
-
-    .subject-item:hover {
-        background: #fff;
-    }
-
-.subject-name {
-    font-size: 18px;
-    font-weight: 600;
-}
-
-.term-item {
-    height: auto;
-    padding: 10px;
-}
-
-.term-item-active {
-    background: #fff;
-}
-
-.term-period {
-    margin: 5px 0;
-    font-size: 14px;
-}
-
-.term-name-title {
-    font-size: 18px;
-    font-weight: 600;
-}
-
-.term-add-user {
-    text-decoration: underline;
-    cursor: pointer;
-}
-
-.term-users {
-    width: 100%;
-    background: #fff;
-    display: flex;
-    flex-direction: row;
-    flex-wrap: wrap;
-    margin-top: 10px;
-}
-
-.term-user-item {
-    padding: 5px;
-    margin: 5px;
-}
-
-.term-user-img {
-    width: 20px;
-    height: 20px;
-    border-radius: 50%;
-}
-
-.term-user-name {
-    margin-left: 5px;
-    color: rgb(139, 139, 139);
-}
-
-.centerCol {
-    display: flex;
-    flex-direction: column;
-    justify-content: center;
-    align-items: center;
-}
-
-.center {
-    display: flex;
-    flex-direction: row;
-    justify-content: center;
-    align-items: center;
-}
-
-.list-col::-webkit-scrollbar { /*滚动条整体样式*/
-    width: 0px; /*高宽分别对应横竖滚动条的尺寸*/
-    height: 1px;
-}
-
-.list-col:hover .ztree_box::-webkit-scrollbar {
-    width: 5px;
-}
-
-.list-col::-webkit-scrollbar-thumb { /*滚动条里面小方块*/
-    border-radius: 10px;
-    -webkit-box-shadow: inset 0 0 5px rgba(0,0,0,0.2);
-    background: #ffffff26;
-}
-
-.list-col::-webkit-scrollbar-track { /*滚动条里面轨道*/
-    background: #f4f4f400;
-}
-
-.s-block-tools {
-    margin-left: 10px;
-}
-
-    .s-block-tools .ivu-icon {
-        margin-left: 5px;
-        margin-bottom: 2px;
-        font-size: 16px;
-        color: rgb(185, 185, 185);
-    }
-
-.modal-title {
-    margin: 10px 5px;
-}
-
-.animated {
-    animation-duration: 0.2s;
-}
-
-@-webkit-keyframes slideInDown {
-    from {
-        -webkit-transform: translate3d(0,-40%, 0);
-        transform: translate3d(0, -40%, 0) !important;
-        visibility: visible;
-    }
-
-    to {
-        -webkit-transform: translate3d(0, 0%, 0);
-        transform: translate3d(0, 0%, 0);
-    }
-}
-
-@keyframes slideInDown {
-    from {
-        -webkit-transform: translate3d(0, -20%, 0);
-        transform: translate3d(0, -20%, 0) !important;
-        visibility: visible;
-    }
-
-    to {
-        -webkit-transform: translate3d(0, 0%, 0);
-        transform: translate3d(0, 0%, 0);
-    }
-}
-
-.slideInDown {
-    -webkit-animation-name: slideInDown;
-    animation-name: slideInDown;
-}
-
-.d-none {
-    display: none;
-}
-
-.syllabus-main .no-data-text {
-    margin: 20px;
-    font-size: 16px;
-}
-
-.demo-spin-icon-load {
-    animation: ani-demo-spin 1s linear infinite;
-}
-
-@keyframes ani-demo-spin {
-    from {
-        transform: rotate(0deg);
-    }
-
-    50% {
-        transform: rotate(180deg);
-    }
-
-    to {
-        transform: rotate(360deg);
-    }
-}
-
-.demo-spin-col {
-    height: 100px;
-    position: relative;
-    border: 1px solid #eee;
-}

+ 0 - 569
TEAMModelOS/ClientApp/src/view/syllabus/index/Syllabus.vue

@@ -1,569 +0,0 @@
-
-<template>
-  <div class="syllabus-main center">
-    <div class="content-wrap">
-      <div class="header-wrap">
-        <Input placeholder="关键词搜索课纲" style="width:15.1% !important;" />
-        <div class="header-right">
-          <div class="header-right-item" @click="addSubject">
-            <Icon type="logo-buffer" size="18" />
-            <span>新增科目</span>
-          </div>
-          <div class="header-right-item" @click="addTerm" v-if="currentSubjectList.length > 0">
-            <Icon type="ios-browsers" size="18" />
-            <span>新增册别</span>
-          </div>
-          <div class="header-right-item" @click="addSyllabus" v-if="currentSubjectList.length > 0">
-            <Icon type="ios-browsers" size="18" />
-            <span>新增课纲</span>
-          </div>
-          <div class="header-right-item">
-            <Icon type="ios-cloud-download" size="18" />
-            <span>导入课纲</span>
-          </div>
-        </div>
-      </div>
-      <div class="list-wrap">
-        <!-- 左边科目列表 -->
-        <div class="list-col list-left">
-          <Spin fix v-show="subjectLoading"></Spin>
-          <template v-if="currentSubjectList.length > 0">
-            <div v-for="(item,index) in currentSubjectList" :key="index" :class='["subject-item", item.rowKey===s_click_id ? "term-item-active" : ""]' @click="subjectClick(item)">
-              <span class="subject-name">
-                <Input v-if="item.rowKey===c_edit_id" clearable type="text" v-model="item.name"
-                       @on-blur="editSubject(item)"
-                       @keyup.enter.native="$event.target.blur"
-                       @click.stop.native="inputFocus($event)" />
-                <span v-else>{{item.name}}</span>
-
-                <span class="s-block-tools" v-show="item.rowKey===c_subject_id">
-                  <Icon type="md-create" @click="handleEditSubject(item,$event)" />
-                  <Icon type="md-trash" @click="handleDeleteSubject(item)" />
-                </span>
-              </span>
-              <span class="subject-term-num">册数 | {{item.termNum?item.termNum:0}}</span>
-            </div>
-          </template>
-          <div v-else class="no-data-text">暂无数据</div>
-        </div>
-        <!-- 中间册别列表 -->
-        <div class="list-col list-middle">
-          <Spin fix v-show="volumesLoading"></Spin>
-          <template v-if="volumesList.length > 0">
-            <div v-for="(item,index) in volumesList" :key="index" :class='["subject-item", "term-item", item.rowKey===c_click_id ? "term-item-active" : ""]' @click="volumesClick(item)">
-              <span class="subject-name term-name">
-                <Input v-if="item.rowKey===t_edit_id" clearable type="text" v-model="item.name"
-                       @on-blur="editTerm(item)"
-                       @keyup.enter.native="$event.target.blur"
-                       @click.stop.native="inputFocus($event)" />
-                <span v-else class="term-name-title">{{item.name}} | {{item.termCode}}</span>
-                <span class="s-block-tools" v-show="item.rowKey===c_term_id">
-                  <Icon type="md-create" @click="handleEditTerm(item,$event)" />
-                  <Icon type="md-trash" @click="handleDeleteVolumes(item)" />
-                </span>
-              </span>
-              <span class="term-period">{{item.periodName}} | {{item.gradeName + item.termName}}  <Icon type="md-arrow-dropdown" v-show="item.rowKey===c_click_id" size="18" style="margin-bottom:3px" /></span>
-              <div class="term-userNum">
-                <span>共编使用者数 | {{item.termCode}} 名</span>
-                <Poptip content="content" placement="bottom-end" theme="dark">
-                  <span class="term-add-user" v-show="item.id===c_click_id">添加共编使用者</span>
-                  <div class="pop-content" slot="content" style="padding-bottom:10px;">
-                    <Tabs value="filter" :animated="false">
-                      <TabPane label="选择老师" name="filter">
-                        <template>
-                          <Select v-model="selectGrade" style="width:100%" @on-change="handleGradeChange">
-                            <Option v-for="item in gradeList" :value="item.name" :key="item.name">{{ item.name }}</Option>
-                          </Select>
-                        </template>
-                        <CheckboxGroup v-model="tearchList" @on-change="handleTeacherCheck">
-                          <Checkbox v-for="(item,index) in userList" :key="index" :label="item.index">{{item.name}}{{item.role}}</Checkbox>
-                        </CheckboxGroup>
-                      </TabPane>
-                      <TabPane label="选择群组" name="orderBy">
-
-                      </TabPane>
-                    </Tabs>
-                  </div>
-                </Poptip>
-              </div>
-              <!-- 使用者列表 -->
-              <transition enter-active-class="animated slideInDown" leave-active-class="d-none">
-                <div class="term-users" v-show="item.id===c_click_id">
-                  <div class="term-user-item center" v-for="(user,index) in userList" :key="index">
-                    <img class="term-user-img" :src="user.headImg" />
-                    <span class="term-user-name">{{user.name}} {{user.role}}</span>
-                  </div>
-                </div>
-              </transition>
-            </div>
-          </template>
-          <div v-else class="no-data-text">暂无数据</div>
-        </div>
-        <!-- 右侧树形列表 -->
-        <div class="list-col list-right">
-          <Spin fix v-show="syllabusLoading"></Spin>
-          <Tree :treeDatas="treeDatas" :volumeCode="volumeCode" v-if="volumesList.length > 0 && treeDatas.length > 0"></Tree>
-          <div v-else class="no-data-text">暂无数据</div>
-        </div>
-      </div>
-
-      <!-- 新增科目弹窗  -->
-      <Modal v-model="addSubjectModal"
-             title="新增科目"
-             class-name="subject-modal"
-             ok-text="确认"
-             cancel-text="取消"
-             @on-ok="handleAddSubject">
-        <p class="modal-title" v-show="currentSubjectList.length > 0">当前已选科目</p>
-        <CheckboxGroup v-model="currentSubjectList" v-show="currentSubjectList.length > 0">
-          <Checkbox v-for="(item,index) in currentSubjectList" :label="index" :key="index" disabled>{{item.name}}</Checkbox>
-        </CheckboxGroup>
-
-        <p class="modal-title">请选择需要添加的新科目</p>
-        <CheckboxGroup v-model="newSubjectList">
-          <Checkbox v-for="(item,index) in subjectList" :label="index" :key="index">{{item.name}}</Checkbox>
-        </CheckboxGroup>
-      </Modal>
-
-      <!-- 新增册别弹窗 -->
-      <Modal v-model="addTermModal"
-             title="新增册别"
-             class-name="subject-modal"
-             ok-text="确认"
-             cancel-text="取消"
-             @on-ok="handleAddTerm">
-        <p class="modal-title">当前科目:{{subjectInfo.name}}</p>
-        <p class="modal-title">请选择学段:</p>
-        <Select v-model="periodSelect" style="width:200px" @on-change="periodChange" label-in-value>
-          <Option v-for="item in findPeriodsList" :value="item.code" :key="item.code">{{ item.name }}</Option>
-        </Select>
-        <p class="modal-title">请选择年级:</p>
-        <Select v-model="gradeSelect" style="width:200px" @on-change="gradeChange" label-in-value>
-          <Option v-for="item in findGradesList" :value="item.code" :key="item.code">{{ item.name }}</Option>
-        </Select>
-        <p class="modal-title">请选择学期:</p>
-        <Select v-model="termSelect" style="width:200px" @on-change="termChange" label-in-value>
-          <Option v-for="item in findTermsList" :value="item.code" :key="item.code">{{ item.name }}</Option>
-        </Select>
-        <p class="modal-title">请输入册别名称:</p>
-        <Input v-model="addVolumesData.name" placeholder="输入新册别名称" style="width: 300px" />
-      </Modal>
-
-      <!-- 新增课纲弹窗 -->
-      <Modal v-model="addSyllabusModal"
-             title="新增课纲"
-             class-name="subject-modal"
-             ok-text="确认"
-             cancel-text="取消"
-             @on-ok="handleAddSyllabus">
-        <p class="modal-title">当前科目:{{subjectInfo.name}}</p>
-        <p class="modal-title">当前册别:{{volumesInfo.name}}</p>
-        <p class="modal-title">请输入课纲名称:</p>
-        <Input v-model="addSyllabusData.title" placeholder="输入课纲名称" style="width: 300px" />
-      </Modal>
-    </div>
-  </div>
-</template>
-
-<script>
-  import Tree from '@/components/syllabus/Tree.vue'
-  export default {
-    name: 'Syllabus',
-    components: {
-      Tree: Tree
-    },
-    data() {
-      return {
-        schoolInfos: {}, // 身份全部信息
-        schoolInfo: {}, // 学校信息
-        subjectInfo: {}, // 当前选中科目信息
-        subjectList: [], // 全部科目列表
-        currentSubjectList: [], // 学校科目列表
-        volumesList: [], // 册别列表
-        volumesInfo: {}, // 当前选中册别信息
-        treeData: [], // 课纲数据
-        userList: [], // 共编使用者列表
-        treeDatas: [],
-        volumeCode: '',
-        subjectLoading: true,
-        volumesLoading: true,
-        syllabusLoading: true,
-
-        findPeriodsList: [],
-        findGradesList: [],
-        findTermsList: [],
-        newVolumesName: '',
-        periodSelect: '',
-        gradeSelect: '',
-        termSelect: '',
-        addVolumesData: {},
-        addSyllabusData: {},
-
-        gradeList: [],
-        tearchList: [],
-        c_subject_id: 0,
-        c_term_id: 0,
-        c_click_id: 0,
-        s_click_id: 0,
-        c_edit_id: null,
-        t_edit_id: null,
-        addSubjectModal: false,
-        addTermModal: false,
-        addSyllabusModal: false,
-        newSubjectList: [],
-        termName: '',
-        selectGrade: '1年级'
-
-      }
-    },
-    created() {
-      this.schoolInfo = JSON.parse(localStorage.getItem('c_role_info')).roleClaim[0] // 默认选中第一个学校
-      let schoolClaims = this.schoolInfo.claim
-      for (let i in schoolClaims) {
-        if (schoolClaims[i].claimType === 'SchoolCode') {
-          this.schoolInfo = schoolClaims[i]
-        }
-      }
-      this.findAllSubjects()
-      this.findSchoolSubjectsByDict()
-    },
-    methods: {
-      // 查找全部科目
-      findAllSubjects() {
-        this.$api.FindSubjectsByDict({}).then(res => {
-          this.subjectList = res.result.data
-        })
-      },
-      // 查找当前学校已有科目
-      findSchoolSubjectsByDict() {
-        console.log(this.schoolInfo)
-        this.$api.FindSchoolSubjectsByDict({ SchoolCode: this.schoolInfo.claimCode, Status: 1 }).then(res => {
-          this.currentSubjectList = res.result.data
-          if (res.result.data.length > 0) {
-             this.subjectInfo = res.result.data[0]
-             this.subjectClick(res.result.data[0])
-          }
-          this.subjectLoading = false
-          this.volumesLoading = false
-          this.syllabusLoading = false
-        })
-      },
-       // 点击科目
-      subjectClick(data) {
-        this.volumesLoading = true
-        this.subjectInfo = data
-        this.s_click_id = data.rowKey
-        this.c_subject_id = data.rowKey
-        this.c_edit_id = null
-        let defaultData = {
-          SchoolCode: this.schoolInfo.claimCode,
-          PartitionKey: data.partitionKey,
-          SubjectCode: data.code,
-          Status: 1
-        }
-        this.$api.FindSchoolVolumesByDict(defaultData).then(res => {
-          this.volumesList = res.result.data
-          if (res.result.data.length > 0) {
-            this.volumesClick(res.result.data[0])
-          }
-          this.volumesLoading = false
-         })
-      },
-
-      // 点击编辑科目
-      handleEditSubject(data, e) {
-        e.stopPropagation()
-        this.c_edit_id = data.rowKey
-      },
-
-      // 点击册别
-      volumesClick(data) {
-        this.syllabusLoading = true
-        this.volumesInfo = data
-        this.$api.FindSyllabusByVolumeCode({ VolumeCode: data.rowKey, Status: 1 }).then(res => {
-          this.treeDatas = res.result.data
-          this.volumeCode = data.rowKey
-          this.syllabusLoading = false
-        })
-        this.c_click_id = data.rowKey
-        this.c_term_id = data.rowKey
-        this.t_edit_id = null
-      },
-
-      // 点击编辑册别
-      handleEditTerm(data, e) {
-        e.stopPropagation()
-        this.t_edit_id = data.rowKey
-      },
-      // 编辑科目input失焦
-      editSubject(data) {
-        this.$api.SaveOrUpdateSchoolSubject(data).then(res => {
-            if (res.result.message === 'Success') {
-              this.$Message.success('修改成功')
-            }
-          })
-        this.c_edit_id = null
-      },
-      // 编辑册别input失焦
-      editTerm(data) {
-          this.$api.SaveOrUpdateSchoolVolume(data).then(res => {
-            if (res.result.message === 'Success') {
-              this.$Message.success('修改成功')
-            }
-          })
-        this.t_edit_id = null
-      },
-      // input聚焦
-      inputFocus(e) {
-        // e.cancelBubble = true;
-      },
-      // 点击添加科目
-      addSubject() {
-        let currentList = this.currentSubjectList
-        this.$api.FindSubjectsByDict({}).then(res => {
-          this.subjectList = res.result.data
-          let tempList = this.subjectList.slice(0)
-          if (currentList.length > 0) {
-            for (let i in tempList) {
-              for (let j in currentList) {
-                if (tempList[i].rowKey === currentList[j].code) {
-                  this.subjectList.splice(this.subjectList.indexOf(tempList[i]), 1)
-                }
-              }
-            }
-          }
-        })
-        this.addSubjectModal = true
-        this.newSubjectList = []
-      },
-
-      // 确认添加科目
-      handleAddSubject() {
-        let newList = this.newSubjectList
-        for (let i of newList) {
-          let defaultSubject = {
-            schoolCode: this.schoolInfo.claimCode,
-            partitionKey: this.subjectList[i].partitionKey,
-            name: this.subjectList[i].name,
-            code: this.subjectList[i].rowKey,
-            status: 1,
-            schoolName: this.schoolInfo.claimName
-          }
-           this.$api.SaveOrUpdateSchoolSubject(defaultSubject).then(res => {
-             this.currentSubjectList.push(res.result.data)
-             this.subjectClick(this.currentSubjectList[0]) // 默认展开第一个
-           })
-        }
-      },
-
-      // 点击添加册别
-      addTerm() {
-        this.addTermModal = true
-        this.findSchoolPeriodsByDict()
-        this.findSchoolTermsByDict()
-        this.addVolumesData = {
-            schoolCode: this.schoolInfo.claimCode,
-            partitionKey: this.schoolInfo.partitionKey,
-            schoolName: this.schoolInfo.claimName,
-            subjectName: this.subjectInfo.name,
-            subjectCode: this.subjectInfo.code,
-            status: 1,
-            periodName: 0,
-            gradeName: 0,
-            termName: 0,
-            periodCode: 0,
-            gradeCode: 0,
-            termCode: 0,
-            name: this.newVolumesName
-          }
-      },
-
-      // 点击添加课纲
-      addSyllabus() {
-        this.addSyllabusModal = true
-        this.addSyllabusData = {
-            volumeCode: this.volumesInfo.rowKey,
-            pid: this.volumesInfo.rowKey,
-            remark: '',
-            type: 0,
-            order: 0,
-            expand: true,
-            status: 1,
-            nodeKey: 0,
-            title: ''
-          }
-      },
-
-      // 发送请求添加课纲
-      handleAddSyllabus() {
-        let that = this
-        if (that.addSyllabusData.title && this.addSyllabusData.title.replace(/\s*/g, '').length !== 0) {
-          this.$api.SaveOrUpdateSingleNode(this.addSyllabusData).then(res => {
-            that.$Message.success('添加成功')
-            that.$api.FindSyllabusByVolumeCode({ VolumeCode: that.volumesInfo.rowKey, Status: 1 }).then(res => {
-              that.treeDatas = res.result.data
-            })
-          })
-        } else {
-           this.$Message.warning('名称不能为空!')
-        }
-      },
-
-      // 发送请求添加册别
-      handleAddTerm() {
-        if (this.addVolumesData.name && this.addVolumesData.name.replace(/\s*/g, '').length !== 0) {
-          // 查询是否已存在此类册别
-          this.$api.FindSchoolVolumesByDict({
-            SchoolCode: this.addVolumesData.schoolCode,
-            PartitionKey: this.addVolumesData.partitionKey,
-            SubjectCode: this.addVolumesData.subjectCode,
-            Status: this.addVolumesData.status,
-            PeriodCode: this.addVolumesData.periodCode,
-            GradeCode: this.addVolumesData.gradeCode,
-            TermCode: this.addVolumesData.termCode
-          }).then(res => {
-            if (res.result.data.length > 0) {
-              this.$Modal.confirm({
-                title: '温馨提示',
-                content: '<p>已存在该学期下的册别,是否覆盖?</p>',
-                okText: '确认',
-                cancelText: '取消',
-                onOk: () => {
-                  // 存在即更新册别名字
-                  this.$api.SaveOrUpdateSchoolVolume(this.addVolumesData).then(res => {
-                    this.c_term_id = res.result.data.rowKey
-                    this.c_click_id = res.result.data.rowKey
-                    for (let i in this.volumesList) {
-                      if (this.volumesList[i].rowKey === res.result.data.rowKey) {
-                        this.volumesList[i].name = res.result.data.name
-                      }
-                    }
-                  })
-                }
-              })
-            } else {
-              // 不存在则直接加入列表
-              this.$api.SaveOrUpdateSchoolVolume(this.addVolumesData).then(res => {
-                this.volumesList.push(res.result.data)
-                this.c_term_id = res.result.data.rowKey
-                this.c_click_id = res.result.data.rowKey
-              })
-            }
-          })
-        } else {
-          this.$Message.warning('名称不能为空!')
-        }
-      },
-
-      // 删除科目,修改科目状态
-      handleDeleteSubject(data) {
-        data.status = 0
-        this.$Modal.confirm({
-          title: '删除科目',
-          content: '<p>确认删除该科目?</p>',
-          okText: '确认',
-          cancelText: '取消',
-          onOk: () => {
-            this.$api.SaveOrUpdateSchoolSubject(data).then(res => {
-              data.status = 1
-              this.$Message.success('删除成功')
-              this.currentSubjectList.splice(data, 1)
-              this.subjectList.push(data)
-              this.findSchoolSubjectsByDict()
-              if (this.currentSubjectList.length === 0) {
-                this.volumesList = []
-                this.treeData = []
-              }
-           })
-          },
-          onCancel: () => {
-            this.$Message.info('Clicked cancel')
-          }
-        })
-      },
-
-      // 删除册别,修改册别状态
-      handleDeleteVolumes(data) {
-        data.status = 0
-        this.$Modal.confirm({
-          title: '删除科目',
-          content: '<p>确认删除该册别?</p>',
-          okText: '确认',
-          cancelText: '取消',
-          onOk: () => {
-            this.$api.SaveOrUpdateSchoolVolume(data).then(res => {
-              this.$Message.success('删除成功')
-              this.subjectClick(this.subjectInfo)
-           })
-          },
-          onCancel: () => {
-            this.$Message.info('Clicked cancel')
-          }
-        })
-      },
-      // 获取当前学校全部学段
-      findSchoolPeriodsByDict() {
-        this.$api.FindSchoolPeriodsByDict({ SchoolCode: this.schoolInfo.claimCode }).then(res => {
-          this.findPeriodsList = res.result.data
-          this.periodSelect = res.result.data[0].code
-          this.addVolumesData.periodCode = res.result.data[0].code
-          this.addVolumesData.periodName = res.result.data[0].name
-          this.findSchoolGradesByDict(res.result.data[0].code)
-        })
-      },
-       // 获取当前学校全部年级
-      findSchoolGradesByDict(periodCode) {
-        let data = {
-          SchoolCode: this.schoolInfo.claimCode,
-          PeriodCode: periodCode
-        }
-        this.$api.FindSchoolGradesByDict(data).then(res => {
-          this.findGradesList = res.result.data
-          this.gradeSelect = res.result.data[0].code
-          this.addVolumesData.gradeCode = res.result.data[0].code
-          this.addVolumesData.gradeName = res.result.data[0].name
-        })
-      },
-      // 获取当前学校全部学期
-      findSchoolTermsByDict() {
-        this.$api.FindSchoolTermsByDict({ SchoolCode: this.schoolInfo.claimCode }).then(res => {
-          this.findTermsList = res.result.data
-          this.termSelect = res.result.data[0].code
-          this.addVolumesData.termCode = res.result.data[0].code
-          this.addVolumesData.termName = res.result.data[0].name
-        })
-      },
-
-      periodChange(val) {
-        console.log(val)
-        this.addVolumesData.periodName = val.label
-        this.addVolumesData.periodCode = val.value
-      },
-      gradeChange(val) {
-        console.log(val)
-        this.addVolumesData.gradeName = val.label
-        this.addVolumesData.gradeCode = val.value
-      },
-      termChange(val) {
-        console.log(val)
-        this.addVolumesData.termName = val.label
-        this.addVolumesData.termCode = val.value
-      },
-
-      // 选择年级的自动完成
-      filterGrade(value, option) {
-        return option.toUpperCase().indexOf(value.toUpperCase()) !== -1
-      },
-
-      // 选择老师的回调事件
-      handleTeacherCheck() {
-        console.log(this.tearchList)
-      },
-
-      // 选择老师的回调事件
-      handleGradeChange(val) {
-        console.log(val)
-      }
-    }
-  }
-</script>

+ 0 - 105
TEAMModelOS/ClientApp/src/view/syllabus/index/index.vue

@@ -1,105 +0,0 @@
-<style>
-  @import 'Syllabus.css';
-  @import 'KnowPoint.css';
-</style>
-
-<template>
-  <div class="index">
-    <div class="sak-header">
-      <Headers :parentToChild="syllabusTitle" :identityselect="identitydata"></Headers>
-    </div>
-    <div class="sak-main center">
-      <div class="sak-left">
-        <Syllabus></Syllabus>
-      </div>
-      <!--<div class="sak-right">
-        <KnowPoint></KnowPoint>
-      </div>-->
-    </div>
-  </div>
-</template>
-<script>
-  import Headers from '@/common/headers.vue'
-  import Syllabus from './Syllabus.vue'
-  // import KnowPoint from './KnowPoint.vue'
-  export default {
-    name: 'app',
-    components: {
-      Headers: Headers,
-      Syllabus: Syllabus
-      // KnowPoint: KnowPoint
-    },
-    data() {
-      return {
-        syllabusTitle: '课纲管理/知识点管理',
-        schoolName: '',
-        username: '',
-        activeIndex: sessionStorage.getItem('kIndex') || 0,
-        identitydata: [
-          { 'id': 1, 'name': '成都紫藤小学', 'rolename': '管理员', status: '1' },
-          { 'id': 2, 'name': '成都七中小学', 'rolename': '班主任', status: '2' }
-        ]
-      }
-    },
-    created() {
-
-    },
-    methods: {
-
-    },
-    mounted() {
-
-    }
-  }
-</script>
-<style scoped>
-  .index {
-    position: relative;
-    width: 100%;
-    height: 100%;
-    overflow-y: hidden;
-    min-width: 1366px;
-    background: #fff;
-    -moz-user-select: none; /*火狐 firefox*/
-    -webkit-user-select: none; /*webkit浏览器*/
-    -ms-user-select: none; /*IE10+*/
-    user-select: none;
-    display: flex;
-    flex-direction: column;
-    align-items: center;
-  }
-
-  .sak-header {
-    width: 100%;
-    height: 60px;
-  }
-
-  .sak-main {
-    width: 100%;
-    height: 100%;
-  }
-
-  .sak-left {
-    width: 100%;
-    height: 100%;
-  }
-
-  .sak-right {
-    width: 40%;
-    height: 100%;
-  }
-
-  .center {
-    display: flex;
-    flex-direction: row;
-    justify-content: center;
-    align-items: center;
-  }
-
-  .centerCol {
-    display: flex;
-    flex-direction: column;
-    justify-content: center;
-    align-items: center;
-  }
-</style>

+ 11 - 11
TEAMModelOS/ClientApp/src/view/syllabus/newSyllabus/Index.vue

@@ -179,11 +179,10 @@
         data() {
             return {
                 schoolInfo: { // 学校基本信息
-                    schoolCode: 'HBCN',
-                    areaCode: '86'
+                    code: 'HBCN',
                 },
                 currentParams: { // 默认API传递参数
-                    scopeCode: '',
+                    code: '',
                     periodCode: '',
                     subjectCode: '',
                     type: 0,
@@ -238,12 +237,12 @@
         methods: {
             // 获取当前学校学段学科等基本信息
             initSchoolData() {
-                this.$api.syllabus.GetSchoolInfo(this.schoolInfo).then(res => {
-                    if (!res.error && res.result.data.length) {
-                        this.originSchoolData = res.result.data[0] // 默认选择第一个
-                        this.originData = res.result.data[0] // 默认选择第一个
+                this.$store.dispatch('schoolBaseInfo/getSchoolBaseData').then(res => {
+                    if (res.data) {
+                        this.originSchoolData = res.data // 默认选择第一个
+                        this.originData = res.data // 默认选择第一个
                         this.periodList = this.originData.period
-                        this.currentParams.scopeCode = this.originData.schoolCode
+                        this.currentParams.code = this.originData.schoolCode
                         this.currentParams.periodCode = this.originData.period[0].periodCode
                         this.currentPeriodIndex = 0 // 默认选择第一个学段
                         this.onPeriodChange(0)
@@ -259,7 +258,7 @@
                     this.schoolVolCount = this.volumnCounts[this.currentPeriodIndex].map(i => i[0])
                     this.privateVolCount = this.volumnCounts[this.currentPeriodIndex].map(i => i[1])
                 } else {
-                    this.$api.syllabus.FindSyllabusCount({ schoolCode: this.schoolInfo.schoolCode }).then(res => {
+                    this.$api.syllabus.FindSyllabusCount({ code: this.schoolInfo.code }).then(res => {
                         if (!res.error) {
                             this.$nextTick(() => {
                                 this.volumnCounts = res.result.data
@@ -276,6 +275,7 @@
             // 根据学科获取所有册别信息
             getVolumesData() {
                 let that = this
+                console.log(this.currentParams)
                 this.$api.syllabus.GetVolumes(this.currentParams).then(res => {
                     if (!res.error && res.result.data) {
                         let list = res.result.data
@@ -299,7 +299,7 @@
             // 根据册别CODE来获取对应树形课纲数据
             getTreeByVolume(volumeCode) {
                 let that = this
-                this.$api.syllabus.GetTreeByVolume({ volumeCode: volumeCode }).then(res => {
+                this.$api.syllabus.GetTreeByVolume({ code: volumeCode }).then(res => {
                     if (!res.error && res.result.data) {
                         this.treeData = res.result.data
                         setTimeout(function () {
@@ -318,7 +318,7 @@
                 if (index === 0 && this.currentParams.TEAMModelId) {
                     delete this.currentParams.TEAMModelId
                 } else {
-                    this.currentParams.TEAMModelId = 'habook#0001'
+                    this.currentParams.TEAMModelId = this.$store.state.userInfo.TEAMModelId
                 }
                 this.addType = index === 0 ? 'school' : 'private'
                 this.onPeriodChange(this.currentPeriodIndex)

+ 1 - 1
TEAMModelOS/ClientApp/src/view/syllabus/newSyllabus/operation/AddEditors.vue

@@ -57,7 +57,7 @@
                     params.volumeCode = this.editVolumeItem.volumeCode
                 }
                 if (this.addVolumeType === 'private') {
-                    params.TEAMModelId = 'habook#0001'
+                    params.TEAMModelId = this.$store.state.userInfo.TEAMModelId
                 }
                 this.$api.syllabus.SaveOrUpdateVolume(params).then(res => {
                     if (!res.error && res.result.data) {

+ 2 - 2
TEAMModelOS/ClientApp/src/view/syllabus/newSyllabus/operation/AddVolume.vue

@@ -53,7 +53,7 @@
                 this.isLoading = true
                 let params = {
                     type: this.addVolumeType === 'school' ? 0 : 1,
-                    scopeCode: this.originDatas.schoolCode,
+                    code: this.originDatas.schoolCode,
                     periodCode: this.currentPeriod.periodCode,
                     subjectCode: this.formTop.subject,
                     gradeCode: this.formTop.grade,
@@ -66,7 +66,7 @@
                     params.volumeCode = this.editItem.volumeCode
                 }
                 if (this.addVolumeType === 'private') {
-                    params.TEAMModelId = 'habook#0001'
+                    params.TEAMModelId = this.$store.state.userInfo.TEAMModelId
                 }
                 this.$api.syllabus.SaveOrUpdateVolume(params).then(res => {
                     if (!res.error && res.result.data) {

+ 3 - 3
TEAMModelOS/ClientApp/src/view/syllabus/newSyllabus/operation/BaseKnowledge.vue

@@ -83,7 +83,7 @@
             this.currentVolume = this.volume
             this.currentParams = {
                 subjectCode: this.currentVolume.subjectCode,
-                scopeCode: this.currentVolume.schoolCode,
+                code: this.currentVolume.schoolCode,
                 period: this.currentVolume.periodCode,
                 type: 1
             }
@@ -110,7 +110,7 @@
 
             // 获取校本知识点仓库
             getSchoolPoints() {
-                this.currentParams.scopeCode = this.currentVolume.schoolCode
+                this.currentParams.code = this.currentVolume.schoolCode
                 this.$api.knowledge.GetSchoolPoints(this.currentParams).then(res => {
                     if (!res.error && res.result.data) {
                         let list = res.result.data
@@ -123,7 +123,7 @@
 
             // 获取私人知识点仓库
             getPrivatePoints() {
-                this.currentParams.scopeCode = this.$store.state.userInfo.TEAMModelId
+                this.currentParams.code = this.$store.state.userInfo.TEAMModelId
                 this.$api.knowledge.GetSchoolPoints(this.currentParams).then(res => {
                     if (!res.error && res.result.data) {
                         let list = res.result.data