예제 #1
0
 @POST
 @Consumes(MediaType.APPLICATION_JSON)
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/insertOrUpdateTarget/{user}/{token}")
 public Response insertOrUpdateTarget(Targets targets, @PathParam("token") String token) {
   List<String> resultList = partnerService.insertOrUpdateTarget(targets);
   BaseResponse<String> baseResponse = new BaseResponse<>();
   baseResponse.setResponseListObject(resultList);
   response = FiinfraResponseBuilder.getSuccessResponse(baseResponse, null);
   return response;
 }
예제 #2
0
 @POST
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/getAllRoleAccessList/{user}/{token}")
 public Response getAllRoleAccessList(
     @Context HttpServletRequest request,
     @PathParam("token") String token,
     @PathParam("user") String name,
     @RequestBody RoleAccess roleAccess) {
   String buId = request.getHeader("buId");
   response = partnerService.getAllRoleAccessList(roleAccess, Integer.parseInt(buId));
   return response;
 }
예제 #3
0
 @GET
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/getAutoPlanClinetDetailsRecord/{user}/{token}")
 public Response getAutoPlanClinetDetailsRecord(
     @QueryParam("partyId") int partyId,
     @QueryParam("buId") int buId,
     @PathParam("token") String token,
     @PathParam("user") String name)
     throws JsonGenerationException, JsonMappingException, IOException {
   BaseResponse<AutoPlanData> baseResponse = new BaseResponse<AutoPlanData>();
   baseResponse.setResponseObject(partnerService.getAutoPlanClinetDetailsRecord(partyId, buId));
   baseResponse.setStatus("SUCCESS");
   Response response = FiinfraResponseBuilder.getSuccessResponse(baseResponse, null);
   return response;
 }
예제 #4
0
 @GET
 @Consumes(MediaType.APPLICATION_JSON)
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/getPlanType/{user}/{token}")
 public Response getPlanType(
     @QueryParam("buId") int buId,
     @QueryParam("partyId") int partyId,
     @PathParam("token") String token,
     @PathParam("user") String name)
     throws IOException {
   BaseResponse<Integer> br = new BaseResponse<>();
   br.setResponseObject(partnerService.getPlanType(partyId, buId));
   Response response = FiinfraResponseBuilder.getSuccessResponse(br, null);
   return response;
 }
예제 #5
0
 @GET
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/deleteTargets/{user}/{token}")
 public Response deleteTargets(
     @QueryParam("buId") int buId,
     @QueryParam("targetIds") String targetIds,
     @PathParam("token") String token,
     @PathParam("user") String name)
     throws Exception {
   int recordCount = partnerService.deleteTargets(targetIds, buId);
   BaseResponse<Integer> br = new BaseResponse<Integer>();
   br.setResponseObject(recordCount);
   response = FiinfraResponseBuilder.getSuccessResponse(br, null);
   return response;
 }
예제 #6
0
 @POST
 @Consumes(MediaType.APPLICATION_JSON)
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/convertContact/{user}/{token}")
 public Response convertContact(
     UserData userData, @PathParam("token") String token, @PathParam("user") String name)
     throws Exception {
   int buId = userData.getBuID();
   int lastModifiedBy = userData.getCreatedBy();
   List<Integer> recordCount =
       partnerService.convertContact(buId, lastModifiedBy, userData.getUserDataXML());
   BaseResponse<Integer> br = new BaseResponse<>();
   br.setResponseListObject(recordCount);
   response = FiinfraResponseBuilder.getSuccessResponse(br, null);
   return response;
 }
예제 #7
0
 @POST
 @Path(value = "/saveInterstedFpSection/{username}/{token}")
 @Produces(MediaType.APPLICATION_JSON)
 public Response saveInterstedFpSection(
     @PathParam("username") String userName,
     @PathParam("token") String token,
     @QueryParam("partyId") int partyId,
     @QueryParam("lastModifiedBy") Integer lastModifiedBy,
     @QueryParam("buId") Integer buId,
     @RequestBody KeyValue keyValue) {
   BaseResponse<Boolean> baseResponse = new BaseResponse<Boolean>();
   baseResponse.setResponseObject(new Boolean(true));
   partnerService.saveInterstedFpSection(partyId, lastModifiedBy, keyValue, buId);
   Response response = FiinfraResponseBuilder.getSuccessResponse(baseResponse, null);
   return response;
 }
