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
08752ff9
Commit
08752ff9
authored
Aug 06, 2024
by
pete谢兆麟
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
我的文书我的签字 添加实名认证UI及逻辑
parent
3a80d9dd
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
434 additions
and
0 deletions
+434
-0
project.pbxproj
galaxy/galaxy.xcodeproj/project.pbxproj
+4
-0
YHMyDocumentsDetailViewController.swift
...Documents(我的文书)/C/YHMyDocumentsDetailViewController.swift
+12
-0
YHMyDocumentsDetailViewModel.swift
...uments(我的文书)/ViewModel/YHMyDocumentsDetailViewModel.swift
+24
-0
YHMySignatureDetailViewController.swift
...Signature(我的签字)/C/YHMySignatureDetailViewController.swift
+12
-0
YHSignAppendStepView.swift
...vice(服务中心)/MySignature(我的签字)/V/YHSignAppendStepView.swift
+336
-0
YHMySignatureDetailViewModel.swift
...)/MySignature(我的签字)/VM/YHMySignatureDetailViewModel.swift
+24
-0
Contents.json
...ceCenter/我的文书和签字/service_step_tips.imageset/Contents.json
+22
-0
service_step_tips@2x.png
...文书和签字/service_step_tips.imageset/service_step_tips@2x.png
+0
-0
service_step_tips@3x.png
...文书和签字/service_step_tips.imageset/service_step_tips@3x.png
+0
-0
No files found.
galaxy/galaxy.xcodeproj/project.pbxproj
View file @
08752ff9
...
...
@@ -301,6 +301,7 @@
047AA3F62C50E773009C4554
/* YHShareCashOutModel.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
047AA3F52C50E773009C4554
/* YHShareCashOutModel.swift */
;
};
047AA3F82C5CC7B0009C4554
/* YHShareStepView.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
047AA3F72C5CC7B0009C4554
/* YHShareStepView.swift */
;
};
047AA3FA2C60739E009C4554
/* YHInvitationWithGiftsSelectItemView.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
047AA3F92C60739E009C4554
/* YHInvitationWithGiftsSelectItemView.swift */
;
};
047AA3FC2C61EE7F009C4554
/* YHSignAppendStepView.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
047AA3FB2C61EE7F009C4554
/* YHSignAppendStepView.swift */
;
};
0480976B2BA15269000B9DCA
/* YHCertificateInfoCell.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
0480976A2BA15269000B9DCA
/* YHCertificateInfoCell.swift */
;
};
0480976D2BA158A1000B9DCA
/* YHCertificateListVC.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
0480976C2BA158A1000B9DCA
/* YHCertificateListVC.swift */
;
};
048097712BA18D66000B9DCA
/* YHCertificateSearchBar.swift in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
048097702BA18D66000B9DCA
/* YHCertificateSearchBar.swift */
;
};
...
...
@@ -934,6 +935,7 @@
047AA3F52C50E773009C4554
/* YHShareCashOutModel.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHShareCashOutModel.swift
;
sourceTree
=
"<group>"
;
};
047AA3F72C5CC7B0009C4554
/* YHShareStepView.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHShareStepView.swift
;
sourceTree
=
"<group>"
;
};
047AA3F92C60739E009C4554
/* YHInvitationWithGiftsSelectItemView.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHInvitationWithGiftsSelectItemView.swift
;
sourceTree
=
"<group>"
;
};
047AA3FB2C61EE7F009C4554
/* YHSignAppendStepView.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHSignAppendStepView.swift
;
sourceTree
=
"<group>"
;
};
0480976A2BA15269000B9DCA
/* YHCertificateInfoCell.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHCertificateInfoCell.swift
;
sourceTree
=
"<group>"
;
};
0480976C2BA158A1000B9DCA
/* YHCertificateListVC.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHCertificateListVC.swift
;
sourceTree
=
"<group>"
;
};
048097702BA18D66000B9DCA
/* YHCertificateSearchBar.swift */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.swift
;
path
=
YHCertificateSearchBar.swift
;
sourceTree
=
"<group>"
;
};
...
...
@@ -1916,6 +1918,7 @@
0435FA802BA186D600024EAE
/* YHMyFileMethodTableViewCell.swift */
,
044CF8D32BB6BCF700008CE8
/* YHSignatureUploadTableViewCell.swift */
,
0435FA7E2BA178C100024EAE
/* YHCommonAlertView.swift */
,
047AA3FB2C61EE7F009C4554
/* YHSignAppendStepView.swift */
,
);
path
=
V
;
sourceTree
=
"<group>"
;
...
...
@@ -4023,6 +4026,7 @@
045EEE962B9F171A0022A143
/* YHPreviewInfoCertificatePictureItemsView.swift in Sources */
,
A592FE912BA6CC010062FACA
/* YHCertificateEntryHeadView.swift in Sources */
,
0425E63D2BA9345200A5E763
/* YHSchemeTableViewCell.swift in Sources */
,
047AA3FC2C61EE7F009C4554
/* YHSignAppendStepView.swift in Sources */
,
044D0C1E2C22CFBF00C5CF5E
/* YHEditWorkViewController.swift in Sources */
,
A5ACE9302B4564F7002C94D2
/* Algorithm.swift in Sources */
,
045EEED52B9F171A0022A143
/* YHEducationRequestViewModel.swift in Sources */
,
...
...
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/MyDocuments(我的文书)/C/YHMyDocumentsDetailViewController.swift
View file @
08752ff9
...
...
@@ -558,6 +558,18 @@ extension YHMyDocumentsDetailViewController: UITableViewDelegate, UITableViewDat
present
(
safariViewController
,
animated
:
true
,
completion
:
nil
)
})
}
}
else
if
error
?
.
errorCode
==
1008612
{
YHSignAppendStepView
.
show
{[
weak
self
]
name
,
phone
in
guard
let
self
=
self
else
{
return
}
self
.
viewModel
.
requestSignaturePersonalWithNameAndPhoneURL
(
name
:
name
,
phone
:
phone
,
callBackBlock
:
{[
weak
self
]
success
,
error
in
guard
let
self
=
self
else
{
return
}
let
url
=
URL
(
string
:
self
.
viewModel
.
personalUrl
)
??
URL
(
fileURLWithPath
:
""
)
let
safariViewController
=
SFSafariViewController
(
url
:
url
)
safariViewController
.
dismissButtonStyle
=
.
close
safariViewController
.
delegate
=
self
safariViewController
.
modalPresentationStyle
=
.
fullScreen
})
}
}
else
{
if
success
??
false
{
let
url
=
URL
(
string
:
self
.
viewModel
.
pageUrl
)
??
URL
(
fileURLWithPath
:
""
)
...
...
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/MyDocuments(我的文书)/ViewModel/YHMyDocumentsDetailViewModel.swift
View file @
08752ff9
...
...
@@ -175,6 +175,30 @@ class YHMyDocumentsDetailViewModel: YHBaseViewModel {
}
}
func
requestSignaturePersonalWithNameAndPhoneURL
(
name
:
String
,
phone
:
String
,
callBackBlock
:
@escaping
(
_
success
:
Bool
?,
_
error
:
YHErrorModel
?)
->
())
{
let
params
:
[
String
:
Any
]
=
[
"user_name"
:
name
,
"mobile"
:
phone
]
let
strUrl
=
YHBaseUrlManager
.
shared
.
curURL
()
+
YHAllApiName
.
Signature
.
personalUrl
let
_
=
YHNetRequest
.
postRequest
(
url
:
strUrl
)
{
[
weak
self
]
json
,
code
in
//1. json字符串 转 对象
guard
let
self
=
self
else
{
return
}
if
json
.
code
==
200
{
let
dic
=
json
.
data
guard
let
result
=
YHMySignatureURLModel
.
deserialize
(
from
:
dic
as?
Dictionary
)
else
{
callBackBlock
(
false
,
nil
)
return
}
self
.
personalUrl
=
result
.
url
callBackBlock
(
true
,
nil
)
}
else
{
let
error
:
YHErrorModel
=
YHErrorModel
(
errorCode
:
Int32
(
json
.
code
),
errorMsg
:
json
.
msg
)
callBackBlock
(
false
,
error
)
}
}
failBlock
:
{
err
in
callBackBlock
(
false
,
err
)
}
}
func
requestSignatureLook
(
_
id
:
String
,
callBackBlock
:
@escaping
(
_
success
:
Bool
,
_
error
:
YHErrorModel
?)
->
())
{
let
params
:
[
String
:
Any
]
=
[
"id"
:
id
]
let
strUrl
=
YHBaseUrlManager
.
shared
.
curURL
()
+
YHAllApiName
.
Signature
.
look
...
...
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/MySignature(我的签字)/C/YHMySignatureDetailViewController.swift
View file @
08752ff9
...
...
@@ -408,6 +408,18 @@ extension YHMySignatureDetailViewController: UITableViewDelegate, UITableViewDat
present
(
safariViewController
,
animated
:
true
,
completion
:
nil
)
})
}
}
else
if
error
?
.
errorCode
==
1008612
{
YHSignAppendStepView
.
show
{[
weak
self
]
name
,
phone
in
guard
let
self
=
self
else
{
return
}
self
.
viewModel
.
requestSignaturePersonalWithNameAndPhoneURL
(
name
:
name
,
phone
:
phone
,
callBackBlock
:
{[
weak
self
]
success
,
error
in
guard
let
self
=
self
else
{
return
}
let
url
=
URL
(
string
:
self
.
viewModel
.
personalUrl
)
??
URL
(
fileURLWithPath
:
""
)
let
safariViewController
=
SFSafariViewController
(
url
:
url
)
safariViewController
.
dismissButtonStyle
=
.
close
safariViewController
.
delegate
=
self
safariViewController
.
modalPresentationStyle
=
.
fullScreen
})
}
}
else
{
if
success
??
false
{
let
url
=
URL
(
string
:
self
.
viewModel
.
pageUrl
)
??
URL
(
fileURLWithPath
:
""
)
...
...
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/MySignature(我的签字)/V/YHSignAppendStepView.swift
0 → 100644
View file @
08752ff9
//
// YHSignAppendStepView.swift
// galaxy
//
// Created by EDY on 2024/8/6.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import
UIKit
import
IQKeyboardManagerSwift
class
YHSignAppendStepView
:
UIView
{
var
backDate
:
((
String
,
String
)
->
Void
)?
var
centerView
:
UIView
!
var
titleLabel
:
UILabel
!
var
closeButton
:
UIButton
!
var
tipsView
:
UIView
!
var
iconImageView
:
UIImageView
!
var
tipsLabel
:
UILabel
!
var
sureButton
:
UIButton
!
var
lineView
:
UIView
!
var
nameLabel
:
UILabel
!
var
phoneLabel
:
UILabel
!
var
nameLine
:
UIView
!
var
phoneLine
:
UIView
!
var
nameTextField
:
UITextField
!
var
phoneTextField
:
UITextField
!
override
init
(
frame
:
CGRect
)
{
super
.
init
(
frame
:
frame
)
backgroundColor
=
UIColor
(
white
:
0.5
,
alpha
:
0.1
)
let
tap
=
UITapGestureRecognizer
(
target
:
self
,
action
:
#selector(
handleTap
)
)
tap
.
delegate
=
self
addGestureRecognizer
(
tap
)
setView
()
addKeyBoardNotify
()
}
required
init
?(
coder
:
NSCoder
)
{
fatalError
(
"init(coder:) has not been implemented"
)
}
func
setView
()
{
backgroundColor
=
UIColor
(
hex
:
0x0000
,
alpha
:
0.5
)
centerView
=
{
let
view
=
UIView
()
view
.
backgroundColor
=
.
white
return
view
}()
addSubview
(
centerView
)
centerView
.
snp
.
makeConstraints
{
make
in
make
.
left
.
right
.
bottom
.
equalToSuperview
()
make
.
height
.
equalTo
(
391
)
}
titleLabel
=
{
let
label
=
UILabel
()
label
.
font
=
UIFont
.
PFSC_M
(
ofSize
:
17
)
label
.
textColor
=
UIColor
.
mainTextColor
label
.
textAlignment
=
.
center
label
.
text
=
"信息确认"
return
label
}()
centerView
.
addSubview
(
titleLabel
)
titleLabel
.
snp
.
makeConstraints
{
make
in
make
.
top
.
equalTo
(
16
)
make
.
height
.
equalTo
(
24
)
make
.
width
.
equalTo
(
200
)
make
.
centerX
.
equalToSuperview
()
}
closeButton
=
{
let
button
=
UIButton
(
type
:
.
custom
)
button
.
setImage
(
UIImage
(
named
:
"my_cer_sheet_close"
),
for
:
.
normal
)
button
.
addTarget
(
self
,
action
:
#selector(
dismiss
)
,
for
:
.
touchUpInside
)
return
button
}()
centerView
.
addSubview
(
closeButton
)
closeButton
.
snp
.
makeConstraints
{
make
in
make
.
right
.
equalTo
(
-
21
)
make
.
height
.
width
.
equalTo
(
24
)
make
.
top
.
equalTo
(
16
)
}
tipsView
=
{
let
view
=
UIView
()
view
.
backgroundColor
=
UIColor
.
brandMainColor
.
withAlphaComponent
(
0.04
)
return
view
}()
centerView
.
addSubview
(
tipsView
)
tipsView
.
snp
.
makeConstraints
{
make
in
make
.
right
.
equalTo
(
-
20
)
make
.
left
.
equalTo
(
20
)
make
.
height
.
width
.
equalTo
(
42
)
make
.
top
.
equalTo
(
72
)
}
iconImageView
=
{
let
view
=
UIImageView
()
view
.
image
=
UIImage
(
named
:
"service_step_tips"
)
return
view
}()
tipsView
.
addSubview
(
iconImageView
)
iconImageView
.
snp
.
makeConstraints
{
make
in
make
.
centerY
.
equalToSuperview
()
make
.
left
.
equalTo
(
12
)
make
.
height
.
width
.
equalTo
(
14
)
}
tipsLabel
=
{
let
label
=
UILabel
()
label
.
font
=
UIFont
.
PFSC_M
(
ofSize
:
12
)
label
.
textColor
=
UIColor
.
brandMainColor
label
.
textAlignment
=
.
center
label
.
text
=
"注意:手机号与姓名必须匹配,否则无法完成签署"
return
label
}()
tipsView
.
addSubview
(
tipsLabel
)
tipsLabel
.
snp
.
makeConstraints
{
make
in
make
.
centerY
.
equalToSuperview
()
make
.
height
.
equalTo
(
18
)
make
.
right
.
equalToSuperview
()
make
.
left
.
equalTo
(
33.5
)
}
nameLabel
=
{
let
label
=
UILabel
()
label
.
font
=
UIFont
.
PFSC_M
(
ofSize
:
14
)
label
.
textColor
=
UIColor
.
mainTextColor
label
.
textAlignment
=
.
center
label
.
text
=
"姓名"
return
label
}()
centerView
.
addSubview
(
nameLabel
)
nameLabel
.
snp
.
makeConstraints
{
make
in
make
.
top
.
equalTo
(
146
)
make
.
height
.
equalTo
(
20
)
make
.
width
.
equalTo
(
60
)
make
.
left
.
equalTo
(
20
)
}
phoneLabel
=
{
let
label
=
UILabel
()
label
.
font
=
UIFont
.
PFSC_M
(
ofSize
:
14
)
label
.
textColor
=
UIColor
.
mainTextColor
label
.
textAlignment
=
.
center
label
.
text
=
"手机号"
return
label
}()
centerView
.
addSubview
(
phoneLabel
)
phoneLabel
.
snp
.
makeConstraints
{
make
in
make
.
top
.
equalTo
(
198
)
make
.
height
.
equalTo
(
20
)
make
.
width
.
equalTo
(
60
)
make
.
left
.
equalTo
(
20
)
}
nameLine
=
{
let
view
=
UIView
()
view
.
backgroundColor
=
UIColor
.
separatorColor
return
view
}()
centerView
.
addSubview
(
nameLine
)
nameLine
.
snp
.
makeConstraints
{
make
in
make
.
left
.
equalTo
(
18
)
make
.
top
.
equalTo
(
182
)
make
.
height
.
equalTo
(
1
)
make
.
right
.
equalTo
(
-
18
)
}
phoneLine
=
{
let
view
=
UIView
()
view
.
backgroundColor
=
UIColor
.
separatorColor
return
view
}()
centerView
.
addSubview
(
phoneLine
)
phoneLine
.
snp
.
makeConstraints
{
make
in
make
.
left
.
equalTo
(
18
)
make
.
top
.
equalTo
(
234
)
make
.
height
.
equalTo
(
1
)
make
.
right
.
equalTo
(
-
18
)
}
nameTextField
=
{
let
textField
=
UITextField
()
// textField.delegate = self
textField
.
textColor
=
UIColor
.
mainTextColor
textField
.
font
=
UIFont
.
PFSC_M
(
ofSize
:
14
)
textField
.
addTarget
(
self
,
action
:
#selector(
textFieldDidChanged
)
,
for
:
.
editingChanged
)
textField
.
placeholder
=
"请输入姓名"
return
textField
}()
centerView
.
addSubview
(
nameTextField
)
nameTextField
.
snp
.
makeConstraints
{
make
in
make
.
top
.
equalTo
(
146
)
make
.
height
.
equalTo
(
20
)
make
.
right
.
equalTo
(
-
20
)
make
.
left
.
equalTo
(
118
)
}
phoneTextField
=
{
let
textField
=
UITextField
()
// textField.delegate = self
textField
.
textColor
=
UIColor
.
mainTextColor
textField
.
font
=
UIFont
.
PFSC_M
(
ofSize
:
14
)
textField
.
addTarget
(
self
,
action
:
#selector(
textFieldDidChanged
)
,
for
:
.
editingChanged
)
textField
.
placeholder
=
"请输入手机号"
textField
.
keyboardType
=
.
numberPad
return
textField
}()
centerView
.
addSubview
(
phoneTextField
)
phoneTextField
.
snp
.
makeConstraints
{
make
in
make
.
top
.
equalTo
(
198
)
make
.
height
.
equalTo
(
20
)
make
.
right
.
equalTo
(
-
20
)
make
.
left
.
equalTo
(
118
)
}
sureButton
=
{
let
button
=
UIButton
(
type
:
.
custom
)
button
.
titleLabel
?
.
font
=
UIFont
.
PFSC_M
(
ofSize
:
16
)
button
.
contentHorizontalAlignment
=
.
center
button
.
setTitle
(
"确定"
,
for
:
.
normal
)
button
.
setTitleColor
(
UIColor
.
white
,
for
:
.
normal
)
button
.
backgroundColor
=
UIColor
.
brandMainColor
.
withAlphaComponent
(
0.3
)
button
.
isEnabled
=
false
button
.
layer
.
cornerRadius
=
3
button
.
addTarget
(
self
,
action
:
#selector(
sure
)
,
for
:
.
touchUpInside
)
return
button
}()
centerView
.
addSubview
(
sureButton
)
sureButton
.
snp
.
makeConstraints
{
make
in
make
.
right
.
equalTo
(
-
16
)
make
.
height
.
equalTo
(
44
)
make
.
left
.
equalTo
(
16
)
make
.
bottom
.
equalTo
(
-
46
)
}
lineView
=
{
let
view
=
UIView
()
view
.
backgroundColor
=
UIColor
.
separatorColor
return
view
}()
centerView
.
addSubview
(
lineView
)
lineView
.
snp
.
makeConstraints
{
make
in
make
.
left
.
equalTo
(
18
)
make
.
top
.
equalTo
(
52
)
make
.
height
.
equalTo
(
1
)
make
.
right
.
equalTo
(
-
18
)
}
centerView
.
layoutIfNeeded
()
let
corner
=
UIRectCorner
(
rawValue
:
UIRectCorner
.
topLeft
.
rawValue
|
UIRectCorner
.
topRight
.
rawValue
)
let
path
=
UIBezierPath
(
roundedRect
:
bounds
,
byRoundingCorners
:
corner
,
cornerRadii
:
CGSizeMake
(
8
,
8
))
let
layer
=
CAShapeLayer
()
layer
.
frame
=
centerView
.
bounds
layer
.
path
=
path
.
cgPath
centerView
.
layer
.
mask
=
layer
}
@objc
private
func
handleTap
(
_
sender
:
AnyObject
?)
{
print
(
"处理点击手势"
)
dismiss
()
}
static
func
show
(
callBack
:
@escaping
((
String
,
String
)
->
Void
))
{
let
view
=
YHSignAppendStepView
(
frame
:
CGRect
(
x
:
0
,
y
:
0
,
width
:
KScreenWidth
,
height
:
KScreenHeight
))
view
.
backDate
=
callBack
let
window
=
UIApplication
.
shared
.
yhKeyWindow
()
window
?
.
addSubview
(
view
)
}
@objc
func
dismiss
()
{
removeFromSuperview
()
}
@objc
func
sure
()
{
if
let
block
=
backDate
{
block
(
nameTextField
.
text
??
""
,
phoneTextField
.
text
??
""
)
}
dismiss
()
}
@objc
func
textFieldDidChanged
()
{
if
nameTextField
.
text
?
.
count
??
0
>
0
,
phoneTextField
.
text
?
.
count
??
0
>
0
{
sureButton
.
backgroundColor
=
UIColor
.
brandMainColor
sureButton
.
isEnabled
=
true
}
else
{
sureButton
.
backgroundColor
=
UIColor
.
brandMainColor
.
withAlphaComponent
(
0.3
)
sureButton
.
isEnabled
=
false
}
}
}
extension
YHSignAppendStepView
:
UIGestureRecognizerDelegate
{
func
gestureRecognizer
(
_
gestureRecognizer
:
UIGestureRecognizer
,
shouldReceive
touch
:
UITouch
)
->
Bool
{
if
touch
.
view
==
self
{
return
true
}
return
false
}
}
extension
YHSignAppendStepView
{
func
addKeyBoardNotify
()
{
NotificationCenter
.
default
.
addObserver
(
self
,
selector
:
#selector(
handleKeyboardNotification(_:)
)
,
name
:
UIResponder
.
keyboardWillShowNotification
,
object
:
nil
)
NotificationCenter
.
default
.
addObserver
(
self
,
selector
:
#selector(
handleKeyboardNotification(_:)
)
,
name
:
UIResponder
.
keyboardWillHideNotification
,
object
:
nil
)
}
func
removeNotify
()
{
NotificationCenter
.
default
.
removeObserver
(
self
)
}
@objc
func
handleKeyboardNotification
(
_
notification
:
Notification
)
{
if
notification
.
userInfo
!=
nil
{
guard
let
keyboardFrame
=
(
notification
.
userInfo
?[
UIResponder
.
keyboardFrameEndUserInfoKey
]
as
AnyObject
)
.
cgRectValue
else
{
return
}
let
isKeyboardShow
=
notification
.
name
==
UIResponder
.
keyboardWillShowNotification
let
bottomMargin
=
(
isKeyboardShow
?
-
keyboardFrame
.
height
:
0
)
if
!
isKeyboardShow
{
IQKeyboardManager
.
shared
.
enable
=
true
}
self
.
centerView
.
snp
.
updateConstraints
{
make
in
make
.
bottom
.
equalToSuperview
()
.
offset
(
bottomMargin
)
}
self
.
setNeedsLayout
()
self
.
layoutIfNeeded
()
}
}
}
galaxy/galaxy/Classes/Modules/IntelligentService(服务中心)/MySignature(我的签字)/VM/YHMySignatureDetailViewModel.swift
View file @
08752ff9
...
...
@@ -88,6 +88,30 @@ class YHMySignatureDetailViewModel: YHBaseViewModel {
}
}
func
requestSignaturePersonalWithNameAndPhoneURL
(
name
:
String
,
phone
:
String
,
callBackBlock
:
@escaping
(
_
success
:
Bool
?,
_
error
:
YHErrorModel
?)
->
())
{
let
params
:
[
String
:
Any
]
=
[
"user_name"
:
name
,
"mobile"
:
phone
]
let
strUrl
=
YHBaseUrlManager
.
shared
.
curURL
()
+
YHAllApiName
.
Signature
.
personalUrl
let
_
=
YHNetRequest
.
postRequest
(
url
:
strUrl
)
{
[
weak
self
]
json
,
code
in
//1. json字符串 转 对象
guard
let
self
=
self
else
{
return
}
if
json
.
code
==
200
{
let
dic
=
json
.
data
guard
let
result
=
YHMySignatureURLModel
.
deserialize
(
from
:
dic
as?
Dictionary
)
else
{
callBackBlock
(
false
,
nil
)
return
}
self
.
personalUrl
=
result
.
url
callBackBlock
(
true
,
nil
)
}
else
{
let
error
:
YHErrorModel
=
YHErrorModel
(
errorCode
:
Int32
(
json
.
code
),
errorMsg
:
json
.
msg
)
callBackBlock
(
false
,
error
)
}
}
failBlock
:
{
err
in
callBackBlock
(
false
,
err
)
}
}
func
requestSignCallBack
(
_
id
:
String
,
callBackBlock
:
@escaping
(
_
success
:
Bool
,
_
error
:
YHErrorModel
?)
->
())
{
// let params: [String : Any] = ["order_id": orderId]
let
params
:
[
String
:
Any
]
=
[
"id"
:
id
]
...
...
galaxy/galaxy/Res/Assets.xcassets/ServiceCenter/我的文书和签字/service_step_tips.imageset/Contents.json
0 → 100644
View file @
08752ff9
{
"images"
:
[
{
"idiom"
:
"universal"
,
"scale"
:
"1x"
},
{
"filename"
:
"service_step_tips@2x.png"
,
"idiom"
:
"universal"
,
"scale"
:
"2x"
},
{
"filename"
:
"service_step_tips@3x.png"
,
"idiom"
:
"universal"
,
"scale"
:
"3x"
}
],
"info"
:
{
"author"
:
"xcode"
,
"version"
:
1
}
}
galaxy/galaxy/Res/Assets.xcassets/ServiceCenter/我的文书和签字/service_step_tips.imageset/service_step_tips@2x.png
0 → 100644
View file @
08752ff9
815 Bytes
galaxy/galaxy/Res/Assets.xcassets/ServiceCenter/我的文书和签字/service_step_tips.imageset/service_step_tips@3x.png
0 → 100644
View file @
08752ff9
1.12 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