fei
3 天以前 d529e4e9f3b00ce5ff0d9d65670e37e422ec660c
修改了代码
12个文件已修改
167 ■■■■ 已修改文件
src/api/system/materials.js 9 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/router/index.js 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/archiveCategory/index.vue 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/archiveExport/index.vue 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/archiveManager/arMAutoUser.vue 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/archiveManager/archiveMaterial/index.vue 64 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/archiveManager/index.vue 67 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/archivePlaceName/index.vue 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/archiveProjectName/index.vue 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/archiveStatics/index.vue 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/archiveToUserStatistic/index.vue 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/system/user/index.vue 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/api/system/materials.js
@@ -69,7 +69,16 @@
    // }
  })
}
export function judge(recordId)
{
  return request({
    url:'/system/materials/judge/'+recordId,
    method:'get',
    // headers:{
    // }
  })
}
export function getFileCount(recordId)
{
  return request({
src/router/index.js
@@ -123,7 +123,7 @@
      },
      //案卷详细信息管理
      {
        path: 'archiveMaterialManager/:recordId/:pageCount',
        path: 'archiveMaterialManager/:recordId/:pageCount/:sho',
        component: () => import('@/views/archiveManager/archiveMaterial/index'),
        name: 'ArchiveMaterialManager',
        meta: { title: '详细信息', activeMenu: '/archiveManager/infoManager' }
src/views/archiveCategory/index.vue
@@ -287,14 +287,14 @@
    handleExport() {
      this.download('system/category/export', {
        ...this.queryParams
      }, `category_${new Date().getTime()}.xlsx`)
      }, `category_${new Date().getTime()}.xls`)
    },
            /** 导入模板下载操作*/
    handleExportTemplate()
    {
     this.download('/system/category/model', {
      }, `category_${new Date().getTime()}.xlsx`)
      }, `category_${new Date().getTime()}.xls`)
    },
     /** 导入操作*/
    async handleImport({file}){
src/views/archiveExport/index.vue
@@ -128,7 +128,7 @@
    </el-form>
    <el-row :gutter="10" class="mb8">
      <el-col :span="1.5">
      <!-- <el-col :span="1.5">
        <el-button
          type="primary"
          plain
@@ -159,7 +159,7 @@
          @click="handleDelete"
          v-hasPermi="['system:records:remove']"
        >删除</el-button>
      </el-col>
      </el-col> -->
      <el-col :span="1.5">
        <el-button
          type="warning"
src/views/archiveManager/arMAutoUser.vue
@@ -148,7 +148,6 @@
  created() {
    const roleId = this.$route.params && this.$route.params.roleId
    const recordId = this.$route.params && this.$route.params.archiveRecordsId
    if (roleId && recordId) {
      this.queryParams.roleId = roleId
      // 进行类型转换
src/views/archiveManager/archiveMaterial/index.vue
@@ -1,5 +1,7 @@
<template>
    <div class="app-container">
      <div v-if="sho">
         <h2 class="title-border">添加案卷详细记录</h2>
 <el-form ref="form" :model="form" :rules="rules" label-width="100px">
@@ -234,7 +236,7 @@
        </div>
</div>
<div class="title-border"></div>
@@ -255,6 +257,7 @@
        </el-col>
        <el-col :span="1.5">
          <el-button
          v-if="sho"
            type="success"
            plain
            icon="el-icon-edit"
@@ -263,6 +266,17 @@
            @click="handleUpdate"
            v-hasPermi="['system:materials:edit']"
          >修改</el-button>
        </el-col>
           <el-col :span="1.5">
          <el-button
            type="warning"
            plain
            icon="el-icon-download"
            size="mini"
            @click="handleExportDir"
            v-hasPermi="['system:materials:list']"
          >导出卷内目录</el-button>
        </el-col>
        <el-col :span="1.5">
          <el-button
@@ -273,10 +287,11 @@
            @click="handleExport"
            v-hasPermi="['system:materials:list']"
          >导出</el-button>
          >导出电子文件目录</el-button>
        </el-col>
        <el-col :span="1.5">
          <el-button
          v-if="sho"
            type="danger"
            plain
            icon="el-icon-delete"
@@ -289,6 +304,7 @@
          <el-col :span="1.5">
          <el-button
          v-if="sho"
            type="success"
            plain
            icon="el-icon-edit"
@@ -345,7 +361,7 @@
              accept=".xlsx,.xls"
        >
          <el-button size="mini"   type="primary"
          <el-button size="mini"  v-if="sho" type="primary"
                     plain
                     icon="el-icon-top">导入</el-button>
@@ -356,7 +372,7 @@
      <el-table v-loading="loading" :data="materialsList" @selection-change="handleSelectionChange">
        <el-table-column type="selection" width="55" align="center" />
        <el-table-column label="操作" align="center" width="160" class-name="small-padding ">
        <el-table-column v-if="sho" label="操作" align="center" width="160" class-name="small-padding ">
              <template slot-scope="scope">
                <el-button
                  size="mini"
@@ -393,8 +409,8 @@
        </el-table-column>
        <el-table-column label="页号" sortable align="center" prop="pageNumber"  />
        <el-table-column label="备注" align="center" prop="remarks" />
                <el-table-column label="页次" sortable align="center" prop="pageOrder"  />
            <!--          <el-table-column label="页次" sortable align="center" prop="pageOrder"  />
--->
        <el-table-column label="所处阶段" sortable align="center" width="180" prop="stage" />
        <el-table-column label="公开属性" sortable align="center" width="180" prop="publicity" />
        <el-table-column label="是否为附图及附件" align="center" prop="isAttachment" />
@@ -798,6 +814,8 @@
    name: "Materials",
    data() {
      return {
        //是否显示相关内容
        sho: true,
        totalPageCount: 0,
        // 记录元素初始位置和状态
  originalOffsetLeft: 0,
@@ -995,6 +1013,11 @@
      const recordId = this.$route.params && this.$route.params.recordId
      this.totalPageCount = this.$route.params && this.$route.params.pageCount
      this.sho = this.$route.params && this.$route.params.sho
      // 将字符串转换为布尔值
      this.sho = this.sho === true || this.sho === "true"
      //alert(this.totalPageCount)
      //alert(recordId)
      this.recordId = recordId;
@@ -1294,7 +1317,7 @@
      handleFileStyleChange(value) {
        // 当选择'其他材料'时,将页号设置为0
        if (value === '其他材料') {
          this.form.pageNumber = null;
          this.forms.pageNumber = null;
        }
      },
      // 处理材料类型变化(修改表单)
@@ -1475,6 +1498,7 @@
      },
      /** 提交按钮 */
      submitForms() {
        console.log(this.forms)
        this.$refs["forms"].validate(valid => {
          if (valid) {
            if (this.forms.materialId != null) {
@@ -1503,6 +1527,26 @@
          this.$modal.msgSuccess("删除成功")
        }).catch(() => {})
      },
           /** 导出按钮操作 - 支持导出选中行或全部数据 */
      handleExportDir() {
        // 判断是否有选中的行
        if (this.ids && this.ids.length > 0) {
          // 显示导出选中行的提示
          this.$message.info(`正在导出${this.ids.length}条选中的数据...`);
          // 导出选中的行数据
          this.download('system/materials/exportDir', {
            ids: this.ids.join(','),
         //   exportType: 'selected'
          }, `materiaDir_selected_${new Date().getTime()}.xls`)
        } else {
          // 显示导出全部数据的提示
          this.$message.info('正在导出符合当前查询条件的所有数据...');
          // 没有选中行时,导出当前查询条件的数据
          this.download('system/materials/exportDir', {
            ...this.queryParams
          }, `materiaDir_${new Date().getTime()}.xls`)
        }
      },
      /** 导出按钮操作 - 支持导出选中行或全部数据 */
      handleExport() {
        // 判断是否有选中的行
@@ -1513,14 +1557,14 @@
          this.download('system/materials/export', {
            ids: this.ids.join(','),
         //   exportType: 'selected'
          }, `materials_selected_${new Date().getTime()}.xlsx`)
          }, `materials_selected_${new Date().getTime()}.xls`)
        } else {
          // 显示导出全部数据的提示
          this.$message.info('正在导出符合当前查询条件的所有数据...');
          // 没有选中行时,导出当前查询条件的数据
          this.download('system/materials/export', {
            ...this.queryParams
          }, `materials_${new Date().getTime()}.xlsx`)
          }, `materials_${new Date().getTime()}.xls`)
        }
      },
@@ -1529,7 +1573,7 @@
    {
      this.download('/system/materials/model', {
      }, `materials_${new Date().getTime()}.xlsx`)
      }, `materials_${new Date().getTime()}.xls`)
    },
       /** 导入操作*/
    async handleImportData({file}){
src/views/archiveManager/index.vue
@@ -366,7 +366,15 @@
                  @click="handleInfo(scope.row)"
                  v-hasPermi="['system:records:edit']"
                >编辑卷内目录</el-button>
          <el-button
                v-if="userId===1"
                  size="mini"
                  type="text"
                  icon="el-icon-edit"
                  @click="CheckInfo(scope.row)"
                  v-hasPermi="['system:records:edit']"
                >查看卷内目录</el-button>
                <el-button
                  size="mini"
                  type="text"
@@ -389,6 +397,7 @@
                  @click="handleSubmit(scope.row)"
                  v-hasPermi="['system:records:edit']"
                >提交案卷</el-button>
                <el-button
                v-if="scope.row.ownData||userId===1"
@@ -872,6 +881,7 @@
import { listAllCategory } from "@/api/system/category"
import { listAllProjectName } from "@/api/system/projectName"
import { listPlaceName, listAllPlaceName } from "@/api/system/placeName"
import { judge } from "@/api/system/materials"
export default {
     components: {
        VueOfficeExcel
@@ -1295,7 +1305,22 @@
      this.vis = false;
      this.title = "添加档案记录"
    },
    /*查看详情*/
    CheckInfo(row)
    {
      var mid = row.id
      const roleId = 2
   //   alert(mid)
      var recordId = mid
      var pageCount = row.pageCount
      var sho = false
    //  this.$router.push("/archiveManager/infoManagerAu/user/" + roleId+"/"+recordId)
      this.$router.push("/archiveManager/infoManagerAu/archiveMaterialManager/" + recordId+"/"+pageCount+"/"+sho)
    },
    handleInfo(row)
    {
@@ -1305,8 +1330,9 @@
      var recordId = mid
      var pageCount = row.pageCount
      var sho = true
    //  this.$router.push("/archiveManager/infoManagerAu/user/" + roleId+"/"+recordId)
      this.$router.push("/archiveManager/infoManagerAu/archiveMaterialManager/" + recordId+"/"+pageCount)
      this.$router.push("/archiveManager/infoManagerAu/archiveMaterialManager/" + recordId+"/"+pageCount+"/"+sho)
    },
    //
@@ -1314,10 +1340,24 @@
    {
     //alert(row.id)
      var id = row.id
      var status = '录入完成'
      updateStatusById(status, id).then(response=>{
        this.$modal.msgSuccess("提交成功")
        this.getList()
      // 在提交之前,调用后端接口检查是否已经上传附件
      judge(id).then(response => {
        // console.log(response)
        // alert(response.data)
        if (response.data===undefined||response.data === false) {
          // 如果文件数量为0,提示用户先上传附件
          this.$modal.msgWarning('请先上传附件,再进行提交操作')
        } else {
          // 如果已经上传了附件,继续提交操作
          var status = '录入完成'
          updateStatusById(status, id).then(response=>{
            this.$modal.msgSuccess("提交成功")
            this.getList()
          })
        }
      }).catch(error => {
        console.error('检查附件数量失败:', error)
        this.$modal.msgError('检查附件数量失败,请稍后重试')
      })
    },
    /** 修改按钮操作 */
@@ -1457,8 +1497,7 @@
    /** 分配用户操作 */
    handleAuthUser: function(row) {
      const roleId = 2
      var archiveRecordsId = row.recordId
      var archiveRecordsId = row.id
      this.$router.push("/archiveManager/infoManagerAu/user/" + roleId+"/"+archiveRecordsId)
    },
    /** 删除按钮操作 */
@@ -1480,12 +1519,12 @@
        // 只导出选中的记录
        this.download('system/records/export', {
          ids: this.ids.join(',') // 将选中的ID数组转换为逗号分隔的字符串
        }, `records_${new Date().getTime()}.xlsx`)
        }, `records_${new Date().getTime()}.xls`)
      } else {
        // 没有选中记录时,导出符合查询条件的所有记录
        this.download('system/records/export', {
          ...this.queryParams
        }, `records_${new Date().getTime()}.xlsx`)
        }, `records_${new Date().getTime()}.xls`)
      }
    },
