Bladeren bron

Merge branch 'master' of http://gogs.hnwmzp.cn/nzk1/Asteria-APP

Abel 1 jaar geleden
bovenliggende
commit
5a2d4914b7
23 gewijzigde bestanden met toevoegingen van 28227 en 27146 verwijderingen
  1. 20 0
      Asteria.xcodeproj/project.pbxproj
  2. 9 0
      Asteria/AppDelegate.m
  3. 4 3
      Asteria/Common/V/AlertMyCartDeleteV.m
  4. 202 10
      Asteria/Fuction/Cart/Cart_CheckoutC.m
  5. 116 4
      Asteria/Fuction/Cart/Cart_MyCartC.m
  6. 30 0
      Asteria/Fuction/Cart/Checkout/ASAddGiftGoodsView.h
  7. 106 0
      Asteria/Fuction/Cart/Checkout/ASAddGiftGoodsView.m
  8. 2 2
      Asteria/Fuction/Cart/Checkout/ASCheckoutGoodsItemCell.m
  9. 16 0
      Asteria/Fuction/Cart/PayManager/ASPaypalManager.h
  10. 22 0
      Asteria/Fuction/Cart/PayManager/ASPaypalManager.m
  11. 3 0
      Asteria/Fuction/Cart/VM/CartVM.h
  12. 2 0
      Podfile
  13. 14 2
      Podfile.lock
  14. 14 2
      Pods/Manifest.lock
  15. 27395 27111
      Pods/Pods.xcodeproj/project.pbxproj
  16. 59 0
      Pods/Target Support Files/Pods-Asteria-NotificationServiceExtension/Pods-Asteria-NotificationServiceExtension-acknowledgements.markdown
  17. 71 0
      Pods/Target Support Files/Pods-Asteria-NotificationServiceExtension/Pods-Asteria-NotificationServiceExtension-acknowledgements.plist
  18. 3 3
      Pods/Target Support Files/Pods-Asteria-NotificationServiceExtension/Pods-Asteria-NotificationServiceExtension.debug.xcconfig
  19. 3 3
      Pods/Target Support Files/Pods-Asteria-NotificationServiceExtension/Pods-Asteria-NotificationServiceExtension.release.xcconfig
  20. 59 0
      Pods/Target Support Files/Pods-Asteria/Pods-Asteria-acknowledgements.markdown
  21. 71 0
      Pods/Target Support Files/Pods-Asteria/Pods-Asteria-acknowledgements.plist
  22. 3 3
      Pods/Target Support Files/Pods-Asteria/Pods-Asteria.debug.xcconfig
  23. 3 3
      Pods/Target Support Files/Pods-Asteria/Pods-Asteria.release.xcconfig

+ 20 - 0
Asteria.xcodeproj/project.pbxproj

@@ -199,6 +199,8 @@
 		8810F5232BEDF31500346FD4 /* Cart.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 8810F5222BEDF31500346FD4 /* Cart.xcassets */; };
 		8810F5262BEDF9F900346FD4 /* ASCheckoutBottomView.m in Sources */ = {isa = PBXBuildFile; fileRef = 8810F5252BEDF9F900346FD4 /* ASCheckoutBottomView.m */; };
 		8810F5292BEE0DEA00346FD4 /* ASCheckoutGoodsItemCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 8810F5282BEE0DEA00346FD4 /* ASCheckoutGoodsItemCell.m */; };
+		8810F52C2BF1A1CD00346FD4 /* ASAddGiftGoodsView.m in Sources */ = {isa = PBXBuildFile; fileRef = 8810F52B2BF1A1CD00346FD4 /* ASAddGiftGoodsView.m */; };
+		8810F5302BF3678400346FD4 /* ASPaypalManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 8810F52F2BF3678400346FD4 /* ASPaypalManager.m */; };
 		8C24ECE114420CDEE7B9B22B /* Pods_Asteria.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 54DCE8001991D89B696E7D44 /* Pods_Asteria.framework */; };
 		9A1247942A1B082300126226 /* Fuction_Tool.m in Sources */ = {isa = PBXBuildFile; fileRef = 9A1247932A1B082300126226 /* Fuction_Tool.m */; };
 		9A1247972A1B0A2800126226 /* AS_ForgotC.m in Sources */ = {isa = PBXBuildFile; fileRef = 9A1247962A1B0A2800126226 /* AS_ForgotC.m */; };
