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
f237474e
Commit
f237474e
authored
Apr 08, 2024
by
David黄金龙
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
切换 主页
parent
64692a81
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
161 additions
and
5 deletions
+161
-5
project.pbxproj
galaxy/galaxy.xcodeproj/project.pbxproj
+6
-2
YHHomePageViewController.swift
...Classes/Modules/Home(首页)/C/YHHomePageViewController.swift
+128
-0
YHStartPageViewController.swift
...lasses/Modules/Home(首页)/C/YHStartPageViewController.swift
+1
-1
YHHomeSearchView.swift
.../galaxy/Classes/Modules/Home(首页)/V/YHHomeSearchView.swift
+4
-2
Contents.json
...ets.xcassets/Home/home_search_icon.imageset/Contents.json
+22
-0
icon_sousuo@2x.png
...cassets/Home/home_search_icon.imageset/icon_sousuo@2x.png
+0
-0
icon_sousuo@3x.png
...cassets/Home/home_search_icon.imageset/icon_sousuo@3x.png
+0
-0
No files found.
galaxy/galaxy.xcodeproj/project.pbxproj
View file @
f237474e
...
...
@@ -259,6 +259,7 @@
A51044182B493675006B60BB
/* README.md in Resources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
A51044172B493675006B60BB
/* README.md */
;
};
A510441A2B495DD0006B60BB
/* UIView+Extension.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
A51044192B495DD0006B60BB
/* UIView+Extension.swift */
;
};
A514E5DC2B60A2B700C93951
/* YHServiceCenterSecondViewController.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
A514E5DB2B60A2B700C93951
/* YHServiceCenterSecondViewController.swift */
;
};
A5173D682BC399B9007D4E74
/* YHHomePageViewController.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
A5173D672BC399B9007D4E74
/* YHHomePageViewController.swift */
;
};
A517A4DF2BB53BE8000DEECD
/* YHDocListBottomView.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
A517A4DE2BB53BE8000DEECD
/* YHDocListBottomView.swift */
;
};
A517A4E12BB573EB000DEECD
/* YHDocListCell.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
A517A4E02BB573EB000DEECD
/* YHDocListCell.swift */
;
};
A517A4E42BB6C4BB000DEECD
/* YHDocumentUploadView.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
A517A4E22BB6C4BB000DEECD
/* YHDocumentUploadView.swift */
;
};
...
...
@@ -674,6 +675,7 @@
A51044172B493675006B60BB
/* README.md */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
net.daringfireball.markdown
;
path
=
README.md
;
sourceTree
=
"<group>"
;
};
A51044192B495DD0006B60BB
/* UIView+Extension.swift */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.swift
;
path
=
"UIView+Extension.swift"
;
sourceTree
=
"<group>"
;
};
A514E5DB2B60A2B700C93951
/* YHServiceCenterSecondViewController.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHServiceCenterSecondViewController.swift
;
sourceTree
=
"<group>"
;
};
A5173D672BC399B9007D4E74
/* YHHomePageViewController.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHHomePageViewController.swift
;
sourceTree
=
"<group>"
;
};
A517A4DE2BB53BE8000DEECD
/* YHDocListBottomView.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHDocListBottomView.swift
;
sourceTree
=
"<group>"
;
};
A517A4E02BB573EB000DEECD
/* YHDocListCell.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHDocListCell.swift
;
sourceTree
=
"<group>"
;
};
A517A4E22BB6C4BB000DEECD
/* YHDocumentUploadView.swift */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHDocumentUploadView.swift
;
sourceTree
=
"<group>"
;
};
...
...
@@ -2104,8 +2106,6 @@
A5ACE95B2B45712D002C94D2
/* V */
=
{
isa
=
PBXGroup
;
children
=
(
A5C5B30F2B57677300A7C5D1
/* YHGestureTableView.swift */
,
A5C5B2FA2B5535DF00A7C5D1
/* YHHomeBannerView.swift */
,
A5C5B2F82B5515CE00A7C5D1
/* YHPageContentView.swift */
,
A530268F2B4E6F2700F35102
/* YHHomeCustomCell.swift */
,
A5C5B2E72B4EC95600A7C5D1
/* YHDavidTestCollectionViewCell.swift */
,
...
...
@@ -2119,7 +2119,9 @@
044413F82BC279D200784A14
/* YHHomeWebBottomView.swift */
,
044413FA2BC27E6F00784A14
/* YHHomeWebBottomButton.swift */
,
A501BE652BC2B76200C4F1FB
/* YHHomeHeadView.swift */
,
A5C5B2FA2B5535DF00A7C5D1
/* YHHomeBannerView.swift */
,
A501BE672BC2B85F00C4F1FB
/* YHHomeSearchView.swift */
,
A5C5B30F2B57677300A7C5D1
/* YHGestureTableView.swift */
,
);
path
=
V
;
sourceTree
=
"<group>"
;
...
...
@@ -2132,6 +2134,7 @@
A5C5B2E52B4EC0BF00A7C5D1
/* YHDavidTestViewController.swift */
,
044413F62BC2786200784A14
/* YHHomeWebViewController.swift */
,
A53D381F2BC243F1006AE6F7
/* YHStartPageViewController.swift */
,
A5173D672BC399B9007D4E74
/* YHHomePageViewController.swift */
,
);
path
=
C
;
sourceTree
=
"<group>"
;
...
...
@@ -2390,6 +2393,7 @@
045EEF112B9F171A0022A143
/* YHMainInformationModel.swift in Sources */
,
A58AC09D2BABD59600A30FA9
/* YHFileListModel.swift in Sources */
,
045EEEFF2B9F171A0022A143
/* YHSaveAndSubmitView.swift in Sources */
,
A5173D682BC399B9007D4E74
/* YHHomePageViewController.swift in Sources */
,
045EEF0E2B9F171A0022A143
/* YHBasicInfoFillView.swift in Sources */
,
045EEEA12B9F171A0022A143
/* YHWorkExperienceDetailModel.swift in Sources */
,
A5573ED22B317BFF00D98EC0
/* AppDelegate.swift in Sources */
,
...
...
galaxy/galaxy/Classes/Modules/Home(首页)/C/YHHomePageViewController.swift
0 → 100644
View file @
f237474e
//
// YHHomePageViewController.swift
// galaxy
//
// Created by davidhuangA on 2024/4/8.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import
UIKit
import
ESPullToRefresh
import
GKNavigationBarSwift
class
YHHomePageViewController
:
YHBaseViewController
{
lazy
var
items
=
{
return
[
AboutAdvantageItem
(
iconName
:
"about_match"
,
title
:
"精准匹配"
,
detail
:
"大数据精准匹配,专属方案获批率更高"
)]
}()
private
lazy
var
homeBannerView
:
YHHomeBannerView
=
{
let
view
=
YHHomeBannerView
()
return
view
}()
lazy
var
homeCollectView
=
{
// 设置布局方向
let
flowLayout
=
UICollectionViewFlowLayout
()
let
margin
=
20.0
let
gap
=
20.0
let
itemWidth
=
ceil
((
KScreenWidth
-
2*
margin
-
gap
)
/
2.0
)
flowLayout
.
itemSize
=
CGSize
(
width
:
itemWidth
,
height
:
210
+
87
+
4
)
flowLayout
.
minimumInteritemSpacing
=
10.0
flowLayout
.
minimumLineSpacing
=
10.0
flowLayout
.
scrollDirection
=
.
vertical
let
collectinoView
=
UICollectionView
(
frame
:
.
zero
,
collectionViewLayout
:
flowLayout
)
collectinoView
.
contentInset
=
UIEdgeInsets
(
top
:
20
,
left
:
20
,
bottom
:
20
,
right
:
20
)
collectinoView
.
backgroundColor
=
.
white
collectinoView
.
register
(
YHAboutUsAdvantageCell
.
self
,
forCellWithReuseIdentifier
:
YHAboutUsAdvantageCell
.
cellReuseIdentifier
)
collectinoView
.
register
(
YHDavidTestCollectionViewCell
.
self
,
forCellWithReuseIdentifier
:
YHDavidTestCollectionViewCell
.
cellReuseIdentifier
)
collectinoView
.
delegate
=
self
collectinoView
.
dataSource
=
self
collectinoView
.
translatesAutoresizingMaskIntoConstraints
=
false
collectinoView
.
alwaysBounceVertical
=
true
return
collectinoView
}()
override
func
viewDidLoad
()
{
super
.
viewDidLoad
()
setupUI
()
}
lazy
var
searchView
:
YHHomeSearchView
=
{
let
view
=
YHHomeSearchView
()
return
view
}()
}
private
extension
YHHomePageViewController
{
func
setupUI
()
{
gk_navTitle
=
""
view
.
backgroundColor
=
.
white
view
.
addSubview
(
searchView
)
searchView
.
snp
.
makeConstraints
{
make
in
make
.
top
.
equalTo
(
k_Height_safeAreaInsetsTop
()
+
6
)
make
.
left
.
equalTo
(
20
)
make
.
right
.
equalTo
(
-
20
)
make
.
height
.
equalTo
(
YHHomeSearchView
.
viewH
)
}
view
.
addSubview
(
homeCollectView
)
homeCollectView
.
snp
.
makeConstraints
{
make
in
make
.
left
.
right
.
bottom
.
equalToSuperview
()
make
.
top
.
equalTo
(
searchView
.
snp
.
bottom
)
.
offset
(
20
)
}
homeCollectView
.
es
.
addInfiniteScrolling
{
self
.
loadFakeData
()
}
}
func
loadFirstItem
()
{
DispatchQueue
.
main
.
asyncAfter
(
deadline
:
.
now
()
+
1
)
{
self
.
items
=
[
AboutAdvantageItem
(
iconName
:
"about_match"
,
title
:
"精准匹配"
,
detail
:
"大数据精准匹配,专属方案获批率更高"
),
AboutAdvantageItem
(
iconName
:
"about_match"
,
title
:
"精准匹配"
,
detail
:
"大数据精准匹配,专属方案获批率更高"
),
AboutAdvantageItem
(
iconName
:
"about_match"
,
title
:
"精准匹配"
,
detail
:
"大数据精准匹配,专属方案获批率更高"
),
AboutAdvantageItem
(
iconName
:
"about_match"
,
title
:
"精准匹配"
,
detail
:
"大数据精准匹配,专属方案获批率更高"
)]
self
.
homeCollectView
.
es
.
stopPullToRefresh
(
ignoreDate
:
true
,
ignoreFooter
:
false
)
self
.
homeCollectView
.
reloadData
()
}
}
func
loadFakeData
()
{
DispatchQueue
.
main
.
asyncAfter
(
deadline
:
.
now
()
+
1
)
{
self
.
items
.
append
(
AboutAdvantageItem
(
iconName
:
"about_match"
,
title
:
"精准匹配"
,
detail
:
"大数据精准匹配,专属方案获批率更高"
))
self
.
items
.
append
(
AboutAdvantageItem
(
iconName
:
"about_match"
,
title
:
"精准匹配"
,
detail
:
"大数据精准匹配,专属方案获批率更高"
))
self
.
items
.
append
(
AboutAdvantageItem
(
iconName
:
"about_match"
,
title
:
"精准匹配"
,
detail
:
"大数据精准匹配,专属方案获批率更高"
))
self
.
items
.
append
(
AboutAdvantageItem
(
iconName
:
"about_match"
,
title
:
"精准匹配"
,
detail
:
"大数据精准匹配,专属方案获批率更高"
))
self
.
items
.
append
(
AboutAdvantageItem
(
iconName
:
"about_match"
,
title
:
"精准匹配"
,
detail
:
"大数据精准匹配,专属方案获批率更高"
))
self
.
homeCollectView
.
es
.
stopLoadingMore
()
self
.
homeCollectView
.
reloadData
()
}
}
}
extension
YHHomePageViewController
:
UICollectionViewDelegateFlowLayout
,
UICollectionViewDelegate
,
UICollectionViewDataSource
{
func
collectionView
(
_
collectionView
:
UICollectionView
,
numberOfItemsInSection
section
:
Int
)
->
Int
{
return
items
.
count
}
func
collectionView
(
_
collectionView
:
UICollectionView
,
cellForItemAt
indexPath
:
IndexPath
)
->
UICollectionViewCell
{
let
cell
=
collectionView
.
dequeueReusableCell
(
withReuseIdentifier
:
YHDavidTestCollectionViewCell
.
cellReuseIdentifier
,
for
:
indexPath
)
as!
YHDavidTestCollectionViewCell
return
cell
}
private
func
collectionView
(
collectionView
:
UICollectionView
,
didSelectItemAtIndexPath
indexPath
:
NSIndexPath
)
{
print
(
"index is
\(
indexPath
.
row
)
"
)
}
}
private
extension
YHHomePageViewController
{
}
galaxy/galaxy/Classes/Modules/Home(首页)/C/YHStartPageViewController.swift
View file @
f237474e
...
...
@@ -98,7 +98,7 @@ private extension YHStartPageViewController {
//1.设置主窗口
func
setupRootVC
()
{
let
tabBarController
=
YHTabBarViewController
()
let
v0
=
YHNavigationController
(
rootVC
:
YHHomeViewController
())
let
v0
=
YHNavigationController
(
rootVC
:
YHHome
Page
ViewController
())
let
v1
=
YHNavigationController
(
rootVC
:
YHServiceCenterMainViewController
())
let
v2
=
YHNavigationController
(
rootVC
:
YHMsgViewController
())
let
v3
=
YHNavigationController
(
rootVC
:
YHMyViewController
())
...
...
galaxy/galaxy/Classes/Modules/Home(首页)/V/YHHomeSearchView.swift
View file @
f237474e
...
...
@@ -8,6 +8,8 @@
import
UIKit
class
YHHomeSearchView
:
UIView
{
static
let
viewH
:
CGFloat
=
36.0
override
init
(
frame
:
CGRect
)
{
super
.
init
(
frame
:
frame
)
initView
()
...
...
@@ -24,7 +26,7 @@ private extension YHHomeSearchView {
let
imageV
:
UIImageView
=
UIImageView
()
imageV
.
contentMode
=
.
scaleAspectFill
imageV
.
image
=
UIImage
(
named
:
""
)
imageV
.
image
=
UIImage
(
named
:
"
home_search_icon
"
)
addSubview
(
imageV
)
imageV
.
snp
.
makeConstraints
{
make
in
make
.
centerY
.
equalToSuperview
()
...
...
@@ -40,7 +42,7 @@ private extension YHHomeSearchView {
addSubview
(
lable
)
lable
.
snp
.
makeConstraints
{
make
in
make
.
centerY
.
equalToSuperview
()
make
.
left
.
equalTo
(
imageV
.
snp
.
lef
t
)
.
offset
(
8
)
make
.
left
.
equalTo
(
imageV
.
snp
.
righ
t
)
.
offset
(
8
)
make
.
height
.
equalTo
(
18
)
make
.
right
.
equalToSuperview
()
.
offset
(
-
12
)
}
...
...
galaxy/galaxy/Res/Assets.xcassets/Home/home_search_icon.imageset/Contents.json
0 → 100644
View file @
f237474e
{
"images"
:
[
{
"idiom"
:
"universal"
,
"scale"
:
"1x"
},
{
"filename"
:
"icon_sousuo@2x.png"
,
"idiom"
:
"universal"
,
"scale"
:
"2x"
},
{
"filename"
:
"icon_sousuo@3x.png"
,
"idiom"
:
"universal"
,
"scale"
:
"3x"
}
],
"info"
:
{
"author"
:
"xcode"
,
"version"
:
1
}
}
galaxy/galaxy/Res/Assets.xcassets/Home/home_search_icon.imageset/icon_sousuo@2x.png
0 → 100644
View file @
f237474e
813 Bytes
galaxy/galaxy/Res/Assets.xcassets/Home/home_search_icon.imageset/icon_sousuo@3x.png
0 → 100644
View file @
f237474e
1.28 KB
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