master
luoyang 6 years ago
parent cffd93f282
commit 82d2385fde

@ -60,7 +60,6 @@ public interface ManageAppService {
List<JSONObject> getOrgPrizeList(JSONObject device);
List<JSONObject> getOrgPrizeDetail(JSONObject device, Date month);
JSONObject getBdConfigKpi(JSONObject device);

@ -352,14 +352,6 @@ public class ManageAppServiceImp implements ManageAppService {
return orgPrizeList;
}
@Override
public List<JSONObject> getOrgPrizeDetail(JSONObject device, Date month) {
String clientType = device.getString("client_type");
manageDeviceSupport.findRegister(clientType);
JSONObject manager = managerMapper.findById(device.getString("manager_id"));
return financialPartnerCommissionMapper.getOrgPrizeDetail(manager.getString("org_id"), month);
}
@Override
public JSONObject getBdConfigKpi(JSONObject device) {
String clientType = device.getString("client_type");
@ -371,6 +363,13 @@ public class ManageAppServiceImp implements ManageAppService {
@Override
public List<JSONObject> getBdPrizeList(JSONObject device) {
//todo 获取BD提成列表
return null;
String clientType = device.getString("client_type");
manageDeviceSupport.findRegister(clientType);
JSONObject manager = managerMapper.findById(device.getString("manager_id"));
List<JSONObject> listBdPrizeLogByOne = financialBDPrizeLogMapper.listBdPrizeLogByOne(manager.getString("manager_id"));
for (JSONObject log : listBdPrizeLogByOne) {
log.put("data", financialBDPrizeLogMapper.findReportByOne(log.getString("record_id"), manager.getString("manager_id")));
}
return listBdPrizeLogByOne;
}
}

@ -33,7 +33,6 @@ import java.util.Map;
@AppClientController
@RequestMapping("/api/v1.0/manage/app")
public class ManageAppController {
Logger logger = LoggerFactory.getLogger(getClass());
@Resource
private ManageAppService manageAppService;
@ -159,17 +158,6 @@ public class ManageAppController {
return manageAppService.getOrgPrizeList(device);
}
// @RequestMapping(value = "/org_prize/{monthStr}", method = RequestMethod.GET)
// public List<JSONObject> getOrgPrizeDetail(@ModelAttribute(CommonConsts.MANAGER_DEVICE) JSONObject device,@PathVariable String monthStr) {
// Date date;
// try {
// date = DateUtils.parseDate(monthStr, new String[] { "yyyy-MM" });
// } catch (ParseException e) {
// throw new BadRequestException("Invalid month format");
// }
// return manageAppService.getOrgPrizeDetail(device, date);
// }
@RequestMapping(value = "/bd/kpi", method = RequestMethod.GET)
public JSONObject getBdConfigKpi(@ModelAttribute(CommonConsts.MANAGER_DEVICE) JSONObject device) {
return manageAppService.getBdConfigKpi(device);

@ -96,6 +96,10 @@ public class RetailValidationController {
// deviceSupport.validDeviceWithClient(manager, loginInfo.getDevId());
// }
manager.put("sign_key", signKey);
manager.remove("available_func_ids");
manager.remove("available_func_names");
manager.remove("modules");
manager.remove("module_names");
return manager;
}

@ -48,4 +48,16 @@ public interface FinancialBDPrizeLogMapper {
@AutoSql(type = SqlType.DELETE)
void clearLogsOfReport(@Param("record_id") String recordId);
@Select("select bpl.record_id,bpl.manager_id,bpl.bd_name,sum(bpl.total_amount) total_amount,sum(bpl.total_prize) total_prize,sum(bpl.total_donation) total_donation,sum(bpl.send_prize) send_prize,sum(bpl.hold_prize) hold_prize," +
"bpl.kpi_amount,bpr.`month` " +
"from financial_bd_prize_log bpl INNER JOIN financial_bd_prize_records bpr on bpl.record_id = bpr.record_id " +
"where bpl.manager_id= #{manager_id} " +
"and bpl.channel!='ALL' " +
"group by bpr.month " +
"ORDER BY bpr.month desc")
List<JSONObject> listBdPrizeLogByOne(@Param("manager_id") String manager_id);
@AutoSql(type = SqlType.SELECT)
List<JSONObject> findReportByOne(@Param("record_id") String recordId, @Param("manager_id") String managerId);
}

Loading…
Cancel
Save