diff --git a/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/ShRequester.java b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/ShRequester.java index 36f8617..1e25949 100644 --- a/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/ShRequester.java +++ b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/ShRequester.java @@ -1,22 +1,29 @@ package com.yxt.supervise.gf.shanhai; import cn.hutool.core.bean.BeanUtil; -import cn.hutool.json.JSON; import cn.hutool.json.JSONObject; import cn.hutool.json.JSONUtil; import com.yxt.supervise.gf.shanhai.req.Apply_materialIndex; -import com.yxt.supervise.gf.shanhai.resp.ApplyMaterial; -import com.yxt.supervise.gf.shanhai.resp.BaseResponse; -import com.yxt.supervise.gf.shanhai.resp.BaseResponseListObj; +import com.yxt.supervise.gf.shanhai.req.Examine; +import com.yxt.supervise.gf.shanhai.req.ExportData; +import com.yxt.supervise.gf.shanhai.req.InventoryIndex; +import com.yxt.supervise.gf.shanhai.resp.*; import java.util.HashMap; +import java.util.List; import java.util.Map; public class ShRequester { - private static String api$system$apply_material$index = "/api/system/apply_material/index"; //1.待配货列表 - private static String api$system$apply_material$get_actual_order_material = "/api/system/apply_material/get_actual_order_material"; //2.查看物料实发 - + private static String apply_material$index = "/api/system/apply_material/index"; //1.待配货列表 + private static String apply_material$get_actual_order_material = "/api/system/apply_material/get_actual_order_material"; //2.查看物料实发 + private static String stock_record$get_material_stat = "/api/system/stock_record/get_material_stat"; //3.统计物料 + private static String stock_record$export_data = "/api/system/stock_record/export_data"; //4.导出物料 + private static String stock_record$material_stat_export = "/api/system/stock_record/material_stat_export"; //5.导出物料统计 + private static String inventory$index = "/api/system/inventory/index"; //6.库存管理 库存列表 + private static String out_stock$get_info = "/api/system/out_stock/get_info";//7.出库申请 出库申请详情 + private static String out_stock$examine = "/api/system/out_stock/examine"; //8. 出库审核 出库审核 + private static String out_stock$export_data = "/api/system/out_stock/export_data"; //9. 出库记录导出 出库记录导出 /** * 1.待配货列表 * @@ -27,9 +34,10 @@ public class ShRequester { if (reqParams != null) param = BeanUtil.beanToMap(reqParams); BaseResponse> resp = new BaseResponse<>(); - String s = ShHttp.doGet(api$system$apply_material$index, param); - JSONObject jsonObject = JSONUtil.parseObj(s); - return resp; + BaseResponseListObj respObj = new BaseResponseListObj<>(); + String s = ShHttp.doGet(apply_material$index, param); + BaseResponse> baseResponse = toBean(s, resp, respObj); + return baseResponse; } /** @@ -38,10 +46,144 @@ public class ShRequester { * @param id 备货申请id * @return */ - public static String getApi$system$apply_material$get_actual_order_material(String id) { + public static BaseResponse> getApi$system$apply_material$get_actual_order_material(String id) { + BaseResponse> resp = new BaseResponse<>(); + BaseResponseListObj respObj = new BaseResponseListObj<>(); Map params = new HashMap<>(); params.put("id", id); - String s = ShHttp.doGet(api$system$apply_material$get_actual_order_material, params); + String s = ShHttp.doGet(apply_material$get_actual_order_material, params); + BaseResponse> baseResponse = toBean(s, resp, respObj); + return baseResponse; + } + + /** + * @Description //描述: 3.统计物料 + * @Param [] + * @return com.yxt.supervise.gf.shanhai.resp.BaseResponse> + **/ + public static BaseResponse> getApi$system$stock_record$get_material_stat(){ + BaseResponse> resp = new BaseResponse<>(); + BaseResponseListObj respObj = new BaseResponseListObj<>(); + String s = ShHttp.doGet(stock_record$get_material_stat, null); + BaseResponse> baseResponse = toBean(s, resp, respObj); + return baseResponse; + } + + /** + * @Description //描述: 4. 导出物料 + * @Param [] + * @return java.lang.String + **/ + public static String getApi$system$stock_record$export_data(){ + String s = ShHttp.doGet(stock_record$export_data, null); + return s; + } + + /** + * @Description //描述:5. 导出物料统计 + * @Param [] + * @return java.lang.String + **/ + public static String getApi$system$stock_record$material_stat_export(){ + String s = ShHttp.doGet(stock_record$material_stat_export, null); return s; } + + /** + * @Description //描述: 6. 库存管理 库存列表 + * @Param [reqParams] + * @return com.yxt.supervise.gf.shanhai.resp.BaseResponse> + **/ + public static BaseResponse> getApi$system$inventory$index(InventoryIndex reqParams){ + Map param = null; + if (reqParams != null) + param = BeanUtil.beanToMap(reqParams); + BaseResponse> resp = new BaseResponse<>(); + BaseResponseListObj respObj = new BaseResponseListObj<>(); + String s = ShHttp.doGet(inventory$index, param); + BaseResponse> response = toBean(s, resp, respObj); + return response; + } + + /** + * @Description //描述: 7. 出库申请 出库申请详情 + * @Param [id] + * @return com.yxt.supervise.gf.shanhai.resp.BaseResponse + **/ + public static BaseResponse getApi$system$out_stock$get_info(String id){ + BaseResponse resp = new BaseResponse<>(); + Map params = new HashMap<>(); + params.put("id", id); + String s = ShHttp.doGet(out_stock$get_info, params); + JSONObject jsonObject = JSONUtil.parseObj(s); + String code = jsonObject.get("code").toString(); + String msg = jsonObject.get("msg").toString(); + resp.setCode(Integer.parseInt(code)); + resp.setMsg(msg); + JSONObject data = (JSONObject)jsonObject.get("data"); + GetInfo outStock = JSONUtil.toBean(data, GetInfo.class); + resp.setData(outStock); + return resp; + } + + /** + * @Description //描述: 8. 出库审核 出库审核 + * @Param [reqParams] + * @return com.yxt.supervise.gf.shanhai.resp.BaseResponse + **/ + public static BaseResponse getApi$system$out_stock$examine(Examine reqParams){ + BaseResponse resp = new BaseResponse<>(); + Map param = null; + if (reqParams != null) + param = BeanUtil.beanToMap(reqParams); + String s = ShHttp.dopost(out_stock$examine, param); + JSONObject jsonObject = JSONUtil.parseObj(s); + String code = jsonObject.get("code").toString(); + String msg = jsonObject.get("msg").toString(); + JSONObject data = (JSONObject)jsonObject.get("data"); + resp.setCode(Integer.parseInt(code)); + resp.setMsg(msg); + resp.setData(data); + return resp; + } + + /** + * @Description //描述: 9. 出库记录导出 + * @Param [reqParams] + * @return java.lang.String + **/ + public static String getApi$system$out_stock$export_data(ExportData reqParams){ + Map param = null; + if (reqParams != null) + param = BeanUtil.beanToMap(reqParams); + String s = ShHttp.doGet(out_stock$export_data, param); + return s; + } + + /** + * @Description //描述: 将Json格式数据封装成统一返回对象 + * @Param [s, resp, respObj] + * @return com.yxt.supervise.gf.shanhai.resp.BaseResponse + **/ + private static BaseResponse toBean(String s,BaseResponse resp,BaseResponseListObj respObj){ + JSONObject jsonObject = JSONUtil.parseObj(s); + String code = jsonObject.get("code").toString(); + String msg = jsonObject.get("msg").toString(); + resp.setCode(Integer.parseInt(code)); + resp.setMsg(msg); + try { + JSONObject data = (JSONObject)jsonObject.get("data"); + BaseResponseListObj listObj = JSONUtil.toBean(data, BaseResponseListObj.class); + List list = listObj.getList(); + respObj.setList(list); + respObj.setCount(listObj.getCount()); + resp.setData(respObj); + }catch (Exception e){ + Boolean a = jsonObject.get("data").toString().equals("null") || jsonObject.get("data") == null; + List data = a ? null : (List)jsonObject.get("data"); + respObj.setList(data); + resp.setData(respObj); + } + return resp; + } } diff --git a/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/req/Examine.java b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/req/Examine.java new file mode 100644 index 0000000..7267e16 --- /dev/null +++ b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/req/Examine.java @@ -0,0 +1,18 @@ +package com.yxt.supervise.gf.shanhai.req; + +import io.swagger.annotations.ApiModel; +import lombok.Data; + +/** + * @author feikefei + * @create 2023-07-05-16:50 + */ +@Data +@ApiModel(value = "出库审核", description = "出库审核") +public class Examine { + private Integer id;//申请id + private String examine;//审核次数 + private String status;//审核状态 + private String remark;//备注 + +} diff --git a/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/req/ExportData.java b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/req/ExportData.java new file mode 100644 index 0000000..3b09eee --- /dev/null +++ b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/req/ExportData.java @@ -0,0 +1,33 @@ +package com.yxt.supervise.gf.shanhai.req; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +/** + * @author feikefei + * @create 2023-07-05-17:48 + */ +@Data +@ApiModel(value = "出库记录导出") +public class ExportData { + @ApiModelProperty("出库开始时间") + private String start_happen_time; + @ApiModelProperty("出库结束时间") + private String end_happen_time; + @ApiModelProperty("批次号") + private String batch_number; + @ApiModelProperty("物料编号") + private String materiel_no; + @ApiModelProperty("物料名称") + private String materiel_name; + @ApiModelProperty("出库类型") + private String type; + @ApiModelProperty("出库仓库") + private String out_storehouse_id; + @ApiModelProperty("提货方id") + private String target_id; + @ApiModelProperty("提货方类型") + private String target_type; + +} diff --git a/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/req/InventoryIndex.java b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/req/InventoryIndex.java new file mode 100644 index 0000000..2af389d --- /dev/null +++ b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/req/InventoryIndex.java @@ -0,0 +1,21 @@ +package com.yxt.supervise.gf.shanhai.req; + +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +/** + * @author feikefei + * @create 2023-07-05-14:57 + */ +@Data +public class InventoryIndex { + @ApiModelProperty("物料组id") + private String materiel_group; + @ApiModelProperty("物料编号") + private String materiel_no; + @ApiModelProperty("物料名称") + private String materiel_name; + @ApiModelProperty("仓库名称") + private String storehouse_name; + +} diff --git a/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/ActualOrderMaterial.java b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/ActualOrderMaterial.java new file mode 100644 index 0000000..9fdb825 --- /dev/null +++ b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/ActualOrderMaterial.java @@ -0,0 +1,54 @@ +package com.yxt.supervise.gf.shanhai.resp; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +/** + * @author feikefei + * @create 2023-07-05-9:43 + */ +@Data +@ApiModel(value = "查看物料实发") +public class ActualOrderMaterial { + @ApiModelProperty("唯一标识") + private String id; + @ApiModelProperty("申请id") + private String apply_id; + @ApiModelProperty("物料id") + private String materiel_id; + @ApiModelProperty("物料编码") + private String materiel_no; + @ApiModelProperty("应付价格") + private String answer_price; + @ApiModelProperty("应发数量") + private String answer_num; + @ApiModelProperty("实际价格") + private String actual_price; + @ApiModelProperty("实际数量") + private String actual_num; + @ApiModelProperty("冻结代理商库存数量") + private String frozen_agent_stock_num; + @ApiModelProperty("品牌") + private String brand_name; + @ApiModelProperty("备注说明") + private String note; + @ApiModelProperty("状态") + private String status; + @ApiModelProperty("备注") + private String remark; + @ApiModelProperty("") + private String materiel_group; + @ApiModelProperty("物料分组说明") + private String materiel_group_text; + @ApiModelProperty("物料名称") + private String materiel_name; + @ApiModelProperty("代理商名称") + private String agent_name; + @ApiModelProperty("申请唯一编码") + private String apply_no; + @ApiModelProperty("申请数量") + private String inventory_num; + @ApiModelProperty("代理商id") + private String agent_id; +} \ No newline at end of file diff --git a/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/ApplyMaterial.java b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/ApplyMaterial.java index 9f87d71..bf5ee97 100644 --- a/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/ApplyMaterial.java +++ b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/ApplyMaterial.java @@ -1,8 +1,10 @@ package com.yxt.supervise.gf.shanhai.resp; +import io.swagger.annotations.ApiModel; import lombok.Data; @Data +@ApiModel(value = "待配货列表") public class ApplyMaterial { // { // "id": 10888, diff --git a/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/Auth.java b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/Auth.java new file mode 100644 index 0000000..4018003 --- /dev/null +++ b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/Auth.java @@ -0,0 +1,35 @@ +package com.yxt.supervise.gf.shanhai.resp; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +/** + * @author feikefei + * @create 2023-07-05-16:11 + */ +@Data +@ApiModel(value = "出库申请",description = "") +public class Auth { + @ApiModelProperty("申请id") + private String id; + @ApiModelProperty("入库id") + private String inventory_record_id; + @ApiModelProperty("审核人id") + private String audit_admin_id; + @ApiModelProperty("审核状态 1为通过 ,2为拒绝") + private String audit_status; + @ApiModelProperty("审核说明") + private String audit_remark; + @ApiModelProperty("") + private String type;// 审核次数 + @ApiModelProperty("审核时间") + private String fin_time;// + @ApiModelProperty("审核人姓名") + private String audit_admin_name; + @ApiModelProperty("审核时间明文") + private String fin_time_text; + @ApiModelProperty("审核状态明文") + private String audit_status_text; + +} diff --git a/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/BaseResponse.java b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/BaseResponse.java index f12be4c..6a321cd 100644 --- a/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/BaseResponse.java +++ b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/BaseResponse.java @@ -1,33 +1,12 @@ package com.yxt.supervise.gf.shanhai.resp; +import lombok.Data; + +@Data public class BaseResponse { //{"code":404,"msg":"header参数验证错误","data":null} private int code; private String msg; private T data; - - public int getCode() { - return code; - } - - public void setCode(int code) { - this.code = code; - } - - public String getMsg() { - return msg; - } - - public void setMsg(String msg) { - this.msg = msg; - } - - public T getData() { - return data; - } - - public void setData(T data) { - this.data = data; - } } diff --git a/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/BaseResponseListObj.java b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/BaseResponseListObj.java index 2c39d68..4de2cc0 100644 --- a/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/BaseResponseListObj.java +++ b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/BaseResponseListObj.java @@ -1,25 +1,12 @@ package com.yxt.supervise.gf.shanhai.resp; +import lombok.Data; + import java.util.List; +@Data public class BaseResponseListObj { private List list; - private long count; - - public List getList() { - return list; - } - - public void setList(List list) { - this.list = list; - } - - public long getCount() { - return count; - } - - public void setCount(long count) { - this.count = count; - } + private Integer count; } diff --git a/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/File.java b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/File.java new file mode 100644 index 0000000..76344d0 --- /dev/null +++ b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/File.java @@ -0,0 +1,30 @@ +package com.yxt.supervise.gf.shanhai.resp; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +/** + * @author feikefei + * @create 2023-07-05-16:06 + */ +@Data +@ApiModel(value = "出库申请",description = "附件文件") +public class File { + @ApiModelProperty("id") + private String id;//10814, + @ApiModelProperty("其他附件") + private String inventory_record_id;//10888, + @ApiModelProperty("合同id") + private String voucher;//null, + @ApiModelProperty("钉钉审批图片") + private String contract_id;//0, + @ApiModelProperty("出货单/供货单") + private String ding;//null, + @ApiModelProperty("合同图片") + private String[] bill; + @ApiModelProperty("创建时间") + private String create_time;//"1682389530", + @ApiModelProperty("审核") + private String create_time_text;//"2023-04-25 10:25:30" +} diff --git a/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/GetInfo.java b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/GetInfo.java new file mode 100644 index 0000000..f5a609c --- /dev/null +++ b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/GetInfo.java @@ -0,0 +1,57 @@ +package com.yxt.supervise.gf.shanhai.resp; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.util.List; + +/** + * @author feikefei + * @create 2023-07-05-15:41 + */ +@Data +@ApiModel(value = "出库申请",description = "出库申请详情") +public class GetInfo { + @ApiModelProperty("申请id") + private String id;// array + @ApiModelProperty("入库id") + private String storehouse_id;// string + @ApiModelProperty("仓库名称") + private String storehouse_name;// string + @ApiModelProperty("批次编号") + private String batch_number;// string + @ApiModelProperty("入库类型") + private String type;// string + @ApiModelProperty("入库类型明文") + private String type_text;// string + @ApiModelProperty("入库时间") + private String happen_time;// string + @ApiModelProperty("审核人名称") + private String admin_name;// string + @ApiModelProperty("供应商名称") + private String supplier_name;// string + @ApiModelProperty("供应商id") + private String supplier_id;// string + @ApiModelProperty("创建时间") + private String create_time;// string + @ApiModelProperty("审核状态") + private String status;// string + @ApiModelProperty("审核时间") + private String opinion_time;// string + @ApiModelProperty("关联批次号") + private String link_batch_number;// string + @ApiModelProperty("备注") + private String note;// string + @ApiModelProperty("审核次数") + private String examine;// string + @ApiModelProperty("当前审核次数") + private String current_examine;// string + @ApiModelProperty("物料信息") + private List maeriel; + @ApiModelProperty("附件文件") + private List file; + @ApiModelProperty("") + private List auth; + +} diff --git a/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/Inventory.java b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/Inventory.java new file mode 100644 index 0000000..17d2962 --- /dev/null +++ b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/Inventory.java @@ -0,0 +1,38 @@ +package com.yxt.supervise.gf.shanhai.resp; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +/** + * @author feikefei + * @create 2023-07-05-14:49 + */ +@Data +@ApiModel(value = "库存管理",description = "库存列表") +public class Inventory { + @ApiModelProperty("库存数量") + private String num;//268 + @ApiModelProperty("仓库名称") + private String storehouse_name;//"藁城荣名库" + @ApiModelProperty("仓库编号") + private String storehouse_code;//"031102" + @ApiModelProperty("物料id") + private String materiel_id;//19428 + @ApiModelProperty("物料编号") + private String materiel_no;//"9001000037" + @ApiModelProperty("物料组id") + private String materiel_group;//7 + @ApiModelProperty("物料品牌") + private String brand_name;//"山海新能" + @ApiModelProperty("物料名称") + private String materiel_name;//"铝线3*95+1-50mm" + @ApiModelProperty("物料单价(成本价)") + private String price;//"0.00" + @ApiModelProperty("最后更新时间") + private String update_time;//1684723525 + @ApiModelProperty("物料组明文") + private String materiel_group_text;//"线缆" + @ApiModelProperty("最后更新时间明文") + private String update_time_text;//"2023-05-22 10:45:25" +} diff --git a/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/Maeriel.java b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/Maeriel.java new file mode 100644 index 0000000..9007eae --- /dev/null +++ b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/Maeriel.java @@ -0,0 +1,48 @@ +package com.yxt.supervise.gf.shanhai.resp; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +/** + * @author feikefei + * @create 2023-07-05-15:59 + */ +@Data +@ApiModel(value = "出库申请",description = "物料信息") +public class Maeriel { + @ApiModelProperty("id") + private String id;//13519, + @ApiModelProperty("所属申请记录id") + private String inventory_record_id;//10888, + @ApiModelProperty("批次号") + private String batch_number;//"2023042500001", + @ApiModelProperty("物料id") + private String materiel_id;//28, + @ApiModelProperty("物料编号") + private String materiel_no;//"3001000050", + @ApiModelProperty("物料名称") + private String materiel_name;//"3号箱40-50kw", + @ApiModelProperty("") + private String brand_name;//"山海智慧", + @ApiModelProperty("入库数量") + private String num;//3, + @ApiModelProperty("原数量") + private String orig_num;//119, + @ApiModelProperty("更新后数量") + private String new_num;//116, + @ApiModelProperty("物料组") + private String materiel_group;//3, + @ApiModelProperty("更新时间") + private String update_time;//"0", + @ApiModelProperty("创建时间") + private String create_time;//"1682389077", + @ApiModelProperty("单价") + private String price;//"1265.00", + @ApiModelProperty("单位") + private String unit;//"个", + @ApiModelProperty("") + private String inventory_num;//80, + @ApiModelProperty("物料组名称") + private String materiel_group_text;//"配电箱" +} diff --git a/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/MaterialStat.java b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/MaterialStat.java new file mode 100644 index 0000000..fa1c005 --- /dev/null +++ b/yxt-supervise-gf-biz/src/main/java/com/yxt/supervise/gf/shanhai/resp/MaterialStat.java @@ -0,0 +1,39 @@ +package com.yxt.supervise.gf.shanhai.resp; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +/** + * @author feikefei + * @create 2023-07-05-10:23 + */ +@Data +@ApiModel(value = "统计物料") +public class MaterialStat { + @ApiModelProperty("物料编号") + private String materiel_no; + @ApiModelProperty("物料名称") + private String name; + @ApiModelProperty("出库数量") + private String out_num; + @ApiModelProperty("入库数量") + private String inp_num; + @ApiModelProperty("采购入库数量") + private String purchase; + @ApiModelProperty("退换货入库") + private String returninc; + @ApiModelProperty("调拨入库") + private String allocationinc; + @ApiModelProperty("备货下单入库") + private String buyinc; + @ApiModelProperty("销售出库") + private String sale; + @ApiModelProperty("退换货出库") + private String returndec; + @ApiModelProperty("调拨出库") + private String allocationdec; + @ApiModelProperty("备货下单出库") + private String buydec; + +} diff --git a/yxt-supervise-gf-biz/src/test/java/demo/tool/SecurTest.java b/yxt-supervise-gf-biz/src/test/java/demo/tool/SecurTest.java index 1e777e9..065aad8 100644 --- a/yxt-supervise-gf-biz/src/test/java/demo/tool/SecurTest.java +++ b/yxt-supervise-gf-biz/src/test/java/demo/tool/SecurTest.java @@ -1,17 +1,15 @@ package demo.tool; import cn.hutool.core.codec.Base64; -import cn.hutool.core.date.DateUtil; -import cn.hutool.core.util.CharsetUtil; -import cn.hutool.core.util.StrUtil; import cn.hutool.crypto.SecureUtil; import cn.hutool.crypto.asymmetric.AsymmetricCrypto; import cn.hutool.crypto.asymmetric.KeyType; import cn.hutool.crypto.asymmetric.RSA; import cn.hutool.http.HttpRequest; -import com.yxt.supervise.gf.api.utils.RsaUtil; import com.yxt.supervise.gf.shanhai.ShRequester; +import com.yxt.supervise.gf.shanhai.req.Examine; import com.yxt.supervise.gf.shanhai.resp.BaseResponse; +import com.yxt.supervise.gf.shanhai.resp.GetInfo; import org.junit.Test; import sun.misc.BASE64Decoder; @@ -21,7 +19,6 @@ import java.security.interfaces.RSAPublicKey; import java.security.spec.InvalidKeySpecException; import java.security.spec.PKCS8EncodedKeySpec; import java.security.spec.X509EncodedKeySpec; -import java.util.Date; public class SecurTest { @@ -72,13 +69,39 @@ public class SecurTest { System.out.println(body); } -// @Test + @Test public void testRequester() { - BaseResponse api$system$applyMaterial$index = ShRequester.getApi$system$apply_material$index(null); - System.out.println(api$system$applyMaterial$index); +// BaseResponse api$system$applyMaterial$index = ShRequester.getApi$system$apply_material$index(null); +// System.out.println(api$system$applyMaterial$index); -// String api$system$applyMaterial$getActualOrderMaterial = ShRequester.getApi$system$apply_material$get_actual_order_material("10888"); +// BaseResponse> api$system$applyMaterial$getActualOrderMaterial = ShRequester.getApi$system$apply_material$get_actual_order_material("10888"); // System.out.println(api$system$applyMaterial$getActualOrderMaterial); + +// BaseResponse> api$system$stock_record$get_material_stat = ShRequester.getApi$system$stock_record$get_material_stat(); +// System.out.println(api$system$stock_record$get_material_stat); + +// String api$system$stock_record$export_data = ShRequester.getApi$system$stock_record$export_data(); +// System.out.println(api$system$stock_record$export_data); + +// String api$system$stock_record$material_stat_export = ShRequester.getApi$system$stock_record$material_stat_export(); +// System.out.println(api$system$stock_record$material_stat_export); + +// BaseResponse> api$system$inventory$index = ShRequester.getApi$system$inventory$index(null); +// System.out.println(api$system$inventory$index); + +// BaseResponse api$system$out_stock$get_info = ShRequester.getApi$system$out_stock$get_info("10888"); +// System.out.println(api$system$out_stock$get_info); + +// Examine examine = new Examine(); +// examine.setId(10888); +// examine.setExamine("1"); +// examine.setStatus("1"); +// examine.setRemark("备注"); +// BaseResponse api$system$out_stock$examine = ShRequester.getApi$system$out_stock$examine(examine); +// System.out.println(api$system$out_stock$examine); + + String api$system$out_stock$export_data = ShRequester.getApi$system$out_stock$export_data(null); + System.out.println(api$system$out_stock$export_data); } /**