|
|
@ -245,6 +245,7 @@ public class QyWxOperationService { |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* 用于向企业微信中该盘点记录的负责人发送盘点消息 |
|
|
* 用于向企业微信中该盘点记录的负责人发送盘点消息 |
|
|
|
|
|
* |
|
|
* @param uid 接收人 |
|
|
* @param uid 接收人 |
|
|
* @param mainId 盘点记录编号 |
|
|
* @param mainId 盘点记录编号 |
|
|
* @return |
|
|
* @return |
|
|
@ -404,8 +405,6 @@ public class QyWxOperationService { |
|
|
horizontal_content_inventory.setValue(stockTakingInventory.toString()); |
|
|
horizontal_content_inventory.setValue(stockTakingInventory.toString()); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 二级标题+文本列表,用于设置申请查看明细
|
|
|
// 二级标题+文本列表,用于设置申请查看明细
|
|
|
TemplateCard_horizontal_content horizontal_content_detail = new TemplateCard_horizontal_content(); |
|
|
TemplateCard_horizontal_content horizontal_content_detail = new TemplateCard_horizontal_content(); |
|
|
// 链接类型 0代表不是链接
|
|
|
// 链接类型 0代表不是链接
|
|
|
@ -491,6 +490,7 @@ public class QyWxOperationService { |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* 用于向企业微信盘点人员发送盘点消息 |
|
|
* 用于向企业微信盘点人员发送盘点消息 |
|
|
|
|
|
* |
|
|
* @param uid 接收人 |
|
|
* @param uid 接收人 |
|
|
* @param mainId 盘点记录编号 |
|
|
* @param mainId 盘点记录编号 |
|
|
* @return |
|
|
* @return |
|
|
@ -654,8 +654,6 @@ public class QyWxOperationService { |
|
|
horizontal_content_inventory.setValue(stockTakingInventory.toString()); |
|
|
horizontal_content_inventory.setValue(stockTakingInventory.toString()); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 二级标题+文本列表,用于设置申请查看明细
|
|
|
// 二级标题+文本列表,用于设置申请查看明细
|
|
|
TemplateCard_horizontal_content horizontal_content_detail = new TemplateCard_horizontal_content(); |
|
|
TemplateCard_horizontal_content horizontal_content_detail = new TemplateCard_horizontal_content(); |
|
|
// 链接类型 0代表不是链接
|
|
|
// 链接类型 0代表不是链接
|
|
|
@ -666,6 +664,13 @@ public class QyWxOperationService { |
|
|
horizontal_content_detail.setUrl("https://jy.hxgk.group/StockTakingView?id=" + mainId); |
|
|
horizontal_content_detail.setUrl("https://jy.hxgk.group/StockTakingView?id=" + mainId); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 卡片整体点击方法
|
|
|
|
|
|
TemplateCard_card_action card_action = new TemplateCard_card_action(); |
|
|
|
|
|
card_action.setType(1); |
|
|
|
|
|
card_action.setUrl("https://jy.hxgk.group/StockTakingView?id=" + mainId); |
|
|
|
|
|
templateCard_button_interaction.setCard_action(card_action); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
List<TemplateCard_horizontal_content> horizontal_contentList = new ArrayList<>(); |
|
|
List<TemplateCard_horizontal_content> horizontal_contentList = new ArrayList<>(); |
|
|
horizontal_contentList.add(horizontal_content_mname); |
|
|
horizontal_contentList.add(horizontal_content_mname); |
|
|
horizontal_contentList.add(horizontal_content_quantity); |
|
|
horizontal_contentList.add(horizontal_content_quantity); |
|
|
@ -930,6 +935,7 @@ public class QyWxOperationService { |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* 用于向负责人发送盘点过程中的错误信息 |
|
|
* 用于向负责人发送盘点过程中的错误信息 |
|
|
|
|
|
* |
|
|
* @param uid 接收人 |
|
|
* @param uid 接收人 |
|
|
* @param errIds 错误id |
|
|
* @param errIds 错误id |
|
|
* @param mainRecord 主订单 |
|
|
* @param mainRecord 主订单 |
|
|
@ -1025,6 +1031,7 @@ public class QyWxOperationService { |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* 将转移信息发送给盘点人员 |
|
|
* 将转移信息发送给盘点人员 |
|
|
|
|
|
* |
|
|
* @param map |
|
|
* @param map |
|
|
* @return |
|
|
* @return |
|
|
*/ |
|
|
*/ |
|
|
@ -1125,7 +1132,6 @@ public class QyWxOperationService { |
|
|
MaterialAndPlace newPlaceAndMaterial = placeMapper.findPlaceAndMaterialByMidAndPid(paramForMaterialAndPlace); |
|
|
MaterialAndPlace newPlaceAndMaterial = placeMapper.findPlaceAndMaterialByMidAndPid(paramForMaterialAndPlace); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
content.append(">- 物料名称:").append(material.getMname()).append("%n"); |
|
|
content.append(">- 物料名称:").append(material.getMname()).append("%n"); |
|
|
content.append(">- 盘点数量:").append(minRecord.getNewInventory()).append("%n"); |
|
|
content.append(">- 盘点数量:").append(minRecord.getNewInventory()).append("%n"); |
|
|
content.append(">- 盘点位置:").append(fromLocation).append("%n"); |
|
|
content.append(">- 盘点位置:").append(fromLocation).append("%n"); |
|
|
@ -1237,16 +1243,28 @@ public class QyWxOperationService { |
|
|
horizontal_content_mname.setType(0); |
|
|
horizontal_content_mname.setType(0); |
|
|
horizontal_content_mname.setKeyname("物料名称:"); |
|
|
horizontal_content_mname.setKeyname("物料名称:"); |
|
|
horizontal_content_mname.setValue(materialById.getMname()); |
|
|
horizontal_content_mname.setValue(materialById.getMname()); |
|
|
// 物料编码
|
|
|
// 物料编码规格型号
|
|
|
TemplateCard_horizontal_content horizontal_content_mcode = new TemplateCard_horizontal_content(); |
|
|
TemplateCard_horizontal_content horizontal_content_version = new TemplateCard_horizontal_content(); |
|
|
horizontal_content_mcode.setType(0); |
|
|
horizontal_content_version.setType(0); |
|
|
horizontal_content_mcode.setKeyname("物料编码:"); |
|
|
horizontal_content_version.setKeyname("物料型号:"); |
|
|
horizontal_content_mcode.setValue(materialById.getCode()); |
|
|
horizontal_content_version.setValue(materialById.getVersion()); |
|
|
// 申请数量
|
|
|
// 申请数量
|
|
|
TemplateCard_horizontal_content horizontal_content_quantity = new TemplateCard_horizontal_content(); |
|
|
TemplateCard_horizontal_content horizontal_content_quantity = new TemplateCard_horizontal_content(); |
|
|
horizontal_content_quantity.setType(0); |
|
|
horizontal_content_quantity.setType(0); |
|
|
horizontal_content_quantity.setKeyname("申请数量:"); |
|
|
horizontal_content_quantity.setKeyname("申请数量:"); |
|
|
horizontal_content_quantity.setValue(recordMin.getQuantity().toString()); |
|
|
horizontal_content_quantity.setValue(recordMin.getQuantity().toString()); |
|
|
|
|
|
|
|
|
|
|
|
// 申请单位
|
|
|
|
|
|
TemplateCard_horizontal_content horizontal_content_unit = new TemplateCard_horizontal_content(); |
|
|
|
|
|
horizontal_content_unit.setType(0); |
|
|
|
|
|
horizontal_content_unit.setKeyname("申请单位:"); |
|
|
|
|
|
// 当前申请单位
|
|
|
|
|
|
String unit = recordMin.getUnit(); |
|
|
|
|
|
if ("-1".equals(unit)) { |
|
|
|
|
|
// 如果是基础单位
|
|
|
|
|
|
unit = materialById.getUnit(); |
|
|
|
|
|
} |
|
|
|
|
|
horizontal_content_unit.setValue(unit); |
|
|
// 所在仓库
|
|
|
// 所在仓库
|
|
|
TemplateCard_horizontal_content horizontal_content_depository = new TemplateCard_horizontal_content(); |
|
|
TemplateCard_horizontal_content horizontal_content_depository = new TemplateCard_horizontal_content(); |
|
|
horizontal_content_depository.setType(0); |
|
|
horizontal_content_depository.setType(0); |
|
|
@ -1260,8 +1278,9 @@ public class QyWxOperationService { |
|
|
horizontal_content_applyRemark.setValue(outRecordP.getApplyRemark()); |
|
|
horizontal_content_applyRemark.setValue(outRecordP.getApplyRemark()); |
|
|
|
|
|
|
|
|
horizontalContentList.add(horizontal_content_mname); |
|
|
horizontalContentList.add(horizontal_content_mname); |
|
|
horizontalContentList.add(horizontal_content_mcode); |
|
|
horizontalContentList.add(horizontal_content_version); |
|
|
horizontalContentList.add(horizontal_content_quantity); |
|
|
horizontalContentList.add(horizontal_content_quantity); |
|
|
|
|
|
horizontalContentList.add(horizontal_content_unit); |
|
|
horizontalContentList.add(horizontal_content_depository); |
|
|
horizontalContentList.add(horizontal_content_depository); |
|
|
horizontalContentList.add(horizontal_content_applyRemark); |
|
|
horizontalContentList.add(horizontal_content_applyRemark); |
|
|
|
|
|
|
|
|
@ -1349,6 +1368,7 @@ public class QyWxOperationService { |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* 获取审批模板详细 |
|
|
* 获取审批模板详细 |
|
|
|
|
|
* |
|
|
* @return |
|
|
* @return |
|
|
*/ |
|
|
*/ |
|
|
public JSONObject getApprovalTemplateInfo(String userAgent, String template_id) { |
|
|
public JSONObject getApprovalTemplateInfo(String userAgent, String template_id) { |
|
|
@ -1364,6 +1384,7 @@ public class QyWxOperationService { |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* 用于发送物料出库审批 |
|
|
* 用于发送物料出库审批 |
|
|
|
|
|
* |
|
|
* @param userAgent 加密后的userAgent |
|
|
* @param userAgent 加密后的userAgent |
|
|
* @param userToken 申请人 |
|
|
* @param userToken 申请人 |
|
|
* @param mainId 出库的主订单 |
|
|
* @param mainId 出库的主订单 |
|
|
@ -1576,7 +1597,7 @@ public class QyWxOperationService { |
|
|
detail_list_control_info_unit.put("value", detail_list_control_info_value_unit); |
|
|
detail_list_control_info_unit.put("value", detail_list_control_info_value_unit); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 物料名称
|
|
|
// 仓库名称
|
|
|
Map<String, Object> detail_list_control_info_depositoryName = new HashMap<>(); |
|
|
Map<String, Object> detail_list_control_info_depositoryName = new HashMap<>(); |
|
|
detail_list_control_info_depositoryName.put("control", "Text"); |
|
|
detail_list_control_info_depositoryName.put("control", "Text"); |
|
|
detail_list_control_info_depositoryName.put("id", "Text-1668137728919"); |
|
|
detail_list_control_info_depositoryName.put("id", "Text-1668137728919"); |
|
|
@ -1592,12 +1613,29 @@ public class QyWxOperationService { |
|
|
detail_list_control_info_value_dname.put("text", depositoryById.getDname()); |
|
|
detail_list_control_info_value_dname.put("text", depositoryById.getDname()); |
|
|
detail_list_control_info_depositoryName.put("value", detail_list_control_info_value_dname); |
|
|
detail_list_control_info_depositoryName.put("value", detail_list_control_info_value_dname); |
|
|
|
|
|
|
|
|
|
|
|
// 物料规格型号
|
|
|
|
|
|
Map<String, Object> detail_list_control_info_version = new HashMap<>(); |
|
|
|
|
|
detail_list_control_info_version.put("control", "Text"); |
|
|
|
|
|
detail_list_control_info_version.put("id", "Text-1672879620723"); |
|
|
|
|
|
Map<String, String> detail_list_control_info_title_version = new HashMap<>(); |
|
|
|
|
|
detail_list_control_info_title_version.put("text", "规格型号"); |
|
|
|
|
|
detail_list_control_info_title_version.put("lang", "zh_CN"); |
|
|
|
|
|
|
|
|
|
|
|
List<Object> detail_list_control_info_title_list_version = new ArrayList<>(); |
|
|
|
|
|
detail_list_control_info_title_list_version.add(detail_list_control_info_title_version); |
|
|
|
|
|
detail_list_control_info_version.put("title", detail_list_control_info_title_list_version); |
|
|
|
|
|
|
|
|
|
|
|
Map<String, String> detail_list_control_info_value_version = new HashMap<>(); |
|
|
|
|
|
detail_list_control_info_value_version.put("text", materialById.getVersion() == null ? "" : materialById.getVersion()); |
|
|
|
|
|
detail_list_control_info_version.put("value", detail_list_control_info_value_version); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
detail_list_control.add(detail_list_control_info_materialName); |
|
|
detail_list_control.add(detail_list_control_info_materialName); |
|
|
detail_list_control.add(detail_list_control_info_materialCode); |
|
|
detail_list_control.add(detail_list_control_info_materialCode); |
|
|
detail_list_control.add(detail_list_control_info_outNumber); |
|
|
detail_list_control.add(detail_list_control_info_outNumber); |
|
|
detail_list_control.add(detail_list_control_info_depositoryName); |
|
|
detail_list_control.add(detail_list_control_info_depositoryName); |
|
|
detail_list_control.add(detail_list_control_info_unit); |
|
|
detail_list_control.add(detail_list_control_info_unit); |
|
|
|
|
|
detail_list_control.add(detail_list_control_info_version); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
detail_list.put("list", detail_list_control); |
|
|
detail_list.put("list", detail_list_control); |
|
|
@ -1673,6 +1711,7 @@ public class QyWxOperationService { |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* 用于发送出库审批 |
|
|
* 用于发送出库审批 |
|
|
|
|
|
* |
|
|
* @param userAgent 加密后的userAgent |
|
|
* @param userAgent 加密后的userAgent |
|
|
* @param userToken 审批人 |
|
|
* @param userToken 审批人 |
|
|
* @param mainId 主订单 |
|
|
* @param mainId 主订单 |
|
|
@ -1786,7 +1825,6 @@ public class QyWxOperationService { |
|
|
approval_template_apply_data_contents_list.add(approval_template_apply_data_contents_department); |
|
|
approval_template_apply_data_contents_list.add(approval_template_apply_data_contents_department); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//定义模板控件——明细
|
|
|
//定义模板控件——明细
|
|
|
Approval_template_apply_data_contents approval_template_apply_data_contents_info = new Approval_template_apply_data_contents(); |
|
|
Approval_template_apply_data_contents approval_template_apply_data_contents_info = new Approval_template_apply_data_contents(); |
|
|
approval_template_apply_data_contents_info.setControl("Table"); |
|
|
approval_template_apply_data_contents_info.setControl("Table"); |
|
|
@ -1877,7 +1915,7 @@ public class QyWxOperationService { |
|
|
detail_list_control_info_value_unit.put("text", unit); |
|
|
detail_list_control_info_value_unit.put("text", unit); |
|
|
detail_list_control_info_unit.put("value", detail_list_control_info_value_unit); |
|
|
detail_list_control_info_unit.put("value", detail_list_control_info_value_unit); |
|
|
|
|
|
|
|
|
// 物料名称
|
|
|
// 仓库名称
|
|
|
Map<String, Object> detail_list_control_info_depositoryName = new HashMap<>(); |
|
|
Map<String, Object> detail_list_control_info_depositoryName = new HashMap<>(); |
|
|
detail_list_control_info_depositoryName.put("control", "Text"); |
|
|
detail_list_control_info_depositoryName.put("control", "Text"); |
|
|
detail_list_control_info_depositoryName.put("id", "Text-1668220760317"); |
|
|
detail_list_control_info_depositoryName.put("id", "Text-1668220760317"); |
|
|
@ -1894,10 +1932,28 @@ public class QyWxOperationService { |
|
|
detail_list_control_info_depositoryName.put("value", detail_list_control_info_value_dname); |
|
|
detail_list_control_info_depositoryName.put("value", detail_list_control_info_value_dname); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 物料规格型号
|
|
|
|
|
|
Map<String, Object> detail_list_control_info_version = new HashMap<>(); |
|
|
|
|
|
detail_list_control_info_version.put("control", "Text"); |
|
|
|
|
|
detail_list_control_info_version.put("id", "Text-1672880000043"); |
|
|
|
|
|
Map<String, String> detail_list_control_info_title_version = new HashMap<>(); |
|
|
|
|
|
detail_list_control_info_title_version.put("text", "规格型号"); |
|
|
|
|
|
detail_list_control_info_title_version.put("lang", "zh_CN"); |
|
|
|
|
|
|
|
|
|
|
|
List<Object> detail_list_control_info_title_list_version = new ArrayList<>(); |
|
|
|
|
|
detail_list_control_info_title_list_version.add(detail_list_control_info_title_version); |
|
|
|
|
|
detail_list_control_info_version.put("title", detail_list_control_info_title_list_version); |
|
|
|
|
|
|
|
|
|
|
|
Map<String, String> detail_list_control_info_value_version = new HashMap<>(); |
|
|
|
|
|
detail_list_control_info_value_version.put("text", materialById.getVersion() == null ? "" : materialById.getVersion()); |
|
|
|
|
|
detail_list_control_info_version.put("value", detail_list_control_info_value_version); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
detail_list_control.add(detail_list_control_info_materialName); |
|
|
detail_list_control.add(detail_list_control_info_materialName); |
|
|
detail_list_control.add(detail_list_control_info_materialCode); |
|
|
detail_list_control.add(detail_list_control_info_materialCode); |
|
|
detail_list_control.add(detail_list_control_info_outNumber); |
|
|
detail_list_control.add(detail_list_control_info_outNumber); |
|
|
detail_list_control.add(detail_list_control_info_depositoryName); |
|
|
detail_list_control.add(detail_list_control_info_depositoryName); |
|
|
|
|
|
detail_list_control.add(detail_list_control_info_version); |
|
|
detail_list_control.add(detail_list_control_info_unit); |
|
|
detail_list_control.add(detail_list_control_info_unit); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -1982,9 +2038,9 @@ public class QyWxOperationService { |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* 用于发送库存判断审批 |
|
|
* 用于发送库存判断审批 |
|
|
|
|
|
* |
|
|
* @param userAgent |
|
|
* @param userAgent |
|
|
* @param userToken |
|
|
* @param userToken |
|
|
* @param mainId |
|
|
* @param mainId |
|
|
@ -2236,7 +2292,6 @@ public class QyWxOperationService { |
|
|
detail_list_control_info_materialTexture.put("value", detail_list_control_info_value_materialTexture); |
|
|
detail_list_control_info_materialTexture.put("value", detail_list_control_info_value_materialTexture); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 物料规格型号
|
|
|
// 物料规格型号
|
|
|
Map<String, Object> detail_list_control_info_materialVersion = new HashMap<>(); |
|
|
Map<String, Object> detail_list_control_info_materialVersion = new HashMap<>(); |
|
|
detail_list_control_info_materialVersion.put("control", "Text"); |
|
|
detail_list_control_info_materialVersion.put("control", "Text"); |
|
|
@ -2350,7 +2405,6 @@ public class QyWxOperationService { |
|
|
detail_list_control_info_stockTakingInventory.put("value", detail_list_control_info_value_stockTakingInventory); |
|
|
detail_list_control_info_stockTakingInventory.put("value", detail_list_control_info_value_stockTakingInventory); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
detail_list_control.add(detail_list_control_info_materialName); |
|
|
detail_list_control.add(detail_list_control_info_materialName); |
|
|
detail_list_control.add(detail_list_control_info_materialCode); |
|
|
detail_list_control.add(detail_list_control_info_materialCode); |
|
|
detail_list_control.add(detail_list_control_info_materialType); |
|
|
detail_list_control.add(detail_list_control_info_materialType); |
|
|
@ -2433,10 +2487,9 @@ public class QyWxOperationService { |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* 用于当在系统内进行审批后向其他所有用户发送消息 |
|
|
* 用于当在系统内进行审批后向其他所有用户发送消息 |
|
|
|
|
|
* |
|
|
* @param mainId |
|
|
* @param mainId |
|
|
* @param uid |
|
|
* @param uid |
|
|
* @param userAgent |
|
|
* @param userAgent |
|
|
|