예제 #8
0
 @GET
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/getPartnerAutoPlanConfiguration/{user}/{token}")
 public Response getPartnerAutoPlanConfiguration(
     @Context HttpServletRequest request,
     @PathParam("token") String token,
     @PathParam("user") String name,
     @QueryParam("partyId") int partyId)
     throws IOException {
   String buId = request.getHeader("buId");
   BaseResponse<Integer> br = new BaseResponse<Integer>();
   br.setResponseObject(
       partnerService.getPartnerAutoPlanCongiguration(partyId, Integer.parseInt(buId)));
   Response response = FiinfraResponseBuilder.getSuccessResponse(br, null);
   return response;
 }
예제 #9
0
 @POST
 @Path(value = "/updateQuickDCDetails/{username}/{token}")
 @Consumes(MediaType.APPLICATION_JSON)
 @Produces(MediaType.APPLICATION_JSON)
 public Response updateQuickDCDetails(
     AutoPlanData autoPlanData,
     @Context HttpServletRequest request,
     @PathParam("username") String userName,
     @PathParam("token") String token) {
   String buId = request.getHeader("buId");
   BaseResponse<Integer> baseResponse = new BaseResponse<>();
   baseResponse.setResponseObject(
       partnerService.updateQuickDCDetails(autoPlanData, Integer.parseInt(buId)));
   Response response = FiinfraResponseBuilder.getSuccessResponse(baseResponse, null);
   return response;
 }
예제 #10
0
 @GET
 @Path(value = "/updateCurrentNodeIdForPartyId/{username}/{token}")
 @Produces(MediaType.APPLICATION_JSON)
 public Response updateCurrentNodeIdForPartyId(
     @Context HttpServletRequest request,
     @PathParam("username") String userName,
     @PathParam("token") String token,
     @QueryParam("partyId") int partyId,
     @QueryParam("nodeId") int nodeId) {
   String buId = request.getHeader("buId");
   BaseResponse<Boolean> baseResponse = new BaseResponse<Boolean>();
   baseResponse.setResponseObject(
       partnerService.updateCurrentNodeIdForPartyId(partyId, nodeId, Integer.parseInt(buId)));
   Response response = FiinfraResponseBuilder.getSuccessResponse(baseResponse, null);
   return response;
 }
예제 #11
0
 @GET
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/getProfileRecord/{user}/{token}")
 public Response getProfileRecord(
     @QueryParam("partyId") int partyId,
     @QueryParam("buId") int buId,
     @PathParam("token") String token,
     @PathParam("user") String name)
     throws JsonGenerationException, JsonMappingException, IOException {
   logger.debug("partyId:---" + partyId);
   ProfileData documentData = partnerService.getProfileDetails(partyId, buId);
   BaseResponse<ProfileData> br = new BaseResponse<>();
   br.setResponseObject(documentData);
   response = FiinfraResponseBuilder.getSuccessResponse(br, null);
   return response;
 }
예제 #12
0
 @POST
 @Consumes(MediaType.APPLICATION_JSON)
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/savePartnerLocationData/{user}/{token}")
 public Response savePartnerLocationData(
     LocationData locationData,
     @Context HttpServletRequest request,
     @PathParam("token") String token,
     @PathParam("user") String name)
     throws Exception {
   String buId = request.getHeader("buId");
   int recordCount = partnerService.savePartnerLocationData(locationData, Integer.parseInt(buId));
   BaseResponse<Integer> br = new BaseResponse<>();
   br.setResponseObject(recordCount);
   response = FiinfraResponseBuilder.getSuccessResponse(br, null);
   return response;
 }
예제 #13
0
  @GET
  @Produces(MediaType.APPLICATION_JSON)
  @Path("/getOLTransactionConfiguration/{username}/{token}")
  public Response getOLTransactionConfiguration(
      @PathParam("username") String username,
      @PathParam("token") String token,
      @QueryParam("partyId") Integer partyId,
      @QueryParam("attrCodeId") Integer attrCodeId,
      @QueryParam("attrCodeList") String attrCodeList,
      @QueryParam("buId") Integer buId) {

    BaseResponse<ConfigurationProductsList> br = new BaseResponse<ConfigurationProductsList>();
    br.setResponseObject(
        partnerService.getConfigurationProductsList(partyId, attrCodeId, attrCodeList, buId));
    response = FiinfraResponseBuilder.getSuccessResponse(br, null);
    return response;
  }
