完善部署配置

This commit is contained in:
subaixi 2024-12-23 16:34:40 +08:00
parent 4bd9370f34
commit 2555257027
3 changed files with 41 additions and 5 deletions

View File

@ -13,6 +13,7 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController; import org.springframework.web.bind.annotation.RestController;
import java.time.LocalDateTime; import java.time.LocalDateTime;
import java.time.LocalTime; import java.time.LocalTime;
@ -30,47 +31,53 @@ public class WorkSpaceController {
/** /**
* 工作台今日数据查询 * 工作台今日数据查询
*
* @return * @return
*/ */
@GetMapping("/businessData") @GetMapping("/businessData")
@ApiOperation("工作台今日数据查询") @ApiOperation("工作台今日数据查询")
public Result<BusinessDataVO> businessData(){ public Result<BusinessDataVO> businessData() {
//获得当天的开始时间 //获得当天的开始时间
LocalDateTime begin = LocalDateTime.now().with(LocalTime.MIN); LocalDateTime begin = LocalDateTime.now().with(LocalTime.MIN);
//获得当天的结束时间 //获得当天的结束时间
LocalDateTime end = LocalDateTime.now().with(LocalTime.MAX); LocalDateTime end = LocalDateTime.now().with(LocalTime.MAX);
BusinessDataVO businessDataVO = workspaceService.getBusinessData(begin, end); BusinessDataVO businessDataVO = workspaceService.getBusinessData(begin, end);
return Result.success(businessDataVO); return Result.success(businessDataVO);
} }
/** /**
* 查询订单管理数据 * 查询订单管理数据
*
* @return * @return
*/ */
@GetMapping("/overviewOrders") @GetMapping("/overviewOrders")
@ApiOperation("查询订单管理数据") @ApiOperation("查询订单管理数据")
public Result<OrderOverViewVO> orderOverView(){ public Result<OrderOverViewVO> orderOverView() {
return Result.success(workspaceService.getOrderOverView()); return Result.success(workspaceService.getOrderOverView());
} }
/** /**
* 查询菜品总览 * 查询菜品总览
*
* @return * @return
*/ */
@GetMapping("/overviewDishes") @GetMapping("/overviewDishes")
@ApiOperation("查询菜品总览") @ApiOperation("查询菜品总览")
public Result<DishOverViewVO> dishOverView(){ public Result<DishOverViewVO> dishOverView() {
return Result.success(workspaceService.getDishOverView()); return Result.success(workspaceService.getDishOverView());
} }
/** /**
* 查询套餐总览 * 查询套餐总览
*
* @return * @return
*/ */
@GetMapping("/overviewSetmeals") @GetMapping("/overviewSetmeals")
@ApiOperation("查询套餐总览") @ApiOperation("查询套餐总览")
public Result<SetmealOverViewVO> setmealOverView(){ public Result<SetmealOverViewVO> setmealOverView() {
return Result.success(workspaceService.getSetmealOverView()); return Result.success(workspaceService.getSetmealOverView());
} }
} }

View File

@ -0,0 +1,28 @@
sky:
datasource:
driver-class-name: com.mysql.cj.jdbc.Driver
host: ${DB_HOST}
port: ${DB_PORT}
database: ${DB_NAME}
username: ${DB_USERNAME}
password: ${DB_PASSWORD}
alioss:
access-key-id: LTAI5tAggPBTvvugwGhD3onk
access-key-secret: YyUv8YJZjHStekVVoh8ilpCevL2NY4
endpoint: oss-cn-guangzhou.aliyuncs.com
bucket-name: sky-take-out-1919810
redis:
host: ${REDIS_HOST}
port: ${REDIS_PORT}
database: ${REDIS_DATABASE}
password: ${REDIS_PASSWORD}
wechat:
appid: wx34fbbbace9943d4a
secret: 3e5f899be36fa508bb41dc5611bff0c7
mchid: 1561414331
mchSerialNo: 4B3B3DC35414AD50B1B755BAF8DE9CC7CF407606
privateKeyFilePath: D:\apiclient_key.pem
apiV3Key: CZBK51236435wxpay435434323FFDuv3
weChatPayCertFilePath: D:\wechatpay_166D96F876F45C7D07CE98952A96EC980368ACFC.pem
notifyUrl: https://www.weixin.qq.com/wxpay/pay.php
refundNotifyUrl: https://www.weixin.qq.com/wxpay/pay.php

View File

@ -16,6 +16,7 @@ spring:
host: ${sky.redis.host} host: ${sky.redis.host}
port: ${sky.redis.port} port: ${sky.redis.port}
database: ${sky.redis.database} database: ${sky.redis.database}
# password: ${sky.redis.password}
mybatis: mybatis:
#mapper配置文件 #mapper配置文件
@ -45,7 +46,7 @@ sky:
# 用户端jwt签名加密时使用的秘钥 # 用户端jwt签名加密时使用的秘钥
user-secret-key: itheima user-secret-key: itheima
# 用户端jwt过期时间 # 用户端jwt过期时间
# user-ttl: 7200000 # user-ttl: 7200000
user-ttl: 720000000 user-ttl: 720000000
# 用户端前端传递过来的令牌名称 # 用户端前端传递过来的令牌名称
user-token-name: authentication user-token-name: authentication