@@ -718,6 +720,10 @@
 		8810F5252BEDF9F900346FD4 /* ASCheckoutBottomView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ASCheckoutBottomView.m; sourceTree = "<group>"; };
 		8810F5272BEE0DEA00346FD4 /* ASCheckoutGoodsItemCell.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ASCheckoutGoodsItemCell.h; sourceTree = "<group>"; };
 		8810F5282BEE0DEA00346FD4 /* ASCheckoutGoodsItemCell.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ASCheckoutGoodsItemCell.m; sourceTree = "<group>"; };
+		8810F52A2BF1A1CD00346FD4 /* ASAddGiftGoodsView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ASAddGiftGoodsView.h; sourceTree = "<group>"; };
+		8810F52B2BF1A1CD00346FD4 /* ASAddGiftGoodsView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ASAddGiftGoodsView.m; sourceTree = "<group>"; };
+		8810F52E2BF3678400346FD4 /* ASPaypalManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ASPaypalManager.h; sourceTree = "<group>"; };
+		8810F52F2BF3678400346FD4 /* ASPaypalManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ASPaypalManager.m; sourceTree = "<group>"; };
 		9A1247922A1B082300126226 /* Fuction_Tool.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = Fuction_Tool.h; sourceTree = "<group>"; };
 		9A1247932A1B082300126226 /* Fuction_Tool.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = Fuction_Tool.m; sourceTree = "<group>"; };
 		9A1247952A1B0A2800126226 /* AS_ForgotC.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AS_ForgotC.h; sourceTree = "<group>"; };
@@ -1838,6 +1844,15 @@
 			path = edit;
 			sourceTree = "<group>";
 		};
+		8810F52D2BF3676900346FD4 /* PayManager */ = {
+			isa = PBXGroup;
+			children = (
+				8810F52E2BF3678400346FD4 /* ASPaypalManager.h */,
+				8810F52F2BF3678400346FD4 /* ASPaypalManager.m */,
+			);
+			path = PayManager;
+			sourceTree = "<group>";
+		};
 		9A1247912A1B07F400126226 /* Tool */ = {
 			isa = PBXGroup;
 			children = (
@@ -2061,6 +2076,7 @@
 		9A78E0112B6388F500CA4E32 /* Cart */ = {
 			isa = PBXGroup;
 			children = (
+				8810F52D2BF3676900346FD4 /* PayManager */,
 				9AFCDABF2B809C29003D3573 /* Checkout */,
 				9A2415B62B677DC000A6E903 /* Target */,
 				9A2415B52B6770D700A6E903 /* Cell */,
@@ -2457,6 +2473,8 @@
 				8810F5082BEB159600346FD4 /* ASCheckoutTopView.m */,
 				8810F5242BEDF9F900346FD4 /* ASCheckoutBottomView.h */,
 				8810F5252BEDF9F900346FD4 /* ASCheckoutBottomView.m */,
+				8810F52A2BF1A1CD00346FD4 /* ASAddGiftGoodsView.h */,
+				8810F52B2BF1A1CD00346FD4 /* ASAddGiftGoodsView.m */,
 				8810F5272BEE0DEA00346FD4 /* ASCheckoutGoodsItemCell.h */,
 				8810F5282BEE0DEA00346FD4 /* ASCheckoutGoodsItemCell.m */,
 				8810F50A2BEB590C00346FD4 /* ASCheckoutPointApplyCell.h */,
@@ -2758,6 +2776,7 @@
 				9A3F5CAB2B3BBEAB00DDB6A7 /* GoodsDetailsPayV.m in Sources */,
 				81C796242A4FD63A003083B8 /* ASVipCouponsViewController.m in Sources */,
 				9AEFA7DE2B649F4000AE1974 /* MyCarlTableV.m in Sources */,
+				8810F5302BF3678400346FD4 /* ASPaypalManager.m in Sources */,
 				9AFCDAC22B809C5B003D3573 /* CartCheckTableV.m in Sources */,
 				9AC2CC222B3A673B005187BD /* ASGoodsDetailsVM.m in Sources */,
 				816020252A2F1C9E00E4A8F1 /* ASHomeMainListModel.m in Sources */,
@@ -2809,6 +2828,7 @@
 				9AD346002A08D60F005CA070 /* ZFPresentTransition.m in Sources */,
 				81717D112A3C4AE000648139 /* KWSearchViewModel.m in Sources */,
 				9A337E3B2A04EE1A00D058A5 /* BViewController.m in Sources */,
+				8810F52C2BF1A1CD00346FD4 /* ASAddGiftGoodsView.m in Sources */,
 				9A31EDFD2B468A55009F11EE /* RadioButton.m in Sources */,
 				9AD345A72A08D571005CA070 /* TYPageControl.m in Sources */,
 				81354C0A2A289C350082C93A /* KWScrollOffsetView.m in Sources */,

+ 9 - 0
Asteria/AppDelegate.m

@@ -9,6 +9,7 @@
 #import "AS_TabBarViewController.h"
 #import <YTKNetwork/YTKNetwork.h>
 
+#import <PayPal-iOS-SDK/PayPalMobile.h>
 
 @interface AppDelegate ()
 
@@ -26,6 +27,10 @@
     } else {
         // Fallback on earlier versions
     }
+    
+    // 设置PayPal环境,可以是 sandbox 或 live
+    [PayPalMobile initializeWithClientIdsForEnvironments:@{PayPalEnvironmentProduction:@"AT88L7L2ZI0mUNNamuY6VRVtuH8Fik6kUrKC-0HtIEpC79wJA56U8Il9iC-FJKXUtxoGkbn7DtdE8skD",PayPalEnvironmentSandbox:@"ASThYYeLhhglcED1R5LrwwjNLpyLYA5yp_8tHTYimlhojmKeC3_FFD2wS2fQp-LlfQalgJFawbEAA5Bu"}];
+    
     [ASCurrencyManager.shared getAllCurrencyData];
 //    [self xxx_ytkNetConfig];
     [PPNetworkHelper openLog];
@@ -39,6 +44,10 @@
     [ASNetTools reqNet_getAdvCoupons];
     [self.window makeKeyAndVisible];
     
+    
+    
+
+    
     return YES;
 }
 -(void)xxx_ytkNetConfig{

+ 4 - 3
Asteria/Common/V/AlertMyCartDeleteV.m

@@ -261,9 +261,10 @@
         _noBtn.backgroundColor = Col_000;
         [_noBtn setTitleColor:Col_FFF forState:UIControlStateNormal];
         [_noBtn addTarget:self action:@selector(handle_noClickEvent:) forControlEvents:UIControlEventTouchUpInside];
-        NSMutableAttributedString *noString = [[NSMutableAttributedString alloc] initWithString:@"NO"];
-        [noString addAttribute:NSUnderlineStyleAttributeName value:[NSNumber numberWithInteger:NSUnderlineStyleSingle] range:NSMakeRange(0, [noString length])];
-        [_noBtn setAttributedTitle:noString forState:UIControlStateNormal];
+//        NSMutableAttributedString *noString = [[NSMutableAttributedString alloc] initWithString:@"NO"];
+//        [noString addAttribute:NSUnderlineStyleAttributeName value:[NSNumber numberWithInteger:NSUnderlineStyleSingle] range:NSMakeRange(0, [noString length])];
+//        [_noBtn setAttributedTitle:noString forState:UIControlStateNormal];
+        [_noBtn setTitle:@"NO" forState:UIControlStateNormal];
         _noBtn.titleLabel.font = [UIFont fontWithName:Rob_Regular size:16];
         
     }

+ 202 - 10
Asteria/Fuction/Cart/Cart_CheckoutC.m

@@ -15,7 +15,14 @@
 #import "CartVM.h"
 #import "ASUserModel.h"
 
-@interface Cart_CheckoutC ()<RY_baseVMprotocol>
+#import "ASGoodsDetailsVM.h"
+
+#import "ASAddGiftGoodsView.h"
+
+#import <PayPal-iOS-SDK/PayPalMobile.h>
+#import <PayPal-iOS-SDK/PayPalConfiguration.h>
+
+@interface Cart_CheckoutC ()<RY_baseVMprotocol, PayPalPaymentDelegate>
 
 @property (nonatomic, strong) CartVM *VM;
 
@@ -38,14 +45,80 @@
 @property (nonatomic, strong) ASCheckoutPaymentModel *paymentModel;
 
 
+//手动添加赠品至购物车
+@property (nonatomic, strong) ASGoodsDetailsVM *goodsDetailsVM;
+
+@property (nonatomic, strong) ASAddGiftGoodsView *addGiftView;
+@property (nonatomic, strong) NSMutableArray *addGiftParamArr;
+@property (nonatomic, assign) int index;
+@property (nonatomic, assign) int giftShowCount;
+
+//paypal支付
+@property (nonatomic, strong) PayPalConfiguration *payPalConfiguration;
+
+
 @end
 
 @implementation Cart_CheckoutC
 
+- (void)initPayPalConfiguration{
+    _payPalConfiguration = [[PayPalConfiguration alloc] init];
+    _payPalConfiguration.merchantName = @"龙熠科技有限公司";//公司名称
+    _payPalConfiguration.acceptCreditCards = NO;
+    _payPalConfiguration.payPalShippingAddressOption = PayPalShippingAddressOptionPayPal;
+}
+
+//amount:金额
+//currencyCode:获取单位 比如:USD
+//shortDescription:商品标题 简短描述
+- (void)PayPalWithAmount:(NSString *)amount currencyCode:(NSString *)currencyCode shortDescription:(NSString *)shortDescription{
+    
+    PayPalPayment *payment = [[PayPalPayment alloc] init];
+    payment.amount = [[NSDecimalNumber alloc] initWithString:amount];
+    payment.currencyCode = currencyCode;
+    payment.shortDescription = @"购买商品购买商品购买商品";
+    payment.items = nil;  // if not including multiple items, then leave payment.items as nil
+    payment.paymentDetails = nil; // if not including payment details, then leave payment.paymentDetails as nil
+    payment.intent = PayPalPaymentIntentSale;
+    if (!payment.processable) {
+        NSLog(@"-------------");
+    }
+    
+    PayPalPaymentViewController *paymentViewController = [[PayPalPaymentViewController alloc] initWithPayment:payment configuration:self.payPalConfiguration delegate:self];
+    [self presentViewController:paymentViewController animated:YES completion:nil];
+}
+
+#pragma mark - PayPalPaymentDelegate methods
+ 
+- (void)payPalPaymentViewController:(nonnull PayPalPaymentViewController *)paymentViewController
+                 didCompletePayment:(nonnull PayPalPayment *)completedPayment {
+    // 支付成功,可以处理你的支付逻辑
+    NSLog(@"支付成功: %@", completedPayment.confirmation);
+    [self dismissViewControllerAnimated:YES completion:nil];
+}
+
+- (void)payPalPaymentDidCancel:(nonnull PayPalPaymentViewController *)paymentViewController {
+    NSLog(@"支付取消");
+    [self dismissViewControllerAnimated:YES completion:nil];
+}
+
+
+- (void)viewWillAppear:(BOOL)animated {
+    [super viewWillAppear:animated];
+    
+    [PayPalMobile preconnectWithEnvironment:PayPalEnvironmentSandbox];
+
+}
+
 - (void)viewDidLoad {
     [super viewDidLoad];
     self.title = @"Checkout";
     
+//    [PayPalMobile preconnectWithEnvironment:PayPalEnvironmentSandbox];
+//    [ PayPalMobile clearAllUserData];
+    
+    [self initPayPalConfiguration];
+    
     //获取支付方式
     [self requestPaymentMode];
     //获取运输方式
@@ -57,6 +130,10 @@
 - (void)initSubviews {
     [super initSubviews];
     
+    self.addGiftParamArr = [[NSMutableArray alloc] initWithCapacity:1];
+    self.index = 0;
+    self.giftShowCount = 0;
+    
     IPhoneXHeigh
     [self setupTableV:[CartCheckTableV class] Frame:CGRectMake(0, securitytop_Y , KScreenWidth, KScreenHeight - securitytop_Y)];
     self.TableV.backgroundColor = [UIColor colorWithHexString:@"#F8F8F8"];
@@ -211,16 +288,43 @@
         [self updateData];
         
     } else if ([mark isEqualToString:Cart_cartsMineItems_Post]
-              || [mark isEqualToString:DEL_cartsMineItems]
-              || [mark isEqualToString:PUT_cartsMineCoupons]
-              || [mark isEqualToString:Chectout_PUT_usePoints]
-              || [mark isEqualToString:Chectout_DEL_cancelusePoints]
-              || [mark isEqualToString:Chectout_setShipMethod]){
+               || [mark isEqualToString:DEL_cartsMineItems]
+               || [mark isEqualToString:PUT_cartsMineCoupons]
+               || [mark isEqualToString:Chectout_PUT_usePoints]
+               || [mark isEqualToString:Chectout_DEL_cancelusePoints]
+               || [mark isEqualToString:Chectout_setShipMethod]
+               || [mark isEqualToString:Chectout_giftAddCart]){
         if(sucessOrFail){
-            [self reqNet_Cart_cartsMineTotals];
+            if ([mark isEqualToString:Chectout_giftAddCart]) {
+                self.index --;
+                if (self.index == 0) {
+                    [self reqNet_Cart_cartsMineTotals];
+                }
+            } else {
+                [self reqNet_Cart_cartsMineTotals];
+            }
         }else{
             [self.view makeToast:(NSString *)data duration:2 position:CSToastPositionCenter];
         }
+    } else if ([mark isEqualToString:Goods_productGetProductsById]) {
+        //请求赠品详情
+        GoodsInformationM *model = (GoodsInformationM *)[arry firstObject];
+                
+        NSMutableDictionary *param = [NSMutableDictionary dictionaryWithDictionary:@{@"product_id":model.Id, @"isPromoItems":@"yes"}];
+        if (model.options.count > 0) {
+            NSMutableDictionary *optionDic = [NSMutableDictionary dictionary];
+            for (OptionsModel *optionM in model.options) {
+                OptionsValuesM *valuesM = optionM.values[0];
+                NSString *tempStr =[NSString stringWithFormat:@"options[%@]",optionM.option_id];
+                optionDic[tempStr] =valuesM.option_type_id;
+            }
+            [param addEntriesFromDictionary:optionDic];
+        }
+        [self.addGiftParamArr addObject:param];
+        if (self.giftShowCount < 2 && self.addGiftParamArr.count == 1 && self.addGiftView.hidden) {
+            self.addGiftView.hidden = NO;
+            [self.addGiftView setGiftData:model.add_gooodsImgUrl];
+        }
     }
 }
 
@@ -269,8 +373,21 @@
     //支付方式数据
     [self.TableV.infodata addObjectsFromArray:self.paymentArray];
     
+    //手动添加赠品功能
+    [self.addGiftParamArr removeAllObjects];
     
-    
+    NSDictionary *freeData = (NSDictionary *)[[self.totalsM.extension_attributes objectForKey:@"free_data"] mj_JSONObject];
+    BOOL is_show = [[freeData objectForKey:@"is_show"] boolValue];
+    if (is_show && self.giftShowCount< 2) {//显示存在赠品
+        NSArray *productArr = [freeData objectForKey:@"products"];
+        if (productArr.count > 0) { //存在赠品
+            for (int i = 0; i < productArr.count; i++) {
+                NSDictionary *productDic = productArr[i];
+                NSString *entity_id = productDic[@"entity_id"];
+                [self reqNet_GoodsDetails_productGetProduct:entity_id];
+            }
+        }
+    }
     
     [self.TableV reloadData];
 }
@@ -348,6 +465,11 @@
     
     [param removeObjectForKey:@"extension_attributes"];//移除格式不正确的无用参数
     
+    if (NIL(self.shipmethodCellM.shipMethodModel.method_code) || NIL(self.shipmethodCellM.shipMethodModel.carrier_code)) {
+        [self.view makeToast:@"运输方式获取失败"];
+        return;
+    }
+    
     NSDictionary *params = @{@"shipping_address":param,
                              @"shipping_method_code":self.shipmethodCellM.shipMethodModel.method_code,
                              @"shipping_carrier_code":self.shipmethodCellM.shipMethodModel.carrier_code};
@@ -385,7 +507,7 @@
 }
 -(void)reqNet_PUT_cartsMineCoupons:(NSString *)coupon{
     [MBProgressHUD showHUDAddedTo:self.view animated:YES];
-
+    self.giftShowCount = 0;
     [self.VM ry_requestPutApi:PUT_cartsMineCoupons param:coupon];
 }
 -(void)reqNet_DEL_cartsMineCoupons{
@@ -404,8 +526,34 @@
 }
 //下单
 -(void)requestSureOrder{
+    
+    NSString *paymentCode = self.paymentModel.code;
+    
+    if ([paymentCode isEqualToString:@"paypal_express"]) {//paypal
+        
+        for (int i=0; i<self.totalCellM.total_segments.count; i++) {
+            NSDictionary *dic = self.totalCellM.total_segments[i];
+            NSString *code = MM_str(dic[@"code"]);
+            if ([code isEqualToString:@"grand_total"]){ //subBottomV
+                NSString *priceStr = [NSString stringWithFormat:@"%@",dic[@"value"]];
+                [self PayPalWithAmount:priceStr currencyCode:ASCurrencyManager.shared.currentCur shortDescription:@"购买商品"];
+                return;
+
+            }
+        }
+        return;
+    } else if ([paymentCode isEqualToString:@"stripe_payments"]) {//visa
+        
+    } else if ([paymentCode isEqualToString:@"afterpay_payment"]) {//afterpay
+        
+    } else if ([paymentCode isEqualToString:@"klarna_kco"]) {//klarna
+        
+    } else {
+        
+    }
+    
     [MBProgressHUD showHUDAddedTo:self.view animated:YES];
-    NSDictionary *param = @{@"method":self.paymentModel.code};
+    NSDictionary *param = @{@"method":paymentCode};
     
     [ASNetTools.shared putWithPath:Chectout_PUT_sureOrder param:@{@"paymentMethod":param} success:^(id _Nonnull json) {
         [MBProgressHUD hideHUDForView:self.view animated:YES];
@@ -418,9 +566,34 @@
     
 }
 
+//请求赠品商品详情
+-(void)reqNet_GoodsDetails_productGetProduct:(NSString *)enterId{
+    NSMutableDictionary * params = [[NSMutableDictionary alloc] init];
+//    [params setObject:@"55475" forKey:@"productId"];
+    [params setObject:enterId forKey:@"productId"];
+    [params setObject:ASCurrencyManager.shared.currentCur forKey:@"currencyCode"];
+//    [MBProgressHUD showHUDAddedTo:self.view animated:YES];
+    [self.goodsDetailsVM ry_requestGetApi:Goods_productGetProductsById param:params];
+}
+
+//赠品加车
+- (void)requestGiftAddCart {
+    [MBProgressHUD showHUDAddedTo:self.view animated:YES];
+    
+    for (int i = 0; i < self.addGiftParamArr.count; i++) {
+        NSDictionary *param = self.addGiftParamArr[i];
+        self.index ++;
+        self.giftShowCount = 2;
+        [self.VM ry_formDataRequestPostApi:Chectout_giftAddCart param:param];
+    }
+    
+    
+}
+
 #pragma mark --- 懒加载 ---
 - (void)ucm_bindvmmodel{
     self.VM = [[CartVM alloc] initDelegate:self];
+    self.goodsDetailsVM = [[ASGoodsDetailsVM alloc] initDelegate:self];
 }
 
 - (MyCartCouponCellData *)couponCellM {
@@ -491,6 +664,25 @@
     return _bottomView;
 }
 
+- (ASAddGiftGoodsView *)addGiftView {
+    if (!_addGiftView) {
+        _addGiftView = [[ASAddGiftGoodsView alloc] initWithFrame:CGRectMake(0, 0, KScreenWidth, KScreenHeight)];
+        @weakify(self)
+        _addGiftView.addBlock = ^(int type) {
+            @strongify(self)
+            self.addGiftView.hidden = YES;
+            if (type == 1) {
+                [self requestGiftAddCart];
+            } else {
+                self.giftShowCount ++;
+            }
+        };
+        _addGiftView.hidden = YES;
+        [[UIApplication sharedApplication].keyWindow addSubview:_addGiftView];
+    }
+    return _addGiftView;
+}
+
 #pragma mark - **************** reqNet ****************
 
 

+ 116 - 4
Asteria/Fuction/Cart/Cart_MyCartC.m

@@ -9,6 +9,11 @@
 #import "CartVM.h"
 #import "MyCarlTableV.h"
 #import "Cart_CheckoutC.h"
+
+#import "ASGoodsDetailsVM.h"
+
+#import "ASAddGiftGoodsView.h"
+
 @interface Cart_MyCartC ()<RY_baseVMprotocol>
 @property (nonatomic, strong) CartVM *VM;
 @property (nonatomic, strong) UIView *topBgV;
@@ -20,6 +25,16 @@
 @property (nonatomic, strong) MyCartCouponCellData *couponCellM;
 @property (nonatomic, strong) MyCartGrandTotalCellData *totalCellM;
 @property (nonatomic, strong) UIButton *postBtn;
+
+
+//手动添加赠品至购物车
+@property (nonatomic, strong) ASGoodsDetailsVM *goodsDetailsVM;
+
+@property (nonatomic, strong) ASAddGiftGoodsView *addGiftView;
+@property (nonatomic, strong) NSMutableArray *addGiftParamArr;
+@property (nonatomic, assign) int index;
+@property (nonatomic, assign) int giftShowCount;
+
 @end
 
 @implementation Cart_MyCartC
@@ -55,7 +70,10 @@
     
     [self.view addSubview:self.postBtn];
     self.postBtn.mj_y = CGRectGetMaxY(self.TableV.frame);
-
+    
+    self.addGiftParamArr = [[NSMutableArray alloc] initWithCapacity:1];
+    self.index = 0;
+    self.giftShowCount = 0;
 }
 
 
@@ -87,8 +105,11 @@
 }
 - (void)ucm_bindvmmodel{
     self.VM = [[CartVM alloc] initDelegate:self];
+    self.goodsDetailsVM = [[ASGoodsDetailsVM alloc] initDelegate:self];
 }
 
