shi'sen'yuan 3 سال پیش
والد
کامیت
9c402fb517

+ 2 - 1
master/src/main/resources/mybatis/training/TTrainingDeviceMapper.xml

@@ -23,10 +23,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <result property="hour"    column="duration"    />
         <result property="year"    column="years"    />
         <result property="supplementary"    column="supplementary"    />
+        <result property="trainingType"    column="training_type"    />
     </resultMap>
 
     <sql id="selectTTrainingDeviceVo">
-        select d.id, s.name, t.courseid, t.course, t.course_startdate, t.trainer, t.duration, t.years, d.staff_id, d.regular_id, d.start_date, d.remarks, d.del_flag, d.creater_code, d.createdate, d.updater_code, d.updatedate, d.supplementary from t_training_device d
+        select d.id, t.training_type, s.name, t.courseid, t.course, t.course_startdate, t.trainer, t.duration, t.years, d.staff_id, d.regular_id, d.start_date, d.remarks, d.del_flag, d.creater_code, d.createdate, d.updater_code, d.updatedate, d.supplementary from t_training_device d
         left join t_training t on t.id = d.regular_id
         left join t_staffmgr s on s.staffid = t.trainer
     </sql>

+ 2 - 2
ui/src/views/training/trainingrecords/index.vue

@@ -541,8 +541,8 @@
         <el-table-column :label="$t('课时')" align="center" prop="hour" :show-overflow-tooltip="true"/>
         <el-table-column :label="$t('开始日期')" align="center" prop="startDate" width="100">
           <template slot-scope="scope">
-            <span v-if="scope.row.supplementary === '0'">{{ parseTime(scope.row.startDate, '{y}-{m}') }}</span>
-            <span v-if="scope.row.supplementary === '1'">{{ parseTime(scope.row.startDate, '{y}-{m}-{d}') }}</span>
+            <span v-if="scope.row.supplementary === '0' && scope.row.trainingType === '10'">{{ parseTime(scope.row.startDate, '{y}-{m}') }}</span>
+            <span v-else>{{ parseTime(scope.row.startDate, '{y}-{m}-{d}') }}</span>
           </template>
         </el-table-column>
         <el-table-column :label="$t('备注')" align="center" prop="remarks" :show-overflow-tooltip="true"/>