Commit 982b87b4 authored by zhoumaotao's avatar zhoumaotao

代码调整

parent 5ce394fa
......@@ -27,7 +27,6 @@ import com.gavel.common.utils.BooleanEnum;
import com.gavel.common.utils.DateUtils;
import com.gavel.common.utils.StringUtils;
import com.gavel.common.utils.ThreadContext;
import com.gavel.file.vo.FilesVO;
import com.gavel.gygl.vo.BzgxVO;
import com.gavel.kwell.persistent.Gpfk;
import com.gavel.kwell.service.GpfkService;
......@@ -37,7 +36,7 @@ import com.gavel.kwell.vo.GpbhgfkCondition;
import com.gavel.kwell.vo.GpbhgmxVO;
import com.gavel.kwell.vo.GpfkCondition;
import com.gavel.kwell.vo.GpfkVO;
import com.gavel.kwell.vo.HzWoVO;
import com.gavel.kwell.vo.WosngzVO;
import com.gavel.persistence.sql.RecordSet;
import com.gavel.wo.vo.WobomVO;
......@@ -132,7 +131,7 @@ public class GpfkController extends BaseController {
setReturnMessage("条码不允许为空!");
return returnData();
}
HzWoVO woVO = gpfkService.queryWoBySnid(wosnid);
WosngzVO woVO = gpfkService.queryWoBySnid(wosnid);
if(woVO != null){
return buildReturnData(woVO);
}else{
......
......@@ -61,8 +61,8 @@ public class WosngzController extends BaseController {
@RequestMapping(value = BaseURL.QUERY, method = RequestMethod.POST)
@ResponseBody
public Object query(@RequestBody GpWoCondition condition) {
RecordSet<HzWoVO> records = gpfkService.queryWosngz(condition);
return buildReturnData(records, HzWoVO.class);
RecordSet<WosngzVO> records = gpfkService.queryWosngz(condition);
return buildReturnData(records, WosngzVO.class);
}
@ResourcePermissions(SystemOperation.BottonResource.EXPORT)
......@@ -70,7 +70,7 @@ public class WosngzController extends BaseController {
@ResponseBody
public void export(HttpServletRequest request, HttpServletResponse response, @RequestBody JSONObject param) throws Exception {
GpWoCondition condition = DataConvert.getCondition(param.getJSONObject("condition"), GpWoCondition.class);
RecordSet<HzWoVO> records = gpfkService.queryWosngz(condition);
RecordSet<WosngzVO> records = gpfkService.queryWosngz(condition);
doExport(request, response, param, records.getRecords());
}
......
......@@ -16,7 +16,7 @@ import com.gavel.kwell.vo.GpbhgmxVO;
import com.gavel.kwell.vo.GpfkCondition;
import com.gavel.kwell.vo.GpfkVO;
import com.gavel.kwell.vo.GpwxmxVO;
import com.gavel.kwell.vo.HzWoVO;
import com.gavel.kwell.vo.WosngzVO;
import com.gavel.persistence.sql.RecordSet;
import com.gavel.wo.vo.WobomVO;
import com.gavel.wo.vo.WogylxVO;
......@@ -28,7 +28,7 @@ public interface GpfkDao extends BaseDao {
public RecordSet<GpfkVO> queryZyjhGpfk(GpfkCondition condition);
public HzWoVO queryWoBySnid(String snid);
public WosngzVO queryWoBySnid(String snid);
public List<Gpfk> queryExistGpfk(String wosnid, String gxid);
......@@ -36,7 +36,7 @@ public interface GpfkDao extends BaseDao {
public GpfkVO getLastGpfk(String wosnid,String[] lhids);
public RecordSet<HzWoVO> queryWosngz(GpWoCondition condition);
public RecordSet<WosngzVO> queryWosngz(GpWoCondition condition);
public List<GpfkVO> queryWosngzByWosnid(String wosnid,String[] lhids);
......@@ -111,7 +111,7 @@ public interface GpfkDao extends BaseDao {
/**科威尔工票反馈sql */
public HzWoVO queryKwellWoBySnid(String snid);
public WosngzVO queryKwellWoBySnid(String snid);
public List<WobomVO> queryWobomByWo(String woid,String bzlx);
......
package com.gavel.kwell.dao;
import com.gavel.common.base.dao.BaseDao;
import com.gavel.kwell.persistent.HzWosn;
import com.gavel.kwell.vo.UWosnCondition;
import com.gavel.kwell.vo.UWosnVO;
import com.gavel.persistence.sql.RecordSet;
import com.gavel.wo.persistent.Wosn;
public interface UWosnDao extends BaseDao {
......@@ -13,7 +13,7 @@ public interface UWosnDao extends BaseDao {
public RecordSet<UWosnVO> wosnZpxx(UWosnCondition condition);
public HzWosn queryByCode(String wosnid);
public Wosn queryByCode(String wosnid);
public int queryHasPringCount(String id);
}
......@@ -24,7 +24,7 @@ import com.gavel.kwell.vo.GpbhgmxVO;
import com.gavel.kwell.vo.GpfkCondition;
import com.gavel.kwell.vo.GpfkVO;
import com.gavel.kwell.vo.GpwxmxVO;
import com.gavel.kwell.vo.HzWoVO;
import com.gavel.kwell.vo.WosngzVO;
import com.gavel.persistence.sql.RecordSet;
import com.gavel.persistence.sql.SqlMap;
import com.gavel.persistence.sql.SqlUtil;
......@@ -45,8 +45,8 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
sqlMap.append(" GPFK_WHRID, GPFK_WHR, GPFK_WHSJ, GPFK_CJRID, GPFK_CJR, ");
sqlMap.append(" GPFK_CJSJ, GPFK_SYSVERSION, GPFK_FKRID, GPFK_FKBX, GPFK_FKJSSJ, ");
sqlMap.append(" BX_CODE, BX_NAME, BZGX_CODE, BZGX_NAME, ");
sqlMap.append(" WLXX_CODE, WLXX_NAME, WLXX_GG, U_WLXX_BZLHSJ, WO_DJID, ");
sqlMap.append(" DATEDIFF(mi,GPFK_FKSJ,GPFK_FKJSSJ) as gxhs, U_WLXX_JZNAME, ");
sqlMap.append(" WLXX_CODE, WLXX_NAME, WLXX_GG,WO_DJID, ");
sqlMap.append(" DATEDIFF(mi,GPFK_FKSJ,GPFK_FKJSSJ) as gxhs, ");
sqlMap.append(" GPFK_GFSL, GPFK_LFSL, GPFK_FXSL, GPFK_FGSL, GPFK_YWRQ, GPFK_HGDJ, WOSN_KHCODE");
sqlMap.append("from GPFK ");
sqlMap.append(" left join BX on BX_ID = GPFK_FKBX ");
......@@ -65,10 +65,10 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
sqlMap.append(" and GPFK_FKGX = :pFKGX ");
sqlMap.setParamValue("pFKGX",condition.getGxid());
}
// if (StringUtils.isNotEmpty(condition.getBxid())){
// sqlMap.append(" and GPFK_FKBX = :pBXID ");
// sqlMap.setParamValue("pBXID",condition.getBxid());
// }
if (StringUtils.isNotEmpty(condition.getBxid())){
sqlMap.append(" and GPFK_FKBX = :pBXID ");
sqlMap.setParamValue("pBXID",condition.getBxid());
}
if (StringUtils.isNotEmpty(condition.getFkrid())){
sqlMap.append(" and GPFK_FKRID = :pFKRID ");
sqlMap.setParamValue("pFKRID",condition.getFkrid());
......@@ -105,8 +105,8 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
sqlMap.append(" GPFK_WHRID, GPFK_WHR, GPFK_WHSJ, GPFK_CJRID, GPFK_CJR, ");
sqlMap.append(" GPFK_CJSJ, GPFK_SYSVERSION, GPFK_FKRID, GPFK_FKBX, GPFK_FKJSSJ,");
sqlMap.append(" BX_CODE, BX_NAME, BZGX_CODE, BZGX_NAME, ");
sqlMap.append(" WLXX_CODE, WLXX_NAME, WLXX_GG, U_WLXX_BZLHSJ, WO_DJID, ");
sqlMap.append(" DATEDIFF(mi,GPFK_FKSJ,GPFK_FKJSSJ) as gxhs, U_WLXX_JZNAME, ");
sqlMap.append(" WLXX_CODE, WLXX_NAME, WLXX_GG, WO_DJID, ");
sqlMap.append(" DATEDIFF(mi,GPFK_FKSJ,GPFK_FKJSSJ) as gxhs, ");
sqlMap.append(" GPFK_GFSL, GPFK_LFSL, GPFK_FXSL, GPFK_FGSL, GPFK_HGDJ, WOSN_KHCODE ");
sqlMap.append("from GPFK ");
sqlMap.append(" left join BX on BX_ID = GPFK_FKBX ");
......@@ -161,8 +161,8 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
sqlMap.append(" GPFK_WHRID, GPFK_WHR, GPFK_WHSJ, GPFK_CJRID, GPFK_CJR, ");
sqlMap.append(" GPFK_CJSJ, GPFK_SYSVERSION, GPFK_FKRID, GPFK_FKBX, GPFK_FKJSSJ, ");
sqlMap.append(" BX_CODE, BX_NAME, BZGX_CODE, BZGX_NAME, ");
sqlMap.append(" WLXX_CODE, WLXX_NAME, WLXX_GG, U_WLXX_BZLHSJ, WO_DJID, ");
sqlMap.append(" DATEDIFF(mi,GPFK_FKSJ,GPFK_FKJSSJ) as gxhs, U_WLXX_JZNAME, ");
sqlMap.append(" WLXX_CODE, WLXX_NAME, WLXX_GG,WO_DJID, ");
sqlMap.append(" DATEDIFF(mi,GPFK_FKSJ,GPFK_FKJSSJ) as gxhs, ");
sqlMap.append(" GPFK_GFSL, GPFK_LFSL, GPFK_FXSL, GPFK_FGSL ");
sqlMap.append("from GPFK ");
sqlMap.append(" left join BX on BX_ID = GPFK_FKBX ");
......@@ -213,7 +213,7 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
}
@Override
public HzWoVO queryWoBySnid(String snid){
public WosngzVO queryWoBySnid(String snid){
SqlMap sqlMap = new SqlMap();
sqlMap.append("select WO_ID, WO_DJID, WO_GCID, WO_YWRQ, WO_WLID, WO_XQSL, ");
sqlMap.append(" WO_JHKGRQ, WO_JHWGRQ, WO_BMID, WO_SCXID, WO_DJLY, ");
......@@ -223,8 +223,7 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
sqlMap.append(" WO_HGSL, WO_BZ, WO_WHRID, WO_WHR, WO_WHSJ, ");
sqlMap.append(" WO_CJRID, WO_CJR, WO_CJSJ, WO_SYSVERSION, BM_CODE, ");
sqlMap.append(" BM_NAME, GC_CODE, GC_NAME, SCX_CODE, SCX_NAME,");
sqlMap.append(" WLXX_CODE, WLXX_NAME, WLXX_GG, JLDW_NAME, U_WLXX_BZLHSJ, ");
sqlMap.append(" WOSN_CODE, U_WLXX_JZNAME, WO_WLID, ");
sqlMap.append(" WLXX_CODE, WLXX_NAME, WLXX_GG, JLDW_NAME,WOSN_CODE, WO_WLID, ");
sqlMap.append(" GCXM_CODE, GCXM_NAME, KH_CODE, KH_NAME, WOSN_ID ");
sqlMap.append("from WO ");
sqlMap.append(" left join GC on GC_ID = WO_GCID");
......@@ -238,7 +237,7 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
sqlMap.append("where 1 = 1 ");
sqlMap.append(" and WOSN_CODE = :pSNID ");
sqlMap.setParamValue("pSNID",snid);
return sqlMap.queryEntity(HzWoVO.class);
return sqlMap.queryEntity(WosngzVO.class);
}
@Override
......@@ -333,7 +332,7 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
@Override
public RecordSet<HzWoVO> queryWosngz(GpWoCondition condition){
public RecordSet<WosngzVO> queryWosngz(GpWoCondition condition){
SqlMap sqlMap = new SqlMap();
sqlMap.setPageNo(condition.getPageNo());
sqlMap.setRowCount(condition.getPageSize());
......@@ -343,52 +342,18 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
sqlMap.append(" WO_GBYY, WO_BOMID, WO_GYLXID, WO_PCYXJ, WO_LYDJID, ");
sqlMap.append(" WO_WGSL, WO_SJKGRQ, WO_SJWGRQ, WO_SNNUM, WO_SJSL, ");
sqlMap.append(" WO_HGSL, WO_BZ, BM_CODE, BM_NAME, GC_CODE, GC_NAME,");
sqlMap.append(" WLXX_CODE, WLXX_NAME, U_WLXX_BZLHSJ, WOSN_CODE, ");
sqlMap.append(" U_WLXX_JZNAME, BZGX_NAME,GPFK_FKR,GPFK_CZSJ,GZZX_ID, ");
sqlMap.append(" GZZX_NAME, BX_ID, BX_NAME, U_WOSN_HGDJ ");
sqlMap.append(" WLXX_CODE, WLXX_NAME, WOSN_CODE,BZGX_NAME, GPFK_FKR, ");
sqlMap.append(" GPFK_CZSJ,GZZX_ID,GZZX_NAME, BX_ID, BX_NAME ");
sqlMap.append(" from ( ");
sqlMap.append(" select WO_ID, WO_DJID, WO_GCID, WO_YWRQ, WO_WLID, WO_XQSL, ");
sqlMap.append(" WO_JHKGRQ, WO_JHWGRQ, WO_BMID, WO_SCXID, WO_DJLY, ");
sqlMap.append(" WO_ZT, WO_QRR, WO_QRSJ, WO_GBR, WO_GBSJ, ");
sqlMap.append(" WO_GBYY, WO_BOMID, WO_GYLXID, WO_PCYXJ, WO_LYDJID, ");
sqlMap.append(" WO_WGSL, WO_SJKGRQ, WO_SJWGRQ, WO_SNNUM, WO_SJSL, ");
sqlMap.append(" WO_HGSL, WO_BZ,BM_CODE,BM_NAME, GC_CODE, GC_NAME,");
sqlMap.append(" WLXX_CODE, WLXX_NAME,U_WLXX_BZLHSJ, WOSN_CODE, U_WLXX_JZNAME, U_WOSN_HGDJ, ");
sqlMap.append(" case when (isnull(ZT.GPFK_FKSJ,0) > isnull(ZX.GPFK_FKSJ,0) and isnull(ZT.GPFK_FKSJ,0) > isnull(GX.GPFK_FKSJ,0) and isnull(ZT.GPFK_FKSJ,0) > isnull(KC.GPFK_FKSJ,0)) then ZT.GZZX_ID ");
sqlMap.append(" when (isnull(ZX.GPFK_FKSJ,0) > isnull(ZT.GPFK_FKSJ,0) and isnull(ZX.GPFK_FKSJ,0) > isnull(GX.GPFK_FKSJ,0) and isnull(ZX.GPFK_FKSJ,0) > isnull(KC.GPFK_FKSJ,0)) then ZX.GZZX_ID ");
sqlMap.append(" when (isnull(GX.GPFK_FKSJ,0) > isnull(ZT.GPFK_FKSJ,0) and isnull(GX.GPFK_FKSJ,0) > isnull(ZX.GPFK_FKSJ,0) and isnull(GX.GPFK_FKSJ,0) > isnull(KC.GPFK_FKSJ,0) ) then GX.GZZX_ID ");
sqlMap.append(" when (isnull(KC.GPFK_FKSJ,0) > isnull(ZT.GPFK_FKSJ,0) and isnull(KC.GPFK_FKSJ,0) > isnull(ZX.GPFK_FKSJ,0) and isnull(KC.GPFK_FKSJ,0) > isnull(GX.GPFK_FKSJ,0) ) then KC.GZZX_ID ");
sqlMap.append(" end as GZZX_ID, ");
sqlMap.append(" case when (isnull(ZT.GPFK_FKSJ,0) > isnull(ZX.GPFK_FKSJ,0) and isnull(ZT.GPFK_FKSJ,0) > isnull(GX.GPFK_FKSJ,0) and isnull(ZT.GPFK_FKSJ,0) > isnull(KC.GPFK_FKSJ,0)) then ZT.GZZX_NAME ");
sqlMap.append(" when (isnull(ZX.GPFK_FKSJ,0) > isnull(ZT.GPFK_FKSJ,0) and isnull(ZX.GPFK_FKSJ,0) > isnull(GX.GPFK_FKSJ,0) and isnull(ZX.GPFK_FKSJ,0) > isnull(KC.GPFK_FKSJ,0)) then ZX.GZZX_NAME ");
sqlMap.append(" when (isnull(GX.GPFK_FKSJ,0) > isnull(ZT.GPFK_FKSJ,0) and isnull(GX.GPFK_FKSJ,0) > isnull(ZX.GPFK_FKSJ,0) and isnull(GX.GPFK_FKSJ,0) > isnull(KC.GPFK_FKSJ,0) ) then GX.GZZX_NAME ");
sqlMap.append(" when (isnull(KC.GPFK_FKSJ,0) > isnull(ZT.GPFK_FKSJ,0) and isnull(KC.GPFK_FKSJ,0) > isnull(ZX.GPFK_FKSJ,0) and isnull(KC.GPFK_FKSJ,0) > isnull(GX.GPFK_FKSJ,0) ) then KC.GZZX_NAME ");
sqlMap.append(" end as GZZX_NAME, ");
sqlMap.append(" case when (isnull(ZT.GPFK_FKSJ,0) > isnull(ZX.GPFK_FKSJ,0) and isnull(ZT.GPFK_FKSJ,0) > isnull(GX.GPFK_FKSJ,0) and isnull(ZT.GPFK_FKSJ,0) > isnull(KC.GPFK_FKSJ,0)) then ZT.BZGX_NAME ");
sqlMap.append(" when (isnull(ZX.GPFK_FKSJ,0) > isnull(ZT.GPFK_FKSJ,0) and isnull(ZX.GPFK_FKSJ,0) > isnull(GX.GPFK_FKSJ,0) and isnull(ZX.GPFK_FKSJ,0) > isnull(KC.GPFK_FKSJ,0)) then ZX.BZGX_NAME ");
sqlMap.append(" when (isnull(GX.GPFK_FKSJ,0) > isnull(ZT.GPFK_FKSJ,0) and isnull(GX.GPFK_FKSJ,0) > isnull(ZX.GPFK_FKSJ,0) and isnull(GX.GPFK_FKSJ,0) > isnull(KC.GPFK_FKSJ,0) ) then GX.BZGX_NAME ");
sqlMap.append(" when (isnull(KC.GPFK_FKSJ,0) > isnull(ZT.GPFK_FKSJ,0) and isnull(KC.GPFK_FKSJ,0) > isnull(ZX.GPFK_FKSJ,0) and isnull(KC.GPFK_FKSJ,0) > isnull(GX.GPFK_FKSJ,0) ) then KC.BZGX_NAME ");
sqlMap.append(" end as BZGX_NAME, ");
sqlMap.append(" case when (isnull(ZT.GPFK_FKSJ,0) > isnull(ZX.GPFK_FKSJ,0) and isnull(ZT.GPFK_FKSJ,0) > isnull(GX.GPFK_FKSJ,0) and isnull(ZT.GPFK_FKSJ,0) > isnull(KC.GPFK_FKSJ,0)) then ZT.GPFK_FKR ");
sqlMap.append(" when (isnull(ZX.GPFK_FKSJ,0) > isnull(ZT.GPFK_FKSJ,0) and isnull(ZX.GPFK_FKSJ,0) > isnull(GX.GPFK_FKSJ,0) and isnull(ZX.GPFK_FKSJ,0) > isnull(KC.GPFK_FKSJ,0)) then ZX.GPFK_FKR ");
sqlMap.append(" when (isnull(GX.GPFK_FKSJ,0) > isnull(ZT.GPFK_FKSJ,0) and isnull(GX.GPFK_FKSJ,0) > isnull(ZX.GPFK_FKSJ,0) and isnull(GX.GPFK_FKSJ,0) > isnull(KC.GPFK_FKSJ,0) ) then GX.GPFK_FKR ");
sqlMap.append(" when (isnull(KC.GPFK_FKSJ,0) > isnull(ZT.GPFK_FKSJ,0) and isnull(KC.GPFK_FKSJ,0) > isnull(ZX.GPFK_FKSJ,0) and isnull(KC.GPFK_FKSJ,0) > isnull(GX.GPFK_FKSJ,0) ) then KC.GPFK_FKR ");
sqlMap.append(" end as GPFK_FKR , ");
sqlMap.append(" case when (isnull(ZT.GPFK_FKSJ,0) > isnull(ZX.GPFK_FKSJ,0) and isnull(ZT.GPFK_FKSJ,0) > isnull(GX.GPFK_FKSJ,0) and isnull(ZT.GPFK_FKSJ,0) > isnull(KC.GPFK_FKSJ,0)) then ZT.GPFK_FKSJ ");
sqlMap.append(" when (isnull(ZX.GPFK_FKSJ,0) > isnull(ZT.GPFK_FKSJ,0) and isnull(ZX.GPFK_FKSJ,0) > isnull(GX.GPFK_FKSJ,0) and isnull(ZX.GPFK_FKSJ,0) > isnull(KC.GPFK_FKSJ,0)) then ZX.GPFK_FKSJ ");
sqlMap.append(" when (isnull(GX.GPFK_FKSJ,0) > isnull(ZT.GPFK_FKSJ,0) and isnull(GX.GPFK_FKSJ,0) > isnull(ZX.GPFK_FKSJ,0) and isnull(GX.GPFK_FKSJ,0) > isnull(KC.GPFK_FKSJ,0) ) then GX.GPFK_FKSJ ");
sqlMap.append(" when (isnull(KC.GPFK_FKSJ,0) > isnull(ZT.GPFK_FKSJ,0) and isnull(KC.GPFK_FKSJ,0) > isnull(ZX.GPFK_FKSJ,0) and isnull(KC.GPFK_FKSJ,0) > isnull(GX.GPFK_FKSJ,0) ) then KC.GPFK_FKSJ ");
sqlMap.append(" end as GPFK_CZSJ, ");
sqlMap.append(" case when (isnull(ZT.GPFK_FKSJ,0) > isnull(ZX.GPFK_FKSJ,0) and isnull(ZT.GPFK_FKSJ,0) > isnull(GX.GPFK_FKSJ,0) and isnull(ZT.GPFK_FKSJ,0) > isnull(KC.GPFK_FKSJ,0)) then ZT.BX_ID ");
sqlMap.append(" when (isnull(ZX.GPFK_FKSJ,0) > isnull(ZT.GPFK_FKSJ,0) and isnull(ZX.GPFK_FKSJ,0) > isnull(GX.GPFK_FKSJ,0) and isnull(ZX.GPFK_FKSJ,0) > isnull(KC.GPFK_FKSJ,0)) then ZX.BX_ID ");
sqlMap.append(" when (isnull(GX.GPFK_FKSJ,0) > isnull(ZT.GPFK_FKSJ,0) and isnull(GX.GPFK_FKSJ,0) > isnull(ZX.GPFK_FKSJ,0) and isnull(GX.GPFK_FKSJ,0) > isnull(KC.GPFK_FKSJ,0) ) then GX.BX_ID ");
sqlMap.append(" when (isnull(KC.GPFK_FKSJ,0) > isnull(ZT.GPFK_FKSJ,0) and isnull(KC.GPFK_FKSJ,0) > isnull(ZX.GPFK_FKSJ,0) and isnull(KC.GPFK_FKSJ,0) > isnull(GX.GPFK_FKSJ,0) ) then KC.BX_ID ");
sqlMap.append(" end as BX_ID, ");
sqlMap.append(" case when (isnull(ZT.GPFK_FKSJ,0) > isnull(ZX.GPFK_FKSJ,0) and isnull(ZT.GPFK_FKSJ,0) > isnull(GX.GPFK_FKSJ,0) and isnull(ZT.GPFK_FKSJ,0) > isnull(KC.GPFK_FKSJ,0)) then ZT.BX_NAME ");
sqlMap.append(" when (isnull(ZX.GPFK_FKSJ,0) > isnull(ZT.GPFK_FKSJ,0) and isnull(ZX.GPFK_FKSJ,0) > isnull(GX.GPFK_FKSJ,0) and isnull(ZX.GPFK_FKSJ,0) > isnull(KC.GPFK_FKSJ,0)) then ZX.BX_NAME ");
sqlMap.append(" when (isnull(GX.GPFK_FKSJ,0) > isnull(ZT.GPFK_FKSJ,0) and isnull(GX.GPFK_FKSJ,0) > isnull(ZX.GPFK_FKSJ,0) and isnull(GX.GPFK_FKSJ,0) > isnull(KC.GPFK_FKSJ,0) ) then GX.BX_NAME ");
sqlMap.append(" when (isnull(KC.GPFK_FKSJ,0) > isnull(ZT.GPFK_FKSJ,0) and isnull(KC.GPFK_FKSJ,0) > isnull(ZX.GPFK_FKSJ,0) and isnull(KC.GPFK_FKSJ,0) > isnull(GX.GPFK_FKSJ,0) ) then KC.BX_NAME ");
sqlMap.append(" end as BX_NAME ");
sqlMap.append(" WO_ZT, WO_QRR, WO_QRSJ, WO_GBR, WO_GBSJ, WO_GBYY, ");
sqlMap.append(" WO_BOMID, WO_GYLXID, WO_PCYXJ, WO_LYDJID,WO_WGSL, ");
sqlMap.append(" WO_SJKGRQ, WO_SJWGRQ, WO_SNNUM, WO_SJSL, WO_HGSL, ");
sqlMap.append(" WO_BZ,BM_CODE,BM_NAME, GC_CODE, GC_NAME, WLXX_CODE, WLXX_NAME,");
sqlMap.append(" WOSN_CODE,GX.GZZX_ID as GZZX_ID, GX.GZZX_NAME as GZZX_NAME, ");
sqlMap.append(" GX.BZGX_NAME as BZGX_NAME,GX.GPFK_FKR as GPFK_FKR, ");
sqlMap.append(" GX.GPFK_FKSJ as GPFK_CZSJ, GX.BX_ID as BX_ID, GX.BX_NAME as BX_NAME ");
sqlMap.append(" from WOSN ");
sqlMap.append(" left join WO on WO_ID = WOSN_WOID ");
sqlMap.append(" left join GC on GC_ID = WO_GCID ");
......@@ -405,42 +370,8 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
sqlMap.append(" group by GPFK_WOSNID ");
sqlMap.append(" ) ");
sqlMap.append(" ) GX on GX.GPFK_WOSNID = WOSN_CODE ");
sqlMap.append(" left join (select U_ZXGL_NRID as GPFK_WOSNID,GZZX_ID,GZZX_NAME,U_ZXGL_CJSJ as GPFK_FKSJ,U_ZXGL_CJR as GPFK_FKR,'装箱' as BZGX_NAME , ");
sqlMap.append(" BX_ID,BX_NAME from U_ZXGL B ");
sqlMap.append(" left join U_ZXSN on U_ZXSN_CODE = B.U_ZXGL_ZXSNID ");
sqlMap.append(" left join GZZX on GZZX_ID = U_ZXSN_GZZXID ");
sqlMap.append(" left join BX on BX_ID = U_ZXSN_BX ");
sqlMap.append(" where U_ZXGL_CJSJ = (select max(U_ZXGL_CJSJ) as fksj ");
sqlMap.append(" from U_ZXGL ");
sqlMap.append(" where 1 = 1 ");
sqlMap.append(" and U_ZXGL_NRID = B.U_ZXGL_NRID ");
sqlMap.append(" group by U_ZXGL_NRID ");
sqlMap.append(" ) ");
sqlMap.append(" ) ZX on ZX.GPFK_WOSNID = WOSN_CODE ");
sqlMap.append(" left join (select U_ZXGL_NRID as GPFK_WOSNID,'ZT001'as GZZX_ID, '装托工作中心' as GZZX_NAME, U_ZTGL_CJSJ as GPFK_FKSJ,U_ZTGL_CJR as GPFK_FKR,'装拖' as BZGX_NAME,");
sqlMap.append(" '' as BX_ID,'' as BX_NAME from U_ZTGL C ");
sqlMap.append(" left join U_ZXGL D on U_ZXGL_ZXSNID = U_ZTGL_NRID ");
sqlMap.append(" where U_ZTGL_CJSJ = (select max(U_ZTGL_CJSJ) as fksj ");
sqlMap.append(" from U_ZTGL ");
sqlMap.append(" left join U_ZXGL on U_ZXGL_ZXSNID = C.U_ZTGL_NRID ");
sqlMap.append(" where 1 = 1 ");
sqlMap.append(" and U_ZXGL_NRID = D.U_ZXGL_NRID ");
sqlMap.append(" group by U_ZXGL_NRID ");
sqlMap.append(" ) ");
sqlMap.append(" )ZT on ZT.GPFK_WOSNID = WOSN_CODE ");
sqlMap.append(" left join (select KCSW_SNID as GPFK_WOSNID, KCSW_CJSJ as GPFK_FKSJ,KCSW_CJR as GPFK_FKR,'CK001'as GZZX_ID, '仓库工作中心' as GZZX_NAME,");
sqlMap.append(" '' as BX_ID,'' as BX_NAME , case SWLX_XTSWLXID when 'QTRK' then '入库' when 'QTCK' then '出库' end as BZGX_NAME from KCSW E ");
sqlMap.append(" left join KC on KC_ID = KCSW_MID ");
sqlMap.append(" left join SWLX on SWLX_ID = KC_SWLXID ");
sqlMap.append(" where KCSW_CJSJ = (select max(KCSW_CJSJ) as fksj ");
sqlMap.append(" from KCSW ");
sqlMap.append(" where 1 = 1 ");
sqlMap.append(" and isnull(KCSW_SNID,' ') <> ' ' ");
sqlMap.append(" and KCSW_SNID = E.KCSW_SNID ");
sqlMap.append(" group by KCSW_SNID ");
sqlMap.append(" ) ");
sqlMap.append(" ) KC on KC.GPFK_WOSNID = WOSN_CODE ");
sqlMap.append("where 1=1 ");
if (StringUtils.isNotEmpty(condition.getWosnid())){
sqlMap.append(" and WOSN_CODE like :WOSN_CODE");
sqlMap.setParamValueLike("WOSN_CODE", condition.getWosnid());
......@@ -454,13 +385,9 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
sqlMap.setParamValue("WO_GCID", condition.getGcid());
}
if (StringUtils.isNotEmpty(condition.getWlid())) {
sqlMap.append(" and (WLXX_CODE like :WLID or WLXX_NAME like :WLID or U_WLXX_JZNAME like :WLID )");
sqlMap.append(" and (WLXX_CODE like :WLID or WLXX_NAME like :WLID or WLXX_GG like :WLID )");
sqlMap.setParamValueLike("WLID", condition.getWlid());
}
if (StringUtils.isNotEmpty(condition.getJzname())) {
sqlMap.append(" and " + SqlUtil.getWhereLikeSql("U_WLXX_JZNAME"));
sqlMap.setParamValueLike("U_WLXX_JZNAME", condition.getJzname());
}
sqlMap.append(" ) A ");
sqlMap.append("where GPFK_CZSJ is not null ");
......@@ -482,16 +409,16 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
sqlMap.setParamValueLike("pFkr", condition.getFkr());
}
if (condition.getBegin() != null) {
sqlMap.append(" and GPFK_CZSJ >= :KSSJ");
sqlMap.setParamValue("KSSJ", condition.getBegin());
sqlMap.append(" and GPFK_CZSJ >= :pKSSJ");
sqlMap.setParamValue("pKSSJ", condition.getBegin());
}
if (condition.getEnd() != null) {
sqlMap.append(" and GPFK_CZSJ <=:JSSJ");
sqlMap.setParamValue("JSSJ",condition.getEnd());
sqlMap.append(" and GPFK_CZSJ <=:pJSSJ");
sqlMap.setParamValue("pJSSJ",condition.getEnd());
}
sqlMap.append(" order by GPFK_CZSJ desc ");
sqlMap.setTranslate(false);
sqlMap.query(HzWoVO.class);
sqlMap.query(WosngzVO.class);
return sqlMap.getRecordSet();
}
......@@ -508,64 +435,9 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
sqlMap.append(" left join BZGX on BZGX_ID = GPFK_FKGX ");
sqlMap.append(" where 1 = 1 ");
sqlMap.append(" and GPFK_WOSNID = :pCode ");
if(lhids != null && StringUtils.isNotEmpty(lhids[0])){
sqlMap.append(" and not" + SqlUtil.getWhereEqualSql("BZGX_ID", lhids));
}
sqlMap.append(" union all ");
sqlMap.append(" select U_ZXGL_ZXSNID as GPFK_ID, U_ZXGL_CJSJ as GPFK_FKSJ, null as GPFK_FKJSSJ, ");
sqlMap.append(" 'Y' as GPFK_HGBZ, 1 as GPFK_FKSL, 1 as GPFK_HGSL, ");
sqlMap.append(" 0 as GPFK_BHGSL, U_ZXGL_CJR as GPFK_FKR, ");
sqlMap.append(" '装箱' as BZGX_NAME,' ' as BZGX_CODE, 'ZX' as BZGX_GXLX ");
sqlMap.append(" from U_ZXGL ");
sqlMap.append(" where 1 = 1 ");
sqlMap.append(" and U_ZXGL_NRID = :pCode ");
sqlMap.append(" union all ");
sqlMap.append(" select U_ZTGL_ZTSNID as GPFK_ID, U_ZTGL_CJSJ as GPFK_FKSJ, null as GPFK_FKJSSJ, ");
sqlMap.append(" 'Y' as GPFK_HGBZ, 1 as GPFK_FKSL, 1 as GPFK_HGSL, ");
sqlMap.append(" 0 as GPFK_BHGSL, U_ZTGL_CJR as GPFK_FKR, ");
sqlMap.append(" '装拖' as BZGX_NAME,' ' as BZGX_CODE, 'ZT' as BZGX_GXLX ");
sqlMap.append(" from U_ZTGL ");
sqlMap.append(" left join U_ZXGL on U_ZXGL_ZXSNID = U_ZTGL_NRID ");
sqlMap.append(" where 1 = 1 ");
sqlMap.append(" and U_ZXGL_NRID = :pCode ");
sqlMap.append(" union all ");
sqlMap.append(" select GPFK_ID, GPFK_FKSJ, GPFK_FKJSSJ, GPFK_HGBZ, GPFK_FKSL, ");
sqlMap.append(" GPFK_HGSL, GPFK_BHGSL, GPFK_FKR, '老化' as BZGX_NAME,' ' as BZGX_CODE, ");
sqlMap.append(" 'LH' as BZGX_GXLX");
sqlMap.append(" from GPFK ");
sqlMap.append(" left join BZGX on BZGX_ID = GPFK_FKGX ");
sqlMap.append(" where 1 = 1 ");
sqlMap.append(" and GPFK_WOSNID = :pCode ");
if(lhids != null && StringUtils.isNotEmpty(lhids[0])){
sqlMap.append(" and " + SqlUtil.getWhereEqualSql("BZGX_ID", lhids));
}else{
sqlMap.append(" and 1 <> 1 ");
}
sqlMap.append(" union all ");
sqlMap.append(" select KC_DJID as GPFK_ID, KCSW_CJSJ as GPFK_FKSJ, KC_YWRQ as GPFK_FKJSSJ, ");
sqlMap.append(" 'Y' as GPFK_HGBZ, KCSW_RKSL as GPFK_FKSL, KCSW_RKSL as GPFK_HGSL, ");
sqlMap.append(" 0 as GPFK_BHGSL, KCSW_CJR as GPFK_FKR, ");
sqlMap.append(" '入库' as BZGX_NAME,' ' as BZGX_CODE, 'RK' as BZGX_GXLX ");
sqlMap.append(" from KCSW ");
sqlMap.append(" left join KC on KC_ID = KCSW_MID ");
sqlMap.append(" left join SWLX on SWLX_ID = KC_SWLXID ");
sqlMap.append(" where 1 = 1 ");
sqlMap.append(" and KCSW_SNID = :pCode ");
sqlMap.append(" and SWLX_XTSWLXID = 'QTRK' ");
sqlMap.append(" union all ");
sqlMap.append(" select KC_DJID as GPFK_ID, KCSW_CJSJ as GPFK_FKSJ, KC_YWRQ as GPFK_FKJSSJ, ");
sqlMap.append(" 'Y' as GPFK_HGBZ, KCSW_CKSL as GPFK_FKSL, KCSW_CKSL as GPFK_HGSL, ");
sqlMap.append(" 0 as GPFK_BHGSL, KCSW_CJR as GPFK_FKR, ");
sqlMap.append(" '出库' as BZGX_NAME,' ' as BZGX_CODE, 'CK' as BZGX_GXLX ");
sqlMap.append(" from KCSW ");
sqlMap.append(" left join KC on KC_ID = KCSW_MID ");
sqlMap.append(" left join SWLX on SWLX_ID = KC_SWLXID ");
sqlMap.append(" where 1 = 1 ");
sqlMap.append(" and KCSW_SNID = :pCode ");
sqlMap.append(" and SWLX_XTSWLXID = 'QTCK' ");
sqlMap.append(" )GC");
sqlMap.append("order by GPFK_FKSJ ");
sqlMap.setParamValue("pCode",wosnid);
sqlMap.append(" )GC ");
sqlMap.append("order by GPFK_FKSJ ");
return sqlMap.query(GpfkVO.class);
}
......@@ -687,9 +559,8 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
sqlMap.append(" GPFK_HGSL, GPFK_BHGSL, GPFK_FKR, GPFK_FKGX, GPFK_BZ, ");
sqlMap.append(" GPFK_WHRID, GPFK_WHR, GPFK_WHSJ, GPFK_CJRID, GPFK_CJR, ");
sqlMap.append(" GPFK_CJSJ, GPFK_SYSVERSION, GPFK_FKRID, GPFK_FKBX, GPFK_FKJSSJ, ");
sqlMap.append(" BZGX_CODE, BZGX_NAME, ");
sqlMap.append(" WLXX_CODE, WLXX_NAME, WLXX_GG, U_WLXX_BZLHSJ, ");
sqlMap.append(" DATEDIFF(mi,GPFK_FKSJ,GPFK_FKJSSJ) as gxhs, U_WLXX_JZNAME ");
sqlMap.append(" BZGX_CODE, BZGX_NAME,WLXX_CODE, WLXX_NAME, WLXX_GG, ");
sqlMap.append(" DATEDIFF(mi,GPFK_FKSJ,GPFK_FKJSSJ) as gxhs ");
sqlMap.append("from GPFK ");
sqlMap.append(" left join WOSN on WOSN_CODE = GPFK_WOSNID ");
sqlMap.append(" left join WO on WO_ID = WOSN_WOID ");
......@@ -709,9 +580,8 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
sqlMap.append(" GPFK_HGSL, GPFK_BHGSL, GPFK_FKR, GPFK_FKGX, GPFK_BZ, ");
sqlMap.append(" GPFK_WHRID, GPFK_WHR, GPFK_WHSJ, GPFK_CJRID, GPFK_CJR, ");
sqlMap.append(" GPFK_CJSJ, GPFK_SYSVERSION, GPFK_FKRID, GPFK_FKBX, GPFK_FKJSSJ, ");
sqlMap.append(" BZGX_CODE, BZGX_NAME, ");
sqlMap.append(" WLXX_CODE, WLXX_NAME, WLXX_GG, U_WLXX_BZLHSJ, ");
sqlMap.append(" DATEDIFF(mi,GPFK_FKSJ,GPFK_FKJSSJ) as gxhs, U_WLXX_JZNAME, GPFK_FKPH ");
sqlMap.append(" BZGX_CODE, BZGX_NAME, WLXX_CODE, WLXX_NAME, WLXX_GG, ");
sqlMap.append(" DATEDIFF(mi,GPFK_FKSJ,GPFK_FKJSSJ) as gxhs, GPFK_FKPH ");
sqlMap.append("from GPFK ");
sqlMap.append(" left join ZYJHMX on ZYJHMX_GPCODE = GPFK_WOSNID ");
sqlMap.append(" left join WLXX on WLXX_ID = ZYJHMX_WLID ");
......@@ -974,9 +844,8 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
sqlMap.append(" GPFK_HGSL, GPFK_BHGSL, GPFK_FKR, GPFK_FKGX, GPFK_BZ, ");
sqlMap.append(" GPFK_WHRID, GPFK_WHR, GPFK_WHSJ, GPFK_CJRID, GPFK_CJR, ");
sqlMap.append(" GPFK_CJSJ, GPFK_SYSVERSION, GPFK_FKRID, GPFK_FKBX, GPFK_FKJSSJ, ");
sqlMap.append(" BX_CODE, BX_NAME, BZGX_CODE, BZGX_NAME, ");
sqlMap.append(" WLXX_CODE, WLXX_NAME, WLXX_GG, U_WLXX_BZLHSJ, ");
sqlMap.append(" DATEDIFF(mi,GPFK_FKSJ,GPFK_FKJSSJ) as gxhs, U_WLXX_JZNAME, ");
sqlMap.append(" BX_CODE, BX_NAME, BZGX_CODE, BZGX_NAME, WLXX_CODE, WLXX_NAME, WLXX_GG, ");
sqlMap.append(" DATEDIFF(mi,GPFK_FKSJ,GPFK_FKJSSJ) as gxhs, ");
sqlMap.append(" GPFK_GFSL, GPFK_LFSL, GPFK_FXSL, GPFK_FGSL, GPFK_FKPH ");
sqlMap.append("from GPFK ");
sqlMap.append(" left join BX on BX_ID = GPFK_FKBX ");
......@@ -1138,9 +1007,6 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
public int queryZxNum(String wosnid){
try {
SqlMap sqlMap = new SqlMap();
sqlMap.append("select count(1) from U_ZXGL ");
sqlMap.append("where 1 = 1");
sqlMap.append(" and U_ZXGL_NRID = :pWOSNID ");
sqlMap.setParamValue("pWOSNID", wosnid);
return sqlMap.queryInt();
} catch (Exception e) {
......@@ -1179,11 +1045,11 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
sqlMap.append(" GPFK_HGSL, GPFK_BHGSL, GPFK_FKR, GPFK_FKGX, GPFK_BZ,");
sqlMap.append(" GPFK_WHRID, GPFK_WHR, GPFK_WHSJ, GPFK_CJRID, GPFK_CJR, ");
sqlMap.append(" GPFK_CJSJ, GPFK_SYSVERSION, GPFK_FKRID, GPFK_FKBX, GPFK_FKJSSJ,");
sqlMap.append(" BX_CODE, BX_NAME, BZGX_CODE, BZGX_NAME, ");
sqlMap.append(" WLXX_CODE, WLXX_NAME, WLXX_GG, U_WLXX_BZLHSJ, WO_DJID, ");
sqlMap.append(" DATEDIFF(mi,GPFK_FKSJ,GPFK_FKJSSJ) as gxhs, U_WLXX_JZNAME, ");
sqlMap.append(" GPFK_GFSL, GPFK_LFSL, GPFK_FXSL, GPFK_FGSL, GPFK_HGDJ, WOSN_KHCODE, U_WOSN_KHCODEBY1, ");
sqlMap.append(" RIGHT('0'+CAST(isnull(datepart(wk,WOSN_CJSJ),'0') as varchar(10)),2) as SNWEEK, substring(convert( nvarchar,datepart(year ,getdate())) ,3, 4) as SNYEAR ");
sqlMap.append(" BX_CODE, BX_NAME, BZGX_CODE, BZGX_NAME, WLXX_CODE, WLXX_NAME, WLXX_GG, WO_DJID, ");
sqlMap.append(" DATEDIFF(mi,GPFK_FKSJ,GPFK_FKJSSJ) as gxhs, ");
sqlMap.append(" GPFK_GFSL, GPFK_LFSL, GPFK_FXSL, GPFK_FGSL, GPFK_HGDJ, WOSN_KHCODE, ");
sqlMap.append(" RIGHT('0'+CAST(isnull(datepart(wk,WOSN_CJSJ),'0') as varchar(10)),2) as SNWEEK, ");
sqlMap.append(" substring(convert( nvarchar,datepart(year ,getdate())) ,3, 4) as SNYEAR ");
sqlMap.append("from GPFK ");
sqlMap.append(" left join BX on BX_ID = GPFK_FKBX ");
sqlMap.append(" left join WOSN on WOSN_CODE = GPFK_WOSNID ");
......@@ -1202,7 +1068,7 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
@Override
public HzWoVO queryKwellWoBySnid(String snid){
public WosngzVO queryKwellWoBySnid(String snid){
SqlMap sqlMap = new SqlMap();
sqlMap.append("select WO_ID, WO_DJID, WO_GCID, WO_YWRQ, WO_WLID, WO_XQSL, ");
sqlMap.append(" WO_JHKGRQ, WO_JHWGRQ, WO_BMID, WO_SCXID, WO_DJLY, ");
......@@ -1227,7 +1093,7 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
sqlMap.append("where 1 = 1 ");
sqlMap.append(" and WOSN_CODE = :pSNID ");
sqlMap.setParamValue("pSNID",snid);
return sqlMap.queryEntity(HzWoVO.class);
return sqlMap.queryEntity(WosngzVO.class);
}
......
......@@ -28,11 +28,11 @@ public class UWoDaoImpl extends BaseDaoImpl implements UWoDao {
sqlMap.append(" D.WO_JHKGRQ, D.WO_JHWGRQ, D.WO_BMID, D.WO_SCXID, D.WO_DJLY, ");
sqlMap.append(" D.WO_ZT, D.WO_QRR, D.WO_QRSJ, D.WO_GBR, D.WO_GBSJ, ");
sqlMap.append(" D.WO_GBYY, D.WO_BOMID, D.WO_GYLXID, D.WO_PCYXJ, D.WO_LYDJID, ");
sqlMap.append(" D.WO_WGSL as WO_WGSL,D.WO_RKSL as WO_RKSL, D.WO_SJKGRQ, D.WO_SJWGRQ, D.WO_SNNUM as WO_SNNUM, D.WO_SJSL as WO_SJSL, ");
sqlMap.append(" D.WO_HGSL as WO_HGSL, D.WO_BZ, D.WO_WHRID, D.WO_WHR, D.WO_WHSJ,D.WO_XDR,");
sqlMap.append(" D.WO_WGSL as WO_WGSL,D.WO_RKSL as WO_RKSL, D.WO_SJKGRQ, D.WO_SJWGRQ, D.WO_SNNUM as WO_SNNUM,");
sqlMap.append(" D.WO_SJSL as WO_SJSL, D.WO_HGSL as WO_HGSL, D.WO_BZ, D.WO_WHRID, D.WO_WHR, D.WO_WHSJ,D.WO_XDR,");
sqlMap.append(" D.WO_XDSJ,D.WO_CJRID, D.WO_CJR, D.WO_CJSJ, D.WO_SYSVERSION,");
sqlMap.append(" BM_CODE, BM_NAME, GC_CODE, GC_NAME, SCX_CODE, SCX_NAME,");
sqlMap.append(" WL.WLXX_CODE, WL.WLXX_NAME, WL.WLXX_GG, JLDW_NAME,S.WO_DJID as LYDH, WL.U_WLXX_JZNAME,");
sqlMap.append(" WL.WLXX_CODE, WL.WLXX_NAME, WL.WLXX_GG, JLDW_NAME,S.WO_DJID as LYDH,");
sqlMap.append(" BOM.WLXX_CODE as BOMCODE, GYLX.WLXX_CODE as GYLXCODE, D.WO_XMID, ");
sqlMap.append(" GCXM_CODE, GCXM_NAME");
sqlMap.append("from WO D ");
......@@ -75,14 +75,10 @@ public class UWoDaoImpl extends BaseDaoImpl implements UWoDao {
sqlMap.setParamValue("WO_ZT", condition.getZt());
}
if (StringUtils.isNotEmpty(condition.getWlid())) {
sqlMap.append(" and (WL.WLXX_CODE like :WLID or WL.WLXX_NAME like :WLID or WL.U_WLXX_JZNAME like :WLID or WL.WLXX_GG like :WLID )");
sqlMap.append(" and (WL.WLXX_CODE like :WLID or WL.WLXX_NAME like :WLID or WL.WLXX_GG like :WLID )");
sqlMap.setParamValueLike("WLID", condition.getWlid());
}
if (StringUtils.isNotEmpty(condition.getJzname())) {
sqlMap.append(" and " + SqlUtil.getWhereLikeSql("WL.U_WLXX_JZNAME"));
sqlMap.setParamValueLike("WL.U_WLXX_JZNAME", condition.getJzname());
}
if (StringUtils.isNotEmpty(condition.getDjly())) {
sqlMap.append(" and D.WO_DJLY = :WO_DJLY");
sqlMap.setParamValue("WO_DJLY", condition.getDjly());
......@@ -114,11 +110,11 @@ public class UWoDaoImpl extends BaseDaoImpl implements UWoDao {
sqlMap.append(" D.WO_JHKGRQ, D.WO_JHWGRQ, D.WO_BMID, D.WO_SCXID, D.WO_DJLY, ");
sqlMap.append(" D.WO_ZT, D.WO_QRR, D.WO_QRSJ, D.WO_GBR, D.WO_GBSJ, ");
sqlMap.append(" D.WO_GBYY, D.WO_BOMID, D.WO_GYLXID, D.WO_PCYXJ, D.WO_LYDJID, ");
sqlMap.append(" D.WO_WGSL as WO_WGSL,D.WO_RKSL as WO_RKSL, D.WO_SJKGRQ, D.WO_SJWGRQ, D.WO_SNNUM as WO_SNNUM, D.WO_SJSL as WO_SJSL, ");
sqlMap.append(" D.WO_HGSL as WO_HGSL, D.WO_BZ, D.WO_WHRID, D.WO_WHR, D.WO_WHSJ,D.WO_XDR,");
sqlMap.append(" D.WO_WGSL as WO_WGSL,D.WO_RKSL as WO_RKSL, D.WO_SJKGRQ, D.WO_SJWGRQ, D.WO_SNNUM as WO_SNNUM, ");
sqlMap.append(" D.WO_SJSL as WO_SJSL,D.WO_HGSL as WO_HGSL, D.WO_BZ, D.WO_WHRID, D.WO_WHR, D.WO_WHSJ,D.WO_XDR,");
sqlMap.append(" D.WO_XDSJ,D.WO_CJRID, D.WO_CJR, D.WO_CJSJ, D.WO_SYSVERSION,");
sqlMap.append(" BM_CODE, BM_NAME, GC_CODE, GC_NAME, SCX_CODE, SCX_NAME,");
sqlMap.append(" WL.WLXX_CODE, WL.WLXX_NAME, WL.WLXX_GG, JLDW_NAME,S.WO_DJID as LYDH, WL.U_WLXX_JZNAME,");
sqlMap.append(" WL.WLXX_CODE, WL.WLXX_NAME, WL.WLXX_GG, JLDW_NAME,S.WO_DJID as LYDH, ");
sqlMap.append(" BOM.WLXX_CODE as BOMCODE, GYLX.WLXX_CODE as GYLXCODE");
sqlMap.append("from WO D ");
sqlMap.append(" left join GC on GC_ID = D.WO_GCID");
......@@ -179,11 +175,6 @@ public class UWoDaoImpl extends BaseDaoImpl implements UWoDao {
sqlMap.setParamValueLike("WLID", condition.getWlid());
}
if (StringUtils.isNotEmpty(condition.getJzname())) {
sqlMap.append(" and " + SqlUtil.getWhereLikeSql("WL.U_WLXX_JZNAME"));
sqlMap.setParamValueLike("WL.U_WLXX_JZNAME", condition.getJzname());
}
if (condition.getZtList() != null && condition.getZtList().length > 0) {
sqlMap.append(" and " + SqlUtil.getWhereEqualSql("D.WO_ZT", condition.getZtList()));
}
......@@ -202,11 +193,11 @@ public class UWoDaoImpl extends BaseDaoImpl implements UWoDao {
sqlMap.append(" D.WO_JHKGRQ, D.WO_JHWGRQ, D.WO_BMID, D.WO_SCXID, D.WO_DJLY, ");
sqlMap.append(" D.WO_ZT, D.WO_QRR, D.WO_QRSJ, D.WO_GBR, D.WO_GBSJ, ");
sqlMap.append(" D.WO_GBYY, D.WO_BOMID, D.WO_GYLXID, D.WO_PCYXJ, D.WO_LYDJID, ");
sqlMap.append(" D.WO_WGSL as WO_WGSL,D.WO_RKSL as WO_RKSL, D.WO_SJKGRQ, D.WO_SJWGRQ, D.WO_SNNUM as WO_SNNUM, D.WO_SJSL as WO_SJSL, ");
sqlMap.append(" D.WO_HGSL as WO_HGSL, D.WO_BZ, D.WO_WHRID, D.WO_WHR, D.WO_WHSJ,D.WO_XDR,");
sqlMap.append(" D.WO_WGSL as WO_WGSL,D.WO_RKSL as WO_RKSL, D.WO_SJKGRQ, D.WO_SJWGRQ, D.WO_SNNUM as WO_SNNUM, ");
sqlMap.append(" D.WO_SJSL as WO_SJSL,D.WO_HGSL as WO_HGSL, D.WO_BZ, D.WO_WHRID, D.WO_WHR, D.WO_WHSJ,D.WO_XDR,");
sqlMap.append(" D.WO_XDSJ,D.WO_CJRID, D.WO_CJR, D.WO_CJSJ, D.WO_SYSVERSION,");
sqlMap.append(" BM_CODE, BM_NAME, GC_CODE, GC_NAME, SCX_CODE, SCX_NAME,");
sqlMap.append(" WL.WLXX_CODE, WL.WLXX_NAME, WL.WLXX_GG, JLDW_NAME,S.WO_DJID as LYDH, WL.U_WLXX_JZNAME,");
sqlMap.append(" WL.WLXX_CODE, WL.WLXX_NAME, WL.WLXX_GG, JLDW_NAME,S.WO_DJID as LYDH ");
sqlMap.append(" BOM.WLXX_CODE as BOMCODE, GYLX.WLXX_CODE as GYLXCODE");
sqlMap.append("from WO D ");
sqlMap.append(" left join GC on GC_ID = D.WO_GCID");
......@@ -258,14 +249,10 @@ public class UWoDaoImpl extends BaseDaoImpl implements UWoDao {
sqlMap.setParamValue("WO_ZT", condition.getZt());
}
if (StringUtils.isNotEmpty(condition.getWlid())) {
sqlMap.append(" and (WL.WLXX_CODE like :WLID or WL.WLXX_NAME like :WLID or WL.U_WLXX_JZNAME like :WLID )");
sqlMap.append(" and (WL.WLXX_CODE like :WLID or WL.WLXX_NAME like :WLID or WL.WLXX_GG like :WLID )");
sqlMap.setParamValueLike("WLID", condition.getWlid());
}
if (StringUtils.isNotEmpty(condition.getJzname())) {
sqlMap.append(" and " + SqlUtil.getWhereLikeSql("WL.U_WLXX_JZNAME"));
sqlMap.setParamValueLike("WL.U_WLXX_JZNAME", condition.getJzname());
}
if (StringUtils.isNotEmpty(condition.getDjly())) {
sqlMap.append(" and D.WO_DJLY = :WO_DJLY");
sqlMap.setParamValue("WO_DJLY", condition.getDjly());
......@@ -283,7 +270,6 @@ public class UWoDaoImpl extends BaseDaoImpl implements UWoDao {
sqlMap.append(" and " + SqlUtil.getWhereEqualSql("D.WO_ZT", condition.getZtList()));
}
sqlMap.append("order by WO_YWRQ desc, WO_DJID desc ");
//sqlMap.setTranslate(false);
sqlMap.query(UWoVO.class);
return sqlMap.getRecordSet();
}
......
package com.gavel.kwell.dao.impl;
import com.gavel.wo.persistent.Wosn;
import org.springframework.stereotype.Repository;
import com.gavel.common.base.dao.impl.BaseDaoImpl;
import com.gavel.common.utils.DateUtils;
import com.gavel.common.utils.StringUtils;
import com.gavel.jcsj.utils.WlsxUtils;
import com.gavel.kwell.dao.UWosnDao;
import com.gavel.kwell.persistent.HzWosn;
import com.gavel.kwell.vo.UWosnCondition;
import com.gavel.kwell.vo.UWosnVO;
import com.gavel.persistence.sql.RecordSet;
......@@ -25,9 +24,7 @@ public class UWosnDaoImpl extends BaseDaoImpl implements UWosnDao {
sqlMap.append("select WOSN_ID, WOSN_CODE, WOSN_WOID, WOSN_PNUM, WOSN_BZ,");
sqlMap.append(" WOSN_WHRID, WOSN_WHR, WOSN_WHSJ, WOSN_CJRID, WOSN_CJR,");
sqlMap.append(" WOSN_CJSJ, WOSN_SYSVERSION, WO_WLID, WO_BMID, WLXX_CODE,");
sqlMap.append(" WLXX_NAME, WLXX_GG, WLXX_JLDW, WOSN_KHCODE,WO_DJID, ");
sqlMap.append(" U_WOSN_KHCODEBY1, U_WOSN_KHCODEBY1FLID, U_WOSN_KHCODEBY1PREFIX, U_WOSN_JYHGBZ, U_WOSN_HGDJ ");
sqlMap.append(WlsxUtils.COMMON_SQL);
sqlMap.append(" WLXX_NAME, WLXX_GG, WLXX_JLDW, WOSN_KHCODE,WO_DJID ");
sqlMap.append("from WOSN");
sqlMap.append(" left join WO on WO_ID = WOSN_WOID");
sqlMap.append(" left join WLXX on WLXX_ID = WO_WLID");
......@@ -57,8 +54,7 @@ public class UWosnDaoImpl extends BaseDaoImpl implements UWosnDao {
sqlMap.append("select WOSN_ID, WOSN_CODE, WOSN_WOID, WOSN_PNUM, WOSN_BZ, ");
sqlMap.append(" WOSN_WHRID, WOSN_WHR, WOSN_WHSJ, WOSN_CJRID, WOSN_CJR, ");
sqlMap.append(" WOSN_CJSJ,WO_WLID,WO_GCID,WO_DJID,WO_YWRQ, WO_BMID, WLXX_CODE,");
sqlMap.append(" WLXX_NAME, WLXX_GG, WLXX_JLDW,U_WLXX_JZNAME, WOSN_KHCODE, ");
sqlMap.append(" U_WOSN_KHCODEBY1, U_WOSN_KHCODEBY1FLID, U_WOSN_KHCODEBY1PREFIX, U_WOSN_JYHGBZ ");
sqlMap.append(" WLXX_NAME, WLXX_GG, WLXX_JLDW, WOSN_KHCODE ");
sqlMap.append("from WOSN ");
sqlMap.append(" left join WO on WO_ID = WOSN_WOID ");
sqlMap.append(" left join WLXX on WLXX_ID = WO_WLID ");
......@@ -97,7 +93,7 @@ public class UWosnDaoImpl extends BaseDaoImpl implements UWosnDao {
}
if (StringUtils.isNotEmpty(condition.getWlid())) {
sqlMap.append(" and (WLXX_CODE like :WLID or WLXX_NAME like :WLID or U_WLXX_JZNAME like :WLID )");
sqlMap.append(" and (WLXX_CODE like :WLID or WLXX_NAME like :WLID or WLXX_GG like :WLID )");
sqlMap.setParamValueLike("WLID", condition.getWlid());
}
......@@ -106,25 +102,20 @@ public class UWosnDaoImpl extends BaseDaoImpl implements UWosnDao {
sqlMap.setParamValueLike("WOSN_CODE", condition.getWoid());
}
if (StringUtils.isNotEmpty(condition.getJzname())) {
sqlMap.append(" and " + SqlUtil.getWhereLikeSql("U_WLXX_JZNAME"));
sqlMap.setParamValueLike("U_WLXX_JZNAME", condition.getJzname());
}
return sqlMap.queryRecordset(UWosnVO.class);
}
@Override
public HzWosn queryByCode(String wosnid) {
public Wosn queryByCode(String wosnid) {
SqlMap sqlMap = new SqlMap();
sqlMap.append("select WOSN_ID, WOSN_CODE, WOSN_WOID, WOSN_PNUM, WOSN_BZ,");
sqlMap.append(" WOSN_WHRID, WOSN_WHR, WOSN_WHSJ, WOSN_CJRID, WOSN_CJR,");
sqlMap.append(" WOSN_CJSJ, WOSN_SYSVERSION, WOSN_KHCODE,WO_DJID, ");
sqlMap.append(" U_WOSN_KHCODEBY1, U_WOSN_KHCODEBY1FLID, U_WOSN_KHCODEBY1PREFIX, U_WOSN_JYHGBZ, U_WOSN_HGDJ ");
sqlMap.append(" WOSN_CJSJ, WOSN_SYSVERSION, WOSN_KHCODE,WO_DJID ");
sqlMap.append("from WOSN ");
sqlMap.append("where 1 = 1 ");
sqlMap.append(" and WOSN_CODE = :WOSN_CODE");
sqlMap.setParamValue("WOSN_CODE", wosnid);
return sqlMap.queryEntity(HzWosn.class);
return sqlMap.queryEntity(Wosn.class);
}
@Override
......
......@@ -92,11 +92,6 @@ public class Gpfk extends BaseEntity {
@FieldMeta(fieldName = "GPFK_HGDJ", caption = "合格等级")
private String hgdj;
@FieldMeta(fieldName = "U_GPFK_JYDID", caption = "检验单ID")
private String jydid;
@FieldMeta(fieldName = "U_GPFK_CLBZ", caption = "处理标记")
private String clbz;
@FieldMeta(fieldName = "GPFK_WLID", caption = "物料编码")
private String wlid;
......@@ -381,21 +376,7 @@ public class Gpfk extends BaseEntity {
this.hgdj = hgdj;
}
public String getJydid() {
return jydid;
}
public void setJydid(String jydid) {
this.jydid = jydid;
}
public String getClbz() {
return clbz;
}
public void setClbz(String clbz) {
this.clbz = clbz;
}
}
......
package com.gavel.kwell.persistent;
import com.gavel.persistence.annotation.FieldMeta;
import com.gavel.persistence.annotation.TableMeta;
import com.gavel.wo.persistent.Wosn;
/*
* @Author youjian.ding
* @Date $
**/
@TableMeta(id = "WOSN", name = "WOSN")
public class HzWosn extends Wosn {
/**
*
*/
private static final long serialVersionUID = -5483907460724861059L;
@FieldMeta(fieldName = "U_WOSN_JYHGBZ", caption = "合格标志" )
private String jyhgbz;
@FieldMeta(fieldName = "U_WOSN_HGDJ", caption = "合格等级" )
private String hgdj;
@FieldMeta(fieldName = "U_WOSN_KHCODEBY1", caption = "客户条码备用1" )
private String khcodeby1;
@FieldMeta(fieldName = "U_WOSN_KHCODEBY1FLID", caption = "客户条码构成分类1" )
private String khcodeby1flid;
@FieldMeta(fieldName = "U_WOSN_KHCODEBY1PREFIX", caption = "客户条码构成前缀1" )
private String khcodeby1prefix;
public String getHgdj() {
return hgdj;
}
public void setHgdj(String hgdj) {
this.hgdj = hgdj;
}
public String getJyhgbz() {
return jyhgbz;
}
public void setJyhgbz(String jyhgbz) {
this.jyhgbz = jyhgbz;
}
public String getKhcodeby1() {
return khcodeby1;
}
public void setKhcodeby1(String khcodeby1) {
this.khcodeby1 = khcodeby1;
}
public String getKhcodeby1flid() {
return khcodeby1flid;
}
public void setKhcodeby1flid(String khcodeby1flid) {
this.khcodeby1flid = khcodeby1flid;
}
public String getKhcodeby1prefix() {
return khcodeby1prefix;
}
public void setKhcodeby1prefix(String khcodeby1prefix) {
this.khcodeby1prefix = khcodeby1prefix;
}
}
......@@ -5,7 +5,6 @@ import java.util.List;
import com.gavel.common.attachment.persistent.Attachment;
import com.gavel.common.base.service.BaseEditService;
import com.gavel.file.vo.FilesVO;
import com.gavel.gygl.vo.BzgxCondition;
import com.gavel.gygl.vo.BzgxVO;
import com.gavel.gygl.vo.GylxVO;
......@@ -17,7 +16,7 @@ import com.gavel.kwell.vo.GpbhgfkCondition;
import com.gavel.kwell.vo.GpbhgmxVO;
import com.gavel.kwell.vo.GpfkCondition;
import com.gavel.kwell.vo.GpfkVO;
import com.gavel.kwell.vo.HzWoVO;
import com.gavel.kwell.vo.WosngzVO;
import com.gavel.persistence.sql.RecordSet;
import com.gavel.wo.vo.WobomVO;
......@@ -35,7 +34,7 @@ public interface GpfkService extends BaseEditService {
void doInsZyjhGpfk(Gpfk gpfk);
/** 工票反馈通用--begin */
public HzWoVO queryWoBySnid(String snid);
public WosngzVO queryWoBySnid(String snid);
public Gpfk getGpfkByVo(GpfkVO gpfkInfo);
......@@ -54,7 +53,7 @@ public interface GpfkService extends BaseEditService {
/** 工票老化反馈--begin */
public GpResVO doGplhfk(GpbhgfkCondition gpbhgfkCondition);
public RecordSet<HzWoVO> queryWosngz(GpWoCondition gpWoCondition);
public RecordSet<WosngzVO> queryWosngz(GpWoCondition gpWoCondition);
public List<GpfkVO> queryWosngzByWosnid(String wosnid);
......@@ -89,7 +88,7 @@ public interface GpfkService extends BaseEditService {
/** 科威尔mes工票反馈重写--begin */
public HzWoVO queryKwellWoBySnid(String snid);
public WosngzVO queryKwellWoBySnid(String snid);
public SmCodeModel querySml(String snid);
......
package com.gavel.kwell.service;
import com.gavel.common.base.service.BaseEditService;
import com.gavel.kwell.persistent.HzWosn;
import com.gavel.kwell.vo.UWosnCondition;
import com.gavel.kwell.vo.UWosnVO;
import com.gavel.persistence.sql.RecordSet;
import com.gavel.wo.persistent.Wosn;
public interface UWosnService extends BaseEditService {
......@@ -13,7 +13,7 @@ public interface UWosnService extends BaseEditService {
public RecordSet<UWosnVO> wosnZpxx(UWosnCondition condition);
public HzWosn queryWosnByCode(String wosnid);
public Wosn queryWosnByCode(String wosnid);
public boolean queryIfHasPrint(String id);
......
package com.gavel.kwell.service.impl;
import java.util.ArrayList;
import java.util.Date;
import java.util.HashSet;
import java.util.LinkedHashSet;
import java.util.List;
import java.util.Set;
import org.apache.shiro.SecurityUtils;
import org.apache.shiro.authc.UsernamePasswordToken;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;
import com.gavel.common.Constants;
import com.gavel.common.attachment.persistent.Attachment;
import com.gavel.common.attachment.service.AttachmentService;
import com.gavel.common.attachment.vo.AttachmentVO;
import com.gavel.common.base.entity.BaseEntity;
import com.gavel.common.base.service.impl.BaseEditServiceImpl;
import com.gavel.common.business.service.CommonService;
import com.gavel.common.sql.GavelSql;
import com.gavel.common.utils.BooleanEnum;
import com.gavel.common.utils.CodeStrategy;
import com.gavel.common.utils.DateUtils;
import com.gavel.common.utils.MapList;
import com.gavel.common.utils.NumberUtils;
import com.gavel.common.utils.StringUtils;
import com.gavel.common.utils.ThreadContext;
import com.gavel.common.utils.UserInfoUtil;
import com.gavel.file.service.FilesService;
import com.gavel.file.vo.FilesVO;
import com.gavel.common.utils.*;
import com.gavel.framework.utils.JwtUtil;
import com.gavel.gygl.persistent.Bzgx;
import com.gavel.gygl.service.BzgxService;
......@@ -43,24 +19,11 @@ import com.gavel.kwell.dao.GpfkDao;
import com.gavel.kwell.persistent.Gpbhgmx;
import com.gavel.kwell.persistent.Gpfk;
import com.gavel.kwell.persistent.Gpwxmx;
import com.gavel.kwell.persistent.HzWosn;
import com.gavel.kwell.service.GpfkService;
import com.gavel.kwell.utils.GpfkFklxEnum;
import com.gavel.kwell.utils.HzGylxEnum;
import com.gavel.kwell.utils.KwellParamEnum;
import com.gavel.kwell.utils.SmCodeEnum;
import com.gavel.kwell.utils.SmCodeModel;
import com.gavel.kwell.utils.YymkFKEnum;
import com.gavel.kwell.vo.GpResVO;
import com.gavel.kwell.vo.GpWoCondition;
import com.gavel.kwell.vo.GpbhgfkCondition;
import com.gavel.kwell.vo.GpbhgmxVO;
import com.gavel.kwell.vo.GpfkCondition;
import com.gavel.kwell.vo.GpfkVO;
import com.gavel.kwell.vo.HzWoVO;
import com.gavel.kwell.utils.*;
import com.gavel.kwell.vo.*;
import com.gavel.kzzx.dao.UserDao;
import com.gavel.kzzx.persistent.User;
import com.gavel.kzzx.persistent.Yymk;
import com.gavel.kzzx.service.UserRoleService;
import com.gavel.kzzx.service.YymkService;
import com.gavel.kzzx.vo.UserRoleCondition;
......@@ -69,7 +32,16 @@ import com.gavel.kzzx.vo.YymkCondition;
import com.gavel.kzzx.vo.YymkVO;
import com.gavel.persistence.entity.EntityDataFactory;
import com.gavel.persistence.sql.RecordSet;
import com.gavel.wo.persistent.Wosn;
import com.gavel.wo.vo.WobomVO;
import org.apache.shiro.SecurityUtils;
import org.apache.shiro.authc.UsernamePasswordToken;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;
import java.util.*;
@Service("gpfkService")
......@@ -86,9 +58,6 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
@Autowired
private BzgxService bzgxService;
@Autowired
private FilesService filesService;
@Autowired
private UserRoleService userRoleService;
......@@ -134,7 +103,7 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
if(UserInfoUtil.isSuperuser()){
condition.setFkrid(null);
}
String gxids = commonService.getStringOptionValue(KwellParamEnum.HZGD_GXLX_LH.getId());
String gxids = "";
condition.setGxids(gxids);
return gpfkDao.queryLh(condition);
}
......@@ -238,12 +207,12 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
/**
* 连续扫描校验
*/
String lhids = commonService.getStringOptionValue(KwellParamEnum.HZGD_GXLX_LH.getId());
String lhids = "";
String[] lhgxs = lhids.split(",");
GpfkVO lastGpfk = gpfkDao.getLastGpfk(gpfk.getWosnid(),lhgxs);
if(lastGpfk != null){
if(!dpValid){
String allowContinueIds = commonService.getStringOptionValue(KwellParamEnum.HZGD_GXLX_NGCONTINUE.getId());
String allowContinueIds = "";
if(StringUtils.equalsIgnoreCase(gpfk.getFkgx(),lastGpfk.getFkgx()) &&
(!allowContinueIds.contains(gpfk.getFkgx()) || BooleanEnum.equalsYes(lastGpfk.getHgbz()))){
setReturnMessage("请不要连续扫描!");
......@@ -258,7 +227,6 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
}
}
// GylxVO gylxVO = gpfkDao.queryLastGylxByWlidGx(gpfk.getWlid(),gpfk.getFkgx());
Bzgx existLastGx = null;
List<BzgxVO> bzgxVOList = gpfkDao.queryGylxBzgxByWlid(gpfk.getWlid());
if(bzgxVOList != null && bzgxVOList.size() > 0){
......@@ -294,13 +262,7 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
setReturnMessage("工序不允许为空!");
return false;
}
/**
* 暂时允许反馈为0数据,用于修机耗时等
*/
// if (NumberUtils.isZero(gpfk.getHgsl()) && NumberUtils.isZero(gpfk.getBhgsl())) {
// setReturnMessage("合格数量和不合格数量不允许同时为空!");
// return false;
// }
if(StringUtils.isEmpty(gpfk.getHgbz())){
setReturnMessage("合格标志不允许为空!");
return false;
......@@ -315,20 +277,6 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
return false;
}
/**
* 上道合格数量与本道工序完工数量的校验
*/
// if(!NumberUtils.equals(bzgx.getXh(),0)){
// Bzgx existLastGx = gpfkDao.getLastGx(bzgx);
// if(existLastGx != null){
// List<Gpfk> gpfkList = gpfkDao.queryExistGpfk(gpfk.getWosnid(),existLastGx.getId());
// if(gpfkList == null || gpfkList.size() == 0){
// setReturnMessage("上道工序【%s】尚未完成,不允许反馈!", existLastGx.getName());
// return false;
// }
// }
// }
if(StringUtils.isEmpty(gpfk.getFklx())){
gpfk.setFklx(GpfkFklxEnum.ZYJH.getId());
}
......@@ -336,7 +284,7 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
}
@Override
public HzWoVO queryWoBySnid(String snid){
public WosngzVO queryWoBySnid(String snid){
return gpfkDao.queryWoBySnid(snid);
}
......@@ -375,7 +323,7 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
@Override
public Date getGpfkYwrqByFksj(Date nowDate,String bxid){
if(StringUtils.isNotEmpty(bxid)){
boolean isYb = StringUtils.equalsIgnoreCase(commonService.getStringOptionValue(KwellParamEnum.HZGD_GXLX_YBBX.getId()),bxid);
boolean isYb = false;
if(isYb){
/**
* 小时小于当天12点,则业务日期归结为前一天
......@@ -409,62 +357,6 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
}
// @Override
// public GpResVO doGpfk(GpbhgfkCondition gpbhgfkCondition){
// GpfkVO gpfkInfo = gpbhgfkCondition.getGpfkVO();
// if(gpfkInfo == null || StringUtils.isEmpty(gpfkInfo.getWosnid())){
// setReturnMessage("条码信息不允许为空,请检查!");
// return null;
// }
// if(StringUtils.isEmpty(gpfkInfo.getFkgx())){
// setReturnMessage("反馈工序不允许为空,请检查!");
// return null;
// }
// HzWoVO HzWoVO = queryWoBySnid(gpfkInfo.getWosnid());
// if(HzWoVO == null){
// setReturnMessage("当前产品任务单信息异常,请检查!");
// return null;
// }
//
// Gpfk gpfk = getGpfkByVo(gpfkInfo);
// gpfk.setFklx(GpfkFklxEnum.WO.getId());
//
// List<GpbhgmxVO> gpbhgmxVOList = gpbhgfkCondition.getGpbhgmxList();
//
// List<Gpbhgmx> gpbhgmxList = new ArrayList<Gpbhgmx>();
//
// if(gpbhgmxVOList == null || gpbhgmxVOList.size() == 0){
// /**
// * 没有不合格信息,则设置为合格
// */
//// gpfk.setHgbz(BooleanEnum.YES.getId());
// }else{
// gpbhgmxList = gpbhgmxService.getGpbhgFromVo(gpfk, gpbhgmxVOList);
// }
//
// GpResVO gpResVO = new GpResVO();
// gpResVO.setDcsm(BooleanEnum.NO.getId());
// if(BooleanEnum.equalsYes(gpfk.getHgbz())){
// String allowContinueIds = commonService.getStringOptionValue(HzgdParamEnum.HZGD_GXLX_NGCONTINUE.getId());
// if(allowContinueIds.contains(gpfk.getFkgx())){
// int gxTimes = gpfkDao.queryGxTimes(gpfk.getFkgx(),gpfk.getWosnid());
// gpResVO.setDcsm(NumberUtils.Greater(gxTimes,0)?BooleanEnum.YES.getId():BooleanEnum.NO.getId());
// }
// }
//
// doInsGpfk(gpfk);
// /**
// * insGpbhg
// */
// if(gpbhgmxList != null && gpbhgmxList.size() > 0){
// gpbhgmxService.doInsGpbhg(gpbhgmxList);
// }
// gpResVO.setHzWoVO(HzWoVO);
// gpResVO.setGpfk(gpfk);
// gpResVO.setGpbhgmxList(gpbhgmxList);
// return gpResVO;
// }
@Override
public GpResVO doGpfk(GpbhgfkCondition gpbhgfkCondition){
GpfkVO gpfkInfo = gpbhgfkCondition.getGpfkVO();
......@@ -490,32 +382,21 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
setReturnMessage("反馈工序不允许为空,请检查!");
return null;
}
HzWoVO hzWoVO = queryWoBySnid(gpfkInfo.getWosnid());
if(hzWoVO == null){
WosngzVO wosngzVO = queryWoBySnid(gpfkInfo.getWosnid());
if(wosngzVO == null){
setReturnMessage("当前产品任务单信息异常,请检查!");
return null;
}
gpfkInfo.setWlid(hzWoVO.getWlid());
gpfkInfo.setWlid(wosngzVO.getWlid());
Gpfk gpfk = getGpfkByVo(gpfkInfo);
gpfk.setFklx(GpfkFklxEnum.WO.getId());
List<GpbhgmxVO> gpbhgmxVOList = gpbhgfkCondition.getGpbhgmxList();
List<Gpbhgmx> gpbhgmxList = new ArrayList<Gpbhgmx>();
if(gpbhgmxVOList == null || gpbhgmxVOList.size() == 0){
/**
* 没有不合格信息,则设置为合格
*/
// gpfk.setHgbz(BooleanEnum.YES.getId());
}else{
//gpbhgmxList = gpbhgmxService.getGpbhgFromVo(gpfk, gpbhgmxVOList);
}
GpResVO gpResVO = new GpResVO();
gpResVO.setDcsm(BooleanEnum.NO.getId());
if(BooleanEnum.equalsYes(gpfk.getHgbz())){
String allowContinueIds = commonService.getStringOptionValue(KwellParamEnum.HZGD_GXLX_NGCONTINUE.getId());
String allowContinueIds ="";
if(allowContinueIds.contains(gpfk.getFkgx())){
int gxTimes = gpfkDao.queryGxTimes(gpfk.getFkgx(),gpfk.getWosnid());
gpResVO.setDcsm(NumberUtils.Greater(gxTimes,0)?BooleanEnum.YES.getId():BooleanEnum.NO.getId());
......@@ -523,13 +404,8 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
}
doInsGpfk(gpfk);
/**
* insGpbhg
*/
/*if(gpbhgmxList != null && gpbhgmxList.size() > 0){
gpbhgmxService.doInsGpbhg(gpbhgmxList);
}*/
gpResVO.setHzWoVO(hzWoVO);
gpResVO.setWosngzVO(wosngzVO);
gpResVO.setGpfk(gpfk);
gpResVO.setGpbhgmxList(gpbhgmxList);
return gpResVO;
......@@ -547,57 +423,41 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
setReturnMessage("反馈工序不允许为空,请检查!");
return null;
}
HzWoVO hzWoVO = queryWoBySnid(gpfkInfo.getWosnid());
if(hzWoVO == null){
WosngzVO wosngzVO = queryWoBySnid(gpfkInfo.getWosnid());
if(wosngzVO == null){
setReturnMessage("当前产品任务单信息异常,请检查!");
return null;
}
gpfkInfo.setWlid(hzWoVO.getWlid());
gpfkInfo.setWlid(wosngzVO.getWlid());
Gpfk gpfk = getGpfkByVo(gpfkInfo);
gpfk.setFklx(GpfkFklxEnum.WO.getId());
List<Gpbhgmx> gpbhgmxList = new ArrayList<Gpbhgmx>();
/*if(gpbhgmxVOList == null || gpbhgmxVOList.size() == 0){
*//**
* 没有不合格信息,则设置为合格
*//*
// gpfk.setHgbz(BooleanEnum.YES.getId());
}else{
gpbhgmxList = gpbhgmxService.getGpbhgFromVo(gpfk, gpbhgmxVOList);
}
*/
GpResVO gpResVO = new GpResVO();
gpResVO.setDcsm(BooleanEnum.NO.getId());
if(BooleanEnum.equalsYes(gpfk.getHgbz())){
String allowContinueIds = commonService.getStringOptionValue(KwellParamEnum.HZGD_GXLX_NGCONTINUE.getId());
String allowContinueIds = "";
if(allowContinueIds.contains(gpfk.getFkgx())){
int gxTimes = gpfkDao.queryGxTimes(gpfk.getFkgx(),gpfk.getWosnid());
gpResVO.setDcsm(NumberUtils.Greater(gxTimes,0)?BooleanEnum.YES.getId():BooleanEnum.NO.getId());
}
}
if(BooleanEnum.equalsYes(gpfkInfo.getDpgpfk())){
HzWosn hzWosn = null;
Wosn wosn = null;
if(StringUtils.isNotEmpty(gpfk.getHgdj())){
hzWosn = gpfkDao.queryById(HzWosn.class,hzWoVO.getWosnRealId());
hzWosn.setHgdj(gpfk.getHgdj());
wosn = gpfkDao.queryById(Wosn.class,wosngzVO.getWosnRealId());
}
doInsDpGpfk(gpfk);
if(hzWosn != null){
gpfkDao.updateByUser(hzWosn);
if(wosn != null){
gpfkDao.updateByUser(wosn);
}
}else{
doInsGpfk(gpfk);
}
/**
* insGpbhg
*/
/*if(gpbhgmxList != null && gpbhgmxList.size() > 0){
gpbhgmxService.doInsGpbhg(gpbhgmxList);
}*/
gpResVO.setHzWoVO(hzWoVO);
gpResVO.setWosngzVO(wosngzVO);
gpResVO.setGpfk(gpfk);
gpResVO.setGpbhgmxList(gpbhgmxList);
return gpResVO;
......@@ -614,8 +474,8 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
setReturnMessage("反馈工序不允许为空,请检查!");
return null;
}
HzWoVO HzWoVO = queryWoBySnid(gpfkInfo.getWosnid());
if(HzWoVO == null){
WosngzVO wosngzVO = queryWoBySnid(gpfkInfo.getWosnid());
if(wosngzVO == null){
setReturnMessage("当前产品任务单信息异常,请检查!");
return null;
}
......@@ -639,28 +499,14 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
existGpfk = getLhgpfk(existGpfk, gpfkInfo);
List<Gpbhgmx> gpbhgmxList = new ArrayList<Gpbhgmx>();
/*if(gpbhgmxVOList == null || gpbhgmxVOList.size() == 0){
*//**
* 没有不合格信息,则设置为合格
*//*
existGpfk.setHgbz(BooleanEnum.YES.getId());
}else{
gpbhgmxList = gpbhgmxService.getGpbhgFromVo(existGpfk, gpbhgmxVOList);
}*/
/**
* 大屏老化走更新操作的时候(老化结束),需要检验连续扫描
*/
doUpdGpfk(existGpfk);
// doUpdDpGpfk(existGpfk);
/*
if(gpbhgmxList != null && gpbhgmxList.size() > 0){
gpbhgmxService.doInsGpbhg(gpbhgmxList);
}*/
int gxhs = DateUtils.betweenMinute(existGpfk.getFksj(),existGpfk.getFkjssj());
GpResVO gpResVO = new GpResVO();
gpResVO.setHzWoVO(HzWoVO);
gpResVO.setWosngzVO(wosngzVO);
gpResVO.setGpfk(existGpfk);
gpResVO.setGxhs((double) gxhs);
gpResVO.setGpbhgmxList(gpbhgmxList);
......@@ -668,13 +514,13 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
}
@Override
public RecordSet<HzWoVO> queryWosngz(GpWoCondition gpWoCondition){
public RecordSet<WosngzVO> queryWosngz(GpWoCondition gpWoCondition){
return gpfkDao.queryWosngz(gpWoCondition);
}
@Override
public List<GpfkVO> queryWosngzByWosnid(String wosnid){
String gxid = commonService.getStringOptionValue(KwellParamEnum.HZGD_GXLX_LH.getId());
String gxid ="";
String[] ids = gxid.split(",");
List<GpfkVO> gpfkVOList = gpfkDao.queryWosngzByWosnid(wosnid,ids);
return gpfkVOList;
......@@ -691,7 +537,7 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
condition.setUserid(UserInfoUtil.getId());
String userids = commonService.getStringOptionValue(GyglParamEnum.GYGL_USER_USEDGX.getId());
String[] ugxs = userids.split(",");
String lhids = commonService.getStringOptionValue(KwellParamEnum.HZGD_GXLX_LH.getId());
String lhids ="";
String[] lhgxs = lhids.split(",");
return gpfkDao.queryLhBzgx(condition, ugxs, lhgxs);
}
......@@ -745,12 +591,6 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
if (gpfk == null) {
throw new RuntimeException("数据发生变化,请重新操作!");
}
// if(!UserInfoUtil.isSuperuser() && !StringUtils.equalsIgnoreCase(gpfk.getFkrid(),UserInfoUtil.getUserId())){
// throw new RuntimeException("当前工单由其他人反馈,不允许取消!");
// }
// if(NumberUtils.Greater(gpfkDao.queryZxNum(gpfk.getWosnid()),0)){
// throw new RuntimeException("当前条码已装箱,不允许取消!");
// }
gpfk.setId(gpfkid);
delete(gpfk);
}
......@@ -812,7 +652,7 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
@Override
public Boolean ifNeedPrint(String gxid){
String needPrintGxs = commonService.getStringOptionValue(KwellParamEnum.HZGD_GXLX_NEEDPRINT.getId());
String needPrintGxs = "";
if(StringUtils.isNotEmpty(needPrintGxs)){
return needPrintGxs.contains(gxid);
}
......@@ -830,7 +670,7 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
}
@Override
public HzWoVO queryKwellWoBySnid(String snid) {
public WosngzVO queryKwellWoBySnid(String snid) {
return gpfkDao.queryKwellWoBySnid(snid);
}
......@@ -877,14 +717,14 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
gpfkCondition.setGxid(bzlx);
GpfkVO gpfkVo = gpfkDao.queryKwellGpfkByWosnAndGxid(gpfkCondition);
if(gpfkVo==null) {
HzWoVO hzWoVO =queryKwellWoBySnid(wosn);
WosngzVO wosngzVO =queryKwellWoBySnid(wosn);
Gpfk gpfk = new Gpfk();
gpfk.setWosnid(wosn);
gpfk.setFkgx(bzlx);
gpfk.setFkrid(UserInfoUtil.getId());
gpfk.setFkr(UserInfoUtil.getUserName());
gpfk.setFksj(DateUtils.getDate());
gpfk.setWlid(hzWoVO.getWlid());
gpfk.setWlid(wosngzVO.getWlid());
insert(gpfk);
gpfkVo = gpfkDao.queryKwellGpfkByWosnAndGxid(gpfkCondition);
}
......
......@@ -3,7 +3,6 @@ package com.gavel.kwell.service.impl;
import com.gavel.common.base.service.impl.BaseEditServiceImpl;
import com.gavel.common.utils.NumberUtils;
import com.gavel.kwell.dao.UWosnDao;
import com.gavel.kwell.persistent.HzWosn;
import com.gavel.kwell.service.UWosnService;
import com.gavel.kwell.vo.UWosnCondition;
import com.gavel.kwell.vo.UWosnVO;
......@@ -38,7 +37,7 @@ public class UWosnServiceImpl extends BaseEditServiceImpl implements UWosnServic
}
@Override
public HzWosn queryWosnByCode(String wosnid){
public Wosn queryWosnByCode(String wosnid){
return uwosnDao.queryByCode(wosnid);
}
......
......@@ -8,66 +8,10 @@ import java.util.List;
@GavelParams("901000000")
public enum KwellParamEnum {
HZGD_JYJL_JYBM("HZGDU001", "用户可操作的检验部门", "U", "用户可操作的检验部门", "E", "select BM_ID as ID, BM_CODE as CODE, BM_NAME as NAME from BM where isnull(BM_TYBZ,'N')='N' order by BM_CODE", "", ""),
HZGD_GXLX_LH("HZGDB001", "设置标准工序为老化工序", "B", "设置标准工序为老化工序", "E",
"select BZGX_ID as ID, BZGX_CODE as CODE, BZGX_NAME || '--' || GZZX_NAME as NAME from BZGX left join GZZX on GZZX_ID = BZGX_GZZXID where isnull(BZGX_TYBZ,'N')='N' and BZGX_GXLX = 'JG' order by BZGX_CODE", "", ""),
HZGD_GXLX_CJPD("HZGDB002", "设置标准工序为允许抽检判定工序", "B", "设置标准工序为允许抽检判定工序", "E",
"select BZGX_ID as ID, BZGX_CODE as CODE, BZGX_NAME || '--' || GZZX_NAME as NAME from BZGX left join GZZX on GZZX_ID = BZGX_GZZXID where isnull(BZGX_TYBZ,'N')='N' order by BZGX_CODE", "", ""),
HZGD_GXLX_CJGX("HZGDB003", "设置标准工序为抽检时样本检验工序", "B", "设置标准工序为抽检时样本检验工序", "L",
"select BZGX_ID as ID, BZGX_CODE as CODE, BZGX_NAME || '--' || GZZX_NAME as NAME from BZGX left join GZZX on GZZX_ID = BZGX_GZZXID where isnull(BZGX_TYBZ,'N')='N' and BZGX_GXLX = 'JY' order by BZGX_CODE", "", ""),
HZGD_WOBOM_VALIDFFGX("HZGDB004", "设置装配时是否校验发放工序", "B", "设置装配时是否校验发放工序", "B", "Y"),
HZGD_GXLX_ZXPD("HZGDB005", "设置标准工序为装箱判定工序", "B", "设置标准工序为装箱判定工序", "E",
"select BZGX_ID as ID, BZGX_CODE as CODE, BZGX_NAME || '--' || GZZX_NAME as NAME from BZGX left join GZZX on GZZX_ID = BZGX_GZZXID where isnull(BZGX_TYBZ,'N')='N' order by BZGX_CODE", "", ""),
HZGD_GXLX_DPHGPD("HZGDB006", "设置标准工序为大屏产线合格品判定工序", "B", "设置标准工序为大屏产线合格品判定工序", "E",
"select BZGX_ID as ID, BZGX_CODE as CODE, BZGX_NAME || '--' || GZZX_NAME as NAME from BZGX left join GZZX on GZZX_ID = BZGX_GZZXID where isnull(BZGX_TYBZ,'N')='N' order by BZGX_CODE", "", ""),
HZGD_ZX_VALIDHGBZ("HZGDB007", "设置装箱时判定工序是否必须合格", "B", "设置装箱时判定工序是否必须合格", "B", "N"),
HZGD_GXLX_BGHGPD("HZGDB008", "设置标准工序为背光产线合格品判定工序", "B", "设置标准工序为背光产线合格品判定工序", "E",
"select BZGX_ID as ID, BZGX_CODE as CODE, BZGX_NAME || '--' || GZZX_NAME as NAME from BZGX left join GZZX on GZZX_ID = BZGX_GZZXID where isnull(BZGX_TYBZ,'N')='N' order by BZGX_CODE", "", ""),
HZGD_GXLX_NGCONTINUE("HZGDB009", "设置标准工序为NG后允许连续反馈", "B", "设置标准工序为NG后允许连续反馈", "E",
"select BZGX_ID as ID, BZGX_CODE as CODE, BZGX_NAME || '--' || GZZX_NAME as NAME from BZGX left join GZZX on GZZX_ID = BZGX_GZZXID where isnull(BZGX_TYBZ,'N')='N' order by BZGX_CODE", "", ""),
HZGD_GXLX_YBBX("HZGDB010", "设置反馈班型为夜班班型(存在跨天反馈)", "B", "设置反馈班型为夜班班型(存在跨天反馈)", "E",
"select BX_ID as ID, BX_CODE as CODE, BX_NAME as NAME from BX where 1 = 1 order by BX_CODE", "", ""),
HZGD_GZSD_TYPE("HZGDB011", "冲压车间工作时段划分方式", "B", "冲压车间工作时段划分方式", "L", "A:通升捷排班时段;B:通灿排班时段;","A", "通升捷排班时段"),
HZGD_JYJL_DPJYBM("HZGDB012", "设置部门为大屏检验部门", "B", "设置部门为大屏检验部门", "E", "select BM_ID as ID, BM_CODE as CODE, BM_NAME as NAME from BM where isnull(BM_TYBZ,'N')='N' order by BM_CODE", "", ""),
HZGD_DPFK_QCWL("HZGDB013", "设置QC件物料编码,以逗号分隔", "B", "设置QC件物料编码,以逗号分隔", "S"),
HZGD_GXLX_NEEDPRINT("HZGDB014", "设置标准加工工序为反馈合格后自动打印", "B", "设置标准加工工序为反馈合格后自动打印", "E",
"select BZGX_ID as ID, BZGX_CODE as CODE, BZGX_NAME || '--' || GZZX_NAME as NAME from BZGX left join GZZX on GZZX_ID = BZGX_GZZXID where isnull(BZGX_TYBZ,'N')='N' and BZGX_GXLX = 'JG' order by BZGX_CODE", "", ""),
HZGD_JYJL_DPZZBM("HZGDB015", "设置部门为大屏制造部门", "B", "设置部门为大屏制造部门", "E", "select BM_ID as ID, BM_CODE as CODE, BM_NAME as NAME from BM where isnull(BM_TYBZ,'N')='N' order by BM_CODE", "", ""),
HZGD_SYNC_WLXX("HZGDB020", "同步物料的sql语句", "B", "同步物料的sql语句", "S"),
HZGD_SYNC_WO("HZGDB021", "同步生产订单的sql语句", "B", "同步生产订单的sql语句", "S"),
HZGD_SYNC_WOBOM("HZGDB022", "同步生产物料清单的sql语句", "B", "同步生产物料清单的sql语句", "S"),
HZGD_SYNC_WLFL("HZGDB023", "同步物料分类的sql语句", "B", "同步物料分类的sql语句", "S"),
HZGD_SYNC_JLDW("HZGDB024", "同步计量单位的sql语句", "B", "同步计量单位的sql语句", "S"),
HZGD_SYNC_GYS("HZGDB025", "同步供应商的sql语句", "B", "同步供应商的sql语句", "S"),
HZGD_SYNC_CGSH("HZGDB026", "同步采购收货的sql语句", "B", "同步采购收货单的sql语句", "S"),
HZGD_SYNC_CGSHMX("HZGDB027", "同步采购收货单明细的sql语句", "B", "同步采购收货单明细的sql语句", "S"),
HZGD_SYNC_BOM("HZGDB028", "同步BOM的sql语句", "B", "同步产品结构sql语句", "S"),
HZGD_SYNC_SYNCDATA("HZGDB029", "同步ACCESS数据URL配置", "B", "同步ACCESS数据URL配置", "S","http://localhost:9527/sync/bm7data"),
HZGD_FILE_PATH("HZGDB030", "图片访问URL路径配置", "B", "图片访问URL路径配置", "S","C:\\AOI\\NEW"),
HZGD_SYNC_KH("HZGDB031", "同步客户的sql语句", "B", "同步客户的sql语句", "S"),
HZGD_SYNC_GCXM("HZGDB032", "同步工程项目的sql语句", "B", "同步工程项目的sql语句", "S"),
HZGD_WOZPJH_FLID("HZGDB033", "生产装配计划选择的物料分类", "B", "生产装配计划选择的物料分类", "E", "select WLFL_ID as ID, WLFL_CODE as CODE, WLFL_NAME as NAME from WLFL where 1=1 order by WLFL_CODE", "", "");
HZGD_BM("HZGDU001", "用户可操作的检验部门", "U", "用户可操作的检验部门", "E", "select BM_ID as ID, BM_CODE as CODE, BM_NAME as NAME from BM where isnull(BM_TYBZ,'N')='N' order by BM_CODE", "", ""),
HZGD_GX("HZGDB001", "设置可操作标准工序", "B", "设置可操作标准工序", "E",
"select BZGX_ID as ID, BZGX_CODE as CODE, BZGX_NAME || '--' || GZZX_NAME as NAME from BZGX left join GZZX on GZZX_ID = BZGX_GZZXID where isnull(BZGX_TYBZ,'N')='N' order by BZGX_CODE", "", "");
private String id; // 参数ID
private String name; //参数名称
......
......@@ -11,7 +11,7 @@ public class GpResVO implements Serializable{
private static final long serialVersionUID = 1L;
private HzWoVO HzWoVO;
private WosngzVO wosngzVO;
private Gpfk gpfk;
......@@ -24,12 +24,12 @@ public class GpResVO implements Serializable{
private List<Gpbhgmx> gpbhgmxList;
public HzWoVO getHzWoVO() {
return HzWoVO;
public WosngzVO getWosngzVO() {
return wosngzVO;
}
public void setHzWoVO(HzWoVO HzWoVO) {
this.HzWoVO = HzWoVO;
public void setWosngzVO(WosngzVO wosngzVO) {
this.wosngzVO = wosngzVO;
}
public Gpfk getGpfk() {
......
......@@ -9,7 +9,7 @@ public class GpWxInfoVO {
private static final long serialVersionUID = 1L;
private HzWoVO HzWoVO;
private WosngzVO wosngzVO;
private GpfkVO gpfkVO;
......@@ -21,12 +21,12 @@ public class GpWxInfoVO {
private List<GphyVO> gphyVOList;
public HzWoVO getHzWoVO() {
return HzWoVO;
public WosngzVO getWosngzVO() {
return wosngzVO;
}
public void setHzWoVO(HzWoVO HzWoVO) {
this.HzWoVO = HzWoVO;
public void setWosngzVO(WosngzVO wosngzVO) {
this.wosngzVO = wosngzVO;
}
public List<GpbhgmxVO> getGpbhgmxVOList() {
......
......@@ -40,8 +40,6 @@ public class GpbhgcxVO extends Gpbhgmx {
@FieldMeta(fieldName = "BHGXX_FLID", caption = "不合格分类")
private String flid;
@FieldMeta(fieldName = "U_WLXX_JZNAME", caption = "机种名称" )
private String jzname;
@FieldMeta(fieldName = "WLXX_CODE", caption = "物料编码")
private String wlxxCode;
@FieldMeta(fieldName = "WLXX_NAME", caption = "物料名称")
......@@ -159,14 +157,6 @@ public class GpbhgcxVO extends Gpbhgmx {
this.hgbz = hgbz;
}
public String getJzname() {
return jzname;
}
public void setJzname(String jzname) {
this.jzname = jzname;
}
public String getWlxxCode() {
return wlxxCode;
}
......
......@@ -33,8 +33,7 @@ public class GpfkVO extends Gpfk {
private String wlxxName;
@FieldMeta(fieldName = "WLXX_GG", caption = "规格")
private String wlxxGg;
@FieldMeta(fieldName = "U_WLXX_BZLHSJ", caption = "标准老化时间" )
private Double bzlhsj;
@FieldMeta(fieldName = "WO_DJID", caption = "任务单号")
private String woDjid;
......@@ -50,17 +49,12 @@ public class GpfkVO extends Gpfk {
@FieldMeta(caption = "工序耗时")
private Double gxhs;
@FieldMeta(fieldName = "U_WLXX_JZNAME", caption = "机种名称" )
private String jzname;
@FieldMeta(fieldName = "dpgpfk", caption = "大屏反馈标志" )
private String dpgpfk;
@FieldMeta(fieldName = "hgdjname", caption = "合格等级名称" )
private String hgdjname;
@FieldMeta(fieldName = "U_WOSN_KHCODEBY1", caption = "客户序列号2")
private String khcodeby1;
@FieldMeta(fieldName = "WOSN_KHCODE", caption = "客户序列号")
private String khcode;
......@@ -87,13 +81,6 @@ public class GpfkVO extends Gpfk {
this.snweek = snweek;
}
public String getKhcodeby1() {
return khcodeby1;
}
public void setKhcodeby1(String khcodeby1) {
this.khcodeby1 = khcodeby1;
}
public String getKhcode() {
return khcode;
......@@ -151,14 +138,6 @@ public class GpfkVO extends Gpfk {
this.wlxxGg = wlxxGg;
}
public Double getBzlhsj() {
return bzlhsj;
}
public void setBzlhsj(Double bzlhsj) {
this.bzlhsj = bzlhsj;
}
public String getWoDjid() {
return woDjid;
}
......@@ -199,14 +178,6 @@ public class GpfkVO extends Gpfk {
this.gxhs = gxhs;
}
public String getJzname() {
return jzname;
}
public void setJzname(String jzname) {
this.jzname = jzname;
}
public String getBzgxGxlx() {
return bzgxGxlx;
}
......@@ -256,7 +227,4 @@ public class GpfkVO extends Gpfk {
}
/*---------AutoBegin-----------*/
/*---------AutoEnd-------------*/
}
......@@ -9,8 +9,6 @@ public class GphycxVO extends Gphy {
private static final long serialVersionUID = 1L;
@FieldMeta(fieldName = "U_WLXX_JZNAME", caption = "机种名称" )
private String jzname;
@FieldMeta(fieldName = "WLXX_CODE", caption = "物料编码")
private String wlxxCode;
@FieldMeta(fieldName = "WLXX_NAME", caption = "物料名称")
......@@ -29,14 +27,6 @@ public class GphycxVO extends Gphy {
@FieldMeta(fieldName = "GZZX_NAME", caption = "工作中心")
private String gzzxName;
public String getJzname() {
return jzname;
}
public void setJzname(String jzname) {
this.jzname = jzname;
}
public String getWlxxCode() {
return wlxxCode;
}
......
......@@ -12,7 +12,7 @@ public class GpwxResVO implements Serializable{
private static final long serialVersionUID = 1L;
private HzWoVO HzWoVO;
private WosngzVO wosngzVO;
private Gpfk gpfk;
......@@ -20,12 +20,12 @@ public class GpwxResVO implements Serializable{
private List<Gpbhgmx> gpbhgmxList;
public HzWoVO getHzWoVO() {
return HzWoVO;
public WosngzVO getWosngzVO() {
return wosngzVO;
}
public void setHzWoVO(HzWoVO HzWoVO) {
this.HzWoVO = HzWoVO;
public void setWosngzVO(WosngzVO wosngzVO) {
this.wosngzVO = wosngzVO;
}
public Gpfk getGpfk() {
......
......@@ -28,8 +28,7 @@ public class UWoVO extends Wo {
private String scxName;
@FieldMeta(fieldName = "LYDH", caption = "来源单号")
private String lydh;
@FieldMeta(fieldName = "U_WLXX_JZNAME", caption = "机种名称" )
private String jzname;
@FieldMeta(fieldName = "BOMCODE", caption = "产品结构号")
private String bomcode;
@FieldMeta(fieldName = "GYLXCODE", caption = "工艺路线号")
......@@ -138,14 +137,6 @@ public class UWoVO extends Wo {
this.lydh = lydh;
}
public String getJzname() {
return jzname;
}
public void setJzname(String jzname) {
this.jzname = jzname;
}
public String getBomcode() {
return bomcode;
}
......
......@@ -28,8 +28,6 @@ public class UWosnVO extends Wosn {
private String gcid;
@FieldMeta(fieldName = "WO_YWRQ", caption = "业务日期")
private Date ywrq;
@FieldMeta(fieldName = "U_WLXX_JZNAME", caption = "机种名称" )
private String jzname;
@FieldMeta(fieldName = "GCXM_CODE", caption = "项目编码" )
private String xmCode;
......@@ -43,39 +41,6 @@ public class UWosnVO extends Wosn {
@FieldMeta(fieldName = "KH_NAME", caption = "物料编码" )
private String khxxName;
@FieldMeta(fieldName = "U_WOSN_KHCODEBY1", caption = "客户序列号")
private String khcodeby1;
@FieldMeta(fieldName = "U_WOSN_KHCODEBY1FLID", caption = "客户条码类别ID")
private String khcodeby1flid;
@FieldMeta(fieldName = "U_WOSN_KHCODEBY1PREFIX", caption = "客户条码前缀")
private String khcodeby1prefix;
public String getKhcodeby1() {
return khcodeby1;
}
public void setKhcodeby1(String khcodeby1) {
this.khcodeby1 = khcodeby1;
}
public String getKhcodeby1flid() {
return khcodeby1flid;
}
public void setKhcodeby1flid(String khcodeby1flid) {
this.khcodeby1flid = khcodeby1flid;
}
public String getKhcodeby1prefix() {
return khcodeby1prefix;
}
public void setKhcodeby1prefix(String khcodeby1prefix) {
this.khcodeby1prefix = khcodeby1prefix;
}
public String getBmid() {
return bmid;
}
......@@ -140,14 +105,6 @@ public class UWosnVO extends Wosn {
this.ywrq = ywrq;
}
public String getJzname() {
return jzname;
}
public void setJzname(String jzname) {
this.jzname = jzname;
}
public String getXmCode() {
return xmCode;
}
......
......@@ -6,12 +6,9 @@ import com.gavel.wo.persistent.Wo;
import java.util.Date;
public class HzWoVO extends Wo {
public class WosngzVO extends Wo {
/**
*
*/
private static final long serialVersionUID = 1L;
@FieldMeta(fieldName = "GC_CODE", caption = "工厂编码")
private String gcCode;
@FieldMeta(fieldName = "GC_NAME", caption = "工厂名称")
......@@ -20,7 +17,7 @@ public class HzWoVO extends Wo {
private String wlxxCode;
@FieldMeta(fieldName = "WLXX_NAME", caption = "物料名称")
private String wlxxName;
@FieldMeta(fieldName = "WLXX_GG", caption = "规格")
@FieldMeta(fieldName = "WLXX_GG", caption = "物料规格")
private String wlxxGg;
@FieldMeta(fieldName = "JLDW_NAME", caption = "计量单位")
private String jldwName;
......@@ -48,27 +45,12 @@ public class HzWoVO extends Wo {
@FieldMeta(fieldName = "KH_NAME", caption = "客户名称" )
private String khName;
@FieldMeta(fieldName = "U_WLXX_BZLHSJ", caption = "标准老化时间" )
private Double bzlhsj;
@FieldMeta(fieldName = "WOSN_CODE", caption = "序列号")
private String wosnCode;
@FieldMeta(fieldName = "WOSN_ID", caption = "条码ID")
private String wosnRealId;
@FieldMeta(fieldName = "U_WOSN_JYHGBZ", caption = "合格标志" )
private String jyhgbz;
@FieldMeta(fieldName = "U_WLXX_JZNAME", caption = "机种名称" )
private String jzname;
@FieldMeta(fieldName = "U_ZXGL_ZXSNID", caption = "装包编码")
private String zxsnid;
@FieldMeta(fieldName = "U_ZTGL_ZTSNID", caption = "装托编码")
private String ztsnid;
@FieldMeta(fieldName = "WLXX_JLDW", caption = "计量单位")
private String jldw;
......@@ -90,189 +72,6 @@ public class HzWoVO extends Wo {
@FieldMeta(fieldName = "BX_NAME", caption = "班型" )
private String bxName;
@FieldMeta(fieldName = "codeNum", caption = "条码数量" )
private Integer codeNum;
@FieldMeta(fieldName = "U_WOSN_HGDJ", caption = "合格等级")
private String wosnhgdj;
@FieldMeta(fieldName = "rkts", caption = "入库天数" )
private Double rkts;
@FieldMeta(fieldName = "WLXX_KCQX", caption = "库存期限" )
private Double kcqx;
@FieldMeta(fieldName = "rknum", caption = "入库数量" )
private Double rknum;
@FieldMeta(fieldName = "cknum", caption = "出库数量" )
private Double cknum;
@FieldMeta(fieldName = "KC_YWRQ", caption = "业务日期")
private Date ywrq;
public Double getKcqx() {
return kcqx;
}
public void setKcqx(Double kcqx) {
this.kcqx = kcqx;
}
public String getWosnhgdj() {
return wosnhgdj;
}
public String getWosnhgdjAcceptNull() {
if(StringUtils.isEmpty(wosnhgdj)){
return "";
}else{
return wosnhgdj;
}
}
@Override
public Date getYwrq() {
return ywrq;
}
@Override
public void setYwrq(Date ywrq) {
this.ywrq = ywrq;
}
public Double getRkts() {
return rkts;
}
public void setRkts(Double rkts) {
this.rkts = rkts;
}
public void setWosnhgdj(String wosnhgdj) {
this.wosnhgdj = wosnhgdj;
}
public String getWosnRealId() {
return wosnRealId;
}
public void setWosnRealId(String wosnRealId) {
this.wosnRealId = wosnRealId;
}
public Double getBzlhsj() {
return bzlhsj;
}
public void setBzlhsj(Double bzlhsj) {
this.bzlhsj = bzlhsj;
}
public String getWosnCode() {
return wosnCode;
}
public void setWosnCode(String wosnCode) {
this.wosnCode = wosnCode;
}
public String getJyhgbz() {
return jyhgbz;
}
public void setJyhgbz(String jyhgbz) {
this.jyhgbz = jyhgbz;
}
public String getJzname() {
return jzname;
}
public void setJzname(String jzname) {
this.jzname = jzname;
}
public String getZxsnid() {
return zxsnid;
}
public void setZxsnid(String zxsnid) {
this.zxsnid = zxsnid;
}
public String getZtsnid() {
return ztsnid;
}
public void setZtsnid(String ztsnid) {
this.ztsnid = ztsnid;
}
public String getJldw() {
return jldw;
}
public void setJldw(String jldw) {
this.jldw = jldw;
}
public String getLastBzgx() {
return lastBzgx;
}
public void setLastBzgx(String lastBzgx) {
this.lastBzgx = lastBzgx;
}
public Date getCzsj() {
return czsj;
}
public void setCzsj(Date czsj) {
this.czsj = czsj;
}
public String getFkr() {
return fkr;
}
public void setFkr(String fkr) {
this.fkr = fkr;
}
public String getGzzxid() {
return gzzxid;
}
public void setGzzxid(String gzzxid) {
this.gzzxid = gzzxid;
}
public String getGzzxName() {
return gzzxName;
}
public void setGzzxName(String gzzxName) {
this.gzzxName = gzzxName;
}
public String getBxName() {
return bxName;
}
public void setBxName(String bxName) {
this.bxName = bxName;
}
public Integer getCodeNum() {
return codeNum;
}
public void setCodeNum(Integer codeNum) {
this.codeNum = codeNum;
}
public String getGcCode() {
return gcCode;
}
......@@ -409,19 +208,76 @@ public class HzWoVO extends Wo {
this.khName = khName;
}
public Double getRknum() {
return rknum;
public String getWosnCode() {
return wosnCode;
}
public void setWosnCode(String wosnCode) {
this.wosnCode = wosnCode;
}
public String getWosnRealId() {
return wosnRealId;
}
public void setWosnRealId(String wosnRealId) {
this.wosnRealId = wosnRealId;
}
public String getJldw() {
return jldw;
}
public void setJldw(String jldw) {
this.jldw = jldw;
}
public String getLastBzgx() {
return lastBzgx;
}
public void setLastBzgx(String lastBzgx) {
this.lastBzgx = lastBzgx;
}
public Date getCzsj() {
return czsj;
}
public void setCzsj(Date czsj) {
this.czsj = czsj;
}
public String getFkr() {
return fkr;
}
public void setFkr(String fkr) {
this.fkr = fkr;
}
public String getGzzxid() {
return gzzxid;
}
public void setGzzxid(String gzzxid) {
this.gzzxid = gzzxid;
}
public String getGzzxName() {
return gzzxName;
}
public void setRknum(Double rknum) {
this.rknum = rknum;
public void setGzzxName(String gzzxName) {
this.gzzxName = gzzxName;
}
public Double getCknum() {
return cknum;
public String getBxName() {
return bxName;
}
public void setCknum(Double cknum) {
this.cknum = cknum;
public void setBxName(String bxName) {
this.bxName = bxName;
}
}
......@@ -6,7 +6,7 @@
<a class="toolbar-print toolbar" href="javascript:void(0)"></a>
<a class="toolbar-export toolbar" href="javascript:void(0)"></a>
<a class="toolbar-fkmx toolbar" href="javascript:void(0)"></a>
<a class="toolbar-fkyy toolbar" href="javascript:void(0)"></a>
<!-- <a class="toolbar-fkyy toolbar" href="javascript:void(0)"></a>-->
</div>
<div class="form-sub">
<form class="query-criteria">
......@@ -65,12 +65,12 @@
<input type="text" name="wodjid" class="gui-textbox" style="width: 100%">
</div>
</div>
<div class="gui-col-sm4">
<!--<div class="gui-col-sm4">
<label class="gui-form-label">班型:</label>
<div class="gui-input-block">
<input type="text" name="bxid" class="gui-textbox" style="width: 100%">
</div>
</div>
</div>-->
</li>
</ul>
<span class="toolbar-search-span"><a class="toolbar-search" href="javascript:void(0)"></a></span>
......@@ -111,13 +111,13 @@ $(function () {
url: 'kmes/gpfkcx',
noRequest: true,
columns: [[
{title: "产品序列号", field: "wosnid", fieldType: "ftString",width:200},
{title: "产品序列号", field: "wosnid", fieldType: "ftString",width:180},
{title: "反馈时间", field: "fksj", fieldType: "ftDateTime"},
{title: "反馈人", field: "fkr", fieldType: "ftString",width:100,align:'center'},
{title: "工作中心", field: "gzzxName",width:100,align:'center'},
{title: "工序名称", field: "bzgxName",width:220},
{title: "班型", field: "bxName",width:100},
{title: "合格", field: "hgbz",width:80,fieldType:"checkbox"},
{title: "工序名称", field: "bzgxName",width:140},
/* {title: "班型", field: "bxName",width:100},
{title: "合格", field: "hgbz",width:80,fieldType:"checkbox"},*/
{title: "反馈数量", field: "fksl", fieldType: "int"},
{title: "合格数量", field: "hgsl", fieldType: "int"},
{title: "不合格数量", field: "bhgsl", fieldType: "int"},
......
......@@ -182,7 +182,7 @@
$datagrid.datagrid("options").url="kmes/wosngz/query";
$datagrid.datagrid("load",DataBind.collectData($div));
}
gas.load(paramInit, pageInit, dataInit);
gas.load(paramInit, pageInit, dataInit,run);
$("#wosngzTable-toolbar").find('.toolbar-gpmx').iMenubutton({
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment