Forráskód Böngészése

Merge branch 'main' of http://git.ddse.io:3000/tomy/JD_iOS into main

刘千军 11 hónapja
szülő
commit
a94637db70
40 módosított fájl, 1591 hozzáadás és 524 törlés
  1. 26 6
      Koala/Koala.xcodeproj/project.pbxproj
  2. 1 1
      Koala/Koala.xcodeproj/xcuserdata/mac.xcuserdatad/xcschemes/xcschememanagement.plist
  3. BIN
      Koala/Koala.xcworkspace/xcuserdata/mac.xcuserdatad/UserInterfaceState.xcuserstate
  4. 69 21
      Koala/Koala.xcworkspace/xcuserdata/mac.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist
  5. 8 9
      Koala/Koala/FX/Base/BaseTabBarController.swift
  6. 9 5
      Koala/Koala/FX/NetClass/URLS.swift
  7. 41 8
      Koala/Koala/Modular/Home/V/JDHomeMenuCell.swift
  8. 42 0
      Koala/Koala/Modular/JDMine/M/JDCashRecordModel.swift
  9. 125 12
      Koala/Koala/Modular/JDMine/V/JDExchangeRecordCell.swift
  10. 31 2
      Koala/Koala/Modular/JDMine/V/JDMineCell.swift
  11. 216 0
      Koala/Koala/Modular/JDMine/V/JDSelectAccountTypePopView.swift
  12. 214 0
      Koala/Koala/Modular/JDMine/V/JDSelectStatusTypePopView.swift
  13. 221 10
      Koala/Koala/Modular/JDMine/VC/JDDepositRecordsViewController.swift
  14. 4 2
      Koala/Koala/Modular/JDMine/VC/JDMineUserInfoViewController.swift
  15. 17 230
      Koala/Koala/Modular/JDMine/VC/JDMineViewController.swift
  16. 30 0
      Koala/Koala/Modular/JDTrade/M/JDPositionModel.swift
  17. 5 23
      Koala/Koala/Modular/JDTrade/V/JDTradeAccountCell.swift
  18. 4 1
      Koala/Koala/Modular/JDTrade/V/JDTradeAccountInfoHeaderView.swift
  19. 41 21
      Koala/Koala/Modular/JDTrade/V/JDTradeDealListCell.swift
  20. 138 46
      Koala/Koala/Modular/JDTrade/VC/JDTradeAccountHistoryOrderViewController.swift
  21. 58 42
      Koala/Koala/Modular/JDTrade/VC/JDTradeAccountHoldViewController.swift
  22. 38 18
      Koala/Koala/Modular/JDTrade/VC/JDTradeAccountPositionViewController.swift
  23. 77 39
      Koala/Koala/Modular/JDTrade/VC/JDTradeViewController.swift
  24. 15 1
      Koala/Koala/Modular/Login/V/Register/JDRegisterView.swift
  25. 5 1
      Koala/Koala/Modular/Login/V/Register/RegisterView.swift
  26. 26 0
      Koala/Koala/Modular/Mine/V/BindAccount/JDBindAccountCell.swift
  27. 2 0
      Koala/Koala/Modular/Mine/V/Mine/JDMineAvatarHeaderView.swift
  28. 25 0
      Koala/Koala/Modular/Mine/VC/MineViewController.swift
  29. 11 0
      Koala/Koala/Modular/Model/UserInfoModel/UserInfoDataModel.swift
  30. 22 0
      Koala/Koala/Other/Assets.xcassets/JDTabbar/jdtab_found_sel.imageset/Contents.json
  31. BIN
      Koala/Koala/Other/Assets.xcassets/JDTabbar/jdtab_found_sel.imageset/路径 2备份 2@2x.png
  32. BIN
      Koala/Koala/Other/Assets.xcassets/JDTabbar/jdtab_found_sel.imageset/路径 2备份 2@3x.png
  33. 22 0
      Koala/Koala/Other/Assets.xcassets/JDTabbar/jdtab_trade_sel.imageset/Contents.json
  34. BIN
      Koala/Koala/Other/Assets.xcassets/JDTabbar/jdtab_trade_sel.imageset/路径 2备份 2@2x.png
  35. BIN
      Koala/Koala/Other/Assets.xcassets/JDTabbar/jdtab_trade_sel.imageset/路径 2备份 2@3x.png
  36. 22 0
      Koala/Koala/Other/Assets.xcassets/Mine/Mine_Top_Bg.imageset/Contents.json
  37. BIN
      Koala/Koala/Other/Assets.xcassets/Mine/Mine_Top_Bg.imageset/编组 13@2x.png
  38. BIN
      Koala/Koala/Other/Assets.xcassets/Mine/Mine_Top_Bg.imageset/编组 13@3x.png
  39. 2 2
      Koala/Koala/Other/Info.plist
  40. 24 24
      Koala/Pods/Pods.xcodeproj/xcuserdata/mac.xcuserdatad/xcschemes/xcschememanagement.plist

+ 26 - 6
Koala/Koala.xcodeproj/project.pbxproj

@@ -51,6 +51,11 @@
 		04B46A952AD8EA4500421177 /* JDChangePasswordCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04B46A942AD8EA4500421177 /* JDChangePasswordCell.swift */; };
 		04B46A972AD9176F00421177 /* JDChangePasswordInputView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04B46A962AD9176F00421177 /* JDChangePasswordInputView.swift */; };
 		04B46A992AD94BC500421177 /* JDRealNameAlertPopView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04B46A982AD94BC400421177 /* JDRealNameAlertPopView.swift */; };
+		04BAACED2ADE614600454882 /* JDBindAccountCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04BAACEC2ADE614600454882 /* JDBindAccountCell.swift */; };
+		04BAACF12ADE664300454882 /* JDSelectAccountTypePopView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04BAACF02ADE664300454882 /* JDSelectAccountTypePopView.swift */; };
+		04BAACF32ADE665700454882 /* JDSelectStatusTypePopView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04BAACF22ADE665700454882 /* JDSelectStatusTypePopView.swift */; };
+		04BAACF52ADE944A00454882 /* JDCashRecordModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04BAACF42ADE944A00454882 /* JDCashRecordModel.swift */; };
+		04BAACF92ADFAF7800454882 /* JDPositionModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04BAACF82ADFAF7800454882 /* JDPositionModel.swift */; };
 		04C283102AD5233200FC04AC /* JDMineVipOpenMindCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04C2830F2AD5233200FC04AC /* JDMineVipOpenMindCell.swift */; };
 		04C283142AD5371300FC04AC /* JDMineInviteCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04C283132AD5371300FC04AC /* JDMineInviteCell.swift */; };
 		04C283162AD5522200FC04AC /* JDMineInviteSecionHeaderView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04C283152AD5522200FC04AC /* JDMineInviteSecionHeaderView.swift */; };
@@ -875,6 +880,11 @@
 		04B46A942AD8EA4500421177 /* JDChangePasswordCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDChangePasswordCell.swift; sourceTree = "<group>"; };
 		04B46A962AD9176F00421177 /* JDChangePasswordInputView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDChangePasswordInputView.swift; sourceTree = "<group>"; };
 		04B46A982AD94BC400421177 /* JDRealNameAlertPopView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDRealNameAlertPopView.swift; sourceTree = "<group>"; };
+		04BAACEC2ADE614600454882 /* JDBindAccountCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDBindAccountCell.swift; sourceTree = "<group>"; };
+		04BAACF02ADE664300454882 /* JDSelectAccountTypePopView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDSelectAccountTypePopView.swift; sourceTree = "<group>"; };
+		04BAACF22ADE665700454882 /* JDSelectStatusTypePopView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDSelectStatusTypePopView.swift; sourceTree = "<group>"; };
+		04BAACF42ADE944A00454882 /* JDCashRecordModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDCashRecordModel.swift; sourceTree = "<group>"; };
+		04BAACF82ADFAF7800454882 /* JDPositionModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDPositionModel.swift; sourceTree = "<group>"; };
 		04C2830F2AD5233200FC04AC /* JDMineVipOpenMindCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDMineVipOpenMindCell.swift; sourceTree = "<group>"; };
 		04C283132AD5371300FC04AC /* JDMineInviteCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDMineInviteCell.swift; sourceTree = "<group>"; };
 		04C283152AD5522200FC04AC /* JDMineInviteSecionHeaderView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDMineInviteSecionHeaderView.swift; sourceTree = "<group>"; };
@@ -1659,6 +1669,7 @@
 			isa = PBXGroup;
 			children = (
 				041D4EFE2AC3FD6F008ABDF7 /* JDWorkOrderModel.swift */,
+				04BAACF42ADE944A00454882 /* JDCashRecordModel.swift */,
 			);
 			path = M;
 			sourceTree = "<group>";
@@ -1667,6 +1678,7 @@
 			isa = PBXGroup;
 			children = (
 				04CEE2712AB4311F00FAA760 /* JDTradeAccountModel.swift */,
+				04BAACF82ADFAF7800454882 /* JDPositionModel.swift */,
 			);
 			path = M;
 			sourceTree = "<group>";
@@ -1986,6 +1998,8 @@
 				04C283172AD55A8700FC04AC /* JDMineInviteHeaderView.swift */,
 				04C283152AD5522200FC04AC /* JDMineInviteSecionHeaderView.swift */,
 				04B46A982AD94BC400421177 /* JDRealNameAlertPopView.swift */,
+				04BAACF02ADE664300454882 /* JDSelectAccountTypePopView.swift */,
+				04BAACF22ADE665700454882 /* JDSelectStatusTypePopView.swift */,
 			);
 			path = V;
 			sourceTree = "<group>";
@@ -2609,6 +2623,7 @@
 			children = (
 				6C0C49A2295F2860000BFEEB /* BindAccountView.swift */,
 				6C0C49A4295F287C000BFEEB /* BindAccountCell.swift */,
+				04BAACEC2ADE614600454882 /* JDBindAccountCell.swift */,
 				6C0C49A5295F287C000BFEEB /* BindAccountCell.xib */,
 			);
 			path = BindAccount;
@@ -4232,6 +4247,7 @@
 				6C3717E429AA5B23000DDD8B /* TalentDetailsHeaderView.swift in Sources */,
 				6CA7130F2957034B0047F450 /* PublicModel.swift in Sources */,
 				6CBDC8FD29730A2B003E068F /* BaseSearchView.swift in Sources */,
+				04BAACF32ADE665700454882 /* JDSelectStatusTypePopView.swift in Sources */,
 				6C2FFCBC29618250005B8180 /* FreezeAccountViewModel.swift in Sources */,
 				04CEE2922AB9990900FAA760 /* JDAFiatDepositsCell.swift in Sources */,
 				6CC37FE0298FB0330079FA5C /* AssetsDealViewModel.swift in Sources */,
@@ -4270,6 +4286,7 @@
 				6C00A9972433313300CE9ADB /* HXImagePickerConfig.swift in Sources */,
 				04CEE29E2ABBD80900FAA760 /* JDExchangeRecordCell.swift in Sources */,
 				04CEE2772AB5CA8600FAA760 /* MarketCompanyModel.swift in Sources */,
+				04BAACED2ADE614600454882 /* JDBindAccountCell.swift in Sources */,
 				6CDC5AF629CCA18100E60730 /* AFiatDepositsPayWayCell.swift in Sources */,
 				6CBB63102ADA840E0045A4C9 /* MDFinanceListCell.swift in Sources */,
 				041D4EFA2AC2AB6C008ABDF7 /* JDAFiatExchangeViewController.swift in Sources */,
@@ -4389,6 +4406,7 @@
 				04282A382ADCE17800CB4260 /* JDPhoneInputView.swift in Sources */,
 				6C00A90C242D918D00CE9ADB /* OperationalUserInfoData.swift in Sources */,
 				6C35369729817805003BB632 /* MarketPopView.swift in Sources */,
+				04BAACF52ADE944A00454882 /* JDCashRecordModel.swift in Sources */,
 				6CDC5B0229CF140500E60730 /* AHistoryDetailsViewController.swift in Sources */,
 				6C00A905242D918D00CE9ADB /* UITableView+CategoryClass.swift in Sources */,
 				04D38E922AA1C82F0047EF9C /* MarketAnnouncementViewController.swift in Sources */,
@@ -4551,6 +4569,7 @@
 				04CEE2892AB9282C00FAA760 /* InformationMarketViewController.swift in Sources */,
 				04D38E7B2A9EE8A10047EF9C /* JXSegmentedTitleGradientItemModel.swift in Sources */,
 				6CC380022992B8A80079FA5C /* AssetsDealCell.swift in Sources */,
+				04BAACF92ADFAF7800454882 /* JDPositionModel.swift in Sources */,
 				6CC37FDC298FAFF90079FA5C /* AssetsSavingsViewModel.swift in Sources */,
 				04D38E8E2AA1C0C80047EF9C /* MarketMainDetailViewController.swift in Sources */,
 				6C00A9922433313300CE9ADB /* HXImageClipScrollView.swift in Sources */,
@@ -4620,6 +4639,7 @@
 				04282A472ADD3D1900CB4260 /* JDTradeMainMenuCell.swift in Sources */,
 				04D38E602A9EE8A10047EF9C /* JXSegmentedBaseCell.swift in Sources */,
 				6C00A9592432F43600CE9ADB /* LBXPermissions.swift in Sources */,
+				04BAACF12ADE664300454882 /* JDSelectAccountTypePopView.swift in Sources */,
 				6C584E1D295B10C300CE1D2C /* BackgroundTimerMaker.swift in Sources */,
 				6C00A8F4242D918D00CE9ADB /* ESTabBarItemMoreContentView.swift in Sources */,
 				6C00A913242D918D00CE9ADB /* ProjectPrivateMethod.swift in Sources */,
@@ -4919,7 +4939,7 @@
 				CLANG_ENABLE_MODULES = YES;
 				CODE_SIGN_STYLE = Automatic;
 				CURRENT_PROJECT_VERSION = 1;
-				DEVELOPMENT_TEAM = D983PDLU58;
+				DEVELOPMENT_TEAM = Q8B6859RSC;
 				FRAMEWORK_SEARCH_PATHS = (
 					"$(inherited)",
 					"$(PROJECT_DIR)/Koala/FX/OtherClass/OtherClass/PanoRtc",
@@ -4931,8 +4951,8 @@
 					"$(inherited)",
 					"@executable_path/Frameworks",
 				);
-				MARKETING_VERSION = 1.0.1;
-				PRODUCT_BUNDLE_IDENTIFIER = com.ddse.sup;
+				MARKETING_VERSION = 1.0.2;
+				PRODUCT_BUNDLE_IDENTIFIER = com.jiduclient.app;
 				PRODUCT_NAME = "$(TARGET_NAME)";
 				SUPPORTED_PLATFORMS = "iphoneos iphonesimulator";
 				SUPPORTS_MACCATALYST = NO;
