ganzi-api/inventory-dao/src/main/java/com/rzyc/mapper/SysOrgMapper.java
2022-09-16 15:07:17 +08:00

88 lines
3.2 KiB
Java

package com.rzyc.mapper;
import com.rzyc.bean.bigdata.AreaInfo;
import com.rzyc.bean.organization.vo.CountByOrg;
import com.rzyc.model.SysOrg;
import com.rzyc.model.SysOrgExample;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;
import java.util.List;
import java.util.Map;
@Repository
public interface SysOrgMapper {
long countByExample(SysOrgExample example);
int deleteByExample(SysOrgExample example);
int deleteByPrimaryKey(String orgcode);
int insert(SysOrg record);
int insertSelective(SysOrg record);
List<SysOrg> selectByExample(SysOrgExample example);
SysOrg selectByPrimaryKey(String orgcode);
int updateByExampleSelective(@Param("record") SysOrg record, @Param("example") SysOrgExample example);
int updateByExample(@Param("record") SysOrg record, @Param("example") SysOrgExample example);
int updateByPrimaryKeySelective(SysOrg record);
int updateByPrimaryKey(SysOrg record);
/*地区列表*/
List<SysOrg> sysOrgList(@Param("superiorOrgCode") String superiorOrgCode);
List<AreaInfo> findBySuper(@Param("superiorOrgCode") String superiorOrgCode);
/*通过名字查询*/
SysOrg findByName(@Param("orgName") String orgName,
@Param("superId") String superId);
/*查询所有*/
List<SysOrg> findAll();
/*查询所有*/
List<SysOrg> areaPage(@Param("condition") String condition,
@Param("orgcode") String orgcode);
/*修改地区*/
int changeArea(SysOrg record);
/*下级地区列表*/
List<SysOrg> findByParentId(@Param("orgcode") String orgcode);
/*获取村社代码及名字*/
List<Map<String,String>> selectCommunityInfo(@Param("name")String name);
List<CountByOrg> countByOrg(@Param("yearFirst")String yearFirst,@Param("yearLast")String yearLast,@Param("month1")String month1,
@Param("month2")String month2,@Param("weekFirst")String weekFirst,@Param("weekEnd")String weekEnd,
@Param("lastTimeInterval2")String lastTimeInterval2, @Param("lastTimeInterval1")String lastTimeInterval1);
/*上周数据*/
List<CountByOrg> lastWeek(@Param("lastTimeInterval2")String lastTimeInterval2, @Param("lastTimeInterval1")String lastTimeInterval1);
/*年隐患数据*/
List<CountByOrg> censYearData(@Param("firstDayDateOfYear") String firstDayDateOfYear, @Param("lastDayOfYear") String lastDayOfYear);
/*月隐患数据*/
List<CountByOrg> censMonthData(@Param("firstDayOfMonth") String firstDayOfMonth, @Param("lastDayOfMonth") String lastDayOfMonth);
/*周隐患数据*/
List<CountByOrg> censWeekData(@Param("weekFirst") String weekFirst, @Param("weekEnd")String weekEnd,
@Param("lastTimeInterval2")String lastTimeInterval2, @Param("lastTimeInterval1")String lastTimeInterval1);
/*风险较大镇*/
List<String> topRiskStreet();
/*监督检查地区列表*/
List<SysOrg> checkSysOrg(@Param("superiorOrgCode") String superiorOrgCode,
@Param("startTime") String startTime,
@Param("endTime") String endTime);
}