Merge branch 'dev' into merge_adapay

# Conflicts:
#	jsowell-admin/src/main/java/com/jsowell/api/uniapp/PayController.java
#	jsowell-admin/src/main/resources/application-dev.yml
This commit is contained in:
2023-09-08 15:48:57 +08:00
35 changed files with 3083 additions and 168 deletions

View File

@@ -36,8 +36,6 @@ import java.util.Map;
@RestController
@RequestMapping("/uniapp/pay")
public class PayController extends BaseController {
@Autowired
private MemberService memberService;
@Autowired
private OrderService orderService;
@@ -48,6 +46,9 @@ public class PayController extends BaseController {
@Autowired
private IMemberBasicInfoService memberBasicInfoService;
@Autowired
private MemberService memberService;
/**
* 充值余额支付/微信余额充值
* 提供给小程序使用
@@ -128,8 +129,7 @@ public class PayController extends BaseController {
if (isLock) {
String appId = request.getHeader("appId");
dto.setWechatAppId(appId);
map = orderService.payOrderV2(dto);
// map = orderService.payOrder(dto);
map = orderService.payOrder(dto);
}
response = new RestApiResponse<>(map);
} catch (BusinessException e) {

View File

@@ -147,7 +147,7 @@ public class PileController extends BaseController {
*/
@PostMapping("/remoteGroundLock")
public RestApiResponse<?> remoteGroundLock(HttpServletRequest request, @RequestBody RemoteGroundLockDTO dto) {
logger.info("遥控地锁指令 params:{}", JSONObject.toJSONString(dto));
// logger.info("遥控地锁指令 params:{}", JSONObject.toJSONString(dto));
RestApiResponse<?> response = null;
try {
// 校验参数

View File

@@ -244,6 +244,7 @@ public class TempController extends BaseController {
/**
* 运营商分账手动接口
* 前提条件是已经计算好订单日报了
* http://localhost:8080/temp/orderSplittingOperations
*
* @return
@@ -419,4 +420,20 @@ public class TempController extends BaseController {
}
return new RestApiResponse<>();
}
/**
* 更新会员的余额充值记录
*/
public RestApiResponse<?> updateMemberAdapayRecord(ApplyRefundDTO dto) {
try {
List<String> memberIdList = dto.getMemberIdList();
for (String memberId : memberIdList) {
tempService.updateMemberAdapayRecord(memberId);
}
} catch (Exception e) {
logger.error("批量订单退款error", e);
}
return null;
}
}

View File

@@ -781,12 +781,12 @@ public class OrderService {
.build()
);
// 余额支付
// result.add(
// PayModeVO.builder()
// .payModeCode(OrderPayModeEnum.PAYMENT_OF_BALANCE.getValue())
// .payModeName(OrderPayModeEnum.PAYMENT_OF_BALANCE.getLabel())
// .build()
// );
result.add(
PayModeVO.builder()
.payModeCode(OrderPayModeEnum.PAYMENT_OF_BALANCE.getValue())
.payModeName(OrderPayModeEnum.PAYMENT_OF_BALANCE.getLabel())
.build()
);
}
return result;
}

View File

@@ -441,4 +441,10 @@ public class TempService {
// logger.info("批量进行问题订单退款orderCode:{}, result:{}", orderBasicInfo.getOrderCode(), JSON.toJSONString(result));
}
}
public void updateMemberAdapayRecord(String memberId) {
// 查询
List<MemberAdapayRecord> memberAdapayRecordList = memberAdapayRecordService.selectAdapayRecordList(memberId, ScenarioEnum.BALANCE.getValue());
}
}

View File

@@ -0,0 +1,99 @@
package com.jsowell.web.controller.pile;
import java.util.List;
import javax.servlet.http.HttpServletResponse;
import com.jsowell.pile.service.OrderPileOccupyService;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import com.jsowell.common.annotation.Log;
import com.jsowell.common.core.controller.BaseController;
import com.jsowell.common.core.domain.AjaxResult;
import com.jsowell.common.enums.BusinessType;
import com.jsowell.pile.domain.OrderPileOccupy;
import com.jsowell.common.util.poi.ExcelUtil;
import com.jsowell.common.core.page.TableDataInfo;
/**
* 占桩订单Controller
*
* @author jsowell
* @date 2023-09-08
*/
@RestController
@RequestMapping("/pile/occupy")
public class OrderPileOccupyController extends BaseController {
@Autowired
private OrderPileOccupyService orderPileOccupyService;
/**
* 查询占桩订单列表
*/
@PreAuthorize("@ss.hasPermi('pile:occupy:list')")
@GetMapping("/list")
public TableDataInfo list(OrderPileOccupy orderPileOccupy) {
startPage();
List<OrderPileOccupy> list = orderPileOccupyService.selectOrderPileOccupyList(orderPileOccupy);
return getDataTable(list);
}
/**
* 导出占桩订单列表
*/
@PreAuthorize("@ss.hasPermi('pile:occupy:export')")
@Log(title = "占桩订单", businessType = BusinessType.EXPORT)
@PostMapping("/export")
public void export(HttpServletResponse response, OrderPileOccupy orderPileOccupy) {
List<OrderPileOccupy> list = orderPileOccupyService.selectOrderPileOccupyList(orderPileOccupy);
ExcelUtil<OrderPileOccupy> util = new ExcelUtil<OrderPileOccupy>(OrderPileOccupy.class);
util.exportExcel(response, list, "占桩订单数据");
}
/**
* 获取占桩订单详细信息
*/
@PreAuthorize("@ss.hasPermi('pile:occupy:query')")
@GetMapping(value = "/{id}")
public AjaxResult getInfo(@PathVariable("id") Long id) {
return AjaxResult.success(orderPileOccupyService.selectByPrimaryKey(id.intValue()));
}
/**
* 新增占桩订单
*/
@PreAuthorize("@ss.hasPermi('pile:occupy:add')")
@Log(title = "占桩订单", businessType = BusinessType.INSERT)
@PostMapping
public AjaxResult add(@RequestBody OrderPileOccupy orderPileOccupy) {
return toAjax(orderPileOccupyService.insert(orderPileOccupy));
}
/**
* 修改占桩订单
*/
@PreAuthorize("@ss.hasPermi('pile:occupy:edit')")
@Log(title = "占桩订单", businessType = BusinessType.UPDATE)
@PutMapping
public AjaxResult edit(@RequestBody OrderPileOccupy orderPileOccupy) {
return toAjax(orderPileOccupyService.updateByPrimaryKey(orderPileOccupy));
}
/**
* 删除占桩订单
*/
// @PreAuthorize("@ss.hasPermi('pile:occupy:remove')")
// @Log(title = "占桩订单", businessType = BusinessType.DELETE)
// @DeleteMapping("/{ids}")
// public AjaxResult remove(@PathVariable Long[] ids)
// {
// return toAjax(orderPileOccupyService.deleteByPrimaryKey(ids));
// }
}

View File

@@ -38,8 +38,8 @@ spring:
master:
url: jdbc:mysql://192.168.2.2:3306/jsowell_dev?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
username: jsowell_dev
#url: jdbc:mysql://121.40.174.65:3306/jsowell_prd?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
#username: jsowell
# url: jdbc:mysql://192.168.2.2:3306/jsowell_prd_copy?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
# username: jsowell_prd_copy
password: 123456
# 从库数据源
slave: