Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
galaxy-iOS
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
mobile-group
galaxy-iOS
Commits
e9eb8d51
Commit
e9eb8d51
authored
Mar 17, 2025
by
Steven杜宇
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
// lint
parent
87fa4d4a
Changes
22
Hide whitespace changes
Inline
Side-by-side
Showing
22 changed files
with
122 additions
and
43 deletions
+122
-43
YHAIMainChatViewController.swift
...s/AI/AI-Dialogue(AI对话)/C/YHAIMainChatViewController.swift
+18
-6
YHAIRequestManager.swift
...s/Modules/AI/AI-Dialogue(AI对话)/C/YHAIRequestManager.swift
+10
-5
YHAIRobotChatViewController.swift
.../AI/AI-Dialogue(AI对话)/C/YHAIRobotChatViewController.swift
+19
-6
YHAIServiceListViewController.swift
...I/AI-Dialogue(AI对话)/C/YHAIServiceListViewController.swift
+6
-2
YHAITabViewController.swift
...odules/AI/AI-Dialogue(AI对话)/C/YHAITabViewController.swift
+4
-1
YHAIMessageModel.swift
...ses/Modules/AI/AI-Dialogue(AI对话)/M/YHAIMessageModel.swift
+3
-1
YHAIChatBannerView.swift
...s/Modules/AI/AI-Dialogue(AI对话)/V/YHAIChatBannerView.swift
+6
-2
YHAppleLoginManager.swift
...sses/Modules/AppleLogin(苹果登录)/M/YHAppleLoginManager.swift
+6
-2
YHActivityDetailViewController.swift
...y(社区)/Activity(活动)/C/YHActivityDetailViewController.swift
+12
-4
YHApplyActivityAlert.swift
...s/Community(社区)/Activity(活动)/V/YHApplyActivityAlert.swift
+2
-2
YHActivityViewModel.swift
...s/Community(社区)/Activity(活动)/VM/YHActivityViewModel.swift
+1
-1
YHCommunityViewController.swift
...s/Modules/Community(社区)/C/YHCommunityViewController.swift
+4
-1
YHMatchResultListViewController.swift
...les/Community(社区)/C/YHMatchResultListViewController.swift
+3
-1
YHMyInterestTopicCell.swift
...asses/Modules/Community(社区)/V/YHMyInterestTopicCell.swift
+3
-1
YHHomeHoldViewPageViewController.swift
...Modules/Home(首页)/C/YHHomeHoldViewPageViewController.swift
+4
-1
YHHomeIdentityListVC.swift
...axy/Classes/Modules/Home(首页)/C/YHHomeIdentityListVC.swift
+3
-1
YHHomeIdentityViewController.swift
...ses/Modules/Home(首页)/C/YHHomeIdentityViewController.swift
+3
-1
YHHomeInfoDetailContainerViewController.swift
.../Home(首页)/C/YHHomeInfoDetailContainerViewController.swift
+4
-1
YHHomeInfoDetailViewController.swift
...s/Modules/Home(首页)/C/YHHomeInfoDetailViewController.swift
+3
-1
YHHomeInformationViewController.swift
.../Modules/Home(首页)/C/YHHomeInformationViewController.swift
+3
-1
YHHomePageViewController.swift
...Classes/Modules/Home(首页)/C/YHHomePageViewController.swift
+1
-1
YHMyViewController.swift
...alaxy/Classes/Modules/Mine(我的)/C/YHMyViewController.swift
+4
-1
No files found.
galaxy/galaxy/Classes/Modules/AI/AI-Dialogue(AI对话)/C/YHAIMainChatViewController.swift
View file @
e9eb8d51
...
...
@@ -270,12 +270,16 @@ extension YHAIMainChatViewController: UITableViewDelegate, UITableViewDataSource
let
msg
=
messages
[
indexPath
.
row
]
let
msgType
=
msg
.
getType
()
if
msgType
==
.
text
{
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHAITextMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHAITextMessageCell
guard
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHAITextMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHAITextMessageCell
else
{
return
UITableViewCell
()
}
cell
.
message
=
msg
return
cell
}
else
if
msgType
==
.
recommendText
{
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHRecommendTextMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHRecommendTextMessageCell
guard
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHRecommendTextMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHRecommendTextMessageCell
else
{
return
UITableViewCell
()
}
cell
.
message
=
msg
cell
.
messageClick
=
{
[
weak
self
]
text
in
...
...
@@ -293,11 +297,15 @@ extension YHAIMainChatViewController: UITableViewDelegate, UITableViewDataSource
return
cell
}
else
if
msgType
==
.
thinking
{
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHAIThinkingMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHAIThinkingMessageCell
guard
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHAIThinkingMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHAIThinkingMessageCell
else
{
return
UITableViewCell
()
}
return
cell
}
else
if
msgType
==
.
productList
{
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHProductListMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHProductListMessageCell
guard
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHProductListMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHProductListMessageCell
else
{
return
UITableViewCell
()
}
if
let
listModel
=
msg
.
body
.
cardsInfo
{
cell
.
listModel
=
listModel
}
...
...
@@ -305,7 +313,9 @@ extension YHAIMainChatViewController: UITableViewDelegate, UITableViewDataSource
}
else
if
msgType
==
.
cardList
{
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHCardMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHCardMessageCell
guard
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHCardMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHCardMessageCell
else
{
return
UITableViewCell
()
}
if
let
listModel
=
msg
.
body
.
cardsInfo
{
cell
.
cardListModel
=
listModel
cell
.
evaluationResultCallback
=
{
...
...
@@ -345,7 +355,9 @@ extension YHAIMainChatViewController: UITableViewDelegate, UITableViewDataSource
return
cell
}
else
if
msgType
==
.
picture
{
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHAIPictureMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHAIPictureMessageCell
guard
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHAIPictureMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHAIPictureMessageCell
else
{
return
UITableViewCell
()
}
if
let
imgInfo
=
msg
.
body
.
imageInfo
{
cell
.
imgInfo
=
imgInfo
}
...
...
galaxy/galaxy/Classes/Modules/AI/AI-Dialogue(AI对话)/C/YHAIRequestManager.swift
View file @
e9eb8d51
...
...
@@ -77,9 +77,11 @@ class YHAIRequestManager: NSObject {
self
.
uuid
=
UUID
()
.
uuidString
+
NSDate
()
.
timeIntervalSince1970
.
description
// body 请求体参数
let
parameters
=
[
"botId"
:
botId
,
"conversationId"
:
conversationId
,
"question"
:
question
]
as!
[
String
:
Any
]
guard
let
parameters
=
[
"botId"
:
botId
,
"conversationId"
:
conversationId
,
"question"
:
question
]
as?
[
String
:
Any
]
else
{
return
}
print
(
"AI QUESTION PARAM:
\(
parameters
)
"
)
let
headers
=
self
.
getCommonHeaders
()
...
...
@@ -147,8 +149,11 @@ class YHAIRequestManager: NSObject {
func
stopChat
(
chatId
:
String
,
conversationId
:
String
,
callBackBlock
:
@escaping
(
_
success
:
Bool
,
_
error
:
YHErrorModel
?)
->
Void
)
{
let
url
=
YHBaseUrlManager
.
shared
.
curURL
()
+
YHAllApiName
.
AIChat
.
cancelAIChat
let
param
=
[
"chatId"
:
chatId
,
"conversationId"
:
conversationId
]
as!
[
String
:
Any
]
guard
let
param
=
[
"chatId"
:
chatId
,
"conversationId"
:
conversationId
]
as?
[
String
:
Any
]
else
{
return
}
_
=
YHNetRequest
.
postRequest
(
url
:
url
,
params
:
param
)
{
[
weak
self
]
json
,
_
in
// 1. json字符串 转 对象
...
...
galaxy/galaxy/Classes/Modules/AI/AI-Dialogue(AI对话)/C/YHAIRobotChatViewController.swift
View file @
e9eb8d51
...
...
@@ -417,12 +417,16 @@ extension YHAIRobotChatViewController: UITableViewDelegate, UITableViewDataSourc
msg
=
messages
[
indexPath
.
row
]
msgType
=
msg
.
getType
()
if
msgType
==
.
text
{
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHAITextMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHAITextMessageCell
guard
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHAITextMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHAITextMessageCell
else
{
return
UITableViewCell
()
}
cell
.
message
=
msg
return
cell
}
else
if
msgType
==
.
recommendText
{
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHRecommendTextMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHRecommendTextMessageCell
guard
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHRecommendTextMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHRecommendTextMessageCell
else
{
return
UITableViewCell
()
}
cell
.
message
=
msg
cell
.
messageClick
=
{
[
weak
self
]
text
in
...
...
@@ -439,11 +443,15 @@ extension YHAIRobotChatViewController: UITableViewDelegate, UITableViewDataSourc
return
cell
}
else
if
msgType
==
.
thinking
{
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHAIThinkingMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHAIThinkingMessageCell
guard
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHAIThinkingMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHAIThinkingMessageCell
else
{
return
UITableViewCell
()
}
return
cell
}
else
if
msgType
==
.
productList
{
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHProductListMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHProductListMessageCell
guard
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHProductListMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHProductListMessageCell
else
{
return
UITableViewCell
()
}
if
let
listModel
=
msg
.
body
.
cardsInfo
{
cell
.
listModel
=
listModel
}
...
...
@@ -451,7 +459,10 @@ extension YHAIRobotChatViewController: UITableViewDelegate, UITableViewDataSourc
}
else
if
msgType
==
.
cardList
{
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHCardMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHCardMessageCell
guard
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHCardMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHCardMessageCell
else
{
return
UITableViewCell
()
}
if
let
listModel
=
msg
.
body
.
cardsInfo
{
cell
.
cardListModel
=
listModel
cell
.
evaluationResultCallback
=
{
...
...
@@ -491,7 +502,9 @@ extension YHAIRobotChatViewController: UITableViewDelegate, UITableViewDataSourc
return
cell
}
else
if
msgType
==
.
picture
{
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHAIPictureMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHAIPictureMessageCell
guard
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHAIPictureMessageCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHAIPictureMessageCell
else
{
return
UITableViewCell
()
}
if
let
imgInfo
=
msg
.
body
.
imageInfo
{
cell
.
imgInfo
=
imgInfo
}
...
...
galaxy/galaxy/Classes/Modules/AI/AI-Dialogue(AI对话)/C/YHAIServiceListViewController.swift
View file @
e9eb8d51
...
...
@@ -99,7 +99,9 @@ extension YHAIServiceListViewController: UICollectionViewDelegate, UICollectionV
// 返回自定义单元格
func
collectionView
(
_
collectionView
:
UICollectionView
,
cellForItemAt
indexPath
:
IndexPath
)
->
UICollectionViewCell
{
let
cell
=
collectionView
.
dequeueReusableCell
(
withReuseIdentifier
:
YHAIProductCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHAIProductCell
guard
let
cell
=
collectionView
.
dequeueReusableCell
(
withReuseIdentifier
:
YHAIProductCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHAIProductCell
else
{
return
UICollectionViewCell
()
}
if
0
<=
indexPath
.
item
&&
indexPath
.
item
<
serviceArr
.
count
{
let
model
=
serviceArr
[
indexPath
.
item
]
...
...
@@ -187,7 +189,9 @@ extension YHAIServiceListViewController: UICollectionViewDelegate, UICollectionV
func
collectionView
(
_
collectionView
:
UICollectionView
,
viewForSupplementaryElementOfKind
kind
:
String
,
at
indexPath
:
IndexPath
)
->
UICollectionReusableView
{
if
kind
==
UICollectionView
.
elementKindSectionHeader
{
let
headerView
:
YHAIGreetCollectionReusableView
=
collectionView
.
dequeueReusableSupplementaryView
(
ofKind
:
UICollectionView
.
elementKindSectionHeader
,
withReuseIdentifier
:
YHAIGreetCollectionReusableView
.
reuseIdentifier
,
for
:
indexPath
)
as!
YHAIGreetCollectionReusableView
guard
let
headerView
:
YHAIGreetCollectionReusableView
=
collectionView
.
dequeueReusableSupplementaryView
(
ofKind
:
UICollectionView
.
elementKindSectionHeader
,
withReuseIdentifier
:
YHAIGreetCollectionReusableView
.
reuseIdentifier
,
for
:
indexPath
)
as?
YHAIGreetCollectionReusableView
else
{
return
UICollectionReusableView
()
}
headerView
.
updateGreetingText
()
return
headerView
}
...
...
galaxy/galaxy/Classes/Modules/AI/AI-Dialogue(AI对话)/C/YHAITabViewController.swift
View file @
e9eb8d51
...
...
@@ -309,6 +309,9 @@ extension YHAITabViewController: JXSegmentedListContainerViewDataSource {
}
func
listContainerView
(
_
listContainerView
:
JXSegmentedListContainerView
,
initListAt
index
:
Int
)
->
JXSegmentedListContainerViewListDelegate
{
return
arrItemVCs
[
index
]
as!
JXSegmentedListContainerViewListDelegate
guard
let
vc
=
arrItemVCs
[
index
]
as?
JXSegmentedListContainerViewListDelegate
else
{
return
YHAIMainChatViewController
()
}
return
vc
}
}
galaxy/galaxy/Classes/Modules/AI/AI-Dialogue(AI对话)/M/YHAIMessageModel.swift
View file @
e9eb8d51
...
...
@@ -49,7 +49,9 @@ class YHAIChatMessage: CustomStringConvertible, NSCopying {
msg
.
messageId
=
self
.
messageId
msg
.
isSelf
=
self
.
isSelf
msg
.
isDone
=
self
.
isDone
msg
.
body
=
self
.
body
.
copy
()
as!
YHAIMessageBody
if
let
body
=
self
.
body
.
copy
()
as?
YHAIMessageBody
{
msg
.
body
=
body
}
return
msg
}
...
...
galaxy/galaxy/Classes/Modules/AI/AI-Dialogue(AI对话)/V/YHAIChatBannerView.swift
View file @
e9eb8d51
...
...
@@ -247,7 +247,9 @@ extension YHAIChatBannerView: FSPagerViewDataSource, FSPagerViewDelegate {
}
public
func
pagerView
(
_
pagerView
:
FSPagerView
,
cellForItemAt
index
:
Int
)
->
FSPagerViewCell
{
let
cell
=
pagerView
.
dequeueReusableCell
(
withReuseIdentifier
:
YHAIChatBannerItemCell
.
cellReuseIdentifier
,
at
:
index
)
as!
YHAIChatBannerItemCell
guard
let
cell
=
pagerView
.
dequeueReusableCell
(
withReuseIdentifier
:
YHAIChatBannerItemCell
.
cellReuseIdentifier
,
at
:
index
)
as?
YHAIChatBannerItemCell
else
{
return
FSPagerViewCell
()
}
if
index
<
bannerArr
.
count
{
let
model
=
bannerArr
[
index
]
cell
.
model
=
model
...
...
@@ -292,7 +294,9 @@ extension YHAIChatBannerView: UICollectionViewDelegate, UICollectionViewDataSour
// 返回自定义单元格
func
collectionView
(
_
collectionView
:
UICollectionView
,
cellForItemAt
indexPath
:
IndexPath
)
->
UICollectionViewCell
{
let
cell
=
collectionView
.
dequeueReusableCell
(
withReuseIdentifier
:
YHAIChatBannerCollectionCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHAIChatBannerCollectionCell
guard
let
cell
=
collectionView
.
dequeueReusableCell
(
withReuseIdentifier
:
YHAIChatBannerCollectionCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHAIChatBannerCollectionCell
else
{
return
UICollectionViewCell
()
}
if
0
<=
indexPath
.
item
&&
indexPath
.
item
<
messages
.
count
{
cell
.
titleLabel
.
text
=
messages
[
indexPath
.
item
]
}
...
...
galaxy/galaxy/Classes/Modules/AppleLogin(苹果登录)/M/YHAppleLoginManager.swift
View file @
e9eb8d51
...
...
@@ -45,14 +45,18 @@ extension YHAppleLoginManager: ASAuthorizationControllerDelegate, ASAuthorizatio
let
credential
=
authorization
.
credential
if
credential
is
ASPasswordCredential
{
let
passwdCredential
=
credential
as!
ASPasswordCredential
guard
let
passwdCredential
=
credential
as?
ASPasswordCredential
else
{
return
}
userId
=
passwdCredential
.
user
let
username
=
passwdCredential
.
user
let
password
=
passwdCredential
.
password
printLog
(
"username:
\(
username
)
, passwd:
\(
password
)
"
)
}
else
if
credential
is
ASAuthorizationAppleIDCredential
{
let
appleIdCredential
=
credential
as!
ASAuthorizationAppleIDCredential
guard
let
appleIdCredential
=
credential
as?
ASAuthorizationAppleIDCredential
else
{
return
}
userId
=
appleIdCredential
.
user
email
=
appleIdCredential
.
email
??
""
fullName
=
appleIdCredential
.
fullName
?
.
givenName
??
""
...
...
galaxy/galaxy/Classes/Modules/Community(社区)/Activity(活动)/C/YHActivityDetailViewController.swift
View file @
e9eb8d51
...
...
@@ -269,24 +269,32 @@ extension YHActivityDetailViewController: UITableViewDelegate, UITableViewDataSo
}
func
tableView
(
_
tableView
:
UITableView
,
cellForRowAt
indexPath
:
IndexPath
)
->
UITableViewCell
{
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHActivityDetailCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHActivityDetailCell
guard
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHActivityDetailCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHActivityDetailCell
else
{
return
UITableViewCell
()
}
cell
.
dataModel
=
viewModel
.
activityDetailModel
if
indexPath
.
row
<
viewModel
.
arrActivityDetail
.
count
{
let
model
=
viewModel
.
arrActivityDetail
[
indexPath
.
row
]
if
model
.
type
==
0
{
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHActivityDetailCell0
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHActivityDetailCell0
guard
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHActivityDetailCell0
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHActivityDetailCell0
else
{
return
UITableViewCell
()
}
cell
.
dataModel
=
model
.
activityDetailModel
??
YHActivityDetailModel
()
return
cell
}
else
if
model
.
type
==
1
{
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHActivityDetailCell1
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHActivityDetailCell1
guard
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHActivityDetailCell1
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHActivityDetailCell1
else
{
return
cell
}
cell
.
dataModel
=
model
.
activityDetailModel
??
YHActivityDetailModel
()
return
cell
}
else
if
model
.
type
==
2
{
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHActivityDetailCell2
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHActivityDetailCell2
guard
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHActivityDetailCell2
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHActivityDetailCell2
else
{
return
cell
}
cell
.
dataModel
=
model
.
activityDetailModel
??
YHActivityDetailModel
()
return
cell
}
...
...
galaxy/galaxy/Classes/Modules/Community(社区)/Activity(活动)/V/YHApplyActivityAlert.swift
View file @
e9eb8d51
...
...
@@ -265,14 +265,14 @@ extension YHApplyActivityAlert {
}
@objc
func
clickSubBtn
()
{
applyNumber
=
applyNumber
-
1
applyNumber
-=
1
applyNumberTextField
.
text
=
String
(
applyNumber
)
handleSubAndAddButtonUI
()
}
@objc
func
clickAddBtn
()
{
applyNumber
=
applyNumber
+
1
applyNumber
+=
1
applyNumberTextField
.
text
=
String
(
applyNumber
)
handleSubAndAddButtonUI
()
}
...
...
galaxy/galaxy/Classes/Modules/Community(社区)/Activity(活动)/VM/YHActivityViewModel.swift
View file @
e9eb8d51
...
...
@@ -234,7 +234,7 @@ extension YHActivityViewModel {
self
.
arrActivityListData
=
result
.
data
curPageIndex
=
1
}
else
{
curPageIndex
=
curPageIndex
+
1
curPageIndex
+=
1
self
.
arrActivityListData
.
append
(
contentsOf
:
result
.
data
)
}
...
...
galaxy/galaxy/Classes/Modules/Community(社区)/C/YHCommunityViewController.swift
View file @
e9eb8d51
...
...
@@ -333,7 +333,10 @@ extension YHCommunityViewController: JXSegmentedListContainerViewDataSource {
}
func
listContainerView
(
_
listContainerView
:
JXSegmentedListContainerView
,
initListAt
index
:
Int
)
->
JXSegmentedListContainerViewListDelegate
{
return
arrItemVCs
[
index
]
as!
JXSegmentedListContainerViewListDelegate
guard
let
vc
=
arrItemVCs
[
index
]
as?
JXSegmentedListContainerViewListDelegate
else
{
return
YHMessageListVC
()
}
return
vc
}
}
...
...
galaxy/galaxy/Classes/Modules/Community(社区)/C/YHMatchResultListViewController.swift
View file @
e9eb8d51
...
...
@@ -439,7 +439,9 @@ extension YHMatchResultListViewController: DragCardDelegate {
print
(
"displayTopCardAt:
\(
index
)
"
)
if
cardView
is
YHNameCardInfoView
{
let
cardInfoView
=
cardView
as!
YHNameCardInfoView
guard
let
cardInfoView
=
cardView
as?
YHNameCardInfoView
else
{
return
}
cardInfoView
.
backgroundColor
=
.
white
if
let
secondCardView
=
dragCard
.
viewWithTag
(
1000
+
index
+
1
)
as?
YHNameCardInfoView
{
secondCardView
.
backgroundColor
=
self
.
secondCardColor
...
...
galaxy/galaxy/Classes/Modules/Community(社区)/V/YHMyInterestTopicCell.swift
View file @
e9eb8d51
...
...
@@ -241,7 +241,9 @@ extension YHMyInterestTopicCell: UICollectionViewDelegate, UICollectionViewDataS
// 返回自定义单元格
func
collectionView
(
_
collectionView
:
UICollectionView
,
cellForItemAt
indexPath
:
IndexPath
)
->
UICollectionViewCell
{
let
cell
=
collectionView
.
dequeueReusableCell
(
withReuseIdentifier
:
YHTopicItemCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHTopicItemCell
guard
let
cell
=
collectionView
.
dequeueReusableCell
(
withReuseIdentifier
:
YHTopicItemCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHTopicItemCell
else
{
return
UICollectionViewCell
()
}
if
0
<=
indexPath
.
item
&&
indexPath
.
item
<
topicArr
.
count
{
cell
.
titleLabel
.
text
=
topicArr
[
indexPath
.
item
]
}
...
...
galaxy/galaxy/Classes/Modules/Home(首页)/C/YHHomeHoldViewPageViewController.swift
View file @
e9eb8d51
...
...
@@ -541,7 +541,10 @@ extension YHHomeHoldViewPageViewController: JXSegmentedListContainerViewDataSour
}
func
listContainerView
(
_
listContainerView
:
JXSegmentedListContainerView
,
initListAt
index
:
Int
)
->
JXSegmentedListContainerViewListDelegate
{
return
arrItemVCs
[
index
]
as!
JXSegmentedListContainerViewListDelegate
guard
let
vc
=
arrItemVCs
[
index
]
as?
JXSegmentedListContainerViewListDelegate
else
{
return
YHHomePageViewController
()
}
return
vc
}
}
...
...
galaxy/galaxy/Classes/Modules/Home(首页)/C/YHHomeIdentityListVC.swift
View file @
e9eb8d51
...
...
@@ -154,7 +154,9 @@ extension YHHomeIdentityListVC: JXSegmentedViewDelegate {
extension
YHHomeIdentityListVC
:
UITableViewDataSource
,
UITableViewDelegate
{
func
tableView
(
_
tableView
:
UITableView
,
cellForRowAt
indexPath
:
IndexPath
)
->
UITableViewCell
{
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHHomeIdentityCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHHomeIdentityCell
guard
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHHomeIdentityCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHHomeIdentityCell
else
{
return
UITableViewCell
()
}
if
0
<=
indexPath
.
row
,
indexPath
.
row
<
self
.
imgItems
.
count
{
let
item
=
self
.
imgItems
[
indexPath
.
row
]
cell
.
image
=
item
.
img
...
...
galaxy/galaxy/Classes/Modules/Home(首页)/C/YHHomeIdentityViewController.swift
View file @
e9eb8d51
...
...
@@ -27,7 +27,9 @@ class YHHomeIdentityViewController: YHBaseViewController {
if
0
<=
index
,
index
<
self
.
children
.
count
{
let
vc
=
self
.
children
[
index
]
if
vc
.
isKind
(
of
:
YHHomeIdentityListVC
.
self
)
{
(
vc
as!
YHHomeIdentityListVC
)
.
isShowBottomView
=
false
if
let
vc
=
vc
as?
YHHomeIdentityListVC
{
vc
.
isShowBottomView
=
false
}
self
.
hideBottomOnTabbar
()
}
}
...
...
galaxy/galaxy/Classes/Modules/Home(首页)/C/YHHomeInfoDetailContainerViewController.swift
View file @
e9eb8d51
...
...
@@ -118,6 +118,9 @@ extension YHHomeInfoDetailContainerViewController: JXSegmentedListContainerViewD
}
func
listContainerView
(
_
listContainerView
:
JXSegmentedListContainerView
,
initListAt
index
:
Int
)
->
JXSegmentedListContainerViewListDelegate
{
return
arrItemVCs
[
index
]
as!
JXSegmentedListContainerViewListDelegate
guard
let
vc
=
arrItemVCs
[
index
]
as?
JXSegmentedListContainerViewListDelegate
else
{
return
YHHomeInfoDetailViewController
()
}
return
vc
}
}
galaxy/galaxy/Classes/Modules/Home(首页)/C/YHHomeInfoDetailViewController.swift
View file @
e9eb8d51
...
...
@@ -82,7 +82,9 @@ extension YHHomeInfoDetailViewController: UICollectionViewDelegate, UICollection
func
collectionView
(
_
collectionView
:
UICollectionView
,
cellForItemAt
indexPath
:
IndexPath
)
->
UICollectionViewCell
{
let
cell
=
collectionView
.
dequeueReusableCell
(
withReuseIdentifier
:
YHHomeCollectionViewCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHHomeCollectionViewCell
guard
let
cell
=
collectionView
.
dequeueReusableCell
(
withReuseIdentifier
:
YHHomeCollectionViewCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHHomeCollectionViewCell
else
{
return
UICollectionViewCell
()
}
cell
.
listModel
=
self
.
viewModel
.
arrHomeNewsData
?[
indexPath
.
row
]
return
cell
}
...
...
galaxy/galaxy/Classes/Modules/Home(首页)/C/YHHomeInformationViewController.swift
View file @
e9eb8d51
...
...
@@ -92,7 +92,9 @@ extension YHHomeInformationViewController: UICollectionViewDelegate, UICollectio
func
collectionView
(
_
collectionView
:
UICollectionView
,
viewForSupplementaryElementOfKind
kind
:
String
,
at
indexPath
:
IndexPath
)
->
UICollectionReusableView
{
if
kind
==
CollectionViewWaterfallElementKindSectionHeader
{
let
headerView
:
YHHomeInfoSectionHeadView
=
collectionView
.
dequeueReusableSupplementaryView
(
ofKind
:
CollectionViewWaterfallElementKindSectionHeader
,
withReuseIdentifier
:
YHHomeInfoSectionHeadView
.
reuseIdentifier
,
for
:
indexPath
)
as!
YHHomeInfoSectionHeadView
guard
let
headerView
:
YHHomeInfoSectionHeadView
=
collectionView
.
dequeueReusableSupplementaryView
(
ofKind
:
CollectionViewWaterfallElementKindSectionHeader
,
withReuseIdentifier
:
YHHomeInfoSectionHeadView
.
reuseIdentifier
,
for
:
indexPath
)
as?
YHHomeInfoSectionHeadView
else
{
return
UICollectionReusableView
()
}
headerView
.
items
=
sectionItems
return
headerView
}
...
...
galaxy/galaxy/Classes/Modules/Home(首页)/C/YHHomePageViewController.swift
View file @
e9eb8d51
...
...
@@ -375,7 +375,7 @@ private extension YHHomePageViewController {
}
var
r
=
tmpHeadView
.
frame
r
.
origin
.
y
=
r
.
origin
.
y
-
headViewH
r
.
origin
.
y
-=
headViewH
tmpHeadView
.
frame
=
r
printLog
(
tmpHeadView
.
frame
)
...
...
galaxy/galaxy/Classes/Modules/Mine(我的)/C/YHMyViewController.swift
View file @
e9eb8d51
...
...
@@ -376,7 +376,10 @@ extension YHMyViewController: UITableViewDelegate, UITableViewDataSource {
}
func
tableView
(
_
tableView
:
UITableView
,
cellForRowAt
indexPath
:
IndexPath
)
->
UITableViewCell
{
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHPersonalCenterCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHPersonalCenterCell
guard
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
YHPersonalCenterCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as?
YHPersonalCenterCell
else
{
return
UITableViewCell
()
}
let
item
:
PersonalModuleItem
=
items
[
indexPath
.
row
]
cell
.
updateItem
(
item
:
item
)
return
cell
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment