| | |
| | | package org.jeecg.modules.eam.controller; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import java.io.UnsupportedEncodingException; |
| | | import java.io.IOException; |
| | | import java.net.URLDecoder; |
| | | import java.util.ArrayList; |
| | | import java.util.Arrays; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | import java.util.stream.Collectors; |
| | | |
| | | import javax.servlet.http.HttpServletRequest; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | |
| | | import org.apache.commons.lang3.StringUtils; |
| | | import org.apache.shiro.SecurityUtils; |
| | | import org.jeecg.common.api.vo.Result; |
| | |
| | | import org.jeecg.common.system.query.QueryGenerator; |
| | | import org.jeecg.common.system.vo.LoginUser; |
| | | import org.jeecg.common.util.oConvertUtils; |
| | | import org.jeecg.modules.eam.entity.Equipment; |
| | | import org.jeecg.modules.eam.entity.EquipmentUnseal; |
| | | import org.jeecg.modules.eam.entity.EquipmentUnsealDetail; |
| | | import org.jeecg.modules.eam.service.IEamEquipmentService; |
| | | import org.jeecg.modules.eam.service.IEquipmentUnsealDetailService; |
| | | import org.jeecg.modules.eam.service.IEquipmentUnsealService; |
| | | import org.jeecg.modules.eam.entity.EquipmentUnseal; |
| | | import org.jeecg.modules.eam.vo.EquipmentUnsealPage; |
| | | import org.jeecgframework.poi.excel.ExcelImportUtil; |
| | | import org.jeecgframework.poi.excel.def.NormalExcelConstants; |
| | |
| | | IPage<EquipmentUnseal> pageList = equipmentUnsealService.page(page, queryWrapper); |
| | | return Result.OK(pageList); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 添加 |
| | | * |
| | |
| | | equipmentUnsealService.saveMain(equipmentUnseal, equipmentUnsealPage.getEquipmentUnsealDetailList()); |
| | | return Result.OK("添加成功!"); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 编辑 |
| | | * |
| | |
| | | equipmentUnsealService.updateMain(equipmentUnseal, equipmentUnsealPage.getEquipmentUnsealDetailList()); |
| | | return Result.OK("编辑成功!"); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 通过id删除 |
| | | * |
| | |
| | | equipmentUnsealService.delMain(id); |
| | | return Result.OK("删除成功!"); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 批量删除 |
| | | * |
| | |
| | | this.equipmentUnsealService.delBatchMain(Arrays.asList(ids.split(","))); |
| | | return Result.OK("批量删除成功!"); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 通过id查询 |
| | | * |
| | |
| | | return Result.OK(equipmentUnseal); |
| | | |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 通过id查询 |
| | | * |