修改app测试问题
This commit is contained in:
parent
e1bb871ce3
commit
9fe634e7da
@ -50,7 +50,7 @@ public class ContractMakeServiceImpl implements ContractMakeService{
|
||||
.readRequestParam(request, "UTF-8");
|
||||
fieldMap = (Map<String, Object>) testMap.get("fieldMap"); // ²ÎÊý
|
||||
String userId = fieldMap.get("userid") == null ? "" : fieldMap.get("userid").toString();
|
||||
String vagueCondition = fieldMap.get("vagueCondition") == null ? "" : fieldMap.get("vagueCondition").toString();
|
||||
String globaltext = fieldMap.get("globaltext") == null ? "" : fieldMap.get("globaltext").toString();
|
||||
Map<String, Object> body = new HashMap<String, Object>();
|
||||
ASUser asUser = new ASUser(userId);
|
||||
String orgID = asUser.getOrgID();
|
||||
@ -60,13 +60,14 @@ public class ContractMakeServiceImpl implements ContractMakeService{
|
||||
}else{
|
||||
sql="SELECT lpi.END_DATE AS startdate,lpi.id projectid, lpi.product_id, lpi.project_no, lpi.project_name, ci.customername, getItemName ('CertType', ci.certtype) certtype, ci.certid, getUserName (lpi.project_manage) AS project_manage, getOrgLevelName (lpi.project_dept) project_dept, ci.customertype,lpi.leas_form,lpi.CAR_TYPE,lpi.IS_NETCAR,psl.operationType,psl.signType,psl.sealType,lpi.subjectid,lpi.subjectname,lpc.CLEAN_LEASE_MONEY AS clean_lease_money,lpc.INCOME_NUMBER AS income_number,lec.MODEL AS model,lprp.RENT AS rent FROM LB_PROJECT_INFO lpi LEFT JOIN LC_PROJ_CONDITION lpc ON lpi.id=lpc.project_id LEFT JOIN LB_CONTRACT_INFO lci ON lpi.id=lci.project_id LEFT JOIN LC_CONTRACT_CONDITION lcc ON lci.id=lcc.contract_id LEFT JOIN LB_UNION_LESSEE lult ON lpi.id = lult.project_id AND (lult.contract_id = '' OR lult.contract_id IS NULL) LEFT JOIN CUSTOMER_INFO ci ON lult.customer_id = ci.customerid LEFT JOIN PRD_SPECIFIC_LIBRARY psl ON psl.productid=lpi.product_id LEFT JOIN LB_EQUIPMENT_CAR lec ON lec.project_id=lpi.id LEFT JOIN LC_PROJ_RENT_PLAN lprp ON lprp.project_id=lpi.id AND lprp.plan_list='1' WHERE lult.is_main = 'y' AND lpi.project_status = '13' AND((lci.contract_status = '21' AND lpc.equip_amt>lcc.equip_amt) OR ((lult.CONTRACT_ID='' OR lult.CONTRACT_ID IS NULL)AND (SELECT COUNT(*) FROM lb_contract_info WHERE project_id=lpi.id)=0)) AND lpi.PROJECT_MANAGE='"+userId+"'";
|
||||
}
|
||||
if(vagueCondition.length() ==0 ){
|
||||
if(globaltext.length() ==0 ){
|
||||
sql = sql+ " AND lpi.businesstype='1' ORDER BY lpi.END_DATE DESC ";
|
||||
}else{
|
||||
sql = sql+ " and (lpi.project_no like '%"+vagueCondition+"%' or ci.customername like '%"+vagueCondition+"%') AND lpi.businesstype='1' ORDER BY lpi.END_DATE DESC ";
|
||||
sql = sql+ " and (lpi.project_no like '%"+globaltext+"%' or ci.customername like '%"+globaltext+"%') AND lpi.businesstype='1' ORDER BY lpi.END_DATE DESC ";
|
||||
}
|
||||
List<Map<String, String>> dataList = DataOperatorUtil.getDataBySql(sql);
|
||||
body.put("datas", dataList);
|
||||
body.put("filters", "申请编号,客户名称");
|
||||
ReturnMapUtil.setReturnMap(body,
|
||||
RestfullConstant.baseProperty.get("success").toString(), "");
|
||||
return ReturnMapUtil.getReturnMap();
|
||||
@ -406,7 +407,7 @@ public class ContractMakeServiceImpl implements ContractMakeService{
|
||||
.readRequestParam(request, "UTF-8");
|
||||
fieldMap = (Map<String, Object>) testMap.get("fieldMap"); // ²ÎÊý
|
||||
String userId = fieldMap.get("userid") == null ? "" : fieldMap.get("userid").toString();
|
||||
String vagueCondition = fieldMap.get("vagueCondition") == null ? "" : fieldMap.get("vagueCondition").toString();
|
||||
String globaltext = fieldMap.get("globaltext") == null ? "" : fieldMap.get("globaltext").toString();
|
||||
|
||||
Map<String, Object> body = new HashMap<String, Object>();
|
||||
ASUser asUser = new ASUser(userId);
|
||||
@ -417,13 +418,14 @@ public class ContractMakeServiceImpl implements ContractMakeService{
|
||||
}else{
|
||||
sql="SELECT lpi.END_DATE AS startdate,lci.id as contractid,lult.project_id as projectid,lci.product_id,lci.contract_no flowkey,lci.contract_number,lci.project_name,ci.customername,getItemName('CertType',ci.certtype) certtype,ci.certid,getUserName(lci.project_manage) AS project_manage,getOrgLevelName(lci.project_dept) project_dept,ci.customertype,lci.leas_form,lpi.CAR_TYPE,lpi.IS_NETCAR,psl.operationType,psl.sealType,psl.signType,lci.subjectid,lci.subjectname,lci.inputuserid,lpi.project_no as project_no,lpc.CLEAN_LEASE_MONEY AS clean_lease_money,lpc.INCOME_NUMBER AS income_number,lec.MODEL AS model,lprp.RENT AS rent FROM LB_CONTRACT_INFO lci LEFT JOIN LB_PROJECT_INFO lpi ON lpi.id = lci.project_id LEFT JOIN LB_UNION_LESSEE lult ON lci.id=lult.contract_id LEFT JOIN CUSTOMER_INFO ci ON lult.customer_id=ci.customerid LEFT JOIN PRD_SPECIFIC_LIBRARY psl ON psl.productid = lpi.product_id LEFT JOIN LB_EQUIPMENT_CAR lec ON lec.project_id=lpi.id LEFT JOIN LC_PROJ_RENT_PLAN lprp ON lprp.project_id=lpi.id AND lprp.plan_list='1' LEFT JOIN LC_PROJ_CONDITION lpc ON lpi.id=lpc.project_id WHERE lult.is_main='y' AND lci.businesstype='1' AND NOT EXISTS (SELECT 1 FROM LC_CALC_CONDITION_STATUS ccs WHERE ccs.contract_id=lci.id) AND contract_status='21' AND lci.inputuserid='"+userId+"' ";
|
||||
}
|
||||
if(vagueCondition.length() ==0 ){
|
||||
if(globaltext.length() ==0 ){
|
||||
sql = sql+ " ORDER BY lci.contract_number DESC ";
|
||||
}else{
|
||||
sql = sql+ " and (lci.contract_number like '%"+vagueCondition+"%' or lpi.project_no like '%"+vagueCondition+"%' or ci.customername like '%"+vagueCondition+"%') ORDER BY lci.contract_number DESC ";
|
||||
sql = sql+ " and (lci.contract_number like '%"+globaltext+"%' or lpi.project_no like '%"+globaltext+"%' or ci.customername like '%"+globaltext+"%') ORDER BY lci.contract_number DESC ";
|
||||
}
|
||||
List<Map<String, String>> dataList = DataOperatorUtil.getDataBySql(sql);
|
||||
body.put("datas", dataList);
|
||||
body.put("filters", "合同编号,申请编号,客户名称");
|
||||
ReturnMapUtil.setReturnMap(body,
|
||||
RestfullConstant.baseProperty.get("success").toString(), "");
|
||||
return ReturnMapUtil.getReturnMap();
|
||||
@ -437,7 +439,7 @@ public class ContractMakeServiceImpl implements ContractMakeService{
|
||||
.readRequestParam(request, "UTF-8");
|
||||
fieldMap = (Map<String, Object>) testMap.get("fieldMap"); // ²ÎÊý
|
||||
String userId = fieldMap.get("userid") == null ? "" : fieldMap.get("userid").toString();
|
||||
String vagueCondition = fieldMap.get("vagueCondition") == null ? "" : fieldMap.get("vagueCondition").toString();
|
||||
String globaltext = fieldMap.get("globaltext") == null ? "" : fieldMap.get("globaltext").toString();
|
||||
|
||||
Map<String, Object> body = new HashMap<String, Object>();
|
||||
ASUser asUser = new ASUser(userId);
|
||||
@ -448,13 +450,14 @@ public class ContractMakeServiceImpl implements ContractMakeService{
|
||||
}else{
|
||||
sql="SELECT lpi.END_DATE AS startdate,lci.id as contractid,lult.project_id as projectid, lci.product_id,lci.contract_no FlowKey,lci.contract_number,lci.project_name,ci.customername,getItemName('CertType',ci.certtype) certtype,ci.certid,getUserName(lci.project_manage) AS project_manage,getOrgLevelName(lci.project_dept) project_dept,ci.customertype,lci.car_type,lci.leas_form,lpi.project_no as project_no,lpc.CLEAN_LEASE_MONEY AS clean_lease_money,lpc.INCOME_NUMBER AS income_number,lec.MODEL AS model,lprp.RENT AS rent FROM LB_CONTRACT_INFO lci LEFT JOIN lb_project_info lpi ON lpi.id=lci.project_id LEFT JOIN LB_UNION_LESSEE lult ON lci.id=lult.contract_id LEFT JOIN CUSTOMER_INFO ci ON lult.customer_id=ci.customerid LEFT JOIN LB_EQUIPMENT_CAR lec ON lec.project_id=lpi.id LEFT JOIN LC_PROJ_RENT_PLAN lprp ON lprp.project_id=lpi.id AND lprp.plan_list='1' LEFT JOIN LC_PROJ_CONDITION lpc ON lpi.id=lpc.project_id WHERE lult.is_main='y' AND lci.businesstype = '1' AND NOT EXISTS (SELECT 1 FROM LC_CALC_CONDITION_STATUS ccs WHERE ccs.contract_id=lci.id) AND contract_status='21' AND lci.PROJECT_MANAGE='"+userId+"' ";
|
||||
}
|
||||
if(vagueCondition.length() ==0 ){
|
||||
if(globaltext.length() ==0 ){
|
||||
sql = sql+ " order by lci.contract_number desc ";
|
||||
}else{
|
||||
sql = sql+ " and (lci.contract_number like '%"+vagueCondition+"%' or lpi.project_no like '%"+vagueCondition+"%' or ci.customername like '%"+vagueCondition+"%') ORDER BY lci.contract_number DESC ";
|
||||
sql = sql+ " and (lci.contract_number like '%"+globaltext+"%' or lpi.project_no like '%"+globaltext+"%' or ci.customername like '%"+globaltext+"%') ORDER BY lci.contract_number DESC ";
|
||||
}
|
||||
List<Map<String, String>> dataList = DataOperatorUtil.getDataBySql(sql);
|
||||
body.put("datas", dataList);
|
||||
body.put("filters", "合同编号,申请编号,客户名称");
|
||||
ReturnMapUtil.setReturnMap(body,
|
||||
RestfullConstant.baseProperty.get("success").toString(), "");
|
||||
return ReturnMapUtil.getReturnMap();
|
||||
|
||||
@ -232,7 +232,7 @@ public class AppUserLoginServiceImpl implements AppUserLoginService {
|
||||
sMsg += userMap.get("USERNAME".toLowerCase()) + "!";
|
||||
//获取菜单列表
|
||||
try {
|
||||
List<Map<String, String>> dataList = DataOperatorUtil.getDataBySql("SELECT menuid,displayname,sortno FROM app_menu_info WHERE menuid IN (SELECT menuid FROM app_role_menu WHERE roleid=(SELECT ROLEID FROM USER_ROLE WHERE userid='"+body.get("userid")+"'))");
|
||||
List<Map<String, String>> dataList = DataOperatorUtil.getDataBySql("SELECT menuid,displayname,sortno FROM app_menu_info WHERE menuid IN (SELECT menuid FROM app_role_menu WHERE roleid in (SELECT ROLEID FROM USER_ROLE WHERE userid='"+body.get("userid")+"'))");
|
||||
body.put("menu", dataList);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
@ -336,7 +336,7 @@ public class AppUserLoginServiceImpl implements AppUserLoginService {
|
||||
private void userLoginBefreBusiness(JBOTransaction tx, String sUserId)
|
||||
throws JBOException {
|
||||
// 强踢已登录设备同ID用户下线
|
||||
// SessionHelper.removerByUserId(tx, sUserId);
|
||||
//SessionHelper.removerByUserId(tx, sUserId);
|
||||
}
|
||||
|
||||
private String getMD5Hex(byte[] buf) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user