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
7b435ffb
Commit
7b435ffb
authored
Apr 08, 2025
by
Steven杜宇
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
// UI走查
parent
bae10749
Changes
13
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
180 additions
and
9 deletions
+180
-9
project.pbxproj
galaxy/galaxy.xcodeproj/project.pbxproj
+4
-0
YHPictureBrowserViewController.swift
.../PictureReview(图片预览)/YHPictureBrowserViewController.swift
+98
-0
YHPictureReviewManager.swift
.../Modules/PictureReview(图片预览)/YHPictureReviewManager.swift
+9
-1
YHPlanPolicyDetailViewController.swift
...Modules/Plan(方案)/C/YHPlanPolicyDetailViewController.swift
+6
-1
YHPlanAnalyzeInfoCell.swift
...xy/Classes/Modules/Plan(方案)/V/YHPlanAnalyzeInfoCell.swift
+12
-3
YHPlanPolicyCarouselView.swift
...Classes/Modules/Plan(方案)/V/YHPlanPolicyCarouselView.swift
+1
-1
YHPlanProductListView.swift
...xy/Classes/Modules/Plan(方案)/V/YHPlanProductListView.swift
+3
-3
Contents.json
...xcassets/AI-Chat/photo_brower_save.imageset/Contents.json
+25
-0
下保存图片@2x.png
....xcassets/AI-Chat/photo_brower_save.imageset/下保存图片@2x.png
+0
-0
下保存图片@3x.png
....xcassets/AI-Chat/photo_brower_save.imageset/下保存图片@3x.png
+0
-0
Contents.json
...xcassets/Plan/plan_product_default.imageset/Contents.json
+22
-0
缺省图@2x.png
...ts.xcassets/Plan/plan_product_default.imageset/缺省图@2x.png
+0
-0
缺省图@3x.png
...ts.xcassets/Plan/plan_product_default.imageset/缺省图@3x.png
+0
-0
No files found.
galaxy/galaxy.xcodeproj/project.pbxproj
View file @
7b435ffb
...
...
@@ -1264,6 +1264,7 @@
04D8FF792D97BDBD00703C75
/* YHPlanShareViewController.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
04D8FF782D97BDBD00703C75
/* YHPlanShareViewController.swift */
;
};
04D8FF7B2D97C29E00703C75
/* YHPlanShareView.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
04D8FF7A2D97C29E00703C75
/* YHPlanShareView.swift */
;
};
04D8FFB02D9A3CF200703C75
/* YHPlanShareImageCell.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
04D8FFAF2D9A3CF200703C75
/* YHPlanShareImageCell.swift */
;
};
04D8FFB22DA5007A00703C75
/* YHPictureBrowserViewController.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
04D8FFB12DA5007A00703C75
/* YHPictureBrowserViewController.swift */
;
};
04E4CF3E2D5C6D32004D4013
/* YHCountryMessageView.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
04E4CF3D2D5C6D32004D4013
/* YHCountryMessageView.swift */
;
};
04E4CF402D5C83AE004D4013
/* YHSelectPhoneCountryViewController.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
04E4CF3F2D5C83AE004D4013
/* YHSelectPhoneCountryViewController.swift */
;
};
04E507D62D6EE856005F758B
/* YHUserLevelAlertView.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
04E507D52D6EE856005F758B
/* YHUserLevelAlertView.swift */
;
};
...
...
@@ -2570,6 +2571,7 @@
04D8FF782D97BDBD00703C75
/* YHPlanShareViewController.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHPlanShareViewController.swift
;
sourceTree
=
"<group>"
;
};
04D8FF7A2D97C29E00703C75
/* YHPlanShareView.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHPlanShareView.swift
;
sourceTree
=
"<group>"
;
};
04D8FFAF2D9A3CF200703C75
/* YHPlanShareImageCell.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHPlanShareImageCell.swift
;
sourceTree
=
"<group>"
;
};
04D8FFB12DA5007A00703C75
/* YHPictureBrowserViewController.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHPictureBrowserViewController.swift
;
sourceTree
=
"<group>"
;
};
04E4CF3D2D5C6D32004D4013
/* YHCountryMessageView.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHCountryMessageView.swift
;
sourceTree
=
"<group>"
;
};
04E4CF3F2D5C83AE004D4013
/* YHSelectPhoneCountryViewController.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHSelectPhoneCountryViewController.swift
;
sourceTree
=
"<group>"
;
};
04E507D52D6EE856005F758B
/* YHUserLevelAlertView.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHUserLevelAlertView.swift
;
sourceTree
=
"<group>"
;
};
...
...
@@ -5982,6 +5984,7 @@
children
=
(
045C0EFE2D12CA5E00BD2DC0
/* YHLongtapPictureSheetView.swift */
,
045C0EFF2D12CA5E00BD2DC0
/* YHPictureReviewManager.swift */
,
04D8FFB12DA5007A00703C75
/* YHPictureBrowserViewController.swift */
,
);
path
=
"PictureReview(图片预览)"
;
sourceTree
=
"<group>"
;
...
...
@@ -7497,6 +7500,7 @@
045C10C92D12CA5F00BD2DC0
/* YHResignUploadTravelCardListModel.swift in Sources */
,
045C10CA2D12CA5F00BD2DC0
/* YHDocListBottomView.swift in Sources */
,
045C10CB2D12CA5F00BD2DC0
/* YHPreviewInfoCertificatePictureItemView.swift in Sources */
,
04D8FFB22DA5007A00703C75
/* YHPictureBrowserViewController.swift in Sources */
,
045C10CC2D12CA5F00BD2DC0
/* YHAIChatBannerItemCell.swift in Sources */
,
045C10CD2D12CA5F00BD2DC0
/* YHLoginPrivacyView.swift in Sources */
,
045C10CE2D12CA5F00BD2DC0
/* YHPrincipleUploadListVC.swift in Sources */
,
...
...
galaxy/galaxy/Classes/Modules/PictureReview(图片预览)/YHPictureBrowserViewController.swift
0 → 100644
View file @
7b435ffb
//
// YHPictureBrowserViewController.swift
// galaxy
//
// Created by Dufet on 2025/4/8.
// Copyright © 2025 https://www.galaxy-immi.com. All rights reserved.
//
import
UIKit
import
JXPhotoBrowser
import
Photos
import
PhotosUI
class
YHPictureBrowserViewController
:
JXPhotoBrowser
{
var
getImgUrlBlock
:
((
Int
)
->
(
String
))?
lazy
var
navBar
:
UIView
=
{
let
v
=
UIView
()
let
backBtn
=
UIButton
()
backBtn
.
setImage
(
UIImage
(
named
:
"nav_back_white"
),
for
:
.
normal
)
backBtn
.
addTarget
(
self
,
action
:
#selector(
didBackBtnClicked
)
,
for
:
.
touchUpInside
)
v
.
addSubview
(
backBtn
)
let
saveBtn
=
UIButton
()
let
img
=
UIImage
(
named
:
"photo_brower_save"
)
let
templateImage
=
img
?
.
withRenderingMode
(
.
alwaysTemplate
)
saveBtn
.
setImage
(
templateImage
,
for
:
.
normal
)
saveBtn
.
imageView
?
.
tintColor
=
.
white
saveBtn
.
addTarget
(
self
,
action
:
#selector(
didSaveBtnClicked
)
,
for
:
.
touchUpInside
)
v
.
addSubview
(
saveBtn
)
backBtn
.
snp
.
makeConstraints
{
make
in
make
.
width
.
height
.
equalTo
(
44
)
make
.
left
.
equalToSuperview
()
make
.
bottom
.
equalToSuperview
()
}
saveBtn
.
snp
.
makeConstraints
{
make
in
make
.
width
.
height
.
equalTo
(
44
)
make
.
right
.
equalToSuperview
()
make
.
bottom
.
equalToSuperview
()
}
return
v
}()
@objc
func
didBackBtnClicked
()
{
dismiss
()
}
@objc
func
didSaveBtnClicked
()
{
let
index
=
self
.
browserView
.
pageIndex
if
let
block
=
self
.
getImgUrlBlock
{
let
url
=
block
(
self
.
pageIndex
)
saveLocalPictureSyn
(
url
)
}
}
override
func
viewDidLoad
()
{
super
.
viewDidLoad
()
view
.
addSubview
(
navBar
)
navBar
.
snp
.
makeConstraints
{
make
in
make
.
left
.
right
.
top
.
equalToSuperview
()
make
.
height
.
equalTo
(
k_Height_NavigationtBarAndStatuBar
)
}
}
func
saveLocalPictureSyn
(
_
picUrl
:
String
)
{
let
imageView
=
UIImageView
()
imageView
.
kf
.
setImage
(
with
:
URL
(
string
:
picUrl
))
{
result
in
switch
result
{
case
.
success
(
let
value
):
self
.
saveImage
(
value
.
image
)
case
.
failure
:
YHHUD
.
flash
(
message
:
"保存失败"
)
}
}
}
func
saveImage
(
_
image
:
UIImage
)
{
// 确保应用有权访问相册
PHPhotoLibrary
.
requestAuthorization
{
status
in
if
status
==
.
authorized
{
// 保存图片到相册
DispatchQueue
.
main
.
async
{
UIImageWriteToSavedPhotosAlbum
(
image
,
nil
,
nil
,
nil
)
YHHUD
.
flash
(
message
:
"保存成功"
)
}
}
else
{
DispatchQueue
.
main
.
async
{
YHHUD
.
flash
(
message
:
"保存失败,请检查系统权限"
)
}
}
}
}
}
galaxy/galaxy/Classes/Modules/PictureReview(图片预览)/YHPictureReviewManager.swift
View file @
7b435ffb
...
...
@@ -30,7 +30,7 @@ extension YHPictureReviewManager {
self
.
curIndex
=
curIndex
self
.
arrPics
=
arrPicturs
let
browser
=
JXPhotoBrows
er
()
let
browser
=
YHPictureBrowserViewControll
er
()
browser
.
numberOfItems
=
{
self
.
arrPics
.
count
}
...
...
@@ -54,6 +54,14 @@ extension YHPictureReviewManager {
}
}
browser
.
getImgUrlBlock
=
{
[
weak
self
]
index
in
guard
let
self
=
self
else
{
return
""
}
if
0
<=
index
,
index
<
self
.
arrPics
.
count
{
return
self
.
arrPics
[
index
]
}
return
""
}
// 数字样式的页码指示器
browser
.
pageIndicator
=
JXPhotoBrowserNumberPageIndicator
()
browser
.
pageIndex
=
self
.
curIndex
...
...
galaxy/galaxy/Classes/Modules/Plan(方案)/C/YHPlanPolicyDetailViewController.swift
View file @
7b435ffb
...
...
@@ -43,16 +43,19 @@ class YHPlanPolicyDetailViewController: YHBaseViewController {
}()
lazy
var
collectionView
:
UICollectionView
=
{
let
layout
=
UICollectionViewFlowLayout
()
layout
.
minimumInteritemSpacing
=
0.0
layout
.
minimumLineSpacing
=
0.0
layout
.
scrollDirection
=
.
horizontal
let
collectView
=
UICollectionView
(
frame
:
CGRect
(
x
:
0
,
y
:
k_Height_NavigationtBarAndStatuBar
+
24.0
,
width
:
KScreenWidth
,
height
:
520
),
collectionViewLayout
:
layout
)
collectView
.
backgroundColor
=
.
clear
collectView
.
delegate
=
self
collectView
.
dataSource
=
self
collectView
.
register
(
YHPlanShareImageCell
.
self
,
forCellWithReuseIdentifier
:
YHPlanShareImageCell
.
cellReuseIdentifier
)
collectView
.
isPagingEnabled
=
true
collectView
.
showsHorizontalScrollIndicator
=
false
return
collectView
}()
...
...
@@ -204,7 +207,9 @@ extension YHPlanPolicyDetailViewController: UICollectionViewDelegate, UICollecti
func
collectionView
(
_
collectionView
:
UICollectionView
,
didSelectItemAt
indexPath
:
IndexPath
)
{
if
0
<=
indexPath
.
item
&&
indexPath
.
item
<
imgs
.
count
{
// let text = topicArr[indexPath.item]
let
model
=
imgs
[
indexPath
.
item
]
YHPictureReviewManager
.
shared
.
showNetWorkPicturs
(
curIndex
:
0
,
arrPicturs
:
[
model
.
model
.
image_poster
])
}
}
}
...
...
galaxy/galaxy/Classes/Modules/Plan(方案)/V/YHPlanAnalyzeInfoCell.swift
View file @
7b435ffb
...
...
@@ -11,6 +11,15 @@ import AttributedString
class
YHPlanAnalyzeInfoView
:
UIView
{
var
desc
:
String
=
""
{
didSet
{
if
desc
.
isEmpty
{
descLabel
.
text
=
"——"
}
else
{
descLabel
.
text
=
desc
}
}
}
lazy
var
titleLabel
:
UILabel
=
{
let
lable
=
UILabel
()
lable
.
textColor
=
UIColor
.
mainTextColor
...
...
@@ -88,9 +97,9 @@ class YHPlanAnalyzeInfoCell: UITableViewCell {
let
bb
:
ASAttributedString
=
.
init
(
"/5.0"
,
.
font
(
UIFont
(
name
:
"DINAlternate-Bold"
,
size
:
14
)
!
),
.
foreground
(
UIColor
.
init
(
hex
:
0x8993A2
)))
scoreLabel
.
attributed
.
text
=
aa
+
bb
currentStateVeiw
.
desc
Label
.
text
=
model
.
current_state
requireVeiw
.
desc
Label
.
text
=
model
.
hong_kong_policy
suggestVeiw
.
desc
Label
.
text
=
model
.
suggest
currentStateVeiw
.
desc
=
model
.
current_state
requireVeiw
.
desc
=
model
.
hong_kong_policy
suggestVeiw
.
desc
=
model
.
suggest
products
=
model
.
solution_plan
}
...
...
galaxy/galaxy/Classes/Modules/Plan(方案)/V/YHPlanPolicyCarouselView.swift
View file @
7b435ffb
...
...
@@ -69,7 +69,7 @@ class YHPlanPolicyCarouselView: UIView {
pageControl
.
numberOfPages
=
0
pageControl
.
currentPage
=
0
pageControl
.
dotColor
=
.
init
(
hex
:
0xD5DAE1
)
pageControl
.
selectedDotColor
=
.
brandMain
Color
pageControl
.
selectedDotColor
=
.
mainText
Color
return
pageControl
}()
...
...
galaxy/galaxy/Classes/Modules/Plan(方案)/V/YHPlanProductListView.swift
View file @
7b435ffb
...
...
@@ -17,9 +17,9 @@ class YHPlanProductItemView: UIView {
titleLabel
.
text
=
product
.
title
descLabel
.
text
=
product
.
description
if
let
url
=
URL
(
string
:
product
.
img_url
)
{
iconImgV
.
sd_setImage
(
with
:
url
,
placeholderImage
:
UIImage
(
named
:
"
global_default_image
"
))
iconImgV
.
sd_setImage
(
with
:
url
,
placeholderImage
:
UIImage
(
named
:
"
plan_product_default
"
))
}
else
{
iconImgV
.
image
=
UIImage
(
named
:
"
global_default_image
"
)
iconImgV
.
image
=
UIImage
(
named
:
"
plan_product_default
"
)
}
}
}
...
...
@@ -141,7 +141,7 @@ class YHPlanProductListView: UIView {
let
lable
=
UILabel
()
lable
.
textColor
=
UIColor
.
init
(
hex
:
0xAE6C32
)
lable
.
textAlignment
=
.
left
lable
.
font
=
UIFont
.
PFSC_M
(
ofSize
:
1
5
)
lable
.
font
=
UIFont
.
PFSC_M
(
ofSize
:
1
3
)
lable
.
text
=
"增购以下产品可提升生活联系"
return
lable
}()
...
...
galaxy/galaxy/Res/Assets.xcassets/AI-Chat/photo_brower_save.imageset/Contents.json
0 → 100644
View file @
7b435ffb
{
"images"
:
[
{
"idiom"
:
"universal"
,
"scale"
:
"1x"
},
{
"filename"
:
"下保存图片@2x.png"
,
"idiom"
:
"universal"
,
"scale"
:
"2x"
},
{
"filename"
:
"下保存图片@3x.png"
,
"idiom"
:
"universal"
,
"scale"
:
"3x"
}
],
"info"
:
{
"author"
:
"xcode"
,
"version"
:
1
},
"properties"
:
{
"template-rendering-intent"
:
"template"
}
}
galaxy/galaxy/Res/Assets.xcassets/AI-Chat/photo_brower_save.imageset/下保存图片@2x.png
0 → 100644
View file @
7b435ffb
485 Bytes
galaxy/galaxy/Res/Assets.xcassets/AI-Chat/photo_brower_save.imageset/下保存图片@3x.png
0 → 100644
View file @
7b435ffb
654 Bytes
galaxy/galaxy/Res/Assets.xcassets/Plan/plan_product_default.imageset/Contents.json
0 → 100644
View file @
7b435ffb
{
"images"
:
[
{
"idiom"
:
"universal"
,
"scale"
:
"1x"
},
{
"filename"
:
"缺省图@2x.png"
,
"idiom"
:
"universal"
,
"scale"
:
"2x"
},
{
"filename"
:
"缺省图@3x.png"
,
"idiom"
:
"universal"
,
"scale"
:
"3x"
}
],
"info"
:
{
"author"
:
"xcode"
,
"version"
:
1
}
}
galaxy/galaxy/Res/Assets.xcassets/Plan/plan_product_default.imageset/缺省图@2x.png
0 → 100644
View file @
7b435ffb
1.39 KB
galaxy/galaxy/Res/Assets.xcassets/Plan/plan_product_default.imageset/缺省图@3x.png
0 → 100644
View file @
7b435ffb
2 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