|
|
@@ -12,9 +12,11 @@ import org.springframework.web.bind.annotation.ResponseBody;
|
|
|
import org.springframework.web.servlet.ModelAndView;
|
|
|
|
|
|
import com.goafanti.banners.enums.BannersType;
|
|
|
+import com.goafanti.banners.service.BannersService;
|
|
|
import com.goafanti.common.bo.Result;
|
|
|
import com.goafanti.common.constant.AFTConstants;
|
|
|
-import com.goafanti.common.controller.WebpageController;
|
|
|
+import com.goafanti.common.controller.BaseController;
|
|
|
+import com.goafanti.common.model.Banners;
|
|
|
import com.goafanti.common.model.User;
|
|
|
import com.goafanti.core.shiro.token.TokenManager;
|
|
|
import com.goafanti.engagedFieldGlossory.service.EngagedFieldGlossoryService;
|
|
|
@@ -28,7 +30,7 @@ import com.goafanti.user.service.UserInterestService;
|
|
|
* 大咖说
|
|
|
*/
|
|
|
@Controller
|
|
|
-public class PortalBigShotController extends WebpageController {
|
|
|
+public class PortalBigShotController extends BaseController {
|
|
|
@Resource
|
|
|
private StarService starService;
|
|
|
@Resource
|
|
|
@@ -37,6 +39,8 @@ public class PortalBigShotController extends WebpageController {
|
|
|
private LectureService lectureService;
|
|
|
@Resource
|
|
|
private EngagedFieldGlossoryService engagedFieldGlossoryService;
|
|
|
+ @Resource
|
|
|
+ private BannersService bannersService;
|
|
|
|
|
|
@RequestMapping(value = "/portal/scienceTechnology/bigShot", method = RequestMethod.GET)
|
|
|
public ModelAndView bigShot() {
|
|
|
@@ -86,4 +90,11 @@ public class PortalBigShotController extends WebpageController {
|
|
|
return res;
|
|
|
}
|
|
|
|
|
|
+ private void handleBanners(ModelAndView modelview, BannersType bannersType) {
|
|
|
+ List<Banners> banners = bannersService.findPortalBanners(bannersType.getKey());
|
|
|
+ if (!banners.isEmpty()) {
|
|
|
+ modelview.addObject("banners", banners);
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
}
|