修改app测试问题

This commit is contained in:
tangfutang 2020-08-01 22:25:54 +08:00
parent e9bd6c8837
commit 4d768231e7
4 changed files with 60 additions and 3 deletions

View File

@ -46,6 +46,9 @@ public class BusinessBO implements Serializable {
private String certtype; // 证件类型
private String certid; // 证件号码
private String haveCommission;//是否有佣金
private String nativeplace;//户籍地址
private String isnetcar;//是否是网约车
private String mobile;//手机号
private String SubjectId;
private String SubjectName;
@ -174,6 +177,10 @@ public class BusinessBO implements Serializable {
: fieldMap.get("liter".toLowerCase()).toString(); // 排量
this.geartype = fieldMap.get("geartype".toLowerCase()) == null ? ""
: fieldMap.get("geartype".toLowerCase()).toString(); // 档位
this.nativeplace = fieldMap.get("NATIVEADDRESS".toLowerCase()) == null ? "": fieldMap.get("NATIVEADDRESS".toLowerCase()).toString(); // 户籍地址
this.isnetcar = fieldMap.get("isnetcar".toLowerCase()) == null ? "": fieldMap.get("isnetcar".toLowerCase()).toString(); // 是否是网约车
this.mobile = fieldMap.get("mobile".toLowerCase()) == null ? "": fieldMap.get("mobile".toLowerCase()).toString(); // 手机号
//更具产品id获取对应的主体信息
List<Map<String, String>> sujectIdList = DataOperatorUtil.getDataBySql("SELECT manysubject FROM PRD_SPECIFIC_LIBRARY WHERE productid='"+this.productId+"'");
if(sujectIdList.size()>0){
@ -249,6 +256,9 @@ public class BusinessBO implements Serializable {
map.put("sourcetype", "app");
map.put("SubjectId", SubjectId);
map.put("SubjectName", SubjectName);
map.put("nativeplace", nativeplace);
map.put("isnetcar", isnetcar);
map.put("mobile", mobile);
JSONObject jsonObject = JSONObject.fromObject(map);
this.fixedFlowParam = jsonObject.toString();
@ -564,6 +574,30 @@ public class BusinessBO implements Serializable {
SubjectName = subjectName;
}
public String getNativeplace() {
return nativeplace;
}
public void setNativeplace(String nativeplace) {
this.nativeplace = nativeplace;
}
public String getIsnetcar() {
return isnetcar;
}
public void setIsnetcar(String isnetcar) {
this.isnetcar = isnetcar;
}
public String getMobile() {
return mobile;
}
public void setMobile(String mobile) {
this.mobile = mobile;
}
public void sethaveCommission(String haveCommission) {
haveCommission = haveCommission;
}

View File

@ -3,6 +3,7 @@ package apx.com.amarsoft.als.base.awe.controller;
import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import java.util.Map;
@ -12,6 +13,7 @@ import javax.ws.rs.POST;
import javax.ws.rs.Path;
import javax.ws.rs.core.Context;
import net.sf.json.JSONArray;
import apx.com.amarsoft.als.base.awe.util.AweDoCommUtil;
import apx.com.amarsoft.als.base.flow.AppConfigFlow;
import apx.com.amarsoft.als.base.flow.FlowTask;
@ -64,6 +66,10 @@ public class AweDoQueryController {
objectNo = fieldMap.get("flow_unid") == null ? "" : fieldMap
.get("flow_unid").toString();
}
String pageid = fieldMap.get("pageid") == null ? "" : fieldMap.get("pageid").toString();
if("202007180001".equalsIgnoreCase(pageid)){
fieldMap.put("inputuserid", fieldMap.get("userid"));
}
System.out.println("================Ä£°åÇëÇó²ÎÊý========================");
System.out.println(fieldMap);
System.out.println("=================================================");
@ -208,8 +214,15 @@ public class AweDoQueryController {
Lparam.add(ReturnMapUtil);
}
}
return (Map<String, Object>) targetMethod.invoke(obj,
Lparam.toArray());
Map<String, Object> mapor = (Map<String, Object>) targetMethod.invoke(obj,Lparam.toArray());
Map<String, Object> content =(Map<String, Object>) mapor.get("content");
Object datas = content.get("datas");
//System.out.println("返回参数:"+object.toString());
System.out.println("页码:"+fieldMap.get("pageIndex"));
JSONArray jsonArray = JSONArray.fromObject(datas);
System.out.println("返回数据的条数:"+jsonArray.size());
System.out.println("dataCount返回值"+content.get("dataCount"));
return mapor;
// if (value == null) {
// value = "";
// }

View File

@ -61,7 +61,7 @@ public class ApplyChangeServiceImpl implements ApplyChangeService{
String listSql = "SELECT lci.contract_no contract_no,dis.distributorTime distime,cus.distributorTime custime FROM lb_contract_info lci LEFT JOIN lb_project_info lpi ON lci.project_id=lpi.id LEFT JOIN (SELECT fbo.proj_id,SUM(TIMESTAMPDIFF(SECOND,ft.begintime,ft.endtime)) distributorTime FROM flow_bussiness_object fbo LEFT JOIN flow_task ft ON fbo.flow_unid=ft.objectno WHERE ((fbo.flow_name IN ('业务申请流程','业务变更流程') AND (ft.phaseno='0010' OR ft.phaseno='0020')) OR (fbo.flow_name IN ('合同制作流程','合同变更流程','付款申请(汽车)') AND ft.phaseno='0010'))GROUP BY fbo.proj_id ) dis ON dis.proj_id=lpi.id LEFT JOIN (SELECT fbo.proj_id,SUM(TIMESTAMPDIFF(SECOND,ft.begintime,ft.endtime)) distributorTime FROM flow_bussiness_object fbo LEFT JOIN flow_task ft ON fbo.flow_unid=ft.objectno WHERE ((fbo.flow_name IN ('业务申请流程','业务变更流程') AND ft.phaseno<>'0010' AND ft.phaseno<>'0020' AND ft.phaseno<>'1000' AND ft.phaseno<>'8000') OR (fbo.flow_name IN ('合同制作流程','合同变更流程','付款申请(汽车)') AND ft.phaseno<>'0010' AND ft.phaseno<>'1000' AND ft.phaseno<>'8000'))GROUP BY fbo.proj_id) cus ON cus.proj_id=lpi.id WHERE lci.CONTRACT_STATUS>=31 AND lci.distributor_id='"+disList.get(0).get("distributor_no")+"' ORDER BY dis.distributorTime DESC ";
List<Map<String, String>> dataList = DataOperatorUtil.getDataBySql(listSql);
body.put("listdatas", dataList);
String averageSql = "SELECT LEFT(lpi.INPUTTIME,7) yearmonth,SUM(dis.distributorTime)/COUNT(lpi.INPUTTIME) averagedistim,SUM(cus.distributorTime)/COUNT(lpi.INPUTTIME) averagecustime FROM lb_contract_info lci LEFT JOIN lb_project_info lpi ON lci.project_id=lpi.id LEFT JOIN (SELECT fbo.proj_id,SUM(TIMESTAMPDIFF(SECOND,ft.begintime,ft.endtime)) distributorTime FROM flow_bussiness_object fbo LEFT JOIN flow_task ft ON fbo.flow_unid=ft.objectno WHERE ((fbo.flow_name IN ('业务申请流程','业务变更流程') AND (ft.phaseno='0010' OR ft.phaseno='0020')) OR (fbo.flow_name IN ('合同制作流程','合同变更流程','付款申请(汽车)') AND ft.phaseno='0010'))GROUP BY fbo.proj_id ) dis ON dis.proj_id=lpi.id LEFT JOIN (SELECT fbo.proj_id,SUM(TIMESTAMPDIFF(SECOND,ft.begintime,ft.endtime)) distributorTime FROM flow_bussiness_object fbo LEFT JOIN flow_task ft ON fbo.flow_unid=ft.objectno WHERE ((fbo.flow_name IN ('业务申请流程','业务变更流程') AND ft.phaseno<>'0010' AND ft.phaseno<>'0020' AND ft.phaseno<>'1000' AND ft.phaseno<>'8000') OR (fbo.flow_name IN ('合同制作流程','合同变更流程','付款申请(汽车)') AND ft.phaseno<>'0010' AND ft.phaseno<>'1000' AND ft.phaseno<>'8000'))GROUP BY fbo.proj_id) cus ON cus.proj_id=lpi.id WHERE lci.CONTRACT_STATUS>=31 AND LEFT(lpi.INPUTTIME,7)<='"+month+"' AND lci.distributor_id='"+disList.get(0).get("distributor_no")+"' GROUP BY LEFT(lpi.INPUTTIME,7) ORDER BY LEFT(lpi.INPUTTIME,7) DESC LIMIT 0,6";
String averageSql = "select * from ( SELECT LEFT(lpi.INPUTTIME,7) yearmonth,SUM(dis.distributorTime)/COUNT(lpi.INPUTTIME) averagedistim,SUM(cus.distributorTime)/COUNT(lpi.INPUTTIME) averagecustime FROM lb_contract_info lci LEFT JOIN lb_project_info lpi ON lci.project_id=lpi.id LEFT JOIN (SELECT fbo.proj_id,SUM(TIMESTAMPDIFF(SECOND,ft.begintime,ft.endtime)) distributorTime FROM flow_bussiness_object fbo LEFT JOIN flow_task ft ON fbo.flow_unid=ft.objectno WHERE ((fbo.flow_name IN ('业务申请流程','业务变更流程') AND (ft.phaseno='0010' OR ft.phaseno='0020')) OR (fbo.flow_name IN ('合同制作流程','合同变更流程','付款申请(汽车)') AND ft.phaseno='0010'))GROUP BY fbo.proj_id ) dis ON dis.proj_id=lpi.id LEFT JOIN (SELECT fbo.proj_id,SUM(TIMESTAMPDIFF(SECOND,ft.begintime,ft.endtime)) distributorTime FROM flow_bussiness_object fbo LEFT JOIN flow_task ft ON fbo.flow_unid=ft.objectno WHERE ((fbo.flow_name IN ('业务申请流程','业务变更流程') AND ft.phaseno<>'0010' AND ft.phaseno<>'0020' AND ft.phaseno<>'1000' AND ft.phaseno<>'8000') OR (fbo.flow_name IN ('合同制作流程','合同变更流程','付款申请(汽车)') AND ft.phaseno<>'0010' AND ft.phaseno<>'1000' AND ft.phaseno<>'8000'))GROUP BY fbo.proj_id) cus ON cus.proj_id=lpi.id WHERE lci.CONTRACT_STATUS>=31 AND LEFT(lpi.INPUTTIME,7)<='"+month+"' AND lci.distributor_id='"+disList.get(0).get("distributor_no")+"' GROUP BY LEFT(lpi.INPUTTIME,7) ORDER BY LEFT(lpi.INPUTTIME,7) DESC LIMIT 0,6 ) t ORDER BY yearmonth ASC";
List<Map<String, String>> averageSqldataList = DataOperatorUtil.getDataBySql(averageSql);
body.put("averagedatas", averageSqldataList);

View File

@ -245,11 +245,17 @@ public class LBProjectIntoTempInitCarBusiness extends BaseBussiness {
boCRT.setAttributeValue("INPUTUSERID", asUser.getUserID());//登记人
boCRT.setAttributeValue("INPUTORGID", asUser.getOrgID());//登记部门
boCRT.setAttributeValue("inputtime", StringFunction.getTodayNow());//登记时间,系统当前时间
if("03".equals(this.getAttribute("CustomerType"))){
boCRT.setAttributeValue("BALANCESHEET", "申请人");
if(lbat != null){
boCRT.setAttributeValue("mobile", lbat.getAttribute("fullphone")+"");
}
String sourcetype = this.getAttribute("sourcetype") == null ? "" : this.getAttribute("sourcetype").toString();
if("app".equals(sourcetype)){//如果app进单保存户籍地址和手机号
boCRT.setAttributeValue("MOBILE", this.getAttribute("mobile"));//手机号
boCRT.setAttributeValue("NATIVEPLACE", this.getAttribute("nativeplace"));//户籍地址
}
}
bomC.saveObject(boCRT);
} catch (Exception e) {
@ -353,6 +359,10 @@ public class LBProjectIntoTempInitCarBusiness extends BaseBussiness {
bo.setAttributeValue("is_netcar",isNetCar == null ? "" : isNetCar);
bo.setAttributeValue("subjectid",this.getAttribute("SubjectId"));
bo.setAttributeValue("subjectname",this.getAttribute("SubjectName"));
String sourcetype = this.getAttribute("sourcetype") == null ? "" : this.getAttribute("sourcetype").toString();
if("03".equals(this.getAttribute("CustomerType")) && "app".equals(sourcetype)){
bo.setAttributeValue("is_netcar",this.getAttribute("isnetcar") );
}
bomLPI.saveObject(bo);
}catch (Exception e){
tx.rollback();