Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
B
bigDataSystem
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张伯涛
bigDataSystem
Commits
993ecec9
Commit
993ecec9
authored
Dec 02, 2024
by
罗林杰
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改文件
parent
0647a49e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
96 additions
and
19 deletions
+96
-19
data.ts
src/views/mallResourceDevelopment/file/fileByCreate/data.ts
+62
-14
editFileModal.vue
...llResourceDevelopment/file/fileByCreate/editFileModal.vue
+34
-5
No files found.
src/views/mallResourceDevelopment/file/fileByCreate/data.ts
View file @
993ecec9
...
...
@@ -164,20 +164,15 @@ export const addFileFormSchema: any = [
export
const
editFileFormSchema
:
any
=
[
{
field
:
'name'
,
label
:
'
资源
名称'
,
label
:
'
文件
名称'
,
component
:
'Input'
,
colProps
:
{
lg
:
12
,
md
:
12
},
required
:
true
,
colProps
:
{
lg
:
10
,
md
:
10
},
},
{
field
:
'path'
,
label
:
'文件路径'
,
component
:
'TreeSelect'
,
rules
:
[
{
required
:
true
,
message
:
'请选择上级菜单'
,
},
],
componentProps
:
{
fieldNames
:
{
label
:
'workSpaceName'
,
...
...
@@ -185,13 +180,13 @@ export const editFileFormSchema: any = [
},
getPopupContainer
:
()
=>
document
.
body
,
},
colProps
:
{
lg
:
1
2
,
md
:
12
},
colProps
:
{
lg
:
1
0
,
md
:
10
},
},
{
field
:
'remark'
,
label
:
'描述'
,
component
:
'Input'
,
colProps
:
{
lg
:
1
2
,
md
:
12
},
colProps
:
{
lg
:
1
0
,
md
:
10
},
},
{
field
:
'workGroup'
,
...
...
@@ -233,7 +228,7 @@ export const editFileFormSchema: any = [
value
:
'businessId'
,
},
},
colProps
:
{
lg
:
1
2
,
md
:
12
},
colProps
:
{
lg
:
1
0
,
md
:
10
},
},
{
field
:
'tag'
,
...
...
@@ -248,7 +243,7 @@ export const editFileFormSchema: any = [
{
label
:
'财务'
,
value
:
'财务'
},
],
},
colProps
:
{
lg
:
1
2
,
md
:
12
},
colProps
:
{
lg
:
1
0
,
md
:
10
},
},
{
field
:
'sensitive'
,
...
...
@@ -261,7 +256,7 @@ export const editFileFormSchema: any = [
{
label
:
'不敏感'
,
value
:
'不敏感'
},
],
},
colProps
:
{
lg
:
1
2
,
md
:
12
},
colProps
:
{
lg
:
1
0
,
md
:
10
},
},
{
field
:
'security'
,
...
...
@@ -276,6 +271,59 @@ export const editFileFormSchema: any = [
{
label
:
'D级'
,
value
:
'D级'
},
],
},
colProps
:
{
lg
:
12
,
md
:
12
},
colProps
:
{
lg
:
10
,
md
:
10
},
},
];
export
const
editFilePermissionsFormSchema
:
any
=
[
{
field
:
'download'
,
label
:
'下载权限'
,
component
:
'Switch'
,
required
:
true
,
colProps
:
{
lg
:
24
,
md
:
24
},
},
{
field
:
'encrypt'
,
label
:
'文件加密'
,
component
:
'Switch'
,
required
:
true
,
colProps
:
{
lg
:
24
,
md
:
24
},
},
];
export
const
editFileOptionsFormSchema
:
any
=
[
{
field
:
'autoOffShelfDate'
,
label
:
'自动下架日期'
,
component
:
'Input'
,
required
:
true
,
colProps
:
{
lg
:
24
,
md
:
24
},
},
{
field
:
'shareType'
,
label
:
'共享方式'
,
component
:
'Select'
,
componentProps
:
{
placeholder
:
'请选择共享方式'
,
options
:
[
{
label
:
'公开'
,
value
:
'公开'
},
{
label
:
'私有'
,
value
:
'私有'
},
],
},
required
:
true
,
colProps
:
{
lg
:
24
,
md
:
24
},
},
{
field
:
'visibleRange'
,
label
:
'可见范围'
,
component
:
'Select'
,
componentProps
:
{
placeholder
:
'请选择可见范围'
,
options
:
[
{
label
:
'公开'
,
value
:
'公开'
},
{
label
:
'私有'
,
value
:
'私有'
},
],
},
required
:
true
,
colProps
:
{
lg
:
24
,
md
:
24
},
},
];
src/views/mallResourceDevelopment/file/fileByCreate/editFileModal.vue
View file @
993ecec9
...
...
@@ -7,14 +7,28 @@
@
ok=
"handleSubmit"
>
<Description
size=
"middle"
title=
"基本信息"
:bordered=
"false"
/>
<BasicForm
@
register=
"registerForm"
/>
<div>
<BasicForm
@
register=
"registerForm"
/>
</div>
<Description
size=
"middle"
title=
"开放权限"
:bordered=
"false"
/>
<div>
<BasicForm
@
register=
"registerPermissionsForm"
/>
</div>
<Description
size=
"middle"
title=
"默认上架配置"
:bordered=
"false"
/>
<div>
<BasicForm
@
register=
"registerOptionsForm"
/>
</div>
</BasicModal>
</
template
>
<
script
lang=
"ts"
setup
>
import
{
ref
,
unref
}
from
'vue'
;
import
{
BasicModal
,
useModalInner
}
from
'@/components/Modal'
;
import
{
BasicForm
,
useForm
}
from
'@/components/Form'
;
import
{
editFileFormSchema
}
from
'./data'
;
import
{
editFileFormSchema
,
editFileOptionsFormSchema
,
editFilePermissionsFormSchema
,
}
from
'./data'
;
import
{
TreeData
}
from
'./dataFileData'
;
import
{
useMessage
}
from
'@/hooks/web/useMessage'
;
import
{
Description
}
from
'@/components/Description'
;
...
...
@@ -28,12 +42,27 @@
//获取接口数据并放在下拉框里(这里是打开了一个弹框)
//初始化表单
const
[
registerForm
,
{
setFieldsValue
,
updateSchema
,
resetFields
,
validate
}]
=
useForm
({
labelWidth
:
100
,
baseColProps
:
{
lg
:
24
,
md
:
24
},
labelWidth
:
120
,
schemas
:
editFileFormSchema
,
showActionButtonGroup
:
false
,
actionColOptions
:
{
span
:
23
,
span
:
24
,
},
});
const
[
registerPermissionsForm
]
=
useForm
({
labelWidth
:
120
,
schemas
:
editFilePermissionsFormSchema
,
showActionButtonGroup
:
false
,
actionColOptions
:
{
span
:
24
,
},
});
const
[
registerOptionsForm
]
=
useForm
({
labelWidth
:
120
,
schemas
:
editFileOptionsFormSchema
,
showActionButtonGroup
:
false
,
actionColOptions
:
{
span
:
24
,
},
});
//初始化弹框
...
...
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