package com.bjtdba.pension.controller;

import com.bjtdba.pension.entity.StoreProductAttrValue;
import com.bjtdba.pension.service.PensionService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import java.math.BigDecimal;

@RestController
@RequestMapping("pension_service/pensionService")
public class PensionController {

    @Autowired
    private PensionService pensionService;

    @PostMapping("pension")
    public BigDecimal pension(@RequestParam()StoreProductAttrValue storeProductAttrValue){
        return pensionService.pension(storeProductAttrValue);
    }
}
