Merge branch 'master' of http://121.40.234.130:8899/root/wuHanXinRui
This commit is contained in:
@@ -60,7 +60,7 @@
|
||||
unit.unit_name,
|
||||
SUBSTR(oder.vbillcode,1,6) AS order_code_1,
|
||||
SUBSTR(oder.vbillcode,8,10) AS order_code_2,
|
||||
( oder.qty - dtl.instor_qty ) AS surplus_qty
|
||||
( oder.qty - dtl.receive_qty ) AS surplus_qty
|
||||
FROM
|
||||
PCS_IF_PurchaseOrderProc oder
|
||||
LEFT JOIN MD_CS_SUPPLIERBASE supp ON oder.VEND_ID = supp.ext_id
|
||||
@@ -82,7 +82,7 @@
|
||||
LEFT JOIN PCS_RC_ReceiveMst mst ON mst.receive_id = dtl.receive_id AND mst.is_delete = '0'
|
||||
LEFT JOIN md_pb_measureunit unit ON unit.ext_id = oder.M_UNIT_ID
|
||||
WHERE
|
||||
1=1
|
||||
oder.dr = '0'
|
||||
OPTION 输入.begin_time <> ""
|
||||
oder.CREATE_DATE >= 输入.begin_time
|
||||
ENDOPTION
|
||||
@@ -122,7 +122,7 @@
|
||||
unit.unit_name,
|
||||
SUBSTR(oder.vbillcode,1,6) AS order_code_1,
|
||||
SUBSTR(oder.vbillcode,8,10) AS order_code_2,
|
||||
( oder.qty - dtl.instor_qty ) AS surplus_qty
|
||||
( oder.qty - dtl.receive_qty ) AS surplus_qty
|
||||
FROM
|
||||
PCS_IF_PurchaseOrderProc oder
|
||||
LEFT JOIN MD_CS_SUPPLIERBASE supp ON oder.VEND_ID = supp.ext_id
|
||||
@@ -144,7 +144,7 @@
|
||||
LEFT JOIN md_pb_measureunit unit ON unit.ext_id = oder.M_UNIT_ID
|
||||
LEFT JOIN ST_IVT_IOStorInv ivtmst ON ivtmst.iostorinv_id = dtl.iostorinv_id AND ivtmst.bill_type = '000202'
|
||||
WHERE
|
||||
1=1
|
||||
oder.dr = '0'
|
||||
|
||||
OPTION 输入.type_id <> ""
|
||||
mater.material_type_id in 输入.type_id
|
||||
|
||||
@@ -451,6 +451,9 @@ public class AcceptFormulaServiceImpl implements AcceptFormulaService {
|
||||
// 开单日期
|
||||
oneMap.put("create_time", jsonFormMst.getString("create_time").substring(0,10));
|
||||
|
||||
// 开单人
|
||||
oneMap.put("create_name", jsonFormMst.getString("create_name"));
|
||||
|
||||
/*
|
||||
* 多组填充
|
||||
*/
|
||||
@@ -466,8 +469,8 @@ public class AcceptFormulaServiceImpl implements AcceptFormulaService {
|
||||
if (StrUtil.equals(json.getString("material_type"), "01")) {
|
||||
// 物料:查物料表关联分类表
|
||||
JSONObject jsonDtlMater = materTab.query("material_id = '" + json.getString("material_id") + "'").uniqueResult(0);
|
||||
JSONObject jsonDtlClass = classTab.query("class_id = '" + jsonDtlMater.getString("material_type_id") + "'").uniqueResult(0);
|
||||
class_name = jsonDtlClass.getString("class_name");
|
||||
// JSONObject jsonDtlClass = classTab.query("class_id = '" + jsonDtlMater.getString("material_type_id") + "'").uniqueResult(0);
|
||||
class_name = jsonDtlMater.getString("material_name");
|
||||
} else {
|
||||
// 分类:直接用明细表的物料标识查基础分类表
|
||||
JSONObject jsonDtlClass = classTab.query("class_id = '" + json.getString("material_id") + "'").uniqueResult(0);
|
||||
|
||||
@@ -155,15 +155,18 @@ public class DevicerepairrequestServiceImpl implements DevicerepairrequestServic
|
||||
DeptService deptService = SpringContextHolder.getBean(DeptService.class);
|
||||
|
||||
WQLObject fileTab = WQLObject.getWQLObject("EM_BI_EquipmentFile");
|
||||
WQLObject userTab = WQLObject.getWQLObject("sys_user");
|
||||
|
||||
Long currentUserId = SecurityUtils.getCurrentUserId();
|
||||
String nickName = SecurityUtils.getNickName();
|
||||
String now = DateUtil.now();
|
||||
JSONObject jsonUser = WQLObject.getWQLObject("sys_user").query("user_id = '" + currentUserId + "'").uniqueResult(0);
|
||||
|
||||
// 前一天运行记录表 超过三条没填的报错
|
||||
// 根据登陆人员的部门查询设备使用班组对应的运行记录 超过三条没填的报错
|
||||
JSONArray numRunArr = new JSONArray();
|
||||
JSONArray fileArr = fileTab.query("use_groupid = '"+jsonUser.getString("dept_id")+"' and is_delete = '0' and status not in ('90','91')").getResultJSONArray(0);
|
||||
|
||||
String yesterday = DateUtil.yesterday().toString().substring(0,10);
|
||||
JSONArray fileArr = fileTab.query("is_delete = '0' and status not in ('90','91')").getResultJSONArray(0);
|
||||
|
||||
JSONObject map = new JSONObject();
|
||||
map.put("flag", "5");
|
||||
@@ -178,10 +181,10 @@ public class DevicerepairrequestServiceImpl implements DevicerepairrequestServic
|
||||
|
||||
if (numRunArr.size() > 3) throw new BadRequestException("昨天设备运行记录有超过3条未填写,未填写:"+String.valueOf(numRunArr.size()) + "条");
|
||||
|
||||
|
||||
JwtUserDto currentUser = (JwtUserDto) SecurityUtils.getCurrentUser();
|
||||
Long deptId = currentUser.getDeptId();
|
||||
// 登录人所在班组下的设备维修单(结束维修) > 2 报错
|
||||
JSONObject jsonUser = WQLObject.getWQLObject("sys_user").query("user_id = '" + currentUserId + "'").uniqueResult(0);
|
||||
if (ObjectUtil.isNotEmpty(jsonUser)) {
|
||||
String dept_str = deptService.getChildIdStr(jsonUser.getLong("dept_id"));
|
||||
JSONObject json = WQL.getWO("EM_BI_DEVICEREPAIRREQUEST001").addParam("flag", "4").addParam("deptIds", dept_str).process().uniqueResult(0);
|
||||
|
||||
Reference in New Issue
Block a user