package cn.com.tenlion.buildingpictures.service.picturestemplatearea;

import cn.com.tenlion.buildingpictures.pojo.dtos.picturestemplatearea.PicturesTemplateAreaBuildingDTO;
import cn.com.tenlion.buildingpictures.pojo.dtos.picturestemplatearea.PicturesTemplateAreaDTO;
import cn.com.tenlion.buildingpictures.pojo.vos.picturestemplatearea.PicturesTemplateAreaAllVO;
import cn.com.tenlion.buildingpictures.pojo.vos.picturestemplatearea.PicturesTemplateAreaPiointVO;
import cn.com.tenlion.buildingpictures.pojo.vos.picturestemplatearea.PicturesTemplateAreaVO;
import ink.wgink.exceptions.RemoveException;
import ink.wgink.exceptions.SaveException;
import ink.wgink.exceptions.SearchException;
import ink.wgink.pojo.ListPage;
import ink.wgink.pojo.result.SuccessResult;
import ink.wgink.pojo.result.SuccessResultData;
import ink.wgink.pojo.result.SuccessResultList;
import java.util.List;
import java.util.Map;

/**
 * @ClassName: IPicturesTemplateAreaService
 * @Description: 图片套版模板的区域设置
 * @Author: WenG
 * @Date: 2020-10-20 15:08
 * @Version: 1.0
 **/
public interface IPicturesTemplateAreaService {

    /**
     * 新增图片套版模板的区域设置
     *
     * @param picturesTemplateAreaVO
     * @return
     * @throws Exception
     */
    SuccessResult savePicturesTemplateArea(PicturesTemplateAreaVO picturesTemplateAreaVO) throws Exception;

    /**
     * 新增图片套版模板的区域设置(APP)
     *
     * @param token
     * @param picturesTemplateAreaVO
     * @return
     * @throws Exception
     */
    SuccessResult savePicturesTemplateAreaByToken(String token, PicturesTemplateAreaVO picturesTemplateAreaVO) throws Exception;

    /**
     * 新增图片套版模板的区域设置
     *
     * @param picturesTemplateAreaVO
     * @return picturesTemplateAreaId
     * @throws Exception
     */
    String savePicturesTemplateAreaReturnId(PicturesTemplateAreaVO picturesTemplateAreaVO) throws Exception;

    /**
     * 新增图片套版模板的区域设置(APP)
     *
     * @param token
     * @param picturesTemplateAreaVO
     * @return picturesTemplateAreaId
     * @throws Exception
     */
    String savePicturesTemplateAreaByTokenReturnId(String token, PicturesTemplateAreaVO picturesTemplateAreaVO) throws Exception;

    /**
     * 删除图片套版模板的区域设置
     *
     * @param ids
     * @return
     * @throws RemoveException
     */
    SuccessResult removePicturesTemplateArea(String ids) throws RemoveException;

    /**
     * 删除图片套版模板的区域设置（物理删除）
     *
     * @param ids
     * @throws RemoveException
     */
    void deletePicturesTemplateArea(String ids) throws RemoveException;

    /**
     * 删除图片套版模板的区域设置(APP)
     *
     * @param token
     * @param ids
     * @return
     * @throws RemoveException
     */
    SuccessResult removePicturesTemplateAreaByToken(String token, String ids) throws RemoveException;

    /**
     * 修改图片套版模板的区域设置
     *
     * @param picturesTemplateAreaId
     * @param picturesTemplateAreaVO
     * @return
     * @throws Exception
     */
    SuccessResult updatePicturesTemplateArea(String picturesTemplateAreaId, PicturesTemplateAreaVO picturesTemplateAreaVO) throws Exception;

    /**
     * 修改图片套版模板的区域设置(APP)
     *
     * @param token
     * @param picturesTemplateAreaId
     * @param picturesTemplateAreaVO
     * @return
     * @throws Exception
     */
    SuccessResult updatePicturesTemplateAreaByToken(String token, String picturesTemplateAreaId, PicturesTemplateAreaVO picturesTemplateAreaVO) throws Exception;

    /**
     * 图片套版模板的区域设置详情(通过ID)
     *
     * @param picturesTemplateAreaId
     * @return
     * @throws SearchException
     */
    PicturesTemplateAreaDTO getPicturesTemplateAreaById(String picturesTemplateAreaId) throws SearchException;

    /**
     * 图片套版模板的区域设置列表
     *
     * @param params
     * @return
     * @throws SearchException
     */
    List<PicturesTemplateAreaDTO> listPicturesTemplateArea(Map<String, Object> params) throws SearchException;

    /**
     * 图片套版模板的区域设置分页列表
     *
     * @param page
     * @return
     * @throws SearchException
     */
    SuccessResultList<List<PicturesTemplateAreaDTO>> listPagePicturesTemplateArea(ListPage page) throws SearchException;

    /**
     * 图片套版模板的区域设置统计
     *
     * @param params
     * @return
     * @throws SearchException
     */
    Integer countNumberPicturesTemplateArea(Map<String, Object> params) throws SearchException;

    /**
     * 图片套版模板的区域设置统计
     *
     * @param params
     * @return
     * @throws SearchException
     */
    SuccessResultData<Integer> countPicturesTemplateArea(Map<String, Object> params) throws SearchException;

    List<PicturesTemplateAreaDTO> getPicturesTemplateAreaByPicturesTemplateId(String picturesTemplateId) throws SearchException;

    SuccessResult updatePicturesTemplateAreaPoint(String picturesTemplateAreaId, PicturesTemplateAreaPiointVO picturesTemplateAreaPiointVO) throws Exception;

    SuccessResult copyPicturesTemplateAreaPoint(String picturesTemplateAreaId, String templateAreaSource) throws Exception;

    SuccessResult updatePicturesTemplateAreaPointModuleData(String picturesTemplateAreaId, String templateAreaModuleData) throws Exception;

    List<PicturesTemplateAreaDTO> getPicturesTemplateAreaByPicturesTemplateCode(String picturesTemplateCode) throws SearchException;

    SuccessResult updatePicturesTemplateAreaAll(String picturesTemplateId, PicturesTemplateAreaAllVO picturesTemplateAreaAllVO) throws Exception;

    /**
     * 供其他模块调用时候单独使用, 本模块内还是使用旧的listPicturesTemplateArea
     * @param queryParams
     * @return
     * @throws Exception
     */
    List<PicturesTemplateAreaBuildingDTO> list(Map<String, Object> queryParams) throws SearchException;

    /**
     * 创建图片
     * @param picturesTemplateAreaId
     * @return
     * @throws SearchException
     */
    SuccessResultData<String> saveCreateFile(String picturesTemplateAreaId, String content) throws SaveException;
}