|
@@ -1,409 +1,247 @@
|
|
|
<template>
|
|
<template>
|
|
|
- <div class="">
|
|
|
|
|
- <div class="">
|
|
|
|
|
- <div class="flex-container">
|
|
|
|
|
- <div class="flex-content">
|
|
|
|
|
- <!--文件夹管理-->
|
|
|
|
|
- <div class="flex-aside-left">
|
|
|
|
|
- <div>
|
|
|
|
|
- <Navbar :title="projectName" :is-go-back="true" />
|
|
|
|
|
- <div class="flex-box">
|
|
|
|
|
- <button
|
|
|
|
|
- class="btn btn-default flex-item"
|
|
|
|
|
- @click="updateProjectArchiveFolderByTaskId()"
|
|
|
|
|
- >
|
|
|
|
|
- 项目任务自动生成
|
|
|
|
|
- </button>
|
|
|
|
|
- </div>
|
|
|
|
|
- <div class="flex-box">
|
|
|
|
|
- <button class="btn btn-default flex-item" @click="openFolder()">
|
|
|
|
|
- 新建
|
|
|
|
|
- </button>
|
|
|
|
|
- <button
|
|
|
|
|
- class="btn btn-default flex-item"
|
|
|
|
|
- style="margin-left: 5px"
|
|
|
|
|
- @click="openFolder4()"
|
|
|
|
|
- >
|
|
|
|
|
- 修改
|
|
|
|
|
- </button>
|
|
|
|
|
- <button
|
|
|
|
|
- class="btn btn-default flex-item"
|
|
|
|
|
- style="margin-left: 5px"
|
|
|
|
|
- @click="openDeleteFolder()"
|
|
|
|
|
- >
|
|
|
|
|
- 删除
|
|
|
|
|
- </button>
|
|
|
|
|
- </div>
|
|
|
|
|
- <div id="tree" style="margin-top: 10px" />
|
|
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
|
|
+ <div>
|
|
|
|
|
+ <a-layout>
|
|
|
|
|
+ <a-layout-content>
|
|
|
|
|
+ <a-row>
|
|
|
|
|
+ <a-col :span="24">
|
|
|
|
|
+ <!-- 左侧文件夹管理 -->
|
|
|
|
|
+ <a-layout>
|
|
|
|
|
+ <a-layout-sider width="230" style="background-color: white; padding: 10px; height: calc(100vh - 80px); overflow-y: auto; border: 1px solid #e4e4e4">
|
|
|
|
|
+ <Navbar :title="projectName" :is-go-back="true" />
|
|
|
|
|
+ <a-space direction="vertical" style="width: 100%">
|
|
|
|
|
+ <a-button block @click="updateProjectArchiveFolderByTaskId()">
|
|
|
|
|
+ 项目任务自动生成
|
|
|
|
|
+ </a-button>
|
|
|
|
|
+ <a-space>
|
|
|
|
|
+ <a-button @click="openFolder()">新建</a-button>
|
|
|
|
|
+ <a-button @click="openFolder4()">修改</a-button>
|
|
|
|
|
+ <a-button @click="openDeleteFolder()">删除</a-button>
|
|
|
|
|
+ </a-space>
|
|
|
|
|
+ <a-tree
|
|
|
|
|
+ id="tree"
|
|
|
|
|
+ :show-line="true"
|
|
|
|
|
+ :tree-data="projectArchiveFolderDtos"
|
|
|
|
|
+ :field-names="{
|
|
|
|
|
+ key: 'id',
|
|
|
|
|
+ title: 'text',
|
|
|
|
|
+ children: 'nodes',
|
|
|
|
|
+ }"
|
|
|
|
|
+ @select="onTreeSelect"
|
|
|
|
|
+ />
|
|
|
|
|
+ </a-space>
|
|
|
|
|
+ </a-layout-sider>
|
|
|
|
|
|
|
|
- <div class="flex-main">
|
|
|
|
|
- <div>
|
|
|
|
|
- <div class="flex-main-serch">
|
|
|
|
|
- <div class="form-inline">
|
|
|
|
|
- <div class="flex-box">
|
|
|
|
|
- <input
|
|
|
|
|
|
|
+ <!-- 中间内容区 -->
|
|
|
|
|
+ <a-layout-content style="border-top: 1px solid #e4e4e4; border-bottom: 1px solid #e4e4e4; overflow-y: auto; height: calc(100vh - 80px)">
|
|
|
|
|
+ <a-card :bordered="false" style="margin-bottom: 10px">
|
|
|
|
|
+ <a-space>
|
|
|
|
|
+ <a-input
|
|
|
id="archiveName"
|
|
id="archiveName"
|
|
|
- v-model="param"
|
|
|
|
|
- autocomplete="off"
|
|
|
|
|
- class="form-control flex-item"
|
|
|
|
|
|
|
+ v-model:value="param"
|
|
|
placeholder="归档项名称或者文件名称"
|
|
placeholder="归档项名称或者文件名称"
|
|
|
- @keyup.enter="queryByProjectArchiveDtosByParam()"
|
|
|
|
|
|
|
+ @press-enter="queryByProjectArchiveDtosByParam()"
|
|
|
/>
|
|
/>
|
|
|
|
|
+ <a-button @click="queryByProjectArchiveDtosByParam()">查询</a-button>
|
|
|
|
|
+ <a-button @click="openFolder1()">新建归档项</a-button>
|
|
|
|
|
+ <a-button danger @click="openDeleteProject()">删除归档项</a-button>
|
|
|
|
|
+ </a-space>
|
|
|
|
|
+ </a-card>
|
|
|
|
|
|
|
|
- <button
|
|
|
|
|
- class="btn btn-default flex-item-1"
|
|
|
|
|
- style="margin-left: 5px"
|
|
|
|
|
- @click="queryByProjectArchiveDtosByParam()"
|
|
|
|
|
- >
|
|
|
|
|
- 查询
|
|
|
|
|
- </button>
|
|
|
|
|
- <button
|
|
|
|
|
- class="btn btn-default flex-item-1"
|
|
|
|
|
- style="margin-left: 5px"
|
|
|
|
|
- @click="openFolder1()"
|
|
|
|
|
- >
|
|
|
|
|
- 新建归档项
|
|
|
|
|
- </button>
|
|
|
|
|
- <button
|
|
|
|
|
- class="btn btn-danger flex-item-1"
|
|
|
|
|
- style="margin-left: 5px"
|
|
|
|
|
- @click="openDeleteProject()"
|
|
|
|
|
- >
|
|
|
|
|
- 删除归档项
|
|
|
|
|
- </button>
|
|
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
|
|
+ <a-table
|
|
|
|
|
+ :data-source="projectArchiveDtos"
|
|
|
|
|
+ :row-class-name="(record) => projectArchivesId === record.id ? 'ant-table-row-selected' : ''"
|
|
|
|
|
+ :pagination="false"
|
|
|
|
|
+ row-key="id"
|
|
|
|
|
+ @row-click="trClick"
|
|
|
|
|
+ >
|
|
|
|
|
+ <a-table-column key="name" title="归档项名称" data-index="name" />
|
|
|
|
|
+ <a-table-column key="createDate" title="创建时间" data-index="createDate" />
|
|
|
|
|
+ <a-table-column key="planArchiveDate" title="计划归档日期" data-index="planArchiveDate" />
|
|
|
|
|
+ <a-table-column key="fileName" title="归档文件名" data-index="fileName" />
|
|
|
|
|
+ <a-table-column key="archiveUserName" title="归档人" data-index="archiveUserName" />
|
|
|
|
|
+ <a-table-column key="archiveDate" title="归档时间" data-index="archiveDate" />
|
|
|
|
|
+ </a-table>
|
|
|
|
|
+ </a-layout-content>
|
|
|
|
|
|
|
|
- <table class="table" style="margin-top: 10px">
|
|
|
|
|
- <thead>
|
|
|
|
|
- <tr>
|
|
|
|
|
- <!--<th>
|
|
|
|
|
- 项目名称
|
|
|
|
|
- </th>-->
|
|
|
|
|
- <th>归档项名称</th>
|
|
|
|
|
- <th>创建时间</th>
|
|
|
|
|
- <th>计划归档日期</th>
|
|
|
|
|
- <th>归档文件名</th>
|
|
|
|
|
- <!--<th>
|
|
|
|
|
- 归档文件大小
|
|
|
|
|
- </th>-->
|
|
|
|
|
- <th>归档人</th>
|
|
|
|
|
- <th>归档时间</th>
|
|
|
|
|
- </tr>
|
|
|
|
|
- </thead>
|
|
|
|
|
- <tbody>
|
|
|
|
|
- <tr
|
|
|
|
|
- v-for="item in projectArchiveDtos"
|
|
|
|
|
- :key="item"
|
|
|
|
|
- :class="projectArchivesId == item.id ? 'success' : ''"
|
|
|
|
|
- @click="trClick(item)"
|
|
|
|
|
- @dblclick="openFolder2()"
|
|
|
|
|
- >
|
|
|
|
|
- <!--<td>
|
|
|
|
|
- {{item.projectItemName}}
|
|
|
|
|
- </td>-->
|
|
|
|
|
- <td>
|
|
|
|
|
- {{ item.name }}
|
|
|
|
|
- </td>
|
|
|
|
|
- <td>
|
|
|
|
|
- {{ item.createDate }}
|
|
|
|
|
- </td>
|
|
|
|
|
- <td>
|
|
|
|
|
- {{ item.planArchiveDate }}
|
|
|
|
|
- </td>
|
|
|
|
|
- <td>
|
|
|
|
|
- {{ item.fileName }}
|
|
|
|
|
- </td>
|
|
|
|
|
- <!--<td>
|
|
|
|
|
- {{item.fileSize}}
|
|
|
|
|
- </td>-->
|
|
|
|
|
- <td>
|
|
|
|
|
- {{ item.archiveUserName }}
|
|
|
|
|
- </td>
|
|
|
|
|
- <td>
|
|
|
|
|
- {{ item.archiveDate }}
|
|
|
|
|
- </td>
|
|
|
|
|
- </tr>
|
|
|
|
|
- </tbody>
|
|
|
|
|
- </table>
|
|
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
- <!--归档项下载和历史记录-->
|
|
|
|
|
- <div class="flex-aside-right">
|
|
|
|
|
- <div>
|
|
|
|
|
- <div id="tabs-911500" class="tabbable">
|
|
|
|
|
- <ul class="nav nav-tabs">
|
|
|
|
|
- <li class="active">
|
|
|
|
|
- <a href="#panel1" data-toggle="tab">详细信息</a>
|
|
|
|
|
- </li>
|
|
|
|
|
- <li>
|
|
|
|
|
- <a href="#panel3" data-toggle="tab">历史记录</a>
|
|
|
|
|
- </li>
|
|
|
|
|
- </ul>
|
|
|
|
|
- <div class="tab-content">
|
|
|
|
|
- <div id="panel1" class="tab-pane active">
|
|
|
|
|
- <div
|
|
|
|
|
- v-if="
|
|
|
|
|
- projectArchivesDto.fileName != '' &&
|
|
|
|
|
- projectArchivesDto.fileName != undefined
|
|
|
|
|
- "
|
|
|
|
|
- class="row m-row"
|
|
|
|
|
- >
|
|
|
|
|
- <div class="col-sm-12">
|
|
|
|
|
- <div class="thumbnail">
|
|
|
|
|
- <div class="caption">
|
|
|
|
|
- <p>
|
|
|
|
|
- <strong>文件名:</strong>{{ projectArchivesDto.fileName }}
|
|
|
|
|
- </p>
|
|
|
|
|
- <p>
|
|
|
|
|
- <strong>文件大小:</strong>{{ projectArchivesDto.fileSize }}KB
|
|
|
|
|
- </p>
|
|
|
|
|
- <p>
|
|
|
|
|
- <strong>上传人:</strong>{{ projectArchivesDto.archiveUserName }}
|
|
|
|
|
- </p>
|
|
|
|
|
- <p>
|
|
|
|
|
- <strong>上传时间:</strong>{{ projectArchivesDto.archiveDate }}
|
|
|
|
|
- </p>
|
|
|
|
|
- <button
|
|
|
|
|
- class="btn btn-link"
|
|
|
|
|
- @click="download(projectArchivesDto.fileName)"
|
|
|
|
|
- >
|
|
|
|
|
- 下载
|
|
|
|
|
- </button>
|
|
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
|
|
+ <!-- 右侧详情区域 -->
|
|
|
|
|
+ <a-layout-sider width="300" style="background-color: white; padding: 10px; height: calc(100vh - 80px); overflow-y: auto; border: 1px solid #e4e4e4">
|
|
|
|
|
+ <a-tabs default-active-key="1">
|
|
|
|
|
+ <a-tab-pane key="1" tab="详细信息">
|
|
|
|
|
+ <div v-if="projectArchivesDto.fileName && projectArchivesDto.fileName !== ''">
|
|
|
|
|
+ <a-card>
|
|
|
|
|
+ <a-typography>
|
|
|
|
|
+ <a-typography-paragraph>
|
|
|
|
|
+ <a-typography-text strong>文件名:</a-typography-text>{{ projectArchivesDto.fileName }}
|
|
|
|
|
+ </a-typography-paragraph>
|
|
|
|
|
+ <a-typography-paragraph>
|
|
|
|
|
+ <a-typography-text strong>文件大小:</a-typography-text>{{ projectArchivesDto.fileSize }}KB
|
|
|
|
|
+ </a-typography-paragraph>
|
|
|
|
|
+ <a-typography-paragraph>
|
|
|
|
|
+ <a-typography-text strong>上传人:</a-typography-text>{{ projectArchivesDto.archiveUserName }}
|
|
|
|
|
+ </a-typography-paragraph>
|
|
|
|
|
+ <a-typography-paragraph>
|
|
|
|
|
+ <a-typography-text strong>上传时间:</a-typography-text>{{ projectArchivesDto.archiveDate }}
|
|
|
|
|
+ </a-typography-paragraph>
|
|
|
|
|
+ </a-typography>
|
|
|
|
|
+ <a-button type="link" @click="download(projectArchivesDto.fileName)">下载</a-button>
|
|
|
|
|
+ </a-card>
|
|
|
</div>
|
|
</div>
|
|
|
- </div>
|
|
|
|
|
- <div id="panel3" class="tab-pane">
|
|
|
|
|
- <template v-for="item in projectArchiveAuditDtos">
|
|
|
|
|
- <div
|
|
|
|
|
- v-if="item.fileName != '' && item.fileName != undefined"
|
|
|
|
|
- :key="item.id"
|
|
|
|
|
- class="row m-row"
|
|
|
|
|
- >
|
|
|
|
|
- <div class="col-sm-12">
|
|
|
|
|
- <div class="thumbnail">
|
|
|
|
|
- <div class="caption">
|
|
|
|
|
- <p>
|
|
|
|
|
- <strong>文件名:</strong>{{ item.fileName }}
|
|
|
|
|
- </p>
|
|
|
|
|
- <p>
|
|
|
|
|
- <strong>文件大小:</strong>{{ item.fileSize }}KB
|
|
|
|
|
- </p>
|
|
|
|
|
- <p>
|
|
|
|
|
- <strong>上传人:</strong>{{ item.archiveUserName }}
|
|
|
|
|
- </p>
|
|
|
|
|
- <p>
|
|
|
|
|
- <strong>上传时间:</strong>{{ item.archiveDate }}
|
|
|
|
|
- </p>
|
|
|
|
|
- <button
|
|
|
|
|
- class="btn btn-link"
|
|
|
|
|
- @click="download(item.fileName)"
|
|
|
|
|
- >
|
|
|
|
|
- 下载
|
|
|
|
|
- </button>
|
|
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
- </template>
|
|
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
|
|
+ </a-tab-pane>
|
|
|
|
|
+ <a-tab-pane key="2" tab="历史记录">
|
|
|
|
|
+ <a-list item-layout="vertical">
|
|
|
|
|
+ <a-list-item v-for="item in projectArchiveAuditDtos" :key="item.id">
|
|
|
|
|
+ <template v-if="item.fileName && item.fileName !== ''">
|
|
|
|
|
+ <a-card>
|
|
|
|
|
+ <a-typography>
|
|
|
|
|
+ <a-typography-paragraph>
|
|
|
|
|
+ <a-typography-text strong>文件名:</a-typography-text>{{ item.fileName }}
|
|
|
|
|
+ </a-typography-paragraph>
|
|
|
|
|
+ <a-typography-paragraph>
|
|
|
|
|
+ <a-typography-text strong>文件大小:</a-typography-text>{{ item.fileSize }}KB
|
|
|
|
|
+ </a-typography-paragraph>
|
|
|
|
|
+ <a-typography-paragraph>
|
|
|
|
|
+ <a-typography-text strong>上传人:</a-typography-text>{{ item.archiveUserName }}
|
|
|
|
|
+ </a-typography-paragraph>
|
|
|
|
|
+ <a-typography-paragraph>
|
|
|
|
|
+ <a-typography-text strong>上传时间:</a-typography-text>{{ item.archiveDate }}
|
|
|
|
|
+ </a-typography-paragraph>
|
|
|
|
|
+ </a-typography>
|
|
|
|
|
+ <a-button type="link" @click="download(item.fileName)">下载</a-button>
|
|
|
|
|
+ </a-card>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </a-list-item>
|
|
|
|
|
+ </a-list>
|
|
|
|
|
+ </a-tab-pane>
|
|
|
|
|
+ </a-tabs>
|
|
|
|
|
+ </a-layout-sider>
|
|
|
|
|
+ </a-layout>
|
|
|
|
|
+ </a-col>
|
|
|
|
|
+ </a-row>
|
|
|
|
|
+ </a-layout-content>
|
|
|
|
|
+ </a-layout>
|
|
|
|
|
|
|
|
- <div>
|
|
|
|
|
- <Modal
|
|
|
|
|
- v-model:show="modal1"
|
|
|
|
|
- :small="true"
|
|
|
|
|
- :show-ok-button="true"
|
|
|
|
|
- :show-canel-button="true"
|
|
|
|
|
- @ok="saveProjectArchiveFolder"
|
|
|
|
|
- @cancel="cancel"
|
|
|
|
|
- >
|
|
|
|
|
- <template #header>
|
|
|
|
|
- {{ type + "文件夹" }}
|
|
|
|
|
- </template>
|
|
|
|
|
- <label>文件名</label>
|
|
|
|
|
- <input
|
|
|
|
|
- v-model="folderName"
|
|
|
|
|
- autocomplete="off"
|
|
|
|
|
- type="text"
|
|
|
|
|
- class="form-control"
|
|
|
|
|
- placeholder="文件夹名称"
|
|
|
|
|
- />
|
|
|
|
|
- </Modal>
|
|
|
|
|
|
|
+ <!-- 新建文件夹弹窗 -->
|
|
|
|
|
+ <a-modal
|
|
|
|
|
+ v-model:open="modal1"
|
|
|
|
|
+ :title="type + '文件夹'"
|
|
|
|
|
+ @ok="saveProjectArchiveFolder"
|
|
|
|
|
+ @cancel="cancel"
|
|
|
|
|
+ >
|
|
|
|
|
+ <a-form layout="vertical">
|
|
|
|
|
+ <a-form-item label="文件名">
|
|
|
|
|
+ <a-input v-model:value="folderName" placeholder="文件夹名称" />
|
|
|
|
|
+ </a-form-item>
|
|
|
|
|
+ </a-form>
|
|
|
|
|
+ </a-modal>
|
|
|
|
|
|
|
|
- <Modal
|
|
|
|
|
- v-model:show="modal4"
|
|
|
|
|
- :small="true"
|
|
|
|
|
- :show-ok-button="true"
|
|
|
|
|
- :show-canel-button="true"
|
|
|
|
|
- @ok="updateProjectArchiveFolder"
|
|
|
|
|
- @cancel="cancel2"
|
|
|
|
|
- >
|
|
|
|
|
- <template #header>
|
|
|
|
|
- {{ type + "文件夹" }}
|
|
|
|
|
- </template>
|
|
|
|
|
- <div class="form-group">
|
|
|
|
|
- <label for="projectFolder">上级文件名</label>
|
|
|
|
|
|
|
+ <!-- 修改文件夹弹窗 -->
|
|
|
|
|
+ <a-modal
|
|
|
|
|
+ v-model:open="modal4"
|
|
|
|
|
+ :title="type + '文件夹'"
|
|
|
|
|
+ @ok="updateProjectArchiveFolder"
|
|
|
|
|
+ @cancel="cancel2"
|
|
|
|
|
+ >
|
|
|
|
|
+ <a-form layout="vertical">
|
|
|
|
|
+ <a-form-item label="上级文件名">
|
|
|
<a-select
|
|
<a-select
|
|
|
v-model:value="project"
|
|
v-model:value="project"
|
|
|
allow-clear
|
|
allow-clear
|
|
|
- style="width: 100%; height: 30px"
|
|
|
|
|
|
|
+ style="width: 100%"
|
|
|
:options="allProject"
|
|
:options="allProject"
|
|
|
@change="projectChange"
|
|
@change="projectChange"
|
|
|
/>
|
|
/>
|
|
|
- <!-- <select id="projectFolder" class="form-control" /> -->
|
|
|
|
|
- </div>
|
|
|
|
|
- <div class="form-group">
|
|
|
|
|
- <label>文件名</label>
|
|
|
|
|
- <input
|
|
|
|
|
- v-model="folderName"
|
|
|
|
|
- autocomplete="off"
|
|
|
|
|
- type="text"
|
|
|
|
|
- class="form-control"
|
|
|
|
|
- placeholder="文件夹名称"
|
|
|
|
|
- />
|
|
|
|
|
- </div>
|
|
|
|
|
- </Modal>
|
|
|
|
|
|
|
+ </a-form-item>
|
|
|
|
|
+ <a-form-item label="文件名">
|
|
|
|
|
+ <a-input v-model:value="folderName" placeholder="文件夹名称" />
|
|
|
|
|
+ </a-form-item>
|
|
|
|
|
+ </a-form>
|
|
|
|
|
+ </a-modal>
|
|
|
|
|
|
|
|
- <!-- 是否删除文件夹 -->
|
|
|
|
|
- <Modal
|
|
|
|
|
- v-model:show="modal5"
|
|
|
|
|
- :small="true"
|
|
|
|
|
- :show-ok-button="true"
|
|
|
|
|
- :show-canel-button="true"
|
|
|
|
|
- @ok="deleteFolder"
|
|
|
|
|
- @cancel="cancelFolder"
|
|
|
|
|
- >
|
|
|
|
|
- <template #header>
|
|
|
|
|
- {{ "删除文件夹" }}
|
|
|
|
|
- </template>
|
|
|
|
|
- <h3>
|
|
|
|
|
- 您确认要删除{{
|
|
|
|
|
- folderName
|
|
|
|
|
- }}文件夹吗?如果是的话,请点击【确定】按钮,否则点击【取消】按钮。
|
|
|
|
|
- </h3>
|
|
|
|
|
- </Modal>
|
|
|
|
|
- <!-- 是否删除归档项 -->
|
|
|
|
|
- <Modal
|
|
|
|
|
- v-model:show="modal6"
|
|
|
|
|
- :small="true"
|
|
|
|
|
- :show-ok-button="true"
|
|
|
|
|
- :show-canel-button="true"
|
|
|
|
|
- @ok="deleteProjectArchives"
|
|
|
|
|
- @cancel="cancelProject"
|
|
|
|
|
- >
|
|
|
|
|
- <template #header>
|
|
|
|
|
- {{ "删除归档项" }}
|
|
|
|
|
- </template>
|
|
|
|
|
- <h3>
|
|
|
|
|
- 您确认要删除{{
|
|
|
|
|
- projectArchivesDto.name
|
|
|
|
|
- }}归档项吗?如果是的话,请点击【确定】按钮,否则点击【取消】按钮。
|
|
|
|
|
- </h3>
|
|
|
|
|
- </Modal>
|
|
|
|
|
|
|
+ <!-- 删除文件夹确认弹窗 -->
|
|
|
|
|
+ <a-modal
|
|
|
|
|
+ v-model:open="modal5"
|
|
|
|
|
+ title="删除文件夹"
|
|
|
|
|
+ @ok="deleteFolder"
|
|
|
|
|
+ @cancel="cancelFolder"
|
|
|
|
|
+ >
|
|
|
|
|
+ <a-typography>
|
|
|
|
|
+ <a-typography-title :level="5">您确认要删除 {{ folderName }} 文件夹吗?</a-typography-title>
|
|
|
|
|
+ <a-typography-paragraph>
|
|
|
|
|
+ 如果是的话,请点击【确定】按钮,否则点击【取消】按钮。
|
|
|
|
|
+ </a-typography-paragraph>
|
|
|
|
|
+ </a-typography>
|
|
|
|
|
+ </a-modal>
|
|
|
|
|
|
|
|
- <!--
|
|
|
|
|
- 作者:GuoZhiBo
|
|
|
|
|
- 时间:2019-10-14
|
|
|
|
|
- 描述:归档项新增和修改
|
|
|
|
|
- -->
|
|
|
|
|
- <Modal
|
|
|
|
|
- v-model:show="modal2"
|
|
|
|
|
- :small="true"
|
|
|
|
|
- :show-ok-button="true"
|
|
|
|
|
- :show-canel-button="true"
|
|
|
|
|
- @ok="saveProjectArchives"
|
|
|
|
|
- @cancel="cancel1"
|
|
|
|
|
- >
|
|
|
|
|
- <template #header>
|
|
|
|
|
- {{ type + "归档项" }}
|
|
|
|
|
- </template>
|
|
|
|
|
- <div class="form-group">
|
|
|
|
|
- <label for="exampleInputEmail2">归档项名称</label>
|
|
|
|
|
- <input
|
|
|
|
|
- v-model="projectArchivesDto.name"
|
|
|
|
|
- autocomplete="off"
|
|
|
|
|
- style="width: 100%"
|
|
|
|
|
- class="form-control"
|
|
|
|
|
- />
|
|
|
|
|
- </div>
|
|
|
|
|
- <div class="form-group">
|
|
|
|
|
- <label for="exampleInputEmail2">计划归档日期</label>
|
|
|
|
|
|
|
+ <!-- 删除归档项确认弹窗 -->
|
|
|
|
|
+ <a-modal
|
|
|
|
|
+ v-model:open="modal6"
|
|
|
|
|
+ title="删除归档项"
|
|
|
|
|
+ @ok="deleteProjectArchives"
|
|
|
|
|
+ @cancel="cancelProject"
|
|
|
|
|
+ >
|
|
|
|
|
+ <a-typography>
|
|
|
|
|
+ <a-typography-title :level="5">您确认要删除 {{ projectArchivesDto.name }} 归档项吗?</a-typography-title>
|
|
|
|
|
+ <a-typography-paragraph>
|
|
|
|
|
+ 如果是的话,请点击【确定】按钮,否则点击【取消】按钮。
|
|
|
|
|
+ </a-typography-paragraph>
|
|
|
|
|
+ </a-typography>
|
|
|
|
|
+ </a-modal>
|
|
|
|
|
+
|
|
|
|
|
+ <!-- 归档项新增和修改弹窗 -->
|
|
|
|
|
+ <a-modal
|
|
|
|
|
+ v-model:open="modal2"
|
|
|
|
|
+ :title="type + '归档项'"
|
|
|
|
|
+ @ok="saveProjectArchives"
|
|
|
|
|
+ @cancel="cancel1"
|
|
|
|
|
+ >
|
|
|
|
|
+ <a-form layout="vertical">
|
|
|
|
|
+ <a-form-item label="归档项名称">
|
|
|
|
|
+ <a-input v-model:value="projectArchivesDto.name" style="width: 100%" />
|
|
|
|
|
+ </a-form-item>
|
|
|
|
|
+ <a-form-item label="计划归档日期">
|
|
|
<Date v-model="planArchiveDate" style="width: 100%" />
|
|
<Date v-model="planArchiveDate" style="width: 100%" />
|
|
|
- </div>
|
|
|
|
|
- <div class="form-group">
|
|
|
|
|
- <label for="exampleInputEmail2">文件名称</label>
|
|
|
|
|
- <input
|
|
|
|
|
- v-model="projectArchivesDto.fileName"
|
|
|
|
|
- autocomplete="off"
|
|
|
|
|
- style="width: 100%"
|
|
|
|
|
- class="form-control"
|
|
|
|
|
- readonly="readonly"
|
|
|
|
|
- />
|
|
|
|
|
- <!--<span @click="projectArchivesDto.fileName = ''">删除</span>-->
|
|
|
|
|
- </div>
|
|
|
|
|
- <div class="form-group">
|
|
|
|
|
- <label for="exampleInputEmail2">文件大小(KB)</label>
|
|
|
|
|
- <input
|
|
|
|
|
- v-model="projectArchivesDto.fileSize"
|
|
|
|
|
- autocomplete="off"
|
|
|
|
|
- style="width: 100%"
|
|
|
|
|
- class="form-control"
|
|
|
|
|
- readonly="readonly"
|
|
|
|
|
- />
|
|
|
|
|
- </div>
|
|
|
|
|
- <div>
|
|
|
|
|
- <input
|
|
|
|
|
- ref="fileInput"
|
|
|
|
|
- autocomplete="off"
|
|
|
|
|
- type="file"
|
|
|
|
|
- class="form-control file-input"
|
|
|
|
|
- @change="onFileChanges"
|
|
|
|
|
- />
|
|
|
|
|
- <label for="attachment">
|
|
|
|
|
- <a
|
|
|
|
|
- role="button"
|
|
|
|
|
- class="btn btn-primary btn-sm"
|
|
|
|
|
- @click="clickButton"
|
|
|
|
|
- >
|
|
|
|
|
- <i class="fa fa-upload" />
|
|
|
|
|
- 上传附件
|
|
|
|
|
- </a>
|
|
|
|
|
- </label>
|
|
|
|
|
- <button
|
|
|
|
|
- class="btn btn-primary"
|
|
|
|
|
- @click="cleanFile(projectArchivesDto)"
|
|
|
|
|
|
|
+ </a-form-item>
|
|
|
|
|
+ <a-form-item label="文件名称">
|
|
|
|
|
+ <a-input v-model:value="projectArchivesDto.fileName" style="width: 100%" readonly />
|
|
|
|
|
+ </a-form-item>
|
|
|
|
|
+ <a-form-item label="文件大小(KB)">
|
|
|
|
|
+ <a-input v-model:value="projectArchivesDto.fileSize" style="width: 100%" readonly />
|
|
|
|
|
+ </a-form-item>
|
|
|
|
|
+ <a-space>
|
|
|
|
|
+ <a-upload
|
|
|
|
|
+ :file-list="[]"
|
|
|
|
|
+ :show-upload-list="false"
|
|
|
|
|
+ :before-upload="(file) => {
|
|
|
|
|
+ uploadFile(file);
|
|
|
|
|
+ return false;
|
|
|
|
|
+ }"
|
|
|
>
|
|
>
|
|
|
- 清空文件
|
|
|
|
|
- </button>
|
|
|
|
|
- </div>
|
|
|
|
|
- </Modal>
|
|
|
|
|
- </div>
|
|
|
|
|
- <div>
|
|
|
|
|
- <Loading v-if="loading" />
|
|
|
|
|
- </div>
|
|
|
|
|
|
|
+ <a-button type="primary">
|
|
|
|
|
+ <upload-outlined />
|
|
|
|
|
+ 上传附件
|
|
|
|
|
+ </a-button>
|
|
|
|
|
+ </a-upload>
|
|
|
|
|
+ <a-button @click="cleanFile(projectArchivesDto)">清空文件</a-button>
|
|
|
|
|
+ </a-space>
|
|
|
|
|
+ </a-form>
|
|
|
|
|
+ </a-modal>
|
|
|
|
|
+
|
|
|
|
|
+ <!-- <a-spin :spinning="loading" tip="加载中..." size="large" /> -->
|
|
|
|
|
+ <Loading v-if="loading" />
|
|
|
</div>
|
|
</div>
|
|
|
</template>
|
|
</template>
|
|
|
-<script type="text/javascript">
|
|
|
|
|
|
|
+
|
|
|
|
|
+<script>
|
|
|
import Common from '../common/Common.js';
|
|
import Common from '../common/Common.js';
|
|
|
import { Notify } from 'pc-component-v3';
|
|
import { Notify } from 'pc-component-v3';
|
|
|
import UpladFile from '../widget/UpladFile.js';
|
|
import UpladFile from '../widget/UpladFile.js';
|
|
|
import { message } from 'ant-design-vue';
|
|
import { message } from 'ant-design-vue';
|
|
|
|
|
+import { UploadOutlined } from '@ant-design/icons-vue';
|
|
|
|
|
|
|
|
export default {
|
|
export default {
|
|
|
components: {
|
|
components: {
|
|
|
UpladFile,
|
|
UpladFile,
|
|
|
|
|
+ UploadOutlined,
|
|
|
},
|
|
},
|
|
|
data: function () {
|
|
data: function () {
|
|
|
return {
|
|
return {
|
|
@@ -411,7 +249,6 @@ export default {
|
|
|
projectName: undefined,
|
|
projectName: undefined,
|
|
|
projectArchiveFolderDtos: [], //文件夹dtos
|
|
projectArchiveFolderDtos: [], //文件夹dtos
|
|
|
folderName: undefined, //文件夹名称
|
|
folderName: undefined, //文件夹名称
|
|
|
- tree: undefined,
|
|
|
|
|
planArchiveDate: '',
|
|
planArchiveDate: '',
|
|
|
projectArchiveDtos: [], //归档项Dto
|
|
projectArchiveDtos: [], //归档项Dto
|
|
|
projectArchivesDto: {
|
|
projectArchivesDto: {
|
|
@@ -469,8 +306,21 @@ export default {
|
|
|
}, 300);
|
|
}, 300);
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
- beforeUnmount: function () {},
|
|
|
|
|
methods: {
|
|
methods: {
|
|
|
|
|
+ // 树节点选择事件
|
|
|
|
|
+ onTreeSelect(selectedKeys, e) {
|
|
|
|
|
+ console.log(selectedKeys, e, 'selectedKeys, e');
|
|
|
|
|
+ if (selectedKeys.length > 0) {
|
|
|
|
|
+ this.folderId = selectedKeys[0];
|
|
|
|
|
+ this.folderName = e.node.text;
|
|
|
|
|
+ this.parentProjectArchiveFolderId = e.node.parentProjectArchiveFolderId;
|
|
|
|
|
+ } else {
|
|
|
|
|
+ this.folderId = undefined;
|
|
|
|
|
+ this.folderName = undefined;
|
|
|
|
|
+ this.parentProjectArchiveFolderId = undefined;
|
|
|
|
|
+ }
|
|
|
|
|
+ },
|
|
|
|
|
+
|
|
|
/**
|
|
/**
|
|
|
* 清空文件
|
|
* 清空文件
|
|
|
* @param {Object} item
|
|
* @param {Object} item
|
|
@@ -518,19 +368,12 @@ export default {
|
|
|
},
|
|
},
|
|
|
/**
|
|
/**
|
|
|
* 表格点击事件
|
|
* 表格点击事件
|
|
|
- * @param {Object} item
|
|
|
|
|
|
|
+ * @param {Object} record
|
|
|
*/
|
|
*/
|
|
|
- trClick: function (item) {
|
|
|
|
|
|
|
+ trClick: function (record) {
|
|
|
var _self = this;
|
|
var _self = this;
|
|
|
- _self.projectArchivesId = item.id;
|
|
|
|
|
- _self.projectArchivesDto = item;
|
|
|
|
|
- },
|
|
|
|
|
- /**
|
|
|
|
|
- * 点击上传按钮事件
|
|
|
|
|
- * @return {[type]} [description]
|
|
|
|
|
- */
|
|
|
|
|
- clickButton: function () {
|
|
|
|
|
- $(this.$refs.fileInput).click();
|
|
|
|
|
|
|
+ _self.projectArchivesId = record.id;
|
|
|
|
|
+ _self.projectArchivesDto = record;
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
@@ -612,6 +455,7 @@ export default {
|
|
|
*/
|
|
*/
|
|
|
initData: function () {
|
|
initData: function () {
|
|
|
var _self = this;
|
|
var _self = this;
|
|
|
|
|
+ _self.loading = true;
|
|
|
$.ajax({
|
|
$.ajax({
|
|
|
url: Common.getApiURL(
|
|
url: Common.getApiURL(
|
|
|
'ProjectArchiveFolderResource/queryByProjectArchiveFolderDtos',
|
|
'ProjectArchiveFolderResource/queryByProjectArchiveFolderDtos',
|
|
@@ -629,21 +473,10 @@ export default {
|
|
|
_self.projectArchiveFolderDtos = data;
|
|
_self.projectArchiveFolderDtos = data;
|
|
|
_self.folderId = undefined;
|
|
_self.folderId = undefined;
|
|
|
_self.folderName = undefined;
|
|
_self.folderName = undefined;
|
|
|
- $('#tree').treeview({
|
|
|
|
|
- data: _self.projectArchiveFolderDtos,
|
|
|
|
|
- onNodeSelected: function (event, data) {
|
|
|
|
|
- _self.folderId = data.id;
|
|
|
|
|
- _self.folderName = data.name;
|
|
|
|
|
- _self.parentProjectArchiveFolderId =
|
|
|
|
|
- data.parentProjectArchiveFolderId;
|
|
|
|
|
- },
|
|
|
|
|
- onNodeUnselected: function (event, data) {
|
|
|
|
|
- _self.folderId = undefined;
|
|
|
|
|
- _self.parentProjectArchiveFolderId = undefined;
|
|
|
|
|
- },
|
|
|
|
|
- });
|
|
|
|
|
|
|
+ _self.loading = false;
|
|
|
},
|
|
},
|
|
|
error: function (XMLHttpRequest, textStatus, errorThrown) {
|
|
error: function (XMLHttpRequest, textStatus, errorThrown) {
|
|
|
|
|
+ _self.loading = false;
|
|
|
Common.processException(XMLHttpRequest, textStatus, errorThrown);
|
|
Common.processException(XMLHttpRequest, textStatus, errorThrown);
|
|
|
},
|
|
},
|
|
|
});
|
|
});
|
|
@@ -714,6 +547,7 @@ export default {
|
|
|
//查询当前文件夹下面所有的归档项
|
|
//查询当前文件夹下面所有的归档项
|
|
|
queryByProjectArchiveDtos: function () {
|
|
queryByProjectArchiveDtos: function () {
|
|
|
var _self = this;
|
|
var _self = this;
|
|
|
|
|
+ _self.loading = true;
|
|
|
$.ajax({
|
|
$.ajax({
|
|
|
url: Common.getApiURL(
|
|
url: Common.getApiURL(
|
|
|
'ProjectArchivesResource/queryByProjectArchiveDtos',
|
|
'ProjectArchivesResource/queryByProjectArchiveDtos',
|
|
@@ -729,8 +563,10 @@ export default {
|
|
|
},
|
|
},
|
|
|
success: function (data) {
|
|
success: function (data) {
|
|
|
_self.projectArchiveDtos = data;
|
|
_self.projectArchiveDtos = data;
|
|
|
|
|
+ _self.loading = false;
|
|
|
},
|
|
},
|
|
|
error: function (XMLHttpRequest, textStatus, errorThrown) {
|
|
error: function (XMLHttpRequest, textStatus, errorThrown) {
|
|
|
|
|
+ _self.loading = false;
|
|
|
Common.processException(XMLHttpRequest, textStatus, errorThrown);
|
|
Common.processException(XMLHttpRequest, textStatus, errorThrown);
|
|
|
},
|
|
},
|
|
|
});
|
|
});
|
|
@@ -804,31 +640,18 @@ export default {
|
|
|
_self.projectArchivesDto.fileName = fileName;
|
|
_self.projectArchivesDto.fileName = fileName;
|
|
|
_self.projectArchivesDto.fileSize =
|
|
_self.projectArchivesDto.fileSize =
|
|
|
Math.round((selectedFile.size / 1024) * 100) / 100;
|
|
Math.round((selectedFile.size / 1024) * 100) / 100;
|
|
|
- // _self.$set(_self.projectArchivesDto, 'fileName', fileName);
|
|
|
|
|
- // _self.$set(
|
|
|
|
|
- // _self.projectArchivesDto,
|
|
|
|
|
- // 'fileSize',
|
|
|
|
|
- // Math.round((selectedFile.size / 1024) * 100) / 100,
|
|
|
|
|
- // );
|
|
|
|
|
if (
|
|
if (
|
|
|
_self.projectArchivesDto.name == null ||
|
|
_self.projectArchivesDto.name == null ||
|
|
|
_self.projectArchivesDto.name == ''
|
|
_self.projectArchivesDto.name == ''
|
|
|
) {
|
|
) {
|
|
|
_self.projectArchivesDto.name = fileName;
|
|
_self.projectArchivesDto.name = fileName;
|
|
|
- // _self.$set(_self.projectArchivesDto, 'name', fileName);
|
|
|
|
|
}
|
|
}
|
|
|
if (
|
|
if (
|
|
|
_self.projectArchivesDto.planArchiveDate == null ||
|
|
_self.projectArchivesDto.planArchiveDate == null ||
|
|
|
_self.projectArchivesDto.planArchiveDate == ''
|
|
_self.projectArchivesDto.planArchiveDate == ''
|
|
|
) {
|
|
) {
|
|
|
- // _self.projectArchivesDto.planArchiveDate = dayjs().format('YYYY-MM-DD HH:mm:ss');
|
|
|
|
|
_self.projectArchivesDto.planArchiveDate =
|
|
_self.projectArchivesDto.planArchiveDate =
|
|
|
_self.planArchiveDate + ' 00:00:00';
|
|
_self.planArchiveDate + ' 00:00:00';
|
|
|
- // _self.$set(
|
|
|
|
|
- // _self.projectArchivesDto,
|
|
|
|
|
- // 'planArchiveDate',
|
|
|
|
|
- // dayjs().format('YYYY-MM-DD HH:mm:ss'),
|
|
|
|
|
- // );
|
|
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
_self.saveProjectArchives();
|
|
_self.saveProjectArchives();
|
|
@@ -1008,6 +831,7 @@ export default {
|
|
|
*/
|
|
*/
|
|
|
queryByProjectArchiveDtoAudit: function () {
|
|
queryByProjectArchiveDtoAudit: function () {
|
|
|
var _self = this;
|
|
var _self = this;
|
|
|
|
|
+ _self.loading = true;
|
|
|
$.ajax({
|
|
$.ajax({
|
|
|
url: Common.getApiURL(
|
|
url: Common.getApiURL(
|
|
|
'ProjectArchivesResource/queryByProjectArchiveDtoAudit',
|
|
'ProjectArchivesResource/queryByProjectArchiveDtoAudit',
|
|
@@ -1023,8 +847,10 @@ export default {
|
|
|
},
|
|
},
|
|
|
success: function (data) {
|
|
success: function (data) {
|
|
|
_self.projectArchiveAuditDtos = data;
|
|
_self.projectArchiveAuditDtos = data;
|
|
|
|
|
+ _self.loading = false;
|
|
|
},
|
|
},
|
|
|
error: function (XMLHttpRequest, textStatus, errorThrown) {
|
|
error: function (XMLHttpRequest, textStatus, errorThrown) {
|
|
|
|
|
+ _self.loading = false;
|
|
|
Common.processException(XMLHttpRequest, textStatus, errorThrown);
|
|
Common.processException(XMLHttpRequest, textStatus, errorThrown);
|
|
|
},
|
|
},
|
|
|
});
|
|
});
|
|
@@ -1108,85 +934,12 @@ export default {
|
|
|
</script>
|
|
</script>
|
|
|
|
|
|
|
|
<style scoped>
|
|
<style scoped>
|
|
|
-.flex-container {
|
|
|
|
|
- display: flex;
|
|
|
|
|
- /* 垂直*/
|
|
|
|
|
- flex-direction: column;
|
|
|
|
|
- width: 100%;
|
|
|
|
|
- /*视口被均分为100单位的vh 占据整个窗口,扣掉顶部topNav的距离后,计算得到container的高度*/
|
|
|
|
|
- height: calc(100vh - 80px);
|
|
|
|
|
-}
|
|
|
|
|
-
|
|
|
|
|
-.flex-content {
|
|
|
|
|
- display: flex;
|
|
|
|
|
- flex: 1;
|
|
|
|
|
- height: calc(100vh - 80px);
|
|
|
|
|
-}
|
|
|
|
|
-
|
|
|
|
|
-.flex-aside-left {
|
|
|
|
|
- flex: 0 0 300px;
|
|
|
|
|
- /* margin-right: 10px; */
|
|
|
|
|
- border: 1px solid #e4e4e4;
|
|
|
|
|
- background-color: white;
|
|
|
|
|
- padding: 10px;
|
|
|
|
|
- height: calc(100vh - 80px);
|
|
|
|
|
- overflow-y: auto;
|
|
|
|
|
-}
|
|
|
|
|
-
|
|
|
|
|
-.flex-aside-right {
|
|
|
|
|
- flex: 0 0 300px;
|
|
|
|
|
- /* margin-left: 10px; */
|
|
|
|
|
- border: 1px solid #e4e4e4;
|
|
|
|
|
- background-color: white;
|
|
|
|
|
- padding: 10px;
|
|
|
|
|
- height: calc(100vh - 80px);
|
|
|
|
|
- overflow-y: auto;
|
|
|
|
|
-}
|
|
|
|
|
-
|
|
|
|
|
-.flex-main {
|
|
|
|
|
- overflow: auto;
|
|
|
|
|
- flex: 1;
|
|
|
|
|
- border-top: 1px solid #e4e4e4;
|
|
|
|
|
- border-bottom: 1px solid #e4e4e4;
|
|
|
|
|
- overflow-y: auto;
|
|
|
|
|
-}
|
|
|
|
|
-
|
|
|
|
|
-.flex-main-serch {
|
|
|
|
|
- padding: 10px;
|
|
|
|
|
- background-color: white;
|
|
|
|
|
- border-bottom: 1px solid #e4e4e4;
|
|
|
|
|
-}
|
|
|
|
|
-
|
|
|
|
|
-tr:hover {
|
|
|
|
|
- background-color: #eee;
|
|
|
|
|
-}
|
|
|
|
|
-
|
|
|
|
|
-.file-input {
|
|
|
|
|
- width: 0.1px;
|
|
|
|
|
- height: 0.1px;
|
|
|
|
|
- opacity: 0;
|
|
|
|
|
- overflow: hidden;
|
|
|
|
|
- position: absolute;
|
|
|
|
|
- z-index: -1;
|
|
|
|
|
-}
|
|
|
|
|
-
|
|
|
|
|
-.m-row {
|
|
|
|
|
- margin-top: 10px;
|
|
|
|
|
-}
|
|
|
|
|
-
|
|
|
|
|
-.flex-box {
|
|
|
|
|
- display: flex;
|
|
|
|
|
- flex-direction: row;
|
|
|
|
|
- flex-wrap: nowrap;
|
|
|
|
|
- justify-content: center;
|
|
|
|
|
- margin: 5px 0;
|
|
|
|
|
-}
|
|
|
|
|
-
|
|
|
|
|
-.flex-item {
|
|
|
|
|
- flex: 1 1 auto;
|
|
|
|
|
|
|
+/* 覆盖Ant Design表格选中行样式 */
|
|
|
|
|
+:deep(.ant-table-row-selected > td) {
|
|
|
|
|
+ background-color: #e6f7ff !important;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
-.flex-item-1 {
|
|
|
|
|
- flex: 0 0 auto;
|
|
|
|
|
|
|
+:deep(.ant-table-row:hover > td) {
|
|
|
|
|
+ background-color: #f5f5f5;
|
|
|
}
|
|
}
|
|
|
</style>
|
|
</style>
|