package sgc.portal.qc.qc0103.web;

import org.springframework.web.bind.annotation.*;
import sgc.portal.base.util.EasyHashMap;
import sgc.portal.qc.qc0103.service.QC01030001UService;
import sgc.portal.qc.qc0103.dto.QC01030001USearch;
import sgc.portal.qc.qc0103.model.QC01030001U;

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

@RestController
@RequestMapping("/qc/qc0103")
public class QC01030001UController {
	
	private final QC01030001UService service;

    public QC01030001UController(QC01030001UService service) {
        this.service = service;
    }
    
    //문서관리 조회
    @PostMapping("/QC01030001U/selectQcOutcoDocGrd")
    public List<EasyHashMap<String, Object>> selectQcOutcoDocGrd(@RequestBody QC01030001USearch search) {
        return service.selectQcOutcoDocGrd(search);
    }
    
    //문서관리 조회
    @PostMapping("/QC01030001U/selectCommonCode")
    public List<EasyHashMap<String, Object>> selectCommonCode(@RequestBody QC01030001USearch search) {
        return service.selectCommonCode(search);
    }
    
	//문서관리 수정
    @PostMapping("/QC01030001U/saveQcOutcoDoc")
    public Map<String, String> saveQcOutcoDoc(@RequestBody List<QC01030001U> qC01030001U) {
    	return service.saveQcOutcoDoc(qC01030001U);
    }
}
