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
58c0428b
Commit
58c0428b
authored
Oct 26, 2020
by
cellee
Browse files
Options
Browse Files
Download
Plain Diff
Signed-off-by: cellee <893264950@qq.com>
parents
eca23140
b005129a
Changes
13
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
241 additions
and
232 deletions
+241
-232
SearchOptionsCommnity.tsx
src/components/SearchOptions/SearchOptionsCommnity.tsx
+11
-13
SearchOptionsTow.tsx
src/components/SearchOptions/SearchOptionsTow.tsx
+4
-5
Detail.tsx
src/pages/CommercialService/Detail.tsx
+99
-99
PropertyServices.tsx
src/pages/CommercialService/PropertyServices.tsx
+33
-31
Renovation.tsx
src/pages/CommercialService/Renovation.tsx
+69
-47
ChargeDetail.tsx
src/pages/PropertyManagement/ChargeDetail.tsx
+1
-1
UsersAdd.tsx
src/pages/UserManagement/LIFEUserManagement/UsersAdd.tsx
+8
-6
UsersAddInput.css
...pages/UserManagement/LIFEUserManagement/UsersAddInput.css
+2
-2
ServiceProviderManagement.tsx
...t/ServiceProviderManagement/ServiceProviderManagement.tsx
+1
-7
Services.tsx
...ges/UserManagement/ServiceProviderManagement/Services.tsx
+0
-5
index.tsx
src/pages/user/login/index.tsx
+12
-15
method.ts
src/utils/method.ts
+1
-1
~$S WEB端 接口文档(word) .docx
项目文档/~$S WEB端 接口文档(word) .docx
+0
-0
No files found.
src/components/SearchOptions/SearchOptionsCommnity.tsx
View file @
58c0428b
...
...
@@ -5,26 +5,24 @@ import SearchOptionsTow from './SearchOptionsTow';
const
SearchOptionsCommnity
=
(
props
:
any
)
=>
{
const
{
dispatch
,
CommunityList
,
opname
,
defaultName
}
=
props
;
const
tosCommunityget
=
(
values
:
any
)
=>
{
dispatch
({
type
:
'Init/tosCommunityget'
,
playload
:
values
})};
const
{
dispatch
,
CommunityList
,
opname
,
defaultName
}
=
props
;
const
tosCommunityget
=
(
values
:
any
)
=>
{
dispatch
({
type
:
'Init/tosCommunityget'
,
playload
:
values
})
};
useEffect
(()
=>
{
if
(
CommunityList
==
null
)
{
tosCommunityget
(
null
)
}
},
[]);
},
[]);
const
extendName
=
(
values
:
any
)
=>
{
// console.log(values)
opname
(
values
)
}
return
(
<>
{
CommunityList
!=
null
?
<>
{
CommunityList
!=
null
?
// <SearchOptions
// titleSearch=
{
titleSearch
}
// disabled=
{
disabled
}
...
...
@@ -33,14 +31,14 @@ const SearchOptionsCommnity = (props: any) => {
// list=
{
CommunityList
}
// onSubmit=
{
extendName
}
/
>
<
SearchOptionsTow
list
=
{
CommunityList
}
extendName
=
{
extendName
}
def
=
{
defaultName
}
>
<
/
SearchOptionsTow
>
:null
}
<
SearchOptionsTow
list
=
{
CommunityList
}
extendName
=
{
extendName
}
def
=
{
defaultName
}
>
<
/
SearchOptionsTow
>
:
null
}
</>
);
};
function
mapStateToProps
(
state
:
any
)
{
const
{
CommunityList
}
=
state
.
Init
;
function
mapStateToProps
(
state
:
any
)
{
const
{
CommunityList
}
=
state
.
Init
;
return
{
CommunityList
,
};
...
...
src/components/SearchOptions/SearchOptionsTow.tsx
View file @
58c0428b
...
...
@@ -2,16 +2,15 @@ import React from 'react'
import
{
Select
}
from
'antd'
;
const
{
Option
}
=
Select
;
const
SearchOptionsTow
=
(
porps
:
any
)
=>
{
const
SearchOptionsTow
=
(
porps
:
any
)
=>
{
const
{
list
,
extendName
,
def
}
=
porps
;
const
options
=
list
.
map
((
d
:
any
,
index
:
number
)
=>
<
Option
value=
{
d
}
key=
{
index
}
>
{
d
}
</
Option
>);
function
onChange
(
value
:
any
)
{
const
{
list
,
extendName
,
def
}
=
porps
;
const
options
=
list
.
map
((
d
:
any
,
index
:
number
)
=>
<
Option
value=
{
d
}
key=
{
index
}
>
{
d
}
</
Option
>);
function
onChange
(
value
:
any
)
{
// console.log(`selected ${value}`);
extendName
(
value
)
}
return
(
<
div
>
<
Select
...
...
src/pages/CommercialService/Detail.tsx
View file @
58c0428b
import
React
,
{
useState
,
useEffect
,
useRef
}
from
'react'
;
import
styles
from
'./css/Detail.less'
;
import
{
Input
,
Form
,
Row
,
Col
,
Upload
,
Spin
,
Button
,
Descriptions
}
from
'antd'
;
import
{
Input
,
Form
,
Row
,
Col
,
Upload
,
Spin
,
Button
,
Descriptions
}
from
'antd'
;
import
{
Link
,
useIntl
,
connect
,
Dispatch
}
from
'umi'
;
import
TextArea
from
'antd/lib/input/TextArea'
;
...
...
@@ -14,18 +14,18 @@ import { getCookie } from '@/utils/method';
import
{
timestampToTime
}
from
'@/utils/time'
;
import
{
validateMessages
}
from
'@/utils/params'
;
const
treatStatus
=
[
"Pending"
,
"Processed"
]
const
treatStatus
=
[
"Pending"
,
"Processed"
]
const
Detail
=
(
props
:
any
)
=>
{
const
Detail
=
(
props
:
any
)
=>
{
const
[
editorFlag
,
setEditorFlag
]
=
useState
(
true
);
const
{
dispatch
,
location
,
CurDataDetail
}
=
props
;
const
fromRef
=
useRef
(
null
)
const
RA
=
(
index
:
any
,
values
:
any
)
=>
{
dispatch
({
type
:
'CommunityService/RA'
,
playload
:
{
index
:
index
,
body
:
values
}
})
};
const
{
dispatch
,
location
,
CurDataDetail
}
=
props
;
const
fromRef
=
useRef
(
null
)
const
RA
=
(
index
:
any
,
values
:
any
)
=>
{
dispatch
({
type
:
'CommunityService/RA'
,
playload
:
{
index
:
index
,
body
:
values
}
})
};
const
[
curString
,
setCurString
]
=
useState
({
readyState
:
false
})
const
[
curString
,
setCurString
]
=
useState
({
readyState
:
false
})
const
[
loading
,
setLoading
]
=
useState
(
false
)
const
[
headTitle
,
setHeadTitle
]
=
useState
(
""
);
...
...
@@ -38,23 +38,22 @@ const Detail = (props:any) => {
"Reply To Problem Feedback"
]
useEffect
(()
=>
{
if
((
location
.
pathname
).
indexOf
(
"/Edit"
)
>-
1
)
{
if
((
location
.
pathname
).
indexOf
(
"/Edit"
)
>
-
1
)
{
setEditorFlag
(
true
)
}
else
{
setEditorFlag
(
false
)
}
RA
(
21
,{
RA
(
21
,
{
serviceType
:
location
.
query
.
serviceType
,
id
:
location
.
query
.
id
})
setHeadTitle
(
headTitles
[
parseInt
(
location
.
query
.
serviceType
)
-
1
])
setHeadTitle
(
headTitles
[
parseInt
(
location
.
query
.
serviceType
)
-
1
])
setLoading
(
true
)
},[
location
.
pathname
]);
useEffect
(()
=>
{
},
[
location
.
pathname
]);
useEffect
(()
=>
{
if
(
CurDataDetail
!=
null
&&
curString
.
readyState
==
true
)
{
console
.
log
(
"@@@@@@@@@@@@@@@@@@@@@@@@@@@@"
)
console
.
log
(
CurDataDetail
)
...
...
@@ -65,20 +64,21 @@ const Detail = (props:any) => {
setLoading
(
false
)
}
},
[
CurDataDetail
])
useEffect
(()
=>
{
useEffect
(()
=>
{
setCurString
({
readyState
:
true
})
console
.
log
(
"页面准备好了"
)
},[])
},
[])
const
onFinish
=
(
values
:
any
)
=>
{
const
onFinish
=
(
values
:
any
)
=>
{
console
.
log
(
values
)
var
val
=
values
;
val
.
handleName
=
getCookie
(
"name"
)
val
.
handleContacts
=
getCookie
(
"phone"
)
val
.
type
=
""
+
location
.
query
.
serviceType
val
.
handleName
=
getCookie
(
"name"
)
val
.
handleContacts
=
getCookie
(
"phone"
)
val
.
type
=
""
+
location
.
query
.
serviceType
val
.
id
=
location
.
query
.
id
val
.
userId
=
location
.
query
.
user_id
val
.
communityId
=
location
.
query
.
community_id
val
.
userId
=
location
.
query
.
user_id
val
.
communityId
=
location
.
query
.
community_id
val
.
handleStatus
=
"1"
// val.file=fileList
console
.
log
(
'Success:'
,
val
)
...
...
@@ -87,103 +87,103 @@ const Detail = (props:any) => {
};
const
titleProps
=
{
sublist
:
CurDataDetail
!=
null
?[
'Status : '
+
treatStatus
[
CurDataDetail
.
status
],
'Create Time : '
+
CurDataDetail
.
time
]:
null
,
sublist
:
CurDataDetail
!=
null
?
[
'Status : '
+
treatStatus
[
CurDataDetail
.
status
],
'Create Time : '
+
CurDataDetail
.
time
]
:
null
,
title
:
headTitle
}
return
(
<
div
>
{
CurDataDetail
!=
null
?
<>
<
Spin
spinning=
{
loading
}
>
<
div
className=
{
styles
.
base
}
>
<
TitleBack
{
...
titleProps
}
/>
<
Descriptions
>
<
Descriptions
.
Item
>
{
CurDataDetail
.
community
}
</
Descriptions
.
Item
>
<
Descriptions
.
Item
span=
{
2
}
>
{
CurDataDetail
.
home
}
</
Descriptions
.
Item
>
<
Descriptions
.
Item
label=
"Address"
span=
{
3
}
>
{
CurDataDetail
.
address
}
</
Descriptions
.
Item
>
<
Descriptions
.
Item
label=
"User Name"
>
{
CurDataDetail
.
name
}
</
Descriptions
.
Item
>
<
Descriptions
.
Item
label=
"Contact Details"
>
{
CurDataDetail
.
phone
}
</
Descriptions
.
Item
>
<
Descriptions
.
Item
>
{
CurDataDetail
.
email
}
</
Descriptions
.
Item
>
</
Descriptions
>
<
Row
gutter=
{
16
}
>
<
Col
span=
{
3
}
>
Description:
</
Col
>
<
Col
><
TextArea
style=
{
{
width
:
394
,
height
:
80
,
padding
:
8
}
}
autoSize=
{
false
}
disabled
value=
{
CurDataDetail
.
content
}
/></
Col
>
</
Row
>
<
Row
gutter=
{
16
}
style=
{
{
marginTop
:
20
}
}
>
<
Col
span=
{
3
}
>
Picture:
</
Col
>
<
Col
>
{
CurDataDetail
!=
null
?
<
PictureOptionsRow
action=
"/tos/communtiy/service/reply/img"
disabled=
{
true
}
defaultValue=
{
CurDataDetail
.
pictrues
}
data=
{
{
userToken
:
"token"
,
imageType
:
'tosCommunityImageReply'
,
extends
:
""
,
}
}
//
/>:
null
}
</
Col
>
</
Row
>
<
Line
/>
<
Form
ref=
{
fromRef
}
name=
"basic"
onFinish=
{
onFinish
}
validateMessages=
{
validateMessages
}
>
{
!
editorFlag
?
<
Row
gutter=
{
16
}
>
<
Col
>
Response:
</
Col
>
<
Col
span=
{
6
}
>
{
getCookie
(
"name"
)
}
</
Col
>
<
Col
>
Contract Detail:
</
Col
>
<
Col
>
{
getCookie
(
"phone"
)
}
</
Col
>
</
Row
>
:
null
}
<
Row
gutter=
{
16
}
style=
{
{
marginTop
:
20
}
}
>
<
Col
span=
{
3
}
>
Solution
&
Conclusion:
</
Col
>
<
Col
><
Form
.
Item
name=
"replyContent"
rules=
{
[{
required
:
true
,
max
:
300
}]
}
><
TextArea
style=
{
{
padding
:
8
,
width
:
394
,
height
:
80
}
}
autoSize=
{
false
}
disabled=
{
!
editorFlag
}
/></
Form
.
Item
></
Col
>
</
Row
>
<
Row
gutter=
{
16
}
>
<
Col
span=
{
3
}
></
Col
>
<
Col
>
{
/* putSubmit={PictureOptionsRowRef} */
}
{
CurDataDetail
.
replyImgUrl
!=
null
?
<>
<
Form
.
Item
name=
"file"
>
<
PictureOptionsRow
action=
"/tos/communtiy/service/reply/img"
disabled=
{
!
editorFlag
}
data=
{
{
<
div
>
{
CurDataDetail
!=
null
?
<>
<
Spin
spinning=
{
loading
}
>
<
div
className=
{
styles
.
base
}
>
<
TitleBack
{
...
titleProps
}
/>
<
Descriptions
>
<
Descriptions
.
Item
>
{
CurDataDetail
.
community
}
</
Descriptions
.
Item
>
<
Descriptions
.
Item
span=
{
2
}
>
{
CurDataDetail
.
home
}
</
Descriptions
.
Item
>
<
Descriptions
.
Item
label=
"Address"
span=
{
3
}
>
{
CurDataDetail
.
address
}
</
Descriptions
.
Item
>
<
Descriptions
.
Item
label=
"User Name"
>
{
CurDataDetail
.
name
}
</
Descriptions
.
Item
>
<
Descriptions
.
Item
label=
"Contact Details"
>
{
CurDataDetail
.
phone
}
</
Descriptions
.
Item
>
<
Descriptions
.
Item
>
{
CurDataDetail
.
email
}
</
Descriptions
.
Item
>
</
Descriptions
>
<
Row
gutter=
{
16
}
>
<
Col
span=
{
3
}
>
Description:
</
Col
>
<
Col
><
TextArea
style=
{
{
width
:
394
,
height
:
80
,
padding
:
8
}
}
autoSize=
{
false
}
disabled
value=
{
CurDataDetail
.
content
}
/></
Col
>
</
Row
>
<
Row
gutter=
{
16
}
style=
{
{
marginTop
:
20
}
}
>
<
Col
span=
{
3
}
>
Picture:
</
Col
>
<
Col
>
{
CurDataDetail
!=
null
?
<
PictureOptionsRow
action=
"/tos/communtiy/service/reply/img"
disabled=
{
true
}
defaultValue=
{
CurDataDetail
.
pictrues
}
data=
{
{
userToken
:
"token"
,
imageType
:
'tosCommunityImageReply'
,
extends
:
""
,
}
}
/>
</
Form
.
Item
>
</>:
null
}
}
//
/>
:
null
}
</
Col
>
</
Row
>
<
Line
/>
<
Form
ref=
{
fromRef
}
name=
"basic"
onFinish=
{
onFinish
}
validateMessages=
{
validateMessages
}
>
{
!
editorFlag
?
<
Row
gutter=
{
16
}
>
<
Col
>
Response:
</
Col
>
<
Col
span=
{
6
}
>
{
getCookie
(
"name"
)
}
</
Col
>
<
Col
>
Contract Detail:
</
Col
>
<
Col
>
{
getCookie
(
"phone"
)
}
</
Col
>
</
Row
>
:
null
}
<
Row
gutter=
{
16
}
style=
{
{
marginTop
:
20
}
}
>
<
Col
span=
{
3
}
>
Solution
&
Conclusion:
</
Col
>
<
Col
><
Form
.
Item
name=
"replyContent"
rules=
{
[{
required
:
true
,
max
:
300
}]
}
><
TextArea
style=
{
{
padding
:
8
,
width
:
394
,
height
:
80
}
}
autoSize=
{
false
}
disabled=
{
!
editorFlag
}
/></
Form
.
Item
></
Col
>
</
Row
>
<
Row
gutter=
{
16
}
>
<
Col
span=
{
3
}
></
Col
>
<
Col
>
{
/* putSubmit={PictureOptionsRowRef} */
}
{
CurDataDetail
.
replyImgUrl
!=
null
?
<>
<
Form
.
Item
name=
"file"
>
<
PictureOptionsRow
action=
"/tos/communtiy/service/reply/img"
disabled=
{
!
editorFlag
}
data=
{
{
userToken
:
"token"
,
imageType
:
'tosCommunityImageReply'
,
extends
:
""
,
}
}
/>
</
Form
.
Item
>
</>
:
null
}
</
Col
>
</
Row
>
{
editorFlag
?
<><
Line
/><
Row
><
Col
span=
{
3
}
></
Col
><
Col
><
Form
.
Item
><
Button
type=
"primary"
htmlType=
"submit"
>
Submit
</
Button
></
Form
.
Item
></
Col
></
Row
></>:
null
}
</
Form
>
</
Col
>
</
Row
>
{
editorFlag
?
<><
Line
/><
Row
><
Col
span=
{
3
}
></
Col
><
Col
><
Form
.
Item
><
Button
type=
"primary"
htmlType=
"submit"
>
Submit
</
Button
></
Form
.
Item
></
Col
></
Row
></>
:
null
}
</
Form
>
</
div
>
</
Spin
>
</>
</
Spin
>
</>
:
null
}
</
div
>
</
div
>
);
};
function
mapStateToProps
(
state
:
any
)
{
function
mapStateToProps
(
state
:
any
)
{
const
{
CurDataDetail
}
=
state
.
CommunityService
;
return
{
CurDataDetail
...
...
src/pages/CommercialService/PropertyServices.tsx
View file @
58c0428b
import
React
,
{
useState
,
useEffect
}
from
'react'
;
import
styles
from
'./css/index.less'
;
import
{
Input
,
Menu
,
Table
,
Space
,
Upload
,
message
,
Pagination
,
Button
}
from
'antd'
;
import
{
Input
,
Menu
,
Table
,
Space
,
Upload
,
message
,
Pagination
,
Button
}
from
'antd'
;
import
{
Link
,
useIntl
,
connect
,
Dispatch
,
history
}
from
'umi'
;
import
{
Link
,
useIntl
,
connect
,
Dispatch
,
history
}
from
'umi'
;
import
{
timestampToTime3
}
from
'../../utils/time'
;
...
...
@@ -11,10 +11,10 @@ import { RA, urlEncode, filterObj, filterObjbyTg } from '@/utils/method';
const
pathname
=
[
"CommunityMaintenance"
,
"ShelfLifeService"
,
"OwnerComplaints"
,
"ReportOnline"
,
"ProblemFeedback"
]
const
handle_Status
=
[[
0
,
"Pending"
],
[
1
,
"Processed"
]]
//["未处理","处理","拒绝"] , [2,"Rejected"]
const
handle_Status
=
[[
0
,
"Pending"
],
[
1
,
"Processed"
]]
//["未处理","处理","拒绝"] , [2,"Rejected"]
const
goToName
=
[
"Reply"
,
"Detail"
];
const
module
=
"CommunityService"
const
module
=
"CommunityService"
const
PropertyServices
=
(
props
:
any
)
=>
{
const
{
dispatch
,
location
,
Data
}
=
props
;
...
...
@@ -22,15 +22,15 @@ const PropertyServices = (props: any) => {
const
[
loading
,
setLoading
]
=
useState
(
false
)
const
[
pageNum
,
setPageNum
]
=
useState
(
1
)
const
[
serviceTypeGobal
,
setServiceType
]
=
useState
(
""
)
const
[
readyData
,
setReadyData
]
=
useState
(
null
)
const
[
readyData
,
setReadyData
]
=
useState
(
null
)
const
columns
=
[
{
title
:
"Community Name"
,
dataIndex
:
'community_name'
,
},
{
title
:
"Ower Name"
,
dataIndex
:
'ower_name'
,
},
{
title
:
"
Reply"
,
dataIndex
:
'handle_name'
,
render
:
(
text
:
any
)
=>
(<
Space
size=
"middle"
>
{
text
!=
null
?
text
:
"--"
}
</
Space
>)
},
{
title
:
"Create Time"
,
dataIndex
:
"create_time"
,
render
:
(
text
:
any
,
record
:
any
)
=>
(<
Space
size=
"middle"
>
{
timestampToTime3
(
text
.
time
)
}
</
Space
>)
},
{
title
:
"Handle status"
,
dataIndex
:
'handle_status'
,
render
:
(
text
:
any
,
record
:
any
)
=>
(<
Space
size=
"middle"
>
{
handle_Status
[
text
][
1
]
}
</
Space
>)
},
{
title
:
"Actions"
,
dataIndex
:
'handle_status'
,
render
:
(
text
:
any
,
record
:
any
)
=>
(<
Space
size=
"middle"
><
a
onClick=
{
goToDetail
.
bind
(
this
,
text
,
record
)
}
>
{
goToName
[
text
]
}
</
a
></
Space
>)
},
{
title
:
"Community Name"
,
dataIndex
:
'community_name'
,
},
{
title
:
"Ower Name"
,
dataIndex
:
'ower_name'
,
},
{
title
:
"
service Content"
,
dataIndex
:
'service_content'
,
ellipsis
:
true
,
width
:
500
,
render
:
(
text
:
any
)
=>
(<
Space
size=
"middle"
>
{
text
!=
null
?
text
:
"--"
}
</
Space
>)
},
{
title
:
"Create Time"
,
dataIndex
:
"create_time"
,
render
:
(
text
:
any
,
record
:
any
)
=>
(<
Space
size=
"middle"
>
{
timestampToTime3
(
text
.
time
)
}
</
Space
>)
},
{
title
:
"Handle status"
,
dataIndex
:
'handle_status'
,
render
:
(
text
:
any
,
record
:
any
)
=>
(<
Space
size=
"middle"
>
{
handle_Status
[
text
][
1
]
}
</
Space
>)
},
{
title
:
"Actions"
,
dataIndex
:
'handle_status'
,
render
:
(
text
:
any
,
record
:
any
)
=>
(<
Space
size=
"middle"
><
a
onClick=
{
goToDetail
.
bind
(
this
,
text
,
record
)
}
>
{
goToName
[
text
]
}
</
a
></
Space
>)
},
];
const
goToDetail
=
(
value
:
any
,
record
:
any
,
e
:
any
)
=>
{
...
...
@@ -39,38 +39,40 @@ const PropertyServices = (props: any) => {
console
.
log
(
record
);
//页面递进
history
.
push
(
location
.
pathname
+
(
value
==
0
?
"/Edit"
:
"/Detail"
)
+
urlEncode
(
location
.
pathname
+
(
value
==
0
?
"/Edit"
:
"/Detail"
)
+
urlEncode
(
{
serviceType
:
serviceTypeGobal
,
id
:
record
.
id
,
user_id
:
record
.
user_id
,
community_id
:
record
.
community_id
user_id
:
record
.
user_id
,
community_id
:
record
.
community_id
}
)
)
)
}
useEffect
(()
=>
{
if
(
Data
!=
null
)
{
setLoading
(
false
)
}
if
(
Data
!=
null
)
{
setLoading
(
false
)
}
},
[
Data
]);
const
ClickTitleSearch
=
(
comment
:
any
)
=>
{
//页面搜索
comment
.
serviceType
=
serviceTypeGobal
comment
.
current
=
1
history
.
push
(
location
.
pathname
+
urlEncode
(
filterObj
(
comment
)))
history
.
push
(
location
.
pathname
+
urlEncode
(
filterObj
(
comment
)))
}
const
PageChange
=
(
values
:
any
)
=>
{
//.current
//页面跳转参数
var
tmp
=
filterObjbyTg
(
location
.
query
,
[
"handleStatus"
,
"ownerName"
,
"communityName"
])
tmp
[
"current"
]
=
values
.
current
tmp
[
"current"
]
=
values
.
current
history
.
push
(
location
.
pathname
+
urlEncode
(
tmp
))
}
useEffect
(()
=>
{
useEffect
(()
=>
{
if
(
location
!=
null
)
{
//细分类:页面指令
var
serviceType
=
""
var
serviceType
=
""
pathname
.
map
((
item
,
index
)
=>
{
if
((
location
.
pathname
).
indexOf
(
item
)
>
-
1
)
{
serviceType
=
""
+
(
index
+
1
)
...
...
@@ -78,7 +80,7 @@ const PropertyServices = (props: any) => {
}
})
//分页设置
if
(
location
.
query
.
current
!=
null
)
{
if
(
location
.
query
.
current
!=
null
)
{
setPageNum
(
parseInt
(
location
.
query
.
current
))
}
else
{
setPageNum
(
1
)
...
...
@@ -117,20 +119,20 @@ const PropertyServices = (props: any) => {
defaultValue=
{
readyData
}
onSubmit=
{
ClickTitleSearch
}
/>
<
Table
rowKey=
{
"id"
}
style=
{
{
marginTop
:
16
}
}
loading=
{
loading
}
columns=
{
columns
}
dataSource=
{
Data
!=
null
?
Data
.
data
.
rows
:
[]
}
pagination=
{
Data
!=
null
?
{
current
:
pageNum
,
total
:
Data
.
data
.
rows
.
length
}
:
{}
}
onChange=
{
PageChange
}
/>
<
Table
rowKey=
{
"id"
}
style=
{
{
marginTop
:
16
}
}
loading=
{
loading
}
columns=
{
columns
}
dataSource=
{
Data
!=
null
?
Data
.
data
.
rows
:
[]
}
pagination=
{
Data
!=
null
?
{
current
:
pageNum
,
total
:
Data
.
data
.
rows
.
length
}
:
{}
}
onChange=
{
PageChange
}
/>
</
div
>
);
};
function
mapStateToProps
(
state
:
any
)
{
function
mapStateToProps
(
state
:
any
)
{
const
{
Data
}
=
state
.
CommunityService
;
return
{
Data
...
...
src/pages/CommercialService/Renovation.tsx
View file @
58c0428b
import
React
,
{
useState
,
useEffect
,
useRef
}
from
'react'
;
import
{
Input
,
Tabs
,
Table
,
Space
,
Button
}
from
'antd'
;
import
React
,
{
useState
,
useEffect
,
useRef
}
from
'react'
;
import
{
Input
,
Tabs
,
Table
,
Space
,
Button
}
from
'antd'
;
const
{
TabPane
}
=
Tabs
;
import
{
connect
,
history
}
from
'umi'
;
import
{
connect
,
history
}
from
'umi'
;
import
TitleSearch
from
'../../components/TitleSearch/TitleSearch'
;
import
{
RA
,
SA
,
urlEncode
,
filterObj
,
filterObjbyTg
}
from
'@/utils/method'
;
import
{
RA
,
SA
}
from
'@/utils/method'
;
import
{
objectColumns
,
stringTab
}
from
'@/utils/string'
;
import
{
timestampToTime
}
from
'@/utils/time'
;
const
module
=
"CommunityService"
const
Renovation
=
(
props
:
any
)
=>
{
const
module
=
"CommunityService"
const
Renovation
=
(
props
:
any
)
=>
{
// const decoration_status = [[0, "待处理"], [1, "已批准"], [2, "已拒绝"]]
const
decoration_status
=
[[
0
,
"Pending"
],
[
1
,
"Approved"
],
[
2
,
"Rejected"
]]
const
pathname
=
[
"CommunityMaintenance"
,
"ShelfLifeService"
,
"OwnerComplaints"
,
"ReportOnline"
,
"ProblemFeedback"
]
const
[
loading
,
setLoading
]
=
useState
(
false
)
const
[
serviceTypeGobal
,
setServiceType
]
=
useState
(
""
)
const
[
pageNum
,
setPageNum
]
=
useState
(
1
)
const
[
readyData
,
setReadyData
]
=
useState
(
null
)
const
columns
=
objectColumns
([
[
"Community"
,
"community_name"
],
[
"Applicant"
,
"applyfor_name"
],
[
"Unit"
,
null
,
(
text
:
any
,
record
:
any
)
=>
(<
div
>
{
record
.
community_build_decorate
}
#
{
record
.
community_floor_decorate
}
-
{
record
.
community_room_decoate
}
</
div
>)],
[
"Content"
,
"decoration_content"
,
(
text
:
any
)
=>
(<
div
>
{
stringTab
(
text
)
}
</
div
>)],
[
"Request Time"
,
"create_time"
,(
text
:
any
)
=>
(<
div
>
{
timestampToTime
(
text
.
time
)
}
</
div
>)],
[
"status"
,
"decoration_status"
,(
text
:
any
)
=>
(<
div
>
{
decoration_status
[
parseInt
(
text
)][
1
]
}
</
div
>)],
[
"Actions"
,
null
,
(
text
:
any
,
record
:
any
)
=>
(<
Space
size=
"middle"
>
<
a
onClick=
{
goToDetail
.
bind
(
this
,
record
)
}
>
Detail
</
a
></
Space
>)],
[
"Request Time"
,
"create_time"
,
(
text
:
any
)
=>
(<
div
>
{
timestampToTime
(
text
.
time
)
}
</
div
>)],
[
"status"
,
"decoration_status"
,
(
text
:
any
)
=>
(<
div
>
{
decoration_status
[
parseInt
(
text
)][
1
]
}
</
div
>)],
[
"Actions"
,
null
,
(
text
:
any
,
record
:
any
)
=>
(<
Space
size=
"middle"
>
<
a
onClick=
{
goToDetail
.
bind
(
this
,
record
)
}
>
Detail
</
a
></
Space
>)],
])
const
{
dispatch
,
Data8
}
=
props
;
const
formRef
=
useRef
(
null
)
useEffect
(()
=>
{
RA
(
23
,
{
serviceType
:
"6"
,
id
:
""
},
module
,
dispatch
)
// applyfor_name: "jack-小白白"
// communityId: "7e5c6fd2f4ba497a90e64535df6e9088"
// community_build_decorate: "01"
// community_floor_decorate: "00"
// community_name: "A4"
// community_room_decoate: "767"
// contact_name: "15626274096"
// contact_phone: "jack-小白白"
// create_time: {date: 10, day: 4, hours: 19, minutes: 39, month: 8, …}
// decorationBegin_time: {date: 10, day: 4, hours: 0, minutes: 0, month: 8, …}
// decorationEnd_time: {date: 10, day: 4, hours: 0, minutes: 0, month: 8, …}
// decoration_content: "滚滚滚"
// decoration_status: 0
// deleted: 0
// id: "977591272158003200"
// ownerId: "c4da40676d044487b37e7a1bdc6dd045"
// update_time: {
// date: 10, day: 4, hours: 19, minutes:
},
[])
const
{
dispatch
,
Data8
,
location
}
=
props
;
useEffect
(()
=>
{
if
(
Data8
!=
null
)
{
setLoading
(
false
)
}
},
[
Data8
]);
useEffect
(()
=>
{
if
(
location
!=
null
)
{
//前置数据
console
.
log
(
"前置数据"
);
let
tmp
:
any
=
filterObjbyTg
(
location
.
query
,
[
"handleStatus"
,
"ownerName"
,
"communityName"
,
"current"
])
tmp
.
handleStatus
=
decoration_status
[
parseInt
(
tmp
.
handleStatus
)]
//特殊处理
setReadyData
(
tmp
)
//获取数据
setLoading
(
true
)
RA
(
23
,
{
serviceType
:
"6"
,
id
:
""
},
module
,
dispatch
)
}
},
[
location
])
//页面搜索
const
ClickTitleSearch
=
(
comment
:
any
)
=>
{
let
tmp
=
filterObjbyTg
(
comment
,
[
"handleStatus"
,
"ownerName"
,
"communityName"
])
tmp
[
"current"
]
=
1
console
.
log
(
tmp
)
history
.
push
(
location
.
pathname
+
urlEncode
(
tmp
))
}
const
goToDetail
=
(
values
:
any
,
e
:
any
)
=>
{
SA
(
values
,
module
,
dispatch
)
history
.
push
(
'./RenovationApplication/Detail'
)
SA
(
values
,
module
,
dispatch
)
history
.
push
(
'./RenovationApplication/Detail'
)
}
return
(
<
div
style=
{
{
width
:
"100%"
,
minWidth
:
1020
,
padding
:
34
,
backgroundColor
:
"#ffffff"
}
}
>
{
Data8
!=
null
?
<>
<
Table
loading=
{
false
}
rowKey=
"id"
style=
{
{
marginTop
:
16
}
}
dataSource=
{
Data8
.
data
.
rows
}
columns=
{
columns
}
pagination=
{
{
defaultCurrent
:
1
,
total
:
Data8
.
total
}
}
/>
</>
Data8
!=
null
?
<>
<
TitleSearch
communitySelect=
{
true
}
listkey=
{
[
'ownerName'
]
}
list=
{
[
'Owner Name'
]
}
status=
{
[{
name
:
[
"handleStatus"
,
"Status"
],
data
:
decoration_status
}]
}
defaultValue=
{
readyData
}
onSubmit=
{
ClickTitleSearch
}
/>
<
Table
loading=
{
loading
}
rowKey=
"id"
style=
{
{
marginTop
:
16
}
}
dataSource=
{
Data8
.
data
.
rows
}
columns=
{
columns
}
pagination=
{
{
defaultCurrent
:
1
,
total
:
Data8
.
total
}
}
/>
</>
:
null
}
</
div
>
);
};
function
map
(
state
:
any
)
{
const
{
Data8
}
=
state
[
module
]
return
{
Data8
}
function
map
(
state
:
any
)
{
const
{
Data8
}
=
state
[
module
]
return
{
Data8
}
}
export
default
connect
(
map
)(
Renovation
);
src/pages/PropertyManagement/ChargeDetail.tsx
View file @
58c0428b
...
...
@@ -66,7 +66,7 @@ const ChargeDetail = (props: any) => {
<
Pagination
simple
defaultCurrent=
{
curpage
}
total=
{
pages
*
10
}
onChange=
{
pageChange
}
/>
</
div
>
<>
<
Tooltip
title=
{
scale
==
1.3
?
'点击放大查看'
+
CurData
.
billFileUrl
:
'还原视图'
}
>
<
Tooltip
title=
{
scale
==
1.3
?
'点击放大查看'
:
'还原视图'
}
>
<
div
className=
{
scale
==
1.3
?
styles
.
box3out
:
null
}
>
<
div
className=
{
scale
==
1.3
?
styles
.
box3
:
styles
.
box3of
}
onClick=
{
lookup
}
>
<
PDF
...
...
src/pages/UserManagement/LIFEUserManagement/UsersAdd.tsx
View file @
58c0428b
...
...
@@ -10,7 +10,7 @@ import SearchOptionsCommnity from '../../../components/SearchOptions/SearchOptio
import
{
checkParam
,
RA
}
from
'../../../utils/method'
import
{
validateMessages
}
from
'@/utils/params'
;
import
"./UsersAddInput.less"
//
import "./UsersAddInput.less"
const
module
=
"User"
...
...
@@ -22,8 +22,9 @@ const UsersAdd = (props: any) => {
const
formRef
=
useRef
(
null
as
any
);
const
[
loading
,
setLoading
]
=
useState
(
false
)
const
onFinish
=
(
values
:
any
)
=>
{
const
onFinish
=
(
values
:
any
)
=>
{
console
.
log
(
values
)
if
(
postman
.
extend
!=
null
)
{
values
.
communityName
=
postman
.
extend
}
else
{
...
...
@@ -57,6 +58,7 @@ const UsersAdd = (props: any) => {
},
[
communityInfo
])
const
checkData
=
(
rule
:
any
,
value
:
any
,
callback
:
any
)
=>
{
console
.
log
(
rule
,
value
)
if
(
value
)
{
if
(
/^
[
a-zA-Z0-9
]
+$/g
.
test
(
value
))
{
callback
();
...
...
@@ -79,10 +81,10 @@ const UsersAdd = (props: any) => {
</
div
>
{
/* <div className={styles.box4}>
<div className={styles.box4item0}>Contact Details</div>
<div className={styles.box4item1}><Form.Item name="owerPhone" ><Input placeholder="Phone Number" /></Form.Item></div>
<div className={styles.box4item2}><Form.Item name="owerEmail" ><Input placeholder="Email" /></Form.Item></div>
</div>
*/
}
<div className={styles.box4item0}>Contact Details</div>
<div className={styles.box4item1}><Form.Item name="owerPhone" ><Input placeholder="Phone Number" /></Form.Item></div>
<div className={styles.box4item2}><Form.Item name="owerEmail" ><Input placeholder="Email" /></Form.Item></div>
</div>
*/
}
<
div
className=
{
styles
.
box2
}
>
<
div
className=
{
styles
.
box2item1
}
>
Contact Details
</
div
>
...
...
src/pages/UserManagement/LIFEUserManagement/UsersAddInput.css
View file @
58c0428b
.box2item3___3VsZz
.ant-form-item-explain
{
/*
.box2item3___3VsZz .ant-form-item-explain {
margin-left: -80px;
}
.box2item5___2AZ2K .ant-form-item-explain {
...
...
@@ -9,4 +9,4 @@
}
.box2item7___ePaor .ant-form-item-explain {
margin-left: -30px;
}
}
*/
src/pages/UserManagement/ServiceProviderManagement/ServiceProviderManagement.tsx
View file @
58c0428b
...
...
@@ -108,22 +108,16 @@ const ServiceProviderManagement = (props: any) => {
},
[
Data
])
useEffect
(()
=>
{
//分页设置
// if (location.query.pageNum != null) {
// setPageNum(parseInt(location.query.pageNum))
// } else {
// }
setPageNum
(
1
)
setLoading
(
true
)
//获取数据
TosTosServiceProviderGet
({
...
location
.
query
,
serviceCommunityList
:
(
testData
===
null
||
testData
.
length
===
0
)
?
CommunityList
:
testData
,
pageNum
:
1
})
},
[
location
])
const
CallBackTitleSearch
=
(
comment
:
any
)
=>
{
...
...
src/pages/UserManagement/ServiceProviderManagement/Services.tsx
View file @
58c0428b
...
...
@@ -4,12 +4,7 @@ import { Form, Button, Modal, Space, Pagination, Tooltip, Checkbox } from 'antd'
import
{
Link
,
useIntl
,
connect
,
Dispatch
}
from
'umi'
;
import
{
PlusCircleOutlined
}
from
'@ant-design/icons'
;
import
Line
from
'../../../components/Line/Line'
;
import
BackButton
from
'../../../components/BackButton/BackButton'
;
import
TitleGet
from
'../../../components/TitleGet/TitleGet'
;
import
TagSelect
from
'../../../components/TagSelect/index'
;
import
{
RA
}
from
'@/utils/method'
;
import
TitleBack
from
'@/components/TitleBack/TitleBack'
;
...
...
src/pages/user/login/index.tsx
View file @
58c0428b
...
...
@@ -32,9 +32,6 @@ const Login: React.FC<LoginProps> = (props) => {
const
handleSubmit
=
(
values
:
LoginParamsType
)
=>
{
const
{
dispatch
}
=
props
;
console
.
log
({
...
values
,
type
,
userName
,
password
});
console
.
log
(
props
);
console
.
log
(
dispatch
,
'dispatch'
);
dispatch
({
type
:
'login/login'
,
payload
:
{
userName
,
password
},
...
...
@@ -84,8 +81,8 @@ const Login: React.FC<LoginProps> = (props) => {
<
ArrowLeftOutlined
style=
{
{
fontSize
:
'28px'
}
}
/>
</
div
>
)
:
(
<
div
/>
)
}
<
div
/>
)
}
<
LoginForm
activeKey=
{
type
}
onTabChange=
{
setType
}
onSubmit=
{
handleSubmit
}
>
<
div
className=
{
styles
.
box1
}
>
Account Number
</
div
>
<
input
className=
{
styles
.
input
}
onChange=
{
usernameHandle
}
/>
...
...
@@ -98,20 +95,20 @@ const Login: React.FC<LoginProps> = (props) => {
</
div
>
</
div
>
)
:
(
<
div
>
<
input
className=
{
styles
.
input2
}
onChange=
{
passwdHandle
}
type=
"password"
/>
<
div
>
<
div
className=
{
styles
.
input3
}
onClick=
{
gotoForgetHandle
}
>
Forget Password
<
input
className=
{
styles
.
input2
}
onChange=
{
passwdHandle
}
type=
"password"
/>
<
div
>
<
div
className=
{
styles
.
input3
}
onClick=
{
gotoForgetHandle
}
>
Forget Password
</
div
>
<
div
className=
{
styles
.
input4
}
>
{
status
===
'error'
&&
loginType
===
'account'
&&
!
submitting
&&
(
<
div
>
Wrong account or password
</
div
>
)
}
<
div
className=
{
styles
.
input4
}
>
{
status
===
'error'
&&
loginType
===
'account'
&&
!
submitting
&&
(
<
div
>
Wrong account or password
</
div
>
)
}
</
div
>
</
div
>
</
div
>
</
div
>
)
}
)
}
<
Submit
className=
{
styles
.
button
}
loading=
{
submitting
}
style=
{
{
width
:
330
}
}
>
{
forgetflag
?
'Next'
:
'登录'
}
</
Submit
>
...
...
src/utils/method.ts
View file @
58c0428b
...
...
@@ -146,7 +146,7 @@ export const filterObjbyTg = (obj: any, tg: any) => {
var
tmp
=
{};
for
(
var
item
in
obj
)
{
if
(
tg
.
indexOf
(
item
)
>
-
1
)
{
if
(
obj
[
item
]
!=
null
)
{
if
(
(
obj
[
item
]
===
0
||
obj
[
item
])
&&
obj
[
item
]
!=
null
)
{
tmp
[
item
]
=
obj
[
item
];
}
}
...
...
项目文档/~$S WEB端 接口文档(word) .docx
0 → 100644
View file @
58c0428b
File added
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