package cn.com.countrygarden.bi.main.controller.resident;

import cn.com.countrygarden.bi.main.core.Response;
import cn.com.countrygarden.bi.main.core.Result;
import cn.com.countrygarden.bi.main.model.resident.ContractConstant;
import cn.com.countrygarden.bi.main.model.resident.PaymentMethod;
import cn.com.countrygarden.bi.main.service.resident.PaymentMethodService;
import cn.com.countrygarden.bi.main.util.RedisCacheUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

import java.util.HashMap;
import java.util.List;

/**
 * Created by chenweijiang on 2017/11/13.
 */
@RestController("PaymentMethodController")
@RequestMapping("/api/resident/paymentmethod")
public class PaymentMethodController {

    @Autowired
    private PaymentMethodService paymentMethodService;

    @RequestMapping(value = "",method = {RequestMethod.GET},produces = {"application/json;charset=utf-8"})
    public Result listPaymentMethod(){

        List<PaymentMethod> result =  paymentMethodService.listAll();
        return Response.response(result);
    }

}
