Explorar el Código

修改文件,做代码差异

ganzf hace 8 meses
padre
commit
5a6ca8aa05
Se han modificado 100 ficheros con 2173 adiciones y 50 borrados
  1. 16 8
      ABtong/ABtong.xcodeproj/project.pbxproj
  2. 8 0
      ABtong/ABtong/ABtong.entitlements
  3. 0 0
      ABtong/ABtong/ALLController/JSwebRTC/CustomJitsiLogger.h
  4. 0 0
      ABtong/ABtong/ALLController/JSwebRTC/CustomJitsiLogger.m
  5. 0 0
      ABtong/ABtong/ALLController/JSwebRTC/FloatJSWindow.h
  6. 0 0
      ABtong/ABtong/ALLController/JSwebRTC/FloatJSWindow.m
  7. 0 0
      ABtong/ABtong/ALLController/JSwebRTC/JSGController.h
  8. 0 0
      ABtong/ABtong/ALLController/JSwebRTC/JSGController.m
  9. 168 0
      ABtong/ABtong/ALLController/call/CallControllers.storyboard
  10. 18 0
      ABtong/ABtong/ALLController/call/CallIndexCell.h
  11. 238 0
      ABtong/ABtong/ALLController/call/CallIndexCell.m
  12. 20 0
      ABtong/ABtong/ALLController/call/CallIndexController.h
  13. 254 0
      ABtong/ABtong/ALLController/call/CallIndexController.m
  14. 18 0
      ABtong/ABtong/ALLController/call/CalldetailsCell.h
  15. 233 0
      ABtong/ABtong/ALLController/call/CalldetailsCell.m
  16. 19 0
      ABtong/ABtong/ALLController/call/CalldetailsController.h
  17. 185 0
      ABtong/ABtong/ALLController/call/CalldetailsController.m
  18. 26 0
      ABtong/ABtong/ALLController/call/PhoneKeybord.h
  19. 139 0
      ABtong/ABtong/ALLController/call/PhoneKeybord.m
  20. 308 0
      ABtong/ABtong/ALLController/call/PhoneKeybord.xib
  21. 0 0
      ABtong/ABtong/ALLController/chat/CameraViewController.h
  22. 0 0
      ABtong/ABtong/ALLController/chat/CameraViewController.m
  23. 0 0
      ABtong/ABtong/ALLController/chat/ChatController.h
  24. 1 1
      ABtong/ABtong/ALLController/chat/ChatController.m
  25. 0 0
      ABtong/ABtong/ALLController/chat/ChatHistory.storyboard
  26. 0 0
      ABtong/ABtong/ALLController/chat/ChatHistoryController.h
  27. 0 0
      ABtong/ABtong/ALLController/chat/ChatHistoryController.m
  28. 0 0
      ABtong/ABtong/ALLController/chat/ChatIndexController.h
  29. 0 0
      ABtong/ABtong/ALLController/chat/ChatIndexController.m
  30. 0 0
      ABtong/ABtong/ALLController/chat/ChatListCell.h
  31. 30 17
      ABtong/ABtong/ALLController/chat/ChatListCell.m
  32. 0 0
      ABtong/ABtong/ALLController/chat/ChatListCell.xib
  33. 0 0
      ABtong/ABtong/ALLController/chat/ChatRecordController.h
  34. 0 0
      ABtong/ABtong/ALLController/chat/ChatRecordController.m
  35. 0 0
      ABtong/ABtong/ALLController/chat/MentionTextView.h
  36. 0 0
      ABtong/ABtong/ALLController/chat/MentionTextView.m
  37. 0 0
      ABtong/ABtong/ALLController/chat/QuoteDetailController.h
  38. 0 0
      ABtong/ABtong/ALLController/chat/QuoteDetailController.m
  39. 0 0
      ABtong/ABtong/ALLController/chat/chetCell/ChatAtMemberCell.h
  40. 0 0
      ABtong/ABtong/ALLController/chat/chetCell/ChatAtMemberCell.m
  41. 0 0
      ABtong/ABtong/ALLController/chat/chetCell/ChatAtMemberView.h
  42. 0 0
      ABtong/ABtong/ALLController/chat/chetCell/ChatAtMemberView.m
  43. 0 0
      ABtong/ABtong/ALLController/chat/chetCell/ChatBatchView.h
  44. 0 0
      ABtong/ABtong/ALLController/chat/chetCell/ChatBatchView.m
  45. 0 0
      ABtong/ABtong/ALLController/chat/chetCell/ChatFileModel.h
  46. 0 0
      ABtong/ABtong/ALLController/chat/chetCell/ChatFileModel.m
  47. 0 0
      ABtong/ABtong/ALLController/chat/chetCell/ChatLongPressMenuView.h
  48. 0 0
      ABtong/ABtong/ALLController/chat/chetCell/ChatLongPressMenuView.m
  49. 0 0
      ABtong/ABtong/ALLController/chat/chetCell/ChatMessageModel.h
  50. 17 4
      ABtong/ABtong/ALLController/chat/chetCell/ChatMessageModel.m
  51. 0 0
      ABtong/ABtong/ALLController/chat/chetCell/ChatPopoverView.h
  52. 0 0
      ABtong/ABtong/ALLController/chat/chetCell/ChatPopoverView.m
  53. 0 0
      ABtong/ABtong/ALLController/chat/chetCell/ChatQuoteView.h
  54. 0 0
      ABtong/ABtong/ALLController/chat/chetCell/ChatQuoteView.m
  55. 0 0
      ABtong/ABtong/ALLController/chat/chetCell/chatCellView.h
  56. 5 4
      ABtong/ABtong/ALLController/chat/chetCell/chatCellView.m
  57. 0 0
      ABtong/ABtong/ALLController/chat/chetCell/chatpopView.h
  58. 0 0
      ABtong/ABtong/ALLController/chat/chetCell/chatpopView.m
  59. 0 0
      ABtong/ABtong/ALLController/chat/chetCell/chatpopView.xib
  60. 0 0
      ABtong/ABtong/ALLController/friend/EXFriendController.h
  61. 0 0
      ABtong/ABtong/ALLController/friend/EXFriendController.m
  62. 0 0
      ABtong/ABtong/ALLController/friend/EXFriendListCell.h
  63. 0 0
      ABtong/ABtong/ALLController/friend/EXFriendListCell.m
  64. 0 0
      ABtong/ABtong/ALLController/friend/ForwardViewController.h
  65. 0 0
      ABtong/ABtong/ALLController/friend/ForwardViewController.m
  66. 0 0
      ABtong/ABtong/ALLController/friend/FriendController.h
  67. 0 0
      ABtong/ABtong/ALLController/friend/FriendController.m
  68. 0 0
      ABtong/ABtong/ALLController/friend/FriendListCell.h
  69. 0 0
      ABtong/ABtong/ALLController/friend/FriendListCell.m
  70. 0 0
      ABtong/ABtong/ALLController/friend/FriendListController.h
  71. 19 1
      ABtong/ABtong/ALLController/friend/FriendListController.m
  72. 0 0
      ABtong/ABtong/ALLController/friend/ReportViewController.h
  73. 0 0
      ABtong/ABtong/ALLController/friend/ReportViewController.m
  74. 0 0
      ABtong/ABtong/ALLController/friend/addFriendController.h
  75. 0 0
      ABtong/ABtong/ALLController/friend/addFriendController.m
  76. 0 0
      ABtong/ABtong/ALLController/group/GroupController.h
  77. 0 0
      ABtong/ABtong/ALLController/group/GroupController.m
  78. 0 0
      ABtong/ABtong/ALLController/group/GroupEditController.h
  79. 0 0
      ABtong/ABtong/ALLController/group/GroupEditController.m
  80. 0 0
      ABtong/ABtong/ALLController/group/GroupGonggaoController.h
  81. 0 0
      ABtong/ABtong/ALLController/group/GroupGonggaoController.m
  82. 0 0
      ABtong/ABtong/ALLController/group/GroupListCell.h
  83. 0 0
      ABtong/ABtong/ALLController/group/GroupListCell.m
  84. 0 0
      ABtong/ABtong/ALLController/group/GroupListController.h
  85. 0 0
      ABtong/ABtong/ALLController/group/GroupListController.m
  86. 0 0
      ABtong/ABtong/ALLController/group/NewGroupController.h
  87. 0 0
      ABtong/ABtong/ALLController/group/NewGroupController.m
  88. 0 0
      ABtong/ABtong/ALLController/group/groupstory.storyboard
  89. 0 0
      ABtong/ABtong/ALLController/login/APPLockView.h
  90. 1 1
      ABtong/ABtong/ALLController/login/APPLockView.m
  91. 0 0
      ABtong/ABtong/ALLController/login/GCoverController.h
  92. 0 0
      ABtong/ABtong/ALLController/login/GCoverController.m
  93. 0 1
      ABtong/ABtong/ALLController/login/GLoginController.h
  94. 100 13
      ABtong/ABtong/ALLController/login/GLoginController.m
  95. 0 0
      ABtong/ABtong/ALLController/login/GSignController.h
  96. 0 0
      ABtong/ABtong/ALLController/login/GSignController.m
  97. 23 0
      ABtong/ABtong/ALLController/login/GserverListCell.h
  98. 86 0
      ABtong/ABtong/ALLController/login/GserverListCell.m
  99. 19 0
      ABtong/ABtong/ALLController/login/GserverListController.h
  100. 222 0
      ABtong/ABtong/ALLController/login/GserverListController.m

+ 16 - 8
ABtong/ABtong.xcodeproj/project.pbxproj

