ly пре 3 година
родитељ
комит
d794244898

+ 3 - 0
master/src/main/java/com/ruoyi/project/common/CommonController.java

@@ -245,6 +245,9 @@ public class CommonController extends BaseController
         } else if( type.equals("newemployee") ) {
             downloadname = "新员工培训导入模板.xlsx";
             url = "static/template/training/newemployee.xlsx";
+        }else if( type.equals("companyLevelRecord") ) {
+            downloadname = "公司培训成绩导入模板.xlsx";
+            url = "static/template/training/companyLevelRecord.xlsx";
         } else if( type.equals("targetlist") ) {
             downloadname = "目标录入导入模板.xlsx";
             url = "static/template/plant/targetlist.xlsx";

BIN
master/src/main/resources/static/template/training/companyLevelRecord.xlsx


+ 5 - 4
ui/src/views/training/companylevel/index.vue

@@ -264,6 +264,9 @@
                 <!--<el-checkbox v-model="upload.updateSupport" />是否更新已经存在的用户数据-->
                 <el-link type="info" style="font-size:12px" @click="importTemplate">{{ $t('下载模板') }}</el-link>
             </div>
+          <form ref="downloadFileForm" :action="upload.downloadAction" target="FORMSUBMIT">
+            <input name="type" :value="upload.type" hidden />
+          </form>
             <div class="el-upload__tip" style="color:#ff0000" slot="tip">{{ $t('提示:仅允许导入“xls”或“xlsx”格式文件!') }}</div>
         </el-upload>
         <div slot="footer" class="dialog-footer">
@@ -327,7 +330,7 @@ export default {
       upload: {
         downloadAction: process.env.VUE_APP_BASE_API + '/common/template',
         //下载模板类型
-        type: "conpanylevel",
+        type: "companyLevelRecord",
         // 是否显示弹出层(用户导入)
         open: false,
         // 弹出层标题(用户导入)
@@ -646,9 +649,7 @@ export default {
     },
     /** 下载模板操作 */
     importTemplate() {
-        importTemplate().then(response => {
-            this.download(response.msg);
-        });
+      this.$refs['downloadFileForm'].submit()
     },
     // 文件上传中处理
     handleFileUploadProgress(event, file, fileList) {

+ 9 - 11
ui/src/views/training/spec/successor/staffResume.vue

@@ -6,21 +6,18 @@
       </div>
       <div class="el-descriptions">
         <div class="el-descriptions__body">
-          <table class="el-descriptions__table is-bordered el-descriptions--big" style="border: 1px solid #e6ebf5;">
-            <tbody>
-            <tr class="el-descriptions-row" rowspan="3">
+          <table class="el-descriptions__table is-bordered el-descriptions--big" style="table-layout: fixed;border: 1px solid #e6ebf5;">
+            <tr class="el-descriptions-row">
               <th colspan="1" class="el-descriptions-item__cell el-descriptions-item__label is-bordered-label "> 姓名</th>
               <td colspan="1" class="el-descriptions-item__cell el-descriptions-item__content"> {{staff.name}}</td>
               <th colspan="1" class="el-descriptions-item__cell el-descriptions-item__label is-bordered-label "> 性别</th>
               <td colspan="1" class="el-descriptions-item__cell el-descriptions-item__content" > {{sexFormat(staff)}}</td>
               <th colspan="1" class="el-descriptions-item__cell el-descriptions-item__label is-bordered-label "> 年龄</th>
               <td colspan="1" class="el-descriptions-item__cell el-descriptions-item__content">{{staff.birthday}}</td>
-              <td colspan="1" rowspan="3" class="el-descriptions-item__cell el-descriptions-item__content">
-                <img :src="staff.photo"  />
+              <td colspan="1" rowspan="3" >
+                <img :src="photo"  style="width: 150px"/>
               </td>
             </tr>
-            </tbody>
-            <tbody>
             <tr class="el-descriptions-row">
               <th colspan="1" class="el-descriptions-item__cell el-descriptions-item__label is-bordered-label "> 学历</th>
               <td colspan="1" class="el-descriptions-item__cell el-descriptions-item__content">{{educationFormat(staff)}}</td>
@@ -29,8 +26,7 @@
               <th colspan="1" class="el-descriptions-item__cell el-descriptions-item__label is-bordered-label "> 工号</th>
               <td colspan="1" class="el-descriptions-item__cell el-descriptions-item__content">{{staff.staffid}}</td>
             </tr>
-            </tbody>
-            <tbody>
+
             <tr class="el-descriptions-row">
               <th colspan="1" class="el-descriptions-item__cell el-descriptions-item__label is-bordered-label "> 入职时间
               </th>
@@ -39,7 +35,6 @@
               </th>
               <td colspan="3" class="el-descriptions-item__cell el-descriptions-item__content">{{actualpostFormat(staff)}}</td>
             </tr>
-            </tbody>
           </table>
         </div>
       </div>
@@ -137,7 +132,8 @@ export default {
       visible: false,
       // 选中数组
       ids: [],
-      staff: null,
+      staff: {},
+      photo: '',
       dataListSelections: [],
       // 装置名称字典
       plantCodeOptions: [],
@@ -239,7 +235,9 @@ export default {
   methods: {
     init(row) {
       this.visible = true
+      console.log(row.staff)
       this.staff = row.staff
+      this.photo = process.env.VUE_APP_BASE_API + row.staff.photo
       this.queryParams.staffId = row.staff.staffid
       this.getNowTime()
       this.getPlanList()