package sgc.portal.cw.cw0301.web;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import sgc.portal.base.util.EasyHashMap;
import sgc.portal.com.auth.model.PrvtinfoFindHist;
import sgc.portal.com.auth.model.SmComHdlgAuth;
import sgc.portal.com.auth.service.MaskingDesabledService;
import sgc.portal.com.com.service.ComAuthUserMngService;
import sgc.portal.cw.cw0301.service.CW03010001UService;
import sgc.portal.cw.cw0301.dto.CW03010001USearch;
import sgc.portal.cw.cw0301.model.CW03010001U;

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

@RestController
@RequestMapping("/cw/cw0301")
public class CW03010001UController {
	
	private final CW03010001UService service;

    public CW03010001UController(CW03010001UService service) {
        this.service = service;
    }

	//고충등록 내용 조회
    @PostMapping("/CW03010001U/selectProblemRegistryList")
    public List<EasyHashMap<String, Object>> selectProblemRegistryList(@RequestBody CW03010001USearch search) {
        return service.selectProblemRegistryList(search);
    }

	//고충등록 수정
    @PostMapping("/CW03010001U/saveProblemRegistryList")
    public void saveProblemRegistryList(@RequestBody CW03010001U cW03010001U) {
    	service.saveProblemRegistryList(cW03010001U);
    }
	
	//등록취소
    @PostMapping("/CW03010001U/updateProblemRegistryCanCel")
    public void updateProblemRegistryCanCel(@RequestBody CW03010001U cW03010001U) {
    	service.updateProblemRegistryCanCel(cW03010001U);
    }
}
