package cn.ezhizao.project.business.controller;

import cn.ezhizao.framework.task.RyTask;
import cn.ezhizao.framework.web.controller.BaseController;
import cn.ezhizao.framework.web.page.TableDataInfo;
import cn.ezhizao.project.business.domain.BizCarrier;
import cn.ezhizao.project.business.service.IBizCarrierService;
import com.fasterxml.jackson.core.JsonProcessingException;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.*;

import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest;
import java.util.List;


/**
 * 载具Controller
 *
 * @author ezhizao
 * @date 2023-11-14
 */
@RestController
@RequestMapping("/business/carrier")
public class BizCarrierController extends BaseController {
    @Resource
    private IBizCarrierService iBizCarrierService;
    @Resource
    private HttpServletRequest request;

    @GetMapping("/list")
    public TableDataInfo list(BizCarrier data) throws NoSuchFieldException, IllegalAccessException, JsonProcessingException {
        startPage();
        List<BizCarrier> list = iBizCarrierService.getList(data);
        return getDataTable(list);
    }
}
