|
@@ -4,6 +4,7 @@ import com.yoho.error.exception.ServiceException; |
|
@@ -4,6 +4,7 @@ import com.yoho.error.exception.ServiceException; |
4
|
import com.yoho.tools.common.beans.ApiResponse;
|
4
|
import com.yoho.tools.common.beans.ApiResponse;
|
5
|
import com.yohobuy.ufo.model.enums.StoredSellerStatusEnum;
|
5
|
import com.yohobuy.ufo.model.enums.StoredSellerStatusEnum;
|
6
|
import com.yohobuy.ufo.model.order.common.EntrySellerType;
|
6
|
import com.yohobuy.ufo.model.order.common.EntrySellerType;
|
|
|
7
|
+import com.yohobuy.ufo.model.order.resp.SellerResp;
|
7
|
import com.yohoufo.common.caller.UfoServiceCaller;
|
8
|
import com.yohoufo.common.caller.UfoServiceCaller;
|
8
|
import com.yohoufo.dal.order.StoredSellerMapper;
|
9
|
import com.yohoufo.dal.order.StoredSellerMapper;
|
9
|
import com.yohoufo.dal.order.model.StoredSeller;
|
10
|
import com.yohoufo.dal.order.model.StoredSeller;
|
|
@@ -21,6 +22,7 @@ import java.time.LocalDateTime; |
|
@@ -21,6 +22,7 @@ import java.time.LocalDateTime; |
21
|
import java.time.ZoneOffset;
|
22
|
import java.time.ZoneOffset;
|
22
|
import java.util.HashMap;
|
23
|
import java.util.HashMap;
|
23
|
import java.util.Map;
|
24
|
import java.util.Map;
|
|
|
25
|
+import java.util.Objects;
|
24
|
|
26
|
|
25
|
@Service
|
27
|
@Service
|
26
|
public class StoreSellerServiceImpl implements IStoredSellerService {
|
28
|
public class StoreSellerServiceImpl implements IStoredSellerService {
|
|
@@ -42,6 +44,9 @@ public class StoreSellerServiceImpl implements IStoredSellerService { |
|
@@ -42,6 +44,9 @@ public class StoreSellerServiceImpl implements IStoredSellerService { |
42
|
@Value("${zhimacert.switch:true}")
|
44
|
@Value("${zhimacert.switch:true}")
|
43
|
private boolean zhiMaCertSwitch;
|
45
|
private boolean zhiMaCertSwitch;
|
44
|
|
46
|
|
|
|
47
|
+ @Autowired
|
|
|
48
|
+ private SellerService sellerService;
|
|
|
49
|
+
|
45
|
/**
|
50
|
/**
|
46
|
* 是否入驻商户
|
51
|
* 是否入驻商户
|
47
|
* @param uid
|
52
|
* @param uid
|
|
@@ -58,7 +63,7 @@ public class StoreSellerServiceImpl implements IStoredSellerService { |
|
@@ -58,7 +63,7 @@ public class StoreSellerServiceImpl implements IStoredSellerService { |
58
|
}
|
63
|
}
|
59
|
|
64
|
|
60
|
@Override
|
65
|
@Override
|
61
|
- public Map<String,Boolean> entryStatus(Integer uid){
|
66
|
+ public SellerResp entryStatus(Integer uid){
|
62
|
logger.info("StoredSellerServiceImpl entryStatus uid is {} ",uid);
|
67
|
logger.info("StoredSellerServiceImpl entryStatus uid is {} ",uid);
|
63
|
Boolean isZhiMaCert=false;
|
68
|
Boolean isZhiMaCert=false;
|
64
|
|
69
|
|
|
@@ -92,11 +97,14 @@ public class StoreSellerServiceImpl implements IStoredSellerService { |
|
@@ -92,11 +97,14 @@ public class StoreSellerServiceImpl implements IStoredSellerService { |
92
|
}
|
97
|
}
|
93
|
}
|
98
|
}
|
94
|
|
99
|
|
95
|
- Map<String,Boolean> map=new HashMap<>();
|
|
|
96
|
- map.put("isZhiMaCert",isZhiMaCert);
|
|
|
97
|
- map.put("isStoredSeller",isStoredSeller);
|
|
|
98
|
- map.put("storedBefore",storedBefore);
|
|
|
99
|
- return map;
|
100
|
+ EntrySellerType entrySellerType = sellerService.getEntrySellerType(uid);
|
|
|
101
|
+ SellerResp sellerResp = new SellerResp();
|
|
|
102
|
+ sellerResp.setZhiMaCert(isZhiMaCert);
|
|
|
103
|
+ sellerResp.setStoredBefore(storedBefore);
|
|
|
104
|
+ sellerResp.setStoredSeller(isStoredSeller);
|
|
|
105
|
+ if(Objects.nonNull(entrySellerType))
|
|
|
106
|
+ sellerResp.setEntrySellerType(entrySellerType.getCode());
|
|
|
107
|
+ return sellerResp;
|
100
|
}
|
108
|
}
|
101
|
|
109
|
|
102
|
@Override
|
110
|
@Override
|