Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
smart-office-platform
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
赵啸非
smart-office-platform
Commits
9c48b908
Commit
9c48b908
authored
Sep 08, 2023
by
赵啸非
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
更新附件添加多个设置
parent
f7aff401
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
44 additions
and
20 deletions
+44
-20
smart-office-manager-ui/admin/src/components/FileUpload.vue
smart-office-manager-ui/admin/src/components/FileUpload.vue
+43
-17
smart-office-manager-ui/admin/src/router.js
smart-office-manager-ui/admin/src/router.js
+1
-1
smart-office-manager-ui/admin/src/views/room/drawershow.vue
smart-office-manager-ui/admin/src/views/room/drawershow.vue
+0
-2
No files found.
smart-office-manager-ui/admin/src/components/FileUpload.vue
View file @
9c48b908
...
@@ -113,6 +113,42 @@ export default {
...
@@ -113,6 +113,42 @@ export default {
value
:
{
value
:
{
handler
(
val
)
{
handler
(
val
)
{
if
(
val
)
{
if
(
val
)
{
this
.
showFileList
();
// let temp = 1;
// // 首先将值转为数组
// const filePathlist = this.value.split(',');
// // 然后将数组转为对象数组
// const fileNamelist =this.fileName.split(',');
// for (var i = 0; i
<
filePathlist
.
length
;
i
++
)
{
// let item = {}
// console.log(fileNamelist.length===filePathlist.length)
// if(fileNamelist.length===filePathlist.length){
// item.name = fileNamelist[i];
// }else{
// item.name = filePathlist[i];
// }
// item.url = filePathlist[i];
// item.uid = new Date().getTime() + temp++;
// this.fileList.push(item)
// }
}
else
{
this
.
fileList
=
[];
return
[];
}
}
}
},
computed
:
{
// 是否显示提示
showTip
()
{
return
this
.
isShowTip
&&
(
this
.
fileType
||
this
.
fileSize
);
},
},
methods
:
{
showFileList
(){
let
temp
=
1
;
let
temp
=
1
;
// 首先将值转为数组
// 首先将值转为数组
const
filePathlist
=
this
.
value
.
split
(
'
,
'
);
const
filePathlist
=
this
.
value
.
split
(
'
,
'
);
...
@@ -120,31 +156,19 @@ export default {
...
@@ -120,31 +156,19 @@ export default {
const
fileNamelist
=
this
.
fileName
.
split
(
'
,
'
);
const
fileNamelist
=
this
.
fileName
.
split
(
'
,
'
);
for
(
var
i
=
0
;
i
<
filePathlist
.
length
;
i
++
)
{
for
(
var
i
=
0
;
i
<
filePathlist
.
length
;
i
++
)
{
let
item
=
{}
let
item
=
{}
console
.
log
(
fileNamelist
.
length
===
filePathlist
.
length
)
console
.
log
(
fileNamelist
.
length
===
filePathlist
.
length
)
if
(
fileNamelist
.
length
===
filePathlist
.
length
)
{
if
(
fileNamelist
.
length
===
filePathlist
.
length
)
{
item
.
name
=
fileNamelist
[
i
];
item
.
name
=
fileNamelist
[
i
];
}
else
{
}
else
{
item
.
name
=
filePathlist
[
i
];
item
.
name
=
filePathlist
[
i
];
}
}
item
.
url
=
filePathlist
[
i
];
item
.
url
=
filePathlist
[
i
];
item
.
uid
=
new
Date
().
getTime
()
+
temp
++
;
item
.
uid
=
new
Date
().
getTime
()
+
temp
++
;
this
.
fileList
.
push
(
item
)
this
.
fileList
.
push
(
item
)
}
}
}
else
{
this
.
fileList
=
[];
return
[];
}
}
}
},
},
computed
:
{
// 是否显示提示
showTip
()
{
return
this
.
isShowTip
&&
(
this
.
fileType
||
this
.
fileSize
);
},
},
methods
:
{
// 上传前校检格式和大小
// 上传前校检格式和大小
handleBeforeUpload
(
file
)
{
handleBeforeUpload
(
file
)
{
// 校检文件类型
// 校检文件类型
...
@@ -218,6 +242,8 @@ export default {
...
@@ -218,6 +242,8 @@ export default {
}
}
},
},
created
()
{
created
()
{
console
.
log
(
"
file create
"
)
this
.
showFileList
();
// this.fileList = this.list;
// this.fileList = this.list;
},
},
};
};
...
...
smart-office-manager-ui/admin/src/router.js
View file @
9c48b908
...
@@ -102,7 +102,7 @@ function getComponent(fileName) {
...
@@ -102,7 +102,7 @@ function getComponent(fileName) {
try
{
try
{
return
require
(
'
./views/
'
+
fileName
).
default
return
require
(
'
./views/
'
+
fileName
).
default
}
catch
(
error
)
{
}
catch
(
error
)
{
console
.
log
(
"
error:
"
,
error
)
//
console.log("error:",error)
return
fileNotFound
;
return
fileNotFound
;
}
}
}
}
...
...
smart-office-manager-ui/admin/src/views/room/drawershow.vue
View file @
9c48b908
...
@@ -125,8 +125,6 @@
...
@@ -125,8 +125,6 @@
},
},
/**获取数据后弹框 */
/**获取数据后弹框 */
afterRender
(
data
)
{
afterRender
(
data
)
{
console
.
log
(
data
)
console
.
log
(
this
.
form
)
this
.
open
=
true
;
this
.
open
=
true
;
},
},
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment