package com.sptg.gateway.controller.implement;

import com.sptg.common.core.beans.ResultBean;
import com.sptg.estate.api.entity.Contract;
import com.sptg.estate.api.entity.ProjectBook;
import com.sptg.estate.api.feigns.ProjectBookFeign;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * title: ProjectBookController
 * package: com.sptg.estate.biz.security
 * description: 立项书-控制器
 *
 *               
 *                      
 */
@Slf4j
@RestController
@RequiredArgsConstructor
@RequestMapping(value = "/implement/projectBook")
public class ProjectBookController {

    private final ProjectBookFeign projectBookFeign;

    /**
     * 功能描述:新增
     * @param projectBook
     * @return ResultBean<Boolean>
     *               
     *                      
     */
    @PostMapping("/insertByResidentialId")
    public ResultBean<Boolean> insertByResidentialId(ProjectBook projectBook){
        return this.projectBookFeign.insertByResidentialId(projectBook);
    }
    /**
     * 功能描述:修改
     * @param projectBook
     * @return ResultBean<Boolean>
     *               
     *                      
     */
    @PostMapping("/editByProjectId")
    public ResultBean<Boolean> editByProjectId(ProjectBook projectBook){
        return this.projectBookFeign.editByProjectId(projectBook);
    }
}
