jyy
2021-01-25 ae6d2af141f18e40956d98cea765fec838985817
1、新增默认头像设置
2、修改知识库bug
3、修改点赞bug
9 files modified
77 ■■■■ changed files
zq-erp/src/main/java/com/matrix/system/app/action/ApiFollowupAction.java 8 ●●●● patch | view | raw | blame | history
zq-erp/src/main/java/com/matrix/system/constance/Dictionary.java 4 ●●● patch | view | raw | blame | history
zq-erp/src/main/java/com/matrix/system/hive/action/ProjUseController.java 10 ●●●●● patch | view | raw | blame | history
zq-erp/src/main/java/com/matrix/system/hive/service/imp/SysVipInfoServiceImpl.java 25 ●●●●● patch | view | raw | blame | history
zq-erp/src/main/resources/config/application.properties 14 ●●●● patch | view | raw | blame | history
zq-erp/src/main/resources/config/prd/application.properties 6 ●●●● patch | view | raw | blame | history
zq-erp/src/main/resources/config/test/application.properties 3 ●●●●● patch | view | raw | blame | history
zq-erp/src/main/resources/mybatis/mapper/hive/ArticleDao.xml 3 ●●●● patch | view | raw | blame | history
zq-erp/src/main/resources/templates/views/admin/hive/beautySalon/vip.html 4 ●●●● patch | view | raw | blame | history
zq-erp/src/main/java/com/matrix/system/app/action/ApiFollowupAction.java
@@ -113,18 +113,18 @@
        SysUsers user = WebUtil.getSessionAttribute(MatrixConstance.LOGIN_KEY);
        SysFollowup followup = followupDao.selectById(id);
        String zans=followup.getZans();
        if(StringUtils.isBlank(zans)){
        if(StringUtils.isNotBlank(zans)){
            List<Long> zanIds = StringUtils.strToCollToLong(zans, ",");
            List<Long> zaned = zanIds.stream().filter(zanid -> zanid.equals(user.getSuId())).collect(Collectors.toList());
            if(CollectionUtils.isEmpty(zaned)){
            if(CollectionUtils.isNotEmpty(zaned)){
                //取消赞
                List<Long> newZaned = zanIds.stream().filter(zanid -> !zanid.equals(user.getSuId())).collect(Collectors.toList());
                zans=StringUtils.collToStr(newZaned,",");
            }else{
                //点赞
                zaned.add(user.getSuId());
                zans=StringUtils.collToStr(zaned,",");
                zanIds.add(user.getSuId());
                zans=StringUtils.collToStr(zanIds,",");
            }
        }else{
            //直接点赞
zq-erp/src/main/java/com/matrix/system/constance/Dictionary.java
@@ -567,5 +567,7 @@
    String ACHIEVE_TYPE_CASH = "现金业绩";
    String ACHIEVE_TYPE_CARD = "划扣业绩";
    String SEX_MAN ="男";
    String SEX_WOMAN ="女";
}
zq-erp/src/main/java/com/matrix/system/hive/action/ProjUseController.java
@@ -23,6 +23,7 @@
import com.matrix.system.hive.service.SysProjUseService;
import com.matrix.system.hive.service.SysProjuseFreezeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Controller;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.web.bind.annotation.RequestMapping;
@@ -68,6 +69,13 @@
    @Autowired
    MoneyCardUseDao moneyCardUseDao;
    @Value("${default.vip.photo.woman}")
    String defaultWoman;
    @Value("${default.vip.photo.man}")
    String defaultman;
    public static final String fnCode = "projUse";
@@ -359,6 +367,7 @@
                vipInfo = new SysVipInfo();
                vipInfo.setShopId(sysUsers.getShopId());
                vipInfo.setPhone(telStr);
                vipInfo.setPhoto(defaultWoman);
                vipInfo.setName(objects.get(0).toString());
                vipInfoDao.insert(vipInfo);
            }
@@ -415,6 +424,7 @@
                vipInfo = new SysVipInfo();
                vipInfo.setShopId(sysUsers.getShopId());
                vipInfo.setPhone(telStr);
                vipInfo.setPhoto(defaultWoman);
                vipInfo.setName(objects.get(0).toString());
                vipInfoDao.insert(vipInfo);
            }
