| | |
| | | import com.ruoyi.common.utils.ServletUtils; |
| | | import com.ruoyi.common.utils.poi.ExcelUtil; |
| | | import com.ruoyi.domain.ZfEvent; |
| | | import com.ruoyi.domain.excel.ZfEquipmentExcelBean; |
| | | import com.ruoyi.domain.excel.ZfEventExcelBean; |
| | | import com.ruoyi.service.ZfEventService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.web.bind.annotation.*; |
| | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.Arrays; |
| | | import java.util.Collections; |
| | | import java.util.List; |
| | | |
| | | import static com.ruoyi.common.core.page.TableSupport.PAGE_NUM; |
| | |
| | | return zfEventService.selectDataList(zfEvent, pageNum, pageSize); |
| | | } |
| | | |
| | | /** |
| | | * 获取导入模板 |
| | | */ |
| | | @GetMapping("/model") |
| | | public void getExportModel(HttpServletResponse response){ |
| | | List<ZfEventExcelBean> list = Collections.singletonList(new ZfEventExcelBean()); |
| | | ExcelUtil<ZfEventExcelBean> util = new ExcelUtil<>(ZfEventExcelBean.class); |
| | | util.exportExcel(response,list,"家大事记记录数据"); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 导出家庭大事件记录列表 |
| | |
| | | |
| | | } |
| | | |
| | | public static void main(String[] args) { |
| | | System.out.println(); |
| | | } |
| | | |
| | | /** |
| | | * 导入家庭大事件记录列表 |