+
+
 #pragma mark - **************** reqNet ****************
 ///获取购物车
 -(void)reqNet_Cart_cartsMineTotals{
@@ -115,7 +136,7 @@
 }
 -(void)reqNet_PUT_cartsMineCoupons:(NSString *)coupon{
     [MBProgressHUD showHUDAddedTo:self.view animated:YES];
-
+    self.giftShowCount = 0;
     [self.VM ry_requestPutApi:PUT_cartsMineCoupons param:coupon];
 }
 -(void)reqNet_DEL_cartsMineCoupons{
@@ -123,6 +144,29 @@
     [self.VM ry_requestDeleteApi:DEL_cartsMineCoupons paramStr:@""];
 }
 
+//请求赠品商品详情
+-(void)reqNet_GoodsDetails_productGetProduct:(NSString *)enterId{
+    NSMutableDictionary * params = [[NSMutableDictionary alloc] init];
+//    [params setObject:@"55475" forKey:@"productId"];
+    [params setObject:enterId forKey:@"productId"];
+    [params setObject:ASCurrencyManager.shared.currentCur forKey:@"currencyCode"];
+//    [MBProgressHUD showHUDAddedTo:self.view animated:YES];
+    [self.goodsDetailsVM ry_requestGetApi:Goods_productGetProductsById param:params];
+}
+
+//赠品加车
+- (void)requestGiftAddCart {
+    [MBProgressHUD showHUDAddedTo:self.view animated:YES];
+    
+    for (int i = 0; i < self.addGiftParamArr.count; i++) {
+        NSDictionary *param = self.addGiftParamArr[i];
+        self.index ++;
+        [self.VM ry_formDataRequestPostApi:Chectout_giftAddCart param:param];
+    }
+    
+    
+}
+
 - (void)ry_respnsData:(id)data 
              parseAry:(NSMutableArray *)arry
                sucess:(BOOL)sucessOrFail 
@@ -153,16 +197,65 @@
             data.currency_symbol = model.currency_symbol;
             [self.TableV.infodata addObject:data];
             
+            //手动添加赠品功能
+            [self.addGiftParamArr removeAllObjects];
+            
+            NSDictionary *freeData = (NSDictionary *)[[self.totalsM.extension_attributes objectForKey:@"free_data"] mj_JSONObject];
+            BOOL is_show = [[freeData objectForKey:@"is_show"] boolValue];
+            if (is_show && self.giftShowCount< 1) {//显示存在赠品
+                NSArray *productArr = [freeData objectForKey:@"products"];
+                if (productArr.count > 0) { //存在赠品
+                    for (int i = 0; i < productArr.count; i++) {
+                        NSDictionary *productDic = productArr[i];
+                        NSString *entity_id = productDic[@"entity_id"];
+                        [self reqNet_GoodsDetails_productGetProduct:entity_id];
+                    }
+                }
+            }
+            
             [self.TableV reloadData];
         }
     }else if ([mark isEqualToString:Cart_cartsMineItems_Post]
               || [mark isEqualToString:DEL_cartsMineItems]
-              || [mark isEqualToString:PUT_cartsMineCoupons]){
+              || [mark isEqualToString:PUT_cartsMineCoupons]
+              || [mark isEqualToString:Chectout_giftAddCart]){
         if(sucessOrFail){
-            [self reqNet_Cart_cartsMineTotals];
+            
+            if ([mark isEqualToString:Chectout_giftAddCart]) {
+                self.index --;
+                if (self.index == 0) {
+                    [self reqNet_Cart_cartsMineTotals];
+                }
+            } else {
+                [self reqNet_Cart_cartsMineTotals];
+            }
+            
+            
         }else{
             [self.view makeToast:(NSString *)data duration:2 position:CSToastPositionCenter];
         }
+    } else if ([mark isEqualToString:Goods_productGetProductsById]) {
+        //请求赠品详情
+        GoodsInformationM *model = (GoodsInformationM *)[arry firstObject];
+        
+        NSLog(@"optionsoptions====%@=====%@", model.Id, model.options);
+        
+        NSMutableDictionary *param = [NSMutableDictionary dictionaryWithDictionary:@{@"product_id":model.Id, @"isPromoItems":@"yes"}];
+        if (model.options.count > 0) {
+            NSMutableDictionary *optionDic = [NSMutableDictionary dictionary];
+            for (OptionsModel *optionM in model.options) {
+                OptionsValuesM *valuesM = optionM.values[0];
+                NSString *tempStr =[NSString stringWithFormat:@"options[%@]",optionM.option_id];
+                optionDic[tempStr] =valuesM.option_type_id;
+            }
+            [param addEntriesFromDictionary:optionDic];
+        }
+//        param = /*@{@"product_id":model.Id, @"isPromoItems":@"1"}*/;
+        [self.addGiftParamArr addObject:param];
+        if (self.giftShowCount < 1 && self.addGiftParamArr.count == 1 && self.addGiftView.hidden) {
+            self.addGiftView.hidden = NO;
+            [self.addGiftView setGiftData:model.add_gooodsImgUrl];
+        }
     }
 }
 - (void)tapcellTriggereventIndex:(NSIndexPath *)index model:(id)model{
@@ -243,4 +336,23 @@
     return _postBtn;
 }
 
