package org.example.ModuleApi.ModuleAjaxApi.mapper;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

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

@Mapper
public interface DMCrmMapper {

    List<Map<String, Object>> getModuleIdFieldRow(@Param("keyName") String keyName, @Param("tab") String key, @Param("labTreeType") int labTreeType);

    List<Map<String, Object>> GetCondition(
            @Param("fromkey") String fromkey,
            @Param("id") Integer id,
            @Param("windowsDirver") boolean windowsDirver);

    int getAuditStepCount(@Param("moduleId") String moduleId, @Param("isBase") boolean isBase);

    List<Map<String, Object>> GetBillDetailColumns(
            @Param("moduleCode") String moduleCode,
            @Param("userId") String userId,
            @Param("username") String username,
            @Param("id") int id,
            @Param("windowsDirver") boolean windowsDirver);

    List<Map<String, Object>> GetBillMasterRows(
            @Param("moduleId") String moduleId,
            @Param("userName") String userName,
            @Param("id") int id,
            @Param("windowsDirver") boolean windowsDirver);

    Map<String, Object> GetBillModule(@Param("moduleCode") String moduleCode, @Param("menuId") String menuId);

    List<Map<String, Object>> GetControlRows(@Param("fromkey") Object fromkey, @Param("userName") String userName, @Param("moduleId") String moduleId, @Param("fieldId") Integer fieldId);

    List<Map<String, Object>> selectSystemPopupMenuById(@Param("menuid") int menuid, @Param("fromkey") String fromkey, @Param("username") String username);

    List<Map<String, Object>> selectSystemPopupMenuByType(@Param("menutype") int menutype,
                                                          @Param("fromkey") String fromkey,
                                                          @Param("username") String username,
                                                          @Param("windowsDirver") boolean windowsDirver);

    List<Map<String, Object>> getBillSource(
            @Param("typeCode") String typeCode,
            @Param("condition") String condition
    );

    List<Map<String, Object>> getBillSourceColumns(
            @Param("sourceId") String sourceId,
            @Param("userId") String userId,
            @Param("billSourceGridView") String billSourceGridView
    );

    List<Map<String, Object>> getBillSourceDetailColumns(
            @Param("sourceId") String sourceId,
            @Param("billSourceDetailGridView") String billSourceDetailGridView,
            @Param("userId") String userId
    );

    List<Map<String, Object>> GetBaseModule(@Param("moduleCode") String moduleCode, @Param("menuId") String menuId);

}
