增加firstorder字段
This commit is contained in:
@@ -17,8 +17,7 @@
|
||||
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
|
||||
</resultMap>
|
||||
<select id="selectByShopId" resultType="com.cool.store.dto.openPreparation.FirstOrderDTO">
|
||||
select id, total_order_deposit as totalOrderDeposit, latest_payment_date as latestPaymentDate ,
|
||||
estimated_cost as estimatedCost ,fruits_cost as fruitsCost
|
||||
select *
|
||||
from xfsg_first_order
|
||||
where shop_id = #{shopId}
|
||||
</select>
|
||||
|
||||
@@ -32,7 +32,12 @@ public class FirstOrderDTO {
|
||||
|
||||
@ApiModelProperty("创建人")
|
||||
private String createUserId;
|
||||
|
||||
@ApiModelProperty("加盟商")
|
||||
private String partnerName;
|
||||
@ApiModelProperty("创建时间")
|
||||
private Date createTime;
|
||||
@ApiModelProperty("更新时间")
|
||||
private Date updateTime;
|
||||
@ApiModelProperty("更新人")
|
||||
private String updateUserId;
|
||||
|
||||
|
||||
@@ -4,6 +4,7 @@ import com.alibaba.fastjson.JSONObject;
|
||||
import com.cool.store.constants.CommonConstants;
|
||||
import com.cool.store.context.CurrentUserHolder;
|
||||
import com.cool.store.context.LoginUserInfo;
|
||||
import com.cool.store.dao.EnterpriseUserDAO;
|
||||
import com.cool.store.dao.FirstOrderDAO;
|
||||
import com.cool.store.dao.ShopStageInfoDAO;
|
||||
import com.cool.store.dto.openPreparation.FirstOrderDTO;
|
||||
@@ -50,7 +51,8 @@ public class FirstOrderServiceImp implements FirstOrderService {
|
||||
private ShopStageInfoDAO shopStageInfoDAO;
|
||||
@Resource
|
||||
private CoolStoreStartFlowService coolStoreStartFlowService;
|
||||
|
||||
@Resource
|
||||
private EnterpriseUserDAO enterpriseUserDAO;
|
||||
@Override
|
||||
public Integer saveOrder(FirstOrderRequest request, LoginUserInfo user) {
|
||||
log.info("save order:{}", JSONObject.toJSONString(request));
|
||||
@@ -116,11 +118,17 @@ public class FirstOrderServiceImp implements FirstOrderService {
|
||||
ShopStageInfoDO shopSubStageInfo = shopStageInfoDAO.getShopSubStageInfo(shopId, ShopSubStageEnum.SHOP_STAGE_15);
|
||||
if (ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_151.getShopSubStageStatus().equals(shopSubStageInfo.getShopSubStageStatus()))
|
||||
{
|
||||
|
||||
String userName = enterpriseUserDAO.getUserName(order.getCreateUserId());
|
||||
order.setPartnerName(userName);
|
||||
order.setFirstOrderSubStage( ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_151.getShopSubStageStatus());
|
||||
return order;
|
||||
}
|
||||
if (Objects.nonNull(order)) {
|
||||
try {
|
||||
|
||||
String userName = enterpriseUserDAO.getUserName(order.getCreateUserId());
|
||||
order.setPartnerName(userName);
|
||||
ShopInfoDO shopInfo = shopService.getShopInfo(order.getShopId());
|
||||
String storeNum = shopInfo.getStoreNum();
|
||||
Boolean flag = coolStoreStartFlowService.getFirstOrder(storeNum);
|
||||
|
||||
Reference in New Issue
Block a user