예제 #14
0
 @GET
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/getPartnerDetails/{user}/{token}")
 public Response getPartnerDetails(
     @QueryParam("buId") int buId,
     @QueryParam("partyId") int partyId,
     @PathParam("token") String token,
     @PathParam("user") String name)
     throws JsonGenerationException, JsonMappingException, IOException {
   logger.debug("partyId:---" + partyId);
   Partner partner = partnerService.getPartnerDetails(partyId, buId);
   BaseResponse<Partner> br = new BaseResponse<>();
   br.setResponseObject(partner);
   response = FiinfraResponseBuilder.getSuccessResponse(br, null);
   // System.out.println("Response======"+response);
   return response;
 }
예제 #15
0
 @GET
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/getNotificationListForPartner/{user}/{token}")
 public Response getNotificationListForPartner(
     @QueryParam("partyId") int partyId,
     @QueryParam("buId") int buId,
     @PathParam("token") String token,
     @PathParam("user") String name)
     throws JsonGenerationException, JsonMappingException, IOException {
   logger.debug("partyId:---" + partyId);
   List<NotificationDetails> notificationDetailsList =
       partnerService.getNotificationListForPartner(partyId, buId);
   BaseResponse<NotificationDetails> br = new BaseResponse<>();
   br.setResponseListObject(notificationDetailsList);
   response = FiinfraResponseBuilder.getSuccessResponse(br, null);
   return response;
 }
예제 #16
0
 @GET
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/getInterstedFpSection/{user}/{token}")
 public Response getInterstedFpSection(
     @QueryParam("partnerPartyId") int partnerPartyId,
     @QueryParam("buId") int buId,
     @QueryParam("clientPartyId") int clientPartyId,
     @PathParam("token") String token,
     @PathParam("user") String name)
     throws JsonGenerationException, JsonMappingException, IOException {
   BaseResponse<KeyValue> baseResponse = new BaseResponse<KeyValue>();
   baseResponse.setResponseListObject(
       partnerService.getInterstedFpSection(partnerPartyId, clientPartyId, buId));
   baseResponse.setStatus("SUCCESS");
   Response response = FiinfraResponseBuilder.getSuccessResponse(baseResponse, null);
   return response;
 }
예제 #17
0
 @GET
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/getNameOfPartnerOrNode/{user}/{token}")
 public Response getNameOfPartnerOrNode(
     @Context HttpServletRequest request,
     @QueryParam("partyId") Integer partyId,
     @QueryParam("currentNodeId") Integer currentNodeId,
     @PathParam("token") String token,
     @PathParam("user") String userName)
     throws JsonGenerationException, JsonMappingException, IOException {
   String buId = request.getHeader("buId");
   String name =
       partnerService.getNameOfPartnerOrNode(partyId, currentNodeId, Integer.parseInt(buId));
   BaseResponse<String> br = new BaseResponse<>();
   br.setResponseObject(name);
   response = FiinfraResponseBuilder.getSuccessResponse(br, null);
   return response;
 }
예제 #18
0
  @GET
  @Produces(MediaType.APPLICATION_JSON)
  @Path("/getTargetsList/{user}/{token}")
  public Response getTargetsList(
      @QueryParam("partyId") int partyId,
      @QueryParam("buId") int buId,
      @QueryParam("nodeId") int nodeId,
      @PathParam("token") String token,
      @PathParam("user") String name)
      throws Exception {
    List<Targets> notifyTemplateDatas = partnerService.getTargetsList(partyId, buId, nodeId);
    // System.out.println("in APP getStandardPingList ="+partyId);
    BaseResponse<Targets> br = new BaseResponse<>();

    br.setResponseListObject(notifyTemplateDatas);
    response = FiinfraResponseBuilder.getSuccessResponse(br, null);
    return response;
  }
