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
1f1ecc32
Commit
1f1ecc32
authored
Aug 27, 2024
by
Steven杜宇
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
// 赴港指引
parent
be1b3029
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
48 additions
and
15 deletions
+48
-15
YHServiceOrderListViewController.swift
...entService(服务中心)/C/YHServiceOrderListViewController.swift
+41
-2
YHPrincipleUploadListVC.swift
...rvice/PrincipleBatch(原则批)/C/YHPrincipleUploadListVC.swift
+0
-6
YHMyViewController.swift
...alaxy/Classes/Modules/Mine(我的)/C/YHMyViewController.swift
+1
-7
String+Extension.swift
galaxy/galaxy/Classes/Tools/Extention/String+Extension.swift
+6
-0
No files found.
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/C/YHServiceOrderListViewController.swift
View file @
1f1ecc32
...
...
@@ -12,7 +12,8 @@ import JXSegmentedView
class
YHServiceOrderListView
:
YHBaseViewController
{
private
let
viewModel
:
YHServiceCenterMainViewModel
=
YHServiceCenterMainViewModel
()
let
principleViewModel
:
YHPrincleViewModel
=
YHPrincleViewModel
()
let
appointViewModel
=
YHCerAppointViewModel
()
typealias
Block
=
(
Int
,
Int
,
Bool
)
->
()
var
block
:
Block
?
var
orderID
:
Int
=
0
...
...
@@ -263,7 +264,45 @@ extension YHServiceOrderListView : UITableViewDelegate,UITableViewDataSource {
self
.
navigationController
?
.
pushViewController
(
vc
)
}
else
if
model
.
type
==
25
{
//赴港行程指引
// 赴港行程指引
YHHUD
.
show
(
.
progress
(
message
:
"加载中..."
))
appointViewModel
.
getIsNeedGoToHK
(
orderId
:
orderID
)
{
// needGoHK 1需要赴港 0不需要 2没有选择
// reservationToHK 0 没有预约 1 已经预約
[
weak
self
]
needGoHK
,
reservationToHK
in
YHHUD
.
hide
()
guard
let
self
=
self
else
{
return
}
var
isNeedAppoint
=
true
if
needGoHK
==
1
,
reservationToHK
==
1
{
// 选择赴港且已预约
isNeedAppoint
=
false
}
if
isNeedAppoint
{
//预约弹窗
let
alert
=
YHDisappointHKAlertView
.
alertView
()
alert
.
confirmBlock
=
{
let
vc
=
YHCertificateAppointViewController
()
vc
.
orderId
=
self
.
orderID
self
.
navigationController
?
.
pushViewController
(
vc
)
}
alert
.
show
()
}
else
{
// 已预约过直接进入赴港行程指引
if
var
token
=
YHLoginManager
.
shared
.
userModel
?
.
token
{
var
url
=
YHBaseUrlManager
.
shared
.
curH5URL
()
+
"superAppBridge.html#/tohkList"
let
addtionString
=
String
.
randomAlphaNumericStringT
(
6
)
//随机6个字母或者数字
let
indexToInsert
=
token
.
index
(
token
.
startIndex
,
offsetBy
:
6
)
//插入位置,这里以第六个字符后面为例
token
.
insert
(
contentsOf
:
addtionString
,
at
:
indexToInsert
)
url
=
url
+
"?paramO=
\(
self
.
orderID
)
"
+
"¶m="
+
token
let
vc
=
YHH5WebViewVC
()
vc
.
url
=
url
self
.
navigationController
?
.
pushViewController
(
vc
)
}
}
}
}
else
if
model
.
type
==
26
{
//旅行证件准备
let
vc
=
YHTravelDocsPreparationListViewController
()
...
...
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/CustomerService/PrincipleBatch(原则批)/C/YHPrincipleUploadListVC.swift
View file @
1f1ecc32
...
...
@@ -514,12 +514,6 @@ extension YHPrincipleUploadListVC: UITableViewDelegate, UITableViewDataSource {
return
view
}
func
randomAlphaNumericString
(
_
length
:
Int
)
->
String
{
let
letters
=
"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"
let
randomString
=
(
0
..<
length
)
.
map
{
_
in
String
(
letters
.
randomElement
()
!
)
}
.
reduce
(
""
,
+
)
return
randomString
}
func
showPreviewAndMailList
(
_
model
:
YHPrincipleAgreementModel
)
{
//弹窗 选择发送邮箱
...
...
galaxy/galaxy/Classes/Modules/Mine(我的)/C/YHMyViewController.swift
View file @
1f1ecc32
...
...
@@ -377,7 +377,7 @@ extension YHMyViewController : UITableViewDelegate, UITableViewDataSource {
var
token
:
String
=
param
var
url
=
YHBaseUrlManager
.
shared
.
curH5URL
()
+
"superApp/integral"
let
addtionString
=
randomAlphanumericString
(
6
)
//随机6个字母或者数字
let
addtionString
=
String
.
randomAlphaNumericStringT
(
6
)
//随机6个字母或者数字
let
indexToInsert
=
token
.
index
(
token
.
startIndex
,
offsetBy
:
6
)
//插入位置,这里以第六个字符后面为例
token
.
insert
(
contentsOf
:
addtionString
,
at
:
indexToInsert
)
url
=
url
+
"?param="
+
token
...
...
@@ -432,12 +432,6 @@ extension YHMyViewController : UITableViewDelegate, UITableViewDataSource {
extension
YHMyViewController
{
func
randomAlphanumericString
(
_
length
:
Int
)
->
String
{
let
letters
=
"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"
let
randomString
=
(
0
..<
length
)
.
map
{
_
in
String
(
letters
.
randomElement
()
!
)
}
.
reduce
(
""
,
+
)
return
randomString
}
@objc
func
loginSuccess
()
{
printLog
(
"登录成功,进行相应的 UI刷新操作"
)
updateUserUI
()
...
...
galaxy/galaxy/Classes/Tools/Extention/String+Extension.swift
View file @
1f1ecc32
...
...
@@ -19,6 +19,12 @@ func isEmptyString(_ string: String?) -> Bool {
extension
String
{
static
func
randomAlphaNumericStringT
(
_
length
:
Int
)
->
String
{
let
letters
=
"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"
let
randomString
=
(
0
..<
length
)
.
map
{
_
in
String
(
letters
.
randomElement
()
!
)
}
.
reduce
(
""
,
+
)
return
randomString
}
/// JSONString转换为字典
func
toDictionary
()
->
Dictionary
<
String
,
Any
>
{
guard
let
jsonData
:
Data
=
data
(
using
:
.
utf8
)
else
{
return
[
String
:
Any
]()
}
...
...
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