package sgc.portal.base.web;

import sgc.portal.base.model.Yfvrprg;
import sgc.portal.base.service.ComBookMarkPopService;
import sgc.portal.base.util.EasyHashMap;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**********************************************************
 * 시스템명  : 시스템관리(COM)
 * 프로그램ID : ComBookMarkController
 * 프로그램명   : 즐겨찾기
 * @author  : mir(aaaa@aaa.co.kr)
 * @version  :  2020-10-26
 * @since JDK1.8
 * @see   1.최초 작성
 */
@RestController
public class ComBookMarkPopController {

    @Autowired
    private ComBookMarkPopService comBookMarkPopService;

    /**
     * Select book mark menu list.
     *
     * @param yfvrprgs the yfvrprgs
     * @return list
     * @throws Exception `
     */
    //조회
    @PostMapping(value = "/com/cmm/selectBookMarkMenu")
    public List<EasyHashMap<String, Object>> selectBookMarkMenu(@RequestBody Yfvrprg yfvrprgs) {
        return comBookMarkPopService.selectBookMarkMenu(yfvrprgs);
    }

    /**
     * Save book mark menu.
     *
     * @param yfvrprgs the yfvrprgs
     */
    //저장
    @PostMapping(value = "/com/cmm/saveBookMarkMenu")
    public void saveBookMarkMenu(@RequestBody List<Yfvrprg> yfvrprgs) {
        comBookMarkPopService.saveBookMarkMenu(yfvrprgs);
    }



}