예제 #19
0
  @GET
  @Produces(MediaType.APPLICATION_JSON)
  @Path("/updateRoleAccessList/{user}/{token}")
  public Response updateRoleAccessList(
      @Context HttpServletRequest request,
      @QueryParam("Lists") String objectIdList,
      @QueryParam("partyId") int partyId,
      @QueryParam("createdby") int createdby,
      @QueryParam("sourceId") int sourceId,
      @PathParam("token") String token,
      @PathParam("user") String name) {

    String buId = request.getHeader("buId");
    response =
        partnerService.updateRoleAccessList(
            objectIdList, partyId, createdby, sourceId, Integer.parseInt(buId));
    return response;
  }
예제 #20
0
 @GET
 @Consumes(MediaType.APPLICATION_JSON)
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/deletePartner/{user}/{token}")
 public Response deletePartner(
     @QueryParam("buId") int buId,
     @QueryParam("partyId") int partyId,
     @PathParam("token") String token,
     @PathParam("user") String name)
     throws IOException {
   // System.out.println("In APP Calling deletePartner");
   BaseResponse<Integer> br = new BaseResponse<>();
   logger.info(br);
   br.setResponseObject(partnerService.deletePartner(partyId, buId));
   // Response  response=partnerService.addPartner(partner);
   Response response = FiinfraResponseBuilder.getSuccessResponse(br, null);
   // System.out.println("Delete Partner="+response);
   return response;
 }
예제 #21
0
 @POST
 @Consumes(MediaType.APPLICATION_JSON)
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/savePartnerData/{user}/{token}")
 public Response savePartnerData(
     Partner partner,
     @Context HttpServletRequest request,
     @PathParam("token") String token,
     @PathParam("user") String name)
     throws IOException {
   // System.out.println("In APP Calling SavePartner");
   String buId = request.getHeader("buId");
   BaseResponse<Integer> br = new BaseResponse<>();
   logger.info(br);
   br.setResponseObject(partnerService.addPartner(partner, Integer.parseInt(buId)));
   // Response  response=partnerService.addPartner(partner);
   Response response = FiinfraResponseBuilder.getSuccessResponse(br, null);
   return response;
 }
예제 #22
0
 @POST
 @Consumes(MediaType.APPLICATION_JSON)
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/updatePartnerProfile/{user}/{token}")
 public Response updatePartnerProfile(
     ProfileData profileData, @PathParam("token") String token, @PathParam("user") String name)
     throws Exception {
   String sectionName = profileData.getSectionName();
   String dataXml = FiinfraUtility.getProfileDataXML(profileData, sectionName);
   int buId = profileData.getBuId();
   int partyId = profileData.getPartyId();
   int recordCount =
       partnerService.updatePartnerProfile(
           sectionName, dataXml, buId, partyId, profileData.getLastModifiedBy());
   BaseResponse<Integer> br = new BaseResponse<>();
   br.setResponseObject(recordCount);
   response = FiinfraResponseBuilder.getSuccessResponse(br, null);
   return response;
 }
예제 #23
0
 @GET
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/getperformanceMatrixReport/{user}/{token}")
 public Response getperformanceMatrixReport(
     @QueryParam("partyId") int partyId,
     @QueryParam("buId") int buId,
     @QueryParam("benchMark") int benchMark,
     @QueryParam("banchMarkCategory") int banchMarkCategory,
     @QueryParam("dataTagId") int dataTagId,
     @PathParam("token") String token,
     @PathParam("user") String name)
     throws JsonGenerationException, JsonMappingException, IOException {
   BaseResponse<PerformanceMatrixData> baseResponse = new BaseResponse<PerformanceMatrixData>();
   baseResponse.setResponseListObject(
       partnerService.getperformanceMatrixReport(
           partyId, buId, benchMark, banchMarkCategory, dataTagId));
   baseResponse.setStatus("SUCCESS");
   Response response = FiinfraResponseBuilder.getSuccessResponse(baseResponse, null);
   return response;
 }
예제 #24
0
 @POST
 @Consumes(MediaType.APPLICATION_JSON)
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/insertOrUpdateBisunessValuation/{user}/{token}")
 public Response insertOrUpdateBisunessValuation(
     BusinessValuationData businessValuationData,
     @Context HttpServletRequest request,
     @PathParam("token") String token,
     @PathParam("user") String name)
     throws Exception {
   String buId = request.getHeader("buId");
   String dataXml = FiinfraUtility.getBusinessDataXML(businessValuationData);
   int partyId = businessValuationData.getPartyId();
   int recordCount =
       partnerService.insertOrUpdateBisunessValuation(
           dataXml, partyId, businessValuationData.getCreatedBy(), Integer.parseInt(buId));
   BaseResponse<Integer> br = new BaseResponse<>();
   br.setResponseObject(recordCount);
   response = FiinfraResponseBuilder.getSuccessResponse(br, null);
   return response;
 }
