Commit 69c77f5c authored by Alex朱枝文's avatar Alex朱枝文

续签在港缴费页面调整

parent 90c050a9
......@@ -230,6 +230,20 @@
044F39402CB7CB6B007CA277 /* YHVisaRenewalTroubleshootingGuideVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 044F393F2CB7CB6B007CA277 /* YHVisaRenewalTroubleshootingGuideVC.swift */; };
044F39422CB7CCBB007CA277 /* YHVisaRenewalTroubleshootingGuideHeaderCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 044F39412CB7CCBB007CA277 /* YHVisaRenewalTroubleshootingGuideHeaderCell.swift */; };
044F39442CB7D72C007CA277 /* YHVisaRenewalWorkflowCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 044F39432CB7D72C007CA277 /* YHVisaRenewalWorkflowCell.swift */; };
044F39462CB80611007CA277 /* YHVisaRenewalSectionHeaderCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 044F39452CB80611007CA277 /* YHVisaRenewalSectionHeaderCell.swift */; };
044F39482CB80626007CA277 /* YHVisaRenewalTipsCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 044F39472CB80626007CA277 /* YHVisaRenewalTipsCell.swift */; };
044F394A2CB8068E007CA277 /* YHVisaRenewalResidenceActionCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 044F39492CB8068E007CA277 /* YHVisaRenewalResidenceActionCell.swift */; };
044F394C2CB806D0007CA277 /* YHVisaRenewalPayMethodUrlCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 044F394B2CB806D0007CA277 /* YHVisaRenewalPayMethodUrlCell.swift */; };
044F394E2CB806E6007CA277 /* YHVisaRenewalPayMethodQrcodeCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 044F394D2CB806E6007CA277 /* YHVisaRenewalPayMethodQrcodeCell.swift */; };
044F39502CB80706007CA277 /* YHVisaRenewalPayStatusCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 044F394F2CB80706007CA277 /* YHVisaRenewalPayStatusCell.swift */; };
044F39522CB80719007CA277 /* YHVisaRenewalPayInfoCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 044F39512CB80719007CA277 /* YHVisaRenewalPayInfoCell.swift */; };
044F39542CB80731007CA277 /* YHVisaRenewalPayTipsCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 044F39532CB80731007CA277 /* YHVisaRenewalPayTipsCell.swift */; };
044F39562CB8C2FC007CA277 /* YHVisaRenewalPresenceStatus.swift in Sources */ = {isa = PBXBuildFile; fileRef = 044F39552CB8C2FC007CA277 /* YHVisaRenewalPresenceStatus.swift */; };
044F395C2CB8D58A007CA277 /* YHVisaRenewalPayInfoBaseCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 044F395B2CB8D58A007CA277 /* YHVisaRenewalPayInfoBaseCell.swift */; };
044F395E2CB8D7EC007CA277 /* YHVisaRenewalPayOccupyingSpaceCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 044F395D2CB8D7EC007CA277 /* YHVisaRenewalPayOccupyingSpaceCell.swift */; };
044F39602CB8F3F9007CA277 /* YHVisaRenewalPaymentStatus.swift in Sources */ = {isa = PBXBuildFile; fileRef = 044F395F2CB8F3F9007CA277 /* YHVisaRenewalPaymentStatus.swift */; };
044F39622CB8FF16007CA277 /* YHVisaRenewalPayContentCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 044F39612CB8FF16007CA277 /* YHVisaRenewalPayContentCell.swift */; };
044F39642CB90501007CA277 /* YHVisaRenewalItemDetailType.swift in Sources */ = {isa = PBXBuildFile; fileRef = 044F39632CB90501007CA277 /* YHVisaRenewalItemDetailType.swift */; };
04506F552C6F57E600738EA1 /* YHFamilyMemberInfoCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04506F542C6F57E600738EA1 /* YHFamilyMemberInfoCell.swift */; };
045A08C02C37ABF500BCBABA /* YHSegmentView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 045A08BF2C37ABF500BCBABA /* YHSegmentView.swift */; };
045A08C22C37EB8B00BCBABA /* YHMyFileListNoneCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 045A08C12C37EB8B00BCBABA /* YHMyFileListNoneCell.swift */; };
......@@ -1134,6 +1148,20 @@
044F393F2CB7CB6B007CA277 /* YHVisaRenewalTroubleshootingGuideVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHVisaRenewalTroubleshootingGuideVC.swift; sourceTree = "<group>"; };
044F39412CB7CCBB007CA277 /* YHVisaRenewalTroubleshootingGuideHeaderCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHVisaRenewalTroubleshootingGuideHeaderCell.swift; sourceTree = "<group>"; };
044F39432CB7D72C007CA277 /* YHVisaRenewalWorkflowCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHVisaRenewalWorkflowCell.swift; sourceTree = "<group>"; };
044F39452CB80611007CA277 /* YHVisaRenewalSectionHeaderCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHVisaRenewalSectionHeaderCell.swift; sourceTree = "<group>"; };
044F39472CB80626007CA277 /* YHVisaRenewalTipsCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHVisaRenewalTipsCell.swift; sourceTree = "<group>"; };
044F39492CB8068E007CA277 /* YHVisaRenewalResidenceActionCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHVisaRenewalResidenceActionCell.swift; sourceTree = "<group>"; };
044F394B2CB806D0007CA277 /* YHVisaRenewalPayMethodUrlCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHVisaRenewalPayMethodUrlCell.swift; sourceTree = "<group>"; };
044F394D2CB806E6007CA277 /* YHVisaRenewalPayMethodQrcodeCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHVisaRenewalPayMethodQrcodeCell.swift; sourceTree = "<group>"; };
044F394F2CB80706007CA277 /* YHVisaRenewalPayStatusCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHVisaRenewalPayStatusCell.swift; sourceTree = "<group>"; };
044F39512CB80719007CA277 /* YHVisaRenewalPayInfoCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHVisaRenewalPayInfoCell.swift; sourceTree = "<group>"; };
044F39532CB80731007CA277 /* YHVisaRenewalPayTipsCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHVisaRenewalPayTipsCell.swift; sourceTree = "<group>"; };
044F39552CB8C2FC007CA277 /* YHVisaRenewalPresenceStatus.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHVisaRenewalPresenceStatus.swift; sourceTree = "<group>"; };
044F395B2CB8D58A007CA277 /* YHVisaRenewalPayInfoBaseCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHVisaRenewalPayInfoBaseCell.swift; sourceTree = "<group>"; };
044F395D2CB8D7EC007CA277 /* YHVisaRenewalPayOccupyingSpaceCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHVisaRenewalPayOccupyingSpaceCell.swift; sourceTree = "<group>"; };
044F395F2CB8F3F9007CA277 /* YHVisaRenewalPaymentStatus.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHVisaRenewalPaymentStatus.swift; sourceTree = "<group>"; };
044F39612CB8FF16007CA277 /* YHVisaRenewalPayContentCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHVisaRenewalPayContentCell.swift; sourceTree = "<group>"; };
044F39632CB90501007CA277 /* YHVisaRenewalItemDetailType.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHVisaRenewalItemDetailType.swift; sourceTree = "<group>"; };
04506F542C6F57E600738EA1 /* YHFamilyMemberInfoCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHFamilyMemberInfoCell.swift; sourceTree = "<group>"; };
045A08BF2C37ABF500BCBABA /* YHSegmentView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHSegmentView.swift; sourceTree = "<group>"; };
045A08C12C37EB8B00BCBABA /* YHMyFileListNoneCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHMyFileListNoneCell.swift; sourceTree = "<group>"; };
......@@ -2513,6 +2541,9 @@
044F39292CB54C07007CA277 /* M */ = {
isa = PBXGroup;
children = (
044F39552CB8C2FC007CA277 /* YHVisaRenewalPresenceStatus.swift */,
044F39632CB90501007CA277 /* YHVisaRenewalItemDetailType.swift */,
044F395F2CB8F3F9007CA277 /* YHVisaRenewalPaymentStatus.swift */,
);
path = M;
sourceTree = "<group>";
......@@ -2530,6 +2561,17 @@
044F39392CB7772D007CA277 /* YHVisaRenewalGuideRemarkCell.swift */,
044F393B2CB777D3007CA277 /* YHVisaRenewalGuideIndentCell.swift */,
044F393D2CB7827B007CA277 /* YHVisaRenewalGuideTipsCell.swift */,
044F39452CB80611007CA277 /* YHVisaRenewalSectionHeaderCell.swift */,
044F39472CB80626007CA277 /* YHVisaRenewalTipsCell.swift */,
044F39492CB8068E007CA277 /* YHVisaRenewalResidenceActionCell.swift */,
044F394B2CB806D0007CA277 /* YHVisaRenewalPayMethodUrlCell.swift */,
044F394D2CB806E6007CA277 /* YHVisaRenewalPayMethodQrcodeCell.swift */,
044F395B2CB8D58A007CA277 /* YHVisaRenewalPayInfoBaseCell.swift */,
044F395D2CB8D7EC007CA277 /* YHVisaRenewalPayOccupyingSpaceCell.swift */,
044F394F2CB80706007CA277 /* YHVisaRenewalPayStatusCell.swift */,
044F39512CB80719007CA277 /* YHVisaRenewalPayInfoCell.swift */,
044F39612CB8FF16007CA277 /* YHVisaRenewalPayContentCell.swift */,
044F39532CB80731007CA277 /* YHVisaRenewalPayTipsCell.swift */,
);
path = V;
sourceTree = "<group>";
......@@ -5177,6 +5219,7 @@
045EEEA12B9F171A0022A143 /* YHWorkExperienceDetailModel.swift in Sources */,
A5573ED22B317BFF00D98EC0 /* AppDelegate.swift in Sources */,
A5ACE9542B4564F7002C94D2 /* YHNavigationController.swift in Sources */,
044F39642CB90501007CA277 /* YHVisaRenewalItemDetailType.swift in Sources */,
044D0C002C21663300C5CF5E /* YHMyInformationItemCell.swift in Sources */,
045EEF252B9F171A0022A143 /* YHMainInformationCardTableViewCell.swift in Sources */,
04AD317B2C2428CB00DF5655 /* YHPeopleSuccessView.swift in Sources */,
......@@ -5336,6 +5379,7 @@
04F243552C9C435A00DF2C74 /* YHHKRecordsInfoItemCell.swift in Sources */,
A5D0012C2BABC84A001F003C /* YHFileListBottomView.swift in Sources */,
0485DFDC2C670C7200B50293 /* YHPrincipleSendMailView.swift in Sources */,
044F394A2CB8068E007CA277 /* YHVisaRenewalResidenceActionCell.swift in Sources */,
04E41DE82BD240570077EAE3 /* YHOrderDetailViewController.swift in Sources */,
A5FD63C52B637EE000D1D9DA /* YHSubmitAllInfoCheckView.swift in Sources */,
045EEF222B9F171A0022A143 /* YHImagePickerView.swift in Sources */,
......@@ -5347,6 +5391,7 @@
045EEEB22B9F171A0022A143 /* YHWorkActionView.swift in Sources */,
04CA2BF02CB7A74C00F36DE7 /* YHResignUploadTravelHKViewController.swift in Sources */,
A58AC09F2BAC05BA00A30FA9 /* YHFileListItemsView.swift in Sources */,
044F39562CB8C2FC007CA277 /* YHVisaRenewalPresenceStatus.swift in Sources */,
A5000F512C3BC28B00843452 /* YHHomeHoldViewPageViewController.swift in Sources */,
04CE1ACF2C2AD91F001CB80A /* YHActivityViewModel.swift in Sources */,
045EEE8C2B9F171A0022A143 /* YHPreviewMainViewController.swift in Sources */,
......@@ -5372,6 +5417,7 @@
045EEF1A2B9F171A0022A143 /* YHAddressViewController.swift in Sources */,
A5C382CA2B5E1F4C00C5E65C /* YHLoginTipsView.swift in Sources */,
A5765B282C772185002CD3C1 /* YHRangeDatePickerCell.swift in Sources */,
044F39602CB8F3F9007CA277 /* YHVisaRenewalPaymentStatus.swift in Sources */,
04FB01D02C23FA420040115D /* YHMatchUserInfo.swift in Sources */,
045EEEE92B9F171A0022A143 /* YHFamilyRequestViewModel.swift in Sources */,
04B360E72C60CD37001EB053 /* YHPrincipleUploadFileCell.swift in Sources */,
......@@ -5415,6 +5461,7 @@
049AC4C62BC3E55300F857F4 /* YHServiceSectionView.swift in Sources */,
04256E152C75BD2700A37BA4 /* YHPayMembersCell.swift in Sources */,
0408C3632BEC7C6900DB1E25 /* YHVideoPlayerControlView.swift in Sources */,
044F394C2CB806D0007CA277 /* YHVisaRenewalPayMethodUrlCell.swift in Sources */,
A567E5B12BD7643D00D5D5A0 /* YHHomeCollectionViewCell.swift in Sources */,
A582B2432BB95E20009D098C /* YHHKPlanCell.swift in Sources */,
04256DE62C7310BE00A37BA4 /* YHSelectApplicantGroupCell.swift in Sources */,
......@@ -5438,6 +5485,7 @@
048B2A4D2BC7DAE800A93BF0 /* YHMyLikeViewModel.swift in Sources */,
04C693622B723AB8004C1758 /* YHMySettingViewController.swift in Sources */,
045EEECD2B9F171A0022A143 /* YHScoreDataModel.swift in Sources */,
044F39622CB8FF16007CA277 /* YHVisaRenewalPayContentCell.swift in Sources */,
04F2432F2C94704200DF2C74 /* YHPaddedLabel.swift in Sources */,
A5ACE9342B4564F7002C94D2 /* YHAllApiName.swift in Sources */,
04AF82D62C25542D0028CE2A /* YHInterestTopicLayout.swift in Sources */,
......@@ -5455,6 +5503,7 @@
A59B43C72C48F68200B28379 /* YHEvaluationView.swift in Sources */,
045EEF122B9F171A0022A143 /* YHCNIDCardModel.swift in Sources */,
045EEF032B9F171A0022A143 /* YHFormItemDoubleChoiceCell.swift in Sources */,
044F39482CB80626007CA277 /* YHVisaRenewalTipsCell.swift in Sources */,
0430E6842C76D702000511E2 /* YHAddpterViewModel.swift in Sources */,
045EEEAE2B9F171A0022A143 /* YHWorkHighlightsTableViewCell.swift in Sources */,
A567E59A2BD7643D00D5D5A0 /* YHHomeKingKongBlockModel.swift in Sources */,
......@@ -5545,6 +5594,7 @@
A5EB6C712C69FB9A0081FB6C /* YHOffivialApprovalSuccessView.swift in Sources */,
A567E5AD2BD7643D00D5D5A0 /* YHSearchInfoHistoryCell.swift in Sources */,
04CE1ADC2C2AD91F001CB80A /* YHActivityTipsItemView.swift in Sources */,
044F39462CB80611007CA277 /* YHVisaRenewalSectionHeaderCell.swift in Sources */,
048058312C7DBDC900502CAA /* YHTravelCertificateTipsView.swift in Sources */,
04CCEE012CA165070026EA70 /* YHHKImmigrationEditRecordModel.swift in Sources */,
A5EF21332BA6E030005027E6 /* YHFileListViewController.swift in Sources */,
......@@ -5676,6 +5726,7 @@
A58556BA2B6BCF1A003746B2 /* YHPersonInfoFillStepModel.swift in Sources */,
045EEEC92B9F171A0022A143 /* YHOtherInfoSessionView.swift in Sources */,
A567E59B2BD7643D00D5D5A0 /* YHWebModel.swift in Sources */,
044F395E2CB8D7EC007CA277 /* YHVisaRenewalPayOccupyingSpaceCell.swift in Sources */,
A5EE41EF2C21387C005BBA5D /* YHAiRadarAreaView.swift in Sources */,
0430E6662C7487B8000511E2 /* YHAdopterTravelItemTableViewCell.swift in Sources */,
045EEEE22B9F171A0022A143 /* YHMySignatureDetailViewModel.swift in Sources */,
......@@ -5787,6 +5838,7 @@
04256E1F2C7618A800A37BA4 /* YHAppointWarmTipsCell.swift in Sources */,
04256E132C75BD2700A37BA4 /* YHPayMemberContentItems.swift in Sources */,
A5FD63C12B62616D00D1D9DA /* YHInformationPerfectModel.swift in Sources */,
044F395C2CB8D58A007CA277 /* YHVisaRenewalPayInfoBaseCell.swift in Sources */,
A567E5A62BD7643D00D5D5A0 /* YHHomeSearchView.swift in Sources */,
045EEE912B9F171A0022A143 /* YHPreviewInfoCertificatePictureItemView.swift in Sources */,
04358E082C77657000811928 /* YHReAppointViewController.swift in Sources */,
......@@ -5817,6 +5869,7 @@
04CA2BE82CB769CD00F36DE7 /* YHResignUploadTravelCardListViewController.swift in Sources */,
0480976D2BA158A1000B9DCA /* YHCertificateListVC.swift in Sources */,
04CCEDFF2CA161910026EA70 /* YHHKRecordsFamilyMembers.swift in Sources */,
044F39522CB80719007CA277 /* YHVisaRenewalPayInfoCell.swift in Sources */,
0430E6522C733D82000511E2 /* YHAdopterIncomeFileTableViewCell.swift in Sources */,
045EEE8B2B9F171A0022A143 /* YHPreviewMainApplicantInfoViewController.swift in Sources */,
04256E162C75BD2700A37BA4 /* YHPayMemberSectionItem.swift in Sources */,
......@@ -5825,6 +5878,7 @@
0430E6482C731B0A000511E2 /* YHAdopterAddNewTableViewCell.swift in Sources */,
A5EB6C742C69FB9A0081FB6C /* YHOfficailLetterColledtionCell.swift in Sources */,
045EEEF92B9F171A0022A143 /* YHFormItemTitleCell.swift in Sources */,
044F394E2CB806E6007CA277 /* YHVisaRenewalPayMethodQrcodeCell.swift in Sources */,
A580371E2BAD784B0031C312 /* YHMySchemeViewModel.swift in Sources */,
0425E6482BA96B4100A5E763 /* YHSchemeHeadScoreItemView.swift in Sources */,
04A271252BAC33BB00652B1B /* YHFilePreviewTool.swift in Sources */,
......@@ -5862,6 +5916,7 @@
045EEE872B9F171A0022A143 /* YHPreviewControllerHoldViewController.swift in Sources */,
0419A0A22C49099A00A5FCFA /* YHInvitationWithGiftsShareBottomView.swift in Sources */,
04AAA8DC2BF5E5A200FE9FD5 /* YHEmptyDataView.swift in Sources */,
044F39502CB80706007CA277 /* YHVisaRenewalPayStatusCell.swift in Sources */,
A5A89FD72C256B94005A71DD /* YHHomeLastMessageModel.swift in Sources */,
045EEF172B9F171A0022A143 /* YHSelectCountryViewController.swift in Sources */,
044CF8D62BBA57DC00008CE8 /* YHFailPromptView.swift in Sources */,
......@@ -5938,6 +5993,7 @@
045EEEF52B9F171A0022A143 /* YHSpouseInfoContainerVC.swift in Sources */,
047AA3F62C50E773009C4554 /* YHShareCashOutModel.swift in Sources */,
0472CBAC2C5A11640096F48F /* YHPrincleViewModel.swift in Sources */,
044F39542CB80731007CA277 /* YHVisaRenewalPayTipsCell.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
......
......@@ -10,7 +10,7 @@ import UIKit
class YHBaseDynamicCornerRadiusView: UIView {
private var radius: CGFloat = 8
public var radius: CGFloat = 8
public var corner: UIRectCorner? {
didSet {
if corner != oldValue {
......
......@@ -7,6 +7,9 @@
//
import UIKit
import AttributedString
import SafariServices
import Photos
class YHHKVisaRenewalPaymentVC: YHBaseViewController {
......@@ -17,6 +20,11 @@ class YHHKVisaRenewalPaymentVC: YHBaseViewController {
private lazy var tableView: UITableView = {
let view = UITableView(frame: .zero, style: .grouped)
view.estimatedSectionHeaderHeight = 16.0
view.estimatedSectionFooterHeight = 0.01
view.sectionHeaderHeight = 16.0
view.sectionFooterHeight = 0.01
view.contentInsetAdjustmentBehavior = .never
view.backgroundColor = .clear
view.separatorStyle = .none
view.rowHeight = UITableView.automaticDimension
......@@ -24,7 +32,17 @@ class YHHKVisaRenewalPaymentVC: YHBaseViewController {
view.dataSource = self
view.delegate = self
view.showsVerticalScrollIndicator = false
//view.register(YHHKRecordsHeaderCell.self, forCellReuseIdentifier: YHHKRecordsHeaderCell.cellReuseIdentifier)
view.register(YHVisaRenewalSectionHeaderCell.self, forCellReuseIdentifier: YHVisaRenewalSectionHeaderCell.cellReuseIdentifier)
view.register(YHVisaRenewalTipsCell.self, forCellReuseIdentifier: YHVisaRenewalTipsCell.cellReuseIdentifier)
view.register(YHVisaRenewalResidenceActionCell.self, forCellReuseIdentifier: YHVisaRenewalResidenceActionCell.cellReuseIdentifier)
view.register(YHVisaRenewalPayMethodUrlCell.self, forCellReuseIdentifier: YHVisaRenewalPayMethodUrlCell.cellReuseIdentifier)
view.register(YHVisaRenewalPayMethodQrcodeCell.self, forCellReuseIdentifier: YHVisaRenewalPayMethodQrcodeCell.cellReuseIdentifier)
view.register(YHVisaRenewalPayOccupyingSpaceCell.self, forCellReuseIdentifier: YHVisaRenewalPayOccupyingSpaceCell.cellReuseIdentifier)
view.register(YHVisaRenewalPayStatusCell.self, forCellReuseIdentifier: YHVisaRenewalPayStatusCell.cellReuseIdentifier)
view.register(YHVisaRenewalPayInfoCell.self, forCellReuseIdentifier: YHVisaRenewalPayInfoCell.cellReuseIdentifier)
view.register(YHVisaRenewalPayContentCell.self, forCellReuseIdentifier: YHVisaRenewalPayContentCell.cellReuseIdentifier)
view.register(YHVisaRenewalPayTipsCell.self, forCellReuseIdentifier: YHVisaRenewalPayTipsCell.cellReuseIdentifier)
return view
}()
......@@ -75,6 +93,8 @@ class YHHKVisaRenewalPaymentVC: YHBaseViewController {
return view
}()
private lazy var datas: [[YHVisaRenewalItemDetailType]] = []
private var didShowGuideVC = false
private let orderId: Int
......@@ -90,10 +110,12 @@ class YHHKVisaRenewalPaymentVC: YHBaseViewController {
override func viewDidLoad() {
super.viewDidLoad()
setupUI()
requestData()
}
override func viewDidAppear(_ animated: Bool) {
super.viewDidAppear(animated)
if !didShowGuideVC {
didShowGuideVC = true
let didShowGuide = YHVisaRenewalGuideVC.didShowGuide
......@@ -148,16 +170,57 @@ extension YHHKVisaRenewalPaymentVC {
make.height.equalTo(74)
}
tableView.snp.makeConstraints { make in
make.left.equalToSuperview().offset(kMargin).priority(.high)
make.right.equalToSuperview().offset(-kMargin).priority(.high)
make.left.equalToSuperview()
make.right.equalToSuperview()
make.top.equalTo(stepView.snp.bottom)
make.bottom.equalTo(bottomView.snp.top)
}
tableView.tableHeaderView = UIView(frame: CGRect.init(x: 0, y: 0, width: KScreenWidth, height: kMargin))
tableView.tableFooterView = UIView(frame: CGRect.init(x: 0, y: 0, width: KScreenWidth, height: kMargin))
}
private func requestData() {
let approvalPendingMsg = "申请人暂未获批,无法在港缴费"
let confirmedPresenceMsg = "申请人已在港"
var sections: [[YHVisaRenewalItemDetailType]] = []
let confirmingPresenceTips: ASAttributedString = .init(string: "提示:", .foreground(UIColor.yhOrangeColor)) + .init(string: "缴费前请先确认涉及到的") + .init(string: "申请人在香港", .foreground(UIColor.yhOrangeColor))
let confirmingPresenceSection: [YHVisaRenewalItemDetailType] = [.sectionHeader("确认申请人在港", nil), .tips(confirmingPresenceTips), .residenceAction("欧阳唯一", .approvalPending, .mid, {
printLog("欧阳唯一 approvalPending")
YHHUD.flash(message: approvalPendingMsg)
}), .residenceAction("欧阳唯二", .confirmingPresence, .mid, {
printLog("欧阳唯二 confirmingPresence")
}), .residenceAction("欧阳唯三", .confirmedPresence, .bottom, {
printLog("欧阳唯三 confirmedPresence")
YHHUD.flash(message: confirmedPresenceMsg)
})]
sections.append(confirmingPresenceSection)
let payMethodTips: ASAttributedString = .init(string: "提示:", .foreground(UIColor.yhOrangeColor)) + .init(string: "请先到下方“缴费成员”处") + .init(string: "复制档案号", .foreground(UIColor.yhOrangeColor)) + .init(string: "再缴费")
let webPageUrl = "https://www.gov.hk/tc/residents/immigration/nonpermanent/onlinepaymentforevisa.htm"
let qrImage = webPageUrl.generateQRCode()
let payMethodSection: [YHVisaRenewalItemDetailType] = [.sectionHeader("港府官网缴费方式", "缴费遇到问题?", { [weak self] in
printLog("缴费遇到问题")
self?.showTroubleshootingGuideVC()
}), .tips(payMethodTips), .payMethodUrl("方式一", "点击下方链接,跳转浏览器,进入港府官网操作缴费", webPageUrl, { [weak self] in
printLog("点击下方链接,跳转浏览器")
self?.gotoWebVC(webPageUrl)
}), .payMethodQrcode("方式二", "用其他设备直接扫码,或长按保存图片,通过微信识别打开", qrImage)]
sections.append(payMethodSection)
let payMembersSection: [YHVisaRenewalItemDetailType] = [.sectionHeader("缴费成员", "电子签证范例"), .occupyingSpace, .subHeader("欧阳唯一", .pendingPayment), .subInfo("档案号:", "TQEN-03709888-23", "复制", .mid, nil, false, { [weak self] in
self?.copyToPasteBoard("TQEN-03709888-23")
}), .subInfo("可缴费时间段:", "2023.10.1 - 2023.11.20", nil), .subInfo("缴费金额:", "230港币(≈211.89人民币)", nil), .subRemark("请复制档案号去港府官网缴费"), .occupyingSpace, .subHeader("欧阳唯三", .expired), .subInfo("档案号:", "TQEN-03709888-23", "复制", .mid, nil, false, { [weak self] in
self?.copyToPasteBoard("TQEN-03709888-23")
}), .subInfo("可缴费时间段:", "2023.10.1 - 2023.11.20", nil), .subInfo("缴费金额:", "230港币(≈211.89人民币)", nil, .bottom), .occupyingSpace, .subHeader("欧阳唯四", .paid), .subInfo("档案号:", "TQEN-03709888-23", "复制", .mid, 12, true, { [weak self] in
self?.copyToPasteBoard("TQEN-03709888-23")
}), .subContent("缴费电子签证:", "Visa QMEN-0021813-22.pdf", "查看", .mid, { [weak self] in
self?.gotoPreview("Visa QMEN-0021813-22.pdf")
}), .subContent("缴费电子签证链接:", "https://www.gov.hk/tc/residents/immigration/nonpermanent/onlinepaymentforevisa.htm", "复制", .bottom, { [weak self] in
self?.copyToPasteBoard("https://www.gov.hk/tc/residents/immigration/nonpermanent/onlinepaymentforevisa.htm")
}), .occupyingSpace, .subHeader("欧阳唯五", .pendingApproval), .subRemark("续签申请暂未正式获批,请耐心等待"), .occupyingSpace]
sections.append(payMembersSection)
datas = sections
tableView.reloadData()
}
private func showGuideVC() {
let vc = YHVisaRenewalGuideVC()
let pc = YHBottomPresentationController(presentedViewController: vc, presenting: self)
......@@ -169,6 +232,31 @@ extension YHHKVisaRenewalPaymentVC {
present(vc, animated: true, completion: nil)
}
private func gotoWebVC(_ urlString: String) {
guard let url = URL(string: urlString) else {
printLog("无法打开链接")
return
}
if UIApplication.shared.canOpenURL(url) {
UIApplication.shared.open(url, options: [:], completionHandler: nil)
} else {
// 显示一个提示,告知用户无法打开链接
printLog("无法打开链接")
YHHUD.flash(message: "无法打开链接")
}
}
private func gotoPreview(_ urlString: String) {
guard let url = URL(string: urlString), UIApplication.shared.canOpenURL(url) else {
YHHUD.flash(message: "无法打开链接")
return
}
let safariViewController = SFSafariViewController(url: url)
safariViewController.dismissButtonStyle = .close
safariViewController.modalPresentationStyle = .fullScreen
present(safariViewController, animated: true, completion: nil)
}
private func showTroubleshootingGuideVC() {
let vc = YHVisaRenewalTroubleshootingGuideVC()
let pc = YHBottomPresentationController(presentedViewController: vc, presenting: self)
......@@ -179,19 +267,137 @@ extension YHHKVisaRenewalPaymentVC {
}
present(vc, animated: true, completion: nil)
}
private func copyToPasteBoard(_ text: String) {
let pasteBoard = UIPasteboard.general
pasteBoard.string = text
YHHUD.flash(message: "复制成功")
}
private func saveImage(_ image: UIImage) {
// 确保应用有权访问相册
PHPhotoLibrary.requestAuthorization { status in
if status == .authorized {
// 保存UIImage对象到相册
DispatchQueue.main.async {
UIImageWriteToSavedPhotosAlbum(image, self, #selector(self.image(_:didFinishSavingWithError:contextInfo:)), nil)
}
} else {
DispatchQueue.main.async {
YHHUD.flash(message: "保存失败,请检查系统权限")
}
}
}
}
@objc func image(_ image: UIImage, didFinishSavingWithError error: Error?, contextInfo: UnsafeMutableRawPointer?) {
// 保存完成后的处理逻辑
if let error = error {
printLog("保存照片失败:\(error.localizedDescription)")
YHHUD.flash(message: "保存失败")
} else {
printLog("保存照片成功")
YHHUD.flash(message: "保存成功")
}
}
}
extension YHHKVisaRenewalPaymentVC: UITableViewDelegate, UITableViewDataSource {
func numberOfSections(in tableView: UITableView) -> Int {
return 0
return datas.count
}
func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
return 1
guard datas.count > section else {
return 0
}
let sectionArr = datas[section]
return sectionArr.count
}
func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
guard datas.count > indexPath.section else {
return UITableViewCell()
}
let sectionArr = datas[indexPath.section]
guard sectionArr.count > indexPath.row else {
return UITableViewCell()
}
let row = sectionArr[indexPath.row]
switch row {
case let .sectionHeader(title, actionTitle, action):
if let cell = tableView.dequeueReusableCell(withIdentifier: YHVisaRenewalSectionHeaderCell.cellReuseIdentifier) as? YHVisaRenewalSectionHeaderCell {
cell.setupCellInfo(title: title, buttonTitle: actionTitle)
cell.rightButtonEvent = {
action?()
}
return cell
}
case let .tips(detail):
if let cell = tableView.dequeueReusableCell(withIdentifier: YHVisaRenewalTipsCell.cellReuseIdentifier) as? YHVisaRenewalTipsCell {
cell.setupCellInfo(detail: detail)
return cell
}
case let .residenceAction(title, status, cellType, action):
if let cell = tableView.dequeueReusableCell(withIdentifier: YHVisaRenewalResidenceActionCell.cellReuseIdentifier) as? YHVisaRenewalResidenceActionCell {
cell.setupCellInfo(title: title, presenceStatus: status, cellType: cellType)
cell.rightButtonEvent = {
action?()
}
return cell
}
case let .payMethodUrl(title, detail, url, action):
if let cell = tableView.dequeueReusableCell(withIdentifier: YHVisaRenewalPayMethodUrlCell.cellReuseIdentifier) as? YHVisaRenewalPayMethodUrlCell {
cell.setupCellInfo(title: title, tips: detail, url: url)
cell.urlClicked = { _ in
action?()
}
return cell
}
case let .payMethodQrcode(title, detail, image):
if let cell = tableView.dequeueReusableCell(withIdentifier: YHVisaRenewalPayMethodQrcodeCell.cellReuseIdentifier) as? YHVisaRenewalPayMethodQrcodeCell {
cell.setupCellInfo(title: title, tips: detail, qrCode: image)
cell.onLongPressEvent = { [weak self] image in
self?.saveImage(image)
}
return cell
}
case let .subHeader(title, status):
if let cell = tableView.dequeueReusableCell(withIdentifier: YHVisaRenewalPayStatusCell.cellReuseIdentifier) as? YHVisaRenewalPayStatusCell {
cell.setupCellInfo(title: title, status: status)
return cell
}
case let .subInfo(title, detail, actionTitle, cellType, defaultMargin, showBottomLine, action):
if let cell = tableView.dequeueReusableCell(withIdentifier: YHVisaRenewalPayInfoCell.cellReuseIdentifier) as? YHVisaRenewalPayInfoCell {
cell.setupCellInfo(title: title, detail: detail, rightButtonTitle: actionTitle, cellType: cellType, defaultMargin: defaultMargin, showBottomLine: showBottomLine)
cell.rightButtonEvent = {
action?()
}
return cell
}
case let .subContent(title, detail, actionTitle, cellType, action):
if let cell = tableView.dequeueReusableCell(withIdentifier: YHVisaRenewalPayContentCell.cellReuseIdentifier) as? YHVisaRenewalPayContentCell {
cell.setupCellInfo(title: title, detail: detail, rightButtonTitle: actionTitle, cellType: cellType)
cell.rightButtonEvent = {
action?()
}
return cell
}
case let .subRemark(detail):
if let cell = tableView.dequeueReusableCell(withIdentifier: YHVisaRenewalPayTipsCell.cellReuseIdentifier) as? YHVisaRenewalPayTipsCell {
cell.setupCellInfo(detail: detail)
return cell
}
case .occupyingSpace:
if let cell = tableView.dequeueReusableCell(withIdentifier: YHVisaRenewalPayOccupyingSpaceCell.cellReuseIdentifier) as? YHVisaRenewalPayOccupyingSpaceCell {
let isBottom = indexPath.row == sectionArr.count - 1
cell.setupCellInfo(isBottom: isBottom)
return cell
}
}
return UITableViewCell()
}
......
//
// YHVisaRenewalItemDetailType.swift
// galaxy
//
// Created by alexzzw on 2024/10/11.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import Foundation
import AttributedString
enum YHVisaRenewalItemDetailType {
case sectionHeader(_ title: String, _ actionTitle: String? = nil, _ action: (() -> Void)? = nil)
case tips(_ detail: ASAttributedString)
case residenceAction(_ title: String, _ status: YHVisaRenewalPresenceStatus, _ cellType: YHResignRoundCellType = .mid, _ action: (() -> Void)? = nil)
case payMethodUrl(_ title: String, _ tips: String, _ url: String, _ action: (() -> Void)? = nil)
case payMethodQrcode(_ title: String, _ tips: String, _ image: UIImage?)
case subHeader(_ title: String, _ status: YHVisaRenewalPaymentStatus)
case subInfo(_ title: String, _ detail: String, _ actionTitle: String? = nil, _ cellType: YHResignRoundCellType = .mid, _ defaultMargin: CGFloat? = nil, _ showBottomLine: Bool = false, _ action: (() -> Void)? = nil)
case subContent(_ title: String, _ detail: String, _ actionTitle: String? = nil, _ cellType: YHResignRoundCellType = .mid, _ action: (() -> Void)? = nil)
case subRemark(_ remark: String)
case occupyingSpace
}
//
// YHVisaRenewalPaymentStatus.swift
// galaxy
//
// Created by alexzzw on 2024/10/11.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import Foundation
enum YHVisaRenewalPaymentStatus {
// 待缴费 待获批 已缴费 已过期
case pendingPayment
case pendingApproval
case paid
case expired
var title: String {
switch self {
case .pendingPayment:
return "待缴费"
case .pendingApproval:
return "待获批"
case .paid:
return "已缴费"
case .expired:
return "已过期"
}
}
var titleColor: UIColor? {
switch self {
case .pendingPayment:
return .brandMainColor
case .pendingApproval:
return .yhOrangeColor
case .paid:
return .mainTextColor50
case .expired:
return .failColor
}
}
}
//
// YHVisaRenewalPresenceStatus.swift
// galaxy
//
// Created by alexzzw on 2024/10/11.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import Foundation
enum YHVisaRenewalPresenceStatus {
// 暂未获批 确认在港 已确认在港
case approvalPending
case confirmingPresence
case confirmedPresence
var title: String {
switch self {
case .approvalPending:
return "暂未获批"
case .confirmingPresence:
return "确认在港"
case .confirmedPresence:
return "已确认在港"
}
}
var titleColor: UIColor? {
switch self {
case .approvalPending:
return .mainTextColor30
case .confirmingPresence:
return UIColor(hexString: "#FFFFFF")
case .confirmedPresence:
return .yhGreenColor
}
}
var bgColor: UIColor? {
switch self {
case .approvalPending:
return UIColor(hexString: "#F4F6FA")
case .confirmingPresence:
return .brandMainColor
case .confirmedPresence:
return .clear
}
}
}
......@@ -125,18 +125,21 @@ extension YHHKVisaRenewalPaymentStepView {
make.top.equalTo(secondStepLabel.snp.bottom).offset(6)
make.centerX.equalTo(secondStepLabel.snp.centerX)
make.bottom.equalToSuperview().offset(-16)
make.left.greaterThanOrEqualTo(firstStepNameLabel.snp.right).offset(6)
}
thirdStepNameLabel.snp.makeConstraints { make in
make.top.equalTo(thirdStepLabel.snp.bottom).offset(6)
make.centerX.equalTo(thirdStepLabel.snp.centerX)
make.bottom.equalToSuperview().offset(-16)
make.left.greaterThanOrEqualTo(secondStepNameLabel.snp.right).offset(6)
}
fourthStepNameLabel.snp.makeConstraints { make in
make.top.equalTo(fourthStepLabel.snp.bottom).offset(6)
make.centerX.equalTo(fourthStepLabel.snp.centerX)
make.bottom.equalToSuperview().offset(-16)
make.left.greaterThanOrEqualTo(thirdStepNameLabel.snp.right).offset(6)
}
}
......
......@@ -61,6 +61,7 @@ class YHVisaRenewalGuideHeaderCell: UITableViewCell {
label.textColor = .mainTextColor70
label.text = "获批后,3个月内完成缴费,否则身份会失效"
label.numberOfLines = 0
label.lineBreakMode = .byCharWrapping
return label
}()
......@@ -70,6 +71,7 @@ class YHVisaRenewalGuideHeaderCell: UITableViewCell {
label.textColor = .mainTextColor70
label.text = "缴费领取电子签证时,涉及到的申请人应身在香港"
label.numberOfLines = 0
label.lineBreakMode = .byCharWrapping
return label
}()
......@@ -91,6 +93,7 @@ class YHVisaRenewalGuideHeaderCell: UITableViewCell {
label.textColor = UIColor(hex: 0xFF8000)
label.text = "在港缴费领取电子签证时使用的入境证件,请务必和递交续签资料时入境香港使用的旅行证件保持一致"
label.numberOfLines = 0
label.lineBreakMode = .byCharWrapping
return label
}()
......@@ -99,6 +102,7 @@ class YHVisaRenewalGuideHeaderCell: UITableViewCell {
label.font = .PFSC_B(ofSize: 16)
label.textColor = .mainTextColor
label.numberOfLines = 0
label.lineBreakMode = .byCharWrapping
label.text = "一、递交续签申请后,未离境一直在港"
return label
}()
......@@ -108,6 +112,7 @@ class YHVisaRenewalGuideHeaderCell: UITableViewCell {
label.font = .PFSC_R(ofSize: 14)
label.textColor = .mainTextColor70
label.numberOfLines = 0
label.lineBreakMode = .byCharWrapping
let paragraphStyle = NSMutableParagraphStyle()
paragraphStyle.lineHeightMultiple = 1.07
let attributedText = NSAttributedString(
......
......@@ -33,6 +33,7 @@ class YHVisaRenewalGuideIndentCell: UITableViewCell {
label.font = .PFSC_R(ofSize: 13)
label.textColor = .mainTextColor70
label.numberOfLines = 0
label.lineBreakMode = .byCharWrapping
return label
}()
......
......@@ -16,6 +16,7 @@ class YHVisaRenewalGuideParagraphCell: UITableViewCell {
label.font = .PFSC_B(ofSize: 16)
label.textColor = .mainTextColor
label.numberOfLines = 0
label.lineBreakMode = .byCharWrapping
return label
}()
......@@ -24,6 +25,7 @@ class YHVisaRenewalGuideParagraphCell: UITableViewCell {
label.font = .PFSC_R(ofSize: 14)
label.textColor = .mainTextColor70
label.numberOfLines = 0
label.lineBreakMode = .byCharWrapping
return label
}()
......
......@@ -16,6 +16,7 @@ class YHVisaRenewalGuideRemarkCell: UITableViewCell {
label.font = .PFSC_R(ofSize: 14)
label.textColor = .mainTextColor70
label.numberOfLines = 0
label.lineBreakMode = .byCharWrapping
return label
}()
......
......@@ -30,6 +30,7 @@ class YHVisaRenewalGuideTipsCell: UITableViewCell {
label.font = .PFSC_R(ofSize: 13)
label.textColor = .mainTextColor70
label.numberOfLines = 0
label.lineBreakMode = .byCharWrapping
return label
}()
......
//
// YHVisaRenewalPayContentCell.swift
// galaxy
//
// Created by alexzzw on 2024/10/11.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import UIKit
class YHVisaRenewalPayContentCell: YHVisaRenewalPayInfoBaseCell {
static let cellReuseIdentifier = "YHVisaRenewalPayContentCell"
var rightButtonEvent: (() -> Void)?
private lazy var infoTitleLabel: UILabel = {
let label = UILabel()
label.font = .PFSC_R(ofSize: 13)
label.textColor = .mainTextColor70
return label
}()
private lazy var infoDetailLabel: UILabel = {
let label = UILabel()
label.font = .PFSC_M(ofSize: 13)
label.textColor = UIColor(hexString: "#222222")
label.numberOfLines = 0
label.lineBreakMode = .byCharWrapping
return label
}()
private lazy var rightButton: UIButton = {
let button = UIButton(type: .custom)
button.setTitleColor(.mainTextColor, for: .normal)
button.titleLabel?.font = .PFSC_M(ofSize: 10)
button.backgroundColor = .separatorColor
button.layer.cornerRadius = 8
button.clipsToBounds = true
button.addTarget(self, action: #selector(rightButtonClicked), for: .touchUpInside)
return button
}()
private lazy var bottomLineView: UIView = {
let view = UIView()
view.backgroundColor = .separatorColor
return view
}()
override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
super.init(style: style, reuseIdentifier: reuseIdentifier)
setupUI()
}
required init?(coder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
func setupCellInfo(title: String, detail: String, rightButtonTitle: String? = nil, cellType: YHResignRoundCellType = .mid) {
infoTitleLabel.text = title
infoDetailLabel.text = detail
updateInnerCellCorner(cellType)
let bottomMargin = cellType == .bottom ? 16 : 12
bottomLineView.isHidden = cellType == .bottom
infoDetailLabel.snp.remakeConstraints { make in
make.top.equalTo(infoTitleLabel.snp.bottom).offset(12)
make.right.lessThanOrEqualToSuperview().offset(-16)
make.left.equalTo(infoTitleLabel)
make.bottom.equalToSuperview().offset(-bottomMargin)
}
if let rightButtonTitle = rightButtonTitle, rightButtonTitle.count > 0 {
rightButton.setTitle(rightButtonTitle, for: .normal)
rightButton.isHidden = false
} else {
rightButton.setTitle(nil, for: .normal)
rightButton.isHidden = true
}
}
}
extension YHVisaRenewalPayContentCell {
@objc private func rightButtonClicked() {
rightButtonEvent?()
}
private func setupUI() {
updateInnerCellCorner(.mid)
innerContainerView.addSubview(rightButton)
innerContainerView.addSubview(infoTitleLabel)
innerContainerView.addSubview(infoDetailLabel)
innerContainerView.addSubview(bottomLineView)
rightButton.setContentCompressionResistancePriority(.required, for: .horizontal)
infoTitleLabel.setContentCompressionResistancePriority(.defaultLow, for: .horizontal)
bottomLineView.snp.makeConstraints { make in
make.left.equalToSuperview().offset(16)
make.right.equalToSuperview().offset(-16)
make.bottom.equalToSuperview()
make.height.equalTo(0.5)
}
infoTitleLabel.snp.makeConstraints { make in
make.left.equalToSuperview().offset(16)
make.top.equalToSuperview().offset(12)
}
rightButton.snp.makeConstraints { make in
make.right.equalToSuperview().offset(-16)
make.width.equalTo(36)
make.height.equalTo(18)
make.centerY.equalTo(infoTitleLabel)
make.left.greaterThanOrEqualTo(infoTitleLabel.snp.right).offset(12)
}
infoDetailLabel.snp.makeConstraints { make in
make.top.equalTo(infoTitleLabel.snp.bottom).offset(12)
make.right.lessThanOrEqualToSuperview().offset(-16)
make.left.equalTo(infoTitleLabel)
make.bottom.equalToSuperview().offset(-12)
}
}
}
//
// YHVisaRenewalPayInfoBaseCell.swift
// galaxy
//
// Created by alexzzw on 2024/10/11.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import UIKit
class YHVisaRenewalPayInfoBaseCell: YHResignDocumentCell {
lazy var innerContainerView: YHBaseDynamicCornerRadiusView = {
let view = YHBaseDynamicCornerRadiusView(cornerRadius: 6, corner: .none)
view.backgroundColor = .contentBkgColor
return view
}()
override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
super.init(style: style, reuseIdentifier: reuseIdentifier)
setupUI()
}
required init?(coder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
func updateInnerCellCorner(_ cellType: YHResignRoundCellType) {
switch cellType {
case .top:
innerContainerView.corner = [.topLeft, .topRight]
case .mid:
innerContainerView.corner = .none
case .bottom:
innerContainerView.corner = [.bottomLeft, .bottomRight]
case .single:
innerContainerView.corner = .allCorners
}
}
}
extension YHVisaRenewalPayInfoBaseCell {
private func setupUI() {
subContainerView.radius = 6
updateCellCorner(.mid)
subContainerView.addSubview(innerContainerView)
innerContainerView.snp.makeConstraints { make in
make.top.bottom.equalToSuperview()
make.left.equalToSuperview().offset(18)
make.right.equalToSuperview().offset(-18)
}
}
}
//
// YHVisaRenewalPayInfoCell.swift
// galaxy
//
// Created by alexzzw on 2024/10/10.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import UIKit
class YHVisaRenewalPayInfoCell: YHVisaRenewalPayInfoBaseCell {
static let cellReuseIdentifier = "YHVisaRenewalPayInfoCell"
var rightButtonEvent: (() -> Void)?
private lazy var infoTitleLabel: UILabel = {
let label = UILabel()
label.font = .PFSC_R(ofSize: 13)
label.textColor = .mainTextColor70
return label
}()
private lazy var infoDetailLabel: UILabel = {
let label = UILabel()
label.font = .PFSC_M(ofSize: 13)
label.textColor = .mainTextColor
return label
}()
private lazy var rightButton: UIButton = {
let button = UIButton(type: .custom)
button.setTitleColor(.mainTextColor, for: .normal)
button.titleLabel?.font = .PFSC_M(ofSize: 10)
button.backgroundColor = .separatorColor
button.layer.cornerRadius = 8
button.clipsToBounds = true
button.addTarget(self, action: #selector(rightButtonClicked), for: .touchUpInside)
return button
}()
private lazy var bottomLineView: UIView = {
let view = UIView()
view.backgroundColor = .separatorColor
view.isHidden = true
return view
}()
override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
super.init(style: style, reuseIdentifier: reuseIdentifier)
setupUI()
}
required init?(coder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
func setupCellInfo(title: String, detail: String, rightButtonTitle: String? = nil, cellType: YHResignRoundCellType = .mid, defaultMargin: CGFloat? = nil, showBottomLine: Bool = false) {
infoTitleLabel.text = title
infoDetailLabel.text = detail
updateInnerCellCorner(cellType)
bottomLineView.isHidden = !showBottomLine
var bottomMargin: CGFloat = cellType == .bottom ? 16 : 0
if let defaultMargin = defaultMargin {
bottomMargin = defaultMargin
}
if let rightButtonTitle = rightButtonTitle, rightButtonTitle.count > 0 {
rightButton.setTitle(rightButtonTitle, for: .normal)
rightButton.isHidden = false
infoDetailLabel.snp.remakeConstraints { make in
make.right.equalTo(rightButton.snp.left).offset(-6)
make.left.greaterThanOrEqualTo(infoTitleLabel.snp.right).offset(12)
make.centerY.equalTo(infoTitleLabel)
make.bottom.equalToSuperview().offset(-bottomMargin)
}
} else {
rightButton.setTitle(nil, for: .normal)
rightButton.isHidden = true
infoDetailLabel.snp.remakeConstraints { make in
make.right.equalToSuperview().offset(-16)
make.left.greaterThanOrEqualTo(infoTitleLabel.snp.right).offset(12)
make.centerY.equalTo(infoTitleLabel)
make.bottom.equalToSuperview().offset(-bottomMargin)
}
}
}
}
extension YHVisaRenewalPayInfoCell {
@objc private func rightButtonClicked() {
rightButtonEvent?()
}
private func setupUI() {
updateInnerCellCorner(.mid)
innerContainerView.addSubview(rightButton)
innerContainerView.addSubview(infoTitleLabel)
innerContainerView.addSubview(infoDetailLabel)
innerContainerView.addSubview(bottomLineView)
rightButton.setContentCompressionResistancePriority(.required, for: .horizontal)
infoTitleLabel.setContentCompressionResistancePriority(.defaultLow, for: .horizontal)
infoDetailLabel.setContentCompressionResistancePriority(.required, for: .horizontal)
bottomLineView.snp.makeConstraints { make in
make.left.equalToSuperview().offset(16)
make.right.equalToSuperview().offset(-16)
make.bottom.equalToSuperview()
make.height.equalTo(0.5)
}
infoTitleLabel.snp.makeConstraints { make in
make.left.equalToSuperview().offset(16)
make.top.equalToSuperview().offset(12)
}
rightButton.snp.makeConstraints { make in
make.right.equalToSuperview().offset(-16)
make.width.equalTo(36)
make.height.equalTo(18)
make.centerY.equalTo(infoTitleLabel)
}
infoDetailLabel.snp.makeConstraints { make in
make.right.equalTo(rightButton.snp.left).offset(-6)
make.left.greaterThanOrEqualTo(infoTitleLabel.snp.right).offset(12)
make.centerY.equalTo(infoTitleLabel)
make.bottom.equalToSuperview()
}
}
}
//
// YHVisaRenewalPayMethodQrcodeCell.swift
// galaxy
//
// Created by alexzzw on 2024/10/10.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import UIKit
class YHVisaRenewalPayMethodQrcodeCell: YHResignDocumentCell {
static let cellReuseIdentifier = "YHVisaRenewalPayMethodQrcodeCell"
var onLongPressEvent: ((UIImage) -> Void)?
private lazy var infoTitleLabel: UILabel = {
let label = UILabel()
label.font = .PFSC_M(ofSize: 14)
label.textColor = .mainTextColor
return label
}()
private lazy var infoTipsLabel: UILabel = {
let label = UILabel()
label.font = .PFSC_R(ofSize: 12)
label.textColor = .mainTextColor50
label.numberOfLines = 0
label.lineBreakMode = .byCharWrapping
return label
}()
private lazy var qrcodeIcon: UIImageView = {
let view = UIImageView()
view.contentMode = .scaleAspectFit
view.isUserInteractionEnabled = false
view.addGestureRecognizer(longPress)
return view
}()
/// 已添加的长按手势
private lazy var longPress: UILongPressGestureRecognizer = {
return UILongPressGestureRecognizer(target: self, action: #selector(onLongPress(_:)))
}()
override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
super.init(style: style, reuseIdentifier: reuseIdentifier)
setupUI()
}
required init?(coder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
func setupCellInfo(title: String, tips: String, qrCode: UIImage?) {
infoTitleLabel.text = title
infoTipsLabel.text = tips
if let qrCode = qrCode {
qrcodeIcon.image = qrCode
qrcodeIcon.isUserInteractionEnabled = true
}
}
}
extension YHVisaRenewalPayMethodQrcodeCell {
/// 长按
@objc func onLongPress(_ press: UILongPressGestureRecognizer) {
if press.state == .began {
guard let image = self.qrcodeIcon.image else {
return
}
onLongPressEvent?(image)
}
}
private func setupUI() {
subContainerView.radius = 6
updateCellCorner(.bottom)
subContainerView.addSubview(infoTitleLabel)
subContainerView.addSubview(infoTipsLabel)
subContainerView.addSubview(qrcodeIcon)
qrcodeIcon.snp.makeConstraints { make in
make.top.equalToSuperview().offset(18)
make.right.equalToSuperview().offset(-18)
make.bottom.equalToSuperview().offset(-27)
make.width.height.equalTo(86)
}
infoTitleLabel.snp.makeConstraints { make in
make.left.equalToSuperview().offset(18)
make.top.equalToSuperview().offset(31)
make.right.lessThanOrEqualTo(qrcodeIcon.snp.left).offset(-16)
}
infoTipsLabel.snp.makeConstraints { make in
make.left.equalTo(infoTitleLabel.snp.left)
make.top.equalTo(infoTitleLabel.snp.bottom).offset(6)
make.right.lessThanOrEqualTo(qrcodeIcon.snp.left).offset(-16)
make.bottom.lessThanOrEqualToSuperview().offset(-18)
}
}
}
//
// YHVisaRenewalPayMethodUrlCell.swift
// galaxy
//
// Created by alexzzw on 2024/10/10.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import UIKit
import AttributedString
class YHVisaRenewalPayMethodUrlCell: YHResignDocumentCell {
static let cellReuseIdentifier = "YHVisaRenewalPayMethodUrlCell"
var urlClicked: ((String) -> Void)?
private lazy var infoTitleLabel: UILabel = {
let label = UILabel()
label.font = .PFSC_M(ofSize: 14)
label.textColor = .mainTextColor
return label
}()
private lazy var infoTipsLabel: UILabel = {
let label = UILabel()
label.font = .PFSC_R(ofSize: 12)
label.textColor = .mainTextColor50
label.numberOfLines = 0
label.lineBreakMode = .byCharWrapping
return label
}()
private lazy var bottomContainerView: YHBaseDynamicCornerRadiusView = {
let view = YHBaseDynamicCornerRadiusView(cornerRadius: 4, corner: .allCorners)
view.backgroundColor = .contentBkgColor
return view
}()
private lazy var urlLabel: UILabel = {
let label = UILabel()
label.font = .PFSC_R(ofSize: 12)
label.textColor = .brandMainColor
label.numberOfLines = 0
label.lineBreakMode = .byCharWrapping
return label
}()
private lazy var bottomLineView: UIView = {
let view = UIView()
view.backgroundColor = .separatorColor
return view
}()
override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
super.init(style: style, reuseIdentifier: reuseIdentifier)
setupUI()
}
required init?(coder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
func setupCellInfo(title: String, tips: String, url: String) {
infoTitleLabel.text = title
infoTipsLabel.text = tips
let attStr = ASAttributedString.init(string: url, .underline(.init(rawValue: 1)), .action { [weak self] in
self?.urlClicked?(url)
})
urlLabel.attributed.text = attStr
}
}
extension YHVisaRenewalPayMethodUrlCell {
private func setupUI() {
subContainerView.radius = 6
updateCellCorner(.mid)
subContainerView.addSubview(infoTitleLabel)
subContainerView.addSubview(infoTipsLabel)
subContainerView.addSubview(bottomContainerView)
subContainerView.addSubview(bottomLineView)
bottomContainerView.addSubview(urlLabel)
infoTitleLabel.snp.makeConstraints { make in
make.left.equalToSuperview().offset(18)
make.top.equalToSuperview()
make.right.lessThanOrEqualToSuperview().offset(-18)
}
infoTipsLabel.snp.makeConstraints { make in
make.left.equalTo(infoTitleLabel.snp.left)
make.top.equalTo(infoTitleLabel.snp.bottom).offset(6)
make.right.lessThanOrEqualToSuperview().offset(-18)
}
bottomContainerView.snp.makeConstraints { make in
make.top.equalTo(infoTipsLabel.snp.bottom).offset(12)
make.left.equalTo(infoTitleLabel.snp.left)
make.right.equalToSuperview().offset(-18)
make.bottom.equalToSuperview().offset(-18)
}
urlLabel.snp.makeConstraints { make in
make.left.equalToSuperview().offset(16)
make.right.equalToSuperview().offset(-16)
make.top.equalToSuperview().offset(16)
make.bottom.equalToSuperview().offset(-16)
}
bottomLineView.snp.makeConstraints { make in
make.left.equalTo(infoTitleLabel.snp.left)
make.right.equalTo(bottomContainerView.snp.right)
make.bottom.equalToSuperview()
make.height.equalTo(0.5)
}
}
}
//
// YHVisaRenewalPayOccupyingSpaceCell.swift
// galaxy
//
// Created by alexzzw on 2024/10/11.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import UIKit
class YHVisaRenewalPayOccupyingSpaceCell: YHResignDocumentCell {
static let cellReuseIdentifier = "YHVisaRenewalPayOccupyingSpaceCell"
override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
super.init(style: style, reuseIdentifier: reuseIdentifier)
setupUI()
}
required init?(coder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
func setupCellInfo(isBottom: Bool = false) {
subContainerView.corner = isBottom ? [.bottomLeft, .bottomRight] : .none
let height: CGFloat = isBottom ? 18 : 12
subContainerView.snp.remakeConstraints { make in
make.top.bottom.equalToSuperview()
make.left.equalToSuperview().offset(16)
make.right.equalToSuperview().offset(-16)
make.height.equalTo(height)
}
}
}
extension YHVisaRenewalPayOccupyingSpaceCell {
private func setupUI() {
subContainerView.radius = 6
updateCellCorner(.mid)
}
}
//
// YHVisaRenewalPayStatusCell.swift
// galaxy
//
// Created by alexzzw on 2024/10/10.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import UIKit
class YHVisaRenewalPayStatusCell: YHVisaRenewalPayInfoBaseCell {
static let cellReuseIdentifier = "YHVisaRenewalPayStatusCell"
private lazy var iconView: UIView = {
let view = UIView()
view.backgroundColor = .brandMainColor
return view
}()
private lazy var infoTitleLabel: UILabel = {
let label = UILabel()
label.font = .PFSC_M(ofSize: 15)
label.textColor = .mainTextColor
return label
}()
private lazy var infoDetailLabel: UILabel = {
let label = UILabel()
label.font = .PFSC_M(ofSize: 13)
label.textColor = .brandMainColor
return label
}()
private lazy var bottomLineView: UIView = {
let view = UIView()
view.backgroundColor = .separatorColor
return view
}()
override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
super.init(style: style, reuseIdentifier: reuseIdentifier)
setupUI()
}
required init?(coder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
func setupCellInfo(title: String, status: YHVisaRenewalPaymentStatus) {
infoTitleLabel.text = title
infoDetailLabel.text = status.title
infoDetailLabel.textColor = status.titleColor
}
}
extension YHVisaRenewalPayStatusCell {
private func setupUI() {
updateInnerCellCorner(.top)
innerContainerView.addSubview(iconView)
innerContainerView.addSubview(infoTitleLabel)
innerContainerView.addSubview(infoDetailLabel)
innerContainerView.addSubview(bottomLineView)
iconView.setContentCompressionResistancePriority(.required, for: .horizontal)
infoTitleLabel.setContentCompressionResistancePriority(.defaultLow, for: .horizontal)
infoDetailLabel.setContentCompressionResistancePriority(.required, for: .horizontal)
bottomLineView.snp.makeConstraints { make in
make.left.right.bottom.equalToSuperview()
make.height.equalTo(0.5)
}
iconView.snp.makeConstraints { make in
make.left.equalToSuperview()
make.width.equalTo(4)
make.height.equalTo(15)
make.centerY.equalTo(infoTitleLabel)
}
infoTitleLabel.snp.makeConstraints { make in
make.left.equalTo(iconView.snp.right).offset(12)
make.top.equalToSuperview().offset(16)
make.bottom.equalToSuperview().offset(-12)
}
infoDetailLabel.snp.makeConstraints { make in
make.right.equalToSuperview().offset(-16)
make.left.greaterThanOrEqualTo(infoTitleLabel.snp.right).offset(12)
make.centerY.equalTo(infoTitleLabel)
}
}
}
//
// YHVisaRenewalPayTipsCell.swift
// galaxy
//
// Created by alexzzw on 2024/10/10.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import UIKit
class YHVisaRenewalPayTipsCell: YHVisaRenewalPayInfoBaseCell {
static let cellReuseIdentifier = "YHVisaRenewalPayTipsCell"
private lazy var infoDetailLabel: UILabel = {
let label = UILabel()
label.font = .PFSC_M(ofSize: 13)
label.textColor = .mainTextColor50
label.numberOfLines = 0
label.lineBreakMode = .byCharWrapping
label.textAlignment = .center
return label
}()
override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
super.init(style: style, reuseIdentifier: reuseIdentifier)
setupUI()
}
required init?(coder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
func setupCellInfo(detail: String) {
infoDetailLabel.text = detail
}
}
extension YHVisaRenewalPayTipsCell {
private func setupUI() {
updateInnerCellCorner(.bottom)
innerContainerView.addSubview(infoDetailLabel)
infoDetailLabel.snp.makeConstraints { make in
make.top.equalToSuperview().offset(12)
make.bottom.equalToSuperview().offset(-16)
make.centerX.equalToSuperview()
make.left.greaterThanOrEqualToSuperview().offset(16)
make.right.lessThanOrEqualToSuperview().offset(-16)
}
}
}
//
// YHVisaRenewalResidenceActionCell.swift
// galaxy
//
// Created by alexzzw on 2024/10/10.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import UIKit
class YHVisaRenewalResidenceActionCell: YHResignDocumentCell {
static let cellReuseIdentifier = "YHVisaRenewalResidenceActionCell"
var rightButtonEvent: (() -> Void)?
private lazy var infoTitleLabel: UILabel = {
let label = UILabel()
label.font = .PFSC_R(ofSize: 14)
label.textColor = .mainTextColor
return label
}()
private lazy var rightButton: UIButton = {
let button = UIButton(type: .custom)
button.setTitleColor(.mainTextColor, for: .normal)
button.titleLabel?.font = .PFSC_M(ofSize: 12)
button.addTarget(self, action: #selector(rightButtonClicked), for: .touchUpInside)
button.layer.cornerRadius = 2
button.clipsToBounds = true
return button
}()
private lazy var bottomLineView: UIView = {
let view = UIView()
view.backgroundColor = .separatorColor
return view
}()
override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
super.init(style: style, reuseIdentifier: reuseIdentifier)
setupUI()
}
required init?(coder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
func setupCellInfo(title: String, presenceStatus: YHVisaRenewalPresenceStatus, cellType: YHResignRoundCellType = .mid) {
updateCellCorner(cellType)
infoTitleLabel.text = title
rightButton.setTitle(presenceStatus.title, for: .normal)
rightButton.setTitleColor(presenceStatus.titleColor, for: .normal)
rightButton.backgroundColor = presenceStatus.bgColor
let isBottom = cellType == .bottom
bottomLineView.isHidden = isBottom ? true : false
let bottomMargin: CGFloat = isBottom ? 38 : 16
infoTitleLabel.snp.remakeConstraints { make in
make.left.equalToSuperview().offset(18)
make.top.equalToSuperview().offset(16)
make.bottom.equalToSuperview().offset(-bottomMargin)
}
}
}
extension YHVisaRenewalResidenceActionCell {
@objc private func rightButtonClicked() {
rightButtonEvent?()
}
private func setupUI() {
subContainerView.radius = 6
updateCellCorner(.mid)
subContainerView.addSubview(infoTitleLabel)
subContainerView.addSubview(rightButton)
subContainerView.addSubview(bottomLineView)
infoTitleLabel.setContentCompressionResistancePriority(.defaultLow, for: .horizontal)
rightButton.setContentCompressionResistancePriority(.required, for: .horizontal)
infoTitleLabel.snp.makeConstraints { make in
make.left.equalToSuperview().offset(18)
make.top.equalToSuperview().offset(16)
make.bottom.equalToSuperview().offset(-16)
}
rightButton.snp.makeConstraints { make in
make.left.greaterThanOrEqualTo(infoTitleLabel.snp.right).offset(6)
make.centerY.equalTo(infoTitleLabel)
make.right.equalToSuperview().offset(-18)
make.height.equalTo(26)
make.width.equalTo(72)
}
bottomLineView.snp.makeConstraints { make in
make.left.equalTo(infoTitleLabel.snp.left)
make.right.equalTo(rightButton.snp.right)
make.bottom.equalToSuperview()
make.height.equalTo(0.5)
}
}
}
//
// YHVisaRenewalSectionHeaderCell.swift
// galaxy
//
// Created by alexzzw on 2024/10/10.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import UIKit
class YHVisaRenewalSectionHeaderCell: YHResignDocumentCell {
static let cellReuseIdentifier = "YHVisaRenewalSectionHeaderCell"
var rightButtonEvent: (() -> Void)?
private lazy var infoTitleLabel: UILabel = {
let label = UILabel()
label.font = .PFSC_B(ofSize: 17)
label.textColor = .mainTextColor
return label
}()
private lazy var rightButton: UIButton = {
let button = UIButton(type: .custom)
button.setTitleColor(.brandMainColor, for: .normal)
button.titleLabel?.font = .PFSC_R(ofSize: 12)
button.addTarget(self, action: #selector(rightButtonClicked), for: .touchUpInside)
return button
}()
private lazy var bottomLineView: UIView = {
let view = UIView()
view.backgroundColor = .separatorColor
return view
}()
override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
super.init(style: style, reuseIdentifier: reuseIdentifier)
setupUI()
}
required init?(coder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
func setupCellInfo(title: String, buttonTitle: String? = nil) {
infoTitleLabel.text = title
guard let buttonTitle = buttonTitle, buttonTitle.count > 0 else {
rightButton.setTitle(nil, for: .normal)
rightButton.isHidden = true
return
}
rightButton.isHidden = false
rightButton.setTitle(buttonTitle, for: .normal)
}
}
extension YHVisaRenewalSectionHeaderCell {
@objc private func rightButtonClicked() {
rightButtonEvent?()
}
private func setupUI() {
subContainerView.radius = 6
updateCellCorner(.top)
subContainerView.addSubview(infoTitleLabel)
subContainerView.addSubview(rightButton)
subContainerView.addSubview(bottomLineView)
infoTitleLabel.setContentCompressionResistancePriority(.defaultLow, for: .horizontal)
rightButton.setContentCompressionResistancePriority(.required, for: .horizontal)
infoTitleLabel.snp.makeConstraints { make in
make.left.equalToSuperview().offset(18)
make.top.equalToSuperview().offset(16)
make.bottom.equalToSuperview().offset(-12)
}
rightButton.snp.makeConstraints { make in
make.left.greaterThanOrEqualTo(infoTitleLabel.snp.right).offset(6)
make.centerY.equalTo(infoTitleLabel)
make.right.equalToSuperview().offset(-18)
}
bottomLineView.snp.makeConstraints { make in
make.left.right.bottom.equalToSuperview()
make.height.equalTo(0.5)
}
}
}
//
// YHVisaRenewalTipsCell.swift
// galaxy
//
// Created by alexzzw on 2024/10/10.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import UIKit
import AttributedString
class YHVisaRenewalTipsCell: YHResignDocumentCell {
static let cellReuseIdentifier = "YHVisaRenewalTipsCell"
private lazy var infoDetailLabel: UILabel = {
let label = UILabel()
label.font = .PFSC_R(ofSize: 12)
label.textColor = .mainTextColor50
return label
}()
override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
super.init(style: style, reuseIdentifier: reuseIdentifier)
setupUI()
}
required init?(coder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
func setupCellInfo(detail: ASAttributedString) {
infoDetailLabel.attributed.text = detail
}
}
extension YHVisaRenewalTipsCell {
private func setupUI() {
subContainerView.radius = 6
updateCellCorner(.mid)
subContainerView.addSubview(infoDetailLabel)
infoDetailLabel.snp.makeConstraints { make in
make.left.equalToSuperview().offset(18)
make.top.equalToSuperview().offset(12)
make.bottom.equalToSuperview().offset(-12)
make.right.lessThanOrEqualToSuperview().offset(-18)
}
}
}
......@@ -29,6 +29,7 @@ class YHVisaRenewalTroubleshootingGuideHeaderCell: UITableViewCell {
label.font = .PFSC_R(ofSize: 14)
label.textColor = .mainTextColor70
label.numberOfLines = 0
label.lineBreakMode = .byCharWrapping
let paragraphStyle = NSMutableParagraphStyle()
paragraphStyle.lineHeightMultiple = 1.07
let attributedText = NSAttributedString(
......
......@@ -47,6 +47,15 @@ class YHVisaRenewalWorkflowCell: UITableViewCell {
func setupCellInfo(title: String, workflows: [String]) {
infoTitleLabel.text = title
stepLabels.forEach {
$0.removeFromSuperview()
}
circleViews.forEach {
$0.removeFromSuperview()
}
dashLines.forEach {
$0.removeFromSuperview()
}
stepLabels.removeAll()
circleViews.removeAll()
dashLines.removeAll()
......@@ -141,6 +150,7 @@ extension YHVisaRenewalWorkflowCell {
label.font = .PFSC_R(ofSize: 13)
label.textColor = .mainTextColor70
label.numberOfLines = 0
label.lineBreakMode = .byCharWrapping
let paragraphStyle = NSMutableParagraphStyle()
paragraphStyle.lineHeightMultiple = 1.1
let attributedText = NSAttributedString(
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment