Commit f92ee338 authored by Quxl's avatar Quxl

x

parent 5620df01
package com.egolm.film.api.service;
import java.util.Date;
import java.util.List;
import java.util.Map;
import com.egolm.common.jdbc.Page;
public interface ReviewService {
Object queryDoubtfulList();
List<Map<String, Object>> queryReviewList(boolean is_review, Integer user_id, Date push_date, Integer film_type_id, Integer enroll_type_id, String keyword, Page page);
}
}
\ No newline at end of file
package com.egolm.film.api.service;
import java.util.Date;
import java.util.List;
import java.util.Map;
import com.egolm.common.jdbc.Page;
public interface UserReviewService {
List<Map<String, Object>> queryReviewList(boolean is_review, Integer user_id, Date push_date, Integer film_type_id, Integer enroll_type_id, String keyword, Page page);
}
\ No newline at end of file
package com.egolm.film.api.service.impl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.egolm.common.jdbc.JdbcTemplate;
import com.egolm.film.api.service.ReviewService;
@Service
public class ReviewServiceImpl implements ReviewService {
@Autowired
JdbcTemplate jdbcTemplate;
@Override
public Object queryDoubtfulList() {
return jdbcTemplate.queryForList("select * from enum_doubtful");
}
}
......@@ -11,11 +11,11 @@ import com.egolm.common.DateUtil;
import com.egolm.common.StringUtil;
import com.egolm.common.jdbc.JdbcTemplate;
import com.egolm.common.jdbc.Page;
import com.egolm.film.api.service.UserReviewService;
import com.egolm.film.api.service.ReviewService;
import com.egolm.film.util.SqlWhere;
@Service
public class UserReviewServiceImpl implements UserReviewService {
public class UserReviewServiceImpl implements ReviewService {
@Autowired
JdbcTemplate jdbcTemplate;
......@@ -54,6 +54,11 @@ public class UserReviewServiceImpl implements UserReviewService {
+ StringUtil.join(" and ", " and ", "", "", where.getStringList());
return jdbcTemplate.limit(sql, page, where.getObjectList());
}
@Override
public Object queryDoubtfulList() {
return jdbcTemplate.queryForList("select * from enum_doubtful");
}
}
......@@ -5,6 +5,7 @@ import java.util.List;
import java.util.Map;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.format.annotation.DateTimeFormat;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
......@@ -12,7 +13,7 @@ import org.springframework.web.bind.annotation.ResponseBody;
import com.egolm.common.bean.Rjx;
import com.egolm.common.jdbc.Page;
import com.egolm.film.api.service.UserReviewService;
import com.egolm.film.api.service.ReviewService;
import com.egolm.film.api.service.UserTokenService;
import com.egolm.film.model.LoginToken;
......@@ -30,7 +31,7 @@ public class UserReviewController {
private UserTokenService tokenService;
@Autowired
private UserReviewService service;
private ReviewService service;
@ResponseBody
@PostMapping("review_list")
......@@ -54,4 +55,17 @@ public class UserReviewController {
return Rjx.jsonOk().setData(list).setPage(page);
}
@ResponseBody
@PostMapping("doubtful_save")
@ApiOperation("保存疑点记录")
@ApiImplicitParams({
@ApiImplicitParam(paramType = "query", dataType = "int", required = false, name = "film_id", value="影片ID"),
@ApiImplicitParam(paramType = "query", dataType = "int", required = false, name = "enroll_type_id", value="申报奖项ID"),
@ApiImplicitParam(paramType = "query", dataType = "int", required = false, name = "doubtful_type_id", value="疑点类型ID"),
@ApiImplicitParam(paramType = "query", dataType = "string", required = false, name = "doubtful_text", value="疑点描述"),
@ApiImplicitParam(paramType = "query", dataType = "date", required = false, name = "play_time", value="播放时间{yyyy-MM-dd HH:mm:ss}"),
})
public Object saveDoubtful(Integer film_id, Integer enroll_type_id, Integer doubtful_type_id, String doubtful_text, @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")Date play_time) {
return Rjx.jsonOk();
}
}
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