Commit a460b16f authored by 张永's avatar 张永

1

parent 80678b52
...@@ -49,6 +49,7 @@ public class PageController { ...@@ -49,6 +49,7 @@ public class PageController {
String adTypeID = request.getParameter("adTypeID"); String adTypeID = request.getParameter("adTypeID");
String index = request.getParameter("index"); String index = request.getParameter("index");
String limit = request.getParameter("limit"); String limit = request.getParameter("limit");
String AgentID = request.getParameter("AgentID");
if(!StringUtil.isNotEmpty(orgNO,adTypeID,index,limit)) { if(!StringUtil.isNotEmpty(orgNO,adTypeID,index,limit)) {
return Rjx.json().setCode(-1).setMessage(I18NUtils.getMessage(orgNO,adTypeID, "Msg_Parameter_empty")).toJson(); return Rjx.json().setCode(-1).setMessage(I18NUtils.getMessage(orgNO,adTypeID, "Msg_Parameter_empty")).toJson();
} }
...@@ -56,6 +57,7 @@ public class PageController { ...@@ -56,6 +57,7 @@ public class PageController {
params.put("orgNO", orgNO); params.put("orgNO", orgNO);
params.put("adTypeID", adTypeID); params.put("adTypeID", adTypeID);
params.put("custNo", custNo); params.put("custNo", custNo);
params.put("AgentID", AgentID);
Page page = new Page(); Page page = new Page();
page.setIndex(Long.valueOf(index)); page.setIndex(Long.valueOf(index));
......
...@@ -331,37 +331,11 @@ public class OrderServiceImpl implements OrderService { ...@@ -331,37 +331,11 @@ public class OrderServiceImpl implements OrderService {
String sTransTraceNO, Date dPayDateTime,String PayTypeID) { String sTransTraceNO, Date dPayDateTime,String PayTypeID) {
String sql = "exec up_B2BSalesOrderPayUpdate '" + sOutTradeNO + "' ,'" + sTransTraceNO + "' , '" + sOpenID String sql = "exec up_B2BSalesOrderPayCallBack '" + sOutTradeNO + "' ,'" + sTransTraceNO + "' , '" + nPayAmount
+ "' , '" + nPayAmount + "' , '" + PayTypeID + "' "; + "' , '" + DateUtil.format(dPayDateTime, DateUtil.FMT_DATE_SECOND) + "' , '" + PayTypeID + "' ,0,'' ";
List<Map<String, Object>> returnMap = jdbcTemplate.executeMutil(sql).getDatas().get(0); List<Map<String, Object>> returnMap = jdbcTemplate.executeMutil(sql).getDatas().get(0);
/*List<Map<String, Object>> returnMap = new ArrayList<Map<String, Object>>();
String sSalesOrderID ="";
try {
String sSalesOrderIDSql = "select sSalesOrderID from tSalesOrderPay where sOutTradeNO = ? ";
sSalesOrderID = jdbcTemplate.queryForString(sSalesOrderIDSql, sOutTradeNO);
} catch (Exception e1) {
e1.printStackTrace();
}
if(StringUtil.isNotBlank(sSalesOrderID)) {
jdbcTemplate.update("UPDATE tSalesOrderPay SET sTransTraceNO = ? , dPayDateTime = ? ,dLastUpdateTime = getdate() WHERE sOutTradeNO = ? ",sTransTraceNO,DateUtil.format(dPayDateTime, DateUtil.FMT_DATE_SECOND),sOutTradeNO);
jdbcTemplate.update("update tSalesOrder set nOrderStatus = nOrderStatus|32 where sSalesOrderID = ?",
sSalesOrderID);
try {
returnMap = jdbcTemplate.executeMutil("exec Up_Ego_SplitOrderPrd '" + sSalesOrderID + "'").getDatas()
.get(0);
} catch (Exception e) {
e.printStackTrace();
}
}else {
logger.info("支付单号:"+sOutTradeNO +"未找到对应的订单号。");
}*/
return returnMap; return returnMap;
} }
......
...@@ -66,20 +66,16 @@ public class PageServiceImpl implements PageService { ...@@ -66,20 +66,16 @@ public class PageServiceImpl implements PageService {
String orgNO = params.get("orgNO")+""; String orgNO = params.get("orgNO")+"";
String adTypeID = params.get("adTypeID")+""; String adTypeID = params.get("adTypeID")+"";
String custNo = params.get("custNo")+""; String custNo = params.get("custNo")+"";
String AgentID = params.get("AgentID")+"";
jdbcTemplate.setDialect(new SqlServerDialect()); jdbcTemplate.setDialect(new SqlServerDialect());
String sql = "SELECT BannerAdNO = b.sBannerAdNO, BannerAdTitle = b.sBannerAdTitle,OrgNO = b.sOrgNO,AdPostionTypeID = b.sAdPositionTypeID,AdPostionType = b.sAdPositionType," String sql = "SELECT BannerAdNO = b.sBannerAdNO, BannerAdTitle = b.sBannerAdTitle,OrgNO = b.sOrgNO,AdPostionTypeID = b.sAdPositionTypeID,AdPostionType = b.sAdPositionType,"
+ " LayoutTypeID = b.sLayoutTypeID,LayoutType = b.sLayoutType,JumpTypeID = b.sJumpTypeID,JumpType = b.sJumpType,JumpList = b.sJumpList,Idx = b.nIdx,ImagePath = b.sImagePath," + " LayoutTypeID = b.sLayoutTypeID,LayoutType = b.sLayoutType,JumpTypeID = b.sJumpTypeID,JumpType = b.sJumpType,JumpList = b.sJumpList,Idx = b.nIdx,ImagePath = b.sImagePath,"
+ " LinkPath = b.sLinkPath " + " LinkPath = b.sLinkPath "
+ " from tBannerAd b " + " from tBannerAd b "
+ " WHERE b.sOrgNO = ? AND sAdPositionTypeID = ? AND b.dStartTime <=getdate() AND b.dEndTime >= getdate() AND b.nTag&2 = 2 "; + " WHERE b.sOrgNO = ? AND sAdPositionTypeID = ? AND b.dStartTime <=getdate() AND b.dEndTime >= getdate() AND b.nTag&2 = 2 and b.nAgentID = ? ";
if(StringUtil.isNotBlank(custNo)) { return jdbcTemplate.limit(sql, page, orgNO, adTypeID,AgentID);
sql += " and b.nAgentID = (select nAgentID from tCustomer c where c.nTag&2 = 2 and c.sCustNO = ? )" ;
return jdbcTemplate.limit(sql, page, orgNO, adTypeID,custNo);
}else {
return jdbcTemplate.limit(sql, page, orgNO, adTypeID);
}
} }
......
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