@@ -4952,7 +4972,7 @@
 				CLANG_ENABLE_MODULES = YES;
 				CODE_SIGN_STYLE = Automatic;
 				CURRENT_PROJECT_VERSION = 1;
-				DEVELOPMENT_TEAM = D983PDLU58;
+				DEVELOPMENT_TEAM = Q8B6859RSC;
 				FRAMEWORK_SEARCH_PATHS = (
 					"$(inherited)",
 					"$(PROJECT_DIR)/Koala/FX/OtherClass/OtherClass/PanoRtc",
@@ -4964,8 +4984,8 @@
 					"$(inherited)",
 					"@executable_path/Frameworks",
 				);
-				MARKETING_VERSION = 1.0.1;
-				PRODUCT_BUNDLE_IDENTIFIER = com.ddse.sup;
+				MARKETING_VERSION = 1.0.2;
+				PRODUCT_BUNDLE_IDENTIFIER = com.jiduclient.app;
 				PRODUCT_NAME = "$(TARGET_NAME)";
 				SUPPORTED_PLATFORMS = "iphoneos iphonesimulator";
 				SUPPORTS_MACCATALYST = NO;

+ 1 - 1
Koala/Koala.xcodeproj/xcuserdata/mac.xcuserdatad/xcschemes/xcschememanagement.plist

@@ -7,7 +7,7 @@
 		<key>Koala.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>2</integer>
+			<integer>27</integer>
 		</dict>
 	</dict>
 </dict>

BIN
Koala/Koala.xcworkspace/xcuserdata/mac.xcuserdatad/UserInterfaceState.xcuserstate


+ 69 - 21
Koala/Koala.xcworkspace/xcuserdata/mac.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist

@@ -231,22 +231,6 @@
       <BreakpointProxy
          BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
          <BreakpointContent
-            uuid = "898AFC8F-C88D-4462-890A-F506FAB13D51"
-            shouldBeEnabled = "No"
-            ignoreCount = "0"
-            continueAfterRunningActions = "No"
-            filePath = "Koala/Modular/JDMine/VC/JDMineViewController.swift"
-            startingColumnNumber = "9223372036854775807"
-            endingColumnNumber = "9223372036854775807"
-            startingLineNumber = "316"
-            endingLineNumber = "316"
-            landmarkName = "unknown"
-            landmarkType = "0">
-         </BreakpointContent>
-      </BreakpointProxy>
-      <BreakpointProxy
-         BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
-         <BreakpointContent
             uuid = "55544C7F-4C54-4C07-8184-D312156FEAFD"
             shouldBeEnabled = "No"
             ignoreCount = "0"
@@ -679,16 +663,80 @@
       <BreakpointProxy
          BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
          <BreakpointContent
-            uuid = "481DDB5C-A5DA-4900-ADDC-17B99BAEC281"
+            uuid = "084B48CA-27AE-456A-BB4F-F174660CBD4C"
+            shouldBeEnabled = "No"
+            ignoreCount = "0"
+            continueAfterRunningActions = "No"
+            filePath = "Koala/Modular/JDMine/V/JDExchangeRecordCell.swift"
+            startingColumnNumber = "9223372036854775807"
+            endingColumnNumber = "9223372036854775807"
+            startingLineNumber = "87"
+            endingLineNumber = "87"
+            landmarkName = "setupCellByExchangeRecord(model:)"
+            landmarkType = "7">
+            <Locations>
+               <Location
+                  uuid = "084B48CA-27AE-456A-BB4F-F174660CBD4C - 6ebf2d7fee17cc87"
+                  shouldBeEnabled = "Yes"
+                  ignoreCount = "0"
+                  continueAfterRunningActions = "No"
+                  symbolName = "Koala.JDExchangeRecordCell.setupCellByExchangeRecord(model: Koala.JDCashRecordModel) -&gt; ()"
+                  moduleName = "Koala"
+                  usesParentBreakpointCondition = "Yes"
+                  urlString = "file:///Users/mac/Desktop/%20WorkSpace/JiduClient/Koala/Koala/Modular/JDMine/V/JDExchangeRecordCell.swift"
+                  startingColumnNumber = "9223372036854775807"
+                  endingColumnNumber = "9223372036854775807"
+                  startingLineNumber = "88"
+                  endingLineNumber = "88"
+                  offsetFromSymbolStart = "144">
+               </Location>
+               <Location
+                  uuid = "084B48CA-27AE-456A-BB4F-F174660CBD4C - 6ebf2d7fee17cc87"
+                  shouldBeEnabled = "Yes"
+                  ignoreCount = "0"
+                  continueAfterRunningActions = "No"
+                  symbolName = "Koala.JDExchangeRecordCell.setupCellByExchangeRecord(model: Koala.JDCashRecordModel) -&gt; ()"
+                  moduleName = "Koala"
+                  usesParentBreakpointCondition = "Yes"
+                  urlString = "file:///Users/mac/Desktop/%20WorkSpace/JiduClient/Koala/Koala/Modular/JDMine/V/JDExchangeRecordCell.swift"
+                  startingColumnNumber = "9223372036854775807"
+                  endingColumnNumber = "9223372036854775807"
+                  startingLineNumber = "88"
+                  endingLineNumber = "88"
+                  offsetFromSymbolStart = "257">
+               </Location>
+            </Locations>
+         </BreakpointContent>
+      </BreakpointProxy>
+      <BreakpointProxy
+         BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
+         <BreakpointContent
+            uuid = "54DAA902-9327-46D7-8800-D95CF0D6B50D"
+            shouldBeEnabled = "No"
+            ignoreCount = "0"
+            continueAfterRunningActions = "No"
+            filePath = "Koala/Modular/JDMine/V/JDExchangeRecordCell.swift"
+            startingColumnNumber = "9223372036854775807"
+            endingColumnNumber = "9223372036854775807"
+            startingLineNumber = "108"
+            endingLineNumber = "108"
+            landmarkName = "setupCellByExchangeRecord(model:)"
+            landmarkType = "7">
+         </BreakpointContent>
+      </BreakpointProxy>
+      <BreakpointProxy
+         BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
+         <BreakpointContent
+            uuid = "334645D6-45C7-4FA8-88AC-E650C2E607DF"
             shouldBeEnabled = "No"
             ignoreCount = "0"
             continueAfterRunningActions = "No"
-            filePath = "Koala/Modular/JDTrade/VC/JDTradeAccountHoldViewController.swift"
+            filePath = "Koala/Modular/JDTrade/V/JDTradeDealListCell.swift"
             startingColumnNumber = "9223372036854775807"
             endingColumnNumber = "9223372036854775807"
-            startingLineNumber = "62"
-            endingLineNumber = "62"
-            landmarkName = "requestEntrustList()"
+            startingLineNumber = "149"
+            endingLineNumber = "149"
+            landmarkName = "setupCellByPositionModel(model:)"
             landmarkType = "7">
          </BreakpointContent>
       </BreakpointProxy>

+ 8 - 9
Koala/Koala/FX/Base/BaseTabBarController.swift

