Commit db256a5f authored by Alex朱枝文's avatar Alex朱枝文

在港记录相关

parent b28739e6
...@@ -594,6 +594,7 @@ ...@@ -594,6 +594,7 @@
04F2436C2C9D9A3A00DF2C74 /* YHResignDocumentCompleteModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04F2436B2C9D9A3A00DF2C74 /* YHResignDocumentCompleteModel.swift */; }; 04F2436C2C9D9A3A00DF2C74 /* YHResignDocumentCompleteModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04F2436B2C9D9A3A00DF2C74 /* YHResignDocumentCompleteModel.swift */; };
04F2436E2C9E5D8D00DF2C74 /* YHResignDocumentSignatureModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04F2436D2C9E5D8D00DF2C74 /* YHResignDocumentSignatureModel.swift */; }; 04F2436E2C9E5D8D00DF2C74 /* YHResignDocumentSignatureModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04F2436D2C9E5D8D00DF2C74 /* YHResignDocumentSignatureModel.swift */; };
04F243702C9E788200DF2C74 /* YHResignDocumentPreviewModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04F2436F2C9E788200DF2C74 /* YHResignDocumentPreviewModel.swift */; }; 04F243702C9E788200DF2C74 /* YHResignDocumentPreviewModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04F2436F2C9E788200DF2C74 /* YHResignDocumentPreviewModel.swift */; };
04F243722C9EC90C00DF2C74 /* YHHKRecordsEditPersonnelModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04F243712C9EC90C00DF2C74 /* YHHKRecordsEditPersonnelModel.swift */; };
04F316442C3568F000024164 /* YHAboutGalaxyViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04F316432C3568F000024164 /* YHAboutGalaxyViewController.swift */; }; 04F316442C3568F000024164 /* YHAboutGalaxyViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04F316432C3568F000024164 /* YHAboutGalaxyViewController.swift */; };
04F4B76B2BAA7E1E00D13284 /* YHCertificateTemplateSheetView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04F4B76A2BAA7E1E00D13284 /* YHCertificateTemplateSheetView.swift */; }; 04F4B76B2BAA7E1E00D13284 /* YHCertificateTemplateSheetView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04F4B76A2BAA7E1E00D13284 /* YHCertificateTemplateSheetView.swift */; };
04F5F86A2C1A95BB004A463C /* YHOtherServiceViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04F5F8692C1A95BB004A463C /* YHOtherServiceViewController.swift */; }; 04F5F86A2C1A95BB004A463C /* YHOtherServiceViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04F5F8692C1A95BB004A463C /* YHOtherServiceViewController.swift */; };
...@@ -1441,6 +1442,7 @@ ...@@ -1441,6 +1442,7 @@
04F2436B2C9D9A3A00DF2C74 /* YHResignDocumentCompleteModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHResignDocumentCompleteModel.swift; sourceTree = "<group>"; }; 04F2436B2C9D9A3A00DF2C74 /* YHResignDocumentCompleteModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHResignDocumentCompleteModel.swift; sourceTree = "<group>"; };
04F2436D2C9E5D8D00DF2C74 /* YHResignDocumentSignatureModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHResignDocumentSignatureModel.swift; sourceTree = "<group>"; }; 04F2436D2C9E5D8D00DF2C74 /* YHResignDocumentSignatureModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHResignDocumentSignatureModel.swift; sourceTree = "<group>"; };
04F2436F2C9E788200DF2C74 /* YHResignDocumentPreviewModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHResignDocumentPreviewModel.swift; sourceTree = "<group>"; }; 04F2436F2C9E788200DF2C74 /* YHResignDocumentPreviewModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHResignDocumentPreviewModel.swift; sourceTree = "<group>"; };
04F243712C9EC90C00DF2C74 /* YHHKRecordsEditPersonnelModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHHKRecordsEditPersonnelModel.swift; sourceTree = "<group>"; };
04F316432C3568F000024164 /* YHAboutGalaxyViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHAboutGalaxyViewController.swift; sourceTree = "<group>"; }; 04F316432C3568F000024164 /* YHAboutGalaxyViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHAboutGalaxyViewController.swift; sourceTree = "<group>"; };
04F4B76A2BAA7E1E00D13284 /* YHCertificateTemplateSheetView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHCertificateTemplateSheetView.swift; sourceTree = "<group>"; }; 04F4B76A2BAA7E1E00D13284 /* YHCertificateTemplateSheetView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHCertificateTemplateSheetView.swift; sourceTree = "<group>"; };
04F5F8692C1A95BB004A463C /* YHOtherServiceViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHOtherServiceViewController.swift; sourceTree = "<group>"; }; 04F5F8692C1A95BB004A463C /* YHOtherServiceViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHOtherServiceViewController.swift; sourceTree = "<group>"; };
...@@ -3549,6 +3551,7 @@ ...@@ -3549,6 +3551,7 @@
isa = PBXGroup; isa = PBXGroup;
children = ( children = (
04F243402C9AFBAB00DF2C74 /* YHHKRecordItemDetailType.swift */, 04F243402C9AFBAB00DF2C74 /* YHHKRecordItemDetailType.swift */,
04F243712C9EC90C00DF2C74 /* YHHKRecordsEditPersonnelModel.swift */,
); );
path = M; path = M;
sourceTree = "<group>"; sourceTree = "<group>";
...@@ -5436,6 +5439,7 @@ ...@@ -5436,6 +5439,7 @@
A5ACE9562B4564F7002C94D2 /* YHBouncesContentView.swift in Sources */, A5ACE9562B4564F7002C94D2 /* YHBouncesContentView.swift in Sources */,
A554A5122B99715000EA5973 /* YHConstantArrayData.swift in Sources */, A554A5122B99715000EA5973 /* YHConstantArrayData.swift in Sources */,
045EEE962B9F171A0022A143 /* YHPreviewInfoCertificatePictureItemsView.swift in Sources */, 045EEE962B9F171A0022A143 /* YHPreviewInfoCertificatePictureItemsView.swift in Sources */,
04F243722C9EC90C00DF2C74 /* YHHKRecordsEditPersonnelModel.swift in Sources */,
044EE2362C92916600A2FE3A /* YHResignCertificateListViewController.swift in Sources */, 044EE2362C92916600A2FE3A /* YHResignCertificateListViewController.swift in Sources */,
04F243412C9AFBAB00DF2C74 /* YHHKRecordItemDetailType.swift in Sources */, 04F243412C9AFBAB00DF2C74 /* YHHKRecordItemDetailType.swift in Sources */,
04256DDE2C72DA3B00A37BA4 /* YHCertificateAppointViewController.swift in Sources */, 04256DDE2C72DA3B00A37BA4 /* YHCertificateAppointViewController.swift in Sources */,
......
...@@ -122,7 +122,8 @@ extension YHHKImmigrationRecordsVC { ...@@ -122,7 +122,8 @@ extension YHHKImmigrationRecordsVC {
} }
@objc private func clickAddNewButton() { @objc private func clickAddNewButton() {
// let vc = YHHKRecordsEditContentVC(pageType: .add)
navigationController?.pushViewController(vc)
} }
} }
......
...@@ -135,7 +135,7 @@ extension YHHKRecordsContentVC: UITableViewDelegate, UITableViewDataSource { ...@@ -135,7 +135,7 @@ extension YHHKRecordsContentVC: UITableViewDelegate, UITableViewDataSource {
} }
let row = sectionArr[indexPath.row] let row = sectionArr[indexPath.row]
if case .edit = row { if case .edit = row {
let vc = YHHKRecordsEditContentVC() let vc = YHHKRecordsEditContentVC(pageType: .edit)
navigationController?.pushViewController(vc) navigationController?.pushViewController(vc)
} }
} }
......
//
// YHHKRecordsEditPersonnelModel.swift
// galaxy
//
// Created by alexzzw on 2024/9/21.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import Foundation
struct YHHKRecordsEditPersonnelModel {
var name: String = ""
var isSelected: Bool = false
}
...@@ -89,8 +89,9 @@ class YHHKRecordsPersonnelSelectCell: UICollectionViewCell { ...@@ -89,8 +89,9 @@ class YHHKRecordsPersonnelSelectCell: UICollectionViewCell {
} }
} }
func setupCellInfo(_ text: String?) { func setupCellInfo(_ text: String?, isSelected: Bool) {
tagLabel.text = text tagLabel.text = text
self.isSelected = isSelected
} }
} }
...@@ -15,9 +15,9 @@ class YHHKRecordsStayingPersonnelCell: YHResignDocumentCell { ...@@ -15,9 +15,9 @@ class YHHKRecordsStayingPersonnelCell: YHResignDocumentCell {
private static let minimumLineSpacing: CGFloat = 12 private static let minimumLineSpacing: CGFloat = 12
private static let minimumInteritemSpacing: CGFloat = 8 private static let minimumInteritemSpacing: CGFloat = 8
var selectItemAction: ((String?) -> Void)? var selectItemAction: ((YHHKRecordsEditPersonnelModel?) -> Void)?
var collectionData: [String] = [] { var collectionData: [YHHKRecordsEditPersonnelModel] = [] {
didSet { didSet {
infoCollectionView.reloadData() infoCollectionView.reloadData()
} }
...@@ -91,6 +91,7 @@ extension YHHKRecordsStayingPersonnelCell { ...@@ -91,6 +91,7 @@ extension YHHKRecordsStayingPersonnelCell {
subContainerView.addSubview(asteriskIcon) subContainerView.addSubview(asteriskIcon)
subContainerView.addSubview(infoTitleLabel) subContainerView.addSubview(infoTitleLabel)
subContainerView.addSubview(bottomLineView) subContainerView.addSubview(bottomLineView)
subContainerView.addSubview(infoCollectionView)
asteriskIcon.snp.makeConstraints { make in asteriskIcon.snp.makeConstraints { make in
make.left.equalToSuperview().offset(18) make.left.equalToSuperview().offset(18)
...@@ -129,7 +130,7 @@ extension YHHKRecordsStayingPersonnelCell: UICollectionViewDelegate, UICollectio ...@@ -129,7 +130,7 @@ extension YHHKRecordsStayingPersonnelCell: UICollectionViewDelegate, UICollectio
func collectionView(_ collectionView: UICollectionView, cellForItemAt indexPath: IndexPath) -> UICollectionViewCell { func collectionView(_ collectionView: UICollectionView, cellForItemAt indexPath: IndexPath) -> UICollectionViewCell {
if collectionData.count > indexPath.item, let cell = collectionView.dequeueReusableCell(withReuseIdentifier: YHHKRecordsPersonnelSelectCell.cellReuseIdentifier, for: indexPath) as? YHHKRecordsPersonnelSelectCell { if collectionData.count > indexPath.item, let cell = collectionView.dequeueReusableCell(withReuseIdentifier: YHHKRecordsPersonnelSelectCell.cellReuseIdentifier, for: indexPath) as? YHHKRecordsPersonnelSelectCell {
let data = collectionData[indexPath.item] let data = collectionData[indexPath.item]
cell.setupCellInfo(data) cell.setupCellInfo(data.name, isSelected: data.isSelected)
return cell return cell
} }
return UICollectionViewCell() return UICollectionViewCell()
...@@ -138,7 +139,7 @@ extension YHHKRecordsStayingPersonnelCell: UICollectionViewDelegate, UICollectio ...@@ -138,7 +139,7 @@ extension YHHKRecordsStayingPersonnelCell: UICollectionViewDelegate, UICollectio
func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, sizeForItemAt indexPath: IndexPath) -> CGSize { func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, sizeForItemAt indexPath: IndexPath) -> CGSize {
if collectionData.count > indexPath.item { if collectionData.count > indexPath.item {
let data = collectionData[indexPath.item] let data = collectionData[indexPath.item]
let attrString = NSAttributedString(string: data, attributes: [.font: YHHKRecordsPersonnelSelectCell.labelFont]) let attrString = NSAttributedString(string: data.name, attributes: [.font: YHHKRecordsPersonnelSelectCell.labelFont])
var width = attrString.yh_width(containerHeight: YHHKRecordsPersonnelSelectCell.cellHeight) + 2 * YHHKRecordsPersonnelSelectCell.offsetX var width = attrString.yh_width(containerHeight: YHHKRecordsPersonnelSelectCell.cellHeight) + 2 * YHHKRecordsPersonnelSelectCell.offsetX
if width < minWidth { if width < minWidth {
width = minWidth width = minWidth
......
...@@ -11,6 +11,8 @@ import UIKit ...@@ -11,6 +11,8 @@ import UIKit
class YHHKRecordsTimeSelectCell: YHResignDocumentCell { class YHHKRecordsTimeSelectCell: YHResignDocumentCell {
static let cellReuseIdentifier = "YHHKRecordsTimeSelectCell" static let cellReuseIdentifier = "YHHKRecordsTimeSelectCell"
private let placeholderColor = UIColor.mainTextColor30
private let selectedColor = UIColor.mainTextColor
private lazy var asteriskIcon: UIImageView = { private lazy var asteriskIcon: UIImageView = {
let view = UIImageView() let view = UIImageView()
...@@ -53,9 +55,16 @@ class YHHKRecordsTimeSelectCell: YHResignDocumentCell { ...@@ -53,9 +55,16 @@ class YHHKRecordsTimeSelectCell: YHResignDocumentCell {
fatalError("init(coder:) has not been implemented") fatalError("init(coder:) has not been implemented")
} }
func setupCellInfo(title: String?, detail: String?) { func setupCellInfo(title: String?, detail: String?, placeholder: String) {
infoTitleLabel.text = title infoTitleLabel.text = title
infoDetailLabel.text = detail if let detail = detail {
infoDetailLabel.text = detail
infoDetailLabel.textColor = selectedColor
} else {
infoDetailLabel.text = placeholder
infoDetailLabel.textColor = placeholderColor
}
} }
} }
......
...@@ -49,8 +49,9 @@ class YHResignDocumentTipsCell: YHResignDocumentCell { ...@@ -49,8 +49,9 @@ class YHResignDocumentTipsCell: YHResignDocumentCell {
fatalError("init(coder:) has not been implemented") fatalError("init(coder:) has not been implemented")
} }
func setupCellInfo(title: String?, detail: NSAttributedString?) { func setupCellInfo(title: String?, detail: NSAttributedString?, detailColor: UIColor = .mainTextColor50) {
infoTitleLabel.text = title infoTitleLabel.text = title
infoDetailLabel.textColor = detailColor
infoDetailLabel.attributedText = detail infoDetailLabel.attributedText = detail
} }
} }
......
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