Ver código fonte

feat(课程搜索): 添加培训计划和学员名单筛选字段

zhanghaijun 10 meses atrás
pai
commit
1aee8269da

+ 9 - 1
.vscode/settings.json

@@ -51,15 +51,23 @@
     "Cascader",
     "checkboxgroup",
     "iconfont",
+    "JXJHID",
+    "KMMC",
     "Oper",
     "persistedstate",
     "pinia",
+    "PXSSID",
+    "PXSSMC",
+    "SDKCGUIDs",
+    "TESTKCGUIDs",
     "unplugin",
     "unref",
     "VITE",
     "vueuse",
     "Worktab",
     "Worktabs",
-    "xgplayer"
+    "xgplayer",
+    "XYEMPID",
+    "XYXM"
   ]
 }

Diferenças do arquivo suprimidas por serem muito extensas
+ 1 - 0
public/device.20251117082337.json


Diferenças do arquivo suprimidas por serem muito extensas
+ 1 - 0
public/device.20251117200159.json


BIN
src/assets/img/cover/1001.png


BIN
src/assets/img/user/avatar.teacher.png


BIN
src/assets/img/user/user.avatar.png


+ 5 - 4
src/components/core/layouts/art-header-bar/index.vue

@@ -95,12 +95,12 @@
             popper-style="border: 1px solid var(--art-border-dashed-color); border-radius: calc(var(--custom-radius) / 2 + 4px); padding: 5px 16px; 5px 16px;"
           >
             <template #reference>
-              <img class="cover" src="@imgs/user/avatar.webp" alt="avatar" />
+              <img class="cover" :src="getUserType === 1 ? UserAvatarImage : TeacherAvatarImage" alt="avatar" />
             </template>
             <template #default>
               <div class="user-menu-box">
                 <div class="user-head">
-                  <img class="cover" src="@imgs/user/avatar.webp" style="float: left" />
+                  <img class="cover" :src="getUserType === 1 ? UserAvatarImage : TeacherAvatarImage" style="float: left" />
                   <div class="user-wrap">
                     <span class="name">{{ userInfo.username }}</span>
                     <span class="email">{{ userInfo.userId }}</span>
@@ -153,6 +153,8 @@
   import { themeAnimation } from '@/utils/theme/animation'
   import { useCommon } from '@/composables/useCommon'
   import { useHeaderBar } from '@/composables/useHeaderBar'
+  import UserAvatarImage from '@imgs/user/user.avatar.png'
+  import TeacherAvatarImage from '@imgs/user/teacher.avatar.png'
 
   defineOptions({ name: 'ArtHeaderBar' })
 
@@ -170,8 +172,7 @@
 
   const { systemThemeColor, showSettingGuide, menuType, isDark, tabStyle } = storeToRefs(settingStore)
 
-  const { language, userInfo } = storeToRefs(userStore)
-  // const { menuList } = storeToRefs(menuStore)
+  const { language, userInfo, getUserType } = storeToRefs(userStore)
 
   const showNotice = ref(false)
   const notice = ref(null)

+ 27 - 1
src/views/train/course/list/search.vue

@@ -36,7 +36,9 @@
     { label: '课程分类', key: 'typeID', type: 'select', placeholder: '请选择课程分类', clearable: true, options: dictStore.getDictWithCode('course_category') || [] },
     { label: '线路号', key: 'lineNo', type: 'select', placeholder: '请输入线路号', clearable: true, options: dictStore.getDictWithCode('course_line') || [] },
     { label: '运行图', key: 'runningMap', type: 'select', placeholder: '请输入运行图', clearable: true, options: dictStore.getDictWithCode('course_run_map') || [] },
-    { label: '创建人', key: 'creator', type: 'input', placeholder: '请输入创建人', clearable: true }
+    { label: '创建人', key: 'creator', type: 'input', placeholder: '请输入创建人', clearable: true },
+    { label: '培训计划', key: 'PXSSID', type: 'select', placeholder: '请选择培训计划', clearable: true, options: [] },
+    { label: '学员名单', key: 'XYEMPID', type: 'select', placeholder: '请选择学员', clearable: true, options: [] }
   ])
 
   const courseSearchHandle = async () => {
@@ -44,6 +46,30 @@
     emit('search', courseFormData)
   }
 
+  // // 培训计划
+  // export interface TrainPlanItem {
+  //   PXSSID?: string /** 培训实施ID */
+  //   PXSSMC?: string /** 培训实施名称 */
+  //   PlanInfo?: {
+  //     JXJHID?: string /** 计划ID */
+  //     KMMC?: string /** 计划名称 */
+  //     SDKCGUIDs?: string[] /** 培训课程GUID列表 */
+  //     TESTKCGUIDs?: string[] /** 课程课程GUID列表 */
+  //   }[] /** 计划信息 */
+  // }
+  // const trainPlanOptions = async () => {
+  //   const { data } = await request.post<TrainPlanItem[]>('/course/tmsplan', {})
+  // }
+
+  // // 学员列表
+  // export interface StudentItem {
+  //   XYEMPID: string /** 学员GUID */
+  //   XYXM: string /** 学员姓名 */
+  // }
+  // const studentOptions = async () => {
+  //   const { data } = await request.post<StudentItem[]>('/course/tmsplanstudent', { PXSSID: '' })
+  // }
+
   defineExpose({
     reset: () => {
       courseSearchRef.value?.reset()