diff --git a/ALand.xcodeproj/project.pbxproj b/ALand.xcodeproj/project.pbxproj index d408026d10eb89750ca651fce0ba50f75cf7feab..55bd083c9edd7aa422f76b88ef8028eef64681a7 100644 --- a/ALand.xcodeproj/project.pbxproj +++ b/ALand.xcodeproj/project.pbxproj @@ -190,6 +190,7 @@ 197BA6821CD851DB000E2087 /* JavenDetailReseller.m in Sources */ = {isa = PBXBuildFile; fileRef = 197BA6811CD851DB000E2087 /* JavenDetailReseller.m */; }; 197BA6851CD85632000E2087 /* NSNumber+Fommater.m in Sources */ = {isa = PBXBuildFile; fileRef = 197BA6841CD85632000E2087 /* NSNumber+Fommater.m */; }; 197BA6891CD865D1000E2087 /* JavencommissionAccountModel.m in Sources */ = {isa = PBXBuildFile; fileRef = 197BA6881CD865D1000E2087 /* JavencommissionAccountModel.m */; }; + 197DCD381D40CC1F00589E2C /* OrderPayViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 197DCD371D40CC1F00589E2C /* OrderPayViewController.m */; }; 199B4D681CABBCF600451E0E /* OrderDetailViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 199B4D671CABBCF600451E0E /* OrderDetailViewController.m */; }; 199B4D6A1CABBEF400451E0E /* OrderDetailTopView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 199B4D691CABBEF400451E0E /* OrderDetailTopView.xib */; }; 199B4D6D1CABBF0800451E0E /* OrderDetailTopView.m in Sources */ = {isa = PBXBuildFile; fileRef = 199B4D6C1CABBF0800451E0E /* OrderDetailTopView.m */; }; @@ -228,6 +229,7 @@ 19ADD38A1CA4E4BD00EE6E5A /* AddCommodityHeaderView.m in Sources */ = {isa = PBXBuildFile; fileRef = 19ADD3891CA4E4BD00EE6E5A /* AddCommodityHeaderView.m */; }; 19ADD38E1CA4EC1000EE6E5A /* AddCommodityHeaderCollectionReusableView.m in Sources */ = {isa = PBXBuildFile; fileRef = 19ADD38C1CA4EC1000EE6E5A /* AddCommodityHeaderCollectionReusableView.m */; }; 19ADD38F1CA4EC1000EE6E5A /* AddCommodityHeaderCollectionReusableView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 19ADD38D1CA4EC1000EE6E5A /* AddCommodityHeaderCollectionReusableView.xib */; }; + 19C135661D39465D00DC766F /* CalculateHelper.m in Sources */ = {isa = PBXBuildFile; fileRef = 19C135651D39465D00DC766F /* CalculateHelper.m */; }; 19D906AC1CC7898C00CD42DC /* MineViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 19D906AA1CC7898C00CD42DC /* MineViewController.m */; }; 19D906AD1CC7898C00CD42DC /* MineViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 19D906AB1CC7898C00CD42DC /* MineViewController.xib */; }; 19D906B61CC86DA300CD42DC /* SettingViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 19D906B41CC86DA300CD42DC /* SettingViewController.m */; }; @@ -676,6 +678,8 @@ 197BA6841CD85632000E2087 /* NSNumber+Fommater.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSNumber+Fommater.m"; sourceTree = "<group>"; }; 197BA6871CD865D1000E2087 /* JavencommissionAccountModel.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JavencommissionAccountModel.h; sourceTree = "<group>"; }; 197BA6881CD865D1000E2087 /* JavencommissionAccountModel.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = JavencommissionAccountModel.m; sourceTree = "<group>"; }; + 197DCD361D40CC1F00589E2C /* OrderPayViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = OrderPayViewController.h; sourceTree = "<group>"; }; + 197DCD371D40CC1F00589E2C /* OrderPayViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = OrderPayViewController.m; sourceTree = "<group>"; }; 199B4D661CABBCF600451E0E /* OrderDetailViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = OrderDetailViewController.h; sourceTree = "<group>"; }; 199B4D671CABBCF600451E0E /* OrderDetailViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = OrderDetailViewController.m; sourceTree = "<group>"; }; 199B4D691CABBEF400451E0E /* OrderDetailTopView.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = OrderDetailTopView.xib; sourceTree = "<group>"; }; @@ -739,6 +743,8 @@ 19ADD38B1CA4EC1000EE6E5A /* AddCommodityHeaderCollectionReusableView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AddCommodityHeaderCollectionReusableView.h; sourceTree = "<group>"; }; 19ADD38C1CA4EC1000EE6E5A /* AddCommodityHeaderCollectionReusableView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AddCommodityHeaderCollectionReusableView.m; sourceTree = "<group>"; }; 19ADD38D1CA4EC1000EE6E5A /* AddCommodityHeaderCollectionReusableView.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = AddCommodityHeaderCollectionReusableView.xib; sourceTree = "<group>"; }; + 19C135641D39465D00DC766F /* CalculateHelper.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CalculateHelper.h; sourceTree = "<group>"; }; + 19C135651D39465D00DC766F /* CalculateHelper.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CalculateHelper.m; sourceTree = "<group>"; }; 19D906A91CC7898C00CD42DC /* MineViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MineViewController.h; sourceTree = "<group>"; }; 19D906AA1CC7898C00CD42DC /* MineViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MineViewController.m; sourceTree = "<group>"; }; 19D906AB1CC7898C00CD42DC /* MineViewController.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = MineViewController.xib; sourceTree = "<group>"; }; @@ -1473,6 +1479,8 @@ 197975501CAB6F5D00407E3F /* OrderViewController.m */, 199B4D661CABBCF600451E0E /* OrderDetailViewController.h */, 199B4D671CABBCF600451E0E /* OrderDetailViewController.m */, + 197DCD361D40CC1F00589E2C /* OrderPayViewController.h */, + 197DCD371D40CC1F00589E2C /* OrderPayViewController.m */, ); name = "Order(订å•)"; path = Order; @@ -2088,6 +2096,8 @@ 199BC7CF1C9BAC9600E4E0B8 /* MyTools.m */, 19563C8C1CDB203500AFD0E0 /* MyBankClass.h */, 19563C8D1CDB203500AFD0E0 /* MyBankClass.m */, + 19C135641D39465D00DC766F /* CalculateHelper.h */, + 19C135651D39465D00DC766F /* CalculateHelper.m */, 19DCCB7F1C9AA0450072C3BF /* Categories */, 19DCCBA61C9AA0450072C3BF /* CustomCells */, 19DCCBA91C9AA0450072C3BF /* GXFBottomView.h */, @@ -2635,6 +2645,7 @@ 1912FD031CD0907D004CF976 /* MoreHotTagViewController.m in Sources */, 190A465C1CE04265006037CB /* AgreementViewController.m in Sources */, 1912FCDA1CCDC955004CF976 /* JavenResellerModel.m in Sources */, + 197DCD381D40CC1F00589E2C /* OrderPayViewController.m in Sources */, 194CB5391CD8AA4A0050E59F /* JavenQNManager.m in Sources */, 191AEE5E1CBCC6D100F5E535 /* Conditions.m in Sources */, 19563C4A1CDAEA3800AFD0E0 /* MyBandBottomView.m in Sources */, @@ -2652,6 +2663,7 @@ 197975221CA8DA8200407E3F /* CommodityDetailViewController.m in Sources */, 19DCCB771C9A9EB30072C3BF /* IBTUIViewController.m in Sources */, 191AEE5C1CBCC6D100F5E535 /* addCommodityRequestModel.m in Sources */, + 19C135661D39465D00DC766F /* CalculateHelper.m in Sources */, 19632DAE1CB38FFC0024A8A1 /* HTTPCilent.m in Sources */, 19DCCB6D1C9A9EB30072C3BF /* IBTTableView.m in Sources */, 19DCCB731C9A9EB30072C3BF /* IBTUIScrollView.m in Sources */, @@ -2926,7 +2938,7 @@ baseConfigurationReference = AAF51B5D53AE9938C03065C3 /* Pods.release.xcconfig */; buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - CODE_SIGN_IDENTITY = "iPhone Distribution: Shanghai Gomore Information Technology Co.,Ltd"; + CODE_SIGN_IDENTITY = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution: Shanghai Gomore Information Technology Co.,Ltd"; ENABLE_BITCODE = NO; GCC_PREFIX_HEADER = Aland/PrefixHeader.pch; diff --git a/ALand/CodeClass/Home/View/Commodity/CommodityListCollectionViewCell.m b/ALand/CodeClass/Home/View/Commodity/CommodityListCollectionViewCell.m index 4eccbff19c70f2118586a46f201973d01973ed40..df5d36feadad31685caefd5e131c3e1c36562e8b 100644 --- a/ALand/CodeClass/Home/View/Commodity/CommodityListCollectionViewCell.m +++ b/ALand/CodeClass/Home/View/Commodity/CommodityListCollectionViewCell.m @@ -18,15 +18,14 @@ @property (weak, nonatomic) IBOutlet MBLabelWithFontAdapter *labelBrokerageRate; //佣金 @property (weak, nonatomic) IBOutlet UILabel *labelSalesVolume; //é”€é‡ - @end @implementation CommodityListCollectionViewCell - (void)cellWithModel:(CommotityListModel *)model { - self.labelPrice.text = [NSString stringWithFormat:@"%.0f",model.price]; + self.labelPrice.text = [NSString stringWithFormat:@"%.2f",model.price]; [self.imageViewTop sd_setImageWithURL:[NSURL URLWithString:model.cover] placeholderImage:kPlaceHolderImage]; - self.labelOriginalPrice.text = [NSString stringWithFormat:@"ï¿¥%.0f", model.originalPrice]; + self.labelOriginalPrice.text = [NSString stringWithFormat:@"ï¿¥%.2f", model.originalPrice]; self.labelBrokerageRate.text = [NSString stringWithFormat:@"ï¿¥%.2f", model.commission]; self.labelSalesVolume.text = [NSString stringWithFormat:@"销é‡ï¼š%.0f", model.salesVolume]; diff --git a/ALand/CodeClass/Home/View/CommodityMutipleSelectBottomView.xib b/ALand/CodeClass/Home/View/CommodityMutipleSelectBottomView.xib index 364017372d755eec3b8ecfed4075c928797d3dc7..49f42502bf55234462f67328cabfb6e293ee93e1 100644 --- a/ALand/CodeClass/Home/View/CommodityMutipleSelectBottomView.xib +++ b/ALand/CodeClass/Home/View/CommodityMutipleSelectBottomView.xib @@ -11,7 +11,7 @@ <rect key="frame" x="0.0" y="0.0" width="320" height="95"/> <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> <subviews> - <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="kJF-jD-kCU"> + <button opaque="NO" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="kJF-jD-kCU"> <rect key="frame" x="8" y="0.0" width="67" height="95"/> <constraints> <constraint firstAttribute="height" constant="35" id="T70-gy-1Ql"/> @@ -28,14 +28,14 @@ </mask> </variation> </button> - <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="k9d-7S-PR5"> + <button opaque="NO" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="k9d-7S-PR5"> <rect key="frame" x="173" y="26" width="66" height="44"/> <fontDescription key="fontDescription" type="system" pointSize="21"/> <state key="normal" title="下架" backgroundImage="greenbtn_bg"> <color key="titleColor" white="1" alpha="1" colorSpace="calibratedWhite"/> </state> </button> - <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="QZW-mi-oUQ"> + <button opaque="NO" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="QZW-mi-oUQ"> <rect key="frame" x="100" y="26" width="65" height="44"/> <constraints> <constraint firstAttribute="height" constant="44" id="aLI-tT-ELQ"/> @@ -45,7 +45,7 @@ <color key="titleColor" white="1" alpha="1" colorSpace="calibratedWhite"/> </state> </button> - <button opaque="NO" contentMode="scaleToFill" horizontalCompressionResistancePriority="749" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="5Md-Ga-YFh"> + <button opaque="NO" contentMode="scaleToFill" horizontalCompressionResistancePriority="749" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="5Md-Ga-YFh"> <rect key="frame" x="247" y="26" width="65" height="44"/> <fontDescription key="fontDescription" type="system" pointSize="21"/> <state key="normal" title="上架" backgroundImage="greenbtn_bg"> diff --git a/ALand/CodeClass/Home/View/CommodityTableViewCell.m b/ALand/CodeClass/Home/View/CommodityTableViewCell.m index 8d3e9f5b983ea9c6d0a128d3d6c8486fce4af913..1b94e74653dbaf8cd4ea5ce761181dcebc1947a8 100644 --- a/ALand/CodeClass/Home/View/CommodityTableViewCell.m +++ b/ALand/CodeClass/Home/View/CommodityTableViewCell.m @@ -26,7 +26,7 @@ { [self.imgViewCommodity sd_setImageWithURL:[NSURL URLWithString:model.cover] placeholderImage:kPlaceHolderImage]; self.labelTitle.text = model.name; - self.labelPrice.text = [NSString stringWithFormat:@"ï¿¥%.0f",model.price]; + self.labelPrice.text = [NSString stringWithFormat:@"ï¿¥%.2f",model.price]; self.labelBrokerageRate.text = [NSString stringWithFormat:@"%.2f",model.commission]; self.labelSaleNumber.text = [NSString stringWithFormat:@"销é‡ï¼š%.0f",model.salesVolume]; diff --git a/ALand/CodeClass/Home/View/Order/OrderDetailTopView.xib b/ALand/CodeClass/Home/View/Order/OrderDetailTopView.xib index cb408b80bfa9ebffda5d08ebd0964413fc7ce856..aadc7c567c295483fc3ce5c7851760089a1f3583 100644 --- a/ALand/CodeClass/Home/View/Order/OrderDetailTopView.xib +++ b/ALand/CodeClass/Home/View/Order/OrderDetailTopView.xib @@ -11,8 +11,8 @@ <rect key="frame" x="0.0" y="0.0" width="320" height="402"/> <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> <subviews> - <view contentMode="scaleToFill" misplaced="YES" translatesAutoresizingMaskIntoConstraints="NO" id="9kH-LK-wk8"> - <rect key="frame" x="0.0" y="176" width="320" height="138"/> + <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="9kH-LK-wk8"> + <rect key="frame" x="0.0" y="178" width="320" height="102"/> <subviews> <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="收货人:" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Xru-fq-ja3"> <rect key="frame" x="45" y="22" width="68" height="21"/> @@ -47,14 +47,14 @@ </connections> </button> <imageView opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleAspectFit" image="icon_order_address" translatesAutoresizingMaskIntoConstraints="NO" id="OeX-RE-d2m"> - <rect key="frame" x="4" y="92" width="30" height="23"/> + <rect key="frame" x="4" y="74" width="30" height="23"/> <constraints> <constraint firstAttribute="width" constant="30" id="eth-Xe-EGH"/> <constraint firstAttribute="height" constant="23" id="yMF-z8-J4m"/> </constraints> </imageView> - <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="上海市 上海市 闵行区 鹤å¡å—è·¯55弄2å·232室上海市 上海市 闵行区 鹤å¡å—è·¯55弄2å·232室" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="rM9-W2-1PT"> - <rect key="frame" x="45" y="76" width="267" height="54"/> + <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="上海市 上海市 闵行区 " textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="rM9-W2-1PT"> + <rect key="frame" x="45" y="76" width="267" height="18"/> <fontDescription key="fontDescription" type="system" pointSize="15"/> <nil key="highlightedColor"/> </label> @@ -92,8 +92,8 @@ </mask> </variation> </view> - <view contentMode="scaleToFill" misplaced="YES" translatesAutoresizingMaskIntoConstraints="NO" id="kMe-iN-q0b"> - <rect key="frame" x="0.0" y="322" width="320" height="29"/> + <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="kMe-iN-q0b"> + <rect key="frame" x="0.0" y="288" width="320" height="29"/> <subviews> <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="商å“ä¿¡æ¯" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="nUT-vO-b28"> <rect key="frame" x="15" y="4" width="68" height="21"/> @@ -109,8 +109,8 @@ <constraint firstItem="nUT-vO-b28" firstAttribute="leading" secondItem="kMe-iN-q0b" secondAttribute="leading" constant="15" id="zCP-9S-LPU"/> </constraints> </view> - <view contentMode="scaleToFill" misplaced="YES" translatesAutoresizingMaskIntoConstraints="NO" id="9bs-ar-XXb"> - <rect key="frame" x="0.0" y="120" width="320" height="56"/> + <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="9bs-ar-XXb"> + <rect key="frame" x="0.0" y="120" width="320" height="58"/> <subviews> <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" misplaced="YES" text="在上海市闵行区分公" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="3" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="qgd-cT-Y2S" customClass="MBLabelWithFontAdapter"> <rect key="frame" x="45" y="8" width="232" height="18"/> diff --git a/ALand/CodeClass/Home/View/Order/SeeLogistics.h b/ALand/CodeClass/Home/View/Order/SeeLogistics.h index b6859bf9015b87e753fc04733de7d4b642cc6db2..1cb7478cbe617e245629d448f6098c06542f178d 100644 --- a/ALand/CodeClass/Home/View/Order/SeeLogistics.h +++ b/ALand/CodeClass/Home/View/Order/SeeLogistics.h @@ -9,5 +9,6 @@ #import <UIKit/UIKit.h> @interface SeeLogistics : UIView +@property (weak, nonatomic) IBOutlet UIButton *btn; @end diff --git a/ALand/CodeClass/Home/View/Order/SeeLogistics.xib b/ALand/CodeClass/Home/View/Order/SeeLogistics.xib index 2185cd781128f8471c36d2f2cc5e4554c19d9156..55059ed2eee5133b391cdf0a38c7cd424c652dc7 100644 --- a/ALand/CodeClass/Home/View/Order/SeeLogistics.xib +++ b/ALand/CodeClass/Home/View/Order/SeeLogistics.xib @@ -11,14 +11,14 @@ <rect key="frame" x="0.0" y="0.0" width="320" height="67"/> <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> <subviews> - <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="BEp-i5-uuc"> - <rect key="frame" x="52" y="12" width="216" height="44"/> + <button opaque="NO" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="BEp-i5-uuc"> + <rect key="frame" x="38" y="-1" width="244" height="70"/> <constraints> <constraint firstAttribute="width" constant="216" id="QMg-u5-sI8"/> <constraint firstAttribute="height" constant="44" id="saD-TZ-a7b"/> </constraints> <fontDescription key="fontDescription" type="system" pointSize="22"/> - <state key="normal" title="查看物æµ" backgroundImage="logistics_btn"> + <state key="normal" title="去支付" backgroundImage="logistics_btn"> <color key="titleColor" red="0.48627450979999998" green="0.76470588240000004" blue="0.1450980392" alpha="1" colorSpace="calibratedRGB"/> </state> </button> @@ -39,6 +39,9 @@ <constraint firstItem="l89-NE-khH" firstAttribute="top" secondItem="iN0-l3-epB" secondAttribute="top" id="ytH-o1-fbL"/> </constraints> <freeformSimulatedSizeMetrics key="simulatedDestinationMetrics"/> + <connections> + <outlet property="btn" destination="BEp-i5-uuc" id="hfn-1h-03v"/> + </connections> <point key="canvasLocation" x="275" y="30.5"/> </view> </objects> diff --git a/ALand/CodeClass/Home/ViewController/Order/NoPaymentTableViewController.m b/ALand/CodeClass/Home/ViewController/Order/NoPaymentTableViewController.m index c43d4a5015c127619389438dd6a98ee9dd51757c..cfe599a8aa280e5f352e0ebbda2e7a6ee4eace82 100644 --- a/ALand/CodeClass/Home/ViewController/Order/NoPaymentTableViewController.m +++ b/ALand/CodeClass/Home/ViewController/Order/NoPaymentTableViewController.m @@ -16,7 +16,8 @@ #import "OrderDetailTableViewCell.h" #import "OrderListHeaderView.h" #import "OrderListFooterView.h" - +#import "NSString+OrderState.h" +#import "SeeLogistics.h" #define kExpressCell @"OrderExpressTableViewCell.h" #define kCellId @"OrderTableViewCell.h" #define kPageSize 10 @@ -25,6 +26,7 @@ @interface NoPaymentTableViewController () @property (nonatomic, assign) NSInteger page; @property (nonatomic, strong) NSMutableArray *arrDatas; +@property (nonatomic, strong) SeeLogistics *logisticsView; @end @implementation NoPaymentTableViewController @@ -49,6 +51,8 @@ self.page += 1; [weakSelf setUpData]; }]; + + } - (NSMutableArray *)arrDatas { @@ -171,6 +175,7 @@ orderDetailVC.isShowNavigationBar = YES; orderDetailVC.model = self.arrDatas[indexPath.section]; + orderDetailVC.orderType = self.orderTag; [self.navigationController pushViewController:orderDetailVC animated:YES]; } diff --git a/ALand/CodeClass/Home/ViewController/Order/OrderDetailViewController.m b/ALand/CodeClass/Home/ViewController/Order/OrderDetailViewController.m index ce04ef42a1033b4262153a8d6c08d912dac0d2c9..170719d9a4e0baf8c585541fe9c34eac9f4ff748 100644 --- a/ALand/CodeClass/Home/ViewController/Order/OrderDetailViewController.m +++ b/ALand/CodeClass/Home/ViewController/Order/OrderDetailViewController.m @@ -14,7 +14,7 @@ #import "OrderDetailBottomView.h" #import "CommodityDetailViewController.h" #import "CommodityListModel/CommotityListModel.h" - +#import "OrderPayViewController.h" #define kCellId @"OrderDetailTableViewCell.h" @interface OrderDetailViewController ()<UITableViewDelegate, UITableViewDataSource> @property (nonatomic, strong) UITableView *tableView; @@ -56,20 +56,28 @@ self.tableView.tableFooterView = self.bottomView; //åº•éƒ¨æŸ¥çœ‹ç‰©æµæŒ‰é’® -// if (self.orderType == ORDERTOPTYPE_TRANSPORTED) { -// SeeLogistics *viewBottom = [SeeLogistics viewWithNibName:@"SeeLogistics"]; -// viewBottom.frame = CGRectMake(0, kHeight - 64 - 65, kWidth, 64 + 65); -// [self.view addSubview:viewBottom]; -// } - - - + if ([self.orderType isEqualToString:@"待支付"]) { + SeeLogistics *viewBottom = [SeeLogistics viewWithNibName:@"SeeLogistics"]; + [viewBottom.btn addTarget:self action:@selector(actionPay) forControlEvents:UIControlEventTouchUpInside]; + viewBottom.frame = CGRectMake(0, kHeight - 64 - 65, kWidth, 64 + 65); + [self.view addSubview:viewBottom]; + } // Do any additional setup after loading the view. } +- (void)actionPay { + OrderPayViewController *payVC = [[OrderPayViewController alloc] init]; + payVC.model = self.model; + [self.navigationController pushViewController:payVC animated:YES]; +} + - (void)viewDidLayoutSubviews { self.tableView.frame = CGRectMake(0, 0, kWidth, kHeight); + //åº•éƒ¨æŸ¥çœ‹ç‰©æµæŒ‰é’® + if ([self.orderType isEqualToString:@"待支付"]) { + self.tableView.frame = CGRectMake(0, 0, kWidth, kHeight - 64); + } [self.atopView updateHeight]; self.atopView.frame = CGRectMake(0, -self.atopView.height, kWidth, self.atopView.height); diff --git a/ALand/CodeClass/Home/ViewController/Order/OrderPayViewController.h b/ALand/CodeClass/Home/ViewController/Order/OrderPayViewController.h new file mode 100644 index 0000000000000000000000000000000000000000..8f829ae4b4daa7f20361245a93d683578a111b0d --- /dev/null +++ b/ALand/CodeClass/Home/ViewController/Order/OrderPayViewController.h @@ -0,0 +1,17 @@ +// +// OrderPayViewController.h +// ALand +// +// Created by Z on 16/7/21. +// Copyright © 2016å¹´ Z. All rights reserved. +// + +#import <UIKit/UIKit.h> +#import "IBTUIViewController.h" + +#import "JavenOrderModel.h" + +@interface OrderPayViewController : IBTUIViewController +@property (nonatomic, strong) JavenOrderModel *model; + +@end diff --git a/ALand/CodeClass/Home/ViewController/Order/OrderPayViewController.m b/ALand/CodeClass/Home/ViewController/Order/OrderPayViewController.m new file mode 100644 index 0000000000000000000000000000000000000000..3568179733f9c6d5ace0c59d91e67dfb6a9b8b05 --- /dev/null +++ b/ALand/CodeClass/Home/ViewController/Order/OrderPayViewController.m @@ -0,0 +1,85 @@ +// +// OrderPayViewController.m +// ALand +// +// Created by Z on 16/7/21. +// Copyright © 2016å¹´ Z. All rights reserved. +// + +#import "OrderPayViewController.h" +#import <WebKit/WebKit.h> + +@interface OrderPayViewController ()<WKNavigationDelegate, WKUIDelegate> +@property (nonatomic, strong) WKWebView *webView; + +@end + +@implementation OrderPayViewController + +- (void)viewDidLoad { + [super viewDidLoad]; + WKWebView *webView = [[WKWebView alloc] initWithFrame:CGRectMake(0, 0, kWidth, kHeight - 64)]; + UserInfo *user = [UserInfo shareInstance]; + NSString *url = [NSString stringWithFormat:@"%@Wap/orderDetail/id/%@/shop_id/%@/mobile/%@.html",user.webShopBaseUrl,self.model.billNumber,self.model.shop.uuid,user.mobilephone]; + + [webView loadRequest:[NSURLRequest requestWithURL:[NSURL URLWithString:url]]]; + self.webView = webView; + webView.navigationDelegate = self; + webView.UIDelegate = self; + [self.view addSubview:webView]; + // Do any additional setup after loading the view from its nib. +} + +#pragma mark - wkwebview delegate + +// 页é¢å¼€å§‹åŠ è½½æ—¶è°ƒç”¨ +- (void)webView:(WKWebView *)webView didStartProvisionalNavigation:(WKNavigation *)navigation +{ + + [MBProgressHUD showHUDAddedTo:self.view animated:YES]; +} + + +- (void)webView:(WKWebView *)webView runJavaScriptConfirmPanelWithMessage:(NSString *)message initiatedByFrame:(WKFrameInfo *)frame completionHandler:(void (^)(BOOL))completionHandler { + UIAlertController *alertController = [UIAlertController alertControllerWithTitle:message + message:nil + preferredStyle:UIAlertControllerStyleAlert]; + [alertController addAction:[UIAlertAction actionWithTitle:@"确定" + style:UIAlertActionStyleDefault + handler:^(UIAlertAction *action) { + completionHandler(YES); + }]]; + [alertController addAction:[UIAlertAction actionWithTitle:@"å–æ¶ˆ" + style:UIAlertActionStyleCancel + handler:^(UIAlertAction *action){ + completionHandler(NO); + }]]; + + [self presentViewController:alertController animated:YES completion:^{}]; +} + +// 页é¢åŠ è½½å®Œæˆä¹‹åŽè°ƒç”¨ +- (void)webView:(WKWebView *)webView didFinishNavigation:(WKNavigation *)navigation +{ + self.title = webView.title; + + [MBProgressHUD hideHUDForView:self.view]; +} + + +- (void)didReceiveMemoryWarning { + [super didReceiveMemoryWarning]; + // Dispose of any resources that can be recreated. +} + +/* +#pragma mark - Navigation + +// In a storyboard-based application, you will often want to do a little preparation before navigation +- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender { + // Get the new view controller using [segue destinationViewController]. + // Pass the selected object to the new view controller. +} +*/ + +@end diff --git a/ALand/CodeClass/Login/LoginViewController.xib b/ALand/CodeClass/Login/LoginViewController.xib index 7e11f00b983670ffd16d79833c3db6bb65616e19..158c607a23fb990dbf3a1b9b3706caaa0e62b96f 100644 --- a/ALand/CodeClass/Login/LoginViewController.xib +++ b/ALand/CodeClass/Login/LoginViewController.xib @@ -18,11 +18,11 @@ <rect key="frame" x="0.0" y="0.0" width="320" height="480"/> <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> <subviews> - <view hidden="YES" contentMode="scaleToFill" misplaced="YES" translatesAutoresizingMaskIntoConstraints="NO" id="a5g-v2-8Qq" userLabel="bottomBg"> + <view hidden="YES" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="a5g-v2-8Qq" userLabel="bottomBg"> <rect key="frame" x="0.0" y="480" width="320" height="0.0"/> <color key="backgroundColor" red="0.97254901959999995" green="0.97254901959999995" blue="0.97254901959999995" alpha="1" colorSpace="calibratedRGB"/> </view> - <view contentMode="scaleToFill" misplaced="YES" translatesAutoresizingMaskIntoConstraints="NO" id="Tdr-oJ-D2D"> + <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="Tdr-oJ-D2D"> <rect key="frame" x="0.0" y="0.0" width="320" height="480"/> <subviews> <imageView userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" misplaced="YES" image="login_top" translatesAutoresizingMaskIntoConstraints="NO" id="gIO-Jz-jhA"> @@ -31,7 +31,7 @@ <constraint firstAttribute="width" constant="234" id="jkq-tN-k4O"/> </constraints> </imageView> - <button opaque="NO" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="Drd-sW-LYv"> + <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="Drd-sW-LYv"> <rect key="frame" x="32" y="252" width="256" height="44"/> <constraints> <constraint firstAttribute="width" constant="300" id="1bQ-Cb-7AQ"/> @@ -50,7 +50,7 @@ <action selector="rigistAction:" destination="-1" eventType="touchUpInside" id="Qaf-df-5Yo"/> </connections> </button> - <button opaque="NO" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="Te4-Rx-W0K"> + <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="Te4-Rx-W0K"> <rect key="frame" x="32" y="326" width="256" height="44"/> <constraints> <constraint firstAttribute="width" constant="300" id="do6-tj-oIb"/> @@ -95,7 +95,7 @@ </mask> </variation> </view> - <label hidden="YES" opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" misplaced="YES" text="第三方å¸å·å¿«é€Ÿç™»å½•" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="A0v-gX-51g"> + <label hidden="YES" opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="第三方å¸å·å¿«é€Ÿç™»å½•" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="A0v-gX-51g"> <rect key="frame" x="84" y="493" width="153" height="21"/> <constraints> <constraint firstAttribute="height" constant="21" id="58L-Dk-Bgf"/> diff --git a/ALand/General/CalculateHelper.h b/ALand/General/CalculateHelper.h new file mode 100644 index 0000000000000000000000000000000000000000..d3e1cda177ccd8b6f6e2d9656533d78ea466be15 --- /dev/null +++ b/ALand/General/CalculateHelper.h @@ -0,0 +1,40 @@ +// +// CalculateHelper.h +// XFFruit +// +// Created by Z on 16/7/14. +// Copyright © 2016å¹´ Xummer. All rights reserved. +// + +#import <Foundation/Foundation.h> +typedef NS_ENUM(NSInteger, CalculateType) { + CalculateTypeAdd = 0, //åŠ + CalculateTypeSub, //å‡ + CalculateTypeMul, //乘 + CalculateTypeDiv //除 +}; +@interface CalculateHelper : NSObject + +/* + NSRoundPlain, // Round up on a tie ï¼ï¼è²Œä¼¼å–æ•´ + + NSRoundDown, // Always down == truncate ï¼ï¼åªèˆä¸å…¥ + + NSRoundUp, // Always up ï¼ï¼ åªå…¥ä¸èˆ + + NSRoundBankers // on a tie round so last digit is even 貌似四èˆäº”å…¥ + */ +/** + * 计算 + * + * @param num1 ç¬¬ä¸€ä¸ªæ•°å— + * @param num2 ç¬¬äºŒä¸ªæ•°å— + * @param type è®¡ç®—ç±»åž‹ï¼ˆåŠ å‡ä¹˜é™¤ï¼‰ + * @param roundingType å››èˆäº”入类型 + * @param coutLenth å°æ•°ç‚¹åŽé¢ä¿ç•™å‡ ä½ + * + * @return 结算结果 + */ ++ (NSDecimalNumber *)calculateNum1:(id)num1 num2:(id)num2 type:(CalculateType)type roundingType:(NSRoundingMode)roundingType cutLenth:(NSInteger)coutLenth; ++ (NSString *)doubleValueToMoneyString:(double)value; +@end diff --git a/ALand/General/CalculateHelper.m b/ALand/General/CalculateHelper.m new file mode 100644 index 0000000000000000000000000000000000000000..39216bb26d868008d6fb87b07740606b67233c3c --- /dev/null +++ b/ALand/General/CalculateHelper.m @@ -0,0 +1,83 @@ +// +// CalculateHelper.m +// XFFruit +// +// Created by Z on 16/7/14. +// Copyright © 2016å¹´ Xummer. All rights reserved. +// + +#import "CalculateHelper.h" + +@implementation CalculateHelper + + ++ (NSDecimalNumber *)calculateNum1:(id)num1 num2:(id)num2 type:(CalculateType)type roundingType:(NSRoundingMode)roundingType cutLenth:(NSInteger)coutLenth { + NSDecimalNumberHandler *roundUp = [NSDecimalNumberHandler + + decimalNumberHandlerWithRoundingMode:roundingType + + scale:coutLenth + + raiseOnExactness:NO + + raiseOnOverflow:NO + + raiseOnUnderflow:NO + + raiseOnDivideByZero:YES]; + NSDecimalNumber *decimalNum1 = [self changeType:num1]; + NSDecimalNumber *decimalNum2 = [self changeType:num2]; + + if (decimalNum1 == nil || decimalNum2 == nil) { + return @"ä¼ å…¥çš„ç±»åž‹ä¸æ£ç¡®"; + } + + NSDecimalNumber *decimalResult; + NSString *result; + switch (type) { + case CalculateTypeAdd: { + decimalResult = [decimalNum1 decimalNumberByAdding:decimalNum2 withBehavior:roundUp]; + result = [decimalResult stringValue]; + break; + } + case CalculateTypeSub: { + decimalResult = [decimalNum1 decimalNumberBySubtracting:decimalNum2 withBehavior:roundUp]; + result = [decimalResult stringValue]; + break; + } + case CalculateTypeMul: { + decimalResult = [decimalNum1 decimalNumberByMultiplyingBy:decimalNum2 withBehavior:roundUp]; + result = [decimalResult stringValue]; + break; + } + case CalculateTypeDiv: { + decimalResult = [decimalNum1 decimalNumberByDividingBy:decimalNum2 withBehavior:roundUp]; + result = [decimalResult stringValue]; + break; + } + } + + + return decimalResult; +} + ++ (NSDecimalNumber *)changeType:(id)num1 { + NSDecimalNumber *decimalNum1; + if ([num1 isKindOfClass:[NSDecimalNumber class]]) { + decimalNum1 = num1; + }else if([num1 isKindOfClass:[NSString class]]){ + decimalNum1 = [NSDecimalNumber decimalNumberWithString:num1]; + }else if ([num1 isKindOfClass:[NSNumber class]]){ + decimalNum1 = [NSDecimalNumber decimalNumberWithDecimal:[num1 decimalValue]]; + }else{ + return nil; + } + return decimalNum1; +} + + ++ (NSString *)doubleValueToMoneyString:(double)value { + return nil; +} + +@end diff --git a/ALand/Global/HTTPCilent.m b/ALand/Global/HTTPCilent.m index bbeed16859dc3e2c44cd69ddbf3cd049a7163769..c31c3b5a8c372864b7cbe4dd6408c02d70bfb125 100644 --- a/ALand/Global/HTTPCilent.m +++ b/ALand/Global/HTTPCilent.m @@ -46,8 +46,8 @@ } success:^(NSURLSessionDataTask * _Nonnull task, id _Nullable responseObject) { NSDictionary *dic = responseObject; - - CLog(@"POST successï¼-------->\n%@", [dic JSONString]); + NSString *jsonString = [dic JSONString]; + CLog(@"POST successï¼-------->\n%@", jsonString); success(task, responseObject); } failure:^(NSURLSessionDataTask * _Nullable task, NSError * _Nonnull error) { diff --git a/ALand/Info.plist b/ALand/Info.plist index 1d4dd836d4893068de47b5f2469dbf523d8d32b5..5e4707e02029407acb41ba592b61a4b692c55248 100644 --- a/ALand/Info.plist +++ b/ALand/Info.plist @@ -17,7 +17,7 @@ <key>CFBundlePackageType</key> <string>APPL</string> <key>CFBundleShortVersionString</key> - <string>1.0.2</string> + <string>1.0.4</string> <key>CFBundleSignature</key> <string>????</string> <key>CFBundleURLTypes</key> diff --git a/ALand/Macro/UrlHeader.h b/ALand/Macro/UrlHeader.h index a282dc7eaf04a518e14fed0bbf72129332563541..2908b2e32275ba8b294a47b63d0e50a78a90dab9 100644 --- a/ALand/Macro/UrlHeader.h +++ b/ALand/Macro/UrlHeader.h @@ -9,9 +9,9 @@ #ifndef UrlHeader_h #define UrlHeader_h -#define REST_BASE_URL @"http://139.196.173.244:8080/aland-server/rest" //æ£å¼çŽ¯å¢ƒ +//#define REST_BASE_URL @"http://139.196.173.244:8080/aland-server/rest" //æ£å¼çŽ¯å¢ƒ -//#define REST_BASE_URL @"http://139.196.195.30:8080/aland-server/rest" //测试环境 +#define REST_BASE_URL @"http://139.196.195.30:9090/aland-server/rest" //测试环境 #define kDomain @"0001" //组织代ç