| | |
| | | import com.github.pagehelper.PageInfo; |
| | | import com.whyc.dto.*; |
| | | import com.whyc.mapper.BattGroupDataMapper; |
| | | import com.whyc.mapper.FileInfoMapper; |
| | | import com.whyc.mapper.FileParamMapper; |
| | | import com.whyc.mapper.TestParamMapper; |
| | | import com.whyc.pojo.*; |
| | |
| | | private FileParamMapper paramMapper; |
| | | |
| | | @Autowired(required = false) |
| | | private FileInfoMapper infoMapper; |
| | | |
| | | @Autowired(required = false) |
| | | private TestParamMapper testParamMapper; |
| | | |
| | | //解析xml文件(传参一个文件) |
| | |
| | | if (file.isFile()) { |
| | | FileInfo fileInfo = XmlFileOpreate.readXml(filePath); |
| | | fileInfo.setFileUrl(filePath); |
| | | fileInfo.setFileId("0"); |
| | | String fileName = filePath.substring(filePath.lastIndexOf("\\")+1); |
| | | fileInfo.setFileName(fileName); |
| | | fileInfo.setFileNameTmp(fileName+" tmp1.~xml"); |
| | |
| | | dataMapper.deleteDataAndInfo(stationId,fileId); |
| | | //删除所有文件参数 |
| | | paramMapper.deleteParamByFileId(fileId); |
| | | //移除机房下挂在的文件 |
| | | infoMapper.deleteFileInStation(stationId,fileId); |
| | | return new Response().set(1,"删除成功!"); |
| | | } |
| | | } |