package com.bonus.material.cnarea.service.impl;

import com.bonus.material.cnarea.mapper.CnareaMapper;
import com.bonus.material.cnarea.service.CnareaService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;
import java.util.Map;

@Service
public class CnareaServiceImpl implements CnareaService {

    @Resource
    private CnareaMapper mapper;

    /**
     * 获取所有省份
     */
    @Override
    public List<Map<String, Object>> getProvinces() {
        return mapper.getProvinces();
    }

    /**
     * 根据省份代码获取城市列表
     *
     * @param provinceCode
     */
    @Override
    public List<Map<String, Object>> getCities(String provinceCode) {
        return mapper.getCities(provinceCode);
    }
}
