|
|
|
@ -358,14 +358,32 @@ public class RetailAppServiceImp implements RetailAppService {
|
|
|
|
|
|
|
|
|
|
@Override
|
|
|
|
|
public JSONObject getClientInfoRealtime(JSONObject device) {
|
|
|
|
|
return clientMapper.findClient(device.getIntValue("client_id"));
|
|
|
|
|
JSONObject client = clientMapper.findClient(device.getIntValue("client_id"));
|
|
|
|
|
JSONObject result = new JSONObject();
|
|
|
|
|
result.put("company_phone",client.getString("company_phone"));
|
|
|
|
|
result.put("short_name",client.getString("short_name"));
|
|
|
|
|
result.put("company_name",client.getString("company_name"));
|
|
|
|
|
result.put("business_name",client.getString("business_name"));
|
|
|
|
|
result.put("business_structure",client.getString("business_structure"));
|
|
|
|
|
result.put("abn",client.getString("abn"));
|
|
|
|
|
result.put("acn",client.getString("acn"));
|
|
|
|
|
result.put("address",client.getString("address"));
|
|
|
|
|
result.put("suburb",client.getString("suburb"));
|
|
|
|
|
result.put("postcode",client.getString("postcode"));
|
|
|
|
|
result.put("state",client.getString("state"));
|
|
|
|
|
result.put("timezone",client.getString("timezone"));
|
|
|
|
|
result.put("contact_email",client.getString("contact_email"));
|
|
|
|
|
result.put("mail_confirm",client.getString("mail_confirm"));
|
|
|
|
|
result.put("contact_person",client.getString("contact_person"));
|
|
|
|
|
result.put("logo_url",client.getString("logo_url"));
|
|
|
|
|
result.put("store_photo",client.getString("store_photo"));
|
|
|
|
|
return result;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@Override
|
|
|
|
|
public JSONObject getClientInfoMe(JSONObject device) {
|
|
|
|
|
JSONObject result = new JSONObject();
|
|
|
|
|
JSONObject client = clientMapper.findClient(device.getIntValue("client_id"));
|
|
|
|
|
if (client.getString("store_photo") == null || client.getString("logo_url") == null || client.getString("company_photo") == null) {
|
|
|
|
|
if (StringUtils.isEmpty(client.getString("store_photo"))|| StringUtils.isEmpty(client.getString("logo_url"))|| StringUtils.isEmpty(client.getString("company_photo"))) {
|
|
|
|
|
result.put("base_info_lack", true);
|
|
|
|
|
}
|
|
|
|
|
JSONObject file = clientManager.getAuthFiles(null, client.getString("client_moniker"));
|
|
|
|
@ -374,6 +392,7 @@ public class RetailAppServiceImp implements RetailAppService {
|
|
|
|
|
result.put("compliance_info_lack", true);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
result.putAll(file);
|
|
|
|
|
return result;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|