예제 #25
0
  @GET
  @Produces(MediaType.APPLICATION_JSON)
  @Path("/getchartDataList/{user}/{token}")
  public Response getchartDataList(
      @QueryParam("partyId") int partyId,
      @QueryParam("buId") int buId,
      @QueryParam("chartType") String chartType,
      @QueryParam("nodeId") int nodeId,
      @PathParam("token") String token,
      @PathParam("user") String name)
      throws JsonGenerationException, JsonMappingException, IOException {
    logger.debug("partyId:---" + partyId);

    List<ChartData> lstchartData =
        partnerService.getChartDataList(partyId, buId, chartType, nodeId);

    BaseResponse<ChartData> br = new BaseResponse<>();
    br.setResponseListObject(lstchartData);
    response = FiinfraResponseBuilder.getSuccessResponse(br, null);
    return response;
  }
예제 #26
0
 @GET
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/updatePartnerAutoPlanConfiguration/{user}/{token}")
 public Response updatePartnerAutoPlanConfiguration(
     @Context HttpServletRequest request,
     @QueryParam("isAutoPlanEnabled") int isAutoPlanEnabled,
     @QueryParam("partyId") int partyId,
     @QueryParam("lastModifiedBy") int lastModifiedBy,
     @PathParam("token") String token,
     @PathParam("user") String name)
     throws JsonGenerationException, JsonMappingException, IOException {
   logger.debug("partyId:---" + partyId);
   String buId = request.getHeader("buId");
   Integer recordCount =
       partnerService.updatePartnerAutoPlanConfiguration(
           partyId, lastModifiedBy, isAutoPlanEnabled, Integer.parseInt(buId));
   BaseResponse<Integer> br = new BaseResponse<>();
   br.setResponseObject(recordCount);
   response = FiinfraResponseBuilder.getSuccessResponse(br, null);
   return response;
 }
예제 #27
0
 @POST
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/saveRtaFilePasswords/{user}/{token}")
 public Response saveRtaFilePasswords(
     @Context HttpServletRequest request,
     @PathParam("token") String token,
     @PathParam("user") String user,
     @QueryParam("partyId") Integer partyId,
     @QueryParam("userId") Integer userId,
     @RequestBody List<String> passwords)
     throws IOException {
   // System.out.println("In APP Calling SavePartner");
   String buId = request.getHeader("buId");
   BaseResponse<Boolean> br = new BaseResponse<Boolean>();
   logger.info(br);
   br.setResponseObject(
       partnerService.saveRtaFilePasswords(partyId, passwords, userId, Integer.parseInt(buId)));
   // Response  response=partnerService.addPartner(partner);
   Response response = FiinfraResponseBuilder.getSuccessResponse(br, null);
   return response;
 }
예제 #28
0
 @GET
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/getHeirarchyDataForVP/{user}/{token}")
 public Response getHeirarchyDataForVP(
     @Context HttpServletRequest request,
     @QueryParam("partyId") int partyId,
     @QueryParam("currentNodeId") int currentNodeId,
     @QueryParam("level") int level,
     @PathParam("token") String token,
     @PathParam("user") String name)
     throws JsonGenerationException, JsonMappingException, IOException {
   String buId = request.getHeader("buId");
   logger.debug("partyId:---" + partyId);
   logger.debug("currentNodeId:---" + currentNodeId);
   logger.debug("level:---" + level);
   HeirarchyData heirarchyData =
       partnerService.getHeirarchyDataForVP(partyId, currentNodeId, level, Integer.parseInt(buId));
   BaseResponse<HeirarchyData> br = new BaseResponse<>();
   br.setResponseObject(heirarchyData);
   response = FiinfraResponseBuilder.getSuccessResponse(br, null);
   return response;
 }
