package sgc.portal.cw.cw0622.web;

import org.springframework.web.bind.annotation.*;
import sgc.portal.base.util.EasyHashMap;
import sgc.portal.cw.cw0622.model.CW06220001U;
import sgc.portal.cw.cw0622.dto.CW06220001USearch;
import sgc.portal.cw.cw0622.service.CW06220001UService;

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

@RestController
@RequestMapping("/cw/cw0622")
public class CW06220001UController {
    private final CW06220001UService service;

    public CW06220001UController(CW06220001UService service) {
        this.service = service;
    }

    @PostMapping("/CW06220001U/list")
    public List<EasyHashMap<String, Object>> getList(@RequestBody CW06220001USearch search) {
        return service.getList(search);
    }
    
    @PostMapping("/CW06220001U/save")
    public Map<String, String> save(@RequestBody List<CW06220001U> CW06220001U) {
    	return service.save(CW06220001U);
    }
}
