Commit 8e4e0a8f authored by Quxl's avatar Quxl

x

parent 1d496425
...@@ -92,6 +92,6 @@ public interface ReviewService { ...@@ -92,6 +92,6 @@ public interface ReviewService {
void deleteDoubtfulById(Integer id); void deleteDoubtfulById(Integer id);
Fc_review_record queryReviewRecordById(Integer record_id); Map<String, Object> queryReviewRecordMapById(Integer record_id);
} }
\ No newline at end of file
...@@ -574,8 +574,8 @@ public class ReviewServiceImpl implements ReviewService { ...@@ -574,8 +574,8 @@ public class ReviewServiceImpl implements ReviewService {
} }
@Override @Override
public Fc_review_record queryReviewRecordById(Integer record_id) { public Map<String, Object> queryReviewRecordMapById(Integer record_id) {
return jdbcTemplate.queryForBean("select rr.*, r.enroll_type_id from fc_review_record rr left join fc_review r on r.id = rr.review_id where rr.id = ?", Fc_review_record.class, record_id); return jdbcTemplate.queryForMap("select rr.*, r.enroll_type_id from fc_review_record rr left join fc_review r on r.id = rr.review_id where rr.id = ?", Fc_review_record.class, record_id);
} }
} }
\ No newline at end of file
...@@ -11,6 +11,7 @@ import org.springframework.web.bind.annotation.PostMapping; ...@@ -11,6 +11,7 @@ import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody; import org.springframework.web.bind.annotation.ResponseBody;
import com.egolm.common.Util;
import com.egolm.common.bean.Rjx; import com.egolm.common.bean.Rjx;
import com.egolm.common.jdbc.Page; import com.egolm.common.jdbc.Page;
import com.egolm.film.api.service.AdminTokenService; import com.egolm.film.api.service.AdminTokenService;
...@@ -156,7 +157,8 @@ public class AdminReviewController { ...@@ -156,7 +157,8 @@ public class AdminReviewController {
@ApiImplicitParam(paramType = "query", dataType = "double", required = false, allowMultiple=true, name = "ext_score", value="奖项得分"), @ApiImplicitParam(paramType = "query", dataType = "double", required = false, allowMultiple=true, name = "ext_score", value="奖项得分"),
}) })
public Object saveReviewRecord(Integer record_id, Integer review_state, Double review_score, String review_text, String review_text_1, String review_text_2, String review_text_3, String review_text_4, String[] ext_title, Double[] ext_score) { public Object saveReviewRecord(Integer record_id, Integer review_state, Double review_score, String review_text, String review_text_1, String review_text_2, String review_text_3, String review_text_4, String[] ext_title, Double[] ext_score) {
Fc_review_record ru = reviewService.queryReviewRecordById(record_id); Map<String, Object> recordMap = reviewService.queryReviewRecordMapById(record_id);
Fc_review_record ru = Util.mapTo(recordMap, Fc_review_record.class);
ru.setReview_score(review_score); ru.setReview_score(review_score);
ru.setReview_state(review_state); ru.setReview_state(review_state);
ru.setReview_text(review_text); ru.setReview_text(review_text);
...@@ -214,9 +216,10 @@ public class AdminReviewController { ...@@ -214,9 +216,10 @@ public class AdminReviewController {
@ApiImplicitParam(paramType = "query", dataType = "int", required = false, name = "record_id", value="审片记录ID"), @ApiImplicitParam(paramType = "query", dataType = "int", required = false, name = "record_id", value="审片记录ID"),
}) })
public Object getReviewRecord(Integer record_id) { public Object getReviewRecord(Integer record_id) {
Fc_review_record record = reviewService.queryReviewRecordById(record_id); Map<String, Object> recordMap = reviewService.queryReviewRecordMapById(record_id);
Fc_review_record record = Util.mapTo(recordMap, Fc_review_record.class);
List<Fc_review_record_ext> extList = reviewService.queryReviewRecordExtList(record.getId()); List<Fc_review_record_ext> extList = reviewService.queryReviewRecordExtList(record.getId());
return Rjx.jsonOk().setData(record).set("exts", extList); return Rjx.jsonOk().setData(recordMap).set("exts", extList);
} }
} }
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