use of build.dream.common.api.ApiRest in project erp-catering by liuyandong33.
the class AnubisController method chainStore.
/**
* 添加门店
*
* @return
*/
@RequestMapping(value = "/chainStore")
@ResponseBody
public String chainStore() {
ApiRest apiRest = null;
Map<String, String> requestParameters = ApplicationHandler.getRequestParameters();
try {
ChainStoreModel chainStoreModel = ApplicationHandler.instantiateObject(ChainStoreModel.class, requestParameters);
chainStoreModel.validateAndThrow();
apiRest = anubisService.chainStore(chainStoreModel);
} catch (Exception e) {
LogUtils.error("添加门店失败", controllerSimpleName, "chainStore", e, requestParameters);
apiRest = new ApiRest(e);
}
return GsonUtils.toJson(apiRest);
}
use of build.dream.common.api.ApiRest in project erp-catering by liuyandong33.
the class AnubisController method chainStoreDeliveryQuery.
/**
* 查询配送服务
*
* @return
*/
@RequestMapping(value = "/chainStoreDeliveryQuery")
@ResponseBody
public String chainStoreDeliveryQuery() {
ApiRest apiRest = null;
Map<String, String> requestParameters = ApplicationHandler.getRequestParameters();
try {
ChainStoreDeliveryQueryModel chainStoreDeliveryQueryModel = ApplicationHandler.instantiateObject(ChainStoreDeliveryQueryModel.class, requestParameters);
chainStoreDeliveryQueryModel.validateAndThrow();
apiRest = anubisService.chainStoreDeliveryQuery(chainStoreDeliveryQueryModel);
} catch (Exception e) {
LogUtils.error("查询配送服务失败", controllerSimpleName, "chainStoreDeliveryQuery", e, requestParameters);
apiRest = new ApiRest(e);
}
return GsonUtils.toJson(apiRest);
}
use of build.dream.common.api.ApiRest in project erp-catering by liuyandong33.
the class AnubisController method orderCancel.
/**
* 同步取消订单
*
* @return
*/
@RequestMapping(value = "/orderCancel")
@ResponseBody
public String orderCancel() {
ApiRest apiRest = null;
Map<String, String> requestParameters = ApplicationHandler.getRequestParameters();
try {
OrderCancelModel orderCancelModel = ApplicationHandler.instantiateObject(OrderCancelModel.class, requestParameters);
orderCancelModel.validateAndThrow();
apiRest = anubisService.orderCancel(orderCancelModel);
} catch (Exception e) {
LogUtils.error("同步取消订单失败", controllerSimpleName, "orderCancel", e, requestParameters);
apiRest = new ApiRest(e);
}
return GsonUtils.toJson(apiRest);
}
use of build.dream.common.api.ApiRest in project erp-catering by liuyandong33.
the class AnubisController method obtainDeliveryStates.
/**
* 获取配送记录
*
* @return
*/
@RequestMapping(value = "/obtainDeliveryStates")
@ResponseBody
public String obtainDeliveryStates() {
ApiRest apiRest = null;
Map<String, String> requestParameters = ApplicationHandler.getRequestParameters();
try {
ObtainDeliveryStatesModel obtainDeliveryStatesModel = ApplicationHandler.instantiateObject(ObtainDeliveryStatesModel.class, requestParameters);
obtainDeliveryStatesModel.validateAndThrow();
apiRest = anubisService.obtainDeliveryStates(obtainDeliveryStatesModel);
} catch (Exception e) {
LogUtils.error("获取配送记录失败", controllerSimpleName, "obtainDeliveryStates", e, requestParameters);
apiRest = new ApiRest(e);
}
return GsonUtils.toJson(apiRest);
}
use of build.dream.common.api.ApiRest in project erp-catering by liuyandong33.
the class AnubisController method chainStoreUpdate.
/**
* 更新门店信息
*
* @return
*/
@RequestMapping(value = "/chainStoreUpdate")
@ResponseBody
public String chainStoreUpdate() {
ApiRest apiRest = null;
Map<String, String> requestParameters = ApplicationHandler.getRequestParameters();
try {
ChainStoreUpdateModel chainStoreUpdateModel = ApplicationHandler.instantiateObject(ChainStoreUpdateModel.class, requestParameters);
chainStoreUpdateModel.validateAndThrow();
apiRest = anubisService.chainStoreUpdate(chainStoreUpdateModel);
} catch (Exception e) {
LogUtils.error("更新门店信息失败", controllerSimpleName, "chainStoreUpdate", e, requestParameters);
apiRest = new ApiRest(e);
}
return GsonUtils.toJson(apiRest);
}
Aggregations