|
@@ -1,7 +1,17 @@
|
|
|
package com.sf.home.controller;
|
|
|
|
|
|
+import com.sf.core.dto.RestResp;
|
|
|
+import com.sf.home.dto.resp.HomeFriendLinkRespDto;
|
|
|
+import com.sf.home.service.IHomeFriendLinkService;
|
|
|
+import io.swagger.v3.oas.annotations.Operation;
|
|
|
+import io.swagger.v3.oas.annotations.tags.Tag;
|
|
|
+import org.springframework.beans.factory.annotation.Autowired;
|
|
|
+import org.springframework.web.bind.annotation.GetMapping;
|
|
|
import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
import org.springframework.stereotype.Controller;
|
|
|
+import org.springframework.web.bind.annotation.RestController;
|
|
|
+
|
|
|
+import java.util.List;
|
|
|
|
|
|
/**
|
|
|
* <p>
|
|
@@ -11,8 +21,19 @@ import org.springframework.stereotype.Controller;
|
|
|
* @author baomidou
|
|
|
* @since 2024-08-05
|
|
|
*/
|
|
|
-@Controller
|
|
|
-@RequestMapping("/homeFriendLink")
|
|
|
+@Tag(name = "HomeFriendLinkController", description = "友情链接模块")
|
|
|
+@RestController
|
|
|
+@RequestMapping("/api/front/home")
|
|
|
public class HomeFriendLinkController {
|
|
|
|
|
|
+ @Autowired
|
|
|
+ private IHomeFriendLinkService homeFriendLinkService;
|
|
|
+
|
|
|
+ @Operation(summary = "友情链接列表接口")
|
|
|
+ @GetMapping("/friend_Link/list")
|
|
|
+ public RestResp<List<HomeFriendLinkRespDto>> listHomeFriendLinks() {
|
|
|
+ List<HomeFriendLinkRespDto> homeFriendLinkRespDtos = homeFriendLinkService.listHomeFriendLinks();
|
|
|
+ return RestResp.ok(homeFriendLinkRespDtos);
|
|
|
+ }
|
|
|
}
|
|
|
+
|