package com.nokia.dao;

import java.util.List;

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

import com.nokia.pojo.Area;

@Mapper
public interface AreaDao {

    @Select("select * from sqmdb_rpt.acl_area order by type_code, area_id")
    List<Area> getAll();

    @Select("select * from sqmdb_rpt.acl_area where parent_id = #{parentId} order by type_code, area_id")
    List<Area> getByParentId(int parent_id);

    @Select("select * from sqmdb_rpt.acl_area where area_id = #{areaId}")
    Area getByAreaId(int areaId);
}
