|
|
|
|
@ -71,27 +71,10 @@
|
|
|
|
|
|
|
|
|
|
</el-row>
|
|
|
|
|
|
|
|
|
|
<el-dialog title="档案文件上传" :visible.sync="upload.open" width="700px" append-to-body>
|
|
|
|
|
<el-dialog title="档案本地上传" :visible.sync="upload.open" width="400px" append-to-body>
|
|
|
|
|
|
|
|
|
|
<div v-loading="upload.loading">
|
|
|
|
|
<div style="margin-bottom: 30px;display: flex;min-height: 300px;">
|
|
|
|
|
<div style="width:250px;border: 1px solid #eee; padding: 10px;max-height: 400px;overflow-y: auto">
|
|
|
|
|
<div style="margin-bottom: 5px;">档案室密集柜:</div>
|
|
|
|
|
<el-tree
|
|
|
|
|
:data="shuJiaOptions"
|
|
|
|
|
:props="{
|
|
|
|
|
children: 'children',
|
|
|
|
|
label: 'label'
|
|
|
|
|
}"
|
|
|
|
|
:expand-on-click-node="false"
|
|
|
|
|
ref="myTreeSelect"
|
|
|
|
|
node-key="id"
|
|
|
|
|
highlight-current
|
|
|
|
|
@node-click="selectTree"
|
|
|
|
|
/>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div v-show="upload.id" style="width: 360px;margin-left: 20px;">
|
|
|
|
|
<div style="margin-bottom: 20px;min-height: 400px;">
|
|
|
|
|
<el-upload :show-file-list="false"
|
|
|
|
|
ref="upload"
|
|
|
|
|
action="#"
|
|
|
|
|
@ -106,7 +89,7 @@
|
|
|
|
|
<div class="el-upload__tip" slot="tip">只能上传图片,且不超过{{ upload.fileSize }}MB</div>
|
|
|
|
|
</el-upload>
|
|
|
|
|
|
|
|
|
|
<ul class="el-upload-list el-upload-list--text" style="max-height:200px;overflow-y:scroll;padding: 15px;">
|
|
|
|
|
<ul class="el-upload-list el-upload-list--text" style="max-height:200px;overflow-y:auto;padding: 15px;">
|
|
|
|
|
<li tabindex="0" class="el-upload-list__item is-success" v-for="(item,index) in fileList" :key="item.uid">
|
|
|
|
|
<a class="el-upload-list__item-name">
|
|
|
|
|
<i class="el-icon-document"></i>
|
|
|
|
|
@ -118,9 +101,6 @@
|
|
|
|
|
<i class="el-icon-close" @click="deleteFile(index)"></i>
|
|
|
|
|
</li>
|
|
|
|
|
</ul>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div style="text-align: center">
|
|
|
|
|
@ -130,27 +110,12 @@
|
|
|
|
|
|
|
|
|
|
</el-dialog>
|
|
|
|
|
|
|
|
|
|
<el-dialog title="扫描文件上传" :visible.sync="smwj.open" width="1000px" append-to-body>
|
|
|
|
|
<el-dialog title="扫描文件上传" :visible.sync="smwj.open" width="750px" append-to-body>
|
|
|
|
|
|
|
|
|
|
<div v-loading="smwj.loading">
|
|
|
|
|
<div style="margin-bottom: 30px;display: flex;align-items:start;min-height: 300px;">
|
|
|
|
|
<div style="width:250px;border: 1px solid #eee; padding: 10px;max-height: 400px;overflow-y: auto">
|
|
|
|
|
<div style="margin-bottom: 5px;">档案室密集柜:</div>
|
|
|
|
|
<el-tree
|
|
|
|
|
:data="shuJiaOptions"
|
|
|
|
|
:props="{
|
|
|
|
|
children: 'children',
|
|
|
|
|
label: 'label'
|
|
|
|
|
}"
|
|
|
|
|
:expand-on-click-node="false"
|
|
|
|
|
ref="myTreeSelect"
|
|
|
|
|
node-key="id"
|
|
|
|
|
highlight-current
|
|
|
|
|
@node-click="selectTree1"
|
|
|
|
|
/>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div v-if="smwj.id && smwj.list.length===0" style="width: 650px;margin-left: 20px;" v-loading="smwj.smloading" element-loading-text="文件扫描中"
|
|
|
|
|
<div style="width: 700px;margin-left: 20px;" v-loading="smwj.smloading" element-loading-text="文件扫描中"
|
|
|
|
|
element-loading-spinner="el-icon-loading">
|
|
|
|
|
<div>
|
|
|
|
|
<el-row class="sm_row" :gutter="20">
|
|
|
|
|
@ -185,7 +150,7 @@
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div v-if="smwj.id && smwj.list.length>0" style="width: 560px;margin-left: 20px;display: flex;flex-wrap: wrap">
|
|
|
|
|
<div v-if="smwj.list.length>0" style="width: 560px;margin-left: 20px;display: flex;flex-wrap: wrap">
|
|
|
|
|
|
|
|
|
|
<div v-for="(item,index) in smwj.list" class="smwjList">
|
|
|
|
|
<el-image
|
|
|
|
|
@ -376,11 +341,8 @@ export default {
|
|
|
|
|
loading: false,
|
|
|
|
|
// 是否显示弹出层(用户导入)
|
|
|
|
|
open: false,
|
|
|
|
|
id: undefined,
|
|
|
|
|
wlsjNode: undefined
|
|
|
|
|
id: undefined
|
|
|
|
|
},
|
|
|
|
|
// 书架树选项
|
|
|
|
|
shuJiaOptions: [],
|
|
|
|
|
// 上传图片记录
|
|
|
|
|
pictureRecard: [],
|
|
|
|
|
// 已识别图片
|
|
|
|
|
@ -397,7 +359,6 @@ export default {
|
|
|
|
|
// 是否显示弹出层(用户导入)
|
|
|
|
|
open: false,
|
|
|
|
|
id: undefined,
|
|
|
|
|
wlsjNode: undefined,
|
|
|
|
|
list: []
|
|
|
|
|
},
|
|
|
|
|
};
|
|
|
|
|
@ -566,7 +527,6 @@ export default {
|
|
|
|
|
handleUpload() {
|
|
|
|
|
if(this.dangAnNode){
|
|
|
|
|
this.$modal.confirm(`是否确认选择【${this.dangAnNode.label}】档案目录?`).then(() => {
|
|
|
|
|
this.getTreeselect();
|
|
|
|
|
this.fileList = []
|
|
|
|
|
this.upload.id=undefined;
|
|
|
|
|
this.upload.wlsjNode=undefined;
|
|
|
|
|
@ -584,10 +544,7 @@ export default {
|
|
|
|
|
handleScan(){
|
|
|
|
|
if(this.dangAnNode){
|
|
|
|
|
this.$modal.confirm(`是否确认选择【${this.dangAnNode.label}】档案目录?`).then(() => {
|
|
|
|
|
this.getTreeselect();
|
|
|
|
|
this.smwj.list = [];
|
|
|
|
|
this.smwj.id=undefined;
|
|
|
|
|
this.smwj.wlsjNode=undefined;
|
|
|
|
|
this.smwj.open = true;
|
|
|
|
|
}).catch(() => {
|
|
|
|
|
this.smwj.open = false;
|
|
|
|
|
@ -598,12 +555,6 @@ export default {
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
/** 查询目录下拉树结构 */
|
|
|
|
|
getTreeselect() {
|
|
|
|
|
getCabinetTree().then(response => {
|
|
|
|
|
this.shuJiaOptions = response.data
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
// 上传文件之前的钩子
|
|
|
|
|
beforeUpload(file) {
|
|
|
|
|
this.$refs.upload.clearFiles();
|
|
|
|
|
@ -617,9 +568,7 @@ export default {
|
|
|
|
|
submitFiles(type) {
|
|
|
|
|
|
|
|
|
|
this.checkAll = false;
|
|
|
|
|
|
|
|
|
|
if (type === 1) {
|
|
|
|
|
|
|
|
|
|
if (this.smwj.list.length === 0) {
|
|
|
|
|
this.$alert(`请先开始扫描!`, `提示`, {
|
|
|
|
|
type: 'warning'
|
|
|
|
|
@ -641,8 +590,6 @@ export default {
|
|
|
|
|
DaPicturesRecard.muId = this.dangAnNode.key;
|
|
|
|
|
DaPicturesRecard.muPath = this.getAllLabels(this.dangAnNode);
|
|
|
|
|
DaPicturesRecard.ywType = this.dangAnNode.data.ywType;
|
|
|
|
|
DaPicturesRecard.wlsjId = this.smwj.wlsjNode.key;
|
|
|
|
|
DaPicturesRecard.wlsjPath = this.getAllLabels(this.smwj.wlsjNode);
|
|
|
|
|
formData.append('picRecard', new Blob([JSON.stringify(DaPicturesRecard)], {type: 'application/json',}));
|
|
|
|
|
this.smwj.loading = true;
|
|
|
|
|
collectSaves(formData).then(response => {
|
|
|
|
|
@ -681,8 +628,6 @@ export default {
|
|
|
|
|
DaPicturesRecard.muId = this.dangAnNode.key;
|
|
|
|
|
DaPicturesRecard.muPath = this.getAllLabels(this.dangAnNode);
|
|
|
|
|
DaPicturesRecard.ywType = this.dangAnNode.data.ywType;
|
|
|
|
|
DaPicturesRecard.wlsjId = this.upload.wlsjNode.key;
|
|
|
|
|
DaPicturesRecard.wlsjPath = this.getAllLabels(this.upload.wlsjNode);
|
|
|
|
|
formData.append('picRecard', new Blob([JSON.stringify(DaPicturesRecard)], {type: 'application/json',}));
|
|
|
|
|
this.upload.loading = true;
|
|
|
|
|
|
|
|
|
|
@ -701,16 +646,6 @@ export default {
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
// 档案室密集柜树选择 点击上传
|
|
|
|
|
selectTree(data, Node) {
|
|
|
|
|
this.upload.id = data.id;
|
|
|
|
|
this.upload.wlsjNode = Node;
|
|
|
|
|
},
|
|
|
|
|
// 档案室密集柜树选择 扫描上传
|
|
|
|
|
selectTree1(data, Node) {
|
|
|
|
|
this.smwj.id = data.id;
|
|
|
|
|
this.smwj.wlsjNode = Node;
|
|
|
|
|
},
|
|
|
|
|
// 获取所有label
|
|
|
|
|
getAllLabels(obj) {
|
|
|
|
|
let values = '';
|
|
|
|
|
|