+- (ASAddGiftGoodsView *)addGiftView {
+    if (!_addGiftView) {
+        _addGiftView = [[ASAddGiftGoodsView alloc] initWithFrame:CGRectMake(0, 0, KScreenWidth, KScreenHeight)];
+        @weakify(self)
+        _addGiftView.addBlock = ^(int type) {
+            @strongify(self)
+            self.addGiftView.hidden = YES;
+            if (type == 1) {
+                [self requestGiftAddCart];
+            } else {
+                self.giftShowCount ++;
+            }
+        };
+        _addGiftView.hidden = YES;
+        [[UIApplication sharedApplication].keyWindow addSubview:_addGiftView];
+    }
+    return _addGiftView;
+}
+
 @end

+ 30 - 0
Asteria/Fuction/Cart/Checkout/ASAddGiftGoodsView.h

@@ -0,0 +1,30 @@
+//
+//  ASAddGiftGoodsView.h
+//  Asteria
+//
+//  Created by xingyu on 2024/5/13.
+//
+
+#import <UIKit/UIKit.h>
+
+NS_ASSUME_NONNULL_BEGIN
+
+typedef void(^ASAddGiftAddBlock)(int type);
+
+@interface ASAddGiftData : NSObject
+
+@property (nonatomic, copy) NSString *isShowGift;
+
+@property (nonatomic, strong) NSArray *productsArr;
+
+@end
+
+@interface ASAddGiftGoodsView : UIView
+
+@property (nonatomic, copy) ASAddGiftAddBlock addBlock;
+
+- (void)setGiftData:(NSString *)imageStr;
+
+@end
+
+NS_ASSUME_NONNULL_END

+ 106 - 0
Asteria/Fuction/Cart/Checkout/ASAddGiftGoodsView.m

@@ -0,0 +1,106 @@
+//
+//  ASAddGiftGoodsView.m
+//  Asteria
+//
+//  Created by xingyu on 2024/5/13.
+//
+
+#import "ASAddGiftGoodsView.h"
+
+@interface ASAddGiftGoodsView()
+
+@property (nonatomic, strong) UIImageView *goodsImage;
+
+@end
+
+@implementation ASAddGiftGoodsView
+
+- (instancetype)initWithFrame:(CGRect)frame {
+    if (self = [super initWithFrame:frame]) {
+        
+        self.backgroundColor = [[UIColor blackColor] colorWithAlphaComponent:0.4];
+        
+        UIView *backView = [[UIView alloc] init];
+        backView.backgroundColor = Col_FFF;
+        TT_ViewRadius(backView, 8);
+        [self addSubview:backView];
+        [backView mas_makeConstraints:^(MASConstraintMaker *make) {
+            make.center.equalTo(self);
+            make.width.mas_equalTo(300);
+        }];
+        
+        UIButton *closeBtn = [UIButton buttonWithType:UIButtonTypeCustom];
+        [closeBtn setImage:[UIImage imageNamed:@"base_close_black"] forState:UIControlStateNormal];
+        [closeBtn addTarget:self action:@selector(_closeClick) forControlEvents:UIControlEventTouchUpInside];
+        [backView addSubview:closeBtn];
+        [closeBtn mas_makeConstraints:^(MASConstraintMaker *make) {
+            make.top.mas_equalTo(10);
+            make.right.mas_equalTo(-10);
+            make.width.height.mas_equalTo(36);
+        }];
+        
+        UILabel *topLab = [UILabel labelCreateWithText:@"Congratulations!" font:[UIFont fontWithName:Rob_Bold size:14] textColor:Col_000];
+        [backView addSubview:topLab];
+        [topLab mas_makeConstraints:^(MASConstraintMaker *make) {
+            make.centerX.equalTo(backView);
+            make.top.mas_equalTo(56);
+        }];
+        
+        UILabel *descLab = [UILabel labelCreateWithText:@"You got a free gift" font:[UIFont fontWithName:Rob_Regular size:14] textColor:Col_000];
+        [backView addSubview:descLab];
+        [descLab mas_makeConstraints:^(MASConstraintMaker *make) {
+            make.centerX.equalTo(backView);
+            make.top.mas_equalTo(topLab.mas_bottom).offset(10);
+        }];
+        
+        _goodsImage = [[UIImageView alloc] init];
+        [backView addSubview:_goodsImage];
+        [_goodsImage mas_makeConstraints:^(MASConstraintMaker *make) {
+            make.centerX.equalTo(backView);
+            make.top.mas_equalTo(descLab.mas_bottom).offset(10);
+            make.width.height.mas_equalTo(86);
+        }];
+        
+        UIButton *getBtn = [UIButton buttonWithType:UIButtonTypeCustom];
+        [getBtn setTitle:@"Get" forState:UIControlStateNormal];
+        [getBtn setTitleColor:Col_FFF forState:UIControlStateNormal];
+        getBtn.titleLabel.font = [UIFont fontWithName:Rob_Regular size:14];
+        getBtn.backgroundColor = Col_000;
+        [getBtn addTarget:self action:@selector(_addCart) forControlEvents:UIControlEventTouchUpInside];
+        TT_ViewRadius(getBtn, 4);
+        [backView addSubview:getBtn];
+        [getBtn mas_makeConstraints:^(MASConstraintMaker *make) {
+            make.left.mas_equalTo(34);
+            make.right.mas_equalTo(-34);
+            make.top.equalTo(_goodsImage.mas_bottom).offset(30);
+            make.height.mas_equalTo(35);
+            make.bottom.mas_equalTo(-30);
+        }];
+        
+    }
+    return self;
+}
+
+- (void)setGiftData:(NSString *)imageStr {
+    
+    NSString *imageAllStr = [NSString stringWithFormat:@"https:%@%@%@",HostPath,ProductImgPath,imageStr];
+    
+    [self.goodsImage sd_setImageWithURL:[NSURL URLWithString:imageAllStr] placeholderImage:UIImageDefaultImg_SD];
+}
+
+- (void)_addCart {
+    
+//    [self removeFromSuperview];
+    
+    if (self.addBlock) {
+        self.addBlock(1);
+    }
+}
+
+- (void)_closeClick {
+    if (self.addBlock) {
+        self.addBlock(0);
+    }
+}
+
+@end

+ 2 - 2
Asteria/Fuction/Cart/Checkout/ASCheckoutGoodsItemCell.m

@@ -154,8 +154,8 @@
     if(itemM.isGift){
         self.bgDesLab.hidden = YES;
     }else{
-        self.bgDesLab.hidden = NO;
-        self.bgDesLab.text = [NSString stringWithFormat:@"SAVE %@%.2f",itemM.currency_symbol,[itemM.initial_price floatValue]-[itemM.price floatValue]];
+        self.bgDesLab.hidden = YES;
+//        self.bgDesLab.text = [NSString stringWithFormat:@"SAVE %@%.2f",itemM.currency_symbol,[itemM.initial_price floatValue]-[itemM.price floatValue]];
         self.countV.numLab.text = MM_str(itemM.qty);
         [self.countV xxx_changeBtnIsEnable:YES num:[self.countV.numLab.text integerValue]];
     }

+ 16 - 0
Asteria/Fuction/Cart/PayManager/ASPaypalManager.h

@@ -0,0 +1,16 @@
+//
+//  ASPaypalManager.h
+//  Asteria
+//
+//  Created by xingyu on 2024/5/14.
+//
+
+#import <Foundation/Foundation.h>
+
+NS_ASSUME_NONNULL_BEGIN
+
+@interface ASPaypalManager : NSObject
+
+@end
+
+NS_ASSUME_NONNULL_END

+ 22 - 0
Asteria/Fuction/Cart/PayManager/ASPaypalManager.m

@@ -0,0 +1,22 @@
+//
+//  ASPaypalManager.m
+//  Asteria
+//
+//  Created by xingyu on 2024/5/14.
+//
+
+#import "ASPaypalManager.h"
+
+#import <PayPal-iOS-SDK/PayPalMobile.h>
+#import <PayPal-iOS-SDK/PayPalConfiguration.h>
+
+@interface ASPaypalManager()
+
+//paypal支付
+@property (nonatomic, strong) PayPalConfiguration *payPalConfiguration;
+
+@end
+
+@implementation ASPaypalManager
+
+@end

+ 3 - 0
Asteria/Fuction/Cart/VM/CartVM.h

@@ -39,6 +39,9 @@
 //下单
 #define Chectout_PUT_sureOrder       BaseRequestrUrl(@"carts/mine/order")
 
+//赠品手动加车
+#define Chectout_giftAddCart         BaseRequestrUrl(@"addGiftProduct")
+
 NS_ASSUME_NONNULL_BEGIN
 
 @interface CartVM : RYBaseVM

+ 2 - 0
Podfile

@@ -61,6 +61,8 @@ target 'Asteria' do
   pod 'MKNetworkKit'
   
   pod 'LookinServer', :configurations => ['Debug']
+  
+  pod 'PayPal-iOS-SDK'
 
 pod 'OneSignalXCFramework', '>= 3.0.0', '< 4.0'
 

+ 14 - 2
Podfile.lock

@@ -636,6 +636,7 @@ PODS:
   - BRPickerView/StringPickerView (2.8.1):
     - BRPickerView/Base
   - Bugly (2.5.93)
+  - CardIO (5.4.1)
   - CTMediator (48)
   - FBAEMKit (16.1.0):
     - FBSDKCoreKit_Basics (= 16.1.0)
@@ -832,6 +833,12 @@ PODS:
     - OneSignalXCFramework/OneSignalOutcomes
   - OneSignalXCFramework/OneSignalOutcomes (3.12.5):
     - OneSignalXCFramework/OneSignalCore
+  - PayPal-iOS-SDK (2.18.1):
+    - PayPal-iOS-SDK/CardIO (= 2.18.1)
+    - PayPal-iOS-SDK/Core (= 2.18.1)
+  - PayPal-iOS-SDK/CardIO (2.18.1):
+    - CardIO (~> 5.4.1)
+  - PayPal-iOS-SDK/Core (2.18.1)
   - PPBadgeView (3.1.0)
   - PromisesObjC (2.2.0)
   - QMUIKit (4.6.0):
@@ -1173,6 +1180,7 @@ DEPENDENCIES:
   - MJRefresh
   - MKNetworkKit
   - OneSignalXCFramework (< 4.0, >= 3.0.0)
+  - PayPal-iOS-SDK
   - PPBadgeView
   - Reachability
   - SDWebImage
@@ -1187,6 +1195,7 @@ SPEC REPOS:
     - BoringSSL-GRPC
     - BRPickerView
     - Bugly
+    - CardIO
     - CTMediator
     - FBAEMKit
     - FBSDKCoreKit
@@ -1219,6 +1228,7 @@ SPEC REPOS:
     - MKNetworkKit
     - nanopb
     - OneSignalXCFramework
+    - PayPal-iOS-SDK
     - PPBadgeView
     - PromisesObjC
     - QMUIKit
@@ -1239,6 +1249,7 @@ SPEC CHECKSUMS:
   BoringSSL-GRPC: 3175b25143e648463a56daeaaa499c6cb86dad33
   BRPickerView: 2531a2d4d0fea0b57a1c738de215af0f88863a2f
   Bugly: b8715e6ec4004b7f7fbffab0643ba80545aee3da
+  CardIO: 56983b39b62f495fc6dae9ad7cf875143df06443
   CTMediator: 3f3578b525b3a46a7a2f92a99922ec40363f4269
   FBAEMKit: c7efe06720a8b15b1d25b68921ba46dee20996e0
   FBSDKCoreKit: ca77d40d46786157b7b31ad3516f5ad9c2315339
@@ -1271,6 +1282,7 @@ SPEC CHECKSUMS:
   MKNetworkKit: 1171bfac5c3a1cd7fea9a027f29359e1b4cab705
   nanopb: b552cce312b6c8484180ef47159bc0f65a1f0431
   OneSignalXCFramework: 4afdd14f6fa769eadf141209037e3eac5890beb9
+  PayPal-iOS-SDK: 70d56697aef502c130b9840e31dea5c6b8a350e1
   PPBadgeView: b50a223638970fd0781e8753250385864b6dd2fe
   PromisesObjC: 09985d6d70fbe7878040aa746d78236e6946d2ef
   QMUIKit: 6321cf1124623d686a9ec0a79a7cc59d0d64a52c
