Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
J
jinfa-platform
Project
Project
Details
Activity
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
shenshaokai
jinfa-platform
Commits
0269a9e1
Commit
0269a9e1
authored
Jun 07, 2021
by
XieZhiXiong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
chore: 重命名
parent
e362615e
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
145 deletions
+4
-145
index.less
.../member/components/QualificationUploadFormItem/index.less
+0
-18
index.tsx
...s/member/components/QualificationUploadFormItem/index.tsx
+0
-123
index.tsx
...pages/member/components/QualitiesUploadFormItem/index.tsx
+4
-4
No files found.
src/pages/member/components/QualificationUploadFormItem/index.less
deleted
100644 → 0
View file @
e362615e
@import '~antd/es/style/themes/default.less';
.add-btn {
width: 175px;
height: 120px;
text-align: center;
vertical-align: top;
background-color: @descriptions-bg;
border: 1px dashed @border-color-base;
border-radius: @border-radius-base;
cursor: pointer;
transition: border-color 0.3s;
&:hover {
background-color: @descriptions-bg;
}
}
\ No newline at end of file
src/pages/member/components/QualificationUploadFormItem/index.tsx
deleted
100644 → 0
View file @
e362615e
/*
* @Author: XieZhiXiong
* @Date: 2021-06-01 16:13:35
* @LastEditors: XieZhiXiong
* @LastEditTime: 2021-06-07 14:56:46
* @Description: 资质证明上传组件
*/
import
React
from
'react'
;
import
{
Row
,
Col
,
Button
}
from
'antd'
;
import
{
PlusOutlined
}
from
'@ant-design/icons'
;
import
{
ArrayList
}
from
'@formily/react-shared-components'
;
import
{
Schema
,
SchemaField
}
from
'@formily/antd'
;
import
{
toArr
,
FormPath
}
from
'@formily/shared'
;
import
{
UPLOAD_TYPE
,
}
from
'@/constants'
;
import
styles
from
'./index.less'
;
const
schema
=
new
Schema
({
type
:
'object'
,
properties
:
{
MEGA_LAYOUT1
:
{
type
:
'object'
,
'x-component'
:
'Mega-Layout'
,
'x-component-props'
:
{
grid
:
true
,
full
:
true
,
columns
:
2
,
},
properties
:
{
file
:
{
type
:
'string'
,
'x-component'
:
'QualitiesUpload'
,
'x-component-props'
:
{
action
:
'/api/file/file/upload/prefix'
,
data
:
{
fileType
:
UPLOAD_TYPE
,
prefix
:
'member_qualifications_'
,
},
accept
:
'.doc, .docx, .xls, .xlsx, .pot, .pps, .vsd, .wps, .dps, .pdf, .txt, .png, .jpg, .rar, .zip'
,
},
},
MEGA_LAYOUT2
:
{
type
:
'object'
,
'x-component'
:
'Mega-Layout'
,
properties
:
{
expireDay
:
{
type
:
'string'
,
title
:
'到期日'
,
'x-component'
:
'DatePicker'
,
},
permanent
:
{
type
:
'string'
,
title
:
'有效期'
,
'x-component'
:
'CheckboxGroup'
,
enum
:
[
{
label
:
'长期有效'
,
value
:
1
},
]
},
},
},
},
}
},
});
const
Qualifications
=
(
props
)
=>
{
const
{
value
,
className
,
editable
,
path
,
mutators
,
// schema,
}
=
props
;
const
{
colSpan
}
=
(
props
.
props
[
'x-component-props'
]
||
{});
const
onAdd
=
()
=>
mutators
.
push
(
schema
.
getEmptyValue
())
const
span
=
colSpan
?
{
span
:
colSpan
,
}
:
{
sm
:
12
,
md
:
8
,
lg
:
8
,
};
return
(
<
ArrayList
value=
{
value
}
>
<
Row
gutter=
{
{
sm
:
44
,
md
:
88
,
lg
:
88
}
}
style=
{
{
width
:
'100%'
,
}
}
>
{
toArr
(
value
).
map
((
item
,
index
)
=>
(
<
Col
key=
{
index
}
{
...
span
}
>
<
SchemaField
path=
{
FormPath
.
parse
(
path
).
concat
(
index
)
}
schema=
{
schema
}
/>
</
Col
>
))
}
{
editable
&&
(
<
Col
{
...
span
}
>
<
Button
onClick=
{
onAdd
}
type=
"dashed"
className=
{
styles
[
'add-btn'
]
}
>
<
PlusOutlined
/>
</
Button
>
</
Col
>
)
}
</
Row
>
</
ArrayList
>
);
};
Qualifications
.
isFieldComponent
=
true
;
export
default
Qualifications
;
src/pages/member/components/QualitiesUploadFormItem/index.tsx
View file @
0269a9e1
...
...
@@ -2,7 +2,7 @@
* @Author: XieZhiXiong
* @Date: 2021-06-01 16:13:35
* @LastEditors: XieZhiXiong
* @LastEditTime: 2021-06-07 1
4:56:46
* @LastEditTime: 2021-06-07 1
5:07:45
* @Description: 资质证明上传组件
*/
import
React
from
'react'
;
...
...
@@ -64,7 +64,7 @@ const schema = new Schema({
},
});
const
Quali
fications
=
(
props
)
=>
{
const
Quali
tiesUploadFormItem
=
(
props
)
=>
{
const
{
value
,
className
,
...
...
@@ -117,7 +117,7 @@ const Qualifications = (props) => {
);
};
Quali
fications
.
isFieldComponent
=
true
;
Quali
tiesUploadFormItem
.
isFieldComponent
=
true
;
export
default
Quali
fications
;
export
default
Quali
tiesUploadFormItem
;
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