Browse Source

研修平台调整

OnePsycho 3 năm trước cách đây
mục cha
commit
dd5c5cc3d1

+ 15 - 1
TEAMModelOS.SDK/Models/Service/GroupListService.cs

@@ -342,6 +342,9 @@ namespace TEAMModelOS.SDK.Models
                     classes = classes.Except(schoolList.Select(y => y.id)).ToList();
                     if (classes.IsNotEmpty())
                     {
+                        if (!groupLists.IsNotEmpty()) {
+                            groupLists = new List<GroupListDto>();
+                        }
                         string insql = string.Join(",", classes.Select(x => $"'{x}'"));
                         //搜寻没有关联学生的行政班
                         await foreach (var item in client.GetContainer(Constant.TEAMModelOS, "School").GetItemQueryIterator<GroupListDto>(queryText: $"select   c.id,c.code,c.name,c.no,c.periodId,c.scope,c.school,c.creatorId,c.type,c.year,c.tcount,c.scount,c.teacher.id as leader from c where c.id in ({insql})",
@@ -382,7 +385,18 @@ namespace TEAMModelOS.SDK.Models
                         groups.Add("Teacher", privateList);
                     }
                 }
-                groupLists = groups.SelectMany(x => x.Value).ToList();
+                if (groups.Count != 0)
+
+                {
+                    if (groupLists.IsNotEmpty())
+                    {
+                        groupLists .AddRange(groups.SelectMany(x => x.Value).ToList());
+                    }
+                    else {
+                        groupLists = groups.SelectMany(x => x.Value).ToList();
+                    }
+                }
+                
             }
             return groupLists;
         }

+ 11 - 2
TEAMModelOS/ClientApp/src/common/AbilityUpload.vue

@@ -59,7 +59,12 @@
 			acceptTypes: {
 				type: Array,
 				default: () => []
-			}
+			},
+			// 简易上传,只返回选择的fileArr,不做操作处理
+			simpleUpload:{
+				type:Boolean,
+				default:false
+			},
 		},
 		data() {
 			return {
@@ -176,8 +181,12 @@
 					return options
 				}
 			},
