|
|
@ -1,7 +1,7 @@
|
|
|
|
package au.com.royalpay.payment.manage.apps.web;
|
|
|
|
package au.com.royalpay.payment.manage.apps.web;
|
|
|
|
|
|
|
|
|
|
|
|
import au.com.royalpay.payment.manage.apps.bean.CustomerImpressionQuery;
|
|
|
|
import au.com.royalpay.payment.manage.apps.bean.CustomerImpressionQuery;
|
|
|
|
import au.com.royalpay.payment.manage.apps.core.CustomerImpression;
|
|
|
|
import au.com.royalpay.payment.manage.apps.core.CustomerImpressionService;
|
|
|
|
import au.com.royalpay.payment.tools.CommonConsts;
|
|
|
|
import au.com.royalpay.payment.tools.CommonConsts;
|
|
|
|
import au.com.royalpay.payment.tools.device.advise.AppClientController;
|
|
|
|
import au.com.royalpay.payment.tools.device.advise.AppClientController;
|
|
|
|
|
|
|
|
|
|
|
@ -20,25 +20,31 @@ import javax.annotation.Resource;
|
|
|
|
@RequestMapping(value = "/customers/impression")
|
|
|
|
@RequestMapping(value = "/customers/impression")
|
|
|
|
public class CustomerImpressionController {
|
|
|
|
public class CustomerImpressionController {
|
|
|
|
@Resource
|
|
|
|
@Resource
|
|
|
|
private CustomerImpression customerImpression;
|
|
|
|
private CustomerImpressionService customerImpressionService;
|
|
|
|
|
|
|
|
|
|
|
|
@RequestMapping(value = "/list", method = RequestMethod.GET)
|
|
|
|
@RequestMapping(value = "/list", method = RequestMethod.GET)
|
|
|
|
@ResponseBody
|
|
|
|
@ResponseBody
|
|
|
|
public JSONObject list(CustomerImpressionQuery customerImpressionQuery,@ModelAttribute(CommonConsts.RETAIL_DEVICE) JSONObject app) {
|
|
|
|
public JSONObject list(CustomerImpressionQuery customerImpressionQuery, @ModelAttribute(CommonConsts.RETAIL_DEVICE) JSONObject app) {
|
|
|
|
customerImpressionQuery.setClient_id(app.getInteger("client_id"));
|
|
|
|
customerImpressionQuery.setClient_id(app.getInteger("client_id"));
|
|
|
|
return customerImpression.listPageble(customerImpressionQuery);
|
|
|
|
return customerImpressionService.listPageble(customerImpressionQuery);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@RequestMapping(value = "/{customer_id}", method = RequestMethod.GET)
|
|
|
|
@RequestMapping(value = "/{customer_id}", method = RequestMethod.GET)
|
|
|
|
@ResponseBody
|
|
|
|
@ResponseBody
|
|
|
|
public JSONObject find(@PathVariable String customer_id,@ModelAttribute(CommonConsts.RETAIL_DEVICE) JSONObject app) {
|
|
|
|
public JSONObject find(@PathVariable String customer_id, @ModelAttribute(CommonConsts.RETAIL_DEVICE) JSONObject app) {
|
|
|
|
return customerImpression.findOne(app.getIntValue("client_id"),customer_id);
|
|
|
|
return customerImpressionService.findOne(app.getIntValue("client_id"), customer_id);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
@RequestMapping(value = "/{customer_id}", method = RequestMethod.PUT)
|
|
|
|
@RequestMapping(value = "/{customer_id}", method = RequestMethod.PUT)
|
|
|
|
@ResponseBody
|
|
|
|
@ResponseBody
|
|
|
|
public void modifyNameRemark(@PathVariable String customer_id, @RequestBody JSONObject customerInfo,@ModelAttribute(CommonConsts.RETAIL_DEVICE) JSONObject app) {
|
|
|
|
public void modifyNameRemark(@PathVariable String customer_id, @RequestBody JSONObject customerInfo,
|
|
|
|
customerImpression.modifyNameRemark(app.getIntValue("client_id"),customer_id,customerInfo.getString("name_remark"));
|
|
|
|
@ModelAttribute(CommonConsts.RETAIL_DEVICE) JSONObject app) {
|
|
|
|
|
|
|
|
customerImpressionService.modifyNameRemark(app.getIntValue("client_id"), customer_id, customerInfo.getString("name_remark"));
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@RequestMapping(value = "/gengrate", method = RequestMethod.PUT)
|
|
|
|
|
|
|
|
@ResponseBody
|
|
|
|
|
|
|
|
public void generate(@ModelAttribute(CommonConsts.RETAIL_DEVICE) JSONObject app) {
|
|
|
|
|
|
|
|
customerImpressionService.generate(app.getIntValue("client_id"));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|