Class AdminFundProjAPIController
java.lang.Object
com.eeit87t3.tickiteasy.cwdfunding.controller.AdminFundProjAPIController
- Author:
- TingXD (chen19990627)
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddProject(FundProjDTO fundProjDTO) deleteFundProj(Integer projectID) editProductStatusByID(Integer projectID, Map<String, Integer> requestBody) editProject(String projectID, String title, String categoryID, String tagID, String startDateStr, String endDateStr, String targetAmount, String currentAmount, String threshold, String postponeDateStr, MultipartFile image, String oldImage, String description, List<String> planIDs, List<String> planTitles, List<String> planUnitPrices, List<String> planTotalAmounts, List<String> planBuyAmounts, List<MultipartFile> planImages, List<String> oldPlanImages, List<String> planContents) org.springframework.data.domain.Page<FundProjDTO> findByPageApi(Integer pageNumber, Integer categoryID, Model model) org.springframework.data.domain.Page<FundOrder> findOrderByPageApi(Integer pageNumber)
-
Constructor Details
-
AdminFundProjAPIController
public AdminFundProjAPIController()
-
-
Method Details
-
findByPageApi
@ResponseBody @GetMapping("/api/fundproject") public org.springframework.data.domain.Page<FundProjDTO> findByPageApi(@RequestParam Integer pageNumber, @RequestParam(required=false) Integer categoryID, Model model) -
findByID
@ResponseBody @GetMapping("/api/fundproject/{projectID}") public FundProjDTO findByID(@PathVariable Integer projectID) -
findOrderByPageApi
@ResponseBody @GetMapping("/api/fundprojectOrder") public org.springframework.data.domain.Page<FundOrder> findOrderByPageApi(@RequestParam Integer pageNumber) -
deleteFundProj
@ResponseBody @DeleteMapping("/api/fundproject/{projectID}") public ResponseEntity<String> deleteFundProj(@PathVariable Integer projectID) -
addProject
@ResponseBody @PostMapping("/api/fundproject") public ResponseEntity<Map<String,Object>> addProject(@ModelAttribute FundProjDTO fundProjDTO) -
editProject
@ResponseBody @PutMapping("/api/fundproject/{projectID}") public ResponseEntity<Map<String,Object>> editProject(@PathVariable String projectID, @RequestParam String title, @RequestParam String categoryID, @RequestParam String tagID, @RequestParam("startDate") String startDateStr, @RequestParam("endDate") String endDateStr, @RequestParam String targetAmount, @RequestParam String currentAmount, @RequestParam String threshold, @RequestParam("postponeDate") String postponeDateStr, @RequestParam MultipartFile image, @RequestParam("old-image") String oldImage, @RequestParam String description, @RequestParam List<String> planIDs, @RequestParam List<String> planTitles, @RequestParam List<String> planUnitPrices, @RequestParam List<String> planTotalAmounts, @RequestParam List<String> planBuyAmounts, @RequestParam List<MultipartFile> planImages, @RequestParam("old-planImage") List<String> oldPlanImages, @RequestParam List<String> planContents) -
editProductStatusByID
@PutMapping("/api/fundproject/status/{projectID}") @ResponseBody public ResponseEntity<?> editProductStatusByID(@PathVariable("projectID") Integer projectID, @RequestBody Map<String, Integer> requestBody)
-