Merge branch 'score_shop' of http://120.27.238.55:7000/r/beauty-erp into score_shop
1 files added
13 files modified
| | |
| | | import org.springframework.boot.SpringApplication; |
| | | import org.springframework.boot.autoconfigure.SpringBootApplication; |
| | | import org.springframework.context.annotation.ComponentScan; |
| | | import org.springframework.scheduling.annotation.EnableAsync; |
| | | |
| | | /** |
| | | * spring boot入口 |
| | |
| | | * @description 容器添加组件 |
| | | * @date 2019-06-14 15:50 |
| | | */ |
| | | @Configuration |
| | | @Configuration() |
| | | @PropertySource("classpath:config/system.properties") |
| | | public class MvcCoreConfig implements WebMvcConfigurer { |
| | | |
| | |
| | | package com.matrix.config; |
| | | |
| | | import org.springframework.context.annotation.Configuration; |
| | | import com.matrix.core.tools.LogUtil; |
| | | import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty; |
| | | import org.springframework.scheduling.annotation.EnableScheduling; |
| | | import org.springframework.stereotype.Component; |
| | | |
| | | @Configuration |
| | | @Component |
| | | @EnableScheduling |
| | | @ConditionalOnProperty(name = "scheduling.enabled", havingValue= "true") |
| | | public class TaskScheduleConfig { |
| | | |
| | | public TaskScheduleConfig(){ |
| | | LogUtil.debug("**********定时任务启动**********"); |
| | | } |
| | | } |
| | |
| | | |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.matrix.component.redis.RedisClient; |
| | | import com.matrix.core.constance.MatrixConstance; |
| | | import com.matrix.core.pojo.AjaxResult; |
| | | import com.matrix.core.tools.*; |
| | | import com.matrix.system.app.authority.AppAuthorityManager; |
| | |
| | | import com.matrix.system.common.authority.strategy.AccountPasswordLogin; |
| | | import com.matrix.system.common.authority.strategy.LoginStrategy; |
| | | import com.matrix.system.common.bean.SysUsers; |
| | | import com.matrix.system.common.constance.AppConstance; |
| | | import com.matrix.system.common.dao.BusParameterSettingsDao; |
| | | import com.matrix.system.common.service.SysUsersService; |
| | | import com.matrix.system.common.tools.PasswordUtil; |
| | |
| | | |
| | | |
| | | |
| | | @ApiOperation(value = "获取app配置", notes = "获取app配置") |
| | | @ApiResponses({ |
| | | @ApiResponse(code = 200, message = "ok", response = AppVersion.class) |
| | | }) |
| | | @GetMapping(value = "/findAppSettings") |
| | | public AjaxResult findAppSettings() { |
| | | SysUsers user = WebUtil.getSessionAttribute(MatrixConstance.LOGIN_KEY); |
| | | AjaxResult result = AjaxResult.buildSuccessInstance("查询成功"); |
| | | result.putInMap(AppConstance.APP_BANNER_GL, busParameterSettingsDao.selectCompanyParamByCode(AppConstance.APP_BANNER_GL,user.getCompanyId())); |
| | | return result; |
| | | } |
| | | |
| | | |
| | | |
| | | |
New file |
| | |
| | | package com.matrix.system.app.action; |
| | | |
| | | import com.matrix.core.constance.MatrixConstance; |
| | | import com.matrix.core.pojo.AjaxResult; |
| | | import com.matrix.core.tools.WebUtil; |
| | | import com.matrix.system.common.bean.SysUsers; |
| | | import com.matrix.system.common.constance.AppConstance; |
| | | import com.matrix.system.common.dao.BusParameterSettingsDao; |
| | | import com.matrix.system.hive.bean.AppVersion; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import io.swagger.annotations.ApiResponse; |
| | | import io.swagger.annotations.ApiResponses; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.CrossOrigin; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | /** |
| | | * @author jyy |
| | | * @date 2020-12-21 |
| | | **/ |
| | | @CrossOrigin(origins = "*") |
| | | @Api(value = "ApiSettingAction", tags = "配置查询类") |
| | | @RestController |
| | | @RequestMapping(value = "/api/setting") |
| | | public class ApiSettingAction { |
| | | |
| | | |
| | | @Autowired |
| | | private BusParameterSettingsDao busParameterSettingsDao; |
| | | |
| | | |
| | | @ApiOperation(value = "获取app配置", notes = "获取app配置") |
| | | @ApiResponses({ |
| | | @ApiResponse(code = 200, message = "ok", response = AppVersion.class) |
| | | }) |
| | | @GetMapping(value = "/findAppSettings") |
| | | public AjaxResult findAppSettings() { |
| | | SysUsers user = WebUtil.getSessionAttribute(MatrixConstance.LOGIN_KEY); |
| | | AjaxResult result = AjaxResult.buildSuccessInstance("查询成功"); |
| | | result.putInMap(AppConstance.APP_BANNER_GL, busParameterSettingsDao.selectCompanyParamByCode(AppConstance.APP_BANNER_GL,user.getCompanyId())); |
| | | return result; |
| | | } |
| | | |
| | | } |
| | |
| | | package com.matrix.system.job; |
| | | |
| | | import com.matrix.core.tools.LogUtil; |
| | | import com.matrix.system.constance.Dictionary; |
| | | import com.matrix.system.hive.bean.MoneyCardUse; |
| | | import com.matrix.system.hive.bean.SysProjUse; |
| | |
| | | |
| | | @Scheduled(cron = "0 0 0 * * ?") |
| | | public void setProjUseToInvalid() { |
| | | LogUtil.info("#项目,套餐失效任务处理#"); |
| | | List<SysProjUse> sysProjUses = sysProjUseDao.selectHasValidProjUse(); |
| | | |
| | | List<MoneyCardUse> moneyCardUses = moneyCardUseDao.selectHasValidMoneyCardUse(); |
| | |
| | | |
| | | import com.matrix.component.rabbitmq.RabiitMqTemplate; |
| | | import com.matrix.core.tools.LogUtil; |
| | | import com.matrix.system.common.bean.SysUsers; |
| | | import com.matrix.system.constance.Dictionary; |
| | | import com.matrix.system.hive.bean.MoneyCardUse; |
| | | import com.matrix.system.hive.bean.SysProjServices; |
| | | import com.matrix.system.hive.bean.SysProjUse; |
| | | import com.matrix.system.hive.dao.MoneyCardUseDao; |
| | | import com.matrix.system.hive.dao.SysProjServicesDao; |
| | | import com.matrix.system.hive.dao.SysProjUseDao; |
| | | import com.matrix.system.hive.plugin.util.CollectionUtils; |
| | | import com.matrix.system.shopXcx.mqTask.MQTaskRouting; |
| | | import com.matrix.system.wechart.templateMsg.UniformMsgParam; |
| | |
| | | import org.springframework.scheduling.annotation.Scheduled; |
| | | import org.springframework.stereotype.Component; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.stream.Collectors; |
| | | |
| | |
| | | /** |
| | | * 每分钟执行一次 |
| | | */ |
| | | @Scheduled(cron = "0 0/1 * * * ?") |
| | | @Scheduled(cron = "0/30 * * * * ?") |
| | | public void serviceOvertimeNotice() { |
| | | |
| | | List<SysProjServices> needNoticeService=projServicesDao.selectNeedNoticeService(); |
| | |
| | | import com.matrix.system.shopXcx.dao.ShopActivitiesDao; |
| | | import com.matrix.system.shopXcx.dao.ShopActivitiesGroupJoinDao; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import org.springframework.context.annotation.Configuration; |
| | | import org.springframework.scheduling.annotation.Scheduled; |
| | | |
| | |
| | | @Autowired |
| | | private ShopActivitiesDao shopActivitiesDao ; |
| | | |
| | | @Value("${scheduling.enabled}") |
| | | private boolean taskSwitch; |
| | | |
| | | |
| | | |
| | | @Scheduled(cron = "0 */1 * * * ?") |
| | | public boolean executeExt() { |
| | | if (taskSwitch) { |
| | | LogUtil.info("#开团时间超时任务处理#"); |
| | | List<ShopActivitiesGroupJoin> groupJoins = shopActivitiesGroupJoinDao.selectGroupJoinWithEnd(); |
| | | ShopActivityTimeOutQuartz timeOutQuartz = new ShopActivityTimeOutQuartz(); |
| | |
| | | timeOutQuartz.doVirtualGroup(groupJoin); |
| | | } else { |
| | | timeOutQuartz.doUnVirtualGroup(groupJoin); |
| | | } |
| | | } |
| | | } |
| | | } |
| | |
| | | import com.matrix.system.shopXcx.dao.ShopActivitiesGroupJoinUserDao; |
| | | import com.matrix.system.shopXcx.dao.ShopOrderDao; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import org.springframework.context.annotation.Configuration; |
| | | import org.springframework.scheduling.annotation.Scheduled; |
| | | |
| | |
| | | @Autowired |
| | | private ShopActivitiesGroupJoinDao shopActivitiesGroupJoinDao; |
| | | |
| | | @Value("${scheduling.enabled}") |
| | | private boolean taskSwitch; |
| | | |
| | | |
| | | @Scheduled(cron = "0 */1 * * * ?") |
| | | public void executeExt() { |
| | | if (taskSwitch) { |
| | | |
| | | LogUtil.info("#拼团支付超时处理任务#"); |
| | | List<ShopActivitiesGroupJoinUser> joinUserList = shopActivitiesGroupJoinUserDao.selectGroupJoinUserEnd(); |
| | | if (CollectionUtils.isNotEmpty(joinUserList)) { |
| | |
| | | shopOrder.setOrderStatus(ShopOrder.ORDER_STATUS_CANCEL); |
| | | shopOrderDao.updateByModel(shopOrder); |
| | | } |
| | | } |
| | | |
| | | } |
| | | } |
| | | } |
| | |
| | | import com.matrix.system.shopXcx.bean.*; |
| | | import com.matrix.system.shopXcx.dao.*; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import org.springframework.context.annotation.Configuration; |
| | | import org.springframework.scheduling.annotation.Scheduled; |
| | | |
| | |
| | | @Autowired |
| | | private ShopActivitiesGroupJoinUserDao shopActivitiesGroupJoinUserDao; |
| | | |
| | | @Value("${scheduling.enabled}") |
| | | private boolean taskSwitch; |
| | | |
| | | |
| | | @Scheduled(cron = "0 */1 * * * ?") |
| | | public void executeExt() { |
| | | if (taskSwitch) { |
| | | |
| | | LogUtil.info("#拼团活动自动结束任务#"); |
| | | List<ShopActivities> actList = shopActivitiesDao.selectShopActivitiesHasEnd(); |
| | | if (CollectionUtils.isNotEmpty(actList)) { |
| | |
| | | } |
| | | } |
| | | } |
| | | } |
| | | |
| | | } |
| | | |
| | | /** |
| | |
| | | @Configuration |
| | | public class ShopAutomaticReceiveQuartz { |
| | | |
| | | @Value("${scheduling.enabled}") |
| | | private boolean taskSwitch; |
| | | |
| | | @Autowired |
| | | private ShopDeliveryInfoDao shopDeliveryInfoDao; |
| | | |
| | |
| | | |
| | | @Scheduled(cron = "0/30 * * * * ?") |
| | | public void executeExt() { |
| | | if(taskSwitch) { |
| | | |
| | | |
| | | LogUtil.info("#15天自动收货任务处理#"); |
| | | |
| | | List<ShopDeliveryInfo> shopDeliveryInfos = shopDeliveryInfoDao.selectAutomaticReceive(); |
| | | int flag = 0; |
| | |
| | | } |
| | | } |
| | | LogUtil.info("自动确认收货更新条数:" + flag); |
| | | } |
| | | |
| | | } |
| | | |
| | | } |
| | |
| | | import com.matrix.core.tools.LogUtil; |
| | | import com.matrix.system.shopXcx.dao.ShopCouponDao; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import org.springframework.context.annotation.Configuration; |
| | | import org.springframework.scheduling.annotation.Scheduled; |
| | | |
| | |
| | | |
| | | |
| | | |
| | | @Value("${scheduling.enabled}") |
| | | private boolean taskSwitch; |
| | | |
| | | @Autowired |
| | | private ShopCouponDao shopCouponDao; |
| | | |
| | | @Scheduled(cron = "0 */1 * * * ?") |
| | | public void executeExt() { |
| | | if(taskSwitch){ |
| | | int i = shopCouponDao.updateAllCouponStatus(); |
| | | LogUtil.info("优惠券状态更新条数:" + i); |
| | | } |
| | | |
| | | } |
| | | |
| | | |
| | |
| | | groupBuy.pay.timeLimit=30 |
| | | |
| | | #定时任务 |
| | | scheduling.enabled=false |
| | | scheduling.enabled=true |
| | | |
| | | swagger.enable=true |
| | | swagger.security.username=admin |
| | |
| | | this.loadInfo(); |
| | | window.addEventListener("keydown", this.keydown); |
| | | //初始化编辑器 |
| | | ue = UE.getEditor('description'); |
| | | ue = UE.getEditor('description', { |
| | | toolbars: [ |
| | | [ |
| | | 'anchor', |
| | | 'bold', //加粗 |
| | | 'indent', //首行缩进 |
| | | 'italic', //斜体 |
| | | 'underline', //下划线 |
| | | 'strikethrough', //删除线 |
| | | 'subscript', //下标 |
| | | 'fontborder', //字符边框 |
| | | 'superscript', //上标 |
| | | 'formatmatch', //格式刷 |
| | | 'pasteplain', //纯文本粘贴模式 |
| | | 'selectall', //全选 |
| | | 'horizontal', //分隔线 |
| | | 'removeformat', //清除格式 |
| | | 'unlink', //取消链接 |
| | | 'inserttitle', //插入标题 |
| | | 'cleardoc', //清空文档 |
| | | 'fontfamily', //字体 |
| | | 'fontsize', //字号 |
| | | 'paragraph', //段落格式 |
| | | 'simpleupload', //单图上传 |
| | | 'insertimage', //多图上传 |
| | | 'link', //超链接 |
| | | 'emotion', //表情 |
| | | 'justifyleft', //居左对齐 |
| | | 'justifyright', //居右对齐 |
| | | 'justifycenter', //居中对齐 |
| | | 'justifyjustify', //两端对齐 |
| | | 'forecolor', //字体颜色 |
| | | 'backcolor', //背景色 |
| | | 'insertorderedlist', //有序列表 |
| | | 'insertunorderedlist', //无序列表 |
| | | 'fullscreen', //全屏 |
| | | 'rowspacingtop', //段前距 |
| | | 'rowspacingbottom', //段后距 |
| | | 'imagecenter', //居中 |
| | | 'lineheight', //行间距 |
| | | 'customstyle', //自定义标题 |
| | | 'autotypeset', //自动排版 |
| | | 'background', //背景 |
| | | ] |
| | | ]}); |
| | | }, |
| | | mounted: function () { |
| | | }, |