Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gxpt_ht
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_ht
Commits
0bd62cdc
Commit
0bd62cdc
authored
Dec 04, 2023
by
吕明尚
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改订单管理页面
parent
16352cdc
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
34 additions
and
2 deletions
+34
-2
PackController.java
...main/java/share/web/controller/system/PackController.java
+1
-1
SRoomController.java
...ain/java/share/web/controller/system/SRoomController.java
+8
-0
OrderTask.java
share-quartz/src/main/java/share/quartz/task/OrderTask.java
+6
-1
ISRoomService.java
...tem/src/main/java/share/system/service/ISRoomService.java
+3
-0
SRoomServiceImpl.java
...main/java/share/system/service/impl/SRoomServiceImpl.java
+16
-0
No files found.
share-admin/src/main/java/share/web/controller/system/PackController.java
View file @
0bd62cdc
...
@@ -49,7 +49,7 @@ public class PackController extends BaseController {
...
@@ -49,7 +49,7 @@ public class PackController extends BaseController {
/**
/**
* 查询套餐列表
* 查询套餐列表
*/
*/
@PreAuthorize
(
"@ss.hasPermi('system:pack:list')"
)
//
@PreAuthorize("@ss.hasPermi('system:pack:list')")
@GetMapping
(
"/query"
)
@GetMapping
(
"/query"
)
public
R
<
List
<
SPack
>>
query
()
{
public
R
<
List
<
SPack
>>
query
()
{
return
R
.
ok
(
packService
.
selectPackList
(
new
SPack
()));
return
R
.
ok
(
packService
.
selectPackList
(
new
SPack
()));
...
...
share-admin/src/main/java/share/web/controller/system/SRoomController.java
View file @
0bd62cdc
...
@@ -49,6 +49,14 @@ public class SRoomController extends BaseController
...
@@ -49,6 +49,14 @@ public class SRoomController extends BaseController
}
}
/**
/**
* 查询房间列表
*/
@GetMapping
(
"/query"
)
public
AjaxResult
query
()
{
return
success
(
sRoomService
.
queryRoomList
());
}
/**
* 导出房间列表
* 导出房间列表
*/
*/
@PreAuthorize
(
"@ss.hasPermi('system:room:export')"
)
@PreAuthorize
(
"@ss.hasPermi('system:room:export')"
)
...
...
share-quartz/src/main/java/share/quartz/task/OrderTask.java
View file @
0bd62cdc
...
@@ -6,6 +6,7 @@ import cn.hutool.core.date.DateUnit;
...
@@ -6,6 +6,7 @@ import cn.hutool.core.date.DateUnit;
import
cn.hutool.core.util.ObjectUtil
;
import
cn.hutool.core.util.ObjectUtil
;
import
cn.hutool.core.util.StrUtil
;
import
cn.hutool.core.util.StrUtil
;
import
cn.hutool.json.JSONObject
;
import
cn.hutool.json.JSONObject
;
import
lombok.extern.slf4j.Slf4j
;
import
org.slf4j.Logger
;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
import
org.slf4j.LoggerFactory
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
@@ -236,7 +237,6 @@ public class OrderTask {
...
@@ -236,7 +237,6 @@ public class OrderTask {
}
}
if
(
expirationTime
.
getTime
()
<
new
Date
().
getTime
())
{
if
(
expirationTime
.
getTime
()
<
new
Date
().
getTime
())
{
sOrders
.
add
(
orderService
.
getByOrderNo
(
String
.
valueOf
(
orderNo
)));
sOrders
.
add
(
orderService
.
getByOrderNo
(
String
.
valueOf
(
orderNo
)));
redisUtil
.
delete
(
String
.
valueOf
(
o
));
}
}
});
});
if
(
CollectionUtils
.
isEmpty
(
sOrders
))
{
if
(
CollectionUtils
.
isEmpty
(
sOrders
))
{
...
@@ -264,10 +264,15 @@ public class OrderTask {
...
@@ -264,10 +264,15 @@ public class OrderTask {
room
.
setUpdateTime
(
new
Date
());
room
.
setUpdateTime
(
new
Date
());
}
}
});
});
logger
.
info
(
"开始发送消息!!!!"
);
//推送订单开始预定消息
//推送订单开始预定消息
wechatNewService
.
sendMiniSubscribeMessage
(
item
,
MessageReminderEnum
.
START
);
wechatNewService
.
sendMiniSubscribeMessage
(
item
,
MessageReminderEnum
.
START
);
logger
.
info
(
"发送消息结束!!!!"
);
logger
.
info
(
"开始通电!!!!"
);
//到达预定时间进行通电
//到达预定时间进行通电
deviceOpService
.
openOrCloseDevice
(
item
.
getRoomId
(),
item
.
getConsumerPhone
(),
OpTypeEnum
.
GET_ELECTRIC
.
getCode
(),
false
,
ZERO
);
deviceOpService
.
openOrCloseDevice
(
item
.
getRoomId
(),
item
.
getConsumerPhone
(),
OpTypeEnum
.
GET_ELECTRIC
.
getCode
(),
false
,
ZERO
);
logger
.
info
(
"通电完成!!!!"
);
redisUtil
.
delete
(
ReceiptRdeisEnum
.
ORDER_NO
.
getValue
()
+
item
.
getOrderNo
());
}
}
});
});
Boolean
execute
=
transactionTemplate
.
execute
(
e
->
{
Boolean
execute
=
transactionTemplate
.
execute
(
e
->
{
...
...
share-system/src/main/java/share/system/service/ISRoomService.java
View file @
0bd62cdc
package
share
.
system
.
service
;
package
share
.
system
.
service
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Map
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
share.system.domain.Device
;
import
share.system.domain.Device
;
...
@@ -102,4 +103,6 @@ public interface ISRoomService extends IService<SRoom>
...
@@ -102,4 +103,6 @@ public interface ISRoomService extends IService<SRoom>
int
addRoomDevice
(
Long
roomId
,
String
[]
devIds
);
int
addRoomDevice
(
Long
roomId
,
String
[]
devIds
);
int
deleteRoomDevice
(
Device
device
);
int
deleteRoomDevice
(
Device
device
);
List
<
Map
>
queryRoomList
();
}
}
share-system/src/main/java/share/system/service/impl/SRoomServiceImpl.java
View file @
0bd62cdc
...
@@ -330,6 +330,22 @@ public class SRoomServiceImpl extends ServiceImpl<SRoomMapper, SRoom> implements
...
@@ -330,6 +330,22 @@ public class SRoomServiceImpl extends ServiceImpl<SRoomMapper, SRoom> implements
return
deviceMapper
.
clearDeviceRoomId
(
device
);
return
deviceMapper
.
clearDeviceRoomId
(
device
);
}
}
@Override
public
List
<
Map
>
queryRoomList
()
{
List
<
SRoom
>
roomList
=
sRoomMapper
.
selectSRoomList
(
new
SRoom
());
List
<
Map
>
result
=
new
ArrayList
<>();
if
(
CollectionUtils
.
isNotEmpty
(
roomList
))
{
result
=
roomList
.
stream
().
map
(
store
->
{
Map
<
String
,
Object
>
map
=
new
HashMap
<
String
,
Object
>()
{{
put
(
"id"
,
store
.
getId
());
put
(
"name"
,
store
.
getName
());
}};
return
map
;
}).
collect
(
Collectors
.
toList
());
}
return
result
;
}
private
List
<
SRoomVo
>
convertDoListToVoList
(
List
<
SRoom
>
roomList
)
{
private
List
<
SRoomVo
>
convertDoListToVoList
(
List
<
SRoom
>
roomList
)
{
List
<
SRoomVo
>
voList
=
new
ArrayList
<>();
List
<
SRoomVo
>
voList
=
new
ArrayList
<>();
...
...
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