Merge branch 'master' of gitee.com:beijing_hongye_huicheng/lilishop
This commit is contained in:
commit
f9112c4b39
@ -180,11 +180,28 @@ public class StoreDetail extends BaseIdEntity {
|
|||||||
|
|
||||||
public StoreDetail(Store store, AdminStoreApplyDTO adminStoreApplyDTO) {
|
public StoreDetail(Store store, AdminStoreApplyDTO adminStoreApplyDTO) {
|
||||||
this.storeId = store.getId();
|
this.storeId = store.getId();
|
||||||
|
//过滤字段值
|
||||||
|
isNotNull(adminStoreApplyDTO);
|
||||||
//设置店铺公司信息、设置店铺银行信息、设置店铺其他信息
|
//设置店铺公司信息、设置店铺银行信息、设置店铺其他信息
|
||||||
BeanUtil.copyProperties(adminStoreApplyDTO, this);
|
BeanUtil.copyProperties(adminStoreApplyDTO, this);
|
||||||
this.settlementDay = DateUtil.date();
|
this.settlementDay = DateUtil.date();
|
||||||
this.stockWarning = 10;
|
this.stockWarning = 10;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void isNotNull(AdminStoreApplyDTO adminStoreApplyDTO){
|
||||||
|
if("null".equals(adminStoreApplyDTO.getSalesConsigneeName())){
|
||||||
|
adminStoreApplyDTO.setSalesConsigneeName("");
|
||||||
|
}
|
||||||
|
if("null".equals(adminStoreApplyDTO.getSalesConsigneeMobile())){
|
||||||
|
adminStoreApplyDTO.setSalesConsigneeMobile("");
|
||||||
|
}
|
||||||
|
if("null".equals(adminStoreApplyDTO.getSalesConsigneeDetail())){
|
||||||
|
adminStoreApplyDTO.setSalesConsigneeDetail("");
|
||||||
|
}
|
||||||
|
if("null".equals(adminStoreApplyDTO.getDdCode())){
|
||||||
|
adminStoreApplyDTO.setDdCode("");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
@ -75,7 +75,8 @@ public class StoreDetailServiceImpl extends ServiceImpl<StoreDetailMapper, Store
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public StoreDetailVO getStoreDetailVO(String storeId) {
|
public StoreDetailVO getStoreDetailVO(String storeId) {
|
||||||
return this.baseMapper.getStoreDetail(storeId);
|
StoreDetailVO storeDetail = this.baseMapper.getStoreDetail(storeId);
|
||||||
|
return storeDetail;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -115,7 +115,6 @@ public class StoreServiceImpl extends ServiceImpl<StoreMapper, Store> implements
|
|||||||
if (Boolean.TRUE.equals(member.getHaveStore())) {
|
if (Boolean.TRUE.equals(member.getHaveStore())) {
|
||||||
throw new ServiceException(ResultCode.STORE_APPLY_DOUBLE_ERROR);
|
throw new ServiceException(ResultCode.STORE_APPLY_DOUBLE_ERROR);
|
||||||
}
|
}
|
||||||
|
|
||||||
//添加店铺
|
//添加店铺
|
||||||
Store store = new Store(member, adminStoreApplyDTO);
|
Store store = new Store(member, adminStoreApplyDTO);
|
||||||
this.save(store);
|
this.save(store);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user