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
2eb42250
Commit
2eb42250
authored
Feb 26, 2021
by
cellee
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Signed-off-by: cellee <893264950@qq.com>
parent
d9d0e084
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
18 additions
and
28 deletions
+18
-28
index.jsx
src/components/SelectOptions/index.jsx
+0
-1
TitleSearch.tsx
src/components/TitleSearch/TitleSearch.tsx
+11
-10
FacilityBookings.tsx
...CommunityManagement/FacilityBookings/FacilityBookings.tsx
+7
-17
No files found.
src/components/SelectOptions/index.jsx
View file @
2eb42250
...
@@ -173,7 +173,6 @@ class SelectOptions extends React.PureComponent {
...
@@ -173,7 +173,6 @@ class SelectOptions extends React.PureComponent {
};
};
// 多选框改变的回调
// 多选框改变的回调
onChangeValue
=
(
checkedList
)
=>
{
onChangeValue
=
(
checkedList
)
=>
{
// console.log(checkedList);
if
(
this
.
props
.
single
!=
null
)
{
if
(
this
.
props
.
single
!=
null
)
{
var
tmp
;
var
tmp
;
if
(
checkedList
.
length
>
1
)
{
if
(
checkedList
.
length
>
1
)
{
...
...
src/components/TitleSearch/TitleSearch.tsx
View file @
2eb42250
...
@@ -27,6 +27,8 @@ const TitleSearch = (props: any) => {
...
@@ -27,6 +27,8 @@ const TitleSearch = (props: any) => {
push
,
push
,
}
=
props
;
}
=
props
;
// console.log(props);
const
key
=
props
.
listkey
;
const
key
=
props
.
listkey
;
const
name
=
props
.
list
;
const
name
=
props
.
list
;
...
@@ -48,9 +50,6 @@ const TitleSearch = (props: any) => {
...
@@ -48,9 +50,6 @@ const TitleSearch = (props: any) => {
// console.log("小区数量初始化") OK
// console.log("小区数量初始化") OK
tosCommunityget
(
null
);
tosCommunityget
(
null
);
}
}
if
(
defaultValue
!=
null
)
{
form
.
setFieldsValue
(
defaultValue
);
}
},
[]);
},
[]);
useEffect
(()
=>
{
useEffect
(()
=>
{
...
@@ -81,7 +80,6 @@ const TitleSearch = (props: any) => {
...
@@ -81,7 +80,6 @@ const TitleSearch = (props: any) => {
// 监听 time
// 监听 time
useEffect
(()
=>
{
useEffect
(()
=>
{
if
(
time
)
{
if
(
time
)
{
// console.log(time);
form
.
setFieldsValue
({
form
.
setFieldsValue
({
subscribeDate
:
time
[
2
],
subscribeDate
:
time
[
2
],
});
});
...
@@ -89,21 +87,25 @@ const TitleSearch = (props: any) => {
...
@@ -89,21 +87,25 @@ const TitleSearch = (props: any) => {
},
[
time
]);
},
[
time
]);
const
onFinish
=
(
values
:
any
)
=>
{
const
onFinish
=
(
values
:
any
)
=>
{
// console.log(values);
if
(
datePicker
)
{
if
(
datePicker
)
{
values
[
time
[
0
]]
=
datePicker
;
values
[
time
[
0
]]
=
datePicker
;
}
}
if
(
community
)
{
if
(
community
)
{
values
[
community
]
=
communitys
;
values
[
community
]
=
communitys
;
}
}
if
(
time
)
{
values
.
subscribeDate
=
time
[
2
];
}
// console.log(values);
props
.
onSubmit
(
values
);
props
.
onSubmit
(
values
);
};
};
const
onFinishFailed
=
()
=>
{};
const
onFinishFailed
=
()
=>
{};
// 选择时间
// 选择时间
const
onChange
=
(
date
:
any
,
dateString
:
string
)
=>
{
const
onChanges
=
(
date
:
any
,
dateString
:
string
)
=>
{
console
.
log
(
dateString
);
// console.log(dateString);
time
[
2
]
=
dateString
;
setDate
(
dateString
);
setDate
(
dateString
);
};
};
...
@@ -201,11 +203,10 @@ const TitleSearch = (props: any) => {
...
@@ -201,11 +203,10 @@ const TitleSearch = (props: any) => {
{
/* 时间 */
}
{
/* 时间 */
}
{
time
!=
null
?
(
{
time
!=
null
?
(
<
Col
key=
"datePicker_"
>
<
Col
key=
"datePicker_"
>
{
' '
}
<
DatePicker
<
DatePicker
placeholder=
{
time
[
1
]
}
placeholder=
{
time
[
1
]
}
defaultV
alue=
{
time
[
2
]
?
moment
(
time
[
2
],
'YYYY/MM/DD'
)
:
null
}
v
alue=
{
time
[
2
]
?
moment
(
time
[
2
],
'YYYY/MM/DD'
)
:
null
}
onChange=
{
onChange
}
onChange=
{
onChange
s
}
/>
/>
</
Col
>
</
Col
>
)
:
null
}
)
:
null
}
...
...
src/pages/CommunityManagement/FacilityBookings/FacilityBookings.tsx
View file @
2eb42250
...
@@ -216,6 +216,7 @@ const FacilityBookings = (props: any) => {
...
@@ -216,6 +216,7 @@ const FacilityBookings = (props: any) => {
pageNum
:
search
.
pageNum
?
search
.
pageNum
:
1
,
// 实际搜索页码
pageNum
:
search
.
pageNum
?
search
.
pageNum
:
1
,
// 实际搜索页码
globalMark
:
search
.
globalMark
?
search
.
globalMark
:
'no'
,
// 搜索全部内容
globalMark
:
search
.
globalMark
?
search
.
globalMark
:
'no'
,
// 搜索全部内容
};
};
// console.log(obj);
requse
(
obj
,
tab
);
requse
(
obj
,
tab
);
}
else
{
}
else
{
let
obj
=
{
let
obj
=
{
...
@@ -229,20 +230,16 @@ const FacilityBookings = (props: any) => {
...
@@ -229,20 +230,16 @@ const FacilityBookings = (props: any) => {
// 发起搜索
// 发起搜索
const
CallBackTitleSearch
=
(
comment
:
any
)
=>
{
const
CallBackTitleSearch
=
(
comment
:
any
)
=>
{
// console.log(comment);
if
(
tab
==
1
)
{
if
(
tab
==
1
)
{
if
(
if
(
comment
.
communityName
&&
comment
.
communityName
!=
null
||
comment
.
communityName
.
length
==
0
&&
comment
.
subscribeDate
!=
null
||
comment
.
status
==
null
&&
comment
.
status
!=
null
comment
.
key
==
null
)
{
)
{
message
.
warning
(
'Please fill in at least one condition'
);
return
false
;
}
if
(
comment
.
communityName
!=
null
||
comment
.
key
!=
null
||
comment
.
status
!=
null
)
{
let
obj
=
{
let
obj
=
{
communityNameList
:
comment
.
communityName
?
comment
.
communityName
:
null
,
// 所选小区
communityNameList
:
comment
.
communityName
?
comment
.
communityName
:
null
,
// 所选小区
subscribeDate
:
comment
.
key
?
comment
.
key
:
null
,
// 时间
subscribeDate
:
comment
.
subscribeDate
?
comment
.
subscribeDate
:
null
,
// 时间
status
:
comment
.
status
!==
null
?
comment
.
status
:
null
,
// 状态
status
:
comment
.
status
!==
null
?
comment
.
status
:
null
,
// 状态
pageNum
:
1
,
// 实际搜索页码
pageNum
:
1
,
// 实际搜索页码
globalMark
:
'no'
,
// 搜索全部内容
globalMark
:
'no'
,
// 搜索全部内容
...
@@ -250,14 +247,6 @@ const FacilityBookings = (props: any) => {
...
@@ -250,14 +247,6 @@ const FacilityBookings = (props: any) => {
requse
(
obj
,
tab
);
requse
(
obj
,
tab
);
}
}
}
else
{
}
else
{
if
(
comment
.
communityName2
&&
comment
.
communityName2
.
length
==
0
&&
comment
.
facilityName
==
''
)
{
message
.
warning
(
'Please fill in at least one condition'
);
return
false
;
}
if
(
comment
.
communityName2
!=
null
||
comment
.
facilityName
!=
null
)
{
if
(
comment
.
communityName2
!=
null
||
comment
.
facilityName
!=
null
)
{
let
obj
=
{
let
obj
=
{
communityNameList
:
comment
.
communityName2
?
comment
.
communityName2
:
null
,
communityNameList
:
comment
.
communityName2
?
comment
.
communityName2
:
null
,
...
@@ -327,6 +316,7 @@ const FacilityBookings = (props: any) => {
...
@@ -327,6 +316,7 @@ const FacilityBookings = (props: any) => {
status
:
v
.
status
!==
null
?
v
.
status
:
null
,
status
:
v
.
status
!==
null
?
v
.
status
:
null
,
globalMark
:
v
.
globalMark
?
v
.
globalMark
:
'yes'
,
globalMark
:
v
.
globalMark
?
v
.
globalMark
:
'yes'
,
};
};
// console.log(obj);
QA
({
...
obj
});
QA
({
...
obj
});
RA
(
9
,
{
...
obj
});
RA
(
9
,
{
...
obj
});
}
else
{
}
else
{
...
...
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