@@ -1281,6 +1293,6 @@ SPEC CHECKSUMS:
   YTKNetwork: c16be90b06be003de9e9cd0d3b187cc8eaf35c04
   YYCache: 8105b6638f5e849296c71f331ff83891a4942952
 
-PODFILE CHECKSUM: ba7c106e897ece4e287441c9de35990e024aa198
+PODFILE CHECKSUM: 6aef0f7cd78a40d6def250c7fc3efd31bc54ffac
 
-COCOAPODS: 1.13.0
+COCOAPODS: 1.15.2

+ 14 - 2
Pods/Manifest.lock

@@ -636,6 +636,7 @@ PODS:
   - BRPickerView/StringPickerView (2.8.1):
     - BRPickerView/Base
   - Bugly (2.5.93)
+  - CardIO (5.4.1)
   - CTMediator (48)
   - FBAEMKit (16.1.0):
     - FBSDKCoreKit_Basics (= 16.1.0)
@@ -832,6 +833,12 @@ PODS:
     - OneSignalXCFramework/OneSignalOutcomes
   - OneSignalXCFramework/OneSignalOutcomes (3.12.5):
     - OneSignalXCFramework/OneSignalCore
+  - PayPal-iOS-SDK (2.18.1):
+    - PayPal-iOS-SDK/CardIO (= 2.18.1)
+    - PayPal-iOS-SDK/Core (= 2.18.1)
+  - PayPal-iOS-SDK/CardIO (2.18.1):
+    - CardIO (~> 5.4.1)
+  - PayPal-iOS-SDK/Core (2.18.1)
   - PPBadgeView (3.1.0)
   - PromisesObjC (2.2.0)
   - QMUIKit (4.6.0):
@@ -1173,6 +1180,7 @@ DEPENDENCIES:
   - MJRefresh
   - MKNetworkKit
   - OneSignalXCFramework (< 4.0, >= 3.0.0)
+  - PayPal-iOS-SDK
   - PPBadgeView
   - Reachability
   - SDWebImage
@@ -1187,6 +1195,7 @@ SPEC REPOS:
     - BoringSSL-GRPC
     - BRPickerView
     - Bugly
+    - CardIO
     - CTMediator
     - FBAEMKit
     - FBSDKCoreKit
@@ -1219,6 +1228,7 @@ SPEC REPOS:
     - MKNetworkKit
     - nanopb
     - OneSignalXCFramework
+    - PayPal-iOS-SDK
     - PPBadgeView
     - PromisesObjC
     - QMUIKit
@@ -1239,6 +1249,7 @@ SPEC CHECKSUMS:
   BoringSSL-GRPC: 3175b25143e648463a56daeaaa499c6cb86dad33
   BRPickerView: 2531a2d4d0fea0b57a1c738de215af0f88863a2f
   Bugly: b8715e6ec4004b7f7fbffab0643ba80545aee3da
+  CardIO: 56983b39b62f495fc6dae9ad7cf875143df06443
   CTMediator: 3f3578b525b3a46a7a2f92a99922ec40363f4269
   FBAEMKit: c7efe06720a8b15b1d25b68921ba46dee20996e0
   FBSDKCoreKit: ca77d40d46786157b7b31ad3516f5ad9c2315339
@@ -1271,6 +1282,7 @@ SPEC CHECKSUMS:
   MKNetworkKit: 1171bfac5c3a1cd7fea9a027f29359e1b4cab705
   nanopb: b552cce312b6c8484180ef47159bc0f65a1f0431
   OneSignalXCFramework: 4afdd14f6fa769eadf141209037e3eac5890beb9
+  PayPal-iOS-SDK: 70d56697aef502c130b9840e31dea5c6b8a350e1
   PPBadgeView: b50a223638970fd0781e8753250385864b6dd2fe
   PromisesObjC: 09985d6d70fbe7878040aa746d78236e6946d2ef
   QMUIKit: 6321cf1124623d686a9ec0a79a7cc59d0d64a52c
@@ -1281,6 +1293,6 @@ SPEC CHECKSUMS:
   YTKNetwork: c16be90b06be003de9e9cd0d3b187cc8eaf35c04
   YYCache: 8105b6638f5e849296c71f331ff83891a4942952
 
-PODFILE CHECKSUM: ba7c106e897ece4e287441c9de35990e024aa198
+PODFILE CHECKSUM: 6aef0f7cd78a40d6def250c7fc3efd31bc54ffac
 
-COCOAPODS: 1.13.0
+COCOAPODS: 1.15.2

File diff suppressed because it is too large
+ 27395 - 27111
Pods/Pods.xcodeproj/project.pbxproj


+ 59 - 0
Pods/Target Support Files/Pods-Asteria-NotificationServiceExtension/Pods-Asteria-NotificationServiceExtension-acknowledgements.markdown

@@ -520,6 +520,33 @@ Copyright (C) 2017 Tencent Bugly, Inc. All rights reserved.
 MIT
 
 
+## CardIO
+
+All files are released under the MIT License:
+
+    The MIT License (MIT)
+
+    Copyright (c) 2013-2016 PayPal Holdings, Inc.
+
+    Permission is hereby granted, free of charge, to any person obtaining a copy
+    of this software and associated documentation files (the "Software"), to deal
+    in the Software without restriction, including without limitation the rights
+    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+    copies of the Software, and to permit persons to whom the Software is
+    furnished to do so, subject to the following conditions:
+
+    The above copyright notice and this permission notice shall be included in
+    all copies or substantial portions of the Software.
+
+    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+    THE SOFTWARE.
+
+
 ## FBAEMKit
 
 Copyright (c) Meta Platforms, Inc. and affiliates. All rights reserved.
@@ -2943,6 +2970,38 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
 SOFTWARE.
 
 
