Commit 258f273d by guojuxing

pmd

parent 68fd06b5
......@@ -61,6 +61,7 @@ public class ProvincesController {
}
return RestResponse.success(resultList);
}
default:
}
return RestResponse.success();
}
......
......@@ -24,12 +24,16 @@ import java.util.List;
/**
*
* 门店表情
* @ClassName: ScreeningController

* @Description: 

* @author boom

* @date 2020/9/14 10:36 AM

*/
@Controller
public class ScreeningController {
private Logger LOGGER = LogManager.getLogger(ScreeningController.class);
private static final Logger LOGGER = LogManager.getLogger(ScreeningController.class);
@Autowired
private EsScreeningInitService esScreeningInitService;
......
......@@ -110,7 +110,7 @@ public class StoreController {
storeSearchDTO.setEnterpriseId(enterpriseId);
storeSearchDTO.setSearchJson(storeWidgetCountQO.getSearchJson());
storeSearchDTO.setAuthSearchJson(storeWidgetCountQO.getAuthSearchJson());
ServiceResponse<Long> response = storeApiService.queryStoreCountFromES(storeSearchDTO);
ServiceResponse<Long> response = storeApiService.queryStoreCountFromEs(storeSearchDTO);
return RestResponse.success(response.getResult());
}
......
......@@ -74,7 +74,7 @@ public class UploadImgController {
List<MultipartFile> list = multiRequest.getMultiFileMap().get(fileName);
for (int i = 0; i < list.size(); i++) {
MultipartFile mf = list.get(i);
SimpleDateFormat sdf = new SimpleDateFormat("YYYYMMddHHmmss");
SimpleDateFormat sdf = new SimpleDateFormat("yyyyMMddHHmmss");
//获得原始文件名;
String fileRealName = mf.getOriginalFilename();
//点号的位置
......@@ -121,7 +121,7 @@ public class UploadImgController {
public static File multipartFileToFile(MultipartFile file) throws Exception {
File toFile = null;
if (file.equals("") || file.getSize() <= 0) {
if ("".equals(file) || file.getSize() <= 0) {
file = null;
} else {
InputStream ins = null;
......
......@@ -222,7 +222,18 @@ public class AppletConfigGoodsController extends BaseGoodsController {
}
//type 1商城本体 2商品资料
/**
* type 1商城本体 2商品资料
* @param currentPage
* @param pageSize
* @param goodsDomainId
* @param shopId
* @param search
* @param channelCode
* @param queryObject
* @param type
* @return
*/
private ServiceResponse<ESResponseQueryBatchDTO> searchGoods(Integer currentPage, Integer pageSize,
Long goodsDomainId, Long shopId, String search, String channelCode,
JSONObject queryObject, int type) {
......@@ -243,7 +254,7 @@ public class AppletConfigGoodsController extends BaseGoodsController {
status = QueryConditionAssemblyUtil.createSimpleQueryNode("status", OperateEnum.OPERATE_EQ, 2);
}
if (Constant.CHANNEL_CODE_MALL.equals(channelCode)) {
status = QueryConditionAssemblyUtil.addQueryNodeForSiblin(status, QueryConditionAssemblyUtil.createSimpleQueryNode("upShelfTime", OperateEnum.OPERATE_LTE, new Date().getTime()), OperateEnum.OPERATE_AND);
status = QueryConditionAssemblyUtil.addQueryNodeForSiblin(status, QueryConditionAssemblyUtil.createSimpleQueryNode("upShelfTime", OperateEnum.OPERATE_LTE, System.currentTimeMillis()), OperateEnum.OPERATE_AND);
}
}
String enterpriseId = getEnterpriseId() + "";
......@@ -302,7 +313,6 @@ public class AppletConfigGoodsController extends BaseGoodsController {
* @param cordId
* @return 调试接口
*/
//@RequestMapping("list-integral-goods-selector")
public RestResponse listIntegralGoodsByChannel(@RequestParam(value = "currentPage", defaultValue = "1") Integer currentPage,
@RequestParam(value = "pageSize", defaultValue = "20") Integer pageSize, String appConfigId, Long cordId,String sortColumn,String ids,Integer proType) {
......
......@@ -3,7 +3,13 @@ package com.gic.plug.web.controller.goods;
import com.gic.enterprise.base.EnterpriseInfo;
import com.gic.enterprise.utils.UserDetailUtils;
import com.gic.mall.base.api.exception.GicMallException;
/**
* 商品
* @ClassName: BaseGoodsController

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:45 AM

*/
public class BaseGoodsController {
EnterpriseInfo getLoginEnterpriseInfo() {
......
......@@ -25,7 +25,13 @@ import org.springframework.web.bind.annotation.RestController;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
/**
* 商品
* @ClassName: GoodsBrandController

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:43 AM

*/
@RestController
public class GoodsBrandController extends BaseGoodsController {
......@@ -55,14 +61,14 @@ public class GoodsBrandController extends BaseGoodsController {
} else {
Long resourceId = UserDetailUtils.getUserDetail().getUserResourceInfo() == null ? null :
UserDetailUtils.getUserDetail().getUserResourceInfo().getGoodsResourceId();
ServiceResponse<GoodsRightsSelectorDTO> selectorDTOServiceResponse = goodsRightsSelectorApiService
ServiceResponse<GoodsRightsSelectorDTO> selectorDtoServiceResponse = goodsRightsSelectorApiService
.getGoodsRightsSelector(resourceId, getEnterpriseId()
, UserDetailUtils.getUserDetail().getUserInfo().getSuperAdmin());
if (!selectorDTOServiceResponse.isSuccess() || selectorDTOServiceResponse.getResult() == null ||
selectorDTOServiceResponse.getResult().getHasRights() == Constant.NO) {
if (!selectorDtoServiceResponse.isSuccess() || selectorDtoServiceResponse.getResult() == null ||
selectorDtoServiceResponse.getResult().getHasRights() == Constant.NO) {
return RestResponse.success(Collections.EMPTY_LIST);
}
goodsRightsBrands = selectorDTOServiceResponse.getResult().getGoodsRightsBrands();
goodsRightsBrands = selectorDtoServiceResponse.getResult().getGoodsRightsBrands();
}
// 是否最高权限
List<Long> branIdList = new ArrayList<>();
......
......@@ -14,7 +14,13 @@ import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;
import java.util.List;
/**
* 商品
* @ClassName: GoodsCategoryController

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:44 AM

*/
@RestController
public class GoodsCategoryController extends BaseGoodsController {
......
......@@ -50,9 +50,9 @@ public class GoodsController extends BaseGoodsController {
* @author xub
*/
@GetMapping("list-goods")
public RestResponse ListGoods(@RequestParam(value = "currentPage", defaultValue = "1") Integer currentPage,
public RestResponse listGoods(@RequestParam(value = "currentPage", defaultValue = "1") Integer currentPage,
@RequestParam(value = "pageSize", defaultValue = "20") Integer pageSize, Long goodsDomainId,String search,String channelCode) {
ServiceResponse<ESResponseQueryBatchDTO> serviceResponse = searchES(currentPage,pageSize,goodsDomainId,search,channelCode);
ServiceResponse<ESResponseQueryBatchDTO> serviceResponse = searchEs(currentPage,pageSize,goodsDomainId,search,channelCode);
if (serviceResponse.isSuccess()) {
return RestResponse.success(serviceResponse.getResult());
}
......@@ -68,9 +68,9 @@ public class GoodsController extends BaseGoodsController {
* @author xub
*/
@GetMapping("list-sku")
public RestResponse ListSku(@RequestParam(value = "currentPage", defaultValue = "1") Integer currentPage,
public RestResponse listSku(@RequestParam(value = "currentPage", defaultValue = "1") Integer currentPage,
@RequestParam(value = "pageSize", defaultValue = "20") Integer pageSize, Long goodsDomainId,String search,String channelCode) {
ServiceResponse<ESResponseQueryBatchDTO> serviceResponse = searchES(currentPage,pageSize,goodsDomainId,search ,channelCode);
ServiceResponse<ESResponseQueryBatchDTO> serviceResponse = searchEs(currentPage,pageSize,goodsDomainId,search ,channelCode);
if (!serviceResponse.isSuccess()) {
return RestResponse.failure(serviceResponse.getCode(), serviceResponse.getMessage());
}
......@@ -80,13 +80,13 @@ public class GoodsController extends BaseGoodsController {
return RestResponse.success(Collections.EMPTY_LIST);
}
//1、获取商品信息
List<GoodsVO> goodsVOS = Lists.newArrayList();
List<GoodsVO> goodsVoS = Lists.newArrayList();
for (JSONObject jsonObject : list) {
GoodsVO goodsVO = JSONObject.toJavaObject(jsonObject, GoodsVO.class);
goodsVOS.add(goodsVO);
goodsVoS.add(goodsVO);
}
//2、获取商品ID信息
List<Long> goodsIds = goodsVOS.stream().mapToLong(GoodsVO::getGoodsId).boxed().collect(Collectors.toList());
List<Long> goodsIds = goodsVoS.stream().mapToLong(GoodsVO::getGoodsId).boxed().collect(Collectors.toList());
ServiceResponse<List<GoodsSkuDTO>> skuResponse = goodsApiService.listSku(goodsIds, channelCode, getEnterpriseId());
if (!skuResponse.isSuccess()) {
return RestResponse.failure(skuResponse.getCode(), skuResponse.getMessage());
......@@ -99,19 +99,19 @@ public class GoodsController extends BaseGoodsController {
}
Map<Long, List<GoodsSkuDTO>> goodsIdAndskuDto = skuDTOList.stream().collect(Collectors.groupingBy(GoodsSkuDTO::getGoodsId));
//4、商品信息中包含是sku信息
for (GoodsVO goodsVO : goodsVOS) {
for (GoodsVO goodsVO : goodsVoS) {
if (goodsIdAndskuDto.containsKey(goodsVO.getGoodsId())) {
List<GoodsVO.SkuVO> skuVOList = EntityUtil.changeEntityListByOrika(GoodsVO.SkuVO.class,goodsIdAndskuDto.get(goodsVO.getGoodsId()));
goodsVO.setSkuVOList(skuVOList);
}
}
return RestResponse.success(goodsVOS);
return RestResponse.success(goodsVoS);
}
private ServiceResponse<ESResponseQueryBatchDTO> searchES( Integer currentPage,Integer pageSize, Long goodsDomainId,String search,String channelCode) {
private ServiceResponse<ESResponseQueryBatchDTO> searchEs( Integer currentPage,Integer pageSize, Long goodsDomainId,String search,String channelCode) {
DynamicSearchDTO searchDTO = new DynamicSearchDTO();
String columnCategoryCode = Constant.ES_CODES_MAP.get(channelCode);
String esName = esScreeningSearchService.getCurrentEsName(getEnterpriseId() + "", columnCategoryCode);
......
......@@ -44,7 +44,7 @@ public class GoodsDomainController extends BaseGoodsController {
@RequestMapping("/get-all-goods-domain-list-for-rights")
public RestResponse getAllGoodsDomainListForRights() {
ServiceResponse<List<GoodsDomainDTO>> serviceResponse = goodsDomainApiService
.listAll(getEnterpriseId(), (Integer) null);
.listAll(getEnterpriseId(), (String) null);
if (!serviceResponse.isSuccess()) {
return RestResponse.failure(serviceResponse.getCode(), serviceResponse.getMessage());
}
......@@ -74,16 +74,16 @@ public class GoodsDomainController extends BaseGoodsController {
} else {
Long resourceId = UserDetailUtils.getUserDetail().getUserResourceInfo() == null ? null :
UserDetailUtils.getUserDetail().getUserResourceInfo().getGoodsResourceId();
ServiceResponse<GoodsRightsSelectorDTO> selectorDTOServiceResponse = goodsRightsSelectorApiService.getGoodsRightsSelector(resourceId,
ServiceResponse<GoodsRightsSelectorDTO> selectorDtoServiceResponse = goodsRightsSelectorApiService.getGoodsRightsSelector(resourceId,
getEnterpriseId(), UserDetailUtils.getUserDetail().getUserInfo().getSuperAdmin());
if (!selectorDTOServiceResponse.isSuccess() || selectorDTOServiceResponse.getResult() == null ||
selectorDTOServiceResponse.getResult().getHasRights() == Constant.NO) {
if (!selectorDtoServiceResponse.isSuccess() || selectorDtoServiceResponse.getResult() == null ||
selectorDtoServiceResponse.getResult().getHasRights() == Constant.NO) {
return RestResponse.success(Collections.EMPTY_LIST);
}
goodsDomian = selectorDTOServiceResponse.getResult().getGoodsRightsDomains();
hasRights = selectorDTOServiceResponse.getResult().getHasRights();
goodsDomian = selectorDtoServiceResponse.getResult().getGoodsRightsDomains();
hasRights = selectorDtoServiceResponse.getResult().getHasRights();
}
ServiceResponse<List<GoodsDomainDTO>> serviceResponse = goodsDomainApiService.listAll(getEnterpriseId(), (Integer) null);
ServiceResponse<List<GoodsDomainDTO>> serviceResponse = goodsDomainApiService.listAll(getEnterpriseId(), (String) null);
// 是否最高权限
boolean isHighestRights = true;
JSONObject json = null;
......
......@@ -18,7 +18,13 @@ import org.springframework.web.bind.annotation.RestController;
import java.util.ArrayList;
import java.util.List;
/**
* 商品
* @ClassName: GoodsPropertyController

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:44 AM

*/
@RestController
public class GoodsPropertyController extends BaseGoodsController {
......
......@@ -14,7 +14,13 @@ import org.apache.logging.log4j.Logger;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
/**
* 商品
* @ClassName: GoodsRightsSelectorController

* @Description: 

* @author maj

* @date 2020/9/14 10:41 AM

*/
@RestController
public class GoodsRightsSelectorController extends BaseGoodsController {
......
......@@ -64,12 +64,12 @@ public class GoodsSelectorController extends BaseGoodsController {
goodsSelectorDTO.setEnterpriseId(getEnterpriseId());
Long resourceId = UserDetailUtils.getUserDetail().getUserResourceInfo() == null ? null :
UserDetailUtils.getUserDetail().getUserResourceInfo().getGoodsResourceId();
ServiceResponse<GoodsRightsSelectorDTO> goodsRightsSelectorDTOServiceResponse = goodsRightsSelectorApiService.getGoodsRightsSelector(resourceId,
ServiceResponse<GoodsRightsSelectorDTO> goodsRightsSelectorDtoServiceResponse = goodsRightsSelectorApiService.getGoodsRightsSelector(resourceId,
getEnterpriseId(), UserDetailUtils.getUserDetail().getUserInfo().getSuperAdmin());
if (!goodsRightsSelectorDTOServiceResponse.isSuccess()) {
return RestResponse.failure(goodsRightsSelectorDTOServiceResponse.getCode(), goodsRightsSelectorDTOServiceResponse.getMessage());
if (!goodsRightsSelectorDtoServiceResponse.isSuccess()) {
return RestResponse.failure(goodsRightsSelectorDtoServiceResponse.getCode(), goodsRightsSelectorDtoServiceResponse.getMessage());
}
GoodsRightsSelectorDTO goodsRightsSelectorDTO = goodsRightsSelectorDTOServiceResponse.getResult();
GoodsRightsSelectorDTO goodsRightsSelectorDTO = goodsRightsSelectorDtoServiceResponse.getResult();
goodsSelectorDTO.setHasRights(goodsRightsSelectorDTO.getHasRights());
goodsSelectorDTO.setGoodsSearchRightValue(goodsRightsSelectorDTO.getGoodsRightsSearchValue());
goodsSelectorDTO.setGoodsSearchRightText(goodsRightsSelectorDTO.getGoodsRightsSearchText());
......@@ -90,12 +90,12 @@ public class GoodsSelectorController extends BaseGoodsController {
goodsSelectorDTO.setEnterpriseId(getEnterpriseId());
Long resourceId = UserDetailUtils.getUserDetail().getUserResourceInfo() == null ? null :
UserDetailUtils.getUserDetail().getUserResourceInfo().getGoodsResourceId();
ServiceResponse<GoodsRightsSelectorDTO> goodsRightsSelectorDTOServiceResponse = goodsRightsSelectorApiService.getGoodsRightsSelector(resourceId,
ServiceResponse<GoodsRightsSelectorDTO> goodsRightsSelectorDtoServiceResponse = goodsRightsSelectorApiService.getGoodsRightsSelector(resourceId,
getEnterpriseId(), UserDetailUtils.getUserDetail().getUserInfo().getSuperAdmin());
if (!goodsRightsSelectorDTOServiceResponse.isSuccess()) {
return RestResponse.failure(goodsRightsSelectorDTOServiceResponse.getCode(), goodsRightsSelectorDTOServiceResponse.getMessage());
if (!goodsRightsSelectorDtoServiceResponse.isSuccess()) {
return RestResponse.failure(goodsRightsSelectorDtoServiceResponse.getCode(), goodsRightsSelectorDtoServiceResponse.getMessage());
}
GoodsRightsSelectorDTO goodsRightsSelectorDTO = goodsRightsSelectorDTOServiceResponse.getResult();
GoodsRightsSelectorDTO goodsRightsSelectorDTO = goodsRightsSelectorDtoServiceResponse.getResult();
goodsSelectorDTO.setHasRights(goodsRightsSelectorDTO.getHasRights());
goodsSelectorDTO.setGoodsSearchRightValue(goodsRightsSelectorDTO.getGoodsRightsSearchValue());
goodsSelectorDTO.setGoodsSearchRightText(goodsRightsSelectorDTO.getGoodsRightsSearchText());
......@@ -126,19 +126,19 @@ public class GoodsSelectorController extends BaseGoodsController {
}
Long resourceId = UserDetailUtils.getUserDetail().getUserResourceInfo() == null ? null :
UserDetailUtils.getUserDetail().getUserResourceInfo().getGoodsResourceId();
ServiceResponse<GoodsRightsSelectorDTO> goodsRightsSelectorDTOServiceResponse = goodsRightsSelectorApiService.getGoodsRightsSelector(resourceId,
ServiceResponse<GoodsRightsSelectorDTO> goodsRightsSelectorDtoServiceResponse = goodsRightsSelectorApiService.getGoodsRightsSelector(resourceId,
getEnterpriseId(), UserDetailUtils.getUserDetail().getUserInfo().getSuperAdmin());
if (!goodsRightsSelectorDTOServiceResponse.isSuccess()) {
return RestResponse.failure(goodsRightsSelectorDTOServiceResponse.getCode(), goodsRightsSelectorDTOServiceResponse.getMessage());
if (!goodsRightsSelectorDtoServiceResponse.isSuccess()) {
return RestResponse.failure(goodsRightsSelectorDtoServiceResponse.getCode(), goodsRightsSelectorDtoServiceResponse.getMessage());
}
if (goodsSelectorId == null) {
GoodsRightsSelectorDTO goodsRightsSelectorDTO = new GoodsRightsSelectorDTO();
goodsRightsSelectorDTO.setGoodsRightsSearchText(goodsRightsSelectorDTOServiceResponse.getResult().getGoodsRightsSearchText());
goodsRightsSelectorDTO.setGoodsRightsSearchValue(goodsRightsSelectorDTOServiceResponse.getResult().getGoodsRightsSearchValue());
goodsRightsSelectorDTO.setHasRights(goodsRightsSelectorDTOServiceResponse.getResult().getHasRights());
goodsRightsSelectorDTO.setGoodsRightsSearchText(goodsRightsSelectorDtoServiceResponse.getResult().getGoodsRightsSearchText());
goodsRightsSelectorDTO.setGoodsRightsSearchValue(goodsRightsSelectorDtoServiceResponse.getResult().getGoodsRightsSearchValue());
goodsRightsSelectorDTO.setHasRights(goodsRightsSelectorDtoServiceResponse.getResult().getHasRights());
return RestResponse.success(goodsRightsSelectorDTO);
}
GoodsRightsSelectorDTO goodsRightsSelectorDTO = goodsRightsSelectorDTOServiceResponse.getResult();
GoodsRightsSelectorDTO goodsRightsSelectorDTO = goodsRightsSelectorDtoServiceResponse.getResult();
ServiceResponse<GoodsSelectorDTO> serviceResponse = goodsSelectorApiService.updateGoodsSelectorRights(goodsSelectorId,
goodsRightsSelectorDTO.getGoodsRightsSearchText(), goodsRightsSelectorDTO.getGoodsRightsSearchValue(), goodsRightsSelectorDTO.getHasRights(), goodsRightsSelectorDTO.getGoodsRightsBrands(), goodsRightsSelectorDTO.getGoodsRightsDomains(), getEnterpriseId());
if (!serviceResponse.isSuccess()) {
......
......@@ -17,7 +17,13 @@ import com.gic.plug.web.vo.goods.GoodsStandardValueVO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
/**
* 商品
* @ClassName: GoodsStandardController

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:44 AM

*/
@RestController
public class GoodsStandardController extends BaseGoodsController {
......
package com.gic.store.web.qo;
package com.gic.plug.web.qo;
import java.io.Serializable;
......
package com.gic.plug.web.qo;
import java.io.Serializable;
/**
* 门店
* @ClassName: StoreWidgetCountQO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:45 AM

*/
public class StoreWidgetCountQO implements Serializable {
private String authSearchJson;
private String searchJson;
......
package com.gic.plug.web.qo;
import java.io.Serializable;
/**
* 门店选择器
* @ClassName: StoreWidgetQO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:38 AM

*/
public class StoreWidgetQO implements Serializable {
private Integer storeWidgetId;
private String authSearchParam;
......
package com.gic.plug.web.qo.goods;
/**
* test
* @ClassName: GoodsQO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:42 AM

*/
public class GoodsQO {
}
package com.gic.plug.web.qo.goods;
/**
* 商品
* @ClassName: GoodsRightsSelectorSaveQO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:39 AM

*/
public class GoodsRightsSelectorSaveQO {
/**
......
package com.gic.plug.web.qo.goods;
/**
* 商品
* @ClassName: GoodsRightsSelectorUpdateQO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:39 AM

*/
public class GoodsRightsSelectorUpdateQO {
/**
......
package com.gic.plug.web.qo.goods;
/**
* 商品
* @ClassName: GoodsSelectorSaveQO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:39 AM

*/
public class GoodsSelectorSaveQO {
private String goodsSearchValue;
......
package com.gic.plug.web.qo.goods;
/**
* 商品
* @ClassName: GoodsSelectorUpdateQO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:39 AM

*/
public class GoodsSelectorUpdateQO {
private Long goodsSelectorId;
......
package com.gic.plug.web.strategy;
import com.gic.plug.web.vo.ScreenBack;
/**
* 回显
* @ClassName: ScreenBackStrategy

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:36 AM

*/
public interface ScreenBackStrategy {
ScreenBack screenBack(String compute, String value, String key, Integer enterpriseId) throws ClassNotFoundException;
}
......@@ -15,7 +15,13 @@ import org.springframework.stereotype.Component;
import java.util.ArrayList;
import java.util.List;
/**
* 门店
* @ClassName: StoreAreaBackImpl

* @Description: 

* @author boom

* @date 2020/9/14 10:40 AM

*/
@Component
public class StoreAreaBackImpl implements ScreenBackStrategy {
@Autowired
......
......@@ -17,7 +17,13 @@ import org.springframework.stereotype.Component;
import java.util.ArrayList;
import java.util.List;
/**
* 门店回显
* @ClassName: StoreBackImpl

* @Description: 

* @author boom

* @date 2020/9/14 10:41 AM

*/
@Component
public class StoreBackImpl implements ScreenBackStrategy {
@Autowired
......
......@@ -13,7 +13,13 @@ import org.springframework.stereotype.Component;
import java.util.ArrayList;
import java.util.List;
/**
* 门店品牌
* @ClassName: StoreBrandBackImpl

* @Description: 

* @author boom

* @date 2020/9/14 10:40 AM

*/
@Component
public class StoreBrandBackImpl implements ScreenBackStrategy {
@Autowired
......
......@@ -113,12 +113,12 @@ public class StoreCustomBackImpl implements ScreenBackStrategy {
}
ServiceResponse<List<StoreFieldSelectDTO>> listServiceResponse = this.storeFieldSelectApiService.listStoreFieldSelectByIds(enterpriseId, list);
if (listServiceResponse.isSuccess()) {
List<StoreFieldSelectDTO> selectDTOS = listServiceResponse.getResult();
List<StoreFieldSelectDTO> selectDtoS = listServiceResponse.getResult();
List<String> view = new ArrayList<>();
List<String> hideView = new ArrayList<>();
int index = 0;
if (CollectionUtils.isNotEmpty(selectDTOS)) {
for (StoreFieldSelectDTO dto : selectDTOS) {
if (CollectionUtils.isNotEmpty(selectDtoS)) {
for (StoreFieldSelectDTO dto : selectDtoS) {
if(index < 5){
view.add(dto.getStoreFieldSelectName());
} else {
......@@ -150,31 +150,31 @@ public class StoreCustomBackImpl implements ScreenBackStrategy {
return screenBack;
}
public String yyyyMMddHHmmssBack(String value) throws ParseException {
public String yearMonthDateHourMinuteSecondBack(String value) throws ParseException {
SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyyMMddHHmmss");
SimpleDateFormat simpleDateFormat1 = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
return this.dateBack(value, simpleDateFormat, simpleDateFormat1);
}
public String yyyyMMddBack(String value) throws ParseException {
public String yearMonthDateBack(String value) throws ParseException {
SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyyMMdd");
SimpleDateFormat simpleDateFormat1 = new SimpleDateFormat("yyyy-MM-dd");
return this.dateBack(value, simpleDateFormat, simpleDateFormat1);
}
public String yyyyMM(String value) throws ParseException {
public String yearMonth(String value) throws ParseException {
SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyyMM");
SimpleDateFormat simpleDateFormat1 = new SimpleDateFormat("yyyy-MM");
return this.dateBack(value, simpleDateFormat, simpleDateFormat1);
}
public String mmddBack(String value) throws ParseException {
public String monthDateBack(String value) throws ParseException {
SimpleDateFormat simpleDateFormat = new SimpleDateFormat("MMdd");
SimpleDateFormat simpleDateFormat1 = new SimpleDateFormat("MM-dd");
return this.dateBack(value, simpleDateFormat, simpleDateFormat1);
}
public String hhmmssBack(String value) throws ParseException {
public String hourMinuteSecondBack(String value) throws ParseException {
SimpleDateFormat simpleDateFormat = new SimpleDateFormat("HHmmss");
SimpleDateFormat simpleDateFormat1 = new SimpleDateFormat("HH:mm:ss");
return this.dateBack(value, simpleDateFormat, simpleDateFormat1);
......
......@@ -13,7 +13,13 @@ import org.springframework.stereotype.Component;
import java.util.ArrayList;
import java.util.List;
/**
* 门店分组回显
* @ClassName: StoreGroupBackImpl

* @Description: 

* @author boom

* @date 2020/9/14 10:40 AM

*/
@Component
public class StoreGroupBackImpl implements ScreenBackStrategy {
@Autowired
......
......@@ -13,7 +13,13 @@ import org.springframework.stereotype.Component;
import java.util.ArrayList;
import java.util.List;
/**
* 门店域回显
* @ClassName: StoreRegionBackImpl

* @Description: 

* @author boom

* @date 2020/9/14 10:40 AM

*/
@Component
public class StoreRegionBackImpl implements ScreenBackStrategy {
@Autowired
......
......@@ -14,7 +14,13 @@ import org.springframework.stereotype.Component;
import java.util.ArrayList;
import java.util.List;
/**
* 门店表情
* @ClassName: StoreTagBackImpl

* @Description: 

* @author boom

* @date 2020/9/14 10:39 AM

*/
@Component
public class StoreTagBackImpl implements ScreenBackStrategy {
@Autowired
......
......@@ -9,7 +9,13 @@ import org.springframework.stereotype.Component;
import javax.annotation.PostConstruct;
import java.util.HashMap;
import java.util.Map;
/**
* 回显
* @ClassName: StrategyInit

* @Description: 

* @author boom

* @date 2020/9/14 10:41 AM

*/
@Component
public class StrategyInit {
@Autowired
......
......@@ -4,7 +4,13 @@ import org.apache.commons.lang.StringUtils;
import java.util.HashMap;
import java.util.Map;
/**
* 符号
* @ClassName: ComputeBackUtil

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:39 AM

*/
public class ComputeBackUtil {
public static Map<String, String> computeMap = new HashMap<>();
static {
......
......@@ -13,7 +13,13 @@ import org.apache.commons.collections.CollectionUtils;
import java.util.HashSet;
import java.util.Set;
/**
* 门店
* @ClassName: StoreRegionAuthUtil

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:45 AM

*/
public class StoreRegionAuthUtil {
public static Set<String> getUserRegion(StoreWidgetApiService storeWidgetApiService){
Set<String> authRegionSet = new HashSet<>();
......
......@@ -4,7 +4,11 @@ import java.io.Serializable;
import java.util.Date;
/**
* tab_city
* 城市
* @ClassName: CityVO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:38 AM

*/
public class CityVO implements Serializable {
/**
......@@ -60,4 +64,8 @@ public class CityVO implements Serializable {
this.cityPy = cityPy;
}
@Override
public String toString() {
return super.toString();
}
}
\ No newline at end of file
......@@ -4,7 +4,11 @@ import java.io.Serializable;
import java.util.Date;
/**
* tab_county
* 地区
* @ClassName: CountyVO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:37 AM

*/
public class CountyVO implements Serializable {
/**
......@@ -86,4 +90,9 @@ public class CountyVO implements Serializable {
public void setCountyPy(String countyPy) {
this.countyPy = countyPy;
}
@Override
public String toString() {
return super.toString();
}
}
\ No newline at end of file
......@@ -4,7 +4,11 @@ import java.io.Serializable;
import java.util.Date;
/**
* tab_province
* 省
* @ClassName: ProvinceVO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:38 AM

*/
public class ProvinceVO implements Serializable {
/**
......@@ -47,4 +51,8 @@ public class ProvinceVO implements Serializable {
this.provincePy = provincePy;
}
@Override
public String toString() {
return super.toString();
}
}
\ No newline at end of file
......@@ -2,7 +2,13 @@ package com.gic.plug.web.vo;
import java.io.Serializable;
import java.util.List;
/**
* 门店
* @ClassName: ScreenBack

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:45 AM

*/
public class ScreenBack implements Serializable {
private String title;
private String compute;
......
package com.gic.plug.web.vo;
import java.util.List;
/**
* 门店
* @ClassName: ScreenBackVO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:45 AM

*/
public class ScreenBackVO {
private String type = "and";
private List<ScreenBack> data;
......@@ -21,4 +27,9 @@ public class ScreenBackVO {
public void setData(List<ScreenBack> data) {
this.data = data;
}
@Override
public String toString() {
return super.toString();
}
}
......@@ -4,7 +4,11 @@ import java.io.Serializable;
import java.util.Date;
/**
* tab_store_dict
* 门店字典
* @ClassName: StoreDictVO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:38 AM

*/
public class StoreDictVO implements Serializable {
private String value;
......@@ -37,4 +41,9 @@ public class StoreDictVO implements Serializable {
public void setKey(String key) {
this.key = key;
}
@Override
public String toString() {
return super.toString();
}
}
\ No newline at end of file
......@@ -24,7 +24,7 @@ public class StoreFieldRegionVO implements Serializable{
private String storeFieldKey;
private int dateType;
private Integer dateType = 0;
/**
* 排序
......@@ -86,4 +86,9 @@ public class StoreFieldRegionVO implements Serializable{
public void setDateType(int dateType) {
this.dateType = dateType;
}
@Override
public String toString() {
return super.toString();
}
}
......@@ -48,4 +48,9 @@ public class StoreFieldSelectVO implements Serializable{
public void setSort(Double sort) {
this.sort = sort;
}
@Override
public String toString() {
return super.toString();
}
}
......@@ -36,4 +36,9 @@ public class StoreRegionVO implements Serializable {
public void setRegionName(String regionName) {
this.regionName = regionName;
}
@Override
public String toString() {
return super.toString();
}
}
package com.gic.plug.web.vo;
import java.util.List;
/**
* 门店
* @ClassName: StoreResourceVO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:44 AM

*/
public class StoreResourceVO {
private Integer authMode;
private String searchJson;
......@@ -28,4 +35,9 @@ public class StoreResourceVO {
public void setSceenBack(List<ScreenBackVO> sceenBack) {
this.sceenBack = sceenBack;
}
@Override
public String toString() {
return super.toString();
}
}
......@@ -35,4 +35,9 @@ public class StoreVO implements Serializable {
public void setStoreCode(String storeCode) {
this.storeCode = storeCode;
}
@Override
public String toString() {
return super.toString();
}
}
......@@ -3,7 +3,11 @@ package com.gic.plug.web.vo;
import java.io.Serializable;
import java.util.List;
/**
* tab_store_widget
* 商品
* @ClassName: StoreWidgetVO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:45 AM

*/
public class StoreWidgetVO implements Serializable {
/**
......@@ -73,4 +77,9 @@ public class StoreWidgetVO implements Serializable {
public void setScreenBack(List<ScreenBackVO> screenBack) {
this.screenBack = screenBack;
}
@Override
public String toString() {
return super.toString();
}
}
\ No newline at end of file
......@@ -4,7 +4,13 @@ import com.fasterxml.jackson.annotation.JsonFormat;
import java.io.Serializable;
import java.util.Date;
/**
* 字典
* @ClassName: CategoryVO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:38 AM

*/
public class CategoryVO implements Serializable {
private static final long serialVersionUID = -8126896401928702304L;
......@@ -207,4 +213,9 @@ public class CategoryVO implements Serializable {
public void setNextChild(Boolean nextChild) {
this.nextChild = nextChild;
}
@Override
public String toString() {
return super.toString();
}
}
package com.gic.plug.web.vo.goods;
import com.fasterxml.jackson.annotation.JsonFormat;
/**
* 商品
* @ClassName: GoodsBrandVO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:42 AM

*/
public class GoodsBrandVO {
@JsonFormat(shape = JsonFormat.Shape.STRING)
......@@ -34,4 +40,9 @@ public class GoodsBrandVO {
public void setBrandCode(String brandCode) {
this.brandCode = brandCode;
}
@Override
public String toString() {
return super.toString();
}
}
package com.gic.plug.web.vo.goods;
/**
* 商品
* @ClassName: GoodsCategoryVO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:43 AM

*/
public class GoodsCategoryVO {
/**
......@@ -17,7 +23,7 @@ public class GoodsCategoryVO {
*/
private String specCategoryCode;
private boolean hasChild;
private Boolean hasChild = false;
public Long getSpecCategoryId() {
return specCategoryId;
......@@ -50,4 +56,9 @@ public class GoodsCategoryVO {
public void setHasChild(boolean hasChild) {
this.hasChild = hasChild;
}
@Override
public String toString() {
return super.toString();
}
}
package com.gic.plug.web.vo.goods;
import java.util.List;
/**
* 商品
* @ClassName: GoodsChannelVO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:42 AM

*/
public class GoodsChannelVO {
private String channelCode;
......@@ -43,4 +49,9 @@ public class GoodsChannelVO {
public void setSceneCode(String sceneCode) {
this.sceneCode = sceneCode;
}
@Override
public String toString() {
return super.toString();
}
}
......@@ -135,4 +135,8 @@ public class GoodsCordVO {
this.sort = sort;
}
@Override
public String toString() {
return super.toString();
}
}
\ No newline at end of file
package com.gic.plug.web.vo.goods;
import com.fasterxml.jackson.annotation.JsonFormat;
/**
* 商品
* @ClassName: GoodsDomainVO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:42 AM

*/
public class GoodsDomainVO {
private String domainCode;
......@@ -34,4 +40,9 @@ public class GoodsDomainVO {
public void setDomainId(Long domainId) {
this.domainId = domainId;
}
@Override
public String toString() {
return super.toString();
}
}
package com.gic.plug.web.vo.goods;
import com.fasterxml.jackson.annotation.JsonFormat;
/**
* 商品
* @ClassName: GoodsPropertyVO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:44 AM

*/
public class GoodsPropertyVO {
/**
......@@ -70,4 +76,9 @@ public class GoodsPropertyVO {
public void setPoints(Integer points) {
this.points = points;
}
@Override
public String toString() {
return super.toString();
}
}
package com.gic.plug.web.vo.goods;
import com.fasterxml.jackson.annotation.JsonFormat;
/**
* 商品
* @ClassName: GoodsPropertyValueVO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:44 AM

*/
public class GoodsPropertyValueVO {
/**
*
......@@ -42,4 +48,9 @@ public class GoodsPropertyValueVO {
public void setSpecPropertyValueCode(String specPropertyValueCode) {
this.specPropertyValueCode = specPropertyValueCode;
}
@Override
public String toString() {
return super.toString();
}
}
......@@ -3,7 +3,13 @@ package com.gic.plug.web.vo.goods;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
/**
* 商品
* @ClassName: GoodsRightsSelectorVO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:42 AM

*/
public class GoodsRightsSelectorVO {
/**
*
......@@ -158,4 +164,9 @@ public class GoodsRightsSelectorVO {
public void setFindCount(Long findCount) {
this.findCount = findCount;
}
@Override
public String toString() {
return super.toString();
}
}
package com.gic.plug.web.vo.goods;
import com.fasterxml.jackson.annotation.JsonFormat;
/**
* 商品
* @ClassName: GoodsSelectorVO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:42 AM

*/
public class GoodsSelectorVO {
@JsonFormat(shape = JsonFormat.Shape.STRING)
......@@ -110,4 +116,9 @@ public class GoodsSelectorVO {
public void setHasRights(Integer hasRights) {
this.hasRights = hasRights;
}
@Override
public String toString() {
return super.toString();
}
}
package com.gic.plug.web.vo.goods;
import com.fasterxml.jackson.annotation.JsonFormat;
/**
* 商品
* @ClassName: GoodsStandardVO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:43 AM

*/
public class GoodsStandardVO {
/**
......@@ -43,4 +49,9 @@ public class GoodsStandardVO {
public void setSpecStandardCode(String specStandardCode) {
this.specStandardCode = specStandardCode;
}
@Override
public String toString() {
return super.toString();
}
}
package com.gic.plug.web.vo.goods;
import com.fasterxml.jackson.annotation.JsonFormat;
/**
* 商品
* @ClassName: GoodsStandardValueGroupVO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:42 AM

*/
public class GoodsStandardValueGroupVO {
/**
*
......@@ -42,4 +48,9 @@ public class GoodsStandardValueGroupVO {
public void setSpecStandardValueGroupCode(String specStandardValueGroupCode) {
this.specStandardValueGroupCode = specStandardValueGroupCode;
}
@Override
public String toString() {
return super.toString();
}
}
package com.gic.plug.web.vo.goods;
import com.fasterxml.jackson.annotation.JsonFormat;
/**
* 商品
* @ClassName: GoodsStandardValueVO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:42 AM

*/
public class GoodsStandardValueVO {
/**
......@@ -43,4 +49,9 @@ public class GoodsStandardValueVO {
public void setSpecStandardValueCode(String specStandardValueCode) {
this.specStandardValueCode = specStandardValueCode;
}
@Override
public String toString() {
return super.toString();
}
}
......@@ -73,4 +73,8 @@ public class GoodsTagVO {
this.specTagCode = specTagCode;
}
@Override
public String toString() {
return super.toString();
}
}
\ No newline at end of file
......@@ -116,6 +116,15 @@ public class GoodsVO {
public void setGoodsSkuCode(String goodsSkuCode) {
this.goodsSkuCode = goodsSkuCode;
}
@Override
public String toString() {
return super.toString();
}
}
@Override
public String toString() {
return super.toString();
}
}
\ No newline at end of file
......@@ -3,7 +3,13 @@ package com.gic.plug.web.vo.goods;
import java.util.List;
import com.fasterxml.jackson.annotation.JsonFormat;
/**
* 商品
* @ClassName: MallGoodsCordVO

* @Description: 

* @author guojuxing

* @date 2020/9/14 10:44 AM

*/
public class MallGoodsCordVO {
/**
......@@ -138,4 +144,9 @@ public class MallGoodsCordVO {
public void setChildSpecCordDTOList(List<MallGoodsCordVO> childSpecCordDTOList) {
this.childSpecCordDTOList = childSpecCordDTOList;
}
@Override
public String toString() {
return super.toString();
}
}
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