|
|
@@ -207,16 +207,16 @@ public class StorePlatformLoginServiceImpl extends ServiceImpl<StoreUserMapper,
|
|
|
public JSONObject getExpirationTime(Integer storeId) throws Exception {
|
|
|
try {
|
|
|
JSONObject jsonObject = new JSONObject();
|
|
|
- jsonObject.put("expirationTime", 0);
|
|
|
- jsonObject.put("foodLicenceExpirationTime", 0);
|
|
|
+ jsonObject.put("expirationTime", 1);
|
|
|
+ jsonObject.put("foodLicenceExpirationTime", 1);
|
|
|
|
|
|
StoreInfo storeInfo = storeInfoMapper.selectById(storeId);
|
|
|
if (storeInfo != null) {
|
|
|
- if (storeInfo.getExpirationTime().compareTo(new Date()) > 0) {
|
|
|
- jsonObject.put("expirationTime", 1);
|
|
|
+ if (storeInfo.getExpirationTime().compareTo(new Date()) < 0) {
|
|
|
+ jsonObject.put("expirationTime", 0);
|
|
|
}
|
|
|
- if (storeInfo.getFoodLicenceExpirationTime().compareTo(new Date()) > 0) {
|
|
|
- jsonObject.put("foodLicenceExpirationTime", 1);
|
|
|
+ if (storeInfo.getFoodLicenceExpirationTime().compareTo(new Date()) < 0) {
|
|
|
+ jsonObject.put("foodLicenceExpirationTime", 0);
|
|
|
}
|
|
|
}
|
|
|
return jsonObject;
|