package com.stylefeng.guns.modular.system.controller;
|
|
import com.stylefeng.guns.core.base.controller.BaseController;
|
import com.stylefeng.guns.modular.system.utils.tips.ErrorTip;
|
import com.stylefeng.guns.modular.system.model.IndexInfo;
|
import com.stylefeng.guns.modular.system.service.ITOrderService;
|
import com.stylefeng.guns.modular.system.utils.tips.SuccessTip;
|
import io.swagger.annotations.Api;
|
import io.swagger.annotations.ApiImplicitParam;
|
import io.swagger.annotations.ApiImplicitParams;
|
import io.swagger.annotations.ApiOperation;
|
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.stereotype.Controller;
|
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.ResponseBody;
|
|
/**
|
* 控制器
|
*
|
* @author fengshuonan
|
* @Date 2022-12-28 09:33:09
|
*/
|
@Controller
|
@Api(tags = "主页")
|
@RequestMapping("/api/index")
|
public class IndexController extends BaseController {
|
|
@Autowired
|
private ITOrderService orderService;
|
|
/**
|
* 获取首页信息
|
*/
|
@ApiOperation(value = "卡车公司-首页信息",notes="首页信息")
|
@ApiImplicitParams({
|
@ApiImplicitParam(name = "Authorization", value = "用户token(Bearer +token)", required = true, dataType = "String", paramType = "header", defaultValue = "Bearer eyJhbGciOiJIUzUxMiJ9....."),
|
@ApiImplicitParam(name = "time", value = "2000-01-01 - 2000-11-11", required = false, dataType = "String"),
|
@ApiImplicitParam(name = "id", value = "卡车公司id", required = true, dataType = "String"),
|
})
|
@GetMapping(value = "/index")
|
@ResponseBody
|
public Object list(String time,int id) {
|
IndexInfo vo = orderService.indexList(time,id);
|
return new SuccessTip(vo);
|
}
|
|
}
|