package com.elephant.framework.galaxy.aroad.module.emergency.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.elephant.framework.galaxy.aroad.module.emergency.dto.TeamEquipmentCoordinateDto;
import com.elephant.framework.galaxy.aroad.module.emergency.entity.EmergencyTeam;
import com.elephant.framework.galaxy.aroad.module.emergency.entity.EmergencyTeamEquipment;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
 * 获取队伍装备基础信息
 *
 * @author XingYuyang
 * @date 2019-04-04 11:03:17
 */
public interface EmergencyTeamEquipmentMapper extends BaseMapper<EmergencyTeamEquipment> {
    /**
     * @Description: 查询队伍装备的坐标信息
     * @Param:
     * @return:
     * @Author: XingYuyang
     * @Date: 2019-04-04 11:11:38
     */
    List<TeamEquipmentCoordinateDto> getCoordinates();

    /**
     * @Description: 新增队伍信息
     * @Author: XingYuyang
     * @Date: 2019-04-16 10:36:00
     */
    @Transactional(propagation= Propagation.REQUIRES_NEW)
    boolean save(EmergencyTeam emergencyTeam);

    /**
     * @Description: 修改队伍信息
     * @Author: XingYuyang
     * @Date: 2019-04-16 10:36:00
     */
    @Transactional(propagation= Propagation.REQUIRES_NEW)
    boolean updateWithId(EmergencyTeam emergencyTeam);
}
