| | |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.hutool.core.util.StrUtil; |
| | | import com.xcong.farmer.cms.common.contants.AppContants; |
| | | import com.xcong.farmer.cms.core.template.TemplateConfiguration; |
| | | import com.xcong.farmer.cms.modules.core.service.ICmsCoreService; |
| | | import com.xcong.farmer.cms.modules.system.mapper.WebSetMapper; |
| | |
| | | @Autowired |
| | | private WebSetMapper webSetMapper; |
| | | |
| | | // private final Executor executor = new ThreadPoolExecutor(10, 20, 600, TimeUnit.SECONDS, new LinkedBlockingQueue<Runnable>()); |
| | | |
| | | |
| | | @Override |
| | | public void articleProcess(Map<String, Object> data, String templateName, String templatePath) { |
| | |
| | | } |
| | | |
| | | try { |
| | | cfg.process(data, templateName); |
| | | String finalTemplateName = templateName; |
| | | AppContants.EXECUTOR.execute(() -> { |
| | | cfg.process(data, finalTemplateName); |
| | | }); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | log.error("发布文章出错", e); |
| | |
| | | } |
| | | |
| | | try { |
| | | cfg.process(data, templateName); |
| | | String finalTemplateName = templateName; |
| | | AppContants.EXECUTOR.execute(() -> { |
| | | cfg.process(data, finalTemplateName); |
| | | }); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | log.error("发布栏目错误", e); |
| | |
| | | } |
| | | |
| | | try { |
| | | cfg.process(data, templateName); |
| | | String finalTemplateName = templateName; |
| | | AppContants.EXECUTOR.execute(() -> { |
| | | cfg.process(data, finalTemplateName); |
| | | }); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | log.error("发布首页错误", e); |
| | |
| | | } |
| | | |
| | | try { |
| | | cfg.process(data, templateName); |
| | | String finalTemplateName = templateName; |
| | | AppContants.EXECUTOR.execute(() -> { |
| | | cfg.process(data, finalTemplateName); |
| | | }); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | log.error("发布错误", e); |