@@ -82,15 +82,14 @@ class BaseTabBarController: ESTabBarController {
         TabbarHoldIndex = 3
         TabbarAssetsIndex = 4
         
-        v1.tabBarItem = ESTabBarItem.init(getBasicContentView(), title: switchLanguage("首页"), image: UIImage(named: "jdtab_home_nor"), selectedImage: UIImage(named: "jdtab_home_sel")?.imageWithTintColor(color: Tabbar_SelectColor))
-        v2.tabBarItem = ESTabBarItem.init(getBasicContentView(), title: switchLanguage("市场"), image: UIImage(named: "jdtab_market_nor"), selectedImage: UIImage(named: "jdtab_market_sel")?.imageWithTintColor(color: Tabbar_SelectColor))
-//        v3.tabBarItem = ESTabBarItem.init(getBasicContentView(), title: switchLanguage("交易"), image: UIImage(named: "Tabar_unDeal"), selectedImage: UIImage(named: "Tabar_unDeal")?.imageWithTintColor(color: Tabbar_SelectColor))
-        v3.tabBarItem = ESTabBarItem.init(getBasicContentView(), title: switchLanguage("发现"), image: UIImage(named: "jdtab_found_nor"), selectedImage: UIImage(named: "Tabar_unDeal")?.imageWithTintColor(color: Tabbar_SelectColor))
-//        v4.tabBarItem = ESTabBarItem.init(getBasicContentView(), title: switchLanguage("持仓"), image: UIImage(named: "jdtab_trade_nor"), selectedImage: UIImage(named: "Tabar_unHold")?.imageWithTintColor(color: Tabbar_SelectColor))
-        v4.tabBarItem = ESTabBarItem.init(getBasicContentView(), title: switchLanguage("交易"), image: UIImage(named: "jdtab_trade_nor"), selectedImage: UIImage(named: "Tabar_unHold")?.imageWithTintColor(color: Tabbar_SelectColor))
-//        v5.tabBarItem = ESTabBarItem.init(getBasicContentView(), title: switchLanguage("资产"), image: UIImage(named: "Tabar_unAssets"), selectedImage: UIImage(named: "Tabar_unAssets")?.imageWithTintColor(color: Tabbar_SelectColor))
-        
-        v5.tabBarItem = ESTabBarItem.init(getBasicContentView(), title: switchLanguage("我的"), image: UIImage(named: "jdtab_mine_nor"), selectedImage: UIImage(named: "jdtab_mine_sel")?.imageWithTintColor(color: Tabbar_SelectColor))
+        v1.tabBarItem = ESTabBarItem.init(getBasicContentView(), title: switchLanguage("首页"), image: UIImage(named: "jdtab_home_nor"), selectedImage: UIImage(named: "jdtab_home_sel")/*?.imageWithTintColor(color: Tabbar_SelectColor)*/)
+        v2.tabBarItem = ESTabBarItem.init(getBasicContentView(), title: switchLanguage("市场"), image: UIImage(named: "jdtab_market_nor"), selectedImage: UIImage(named: "jdtab_market_sel")/*?.imageWithTintColor(color: Tabbar_SelectColor)*/)
+
+        v3.tabBarItem = ESTabBarItem.init(getBasicContentView(), title: switchLanguage("发现"), image: UIImage(named: "jdtab_found_nor"), selectedImage: UIImage(named: "jdtab_found_sel")/*?.imageWithTintColor(color: Tabbar_SelectColor)*/)
+
+        v4.tabBarItem = ESTabBarItem.init(getBasicContentView(), title: switchLanguage("交易"), image: UIImage(named: "jdtab_trade_nor"), selectedImage: UIImage(named: "jdtab_trade_sel")/*?.imageWithTintColor(color: Tabbar_SelectColor)*/)
+
+        v5.tabBarItem = ESTabBarItem.init(getBasicContentView(), title: switchLanguage("我的"), image: UIImage(named: "jdtab_mine_nor"), selectedImage: UIImage(named: "jdtab_mine_sel")/*?.imageWithTintColor(color: Tabbar_SelectColor)*/)
         
         self.viewControllers = [v1,v2,v4,v3,v5]
        

+ 9 - 5
Koala/Koala/FX/NetClass/URLS.swift

@@ -26,7 +26,7 @@ import Foundation
 
 let baseDomain = "https://api.jdnx.com/"
 let basePF = "https://info.jiduzq.com/"
-let baseWSUrl = "wss://stream.jiduzq.com"
+let baseWSUrl = "wss://stream.jdnx.com"
 let baseFilePath = "https://upload.jiduzq.com/"
 let basePicPath = "https://www.ddse.io/"
 
@@ -39,10 +39,10 @@ let HELPCENTER = "https://vcecology.zendesk.com/hc/zh-cn/categories/360002869993
 #else
  //正式环境
 
-let baseDomain = "https://fast.ddse.io/"
-let basePF = "https://pf.ddse.io/api/"
-let baseWSUrl = "wss://quick.ddse.io"
-let baseFilePath = "https://upload.ddse.io/"
+let baseDomain = "https://api.jdnx.com/"
+let basePF = "https://info.jiduzq.com/"
+let baseWSUrl = "wss://stream.jdnx.com"
+let baseFilePath = "https://upload.jiduzq.com/"
 let basePicPath = "https://www.ddse.io/"
 
 let invitationLink = "http://vcex.tech/register/?key="
@@ -175,6 +175,8 @@ let netForGetCashChannelPayList = "getCashChannelModelList"//法币支付方式
 //let netForGetCashChannelList = "getCashChannelList"//法币渠道商列表
 let netForInsertCashInto = "depositCash"//法币充值
 
+let netForGetCash = "getCash"   //获取钱包账户金额
+
 let netForSubmitDepositCashVoucher = "submitDepositCashVoucher"//法币充值
 
 
@@ -193,6 +195,8 @@ let netForGetInvestmentOutList = "getInvestmentOutList"//转出记录
 
 let netForGetCashRecordList = "getCashRecordList"//法币充值记录
 
+let netForGetPayRecordList  = "getPayRecordList" //支付记录
+
 let netForRevokeWithdrawCash = "revokeWithdrawCash"//取消法币提款
 
 

+ 41 - 8
Koala/Koala/Modular/Home/V/JDHomeMenuCell.swift

@@ -88,27 +88,60 @@ extension JDHomeMenuCell : UICollectionViewDataSource{
 
 extension JDHomeMenuCell : UICollectionViewDelegate{
     
+    
+    func showRealNamePopView() -> Void {
+
+        let pop = JDRealNameAlertPopView()
+        pop.showPopupView { index in
+            
+            let vc = RealNameViewController()
+            currentVc()?.navigationController?.pushViewController(vc, animated: true)
+            
+        }
+    }
+    
     func collectionView(_ collectionView: UICollectionView, didSelectItemAt indexPath: IndexPath) {
         
         
         if indexPath.item == 0 {
+            
+            
+            if OperationalUserInfoData.getUserInfoDataModel().identity_status == "1" {
+                
+                let vc = JDAFiatDepositsViewController()
+                currentVc()?.navigationController?.pushViewController(vc, animated: true)
+            }else{
+                self.showRealNamePopView()
+            }
+            
 
-            let vc = JDAFiatDepositsViewController()
-            currentVc()?.navigationController?.pushViewController(vc, animated: true)
+        
         } else if indexPath.item == 1 {
             
+            if OperationalUserInfoData.getUserInfoDataModel().identity_status == "1" {
+
+                let vc = JDAFiatWithdrawViewController()
+                currentVc()?.navigationController?.pushViewController(vc, animated: true)
+                
+            }else{
+                self.showRealNamePopView()
+            }
 
-            let vc = JDAFiatWithdrawViewController()
-            currentVc()?.navigationController?.pushViewController(vc, animated: true)
         } else if indexPath.item == 2 {
-            let vc = JDAFiatExchangeViewController()
-            currentVc()?.navigationController?.pushViewController(vc, animated: true)
+            
+            if OperationalUserInfoData.getUserInfoDataModel().identity_status == "1" {
+                
+                let vc = JDAFiatExchangeViewController()
+                currentVc()?.navigationController?.pushViewController(vc, animated: true)
+                
+            }else{
+                self.showRealNamePopView()
+            }
         }
         
         else {
             
-            let vc = ASelsectCurrencyViewController()
-            vc.type = .Transfer
+            let vc = JDMineServiceViewController()
             currentVc()?.navigationController?.pushViewController(vc, animated: true)
         }
         

+ 42 - 0
Koala/Koala/Modular/JDMine/M/JDCashRecordModel.swift

@@ -0,0 +1,42 @@
+//
+//  JDCashRecordModel.swift
+//  Koala
+//
+//  Created by mac on 2023/10/17.
+//  Copyright © 2023 刘千军. All rights reserved.
+//
+
+import Foundation
+
+
+
+class JDCashRecordModel: BaseModel {
+    public var id: String! = ""
+    public var uid: String! = ""
+    public var tranid: String! = ""
+    public var amount: String! = ""
+    public var balance: String! = ""
+    public var rate: String! = ""
+    public var fee: String! = ""
+    public var type: String! = ""
+    public var path: String! = ""
+    public var status: String! = ""
+    public var from: String! = ""
+    public var to: String! = ""
+    public var bak: String! = ""
+    public var ordernum: String! = ""
+    public var complete_datetime: String! = ""
+    public var insert_datetime: String! = ""
+    public var insert_type: String! = ""
+    public var symbol: String! = ""
+    public var handle_type: String! = ""
+    public var currency: String! = ""
+    public var kTime: String! = ""
+    
+    public var pay_rate : String! = ""
+    public var pay_type : String! = ""
+    public var pay_currency : String! = ""
+    public var arrive_rate : String! = ""
+    public var voucher : String! = ""
+    public var arrive_currency : String! = ""
+}

+ 125 - 12
Koala/Koala/Modular/JDMine/V/JDExchangeRecordCell.swift

@@ -13,34 +13,33 @@ class JDExchangeRecordCell: BaseTableViewCell {
     
     lazy var oldLb : UILabel = {
         let v = UILabel()
-        v.textColor = UIColor.pg_color(withHexString: "333333")
-        v.font = .systemFont(ofSize: 16)
-        v.text = "2,985.55 美元"
+        v.textColor = _color("#333333&#333333")
+        v.setTextFont(.PFSR, 16)
+        v.text = ""
         return v
     }()
     
     lazy var newLb : UILabel = {
         let v = UILabel()
-        v.textColor = UIColor.pg_color(withHexString: "A9A9A9")
-        v.font = .systemFont(ofSize: 12)
-        v.text = "48,25415.05 港元"
+        v.textColor = _color("#A9A9A9&#A9A9A9")
+        v.setTextFont(.PFSR, 12)
+        
         return v
     }()
     
     lazy var resonLb : UILabel = {
         let v = UILabel()
-        v.textColor = UIColor.pg_color(withHexString: "333333")
-        v.font = .systemFont(ofSize: 16)
-        v.text = "美元兑换港元"
+        v.textColor = _color("#333333&#333333")
+        v.setTextFont(.PFSR, 16)
         return v
         
     }()
     
     lazy var timeLb : UILabel = {
         let v = UILabel()
-        v.textColor = UIColor.pg_color(withHexString: "A6A6A6")
-        v.font = .systemFont(ofSize: 12)
-        v.text = "2023-08-10 16:43"
+        v.textColor = _color("#A6A6A6&#A6A6A6")
+        v.setTextFont(.PFSR, 12)
+        
         return v
         
     }()
@@ -80,3 +79,117 @@ class JDExchangeRecordCell: BaseTableViewCell {
         fatalError("init(coder:) has not been implemented")
     }
 }
+
+extension JDExchangeRecordCell {
+    
+    func setupCellByExchangeRecord(model : JDCashRecordModel) ->Void{
+        
+       
+        
+        var from : String = ""
+        
+        let fromDict: NSDictionary = getDictionaryFromJSONString(jsonString: model.from) as! NSDictionary
+       
+        
+        let containsKey = fromDict.allKeys.contains { return $0 as? String == "server" }
+        
+        if containsKey {
+            
+            from = fromDict["server"] as! String
+            from = getAccountNameByServer(server: from)
+        }else {
+            
+            from = "USD"
+        }
+
+        var to : String = ""
+
+        let toDict: NSDictionary = getDictionaryFromJSONString(jsonString: model.to) as! NSDictionary
+
+        let toContainsKey = toDict.allKeys.contains { return $0 as? String == "server" }
+        
+        if toContainsKey {
+            
+            to = toDict["server"] as! String
+            
+            to = getAccountNameByServer(server: to)
+        }else {
+            
+            to = "USD"
+        }
+        
+        
+        resonLb.text = from+"兑换"+to
+        
+        timeLb.text = model.complete_datetime
+        
+        
+        if from == "USD" {
+            
+            oldLb.text = precisionString(with: model.amount, precision: "2" )+" "+model.pay_currency
+            
+            let fromDecNumber : NSDecimalNumber = NSDecimalNumber.init(string: model.amount)
+            var fromNumber = fromDecNumber.doubleValue
+            
+            let feeDecNumber : NSDecimalNumber = NSDecimalNumber.init(string: model.fee)
+            var feeNumber = feeDecNumber.doubleValue
+            
+            let arriveDecNumber : NSDecimalNumber = NSDecimalNumber.init(string: model.arrive_rate)
+            let arriveNumber = arriveDecNumber.doubleValue
+            
+            fromNumber = fromNumber - feeNumber
+            
+            let toNumber = fromNumber*arriveNumber
+            
+            newLb.text = "\(toNumber)"+" "+model.arrive_currency
+            
+        } else {
+            
+            newLb.text = precisionString(with: model.amount, precision: "2" )+" "+model.arrive_currency
+         
+            let fromDecNumber : NSDecimalNumber = NSDecimalNumber.init(string: model.amount)
+            var fromNumber = fromDecNumber.doubleValue
+            
+            let feeDecNumber : NSDecimalNumber = NSDecimalNumber.init(string: model.fee)
+            var feeNumber = feeDecNumber.doubleValue
+            
+            let arriveDecNumber : NSDecimalNumber = NSDecimalNumber.init(string: model.arrive_rate)
+            let arriveNumber = arriveDecNumber.doubleValue
+            
+            fromNumber = fromNumber + feeNumber
+            
+            let toNumber = fromNumber*arriveNumber
+            
+            let oldString = "\(toNumber)"
+            
+            oldLb.text = precisionString(with: oldString, precision: "2" )+" "+model.pay_currency
+            
+        }
+
+    }
+    
+}
+
+func getAccountNameByServer(server : String) ->String {
+    
+    if server == "US" {
+        return "美股通"
+        
+    }else if server == "SH" {
+           return "A股通沪市"
+            
+    }else if server == "SZ"{
+            
+            return "A股通深市"
+    }else if server == "HK" {
+        return "港股通"
+        
+    }else if server == "CFD"{
+         return "综合账户"
+        
+    }else {
+        return "USD"
+    }
+    
+}
+

+ 31 - 2
Koala/Koala/Modular/JDMine/V/JDMineCell.swift

@@ -23,13 +23,29 @@ class JDMineCell: BaseTableViewCell {
         
         let v = UILabel()
         
-        v.textColor = .black
-        v.font = .systemFont(ofSize: 17)
+        v.textColor = _color("#000000&#000000")
+
+        v.setTextFont(.PFSR, 17)
+        return v
+        
+    }()
+    
+    lazy var subTitleLb : UILabel = {
+        let v = UILabel()
+        v.textColor = _color("#A3A3A3&#A3A3A3")
+        v.setTextFont(.PFSR, 13)
         
         return v
+    }()
+    
+    lazy var subIconIv : UIImageView = {
         
+        let v = UIImageView()
+        v.isHidden = true
+        return v
     }()
     
+    
     lazy var  line : UIView = {
         let v = UIView()
         v.backgroundColor = UIColor.pg_color(withHexString: "F2F2F2")
@@ -53,6 +69,19 @@ class JDMineCell: BaseTableViewCell {
             make.left.equalTo(iconIv.snp.right).offset(10)
         }
         
+        contentView.addSubview(subTitleLb)
+        subTitleLb.snp.makeConstraints { make in
+            make.centerY.equalTo(iconIv.snp.centerY)
+            make.right.equalTo(contentView.snp.right).offset(-8)
+        }
+        
+        contentView.addSubview(subIconIv)
+        subIconIv.snp.makeConstraints { make in
+            make.centerY.equalTo(iconIv.snp.centerY)
+            make.right.equalTo(subIconIv.snp.left).offset(-5)
+            make.size.equalTo(CGSize(width: 14, height: 14))
+        }
+        
         contentView.addSubview(line)
         line.snp.makeConstraints { make in
             make.bottom.equalTo(contentView.snp.bottom)

+ 216 - 0
Koala/Koala/Modular/JDMine/V/JDSelectAccountTypePopView.swift

@@ -0,0 +1,216 @@
+//
+//  JDSelectAccountTypePopView.swift
+//  Koala
+//
+//  Created by mac on 2023/10/17.
+//  Copyright © 2023 刘千军. All rights reserved.
+//
+
+import Foundation
+import UIKit
+class JDSelectAccountTypePopView: BaseAlertView {
+
+//    @IBOutlet weak var bgView: UIView!
+//    @IBOutlet weak var titleLab: UILabel!
+//    @IBOutlet weak var closeBtn: UIButton!
+//    @IBOutlet weak var tableView: UITableView!
+    
+    
+    lazy var bgView : UIView = {
+        let v = UIView()
+        
+        return v
+    }()
+  
+    
+    lazy var bottomView : UIView = {
+        let v = UIView()
+        v.backgroundColor = .white
+        return v
+    }()
+    
+    
+    lazy var topCloseBtn : UIButton = {
+        
+        let v = UIButton(type: .custom)
+        v.backgroundColor = .clear
+        v.addTarget(self, action: #selector(clickCloseBtnAction), for: .touchUpInside)
+        return v
+    }()
+    
+    lazy var resetBtn : UIButton = {
+        let v = UIButton(type: .custom)
+        v.setTitle(switchLanguage("重置"), for: .normal)
+        v.setTitleColor(_color("#4F4F4F&#4F4F4F"), for: .normal)
+        v.setTextFont(.PFSM, 16)
+        v.backgroundColor = _color("#F4F8F9&#F4F8F9")
+        v.layer.masksToBounds = true
+        v.layer.cornerRadius = 6
+        return v
+    }()
+    
+    lazy var confirmBtn : UIButton = {
+        let v = UIButton(type: .custom)
+        v.setTitle(switchLanguage("确认"), for: .normal)
+        v.setTitleColor(_color("#FEFFFF&#FEFFFF"), for: .normal)
+        v.setTextFont(.PFSM, 16)
+        v.backgroundColor = MainBackGroundColor
+        v.layer.masksToBounds = true
+        v.layer.cornerRadius = 6
+        return v
+    }()
+    
+    lazy var tableView : UITableView = {
+        let tableView = UITableView(frame: .zero, style: .plain)
+        tableView.delegate = self
+        tableView.dataSource = self
+        tableView.separatorStyle = .none
+        tableView.backgroundColor = .white
+        tableView.tableFooterView = UIView()
+        tableView.tableHeaderView = UIView()
+        tableView.showsVerticalScrollIndicator = false
+        tableView.showsVerticalScrollIndicator = false
+        tableView.estimatedRowHeight = 60
+        tableView.layer.masksToBounds = true
+        tableView.layer.cornerRadius = 10
+//        tableView.register(UINib.init(nibName: "AFiatDepositsPayWayCell", bundle: nil), forCellReuseIdentifier: "AFiatDepositsPayWayCell")
+        tableView.register(JDAFiatAccountBalanceCell.self, forCellReuseIdentifier: JDAFiatAccountBalanceCell.description())
+        
+        return tableView
+        
+    }()
+//    var sourceArray:[CashChannelModelListModel] = [CashChannelModelListModel]()
+        var sourceArray:[JDTradeAccountModel] = [JDTradeAccountModel]()
+//    var popupView: UIView!
+    var completeBlock: ((_ index:NSInteger)->())?
+    
+//    func loadFromNib() -> UIView {
+//        return Bundle.main.loadNibNamed("AFiatDepositsPayWayPopView", owner: self, options: nil)?.first as! UIView
+//    }
+    
+    override init(frame: CGRect) {
+        super.init(frame: frame)
+
+        self.addSubview(topCloseBtn)
+        topCloseBtn.snp.makeConstraints { make in
+            make.left.top.right.equalTo(self)
+            make.bottom.equalTo(self.snp.centerY)
+        }
+        
+        self.addSubview(bottomView)
+        bottomView.snp.makeConstraints { make in
+            make.left.right.bottom.equalTo(self)
+            make.height.equalTo(80)
+        }
+        
+        bottomView.addSubview(resetBtn)
+        resetBtn.snp.makeConstraints { make in
+            make.left.equalTo(bottomView.snp.left).offset(17)
+            make.right.equalTo(bottomView.snp.centerX).offset(-6)
+            make.centerY.equalTo(bottomView)
+            make.height.equalTo(41)
+        }
+        
+        
+        bottomView.addSubview(confirmBtn)
+        confirmBtn.snp.makeConstraints { make in
+            make.left.equalTo(bottomView.snp.centerX).offset(6)
+            make.right.equalTo(bottomView.snp.right).offset(-17)
+            make.height.equalTo(41)
+            make.centerY.equalTo(bottomView)
+        }
+        
+        
+        self.addSubview(tableView)
+        tableView.snp.makeConstraints { make in
+            make.left.right.equalTo(self)
+            make.bottom.equalTo(bottomView.snp.top).offset(6)
+            make.top.equalTo(self.snp.centerY).offset(-6)
+        }
+//        self.closeBtn.addTarget(self, action: #selector(clickCloseBtnAction), for: .touchUpInside)
+    }
+    
+    required init?(coder aDecoder: NSCoder) {
+        super.init(coder: aDecoder)
+    }
+    
+    override func dismissAlert() -> Void {
+        super.dismissAlert()
+        UIView.animate(withDuration: 0.3, animations: {
+            self.frame = CGRect(x: 0, y: SCREEN_HEIGHT, width: SCREEN_WIDTH, height: SCREEN_HEIGHT)
+        }) { (complete) in
+            self.bgView.removeFromSuperview()
+            if self.superview != nil {
+                self.removeFromSuperview()
+            }
+        }
+        
+    }
+    
+    @objc func clickCloseBtnAction(){
+        dismissAlert()
+    }
+   
+}
+
+extension JDSelectAccountTypePopView{
+    func showPopupView(source:[JDTradeAccountModel], complete:@escaping (_ index: NSInteger)->()) -> Void {
+     
+        completeBlock = complete
+        self.sourceArray = source
+      
+        self.backgroundColor = Popup_Bg_Back_Color
+        
+        let app = UIApplication.shared.delegate as? AppDelegate
+        let window = app?.window
+        window?.addSubview(self)
+        
+        self.frame = CGRect(x: 0, y: SCREEN_HEIGHT, width: SCREEN_WIDTH, height: SCREEN_HEIGHT)
+       
+       
+        UIView.animate(withDuration: 0.3) {
+            self.frame = CGRect(x: 0, y: 0, width: SCREEN_WIDTH, height: SCREEN_HEIGHT)
+        }
+    }
+    
+}
+
+extension JDSelectAccountTypePopView:UITableViewDelegate,UITableViewDataSource{
+    
+    func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
+        return self.sourceArray.count
+    }
+    
+    func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
+//        let cell:AFiatDepositsPayWayCell = tableView.dequeueReusableCell(withIdentifier: "AFiatDepositsPayWayCell", for: indexPath) as! AFiatDepositsPayWayCell
+//
+//        cell.updateCellWith(model: self.sourceArray[indexPath.row])
+//
+//        return cell
+        
+        let cell = tableView.dequeueReusableCell(withIdentifier: JDAFiatAccountBalanceCell.description()) as! JDAFiatAccountBalanceCell
+        cell.setupBalanceCellByAccount(model: self.sourceArray[indexPath.row])
+        
+        return cell
+        
+    }
+    
+    func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat {
+        return -1
+    }
+    
+    func tableView(_ tableView: UITableView, heightForHeaderInSection section: Int) -> CGFloat {
+
+        return 0
+    }
+    
+    func tableView(_ tableView: UITableView, viewForHeaderInSection section: Int) -> UIView? {
+        return UIView()
+    }
+   
+    
+    func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
+        self.completeBlock?(indexPath.row)
+        dismissAlert()
+    }
+}

+ 214 - 0
Koala/Koala/Modular/JDMine/V/JDSelectStatusTypePopView.swift

@@ -0,0 +1,214 @@
+//
+//  JDSelectStatusTypePopView.swift
+//  Koala
+//
+//  Created by mac on 2023/10/17.
+//  Copyright © 2023 刘千军. All rights reserved.
+//
+
+import Foundation
+import UIKit
+
+class JDSelectStatusTypePopView: BaseAlertView {
+
+//    @IBOutlet weak var bgView: UIView!
+//    @IBOutlet weak var titleLab: UILabel!
+//    @IBOutlet weak var closeBtn: UIButton!
+//    @IBOutlet weak var tableView: UITableView!
+    
+    
+    lazy var bgView : UIView = {
+        let v = UIView()
+        
+        return v
+    }()
+  
+    
+    lazy var bottomView : UIView = {
+        let v = UIView()
+        v.backgroundColor = .white
+        return v
+    }()
+    
+    
+    lazy var topCloseBtn : UIButton = {
+        
+        let v = UIButton(type: .custom)
+        v.backgroundColor = .clear
+        v.addTarget(self, action: #selector(clickCloseBtnAction), for: .touchUpInside)
+        return v
+    }()
+    
+    lazy var resetBtn : UIButton = {
+        let v = UIButton(type: .custom)
+        v.setTitle(switchLanguage("重置"), for: .normal)
+        v.setTitleColor(_color("#4F4F4F&#4F4F4F"), for: .normal)
+        v.setTextFont(.PFSM, 16)
+        v.backgroundColor = _color("#F4F8F9&#F4F8F9")
+        v.layer.masksToBounds = true
+        v.layer.cornerRadius = 6
+        return v
+    }()
+    
+    lazy var confirmBtn : UIButton = {
+        let v = UIButton(type: .custom)
+        v.setTitle(switchLanguage("确认"), for: .normal)
+        v.setTitleColor(_color("#FEFFFF&#FEFFFF"), for: .normal)
+        v.setTextFont(.PFSM, 16)
+        v.backgroundColor = MainBackGroundColor
+        v.layer.masksToBounds = true
+        v.layer.cornerRadius = 6
+        return v
+    }()
+    
+    lazy var tableView : UITableView = {
+        let tableView = UITableView(frame: .zero, style: .plain)
+        tableView.delegate = self
+        tableView.dataSource = self
+        tableView.separatorStyle = .none
+        tableView.backgroundColor = .white
+        tableView.tableFooterView = UIView()
+        tableView.tableHeaderView = UIView()
+        tableView.showsVerticalScrollIndicator = false
+        tableView.showsVerticalScrollIndicator = false
+        tableView.estimatedRowHeight = 60
+        tableView.layer.masksToBounds = true
+        tableView.layer.cornerRadius = 10
+
+        tableView.register(UITableViewCell.self, forCellReuseIdentifier:"Cell")
+        
+        return tableView
+        
+    }()
+
+        var sourceArray:[String] = [String]()
+
+    var completeBlock: ((_ index:NSInteger)->())?
+    
+
+    override init(frame: CGRect) {
+        super.init(frame: frame)
+
+        self.addSubview(topCloseBtn)
+        topCloseBtn.snp.makeConstraints { make in
+            make.left.top.right.equalTo(self)
+            make.bottom.equalTo(self.snp.centerY)
+        }
+        
+        self.addSubview(bottomView)
+        bottomView.snp.makeConstraints { make in
+            make.left.right.bottom.equalTo(self)
+            make.height.equalTo(80)
+        }
+        
+        bottomView.addSubview(resetBtn)
+        resetBtn.snp.makeConstraints { make in
+            make.left.equalTo(bottomView.snp.left).offset(17)
+            make.right.equalTo(bottomView.snp.centerX).offset(-6)
+            make.centerY.equalTo(bottomView)
+            make.height.equalTo(41)
+        }
+        
+        
+        bottomView.addSubview(confirmBtn)
+        confirmBtn.snp.makeConstraints { make in
+            make.left.equalTo(bottomView.snp.centerX).offset(6)
+            make.right.equalTo(bottomView.snp.right).offset(-17)
+            make.height.equalTo(41)
+            make.centerY.equalTo(bottomView)
+        }
+        
+        
+        self.addSubview(tableView)
+        tableView.snp.makeConstraints { make in
+            make.left.right.equalTo(self)
+            make.bottom.equalTo(bottomView.snp.top).offset(6)
+            make.top.equalTo(self.snp.centerY).offset(-6)
+        }
+//        self.closeBtn.addTarget(self, action: #selector(clickCloseBtnAction), for: .touchUpInside)
+    }
+    
+    required init?(coder aDecoder: NSCoder) {
+        super.init(coder: aDecoder)
+    }
+    
+    override func dismissAlert() -> Void {
+        super.dismissAlert()
+        UIView.animate(withDuration: 0.3, animations: {
+            self.frame = CGRect(x: 0, y: SCREEN_HEIGHT, width: SCREEN_WIDTH, height: SCREEN_HEIGHT)
+        }) { (complete) in
+            self.bgView.removeFromSuperview()
+            if self.superview != nil {
+                self.removeFromSuperview()
+            }
+        }
+        
+    }
+    
+    @objc func clickCloseBtnAction(){
+        dismissAlert()
+    }
+   
+}
+
+extension JDSelectStatusTypePopView{
+    func showPopupView(source:[String], complete:@escaping (_ index: NSInteger)->()) -> Void {
+     
+        completeBlock = complete
+        self.sourceArray = source
+      
+        self.backgroundColor = Popup_Bg_Back_Color
+        
+        let app = UIApplication.shared.delegate as? AppDelegate
+        let window = app?.window
+        window?.addSubview(self)
+        
+        self.frame = CGRect(x: 0, y: SCREEN_HEIGHT, width: SCREEN_WIDTH, height: SCREEN_HEIGHT)
+       
+       
+        UIView.animate(withDuration: 0.3) {
+            self.frame = CGRect(x: 0, y: 0, width: SCREEN_WIDTH, height: SCREEN_HEIGHT)
+        }
+    }
+    
+}
+
+extension JDSelectStatusTypePopView:UITableViewDelegate,UITableViewDataSource{
+    
+    func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
+        return self.sourceArray.count
+    }
+    
+    func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
+
+        
+        let cell : UITableViewCell = tableView.dequeueReusableCell(withIdentifier: "Cell", for: indexPath)
+        
+        cell.textLabel?.text = sourceArray[indexPath.row]
+
+        
+        return cell
+        
+    }
+    
+    func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat {
+        return -1
+    }
+    
+    func tableView(_ tableView: UITableView, heightForHeaderInSection section: Int) -> CGFloat {
+
+        return 0
+    }
+    
+    func tableView(_ tableView: UITableView, viewForHeaderInSection section: Int) -> UIView? {
+        return UIView()
+    }
+   
+    
+    func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
+        self.completeBlock?(indexPath.row)
+        dismissAlert()
+    }
+   
+
+}

+ 221 - 10
Koala/Koala/Modular/JDMine/VC/JDDepositRecordsViewController.swift

@@ -8,10 +8,28 @@
 
 import Foundation
 import UIKit
+import MJRefresh
 
 class JDDepositRecordsViewController: BaseViewController {
     
     
+    lazy var accountList : [JDTradeAccountModel] = {   //账户列表
+       
+        let arr: [JDTradeAccountModel] = [JDTradeAccountModel]()
+        return arr
+    }()
+    
+    
+    lazy var cashRecordList:[JDCashRecordModel] = {
+        let arr = [JDCashRecordModel]()
+        return arr
+    }()
+    
+    var pageNum : Int = 1
+    
+    
+    lazy var statusList : [String] = ["待审核" ,"已审核" ,"待处理","处理中","已完成","已驳回","待撤销","已撤销"]
+    
     var type : RecordType = .Depoist
     lazy var tableView : UITableView = {
         
@@ -23,23 +41,48 @@ class JDDepositRecordsViewController: BaseViewController {
         v.register(JDDepositRecordCell.self, forCellReuseIdentifier: JDDepositRecordCell.description())
         v.register(JDExchangeRecordCell.self, forCellReuseIdentifier: JDExchangeRecordCell.description())
         v.register(JDTransferRecordCell.self, forCellReuseIdentifier: JDTransferRecordCell.description())
+    
+        v.ly_emptyView = emptyView
         return v
             
     }()
     
+    lazy var emptyView:HDEmptyView = {
+        let emptyV:HDEmptyView = HDEmptyView.emptyActionViewWithImageStr(image: NO_DATA_IMAGE, titleStr: switchLanguage("暂无数据") as NSString, detailStr: "", btnTitleStr: "") {
+            // Dlog("点击刷新按钮")
+        }
+        emptyV.titleLabFont = _PFSR(16)
+        emptyV.titleLabTextColor = TitleTextColor
+        emptyV.backgroundColor = .clear
+        emptyV.autoShowEmptyView = true
+        return emptyV
+    }()
+    
+    
     lazy var categoryBtn : UIButton = {
         let v = UIButton(type: .custom)
         v.backgroundColor = .white
-        v.setTitle("所有币种", for: .normal)
-        v.titleLabel?.font = .systemFont(ofSize: 14)
-        v.setTitleColor(UIColor.pg_color(withHexString: "333333"), for: .normal)
-        v.setImage(UIImage(named: "record_arrow"), for: .normal)
+        v.setTitle(switchLanguage("所有币种"), for: .normal)
+
+        v.setTextFont(.PFSR, 14)
+        v.setTitleColor(_color("#333333&#333333"), for: .normal)
+        v.setImage(_image("record_arrow&record_arrow"), for: .normal)
         v.layer.masksToBounds = true
         v.layer.cornerRadius = 17
         v.layer.borderColor = UIColor.pg_color(withHexString: "E8E8E8").cgColor
+        v.addTarget(self, action: #selector(showAccountListAction), for: .touchUpInside)
+        
         return v
     }()
     
+    @objc func showAccountListAction() ->Void {
+        
+        let pop = JDSelectAccountTypePopView()
+        pop.showPopupView(source: self.accountList) { index in
+            print(index)
+        }
+    }
+    
     lazy var  statusBtn : UIButton = {
         let v = UIButton(type: .custom)
         v.backgroundColor = .white
@@ -50,26 +93,41 @@ class JDDepositRecordsViewController: BaseViewController {
         v.layer.masksToBounds = true
         v.layer.cornerRadius = 17
         v.layer.borderColor = UIColor.pg_color(withHexString: "E8E8E8").cgColor
+        
+        v.addTarget(self, action: #selector(showStatusListAction), for: .touchUpInside)
+        
         return v
     }()
     
+    @objc func showStatusListAction() ->Void {
+        
+        let pop = JDSelectStatusTypePopView()
+        pop.showPopupView(source: self.statusList) { index in
+            print(index)
+        }
+    }
+    
+    
     lazy var  exchangeBtn : UIButton = {
         let v = UIButton(type: .custom)
         v.backgroundColor = .white
-        v.setTitle("所有兑换方向", for: .normal)
+        v.setTitle("所有账户", for: .normal)
         v.titleLabel?.font = .systemFont(ofSize: 14)
         v.setTitleColor(UIColor.pg_color(withHexString: "333333"), for: .normal)
         v.setImage(UIImage(named: "record_arrow"), for: .normal)
         v.layer.masksToBounds = true
         v.layer.cornerRadius = 17
         v.layer.borderColor = UIColor.pg_color(withHexString: "E8E8E8").cgColor
+        
+        v.addTarget(self, action: #selector(showAccountListAction), for: .touchUpInside)
+        
         return v
     }()
     
     lazy var  transferBtn : UIButton = {
         let v = UIButton(type: .custom)
         v.backgroundColor = .white
-        v.setTitle("所有转账方向", for: .normal)
+        v.setTitle("所有转账方向", for: .normal)
         v.titleLabel?.font = .systemFont(ofSize: 14)
         v.setTitleColor(UIColor.pg_color(withHexString: "333333"), for: .normal)
         v.setImage(UIImage(named: "record_arrow"), for: .normal)
@@ -88,6 +146,45 @@ class JDDepositRecordsViewController: BaseViewController {
             make.edges.equalTo(view)
         }
         
+        
+        tableView.mj_header = MJRefreshHeader(refreshingBlock: { [weak self] in
+            
+            self?.pageNum = 1
+            if self?.type == .Exchange || self?.type == .Transfer {
+                
+                self?.netCashRecordList()
+            }else {
+                
+                self?.netPayRecordList()
+            }
+                
+            
+        })
+        
+        tableView.mj_footer = MJRefreshAutoFooter(refreshingBlock: { [weak self] in
+            
+            self?.pageNum += 1
+            if self?.type == .Exchange || self?.type == .Transfer {
+                
+                self?.netCashRecordList()
+            }else {
+                
+                self?.netPayRecordList()
+            }
+            
+        })
+        
+        
+        netAccountList()
+        
+        if type == .Exchange || type == .Transfer {
+            
+            netCashRecordList()
+        }else {
+            netPayRecordList()
+        }
+             
+        
     }
     
     
@@ -95,7 +192,115 @@ class JDDepositRecordsViewController: BaseViewController {
 
 
 extension JDDepositRecordsViewController {
+    func netAccountList() -> Void {
+        NetWork.NetWorkInstance.requestData(requestType: .Post, URLString: netForGetAccountList, success: { (code, result) in
+            ProgressHUD.hideHud()
+            if let dict:NSDictionary = result as? NSDictionary {
+                if let list:[NSDictionary] = dict["list"] as? [NSDictionary]{
+                    
+                    self.accountList.removeAll()
+                    for dic in list {
+                       let model = JDTradeAccountModel.deserialize(from: dic)!
+
+                            self.accountList.append(model)
+                    }
+                }else{
+                   
+                }
+            }else{
+                
+            }
+           
+        }) { (code, result) in
+            ProgressHUD.showError(status: result as! String)
+           
+        }
+    }
     
+    func netCashRecordList() -> Void {
+        
+        let param : [String : Any] = [
+            "pageNum" : pageNum,
+            "pageSize" : "10",
+            "type" : type == .Exchange ? ["1","2","3","4"] : ["200"]
+        ]
+        
+        NetWork.NetWorkInstance.requestData(requestType: .Post, URLString: netForGetCashRecordList, parameters: param, success: { (code, result) in
+            ProgressHUD.hideHud()
+            if let dict:NSDictionary = result as? NSDictionary {
+                if let list:[NSDictionary] = dict["list"] as? [NSDictionary]{
+                    
+                    if self.pageNum == 1 {
+                        self.cashRecordList.removeAll()
+                    }
+                    for dic in list {
+                       let model = JDCashRecordModel.deserialize(from: dic)!
+
+                            self.cashRecordList.append(model)
+                    }
+                    
+                    self.tableView.mj_header?.endRefreshing()
+                    self.tableView.mj_footer?.endRefreshing()
+                    self.tableView.reloadData()
+                }
+            }else{
+                self.tableView.mj_header?.endRefreshing()
+                self.tableView.mj_footer?.endRefreshing()
+                self.tableView.reloadData()
+            }
+           
+        }) { (code, result) in
+            
+            self.tableView.mj_header?.endRefreshing()
+            self.tableView.mj_footer?.endRefreshing()
+            self.tableView.reloadData()
+            ProgressHUD.showError(status: result as! String)
+           
+        }
+    }
+    
+    
+    func netPayRecordList() -> Void {
+        
+        let param : [String : Any] = [
+            "pageNum" : pageNum,
+            "pageSize" : "10",
+            "type" : type == .Depoist ? ["1","2","3","4"] : ["200"]
+        ]
+        
+        NetWork.NetWorkInstance.requestData(requestType: .Post, URLString: netForGetPayRecordList, parameters: param, success: { (code, result) in
+            ProgressHUD.hideHud()
+            if let dict:NSDictionary = result as? NSDictionary {
+                if let list:[NSDictionary] = dict["list"] as? [NSDictionary]{
+                    
+                    if self.pageNum == 1 {
+                        self.cashRecordList.removeAll()
+                    }
+                    for dic in list {
+                       let model = JDCashRecordModel.deserialize(from: dic)!
+
+                            self.cashRecordList.append(model)
+                    }
+                    
+                    self.tableView.mj_header?.endRefreshing()
+                    self.tableView.mj_footer?.endRefreshing()
+                    self.tableView.reloadData()
+                }
+            }else{
+                self.tableView.mj_header?.endRefreshing()
+                self.tableView.mj_footer?.endRefreshing()
+                self.tableView.reloadData()
+            }
+           
+        }) { (code, result) in
+            
+            self.tableView.mj_header?.endRefreshing()
+            self.tableView.mj_footer?.endRefreshing()
+            self.tableView.reloadData()
+            ProgressHUD.showError(status: result as! String)
+           
+        }
+    }
     
 }
 
@@ -109,6 +314,14 @@ extension JDDepositRecordsViewController : UITableViewDataSource{
     
     func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
         
+        if type == .Exchange  || type == .Transfer{
+            
+            return cashRecordList.count
+        } else {
+            
+            return cashRecordList.count
+        }
+        
         return 10
     }
     
@@ -171,7 +384,7 @@ extension JDDepositRecordsViewController : UITableViewDataSource{
         }else if type == .Exchange {
             
             let cell = tableView.dequeueReusableCell(withIdentifier: JDExchangeRecordCell.description()) as! JDExchangeRecordCell
-            
+            cell.setupCellByExchangeRecord(model: cashRecordList[indexPath.row])
             return cell
         }else{
             
@@ -190,9 +403,7 @@ extension JDDepositRecordsViewController : UITableViewDelegate{
     func tableView(_ tableView: UITableView, heightForHeaderInSection section: Int) -> CGFloat {
         
         return 54
-      
-        
-        
+
     }
     func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat {
         

+ 4 - 2
Koala/Koala/Modular/JDMine/VC/JDMineUserInfoViewController.swift

@@ -11,6 +11,8 @@ import UIKit
 
 class JDMineUserInfoViewController: BaseViewController {
     
+    var viewModel = MineViewModel.init()
+    
     
     lazy var tableView : UITableView = {
         
@@ -152,8 +154,8 @@ extension JDMineUserInfoViewController : UITableViewDelegate {
                 PhotoManager.shared().show { (index, imageData) in
                     
                     print( imageData)
-//                    self?.viewModel.imageData = imageData
-//                    self?.viewModel.uploadAvtar()
+                    self.viewModel.imageData = imageData
+                    self.viewModel.uploadAvtar()
                 }
                 return
             }else{

+ 17 - 230
Koala/Koala/Modular/JDMine/VC/JDMineViewController.swift

@@ -67,6 +67,8 @@ class JDMineViewController: BaseViewController {
     }()
     
     var titleAry = [[],["邀请好友", "加入我们","奖品活动"],["帮助中心" , "语言设置" , "客服和支持","意见反馈"]]
+    var subTitleAry = [[],["邀请有礼无上限", "代理计划","各种优惠好礼"],["存取款,交易疑问,看这里" , "中文繁体" , "24/7在线响应","帮极度变的更优秀"]]
+    
     
     var iconAry = [[],["jdmine_invite", "jdmine_joinus", "jdmine_active"],["jdmine_help" , "jdmine_lang" , "jdmine_service", "jdmine_feedback"]]
     
@@ -131,7 +133,16 @@ extension JDMineViewController : UITableViewDataSource {
             let cell = tableView.dequeueReusableCell(withIdentifier: JDMineCell.description())  as! JDMineCell
             
             cell.titleLb.text = titleAry[indexPath.section][indexPath.row]
+            cell.subTitleLb.text = subTitleAry[indexPath.section][indexPath.row]
             cell.iconIv.image = UIImage.init(named: iconAry[indexPath.section][indexPath.row])
+            
+            if indexPath.row == 0 {
+                cell.subIconIv.isHidden = false
+//                cell.subIconIv.image = _image("")
+            }else {
+                cell.subIconIv.isHidden = true
+            }
+            
             cell.accessoryType = .disclosureIndicator
             return cell
         }
@@ -187,8 +198,12 @@ extension JDMineViewController : UITableViewDelegate {
             }
             else if indexPath.row == 2 {
                 
-                self.showRealNamePopView()
-                
+                if OperationalUserInfoData.getUserInfoDataModel().identity_status == "1" {
+                    
+                    
+                }else{
+                    self.showRealNamePopView()
+                }
 //                let vc = JDMineActiveViewController()
 //                currentVc()?.navigationController?.pushViewController(vc, animated: true)
             }
@@ -226,241 +241,13 @@ extension JDMineViewController : UITableViewDelegate {
         let pop = JDRealNameAlertPopView()
         pop.showPopupView { index in
             
-            
             let vc = RealNameViewController()
             currentVc()?.navigationController?.pushViewController(vc, animated: true)
             
         }
-        
-//        pop.showPopupView(source: self.accountList) { index in
-//
-//
-//            print(index)
-//        }
-
     }
 }
 
 
-/*
-class JDMineHeaderView: BaseView {
-    
-    
-    lazy var  bgIv : UIImageView = {
-        
-        let v = UIImageView()
-        v.image = UIImage.init(named: "jdmine_bg")
-        return v
-    }()
-    
-    lazy var titleLb : UILabel = {
-        let  v = UILabel()
-        v.textColor = .black
-        v.font = .boldSystemFont(ofSize: 29)
-        v.text = "我的"
-        return v
-    }()
-    
-    
-    lazy var  chatBtn : UIButton = {
-        let v = UIButton(type: .custom)
-        
-        v.setImage(UIImage(named:  "Infomation_chat"), for: .normal)
-//        v.setImage(generateTintedImage(image: UIImage(bundleImageName: "CricIcons/feed_icon_write"), color: .gray), for: .normal)
-        
-        v.addTarget(self, action: #selector(chatAction), for: .touchUpInside)
-        return v
-        
-    }()
-    
-    var chatActionBlock:(()->Void)?
-    
-    @objc func chatAction(){
-        
-        if let chatBlock = self.chatActionBlock {
-            chatBlock()
-        }
-        
-    }
-    
-    lazy var  searchBtn : UIButton = {
-        let v = UIButton(type: .custom)
-        
-        v.setImage(UIImage(named:  "Infomation_search"), for: .normal)
-        
-        v.addTarget(self, action: #selector(searchAction), for: .touchUpInside)
-        return v
-        
-    }()
-    
-    var searchActionBlock:(()->Void)?
-    
-    
-    var jumpBlock:((_ type: AssetsClickType) -> ())?
-    
-    
-    @objc func searchAction(){
-        
-        print("search")
-        if let searchBlock = self.searchActionBlock {
-            searchBlock()
-        }
-        
-    }
-    
-    
-
-    @objc func menuAction(btn: UIButton)  {
-        
-        print("menu")
-        let tag = btn.tag
-        
-        if tag == 10001 {
-            
-            if let jumpblock = self.jumpBlock {
-                
-                jumpblock(.Deposit)
-                
-            }
-            
-        }else if tag == 10002 {
-            
-            if let jumblock  = self.jumpBlock {
-                jumblock(.Transfer)
-            }
-            
-            
-        }else {
-            
-            if let jumblock = self.jumpBlock {
-                
-                jumblock(.FiatWithdrawals)
-            }
-            
-        }
-        
-        
-    }
-    
-    
-    lazy var depositBtn : JDMineMenuButton = {
-        
-        let v = JDMineMenuButton(type: .custom)
-        v.titleLb.text = "存款"
-        v.iconIv.image = UIImage(named: "jdmine_deposit")
-        v.tag = 10001
-        
-        v.addTarget(self, action: #selector(menuAction(btn:)), for: .touchUpInside)
-
-        
-        v.layer.masksToBounds = true
-        v.layer.cornerRadius = 7
-        
-        return v
-    }()
-    
-    lazy var transferBtn : JDMineMenuButton = {
-        
-        let v = JDMineMenuButton(type: .custom)
-        v.titleLb.text = "转账"
-        v.iconIv.image = UIImage(named: "jdmine_transfer")
-        v.tag = 10002
-        
-        v.addTarget(self, action: #selector(menuAction(btn:)), for: .touchUpInside)
-        
-        v.layer.masksToBounds = true
-        v.layer.cornerRadius = 7
-        
-        return v
-    }()
-    
-    lazy var withdrawBtn : JDMineMenuButton = {
-        
-        let v = JDMineMenuButton(type: .custom)
-        v.titleLb.text = "取款"
-        v.iconIv.image = UIImage(named: "jdmine_transfer")
-        v.tag = 10003
-        
-        v.addTarget(self, action: #selector(menuAction(btn:)), for: .touchUpInside)
-        
-        v.layer.masksToBounds = true
-        v.layer.cornerRadius = 7
-        
-        return v
-    }()
-    
-    
-    
-    override init(frame: CGRect) {
-        super.init(frame: frame)
-        
-        self.addSubview(bgIv)
-        bgIv.snp.makeConstraints { make in
-            make.left.top.right.equalTo(self)
-            make.height.equalTo(196)
-        }
-        
-        bgIv.addSubview(titleLb)
-        titleLb.snp.makeConstraints { make in
-            make.left.equalTo(bgIv.snp.left).offset(18)
-            make.top.equalTo(bgIv.snp.top).offset(StatusBarHeight + 16)
-        }
-        
-        self.addSubview(chatBtn)
-        
-        chatBtn.snp.makeConstraints { make in
-            make.centerY.equalTo(titleLb)
-            make.right.equalTo(self.snp.right).offset(-17)
-            make.size.equalTo(CGSizeMake(35, 35))
-        }
-        
-        
-        self.addSubview(searchBtn)
-        searchBtn.snp.makeConstraints { make in
-            make.centerY.equalTo(chatBtn)
-            make.right.equalTo(chatBtn.snp.left).offset(-19)
-            make.size.equalTo(CGSizeMake(35, 35))
-        }
-        
-        let margin = 10.0
-        
-        let buttonCount = 3.0
-        
-        let itemWidth = (SCREEN_WIDTH-(margin*4)) / buttonCount
-       
-        self.addSubview(depositBtn)
-        depositBtn.snp.makeConstraints { make in
-            make.left.equalTo(self.snp.left).offset(margin)
-            make.bottom.equalTo(self.snp.bottom).offset(-18)
-            make.size.equalTo(CGSizeMake(itemWidth, 63))
-        }
-        
-        self.addSubview(transferBtn)
-        
-        transferBtn.snp.makeConstraints { make in
-            make.left.equalTo(depositBtn.snp.right).offset(margin)
-            make.bottom.equalTo(depositBtn.snp.bottom)
-            make.size.equalTo(depositBtn)
-        }
-        
-        self.addSubview(withdrawBtn)
-        withdrawBtn.snp.makeConstraints { make in
-            make.left.equalTo(transferBtn.snp.right).offset(margin)
-            make.bottom.equalTo(depositBtn.snp.bottom)
-            make.size.equalTo(depositBtn)
-        }
-        
-        
-    }
-    
-    required init?(coder: NSCoder) {
-        fatalError("init(coder:) has not been implemented")
-    }
-    
-    
-}
- 
- */
-
 
 

+ 30 - 0
Koala/Koala/Modular/JDTrade/M/JDPositionModel.swift

@@ -0,0 +1,30 @@
+//
+//  JDPositionModel.swift
+//  Koala
+//
+//  Created by mac on 2023/10/18.
+//  Copyright © 2023 刘千军. All rights reserved.
+//
+
+import Foundation
+
+class JDPositionModel:BaseModel{
+    public var comment: String! = ""
+    public var account: String! = ""
+    public var mt_code: String! = ""
+    public var symbol: String! = ""
+    public var tp: String! = ""
+    public var profit: String! = ""
+    public var open_time: String! = ""
+    public var commission: String! = ""
+    public var ticket: String! = "0"
+    public var close_price: String! = ""
+    public var close_time: String! = ""
+    public var cmd: String! = ""
+    public var swaps:String! = ""
+    public var sl: String! = ""
+    public var open_price:String! = ""
+    public var volume: String! = ""
+    
+    public var title: String! = ""
+}

+ 5 - 23
Koala/Koala/Modular/JDTrade/V/JDTradeAccountCell.swift

@@ -23,7 +23,7 @@ class JDTradeAccountCell: UITableViewCell {
         let v = UILabel()
         v.textColor = UIColor.pg_color(withHexString: "333333")
         v.font = .systemFont(ofSize: 16)
-        v.text = "钱包账户(2678)"
+        v.text = "钱包账户"
         return v
     }()
     
@@ -37,7 +37,7 @@ class JDTradeAccountCell: UITableViewCell {
         let v = UILabel()
         v.textColor = UIColor.pg_color(withHexString: "959595")
         v.font = .systemFont(ofSize: 12)
-        v.text = "资产净值.美元"
+        v.text = "资产净值.USD"
         return v
     }()
     
@@ -45,7 +45,7 @@ class JDTradeAccountCell: UITableViewCell {
         let v = UILabel()
         v.textColor = UIColor.pg_color(withHexString: "000000")
         v.font = .boldSystemFont(ofSize: 18)
-        v.text = "131.26"
+        v.text = "0.00"
         return v
     }()
     
@@ -184,25 +184,7 @@ class JDTradeAccountCell: UITableViewCell {
             networthTipLb.text = "资产净值.USD"
         }
         
-        networthLb.text = model.equity
-        
-        //        self.leftConstraint.constant = 15
-//        self.nameLab.setTextFont(.PFSR, 14)
-//        self.hintLab.setTextFont(.PFSR, 12)
-//        self.valueLab.setTextFont(.PFSR, 16)
-//        self.value1Lab.setTextFont(.PFSR, 12)
-//        self.nameLab.textColor = TitleTextColor
-//        self.hintLab.textColor = _color("#68727e&#68727e")
-//        self.valueLab.textColor = TitleTextColor
-//
-//        self.nameLab.text = model.symbol
-//        self.hintLab.text = model.description
-//
-//        self.updateNewPrice(model: model)
-//
-//        if let url = URL.init(string:fileLinkPackage(path:"png/"+model.symbol+".png")) {
-//            self.currencyView.kf.setImage(with:url, placeholder: _image("Base_W_Default_Currency&Base_W_Default_Currency"))
-//        }
+        networthLb.text = precisionString(with: model.equity, precision: "2") //model.equity
         
     }
 
@@ -292,7 +274,7 @@ class JDTradeAssetCell: BaseTableViewCell {
         let v = UILabel()
         v.textColor = .white
         v.font = .boldSystemFont(ofSize: 35)
-        v.text = "8037.08"
+        v.text = "0.00"
         return v
     }()
     

+ 4 - 1
Koala/Koala/Modular/JDTrade/V/JDTradeAccountInfoHeaderView.swift

@@ -378,7 +378,10 @@ extension JDTradeAccountInfoHeaderView {
         }
         
         assetLb.text = model.balance
-        
+        jyLb.text = precisionString(with: model.balance, precision: "2")
+        djLb.text = precisionString(with: model.margin, precision: "2")
+        kyLb.text = precisionString(with: model.margin_free, precision: "2")
+        gmlLb.text = precisionString(with: model.margin_free, precision: "2")
     }
     
 }

+ 41 - 21
Koala/Koala/Modular/JDTrade/V/JDTradeDealListCell.swift

@@ -14,36 +14,39 @@ class JDTradeDealListCell: BaseTableViewCell {
     lazy var nameLb : UILabel = {
         
         let v = UILabel()
-        v.textColor = UIColor.pg_color(withHexString: "333333")
-        v.font = .systemFont(ofSize: 15)
-        v.text = "新力控股集团"
+        v.textColor = _color("#333333&#333333")
+        v.setTextFont(.PFSR, 15)
+
+        v.text = "集团"
         return v
     }()
     
     lazy var  unitLb : UILabel = {
         
         let v = UILabel()
-        v.textColor = UIColor.pg_color(withHexString: "333333")
-        v.font = .systemFont(ofSize: 14)
-        v.text = "73738.00"
+        v.textColor = _color("#333333&#333333")
+        v.setTextFont(.PFSR, 14)
+
+        v.text = "1"
         return v
     }()
     
     lazy var  nowPriceLb : UILabel = {
         
         let v = UILabel()
-        v.textColor = UIColor.pg_color(withHexString: "333333")
-        v.font = .systemFont(ofSize: 14)
-        v.text = "0.36"
+        v.textColor = _color("#333333&#333333")
+        v.setTextFont(.PFSR, 14)
+        
         return v
     }()
     
     lazy var  codeLb : UILabel = {
         
         let v = UILabel()
-        v.textColor = UIColor.pg_color(withHexString: "AEAEAE")
-        v.font = .systemFont(ofSize: 12)
-        v.text = "345523"
+        
+        v.textColor = _color("#AEAEAE&#AEAEAE")
+        v.setTextFont(.PFSR, 12)
+        
         return v
     }()
     
@@ -51,27 +54,29 @@ class JDTradeDealListCell: BaseTableViewCell {
     lazy var  countLb : UILabel = {
         
         let v = UILabel()
-        v.textColor = UIColor.pg_color(withHexString: "AEAEAE")
-        v.font = .systemFont(ofSize: 12)
-        v.text = "93298.2"
+        
+        v.textColor = _color("#AEAEAE&#AEAEAE")
+        v.setTextFont(.PFSR, 12)
+        v.text = "100"
         return v
     }()
     
     lazy var  buyPriceLb : UILabel = {
         
         let v = UILabel()
-        v.textColor = UIColor.pg_color(withHexString: "AEAEAE")
-        v.font = .systemFont(ofSize: 12)
-        v.text = "93298.2"
+        
+        v.textColor = _color("#AEAEAE&#AEAEAE")
+        v.setTextFont(.PFSR, 12)
         return v
     }()
     
     lazy var  updownLb : UILabel = {
         
         let v = UILabel()
-        v.textColor = UIColor.pg_color(withHexString: "959595")
-        v.font = .systemFont(ofSize: 14)
-        v.text = "+0.80"
+
+        v.textColor = _color("#959595&#959595")
+        v.setTextFont(.PFSR, 14)
+        v.text = ""
         return v
     }()
     
@@ -132,7 +137,22 @@ class JDTradeDealListCell: BaseTableViewCell {
         fatalError("init(coder:) has not been implemented")
     }
     
+}
+
+extension JDTradeDealListCell {
     
+    func setupCellByPositionModel(model : JDPositionModel) ->Void{
+        
+        
+        nameLb.text = model.title
+        codeLb.text = model.symbol
+        
+        nowPriceLb.text = precisionString(with: model.close_price, precision: "2")
+        buyPriceLb.text = precisionString(with: model.open_price, precision: "2")
+        
+        updownLb.text = precisionString(with: model.profit, precision: "2")
+        
+    }
     
     
 }

+ 138 - 46
Koala/Koala/Modular/JDTrade/VC/JDTradeAccountHistoryOrderViewController.swift

@@ -15,6 +15,23 @@ class JDTradeAccountHistoryOrderViewController: BaseViewController {
     
     var accountModel : JDTradeAccountModel?
     var dateStr:(String,String) = ("","")
+    
+    var startDate:String = dateToString(stmap: decimalNumber(A:currentTimeStamp(), B: "86400", type: .Subtract) , formatter: "yyyy-MM-dd"){
+        didSet{
+//            self.netGetCloseOrderList()
+        }
+    }
+    var endDate:String = dateToString(stmap: currentTimeStamp(), formatter: "yyyy-MM-dd"){
+        didSet{
+//            self.netGetCloseOrderList()
+        }
+    }
+    
+    lazy var orderList:[JDPositionModel] = {
+        let arr:[JDPositionModel] = [JDPositionModel]()
+        return arr
+    }()
+    
     lazy var tableView : UITableView = {
         
         let v = UITableView(frame: .zero, style: .plain)
@@ -28,6 +45,21 @@ class JDTradeAccountHistoryOrderViewController: BaseViewController {
         
     }()
     
+    lazy var totalLrLb : UILabel = {
+        let v = UILabel()
+        v.setTextFont(.PFSR, 15)
+        v.textColor = _color("#333333&#333333")
+        v.text = "0"
+        return v
+    }()
+    lazy var totalJyLb : UILabel = {
+        let v = UILabel()
+        v.setTextFont(.PFSR, 15)
+        v.textColor = _color("#333333&#333333")
+        v.text = "0"
+        return v
+    }()
+    
     override func viewDidLoad() {
         super.viewDidLoad()
         
@@ -41,41 +73,47 @@ class JDTradeAccountHistoryOrderViewController: BaseViewController {
             make.edges.equalTo(self.view)
         }
         
-        self.requestEntrustList()
+        self.netGetCloseOrderList()
     }
     
 }
 
 extension JDTradeAccountHistoryOrderViewController {
     
-    func requestEntrustList() ->Void {
+    func netGetCloseOrderList() ->Void {
         
         
         let param = [
+            
+            "pageNum" : "1",
+            "startDate" : self.startDate,
+            "endDate" : self.endDate,
             "account": self.accountModel?.account ?? "" ,
             "server" : self.accountModel?.server ?? ""
             
         ] as [String : Any]
         
         
-        NetWork.NetWorkInstance.requestData(requestType: .Post, URLString: netForGetEntrustList,parameters: param,success: { (code, result) in
-            
+        NetWork.NetWorkInstance.requestData(requestType: .Post, URLString: netForGetCloseOrderList,parameters: param,success: { (code, result) in
+        
             ProgressHUD.hideHud()
-//            if let dict:NSDictionary = result as? NSDictionary {
-//                if let list:[NSDictionary] = dict["list"] as? [NSDictionary]{
-//                    self.entrustList.removeAll()
-//                    for dic in list {
-//                       let model = EntrustListModel.deserialize(from: dic)!
-//                        self.entrustList.append(model)
-//                    }
-//                    observer.send(value: true)
-//                }else{
-//                    observer.send(value: false)
-//                }
-//            }else{
-//                observer.send(value: false)
-//            }
-//            observer.sendCompleted()
+            
+            if let dict: NSDictionary = result as? NSDictionary {
+                
+                if let list: [NSDictionary] = dict["list"] as? [NSDictionary]{
+                    self.orderList.removeAll()
+                    
+                    for dic in list {
+                        
+                        let model = JDPositionModel.deserialize(from: dic)!
+                        
+                        self.orderList.append(model)
+                        
+                    }
+                }
+                
+                self.tableView.reloadData()
+            }
         }) { (code, result) in
             ProgressHUD.showError(status: result as! String)
         }
@@ -100,13 +138,15 @@ extension JDTradeAccountHistoryOrderViewController: UITableViewDelegate,UITableV
         dateView.segmentedControl.indexChangeBlock = {[weak self](index) in
             guard let self = self else{return}
             if index == 0 {
-//                self.VM?.startDate = dateToString(stmap: decimalNumber(A:currentTimeStamp(), B: "86400", type: .Subtract) , formatter: "yyyy-MM-dd")
+                self.startDate = dateToString(stmap: decimalNumber(A:currentTimeStamp(), B: "86400", type: .Subtract) , formatter: "yyyy-MM-dd")
+                
+                
             }
             else if index == 1{
-//                self.VM?.startDate = dateToString(stmap: decimalNumber(A:currentTimeStamp(), B: "604800", type: .Subtract) , formatter: "yyyy-MM-dd")
+                self.startDate = dateToString(stmap: decimalNumber(A:currentTimeStamp(), B: "604800", type: .Subtract) , formatter: "yyyy-MM-dd")
             }
             else if index == 2{
-//                self.VM?.startDate = dateToString(stmap: decimalNumber(A:currentTimeStamp(), B: "2592000", type: .Subtract) , formatter: "yyyy-MM-dd")
+                self.startDate = dateToString(stmap: decimalNumber(A:currentTimeStamp(), B: "2592000", type: .Subtract) , formatter: "yyyy-MM-dd")
             }else if index == 3{
                 let pop = PositionHistoryDatePopView()
                 if self.dateStr.0.length == 0 {
@@ -115,11 +155,14 @@ extension JDTradeAccountHistoryOrderViewController: UITableViewDelegate,UITableV
                 }
                 pop.showPopupView(date: self.dateStr) { dateStr in
                     self.dateStr = dateStr
-//                    self.VM?.endDate = dateStr.1
-//                    self.VM?.startDate = dateStr.0
+                    self.endDate = dateStr.1
+                    self.startDate = dateStr.0
                    
                 }
             }
+            
+            self.netGetCloseOrderList()
+            
         }
         headerView.addSubview(dateView)
         
@@ -177,12 +220,76 @@ extension JDTradeAccountHistoryOrderViewController: UITableViewDelegate,UITableV
     }
     
     func tableView(_ tableView: UITableView, heightForFooterInSection section: Int) -> CGFloat {
-        return 54
+        return 54 + 80
     }
     
     func tableView(_ tableView: UITableView, viewForFooterInSection section: Int) -> UIView? {
         
-        let v = UIView(frame: CGRectMake(0, 0, SCREEN_WIDTH, 54))
+        let v = UIView(frame: CGRectMake(0, 0, SCREEN_WIDTH, 54 + 80))
+        
+        let lrView = UIView()
+        v.addSubview(lrView)
+        lrView.snp.makeConstraints { make in
+            make.left.top.right.equalTo(v)
+            make.height.equalTo(40)
+        }
+        
+        let lrLb = UILabel()
+        lrLb.setTextFont(.PFSR, 15)
+        lrLb.textColor = _color("#7C7C7C&#7C7C7C")
+        lrLb.text = switchLanguage("利润")
+        
+        lrView.addSubview(lrLb)
+        lrLb.snp.makeConstraints { make in
+            make.centerY.equalTo(lrView)
+            make.left.equalTo(lrView.snp.left).offset(17)
+        }
+        
+        lrView.addSubview(totalLrLb)
+        totalLrLb.snp.makeConstraints { make in
+            make.centerY.equalTo(lrView)
+            make.right.equalTo(lrView.snp.right).offset(-17)
+        }
+        
+        let lineView = UIView()
+        
+        lineView.backgroundColor = _color("#F0F0F0&#F0F0F0")
+        v.addSubview(lineView)
+        lineView.snp.makeConstraints { make in
+            make.left.right.equalTo(v)
+            make.top.equalTo(lrView.snp.bottom)
+            make.height.equalTo(1)
+        }
+        
+        let jyView = UIView()
+        v.addSubview(jyView)
+        jyView.snp.makeConstraints { make in
+            make.top.equalTo(lineView.snp.bottom)
+            make.left.right.equalTo(v)
+            make.height.equalTo(40)
+        }
+        
+       
+        
+        let jyLb = UILabel()
+        jyLb.setTextFont(.PFSR, 15)
+        jyLb.textColor = _color("#7C7C7C&#7C7C7C")
+        jyLb.text = switchLanguage("结余")
+        
+        jyView.addSubview(jyLb)
+        jyLb.snp.makeConstraints { make in
+            make.centerY.equalTo(jyView)
+            make.left.equalTo(jyView.snp.left).offset(17)
+        }
+       
+        jyView.addSubview(totalJyLb)
+        totalJyLb.snp.makeConstraints { make in
+            make.centerY.equalTo(jyView)
+            make.right.equalTo(jyView.snp.right).offset(-17)
+        }
+        
+        totalJyLb.text = precisionString(with: self.accountModel?.balance ?? "0.00", precision: "2")
+        
         let tipLb = UILabel()
         tipLb.font = .systemFont(ofSize: 12)
         tipLb.textColor = UIColor.pg_color(withHexString: "B1B9C1")
@@ -190,42 +297,27 @@ extension JDTradeAccountHistoryOrderViewController: UITableViewDelegate,UITableV
         tipLb.textAlignment = .center
         v.addSubview(tipLb)
         tipLb.snp.makeConstraints { make in
-            make.center.equalTo(v)
+            make.top.equalTo(jyView.snp.bottom).offset(15)
+            make.centerX.equalTo(v)
         }
         return v
     }
     
-    
     func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
-        1
+        return  orderList.count
     }
     
     func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
-//        let cell:DealListCell = tableView.dequeueReusableCell(withIdentifier: "DealListCell") as! DealListCell
-//        if self.headerView.segmentedControl.selectedSegmentIndex == 0 {
-//            let model = self.VM?.positionList[indexPath.row]
-//            cell.updatePositionCellWith(model: model!)
-//        }
-//        else if self.headerView.segmentedControl.selectedSegmentIndex == 1{
-//            let model = self.VM?.entrustList[indexPath.row]
-//            cell.updateEntrustCellWith(model: model!)
-//        }else{
-//            let model = self.VM?.closeOrderList[indexPath.row]
-//            cell.updateCloseOrderCellWith(model: model!)
-//        }
         
         let cell = tableView.dequeueReusableCell(withIdentifier: JDTradeDealListCell.description()) as! JDTradeDealListCell
-        
+        cell.setupCellByPositionModel(model: self.orderList[indexPath.row])
         return cell
     }
     
     func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat {
         return 62
     }
-    
-    
-    
-    
+ 
 }
 
 extension JDTradeAccountHistoryOrderViewController: JXSegmentedListContainerViewListDelegate {

+ 58 - 42
Koala/Koala/Modular/JDTrade/VC/JDTradeAccountHoldViewController.swift

@@ -14,19 +14,35 @@ class JDTradeAccountHoldViewController: BaseViewController {
     
     var accountModel : JDTradeAccountModel?
     
+    lazy var positionList:[JDPositionModel] = {
+        let arr:[JDPositionModel] = [JDPositionModel]()
+        return arr
+    }()
+    
     lazy var tableView : UITableView = {
         
         let v = UITableView(frame: .zero, style: .plain)
         v.delegate = self
         v.dataSource = self
         v.separatorStyle = .singleLine
-//        v.register(UINib.init(nibName: "DealListCell", bundle: nil), forCellReuseIdentifier: "DealListCell")
         
         v.register(JDTradeDealListCell.self, forCellReuseIdentifier: JDTradeDealListCell.description())
+        v.ly_emptyView = emptyView
         return v
         
     }()
     
+    lazy var emptyView:HDEmptyView = {
+        let emptyV:HDEmptyView = HDEmptyView.emptyActionViewWithImageStr(image: NO_DATA_IMAGE, titleStr: switchLanguage("暂无数据") as NSString, detailStr: "", btnTitleStr: "") {
+            // Dlog("点击刷新按钮")
+        }
+        emptyV.titleLabFont = _PFSR(16)
+        emptyV.titleLabTextColor = TitleTextColor
+        emptyV.backgroundColor = .clear
+        emptyV.autoShowEmptyView = true
+        return emptyV
+    }()
+    
     override func viewDidLoad() {
         super.viewDidLoad()
         
@@ -57,24 +73,27 @@ extension JDTradeAccountHoldViewController {
         ] as [String : Any]
         
         
-        NetWork.NetWorkInstance.requestData(requestType: .Post, URLString: netForGetEntrustList,parameters: param,success: { (code, result) in
+        NetWork.NetWorkInstance.requestData(requestType: .Post, URLString: netForGetPositionList,parameters: param,success: { (code, result) in
             
             ProgressHUD.hideHud()
-//            if let dict:NSDictionary = result as? NSDictionary {
-//                if let list:[NSDictionary] = dict["list"] as? [NSDictionary]{
-//                    self.entrustList.removeAll()
-//                    for dic in list {
-//                       let model = EntrustListModel.deserialize(from: dic)!
-//                        self.entrustList.append(model)
-//                    }
-//                    observer.send(value: true)
-//                }else{
-//                    observer.send(value: false)
-//                }
-//            }else{
-//                observer.send(value: false)
-//            }
-//            observer.sendCompleted()
+            
+            if let dict: NSDictionary = result as? NSDictionary {
+                
+                if let list: [NSDictionary] = dict["list"] as? [NSDictionary]{
+                    self.positionList.removeAll()
+                    
+                    for dic in list {
+                        
+                        let model = JDPositionModel.deserialize(from: dic)!
+                        
+                        self.positionList.append(model)
+                        
+                    }
+                }
+                
+                self.tableView.reloadData()
+            }
+            
         }) { (code, result) in
             ProgressHUD.showError(status: result as! String)
         }
@@ -95,7 +114,7 @@ extension JDTradeAccountHoldViewController: UITableViewDelegate,UITableViewDataS
         
         let view = UIView(frame: CGRect(x: 0, y: 0, width: SCREEN_WIDTH, height: 40))
         
-       
+        
         let codeLb = UILabel()
         codeLb.font = .systemFont(ofSize: 12)
         codeLb.textColor = UIColor.pg_color(withHexString: "AEAEAE")
@@ -106,13 +125,13 @@ extension JDTradeAccountHoldViewController: UITableViewDelegate,UITableViewDataS
             make.centerY.equalTo(view)
             make.left.equalTo(view.snp.left).offset(18)
         }
-            
+        
         
         let countLb = UILabel()
         countLb.font = .systemFont(ofSize: 12)
         countLb.textColor = UIColor.pg_color(withHexString: "AEAEAE")
         countLb.text = "单位/数量"
-    
+        
         view.addSubview(countLb)
         countLb.snp.makeConstraints { make in
             make.centerY.equalTo(view)
@@ -123,26 +142,26 @@ extension JDTradeAccountHoldViewController: UITableViewDelegate,UITableViewDataS
         priceLb.font = .systemFont(ofSize: 12)
         priceLb.textColor = UIColor.pg_color(withHexString: "AEAEAE")
         priceLb.text = "现价/成本"
-    
+        
         view.addSubview(priceLb)
         priceLb.snp.makeConstraints { make in
             make.centerY.equalTo(view)
             make.left.equalTo(view.snp.centerX).offset(20)
         }
-
+        
         let holdLb = UILabel()
         holdLb.font = .systemFont(ofSize: 12)
         holdLb.textColor = UIColor.pg_color(withHexString: "AEAEAE")
         holdLb.text = "持仓盈亏"
-    
+        
         view.addSubview(holdLb)
         holdLb.snp.makeConstraints { make in
             make.centerY.equalTo(view)
             make.right.equalTo(view.snp.right).offset(-17)
         }
-
         
-         return view
+        
+        return view
     }
     
     func tableView(_ tableView: UITableView, heightForFooterInSection section: Int) -> CGFloat {
@@ -166,25 +185,25 @@ extension JDTradeAccountHoldViewController: UITableViewDelegate,UITableViewDataS
     
     
     func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
-        1
+        return self.positionList.count
     }
     
     func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
-//        let cell:DealListCell = tableView.dequeueReusableCell(withIdentifier: "DealListCell") as! DealListCell
-//        if self.headerView.segmentedControl.selectedSegmentIndex == 0 {
-//            let model = self.VM?.positionList[indexPath.row]
-//            cell.updatePositionCellWith(model: model!)
-//        }
-//        else if self.headerView.segmentedControl.selectedSegmentIndex == 1{
-//            let model = self.VM?.entrustList[indexPath.row]
-//            cell.updateEntrustCellWith(model: model!)
-//        }else{
-//            let model = self.VM?.closeOrderList[indexPath.row]
-//            cell.updateCloseOrderCellWith(model: model!)
-//        }
+        //        let cell:DealListCell = tableView.dequeueReusableCell(withIdentifier: "DealListCell") as! DealListCell
+        //        if self.headerView.segmentedControl.selectedSegmentIndex == 0 {
+        //            let model = self.VM?.positionList[indexPath.row]
+        //            cell.updatePositionCellWith(model: model!)
+        //        }
+        //        else if self.headerView.segmentedControl.selectedSegmentIndex == 1{
+        //            let model = self.VM?.entrustList[indexPath.row]
+        //            cell.updateEntrustCellWith(model: model!)
+        //        }else{
+        //            let model = self.VM?.closeOrderList[indexPath.row]
+        //            cell.updateCloseOrderCellWith(model: model!)
+        //        }
         
         let cell = tableView.dequeueReusableCell(withIdentifier: JDTradeDealListCell.description()) as! JDTradeDealListCell
-        
+        cell.setupCellByPositionModel(model: self.positionList[indexPath.row])
         return cell
     }
     
@@ -192,9 +211,6 @@ extension JDTradeAccountHoldViewController: UITableViewDelegate,UITableViewDataS
         return 62
     }
     
-    
-    
-    
 }
 
 extension JDTradeAccountHoldViewController: JXSegmentedListContainerViewListDelegate {

+ 38 - 18
Koala/Koala/Modular/JDTrade/VC/JDTradeAccountPositionViewController.swift

@@ -14,19 +14,36 @@ class JDTradeAccountPositionViewController: BaseViewController {
     
     var accountModel : JDTradeAccountModel?
     
+    lazy var positionList:[JDPositionModel] = {
+        let arr:[JDPositionModel] = [JDPositionModel]()
+        return arr
+    }()
+    
     lazy var tableView : UITableView = {
         
         let v = UITableView(frame: .zero, style: .plain)
         v.delegate = self
         v.dataSource = self
         v.separatorStyle = .singleLine
-//        v.register(UINib.init(nibName: "DealListCell", bundle: nil), forCellReuseIdentifier: "DealListCell")
         
         v.register(JDTradeDealListCell.self, forCellReuseIdentifier: JDTradeDealListCell.description())
+        v.ly_emptyView = emptyView
         return v
         
     }()
     
+    lazy var emptyView:HDEmptyView = {
+        let emptyV:HDEmptyView = HDEmptyView.emptyActionViewWithImageStr(image: NO_DATA_IMAGE, titleStr: switchLanguage("暂无数据") as NSString, detailStr: "", btnTitleStr: "") {
+            // Dlog("点击刷新按钮")
+        }
+        emptyV.titleLabFont = _PFSR(16)
+        emptyV.titleLabTextColor = TitleTextColor
+        emptyV.backgroundColor = .clear
+        emptyV.autoShowEmptyView = true
+        return emptyV
+    }()
+    
+    
     override func viewDidLoad() {
         super.viewDidLoad()
         
@@ -57,24 +74,27 @@ extension JDTradeAccountPositionViewController {
         ] as [String : Any]
         
         
-        NetWork.NetWorkInstance.requestData(requestType: .Post, URLString: netForGetPositionList,parameters: param,success: { (code, result) in
+        NetWork.NetWorkInstance.requestData(requestType: .Post, URLString: netForGetEntrustList,parameters: param,success: { (code, result) in
             
             ProgressHUD.hideHud()
-//            if let dict:NSDictionary = result as? NSDictionary {
-//                if let list:[NSDictionary] = dict["list"] as? [NSDictionary]{
-//                    self.entrustList.removeAll()
-//                    for dic in list {
-//                       let model = EntrustListModel.deserialize(from: dic)!
-//                        self.entrustList.append(model)
-//                    }
-//                    observer.send(value: true)
-//                }else{
-//                    observer.send(value: false)
-//                }
-//            }else{
-//                observer.send(value: false)
-//            }
-//            observer.sendCompleted()
+            
+            if let dict: NSDictionary = result as? NSDictionary {
+                
+                if let list: [NSDictionary] = dict["list"] as? [NSDictionary]{
+                    self.positionList.removeAll()
+                    
+                    for dic in list {
+                        
+                        let model = JDPositionModel.deserialize(from: dic)!
+                        
+                        self.positionList.append(model)
+                        
+                    }
+                }
+                
+                self.tableView.reloadData()
+            }
+            
         }) { (code, result) in
             ProgressHUD.showError(status: result as! String)
         }
@@ -166,7 +186,7 @@ extension JDTradeAccountPositionViewController: UITableViewDelegate,UITableViewD
     
     
     func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
-        1
+        return self.positionList.count
     }
     
     func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {

+ 77 - 39
Koala/Koala/Modular/JDTrade/VC/JDTradeViewController.swift

@@ -29,6 +29,9 @@ class JDTradeViewController: BaseViewController {
         return v
     }()
     
+    var cashBalance : String = "0.00"
+    var isOpen : Bool = true
+    
     lazy var tableView : UITableView = {
         
         let v = UITableView(frame: .zero, style: .plain)
@@ -57,6 +60,53 @@ class JDTradeViewController: BaseViewController {
         }
         
         self.requestAccountList()
+        self.netForGetCashInfo()
+        
+    }
+    
+}
+
+extension JDTradeViewController {
+    
+    func requestAccountList() {
+        
+        NetWork.NetWorkInstance.requestData(requestType: .Post, URLString: netForGetAccountList) { (code,result ) in
+            
+            if let list : [NSDictionary] = result?["list"] as? [NSDictionary] {
+                self.accountList.removeAll()
+                
+                for dic in list {
+                    
+                    let model = JDTradeAccountModel.deserialize(from: dic)
+                    
+                    self.accountList.append(model!)
+                }
+                
+            }
+            
+            self.tableView.reloadData()
+            
+        } failured: {(code, result) in
+            ProgressHUD.showError(status: result as! String)
+        }
+    
+    }
+    
+    
+    func netForGetCashInfo(){
+        NetWork.NetWorkInstance.requestData(requestType: .Post, URLString: netForGetCash) { code, result in
+            
+            self.cashBalance = result?["balance"] as? String ?? "0.00"
+            
+            self.tableView.reloadData()
+            
+            
+        } failured: { code, result in
+            ProgressHUD.showError(status: result as! String)
+            
+        }
+
+        
     }
     
 }
@@ -79,7 +129,13 @@ extension JDTradeViewController : UITableViewDataSource{
             return 1
         } else {
             
-            return accountList.count
+            if self.isOpen == true {
+                
+                return accountList.count
+            }else{
+                
+                return 0
+            }
         }
     }
     
@@ -100,10 +156,12 @@ extension JDTradeViewController : UITableViewDataSource{
             let cell = tableView.dequeueReusableCell(withIdentifier: JDTradeAccountCell.description()) as! JDTradeAccountCell
             
             cell.iconIv.image = UIImage(named: "account_wallet")
-//            let model : JDTradeAccountModel = self.accountList[indexPath.row]
-////            cell.updateMarketCellWith(model: model)
-//            cell.updateHomeCellWith(model: model)
-//
+            cell.titleLb.text = switchLanguage("钱包账户")
+            cell.networthTipLb.text = switchLanguage("资产净值.USD")
+            cell.networthLb.text = precisionString(with: cashBalance, precision: "2")
+            cell.todayTipLb.isHidden = true
+            cell.todayProfitLb.isHidden = true
+            cell.todayRateLb.isHidden = true
             return cell
             
             
@@ -113,7 +171,7 @@ extension JDTradeViewController : UITableViewDataSource{
 //            let model:KSymbolModel = (self.VM?.screenSymbolList[indexPath.row])!;
             
             let model : JDTradeAccountModel = self.accountList[indexPath.row]
-//            cell.updateMarketCellWith(model: model)
+
             cell.updateHomeCellWith(model: model)
             
             return cell
@@ -122,33 +180,7 @@ extension JDTradeViewController : UITableViewDataSource{
     
 }
 
-extension JDTradeViewController {
-    
-    func requestAccountList() {
-        
-        NetWork.NetWorkInstance.requestData(requestType: .Post, URLString: netForGetAccountList) { (code,result ) in
-            
-            if let list : [NSDictionary] = result?["list"] as? [NSDictionary] {
-                self.accountList.removeAll()
-                
-                for dic in list {
-                    
-                    let model = JDTradeAccountModel.deserialize(from: dic)
-                    
-                    self.accountList.append(model!)
-                }
-                
-            }
-            
-            self.tableView.reloadData()
-            
-        } failured: {(code, result) in
-            ProgressHUD.showError(status: result as! String)
-        }
-    
-    }
-    
-}
+
 
 
 extension JDTradeViewController : UITableViewDelegate{
@@ -163,6 +195,13 @@ extension JDTradeViewController : UITableViewDelegate{
         }
     }
     
+    @objc func closeAction()->Void{
+        
+        self.isOpen = !self.isOpen
+        
+        self.tableView.reloadData()
+    }
+    
     func tableView(_ tableView: UITableView, viewForHeaderInSection section: Int) -> UIView? {
     
         if section == 3 {
@@ -181,19 +220,18 @@ extension JDTradeViewController : UITableViewDelegate{
                 make.centerY.equalTo(view)
                 make.left.equalTo(view.snp.left).offset(18)
             }
-            let iv = UIImageView()
             
+            let closeBtn : UIButton = UIButton(type: .custom)
+            closeBtn.setImage(_image("Base_W_DownArrows&Base_W_DownArrows"), for: .normal)
+            closeBtn.addTarget(self, action: #selector(closeAction), for: .touchUpInside)
             
-            iv.image = UIImage(named: "Base_W_DownArrows")
-            
-            view.addSubview(iv)
-            iv.snp.makeConstraints { make in
+            view.addSubview(closeBtn)
+            closeBtn.snp.makeConstraints { make in
                 make.centerY.equalTo(view)
                 make.right.equalTo(view.snp.right).offset(-28)
                 make.size.equalTo(CGSize(width: 17, height: 10))
             }
             
-            
             return view
         } else {
             

+ 15 - 1
Koala/Koala/Modular/Login/V/Register/JDRegisterView.swift

@@ -36,10 +36,24 @@ class JDRegisterView : BaseView {
             tableView.contentInsetAdjustmentBehavior = .never
         }
         return tableView
-        }()
+    }()
 
+    lazy var bgIv : UIImageView = {
+        let v = UIImageView()
+        v.image = _image("jdmine_join_delegateBg&jdmine_join_delegateBg")
+        return v
+    }()
+    
     override func subView() {
         super.subView()
+        
+    
+//        self.addSubview(bgIv)
+//        bgIv.snp.makeConstraints { make in
+//            make.top.left.right.equalTo(self)
+//            make.height.equalTo(300)
+//        }
+        
         self.addSubview(topView)
         self.addSubview(self.tableView)
         mySwitchLanguage()

+ 5 - 1
Koala/Koala/Modular/Login/V/Register/RegisterView.swift

@@ -34,10 +34,14 @@ class RegisterView: BaseView {
             tableView.contentInsetAdjustmentBehavior = .never
         }
         return tableView
-        }()
+    }()
+
 
+    
     override func subView() {
         super.subView()
+    
+        
         self.addSubview(topView)
         self.addSubview(self.tableView)
         mySwitchLanguage()

+ 26 - 0
Koala/Koala/Modular/Mine/V/BindAccount/JDBindAccountCell.swift

@@ -0,0 +1,26 @@
+//
+//  JDBindAccountCell.swift
+//  Koala
+//
+//  Created by mac on 2023/10/17.
+//  Copyright © 2023 刘千军. All rights reserved.
+//
+
+import Foundation
+import  UIKit
+
+class JDBindAccountCell: BaseTableViewCell {
+    
+    
+    
+    override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
+        super.init(style: style, reuseIdentifier: reuseIdentifier)
+    }
+    
+    required init?(coder aDecoder: NSCoder) {
+        fatalError("init(coder:) has not been implemented")
+    }
+    
+    
+    
+}

+ 2 - 0
Koala/Koala/Modular/Mine/V/Mine/JDMineAvatarHeaderView.swift

@@ -20,6 +20,8 @@ class JDMineAvatarHeaderView: BaseView {
     lazy var avatarBtn : UIButton = {
         let v = UIButton(type: .custom)
         v.setBackgroundImage(Base_Avtor_Image, for: .normal)
+        v.layer.masksToBounds = true
+        v.layer.cornerRadius = 30
         return v
     }()
     

+ 25 - 0
Koala/Koala/Modular/Mine/VC/MineViewController.swift

@@ -27,17 +27,42 @@ class MineViewController: BaseViewController {
         self.mySwitchLanguage()
     }
     
+    lazy var bgIv : UIImageView = {
+        let v = UIImageView()
+        v.image = _image("Mine_Top_Bg&Mine_Top_Bg")
+        return v
+    }()
+    
     override func viewDidLoad() {
         super.viewDidLoad()
         self.myNavigationBar.left_SuperView.isHidden = false
         self.myNavigationBar.title_Label.text = "个人中心"
         self.myNavigationBar.left_Button.setImage(NavViewSpecialBlackImage, for: .normal)
         self.myNavigationBar.left_Button.addTarget(self, action: #selector(clickLeftBtnAction), for: .touchUpInside)
+        self.myNavigationBar.left_Button.backgroundColor = .clear
+        self.myNavigationBar.backgroundColor = .clear
+        self.myNavigationBar.back_ImageView.isHidden = true
+        self.myNavigationBar.left_ImageView.isHidden = true
+        self.myNavigationBar.left_SuperView.backgroundColor = .clear
+        
+        self.view.addSubview(bgIv)
+        bgIv.snp.makeConstraints { make in
+            make.left.right.equalTo(self.view)
+            make.top.equalTo(self.myNavigationBar.snp.top)
+            make.height.equalTo(230)
+        }
        
+        self.view.bringSubviewToFront(self.myNavigationBar)
+        
     }
     
     override func subView() {
+        
+        self.view.backgroundColor = .white
+        
         self.view.addSubview(mineView)
+        
+        
     }
     
     override func updateViewConstraints() {

+ 11 - 0
Koala/Koala/Modular/Model/UserInfoModel/UserInfoDataModel.swift

@@ -50,6 +50,17 @@ import Foundation
      var total_profit : String = ""
      var total_commission : String = ""
     
+     var id : String = ""
+     var category : String = ""
+     var country : String = ""
+     var day_amount_exchange : String = ""
+     var day_amount_withdraw : String = ""
+     var group : String = ""
+     var insert_datetime : String = ""
+     var security_code : String = ""
+     var status : String = ""
+     var update_datetime : String = ""
+     var video_status :String = ""
 }
 
 

+ 22 - 0
Koala/Koala/Other/Assets.xcassets/JDTabbar/jdtab_found_sel.imageset/Contents.json

@@ -0,0 +1,22 @@
+{
+  "images" : [
+    {
+      "idiom" : "universal",
+      "scale" : "1x"
+    },
+    {
+      "filename" : "路径 2备份 2@2x.png",
+      "idiom" : "universal",
+      "scale" : "2x"
+    },
+    {
+      "filename" : "路径 2备份 2@3x.png",
+      "idiom" : "universal",
+      "scale" : "3x"
+    }
+  ],
+  "info" : {
+    "author" : "xcode",
+    "version" : 1
+  }
+}

BIN
Koala/Koala/Other/Assets.xcassets/JDTabbar/jdtab_found_sel.imageset/路径 2备份 2@2x.png


BIN
Koala/Koala/Other/Assets.xcassets/JDTabbar/jdtab_found_sel.imageset/路径 2备份 2@3x.png


+ 22 - 0
Koala/Koala/Other/Assets.xcassets/JDTabbar/jdtab_trade_sel.imageset/Contents.json

@@ -0,0 +1,22 @@
+{
+  "images" : [
+    {
+      "idiom" : "universal",
+      "scale" : "1x"
+    },
+    {
+      "filename" : "路径 2备份 2@2x.png",
+      "idiom" : "universal",
+      "scale" : "2x"
+    },
+    {
+      "filename" : "路径 2备份 2@3x.png",
+      "idiom" : "universal",
+      "scale" : "3x"
+    }
+  ],
+  "info" : {
+    "author" : "xcode",
+    "version" : 1
+  }
+}

BIN
Koala/Koala/Other/Assets.xcassets/JDTabbar/jdtab_trade_sel.imageset/路径 2备份 2@2x.png


BIN
Koala/Koala/Other/Assets.xcassets/JDTabbar/jdtab_trade_sel.imageset/路径 2备份 2@3x.png


+ 22 - 0
Koala/Koala/Other/Assets.xcassets/Mine/Mine_Top_Bg.imageset/Contents.json

@@ -0,0 +1,22 @@
+{
+  "images" : [
+    {
+      "idiom" : "universal",
+      "scale" : "1x"
+    },
+    {
+      "filename" : "编组 13@2x.png",
+      "idiom" : "universal",
+      "scale" : "2x"
+    },
+    {
+      "filename" : "编组 13@3x.png",
+      "idiom" : "universal",
+      "scale" : "3x"
+    }
+  ],
+  "info" : {
+    "author" : "xcode",
+    "version" : 1
+  }
+}

BIN
Koala/Koala/Other/Assets.xcassets/Mine/Mine_Top_Bg.imageset/编组 13@2x.png


BIN
Koala/Koala/Other/Assets.xcassets/Mine/Mine_Top_Bg.imageset/编组 13@3x.png


+ 2 - 2
Koala/Koala/Other/Info.plist

@@ -15,9 +15,9 @@
 	<key>CFBundlePackageType</key>
 	<string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string>
 	<key>CFBundleShortVersionString</key>
-	<string>1.0.1</string>
+	<string>1.0.2</string>
 	<key>CFBundleVersion</key>
-	<string>2</string>
+	<string>1</string>
 	<key>LSRequiresIPhoneOS</key>
 	<true/>
 	<key>NSAppTransportSecurity</key>

+ 24 - 24
Koala/Pods/Pods.xcodeproj/xcuserdata/mac.xcuserdatad/xcschemes/xcschememanagement.plist

@@ -7,22 +7,22 @@
 		<key>Alamofire.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>23</integer>
+			<integer>16</integer>
 		</dict>
 		<key>CryptoSwift.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>21</integer>
+			<integer>24</integer>
 		</dict>
 		<key>FMDB.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>9</integer>
+			<integer>23</integer>
 		</dict>
 		<key>GzipSwift.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>24</integer>
+			<integer>15</integer>
 		</dict>
 		<key>HandyJSON.xcscheme_^#shared#^_</key>
 		<dict>
@@ -32,102 +32,102 @@
 		<key>IQKeyboardManagerSwift.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>13</integer>
+			<integer>10</integer>
 		</dict>
 		<key>Kingfisher.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>25</integer>
+			<integer>8</integer>
 		</dict>
 		<key>LLCycleScrollView.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>5</integer>
+			<integer>12</integer>
 		</dict>
 		<key>LiveChat.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>16</integer>
+			<integer>25</integer>
 		</dict>
 		<key>MJExtension.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>10</integer>
+			<integer>7</integer>
 		</dict>
 		<key>MJRefresh.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>27</integer>
+			<integer>17</integer>
 		</dict>
 		<key>PGDatePicker.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>7</integer>
+			<integer>3</integer>
 		</dict>
 		<key>PGPickerView.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>20</integer>
+			<integer>21</integer>
 		</dict>
 		<key>Pods-Koala.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>15</integer>
+			<integer>4</integer>
 		</dict>
 		<key>Pods-KoalaTests.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>4</integer>
+			<integer>18</integer>
 		</dict>
 		<key>Pods-KoalaUITests.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>22</integer>
+			<integer>11</integer>
 		</dict>
 		<key>ReactiveCocoa.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>19</integer>
+			<integer>13</integer>
 		</dict>
 		<key>ReactiveSwift.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>3</integer>
+			<integer>9</integer>
 		</dict>
 		<key>SVProgressHUD.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>14</integer>
+			<integer>6</integer>
 		</dict>
 		<key>SideMenu.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>6</integer>
+			<integer>22</integer>
 		</dict>
 		<key>SnapKit.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>11</integer>
+			<integer>2</integer>
 		</dict>
 		<key>Starscream.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>12</integer>
+			<integer>5</integer>
 		</dict>
 		<key>SwiftSVG.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>17</integer>
+			<integer>14</integer>
 		</dict>
 		<key>SwiftyJSON.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>18</integer>
+			<integer>19</integer>
 		</dict>
 		<key>lottie-ios.xcscheme_^#shared#^_</key>
 		<dict>
 			<key>orderHint</key>
-			<integer>8</integer>
+			<integer>20</integer>
 		</dict>
 	</dict>
 </dict>