Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gxpt_wechat
Overview
Overview
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
pseer
gxpt_wechat
Commits
7fe0bfe8
Commit
7fe0bfe8
authored
Apr 15, 2024
by
zhangzhen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
功能完善
parent
9a599823
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
88 additions
and
14 deletions
+88
-14
cleanRoom.js
api/cleanRoom.js
+7
-2
store.js
api/store.js
+6
-0
public.css
common/public.css
+6
-0
cleanManage.vue
pages/cleanManage/cleanManage.vue
+43
-5
cleanOrderInfo.vue
pages/cleanOrderInfo/cleanOrderInfo.vue
+0
-0
index.vue
pages/couponList/index.vue
+0
-0
order.vue
pages/order/order.vue
+6
-2
index.vue
pages/useCoupon/index.vue
+20
-5
No files found.
api/cleanRoom.js
View file @
7fe0bfe8
...
...
@@ -35,4 +35,10 @@ export const getStarOrder=()=>{
export
const
cleanList
=
(
data
)
=>
{
let
url
=
`/cleanRecords/myCleanList`
return
http
.
get
(
url
,
data
)
}
\ No newline at end of file
}
//领取全部的待保洁的任务
export
const
getAllByStoreId
=
(
data
)
=>
{
let
url
=
`/cleanRecords/startCleanByStore`
return
http
.
get
(
url
,
data
)
}
api/store.js
View file @
7fe0bfe8
...
...
@@ -36,3 +36,8 @@ export const deviceCtrlAuth=()=>{
let
url
=
`/store/storeListByConsumer`
return
http
.
get
(
url
)
}
export
const
getListByIds
=
(
data
)
=>
{
let
url
=
`/store/queryByStoreIds`
return
http
.
post
(
url
,
data
)
}
\ No newline at end of file
common/public.css
View file @
7fe0bfe8
...
...
@@ -23,4 +23,9 @@
left
:
0
;
width
:
100%
;
height
:
100%
;
}
.flex-row-center
{
display
:
flex
;
flex-direction
:
row
;
align-items
:
center
;
}
\ No newline at end of file
pages/cleanManage/cleanManage.vue
View file @
7fe0bfe8
...
...
@@ -28,7 +28,7 @@
</view>
</view>
<view
v-for=
"(item,index) in list"
:key=
"index"
class=
"card-box"
>
<view
v-for=
"(item,index) in list"
:key=
"index"
class=
"card-box
card-box-item
"
>
<view
class=
"store-info"
>
...
...
@@ -38,8 +38,12 @@
</view>
<view
class=
"flex-col part-right"
>
<view
class=
"flex-between"
>
<text
class=
"text-black text-bold text-xl"
>
{{
item
.
name
}}
</text>
<image
:src=
"assetsPath+'/map_icon.png'"
mode=
"widthFix"
@
tap=
"onNavLocation(item)"
></image>
<text
class=
"text-black text-bold text-lg"
>
{{
item
.
name
}}
</text>
<view
class=
"flex-row-center"
>
<button
v-if=
"item.cleanOrderNum"
class=
"cu-btn bg-pink sm margin-right-sm"
@
tap=
"onGetAllByStoreId(item)"
>
一键领取
</button>
<image
:src=
"assetsPath+'/map_icon.png'"
mode=
"widthFix"
@
tap=
"onNavLocation(item)"
></image>
</view>
</view>
<view
class=
"flex-row"
>
<image
:src=
"assetsPath+'/location_icon.png'"
mode=
"widthFix"
></image>
...
...
@@ -93,7 +97,7 @@
</
template
>
<
script
>
import
{
getListStore
,
getStarOrder
}
from
"@/api/cleanRoom.js"
;
import
{
getListStore
,
getStarOrder
,
getAllByStoreId
}
from
"@/api/cleanRoom.js"
;
import
config
from
"@/config/index.config"
import
{
getDictItem
...
...
@@ -189,8 +193,15 @@ import moment from "@/common/moment";
if
(
res
.
data
.
code
===
200
){
let
list
=
res
.
data
.
data
&&
res
.
data
.
data
.
length
?
res
.
data
.
data
:[];
this
.
list
=
list
.
map
(
item
=>
{
let
cleanOrderNum
=
0
item
.
roolList
.
forEach
(
room
=>
{
if
(
room
.
recordsStatus
===
0
){
cleanOrderNum
+=
1
}
})
return
{
...
item
,
cleanOrderNum
:
cleanOrderNum
,
roolList
:
item
.
roolList
&&
item
.
roolList
.
length
?
item
.
roolList
.
map
(
val
=>
{
return
{
...
val
,
...
...
@@ -247,11 +258,31 @@ import moment from "@/common/moment";
url
:
"/pages/cleanOrderInfo/cleanOrderInfo?id="
+
val
.
recordsId
})
}
},
onGetAllByStoreId
(
val
){
uni
.
showLoading
(
"领取中..."
)
getAllByStoreId
({
storeId
:
val
.
id
}).
then
(
res
=>
{
uni
.
hideLoading
()
if
(
res
.
data
.
code
==
200
){
uni
.
showToast
({
icon
:
"none"
,
title
:
"操作成功"
})
this
.
onLoading
();
}
console
.
log
(
res
,
9999
)
})
}
}
}
</
script
>
<
style
>
page
{
background
:
#f1f1f1
;
}
</
style
>
<
style
lang=
"scss"
>
.clean-manage
{
display
:
flex
;
...
...
@@ -265,6 +296,13 @@ import moment from "@/common/moment";
width
:
94%
;
margin-top
:
10
upx
;
}
.card-box-item
{
width
:
100%
;
background-color
:
#ffffff
;
padding
:
20
upx
3%
;
border-radius
:
4
upx
;
margin-top
:
24
upx
;
}
.title-box
{
display
:
flex
;
flex-direction
:
row
;
...
...
pages/cleanOrderInfo/cleanOrderInfo.vue
View file @
7fe0bfe8
This diff is collapsed.
Click to expand it.
pages/couponList/index.vue
View file @
7fe0bfe8
This diff is collapsed.
Click to expand it.
pages/order/order.vue
View file @
7fe0bfe8
...
...
@@ -211,7 +211,7 @@
<view
class=
"flex-between price use-coupon-box"
>
<text
class=
"text-black text-left"
>
{{
useCouponList
[
selectCouponIndex
].
couponType
==
2
?
'团购券'
:
'优惠券'
}}
</text>
<view
class=
"flex-row"
@
tap=
"onNavToSelectCoupon"
>
<view
class=
"flex-
1 flex-
row"
@
tap=
"onNavToSelectCoupon"
>
<text
class=
""
:class=
"useCouponList.length?'text-pink':'text-gray'"
>
{{
useCouponList
.
length
&&
selectCouponIndex
>=
0
?
useCouponList
[
selectCouponIndex
].
name
:
couponList
.
length
?
'请选择'
:
'暂无可用'
}}
</text>
<text
class=
"cuIcon-right "
:class=
"useCouponList.length?'text-pink':'text-gray'"
></text>
...
...
@@ -2092,7 +2092,11 @@
.use-coupon-box
{
.flex-row
{
max-width
:
70%
;
display
:
flex
;
justify-content
:
space-between
;
align-items
:
center
;
//
max-width
:
70%
;
margin-left
:
12
upx
;
}
}
...
...
pages/useCoupon/index.vue
View file @
7fe0bfe8
...
...
@@ -34,7 +34,13 @@
</view>
<view
class=
"part-left"
>
<view
class=
"select-btn"
:class=
"
{active: selectId === item.id }">
<view
class=
"surplus-days"
>
<view
v-if=
"item.surplusDays>=0"
class=
"flex-row-center"
>
<text
class=
"cuIcon-countdown text-red"
></text>
<text
class=
"text-red"
>
{{
item
.
surplusDays
}}
天后过期
</text>
</view>
</view>
<view
class=
"select-btn margin-top-sm"
:class=
"
{active: selectId === item.id }">
<radio-group
v-if=
"item.isAvailable != 1"
class=
"radio-group"
>
<radio
class=
'brown'
:class=
"selectId === item.id?'checked':''"
:checked=
"selectId === item.id?true:false"
color=
"#AF7117"
></radio>
</radio-group>
...
...
@@ -62,6 +68,7 @@
</
template
>
<
script
>
import
moment
from
"@/common/moment.js"
import
{
dictList
}
from
"@/api/index.js"
;
import
{
getDictItem
}
from
"@/utils/tools.js"
import
config
from
"@/config/index.config"
...
...
@@ -131,9 +138,14 @@
if
(
res
.
statusCode
==
200
)
{
if
(
res
.
data
&&
res
.
data
.
data
.
length
)
{
let
list
=
res
.
data
.
data
.
map
(
item
=>
{
let
endTime
=
moment
(
item
.
endDate
).
valueOf
();
let
nowTime
=
moment
().
valueOf
();
let
surplusDays
=
parseInt
(
moment
.
duration
(
endTime
-
nowTime
).
asDays
())
return
{
...
item
,
subPrice
:
item
.
subPrice
||
0
subPrice
:
item
.
subPrice
||
0
,
surplusDays
:
surplusDays
<=
30
?
surplusDays
:
-
10000
}
})
...
...
@@ -210,7 +222,10 @@
}
.part-left
{
display
:
flex
;
flex-direction
:
row
;
flex-direction
:
column
;
.surplus-days{
height
:
40
upx
;
}
.select-btn
{
display
:
flex
;
flex-direction
:
row
;
...
...
@@ -265,9 +280,9 @@
filter
:
grayscale
(
100%
);
.select-btn{
background
:
#ffffff
!important
;
height
:
32
px
!important
;
height
:
26
px
!important
;
border-radius
:
16px
!important
;
padding
:
12
upx
24
upx
!important
;
padding
:
0
12
upx
!important
;
text{
color
:
#929292
!important
;
}
...
...
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