예제 #29
0
 @GET
 @Produces(MediaType.APPLICATION_JSON)
 @Path("/getPurchaseProductsURLs/{username}/{token}")
 public Response getPurchaseProductsURLs(
     @Context HttpServletRequest request,
     @PathParam("username") String username,
     @PathParam("token") String token,
     @QueryParam("partnerPartyId") Integer partnerPartyId,
     @QueryParam("executionId") Integer executionId,
     @QueryParam("productsId") String productsId,
     @QueryParam("settingTypeID") Integer settingTypeID) {
   String buId = request.getHeader("buId");
   BaseResponse<ProductPurchaseURLs> br = new BaseResponse<ProductPurchaseURLs>();
   br.setResponseListObject(
       partnerService.getProductPurchaseURLs(
           partnerPartyId,
           executionId,
           settingTypeID,
           productsId.replace("%2C", ","),
           Integer.parseInt(buId)));
   response = FiinfraResponseBuilder.getSuccessResponse(br, null);
   return response;
 }
예제 #30
0
  @POST
  @Consumes(MediaType.APPLICATION_JSON)
  @Produces(MediaType.APPLICATION_JSON)
  @Path(value = "/getRecommandedProductForQuickAdviceTool")
  public Response getRecommandedProductForQuickAdviceTool(
      @Context HttpServletRequest request, AutoPlanData autoPlanData) {
    String buId = request.getHeader("buId");
    String dataXML = "<Root>";
    dataXML += "<Title>";
    if (autoPlanData.getTitle() != null) {
      dataXML += autoPlanData.getTitle();
    } else {
      dataXML += "0";
    }
    dataXML += "</Title>";

    dataXML += "<FirstName>";
    if (autoPlanData.getFirstname() != null) {
      dataXML += autoPlanData.getFirstname();
    } else {
      dataXML += "";
    }
    dataXML += "</FirstName>";

    dataXML += "<LastName>";
    if (autoPlanData.getLastname() != null) {
      dataXML += autoPlanData.getLastname();
    } else {
      dataXML += "";
    }
    dataXML += "</LastName>";

    dataXML += "<ResStatus>";
    if (autoPlanData.getResidentialStatus() != null) {
      dataXML += autoPlanData.getResidentialStatus();
    } else {
      dataXML += "";
    }
    dataXML += "</ResStatus>";

    dataXML += "<DOB>";
    if (autoPlanData.getDob() != null) {
      dataXML += autoPlanData.getDob();
    } else {
      dataXML += "";
    }
    dataXML += "</DOB>";

    dataXML += "<MaritalStatus>";
    if (autoPlanData.getMaritalStatus() != null) {
      dataXML += autoPlanData.getMaritalStatus();
    } else {
      dataXML += "";
    }
    dataXML += "</MaritalStatus>";

    dataXML += "<Occupation>";
    if (autoPlanData.getOccupation() != null) {
      dataXML += autoPlanData.getOccupation();
    } else {
      dataXML += "";
    }
    dataXML += "</Occupation>";

    dataXML += "<ContactNo>";
    if (autoPlanData.getContactNo() != null) {
      dataXML += autoPlanData.getContactNo();
    } else {
      dataXML += "";
    }
    dataXML += "</ContactNo>";

    dataXML += "<EmailId>";
    if (autoPlanData.getEmailId() != null) {
      dataXML += autoPlanData.getEmailId();
    } else {
      dataXML += "";
    }
    dataXML += "</EmailId>";

    dataXML += "<RiskProfileId>";
    if (autoPlanData.getRiskProfileId() != null) {
      dataXML += autoPlanData.getRiskProfileId();
    } else {
      dataXML += "";
    }
    dataXML += "</RiskProfileId>";

    dataXML += "<Will>";
    if (autoPlanData.getWill() != null) {
      dataXML += autoPlanData.getWill();
    } else {
      dataXML += "";
    }
    dataXML += "</Will>";

    dataXML += "<Gender>";
    if (autoPlanData.getGender() != null) {
      dataXML += autoPlanData.getGender();
    } else {
      dataXML += "";
    }
    dataXML += "</Gender>";

    dataXML += "<EMI>";
    if (autoPlanData.getEMI() != null) {
      dataXML += autoPlanData.getEMI();
    } else {
      dataXML += "";
    }
    dataXML += "</EMI>";

    dataXML += "<MonthlyInvesment>";
    if (autoPlanData.getMonthlyInvestment() != null) {
      dataXML += autoPlanData.getMonthlyInvestment();
    } else {
      dataXML += "";
    }
    dataXML += "</MonthlyInvesment>";

    dataXML += "</Root>";

    autoPlanData.setDataXML(dataXML);

    String goalXML = "<Root>";
    for (int i = 0; i < autoPlanData.getGoalDatas().size(); i++) {
      goalXML += "<Goal>";

      goalXML += "<GoalDescription>";
      goalXML += autoPlanData.getGoalDatas().get(i).getGoalName();
      goalXML += "</GoalDescription>";

      goalXML += "<GoalEndYear>";
      goalXML += autoPlanData.getGoalDatas().get(i).getGoalEndYear();
      goalXML += "</GoalEndYear>";

      goalXML += "<GoalAmountPv>";
      goalXML += autoPlanData.getGoalDatas().get(i).getGoalAmountPv();
      goalXML += "</GoalAmountPv>";

      goalXML += "<GoalTypeId>";
      goalXML += autoPlanData.getGoalDatas().get(i).getGoalTypeId();
      goalXML += "</GoalTypeId>";

      goalXML += "<GoalFamilyPartyID>";
      goalXML += autoPlanData.getGoalDatas().get(i).getGoalFamilyPartyId();
      goalXML += "</GoalFamilyPartyID>";

      goalXML += "<GoalStartYear>";
      goalXML += autoPlanData.getGoalDatas().get(i).getGoalStartYear();
      goalXML += "</GoalStartYear>";

      goalXML += "<IsLoan>";
      goalXML += autoPlanData.getGoalDatas().get(i).getIsLoan();
      goalXML += "</IsLoan>";

      goalXML += "<LoanAmount>";
      goalXML += autoPlanData.getGoalDatas().get(i).getLoanAmount();
      goalXML += "</LoanAmount>";

      goalXML += "<LoanDownPayment>";
      goalXML += autoPlanData.getGoalDatas().get(i).getLoanDownPayment();
      goalXML += "</LoanDownPayment>";

      goalXML += "<LoanInterestPercentage>";
      goalXML += autoPlanData.getGoalDatas().get(i).getLoanInterestPercentage();
      goalXML += "</LoanInterestPercentage>";

      goalXML += "<LoanDurationYears>";
      goalXML += autoPlanData.getGoalDatas().get(i).getLoanDurationYears();
      goalXML += "</LoanDurationYears>";

      goalXML += "<GoalName>";
      goalXML += autoPlanData.getGoalDatas().get(i).getGoalName();
      goalXML += "</GoalName>";

      goalXML += "</Goal>";
    }

    goalXML += "</Root>";
    autoPlanData.setGoalXML(goalXML);

    String partyttributeDataXML = "<Root>";
    for (int i = 0; i < autoPlanData.getPartyAttributeDatas().size(); i++) {
      partyttributeDataXML += "<Data>";

      partyttributeDataXML += "<AttributeCodeId>";
      partyttributeDataXML += autoPlanData.getPartyAttributeDatas().get(i).getAttributeCodeId();
      partyttributeDataXML += "</AttributeCodeId>";

      partyttributeDataXML += "<AttributeValue>";
      partyttributeDataXML += autoPlanData.getPartyAttributeDatas().get(i).getAttributeValue();
      partyttributeDataXML += "</AttributeValue>";

      partyttributeDataXML += "<AttributeReferenceValue>";
      partyttributeDataXML +=
          autoPlanData.getPartyAttributeDatas().get(i).getAttributereferenceValue();
      partyttributeDataXML += "</AttributeReferenceValue>";

      partyttributeDataXML += "</Data>";
    }

    partyttributeDataXML += "</Root>";

    String familyMemberDataXML = "<Root>";
    familyMemberDataXML += "</Root>";

    autoPlanData.setFamilyMemberDataXML(familyMemberDataXML);

    autoPlanData.setLastModifiedBy(1);
    // BaseResponse<Integer> baseResponse = new BaseResponse<>();
    int partyid = partnerService.updateQuickDCDetails(autoPlanData, Integer.parseInt(buId));

    BaseResponse<RecommandedGoalProdResult> br = new BaseResponse<RecommandedGoalProdResult>();
    br.setResponseListObject(
        commonProdRecommService.getRecommandedProductForQuickAdvice(
            partyid, Integer.parseInt(buId)));
    response = FiinfraResponseBuilder.getSuccessResponse(br, null);
    return response;
  }