package com.hzya.frame.sys.template.dao;

import com.hzya.frame.sys.entity.FormmainCheckDto;
import com.hzya.frame.sys.entity.FormmainDeleteDto;
import com.hzya.frame.sys.entity.FormmainDto;
import com.hzya.frame.sys.entity.ModuleDto;
import com.hzya.frame.sys.entity.TemplateQuery;
import com.hzya.frame.sys.template.entity.Template;

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

/**
 * @description: 模版表  dao
 * @tableName: sys_template
 * @entityName: Template
 * @author: gjh
 * @history: 1.0
 */
public interface ITemplateMapper {

        //通过ID获取数据    entity_get
        Template entity_get(String id);

        //查询 采用==查询   entity_list_base
        List<Template> entity_list_base(Template entity);

        //  查询符合条件的数量
        Integer entity_count(Template entity);

        //分页查询列表 采用like格式 entity_list_like
        List<Template> entity_list_like(Template entity);

        //查询列表 字段采用or格式   entity_list_or
        List<Template> entity_list_or(Template entity);

        //新增  entity_insert
        Template entity_insert(Template entity);

        //修改  entity_update
        Integer entity_update(Template entity);

        //逻辑删除    entity_delete
        Integer entity_logicDelete(Template entity);

        //逻辑删除多条件
        Integer entity_logicDelete_Multi_Condition(Template entity);

        //物理删除
        Integer entity_delete(Template entity);


    Template entity_get_by_service(String service);

    List<HashMap<String, Object>> getServiceTemplateData(TemplateQuery templateQuery);

    Long getMaxSorts(Map<String, String> maps);

        Integer checkTable(Map<String, String> maps);

        Integer createTable(Map<String, Object> maps);

    String getTableName(String service);

    HashMap<String, Object> getServiceTemplateDataById(Map<String, Object> maps);

    List<HashMap<String, Object>> getServiceTemplateDataByFormmainId(Map<String, Object> queryData);

    Integer deleteFormmain(Map<String, String> map);

    Integer checkData(FormmainCheckDto formmainCheckDto);

    Integer saveFram(FormmainDto formmainDto);

    Integer update(FormmainDto formmainDto);

    List<String> queryTemplateId(FormmainDeleteDto formmainDeleteDto);

    Integer deleteTemplateById(FormmainDeleteDto formmainDeleteDto);

    List<HashMap<String, Object>> queryTemplateData(ModuleDto entity);
    List<HashMap<String, Object>> queryTemplateDataUp(ModuleDto entity);
    List<HashMap<String, Object>> queryTemplateDataAll(ModuleDto entity);

    HashMap<String, Object> queryTemplateDataOne(ModuleDto entity);

    Integer dropTable(String serviceName);

    Integer alterTable(Map<String, String> maps);
    Integer alterTableName(Map<String, String> maps);
}