-
+			/* 确认上传 */
 			async onConfirmUpload() {
+				if(this.simpleUpload){
+					this.$emit('uploadFinish',this.fileArr)
+					return
+				}
 				this.isShowTool = false
 				this.isLoading = true
 				let result = []

+ 2 - 2
TEAMModelOS/ClientApp/src/common/BaseLayout.vue

@@ -395,7 +395,7 @@ export default {
                     },
                     {
                         icon: 'iconfont icon-test',
-                        name: '小组评分',
+                        name: this.$t('system.menu.appAbility'),
                         router: '/home/ability',
                         tag: '',
                         role: 'admin',
@@ -891,7 +891,7 @@ export default {
 html,
 body {
 	 // font-family:"Microsoft YaHei",'微軟正黑體','Microsoft JhengHei UI','Microsoft JhengHei';
-	// font-family:'微軟正黑體','Microsoft JhengHei UI','Microsoft JhengHei';
+	font-family:'微軟正黑體','Microsoft JhengHei UI','Microsoft JhengHei';
 }
 
 .biz-menu .ivu-menu-vertical .ivu-menu-item-group-title {

+ 5 - 3
TEAMModelOS/ClientApp/src/components/homework/BaseHwForm.vue

@@ -11,7 +11,7 @@
 					<FormItem :label="$t('homework.form.target')" prop="classes">
 						<!-- 预览状态 -->
 						<div v-if="!voteFormEdit && curVoteItem" class="vote-class">
-							<span v-for="item in classNameArr" class="vote-class-item">{{ item.name }}</span>
+							<span v-for="(item,index) in classNameArr" :key="index" class="vote-class-item">{{ item.name }}</span>
 						</div>
 						<!-- 编辑状态 -->
 						<div v-else>
@@ -306,8 +306,10 @@
 			},
 			/* 发布对象变动 */
 			onTargetChange(data) {
-				this.voteForm.classes = this.getCurScope === 'school' ? data : data.map(i => i.split('/')[1])
+				console.error(data)
+				this.voteForm.classes = data
 				this.voteForm.targets = this.getCurScope === 'school' ? [] : data
+				console.error(this.voteForm.classes)
 			},
 			/* 修改开始时间 */
 			onChangeSTime(val) {
@@ -525,7 +527,7 @@
 				return new Promise((r, j) => {
 					this.$api.learnActivity.getClassNameByIds({
 						ids: ids,
-						school: this.$store.state.userInfo.schoolCode
+						schoolId: this.$store.state.userInfo.schoolCode
 					}).then(res => {
 						if (!res.error) {
 							r(res.groups)

+ 1 - 1
TEAMModelOS/ClientApp/src/components/questionnaire/BaseProgress.vue

@@ -186,7 +186,7 @@
 			}
 		},
 		mounted() {
-			if (!this.total) return
+			if (!this.total && total !== 0) return
 			// console.log('mounted',this.noAnswerdCount)
 			this.drawLine()
 

+ 1 - 1
TEAMModelOS/ClientApp/src/components/questionnaire/BaseQnForm.vue

@@ -423,7 +423,7 @@
 				return new Promise((r, j) => {
 					this.$api.learnActivity.getClassNameByIds({
 						ids: ids,
-						school: this.$store.state.userInfo.schoolCode
+						schoolId: this.$store.state.userInfo.schoolCode
 					}).then(res => {
 						if (!res.error) {
 							// 如果根据名单ID没有匹配到名单数据,则显示默认的“未匹配数据”TAG

+ 1 - 1
TEAMModelOS/ClientApp/src/components/vote/BaseVoteForm.vue

@@ -698,7 +698,7 @@
 				return new Promise((r, j) => {
 					this.$api.learnActivity.getClassNameByIds({
 						ids: ids,
-						school: this.$store.state.userInfo.schoolCode
+						schoolId: this.$store.state.userInfo.schoolCode
 					}).then(res => {
 						if (!res.error) {
 							r(res.groups)

+ 1 - 1
TEAMModelOS/ClientApp/src/locale/lang/zh-CN/jyzx.js

@@ -129,7 +129,7 @@ export default{
         noEvaluate: "未评价",
         pass: "通过",
         noPass: "未通过",
-        load: "上传文件",
+        load: "提交材料",
         againTest: "重新检测",
         meTest: "自我检测",
         score: "前往评分",

+ 4 - 4
TEAMModelOS/ClientApp/src/router/routes.js

@@ -925,11 +925,11 @@ export const routes = [{
 				// ]
 			},
 			{
-				path: 'abilityUpload',
-				name: 'abilityUpload',
-				component: resolve => require(['@/view/abilityUpload/AbilityUpload.vue'], resolve),
+				path: 'planUpload',
+				name: 'planUpload',
+				component: resolve => require(['@/view/planUpload/planUpload.vue'], resolve),
 				meta: {
-					activeName: 'abilityUpload'
+					activeName: 'planUpload'
 				}
 			},
 			//应用考核管理员

+ 1 - 0
TEAMModelOS/ClientApp/src/utils/blobTool.js

@@ -121,6 +121,7 @@ export default class BlobTool {
                     let info = getExAndType(file.name)
                     r({
                         url: url,
+                        md5: res.contentMD5,
                         blob: '/' + path + "/" + file.name,
                         name: file.name,
                         size: res._response.request.body.size,

+ 22 - 10
TEAMModelOS/ClientApp/src/view/ability/Ability.vue

@@ -9,8 +9,10 @@
                     <Option v-for="(item,index) in groupList" :value="item.groupName" :key="index">{{ item.groupName }}</Option>
                 </Select>
                 <Input v-special-char v-model="searchVal" suffix="ios-search" :placeholder="$t('ability.place1')" style="width: auto" @on-change="onSearch" />
-                <span class="btn-export" @click="exportData()">
-                    <Icon type="md-download" /> {{ $t('ability.resultDownload') }}
+                <span class="btn-export">
+                    <span @click="onAddTeacher" style="margin-right:10px"><Icon type="md-person-add" /> {{ `添加教研组长` }}</span>
+                    <span @click="exportData()"><Icon type="md-download" /> {{ $t('ability.resultDownload') }}</span>
+                    
                 </span>
             </div>
             <Table :columns="ablitiesColumn" :data="origin" border :span-method="handleSpan" :loading="tableLoading" ref="table">
@@ -41,6 +43,11 @@
         </div>
         <Review v-if="isShowReview" :mode="curReviewMode" :reviewData="curData" @goBack="goBack"></Review>
 
+        <Modal v-model="addTeacherModal" width="750" class="tree-modal add-volume-modal choose-content-modal">
+			<div>
+                邀请教研组长
+            </div>
+		</Modal>
     </div>
 </template>
 <script>
@@ -83,7 +90,7 @@ export default {
                     width: 140
                 },
                 {
-                    title: '小组评结果',
+                    title: '考核结果',
                     slot: 'schoolAppraise',
                     key: 'schoolAppraise',
                     width: 140
@@ -124,17 +131,22 @@ export default {
             curData: false,
             groupData: [],
             curReviewMode: '',
-            originList: []
+            originList: [],
+            addTeacherModal:false
         }
     },
     created() {
         this.getAllSubs()
     },
     methods: {
-        goBack() {
+        goBack(needRefresh) {
             this.isShowReview = false
             this.searchVal = ''
-            this.getAllSubs()
+            needRefresh && this.getAllSubs()
+        },
+        /* 添加教研组长 */
+        onAddTeacher(){
+            this.addTeacherModal = true
         },
 		/* 根据评论ID查找评论内容 */
 		getAppraiseContentById(id){
@@ -238,10 +250,10 @@ export default {
             
         },
         goReview(data) {
-            if (data.tmdid === this.$store.state.userInfo.TEAMModelId) {
-                this.$Message.warning(this.$t('ability.appraiseTip'))
-                return
-            }
+            // if (data.tmdid === this.$store.state.userInfo.TEAMModelId) {
+            //     this.$Message.warning(this.$t('ability.appraiseTip'))
+            //     return
+            // }
             // this.curData = data
             let reviewData = {
                 id: data.sub.abilityId,

Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 546 - 536
TEAMModelOS/ClientApp/src/view/ability/Review.vue


+ 2 - 2
TEAMModelOS/ClientApp/src/view/homework/ManageHomeWork.vue

@@ -93,7 +93,7 @@
 								<BasePie barId="pie1" :total="tableData.length"
 									:noAnswerdCount="tableData.filter(i => !i.submit).length"></BasePie>
 							</div>
-							<div v-for="(classItem,classIndex) in classNameArr" :key="classItem.id">
+							<div v-for="classItem in classNameArr" :key="classItem.id">
 								<p class="class-table-title">{{ classItem.name }}</p>
 								<BaseHwTable
 									:studentsList="tableData.filter(i => i.classes.find(j => j.id === classItem.id))"
@@ -499,11 +499,11 @@
 						"listIds": voteItem.classes.length ? voteItem.classes : voteItem.stuLists
 					}).then(res => {
 						if (!res.error) {
-							console.log(res)
 							if (this.$refs.voteForm) {
 								this.classNameArr = this.$refs.voteForm.classNameArr
 							}
 							this.tableData = res.users
+							console.log('MH > tableData',this.tableData)
 						} else {
 							this.$Message.error(this.$t('homework.getDataFailTip'))
 						}

Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 502 - 508
TEAMModelOS/ClientApp/src/view/jyzx/application.vue


+ 22 - 27
TEAMModelOS/ClientApp/src/view/knowledge-point/index/Index.vue

@@ -353,8 +353,7 @@
 		},
 		created() {
 			this.initSchoolData()
-			this.hostName = this.$store.state.privateSas ? this.$store.state.privateSas.url :
-				'https://teammodelstorage.blob.core.chinacloudapi.cn'
+			this.hostName = this.$evTools.getBlobHost()
 		},
 		methods: {
 			onDownload(val) {
@@ -434,7 +433,7 @@
 					this.$api.knowledge.SaveOrUpdateKnowledge(params).then(res => {
 						if (res) {
 							this.$Message.success(this.$t('knowledge.saveSuccess'))
-							this.getPointsData()
+							this.updated = false
 							this.initBlockCount()
 						} else {
 							this.$Message.warning(this.$t('knowledge.saveFail'))
@@ -522,14 +521,11 @@
 					let schoolBaseInfo = res.school_base
 					if (schoolBaseInfo) {
 						this.schoolInfo = schoolBaseInfo
-						this.originSchoolData = schoolBaseInfo // 默认选择第一个
-						this.originData = schoolBaseInfo // 默认选择第一个
+						this.originSchoolData = schoolBaseInfo
+						this.originData = schoolBaseInfo
 						if (schoolBaseInfo.period.length) {
 							this.periodList = schoolBaseInfo.period
 							this.currentParams.school_code = schoolBaseInfo.id
-							// this.currentParams.periodId = schoolBaseInfo.period[0].id
-							// this.currentPeriodIndex = 0 // 默认选择第一个学段
-							// this.onPeriodChange(0)
 						}
 					}
 				})
@@ -537,7 +533,6 @@
 
 			// 获取当前册别数量(每次都获取最新的数据)
 			initBlockCount() {
-
 				let params = {}
 				for (let data of this.subjectList) {
 					params[this.$store.state.userInfo.schoolCode + "-" + data.id] = this.periodList[this
@@ -569,6 +564,8 @@
 						let list = res[0].blocks
 						this.blockList = list
 						this.originBlockList = JSON.parse(JSON.stringify(list))
+						this.pointList = [...new Set(res[0].points)]
+						this.originPointList = JSON.parse(JSON.stringify(this.pointList))
 						setTimeout(function() {
 							that.isLoadBlocks = false
 						}, 400)
@@ -587,10 +584,12 @@
 							"pk": "Knowledge",
 						}]
 						that.pointDatas = params
-						let list = params[0].blocks
-						this.blockList = list
-						this.originBlockList = JSON.parse(JSON.stringify(list))
+						this.blockList = []
+						this.originBlockList = []
+						this.pointList = []
+						this.originPointList = []
 					}
+					this.updated = false
 				}).catch(err => {
 					this.$Message.error(this.$t('knowledge.warn'))
 					this.isLoadBlocks = false
@@ -600,17 +599,17 @@
 
 			// 根据学科获取学科下所有知识点数据
 			getPointsData() {
-				let that = this
-				this.$api.knowledge.GetSchoolPoints(this.currentParams).then(res => {
-					if (res.length) {
-						this.pointList = [...new Set(res[0].points)]
-						this.originPointList = JSON.parse(JSON.stringify(this.pointList))
-						setTimeout(function() {
-							that.isLoadPoints = false
-						}, 800)
-						this.updated = false
-					}
-				})
+				// let that = this
+				// this.$api.knowledge.GetSchoolPoints(this.currentParams).then(res => {
+				// 	if (res.length) {
+				// 		this.pointList = [...new Set(res[0].points)]
+				// 		this.originPointList = JSON.parse(JSON.stringify(this.pointList))
+				// 		setTimeout(function() {
+				// 			that.isLoadPoints = false
+				// 		}, 800)
+				// 		this.updated = false
+				// 	}
+				// })
 			},
 
 			// 校本知识块与个人切换
@@ -619,12 +618,10 @@
 				this.tabIndex = index
 				switch (index) {
 					case 0:
-						this.getPointsData()
 						this.getBlocksData()
 						this.pointOwn = 'school'
 						break
 					case 1:
-						this.getPointsData()
 						this.getBlocksData()
 						this.pointOwn = 'personal'
 						break
@@ -730,7 +727,6 @@
 							this.currentParams.subjectId = this.subjectList[index].id
 							this.activeSubjectIndex = index
 							this.isLoadBlocks = true
-							this.getPointsData()
 							this.getBlocksData()
 						},
 						onCancel: () => {
@@ -754,7 +750,6 @@
 					this.currentParams.subjectId = this.subjectList[index].id
 					this.activeSubjectIndex = index
 					this.isLoadBlocks = true
-					this.getPointsData()
 					this.getBlocksData()
 				}
 

Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 862 - 870
TEAMModelOS/ClientApp/src/view/newsheet/index.vue


+ 0 - 1
TEAMModelOS/ClientApp/src/view/abilityUpload/AbilityUpload.less

@@ -2,7 +2,6 @@
 	padding: 10px;
 	font-weight: bold;
 	background-color: #f7f7f7;
-	font-family: 'NotoSerif', '微软正黑体', 'Microsoft JhengHei UI', 'Microsoft JhengHei', Sans-serif;
 	
 	.upload-box{
 		width: 500px;

+ 1 - 1
TEAMModelOS/ClientApp/src/view/abilityUpload/AbilityUpload.vue

@@ -93,4 +93,4 @@
 	}
 </script>
 
-<style lang="less" src="./AbilityUpload.less" scoped></style>
+<style lang="less" src="./planUpload.less" scoped></style>