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
e2164ea6
Commit
e2164ea6
authored
Jun 18, 2024
by
pete谢兆麟
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
首次登录后的UI绘制
parent
3d9c8d38
Changes
18
Hide whitespace changes
Inline
Side-by-side
Showing
18 changed files
with
479 additions
and
3 deletions
+479
-3
project.pbxproj
galaxy/galaxy.xcodeproj/project.pbxproj
+16
-0
YHBaseViewController.swift
galaxy/galaxy/Classes/Base/C/YHBaseViewController.swift
+1
-1
YHAllowUseMyInfoViewController.swift
.../Modules/Login(登录)/C/YHAllowUseMyInfoViewController.swift
+102
-0
YHUserInfoSettingViewController.swift
...Modules/Login(登录)/C/YHUserInfoSettingViewController.swift
+143
-0
YHSettingItem.swift
...xy/galaxy/Classes/Modules/Login(登录)/M/YHSettingItem.swift
+23
-0
YHUserModel.swift
galaxy/galaxy/Classes/Modules/Login(登录)/M/YHUserModel.swift
+0
-1
YHAllowSettingTableViewCell.swift
...ses/Modules/Login(登录)/V/YHAllowSettingTableViewCell.swift
+119
-0
YHMyViewController.swift
...alaxy/Classes/Modules/Mine(我的)/C/YHMyViewController.swift
+3
-1
Contents.json
galaxy/galaxy/Res/Assets.xcassets/MyCard/Contents.json
+6
-0
Contents.json
....xcassets/MyCard/user_change_photo.imageset/Contents.json
+22
-0
user_change_photo@2x.png
...yCard/user_change_photo.imageset/user_change_photo@2x.png
+0
-0
user_change_photo@3x.png
...yCard/user_change_photo.imageset/user_change_photo@3x.png
+0
-0
Contents.json
...xcassets/MyCard/user_photo_default.imageset/Contents.json
+22
-0
user_photo_default@2x.png
...ard/user_photo_default.imageset/user_photo_default@2x.png
+0
-0
user_photo_default@3x.png
...ard/user_photo_default.imageset/user_photo_default@3x.png
+0
-0
Contents.json
...ts.xcassets/MyCard/user_take_photo.imageset/Contents.json
+22
-0
user_take_photo@2x.png
...ts/MyCard/user_take_photo.imageset/user_take_photo@2x.png
+0
-0
user_take_photo@3x.png
...ts/MyCard/user_take_photo.imageset/user_take_photo@3x.png
+0
-0
No files found.
galaxy/galaxy.xcodeproj/project.pbxproj
View file @
e2164ea6
...
...
@@ -51,6 +51,10 @@
044D0BEE2C2019C100C5CF5E
/* YHCommunityViewController.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
044D0BED2C2019C100C5CF5E
/* YHCommunityViewController.swift */
;
};
044D0BF02C2025FF00C5CF5E
/* YHActivityViewController.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
044D0BEF2C2025FF00C5CF5E
/* YHActivityViewController.swift */
;
};
044D0BF22C20262100C5CF5E
/* YHPeopleViewController.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
044D0BF12C20262100C5CF5E
/* YHPeopleViewController.swift */
;
};
044D0BF42C21247100C5CF5E
/* YHUserInfoSettingViewController.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
044D0BF32C21247100C5CF5E
/* YHUserInfoSettingViewController.swift */
;
};
044D0BF62C2154CA00C5CF5E
/* YHAllowUseMyInfoViewController.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
044D0BF52C2154CA00C5CF5E
/* YHAllowUseMyInfoViewController.swift */
;
};
044D0BF82C21572B00C5CF5E
/* YHAllowSettingTableViewCell.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
044D0BF72C21572B00C5CF5E
/* YHAllowSettingTableViewCell.swift */
;
};
044D0BFA2C215C6F00C5CF5E
/* YHSettingItem.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
044D0BF92C215C6F00C5CF5E
/* YHSettingItem.swift */
;
};
045EEE792B9F171A0022A143
/* YHPreviewViewModel.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
045EED9A2B9F171A0022A143
/* YHPreviewViewModel.swift */
;
};
045EEE7A2B9F171A0022A143
/* YHPreviewForOtherInfoModel.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
045EED9C2B9F171A0022A143
/* YHPreviewForOtherInfoModel.swift */
;
};
045EEE7B2B9F171A0022A143
/* YHPersonInfoCellModel2.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
045EED9D2B9F171A0022A143
/* YHPersonInfoCellModel2.swift */
;
};
...
...
@@ -547,6 +551,10 @@
044D0BED2C2019C100C5CF5E
/* YHCommunityViewController.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHCommunityViewController.swift
;
sourceTree
=
"<group>"
;
};
044D0BEF2C2025FF00C5CF5E
/* YHActivityViewController.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHActivityViewController.swift
;
sourceTree
=
"<group>"
;
};
044D0BF12C20262100C5CF5E
/* YHPeopleViewController.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHPeopleViewController.swift
;
sourceTree
=
"<group>"
;
};
044D0BF32C21247100C5CF5E
/* YHUserInfoSettingViewController.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHUserInfoSettingViewController.swift
;
sourceTree
=
"<group>"
;
};
044D0BF52C2154CA00C5CF5E
/* YHAllowUseMyInfoViewController.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHAllowUseMyInfoViewController.swift
;
sourceTree
=
"<group>"
;
};
044D0BF72C21572B00C5CF5E
/* YHAllowSettingTableViewCell.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHAllowSettingTableViewCell.swift
;
sourceTree
=
"<group>"
;
};
044D0BF92C215C6F00C5CF5E
/* YHSettingItem.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHSettingItem.swift
;
sourceTree
=
"<group>"
;
};
045EED9A2B9F171A0022A143
/* YHPreviewViewModel.swift */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHPreviewViewModel.swift
;
sourceTree
=
"<group>"
;
};
045EED9C2B9F171A0022A143
/* YHPreviewForOtherInfoModel.swift */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHPreviewForOtherInfoModel.swift
;
sourceTree
=
"<group>"
;
};
045EED9D2B9F171A0022A143
/* YHPersonInfoCellModel2.swift */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHPersonInfoCellModel2.swift
;
sourceTree
=
"<group>"
;
};
...
...
@@ -1755,6 +1763,7 @@
isa
=
PBXGroup
;
children
=
(
0468D4352B57752F00CFB916
/* YHUserModel.swift */
,
044D0BF92C215C6F00C5CF5E
/* YHSettingItem.swift */
,
);
path
=
M
;
sourceTree
=
"<group>"
;
...
...
@@ -2275,6 +2284,8 @@
04B9EE592C06CC3100A4018D
/* YHOtherLoginViewController.swift */
,
0468D4252B495A5400CFB916
/* YHPickPhoneAddressViewController.swift */
,
04E86E0C2B70D51D00A35F4B
/* YHWebViewViewController.swift */
,
044D0BF32C21247100C5CF5E
/* YHUserInfoSettingViewController.swift */
,
044D0BF52C2154CA00C5CF5E
/* YHAllowUseMyInfoViewController.swift */
,
);
path
=
C
;
sourceTree
=
"<group>"
;
...
...
@@ -2288,6 +2299,7 @@
A5ACE8E62B4564F7002C94D2
/* YHValidateCodeInputView.swift */
,
0468D4212B493A5E00CFB916
/* YHPhoneMessageView.swift */
,
0468D4272B50D4AF00CFB916
/* YHPrivacyAlertView.swift */
,
044D0BF72C21572B00C5CF5E
/* YHAllowSettingTableViewCell.swift */
,
);
path
=
V
;
sourceTree
=
"<group>"
;
...
...
@@ -2885,6 +2897,7 @@
045EEF132B9F171A0022A143
/* YHCountryMessage.swift in Sources */
,
045EEE7B2B9F171A0022A143
/* YHPersonInfoCellModel2.swift in Sources */
,
A53B61122BB128AF0010B573
/* YHFileListItemsView2.swift in Sources */
,
044D0BF62C2154CA00C5CF5E
/* YHAllowUseMyInfoViewController.swift in Sources */
,
04F9574D2C20644E003C631C
/* YHFriendsRequestView.swift in Sources */
,
04F5F8702C1AC4C2004A463C
/* YHHKEventWebViewController.swift in Sources */
,
045EEE892B9F171A0022A143
/* YHPreviewBaseViewController.swift in Sources */
,
...
...
@@ -2953,6 +2966,7 @@
045EEED82B9F171A0022A143
/* YHQuestionInfo.swift in Sources */
,
A567E5B82BD7643D00D5D5A0
/* YHSearchItemLayout.swift in Sources */
,
A567E5A02BD7643D00D5D5A0
/* YHHomeWebViewController.swift in Sources */
,
044D0BF42C21247100C5CF5E
/* YHUserInfoSettingViewController.swift in Sources */
,
A567E5942BD7643D00D5D5A0
/* YHHomeListModel.swift in Sources */
,
A5ACE94E2B4564F7002C94D2
/* AlignedCollectionViewFlowLayout.swift in Sources */
,
A567E5B32BD7643D00D5D5A0
/* YHServiceOrderAlertView.swift in Sources */
,
...
...
@@ -3018,6 +3032,7 @@
A5ACE9392B4564F7002C94D2
/* UIDevice+Extension.swift in Sources */
,
045EEEE82B9F171A0022A143
/* YHFamilyMemberViewModel.swift in Sources */
,
045EEED02B9F171A0022A143
/* YHScoreResultView.swift in Sources */
,
044D0BFA2C215C6F00C5CF5E
/* YHSettingItem.swift in Sources */
,
0425E6442BA95FE100A5E763
/* YHSchemeTableHeadView.swift in Sources */
,
045EEEBC2B9F171A0022A143
/* YHClipperButton.swift in Sources */
,
045EEF102B9F171A0022A143
/* YHMainApplicantInformationViewModel.swift in Sources */
,
...
...
@@ -3071,6 +3086,7 @@
045EEEEC2B9F171A0022A143
/* YHBrotherInfoVC.swift in Sources */
,
0477E17A2BA41C7E00436346
/* YHCertificateModel.swift in Sources */
,
045EEF242B9F171A0022A143
/* YHStepView.swift in Sources */
,
044D0BF82C21572B00C5CF5E
/* YHAllowSettingTableViewCell.swift in Sources */
,
A5ACE9482B4564F7002C94D2
/* YHHUDWariningView.swift in Sources */
,
045EEF0F2B9F171A0022A143
/* YHSelectCountryViewModel.swift in Sources */
,
045EEEB52B9F171A0022A143
/* YHWorkIntroductionItemView.swift in Sources */
,
...
...
galaxy/galaxy/Classes/Base/C/YHBaseViewController.swift
View file @
e2164ea6
...
...
@@ -22,7 +22,7 @@ class YHBaseViewController: UIViewController {
gk_navLineHidden
=
true
gk_navBarAlpha
=
0
gk_backImage
=
UIImage
(
named
:
"
nav_
back_icon"
)
gk_backImage
=
UIImage
(
named
:
"back_icon"
)
#if DEBUG
...
...
galaxy/galaxy/Classes/Modules/Login(登录)/C/YHAllowUseMyInfoViewController.swift
0 → 100644
View file @
e2164ea6
//
// YHAllowUseMyInfoViewController.swift
// galaxy
//
// Created by EDY on 2024/6/18.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import
UIKit
class
YHAllowUseMyInfoViewController
:
YHBaseViewController
{
var
tableView
:
UITableView
!
var
nextButton
:
UIButton
!
let
items
:
[
YHSettingItem
]
=
[
YHSettingItem
(
title
:
"允许您的信息在名片中使用"
,
subTitle
:
"开启后,您的信息将自动同步至您的个人名片,并对您的好友公开可见"
,
isSelect
:
true
,
isShowAlert
:
false
)]
override
func
viewDidLoad
()
{
super
.
viewDidLoad
()
gk_navTitle
=
"设置"
gk_navBackgroundColor
=
.
white
gk_navBarAlpha
=
1
setView
()
// Do any additional setup after loading the view.
}
func
setView
()
{
view
.
backgroundColor
=
.
contentBkgColor
tableView
=
{
let
tableView
=
UITableView
(
frame
:
.
zero
,
style
:
.
grouped
)
if
#available(iOS 11.0, *)
{
tableView
.
contentInsetAdjustmentBehavior
=
.
never
}
tableView
.
backgroundColor
=
.
white
tableView
.
separatorStyle
=
.
none
tableView
.
delegate
=
self
tableView
.
dataSource
=
self
tableView
.
register
(
cellWithClass
:
YHAllowSettingTableViewCell
.
self
)
return
tableView
}()
view
.
addSubview
(
tableView
)
tableView
.
snp
.
makeConstraints
{
make
in
make
.
top
.
equalTo
(
k_Height_NavigationtBarAndStatuBar
)
make
.
bottom
.
equalTo
(
-
k_Height_safeAreaInsetsBottom
()
-
48
)
make
.
left
.
right
.
equalTo
(
view
)
}
nextButton
=
{
let
button
=
UIButton
(
type
:
.
custom
)
button
.
backgroundColor
=
UIColor
.
brandMainColor
button
.
titleLabel
?
.
font
=
UIFont
.
PFSC_M
(
ofSize
:
16
)
button
.
contentHorizontalAlignment
=
.
center
button
.
setTitle
(
"下一步"
,
for
:
.
normal
)
button
.
setTitleColor
(
UIColor
(
hex
:
0xffffff
),
for
:
.
normal
)
button
.
layer
.
cornerRadius
=
kCornerRadius3
button
.
addTarget
(
self
,
action
:
#selector(
nextStep
)
,
for
:
.
touchUpInside
)
return
button
}()
view
.
addSubview
(
nextButton
)
nextButton
.
snp
.
makeConstraints
{
make
in
make
.
left
.
equalTo
(
16
)
make
.
right
.
equalTo
(
-
16
)
make
.
bottom
.
equalTo
(
-
8
-
k_Height_safeAreaInsetsBottom
())
make
.
height
.
equalTo
(
48
)
}
}
@objc
func
nextStep
()
{
}
}
extension
YHAllowUseMyInfoViewController
:
UITableViewDelegate
,
UITableViewDataSource
{
func
tableView
(
_
tableView
:
UITableView
,
numberOfRowsInSection
section
:
Int
)
->
Int
{
return
items
.
count
}
func
tableView
(
_
tableView
:
UITableView
,
cellForRowAt
indexPath
:
IndexPath
)
->
UITableViewCell
{
let
cell
=
tableView
.
dequeueReusableCell
(
withClass
:
YHAllowSettingTableViewCell
.
self
)
cell
.
item
=
items
[
indexPath
.
row
]
return
cell
}
func
tableView
(
_
tableView
:
UITableView
,
heightForRowAt
indexPath
:
IndexPath
)
->
CGFloat
{
return
98.0
}
func
tableView
(
_
tableView
:
UITableView
,
viewForHeaderInSection
section
:
Int
)
->
UIView
?
{
let
view
=
UIView
(
frame
:
CGRect
(
x
:
0
,
y
:
0
,
width
:
KScreenWidth
,
height
:
0.01
))
return
view
}
func
tableView
(
_
tableView
:
UITableView
,
heightForHeaderInSection
section
:
Int
)
->
CGFloat
{
return
0.01
}
func
tableView
(
_
tableView
:
UITableView
,
viewForFooterInSection
section
:
Int
)
->
UIView
?
{
return
UIView
()
}
func
tableView
(
_
tableView
:
UITableView
,
heightForFooterInSection
section
:
Int
)
->
CGFloat
{
return
0.01
}
}
galaxy/galaxy/Classes/Modules/Login(登录)/C/YHUserInfoSettingViewController.swift
0 → 100644
View file @
e2164ea6
//
// YHUserInfoSettingViewController.swift
// galaxy
//
// Created by EDY on 2024/6/18.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import
UIKit
class
YHUserInfoSettingViewController
:
YHBaseViewController
{
var
photoImageView
:
UIImageView
!
var
photoButton
:
UIButton
!
var
changeButton
:
UIButton
!
var
nameLabel
:
UILabel
!
var
nameTextField
:
UITextField
!
var
nextButton
:
UIButton
!
override
func
viewDidLoad
()
{
super
.
viewDidLoad
()
setView
()
}
func
setView
()
{
gk_navTitle
=
"设置"
view
.
backgroundColor
=
.
white
photoImageView
=
{
let
imageView
=
UIImageView
()
imageView
.
image
=
UIImage
(
named
:
"user_photo_default"
)
imageView
.
contentMode
=
.
scaleAspectFill
imageView
.
isUserInteractionEnabled
=
true
imageView
.
layer
.
cornerRadius
=
46.5
imageView
.
layer
.
masksToBounds
=
true
return
imageView
}()
view
.
addSubview
(
photoImageView
)
photoImageView
.
snp
.
makeConstraints
{
make
in
make
.
centerX
.
equalToSuperview
()
make
.
top
.
equalTo
(
k_Height_NavigationtBarAndStatuBar
+
30
)
make
.
height
.
width
.
equalTo
(
93
)
}
photoButton
=
{
let
button
=
UIButton
(
type
:
.
custom
)
button
.
setImage
(
UIImage
(
named
:
"user_take_photo"
),
for
:
.
normal
)
button
.
addTarget
(
self
,
action
:
#selector(
takePhoto
)
,
for
:
.
touchUpInside
)
return
button
}()
view
.
addSubview
(
photoButton
)
photoButton
.
snp
.
makeConstraints
{
make
in
make
.
bottom
.
equalTo
(
photoImageView
.
snp
.
bottom
)
make
.
right
.
equalTo
(
photoImageView
.
snp
.
right
)
make
.
width
.
height
.
equalTo
(
28
)
}
changeButton
=
{
let
button
=
UIButton
(
type
:
.
custom
)
button
.
setImage
(
UIImage
(
named
:
"user_change_photo"
),
for
:
.
normal
)
button
.
addTarget
(
self
,
action
:
#selector(
changeHead
)
,
for
:
.
touchUpInside
)
return
button
}()
view
.
addSubview
(
changeButton
)
changeButton
.
snp
.
makeConstraints
{
make
in
make
.
centerX
.
equalToSuperview
()
make
.
top
.
equalTo
(
photoImageView
.
snp
.
bottom
)
.
offset
(
20
)
make
.
width
.
equalTo
(
68.5
)
make
.
height
.
equalTo
(
20
)
}
nameLabel
=
{
let
label
=
UILabel
()
label
.
text
=
"真实姓名"
label
.
font
=
UIFont
.
PFSC_M
(
ofSize
:
15
)
label
.
textColor
=
UIColor
.
mainTextColor
return
label
}()
view
.
addSubview
(
nameLabel
)
nameLabel
.
snp
.
makeConstraints
{
make
in
make
.
left
.
equalTo
(
21
)
make
.
width
.
equalTo
(
70
)
make
.
top
.
equalTo
(
changeButton
.
snp
.
bottom
)
.
offset
(
44
)
make
.
height
.
equalTo
(
21
)
}
nameTextField
=
{
let
textField
=
UITextField
()
textField
.
textColor
=
UIColor
.
mainTextColor
textField
.
font
=
UIFont
.
PFSC_M
(
ofSize
:
15
)
textField
.
adjustsFontSizeToFitWidth
=
true
//最小字体
textField
.
minimumFontSize
=
12
textField
.
placeholder
=
"请输入"
return
textField
}()
view
.
addSubview
(
nameTextField
)
nameTextField
.
snp
.
makeConstraints
{
make
in
make
.
centerY
.
equalTo
(
nameLabel
.
snp
.
centerY
)
make
.
left
.
equalTo
(
129
)
make
.
right
.
equalTo
(
-
21
)
make
.
height
.
equalTo
(
21
)
}
nextButton
=
{
let
button
=
UIButton
(
type
:
.
custom
)
button
.
backgroundColor
=
UIColor
.
brandMainColor
button
.
titleLabel
?
.
font
=
UIFont
.
PFSC_M
(
ofSize
:
16
)
button
.
contentHorizontalAlignment
=
.
center
button
.
setTitle
(
"下一步"
,
for
:
.
normal
)
button
.
setTitleColor
(
UIColor
(
hex
:
0xffffff
),
for
:
.
normal
)
button
.
layer
.
cornerRadius
=
kCornerRadius3
button
.
addTarget
(
self
,
action
:
#selector(
nextStep
)
,
for
:
.
touchUpInside
)
return
button
}()
view
.
addSubview
(
nextButton
)
nextButton
.
snp
.
makeConstraints
{
make
in
make
.
left
.
equalTo
(
16
)
make
.
right
.
equalTo
(
-
16
)
make
.
bottom
.
equalTo
(
-
8
-
k_Height_safeAreaInsetsBottom
())
make
.
height
.
equalTo
(
48
)
}
}
@objc
func
takePhoto
()
{
view
.
endEditing
(
true
)
YHImagePickerView
.
show
()
{[
weak
self
]
image
in
guard
let
self
=
self
else
{
return
}
self
.
photoImageView
.
image
=
image
}
}
@objc
func
changeHead
()
{
}
@objc
func
nextStep
()
{
if
nameTextField
.
text
?
.
count
==
0
{
YHHUD
.
flash
(
message
:
"请填写您的真实姓名"
)
return
}
let
vc
=
YHAllowUseMyInfoViewController
()
self
.
navigationController
?
.
pushViewController
(
vc
)
}
}
galaxy/galaxy/Classes/Modules/Login(登录)/M/YHSettingItem.swift
0 → 100644
View file @
e2164ea6
//
// YHSettingItem.swift
// galaxy
//
// Created by EDY on 2024/6/18.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import
UIKit
class
YHSettingItem
:
NSObject
{
var
title
:
String
=
""
var
subTitle
:
String
=
""
var
isSelect
:
Bool
=
true
var
isShowAlert
:
Bool
=
true
init
(
title
:
String
,
subTitle
:
String
,
isSelect
:
Bool
,
isShowAlert
:
Bool
)
{
self
.
title
=
title
self
.
subTitle
=
subTitle
self
.
isSelect
=
isSelect
self
.
isShowAlert
=
isShowAlert
}
}
galaxy/galaxy/Classes/Modules/Login(登录)/M/YHUserModel.swift
View file @
e2164ea6
...
...
@@ -16,7 +16,6 @@ struct YHUserModel: SmartCodable {
var
headpic
:
String
?
var
sex
:
Int
?
var
token
:
String
?
}
struct
YHDeviceTokenModel
{
...
...
galaxy/galaxy/Classes/Modules/Login(登录)/V/YHAllowSettingTableViewCell.swift
0 → 100644
View file @
e2164ea6
//
// YHAllowSettingTableViewCell.swift
// galaxy
//
// Created by EDY on 2024/6/18.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import
UIKit
class
YHAllowSettingTableViewCell
:
UITableViewCell
{
var
titleLabel
:
UILabel
!
var
exampleButton
:
UIButton
!
var
subTitleLabel
:
UILabel
!
var
detailSwitch
:
UISwitch
!
var
item
:
YHSettingItem
?
{
didSet
{
updateData
()
}
}
override
func
awakeFromNib
()
{
super
.
awakeFromNib
()
// Initialization code
}
override
func
setSelected
(
_
selected
:
Bool
,
animated
:
Bool
)
{
super
.
setSelected
(
selected
,
animated
:
animated
)
// Configure the view for the selected state
}
required
init
?(
coder
:
NSCoder
)
{
super
.
init
(
coder
:
coder
)
}
override
init
(
style
:
UITableViewCell
.
CellStyle
,
reuseIdentifier
:
String
?)
{
super
.
init
(
style
:
style
,
reuseIdentifier
:
reuseIdentifier
)
selectionStyle
=
.
none
setupUI
()
}
func
setupUI
()
{
contentView
.
backgroundColor
=
.
clear
backgroundColor
=
.
clear
titleLabel
=
{
let
label
=
UILabel
()
label
.
font
=
UIFont
.
PFSC_M
(
ofSize
:
17
)
label
.
textColor
=
UIColor
.
mainTextColor
return
label
}()
contentView
.
addSubview
(
titleLabel
)
titleLabel
.
snp
.
makeConstraints
{
make
in
make
.
left
.
equalTo
(
21
)
make
.
top
.
equalTo
(
16
)
make
.
height
.
equalTo
(
22
)
}
exampleButton
=
{
let
button
=
UIButton
(
type
:
.
custom
)
button
.
setBackgroundImage
(
UIImage
(
named
:
"work_experience_alert"
),
for
:
.
normal
)
button
.
addTarget
(
self
,
action
:
#selector(
exampleClick
)
,
for
:
.
touchUpInside
)
return
button
}()
contentView
.
addSubview
(
exampleButton
)
exampleButton
.
snp
.
makeConstraints
{
make
in
make
.
left
.
equalTo
(
titleLabel
.
snp
.
right
)
.
offset
(
4
)
make
.
centerY
.
equalTo
(
titleLabel
.
snp
.
centerY
)
make
.
height
.
equalTo
(
18
)
make
.
width
.
equalTo
(
18
)
}
subTitleLabel
=
{
let
label
=
UILabel
()
label
.
font
=
UIFont
.
PFSC_R
(
ofSize
:
13
)
label
.
textColor
=
UIColor
.
mainTextColor30
label
.
numberOfLines
=
0
return
label
}()
contentView
.
addSubview
(
subTitleLabel
)
subTitleLabel
.
snp
.
makeConstraints
{
make
in
make
.
left
.
equalTo
(
21
)
make
.
right
.
equalTo
(
-
87
)
make
.
top
.
equalTo
(
46
)
}
detailSwitch
=
{
let
switchView
=
UISwitch
()
switchView
.
onTintColor
=
UIColor
.
brandMainColor
switchView
.
addTarget
(
self
,
action
:
#selector(
switchViewChange
)
,
for
:
.
valueChanged
)
return
switchView
}()
contentView
.
addSubview
(
detailSwitch
)
detailSwitch
.
snp
.
makeConstraints
{
make
in
make
.
right
.
equalTo
(
-
21
)
make
.
centerY
.
equalToSuperview
()
make
.
height
.
equalTo
(
22
)
make
.
width
.
equalTo
(
40
)
}
exampleButton
.
YH_clickEdgeInsets
=
UIEdgeInsets
(
top
:
50
,
left
:
50
,
bottom
:
50
,
right
:
50
)
detailSwitch
.
transform
=
CGAffineTransform
(
scaleX
:
0.77
,
y
:
0.77
)
}
@objc
func
exampleClick
()
{
}
@objc
func
switchViewChange
()
{
}
func
updateData
()
{
guard
let
model
=
item
else
{
return
}
titleLabel
.
text
=
model
.
title
subTitleLabel
.
text
=
model
.
subTitle
exampleButton
.
isHidden
=
!
model
.
isShowAlert
detailSwitch
.
isOn
=
model
.
isSelect
}
}
galaxy/galaxy/Classes/Modules/Mine(我的)/C/YHMyViewController.swift
View file @
e2164ea6
...
...
@@ -285,7 +285,9 @@ extension YHMyViewController : UITableViewDelegate, UITableViewDataSource {
switch
item
.
type
{
case
.
myMessage
:
//我的消息
printLog
(
"我的消息"
)
let
vc
=
YHMessageListVC
()
// let vc = YHMessageListVC()
// self.navigationController?.pushViewController(vc)
let
vc
=
YHUserInfoSettingViewController
()
self
.
navigationController
?
.
pushViewController
(
vc
)
case
.
scoreCenter
:
////积分中心
printLog
(
"积分中心"
)
...
...
galaxy/galaxy/Res/Assets.xcassets/MyCard/Contents.json
0 → 100644
View file @
e2164ea6
{
"info"
:
{
"author"
:
"xcode"
,
"version"
:
1
}
}
galaxy/galaxy/Res/Assets.xcassets/MyCard/user_change_photo.imageset/Contents.json
0 → 100644
View file @
e2164ea6
{
"images"
:
[
{
"idiom"
:
"universal"
,
"scale"
:
"1x"
},
{
"filename"
:
"user_change_photo@2x.png"
,
"idiom"
:
"universal"
,
"scale"
:
"2x"
},
{
"filename"
:
"user_change_photo@3x.png"
,
"idiom"
:
"universal"
,
"scale"
:
"3x"
}
],
"info"
:
{
"author"
:
"xcode"
,
"version"
:
1
}
}
galaxy/galaxy/Res/Assets.xcassets/MyCard/user_change_photo.imageset/user_change_photo@2x.png
0 → 100644
View file @
e2164ea6
4.11 KB
galaxy/galaxy/Res/Assets.xcassets/MyCard/user_change_photo.imageset/user_change_photo@3x.png
0 → 100644
View file @
e2164ea6
6.79 KB
galaxy/galaxy/Res/Assets.xcassets/MyCard/user_photo_default.imageset/Contents.json
0 → 100644
View file @
e2164ea6
{
"images"
:
[
{
"idiom"
:
"universal"
,
"scale"
:
"1x"
},
{
"filename"
:
"user_photo_default@2x.png"
,
"idiom"
:
"universal"
,
"scale"
:
"2x"
},
{
"filename"
:
"user_photo_default@3x.png"
,
"idiom"
:
"universal"
,
"scale"
:
"3x"
}
],
"info"
:
{
"author"
:
"xcode"
,
"version"
:
1
}
}
galaxy/galaxy/Res/Assets.xcassets/MyCard/user_photo_default.imageset/user_photo_default@2x.png
0 → 100644
View file @
e2164ea6
50.4 KB
galaxy/galaxy/Res/Assets.xcassets/MyCard/user_photo_default.imageset/user_photo_default@3x.png
0 → 100644
View file @
e2164ea6
97.6 KB
galaxy/galaxy/Res/Assets.xcassets/MyCard/user_take_photo.imageset/Contents.json
0 → 100644
View file @
e2164ea6
{
"images"
:
[
{
"idiom"
:
"universal"
,
"scale"
:
"1x"
},
{
"filename"
:
"user_take_photo@2x.png"
,
"idiom"
:
"universal"
,
"scale"
:
"2x"
},
{
"filename"
:
"user_take_photo@3x.png"
,
"idiom"
:
"universal"
,
"scale"
:
"3x"
}
],
"info"
:
{
"author"
:
"xcode"
,
"version"
:
1
}
}
galaxy/galaxy/Res/Assets.xcassets/MyCard/user_take_photo.imageset/user_take_photo@2x.png
0 → 100644
View file @
e2164ea6
2.01 KB
galaxy/galaxy/Res/Assets.xcassets/MyCard/user_take_photo.imageset/user_take_photo@3x.png
0 → 100644
View file @
e2164ea6
2.84 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