@@ -216,6 +216,7 @@
 			buildSettings = {
 				ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
 				ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
+				CODE_SIGN_ENTITLEMENTS = ABtong/ABtong.entitlements;
 				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
 				CODE_SIGN_STYLE = Manual;
 				CURRENT_PROJECT_VERSION = 1;
@@ -225,21 +226,24 @@
 				GCC_PREFIX_HEADER = "${SRCROOT}/ABtong/Prefix&Header/PrefixHeader.pch";
 				GENERATE_INFOPLIST_FILE = YES;
 				INFOPLIST_FILE = ABtong/Info.plist;
+				INFOPLIST_KEY_CFBundleDisplayName = "MY‘IM";
+				INFOPLIST_KEY_NSCameraUsageDescription = "App 需要访问您的相机来拍摄照片。";
+				INFOPLIST_KEY_NSMicrophoneUsageDescription = "App 需要您允许视频播放。";
 				INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES;
 				INFOPLIST_KEY_UILaunchStoryboardName = LaunchScreen;
 				INFOPLIST_KEY_UIMainStoryboardFile = Main;
-				INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
-				INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
+				INFOPLIST_KEY_UISupportedInterfaceOrientations = UIInterfaceOrientationPortrait;
+				INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown";
 				IPHONEOS_DEPLOYMENT_TARGET = 15.6;
 				LD_RUNPATH_SEARCH_PATHS = (
 					"$(inherited)",
 					"@executable_path/Frameworks",
 				);
 				MARKETING_VERSION = 1.0;
-				PRODUCT_BUNDLE_IDENTIFIER = com.iosapp.test001;
+				PRODUCT_BUNDLE_IDENTIFIER = com.qitewei.aiim01;
 				PRODUCT_NAME = "$(TARGET_NAME)";
 				PROVISIONING_PROFILE_SPECIFIER = "";
-				"PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]" = allTest;
+				"PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]" = aiimdev;
 				SUPPORTED_PLATFORMS = "iphoneos iphonesimulator";
 				SUPPORTS_MACCATALYST = NO;
 				SUPPORTS_MAC_DESIGNED_FOR_IPHONE_IPAD = NO;
@@ -255,6 +259,7 @@
 			buildSettings = {
 				ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
 				ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
+				CODE_SIGN_ENTITLEMENTS = ABtong/ABtong.entitlements;
 				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
 				CODE_SIGN_STYLE = Manual;
 				CURRENT_PROJECT_VERSION = 1;
@@ -264,21 +269,24 @@
 				GCC_PREFIX_HEADER = "${SRCROOT}/ABtong/Prefix&Header/PrefixHeader.pch";
 				GENERATE_INFOPLIST_FILE = YES;
 				INFOPLIST_FILE = ABtong/Info.plist;
+				INFOPLIST_KEY_CFBundleDisplayName = "MY‘IM";
+				INFOPLIST_KEY_NSCameraUsageDescription = "App 需要访问您的相机来拍摄照片。";
+				INFOPLIST_KEY_NSMicrophoneUsageDescription = "App 需要您允许视频播放。";
 				INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES;
 				INFOPLIST_KEY_UILaunchStoryboardName = LaunchScreen;
 				INFOPLIST_KEY_UIMainStoryboardFile = Main;
-				INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
-				INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
+				INFOPLIST_KEY_UISupportedInterfaceOrientations = UIInterfaceOrientationPortrait;
+				INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown";
 				IPHONEOS_DEPLOYMENT_TARGET = 15.6;
 				LD_RUNPATH_SEARCH_PATHS = (
 					"$(inherited)",
 					"@executable_path/Frameworks",
 				);
 				MARKETING_VERSION = 1.0;
-				PRODUCT_BUNDLE_IDENTIFIER = com.iosapp.test001;
+				PRODUCT_BUNDLE_IDENTIFIER = com.qitewei.aiim01;
 				PRODUCT_NAME = "$(TARGET_NAME)";
 				PROVISIONING_PROFILE_SPECIFIER = "";
-				"PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]" = allTest;
+				"PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]" = aiimdev;
 				SUPPORTED_PLATFORMS = "iphoneos iphonesimulator";
 				SUPPORTS_MACCATALYST = NO;
 				SUPPORTS_MAC_DESIGNED_FOR_IPHONE_IPAD = NO;

+ 8 - 0
ABtong/ABtong/ABtong.entitlements

@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+	<key>aps-environment</key>
+	<string>development</string>
+</dict>
+</plist>

+ 0 - 0
ABtong/ABtong/Controller/webRTC/CustomJitsiLogger.h → ABtong/ABtong/ALLController/JSwebRTC/CustomJitsiLogger.h


+ 0 - 0
ABtong/ABtong/Controller/webRTC/CustomJitsiLogger.m → ABtong/ABtong/ALLController/JSwebRTC/CustomJitsiLogger.m


+ 0 - 0
ABtong/ABtong/Controller/webRTC/FloatJSWindow.h → ABtong/ABtong/ALLController/JSwebRTC/FloatJSWindow.h


+ 0 - 0
ABtong/ABtong/Controller/webRTC/FloatJSWindow.m → ABtong/ABtong/ALLController/JSwebRTC/FloatJSWindow.m


+ 0 - 0
ABtong/ABtong/Controller/webRTC/JSGController.h → ABtong/ABtong/ALLController/JSwebRTC/JSGController.h


+ 0 - 0
ABtong/ABtong/Controller/webRTC/JSGController.m → ABtong/ABtong/ALLController/JSwebRTC/JSGController.m


+ 168 - 0
ABtong/ABtong/ALLController/call/CallControllers.storyboard

@@ -0,0 +1,168 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="23727" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
+    <device id="retina6_12" orientation="portrait" appearance="light"/>
+    <dependencies>
+        <deployment identifier="iOS"/>
+        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="23721"/>
+        <capability name="Safe area layout guides" minToolsVersion="9.0"/>
+        <capability name="System colors in document resources" minToolsVersion="11.0"/>
+        <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
+    </dependencies>
+    <scenes>
+        <!--Calldetails Controller-->
+        <scene sceneID="s0d-6b-0kx">
+            <objects>
+                <viewController storyboardIdentifier="CalldetailsController" useStoryboardIdentifierAsRestorationIdentifier="YES" id="Y6W-OH-hqX" customClass="CalldetailsController" sceneMemberID="viewController">
+                    <view key="view" contentMode="scaleToFill" id="5EZ-qb-Rvc">
+                        <rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
+                        <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
+                        <subviews>
+                            <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" image="loginBG" translatesAutoresizingMaskIntoConstraints="NO" id="3er-UH-p4L">
+                                <rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
+                                <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
+                            </imageView>
+                            <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" text="通话记录" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="xe6-RC-L4o">
+                                <rect key="frame" x="158" y="59" width="77" height="24"/>
+                                <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
+                                <fontDescription key="fontDescription" type="system" pointSize="20"/>
+                                <color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                <nil key="highlightedColor"/>
+                            </label>
+                            <button opaque="NO" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="0qh-hA-QuY">
+                                <rect key="frame" x="26" y="55" width="44" height="44"/>
+                                <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
+                                <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                                <state key="normal" image="fanhui"/>
+                                <connections>
+                                    <action selector="fanhui:" destination="Y6W-OH-hqX" eventType="touchUpInside" id="U6D-cB-HyI"/>
+                                </connections>
+                            </button>
+                            <view contentMode="scaleToFill" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="vVi-N4-LfV">
+                                <rect key="frame" x="11" y="118" width="370" height="64"/>
+                                <autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
+                                <subviews>
+                                    <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="V2l-YQ-2Ai">
+                                        <rect key="frame" x="8" y="8" width="50" height="50"/>
+                                        <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES" flexibleMaxY="YES"/>
+                                    </imageView>
+                                    <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" text="Label" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="xDb-TS-CDb">
+                                        <rect key="frame" x="66" y="22" width="128" height="21"/>
+                                        <autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
+                                        <fontDescription key="fontDescription" type="system" pointSize="17"/>
+                                        <nil key="textColor"/>
+                                        <nil key="highlightedColor"/>
+                                    </label>
+                                    <button opaque="NO" tag="3" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="HMa-Su-XvK">
+                                        <rect key="frame" x="322" y="12" width="40" height="40"/>
+                                        <autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMinY="YES" flexibleMaxY="YES"/>
+                                        <state key="normal" title="Button"/>
+                                        <buttonConfiguration key="configuration" style="plain">
+                                            <backgroundConfiguration key="background" image="Cshipinth">
+                                                <color key="backgroundColor" white="0.66666666669999997" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                            </backgroundConfiguration>
+                                        </buttonConfiguration>
+                                        <connections>
+                                            <action selector="actBtselect:" destination="Y6W-OH-hqX" eventType="touchUpInside" id="wSs-uD-LXV"/>
+                                        </connections>
+                                    </button>
+                                    <button opaque="NO" tag="2" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="L4g-Xu-DrB">
+                                        <rect key="frame" x="262" y="12" width="40" height="40"/>
+                                        <autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMinY="YES" flexibleMaxY="YES"/>
+                                        <state key="normal" title="Button"/>
+                                        <buttonConfiguration key="configuration" style="plain">
+                                            <backgroundConfiguration key="background" image="Cyuyinth">
+                                                <color key="backgroundColor" white="0.66666666669999997" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                            </backgroundConfiguration>
+                                        </buttonConfiguration>
+                                        <connections>
+                                            <action selector="actBtselect:" destination="Y6W-OH-hqX" eventType="touchUpInside" id="QCu-Dv-mRQ"/>
+                                        </connections>
+                                    </button>
+                                    <button opaque="NO" tag="1" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="cAX-aN-TiR">
+                                        <rect key="frame" x="202" y="12" width="40" height="40"/>
+                                        <autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMinY="YES" flexibleMaxY="YES"/>
+                                        <color key="tintColor" white="0.66666666669999997" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                        <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                                        <state key="normal" backgroundImage="index"/>
+                                        <buttonConfiguration key="configuration" style="plain">
+                                            <backgroundConfiguration key="background" image="index">
+                                                <color key="backgroundColor" white="0.66666666669999997" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                            </backgroundConfiguration>
+                                        </buttonConfiguration>
+                                        <connections>
+                                            <action selector="actBtselect:" destination="Y6W-OH-hqX" eventType="touchUpInside" id="gfn-If-tSb"/>
+                                        </connections>
+                                    </button>
+                                </subviews>
+                                <color key="backgroundColor" systemColor="systemBackgroundColor"/>
+                            </view>
+                            <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" text="通话记录" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Gec-hT-StB">
+                                <rect key="frame" x="11" y="204" width="187" height="21"/>
+                                <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
+                                <fontDescription key="fontDescription" type="system" pointSize="17"/>
+                                <color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                <nil key="highlightedColor"/>
+                            </label>
+                            <tableView clipsSubviews="YES" contentMode="scaleToFill" fixedFrame="YES" alwaysBounceVertical="YES" dataMode="prototypes" style="plain" separatorStyle="default" rowHeight="-1" estimatedRowHeight="-1" sectionHeaderHeight="-1" estimatedSectionHeaderHeight="-1" sectionFooterHeight="-1" estimatedSectionFooterHeight="-1" translatesAutoresizingMaskIntoConstraints="NO" id="2FX-RA-Hb4">
+                                <rect key="frame" x="0.0" y="233" width="393" height="551"/>
+                                <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
+                                <color key="backgroundColor" systemColor="systemBackgroundColor"/>
+                            </tableView>
+                            <button opaque="NO" alpha="0.0" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="Ccd-AW-3ib">
+                                <rect key="frame" x="337" y="57" width="40" height="40"/>
+                                <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
+                                <state key="normal" title="Button"/>
+                                <buttonConfiguration key="configuration" style="plain">
+                                    <backgroundConfiguration key="background" image="Cjiahao"/>
+                                </buttonConfiguration>
+                            </button>
+                            <button opaque="NO" alpha="0.0" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="trailing" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="os6-D8-1iH">
+                                <rect key="frame" x="252" y="197" width="110" height="35"/>
+                                <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
+                                <color key="tintColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                <state key="normal" title="Button"/>
+                                <buttonConfiguration key="configuration" style="plain" title="全部&gt;">
+                                    <fontDescription key="titleFontDescription" type="system" pointSize="17"/>
+                                </buttonConfiguration>
+                                <connections>
+                                    <action selector="allRecord:" destination="Y6W-OH-hqX" eventType="touchUpInside" id="jmu-uK-6hq"/>
+                                </connections>
+                            </button>
+                            <button opaque="NO" alpha="0.0" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" id="kV3-8Y-w5q">
+                                <rect key="frame" x="45" y="740" width="300" height="35"/>
+                                <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
+                                <color key="backgroundColor" systemColor="systemGray5Color"/>
+                                <state key="normal" title="Button"/>
+                                <buttonConfiguration key="configuration" style="plain" title="添加到通讯录"/>
+                            </button>
+                        </subviews>
+                        <viewLayoutGuide key="safeArea" id="vDu-zF-Fre"/>
+                        <color key="backgroundColor" systemColor="systemBackgroundColor"/>
+                    </view>
+                    <connections>
+                        <outlet property="avatar" destination="V2l-YQ-2Ai" id="AKB-Ti-JH7"/>
+                        <outlet property="nameLb" destination="xDb-TS-CDb" id="upH-85-XE3"/>
+                        <outlet property="tableView" destination="2FX-RA-Hb4" id="gBy-e1-SC3"/>
+                        <outlet property="topcontent" destination="vVi-N4-LfV" id="gfy-sh-KPP"/>
+                    </connections>
+                </viewController>
+                <placeholder placeholderIdentifier="IBFirstResponder" id="Ief-a0-LHa" userLabel="First Responder" customClass="UIResponder" sceneMemberID="firstResponder"/>
+            </objects>
+            <point key="canvasLocation" x="87.786259541984734" y="-34.507042253521128"/>
+        </scene>
+    </scenes>
+    <resources>
+        <image name="Cjiahao" width="20" height="20"/>
+        <image name="Cshipinth" width="56" height="56"/>
+        <image name="Cyuyinth" width="56" height="56"/>
+        <image name="fanhui" width="20" height="20"/>
+        <image name="index" width="32" height="32"/>
+        <image name="loginBG" width="375" height="812"/>
+        <systemColor name="systemBackgroundColor">
+            <color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+        </systemColor>
+        <systemColor name="systemGray5Color">
+            <color red="0.89803921568627454" green="0.89803921568627454" blue="0.91764705882352937" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+        </systemColor>
+    </resources>
+</document>

+ 18 - 0
ABtong/ABtong/ALLController/call/CallIndexCell.h

@@ -0,0 +1,18 @@
+//
+//  CallIndexCell.h
+//  ABtong
+//
+//  Created by gan on 2025/7/31.
+//
+
+#ifndef CallIndexCell_h
+#define CallIndexCell_h
+#import <UIKit/UIKit.h>
+
+
+@interface CallIndexCell : UITableViewCell
+
+- (void)fillWithData:( NSDictionary*)data;
+@end
+
+#endif /* CallIndexCell_h */

+ 238 - 0
ABtong/ABtong/ALLController/call/CallIndexCell.m

@@ -0,0 +1,238 @@
+//
+//  CallIndexCell.m
+//  ABtong
+//
+//  Created by gan on 2025/7/31.
+//
+
+#import <Foundation/Foundation.h>
+#import "CallIndexCell.h"
+#import <SDWebImage/UIImageView+WebCache.h>
+#import "config.h"
+
+
+@interface CallIndexCell()
+
+@property (strong, nonatomic) UILabel *name;
+@property (strong, nonatomic) UILabel *time;
+@property (strong, nonatomic) UILabel *countText;
+@property (strong, nonatomic) UIImageView *avatar;
+@property (strong, nonatomic) UIImageView *rightAr;
+
+@property (strong, nonatomic) UILabel *lineLb;
+
+
+@end
+
+@implementation CallIndexCell
+
+
+- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
+    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
+    if (self) {
+        [self initAlllSubviews];
+        self.selectionStyle = UITableViewCellSelectionStyleNone;
+        self.backgroundColor = [UIColor clearColor];
+    }
+    return self;
+}
+
+
+-(void)initAlllSubviews{
+   
+    // 头像
+    _avatar = [UIImageView new];
+    _avatar.layer.cornerRadius = 25;
+    _avatar.layer.masksToBounds = YES;
+    _avatar.contentMode = UIViewContentModeScaleAspectFill;
+    [self.contentView addSubview:_avatar];
+    
+    
+    _rightAr = [UIImageView new];
+    _rightAr.contentMode = UIViewContentModeScaleAspectFill;
+    [_rightAr setImage:[UIImage imageNamed:@"arrow-right"]];
+    [self.contentView addSubview:_rightAr];
+    
+    
+    // 名字
+    _name = [UILabel new];
+    _name.font = SYSFONT(18);
+    _name.textColor = [UIColor whiteColor];
+    [self.contentView addSubview:_name];
+    
+    // 时间
+    _time = [UILabel new];
+    _time.font = SYSFONT(14);
+    _time.textColor = UIColor.whiteColor;
+    [self.contentView addSubview:_time];
+    
+    // 时间
+    _countText = [UILabel new];
+    _countText.font = SYSFONT(16);
+    _countText.textColor = UIColor.whiteColor;
+    [self.contentView addSubview:_countText];
+    
+    _lineLb = [UILabel new];
+    _lineLb.text = @"";
+    _lineLb.backgroundColor = UIColor.lightGrayColor;
+    [self.contentView addSubview:_lineLb];
+    
+    
+    [_avatar mas_remakeConstraints:^(MASConstraintMaker *make) {
+        make.left.equalTo(self.contentView.mas_left).offset(10);
+        make.top.mas_equalTo(self.contentView.mas_top).offset(10);
+        make.width.mas_equalTo(50);
+        make.height.mas_equalTo(50);
+    }];
+    
+    
+    
+    [_rightAr mas_remakeConstraints:^(MASConstraintMaker *make) {
+        make.right.equalTo(self.contentView.mas_right).offset(-30);
+        make.top.mas_equalTo(self.contentView.mas_top).offset(10);
+        make.width.mas_equalTo(25);
+        make.height.mas_equalTo(25);
+    }];
+    
+    [_name mas_remakeConstraints:^(MASConstraintMaker *make) {
+        make.left.equalTo(_avatar.mas_right).offset(8);
+        make.width.mas_equalTo(250);
+        make.top.mas_equalTo(self.contentView.mas_top).offset(12);
+    }];
+    
+    [_time mas_remakeConstraints:^(MASConstraintMaker *make) {
+        make.left.equalTo(_avatar.mas_right).offset(8);
+        make.top.mas_equalTo(_name.mas_bottom).offset(6);
+    }];
+    
+    [_countText mas_remakeConstraints:^(MASConstraintMaker *make) {
+        make.left.equalTo(_time.mas_right).offset(4);
+        make.top.mas_equalTo(_name.mas_bottom).offset(6);
+    }];
+    
+    [_lineLb mas_remakeConstraints:^(MASConstraintMaker *make) {
+        make.top.mas_equalTo(self.contentView.mas_bottom).offset(-3);
+        make.width.mas_equalTo(self.contentView.mas_width).offset(12);
+        make.height.mas_equalTo(0.5);
+    }];
+    
+    
+}
+
+- (void)fillWithData:( NSDictionary*)data {
+    
+    NSLog(@"fillWithData:%@",data);
+    NSString *avatar =data[@"fromAvatar"]?:@"";
+    if([avatar isKindOfClass:[NSString class]]){
+        
+    }
+    else{
+        avatar = @"";
+    }
+    [self.avatar sd_setImageWithURL:[NSURL URLWithString:avatar] placeholderImage:[UIImage imageNamed:@"Avatar"]];
+    self.name.text =data[@"fromName"]?:@"";
+
+    //NSLog(@"lastTime:%@",data[@"lastTime"]);
+    NSString *timestr =data[@"timestamp"];
+    
+    if([timestr isKindOfClass:[NSNumber class]]){
+        _time.text=[self timeF:timestr.longLongValue];
+    }
+    else if([timestr isKindOfClass:[NSString class]]){
+        _time.text=[self timeF:timestr.longLongValue];
+    }
+    else{
+        _time.text=@"";
+    }
+    NSString *result =data[@"result"];
+    NSString *duration = data[@"duration"];
+    if(result.intValue == 1){
+        _countText.text = [NSString stringWithFormat:@"通话时长:%@",[self formatTimeWithMilliseconds:duration.intValue]];
+    }
+    else{
+        _countText.text = @"未接通";
+    }
+    // tell constraints they need updating
+    [self setNeedsUpdateConstraints];
+
+    // update constraints now so we can animate the change
+    [self updateConstraintsIfNeeded];
+
+    [self layoutIfNeeded];
+}
+
+-(NSString *)timeF:(NSInteger)time{
+    //NSLog(@"time:%ld",(long)time);
+    // 创建日期格式器
+    NSDateFormatter *formatter = [[NSDateFormatter alloc] init];
+    [formatter setDateFormat:@"dd"]; // 设置你想要的日期格式
+    
+    
+    long long timestamp =(long)time/1000; // 例如:2021-10-01 00:00:00 UTC
+    // 转换为NSDate
+    NSDate *date = [NSDate dateWithTimeIntervalSince1970:timestamp];
+    NSString *dateString = [formatter stringFromDate:date];
+    
+    
+    NSDate *now = [NSDate date];
+    NSTimeInterval trt = [now timeIntervalSince1970];
+    date = [NSDate dateWithTimeIntervalSince1970:trt];
+    NSString *tdateString = [formatter stringFromDate:date];
+    
+    
+    NSInteger shijiancha = trt-timestamp;
+    
+    if(shijiancha<60){
+        return NSLocalizedString(@"time-oneminint", @"");
+    }
+    if(shijiancha>24*3600||dateString.intValue!=tdateString.intValue){
+        // 假设这是你的时间戳(以秒为单位)
+        long long timestamp =(long)time/1000; // 例如:2021-10-01 00:00:00 UTC
+        // 转换为NSDate
+        NSDate *date = [NSDate dateWithTimeIntervalSince1970:timestamp];
+        // 创建日期格式器
+        NSDateFormatter *formatter = [[NSDateFormatter alloc] init];
+        [formatter setDateFormat:@"yyyy-MM-dd HH:mm"]; // 设置你想要的日期格式
+        // 转换为字符串
+        NSString *dateString = [formatter stringFromDate:date];
+        return dateString;
+    }
+    else{
+        NSInteger xiaoshi = shijiancha/3600;
+        NSInteger fenzhong = shijiancha/60;
+        if(xiaoshi>0){
+            // 假设这是你的时间戳(以秒为单位)
+            long long timestamp =(long)time/1000; // 例如:2021-10-01 00:00:00 UTC
+            // 转换为NSDate
+            NSDate *date = [NSDate dateWithTimeIntervalSince1970:timestamp];
+            // 创建日期格式器
+            NSDateFormatter *formatter = [[NSDateFormatter alloc] init];
+            [formatter setDateFormat:@"HH:mm"]; // 设置你想要的日期格式
+            // 转换为字符串
+            NSString *dateString = [formatter stringFromDate:date];
+            return dateString;
+        }
+        else{
+            return [NSString stringWithFormat:@"%ld%@",(long)fenzhong,NSLocalizedString(@"time-outmin", @"")];
+        }
+    }
+    
+    return @"";
+}
+
+
+- (NSString *)formatTimeWithMilliseconds:(NSInteger)milliseconds{
+    NSInteger seconds = milliseconds / 1000.0;
+        
+    if (seconds >= 60) {
+        // 大于等于60秒时显示为分钟,保留一位小数
+        NSInteger minutes = seconds / 60.0;
+        NSInteger sc = seconds%60;
+        return [NSString stringWithFormat:@"%ld分%ld秒", (long)minutes,(long)sc];
+    } else {
+        // 小于60秒时显示为秒,保留整数
+        return [NSString stringWithFormat:@"%ld秒", seconds];
+    }
+}
+
+@end

+ 20 - 0
ABtong/ABtong/ALLController/call/CallIndexController.h

@@ -0,0 +1,20 @@
+//
+//  CallIndexController.h
+//  ABtong
+//
+//  Created by gan on 2025/7/30.
+//
+
+#ifndef CallIndexController_h
+#define CallIndexController_h
+
+#import <UIKit/UIKit.h>
+
+
+@interface CallIndexController : UIViewController
+
+
+
+@end
+
+#endif /* CallIndexController_h */

+ 254 - 0
ABtong/ABtong/ALLController/call/CallIndexController.m

@@ -0,0 +1,254 @@
+//
+//  CallIndexController.m
+//  ABtong
+//
+//  Created by gan on 2025/7/30.
+//
+
+#import <Foundation/Foundation.h>
+#import "CallIndexController.h"
+#import "GserverListController.h"
+#import "CallIndexCell.h"
+#import "CallListStore.h"
+#import "AppDelegate.h"
+#import "PhoneKeybord.h"
+#import "ChatController.h"
+#import "ChatListStore.h"
+
+#import "CalldetailsController.h"
+#import "GLoginController.h"
+#import "LoginStateManager.h"
+
+
+@interface CallIndexController()<UITableViewDelegate,UITableViewDataSource,CallListStoreDelegate,PhoneKeybordDelegate>
+
+@property (weak, nonatomic) IBOutlet UILabel *titleLb;
+@property (weak, nonatomic) IBOutlet UILabel *meiyoujlLb;
+@property (weak, nonatomic) IBOutlet UISegmentedControl *segCtroller;
+
+@property (weak, nonatomic) IBOutlet UITableView *tableView;
+@property (strong, nonatomic) NSMutableArray *messageArray;
+
+@property (nonatomic,strong) UIButton *jianpanBt;
+@property (nonatomic,strong) PhoneKeybord *phoneKb;
+
+
+@end
+
+
+@implementation CallIndexController
+
+
+-(void)viewDidLoad{
+    [super viewDidLoad];
+    _meiyoujlLb.alpha=0;
+    
+    [_segCtroller addTarget:self action:@selector(segmentChanged:) forControlEvents:UIControlEventValueChanged];
+    [_segCtroller setTitleTextAttributes:@{NSForegroundColorAttributeName : [UIColor whiteColor]} forState:UIControlStateSelected];
+     
+    // 设置未选中状态的字体颜色
+    [_segCtroller setTitleTextAttributes:@{NSForegroundColorAttributeName : [UIColor whiteColor]} forState:UIControlStateNormal];
+    
+//    _tableView = [[UITableView alloc] initWithFrame:CGRectZero style:UITableViewStylePlain];
+    _tableView.backgroundColor = UIColor.clearColor;
+    _tableView.delegate = self;
+    _tableView.dataSource = self;
+    [_tableView registerClass:CallIndexCell.class forCellReuseIdentifier:@"cellT"];
+    
+    // 添加关闭按钮
+    _jianpanBt = [UIButton buttonWithType:UIButtonTypeSystem];
+    [_jianpanBt setBackgroundImage:kImageMake(@"jianpan") forState:UIControlStateNormal];
+    _jianpanBt.layer.cornerRadius = 5;
+    _jianpanBt.tag = 100; // 用于稍后隐藏/显示
+    [_jianpanBt addTarget:self action:@selector(showPhoneKeybord) forControlEvents:UIControlEventTouchUpInside];
+    [self.view addSubview:_jianpanBt];
+    
+    [_jianpanBt mas_makeConstraints:^(MASConstraintMaker *make) {
+        make.size.mas_equalTo(CGSizeMake(54, 54));
+        make.bottom.mas_equalTo(-120);
+        make.centerX.mas_equalTo(self.view.mas_centerX);
+    }];
+    
+    
+    NSArray *nibs = [[NSBundle mainBundle] loadNibNamed:@"PhoneKeybord" owner:self options:nil];
+    _phoneKb = [nibs objectAtIndex:0];
+    [self.view addSubview:_phoneKb];
+//    [_phoneKb mas_makeConstraints:^(MASConstraintMaker *make) {
+//        make.bottom.mas_equalTo(self.view.mas_bottom).offset(-500);
+//        make.left.mas_equalTo(0);
+//    }];
+//    _phoneKb.backgroundColor = [UIColor whiteColor];
+    _phoneKb.alpha = 0;
+    _phoneKb.delegate=self;
+    [self.view bringSubviewToFront:_phoneKb];
+    
+    CallListStore.shareInstance.delegate = self;
+    [CallListStore.shareInstance reloadData:@""];
+    
+}
+
+-(void)viewWillAppear:(BOOL)animated{
+    [super viewWillAppear:animated];
+    CallListStore.shareInstance.delegate = self;
+    if(_segCtroller.selectedSegmentIndex==0){
+        [CallListStore.shareInstance reloadData:@""];
+    }
+    else{
+        [CallListStore.shareInstance reloadData:@"false"];
+    }
+}
+
+-(NSMutableArray *)messageArray{
+    if(_messageArray){
+        return _messageArray;
+    }
+    _messageArray = [NSMutableArray array];
+    return _messageArray;
+}
+
+- (IBAction)addserver:(id)sender {
+    GserverListController * resetPwdVc = [[GserverListController alloc] init];
+    resetPwdVc.modalPresentationStyle = UIModalPresentationFullScreen;
+    resetPwdVc.canChange = true;
+    UINavigationController * navi = [[UINavigationController alloc] initWithRootViewController:resetPwdVc];
+    navi.modalPresentationStyle = UIModalPresentationFullScreen;
+    [self presentViewController:navi animated:YES completion:nil];
+}
+
+- (void)segmentChanged:(UISegmentedControl *)sender {
+    NSInteger selectedIndex = sender.selectedSegmentIndex;
+    NSString *selectedTitle = [sender titleForSegmentAtIndex:selectedIndex];
+    NSLog(@"Selected segment: %ld, Title: %@", (long)selectedIndex, selectedTitle);
+    if(selectedIndex==0){
+        [CallListStore.shareInstance reloadData:@""];
+    }
+    else{
+        [CallListStore.shareInstance reloadData:@"false"];
+    }
+}
+
+-(void)showPhoneKeybord{
+    if(!LoginStateManager.sharedManager.isLoggedIn){
+        [self gotoLoginView];
+        return;
+    }
+    _phoneKb.frame = CGRectMake(0, -100, self.view.frame.size.width, self.view.frame.size.height);
+    _phoneKb.alpha = 1.0;
+}
+
+-(void)actionNote:(NSDictionary *)dic type:(NSInteger)type{
+    
+    NSString *chtId = dic[@"id"]?:@"";
+    
+    if(chtId.length>0){
+        if(type==1){
+            
+            UIStoryboard *board = [UIStoryboard storyboardWithName:@"Main" bundle:[NSBundle mainBundle]];
+            
+            ChatController *chatctr = [board instantiateViewControllerWithIdentifier:@"ChatController"];
+            
+            UINavigationController *uiNavC = [[UINavigationController alloc] initWithRootViewController:chatctr];
+            
+            uiNavC.modalPresentationStyle = UIModalPresentationFullScreen;
+            chatctr.chatId = dic[@"id"];
+            chatctr.type = 0;
+            ChatListStore.shareInstance.chatId =dic[@"id"];
+            chatctr.titlename = dic[@"name"];
+            chatctr.avatar = dic[@"avatar"];
+
+            [self presentViewController :uiNavC animated:YES completion:nil];
+        }
+        else if(type==2){
+            [[AppDelegate sharedInstance] startJSCall:chtId room:@"" isCaller:YES audioOnly:YES];
+        }
+        else if(type==3){
+            [[AppDelegate sharedInstance] startJSCall:chtId room:@"" isCaller:YES audioOnly:NO];
+        }
+    }
+    else{
+        NSLog(@"呼叫用户信息错误");
+    }
+}
+
+
+
+#pragma mark CallListStoreDelegate
+-(void)ChatsChange:(NSArray *)msgList type:(NSInteger)typpe{
+    NSLog(@"msgList:%lu",(unsigned long)msgList.count);
+    if(typpe==4){
+        if(_segCtroller.selectedSegmentIndex==0){
+            [CallListStore.shareInstance reloadData:@""];
+        }
+        else{
+            [CallListStore.shareInstance reloadData:@"false"];
+        }
+        return;
+    }
+    _messageArray =[msgList copy];
+    [_tableView reloadData];
+    
+}
+
+#pragma mark UITableViewDelegate,UITableViewDataSource
+-(NSInteger)numberOfSectionsInTableView:(UITableView *)tableView{
+    return 1;
+}
+-(NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section{
+    if(_messageArray.count==0){
+        _meiyoujlLb.alpha=1;
+    }
+    else{
+        _meiyoujlLb.alpha=0;
+    }
+    NSLog(@"_messageArray.count:%lu",(unsigned long)_messageArray.count);
+    return _messageArray.count;
+}
+
+-(UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath{
+   
+    static NSString *cellID = @"chatCellView";
+    CallIndexCell *cell =[tableView dequeueReusableCellWithIdentifier:cellID];
+    if(cell==nil){
+        cell=[[CallIndexCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:cellID];
+    }
+//    cell.accessoryType = UITableViewCellAccessoryDisclosureIndicator;
+    
+    NSDictionary *dic = [self.messageArray objectAtIndex:indexPath.row];
+    
+    [cell fillWithData:dic];
+    
+    return cell;
+}
+
+
+
+
+- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath {
+    return 80.0f;
+}
+
+
+
+-(void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath{
+    
+    
+    NSDictionary *dic = [self.messageArray objectAtIndex:indexPath.row];
+    
+    UIStoryboard *board = [UIStoryboard storyboardWithName:@"CallControllers" bundle:[NSBundle mainBundle]];
+    CalldetailsController *chatctr = [board instantiateViewControllerWithIdentifier:@"CalldetailsController"];
+    chatctr.callItem = dic;
+    UINavigationController *uiNavC = [[UINavigationController alloc] initWithRootViewController:chatctr];
+    uiNavC.modalPresentationStyle = UIModalPresentationFullScreen;
+    [self presentViewController :uiNavC animated:YES completion:nil];
+}
+
+
+-(void)gotoLoginView{
+    UIStoryboard *board = [UIStoryboard storyboardWithName:@"Main" bundle:[NSBundle mainBundle]];
+    GLoginController *login = [board instantiateViewControllerWithIdentifier:@"LoginController"];
+    UINavigationController *uiNavC = [[UINavigationController alloc] initWithRootViewController:login];
+    uiNavC.modalPresentationStyle = UIModalPresentationFullScreen;
+    [self presentViewController:uiNavC animated:YES completion:nil];
+}
+
+@end

+ 18 - 0
ABtong/ABtong/ALLController/call/CalldetailsCell.h

@@ -0,0 +1,18 @@
+//
+//  CalldetailsCell.h
+//  ABtong
+//
+//  Created by gan on 2025/7/31.
+//
+
+#ifndef CalldetailsCell_h
+#define CalldetailsCell_h
+#import <UIKit/UIKit.h>
+
+
+@interface CalldetailsCell : UITableViewCell
+
+- (void)fillWithData:( NSDictionary*)data;
+@end
+
+#endif /* CalldetailsCell_h */

+ 233 - 0
ABtong/ABtong/ALLController/call/CalldetailsCell.m

@@ -0,0 +1,233 @@
+//
+//  CalldetailsCell.m
+//  ABtong
+//
+//  Created by gan on 2025/7/31.
+//
+
+#import <Foundation/Foundation.h>
+#import "CalldetailsCell.h"
+#import <SDWebImage/UIImageView+WebCache.h>
+#import "config.h"
+
+
+@interface CalldetailsCell()
+
+@property (strong, nonatomic) UILabel *name;
+@property (strong, nonatomic) UILabel *time;
+@property (strong, nonatomic) UILabel *countText;
+@property (strong, nonatomic) UIImageView *rightAr;
+
+@property (strong, nonatomic) UILabel *lineLb;
+
+
+@end
+
+@implementation CalldetailsCell
+
+
+- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
+    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
+    if (self) {
+        [self initAlllSubviews];
+        self.selectionStyle = UITableViewCellSelectionStyleNone;
+        self.backgroundColor = [UIColor clearColor];
+    }
+    return self;
+}
+
+
+-(void)initAlllSubviews{
+   
+    _rightAr = [UIImageView new];
+    _rightAr.contentMode = UIViewContentModeScaleAspectFill;
+    [_rightAr setImage:[UIImage imageNamed:@"arrow-right"]];
+    [self.contentView addSubview:_rightAr];
+    
+    
+    // 名字
+    _name = [UILabel new];
+    _name.font = SYSFONT(18);
+    _name.textColor = [UIColor whiteColor];
+    [self.contentView addSubview:_name];
+    
+    // 时间
+    _time = [UILabel new];
+    _time.font = SYSFONT(14);
+    _time.textColor = UIColor.whiteColor;
+    [self.contentView addSubview:_time];
+    
+    // 时间
+    _countText = [UILabel new];
+    _countText.font = SYSFONT(16);
+    _countText.textColor = UIColor.whiteColor;
+    [self.contentView addSubview:_countText];
+    
+    _lineLb = [UILabel new];
+    _lineLb.text = @"";
+    _lineLb.backgroundColor = UIColor.lightGrayColor;
+    [self.contentView addSubview:_lineLb];
+    
+    
+    
+    [_rightAr mas_remakeConstraints:^(MASConstraintMaker *make) {
+        make.right.equalTo(self.contentView.mas_right).offset(-30);
+        make.top.mas_equalTo(self.contentView.mas_top).offset(20);
+        make.width.mas_equalTo(32);
+        make.height.mas_equalTo(32);
+    }];
+    
+    [_name mas_remakeConstraints:^(MASConstraintMaker *make) {
+        make.left.equalTo(self.contentView.mas_left).offset(8);
+        make.top.mas_equalTo(self.contentView.mas_top).offset(12);
+    }];
+    
+    [_time mas_remakeConstraints:^(MASConstraintMaker *make) {
+        make.left.equalTo(self.contentView.mas_left).offset(8);
+        make.top.mas_equalTo(_name.mas_bottom).offset(6);
+    }];
+    
+    [_countText mas_remakeConstraints:^(MASConstraintMaker *make) {
+        make.left.equalTo(_time.mas_right).offset(4);
+        make.top.mas_equalTo(_name.mas_bottom).offset(6);
+    }];
+    
+    [_lineLb mas_remakeConstraints:^(MASConstraintMaker *make) {
+        make.top.mas_equalTo(self.contentView.mas_bottom).offset(-3);
+        make.width.mas_equalTo(self.contentView.mas_width).offset(12);
+        make.height.mas_equalTo(0.5);
+    }];
+    
+    
+}
+
+- (void)fillWithData:( NSDictionary*)data {
+    
+    NSLog(@"fillWithData:%@",data);
+    
+    //NSLog(@"lastTime:%@",data[@"lastTime"]);
+    NSString *timestr =data[@"timestamp"];
+    
+    if([timestr isKindOfClass:[NSNumber class]]){
+        self.name.text=[self timeF:timestr.longLongValue];
+    }
+    else if([timestr isKindOfClass:[NSString class]]){
+        self.name.text=[self timeF:timestr.longLongValue];
+    }
+    else{
+        self.name.text=@"";
+    }
+    
+    NSString *chatId =data[@"chatId"]?:@"";
+    NSString *fromId =data[@"fromId"]?:@"";
+    if([chatId isEqualToString:fromId]){
+        _time.text = @"呼入:";
+    }
+    else{
+        _time.text = @"呼出:";
+    }
+    
+    NSString *video =data[@"video"];
+    if (video.intValue==0) {
+        [_rightAr setImage:[UIImage imageNamed:@"Cyuyinth"]];
+    }
+    else{
+        [_rightAr setImage:[UIImage imageNamed:@"Cshipinth"]];
+    }
+    
+    
+    
+    
+    
+    NSString *result =data[@"result"];
+    NSString *duration = data[@"duration"];
+    if(result.intValue == 1){
+        _countText.text = [NSString stringWithFormat:@"   %@",[self formatTimeWithMilliseconds:duration.intValue]];
+    }
+    else{
+        _countText.text = @"未接通";
+    }
+    // tell constraints they need updating
+    [self setNeedsUpdateConstraints];
+
+    // update constraints now so we can animate the change
+    [self updateConstraintsIfNeeded];
+
+    [self layoutIfNeeded];
+}
+
+-(NSString *)timeF:(NSInteger)time{
+    //NSLog(@"time:%ld",(long)time);
+    // 创建日期格式器
+    NSDateFormatter *formatter = [[NSDateFormatter alloc] init];
+    [formatter setDateFormat:@"dd"]; // 设置你想要的日期格式
+    
+    
+    long long timestamp =(long)time/1000; // 例如:2021-10-01 00:00:00 UTC
+    // 转换为NSDate
+    NSDate *date = [NSDate dateWithTimeIntervalSince1970:timestamp];
+    NSString *dateString = [formatter stringFromDate:date];
+    
+    
+    NSDate *now = [NSDate date];
+    NSTimeInterval trt = [now timeIntervalSince1970];
+    date = [NSDate dateWithTimeIntervalSince1970:trt];
+    NSString *tdateString = [formatter stringFromDate:date];
+    
+    
+    NSInteger shijiancha = trt-timestamp;
+    
+    if(shijiancha<60){
+        return NSLocalizedString(@"time-oneminint", @"");
+    }
+    if(shijiancha>24*3600||dateString.intValue!=tdateString.intValue){
+        // 假设这是你的时间戳(以秒为单位)
+        long long timestamp =(long)time/1000; // 例如:2021-10-01 00:00:00 UTC
+        // 转换为NSDate
+        NSDate *date = [NSDate dateWithTimeIntervalSince1970:timestamp];
+        // 创建日期格式器
+        NSDateFormatter *formatter = [[NSDateFormatter alloc] init];
+        [formatter setDateFormat:@"yyyy-MM-dd HH:mm"]; // 设置你想要的日期格式
+        // 转换为字符串
+        NSString *dateString = [formatter stringFromDate:date];
+        return dateString;
+    }
+    else{
+        NSInteger xiaoshi = shijiancha/3600;
+        NSInteger fenzhong = shijiancha/60;
+        if(xiaoshi>0){
+            // 假设这是你的时间戳(以秒为单位)
+            long long timestamp =(long)time/1000; // 例如:2021-10-01 00:00:00 UTC
+            // 转换为NSDate
+            NSDate *date = [NSDate dateWithTimeIntervalSince1970:timestamp];
+            // 创建日期格式器
+            NSDateFormatter *formatter = [[NSDateFormatter alloc] init];
+            [formatter setDateFormat:@"HH:mm"]; // 设置你想要的日期格式
+            // 转换为字符串
+            NSString *dateString = [formatter stringFromDate:date];
+            return dateString;
+        }
+        else{
+            return [NSString stringWithFormat:@"%ld%@",(long)fenzhong,NSLocalizedString(@"time-outmin", @"")];
+        }
+    }
+    
+    return @"";
+}
+
+
+- (NSString *)formatTimeWithMilliseconds:(NSInteger)milliseconds{
+    NSInteger seconds = milliseconds / 1000.0;
+        
+    if (seconds >= 60) {
+        // 大于等于60秒时显示为分钟,保留一位小数
+        NSInteger minutes = seconds / 60.0;
+        NSInteger sc = seconds%60;
+        return [NSString stringWithFormat:@"%ld分%ld秒", (long)minutes,(long)sc];
+    } else {
+        // 小于60秒时显示为秒,保留整数
+        return [NSString stringWithFormat:@"%ld秒", seconds];
+    }
+}
+
+@end

+ 19 - 0
ABtong/ABtong/ALLController/call/CalldetailsController.h

@@ -0,0 +1,19 @@
+//
+//  CalldetailsController.h
+//  ABtong
+//
+//  Created by gan on 2025/8/11.
+//
+
+#ifndef CalldetailsController_h
+#define CalldetailsController_h
+
+
+@interface CalldetailsController : UIViewController
+
+
+@property (strong, nonatomic) NSDictionary *callItem;
+
+@end
+
+#endif /* CalldetailsController_h */

+ 185 - 0
ABtong/ABtong/ALLController/call/CalldetailsController.m

@@ -0,0 +1,185 @@
+//
+//  CalldetailsController.m
+//  ABtong
+//
+//  Created by gan on 2025/8/11.
+//
+
+#import <Foundation/Foundation.h>
+#import "CalldetailsController.h"
+#import "CallListStore.h"
+#import "CalldetailsCell.h"
+#import "ChatController.h"
+#import "ChatListStore.h"
+#import "AppDelegate.h"
+
+@interface CalldetailsController()<UITableViewDelegate,UITableViewDataSource,CallListStoreDelegate>
+@property (weak, nonatomic) IBOutlet UIView *topcontent;
+@property (weak, nonatomic) IBOutlet UIImageView *avatar;
+@property (weak, nonatomic) IBOutlet UILabel *nameLb;
+@property (weak, nonatomic) IBOutlet UITableView *tableView;
+
+@property (strong, nonatomic) NSMutableArray *messageArray;
+
+@end
+
+@implementation CalldetailsController
+
+-(void)viewDidLoad{
+    [super viewDidLoad];
+    [self.navigationController setNavigationBarHidden:YES animated:NO];
+    _tableView.backgroundColor = UIColor.clearColor;
+    _tableView.delegate = self;
+    _tableView.dataSource = self;
+    [_tableView registerClass:CalldetailsCell.class forCellReuseIdentifier:@"cellT"];
+    _topcontent.layer.cornerRadius = 8.0f;
+    
+    CallListStore.shareInstance.delegate = self;
+    if(self.callItem){
+        NSString *chatId = self.callItem[@"chatId"];
+//        [CallListStore.shareInstance loadUserCallMsg:chatId];
+        
+        _avatar.layer.cornerRadius = 25;
+        _avatar.layer.masksToBounds = YES;
+        _avatar.contentMode = UIViewContentModeScaleAspectFill;
+        
+        NSString *avatar =self.callItem[@"fromAvatar"]?:@"";
+        if([avatar isKindOfClass:[NSString class]]){
+            
+        }
+        else{
+            avatar = @"";
+        }
+        [self.avatar sd_setImageWithURL:[NSURL URLWithString:avatar] placeholderImage:[UIImage imageNamed:@"Avatar"]];
+        self.nameLb.text =self.callItem[@"fromName"]?:@"";
+        
+    }
+}
+
+-(void)viewWillAppear:(BOOL)animated{
+    [super viewWillAppear:animated];
+    CallListStore.shareInstance.delegate = self;
+    NSString *chatId = self.callItem[@"chatId"];
+    [CallListStore.shareInstance loadUserCallMsg:chatId];
+}
+
+-(NSMutableArray *)messageArray{
+    if(_messageArray){
+        return _messageArray;
+    }
+    _messageArray = [NSMutableArray array];
+    return _messageArray;
+}
+
+- (IBAction)fanhui:(id)sender {
+    NSLog(@"fanhui------");
+    [self dismissViewControllerAnimated:YES completion:nil];
+}
+
+- (IBAction)actBtselect:(id)sender {
+    
+    NSString *chatId = self.callItem[@"chatId"];
+    
+    UIButton *bt = (UIButton *)sender;
+    NSInteger type =bt.tag;
+    if(chatId.length>0){
+        if(type==1){
+            
+            UIStoryboard *board = [UIStoryboard storyboardWithName:@"Main" bundle:[NSBundle mainBundle]];
+            
+            ChatController *chatctr = [board instantiateViewControllerWithIdentifier:@"ChatController"];
+            
+            UINavigationController *uiNavC = [[UINavigationController alloc] initWithRootViewController:chatctr];
+            
+            uiNavC.modalPresentationStyle = UIModalPresentationFullScreen;
+            chatctr.chatId = chatId;
+            chatctr.type = 0;
+            ChatListStore.shareInstance.chatId =chatId;
+            
+            chatctr.titlename = self.callItem[@"fromName"]?:@"";
+            chatctr.avatar = self.callItem[@"fromAvatar"]?:@"";
+
+            [self presentViewController :uiNavC animated:YES completion:nil];
+        }
+        else if(type==2){
+            [[AppDelegate sharedInstance] startJSCall:chatId room:@"" isCaller:YES audioOnly:YES];
+        }
+        else if(type==3){
+            [[AppDelegate sharedInstance] startJSCall:chatId room:@"" isCaller:YES audioOnly:NO];
+        }
+    }
+    else{
+        NSLog(@"呼叫用户信息错误");
+    }
+}
+
+
+- (IBAction)allRecord:(id)sender {
+}
+
+
+
+#pragma mark CallListStoreDelegate
+-(void)ChatsChange:(NSArray *)msgList type:(NSInteger)typpe{
+    NSLog(@"CalldetailsController:msgList:%@",msgList);
+    _messageArray =[msgList copy];
+    [_tableView reloadData];
+    
+}
+
+
+
+#pragma mark UITableViewDelegate,UITableViewDataSource
+-(NSInteger)numberOfSectionsInTableView:(UITableView *)tableView{
+    return 1;
+}
+-(NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section{
+//    if(_messageArray.count==0){
+//        _meiyoujlLb.alpha=1;
+//    }
+//    else{
+//        _meiyoujlLb.alpha=0;
+//    }
+    NSLog(@"_messageArray.count:%lu",(unsigned long)_messageArray.count);
+    return _messageArray.count;
+}
+
+-(UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath{
+   
+    static NSString *cellID = @"chatCellView";
+    CalldetailsCell *cell =[tableView dequeueReusableCellWithIdentifier:cellID];
+    if(cell==nil){
+        cell=[[CalldetailsCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:cellID];
+    }
+//    cell.accessoryType = UITableViewCellAccessoryDisclosureIndicator;
+    
+    NSDictionary *dic = [self.messageArray objectAtIndex:indexPath.row];
+    
+    [cell fillWithData:dic];
+    
+    return cell;
+}
+
+
+
+
+- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath {
+    return 80.0f;
+}
+
+
+
+-(void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath{
+    
+    
+    NSDictionary *dic = [self.messageArray objectAtIndex:indexPath.row];
+    
+    UIStoryboard *board = [UIStoryboard storyboardWithName:@"CallControllers" bundle:[NSBundle mainBundle]];
+    CalldetailsController *chatctr = [board instantiateViewControllerWithIdentifier:@"CalldetailsController"];
+    chatctr.callItem = dic;
+    UINavigationController *uiNavC = [[UINavigationController alloc] initWithRootViewController:chatctr];
+    uiNavC.modalPresentationStyle = UIModalPresentationFullScreen;
+    [self presentViewController :uiNavC animated:YES completion:nil];
+}
+
+@end

+ 26 - 0
ABtong/ABtong/ALLController/call/PhoneKeybord.h

@@ -0,0 +1,26 @@
+//
+//  PhoneKeybord.h
+//  ABtong
+//
+//  Created by gan on 2025/8/6.
+//
+
+#ifndef PhoneKeybord_h
+#define PhoneKeybord_h
+
+#import <UIKit/UIKit.h>
+
+@protocol PhoneKeybordDelegate <NSObject>
+@optional
+- (void)actionNote:(NSDictionary *_Nullable)dic type:(NSInteger)type;
+@end
+
+@interface PhoneKeybord : UIView
+
+@property (nonatomic,weak) id <PhoneKeybordDelegate> delegate;
+
+@end
+
+
+
+#endif /* PhoneKeybord_h */

+ 139 - 0
ABtong/ABtong/ALLController/call/PhoneKeybord.m

@@ -0,0 +1,139 @@
+//
+//  PhoneKeybord.m
+//  ABtong
+//
+//  Created by gan on 2025/8/6.
+//
+
+#import <Foundation/Foundation.h>
+#import "FriendNetApi.h"
+#import "PhoneKeybord.h"
+
+@interface PhoneKeybord()
+
+
+
+
+@property (weak, nonatomic) IBOutlet UITextField *phoneInput;
+
+
+@property (strong, nonatomic) NSDictionary *showDic;
+
+@property (weak, nonatomic) IBOutlet UIView *userContentV;
+@property (weak, nonatomic) IBOutlet UIImageView *avatar;
+@property (weak, nonatomic) IBOutlet UILabel *nameLb;
+
+
+
+@end
+
+@implementation PhoneKeybord
+
+
+- (instancetype)initWithFrame:(CGRect)frame {
+    self = [super initWithFrame:frame];
+    if (self) {
+        self.backgroundColor = [UIColor whiteColor];
+        _userContentV.alpha = 0;
+    }
+    return self;
+}
+
+- (IBAction)actBtselect:(id)sender {
+    UIButton *bt = (UIButton *)sender;
+    NSLog(@"actBtselect:%ld",(long)bt.tag);
+    
+    if (self.delegate) {
+        [self.delegate actionNote:_showDic type:bt.tag];
+    }
+    self.alpha = 0;
+    _phoneInput.text = @"";
+    _userContentV.alpha = 0;
+}
+
+
+
+- (IBAction)keybtselect:(id)sender {
+    UIButton *bt = (UIButton *)sender;
+    if (bt.tag<10) {//1到九
+        _phoneInput.text = [NSString stringWithFormat:@"%@%ld",_phoneInput.text,(long)bt.tag];
+    }
+    if(bt.tag==10){//零
+        _phoneInput.text = [NSString stringWithFormat:@"%@0",_phoneInput.text];
+    }
+    
+    
+    if(bt.tag==11){//星号*
+        _phoneInput.text = [NSString stringWithFormat:@"%@*",_phoneInput.text];
+    }
+    if(bt.tag==12){//井号#
+        _phoneInput.text = [NSString stringWithFormat:@"%@#",_phoneInput.text];
+    }
+    if(bt.tag==13){//关闭
+        self.alpha = 0;
+        _phoneInput.text = @"";
+    }
+    if(bt.tag==14){//拨号
+        
+        if(_userContentV.alpha != 1){
+            [MBProgressHUD showWithText:NSLocalizedString(@"call-wuxiaohm", @"")];
+            return;
+        }
+        
+        self.alpha = 0;
+        if (self.delegate) {
+            [self.delegate actionNote:_showDic type:2];
+        }
+        _phoneInput.text = @"";
+        _userContentV.alpha = 0;
+    }
+    if(bt.tag==15){//删除
+        NSString *str =_phoneInput.text;
+        if(str.length>0){
+            str=[str substringToIndex:str.length-1];
+            _phoneInput.text = str;
+        }
+    }
+    
+    if(_phoneInput.text.length==6){
+        [self getUserinfo:_phoneInput.text];
+    }
+    else{
+        _userContentV.alpha = 0;
+    }
+    
+}
+
+-(void)getUserinfo:(NSString *)keyword{
+    [FriendNetApi searchfriend:keyword succ:^(int code, NSDictionary * res) {
+        NSLog(@"res:%@",res);
+        NSArray *data= res[@"data"];
+        if(data.count>0){
+            NSLog(@"1:%@",data[0]);
+            [self shouwUserinfo:data[0]];
+        }
+        else{
+            NSLog(@"呼叫用户信息错误");
+        }
+        
+    } fail:^(NSError * _Nonnull error) {
+        
+    }];
+}
+
+-(void)shouwUserinfo:(NSDictionary *)info{
+    _showDic = info.copy;
+    _userContentV.layer.cornerRadius = 8;
+    _userContentV.alpha = 1;
+    _avatar.layer.cornerRadius = 25;
+    _nameLb.text =info[@"name"]?:@"";
+    NSString *url = info[@"avatar"];
+    if([url isKindOfClass:[NSNull class]]){
+        url=@"";
+    }
+    [_avatar sd_setImageWithURL:[NSURL URLWithString:url] placeholderImage:[UIImage imageNamed:@"Avatar"]];
+}
+
+
+
+@end

+ 308 - 0
ABtong/ABtong/ALLController/call/PhoneKeybord.xib

@@ -0,0 +1,308 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="23727" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
+    <device id="retina6_12" orientation="portrait" appearance="light"/>
+    <dependencies>
+        <deployment identifier="iOS"/>
+        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="23721"/>
+        <capability name="Safe area layout guides" minToolsVersion="9.0"/>
+        <capability name="System colors in document resources" minToolsVersion="11.0"/>
+        <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
+    </dependencies>
+    <objects>
+        <placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner"/>
+        <placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
+        <view contentMode="scaleToFill" id="iN0-l3-epB" customClass="PhoneKeybord">
+            <rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
+            <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
+            <subviews>
+                <view alpha="0.69999999999999996" contentMode="scaleToFill" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="2Zt-D3-2ZK">
+                    <rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
+                    <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
+                    <color key="backgroundColor" systemColor="opaqueSeparatorColor"/>
+                </view>
+                <view alpha="0.0" contentMode="scaleToFill" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="NUO-3I-vzO">
+                    <rect key="frame" x="8" y="358" width="377" height="67"/>
+                    <autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMinY="YES"/>
+                    <subviews>
+                        <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" image="Avatar0" translatesAutoresizingMaskIntoConstraints="NO" id="t0I-QC-OQE">
+                            <rect key="frame" x="8" y="8" width="50" height="50"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES" flexibleMaxY="YES"/>
+                        </imageView>
+                        <button opaque="NO" tag="1" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="0e4-YE-NyQ">
+                            <rect key="frame" x="180" y="11" width="44" height="44"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMinY="YES" flexibleMaxY="YES"/>
+                            <state key="normal" title="Button"/>
+                            <buttonConfiguration key="configuration" style="filled">
+                                <backgroundConfiguration key="background" image="index"/>
+                                <color key="baseBackgroundColor" white="0.33333333333333331" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                            </buttonConfiguration>
+                            <connections>
+                                <action selector="actBtselect:" destination="iN0-l3-epB" eventType="touchUpInside" id="UwA-eC-fUe"/>
+                            </connections>
+                        </button>
+                        <button opaque="NO" tag="2" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="NuN-kp-UlZ">
+                            <rect key="frame" x="247" y="11" width="44" height="44"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMinY="YES" flexibleMaxY="YES"/>
+                            <state key="normal" title="Button"/>
+                            <buttonConfiguration key="configuration" style="filled">
+                                <backgroundConfiguration key="background" image="Cyuyinth"/>
+                                <color key="baseBackgroundColor" white="0.33333333333333331" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                            </buttonConfiguration>
+                            <connections>
+                                <action selector="actBtselect:" destination="iN0-l3-epB" eventType="touchUpInside" id="l6j-8e-PcM"/>
+                            </connections>
+                        </button>
+                        <button opaque="NO" tag="3" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="trA-hA-yzG">
+                            <rect key="frame" x="314" y="11" width="44" height="44"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMinY="YES" flexibleMaxY="YES"/>
+                            <state key="normal" title="Button"/>
+                            <buttonConfiguration key="configuration" style="filled">
+                                <backgroundConfiguration key="background" image="Cshipinth"/>
+                                <color key="baseBackgroundColor" white="0.33333333333333331" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                            </buttonConfiguration>
+                            <connections>
+                                <action selector="actBtselect:" destination="iN0-l3-epB" eventType="touchUpInside" id="G6k-9K-WRT"/>
+                            </connections>
+                        </button>
+                        <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" text="Label" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Ubp-9s-7vW">
+                            <rect key="frame" x="66" y="23" width="106" height="21"/>
+                            <autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="17"/>
+                            <nil key="textColor"/>
+                            <nil key="highlightedColor"/>
+                        </label>
+                    </subviews>
+                    <color key="backgroundColor" systemColor="systemBackgroundColor"/>
+                </view>
+                <view contentMode="scaleToFill" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="BD3-3p-1Ue">
+                    <rect key="frame" x="0.0" y="434" width="393" height="418"/>
+                    <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
+                    <subviews>
+                        <button opaque="NO" tag="3" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="F6j-ju-0EL">
+                            <rect key="frame" x="277" y="60" width="50" height="50"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMinY="YES"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="20"/>
+                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                            <state key="normal" title="3" backgroundImage="yuandian">
+                                <color key="titleColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                            </state>
+                            <connections>
+                                <action selector="keybtselect:" destination="iN0-l3-epB" eventType="touchUpInside" id="pvg-ra-Gel"/>
+                            </connections>
+                        </button>
+                        <button opaque="NO" tag="2" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="bFV-yC-FDA">
+                            <rect key="frame" x="171" y="60" width="50" height="50"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMaxX="YES" flexibleMinY="YES"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="20"/>
+                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                            <state key="normal" title="2" backgroundImage="yuandian">
+                                <color key="titleColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                            </state>
+                            <connections>
+                                <action selector="keybtselect:" destination="iN0-l3-epB" eventType="touchUpInside" id="Yay-uV-D86"/>
+                            </connections>
+                        </button>
+                        <button opaque="NO" tag="1" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="nyT-QY-mOH">
+                            <rect key="frame" x="69" y="60" width="50" height="50"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="20"/>
+                            <color key="tintColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                            <state key="normal" title="1" backgroundImage="yuandian">
+                                <color key="titleColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                            </state>
+                            <connections>
+                                <action selector="keybtselect:" destination="iN0-l3-epB" eventType="touchUpInside" id="yoy-Yk-xYl"/>
+                            </connections>
+                        </button>
+                        <button opaque="NO" tag="6" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="vPP-mP-Ffs">
+                            <rect key="frame" x="277" y="128" width="50" height="50"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMinY="YES"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="20"/>
+                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                            <state key="normal" title="6" backgroundImage="yuandian">
+                                <color key="titleColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                            </state>
+                            <connections>
+                                <action selector="keybtselect:" destination="iN0-l3-epB" eventType="touchUpInside" id="Oqu-bh-ejU"/>
+                            </connections>
+                        </button>
+                        <button opaque="NO" tag="5" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="vh7-3g-GDi">
+                            <rect key="frame" x="171" y="128" width="50" height="50"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMaxX="YES" flexibleMinY="YES"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="20"/>
+                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                            <state key="normal" title="5" backgroundImage="yuandian">
+                                <color key="titleColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                            </state>
+                            <connections>
+                                <action selector="keybtselect:" destination="iN0-l3-epB" eventType="touchUpInside" id="3ta-ew-Eh7"/>
+                            </connections>
+                        </button>
+                        <button opaque="NO" tag="4" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="tro-4w-Cqf">
+                            <rect key="frame" x="69" y="128" width="50" height="50"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="20"/>
+                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                            <state key="normal" title="4" backgroundImage="yuandian">
+                                <color key="titleColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                            </state>
+                            <connections>
+                                <action selector="keybtselect:" destination="iN0-l3-epB" eventType="touchUpInside" id="Kd4-fI-3ta"/>
+                            </connections>
+                        </button>
+                        <button opaque="NO" tag="9" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="WBZ-Qk-FM9">
+                            <rect key="frame" x="277" y="196" width="50" height="50"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMinY="YES"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="20"/>
+                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                            <state key="normal" title="9" backgroundImage="yuandian">
+                                <color key="titleColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                            </state>
+                            <connections>
+                                <action selector="keybtselect:" destination="iN0-l3-epB" eventType="touchUpInside" id="Toq-fl-vt7"/>
+                            </connections>
+                        </button>
+                        <button opaque="NO" tag="8" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="4nQ-0K-O8y">
+                            <rect key="frame" x="171" y="196" width="50" height="50"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMaxX="YES" flexibleMinY="YES"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="20"/>
+                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                            <state key="normal" title="8" backgroundImage="yuandian">
+                                <color key="titleColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                            </state>
+                            <connections>
+                                <action selector="keybtselect:" destination="iN0-l3-epB" eventType="touchUpInside" id="wqT-MT-YWq"/>
+                            </connections>
+                        </button>
+                        <button opaque="NO" tag="7" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="XWO-OU-PHN">
+                            <rect key="frame" x="69" y="196" width="50" height="50"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="20"/>
+                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                            <state key="normal" title="7" backgroundImage="yuandian">
+                                <color key="titleColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                            </state>
+                            <connections>
+                                <action selector="keybtselect:" destination="iN0-l3-epB" eventType="touchUpInside" id="POE-AR-SDa"/>
+                            </connections>
+                        </button>
+                        <button opaque="NO" tag="10" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="j3x-j7-LnC">
+                            <rect key="frame" x="171" y="264" width="50" height="50"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMaxX="YES" flexibleMinY="YES"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="20"/>
+                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                            <state key="normal" title="0" backgroundImage="yuandian">
+                                <color key="titleColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                            </state>
+                            <connections>
+                                <action selector="keybtselect:" destination="iN0-l3-epB" eventType="touchUpInside" id="5eX-SC-rmg"/>
+                            </connections>
+                        </button>
+                        <button opaque="NO" tag="12" contentMode="top" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="Yaz-k8-sr5">
+                            <rect key="frame" x="277" y="264" width="50" height="50"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMinY="YES"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="20"/>
+                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                            <state key="normal" title="#" backgroundImage="yuandian">
+                                <color key="titleColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                            </state>
+                            <connections>
+                                <action selector="keybtselect:" destination="iN0-l3-epB" eventType="touchUpInside" id="3qT-Gw-PBV"/>
+                            </connections>
+                        </button>
+                        <button opaque="NO" tag="14" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="YRK-hc-emB">
+                            <rect key="frame" x="176" y="338" width="45" height="45"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMaxX="YES" flexibleMinY="YES"/>
+                            <state key="normal" title="Button"/>
+                            <buttonConfiguration key="configuration" style="plain">
+                                <backgroundConfiguration key="background" image="hangup_icon_blue"/>
+                            </buttonConfiguration>
+                            <connections>
+                                <action selector="keybtselect:" destination="iN0-l3-epB" eventType="touchUpInside" id="JEx-ss-H2A"/>
+                            </connections>
+                        </button>
+                        <button opaque="NO" tag="11" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="JAY-Uo-fWh">
+                            <rect key="frame" x="69" y="264" width="50" height="50"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="22"/>
+                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                            <state key="normal" title="*" backgroundImage="yuandian">
+                                <color key="titleColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                            </state>
+                            <connections>
+                                <action selector="keybtselect:" destination="iN0-l3-epB" eventType="touchUpInside" id="a4M-Jj-cg6"/>
+                            </connections>
+                        </button>
+                        <button opaque="NO" tag="15" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="qt4-IT-EQV">
+                            <rect key="frame" x="277" y="343" width="62" height="40"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMinY="YES"/>
+                            <fontDescription key="fontDescription" name=".AppleSystemUIFont" family=".AppleSystemUIFont" pointSize="17"/>
+                            <color key="tintColor" systemColor="opaqueSeparatorColor"/>
+                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                            <state key="normal" title="删除">
+                                <color key="titleColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                            </state>
+                            <buttonConfiguration key="configuration" style="filled" title="删除">
+                                <fontDescription key="titleFontDescription" type="system" pointSize="18"/>
+                                <color key="baseForegroundColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                <color key="baseBackgroundColor" systemColor="systemGray5Color"/>
+                            </buttonConfiguration>
+                            <connections>
+                                <action selector="keybtselect:" destination="iN0-l3-epB" eventType="touchUpInside" id="OHV-ce-MRX"/>
+                            </connections>
+                        </button>
+                        <textField opaque="NO" contentMode="scaleToFill" horizontalHuggingPriority="248" fixedFrame="YES" enabled="NO" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="roundedRect" placeholder="请输入号码" textAlignment="center" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="c2G-9f-XOa">
+                            <rect key="frame" x="65" y="8" width="262" height="34"/>
+                            <autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMinY="YES"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="16"/>
+                            <textInputTraits key="textInputTraits"/>
+                        </textField>
+                        <button opaque="NO" tag="13" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="RvE-9s-1yB">
+                            <rect key="frame" x="57" y="343" width="62" height="40"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
+                            <color key="tintColor" systemColor="opaqueSeparatorColor"/>
+                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                            <state key="normal" title="关闭"/>
+                            <buttonConfiguration key="configuration" style="filled" title="关闭">
+                                <fontDescription key="titleFontDescription" type="system" pointSize="18"/>
+                                <color key="baseForegroundColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                <color key="baseBackgroundColor" systemColor="systemGray5Color"/>
+                            </buttonConfiguration>
+                            <connections>
+                                <action selector="keybtselect:" destination="iN0-l3-epB" eventType="touchUpInside" id="4pB-VC-I8X"/>
+                            </connections>
+                        </button>
+                    </subviews>
+                    <color key="backgroundColor" systemColor="systemBackgroundColor"/>
+                </view>
+            </subviews>
+            <viewLayoutGuide key="safeArea" id="vUN-kp-3ea"/>
+            <color key="tintColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+            <connections>
+                <outlet property="avatar" destination="t0I-QC-OQE" id="TR3-1m-AzF"/>
+                <outlet property="nameLb" destination="Ubp-9s-7vW" id="bij-Gw-i7W"/>
+                <outlet property="phoneInput" destination="c2G-9f-XOa" id="dw2-oU-eJU"/>
+                <outlet property="userContentV" destination="NUO-3I-vzO" id="6Hv-T2-bY6"/>
+            </connections>
+            <point key="canvasLocation" x="200.76335877862596" y="-269.01408450704224"/>
+        </view>
+    </objects>
+    <resources>
+        <image name="Avatar0" width="200" height="200"/>
+        <image name="Cshipinth" width="56" height="56"/>
+        <image name="Cyuyinth" width="56" height="56"/>
+        <image name="hangup_icon_blue" width="200" height="200"/>
+        <image name="index" width="32" height="32"/>
+        <image name="yuandian" width="200" height="200"/>
+        <systemColor name="opaqueSeparatorColor">
+            <color red="0.77647058820000003" green="0.77647058820000003" blue="0.7843137255" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+        </systemColor>
+        <systemColor name="systemBackgroundColor">
+            <color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+        </systemColor>
+        <systemColor name="systemGray5Color">
+            <color red="0.8980392157" green="0.8980392157" blue="0.91764705879999997" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+        </systemColor>
+    </resources>
+</document>

+ 0 - 0
ABtong/ABtong/Controller/chat/CameraViewController.h → ABtong/ABtong/ALLController/chat/CameraViewController.h


+ 0 - 0
ABtong/ABtong/Controller/chat/CameraViewController.m → ABtong/ABtong/ALLController/chat/CameraViewController.m


+ 0 - 0
ABtong/ABtong/Controller/chat/ChatController.h → ABtong/ABtong/ALLController/chat/ChatController.h


+ 1 - 1
ABtong/ABtong/Controller/chat/ChatController.m → ABtong/ABtong/ALLController/chat/ChatController.m

@@ -26,7 +26,7 @@
 #import "GDBManager.h"
 #import "chatpopView.h"
 #import "config.h"
-#import "JSGController.h"
+
 #import "SDWebImage/SDWebImage.h"
 #import "ChatMessageModel.h"
 #import "ChatFileModel.h"

+ 0 - 0
ABtong/ABtong/Controller/chat/ChatHistory.storyboard → ABtong/ABtong/ALLController/chat/ChatHistory.storyboard


+ 0 - 0
ABtong/ABtong/Controller/chat/ChatHistoryController.h → ABtong/ABtong/ALLController/chat/ChatHistoryController.h


+ 0 - 0
ABtong/ABtong/Controller/chat/ChatHistoryController.m → ABtong/ABtong/ALLController/chat/ChatHistoryController.m


+ 0 - 0
ABtong/ABtong/Controller/chat/ChatIndexController.h → ABtong/ABtong/ALLController/chat/ChatIndexController.h


+ 0 - 0
ABtong/ABtong/Controller/chat/ChatIndexController.m → ABtong/ABtong/ALLController/chat/ChatIndexController.m


+ 0 - 0
ABtong/ABtong/Controller/chat/ChatListCell.h → ABtong/ABtong/ALLController/chat/ChatListCell.h


+ 30 - 17
ABtong/ABtong/Controller/chat/ChatListCell.m → ABtong/ABtong/ALLController/chat/ChatListCell.m

@@ -28,6 +28,8 @@
     }
     return self;
 }
+
+
 - (void)fillWithData:( NSDictionary*)data {
     
 //    NSLog(@"fillWithData:%@",data);
@@ -86,29 +88,40 @@
 
 -(NSString *)timeF:(NSInteger)time{
     //NSLog(@"time:%ld",(long)time);
+    //NSLog(@"time:%ld",(long)time);
+    // 创建日期格式器
+    NSDateFormatter *formatter = [[NSDateFormatter alloc] init];
+    [formatter setDateFormat:@"dd"]; // 设置你想要的日期格式
+    
+    
+    long long timestamp =(long)time/1000; // 例如:2021-10-01 00:00:00 UTC
+    // 转换为NSDate
+    NSDate *date = [NSDate dateWithTimeIntervalSince1970:timestamp];
+    NSString *dateString = [formatter stringFromDate:date];
+    
     
-    if(time<=0){
-        return @"";
-    }
     NSDate *now = [NSDate date];
     NSTimeInterval trt = [now timeIntervalSince1970];
-    NSInteger shijiancha = trt-(long)time/1000;
+    date = [NSDate dateWithTimeIntervalSince1970:trt];
+    NSString *tdateString = [formatter stringFromDate:date];
+    
+    
+    NSInteger shijiancha = trt-timestamp;
+    
     if(shijiancha<60){
         return NSLocalizedString(@"time-oneminint", @"");
     }
-    if(shijiancha>24*3600){
-        shijiancha=shijiancha/(24*3600);
-        if(shijiancha>0){
-            NSDate *date = [NSDate dateWithTimeIntervalSince1970:(long)time/1000];
-            // 初始化NSDateFormatter
-            NSDateFormatter *formatter = [[NSDateFormatter alloc] init];
-            // 设置日期格式,例如:"yyyy-MM-dd HH:mm:ss"
-            [formatter setDateFormat:@"yyyy-MM-dd"];
-            // 将日期格式化为字符串
-            NSString *dateString = [formatter stringFromDate:date];
-            return dateString;
-        }
-        return [NSString stringWithFormat:@"%ld%@",(long)shijiancha,NSLocalizedString(@"time-outday", @"")];
+    if(shijiancha>24*3600||dateString.intValue!=tdateString.intValue){
+        // 假设这是你的时间戳(以秒为单位)
+        long long timestamp =(long)time/1000; // 例如:2021-10-01 00:00:00 UTC
+        // 转换为NSDate
+        NSDate *date = [NSDate dateWithTimeIntervalSince1970:timestamp];
+        // 创建日期格式器
+        NSDateFormatter *formatter = [[NSDateFormatter alloc] init];
+        [formatter setDateFormat:@"yyyy-MM-dd HH:mm"]; // 设置你想要的日期格式
+        // 转换为字符串
+        NSString *dateString = [formatter stringFromDate:date];
+        return dateString;
     }
     else{
         NSInteger xiaoshi = shijiancha/3600;

+ 0 - 0
ABtong/ABtong/Controller/chat/ChatListCell.xib → ABtong/ABtong/ALLController/chat/ChatListCell.xib


+ 0 - 0
ABtong/ABtong/Controller/chat/ChatRecordController.h → ABtong/ABtong/ALLController/chat/ChatRecordController.h


+ 0 - 0
ABtong/ABtong/Controller/chat/ChatRecordController.m → ABtong/ABtong/ALLController/chat/ChatRecordController.m


+ 0 - 0
ABtong/ABtong/Controller/chat/MentionTextView.h → ABtong/ABtong/ALLController/chat/MentionTextView.h


+ 0 - 0
ABtong/ABtong/Controller/chat/MentionTextView.m → ABtong/ABtong/ALLController/chat/MentionTextView.m


+ 0 - 0
ABtong/ABtong/Controller/chat/QuoteDetailController.h → ABtong/ABtong/ALLController/chat/QuoteDetailController.h


+ 0 - 0
ABtong/ABtong/Controller/chat/QuoteDetailController.m → ABtong/ABtong/ALLController/chat/QuoteDetailController.m


+ 0 - 0
ABtong/ABtong/Controller/chat/chetCell/ChatAtMemberCell.h → ABtong/ABtong/ALLController/chat/chetCell/ChatAtMemberCell.h


+ 0 - 0
ABtong/ABtong/Controller/chat/chetCell/ChatAtMemberCell.m → ABtong/ABtong/ALLController/chat/chetCell/ChatAtMemberCell.m


+ 0 - 0
ABtong/ABtong/Controller/chat/chetCell/ChatAtMemberView.h → ABtong/ABtong/ALLController/chat/chetCell/ChatAtMemberView.h


+ 0 - 0
ABtong/ABtong/Controller/chat/chetCell/ChatAtMemberView.m → ABtong/ABtong/ALLController/chat/chetCell/ChatAtMemberView.m


+ 0 - 0
ABtong/ABtong/Controller/chat/chetCell/ChatBatchView.h → ABtong/ABtong/ALLController/chat/chetCell/ChatBatchView.h


+ 0 - 0
ABtong/ABtong/Controller/chat/chetCell/ChatBatchView.m → ABtong/ABtong/ALLController/chat/chetCell/ChatBatchView.m


+ 0 - 0
ABtong/ABtong/Controller/chat/chetCell/ChatFileModel.h → ABtong/ABtong/ALLController/chat/chetCell/ChatFileModel.h


+ 0 - 0
ABtong/ABtong/Controller/chat/chetCell/ChatFileModel.m → ABtong/ABtong/ALLController/chat/chetCell/ChatFileModel.m


+ 0 - 0
ABtong/ABtong/Controller/chat/chetCell/ChatLongPressMenuView.h → ABtong/ABtong/ALLController/chat/chetCell/ChatLongPressMenuView.h


+ 0 - 0
ABtong/ABtong/Controller/chat/chetCell/ChatLongPressMenuView.m → ABtong/ABtong/ALLController/chat/chetCell/ChatLongPressMenuView.m


+ 0 - 0
ABtong/ABtong/Controller/chat/chetCell/ChatMessageModel.h → ABtong/ABtong/ALLController/chat/chetCell/ChatMessageModel.h


+ 17 - 4
ABtong/ABtong/Controller/chat/chetCell/ChatMessageModel.m → ABtong/ABtong/ALLController/chat/chetCell/ChatMessageModel.m

@@ -155,17 +155,30 @@
 }
 
 -(NSString *)timeF:(NSInteger)time{
+    //NSLog(@"time:%ld",(long)time);
+    // 创建日期格式器
+    NSDateFormatter *formatter = [[NSDateFormatter alloc] init];
+    [formatter setDateFormat:@"dd"]; // 设置你想要的日期格式
+    
+    
+    long long timestamp =(long)time/1000; // 例如:2021-10-01 00:00:00 UTC
+    // 转换为NSDate
+    NSDate *date = [NSDate dateWithTimeIntervalSince1970:timestamp];
+    NSString *dateString = [formatter stringFromDate:date];
+    
+    
     NSDate *now = [NSDate date];
     NSTimeInterval trt = [now timeIntervalSince1970];
+    date = [NSDate dateWithTimeIntervalSince1970:trt];
+    NSString *tdateString = [formatter stringFromDate:date];
+    
     
-    NSInteger shijiancha = trt-(long)time/1000;
+    NSInteger shijiancha = trt-timestamp;
     
-//    NSLog(@"trt:%f",trt);
-//    NSLog(@"time:%ld",(long)time);
     if(shijiancha<60){
         return NSLocalizedString(@"time-oneminint", @"");
     }
-    if(shijiancha>24*3600){
+    if(shijiancha>24*3600||dateString.intValue!=tdateString.intValue){
         // 假设这是你的时间戳(以秒为单位)
         long long timestamp =(long)time/1000; // 例如:2021-10-01 00:00:00 UTC
         // 转换为NSDate

+ 0 - 0
ABtong/ABtong/Controller/chat/chetCell/ChatPopoverView.h → ABtong/ABtong/ALLController/chat/chetCell/ChatPopoverView.h


+ 0 - 0
ABtong/ABtong/Controller/chat/chetCell/ChatPopoverView.m → ABtong/ABtong/ALLController/chat/chetCell/ChatPopoverView.m


+ 0 - 0
ABtong/ABtong/Controller/chat/chetCell/ChatQuoteView.h → ABtong/ABtong/ALLController/chat/chetCell/ChatQuoteView.h


+ 0 - 0
ABtong/ABtong/Controller/chat/chetCell/ChatQuoteView.m → ABtong/ABtong/ALLController/chat/chetCell/ChatQuoteView.m


+ 0 - 0
ABtong/ABtong/Controller/chat/chetCell/chatCellView.h → ABtong/ABtong/ALLController/chat/chetCell/chatCellView.h


+ 5 - 4
ABtong/ABtong/Controller/chat/chetCell/chatCellView.m → ABtong/ABtong/ALLController/chat/chetCell/chatCellView.m

@@ -1275,15 +1275,16 @@ static const CGFloat kMediaCornerRadius = 4.0f;
 }
 
 - (NSString *)formatTimeWithMilliseconds:(NSInteger)milliseconds{
-    CGFloat seconds = milliseconds / 1000.0;
+    NSInteger seconds = milliseconds / 1000.0;
         
     if (seconds >= 60) {
         // 大于等于60秒时显示为分钟,保留一位小数
-        CGFloat minutes = seconds / 60.0;
-        return [NSString stringWithFormat:@"%.1f分钟", minutes];
+        NSInteger minutes = seconds / 60.0;
+        NSInteger sc = seconds%60;
+        return [NSString stringWithFormat:@"%ld分%ld秒", (long)minutes,(long)sc];
     } else {
         // 小于60秒时显示为秒,保留整数
-        return [NSString stringWithFormat:@"%.0f秒", seconds];
+        return [NSString stringWithFormat:@"%ld秒", seconds];
     }
 }
 

+ 0 - 0
ABtong/ABtong/Controller/chat/chetCell/chatpopView.h → ABtong/ABtong/ALLController/chat/chetCell/chatpopView.h


+ 0 - 0
ABtong/ABtong/Controller/chat/chetCell/chatpopView.m → ABtong/ABtong/ALLController/chat/chetCell/chatpopView.m


+ 0 - 0
ABtong/ABtong/Controller/chat/chetCell/chatpopView.xib → ABtong/ABtong/ALLController/chat/chetCell/chatpopView.xib


+ 0 - 0
ABtong/ABtong/Controller/friend/EXFriendController.h → ABtong/ABtong/ALLController/friend/EXFriendController.h


+ 0 - 0
ABtong/ABtong/Controller/friend/EXFriendController.m → ABtong/ABtong/ALLController/friend/EXFriendController.m


+ 0 - 0
ABtong/ABtong/Controller/friend/EXFriendListCell.h → ABtong/ABtong/ALLController/friend/EXFriendListCell.h


+ 0 - 0
ABtong/ABtong/Controller/friend/EXFriendListCell.m → ABtong/ABtong/ALLController/friend/EXFriendListCell.m


+ 0 - 0
ABtong/ABtong/Controller/friend/ForwardViewController.h → ABtong/ABtong/ALLController/friend/ForwardViewController.h


+ 0 - 0
ABtong/ABtong/Controller/friend/ForwardViewController.m → ABtong/ABtong/ALLController/friend/ForwardViewController.m


+ 0 - 0
ABtong/ABtong/Controller/friend/FriendController.h → ABtong/ABtong/ALLController/friend/FriendController.h


+ 0 - 0
ABtong/ABtong/Controller/friend/FriendController.m → ABtong/ABtong/ALLController/friend/FriendController.m


+ 0 - 0
ABtong/ABtong/Controller/friend/FriendListCell.h → ABtong/ABtong/ALLController/friend/FriendListCell.h


+ 0 - 0
ABtong/ABtong/Controller/friend/FriendListCell.m → ABtong/ABtong/ALLController/friend/FriendListCell.m


+ 0 - 0
ABtong/ABtong/Controller/friend/FriendListController.h → ABtong/ABtong/ALLController/friend/FriendListController.h


+ 19 - 1
ABtong/ABtong/Controller/friend/FriendListController.m → ABtong/ABtong/ALLController/friend/FriendListController.m

@@ -13,6 +13,8 @@
 #import "FriendController.h"
 #import "EXFriendController.h"
 #import "addFriendController.h"
+#import "GLoginController.h"
+#import "LoginStateManager.h"
 
 @interface FriendListController()<UITableViewDelegate,UITableViewDataSource>
 
@@ -131,6 +133,10 @@
 
 
 -(void)gotoexFriend{
+    if(!LoginStateManager.sharedManager.isLoggedIn){
+        [self gotoLoginView];
+        return;
+    }
     UIStoryboard *board = [UIStoryboard storyboardWithName:@"Main" bundle:[NSBundle mainBundle]];
     EXFriendController *friendctr = [board instantiateViewControllerWithIdentifier:@"EXFriendController"];
     UINavigationController *uiNavC = [[UINavigationController alloc] initWithRootViewController:friendctr];
@@ -140,7 +146,10 @@
 
 
 - (IBAction)addNewFriend:(id)sender {
-    
+    if(!LoginStateManager.sharedManager.isLoggedIn){
+        [self gotoLoginView];
+        return;
+    }
     UIStoryboard *board = [UIStoryboard storyboardWithName:@"Main" bundle:[NSBundle mainBundle]];
     addFriendController *addfriendctr = [board instantiateViewControllerWithIdentifier:@"addFriendController"];
     UINavigationController *uiNavC = [[UINavigationController alloc] initWithRootViewController:addfriendctr];
@@ -221,4 +230,13 @@
 }
 
 
+-(void)gotoLoginView{
+    UIStoryboard *board = [UIStoryboard storyboardWithName:@"Main" bundle:[NSBundle mainBundle]];
+    GLoginController *login = [board instantiateViewControllerWithIdentifier:@"LoginController"];
+    UINavigationController *uiNavC = [[UINavigationController alloc] initWithRootViewController:login];
+    uiNavC.modalPresentationStyle = UIModalPresentationFullScreen;
+    [self presentViewController:uiNavC animated:YES completion:nil];
+}
+
+
 @end

+ 0 - 0
ABtong/ABtong/Controller/friend/ReportViewController.h → ABtong/ABtong/ALLController/friend/ReportViewController.h


+ 0 - 0
ABtong/ABtong/Controller/friend/ReportViewController.m → ABtong/ABtong/ALLController/friend/ReportViewController.m


+ 0 - 0
ABtong/ABtong/Controller/friend/addFriendController.h → ABtong/ABtong/ALLController/friend/addFriendController.h


+ 0 - 0
ABtong/ABtong/Controller/friend/addFriendController.m → ABtong/ABtong/ALLController/friend/addFriendController.m


+ 0 - 0
ABtong/ABtong/Controller/group/GroupController.h → ABtong/ABtong/ALLController/group/GroupController.h


+ 0 - 0
ABtong/ABtong/Controller/group/GroupController.m → ABtong/ABtong/ALLController/group/GroupController.m


+ 0 - 0
ABtong/ABtong/Controller/group/GroupEditController.h → ABtong/ABtong/ALLController/group/GroupEditController.h


+ 0 - 0
ABtong/ABtong/Controller/group/GroupEditController.m → ABtong/ABtong/ALLController/group/GroupEditController.m


+ 0 - 0
ABtong/ABtong/Controller/group/GroupGonggaoController.h → ABtong/ABtong/ALLController/group/GroupGonggaoController.h


+ 0 - 0
ABtong/ABtong/Controller/group/GroupGonggaoController.m → ABtong/ABtong/ALLController/group/GroupGonggaoController.m


+ 0 - 0
ABtong/ABtong/Controller/group/GroupListCell.h → ABtong/ABtong/ALLController/group/GroupListCell.h


+ 0 - 0
ABtong/ABtong/Controller/group/GroupListCell.m → ABtong/ABtong/ALLController/group/GroupListCell.m


+ 0 - 0
ABtong/ABtong/Controller/group/GroupListController.h → ABtong/ABtong/ALLController/group/GroupListController.h


+ 0 - 0
ABtong/ABtong/Controller/group/GroupListController.m → ABtong/ABtong/ALLController/group/GroupListController.m


+ 0 - 0
ABtong/ABtong/Controller/group/NewGroupController.h → ABtong/ABtong/ALLController/group/NewGroupController.h


+ 0 - 0
ABtong/ABtong/Controller/group/NewGroupController.m → ABtong/ABtong/ALLController/group/NewGroupController.m


+ 0 - 0
ABtong/ABtong/Controller/group/groupstory.storyboard → ABtong/ABtong/ALLController/group/groupstory.storyboard


+ 0 - 0
ABtong/ABtong/Controller/login/APPLockView.h → ABtong/ABtong/ALLController/login/APPLockView.h


+ 1 - 1
ABtong/ABtong/Controller/login/APPLockView.m → ABtong/ABtong/ALLController/login/APPLockView.m

@@ -252,7 +252,7 @@
             if([gcode intValue]==200){
                 NSLog(@"ps:%@",ps);
                 [UDManager.shareInstance setDDManager:ps key:dkuserinfo];
-                
+                [UDManager.shareInstance setSDManager:ps[@"id"] key:dkuserId];
                 [[NSNotificationCenter defaultCenter] postNotificationName: nkonLoginSucc object:nil];
                 [self hide];
             }

+ 0 - 0
ABtong/ABtong/Controller/login/GCoverController.h → ABtong/ABtong/ALLController/login/GCoverController.h


+ 0 - 0
ABtong/ABtong/Controller/login/GCoverController.m → ABtong/ABtong/ALLController/login/GCoverController.m


+ 0 - 1
ABtong/ABtong/Controller/login/GLoginController.h → ABtong/ABtong/ALLController/login/GLoginController.h

@@ -9,5 +9,4 @@
 
 @interface GLoginController : UIViewController
 
-
 @end

+ 100 - 13
ABtong/ABtong/Controller/login/GLoginController.m → ABtong/ABtong/ALLController/login/GLoginController.m

@@ -13,15 +13,22 @@
 #import <AdSupport/AdSupport.h>
 #import "FilePreviewer.h"
 #import "GCoverController.h"
+#import "GserverListController.h"
+#import "LoginStateManager.h"
+#import "GDBManager.h"
+#import "GWebSocket.h"
 
 @interface GLoginController ()
 
+
+@property (weak, nonatomic) IBOutlet UILabel *severIP;
+@property (weak, nonatomic) IBOutlet UITextField *inputIP;
+
+
 @property (weak, nonatomic) IBOutlet UITextField *userId;
 @property (weak, nonatomic) IBOutlet UITextField *password;
 @property (weak, nonatomic) IBOutlet UIButton *loginBt;
 @property (weak, nonatomic) IBOutlet UIButton *wangjiBt;
-@property (weak, nonatomic) IBOutlet UIButton *signBt;
-@property (weak, nonatomic) IBOutlet UILabel *meiyouzhlb;
 @property (weak, nonatomic) IBOutlet UIButton *agreedBt;
 
 @property (nonatomic)  BOOL isagreed;
@@ -48,12 +55,46 @@
         }
     }
     [self initsubView];
-    
     [self getUserinfo];
+    [[GWebSocket shareInstance] closeWebSocket];
+}
+- (IBAction)gotoBack:(id)sender {
+    [self dismissViewControllerAnimated:YES completion:nil];
+}
+
+
+-(void)viewDidAppear:(BOOL)animated{
+    [super viewDidAppear:animated];
+    NSDictionary *actuserInfo = [UDManager.shareInstance getDDManager:nkactuserInfo];
+    NSLog(@"actuserInfo:%@",actuserInfo);
+    if(actuserInfo){
+        
+        _inputIP.text =actuserInfo[@"serverIP"]?:@"";
+        _userId.text =actuserInfo[@"userName"]?:@"";
+        _password.text =actuserInfo[@"passWord"]?:@"";
+    }
+    
 }
 
 
+
 -(void)initsubView{
+    
+    
+    _inputIP.borderStyle=UITextBorderStyleNone;
+    _inputIP.layer.borderWidth = 1.0f;
+    _inputIP.layer.borderColor = globalColor(GCTypeGreen).CGColor; //globalColor(GCTypeGreen);
+    _inputIP.layer.cornerRadius = 8.0f; // 可选,设置圆角
+    _inputIP.backgroundColor = [UIColor clearColor];
+    _inputIP.textColor=[UIColor whiteColor];
+    NSString *note1 = @"请选择服务器地址";
+    NSMutableAttributedString *placeholder3 = [[NSMutableAttributedString alloc] initWithString:note1 attributes:@{NSForegroundColorAttributeName: [UIColor lightGrayColor]}];
+    UIView *paddingView3 = [[UIView alloc] initWithFrame:CGRectMake(0, 0, 10, 0)];
+    _inputIP.leftView = paddingView3;
+    _inputIP.leftViewMode = UITextFieldViewModeAlways;
+    _inputIP.attributedPlaceholder = placeholder3;
+    
+    
     _userId.borderStyle=UITextBorderStyleNone;
     _userId.layer.borderWidth = 1.0f;
     _userId.layer.borderColor = globalColor(GCTypeGreen).CGColor; //globalColor(GCTypeGreen);
@@ -93,10 +134,7 @@
     _wangjiBt.titleLabel.font = [UIFont systemFontOfSize: 14.0];
     [_wangjiBt setTitleColor:globalColor(GCTypeGreen) forState:UIControlStateNormal];
     [_wangjiBt setTitle:NSLocalizedString(@"login-wangjimm", @"忘记密码?") forState:UIControlStateNormal];
-    _signBt.titleLabel.font = [UIFont systemFontOfSize: 14.0];
-    [_signBt setTitleColor:globalColor(GCTypeGreen) forState:UIControlStateNormal];
-    [_signBt setTitle:NSLocalizedString(@"login-quzhuce", @"去注册") forState:UIControlStateNormal];
-    _meiyouzhlb.text =NSLocalizedString(@"login-meiyouzh", @"没有账号?");
+
     
     if(_isagreed){
         [_agreedBt setImage:kImageMake(@"checkbox_selected") forState:UIControlStateNormal];
@@ -152,9 +190,21 @@
         return;
     }
     
+    
+    
+    
     [self.view endEditing:YES];
+    NSString *httphost =self.inputIP.text;
     NSString *userid = self.userId.text;
     NSString *password = self.password.text;
+    
+    if(httphost.length==0||userid.length==0||password==0){
+        [MBProgressHUD showWithText:NSLocalizedString(@"fill-complete", @"")];
+        return;
+    }
+    
+    [UDManager.shareInstance setSDManager:httphost key:nkhttphost];
+    
     NSDictionary *ps = @{@"username": userid,
                          @"password": password,
                          @"code": @"",
@@ -176,6 +226,18 @@
         if(token){
             [UDManager.shareInstance setSDManager:res[@"token"] key:gkeytoken];
             [UDManager.shareInstance setSDManager:userid key:dkuserloginId];
+            
+            NSDictionary *actuserInfo = [UDManager.shareInstance getDDManager:nkactuserInfo];
+            NSMutableDictionary *Dict = [NSMutableDictionary dictionaryWithDictionary:actuserInfo];
+            [Dict setObject:token forKey:@"token"];
+            [Dict setObject:res[@"serverId"]?:@"" forKey:@"serverId"];
+            [Dict setObject:password forKey:@"passWord"];
+            [Dict setObject:userid forKey:@"userName"];
+            
+            actuserInfo = [Dict copy];
+            [UDManager.shareInstance setDDManager:actuserInfo key:nkactuserInfo];
+            [GDBManager.shareInstance updataUserServer:actuserInfo succ:nil fail:nil];
+            
             [self getUserinfo];
         }
     } fail:^(NSError * _Nonnull error) {
@@ -192,13 +254,16 @@
     resetPwdVc.modalPresentationStyle = UIModalPresentationFullScreen;
     [self presentViewController:resetPwdVc animated:YES completion:nil];
 }
-- (IBAction)sign:(id)sender {
+
+- (IBAction)moreIPBt:(id)sender {
+    
+    GserverListController * resetPwdVc = [[GserverListController alloc] init];
+    resetPwdVc.modalPresentationStyle = UIModalPresentationFullScreen;
+    resetPwdVc.canChange = false;
+    UINavigationController * navi = [[UINavigationController alloc] initWithRootViewController:resetPwdVc];
+    navi.modalPresentationStyle = UIModalPresentationFullScreen;
+    [self presentViewController:navi animated:YES completion:nil];
     
-    UIStoryboard *board = [UIStoryboard storyboardWithName:@"Main" bundle:[NSBundle mainBundle]];
-    GSignController *chatctr = [board instantiateViewControllerWithIdentifier:@"GSignController"];
-    UINavigationController *uiNavC = [[UINavigationController alloc] initWithRootViewController:chatctr];
-    uiNavC.modalPresentationStyle = UIModalPresentationFullScreen;
-    [self presentViewController :uiNavC animated:YES completion:nil];
 }
 
 
@@ -237,8 +302,17 @@
             if([gcode intValue]==200){
                 NSLog(@"ps:%@",ps);
                 [MBProgressHUD showWithText:@"登录成功"];
+                [[LoginStateManager sharedManager] setloginState:YES];
                 [UDManager.shareInstance setSDManager:ps[@"id"] key:dkuserId];
                 [UDManager.shareInstance setDDManager:ps key:dkuserinfo];
+                
+                NSDictionary *actuserInfo = [UDManager.shareInstance getDDManager:nkactuserInfo];
+                NSMutableDictionary *Dict = [NSMutableDictionary dictionaryWithDictionary:actuserInfo];
+                [Dict setObject:ps[@"id"]?:@"" forKey:@"userId"];
+                actuserInfo = [Dict copy];
+                [UDManager.shareInstance setDDManager:actuserInfo key:nkactuserInfo];
+                [GDBManager.shareInstance updataUserServer:actuserInfo succ:nil fail:nil];
+                
                 [[NSNotificationCenter defaultCenter] postNotificationName: nkonLoginSucc object:nil];
             }
             
@@ -261,8 +335,21 @@
 }
 
 - (IBAction)yinsizhengc:(id)sender {
+    
+    UIStoryboard *board = [UIStoryboard storyboardWithName:@"Main" bundle:[NSBundle mainBundle]];
+    GSignController *chatctr = [board instantiateViewControllerWithIdentifier:@"GSignController"];
+    UINavigationController *uiNavC = [[UINavigationController alloc] initWithRootViewController:chatctr];
+    uiNavC.modalPresentationStyle = UIModalPresentationFullScreen;
+    [self presentViewController :uiNavC animated:YES completion:nil];
+    return;
+    
     [[FilePreviewer shared] previewFileWithLocalPath:@"" remoteURL:getURL(privacyPolicy) fromViewController:self];
 }
 
 
+-(void)updataUserServerInfo{
+    
+}
+
+
 @end

+ 0 - 0
ABtong/ABtong/Controller/login/GSignController.h → ABtong/ABtong/ALLController/login/GSignController.h


+ 0 - 0
ABtong/ABtong/Controller/login/GSignController.m → ABtong/ABtong/ALLController/login/GSignController.m


+ 23 - 0
ABtong/ABtong/ALLController/login/GserverListCell.h

@@ -0,0 +1,23 @@
+//
+//  GserverListCell.h
+//  ABtong
+//
+//  Created by gan on 2025/7/31.
+//
+
+#ifndef GserverListCell_h
+#define GserverListCell_h
+#import <UIKit/UIKit.h>
+#import <Foundation/Foundation.h>
+
+
+@interface GserverListCell : UITableViewCell
+
+@property(nonatomic, strong) UILabel *name;
+@property(nonatomic, strong) UILabel *sever;
+@property(nonatomic, strong) UILabel *userLb;
+- (void)fillWithData:( NSDictionary*)data;
+
+@end
+
+#endif /* GserverListCell_h */

+ 86 - 0
ABtong/ABtong/ALLController/login/GserverListCell.m

@@ -0,0 +1,86 @@
+//
+//  GserverListCell.m
+//  ABtong
+//
+//  Created by gan on 2025/7/31.
+//
+
+#import <Foundation/Foundation.h>
+#import "GserverListCell.h"
+
+
+@implementation GserverListCell
+
+
+- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
+    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
+    if (self) {
+        [self setupViews];
+    }
+    return self;
+}
+
+- (void)setupViews {
+   
+    
+    _name = [[UILabel alloc] init];
+    _name.backgroundColor=[UIColor clearColor];
+    [_name setFont:[UIFont boldSystemFontOfSize:20]];
+    [_name setTextColor:[UIColor whiteColor]];
+    [self.contentView addSubview:_name];
+    _sever = [[UILabel alloc] init];
+    _sever.frame=CGRectMake(68, 8, 250, 50);
+    _sever.backgroundColor=[UIColor clearColor];
+    [_sever setFont:[UIFont boldSystemFontOfSize:18]];
+    [_sever setTextColor:[UIColor whiteColor]];
+    [self.contentView addSubview:_sever];
+    
+    _userLb = [[UILabel alloc] init];
+    _userLb.frame=CGRectMake(68, 8, 250, 50);
+    _userLb.backgroundColor=[UIColor clearColor];
+    [_userLb setFont:[UIFont boldSystemFontOfSize:18]];
+    [_userLb setTextColor:globalColor(GCTypeOrangeR)];
+    [self.contentView addSubview:_userLb];
+
+    
+    
+}
+
+- (void)fillWithData:( NSDictionary*)data {
+    
+    NSLog(@"fillWithData:%@",data);
+   
+    [self.name mas_makeConstraints:^(MASConstraintMaker *make) {
+        make.left.mas_equalTo(15);
+        make.top.mas_equalTo(5);
+        make.width.mas_equalTo(200);
+        make.height.mas_equalTo(30);
+    }];
+    
+    [self.sever mas_makeConstraints:^(MASConstraintMaker *make) {
+        make.left.mas_equalTo(15);
+        make.top.mas_equalTo(self.name.mas_bottom).offset(2);
+        make.width.mas_equalTo(200);
+        make.height.mas_equalTo(30);
+    }];
+    
+    [self.userLb mas_makeConstraints:^(MASConstraintMaker *make) {
+        make.left.mas_equalTo(15);
+        make.top.mas_equalTo(self.sever.mas_bottom).offset(2);
+        make.width.mas_equalTo(200);
+        make.height.mas_equalTo(30);
+    }];
+    
+    self.name.text = data[@"serverName"];
+    self.sever.text = data[@"serverIP"];
+    self.userLb.text = [NSString stringWithFormat:@"账号%@",data[@"userName"]];
+    // tell constraints they need updating
+    [self setNeedsUpdateConstraints];
+
+    // update constraints now so we can animate the change
+    [self updateConstraintsIfNeeded];
+
+    [self layoutIfNeeded];
+}
+
+@end

+ 19 - 0
ABtong/ABtong/ALLController/login/GserverListController.h

@@ -0,0 +1,19 @@
+//
+//  GserverListController.h
+//  ABtong
+//
+//  Created by gan on 2025/7/29.
+//
+
+#ifndef GserverListController_h
+#define GserverListController_h
+
+#import <UIKit/UIKit.h>
+
+@interface GserverListController : UIViewController
+
+@property (nonatomic,assign) BOOL canChange;
+
+@end
+
+#endif /* GserverListController_h */

+ 222 - 0
ABtong/ABtong/ALLController/login/GserverListController.m

@@ -0,0 +1,222 @@
+//
+//  GserverListController.m
+//  ABtong
+//
+//  Created by gan on 2025/7/29.
+//
+
+#import <Foundation/Foundation.h>
+#import "GserverListController.h"
+#import "ServerIPInputView.h"
+#import "GDBManager.h"
+#import "GserverListCell.h"
+#import "LoginStateManager.h"
+
+@interface GserverListController()<UITableViewDelegate,UITableViewDataSource,ServerIPInputViewDelegate>
+
+@property (nonatomic, strong) UIImageView * bgImageView;
+@property (nonatomic, strong) UITableView  * tableView;
+
+@property (nonatomic, strong) ServerIPInputView  * serverV;
+
+@property (nonatomic, strong) NSArray  * serverArray;
+
+
+
+@end
+
+@implementation GserverListController
+
+
+-(void)viewDidLoad{
+    [super viewDidLoad];
+    
+    [self setNavigationTitle:@"服务器列表"];
+    [self setNavigationBarTransparent:YES];
+    [self setNavigationBarBackgroundColor:UIColor.clearColor];
+    [self setNavigationTitleColor:UIColor.whiteColor font:SYSBFONT(18)];
+    [self addBarButtonWithImage:kImageMake(@"fanhui") position:BarButtonItemPositionLeft action:@selector(backToChat)];
+    [self addBarButtonWithImage:kImageMake(@"Cjiahao") position:BarButtonItemPositionRight action:@selector(addServer)];
+    
+    [self.view addSubview:self.bgImageView];
+    [self.bgImageView mas_makeConstraints:^(MASConstraintMaker *make) {
+        make.left.right.top.bottom.mas_equalTo(0);
+    }];
+    
+    [self.view addSubview:self.tableView];
+    [self.tableView mas_makeConstraints:^(MASConstraintMaker *make) {
+        make.left.right.bottom.mas_equalTo(0);
+        make.top.mas_equalTo(SCREEN_TOP);
+    }];
+    NSArray *nibs = [[NSBundle mainBundle] loadNibNamed:@"serverIpinputV" owner:self options:nil];
+    _serverV = [nibs objectAtIndex:0];
+    [self.view addSubview:_serverV];
+    _serverV.delegate= self;
+    [self hidServerView];
+    [self.view bringSubviewToFront:_serverV];
+    
+}
+
+-(void)viewDidAppear:(BOOL)animated{
+    [super viewDidAppear:animated];
+    [self loadData];
+}
+
+-(void)loadData{
+    
+    [GDBManager.shareInstance selectAlllcUserServer:^(NSArray * _Nullable array) {
+        if(array.count>0){
+            NSLog(@"UserServer:%@",array);
+            self->_serverArray = array.copy;
+            [self->_tableView reloadData];
+        }
+        else{
+            self->_serverArray = @[];
+            [self->_tableView reloadData];
+        }
+    } fail:^(NSString * _Nullable error) {
+        NSLog(@"%@",error);
+    }];
+    
+}
+
+#pragma mark lazy
+- (UIImageView *)bgImageView{
+    if (!_bgImageView) {
+        _bgImageView = [[UIImageView alloc] initWithImage:kImageMake(@"loginBG")];
+    }
+    return _bgImageView;
+}
+
+
+- (UITableView *)tableView{
+    if (!_tableView) {
+        _tableView = [[UITableView alloc] initWithFrame:CGRectZero style:UITableViewStylePlain];
+        _tableView.backgroundColor = UIColor.clearColor;
+        _tableView.delegate = self;
+        _tableView.dataSource = self;
+        [_tableView registerClass:GserverListCell.class forCellReuseIdentifier:@"cellT"];
+    }
+    return _tableView;
+}
+
+-(void)backToChat{
+    [self dismissViewControllerAnimated:YES completion:nil];
+}
+
+-(void)addServer{
+    [self showServerView];
+}
+
+-(void)actionNote:(NSString *)note{
+    [self hidServerView];
+    [self loadData];
+}
+
+-(void)hidServerView{
+    CGRect popfram = CGRectMake(0-self.view.frame.size.width,0, self.view.frame.size.width, self.view.frame.size.height);
+    _serverV.frame = popfram;
+    _serverV.frame=popfram;
+    
+    [self.view endEditing:YES];
+}
+
+-(void)showServerView{
+    _serverV.frame = self.view.frame;
+    CGRect popfram = CGRectMake(0,0, self.view.frame.size.width, self.view.frame.size.height);
+    _serverV.frame = popfram;
+    [_serverV setViewContent];
+}
+
+
+#pragma mark tableview delegate
+- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView{
+    return 1;
+}
+
+- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section{
+    return _serverArray.count;
+}
+
+
+
+- (UIView *)tableView:(UITableView *)tableView viewForFooterInSection:(NSInteger)section{
+    return nil;
+}
+
+-(CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath{
+    return 100;
+}
+
+- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath{
+   
+    NSString *cellT =@"cellT";
+    
+    GserverListCell *cell =[tableView dequeueReusableCellWithIdentifier:cellT forIndexPath:indexPath];
+    
+    if(cell==nil){
+        cell=[[GserverListCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:cellT];
+    }
+    cell.backgroundColor = [UIColor clearColor];
+    NSDictionary *item = [_serverArray objectAtIndex:indexPath.row];
+    
+    [cell fillWithData:item];
+    
+    cell.contentView.layer.borderWidth = 0.5f;
+    cell.contentView.layer.borderColor = [UIColor lightGrayColor].CGColor; //globalColor(GCTypeGreen);
+    cell.contentView.layer.cornerRadius = 8.0f; // 可选,设置圆角
+    
+    return cell;
+}
+
+
+- (UISwipeActionsConfiguration *)tableView:(UITableView *)tableView trailingSwipeActionsConfigurationForRowAtIndexPath:(NSIndexPath *)indexPath {
+    weakSelf(self);
+    NSInteger index=indexPath.row;
+    // 创建删除操作
+    UIContextualAction *deleteAction = [UIContextualAction contextualActionWithStyle:UIContextualActionStyleDestructive
+                                                                               title:@"删除"
+                                                                             handler:^(UIContextualAction * _Nonnull action, __kindof UIView * _Nonnull sourceView, void (^ _Nonnull completionHandler)(BOOL)) {
+        
+        // 删除聊天
+        [weakself deleteChatWith:index];
+        // 告诉系统操作已完成
+        completionHandler(YES);
+    }];
+    
+    // 设置删除按钮颜色
+    deleteAction.backgroundColor = [UIColor redColor];
+    
+    // 创建配置并返回
+    UISwipeActionsConfiguration *config = [UISwipeActionsConfiguration configurationWithActions:@[deleteAction]];
+    config.performsFirstActionWithFullSwipe = YES; // 完全滑动直接执行删除
+    return config;
+}
+
+-(void)deleteChatWith:(NSInteger)index{
+    NSDictionary *item = [_serverArray objectAtIndex:index];
+    NSString *sid = item[@"id"]?:@"";
+    [GDBManager.shareInstance deleteUserServer:sid succ:^(NSArray * _Nullable array) {
+        // 更新数据
+        [self loadData];
+    } fail:^(NSString * _Nullable error) {
+        [MBProgressHUD showWithText:NSLocalizedString(@"AppLock_fail", @"")];
+    }];
+}
+
+- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath{
+    NSLog(@"1111");
+    NSDictionary *item = [_serverArray objectAtIndex:indexPath.row];
+    [UDManager.shareInstance setDDManager:item key:nkactuserInfo];
+    
+    if(_canChange){
+        [UDManager.shareInstance setSDManager:item[@"serverIP"] key:nkhttphost];
+        [UDManager.shareInstance setSDManager:item[@"token"] key:gkeytoken];
+        [UDManager.shareInstance setSDManager:item[@"userName"] key:dkuserloginId];
+        [LoginStateManager.sharedManager changeServerToLogin:item];
+    }
+    
+    [self dismissViewControllerAnimated:YES completion:nil];
+}
+
+@end

Algunos archivos no se mostraron porque demasiados archivos cambiaron en este cambio