Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
T
TOSTUMI
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
Maple
TOSTUMI
Commits
a9a1ed0c
Commit
a9a1ed0c
authored
Aug 12, 2020
by
maple
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[new]小区列表组件、未完成、(接口应该为数组非数字符串)
parent
78b644a4
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
61 additions
and
29 deletions
+61
-29
init.ts
src/models/init.ts
+32
-0
ServiceProviderManagement.tsx
...t/ServiceProviderManagement/ServiceProviderManagement.tsx
+6
-4
保安详情.txt
src/pages/UserManagement/ServiceProviderManagement/保安详情.txt
+0
-3
Template.tsx
src/pages/runTest/Template.tsx
+17
-22
Init.ts
src/services/Init.ts
+6
-0
No files found.
src/models/init.ts
0 → 100644
View file @
a9a1ed0c
import
*
as
service
from
'../services/Init'
;
import
{
message
}
from
'antd'
;
import
{
routerRedux
}
from
'dva/router'
export
default
{
namespace
:
'Init'
,
state
:
{
CommunityList
:
''
,
},
reducers
:
{
returnCommunityList
(
state
,
{
CommunityList
})
{
return
{
...
state
,
CommunityList
};
},
},
effects
:
{
//获取物业费列表
*
tosCommunityget
({
playload
},
{
call
,
put
})
{
console
.
log
(
playload
)
const
resp
=
yield
call
(
service
.
tosCommunityget
,
playload
);
console
.
log
(
resp
)
let
CommunityList
=
resp
.
data
.
communityList
;
yield
put
({
type
:
'returnCommunityList'
,
CommunityList
,
});
},
},
};
src/pages/UserManagement/ServiceProviderManagement/ServiceProviderManagement.tsx
View file @
a9a1ed0c
...
@@ -13,7 +13,7 @@ import SelectOptions from '../../../components/SelectOptions/index';
...
@@ -13,7 +13,7 @@ import SelectOptions from '../../../components/SelectOptions/index';
const
ServiceProviderManagement
=
(
props
:
any
)
=>
{
const
ServiceProviderManagement
=
(
props
:
any
)
=>
{
const
{
formatMessage
}
=
useIntl
();
const
{
formatMessage
}
=
useIntl
();
const
{
dispatch
,
location
,
Data
}
=
props
;
const
{
dispatch
,
location
,
Data
,
CommunityList
}
=
props
;
const
get
=
(
values
:
any
)
=>
{
dispatch
({
type
:
'ServiceProvider/get'
,
playload
:
values
})};
const
get
=
(
values
:
any
)
=>
{
dispatch
({
type
:
'ServiceProvider/get'
,
playload
:
values
})};
useEffect
(()
=>
{
useEffect
(()
=>
{
get
(
null
)
get
(
null
)
...
@@ -67,10 +67,10 @@ const ServiceProviderManagement = (props: any) => {
...
@@ -67,10 +67,10 @@ const ServiceProviderManagement = (props: any) => {
return
(
return
(
<
div
className=
{
styles
.
base
}
>
<
div
className=
{
styles
.
base
}
>
{
/* 头部组件 */
}
{
/* 头部组件 */
}
<
h1
>
CommunityList(
{
CommunityList
[
0
]
}
):
{
CommunityList
}
</
h1
>
<
Form
ref=
{
formRef
}
name=
"basic"
initialValues=
{
{}
}
onFinish=
{
onFinish
}
onFinishFailed=
{
onFinishFailed
}
>
<
Form
ref=
{
formRef
}
name=
"basic"
initialValues=
{
{}
}
onFinish=
{
onFinish
}
onFinishFailed=
{
onFinishFailed
}
>
<
div
className=
{
styles
.
box
}
><
Form
.
Item
name=
"providerName"
><
Input
style=
{
{
width
:
200
}
}
placeholder=
"Service Provider"
/></
Form
.
Item
></
div
>
<
div
className=
{
styles
.
box
}
><
Form
.
Item
name=
"providerName"
><
Input
style=
{
{
width
:
200
}
}
placeholder=
"Service Provider"
/></
Form
.
Item
></
div
>
<
SelectOptions
list=
{
[
"美国"
,
"美丽的"
,
"美好"
,
"加拿大"
,
"加油"
,
"XO"
].
sort
()
}
onSubmit=
{
printContent
}
/>
<
SelectOptions
list=
{
CommunityList
}
onSubmit=
{
printContent
}
/>
<
Form
.
Item
><
button
className=
{
styles
.
item3
}
>
Search
</
button
></
Form
.
Item
>
<
Form
.
Item
><
button
className=
{
styles
.
item3
}
>
Search
</
button
></
Form
.
Item
>
</
Form
>
</
Form
>
{
/* 内容组件 */
}
{
/* 内容组件 */
}
...
@@ -89,8 +89,10 @@ const ServiceProviderManagement = (props: any) => {
...
@@ -89,8 +89,10 @@ const ServiceProviderManagement = (props: any) => {
function
mapStateToProps
(
state
:
any
)
{
function
mapStateToProps
(
state
:
any
)
{
const
{
Data
}
=
state
.
ServiceProvider
;
const
{
Data
}
=
state
.
ServiceProvider
;
const
{
CommunityList
}
=
state
.
Init
;
return
{
return
{
Data
Data
,
CommunityList
};
};
}
}
...
...
src/pages/UserManagement/ServiceProviderManagement/保安详情.txt
deleted
100644 → 0
View file @
78b644a4
CompanyName Sunshine Stab
FullName
\ No newline at end of file
src/pages/runTest/Template.tsx
View file @
a9a1ed0c
...
@@ -8,32 +8,21 @@ import Line from '../../components/Line/Line';
...
@@ -8,32 +8,21 @@ import Line from '../../components/Line/Line';
import
BackButton
from
'../../components/BackButton/BackButton'
;
import
BackButton
from
'../../components/BackButton/BackButton'
;
import
TitleGet
from
'../../components/TitleGet/TitleGet'
;
import
TitleGet
from
'../../components/TitleGet/TitleGet'
;
const
Guard
=
()
=>
{
const
Guard
=
(
props
:
any
)
=>
{
return
(
<
div
className=
{
styles
.
base
}
>
const
{
dispatch
,
CommunityList
}
=
props
;
const
tosCommunityget
=
(
values
:
any
)
=>
{
dispatch
({
type
:
'Init/tosCommunityget'
,
playload
:
values
})};
useEffect
(()
=>
{
tosCommunityget
(
null
)
},
[]);
<
div
className=
{
styles
.
item0
}
><
TitleGet
title=
{
"Edit Security Guard Account"
}
/></
div
>
<
div
className=
{
styles
.
item0_1
}
>
Status:Normal
</
div
>
<
div
className=
{
styles
.
item0_1
}
>
Registration Date:23-03-2020
</
div
>
<
div
className=
{
styles
.
item2
}
><
BackButton
/></
div
>
<
div
className=
{
styles
.
clear0
}
></
div
>
<
div
className=
{
styles
.
item1
}
>
Company Name
</
div
>
return
(
<
div
className=
{
styles
.
item1_1
}
>
123
</
div
>
<
div
className=
{
styles
.
base
}
>
<
div
className=
{
styles
.
clear1
}
></
div
>
<
div
className=
{
styles
.
item1
}
>
Full Name
</
div
>
<
div
className=
{
styles
.
item1_1
}
>
123
</
div
>
<
div
className=
{
styles
.
clear1
}
></
div
>
<
div
className=
{
styles
.
item1
}
>
Contact Details
</
div
>
<
div
className=
{
styles
.
item1_1
}
>
12312
</
div
>
<
div
className=
{
styles
.
item1
}
style=
{
{
marginLeft
:
32
,
width
:
40
}
}
>
Email
</
div
>
<
div
className=
{
styles
.
item1_1
}
>
123123213
</
div
>
<
div
className=
{
styles
.
clear1
}
></
div
>
<
div
className=
{
styles
.
item0
}
><
TitleGet
title=
{
"This is a test"
}
/></
div
>
<
h1
>
{
CommunityList
}
</
h1
>
<
Line
/>
<
Line
/>
<
Button
>
Cancellation
</
Button
>
<
Button
>
Cancellation
</
Button
>
...
@@ -43,5 +32,11 @@ const Guard = () => {
...
@@ -43,5 +32,11 @@ const Guard = () => {
);
);
};
};
function
mapStateToProps
(
state
:
any
)
{
const
{
CommunityList
}
=
state
.
Init
;
return
{
CommunityList
};
}
export
default
Guard
;
export
default
connect
(
mapStateToProps
)(
Guard
)
;
src/services/Init.ts
0 → 100644
View file @
a9a1ed0c
import
request
from
'@/utils/request'
;
export
function
tosCommunityget
(
values
:
any
)
{
console
.
log
(
values
)
return
request
(
'/tos/tosCommunity/get'
,{
method
:
'POST'
,
body
:
JSON
.
stringify
(
values
),
headers
:{
'Content-Type'
:
'application/json'
}})
}
\ No newline at end of file
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