| | |
| | | import com.zy.acs.manager.common.annotation.OperationLog; |
| | | import com.zy.acs.framework.common.R; |
| | | import com.zy.acs.manager.system.controller.BaseController; |
| | | import com.zy.acs.manager.core.service.MainService; |
| | | import com.zy.acs.manager.core.service.MainLxtService; |
| | | import com.zy.acs.manager.manager.controller.param.OpenBusSubmitParam; |
| | | import io.swagger.annotations.Api; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | |
| | | /** |
| | | * Created by vincent on 2023/6/12 |
| | | */ |
| | | @Api(tags = "开放平台") |
| | | @Api(tags = "Open Api") |
| | | @RestController |
| | | @RequestMapping("/api/open") |
| | | public class OpenController extends BaseController { |
| | | |
| | | @Autowired |
| | | private MainService mainService; |
| | | private MainLxtService mainService; |
| | | |
| | | @PreAuthorize("hasAuthority('open:bus:submit')") |
| | | @PostMapping("/bus/submit") |
| | | @OperationLog("任务下发") |
| | | @OperationLog("generate task from open api") |
| | | public R save(@RequestBody OpenBusSubmitParam param) { |
| | | mainService.generateBusAndTask(param, null); |
| | | return R.ok("保存成功"); |
| | | return R.ok("generate tasks success"); |
| | | } |
| | | |
| | | } |