@@ -1731,7 +1770,7 @@
        // if (selectedAnnotations.length > 0) {
        //   filename += `_anno${selectedAnnotations.join('')}`;
        // }
        filename += `_${new Date().getTime()}.xlsx`;
        filename += `_${new Date().getTime()}.xls`;
        link.download = filename;
@@ -2011,7 +2050,7 @@
        // 直接下载
        const link = document.createElement('a');
        link.href = url;
        link.download = `${prefix}_${new Date().getTime()}.xlsx`;
        link.download = `${prefix}_${new Date().getTime()}.xls`;
        document.body.appendChild(link);
        link.click();
        document.body.removeChild(link);
@@ -2030,7 +2069,7 @@
            const url = URL.createObjectURL(blob);
            const link = document.createElement('a');
            link.href = url;
            link.download = `record_${id}_${new Date().getTime()}.xlsx`;
            link.download = `record_${id}_${new Date().getTime()}.xls`;
            document.body.appendChild(link);
            link.click();
            document.body.removeChild(link);
@@ -2049,13 +2088,13 @@
    {
      this.download('/system/records/model', {
      }, `records_${new Date().getTime()}.xlsx`)
      }, `records_${new Date().getTime()}.xls`)
    },
    handleExportTemplateOther()
    {
          this.download('/system/records/modelOther', {
      }, `records_${new Date().getTime()}.xlsx`)
      }, `records_${new Date().getTime()}.xls`)
    },
  /** 导入操作*/
    async handleImportData({file}){
src/views/archivePlaceName/index.vue
@@ -288,7 +288,7 @@
      this.download('/system/placeName/export', {
        ...this.queryParams
      }, `name_${new Date().getTime()}.xlsx`)
      }, `name_${new Date().getTime()}.xls`)
    },
             /** 导入模板下载操作*/
    handleExportTemplate()