zq-erp/src/main/java/com/matrix/system/hive/service/imp/SysVipInfoServiceImpl.java
@@ -13,7 +13,6 @@
import com.matrix.system.app.vo.VipInfoListVo;
import com.matrix.system.common.bean.SysUsers;
import com.matrix.system.common.tools.DataAuthUtil;
import com.matrix.system.common.tools.PasswordUtil;
import com.matrix.system.common.tools.ServiceUtil;
import com.matrix.system.constance.Dictionary;
import com.matrix.system.constance.TableMapping;
@@ -24,6 +23,7 @@
import com.matrix.system.hive.pojo.VipInfoVo;
import com.matrix.system.hive.service.SysVipInfoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
@@ -59,6 +59,14 @@
    @Autowired
    private SysVipLabelDao sysVipLabelDao;
    @Value("${default.vip.photo.woman}")
    String defaultWoman;
    @Value("${default.vip.photo.man}")
    String defaultMan;
    /**
     * 新增会员储值卡
@@ -106,6 +114,11 @@
        sysVipInfo.setPointAll(0);
        sysVipInfo.setIsDeal(SysVipInfo.UNDEAL_VIP);
        sysVipInfo.setZjm(StringUtils.toHanyuPinyin(sysVipInfo.getVipName())+","+StringUtils.toHeadWordHanyuPinyin(sysVipInfo.getVipName()));
        if(sysVipInfo.getSex().equals(Dictionary.SEX_MAN)){
            sysVipInfo.setPhoto(defaultMan);
        }else{
            sysVipInfo.setPhoto(defaultWoman);
        }
        int i=sysVipInfoDao.insert(sysVipInfo);
        modifyVipWithOtherInfo(sysVipInfo);
        //创建用户默认储值卡
@@ -338,6 +351,11 @@
        SysUsers users = (SysUsers) WebUtil.getSession().getAttribute(MatrixConstance.LOGIN_KEY);
        sysVipInfo.setCompanyId(users.getCompanyId());
        sysVipInfo.setShopId(users.getShopId());
        if(sysVipInfo.getSex().equals(Dictionary.SEX_MAN)){
            sysVipInfo.setPhoto(defaultMan);
        }else{
            sysVipInfo.setPhoto(defaultWoman);
        }
        int i=sysVipInfoDao.insert(sysVipInfo);
        modifyVipWithOtherInfo(sysVipInfo);
        return i;
@@ -482,6 +500,11 @@
        vipInfo.setPointAll(0);
        vipInfo.setIsDeal(SysVipInfo.UNDEAL_VIP);
        vipInfo.setZjm(StringUtils.toHanyuPinyin(vipInfo.getVipName())+","+StringUtils.toHeadWordHanyuPinyin(vipInfo.getVipName()));
        if(vipInfo.getSex().equals(Dictionary.SEX_MAN)){
            vipInfo.setPhoto(defaultMan);
        }else{
            vipInfo.setPhoto(defaultWoman);
        }
        int i=sysVipInfoDao.insert(vipInfo);
        if (CollectionUtils.isNotEmpty(addVipDto.getLabels())) {
zq-erp/src/main/resources/config/application.properties
@@ -4,9 +4,14 @@
#线上测试环境
spring.datasource.username=ct_test
spring.datasource.password=123456
spring.datasource.url=jdbc:mysql://120.27.238.55:3306/hive_test?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=CONVERT_TO_NULL&allowMultiQueries=true&transformedBitIsBoolean=true&serverTimezone=GMT%2B8
#spring.datasource.username=ct_test
#spring.datasource.password=123456
#spring.datasource.url=jdbc:mysql://120.27.238.55:3306/hive_test?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=CONVERT_TO_NULL&allowMultiQueries=true&transformedBitIsBoolean=true&serverTimezone=GMT%2B8
spring.datasource.username=chuhuan
spring.datasource.password=chuhuan
spring.datasource.url=jdbc:mysql://175.6.132.141:3306/hive_v2_test?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=CONVERT_TO_NULL&allowMultiQueries=true&transformedBitIsBoolean=true&serverTimezone=GMT%2B8
@@ -63,4 +68,7 @@
swagger.security.username=admin
swagger.security.password=admin
#默认头像
default.vip.photo.woman=https://filehive2.jyymatrix.cc/uploadeFile/20210125/db53552e688040afb286686f081e1e68f3fe946f75624598828f01898635152e.png
default.vip.photo.man=https://filehive2.jyymatrix.cc/uploadeFile/20210125/3642f1d827c44c76832fea106c85e0f89e089c16cbcc4dd0a82bb52b9ac700f4.png
zq-erp/src/main/resources/config/prd/application.properties
@@ -60,4 +60,8 @@
#定时任务
scheduling.enabled=true
swagger.enable=false
swagger.enable=false
#默认头像
default.vip.photo.woman=https://filehive2.jyymatrix.cc/uploadeFile/20210125/db53552e688040afb286686f081e1e68f3fe946f75624598828f01898635152e.png
default.vip.photo.man=https://filehive2.jyymatrix.cc/uploadeFile/20210125/3642f1d827c44c76832fea106c85e0f89e089c16cbcc4dd0a82bb52b9ac700f4.png
zq-erp/src/main/resources/config/test/application.properties
@@ -69,3 +69,6 @@
swagger.security.password=admin
#默认头像
default.vip.photo.woman=https://filehive2.jyymatrix.cc/uploadeFile/20210125/db53552e688040afb286686f081e1e68f3fe946f75624598828f01898635152e.png
default.vip.photo.man=https://filehive2.jyymatrix.cc/uploadeFile/20210125/3642f1d827c44c76832fea106c85e0f89e089c16cbcc4dd0a82bb52b9ac700f4.png
zq-erp/src/main/resources/mybatis/mapper/hive/ArticleDao.xml
@@ -440,7 +440,8 @@
    <select id="selectApiArticleListInPage" resultMap="ArticleMap">
        select * from article a
        inner join article_type b on a.type_id=b.id and find_in_set(#{record.typeId}, b.parent_ids)
        inner join article_type b on a.type_id=b.id
        where  a.type_id=#{record.typeId} or find_in_set(#{record.typeId}, b.parent_ids)
        order by a.createtiem desc
        <if test="pageVo !=null"><!-- 判断pageVo对象是否为空 -->
            <if test="pageVo.offset >=0  and pageVo.limit >0">
zq-erp/src/main/resources/templates/views/admin/hive/beautySalon/vip.html
@@ -647,7 +647,7 @@
    var app = new Vue({
        el: '#app',
        data : {
            circleUrl : "https://cube.elemecdn.com/0/88/03b0d39583f48206768a7534e55bcpng.png",
            circleUrl : "",
            activeName : 'vipInfo',
            tags : {
                tags : [],
@@ -762,7 +762,7 @@
                    let data = loj[0].result.rows[0];
                    _this.vipInfo = {};
                    _this.vipInfo = data;
                    _this.circleUrl= _this.vipInfo.photo;
                    if (data.sysOrder != null) {
                        _this.vipInfo.totalMoney = data.sysOrder.zkTotal;
                        _this.vipInfo.totalTimes = data.sysOrder.times;