controllers/car.go
@@ -119,3 +119,16 @@ c.ServeJSON() } // @router /crossRecord [get] func (c *CarController) CrossRecord() { sv := service.NewCarService() records := sv.CrossRecords() resp := code.Code{ Success: true, Status: http.StatusOK, Data: records, } c.Data["json"] = resp c.ServeJSON() }