@@ -296,7 +296,7 @@
    
     this.download('/system/placeName/model', {
      }, `placeName_${new Date().getTime()}.xlsx`)
      }, `placeName_${new Date().getTime()}.xls`)
    },
      /** 导入操作*/
    async handleImport({file}){
src/views/archiveProjectName/index.vue
@@ -308,14 +308,14 @@
    handleExport() {
      this.download('system/projectName/export', {
        ...this.queryParams
      }, `name_${new Date().getTime()}.xlsx`)
      }, `name_${new Date().getTime()}.xls`)
    },
    /** 导入模板下载操作*/
    handleExportTemplate()
    {
      this.download('/system/projectName/model', {
      }, `projectName_${new Date().getTime()}.xlsx`)
      }, `projectName_${new Date().getTime()}.xls`)
    },
    
      /** 导入操作*/
src/views/archiveStatics/index.vue
@@ -547,7 +547,7 @@
     // alert(98)
      this.download('system/records/exportAllStatis', {
       // ...this.queryParams
      }, `records_${new Date().getTime()}.xlsx`)
      }, `records_${new Date().getTime()}.xls`)
    }
  }
}
src/views/archiveToUserStatistic/index.vue
@@ -357,7 +357,7 @@
    handleExport() {
      this.download('system/archiverecordstouser/exportArToUser', {
        // ...this.queryParams
      }, `records_${new Date().getTime()}.xlsx`)
      }, `records_${new Date().getTime()}.xls`)
    }
  }
}
src/views/system/user/index.vue
@@ -524,7 +524,7 @@
    handleExport() {
      this.download('system/user/export', {
        ...this.queryParams
      }, `user_${new Date().getTime()}.xlsx`)
      }, `user_${new Date().getTime()}.xls`)
    },
    /** 导入按钮操作 */
    handleImport() {
@@ -534,7 +534,7 @@
    /** 下载模板操作 */
    importTemplate() {
      this.download('system/user/importTemplate', {
      }, `user_template_${new Date().getTime()}.xlsx`)
      }, `user_template_${new Date().getTime()}.xls`)
    },
    // 文件上传中处理
    handleFileUploadProgress(event, file, fileList) {