+## PayPal-iOS-SDK
+
+The PayPalMobile header files and the PayPal iOS SDK Sample App are released under the BSD License:
+
+    Copyright (c) 2014-2016 PayPal Holdings, Inc.
+    All rights reserved.
+
+    Redistribution and use in source and binary forms, with or without
+    modification, are permitted provided that the following conditions are met:
+
+    1. Redistributions of source code must retain the above copyright notice, this
+       list of conditions and the following disclaimer.
+    2. Redistributions in binary form must reproduce the above copyright notice,
+       this list of conditions and the following disclaimer in the documentation
+       and/or other materials provided with the distribution.
+
+    THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+    ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+    WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+    DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
+    ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+    (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+    LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+    ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+    (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+    SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+    The views and conclusions contained in the software and documentation are those
+    of the authors and should not be interpreted as representing official policies,
+    either expressed or implied, of the FreeBSD Project.
+
+
 ## PromisesObjC
 
 

+ 71 - 0
Pods/Target Support Files/Pods-Asteria-NotificationServiceExtension/Pods-Asteria-NotificationServiceExtension-acknowledgements.plist

@@ -567,6 +567,39 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 			<key>Type</key>
 			<string>PSGroupSpecifier</string>
 		</dict>
+		<dict>
+			<key>FooterText</key>
+			<string>All files are released under the MIT License:
+
+    The MIT License (MIT)
+
+    Copyright (c) 2013-2016 PayPal Holdings, Inc.
+
+    Permission is hereby granted, free of charge, to any person obtaining a copy
+    of this software and associated documentation files (the "Software"), to deal
+    in the Software without restriction, including without limitation the rights
+    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+    copies of the Software, and to permit persons to whom the Software is
+    furnished to do so, subject to the following conditions:
+
+    The above copyright notice and this permission notice shall be included in
+    all copies or substantial portions of the Software.
+
+    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+    THE SOFTWARE.
+</string>
+			<key>License</key>
+			<string>MIT</string>
+			<key>Title</key>
+			<string>CardIO</string>
+			<key>Type</key>
+			<string>PSGroupSpecifier</string>
+		</dict>
 		<dict>
 			<key>FooterText</key>
 			<string>Copyright (c) Meta Platforms, Inc. and affiliates. All rights reserved.
@@ -3158,6 +3191,44 @@ SOFTWARE.
 			<key>Type</key>
 			<string>PSGroupSpecifier</string>
 		</dict>
+		<dict>
+			<key>FooterText</key>
+			<string>The PayPalMobile header files and the PayPal iOS SDK Sample App are released under the BSD License:
+
+    Copyright (c) 2014-2016 PayPal Holdings, Inc.
+    All rights reserved.
+
+    Redistribution and use in source and binary forms, with or without
+    modification, are permitted provided that the following conditions are met:
+
+    1. Redistributions of source code must retain the above copyright notice, this
+       list of conditions and the following disclaimer.
+    2. Redistributions in binary form must reproduce the above copyright notice,
+       this list of conditions and the following disclaimer in the documentation
+       and/or other materials provided with the distribution.
+
+    THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+    ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+    WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+    DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
+    ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+    (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+    LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+    ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+    (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+    SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+    The views and conclusions contained in the software and documentation are those
+    of the authors and should not be interpreted as representing official policies,
+    either expressed or implied, of the FreeBSD Project.
+</string>
+			<key>License</key>
+			<string>BSD</string>
+			<key>Title</key>
+			<string>PayPal-iOS-SDK</string>
+			<key>Type</key>
+			<string>PSGroupSpecifier</string>
+		</dict>
 		<dict>
 			<key>FooterText</key>
 			<string>

File diff suppressed because it is too large
+ 3 - 3
Pods/Target Support Files/Pods-Asteria-NotificationServiceExtension/Pods-Asteria-NotificationServiceExtension.debug.xcconfig


File diff suppressed because it is too large
+ 3 - 3
Pods/Target Support Files/Pods-Asteria-NotificationServiceExtension/Pods-Asteria-NotificationServiceExtension.release.xcconfig


+ 59 - 0
Pods/Target Support Files/Pods-Asteria/Pods-Asteria-acknowledgements.markdown

@@ -520,6 +520,33 @@ Copyright (C) 2017 Tencent Bugly, Inc. All rights reserved.
 MIT
 
 
+## CardIO
+
+All files are released under the MIT License:
+
+    The MIT License (MIT)
+
+    Copyright (c) 2013-2016 PayPal Holdings, Inc.
+
+    Permission is hereby granted, free of charge, to any person obtaining a copy
+    of this software and associated documentation files (the "Software"), to deal
+    in the Software without restriction, including without limitation the rights
+    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+    copies of the Software, and to permit persons to whom the Software is
+    furnished to do so, subject to the following conditions:
+
+    The above copyright notice and this permission notice shall be included in
+    all copies or substantial portions of the Software.
+
+    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+    THE SOFTWARE.
+
+
 ## FBAEMKit
 
 Copyright (c) Meta Platforms, Inc. and affiliates. All rights reserved.
@@ -2943,6 +2970,38 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
 SOFTWARE.
 
 
+## PayPal-iOS-SDK
+
+The PayPalMobile header files and the PayPal iOS SDK Sample App are released under the BSD License:
+
+    Copyright (c) 2014-2016 PayPal Holdings, Inc.
+    All rights reserved.
+
+    Redistribution and use in source and binary forms, with or without
+    modification, are permitted provided that the following conditions are met:
+
+    1. Redistributions of source code must retain the above copyright notice, this
+       list of conditions and the following disclaimer.
+    2. Redistributions in binary form must reproduce the above copyright notice,
+       this list of conditions and the following disclaimer in the documentation
+       and/or other materials provided with the distribution.
+
+    THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+    ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+    WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+    DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
+    ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+    (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+    LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+    ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+    (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+    SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+    The views and conclusions contained in the software and documentation are those
+    of the authors and should not be interpreted as representing official policies,
+    either expressed or implied, of the FreeBSD Project.
+
+
 ## PromisesObjC
 
 

+ 71 - 0
Pods/Target Support Files/Pods-Asteria/Pods-Asteria-acknowledgements.plist

@@ -567,6 +567,39 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 			<key>Type</key>
 			<string>PSGroupSpecifier</string>
 		</dict>
+		<dict>
+			<key>FooterText</key>
+			<string>All files are released under the MIT License:
+
+    The MIT License (MIT)
+
+    Copyright (c) 2013-2016 PayPal Holdings, Inc.
+
+    Permission is hereby granted, free of charge, to any person obtaining a copy
+    of this software and associated documentation files (the "Software"), to deal
+    in the Software without restriction, including without limitation the rights
+    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+    copies of the Software, and to permit persons to whom the Software is
+    furnished to do so, subject to the following conditions:
+
+    The above copyright notice and this permission notice shall be included in
+    all copies or substantial portions of the Software.
+
+    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+    THE SOFTWARE.
+</string>
+			<key>License</key>
+			<string>MIT</string>
+			<key>Title</key>
+			<string>CardIO</string>
+			<key>Type</key>
+			<string>PSGroupSpecifier</string>
+		</dict>
 		<dict>
 			<key>FooterText</key>
 			<string>Copyright (c) Meta Platforms, Inc. and affiliates. All rights reserved.
@@ -3158,6 +3191,44 @@ SOFTWARE.
 			<key>Type</key>
 			<string>PSGroupSpecifier</string>
 		</dict>
+		<dict>
+			<key>FooterText</key>
+			<string>The PayPalMobile header files and the PayPal iOS SDK Sample App are released under the BSD License:
+
+    Copyright (c) 2014-2016 PayPal Holdings, Inc.
+    All rights reserved.
+
+    Redistribution and use in source and binary forms, with or without
+    modification, are permitted provided that the following conditions are met:
+
+    1. Redistributions of source code must retain the above copyright notice, this
+       list of conditions and the following disclaimer.
+    2. Redistributions in binary form must reproduce the above copyright notice,
+       this list of conditions and the following disclaimer in the documentation
+       and/or other materials provided with the distribution.
+
+    THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+    ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+    WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+    DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
+    ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+    (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+    LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+    ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+    (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+    SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+    The views and conclusions contained in the software and documentation are those
+    of the authors and should not be interpreted as representing official policies,
+    either expressed or implied, of the FreeBSD Project.
+</string>
+			<key>License</key>
+			<string>BSD</string>
+			<key>Title</key>
+			<string>PayPal-iOS-SDK</string>
+			<key>Type</key>
+			<string>PSGroupSpecifier</string>
+		</dict>
 		<dict>
 			<key>FooterText</key>
 			<string>

File diff suppressed because it is too large
+ 3 - 3
Pods/Target Support Files/Pods-Asteria/Pods-Asteria.debug.xcconfig


File diff suppressed because it is too large
+ 3 - 3
Pods/Target Support Files/Pods-Asteria/Pods-Asteria.release.xcconfig