logo和名称替换
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import 'package:dio/dio.dart';
|
||||
import 'package:hgmj/tools_base/net/base_resp_bean.dart';
|
||||
import 'package:hgmj/tools_base/net/http_manager.dart';
|
||||
import 'package:wydj/tools_base/net/base_resp_bean.dart';
|
||||
import 'package:wydj/tools_base/net/http_manager.dart';
|
||||
import 'package:uuid/uuid.dart';
|
||||
|
||||
/// 购买相关接口
|
||||
@@ -56,7 +56,8 @@ class BuyService {
|
||||
///[source] 来源页面标识
|
||||
///[experimentId]/[experimentVariant]/[sessionId] VIP 卡皮 A/B:与 /mine/topay 对齐回传
|
||||
///[requestId] 幂等键,见 [_idempotent]
|
||||
static Future<BaseRespBean> buyVip(int? productType, String? productID, String? productName, int? discountedPrice,
|
||||
static Future<BaseRespBean> buyVip(int? productType, String? productID,
|
||||
String? productName, int? discountedPrice,
|
||||
{String? couponId = "",
|
||||
bool? finalPayStatus,
|
||||
String? source,
|
||||
@@ -80,11 +81,18 @@ class BuyService {
|
||||
'contentId': contentId,
|
||||
'checkoutContextId': checkoutContextId,
|
||||
// 空值不传,避免参数错误(DISABLED / 无实验时上游不填)
|
||||
'experimentId': (experimentId != null && experimentId.isNotEmpty) ? experimentId : null,
|
||||
'experimentVariant': (experimentVariant != null && experimentVariant.isNotEmpty) ? experimentVariant : null,
|
||||
'sessionId': (sessionId != null && sessionId.isNotEmpty) ? sessionId : null,
|
||||
'experimentId': (experimentId != null && experimentId.isNotEmpty)
|
||||
? experimentId
|
||||
: null,
|
||||
'experimentVariant':
|
||||
(experimentVariant != null && experimentVariant.isNotEmpty)
|
||||
? experimentVariant
|
||||
: null,
|
||||
'sessionId':
|
||||
(sessionId != null && sessionId.isNotEmpty) ? sessionId : null,
|
||||
};
|
||||
param.removeWhere((k, v) => v == null);
|
||||
return httpManager.fetchResponseByPOST('/product/buy', param: param, options: _idempotent(requestId));
|
||||
return httpManager.fetchResponseByPOST('/product/buy',
|
||||
param: param, options: _idempotent(requestId));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user