Commit ed6578c3ec8a999a6d3def8260b6c380960ddde4

Authored by 王言钊
1 parent 50d2705f

修改查询按钮名称以及拼接判断查询条件

src/main/java/com/cnlive/shenhe/serviceImpl/ChannelServiceImpl.java
... ... @@ -69,10 +69,10 @@ public class ChannelServiceImpl {
69 69 } else {
70 70 example.setOrderByClause("created_at desc");
71 71 }
72   - if (CommonUtils.isNotNull(channelDTO.getStart_date())) {
  72 + if (CommonUtils.isNotEmpty(channelDTO.getStart_date())) {
73 73 criteria.andGreaterThanOrEqualTo("created_at", channelDTO.getStart_date());
74 74 }
75   - if (CommonUtils.isNotNull(channelDTO.getEnd_date())) {
  75 + if (CommonUtils.isNotEmpty(channelDTO.getEnd_date())) {
76 76 criteria.andLessThanOrEqualTo("created_at", channelDTO.getEnd_date());
77 77 }
78 78 if (CommonUtils.isNotEmpty(channelDTO.getChannel_name())) {
... ...
src/main/java/com/cnlive/shenhe/serviceImpl/CommentsServiceImpl.java
... ... @@ -39,7 +39,7 @@ public class CommentsServiceImpl {
39 39 ShyUsersMapper shyUsersMapper;
40 40 @Autowired
41 41 AuditPass Pass;
42   -
  42 +
43 43 @Autowired
44 44 SitesServiceImpl sitesService;
45 45  
... ... @@ -114,7 +114,7 @@ public class CommentsServiceImpl {
114 114 }
115 115 if (CommonUtils.isNotNull(commentsDTO.getReceive())) {
116 116 criteria.andEqualTo("receive", commentsDTO.getReceive());
117   - if (commentsDTO.getReceive().equals(CommonConst.RECEIVE_AFTER) ) {
  117 + if (commentsDTO.getReceive().equals(CommonConst.RECEIVE_AFTER)) {
118 118 criteria.andEqualTo("receive_user_id", commentsDTO.getUserId());
119 119 }
120 120 }
... ... @@ -142,87 +142,88 @@ public class CommentsServiceImpl {
142 142 PageInfo<ShyComments> pageInfo = new PageInfo<>(commentsList);
143 143 return pageInfo;
144 144 }
  145 +
145 146 public PageInfo<ShyComments> getPageExcel(CommentsDTO commentsDTO) {
146   - Example example = new Example(ShyComments.class);
147   - Example.Criteria criteria = example.createCriteria();
148   - if (CommonUtils.isNotEmpty(commentsDTO.getOrderByClause())) {
149   - example.setOrderByClause(commentsDTO.getOrderByClause());
150   - } else {
151   - example.setOrderByClause("comment_time desc");
152   - }
153   - if (CommonUtils.isNotNull(commentsDTO.getStart_date()) && CommonUtils.isNotNull(commentsDTO.getEnd_date())) {
154   - criteria.andGreaterThanOrEqualTo("comment_time", commentsDTO.getStart_date());
155   - criteria.andLessThanOrEqualTo("comment_time", commentsDTO.getEnd_date());
156   - }
157   - if (CommonUtils.isNotEmpty(commentsDTO.getContent())) {
158   - criteria.andLike("comment_content", "%" + commentsDTO.getContent() + "%");
159   - }
160   - if (CommonUtils.isNotEmpty(commentsDTO.getUpdater())) {
161   - criteria.andEqualTo("updater", commentsDTO.getUpdater());
162   - }
163   - if (CommonUtils.isNotNull(commentsDTO.getSpid())) {
164   - criteria.andEqualTo("spid", commentsDTO.getSpid());
165   - }
166   - if (CommonUtils.isNotNull(commentsDTO.getIs_hot())) {
167   - criteria.andEqualTo("is_hot", commentsDTO.getIs_hot());
168   - }
169   - if (CommonUtils.isNotNull(commentsDTO.getType())&&commentsDTO.getType()=="0") {
170   - criteria.andEqualTo("type", CommonConst.CATEGORY_TOPIC);
171   - }else if(CommonUtils.isNotNull(commentsDTO.getType())&&commentsDTO.getType()=="1"){
172   - criteria.andIsNull("type");
173   - }
174   - if (CommonUtils.isNotEmpty(commentsDTO.getActivity_id())) {
175   - criteria.andLike("activity_id", "%" + commentsDTO.getActivity_id() + "%");
176   - }
177   - if (CommonUtils.isNotNull(commentsDTO.getReceive())) {
178   - criteria.andEqualTo("receive", commentsDTO.getReceive());
179   - if (commentsDTO.getReceive().equals(CommonConst.RECEIVE_AFTER)) {
180   - criteria.andEqualTo("receive_user_id", commentsDTO.getUserId());
181   - }
182   - }
183   -
184   -// if (CommonUtils.isNotEmpty(states)) {
185   -// Example.Criteria criteria1 = example.createCriteria();
186   -// String[] stas = states.split(",");
187   -// for (String s : stas) {
188   -// criteria1.orEqualTo("state", Integer.parseInt(s));
189   -// }
190   -// example.and(criteria1);
191   -// }
192   -
193   - if (CommonUtils.isNotNull(commentsDTO.getState()) && commentsDTO.getState() != 3) {
194   - criteria.andEqualTo("state", commentsDTO.getState());
195   - } else if (CommonUtils.isNotNull(commentsDTO.getState()) && commentsDTO.getState() == 3) {
196   - Example.Criteria criteria1 = example.createCriteria();
197   - criteria1.orEqualTo("state", 1);
198   - criteria1.orEqualTo("state", 2);
199   - example.and(criteria1);
200   - }
201   -
202   - List<ShyComments> commentsList = shyCommentsMapper.selectByExample(example);
203   - PageInfo<ShyComments> pageInfo = new PageInfo<>(commentsList);
204   - return pageInfo;
  147 + Example example = new Example(ShyComments.class);
  148 + Example.Criteria criteria = example.createCriteria();
  149 + if (CommonUtils.isNotEmpty(commentsDTO.getOrderByClause())) {
  150 + example.setOrderByClause(commentsDTO.getOrderByClause());
  151 + } else {
  152 + example.setOrderByClause("comment_time desc");
  153 + }
  154 + if (CommonUtils.isNotEmpty(commentsDTO.getStart_date()) && CommonUtils.isNotEmpty(commentsDTO.getEnd_date())) {
  155 + criteria.andGreaterThanOrEqualTo("comment_time", commentsDTO.getStart_date());
  156 + criteria.andLessThanOrEqualTo("comment_time", commentsDTO.getEnd_date());
  157 + }
  158 + if (CommonUtils.isNotEmpty(commentsDTO.getContent())) {
  159 + criteria.andLike("comment_content", "%" + commentsDTO.getContent() + "%");
  160 + }
  161 + if (CommonUtils.isNotEmpty(commentsDTO.getUpdater())) {
  162 + criteria.andEqualTo("updater", commentsDTO.getUpdater());
  163 + }
  164 + if (CommonUtils.isNotNull(commentsDTO.getSpid())) {
  165 + criteria.andEqualTo("spid", commentsDTO.getSpid());
  166 + }
  167 + if (CommonUtils.isNotNull(commentsDTO.getIs_hot())) {
  168 + criteria.andEqualTo("is_hot", commentsDTO.getIs_hot());
  169 + }
  170 + if (CommonUtils.isNotEmpty(commentsDTO.getType()) && commentsDTO.getType()=="0") {
  171 + criteria.andEqualTo("type", CommonConst.CATEGORY_TOPIC);
  172 + } else if (CommonUtils.isNotEmpty(commentsDTO.getType()) && commentsDTO.getType()=="1") {
  173 + criteria.andIsNull("type");
  174 + }
  175 + if (CommonUtils.isNotEmpty(commentsDTO.getActivity_id())) {
  176 + criteria.andLike("activity_id", "%" + commentsDTO.getActivity_id() + "%");
  177 + }
  178 + if (CommonUtils.isNotNull(commentsDTO.getReceive())) {
  179 + criteria.andEqualTo("receive", commentsDTO.getReceive());
  180 + if (commentsDTO.getReceive().equals(CommonConst.RECEIVE_AFTER)) {
  181 + criteria.andEqualTo("receive_user_id", commentsDTO.getUserId());
  182 + }
  183 + }
  184 +
  185 + //if (CommonUtils.isNotEmpty(String.valueOf(commentsDTO.getState()))) {
  186 + // Example.Criteria criteria1 = example.createCriteria();
  187 + // String[] stas = String.valueOf(commentsDTO.getState()).split(",");
  188 + // for (String s : stas) {
  189 + // criteria1.orEqualTo("state", Integer.parseInt(s));
  190 + // }
  191 + // example.and(criteria1);
  192 + //}
  193 +
  194 + if (CommonUtils.isNotNull(commentsDTO.getState()) && commentsDTO.getState() != 3) {
  195 + criteria.andEqualTo("state", commentsDTO.getState());
  196 + } else if (CommonUtils.isNotNull(commentsDTO.getState()) && commentsDTO.getState() == 3) {
  197 + Example.Criteria criteria1 = example.createCriteria();
  198 + criteria1.orEqualTo("state", 1);
  199 + criteria1.orEqualTo("state", 2);
  200 + example.and(criteria1);
  201 + }
  202 +
  203 + List<ShyComments> commentsList = shyCommentsMapper.selectByExample(example);
  204 + PageInfo<ShyComments> pageInfo = new PageInfo<>(commentsList);
  205 + return pageInfo;
205 206 }
206 207  
207 208 public ShyComments getDetailsComment(Integer id) {
208 209 ShyComments comment = shyCommentsMapper.selectByPrimaryKey(id);
209 210 if (!comment.getState().equals(CommonConst.AUDIT_INTT)) {
210   - String updater = CommonUtils.isEmpty(comment.getUpdater()) || "null".equals(comment.getUpdater())? "白名单":comment.getUpdater();
  211 + String updater = CommonUtils.isEmpty(comment.getUpdater()) || "null".equals(comment.getUpdater()) ? "白名单" : comment.getUpdater();
211 212 String auditor_id = comment.getAuditor_id();
212 213 if (CommonUtils.isNotEmpty(auditor_id)) {
213 214 ShyUsers user = new ShyUsers();
214 215 user.setUser_id(auditor_id);
215 216 user = shyUsersMapper.selectOne(user);
216   - String email = CommonUtils.isEmpty(user.getEmail())|| "null".equals(user.getEmail()) ? "" : user.getEmail();
  217 + String email = CommonUtils.isEmpty(user.getEmail()) || "null".equals(user.getEmail()) ? "" : user.getEmail();
217 218 String userName = CommonUtils.isEmpty(user.getUsername()) ? email : user.getUsername();
218   - updater = userName ;
  219 + updater = userName;
219 220 }
220 221 comment.setUpdater(updater);
221 222 }
222 223 return comment;
223 224 }
224 225  
225   - public boolean updateState(String ids, Integer state, String userId,String updater,String msg) {
  226 + public boolean updateState(String ids, Integer state, String userId, String updater, String msg) {
226 227 boolean success = true;
227 228 String[] commentIds = ids.split(",");
228 229 for (String commentId : commentIds) {
... ... @@ -254,12 +255,12 @@ public class CommentsServiceImpl {
254 255 }
255 256 comment.setState(state);
256 257 comment.setMsg(msg);
257   - if(CommonUtils.isEmpty(userId)){
258   - comment.setUpdater(updater);
259   - }else{
260   - comment.setAuditor_id(userId);
261   - comment.setReceive(1);//已领取
262   - comment.setReceive_user_id(userId);
  258 + if (CommonUtils.isEmpty(userId)) {
  259 + comment.setUpdater(updater);
  260 + } else {
  261 + comment.setAuditor_id(userId);
  262 + comment.setReceive(1);//已领取
  263 + comment.setReceive_user_id(userId);
263 264 }
264 265 int i = shyCommentsMapper.updateByPrimaryKeySelective(comment);
265 266 if (i != 1) {
... ... @@ -321,30 +322,33 @@ public class CommentsServiceImpl {
321 322 }
322 323 return n;
323 324 }
  325 +
324 326 public ShyComments selectByPrimaryKey(Integer id) {
325 327 ShyComments shyComments = shyCommentsMapper.selectByPrimaryKey(id);
326 328 return shyComments;
327 329 }
  330 +
328 331 public int updateByPrimaryKeySelective(ShyComments comments) {
329 332 return shyCommentsMapper.updateByPrimaryKeySelective(comments);
330 333 }
331   -
  334 +
332 335 /**
333 336 * 获得审核类型
  337 + *
334 338 * @param shyComments
335 339 */
336   - public void getShenheType(ShyComments shyComments){
337   -
338   - //获取评论免审sp
  340 + public void getShenheType(ShyComments shyComments) {
  341 +
  342 + //获取评论免审sp
339 343 List<Integer> sites = sitesService.getBusinessList(CommonConst.BUSINESS_COMMENT);
340 344 //初始化一个审核状态
341   - Integer shenheType=3;//审核类型,1:免审,2:机审,3:人工审
  345 + Integer shenheType = 3;//审核类型,1:免审,2:机审,3:人工审
342 346 //如果当前sp是免审sp
343   - if(sites.contains(shyComments.getSpid())){
344   - shenheType=1;//免审
  347 + if (sites.contains(shyComments.getSpid())) {
  348 + shenheType = 1;//免审
345 349 }
346 350 shyComments.setShenhe_type(shenheType);
347   - }
  351 + }
348 352  
349 353 }
350 354  
... ...
src/main/java/com/cnlive/shenhe/serviceImpl/TopicServiceImpl.java
... ... @@ -50,21 +50,21 @@ public class TopicServiceImpl {
50 50 VideosServiceImpl videosService;
51 51 @Autowired
52 52 VideofilterServiceImpl videofilterServiceImpl;
53   -
  53 +
54 54 @Value("${spring.localhost.url}")
55 55 String localhost_url;
56 56  
57 57 public ShyTopic getShyTopic(ShyTopic shyTopic) {
58 58 List<ShyTopic> shyTopicList = shyTopicMapper.select(shyTopic);
59   - if(CommonUtils.isNotNull(shyTopicList)&&shyTopicList.size()>0){
60   - return shyTopicList.get(0);
  59 + if (CommonUtils.isNotNull(shyTopicList) && shyTopicList.size() > 0) {
  60 + return shyTopicList.get(0);
61 61 }
62 62 return new ShyTopic();
63 63 }
64 64  
65 65 //**************************************
66 66 public List<ShyTopic> findshyTopic(ShyTopic shyTopic) {
67   -
  67 +
68 68 return shyTopicMapper.selectByRowBounds(shyTopic, new RowBounds(0, 100));
69 69 }
70 70  
... ... @@ -101,11 +101,11 @@ public class TopicServiceImpl {
101 101 } else {
102 102 example.setOrderByClause("create_date desc");
103 103 }
104   - if (CommonUtils.isNotNull(topicDTO.getStart_date()) ) {
  104 + if (CommonUtils.isNotEmpty(topicDTO.getStart_date())) {
105 105 criteria.andGreaterThanOrEqualTo("create_date", topicDTO.getStart_date());
106 106 }
107   - if ( CommonUtils.isNotNull(topicDTO.getEnd_date())) {
108   - criteria.andLessThanOrEqualTo("create_date", topicDTO.getEnd_date());
  107 + if (CommonUtils.isNotEmpty(topicDTO.getEnd_date())) {
  108 + criteria.andLessThanOrEqualTo("create_date", topicDTO.getEnd_date());
109 109 }
110 110 if (CommonUtils.isNotEmpty(topicDTO.getTopic_name())) {
111 111 criteria.andLike("title", "%" + topicDTO.getTopic_name() + "%");
... ... @@ -114,24 +114,26 @@ public class TopicServiceImpl {
114 114 criteria.andEqualTo("updater", topicDTO.getUpdater());
115 115 }
116 116 if (CommonUtils.isNotEmpty(topicDTO.getTopic_tag())) {
117   - criteria.andEqualTo("topic_tag", topicDTO.getTopic_tag());
  117 + criteria.andEqualTo("topic_tag", topicDTO.getTopic_tag());
118 118 }
119 119 if (CommonUtils.isNotNull(topicDTO.getSpid())) {
120 120 criteria.andEqualTo("sp_id", topicDTO.getSpid());
121 121 }
122 122 if (CommonUtils.isNotEmpty(topicDTO.getTopic_id())) {
123   - criteria.andEqualTo("topic_id", topicDTO.getTopic_id());
  123 + criteria.andEqualTo("topic_id", topicDTO.getTopic_id());
124 124 }
125   - if (CommonUtils.isNotNull(topicDTO.getReceive())&& topicDTO.getReceive().equals(CommonConst.RECEIVE_AFTER)) {
  125 + if (CommonUtils.isNotNull(topicDTO.getReceive()) && topicDTO.getReceive().equals(CommonConst.RECEIVE_AFTER)) {
126 126 criteria.andEqualTo("auditor_id", topicDTO.getUserId());
127 127 }
128   - if (CommonUtils.isNotNull(topicDTO.getShenhe_status()) && topicDTO.getShenhe_status() != 3) {//不是 我的已审 进来的,只查一种状态
  128 + //不是 我的已审 进来的,只查一种状态
  129 + if (CommonUtils.isNotNull(topicDTO.getShenhe_status()) && topicDTO.getShenhe_status() != 3) {
129 130 criteria.andEqualTo("shenhe_status", topicDTO.getShenhe_status());
130   - } else if (CommonUtils.isNotNull(topicDTO.getShenhe_status()) && topicDTO.getShenhe_status() == 3) {//是 我的已审,查通过和拒绝的两种状态
131   - Example.Criteria criteria1 = example.createCriteria();
132   - criteria1.orEqualTo("shenhe_status", 1);
133   - criteria1.orEqualTo("shenhe_status", 2);
134   - example.and(criteria1);
  131 + //是 我的已审,查通过和拒绝的两种状态
  132 + } else if (CommonUtils.isNotNull(topicDTO.getShenhe_status()) && topicDTO.getShenhe_status() == 3) {
  133 + Example.Criteria criteria1 = example.createCriteria();
  134 + criteria1.orEqualTo("shenhe_status", 1);
  135 + criteria1.orEqualTo("shenhe_status", 2);
  136 + example.and(criteria1);
135 137 }
136 138  
137 139 PageHelper.startPage(topicDTO.getPage(), topicDTO.getPageSize(), true);
... ... @@ -139,112 +141,111 @@ public class TopicServiceImpl {
139 141 PageInfo<ShyTopic> pageInfo = new PageInfo<>(topicList);
140 142 return pageInfo;
141 143 }
142   -
  144 +
143 145 /**
144 146 * 根据条件导出数据excel
  147 + *
145 148 * @return
146 149 */
147   - public List<ShyTopic> findByCondition(String title,String content_tag,String contentId, Date start_date,
148   - Date end_date,Integer receive_status, Integer page,
149   - Integer pageSize, String orderByClause, Integer spid) {
150   -
151   - Example example = new Example(ShyContent.class);
152   - Example.Criteria criteria = example.createCriteria();
153   - if (CommonUtils.isNotEmpty(orderByClause)) {
154   - example.setOrderByClause(orderByClause);
155   - } else {
156   - example.setOrderByClause("create_date desc");
157   - }
158   - if (CommonUtils.isNotNull(start_date) ) {
159   - criteria.andGreaterThanOrEqualTo("create_date", start_date);
160   - }
161   - if ( CommonUtils.isNotNull(end_date)) {
162   - criteria.andLessThanOrEqualTo("create_date", end_date);
163   - }
164   - if (CommonUtils.isNotEmpty(title)) {
165   - criteria.andLike("title", "%" + title + "%");
166   - }
167   - if (CommonUtils.isNotNull(spid)) {
168   - criteria.andEqualTo("sp_id", spid);
169   - }
170   - if (CommonUtils.isNotEmpty(contentId)) {
171   - criteria.andEqualTo("content_id", contentId);
172   - }
173   - if (CommonUtils.isNotEmpty(content_tag)) {
174   - criteria.andEqualTo("content_tag", content_tag);
175   - }
176   - if (CommonUtils.isNotNull(receive_status)) {
177   - criteria.andEqualTo("receive_status", receive_status);
178   - }
  150 + public List<ShyTopic> findByCondition(String title, String content_tag, String contentId, Date start_date,
  151 + Date end_date, Integer receive_status, Integer page,
  152 + Integer pageSize, String orderByClause, Integer spid) {
  153 +
  154 + Example example = new Example(ShyContent.class);
  155 + Example.Criteria criteria = example.createCriteria();
  156 + if (CommonUtils.isNotEmpty(orderByClause)) {
  157 + example.setOrderByClause(orderByClause);
  158 + } else {
  159 + example.setOrderByClause("create_date desc");
  160 + }
  161 + if (CommonUtils.isNotNull(start_date)) {
  162 + criteria.andGreaterThanOrEqualTo("create_date", start_date);
  163 + }
  164 + if (CommonUtils.isNotNull(end_date)) {
  165 + criteria.andLessThanOrEqualTo("create_date", end_date);
  166 + }
  167 + if (CommonUtils.isNotEmpty(title)) {
  168 + criteria.andLike("title", "%" + title + "%");
  169 + }
  170 + if (CommonUtils.isNotNull(spid)) {
  171 + criteria.andEqualTo("sp_id", spid);
  172 + }
  173 + if (CommonUtils.isNotEmpty(contentId)) {
  174 + criteria.andEqualTo("content_id", contentId);
  175 + }
  176 + if (CommonUtils.isNotEmpty(content_tag)) {
  177 + criteria.andEqualTo("content_tag", content_tag);
  178 + }
  179 + if (CommonUtils.isNotNull(receive_status)) {
  180 + criteria.andEqualTo("receive_status", receive_status);
  181 + }
179 182 List<ShyTopic> shyContentList = shyTopicMapper.selectByExample(example);
180 183 return shyContentList;
181 184 }
182   -
183 185  
184   -
185 186  
186 187 //**********************
187   - public boolean callback(String id, String msg, Integer state, String userId,String updater) {
188   - boolean success = true;
189   - ShyTopic topic = shyTopicMapper.selectByPrimaryKey(Integer.parseInt(id));
190   - JSONObject params = new JSONObject();
191   - params.put("topic_id", topic.getTopic_id());
192   - params.put("status", state+1);
193   - params.put("msg", msg);
194   - success = transitServiceUtils.send("cms","updateTopicStatus", true, params);
195   - if(!success){
196   - logger.error("话题审核回调失败,话题表id:{}", topic.getId());
197   - return success;
198   - }
199   -
200   - topic.setShenhe_status(state);// 设置话题状态为审核后的状态
201   - topic.setShenhe_msg(msg);// 设置审核消息
202   - if (CommonUtils.isNotEmpty(userId)) {
203   - topic.setAuditor_id(userId);
204   - topic.setShenhe_type(CommonConst.AUDIT_TYPE_USER);// 设置审核类型为人工
205   - }else{
206   - topic.setUpdater(updater);//设置更新人
207   - }
208   - topic.setUpdate_date(CommonUtils.getCurrentTime());
209   - int i = shyTopicMapper.updateByPrimaryKeySelective(topic);
210   - if (i != 1) {
211   - success = false;
212   - }
213   -
214   - return success;
215   - }
216   -
217   -
  188 + public boolean callback(String id, String msg, Integer state, String userId, String updater) {
  189 + boolean success = true;
  190 + ShyTopic topic = shyTopicMapper.selectByPrimaryKey(Integer.parseInt(id));
  191 + JSONObject params = new JSONObject();
  192 + params.put("topic_id", topic.getTopic_id());
  193 + params.put("status", state + 1);
  194 + params.put("msg", msg);
  195 + success = transitServiceUtils.send("cms", "updateTopicStatus", true, params);
  196 + if (!success) {
  197 + logger.error("话题审核回调失败,话题表id:{}", topic.getId());
  198 + return success;
  199 + }
  200 +
  201 + topic.setShenhe_status(state);// 设置话题状态为审核后的状态
  202 + topic.setShenhe_msg(msg);// 设置审核消息
  203 + if (CommonUtils.isNotEmpty(userId)) {
  204 + topic.setAuditor_id(userId);
  205 + topic.setShenhe_type(CommonConst.AUDIT_TYPE_USER);// 设置审核类型为人工
  206 + } else {
  207 + topic.setUpdater(updater);//设置更新人
  208 + }
  209 + topic.setUpdate_date(CommonUtils.getCurrentTime());
  210 + int i = shyTopicMapper.updateByPrimaryKeySelective(topic);
  211 + if (i != 1) {
  212 + success = false;
  213 + }
  214 +
  215 + return success;
  216 + }
  217 +
  218 +
218 219 //**************************************
219 220 public ShyTopic selectByPrimaryKey(Integer id) {
220   - ShyTopic shyTopic = shyTopicMapper.selectByPrimaryKey(id);
  221 + ShyTopic shyTopic = shyTopicMapper.selectByPrimaryKey(id);
221 222 return shyTopic;
222 223 }
223   -
  224 +
224 225 public int updateByPrimaryKeySelective(ShyTopic topic) {
225 226 return shyTopicMapper.updateByPrimaryKeySelective(topic);
226 227 }
227   -
  228 +
228 229 /**
229 230 * 获得审核类型
  231 + *
230 232 * @param spId
231 233 */
232   - public Integer getShenheType(Integer spId){
233   -
234   - //获取图文免审sp
  234 + public Integer getShenheType(Integer spId) {
  235 +
  236 + //获取图文免审sp
235 237 List<Integer> sites = sitesService.getBusinessList(CommonConst.BUSINESS_TOPIC);
236 238 //初始化一个审核状态
237   - Integer shenheType=3;//审核类型,1:免审,2:机审,3:人工审
  239 + Integer shenheType = 3;//审核类型,1:免审,2:机审,3:人工审
238 240 //如果当前sp是免审sp
239   - if(sites.contains(spId)){
240   - shenheType=1;//免审
241   - }else{
242   - shenheType=3;//人工审
  241 + if (sites.contains(spId)) {
  242 + shenheType = 1;//免审
  243 + } else {
  244 + shenheType = 3;//人工审
243 245 }
244 246 return shenheType;
245   - }
246   -
247   -
  247 + }
  248 +
248 249  
249 250 }
250 251  
... ...
src/main/resources/templates/page/audio.html
... ... @@ -58,7 +58,7 @@
58 58 </button>
59 59 <button type="button" class="btn btn-sm margin-r-5 filter "
60 60 th:onclick="'javascript:quanbu()'" value="" id="quanbu">
61   - 全部
  61 + 查询
62 62 </button>
63 63 </button>
64 64 <button type="button" class="btn btn-sm margin-r-5 filter " id="daishen"
... ...
src/main/resources/templates/page/channel.html
... ... @@ -62,7 +62,7 @@
62 62 <div class="btn-group margin-bottom">
63 63 <button type="button" id="quanbu"
64 64 class="btn btn-sm margin-r-5 action_bottom"
65   - th:onclick="'javascript:quanbu()'">全部
  65 + th:onclick="'javascript:quanbu()'">查询
66 66 </button>
67 67 <button type="button" id="daishen"
68 68 class="btn btn-sm margin-r-5 action_bottom"
... ...
src/main/resources/templates/page/comment.html
... ... @@ -65,7 +65,7 @@
65 65 </button>
66 66 <button type="button" id="quanbu"
67 67 class="btn btn-sm margin-r-5 action_bottom"
68   - th:onclick="'javascript:quanbu()'">全部
  68 + th:onclick="'javascript:quanbu()'">查询
69 69 </button>
70 70 <button type="button" id="daishen"
71 71 class="btn btn-sm margin-r-5 action_bottom"
... ...
src/main/resources/templates/page/comment2.html
... ... @@ -62,7 +62,7 @@
62 62 <div class="btn-group margin-bottom">
63 63 <button type="button" id="all_button"
64 64 class="btn btn-sm margin-r-5 action_bottom"
65   - onclick="searchStatus('','')">全部
  65 + onclick="searchStatus('','')">查询
66 66 </button>
67 67 <button type="button" id="before_button"
68 68 class="btn btn-sm margin-r-5 action_bottom"
... ...
src/main/resources/templates/page/content.html
... ... @@ -58,7 +58,7 @@
58 58 </button>
59 59 <button type="button" class="btn btn-sm margin-r-5 filter "
60 60 th:onclick="'javascript:quanbu()'" value="" id="quanbu">
61   - 全部
  61 + 查询
62 62 </button>
63 63 <!-- </button> -->
64 64 <button type="button" class="btn btn-sm margin-r-5 filter " id="daishen"
... ...
src/main/resources/templates/page/live.html
... ... @@ -54,7 +54,7 @@
54 54 th:onclick="'javascript:daochu()'" value="" id="excel">导出excel
55 55 </button>
56 56 <button type="button" class="btn btn-sm margin-r-5 filter >"
57   - value="0" th:onclick="'javascript:quanbu()'" id="quanbu">全部</button>
  57 + value="0" th:onclick="'javascript:quanbu()'" id="quanbu">查询</button>
58 58 <button type="button"
59 59 class="btn btn-sm margin-r-5 filter " id="daishen" value="0">全部待领
60 60 </button>
... ...
src/main/resources/templates/page/liveApply.html
... ... @@ -58,7 +58,7 @@
58 58 </button>
59 59 <button type="button" class="btn btn-sm margin-r-5 filter "
60 60 th:onclick="'javascript:quanbu()'" value="" id="quanbu">
61   - 全部
  61 + 查询
62 62 </button>
63 63 <button type="button" class="btn btn-sm margin-r-5 filter " id="daishen"
64 64 th:onclick="'javascript:daishen()'" value="0">全部待领
... ...
src/main/resources/templates/page/notspeak.html
... ... @@ -91,7 +91,7 @@ input:checked + .slider:before {
91 91 <div class="btn-group margin-bottom">
92 92 <button type="button" id="quanbu"
93 93 class="btn btn-sm margin-r-5 action_bottom"
94   - th:onclick="'javascript:quanbu()'">全部
  94 + th:onclick="'javascript:quanbu()'">查询
95 95 </button>
96 96 <button type="button" id="jinyan"
97 97 class="btn btn-sm margin-r-5 action_bottom"
... ...
src/main/resources/templates/page/topic.html
... ... @@ -62,7 +62,7 @@
62 62 <div class="btn-group margin-bottom">
63 63 <button type="button" id="quanbu"
64 64 class="btn btn-sm margin-r-5 action_bottom"
65   - th:onclick="'javascript:quanbu()'">全部
  65 + th:onclick="'javascript:quanbu()'">查询
66 66 </button>
67 67 <button type="button" id="daishen"
68 68 class="btn btn-sm margin-r-5 action_bottom"
... ...
src/main/resources/templates/page/video.html
... ... @@ -58,7 +58,7 @@
58 58 </button>
59 59 <button type="button" class="btn btn-sm margin-r-5 filter "
60 60 th:onclick="'javascript:quanbu()'" value="" id="quanbu">
61   - 全部
  61 + 查询
62 62 </button>
63 63 </button>
64 64 <button type="button" class="btn btn-sm margin-r-5 filter " id="daishen"
... ...
src/main/resources/templates/page/videoStream.html
... ... @@ -70,7 +70,7 @@
70 70  
71 71 <div class="btn-group margin-bottom pull-right">
72 72 <button type="button" class="btn btn-sm margin-r-5 filter ?>"
73   - value="0" id="all" data="all">全部</button>
  73 + value="0" id="all" data="all">查询</button>
74 74 <button type="button"
75 75 class="btn btn-sm margin-r-5 filter btn-info ?>" value="1">全部待领
76 76 </button>
... ...