| | |
| | | import org.springblade.mdm.basesetting.machine.vo.MachineQueryVO; |
| | | import org.springblade.mdm.basesetting.machine.vo.MachineSaveVO; |
| | | import org.springblade.mdm.basesetting.machine.vo.MachineVO; |
| | | import org.springblade.mdm.program.vo.MdmProgramImportVO; |
| | | import org.springblade.system.pojo.entity.User; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | |
| | | @Operation(summary = "修改", description = "机床信息") |
| | | @PostMapping("/update") |
| | | public R<Boolean> update(@RequestBody MachineSaveVO vo) { |
| | | |
| | | return R.<Boolean>status(service.updateMachine(vo)); |
| | | } |
| | | |
| | |
| | | return R.data(service.detail(id)); |
| | | } |
| | | |
| | | @PostMapping("import") |
| | | @ApiOperationSupport(order = 1) |
| | | @Operation(summary = "机床导入", description = "机床导入,全部成功返回空串,部分成功返回具体信息") |
| | | public R<String> importMachines(@RequestParam MultipartFile file) { |
| | | try { |
| | | return R.data(service.importMachines(file)); |
| | | }catch (Exception e){ |
| | | log.error("导入错误",e); |
| | | return R.fail(e.getMessage()); |
| | | } |
| | | } |
| | | /** |
| | | * 删除 |
| | | */ |