package sgc.portal.cw.cw0702.web;

import org.springframework.web.bind.annotation.*;
import sgc.portal.base.util.EasyHashMap;
import sgc.portal.cw.cw0702.dto.CW07020001USearch;
import sgc.portal.cw.cw0702.model.CW07020001U;
import sgc.portal.cw.cw0702.service.CW07020001UService;

import java.util.List;
import java.util.Map;

@RestController
@RequestMapping("/cw/cw0702")
public class CW07020001UController {
	
    private final CW07020001UService service;

    public CW07020001UController(CW07020001UService service) {
        this.service = service;
    }

    @PostMapping("/CW07020001U/selectZehrIsExtraMaterialAdmin")
    public List<EasyHashMap<String, Object>> selectZehrIsExtraMaterialAdmin(@RequestBody CW07020001USearch search) {
        return service.selectZehrIsExtraMaterialAdmin(search);
    }

    @PostMapping("/CW07020001U/saveZehrIsExtraMaterialAdmin")
    public Map<String, String> saveZehrIsExtraMaterialAdmin(@RequestBody List<CW07020001U> CW07020001U) {
    	return service.saveZehrIsExtraMaterialAdmin(CW07020001U);
    }
}