Forráskód Böngészése

Merge branch 'liqk/hotfix-rc' into develop-rc

1755507413 2 éve
szülő
commit
8d10cbdb4b

+ 1 - 1
TEAMModelOS/ClientApp/public/lang/zh-CN.js

@@ -1298,7 +1298,7 @@ const LANG_ZH_CN = {
             image: '图片',
             file: '附件',
             link: '超链接',
-            cw: '课件第',
+            cw: '教材第',
             page: '页',
             pageNoRcd: '此页没有互动数据',
             di: '第',

+ 1 - 1
TEAMModelOS/ClientApp/public/lang/zh-TW.js

@@ -1299,7 +1299,7 @@ const LANG_ZH_TW = {
             image: '圖片',
             file: '附件',
             link: '超連結',
-            cw: '課件第',
+            cw: '教材第',
             page: '頁',
             pageNoRcd: '此頁沒有互動數據',
             di: '第',

+ 39 - 2
TEAMModelOS/ClientApp/src/view/student-account/stuMgt/StuMgt.vue

@@ -63,7 +63,7 @@
         <!--学生账号table-->
         <div class="sc-content" style="position: relative; padding-left: 15px" :style="{width: '100%',transition: 'all 0.7s'}">
             <Scroll :on-reach-bottom="scrollLoad" height="750" :distance-to-edge="[15, 15]">
-                <Table ref="selection" :columns="tableColumns" :data="tableShowData" @on-selection-change="(selection)=>{selections = selection}">
+                <Table ref="selection" :columns="tableColumns" :data="tableShowData" @on-selection-change="(selection)=>{selections = selection}" @on-filter-change="handleFilterData">
                     <template slot-scope="{ row }" slot="header">
                         <PersonalPhoto :name="row.name" :picture="row.picture" />
                     </template>
@@ -275,6 +275,7 @@ export default {
             callback()
         }
         return {
+            imeiFilter:'',
             graduateList: [],
             isGraduate: false,
             imeiTips: '',
@@ -685,6 +686,7 @@ export default {
             }
         },
         initData() {
+            let _this = this
             this.tableColumns = [
                 {
                     type: 'selection',
@@ -769,10 +771,34 @@ export default {
                 this.tableColumns.splice(8, 0, {
                     title: this.$t('stuAccount.imei'),
                     slot: 'imei',
-                    align: 'center'
+                    align: 'center',
+                    key:'imei',
+                    filters: [
+                        {
+                            label: '已绑定',
+                            value: 1
+                        },
+                        {
+                            label: '未绑定',
+                            value: 2
+                        }
+                    ],
+                    filterMultiple: false,
+                    filterMethod (value, row) {
+                        return true
+                    }
                 })
             }
         },
+        handleFilterData(data){
+            console.log(data)
+            if(data._filterChecked.length){
+                this.imeiFilter = data._filterChecked[0]
+            }else{
+                this.imeiFilter = ''
+            }
+            this.filterData()
+        },
         /**基础查询数据 */
         baseFindStudent(params) {
             this.tableLoading = true
@@ -863,6 +889,17 @@ export default {
                 })
             }
 
+            //imei筛选
+            if(this.imeiFilter){
+                data = data.filter(item=>{
+                    if(this.imeiFilter == 1){
+                        return !!item.imei
+                    }else if(this.imeiFilter == 2){
+                        return !item.imei
+                    }
+                })
+            }
+
             this.tableFilterData = data
             this.pointNum = this.basicCount
             this.tableShowData = data.slice(0, this.basicCount)

+ 12 - 4
TEAMModelOS/ClientApp/src/view/teachermgmt/components/mgt/TeacherMgt.vue

@@ -548,12 +548,13 @@ export default {
                         let flag = params.row.permissions?.some(item => {
                             return !p.includes(item)
                         })
-
+                        let areaId = sessionStorage.getItem('areaId')
+                        let isArea = (params.row.areas?.length && !!params.row.areas.find(r => r.areaId == areaId))
                         // 区级管理员 || 校级管理员
-                        if (params.row.areas?.length || params.row.roles?.includes('admin')) {
+                        if (isArea || params.row.roles?.includes('admin')) {
                             let text = ''
-                            if (params.row.areas?.length) text = this.$t('teachermgmt.table.text4')
-                            if (params.row.roles?.includes('admin')) text = `${text}${params.row.areas?.length ? '、' : ''}${this.$t('teachermgmt.table.text3')}`
+                            if (isArea) text = this.$t('teachermgmt.table.text4')
+                            if (params.row.roles?.includes('admin')) text = `${text}${isArea ? '、' : ''}${this.$t('teachermgmt.table.text3')}`
                             return h(
                                 'span',
                                 {
@@ -1357,6 +1358,13 @@ export default {
         teachers: {
             handler(n, o) {
                 this.getTeachersTemp()
+                if (n && n.length) {
+                    setTimeout(() => {
+                        this.curPage = 1
+                        this.tableDataShow = []
+                        this.scrollLoad()
+                    }, 0)
+                }
             },
             deep: true,
             immediate: true