26 changed files with 343 additions and 13 deletions
@ -0,0 +1,30 @@ |
|||||
|
package com.yxt.yyth.api.lpkreserveorder; |
||||
|
|
||||
|
import com.fasterxml.jackson.annotation.JsonFormat; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
import java.util.UUID; |
||||
|
|
||||
|
/** |
||||
|
* @author wangpengfei |
||||
|
* @date 2023/11/23 10:29 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class LpkReserveOrder{ |
||||
|
private String id; |
||||
|
private String sid= UUID.randomUUID().toString(); |
||||
|
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") |
||||
|
private String createTime; |
||||
|
private String remarks; |
||||
|
private String reserveType; |
||||
|
private String cardSid; |
||||
|
private String cardCode; |
||||
|
private String isCustomer; |
||||
|
private String customerSid; |
||||
|
private String userName; |
||||
|
private String userPhone; |
||||
|
private String userAddress; |
||||
|
private String storeSid; |
||||
|
private String reserveDate; |
||||
|
|
||||
|
} |
@ -0,0 +1,8 @@ |
|||||
|
package com.yxt.yyth.api.lpkreserveorder; |
||||
|
|
||||
|
/** |
||||
|
* @author wangpengfei |
||||
|
* @date 2023/11/23 10:29 |
||||
|
*/ |
||||
|
public class LpkReserveOrderDto { |
||||
|
} |
@ -0,0 +1,8 @@ |
|||||
|
package com.yxt.yyth.api.lpkreserveorder; |
||||
|
|
||||
|
/** |
||||
|
* @author wangpengfei |
||||
|
* @date 2023/11/23 10:30 |
||||
|
*/ |
||||
|
public class LpkReserveOrderQuery { |
||||
|
} |
@ -0,0 +1,23 @@ |
|||||
|
package com.yxt.yyth.api.lpkreserveordergoods; |
||||
|
|
||||
|
import com.fasterxml.jackson.annotation.JsonFormat; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
import java.util.UUID; |
||||
|
|
||||
|
/** |
||||
|
* @author wangpengfei |
||||
|
* @date 2023/11/23 10:29 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class LpkReserveOrderGoods { |
||||
|
private String id; |
||||
|
private String sid= UUID.randomUUID().toString(); |
||||
|
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") |
||||
|
private String createTime; |
||||
|
private String remarks; |
||||
|
private String cardSid; |
||||
|
private String goodsSid; |
||||
|
private double goodsNumber; |
||||
|
|
||||
|
} |
@ -0,0 +1,8 @@ |
|||||
|
package com.yxt.yyth.api.lpkreserveordergoods; |
||||
|
|
||||
|
/** |
||||
|
* @author wangpengfei |
||||
|
* @date 2023/11/23 10:29 |
||||
|
*/ |
||||
|
public class LpkReserveOrderGoodsDto { |
||||
|
} |
@ -0,0 +1,8 @@ |
|||||
|
package com.yxt.yyth.api.lpkreserveordergoods; |
||||
|
|
||||
|
/** |
||||
|
* @author wangpengfei |
||||
|
* @date 2023/11/23 10:30 |
||||
|
*/ |
||||
|
public class LpkReserveOrderGoodsQuery { |
||||
|
} |
@ -0,0 +1,13 @@ |
|||||
|
package com.yxt.yyth.api.lpkstore; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @author wangpengfei |
||||
|
* @date 2023/11/23 11:53 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class StoreSelect { |
||||
|
private String value; |
||||
|
private String text; |
||||
|
} |
@ -0,0 +1,13 @@ |
|||||
|
package com.yxt.yyth.biz.lpkreserveorder; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.yxt.yyth.api.lpkreserveorder.LpkReserveOrder; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
|
||||
|
/** |
||||
|
* @author wangpengfei |
||||
|
* @date 2023/11/23 10:36 |
||||
|
*/ |
||||
|
@Mapper |
||||
|
public interface LpkReserveOrderMapper extends BaseMapper<LpkReserveOrder> { |
||||
|
} |
@ -0,0 +1,21 @@ |
|||||
|
<?xml version="1.0" encoding="UTF-8" ?> |
||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
||||
|
<mapper namespace="com.yxt.yyth.biz.lpkreserveorder.LpkReserveOrderMapper"> |
||||
|
<!-- <where> ${ew.sqlSegment} </where>--> |
||||
|
<!-- ${ew.customSqlSegment} --> |
||||
|
|
||||
|
<select id="storeListPage" resultType="com.yxt.yyth.api.lpkstore.LpkStoreVo"> |
||||
|
select |
||||
|
sid, |
||||
|
date_format(createTime, '%Y-%m-%d') as createTime, |
||||
|
code, |
||||
|
`name`, |
||||
|
address, |
||||
|
phone, |
||||
|
businessHours |
||||
|
from lpk_store |
||||
|
<where> |
||||
|
${ew.sqlSegment} |
||||
|
</where> |
||||
|
</select> |
||||
|
</mapper> |
@ -0,0 +1,29 @@ |
|||||
|
package com.yxt.yyth.biz.lpkreserveorder; |
||||
|
|
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import io.swagger.annotations.Api; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import io.swagger.annotations.ApiOperation; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.PostMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestMapping; |
||||
|
import org.springframework.web.bind.annotation.RestController; |
||||
|
|
||||
|
/** |
||||
|
* @author wangpengfei |
||||
|
* @date 2023/11/23 10:35 |
||||
|
*/ |
||||
|
@Api(tags = "预约订单信息") |
||||
|
@RestController |
||||
|
@RequestMapping("lpksreservoorder") |
||||
|
public class LpkReserveOrderRest { |
||||
|
@Autowired |
||||
|
LpkReserveOrderService lpkReserveOrderService; |
||||
|
|
||||
|
|
||||
|
@ApiOperation("预约提交") |
||||
|
@PostMapping("/submission") |
||||
|
public ResultBean submission(){ |
||||
|
return lpkReserveOrderService.submission(); |
||||
|
} |
||||
|
} |
@ -0,0 +1,18 @@ |
|||||
|
package com.yxt.yyth.biz.lpkreserveorder; |
||||
|
|
||||
|
import com.yxt.common.base.service.MybatisBaseService; |
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import com.yxt.yyth.api.lpkreserveorder.LpkReserveOrder; |
||||
|
import org.springframework.stereotype.Service; |
||||
|
|
||||
|
/** |
||||
|
* @author wangpengfei |
||||
|
* @date 2023/11/23 10:36 |
||||
|
*/ |
||||
|
@Service |
||||
|
public class LpkReserveOrderService extends MybatisBaseService<LpkReserveOrderMapper, LpkReserveOrder> { |
||||
|
public ResultBean submission(){ |
||||
|
ResultBean rb=new ResultBean(); |
||||
|
return rb.success().setData("1"); |
||||
|
} |
||||
|
} |
@ -0,0 +1,13 @@ |
|||||
|
package com.yxt.yyth.biz.lpkreserveordergoods; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.yxt.yyth.api.lpkreserveordergoods.LpkReserveOrderGoods; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
|
||||
|
/** |
||||
|
* @author wangpengfei |
||||
|
* @date 2023/11/23 10:36 |
||||
|
*/ |
||||
|
@Mapper |
||||
|
public interface LpkReserveOrderGoodsMapper extends BaseMapper<LpkReserveOrderGoods> { |
||||
|
} |
@ -0,0 +1,21 @@ |
|||||
|
<?xml version="1.0" encoding="UTF-8" ?> |
||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
||||
|
<mapper namespace="com.yxt.yyth.biz.lpkreserveordergoods.LpkReserveOrderGoodsMapper"> |
||||
|
<!-- <where> ${ew.sqlSegment} </where>--> |
||||
|
<!-- ${ew.customSqlSegment} --> |
||||
|
|
||||
|
<select id="storeListPage" resultType="com.yxt.yyth.api.lpkstore.LpkStoreVo"> |
||||
|
select |
||||
|
sid, |
||||
|
date_format(createTime, '%Y-%m-%d') as createTime, |
||||
|
code, |
||||
|
`name`, |
||||
|
address, |
||||
|
phone, |
||||
|
businessHours |
||||
|
from lpk_store |
||||
|
<where> |
||||
|
${ew.sqlSegment} |
||||
|
</where> |
||||
|
</select> |
||||
|
</mapper> |
@ -0,0 +1,28 @@ |
|||||
|
package com.yxt.yyth.biz.lpkreserveordergoods; |
||||
|
|
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import io.swagger.annotations.Api; |
||||
|
import io.swagger.annotations.ApiOperation; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.PostMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestMapping; |
||||
|
import org.springframework.web.bind.annotation.RestController; |
||||
|
|
||||
|
/** |
||||
|
* @author wangpengfei |
||||
|
* @date 2023/11/23 10:35 |
||||
|
*/ |
||||
|
@Api(tags = "预约订单信息") |
||||
|
@RestController |
||||
|
@RequestMapping("lpksreservoorder") |
||||
|
public class LpkReserveOrderGoodsRest { |
||||
|
@Autowired |
||||
|
LpkReserveOrderGoodsService lpkReserveOrderGoodsService; |
||||
|
|
||||
|
|
||||
|
// @ApiOperation("预约提交")
|
||||
|
// @PostMapping("/getReserveByCardSid")
|
||||
|
// public ResultBean getReserveByCardSid(String sid){
|
||||
|
// return lpkReserveOrderGoodsService.getReserveByCardSid(sid);
|
||||
|
// }
|
||||
|
} |
@ -0,0 +1,22 @@ |
|||||
|
package com.yxt.yyth.biz.lpkreserveordergoods; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
||||
|
import com.yxt.common.base.service.MybatisBaseService; |
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import com.yxt.yyth.api.lpkreserveordergoods.LpkReserveOrderGoods; |
||||
|
import org.springframework.stereotype.Service; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* @author wangpengfei |
||||
|
* @date 2023/11/23 10:36 |
||||
|
*/ |
||||
|
@Service |
||||
|
public class LpkReserveOrderGoodsService extends MybatisBaseService<LpkReserveOrderGoodsMapper, LpkReserveOrderGoods> { |
||||
|
public ResultBean<LpkReserveOrderGoods> getReserveByCardSid(String carSid,String goodsSid){ |
||||
|
ResultBean rb=new ResultBean(); |
||||
|
LpkReserveOrderGoods goods= baseMapper.selectOne(new QueryWrapper<LpkReserveOrderGoods>().eq("cardSid",carSid).eq("goodsSid",goodsSid)); |
||||
|
return rb.success().setData(goods); |
||||
|
} |
||||
|
} |
Loading…
Reference in new issue