Authored by qianjun

Merge branch 'dev5.8.1' into test5.8.1

... ... @@ -30,7 +30,8 @@ public class QuestionController {
@RequestParam("startTime") int startTime,
@RequestParam("sourceType") String sourceType,
@RequestParam("endTime") int endTime, @RequestParam("frontAnswers") String frontAnswers) {
logger.info("Enter submitQuestions rest.");
logger.info("Enter submitQuestions rest. questionId={}, uid={}, startTime={}, sourceType={}, endTime={} and frontAnswers={}" ,
id, uid, startTime, sourceType, endTime, frontAnswers);
SubmitQuestionReqBO submitQuestionReqBO=new SubmitQuestionReqBO();
submitQuestionReqBO.setId(id);
... ... @@ -60,8 +61,6 @@ public class QuestionController {
int code = Integer.parseInt(result.get("code").toString());
String message = result.get("message").toString();
Object data = result.get("data");
// String jsonpStr = "callback(" + data + ")";
return new ApiResponse.ApiResponseBuilder().code(code).message(message).data(data).build();
}
... ... @@ -74,8 +73,6 @@ public class QuestionController {
int code = Integer.parseInt(result.get("code").toString());
String message = result.get("message").toString();
Object data = result.get("data");
// String jsonpStr = "callback(" + data + ")";
return new ApiResponse.ApiResponseBuilder().code(code).message(message).data(data).build();
}
... ...
... ... @@ -28,7 +28,7 @@ public interface IQuestionService {
/**
* 问卷验证接口
* @return
*
*/
JSONObject questionValidate(ValidateQuestionReqBO reqBO);
}
... ...
package com.yoho.activity.service.impl;
import com.yoho.activity.service.IQuestionService;
import com.alibaba.fastjson.JSONObject;
import com.yoho.activity.service.IQuestionService;
import com.yoho.core.rest.client.ServiceCaller;
import com.yoho.error.ServiceError;
import com.yoho.error.exception.ServiceException;
import com.yoho.service.model.activity.crm.request.*;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
... ... @@ -70,11 +69,7 @@ public class QuestionServiceImpl implements IQuestionService {
@Override
public JSONObject getQuestionList(QuestionListReqBO reqBO) {
logger.info("Enter getQuestionList impl. reqBO is {}", reqBO);
// if (1 > reqBO.getUid()){
// throw new ServiceException(ServiceError.USER_ID_ERROR);
// }
String url = crmDns + "/FrontQuestionnaireController/getList4Questionnaire.do";
JSONObject result = serviceCaller.post("crm.questionList", url, reqBO, JSONObject.class, null).get(10);
... ...