## 商品订单添加加购条件;
This commit is contained in:
parent
7bb2b0c01c
commit
bfc02d048e
|
@ -5,7 +5,6 @@ import cn.hutool.core.collection.CollectionUtil;
|
|||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.hzs.common.core.annotation.AccessPermissions;
|
||||
import com.hzs.common.core.annotation.Log;
|
||||
import com.hzs.common.core.constant.EnumsPrefixConstants;
|
||||
import com.hzs.common.core.enums.*;
|
||||
import com.hzs.common.core.utils.DateUtils;
|
||||
import com.hzs.common.core.utils.StringUtils;
|
||||
|
@ -15,7 +14,6 @@ import com.hzs.common.core.web.page.TableDataInfo;
|
|||
import com.hzs.common.domain.sale.ext.SaOrderItemsExt;
|
||||
import com.hzs.common.domain.sale.order.SaOrderRemarks;
|
||||
import com.hzs.common.security.utils.SecurityUtils;
|
||||
import com.hzs.common.service.ITransactionCommonService;
|
||||
import com.hzs.sale.order.controller.ParentOrderController;
|
||||
import com.hzs.sale.order.dto.OrderBusinessTemplate;
|
||||
import com.hzs.sale.order.param.*;
|
||||
|
@ -47,8 +45,6 @@ import java.util.stream.Collectors;
|
|||
@Slf4j
|
||||
public class SaOrderController extends ParentOrderController {
|
||||
|
||||
@Autowired
|
||||
private ITransactionCommonService iTransactionCommonService;
|
||||
@Autowired
|
||||
private ISaOrderService iSaOrderService;
|
||||
@Autowired
|
||||
|
@ -109,50 +105,18 @@ public class SaOrderController extends ParentOrderController {
|
|||
if (waresOrderVo.getRecCountry() != null) {
|
||||
waresOrderVo.setRecCountryName(areaMap.get(waresOrderVo.getRecCountry()));
|
||||
}
|
||||
// 发货方式
|
||||
if (null != waresOrderVo.getDeliveryWay()) {
|
||||
EDelivery eDelivery = EDelivery.getDelivery(waresOrderVo.getDeliveryWay());
|
||||
if (null != eDelivery) {
|
||||
waresOrderVo.setDeliveryWayStr(eDelivery.getLabel());
|
||||
}
|
||||
}
|
||||
// 运输方式
|
||||
if (waresOrderVo.getTranType() != null) {
|
||||
waresOrderVo.setTranTypeStr(ETransportType.getETransportType(waresOrderVo.getTranType()).getLabel());
|
||||
}
|
||||
// 预售状态
|
||||
if (waresOrderVo.getPreSaleStatus() != null) {
|
||||
waresOrderVo.setPreSaleStatusStr(EPresaleStatus.getEPresaleStatus(waresOrderVo.getPreSaleStatus()).getLabel());
|
||||
}
|
||||
// 订单状态
|
||||
if (waresOrderVo.getOrderStatus() != null) {
|
||||
EOrderStatus orderStatusEnum = EOrderStatus.getEOrderStatus(waresOrderVo.getOrderStatus());
|
||||
if (orderStatusEnum != null) {
|
||||
waresOrderVo.setOrderStatusStr(orderStatusEnum.getLabel());
|
||||
}
|
||||
}
|
||||
// 支付方式
|
||||
if (waresOrderVo.getPayType() != null) {
|
||||
EOrderPayType eOrderPayType = EOrderPayType.getEnumByValue(waresOrderVo.getPayType());
|
||||
if (null != eOrderPayType) {
|
||||
waresOrderVo.setPayTypeStr(eOrderPayType.getLabel());
|
||||
}
|
||||
}
|
||||
// 订单类型
|
||||
if (waresOrderVo.getOrderType() != null) {
|
||||
EOrderType eOrderType = EOrderType.getEnumByValue(waresOrderVo.getOrderType());
|
||||
if (null != eOrderType) {
|
||||
waresOrderVo.setOrderTypeStr(eOrderType.getLabel());
|
||||
}
|
||||
}
|
||||
// 供应方式
|
||||
if (StringUtils.isNotBlank(waresOrderVo.getOperateScope())) {
|
||||
ESupplyWay eSupplyWay = ESupplyWay.getESupplyWay(Integer.parseInt(waresOrderVo.getOperateScope()));
|
||||
if (null != eSupplyWay) {
|
||||
waresOrderVo.setOperateScope(eSupplyWay.getLabel());
|
||||
}
|
||||
}
|
||||
|
||||
waresOrderVo.setOrderTypeStr(EOrderType.getLabelByValue(waresOrderVo.getOrderType()));
|
||||
// 发货方式
|
||||
waresOrderVo.setDeliveryWayStr(EDelivery.getLabelByValue(waresOrderVo.getDeliveryWay()));
|
||||
// 运输方式
|
||||
waresOrderVo.setTranTypeStr(ETransportType.getLabelByValue(waresOrderVo.getTranType()));
|
||||
// 预售状态
|
||||
waresOrderVo.setPreSaleStatusStr(EPresaleStatus.getLabelByValue(waresOrderVo.getPreSaleStatus()));
|
||||
// 订单状态
|
||||
waresOrderVo.setOrderStatusStr(EOrderStatus.getLabelByValue(waresOrderVo.getOrderStatus()));
|
||||
// 支付方式
|
||||
waresOrderVo.setPayTypeStr(EOrderPayType.getLabelByValue(waresOrderVo.getPayType()));
|
||||
}
|
||||
return getDataTable(resultList);
|
||||
}
|
||||
|
@ -187,8 +151,6 @@ public class SaOrderController extends ParentOrderController {
|
|||
waresOrderParam.setTeamList(userAuthorityDTO.getUserTeamList());
|
||||
|
||||
List<WaresOrderVo> resultList = iSaOrderService.selectByOrderInfoList(waresOrderParam);
|
||||
// 获取需要翻译的枚举翻译
|
||||
Map<String, String> transactionMap = iTransactionCommonService.exportEnumTransaction(EOrderType.values(), EShippingChannel.values());
|
||||
for (WaresOrderVo waresOrderVo : resultList) {
|
||||
// 省
|
||||
if (waresOrderVo.getRecProvince() != null) {
|
||||
|
@ -202,39 +164,18 @@ public class SaOrderController extends ParentOrderController {
|
|||
if (waresOrderVo.getRecCountry() != null) {
|
||||
waresOrderVo.setRecCountryName(areaMap.get(waresOrderVo.getRecCountry()));
|
||||
}
|
||||
// 发货方式
|
||||
waresOrderVo.setDeliveryWayStr(EDelivery.getDelivery(waresOrderVo.getDeliveryWay()).getLabel());
|
||||
// 运输方式
|
||||
if (waresOrderVo.getTranType() != null && ETransportType.getETransportType(waresOrderVo.getTranType()) != null) {
|
||||
waresOrderVo.setTranTypeStr(ETransportType.getETransportType(waresOrderVo.getTranType()).getLabel());
|
||||
}
|
||||
// 预售状态
|
||||
if (waresOrderVo.getPreSaleStatus() != null && EPresaleStatus.getEPresaleStatus(waresOrderVo.getPreSaleStatus()) != null) {
|
||||
waresOrderVo.setPreSaleStatusStr(EPresaleStatus.getEPresaleStatus(waresOrderVo.getPreSaleStatus()).getLabel());
|
||||
}
|
||||
// 订单状态
|
||||
if (waresOrderVo.getOrderStatus() != null) {
|
||||
EOrderStatus orderStatusEnum = EOrderStatus.getEOrderStatus(waresOrderVo.getOrderStatus());
|
||||
if (orderStatusEnum != null) {
|
||||
waresOrderVo.setOrderStatusStr(orderStatusEnum.getLabel());
|
||||
}
|
||||
}
|
||||
// 支付方式
|
||||
if (waresOrderVo.getPayType() != null) {
|
||||
waresOrderVo.setPayTypeStr(EOrderPayType.getEnumByValue(waresOrderVo.getPayType()).getLabel());
|
||||
}
|
||||
// 订单类型
|
||||
if (waresOrderVo.getOrderType() != null) {
|
||||
waresOrderVo.setOrderTypeVal(transactionMap.get(EnumsPrefixConstants.ORDER_TYPE + waresOrderVo.getOrderType()));
|
||||
}
|
||||
// 供应方式
|
||||
if (StringUtils.isNotBlank(waresOrderVo.getOperateScope()) && ESupplyWay.getESupplyWay(Integer.parseInt(waresOrderVo.getOperateScope())) != null) {
|
||||
waresOrderVo.setOperateScope(ESupplyWay.getESupplyWay(Integer.parseInt(waresOrderVo.getOperateScope())).getLabel());
|
||||
}
|
||||
// 发货类型
|
||||
waresOrderVo.setShippingChannelVal(transactionMap.get(EnumsPrefixConstants.E_SHIPPING_CHANNEL + waresOrderVo.getShippingChannel()));
|
||||
waresOrderVo.setLogisticsCode(waresOrderVo.getLogisticsCode());
|
||||
waresOrderVo.setLogisticsCompany(waresOrderVo.getLogisticsCompany());
|
||||
waresOrderVo.setOrderTypeVal(EOrderType.getLabelByValue(waresOrderVo.getOrderType()));
|
||||
// 发货方式
|
||||
waresOrderVo.setDeliveryWayStr(EDelivery.getLabelByValue(waresOrderVo.getDeliveryWay()));
|
||||
// 运输方式
|
||||
waresOrderVo.setTranTypeStr(ETransportType.getLabelByValue(waresOrderVo.getTranType()));
|
||||
// 预售状态
|
||||
waresOrderVo.setPreSaleStatusStr(EPresaleStatus.getLabelByValue(waresOrderVo.getPreSaleStatus()));
|
||||
// 订单状态
|
||||
waresOrderVo.setOrderStatusStr(EOrderStatus.getLabelByValue(waresOrderVo.getOrderStatus()));
|
||||
// 支付方式
|
||||
waresOrderVo.setPayTypeStr(EOrderPayType.getLabelByValue(waresOrderVo.getPayType()));
|
||||
}
|
||||
ExcelUtil<WaresOrderVo> util = new ExcelUtil<>(WaresOrderVo.class, iMenuColumnServiceApi.queryMenuColumn("Commodity", SecurityUtils.getUserId()).getData());
|
||||
util.exportExcel(response, resultList, "商品订单导出");
|
||||
|
@ -261,8 +202,6 @@ public class SaOrderController extends ParentOrderController {
|
|||
waresOrderParam.setEndCreateDate(DateUtils.getEndTime(waresOrderParam.getEndCreateDate()));
|
||||
}
|
||||
|
||||
// 获取需要翻译的枚举翻译
|
||||
Map<String, String> transactionMap = iTransactionCommonService.exportEnumTransaction(EDelivery.values(), ESupplyWay.values());
|
||||
Map<Integer, String> areaMap = iAreaServiceApi.getAreaMap(SecurityUtils.getPkCountry()).getData();
|
||||
|
||||
startPage();
|
||||
|
@ -281,42 +220,23 @@ public class SaOrderController extends ParentOrderController {
|
|||
waresOrderVo.setRecCountryName(areaMap.get(waresOrderVo.getRecCountry()));
|
||||
}
|
||||
// 发货方式
|
||||
if (null != waresOrderVo.getDeliveryWay()) {
|
||||
waresOrderVo.setDeliveryWayStr(transactionMap.get(EnumsPrefixConstants.DELIVERY + waresOrderVo.getDeliveryWay()));
|
||||
}
|
||||
waresOrderVo.setDeliveryWayStr(EDelivery.getLabelByValue(waresOrderVo.getDeliveryWay()));
|
||||
// 运输方式
|
||||
if (waresOrderVo.getTranType() != null) {
|
||||
waresOrderVo.setTranTypeStr(ETransportType.getETransportType(waresOrderVo.getTranType()).getLabel());
|
||||
}
|
||||
|
||||
waresOrderVo.setTranTypeStr(ETransportType.getLabelByValue(waresOrderVo.getTranType()));
|
||||
// 预售状态
|
||||
if (waresOrderVo.getPreSaleStatus() != null) {
|
||||
waresOrderVo.setPreSaleStatusStr(EPresaleStatus.getEPresaleStatus(waresOrderVo.getPreSaleStatus()).getLabel());
|
||||
}
|
||||
waresOrderVo.setPreSaleStatusStr(EPresaleStatus.getLabelByValue(waresOrderVo.getPreSaleStatus()));
|
||||
// 订单状态
|
||||
if (waresOrderVo.getOrderStatus() != null) {
|
||||
waresOrderVo.setOrderStatusStr(EOrderStatus.getEOrderStatus(waresOrderVo.getOrderStatus()).getLabel());
|
||||
}
|
||||
waresOrderVo.setOrderStatusStr(EOrderStatus.getLabelByValue(waresOrderVo.getOrderStatus()));
|
||||
// 支付方式
|
||||
if (waresOrderVo.getPayType() != null) {
|
||||
waresOrderVo.setPayTypeStr(EOrderPayType.getEnumByValue(waresOrderVo.getPayType()).getLabel());
|
||||
}
|
||||
waresOrderVo.setPayTypeStr(EOrderPayType.getLabelByValue(waresOrderVo.getPayType()));
|
||||
// 订单类型
|
||||
if (waresOrderVo.getOrderType() != null) {
|
||||
waresOrderVo.setOrderTypeStr(EOrderType.getEnumByValue(waresOrderVo.getOrderType()).getLabel());
|
||||
}
|
||||
waresOrderVo.setOrderTypeStr(EOrderType.getLabelByValue(waresOrderVo.getOrderType()));
|
||||
// 供应方式
|
||||
if (StringUtils.isNotBlank(waresOrderVo.getOperateScope())) {
|
||||
waresOrderVo.setOperateScope(ESupplyWay.getESupplyWay(Integer.parseInt(waresOrderVo.getOperateScope())).getLabel());
|
||||
}
|
||||
// 计算汇率
|
||||
if (null != waresOrderVo.getInExchangeRate()) {
|
||||
waresOrderVo.setOrderAchieve(waresOrderVo.getInExchangeRate().multiply(waresOrderVo.getOrderAchieve()));
|
||||
waresOrderVo.setOperateScope(ESupplyWay.getLabelByVal(Integer.parseInt(waresOrderVo.getOperateScope())));
|
||||
}
|
||||
// 发货类型
|
||||
if (waresOrderVo.getShippingChannel() != null) {
|
||||
waresOrderVo.setShippingChannelStr(EShippingChannel.getEnumByValue(waresOrderVo.getShippingChannel()).getLabel());
|
||||
}
|
||||
waresOrderVo.setShippingChannelStr(EShippingChannel.getLabelByValue(waresOrderVo.getShippingChannel()));
|
||||
// 计算产品总计
|
||||
waresOrderVo.setProductPriceTotal(waresOrderVo.getProductPrice().multiply(BigDecimal.valueOf(waresOrderVo.getQuantity())));
|
||||
}
|
||||
|
@ -348,8 +268,6 @@ public class SaOrderController extends ParentOrderController {
|
|||
}
|
||||
|
||||
Map<Integer, String> areaMap = iAreaServiceApi.getAreaMap(SecurityUtils.getPkCountry()).getData();
|
||||
// 获取需要翻译的枚举翻译
|
||||
Map<String, String> transactionMap = iTransactionCommonService.exportEnumTransaction(EDelivery.values(), ESupplyWay.values());
|
||||
|
||||
List<WaresOrderVo> resultList = iSaOrderItemsService.selectByInvestmentList(waresOrderParam);
|
||||
for (WaresOrderVo waresOrderVo : resultList) {
|
||||
|
@ -366,56 +284,23 @@ public class SaOrderController extends ParentOrderController {
|
|||
waresOrderVo.setRecCountryName(areaMap.get(waresOrderVo.getRecCountry()));
|
||||
}
|
||||
// 发货方式
|
||||
if (waresOrderVo.getDeliveryWay() != null) {
|
||||
waresOrderVo.setDeliveryWayStr(transactionMap.get(EnumsPrefixConstants.DELIVERY + waresOrderVo.getDeliveryWay()));
|
||||
}
|
||||
|
||||
waresOrderVo.setDeliveryWayStr(EDelivery.getLabelByValue(waresOrderVo.getDeliveryWay()));
|
||||
// 运输方式
|
||||
if (waresOrderVo.getTranType() != null) {
|
||||
ETransportType transportType = ETransportType.getETransportType(waresOrderVo.getTranType());
|
||||
if (transportType != null) {
|
||||
waresOrderVo.setTranTypeStr(transportType.getLabel());
|
||||
}
|
||||
}
|
||||
|
||||
waresOrderVo.setTranTypeStr(ETransportType.getLabelByValue(waresOrderVo.getTranType()));
|
||||
// 预售状态
|
||||
if (waresOrderVo.getPreSaleStatus() != null) {
|
||||
EPresaleStatus presaleStatus = EPresaleStatus.getEPresaleStatus(waresOrderVo.getPreSaleStatus());
|
||||
if (presaleStatus != null) {
|
||||
waresOrderVo.setPreSaleStatusStr(presaleStatus.getLabel());
|
||||
}
|
||||
}
|
||||
waresOrderVo.setPreSaleStatusStr(EPresaleStatus.getLabelByValue(waresOrderVo.getPreSaleStatus()));
|
||||
// 订单状态
|
||||
if (waresOrderVo.getOrderStatus() != null) {
|
||||
EOrderStatus orderStatus = EOrderStatus.getEOrderStatus(waresOrderVo.getOrderStatus());
|
||||
if (orderStatus != null) {
|
||||
waresOrderVo.setOrderStatusStr(orderStatus.getLabel());
|
||||
}
|
||||
}
|
||||
waresOrderVo.setOrderStatusStr(EOrderStatus.getLabelByValue(waresOrderVo.getOrderStatus()));
|
||||
// 支付方式
|
||||
if (waresOrderVo.getPayType() != null) {
|
||||
EOrderPayType orderPayType = EOrderPayType.getEnumByValue(waresOrderVo.getPayType());
|
||||
if (orderPayType != null) {
|
||||
waresOrderVo.setPayTypeStr(orderPayType.getLabel());
|
||||
}
|
||||
}
|
||||
waresOrderVo.setPayTypeStr(EOrderPayType.getLabelByValue(waresOrderVo.getPayType()));
|
||||
// 订单类型
|
||||
if (waresOrderVo.getOrderType() != null) {
|
||||
EOrderType orderType = EOrderType.getEnumByValue(waresOrderVo.getOrderType());
|
||||
if (orderType != null) {
|
||||
waresOrderVo.setOrderTypeStr(orderType.getLabel());
|
||||
}
|
||||
}
|
||||
waresOrderVo.setOrderTypeStr(EOrderType.getLabelByValue(waresOrderVo.getOrderType()));
|
||||
// 供应方式
|
||||
if (StringUtils.isNotBlank(waresOrderVo.getOperateScope()) && ESupplyWay.getESupplyWay(Integer.parseInt(waresOrderVo.getOperateScope())) != null) {
|
||||
waresOrderVo.setOperateScope(ESupplyWay.getESupplyWay(Integer.parseInt(waresOrderVo.getOperateScope())).getLabel());
|
||||
if (StringUtils.isNotBlank(waresOrderVo.getOperateScope())) {
|
||||
waresOrderVo.setOperateScope(ESupplyWay.getLabelByVal(Integer.parseInt(waresOrderVo.getOperateScope())));
|
||||
}
|
||||
// 计算汇率
|
||||
waresOrderVo.setOrderAchieve(waresOrderVo.getInExchangeRate().multiply(waresOrderVo.getOrderAchieve()));
|
||||
// 发货类型
|
||||
if (waresOrderVo.getShippingChannel() != null) {
|
||||
waresOrderVo.setShippingChannelStr(EShippingChannel.getEnumByValue(waresOrderVo.getShippingChannel()).getLabel());
|
||||
}
|
||||
waresOrderVo.setShippingChannelStr(EShippingChannel.getLabelByValue(waresOrderVo.getShippingChannel()));
|
||||
}
|
||||
List<WaresOrderInfoVo> waresOrderInfoList = resultList.stream().map(a -> {
|
||||
WaresOrderInfoVo waresOrderInfoVo = BeanUtil.copyProperties(a, WaresOrderInfoVo.class);
|
||||
|
@ -627,7 +512,6 @@ public class SaOrderController extends ParentOrderController {
|
|||
*/
|
||||
@PostMapping("/single-item-stat-export")
|
||||
public void singleItemStatExport(SingleItemStatParam singleItemStatParam, HttpServletResponse response) {
|
||||
|
||||
if (StringUtils.isBlank(singleItemStatParam.getSkuCode())
|
||||
&& StringUtils.isBlank(singleItemStatParam.getProductName())
|
||||
&& singleItemStatParam.getOrderType() == null
|
||||
|
|
|
@ -149,13 +149,11 @@ public class WaresOrderParam extends BaseAuthorityEntity {
|
|||
/**
|
||||
* 购买人编号
|
||||
*/
|
||||
|
||||
private String buyMemberCode;
|
||||
|
||||
/**
|
||||
* 购买人姓名
|
||||
*/
|
||||
|
||||
private String buyMemberName;
|
||||
/**
|
||||
* 商品编号
|
||||
|
@ -170,4 +168,10 @@ public class WaresOrderParam extends BaseAuthorityEntity {
|
|||
* 隶属体系
|
||||
*/
|
||||
private Integer vertexId;
|
||||
|
||||
/**
|
||||
* 是否加购商品
|
||||
*/
|
||||
private Integer addPurchaseFlag;
|
||||
|
||||
}
|
||||
|
|
|
@ -38,6 +38,7 @@ public class WaresOrderInfoVo implements Serializable {
|
|||
/**
|
||||
* 重量
|
||||
*/
|
||||
@BigDecimalFormat
|
||||
@Excel(name = "重量(KG)")
|
||||
private BigDecimal weight;
|
||||
/**
|
||||
|
@ -157,7 +158,7 @@ public class WaresOrderInfoVo implements Serializable {
|
|||
/**
|
||||
* 省名称
|
||||
*/
|
||||
@Excel(name = "省名称")
|
||||
@Excel(name = "省")
|
||||
private String recProvinceName;
|
||||
/**
|
||||
* 市外键
|
||||
|
@ -167,7 +168,7 @@ public class WaresOrderInfoVo implements Serializable {
|
|||
/**
|
||||
* 市名称
|
||||
*/
|
||||
@Excel(name = "市名称")
|
||||
@Excel(name = "市")
|
||||
private String recCityName;
|
||||
|
||||
/**
|
||||
|
@ -178,7 +179,7 @@ public class WaresOrderInfoVo implements Serializable {
|
|||
/**
|
||||
* 县名称
|
||||
*/
|
||||
@Excel(name = "县名称")
|
||||
@Excel(name = "县")
|
||||
private String recCountryName;
|
||||
/**
|
||||
* 详细地址
|
||||
|
@ -289,7 +290,6 @@ public class WaresOrderInfoVo implements Serializable {
|
|||
/**
|
||||
* 系统类型(0=会员系统,1=海圣优选)
|
||||
*/
|
||||
@Excel(name = "系统类型", readConverterExp = "0=会员系统,1=海圣优选")
|
||||
private Integer systemType;
|
||||
|
||||
/**
|
||||
|
|
|
@ -89,12 +89,12 @@ public class WaresOrderVo implements Serializable {
|
|||
*/
|
||||
@Excel(name = "会员姓名")
|
||||
private String memberName;
|
||||
|
||||
/**
|
||||
* 隶属体系
|
||||
*/
|
||||
@Excel(name = "隶属体系")
|
||||
private String vertexName;
|
||||
|
||||
/**
|
||||
* 联系电话
|
||||
*/
|
||||
|
@ -302,13 +302,10 @@ public class WaresOrderVo implements Serializable {
|
|||
/**
|
||||
* 重量
|
||||
*/
|
||||
@BigDecimalFormat
|
||||
private BigDecimal weight;
|
||||
/**
|
||||
* 展示汇率
|
||||
*/
|
||||
private BigDecimal inExchangeRate;
|
||||
/**
|
||||
* 产品订单明细列表
|
||||
* 产品订单明细列表
|
||||
*/
|
||||
private List<MyOrderItemsVO> productList;
|
||||
/**
|
||||
|
|
|
@ -746,7 +746,6 @@
|
|||
oi.SPECS_NAME specsName,
|
||||
bp.WEIGHT weight,
|
||||
bp.SHIPPING_CHANNEL shippingChannel,
|
||||
bc.IN_EXCHANGE_RATE inExchangeRate,
|
||||
oi.LOGISTICS_CODE logisticsCode,
|
||||
oi.LOGISTICS_COMPANY logisticsCompany,
|
||||
m.MEMBER_CODE buyMemberCode,
|
||||
|
@ -760,14 +759,21 @@
|
|||
ver.VERTEX_NAME vertexName
|
||||
from sa_order_items oi
|
||||
left join sa_order so on oi.PK_ORDER = so.PK_ID
|
||||
left join BD_CURRENCY bc on bc.PK_ID = so.PK_RATE
|
||||
left join CU_MEMBER cm on cm.PK_ID = so.PK_MEMBER
|
||||
left join BD_WARES_EXTEND we on we.PK_WARES = oi.PK_WARES
|
||||
left join BD_WARES bw on bw.PK_ID = we.PK_WARES
|
||||
left join BD_PRODUCT bp on bp.PK_ID = oi.PK_PRODUCT
|
||||
left join CU_MEMBER m on m.PK_ID = so.PK_CREATOR
|
||||
left join BD_VERTEX ver on ver.PK_ID = cm.PK_VERTEX
|
||||
where oi.del_flag = 0 and so.del_flag=0 and ver.del_flag=0
|
||||
left join cu_member m on m.PK_ID = so.PK_CREATOR
|
||||
left join cu_member cm on cm.PK_ID = so.PK_MEMBER
|
||||
left join bd_vertex ver on ver.PK_ID = cm.PK_VERTEX
|
||||
left join bd_wares_extend we on we.PK_WARES = oi.PK_WARES
|
||||
left join bd_wares bw on bw.PK_ID = we.PK_WARES
|
||||
left join bd_product bp on bp.PK_ID = oi.PK_PRODUCT
|
||||
where oi.del_flag = 0 and so.del_flag = 0 and ver.del_flag = 0
|
||||
<if test="addPurchaseFlag != null and addPurchaseFlag == 0">
|
||||
and oi.pk_order in (
|
||||
select distinct soi.pk_order
|
||||
from sa_order_items soi
|
||||
where soi.is_maker_gift = 3
|
||||
and soi.del_flag = 0
|
||||
)
|
||||
</if>
|
||||
<if test="buyMemberCode != null and buyMemberCode != ''">
|
||||
and m.MEMBER_CODE like #{buyMemberCode}||'%'
|
||||
</if>
|
||||
|
|
|
@ -661,6 +661,14 @@
|
|||
left join BD_VERTEX ver on ver.PK_ID = cm.PK_VERTEX
|
||||
where so.DEL_FLAG = 0
|
||||
and ver.DEL_FLAG = 0
|
||||
<if test="addPurchaseFlag != null and addPurchaseFlag == 0">
|
||||
and oi.pk_order in (
|
||||
select distinct soi.pk_order
|
||||
from sa_order_items soi
|
||||
where soi.is_maker_gift = 3
|
||||
and soi.del_flag = 0
|
||||
)
|
||||
</if>
|
||||
<if test="pkCountry != null">
|
||||
and so.PK_COUNTRY = #{pkCountry}
|
||||
</if>
|
||||
|
|
|
@ -48,4 +48,17 @@ public enum EDelivery {
|
|||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public static String getLabelByValue(Integer value) {
|
||||
if (null == value) {
|
||||
return "";
|
||||
}
|
||||
for (EDelivery enums : EDelivery.values()) {
|
||||
if (enums.getValue() == value) {
|
||||
return enums.getLabel();
|
||||
}
|
||||
}
|
||||
return "";
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -41,18 +41,16 @@ public enum EOrderPayType {
|
|||
private final String key;
|
||||
|
||||
|
||||
/**
|
||||
* 根据值获取枚举
|
||||
*
|
||||
* @param value
|
||||
* @return
|
||||
*/
|
||||
public static EOrderPayType getEnumByValue(int value) {
|
||||
public static String getLabelByValue(Integer value) {
|
||||
if (null == value) {
|
||||
return "";
|
||||
}
|
||||
for (EOrderPayType enums : EOrderPayType.values()) {
|
||||
if (enums.getValue() == value) {
|
||||
return enums;
|
||||
if (enums.value == value) {
|
||||
return enums.getLabel();
|
||||
}
|
||||
}
|
||||
return null;
|
||||
return "";
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -68,22 +68,6 @@ public enum EOrderStatus {
|
|||
*/
|
||||
private static List<EOrderStatus> apiList;
|
||||
|
||||
/**
|
||||
* 获取会员前端列表
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public static List<EOrderStatus> getApiList() {
|
||||
if (null == apiList) {
|
||||
apiList = new ArrayList<>();
|
||||
apiList.add(WAIT_PAY);
|
||||
apiList.add(PAY);
|
||||
apiList.add(DELIVERED);
|
||||
apiList.add(RECEIVED);
|
||||
}
|
||||
return apiList;
|
||||
}
|
||||
|
||||
public static EOrderStatus getEOrderStatus(int value) {
|
||||
for (EOrderStatus eOrderStatus : EOrderStatus.values()) {
|
||||
if (eOrderStatus.value == value) {
|
||||
|
@ -93,4 +77,16 @@ public enum EOrderStatus {
|
|||
return null;
|
||||
}
|
||||
|
||||
public static String getLabelByValue(Integer value) {
|
||||
if (null == value) {
|
||||
return "";
|
||||
}
|
||||
for (EOrderStatus enums : EOrderStatus.values()) {
|
||||
if (enums.value == value) {
|
||||
return enums.getLabel();
|
||||
}
|
||||
}
|
||||
return "";
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -5,7 +5,7 @@ import lombok.AllArgsConstructor;
|
|||
import lombok.Getter;
|
||||
|
||||
/**
|
||||
* @Description: 产品发货渠道
|
||||
* 产品发货渠道
|
||||
*/
|
||||
@AllArgsConstructor
|
||||
@Getter
|
||||
|
@ -44,4 +44,17 @@ public enum EShippingChannel {
|
|||
}
|
||||
return TOTAL_WAREHOUSE;
|
||||
}
|
||||
|
||||
public static String getLabelByValue(Integer value) {
|
||||
if (null == value) {
|
||||
return "";
|
||||
}
|
||||
for (EShippingChannel enums : EShippingChannel.values()) {
|
||||
if (enums.value == value) {
|
||||
return enums.getLabel();
|
||||
}
|
||||
}
|
||||
return "";
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -44,12 +44,16 @@ public enum ETransportType {
|
|||
private final String key;
|
||||
|
||||
|
||||
public static ETransportType getETransportType(int value) {
|
||||
for (ETransportType eTransportType : ETransportType.values()) {
|
||||
if (eTransportType.getValue() == value) {
|
||||
return eTransportType;
|
||||
public static String getLabelByValue(Integer value) {
|
||||
if (null == value) {
|
||||
return "";
|
||||
}
|
||||
for (ETransportType enums : ETransportType.values()) {
|
||||
if (enums.value == value) {
|
||||
return enums.getLabel();
|
||||
}
|
||||
}
|
||||
return null;
|
||||
return "";
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue