| | |
| | | import javax.validation.Valid; |
| | | |
| | | import org.springblade.common.node.TreeIntegerNode; |
| | | import org.springblade.core.excel.util.ExcelUtil; |
| | | import org.springblade.core.mp.support.Condition; |
| | | import org.springblade.core.mp.support.Query; |
| | | import org.springblade.core.tool.api.R; |
| | | import org.springblade.core.tool.utils.Func; |
| | | import org.springblade.modules.label.vo.LabelVO; |
| | | import org.springblade.modules.category.excel.CategoryExcel; |
| | | import org.springblade.modules.category.excel.CategoryImporter; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import org.springblade.modules.category.entity.CategoryEntity; |
| | | import org.springblade.modules.category.vo.CategoryVO; |
| | | import org.springblade.modules.category.wrapper.CategoryWrapper; |
| | | import org.springblade.modules.category.service.ICategoryService; |
| | | |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | import java.util.List; |
| | | |
| | | /** |
| | |
| | | return R.data(categoryService.getCategory(category)); |
| | | } |
| | | |
| | | /** |
| | | * 天地图poi 导入 |
| | | */ |
| | | @PostMapping("/import-category") |
| | | public R importCategory(MultipartFile file, Integer isCovered) { |
| | | CategoryImporter categoryImporter = new CategoryImporter(categoryService, isCovered == 1); |
| | | ExcelUtil.save(file, categoryImporter, CategoryExcel.class); |
| | | return R.success("操作成功"); |
| | | } |
| | | |
| | | |
| | | } |