记得上下班打卡 | git大法好,push需谨慎

Commit 9c50d04f authored by jiangxiulong's avatar jiangxiulong

Merge remote-tracking branch 'origin/dev_nft_411' into dev_nft_411

parents 98118fb4 f3f7bc0b
...@@ -205,6 +205,28 @@ public class GoblinRedisConst { ...@@ -205,6 +205,28 @@ public class GoblinRedisConst {
*/ */
public static final String USER_DIGITAL_ARTWORK_GENMARK = PREFIX.concat("u_d_art_gm:"); public static final String USER_DIGITAL_ARTWORK_GENMARK = PREFIX.concat("u_d_art_gm:");
/* ----------------------------------------------------------------- */
/**
* 用户预约标识
* {goblin:user:anticipate:${skuId}:${uid},(goblin_goods_anticipate_user)}
*/
public static final String USER_ANTICIPATE_STATE = PREFIX.concat("user:anticipate:");
/**
* 真实预约人数
* {goblin:anticipate:people:${autId},numPeople}
*/
public static final String ANTICIPATE_PEOPLE = PREFIX.concat("anticipate:people:");
/**
* 记录sku
*/
public static final String ANTICIPATE_SKUID = PREFIX.concat("anticipate:skuId:");
/* ----------------------------------------------------------------- */ /* ----------------------------------------------------------------- */
/* ----------------------------------------------------------------- */ /* ----------------------------------------------------------------- */
} }
package com.liquidnet.service.goblin.dto.manage;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.liquidnet.commons.lang.util.DateUtil;
import com.liquidnet.service.goblin.dto.manage.vo.GoblinGoodsAnticipateValueVo;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import javax.validation.constraints.NotBlank;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.List;
/**
*
* @author liquidnet
* @since 2022-04-07
*/
@ApiModel(value = "GoblinGoodsAnticipateParam", description = "预约")
@Data
public class GoblinGoodsAnticipateAddParam {
/**
* 预约名称
*/
@ApiModelProperty(value = "预约名称")
@NotBlank(message = "预约名称")
private String name;
/**
* 预约规则
*/
@ApiModelProperty(value = "预约规则")
@NotBlank(message = "预约规则")
private String rule;
/**
* 预约人数
*/
@ApiModelProperty(value = "预约人数")
private Long aboutPeople;
/**
* 预约开始时间
*/
@ApiModelProperty(value = "预约开始时间")
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = DateUtil.DATE_FULL_STR)
private LocalDateTime aboutStartDate;
/**
* 预约结束时间
*/
@ApiModelProperty(value = "预约结束时间")
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = DateUtil.DATE_FULL_STR)
private LocalDateTime aboutEndDate;
}
package com.liquidnet.service.goblin.dto.manage;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import javax.validation.constraints.Max;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;
/**
* <p>
* 预约表
* </p>
*
* @author liquidnet
* @since 2022-04-07
*/
@ApiModel(value = "GoblinGoodsAnticipateParam", description = "预约")
@Data
public class GoblinGoodsAnticipateParam{
@ApiModelProperty(position = 11, required = true, value = "当前记录起始索引", example = "1")
@Min(value = 1, message = "起始索引无效")
@NotNull(message = "起始索引无效")
private Integer pageNum;
@ApiModelProperty(position = 12, required = true, value = "每页显示记录数", example = "20")
@Max(value = 100, message = "显示记录数无效")
@NotNull(message = "显示记录数无效")
private Integer pageSize;
/**
* 预约名称
*/
private String name;
}
package com.liquidnet.service.goblin.dto.manage;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import javax.validation.constraints.NotBlank;
import java.time.LocalDateTime;
/**
*
* @author liquidnet
* @since 2022-04-07
*/
@ApiModel(value = "GoblinGoodsAnticipateParam", description = "预约")
@Data
public class GoblinGoodsAnticipateUpdateParam {
@ApiModelProperty(value ="预约id")
@NotBlank(message = "预约id")
private String antId;
/**
* 预约名称
*/
@ApiModelProperty(value = "预约名称")
@NotBlank(message = "预约名称")
private String name;
/**
* 预约规则
*/
@ApiModelProperty(value = "预约规则")
@NotBlank(message = "预约规则")
private String rule;
}
package com.liquidnet.service.goblin.dto.manage;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.io.Serializable;
import java.util.List;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.liquidnet.commons.lang.util.DateUtil;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import javax.validation.constraints.NotBlank;
/**
* <p>
* 预约关联sku和spu表
* </p>
*
* @author liquidnet
* @since 2022-04-08
*/
@Data
public class GoblinGoodsAnticipateValueParam {
private static final long serialVersionUID = 1L;
/**
* antId
*/
@ApiModelProperty(value = "antId")
@NotBlank(message = "antId不能为空")
private String antId;
/**
* sku名称
*/
@ApiModelProperty(value = "sku名称")
@NotBlank(message = "skuName不能为空")
private String skuName;
/**
* sku_id 对应 goblin_goods_sku.sku_id
*/
@ApiModelProperty(value = "sku_id 对应 goblin_goods_sku.sku_id")
@NotBlank(message = "skuId不能为空")
private String skuId;
/**
* spu_id对应 goblin_goods_spu_id
*/
@ApiModelProperty(value = "spu_id对应 goblin_goods_spu_id")
@NotBlank(message = "spuId不能为空")
private String spuId;
/**
* 预约开始时间
*/
@ApiModelProperty(value = "预约开始时间")
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = DateUtil.DATE_FULL_STR)
@NotBlank(message = "预约开始时间不能为空")
private LocalDateTime aboutStartDate;
/**
* 预约结束时间
*/
@ApiModelProperty(value = "预约结束时间")
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = DateUtil.DATE_FULL_STR)
@NotBlank(message = "预约结束时间不能为空")
private LocalDateTime aboutEndDate;
}
package com.liquidnet.service.goblin.dto.manage.vo;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.liquidnet.commons.lang.util.DateUtil;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.time.LocalDateTime;
/**
* <p>
* 预约关联sku和spu表
* </p>
*
* @author liquidnet
* @since 2022-04-08
*/
@Data
public class GoblinGoodsAnticipateValueVo {
private static final long serialVersionUID = 1L;
/**
* antId
*/
@ApiModelProperty(value = "antId")
private String antId;
/**
* sku名称
*/
@ApiModelProperty(value = "sku名称")
private String skuName;
/**
* sku_id 对应 goblin_goods_sku.sku_id
*/
@ApiModelProperty(value = "sku_id 对应 goblin_goods_sku.sku_id")
private String skuId;
/**
* spu_id对应 goblin_goods_spu_id
*/
@ApiModelProperty(value = "spu_id对应 goblin_goods_spu_id")
private String spuId;
/**
* 预约开始时间
*/
@ApiModelProperty(value = "预约开始时间")
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = DateUtil.DATE_FULL_STR)
private LocalDateTime aboutStartDate;
/**
* 预约结束时间
*/
@ApiModelProperty(value = "预约结束时间")
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = DateUtil.DATE_FULL_STR)
private LocalDateTime aboutEndDate;
/**
* 创建时间
*/
@ApiModelProperty(value = "创建时间")
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = DateUtil.DATE_FULL_STR)
private LocalDateTime createdDate;
/**
* 修改时间
*/
@ApiModelProperty(value = "修改时间")
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = DateUtil.DATE_FULL_STR)
private LocalDateTime updateDate;
/**
* 删除(0:未删除1:已删除)
*/
@ApiModelProperty(value = "删除(0:未删除1:已删除)")
private Integer delTag;
}
package com.liquidnet.service.goblin.dto.vo;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import java.io.Serializable;
/**
* @Author: GH
* @Date: 2022/4/10 18:18
* @Description:
*/
@Data
@NoArgsConstructor
public class GoblinGoodAnticipateUserVo implements Serializable {
private static final long serialVersionUID = 1L;
public static final Integer STATE_VALID = 1;
public static final Integer STATE_INVALID = 1;
@ApiModelProperty(value = "uid")
private String uid;
@ApiModelProperty(value = "用户手机号")
private String phone;
@ApiModelProperty(value = "用户预约的skuId")
private String skuId;
@ApiModelProperty(value = "用户状态")
private Integer state;
public GoblinGoodAnticipateUserVo(String uid, String phone, String skuId, Integer state) {
this.uid = uid;
this.phone = phone;
this.skuId = skuId;
this.state = state;
}
}
package com.liquidnet.service.goblin.dto.vo;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.liquidnet.commons.lang.util.DateUtil;
import com.liquidnet.service.goblin.dto.manage.vo.GoblinGoodsAnticipateValueVo;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import javax.validation.constraints.NotBlank;
import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.List;
/**
* <p>
* 预约表
* </p>
*
* @author liquidnet
* @since 2022-04-07
*/
@Data
@EqualsAndHashCode(callSuper = false)
public class GoblinGoodsAnticipateVo implements Serializable {
private static final long serialVersionUID = 1L;
/**
* id
*/
private String id;
/**
* ant_id
*/
private String antId;
/**
* 预约名称
*/
@ApiModelProperty(value = "预约名称")
private String name;
/**
* 预约规则
*/
@ApiModelProperty(value = "预约规则")
private String rule;
/**
* 预约人数
*/
@ApiModelProperty(value = "预约人数")
private Long aboutPeople;
/**
* 预约人数
*/
@ApiModelProperty(value = "实际预约人数")
private Long actualPeople;
/**
* 预约开始时间
*/
@ApiModelProperty(value = "预约开始时间")
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = DateUtil.DATE_FULL_STR)
private LocalDateTime aboutStartDate;
/**
* 预约结束时间
*/
@ApiModelProperty(value = "预约结束时间")
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = DateUtil.DATE_FULL_STR)
private LocalDateTime aboutEndDate;
/**
* 创建时间
*/
@ApiModelProperty(value = "创建时间")
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = DateUtil.DATE_FULL_STR)
private LocalDateTime createdDate;
/**
* 修改时间
*/
@ApiModelProperty(value = "修改时间")
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = DateUtil.DATE_FULL_STR)
private LocalDateTime updateDate;
/**
* 删除(0:未删除1:已删除)
*/
@ApiModelProperty(value = "删除(0:未删除1:已删除)")
private Integer delTag;
@ApiModelProperty(value = "目前三种状态(0:未开始,1:预约中,2:已结束)")
private Integer state;
}
package com.liquidnet.service.goblin.service;
import com.github.pagehelper.PageInfo;
import com.liquidnet.service.base.ResponseDto;
import com.liquidnet.service.goblin.dto.manage.GoblinGoodsAnticipateAddParam;
import com.liquidnet.service.goblin.dto.manage.GoblinGoodsAnticipateParam;
import com.liquidnet.service.goblin.dto.manage.GoblinGoodsAnticipateUpdateParam;
import com.liquidnet.service.goblin.dto.manage.GoblinGoodsAnticipateValueParam;
import com.liquidnet.service.goblin.dto.vo.GoblinGoodsAnticipateVo;
import java.util.List;
/**
* <p>
* 预约表 服务类
* </p>
*
* @author liquidnet
* @since 2022-04-07
*/
public interface IGoblinGoodsAnticipateService{
/**
* 分页获取预约商品列表
* @param goodsAnticipateParam :
* @return :List<GoblinGoodsAnticipateVo>
*/
ResponseDto<PageInfo<GoblinGoodsAnticipateVo>> list(GoblinGoodsAnticipateParam goodsAnticipateParam);
ResponseDto<Object> add(GoblinGoodsAnticipateAddParam goodsAnticipateAddParam);
ResponseDto<Object> update(GoblinGoodsAnticipateUpdateParam goodsAnticipateUpdateParam);
ResponseDto<Object> updatePeople(String antId,Long people);
ResponseDto<Object> delete(String antId);
ResponseDto<Object> getSkus(String spuId);
ResponseDto<Object> userAbout(String antId, String skuId,String uid, String phone,Integer state);
ResponseDto<Object> addAnticipateValues(List<GoblinGoodsAnticipateValueParam> list);
ResponseDto<Object> updateAnticipateValues(List<GoblinGoodsAnticipateValueParam> list);
}
package com.liquidnet.service.goblin.service;
/**
* <p>
* 预约表关联user表 服务类
* </p>
*
* @author liquidnet
* @since 2022-04-07
*/
public interface IGoblinGoodsAnticipateUserService{
}
package com.liquidnet.service.goblin.service;
/**
* <p>
* 预约关联sku和spu表 服务类
* </p>
*
* @author liquidnet
* @since 2022-04-07
*/
public interface IGoblinGoodsAnticipateValueService {
}
...@@ -1060,6 +1060,53 @@ create table goblin_user_coupon ...@@ -1060,6 +1060,53 @@ create table goblin_user_coupon
) engine = InnoDB comment '商城用户券信息'; ) engine = InnoDB comment '商城用户券信息';
create unique index uidx_guc_ucoupon_id on goblin_user_coupon (ucoupon_id); create unique index uidx_guc_ucoupon_id on goblin_user_coupon (ucoupon_id);
# -- >>------------------------------------------------------------------------------------
DROP TABLE IF EXISTS `goblin_goods_anticipate`;
CREATE TABLE `goblin_goods_anticipate` (
`id` bigint NOT NULL AUTO_INCREMENT COMMENT '自增主键id',
`ant_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'ant_id',
`name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '预约名称',
`about_people` bigint NULL DEFAULT 0 COMMENT '预约人数',
`actual_people` bigint NULL DEFAULT 0 COMMENT '实际预约人数',
`about_start_date` datetime NOT NULL COMMENT '预约开始时间',
`about_end_date` datetime NOT NULL COMMENT '预约结束时间',
`created_date` datetime NOT NULL ON UPDATE CURRENT_TIMESTAMP COMMENT '创建时间',
`del_tag` int(1) UNSIGNED ZEROFILL NOT NULL DEFAULT 0 COMMENT '删除(0:未删除1:已删除)',
PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = '预约表' ROW_FORMAT = Dynamic;
create unique index goblin_goods_anticipate on goblin_goods_anticipate (ant_id);
# -- >>------------------------------------------------------------------------------------
DROP TABLE IF EXISTS `goblin_goods_anticipate_value`;
CREATE TABLE `goblin_goods_anticipate_value` (
`id` bigint NOT NULL AUTO_INCREMENT COMMENT '自增主键id',
`ant_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '预约id 对应(goblin_goods_anticipate.id)',
`sku_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'sku名称',
`sku_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'sku_id 对应 goblin_goods_sku.sku_id',
`spu_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'spu_id对应 goblin_goods_spu_id',
`about_start_date` datetime NOT NULL COMMENT '预约开始时间',
`about_end_date` datetime NOT NULL COMMENT '预约结束时间',
`created_date` datetime NOT NULL ON UPDATE CURRENT_TIMESTAMP COMMENT '创建时间',
`update_date` datetime NULL DEFAULT NULL COMMENT '修改时间',
`del_tag` int(1) UNSIGNED ZEROFILL NOT NULL DEFAULT 0 COMMENT '删除(0:未删除1:已删除)',
PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = '预约关联sku和spu表' ROW_FORMAT = Dynamic;
# -- >>------------------------------------------------------------------------------------
DROP TABLE IF EXISTS `goblin_goods_anticipate_user`;
CREATE TABLE `goblin_goods_anticipate_user` (
`id` bigint NOT NULL AUTO_INCREMENT COMMENT '主键id',
`uid` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '用户id',
`phone` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '手机号',
`sku_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'sku_id',
`state` int NOT NULL COMMENT '状态(0:正常(默认))',
PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = '预约表关联user表' ROW_FORMAT = Dynamic;
# -- >>------------------------------------------------------------------------------------ # -- >>------------------------------------------------------------------------------------
# -- >>------------------------------------------------------------------------------------ # -- >>------------------------------------------------------------------------------------
# -- >>------------------------------------------------------------------------------------ # -- >>------------------------------------------------------------------------------------
\ No newline at end of file
package com.liquidnet.service.goblin.controller.manage;
import com.github.pagehelper.PageInfo;
import com.liquidnet.service.base.ResponseDto;
import com.liquidnet.service.goblin.dto.manage.GoblinGoodsAnticipateAddParam;
import com.liquidnet.service.goblin.dto.manage.GoblinGoodsAnticipateParam;
import com.liquidnet.service.goblin.dto.manage.GoblinGoodsAnticipateUpdateParam;
import com.liquidnet.service.goblin.dto.manage.GoblinGoodsAnticipateValueParam;
import com.liquidnet.service.goblin.dto.vo.GoblinGoodsAnticipateVo;
import com.liquidnet.service.goblin.service.IGoblinGoodsAnticipateService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import java.util.List;
/**
* <p>
* 预约表 前端控制器
* </p>
*
* @author liquidnet
* @since 2022-04-07
*/
@Slf4j
@RestController
@Api(tags = "预约相关")
@RequestMapping("/goblin/anticipate")
public class GoblinGoodsAnticipateController {
@Autowired
IGoblinGoodsAnticipateService goblinGoodsAnticipateService;
@ApiOperation("创建预约信息")
@PostMapping("/add")
public ResponseDto<Object> add(@RequestBody GoblinGoodsAnticipateAddParam goodsAnticipateAddParam) {
return goblinGoodsAnticipateService.add(goodsAnticipateAddParam);
}
@PostMapping("/list")
@ApiOperation("获取预约列表")
public ResponseDto<PageInfo<GoblinGoodsAnticipateVo>> list(GoblinGoodsAnticipateParam goodsAnticipateParam) {
return goblinGoodsAnticipateService.list(goodsAnticipateParam);
}
@ApiOperation("修改预约人数")
@PostMapping("/updatePeople")
public ResponseDto<Object> updatePeople(@RequestParam(name = "antId", required = true) String antId, @RequestParam(name = "people", required = true) Long people) {
return goblinGoodsAnticipateService.updatePeople(antId, people);
}
@ApiOperation("修改预约")
@PostMapping("/update")
public ResponseDto<Object> update(GoblinGoodsAnticipateUpdateParam goodsAnticipateUpdateParam) {
return goblinGoodsAnticipateService.update(goodsAnticipateUpdateParam);
}
@ApiOperation("删除预约")
@DeleteMapping("/delete")
public ResponseDto<Object> delete(@RequestParam(name = "antId") String antId) {
return goblinGoodsAnticipateService.delete(antId);
}
@ApiOperation("创建预约关联sku")
@PostMapping("/addAnticipateValues")
public ResponseDto<Object> addAnticipateValues(List<GoblinGoodsAnticipateValueParam> list) {
return goblinGoodsAnticipateService.addAnticipateValues(list);
}
@ApiOperation("修改预约关联")
@PostMapping("/updateAnticipateValues")
public ResponseDto<Object> updateAnticipateValues(List<GoblinGoodsAnticipateValueParam> list ) {
return goblinGoodsAnticipateService.updateAnticipateValues(list);
}
@ApiOperation("用户预约(state预约标识:0为预约,1为取消预约)")
@PostMapping("/userAbout")
public ResponseDto<Object> userAbout(@RequestParam(name = "antId", required = true) String antId,
@RequestParam(name = "skuId", required = true) String skuId,
@RequestParam(name = "uid", required = true) String uid,
@RequestParam(name = "phone", required = true) String phone,
@RequestParam(name = "state", required = true) Integer state) {
return goblinGoodsAnticipateService.userAbout(antId, skuId, uid, phone, state);
}
@ApiOperation("根据spuId查询出所有的sku")
@PostMapping("")
public ResponseDto<Object> getSkus(@RequestParam(name = "apuId") String SpuId) {
return goblinGoodsAnticipateService.getSkus(SpuId);
}
}
package com.liquidnet.service.goblin.service.impl;
import com.github.pagehelper.PageInfo;
import com.liquidnet.commons.lang.util.CollectionUtil;
import com.liquidnet.commons.lang.util.IDGenerator;
import com.liquidnet.service.base.ResponseDto;
import com.liquidnet.service.base.SqlMapping;
import com.liquidnet.service.base.constant.MQConst;
import com.liquidnet.service.goblin.dto.manage.GoblinGoodsAnticipateAddParam;
import com.liquidnet.service.goblin.dto.manage.GoblinGoodsAnticipateParam;
import com.liquidnet.service.goblin.dto.manage.GoblinGoodsAnticipateUpdateParam;
import com.liquidnet.service.goblin.dto.manage.GoblinGoodsAnticipateValueParam;
import com.liquidnet.service.goblin.dto.manage.vo.GoblinGoodsAnticipateValueVo;
import com.liquidnet.service.goblin.dto.vo.GoblinGoodAnticipateUserVo;
import com.liquidnet.service.goblin.dto.vo.GoblinGoodsAnticipateVo;
import com.liquidnet.service.goblin.service.IGoblinGoodsAnticipateService;
import com.liquidnet.service.goblin.util.GoblinMongoUtils;
import com.liquidnet.service.goblin.util.GoblinRedisUtils;
import com.liquidnet.service.goblin.util.QueueUtils;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang.StringUtils;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.time.LocalDateTime;
import java.util.HashMap;
import java.util.LinkedList;
import java.util.List;
/**
* <p>
* 预约表 服务实现类
* </p>
*
* @author liquidnet
* @since 2022-04-07
*/
@Service
@Slf4j
public class GoblinGoodsAnticipateServiceImpl implements IGoblinGoodsAnticipateService {
@Autowired
GoblinMongoUtils goblinMongoUtils;
@Autowired
GoblinRedisUtils goblinRedisUtils;
@Autowired
QueueUtils queueUtils;
@Override
public ResponseDto<PageInfo<GoblinGoodsAnticipateVo>> list(GoblinGoodsAnticipateParam goodsAnticipateParam) {
PageInfo<GoblinGoodsAnticipateVo> pageInfo = new PageInfo<>();
HashMap<String, Object> map = goblinMongoUtils.getGoblinGoodsAnticipateVos(goodsAnticipateParam);
List<GoblinGoodsAnticipateVo> data = (List<GoblinGoodsAnticipateVo>) map.get("data");
for (GoblinGoodsAnticipateVo goblinGoodsAnticipateVo : data) {
//预约开始时间
LocalDateTime aboutStartDate = goblinGoodsAnticipateVo.getAboutStartDate();
LocalDateTime aboutEndDate = goblinGoodsAnticipateVo.getAboutEndDate();
LocalDateTime now = LocalDateTime.now();
if (aboutStartDate.isBefore(now)) {
//未开始 0
goblinGoodsAnticipateVo.setState(0);
}
if (!aboutStartDate.isBefore(now) && aboutEndDate.isAfter(now)) {
//预约中
goblinGoodsAnticipateVo.setState(1);
}
if (aboutEndDate.isBefore(now)) {
//已结束
goblinGoodsAnticipateVo.setState(2);
}
}
pageInfo.setList(data);
pageInfo.setTotal((Long) map.get("total"));
return ResponseDto.success(pageInfo);
}
@Override
public ResponseDto<Object> add(GoblinGoodsAnticipateAddParam goodsAnticipateAddParam) {
if (StringUtils.isNotBlank(goodsAnticipateAddParam.getName())
&& StringUtils.isNotBlank(goodsAnticipateAddParam.getRule())
&& StringUtils.isNotBlank(goodsAnticipateAddParam.getAboutStartDate().toString())
&& StringUtils.isNotBlank(goodsAnticipateAddParam.getAboutEndDate().toString())) {
//生成的antId
String antId = IDGenerator.nextTimeId2();
GoblinGoodsAnticipateVo goodsAnticipateVo = new GoblinGoodsAnticipateVo();
BeanUtils.copyProperties(goodsAnticipateAddParam, goodsAnticipateVo);
goodsAnticipateVo.setAntId(antId);
goodsAnticipateVo.setCreatedDate(LocalDateTime.now());
goodsAnticipateVo.setDelTag(0);
//redis消息预约消息表
LinkedList<Object[]> sqlAnt = CollectionUtil.linkedListObjectArr();
sqlAnt.add(new Object[]{
antId,
goodsAnticipateVo.getName(),
goodsAnticipateVo.getRule(),
goodsAnticipateVo.getAboutPeople(),
goodsAnticipateVo.getAboutStartDate(),
goodsAnticipateVo.getAboutEndDate(),
goodsAnticipateVo.getCreatedDate(),
goodsAnticipateVo.getDelTag()
});
sendRedis("goblin_goods_anticipate", sqlAnt);
//mongodb新增
goblinMongoUtils.setGoblinGoodsAnticipateVo(goodsAnticipateVo);
return ResponseDto.success();
}
return ResponseDto.failure("参数有误");
}
@Override
public ResponseDto<Object> updatePeople(String antId, Long people) {
//修改Mongodb
goblinMongoUtils.updateGoblinGoodsAnticipateVoPeople(antId, people);
//修改mysql
LinkedList<Object[]> sqlValue = CollectionUtil.linkedListObjectArr();
sqlValue.add(new Object[]{
people,
antId
});
sendRedis("goblin_goods_anticipate_update_proper", sqlValue);
return ResponseDto.success();
}
@Override
public ResponseDto<Object> update(GoblinGoodsAnticipateUpdateParam goodsAnticipateUpdateParam) {
//跟新mongodb
goblinMongoUtils.updateGoblinGoodsAnticipateVo(goodsAnticipateUpdateParam);
//修改mysql
LinkedList<Object[]> sqlValue = CollectionUtil.linkedListObjectArr();
sqlValue.add(new Object[]{
goodsAnticipateUpdateParam.getName(),
goodsAnticipateUpdateParam.getRule(),
goodsAnticipateUpdateParam.getAntId()
});
sendRedis("goblin_goods_anticipate_update", sqlValue);
return ResponseDto.success();
}
@Override
public ResponseDto<Object> delete(String antId) {
//mysql删除
LinkedList<Object[]> sqlValue = CollectionUtil.linkedListObjectArr();
sqlValue.add(new Object[]{
antId
});
//预约库删除
sendRedis("goblin_goods_anticipate_delete", sqlValue);
//预约关联库删除
sendRedis("goblin_goods_anticipate_value_delete", sqlValue);
//删除mongodb
if (goblinMongoUtils.delGoodsAnticipateVo(antId)) {
return ResponseDto.success();
}
return ResponseDto.success();
}
@Override
public ResponseDto<Object> getSkus(String spuId) {
return null;
}
@Override
public ResponseDto<Object> userAbout(String antId, String skuId, String uid, String phone, Integer state) {
//查询该用户是否预
GoblinGoodAnticipateUserVo userVo = goblinRedisUtils.getUserAboutAut(skuId, uid);
LinkedList<Object[]> antIdValue = CollectionUtil.linkedListObjectArr();
antIdValue.add(new Object[]{
antId
});
LinkedList<Object[]> sqlValue = CollectionUtil.linkedListObjectArr();
if (state.equals(GoblinGoodAnticipateUserVo.STATE_VALID) && userVo == null) {
//用户没有预约过
//发送redis消息修改mysql记录用户预约
sqlValue.add(new Object[]{
uid,
skuId,
phone,
state
});
sendRedis("goblin_goods_anticipate_user", sqlValue);
GoblinGoodAnticipateUserVo user = new GoblinGoodAnticipateUserVo(uid, skuId, phone, state);
//mongodb记录
goblinRedisUtils.setUserAboutSku(user);
//新增
sendRedis("goblin_goods_anticipate_update_actual_add_people",antIdValue);
} else {
//mysql删除用户记录
sqlValue.add(new Object[]{
uid,
skuId
});
sendRedis("goblin_goods_anticipate_user_update", sqlValue);
//删除缓存 redis和mongodb
goblinRedisUtils.delUserAboutSku(skuId, uid);
sendRedis("goblin_goods_anticipate_update_actual_reduce_people",antIdValue);
}
goblinRedisUtils.setAutId(antId, state);
return ResponseDto.success();
}
@Override
public ResponseDto<Object> addAnticipateValues(List<GoblinGoodsAnticipateValueParam> list) {
if (list != null && list.size() > 0) {
list.forEach(item -> {
GoblinGoodsAnticipateValueVo goodsAnticipateValueVo = new GoblinGoodsAnticipateValueVo();
BeanUtils.copyProperties(item, goodsAnticipateValueVo);
goodsAnticipateValueVo.setCreatedDate(LocalDateTime.now());
goodsAnticipateValueVo.setCreatedDate(LocalDateTime.now());
goodsAnticipateValueVo.setDelTag(0);
//redis消息
//redis标识存入该sku处于预约列表
goblinRedisUtils.setAnticipate(goodsAnticipateValueVo.getSkuId());
//保存mysql中间表
LinkedList<Object[]> sqlValue = CollectionUtil.linkedListObjectArr();
sqlValue.add(new Object[]{
goodsAnticipateValueVo.getAntId(),
goodsAnticipateValueVo.getSkuName(),
goodsAnticipateValueVo.getSkuId(),
goodsAnticipateValueVo.getSpuId(),
goodsAnticipateValueVo.getAboutStartDate(),
goodsAnticipateValueVo.getAboutEndDate(),
goodsAnticipateValueVo.getCreatedDate(),
goodsAnticipateValueVo.getDelTag()
});
sendRedis("goblin_goods_anticipate_value", sqlValue);
//存入mongodb中
goblinMongoUtils.addAnticipateValues(goodsAnticipateValueVo);
});
}
return ResponseDto.success();
}
@Override
public ResponseDto<Object> updateAnticipateValues(List<GoblinGoodsAnticipateValueParam> list) {
if (list != null && list.size() > 0) {
list.forEach(item -> {
GoblinGoodsAnticipateValueVo goodsAnticipateValueVo = new GoblinGoodsAnticipateValueVo();
BeanUtils.copyProperties(item, goodsAnticipateValueVo);
//redis消息
//redis标识存入该sku处于预约列表
goblinRedisUtils.setAnticipate(goodsAnticipateValueVo.getSkuId());
//保存mysql中间表
LinkedList<Object[]> sqlValue = CollectionUtil.linkedListObjectArr();
sqlValue.add(new Object[]{
goodsAnticipateValueVo.getAboutStartDate(),
goodsAnticipateValueVo.getAboutEndDate(),
goodsAnticipateValueVo.getAntId(),
goodsAnticipateValueVo.getSkuId(),
goodsAnticipateValueVo.getSpuId(),
});
sendRedis("goblin_goods_anticipate_value_update", sqlValue);
});
}
return null;
}
public void sendRedis(String sqlKey, LinkedList<Object[]> sqlData) {
LinkedList<String> sql = CollectionUtil.linkedListString();
sql.add(SqlMapping.get(sqlKey));
String sqlStr = SqlMapping.gets(sql, sqlData);
queueUtils.sendMsgByRedis(
MQConst.GoblinQueue.GOBLIN_STORE_MARKET.getKey(),
sqlStr);
}
}
package com.liquidnet.service.goblin.service.impl;
import com.liquidnet.service.goblin.service.IGoblinGoodsAnticipateUserService;
import org.springframework.stereotype.Service;
/**
* <p>
* 预约表关联user表 服务实现类
* </p>
*
* @author liquidnet
* @since 2022-04-07
*/
@Service
public class GoblinGoodsAnticipateUserServiceImpl implements IGoblinGoodsAnticipateUserService {
}
package com.liquidnet.service.goblin.service.impl;
import com.liquidnet.service.goblin.service.IGoblinGoodsAnticipateValueService;
import org.springframework.stereotype.Service;
/**
* <p>
* 预约关联sku和spu表 服务实现类
* </p>
*
* @author liquidnet
* @since 2022-04-07
*/
@Service
public class GoblinGoodsAnticipateValueServiceImpl implements IGoblinGoodsAnticipateValueService {
}
...@@ -4,9 +4,8 @@ import com.liquidnet.commons.lang.util.CollectionUtil; ...@@ -4,9 +4,8 @@ import com.liquidnet.commons.lang.util.CollectionUtil;
import com.liquidnet.commons.lang.util.DateUtil; import com.liquidnet.commons.lang.util.DateUtil;
import com.liquidnet.service.base.PagedResult; import com.liquidnet.service.base.PagedResult;
import com.liquidnet.service.goblin.constant.GoblinStatusConst; import com.liquidnet.service.goblin.constant.GoblinStatusConst;
import com.liquidnet.service.goblin.dto.manage.GoblinStoreMgtCouponFilterParam; import com.liquidnet.service.goblin.dto.manage.*;
import com.liquidnet.service.goblin.dto.manage.GoblinStoreMgtGoodsFilterParam; import com.liquidnet.service.goblin.dto.manage.vo.GoblinGoodsAnticipateValueVo;
import com.liquidnet.service.goblin.dto.manage.GoblinStoreMgtNoticeFilterParam;
import com.liquidnet.service.goblin.dto.manage.vo.GoblinMgtCategorySpecVo; import com.liquidnet.service.goblin.dto.manage.vo.GoblinMgtCategorySpecVo;
import com.liquidnet.service.goblin.dto.manage.vo.GoblinStoreMgtCouponListVo; import com.liquidnet.service.goblin.dto.manage.vo.GoblinStoreMgtCouponListVo;
import com.liquidnet.service.goblin.dto.manage.vo.GoblinStoreMgtGoodsListVo; import com.liquidnet.service.goblin.dto.manage.vo.GoblinStoreMgtGoodsListVo;
...@@ -37,6 +36,7 @@ import org.springframework.util.CollectionUtils; ...@@ -37,6 +36,7 @@ import org.springframework.util.CollectionUtils;
import java.math.BigDecimal; import java.math.BigDecimal;
import java.time.LocalDateTime; import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap; import java.util.HashMap;
import java.util.List; import java.util.List;
...@@ -54,6 +54,108 @@ public class GoblinMongoUtils { ...@@ -54,6 +54,108 @@ public class GoblinMongoUtils {
@Autowired @Autowired
GoblinRedisUtils redisUtils; GoblinRedisUtils redisUtils;
/* ---------------------------------------- 预约数据源 ---------------------------------------- */
/**
* 分页查询
*/
public HashMap<String,Object> getGoblinGoodsAnticipateVos(GoblinGoodsAnticipateParam goodsAnticipateParam) {
HashMap<String,Object> info = CollectionUtil.mapStringObject();
Pageable pageable = PageRequest.of(goodsAnticipateParam.getPageNum() - 1, goodsAnticipateParam.getPageSize(), Sort.by(Sort.Direction.DESC,"createdDate"));
Criteria criteria = Criteria.where("delTag").is(0);
if (StringUtils.isNotBlank(goodsAnticipateParam.getName())) {
criteria = criteria.and("name").is(goodsAnticipateParam.getName());
}
Query query = Query.query(criteria);
//查询总数
long count = mongoTemplate.count(query, GoblinGoodsAnticipateVo.class, GoblinGoodsAnticipateVo.class.getSimpleName());
query.with(pageable);
List<GoblinGoodsAnticipateVo> voList = mongoTemplate.find(query, GoblinGoodsAnticipateVo.class, GoblinGoodsAnticipateVo.class.getSimpleName());
info.put("total",count);
info.put("data",voList);
return info;
}
/**
* 新增预约
*/
public void setGoblinGoodsAnticipateVo(GoblinGoodsAnticipateVo vo) {
mongoTemplate.insert(vo, GoblinGoodsAnticipateVo.class.getSimpleName());
}
/**
* 新增用户预约
*/
public void setGoblinGoodsAnticipateUserVo(GoblinGoodAnticipateUserVo vo) {
mongoTemplate.insert(vo, GoblinGoodAnticipateUserVo.class.getSimpleName());
}
/**
* 根据antId修改 预约人数
*/
public void updateGoblinGoodsAnticipateVoPeople(String antId, Long people) {
Query query = Query.query(Criteria.where("antId").is(antId));
Update update = new Update().set("aboutPeople", people).set("updateDate", LocalDateTime.now());
mongoTemplate.updateFirst(query, update, GoblinGoodsAnticipateVo.class.getSimpleName());
}
/**
* 根据antId修改 预约人数
*/
public void updateGoblinGoodsAnticipateVo(GoblinGoodsAnticipateUpdateParam goodsAnticipateUpdateParam) {
Query query = Query.query(Criteria.where("antId").is(goodsAnticipateUpdateParam.getAntId()));
Update update = new Update().set("name", goodsAnticipateUpdateParam.getName()).set("rule", goodsAnticipateUpdateParam.getRule()).set("updateDate",LocalDateTime.now());
mongoTemplate.updateFirst(query, update, GoblinGoodsAnticipateVo.class.getSimpleName());
}
/**
* 根据amtId删除VO
*/
public boolean delGoodsAnticipateVo(String antId) {
//查询该预约下有多少个开启预约的skuId
delAnticipateValues(antId);
redisUtils.delGoodsAnticipateVo(antId);
Query query = Query.query(Criteria.where("antId").is(antId));
return mongoTemplate.remove(query, GoblinGoodsAnticipateVo.class.getSimpleName()).getDeletedCount() > 0;
}
/**
* 根据活动id查询关联
*/
public List<GoblinGoodsAnticipateValueVo> getGoodsAnticipateValues(String antId){
Criteria criteria = Criteria.where("antId").is(antId);
Query query = Query.query(criteria);
return mongoTemplate.find(query, GoblinGoodsAnticipateValueVo.class, GoblinGoodsAnticipateValueVo.class.getSimpleName());
}
/**
* 根据用户预约
*/
public void delGoodsAnticipateUserVo(String uid,String skuId) {
Query query = Query.query(Criteria.where("uid").is(uid).and("skuId").is(skuId));
mongoTemplate.remove(query, GoblinGoodsAnticipateVo.class.getSimpleName()).getDeletedCount();
}
/**
* 根据预约ID获取预约详情
*/
public GoblinGoodsAnticipateVo getAnticipateVo(String antId) {
return mongoTemplate.findOne(Query.query(Criteria.where("autId").is(antId)),
GoblinGoodsAnticipateVo.class, GoblinGoodsAnticipateVo.class.getSimpleName());
}
/**
* 添加预约中间表信息
*/
public void addAnticipateValues(GoblinGoodsAnticipateValueVo goodsAnticipateValueVo) {
mongoTemplate.insert(goodsAnticipateValueVo, GoblinGoodsAnticipateValueVo.class.getSimpleName());
}
public void delAnticipateValues(String antId){
Query query = Query.query(Criteria.where("antId").is(antId));
mongoTemplate.remove(query, GoblinGoodsAnticipateValueVo.class.getSimpleName()).getDeletedCount();
}
/* ---------------------------------------- 平台分类数据源 ---------------------------------------- */ /* ---------------------------------------- 平台分类数据源 ---------------------------------------- */
public List<GoblinSelfGoodsCategoryVo> getSelfGoodsCategoryVos() { public List<GoblinSelfGoodsCategoryVo> getSelfGoodsCategoryVos() {
......
...@@ -2,10 +2,7 @@ package com.liquidnet.service.goblin.util; ...@@ -2,10 +2,7 @@ package com.liquidnet.service.goblin.util;
import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSON;
import com.fasterxml.jackson.core.type.TypeReference; import com.fasterxml.jackson.core.type.TypeReference;
import com.liquidnet.commons.lang.util.CollectionUtil; import com.liquidnet.commons.lang.util.*;
import com.liquidnet.commons.lang.util.CurrentUtil;
import com.liquidnet.commons.lang.util.HttpUtil;
import com.liquidnet.commons.lang.util.JsonUtils;
import com.liquidnet.service.adam.dto.vo.AdamRscPolymer01Vo; import com.liquidnet.service.adam.dto.vo.AdamRscPolymer01Vo;
import com.liquidnet.service.base.ResponseDto; import com.liquidnet.service.base.ResponseDto;
import com.liquidnet.service.candy.param.BackCouponParam; import com.liquidnet.service.candy.param.BackCouponParam;
......
...@@ -42,6 +42,55 @@ public class GoblinRedisUtils { ...@@ -42,6 +42,55 @@ public class GoblinRedisUtils {
redisUtil.del(keys); redisUtil.del(keys);
} }
/* ---------------------------------------- 预约相关 ---------------------------------------- */
/**
* 该skuId已开启预约
*/
public void setAnticipate(String skuId){
redisUtil.set(GoblinRedisConst.ANTICIPATE_SKUID.concat(skuId),1);
}
public GoblinGoodAnticipateUserVo getUserAboutAut(String skuId, String uid) {
return (GoblinGoodAnticipateUserVo) redisUtil.get(GoblinRedisConst.USER_ANTICIPATE_STATE.concat(skuId).concat(uid));
}
/**
* 新增用户预约
*/
public void setUserAboutSku(GoblinGoodAnticipateUserVo user) {
goblinMongoUtils.setGoblinGoodsAnticipateUserVo(user);
redisUtil.set(GoblinRedisConst.USER_ANTICIPATE_STATE.concat(user.getSkuId()).concat(user.getUid()),user);
}
/**
* 删除用户预约
*/
public void delUserAboutSku(String skuId, String uid) {
goblinMongoUtils.delGoodsAnticipateUserVo(uid, skuId);
redisUtil.del(GoblinRedisConst.USER_ANTICIPATE_STATE.concat(skuId).concat(uid));
}
/**
* 实际预约人数修改
*/
public void setAutId(String autId,Integer state) {
Integer num = (Integer) redisUtil.get(GoblinRedisConst.ANTICIPATE_PEOPLE.concat(autId));
if (state.equals(GoblinGoodAnticipateUserVo.STATE_VALID)){
redisUtil.set(GoblinRedisConst.ANTICIPATE_PEOPLE.concat(autId),num==null? 1:num+1);
}
if (state.equals(GoblinGoodAnticipateUserVo.STATE_INVALID)&&num!=null){
redisUtil.set(GoblinRedisConst.ANTICIPATE_PEOPLE.concat(autId),num-1);
}
}
/**
* 删除预约
*/
public void delGoodsAnticipateVo(String skuId) {
redisUtil.del(GoblinRedisConst.ANTICIPATE_SKUID.concat(skuId));
}
/* ---------------------------------------- sku库存相关 ---------------------------------------- */ /* ---------------------------------------- sku库存相关 ---------------------------------------- */
public void setSkuStock(String marketPre, String skuId, Integer stock) { public void setSkuStock(String marketPre, String skuId, Integer stock) {
String rk = GoblinRedisConst.REAL_STOCK_SKU; String rk = GoblinRedisConst.REAL_STOCK_SKU;
......
...@@ -10,9 +10,9 @@ spring: ...@@ -10,9 +10,9 @@ spring:
cloud: cloud:
config: config:
# uri: http://127.0.0.1:7002/support-config # uri: http://127.0.0.1:7002/support-config
# uri: http://39.107.71.112:7002/support-config uri: http://39.107.71.112:7002/support-config
profile: ${liquidnet.cloudConfig.profile} # profile: ${liquidnet.cloudConfig.profile}
name: ${spring.application.name} #默认为spring.application.name # name: ${spring.application.name} #默认为spring.application.name
discovery: # discovery:
enabled: true # enabled: true
service-id: liquidnet-support-config # service-id: liquidnet-support-config
\ No newline at end of file \ No newline at end of file
#---- 服务支持信息 #---- \u670D\u52A1\u652F\u6301\u4FE1\u606F
goblin_service_support.insert_byreplace=REPLACE INTO goblin_service_support (ssid,name,`desc`,url,del_flg,created_by,created_at)VALUES(?,?,?,?,'0','-',sysdate()) goblin_service_support.insert_byreplace=REPLACE INTO goblin_service_support (ssid,name,`desc`,url,del_flg,created_by,created_at)VALUES(?,?,?,?,'0','-',sysdate())
#---- 店铺信息 #---- \u5E97\u94FA\u4FE1\u606F
goblin_store_info.insert_by_cert=INSERT INTO goblin_store_info (store_id,uid,status,store_type,cert_type,created_by,created_at)VALUES(?,?,?,?,?,?,?) goblin_store_info.insert_by_cert=INSERT INTO goblin_store_info (store_id,uid,status,store_type,cert_type,created_by,created_at)VALUES(?,?,?,?,?,?,?)
goblin_store_info.update_by_cert1=UPDATE goblin_store_info SET store_type=?,cert_type=?,updated_by=?,updated_at=? WHERE store_id=? goblin_store_info.update_by_cert1=UPDATE goblin_store_info SET store_type=?,cert_type=?,updated_by=?,updated_at=? WHERE store_id=?
goblin_store_info.update_by_cert2=UPDATE goblin_store_info SET store_name=?,logo_pic=?,background_pic=?,introduce=?,status=?,reason='',store_type=?,updated_by=?,updated_at=? WHERE store_id=? goblin_store_info.update_by_cert2=UPDATE goblin_store_info SET store_name=?,logo_pic=?,background_pic=?,introduce=?,status=?,reason='',store_type=?,updated_by=?,updated_at=? WHERE store_id=?
...@@ -10,30 +10,30 @@ goblin_store_info.update_by_setting=UPDATE goblin_store_info SET status=?,update ...@@ -10,30 +10,30 @@ goblin_store_info.update_by_setting=UPDATE goblin_store_info SET status=?,update
goblin_store_certification.insert_by_cert=INSERT INTO goblin_store_certification (store_id,person_cert_type,person_name,person_cert_code,person_cert_validity,person_cert_lasting,person_cert_fpic,person_cert_bpic,person_cert_spic,province_id,province_name,city_id,city_name,county_id,county_name,bus_address,bus_name,bus_cert_code,bus_cert_validity,bus_cert_lasting,bus_cert_pic,bus_quality_pic,created_by,created_at) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) goblin_store_certification.insert_by_cert=INSERT INTO goblin_store_certification (store_id,person_cert_type,person_name,person_cert_code,person_cert_validity,person_cert_lasting,person_cert_fpic,person_cert_bpic,person_cert_spic,province_id,province_name,city_id,city_name,county_id,county_name,bus_address,bus_name,bus_cert_code,bus_cert_validity,bus_cert_lasting,bus_cert_pic,bus_quality_pic,created_by,created_at) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)
goblin_store_certification.update_by_cert=UPDATE goblin_store_certification SET person_cert_type=?,person_name=?,person_cert_code=?,person_cert_validity=?,person_cert_lasting=?,person_cert_fpic=?,person_cert_bpic=?,person_cert_spic=?,province_id=?,province_name=?,city_id=?,city_name=?,county_id=?,county_name=?,bus_address=?,bus_name=?,bus_cert_code=?,bus_cert_validity=?,bus_cert_lasting=?,bus_cert_pic=?,bus_quality_pic=?,updated_by=?,updated_at=? WHERE store_id=? goblin_store_certification.update_by_cert=UPDATE goblin_store_certification SET person_cert_type=?,person_name=?,person_cert_code=?,person_cert_validity=?,person_cert_lasting=?,person_cert_fpic=?,person_cert_bpic=?,person_cert_spic=?,province_id=?,province_name=?,city_id=?,city_name=?,county_id=?,county_name=?,bus_address=?,bus_name=?,bus_cert_code=?,bus_cert_validity=?,bus_cert_lasting=?,bus_cert_pic=?,bus_quality_pic=?,updated_by=?,updated_at=? WHERE store_id=?
goblin_store_certification.update_by_del=UPDATE goblin_store_certification SET del_flg=1,updated_by=?,updated_at=? WHERE store_id=? goblin_store_certification.update_by_del=UPDATE goblin_store_certification SET del_flg=1,updated_by=?,updated_at=? WHERE store_id=?
#---- 店铺配置信息 #---- \u5E97\u94FA\u914D\u7F6E\u4FE1\u606F
goblin_store_config.update=UPDATE goblin_store_config SET config_val=?,updated_by=?,updated_at=? WHERE store_id=? AND config_key=? goblin_store_config.update=UPDATE goblin_store_config SET config_val=?,updated_by=?,updated_at=? WHERE store_id=? AND config_key=?
#---- 店铺公告信息 #---- \u5E97\u94FA\u516C\u544A\u4FE1\u606F
goblin_store_notice.insert=INSERT INTO goblin_store_notice (notice_id,store_id,content,release_time,long_lasting,cancell_time,status,created_by,created_at)VALUES(?,?,?,?,?,?,?,?,?) goblin_store_notice.insert=INSERT INTO goblin_store_notice (notice_id,store_id,content,release_time,long_lasting,cancell_time,status,created_by,created_at)VALUES(?,?,?,?,?,?,?,?,?)
goblin_store_notice.update=UPDATE goblin_store_notice SET content=?,release_time=?,long_lasting=?,cancell_time=?,status=?,updated_by=?,updated_at=? WHERE notice_id=? goblin_store_notice.update=UPDATE goblin_store_notice SET content=?,release_time=?,long_lasting=?,cancell_time=?,status=?,updated_by=?,updated_at=? WHERE notice_id=?
goblin_store_notice.release=UPDATE goblin_store_notice SET release_time=?,status='1',updated_by=?,updated_at=? WHERE store_id=? AND notice_id=? goblin_store_notice.release=UPDATE goblin_store_notice SET release_time=?,status='1',updated_by=?,updated_at=? WHERE store_id=? AND notice_id=?
goblin_store_notice.remove=UPDATE goblin_store_notice SET del_flg='1',updated_by=?,updated_at=? WHERE store_id=? AND notice_id=? goblin_store_notice.remove=UPDATE goblin_store_notice SET del_flg='1',updated_by=?,updated_at=? WHERE store_id=? AND notice_id=?
#---- 店铺商品分类信息 #---- \u5E97\u94FA\u5546\u54C1\u5206\u7C7B\u4FE1\u606F
goblin_store_goods_category.insert=INSERT INTO goblin_store_goods_category (store_id,cate_id,name,sort,grade,cate_pid,ne_isbn,created_by,created_at)VALUES(?,?,?,?,?,?,?,?,?) goblin_store_goods_category.insert=INSERT INTO goblin_store_goods_category (store_id,cate_id,name,sort,grade,cate_pid,ne_isbn,created_by,created_at)VALUES(?,?,?,?,?,?,?,?,?)
goblin_store_goods_category.update=UPDATE goblin_store_goods_category SET name=?,sort=?,updated_by=?,updated_at=? WHERE store_id=? AND cate_id=? goblin_store_goods_category.update=UPDATE goblin_store_goods_category SET name=?,sort=?,updated_by=?,updated_at=? WHERE store_id=? AND cate_id=?
goblin_store_goods_category.remove=UPDATE goblin_store_goods_category SET del_flg='1',updated_by=?,updated_at=?,deleted_by=?,updated_at=? WHERE store_id=? AND cate_id=? goblin_store_goods_category.remove=UPDATE goblin_store_goods_category SET del_flg='1',updated_by=?,updated_at=?,deleted_by=?,updated_at=? WHERE store_id=? AND cate_id=?
#---- 商品分类规格信息 #---- \u5546\u54C1\u5206\u7C7B\u89C4\u683C\u4FE1\u606F
goblin_goods_category_spec.insert_byreplace=REPLACE INTO goblin_goods_category_spec (cate_id,spec_name,del_flg)VALUES(?,?,'0') goblin_goods_category_spec.insert_byreplace=REPLACE INTO goblin_goods_category_spec (cate_id,spec_name,del_flg)VALUES(?,?,'0')
#---- 商品规格信息 #---- \u5546\u54C1\u89C4\u683C\u4FE1\u606F
goblin_goods_spec.insert_byreplace=REPLACE INTO goblin_goods_spec (spec_name,del_flg,created_by,created_at)VALUES(?,'0','-',?) goblin_goods_spec.insert_byreplace=REPLACE INTO goblin_goods_spec (spec_name,del_flg,created_by,created_at)VALUES(?,'0','-',?)
goblin_goods_spec_value.insert_byreplace=REPLACE INTO goblin_goods_spec_value (spec_name,spec_vname,del_flg,created_by,created_at)VALUES(?,?,'0','-',?) goblin_goods_spec_value.insert_byreplace=REPLACE INTO goblin_goods_spec_value (spec_name,spec_vname,del_flg,created_by,created_at)VALUES(?,?,'0','-',?)
#---- 商品关联规格信息 #---- \u5546\u54C1\u5173\u8054\u89C4\u683C\u4FE1\u606F
goblin_goods_spu_spec_value.insert_byreplace=REPLACE INTO goblin_goods_spu_spec_value (spu_id,spec_name,spec_vname,sort,del_flg)VALUES(?,?,?,?,'0') goblin_goods_spu_spec_value.insert_byreplace=REPLACE INTO goblin_goods_spu_spec_value (spu_id,spec_name,spec_vname,sort,del_flg)VALUES(?,?,?,?,'0')
goblin_goods_spu_spec_value.update_by_editdel=UPDATE goblin_goods_spu_spec_value SET del_flg='1' WHERE spu_id=? AND spec_name=? AND spec_vname=? AND del_flg='0' goblin_goods_spu_spec_value.update_by_editdel=UPDATE goblin_goods_spu_spec_value SET del_flg='1' WHERE spu_id=? AND spec_name=? AND spec_vname=? AND del_flg='0'
goblin_goods_spu_spec_value.update_by_del_sku=UPDATE goblin_goods_spu_spec_value SET sort=?,del_flg=? WHERE spu_id=? AND spec_name=? AND spec_vname=? goblin_goods_spu_spec_value.update_by_del_sku=UPDATE goblin_goods_spu_spec_value SET sort=?,del_flg=? WHERE spu_id=? AND spec_name=? AND spec_vname=?
goblin_goods_sku_spec_value.insert_byreplace=REPLACE INTO goblin_goods_sku_spec_value (spu_id,sku_id,spec_name,spec_vname,del_flg)VALUES(?,?,?,?,'0') goblin_goods_sku_spec_value.insert_byreplace=REPLACE INTO goblin_goods_sku_spec_value (spu_id,sku_id,spec_name,spec_vname,del_flg)VALUES(?,?,?,?,'0')
goblin_goods_sku_spec_value.update_by_edit=UPDATE goblin_goods_sku_spec_value SET spec_vname=? WHERE sku_id=? AND spec_name=? AND del_flg='0' goblin_goods_sku_spec_value.update_by_edit=UPDATE goblin_goods_sku_spec_value SET spec_vname=? WHERE sku_id=? AND spec_name=? AND del_flg='0'
goblin_goods_sku_spec_value.update_by_del_sku=UPDATE goblin_goods_sku_spec_value SET del_flg='1' WHERE sku_id=? AND del_flg='0' goblin_goods_sku_spec_value.update_by_del_sku=UPDATE goblin_goods_sku_spec_value SET del_flg='1' WHERE sku_id=? AND del_flg='0'
#---- 商品信息 #---- \u5546\u54C1\u4FE1\u606F
goblin_goods.insert=INSERT INTO goblin_goods (spu_id,spu_no,name,subtitle,sell_price, price_ge,price_le,intro,details,cover_pic, video,spec_mode,store_id,cate_fid,cate_sid, cate_tid,store_cate_fid,store_cate_sid,store_cate_tid,brand_id, shelves_handle,shelves_time,spu_validity,virtual_flg,status, shelves_status,spu_appear,shelves_at,created_by,created_at, logistics_template)VALUES(?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) goblin_goods.insert=INSERT INTO goblin_goods (spu_id,spu_no,name,subtitle,sell_price, price_ge,price_le,intro,details,cover_pic, video,spec_mode,store_id,cate_fid,cate_sid, cate_tid,store_cate_fid,store_cate_sid,store_cate_tid,brand_id, shelves_handle,shelves_time,spu_validity,virtual_flg,status, shelves_status,spu_appear,shelves_at,created_by,created_at, logistics_template)VALUES(?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)
goblin_goods.insert_for_digital=INSERT INTO goblin_goods (spu_id,spu_no,spu_type,name,intro,attention,store_id,cate_fid,cate_sid,cate_tid,virtual_flg,status,shelves_status,spu_appear,created_by,created_at)VALUES(?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) goblin_goods.insert_for_digital=INSERT INTO goblin_goods (spu_id,spu_no,spu_type,name,intro,attention,store_id,cate_fid,cate_sid,cate_tid,virtual_flg,status,shelves_status,spu_appear,created_by,created_at)VALUES(?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)
goblin_goods.update_by_edit=UPDATE goblin_goods SET spu_no=?,name=?,subtitle=?,sell_price=?,intro=?,details=?,cover_pic=?,video=?,spec_mode=?,cate_fid=?,cate_sid=?,cate_tid=?,shelves_handle=?,shelves_time=?,spu_validity=?,virtual_flg=?,logistics_template=?,updated_by=?,updated_at=? WHERE spu_id=? AND del_flg='0' goblin_goods.update_by_edit=UPDATE goblin_goods SET spu_no=?,name=?,subtitle=?,sell_price=?,intro=?,details=?,cover_pic=?,video=?,spec_mode=?,cate_fid=?,cate_sid=?,cate_tid=?,shelves_handle=?,shelves_time=?,spu_validity=?,virtual_flg=?,logistics_template=?,updated_by=?,updated_at=? WHERE spu_id=? AND del_flg='0'
...@@ -74,25 +74,25 @@ goblin_goods_artag.insert_byreplace=REPLACE INTO goblin_goods_tag (spu_id,tag_id ...@@ -74,25 +74,25 @@ goblin_goods_artag.insert_byreplace=REPLACE INTO goblin_goods_tag (spu_id,tag_id
goblin_goods_artag.delete=UPDATE goblin_goods_tag SET del_flg='1' WHERE spu_id=? AND tag_belong=? AND del_flg='0' goblin_goods_artag.delete=UPDATE goblin_goods_tag SET del_flg='1' WHERE spu_id=? AND tag_belong=? AND del_flg='0'
goblin_goods_service_support.insert_byreplace=REPLACE INTO goblin_goods_service_support (spu_id,ssid,del_flg)VALUES(?,?,'0') goblin_goods_service_support.insert_byreplace=REPLACE INTO goblin_goods_service_support (spu_id,ssid,del_flg)VALUES(?,?,'0')
goblin_goods_service_support.delete=UPDATE goblin_goods_service_support SET del_flg='1' WHERE spu_id=? AND del_flg='0' goblin_goods_service_support.delete=UPDATE goblin_goods_service_support SET del_flg='1' WHERE spu_id=? AND del_flg='0'
#---- 商铺活动 #---- \u5546\u94FA\u6D3B\u52A8
goblin.store.market.insert=INSERT INTO goblin_store_marketing (`store_market_id`,`name`,`type`,`status`,`store_id`,`start_time`,`end_time`,`del_flag`,`is_pre`,`pre_time`,`created_at`) VALUES (?,?,?,?,?,?,?,?,?,?,?) goblin.store.market.insert=INSERT INTO goblin_store_marketing (`store_market_id`,`name`,`type`,`status`,`store_id`,`start_time`,`end_time`,`del_flag`,`is_pre`,`pre_time`,`created_at`) VALUES (?,?,?,?,?,?,?,?,?,?,?)
goblin.store.market.status=UPDATE goblin_store_marketing SET status=? , del_flag=? WHERE store_market_id =? and store_id =? goblin.store.market.status=UPDATE goblin_store_marketing SET status=? , del_flag=? WHERE store_market_id =? and store_id =?
goblin.store.market.update=UPDATE goblin_store_marketing SET name=?,type=?,status=?,store_id=?,describes=?,start_time=?,end_time=?,del_flag=?,is_pre=?,pre_time=?,updated_at=? WHERE store_market_id =? and store_id =? goblin.store.market.update=UPDATE goblin_store_marketing SET name=?,type=?,status=?,store_id=?,describes=?,start_time=?,end_time=?,del_flag=?,is_pre=?,pre_time=?,updated_at=? WHERE store_market_id =? and store_id =?
goblin.store.market.insertRelation=INSERT INTO goblin_store_market_purchasing (`purchase_id`,`store_market_id`,`spu_id`,`sku_id`,`store_id`,`price_marketing`,`stock_marketing`,`buy_factor`,`buy_roster`,`buy_limit`,`del_flag`,`created_at`) VALUES (?,?,?,?,?,?,?,?,?,?,?,?) goblin.store.market.insertRelation=INSERT INTO goblin_store_market_purchasing (`purchase_id`,`store_market_id`,`spu_id`,`sku_id`,`store_id`,`price_marketing`,`stock_marketing`,`buy_factor`,`buy_roster`,`buy_limit`,`del_flag`,`created_at`) VALUES (?,?,?,?,?,?,?,?,?,?,?,?)
goblin.store.market.updateRelation=UPDATE goblin_store_market_purchasing SET price_marketing=? ,stock_marketing=? , buy_factor=?,buy_roster=?,buy_limit=?,updated_at=? WHERE store_market_id =? and store_id =? goblin.store.market.updateRelation=UPDATE goblin_store_market_purchasing SET price_marketing=? ,stock_marketing=? , buy_factor=?,buy_roster=?,buy_limit=?,updated_at=? WHERE store_market_id =? and store_id =?
goblin.store.market.delSpuRelation=UPDATE goblin_store_market_purchasing SET del_flag = ?,updated_at = ? WHERE store_market_id =? and store_id =? and spu_id=? goblin.store.market.delSpuRelation=UPDATE goblin_store_market_purchasing SET del_flag = ?,updated_at = ? WHERE store_market_id =? and store_id =? and spu_id=?
#---- 平台活动 #---- \u5E73\u53F0\u6D3B\u52A8
goblin.self.market.insertRelation=INSERT INTO goblin_marketing_zhengzai (`zhengzai_id`,`self_market_id`,`spu_id`,`sku_id`,`store_id`,`price_marketing`,`stock_marketing`,`buy_factor`,`buy_roster`,`buy_limit`,`del_flag`,`created_at`) VALUES (?,?,?,?,?,?,?,?,?,?,?,?) goblin.self.market.insertRelation=INSERT INTO goblin_marketing_zhengzai (`zhengzai_id`,`self_market_id`,`spu_id`,`sku_id`,`store_id`,`price_marketing`,`stock_marketing`,`buy_factor`,`buy_roster`,`buy_limit`,`del_flag`,`created_at`) VALUES (?,?,?,?,?,?,?,?,?,?,?,?)
goblin.self.market.updateRelation=UPDATE goblin_marketing_zhengzai SET price_marketing=? ,stock_marketing=? , buy_factor=?,buy_roster=?,buy_limit=?,updated_at=? WHERE self_market_id =? and store_id =? goblin.self.market.updateRelation=UPDATE goblin_marketing_zhengzai SET price_marketing=? ,stock_marketing=? , buy_factor=?,buy_roster=?,buy_limit=?,updated_at=? WHERE self_market_id =? and store_id =?
goblin.self.market.delSpuRelation=UPDATE goblin_marketing_zhengzai SET del_flag = ?,updated_at = ? WHERE self_market_id =? and store_id =? and spu_id=? goblin.self.market.delSpuRelation=UPDATE goblin_marketing_zhengzai SET del_flag = ?,updated_at = ? WHERE self_market_id =? and store_id =? and spu_id=?
#---- 订单创建&支付 #---- \u8BA2\u5355\u521B\u5EFA&\u652F\u4ED8
goblin_order.pay.order=UPDATE goblin_store_order SET payment_type = ? ,payment_id=?,pay_code = ? ,pay_time = ?,write_off_code = ? ,status = ? ,updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.pay.order=UPDATE goblin_store_order SET payment_type = ? ,payment_id=?,pay_code = ? ,pay_time = ?,write_off_code = ? ,status = ? ,updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
goblin_order.pay.sku=UPDATE goblin_order_sku SET status = ? ,updated_at = ? WHERE order_sku_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.pay.sku=UPDATE goblin_order_sku SET status = ? ,updated_at = ? WHERE order_sku_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
#---- 订单绑定[正在下单] 出货 #---- \u8BA2\u5355\u7ED1\u5B9A[\u6B63\u5728\u4E0B\u5355] \u51FA\u8D27
goblin_order.zhengzai.bind=UPDATE goblin_store_order SET user_id = ? ,updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.zhengzai.bind=UPDATE goblin_store_order SET user_id = ? ,updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
goblin_order.zhengzai.push=UPDATE goblin_store_order SET zhengzai_status = ? ,updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.zhengzai.push=UPDATE goblin_store_order SET zhengzai_status = ? ,updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
#---- 商铺订单操作 #---- \u5546\u94FA\u8BA2\u5355\u64CD\u4F5C
goblin_order.store.cancel=UPDATE goblin_store_order SET status = ? ,cancel_time = ? , cancel_reason = ? , updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.store.cancel=UPDATE goblin_store_order SET status = ? ,cancel_time = ? , cancel_reason = ? , updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
goblin_order.store.orderSkuStatus=UPDATE goblin_order_sku SET status = ? , updated_at = ? WHERE order_sku_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.store.orderSkuStatus=UPDATE goblin_order_sku SET status = ? , updated_at = ? WHERE order_sku_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
goblin_order.store.express=UPDATE goblin_store_order SET status = ? , updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.store.express=UPDATE goblin_store_order SET status = ? , updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
...@@ -111,15 +111,15 @@ goblin_order.store.changeSku=UPDATE goblin_back_order SET real_back_price = ? , ...@@ -111,15 +111,15 @@ goblin_order.store.changeSku=UPDATE goblin_back_order SET real_back_price = ? ,
goblin_order.store.backOrderStatus=UPDATE goblin_back_order SET status = ? , refuse_at=?,refuse_size=?,updated_at = ? WHERE back_order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.store.backOrderStatus=UPDATE goblin_back_order SET status = ? , refuse_at=?,refuse_size=?,updated_at = ? WHERE back_order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
goblin_order.store.orderStatus=UPDATE goblin_store_order SET status = ? , updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.store.orderStatus=UPDATE goblin_store_order SET status = ? , updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
goblin_order.store.applyRefund=UPDATE goblin_back_order SET status = ? ,reason=?,audit_at=?, updated_at = ? WHERE back_order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.store.applyRefund=UPDATE goblin_back_order SET status = ? ,reason=?,audit_at=?, updated_at = ? WHERE back_order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
#---- 用户订单操作 #---- \u7528\u6237\u8BA2\u5355\u64CD\u4F5C
goblin_order.user.applyRefund=INSERT INTO goblin_back_order (`back_order_id`,`back_code`,`order_id`,`order_code`,`store_id`,`user_id`,`sku_id_nums`,`type`,`reason`,`describes`,`real_back_price`,`back_price_express`,`status`,`logis_company_name`,`mail_no`,`pics`,`created_at`) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) goblin_order.user.applyRefund=INSERT INTO goblin_back_order (`back_order_id`,`back_code`,`order_id`,`order_code`,`store_id`,`user_id`,`sku_id_nums`,`type`,`reason`,`describes`,`real_back_price`,`back_price_express`,`status`,`logis_company_name`,`mail_no`,`pics`,`created_at`) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)
goblin_order.user.againRefund=UPDATE goblin_back_order SET status = ? , describes = ? , pics = ? , reason = ? , type = ?, updated_at=? where back_order_id=? goblin_order.user.againRefund=UPDATE goblin_back_order SET status = ? , describes = ? , pics = ? , reason = ? , type = ?, updated_at=? where back_order_id=?
#---- 购物车操作 #---- \u8D2D\u7269\u8F66\u64CD\u4F5C
goblin_shop.cart.delete=UPDATE goblin_shopping_cart set del_tag=? where user_id=? and sku_id=? goblin_shop.cart.delete=UPDATE goblin_shopping_cart set del_tag=? where user_id=? and sku_id=?
goblin_shop.cart.insert=insert into goblin_shopping_cart (car_id, user_id, store_id,spu_id, sku_id, `number`,marketing_id, del_tag, `comment`,`type`) values (?,?,?,?,?,?,?,?,?,?) goblin_shop.cart.insert=insert into goblin_shopping_cart (car_id, user_id, store_id,spu_id, sku_id, `number`,marketing_id, del_tag, `comment`,`type`) values (?,?,?,?,?,?,?,?,?,?)
goblin_shop.cart.update=update goblin_shopping_cart set `number` = ? where car_id=? and user_id=? and del_tag=0 goblin_shop.cart.update=update goblin_shopping_cart set `number` = ? where car_id=? and user_id=? and del_tag=0
#---- 商铺活动:优惠券 #---- \u5546\u94FA\u6D3B\u52A8:\u4F18\u60E0\u5238
goblin_store_coupon.insert=INSERT INTO goblin_store_coupon (store_coupon_id,store_coupon_no,store_id,title,label, notice,type,stock,triggers,val_face, discount,val_over,val_minus,deduction,receive_limit, receive_curb,use_scope,state,start_time,end_time, created_by,created_at)VALUES(?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) goblin_store_coupon.insert=INSERT INTO goblin_store_coupon (store_coupon_id,store_coupon_no,store_id,title,label, notice,type,stock,triggers,val_face, discount,val_over,val_minus,deduction,receive_limit, receive_curb,use_scope,state,start_time,end_time, created_by,created_at)VALUES(?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)
goblin_store_coupon.update=UPDATE goblin_store_coupon SET title=?,label=?,notice=?,type=?,triggers=?,val_face=?,discount=?,val_over=?,val_minus=?,deduction=?,receive_limit=?,receive_curb=?,use_scope=?,start_time=?,end_time=?,updated_by=?,updated_at=? WHERE store_coupon_id=? AND del_flg='0' goblin_store_coupon.update=UPDATE goblin_store_coupon SET title=?,label=?,notice=?,type=?,triggers=?,val_face=?,discount=?,val_over=?,val_minus=?,deduction=?,receive_limit=?,receive_curb=?,use_scope=?,start_time=?,end_time=?,updated_by=?,updated_at=? WHERE store_coupon_id=? AND del_flg='0'
goblin_store_coupon.update_stock=UPDATE goblin_store_coupon SET stock=?,updated_by=?,updated_at=? WHERE store_coupon_id=? AND del_flg='0' goblin_store_coupon.update_stock=UPDATE goblin_store_coupon SET stock=?,updated_by=?,updated_at=? WHERE store_coupon_id=? AND del_flg='0'
...@@ -129,7 +129,19 @@ goblin_store_coupon_rule.insert=INSERT INTO goblin_store_coupon_rule (store_coup ...@@ -129,7 +129,19 @@ goblin_store_coupon_rule.insert=INSERT INTO goblin_store_coupon_rule (store_coup
goblin_store_coupon_rule.update_del=UPDATE goblin_store_coupon_rule SET del_flg='1',updated_by=?,updated_at=? WHERE store_coupon_id=? AND del_flg='0' goblin_store_coupon_rule.update_del=UPDATE goblin_store_coupon_rule SET del_flg='1',updated_by=?,updated_at=? WHERE store_coupon_id=? AND del_flg='0'
goblin_user_coupon.insert=INSERT INTO goblin_user_coupon (ucoupon_id, store_coupon_id, uid, state, bind_at, dued_at, operator, created_at)VALUES(?,?,?,?,?,?,?,?) goblin_user_coupon.insert=INSERT INTO goblin_user_coupon (ucoupon_id, store_coupon_id, uid, state, bind_at, dued_at, operator, created_at)VALUES(?,?,?,?,?,?,?,?)
goblin_user_coupon.updateState=UPDATE goblin_user_coupon SET state = ? , used_for = ? ,updated_at = ? where ucoupon_id = ? goblin_user_coupon.updateState=UPDATE goblin_user_coupon SET state = ? , used_for = ? ,updated_at = ? where ucoupon_id = ?
#---- 我的藏品 #---- \u6211\u7684\u85CF\u54C1
goblin_user_digital_artwork.update_for_chain=UPDATE goblin_user_digital_artwork SET edition_sn=?,nft_id=?,release_txhash=?,release_at=?,trading_txhash=?,trading_at=?,state=?,updated_at=? WHERE artwork_id=? AND state<>1 goblin_user_digital_artwork.update_for_chain=UPDATE goblin_user_digital_artwork SET edition_sn=?,nft_id=?,release_txhash=?,release_at=?,trading_txhash=?,trading_at=?,state=?,updated_at=? WHERE artwork_id=? AND state<>1
goblin_user_digital_artwork.update_for_unboxing=UPDATE goblin_user_digital_artwork SET state=1,del_flg='1',opening_at=?,updated_at=?,deleted_at=? WHERE artwork_id=? AND state<>1 goblin_user_digital_artwork.update_for_unboxing=UPDATE goblin_user_digital_artwork SET state=1,del_flg='1',opening_at=?,updated_at=?,deleted_at=? WHERE artwork_id=? AND state<>1
#---- #----
\ No newline at end of file #---- \u9884\u7EA6
goblin_goods_anticipate=INSERT INTO goblin_goods_anticipate(ant_id,`name`,`rule`,actual_people,about_start_date,about_end_date,created_date,del_tag) VALUES(?,?,?,?,?,?,?,?)
goblin_goods_anticipate_update_actual_add_people=UPDATE goblin_goods_anticipate SET actual_people = actual_people+1 WHERE ant_id = ?
goblin_goods_anticipate_update_actual_reduce_people=UPDATE goblin_goods_anticipate SET actual_people = actual_people-1 WHERE ant_id = ?
goblin_goods_anticipate_delete=UPDATE goblin_goods_anticipate SET `del_tag` = 1 WHERE ant_id = ?
goblin_goods_anticipate_value=INSERT INTO goblin_goods_anticipate_value (ant_id,sku_name,sku_id,spu_id,about_start_date,about_end_date,created_date,del_tag) VALUES(?,?,?,?,?,?,?,?)
goblin_goods_anticipate_value_update=UPDATE goblin_goods_anticipate_value SET `about_start_date` = ?,`about_end_date`= ?,update_date = NOW() WHERE ant_id = ? AND sku_id = ? AND spu_id = ?
goblin_goods_anticipate_value_delete=UPDATE goblin_goods_anticipate_value SET `del_tag` = 1 WHERE ant_id = ?
goblin_goods_anticipate_update=UPDATE goblin_goods_anticipate SET `name` = ?,`rule`= ? WHERE ant_id = ?
goblin_goods_anticipate_update_proper=UPDATE goblin_goods_anticipate SET about_people = ? WHERE ant_id = ?
goblin_goods_anticipate_user=INSERT INTO goblin_goods_anticipate_user(uid,sku_id,phone,state) VALUES(?,?,?,?)
goblin_goods_anticipate_user_update=UPDATE goblin_goods_anticipate_user SET state = 0 WHERE uid = ? AND sku_id = ?
import org.springframework.boot.test.context.SpringBootTest;
@SpringBootTest
public class TestGoblinGoodsAnticipate {
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment