|
|
@@ -14,6 +14,7 @@ import com.payment.platform.module.payment.expense.rule.dto.RuleQueryDTO;
|
|
|
import com.payment.platform.module.payment.expense.rule.dto.RuleUpdateDTO;
|
|
|
import com.payment.platform.module.payment.expense.rule.dto.RuleVO;
|
|
|
import lombok.RequiredArgsConstructor;
|
|
|
+import lombok.extern.slf4j.Slf4j;
|
|
|
import org.springframework.stereotype.Service;
|
|
|
import org.springframework.transaction.annotation.Transactional;
|
|
|
|
|
|
@@ -30,6 +31,7 @@ import java.util.stream.Collectors;
|
|
|
* conditionInfo (JSON) 是核心翻译点:前端扁平字段打包存入该 JSON 列,
|
|
|
* 读出时再从 JSON 解包还原为 VO 扁平字段。
|
|
|
*/
|
|
|
+@Slf4j
|
|
|
@Service
|
|
|
@RequiredArgsConstructor
|
|
|
public class RuleService {
|
|
|
@@ -101,6 +103,50 @@ public class RuleService {
|
|
|
ruleMapper.deleteById(exist.getId());
|
|
|
}
|
|
|
|
|
|
+ // ==================== 费控使用规则 (Alipay API stubs) ====================
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 创建费控使用规则
|
|
|
+ * 对应 Python RuleService.create_expense_rule_service
|
|
|
+ * 调用: alipay.ebpp.invoice.institution.expenserule.create
|
|
|
+ * <p>
|
|
|
+ * NOT_IMPL: 接入支付宝 API
|
|
|
+ */
|
|
|
+ public Map<String, Object> createExpense(Map<String, Object> body) {
|
|
|
+ log.warn("未实现: 调用支付宝 alipay.ebpp.invoice.institution.expenserule.create");
|
|
|
+ // NOT_IMPL - 接入支付宝 alipay.ebpp.invoice.institution.expenserule.create
|
|
|
+ log.info("createExpense (STUBBED): body={}", body);
|
|
|
+ return Map.of();
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 编辑使用规则
|
|
|
+ * 对应 Python RuleService.modify_expense_rule_service
|
|
|
+ * 调用: alipay.ebpp.invoice.institution.expenserule.modify
|
|
|
+ * <p>
|
|
|
+ * NOT_IMPL: 接入支付宝 API
|
|
|
+ */
|
|
|
+ public Map<String, Object> modifyExpense(String outBizNo, Map<String, Object> body) {
|
|
|
+ log.warn("未实现: 调用支付宝 alipay.ebpp.invoice.institution.expenserule.modify");
|
|
|
+ // NOT_IMPL - 接入支付宝 alipay.ebpp.invoice.institution.expenserule.modify
|
|
|
+ log.info("modifyExpense (STUBBED): outBizNo={}, body={}", outBizNo, body);
|
|
|
+ return Map.of();
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 删除使用规则
|
|
|
+ * 对应 Python RuleService.delete_expense_rule_service
|
|
|
+ * 调用: alipay.ebpp.invoice.institution.expenserule.delete
|
|
|
+ * <p>
|
|
|
+ * NOT_IMPL: 接入支付宝 API
|
|
|
+ */
|
|
|
+ public Map<String, Object> deleteExpense(String outBizNo, Map<String, Object> body) {
|
|
|
+ log.warn("未实现: 调用支付宝 alipay.ebpp.invoice.institution.expenserule.delete");
|
|
|
+ // NOT_IMPL - 接入支付宝 alipay.ebpp.invoice.institution.expenserule.delete
|
|
|
+ log.info("deleteExpense (STUBBED): outBizNo={}, body={}", outBizNo, body);
|
|
|
+ return Map.of();
|
|
|
+ }
|
|
|
+
|
|
|
// ==================== query helpers ====================
|
|
|
|
|
|
private ExpenseRuleEntity findByRuleId(String ruleId) {
|