mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-06-17 05:39:50 +08:00
Merge branch 'dev' of http://192.168.2.2:8099/jsowell/jsowell-charger-web into dev
This commit is contained in:
@@ -38,6 +38,7 @@ import com.jsowell.pile.domain.ClearingWithdrawInfo;
|
|||||||
import com.jsowell.pile.domain.MemberBasicInfo;
|
import com.jsowell.pile.domain.MemberBasicInfo;
|
||||||
import com.jsowell.pile.dto.PayOrderDTO;
|
import com.jsowell.pile.dto.PayOrderDTO;
|
||||||
import com.jsowell.pile.service.*;
|
import com.jsowell.pile.service.*;
|
||||||
|
import com.jsowell.pile.vo.base.MerchantInfoVO;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
import org.apache.commons.collections4.CollectionUtils;
|
import org.apache.commons.collections4.CollectionUtils;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
@@ -264,6 +265,19 @@ public class AdapayService {
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 审核失败
|
||||||
|
if (Constants.TWO.equals(adapayMemberAccount.getStatus())) {
|
||||||
|
AdapayCorpMemberVO adapayCorpMemberVO = new AdapayCorpMemberVO();
|
||||||
|
MerchantInfoVO merchantInfoVO = pileMerchantInfoService.getMerchantInfoVO(adapayMemberAccount.getMerchantId());
|
||||||
|
if (merchantInfoVO != null) {
|
||||||
|
adapayCorpMemberVO.setName(merchantInfoVO.getMerchantName());
|
||||||
|
}
|
||||||
|
adapayCorpMemberVO.setAuditState("B");
|
||||||
|
adapayCorpMemberVO.setAuditDesc(adapayMemberAccount.getRemark());
|
||||||
|
map.put("adapayCorpMember", adapayCorpMemberVO);
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
// 通过merchantId获取appId
|
// 通过merchantId获取appId
|
||||||
String wechatAppId = pileMerchantInfoService.queryAppIdByMerchantId(merchantId);
|
String wechatAppId = pileMerchantInfoService.queryAppIdByMerchantId(merchantId);
|
||||||
|
|
||||||
|
|||||||
@@ -23,6 +23,8 @@ import org.apache.commons.collections4.CollectionUtils;
|
|||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
import java.math.RoundingMode;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -69,6 +71,11 @@ public class MemberGroupServiceImpl implements MemberGroupService {
|
|||||||
if (CollectionUtils.isEmpty(resultList)) {
|
if (CollectionUtils.isEmpty(resultList)) {
|
||||||
return Lists.newArrayList();
|
return Lists.newArrayList();
|
||||||
}
|
}
|
||||||
|
for (MemberGroupVO memberGroupVO : resultList) {
|
||||||
|
BigDecimal discount = memberGroupVO.getDiscount();
|
||||||
|
// 返回给前端乘以10
|
||||||
|
memberGroupVO.setDiscount(discount.multiply(BigDecimal.TEN));
|
||||||
|
}
|
||||||
return resultList;
|
return resultList;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -89,9 +96,24 @@ public class MemberGroupServiceImpl implements MemberGroupService {
|
|||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (isBetween(memberGroup.getDiscount())) {
|
||||||
|
// 入库除以10
|
||||||
|
memberGroup.setDiscount(memberGroup.getDiscount().divide(BigDecimal.TEN, 2, RoundingMode.DOWN));
|
||||||
|
}
|
||||||
return memberGroupMapper.insertMemberGroup(memberGroup);
|
return memberGroupMapper.insertMemberGroup(memberGroup);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private boolean isBetween(BigDecimal price){
|
||||||
|
BigDecimal start = BigDecimal.ZERO;
|
||||||
|
BigDecimal end = BigDecimal.TEN;
|
||||||
|
return isBetween(price, start, end);
|
||||||
|
}
|
||||||
|
|
||||||
|
private boolean isBetween(BigDecimal price, BigDecimal start, BigDecimal end){
|
||||||
|
return price.compareTo(start) > 0 && price.compareTo(end) < 0;
|
||||||
|
}
|
||||||
|
|
||||||
// 生成编号
|
// 生成编号
|
||||||
private String generateGroupCode() {
|
private String generateGroupCode() {
|
||||||
while (true) {
|
while (true) {
|
||||||
|
|||||||
@@ -312,13 +312,6 @@ public class PileMerchantInfoServiceImpl implements PileMerchantInfoService {
|
|||||||
if (pileMerchantInfo == null) {
|
if (pileMerchantInfo == null) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
// MerchantInfoVO vo = MerchantInfoVO.builder()
|
|
||||||
// .merchantId(merchantId)
|
|
||||||
// .merchantName(pileMerchantInfo.getMerchantName())
|
|
||||||
// .merchantTel(pileMerchantInfo.getServicePhone())
|
|
||||||
// .organizationCode(pileMerchantInfo.getOrganizationCode())
|
|
||||||
// .deptId(pileMerchantInfo.getDeptId())
|
|
||||||
// .build();
|
|
||||||
return conversion2MerchantInfoVO(pileMerchantInfo);
|
return conversion2MerchantInfoVO(pileMerchantInfo);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -104,7 +104,11 @@
|
|||||||
<dict-tag :options="dict.type.group_type" :value="scope.row.groupType" />
|
<dict-tag :options="dict.type.group_type" :value="scope.row.groupType" />
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="折扣率" align="center" prop="discount" />
|
<el-table-column label="折扣率" align="center" prop="discount" >
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span>{{ scope.row.discount }}折</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
|
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
|
||||||
|
|||||||
Reference in New Issue
Block a user