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
cc314693
Commit
cc314693
authored
Dec 10, 2020
by
cellee
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'final' of
http://120.77.240.215:9701/Maple/tostumi.git
into final
parents
c2c49966
f48f02f4
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
73 additions
and
35 deletions
+73
-35
CommunityService.ts
src/models/CommunityManagement/CommunityService.ts
+4
-4
ServiceProvider.ts
src/models/ServiceProvider.ts
+38
-8
Detail.tsx
src/pages/CommercialService/Detail.tsx
+8
-6
PropertyServices.tsx
src/pages/CommercialService/PropertyServices.tsx
+13
-13
Edit.tsx
src/pages/UserManagement/ServiceProviderManagement/Edit.tsx
+10
-4
No files found.
src/models/CommunityManagement/CommunityService.ts
View file @
cc314693
...
...
@@ -173,24 +173,24 @@ export default {
yield
put
({
type
:
'returnCurDataDetail'
,
CurDataDetail
});
},
*
ResultClear
({},
{
put
}:
any
)
{
*
ResultClear
({
},
{
put
}:
any
)
{
var
Result
=
null
;
console
.
log
(
'清除'
);
yield
put
({
type
:
'returnResult'
,
Result
});
},
*
DataSaveDetailClear
({},
{
put
}:
any
)
{
*
DataSaveDetailClear
({
},
{
put
}:
any
)
{
console
.
log
(
'清楚数据'
);
let
DataSaveDetail
=
null
;
yield
put
({
type
:
'returnDataSaveDetail'
,
DataSaveDetail
});
},
*
DataSaveClear
({},
{
put
}:
any
)
{
*
DataSaveClear
({
},
{
put
}:
any
)
{
let
DataSave
=
null
;
yield
put
({
type
:
'returnDataSave'
,
DataSave
});
},
*
Data7Clear
({},
{
put
}:
any
)
{
*
Data7Clear
({
},
{
put
}:
any
)
{
let
Data7
=
null
;
yield
put
({
type
:
'returnPage7'
,
Data7
});
},
...
...
src/models/ServiceProvider.ts
View file @
cc314693
import
*
as
service
from
'../services/tos'
;
import
{
message
}
from
'antd'
;
import
{
message
,
Modal
}
from
'antd'
;
export
default
{
namespace
:
'ServiceProvider'
,
...
...
@@ -27,6 +27,7 @@ export default {
return
{
...
state
,
SaveChooseData
};
},
returnCurData
(
state
:
object
,
{
CurData
}:
any
)
{
console
.
log
(
CurData
)
return
{
...
state
,
CurData
};
},
returnResult
(
state
:
object
,
{
Result
}:
any
)
{
...
...
@@ -56,17 +57,46 @@ export default {
console
.
log
(
playload
);
const
resp
=
yield
call
(
service
.
TosTosServiceProviderSave
,
playload
);
console
.
log
(
resp
);
if
(
resp
.
code
==
500
)
{
let
CurData
=
false
;
yield
put
({
type
:
'returnCurData'
},
CurData
);
// 服务范围选择错误
if
(
resp
.
error_code
===
"0002"
)
{
let
CurData
:
Boolean
=
false
;
yield
put
({
type
:
"returnCurData"
,
CurData
});
// message.error("Service scope selection error!!!")
Modal
.
error
({
title
:
'Service scope selection error'
,
content
:
'Accounting service / security service provider is a single option!!!'
,
});
return
;
}
// 小区选择错误
if
(
resp
.
error_code
===
"0003"
)
{
let
CurData
:
Boolean
=
false
;
yield
put
({
type
:
"returnCurData"
,
CurData
});
Modal
.
error
({
title
:
'Community selection error'
,
content
:
'You cannot select a community that already has a scope of service!!!'
,
});
return
;
}
// 提交失败
if
(
resp
.
error_code
===
"0001"
)
{
let
CurData
:
Boolean
=
false
;
yield
put
({
type
:
'returnCurData'
,
CurData
});
message
.
error
(
'Creation failed. Please try again!'
);
// window.location.href = '/500';
}
else
{
let
CurData
=
true
;
yield
put
({
type
:
'returnCurData'
},
CurData
);
return
;
}
// 创建成功
if
(
resp
.
error_code
===
"0000"
)
{
message
.
success
(
'Operator Success!'
,
1.5
,
()
=>
{
window
.
location
.
href
=
'/UserManagement/ServiceProviderManagement'
;
});
let
CurData
:
Boolean
=
true
;
yield
put
({
type
:
'returnCurData'
,
CurData
});
return
;
}
},
...
...
src/pages/CommercialService/Detail.tsx
View file @
cc314693
...
...
@@ -112,8 +112,8 @@ const Detail = (props: any) => {
<
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
label=
"User Name"
span=
{
3
}
>
{
CurDataDetail
.
name
}
</
Descriptions
.
Item
>
<
Descriptions
.
Item
label=
"Contact Details"
>
{
CurDataDetail
.
phone
}
</
Descriptions
.
Item
>
<
Descriptions
.
Item
>
{
CurDataDetail
.
email
}
</
Descriptions
.
Item
>
</
Descriptions
>
<
Row
gutter=
{
16
}
>
...
...
@@ -131,17 +131,19 @@ const Detail = (props: any) => {
<
Col
span=
{
3
}
>
Picture:
</
Col
>
<
Col
>
{
CurDataDetail
!=
null
?
(
<
PictureOptionsRow
action=
"/tos/communtiy/service/reply/img"
disabled=
{
true
}
defaultValue=
{
CurDataDetail
.
pictrues
}
// defaultValue=
{
v
.
url
}
value=
{
CurDataDetail
.
pictrues
}
data=
{
{
userToken
:
'token'
,
imageType
:
'tosCommunityImageReply'
,
extends
:
''
,
}
}
//
/>
)
:
null
}
</
Col
>
</
Row
>
...
...
@@ -215,8 +217,8 @@ const Detail = (props: any) => {
</
Spin
>
</>
)
:
(
<></>
)
}
<></>
)
}
</
div
>
);
};
...
...
src/pages/CommercialService/PropertyServices.tsx
View file @
cc314693
...
...
@@ -49,19 +49,19 @@ const PropertyServices = (props: any) => {
// const [readyData, setReadyData] = useState(null);
const
columns
=
[
{
title
:
'Community
Name
'
,
dataIndex
:
'community_name'
},
{
title
:
'
Owner Name
'
,
dataIndex
:
'owner_name'
},
{
title
:
'Community'
,
dataIndex
:
'community_name'
},
{
title
:
'
Requestor
'
,
dataIndex
:
'owner_name'
},
{
title
:
parseInt
(
serviceTypeGobal
)
-
1
===
0
?
'
Replier
'
:
'Content'
,
title
:
parseInt
(
serviceTypeGobal
)
-
1
===
0
?
'
Attended By
'
:
'Content'
,
dataIndex
:
parseInt
(
serviceTypeGobal
)
-
1
===
0
?
'handle_name'
:
'service_content'
,
ellipsis
:
true
,
width
:
400
,
render
:
(
text
:
any
)
=>
<
Space
size=
"middle"
>
{
text
!=
null
?
text
:
'
--
'
}
</
Space
>,
//
width: 400,
render
:
(
text
:
any
)
=>
<
Space
size=
"middle"
>
{
text
!=
null
?
text
:
''
}
</
Space
>,
},
{
title
:
'
Create
Time'
,
title
:
'
Submission
Time'
,
dataIndex
:
'create_time'
,
render
:
(
text
:
any
,
record
:
any
)
=>
(
<
Space
size=
"middle"
>
{
timestampToTime3
(
text
.
time
)
}
</
Space
>
...
...
@@ -93,13 +93,13 @@ const PropertyServices = (props: any) => {
//页面递进
history
.
push
(
location
.
pathname
+
(
value
==
0
?
'/Edit'
:
'/Detail'
)
+
urlEncode
({
serviceType
:
serviceTypeGobal
,
id
:
record
.
id
,
user_id
:
record
.
user_id
,
community_id
:
record
.
community_id
,
}),
(
value
==
0
?
'/Edit'
:
'/Detail'
)
+
urlEncode
({
serviceType
:
serviceTypeGobal
,
id
:
record
.
id
,
user_id
:
record
.
user_id
,
community_id
:
record
.
community_id
,
}),
);
};
...
...
src/pages/UserManagement/ServiceProviderManagement/Edit.tsx
View file @
cc314693
import
React
,
{
useState
,
useEffect
,
useRef
}
from
'react'
;
import
styles
from
'./Edit.less'
;
import
{
Input
,
Button
,
Form
,
Spin
,
Radio
,
message
}
from
'antd'
;
import
{
Input
,
Button
,
Form
,
Spin
,
Radio
,
message
,
Checkbox
}
from
'antd'
;
import
{
connect
,
history
}
from
'umi'
;
...
...
@@ -48,6 +48,11 @@ const Edit = (props: any) => {
optionsList
=
[...
DataServices
.
data
.
rows
];
}
return
()
=>
{
}
},
[
DataServices
]);
// 判断是否有小区列表数据返回
...
...
@@ -88,7 +93,7 @@ const Edit = (props: any) => {
val
.
serviceCommunityList
=
CList
;
val
.
creator
=
'admin'
;
val
.
updater
=
'admin'
;
val
.
serviceScopeList
=
[
val
.
serviceScopeList
]
;
// val.serviceScopeList = val.serviceScopeList
;
if
(
SaveChooseData
)
{
val
.
id
=
SaveChooseData
.
id
;
}
...
...
@@ -157,8 +162,8 @@ const Edit = (props: any) => {
},
]
}
>
{
/* <Checkbox.Group options={options as any} /> */
}
<
Radio
.
Group
options=
{
options
as
any
}
/>
<
Checkbox
.
Group
options=
{
options
as
any
}
/>
{
/* <Radio.Group options={options as any} /> */
}
</
Form
.
Item
>
</
div
>
</
div
>
...
...
@@ -233,6 +238,7 @@ function mapStateToProps(state: any) {
const
{
CurData
,
SaveChooseData
}
=
state
.
ServiceProvider
;
const
{
DataServices
}
=
state
.
User
;
const
{
CommunityList
}
=
state
.
Init
;
console
.
log
(
CurData
)
return
{
CurData
,
SaveChooseData
,
...
...
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