Commit a5a90192 authored by Steven杜宇's avatar Steven杜宇

// 原则批

parent 024337b5
This diff is collapsed.
1. 安装环境
1.1 安装 Homebrew
/bin/zsh -c "$(curl -fsSL https://gitee.com/cunkai/HomebrewCN/raw/master/Homebrew.sh)"
......
......@@ -239,6 +239,8 @@
048787D92BCF68530036E221 /* YHProgressView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 048787D82BCF68530036E221 /* YHProgressView.swift */; };
048B2A4A2BC7D9DC00A93BF0 /* YHMyLikeViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 048B2A492BC7D9DC00A93BF0 /* YHMyLikeViewController.swift */; };
048B2A4D2BC7DAE800A93BF0 /* YHMyLikeViewModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 048B2A4C2BC7DAE800A93BF0 /* YHMyLikeViewModel.swift */; };
049062542BDF8ABB0084C985 /* YHPrincipleGroupReviewListCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 049062532BDF8ABB0084C985 /* YHPrincipleGroupReviewListCell.swift */; };
049062562BDF9E500084C985 /* YHPrincipleReviewListVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 049062552BDF9E500084C985 /* YHPrincipleReviewListVC.swift */; };
0493B3DC2BA7EFE600AF9393 /* YHCertificateSearchViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0493B3DB2BA7EFE600AF9393 /* YHCertificateSearchViewController.swift */; };
0493B3DE2BA80C2300AF9393 /* YHCertificateFilterButton.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0493B3DD2BA80C2300AF9393 /* YHCertificateFilterButton.swift */; };
049537852BA9B28500AF7E59 /* YHCertificateTemplateCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 049537842BA9B28500AF7E59 /* YHCertificateTemplateCell.swift */; };
......@@ -694,6 +696,8 @@
048787D82BCF68530036E221 /* YHProgressView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHProgressView.swift; sourceTree = "<group>"; };
048B2A492BC7D9DC00A93BF0 /* YHMyLikeViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHMyLikeViewController.swift; sourceTree = "<group>"; };
048B2A4C2BC7DAE800A93BF0 /* YHMyLikeViewModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHMyLikeViewModel.swift; sourceTree = "<group>"; };
049062532BDF8ABB0084C985 /* YHPrincipleGroupReviewListCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHPrincipleGroupReviewListCell.swift; sourceTree = "<group>"; };
049062552BDF9E500084C985 /* YHPrincipleReviewListVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHPrincipleReviewListVC.swift; sourceTree = "<group>"; };
0493B3DB2BA7EFE600AF9393 /* YHCertificateSearchViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHCertificateSearchViewController.swift; sourceTree = "<group>"; };
0493B3DD2BA80C2300AF9393 /* YHCertificateFilterButton.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHCertificateFilterButton.swift; sourceTree = "<group>"; };
049537842BA9B28500AF7E59 /* YHCertificateTemplateCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHCertificateTemplateCell.swift; sourceTree = "<group>"; };
......@@ -1032,6 +1036,7 @@
0428E22C2BDB88220032A7A1 /* V */ = {
isa = PBXGroup;
children = (
049062532BDF8ABB0084C985 /* YHPrincipleGroupReviewListCell.swift */,
);
path = V;
sourceTree = "<group>";
......@@ -1039,6 +1044,7 @@
0428E22D2BDB882A0032A7A1 /* C */ = {
isa = PBXGroup;
children = (
049062552BDF9E500084C985 /* YHPrincipleReviewListVC.swift */,
);
path = C;
sourceTree = "<group>";
......@@ -2716,6 +2722,7 @@
04174D732BCD5B74000BA46D /* YHMsgViewModel.swift in Sources */,
A567E5952BD7643D00D5D5A0 /* YHHomeClassifyModel.swift in Sources */,
045EEF122B9F171A0022A143 /* YHCNIDCardModel.swift in Sources */,
049062562BDF9E500084C985 /* YHPrincipleReviewListVC.swift in Sources */,
045EEF032B9F171A0022A143 /* YHFormItemDoubleChoiceCell.swift in Sources */,
045EEEAE2B9F171A0022A143 /* YHWorkHighlightsTableViewCell.swift in Sources */,
A567E59A2BD7643D00D5D5A0 /* YHHomeKingKongBlockModel.swift in Sources */,
......@@ -2882,6 +2889,7 @@
049A48A82B49417300D0C641 /* YHAboutUsViewController.swift in Sources */,
047619E92BA9867100F45358 /* YHCountryHotView.swift in Sources */,
045EEEF82B9F171A0022A143 /* YHFormItemOnlyDoubleChoiceCell.swift in Sources */,
049062542BDF8ABB0084C985 /* YHPrincipleGroupReviewListCell.swift in Sources */,
0480976D2BA158A1000B9DCA /* YHCertificateListVC.swift in Sources */,
045EEE8B2B9F171A0022A143 /* YHPreviewMainApplicantInfoViewController.swift in Sources */,
045EEE922B9F171A0022A143 /* YHPreviewInfoNameAndSubNameItemView.swift in Sources */,
......
//
// YHPrincipleReviewListVC.swift
// galaxy
//
// Created by edy on 2024/4/29.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import UIKit
class YHPrincipleReviewListVC: YHBaseViewController {
var items: [String] = ["", "", ""]
lazy var tableView: UITableView = {
let tableView = UITableView(frame:.zero, style:.grouped)
tableView.contentInsetAdjustmentBehavior = .never
tableView.estimatedSectionHeaderHeight = 24.0
tableView.estimatedSectionFooterHeight = 1.0
tableView.showsVerticalScrollIndicator = false
tableView.separatorStyle = .none
tableView.delegate = self
tableView.dataSource = self
tableView.backgroundColor = UIColor.white
tableView.register(UITableViewCell.self, forCellReuseIdentifier: "UITableViewCell")
tableView.register(YHPrincipleGroupReviewListCell.self, forCellReuseIdentifier: YHPrincipleGroupReviewListCell.cellReuseIdentifier)
return tableView
}()
override func viewDidLoad() {
super.viewDidLoad()
self.view.backgroundColor = .white
self.gk_navTitle = "原则批"
createUI()
}
func createUI() {
view.addSubview(tableView)
tableView.snp.makeConstraints { make in
make.top.equalToSuperview().offset(k_Height_NavigationtBarAndStatuBar)
make.left.right.bottom.equalToSuperview()
}
}
}
extension YHPrincipleReviewListVC: UITableViewDelegate, UITableViewDataSource {
func numberOfSections(in tableView: UITableView) -> Int {
return items.count
}
func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
return 1
}
func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
let cell = tableView.dequeueReusableCell(withIdentifier: YHPrincipleGroupReviewListCell.cellReuseIdentifier, for: indexPath) as! YHPrincipleGroupReviewListCell
if 0 <= indexPath.section && indexPath.section < items.count {
}
return cell
}
func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat {
return UITableView.automaticDimension
}
func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
if 0 <= indexPath.section && indexPath.section < items.count {
}
}
private func tableView(_ tableView: UITableView, viewForHeaderInSection section: Int) -> CGFloat {
return 24.0
}
private func tableView(_ tableView: UITableView, viewForFooterInSection section: Int) -> CGFloat {
return 1.0
}
func tableView(_ tableView: UITableView, viewForFooterInSection section: Int) -> UIView? {
return UIView()
}
func tableView(_ tableView: UITableView, viewForHeaderInSection section: Int) -> UIView? {
return UIView()
}
}
//
// YHPrincipleGroupReviewListCell.swift
// galaxy
//
// Created by edy on 2024/4/29.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import UIKit
class YHPrincipleGroupReviewItemView: UIView {
static let height = 55.0
var iconImgV: UIImageView!
var titleLabel: UILabel!
var timeLabel: UILabel!
override init(frame: CGRect) {
super.init(frame: frame)
setupUI()
}
required init?(coder: NSCoder) {
super.init(coder: coder)
}
func updateModel(_ str: String) {
titleLabel.text = str
timeLabel.text = "上传于2023.02.06"
}
func setupUI() {
iconImgV = UIImageView(image: UIImage(named: "my_cer_type_pdf"))
self.addSubview(iconImgV)
titleLabel = UILabel()
titleLabel.font = UIFont.PFSC_M(ofSize: 14)
titleLabel.textColor = UIColor.mainTextColor
titleLabel.text = "新公司在职证明.pdf"
self.addSubview(titleLabel)
timeLabel = UILabel()
timeLabel.font = UIFont.PFSC_R(ofSize: 11)
timeLabel.textColor = UIColor.labelTextColor2
timeLabel.text = "上传于2024.12.12"
self.addSubview(timeLabel)
iconImgV.snp.makeConstraints { make in
make.left.equalTo(22)
make.centerY.equalToSuperview()
make.width.height.equalTo(31.0)
}
titleLabel.snp.makeConstraints { make in
make.bottom.equalTo(self.snp.centerY).offset(-1)
make.left.equalTo(iconImgV.snp.right).offset(18)
make.right.equalTo(-16)
make.height.equalTo(20)
}
timeLabel.snp.makeConstraints { make in
make.top.equalTo(self.snp.centerY).offset(1)
make.left.equalTo(iconImgV.snp.right).offset(18)
make.height.equalTo(20)
make.right.equalTo(-16)
}
}
}
class YHPrincipleGroupReviewListCell: UITableViewCell {
static let cellReuseIdentifier = "YHPrincipleGroupReviewListCell"
var iconImgV: UIImageView!
var titleLabel: UILabel!
var grayView: UIView!
var listTitleLabel: UILabel!
var detailLabel: UILabel!
var statusLabel: UILabel!
var listView: UIView!
var items: [String] = []
required init?(coder: NSCoder) {
super.init(coder: coder)
}
override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
super.init(style: style, reuseIdentifier: reuseIdentifier)
setupUI()
}
func updateList(_ arr:[String]) {
items.removeAll()
items.append(contentsOf: arr)
listView.removeSubviews()
var lastItemView: YHPrincipleGroupReviewItemView? = nil
for (index, title) in items.enumerated() {
let itemView = YHPrincipleGroupReviewItemView(frame: .zero)
itemView.updateModel(title)
listView.addSubview(itemView)
itemView.snp.makeConstraints { make in
make.left.right.equalTo(0)
make.height.equalTo(YHPrincipleGroupReviewItemView.height)
if let lastItemView = lastItemView {
make.top.equalTo(lastItemView.snp.bottom)
} else {
make.top.equalToSuperview()
}
if index == items.count-1 {
make.bottom.equalTo(0)
}
}
lastItemView = itemView
}
self.setNeedsLayout()
self.layoutIfNeeded()
}
func setupUI() {
self.selectionStyle = .none
contentView.backgroundColor = UIColor.white
iconImgV = UIImageView(image: UIImage(named: "custom_service_icon_right"))
contentView.addSubview(iconImgV)
titleLabel = UILabel()
titleLabel.font = UIFont.PFSC_R(ofSize: 13)
titleLabel.textColor = UIColor.mainTextColor
titleLabel.text = "已获得港府甄选名额"
contentView.addSubview(titleLabel)
grayView = UIView()
grayView.backgroundColor = UIColor.init(hex: 0xf8f9fb)
grayView.layer.cornerRadius = 6.0
grayView.clipsToBounds = true
contentView.addSubview(grayView)
listTitleLabel = UILabel()
listTitleLabel.font = UIFont.PFSC_M(ofSize: 17)
listTitleLabel.textColor = UIColor.mainTextColor
listTitleLabel.text = "已获得港府甄选名额"
grayView.addSubview(listTitleLabel)
statusLabel = UILabel()
statusLabel.textAlignment = .center
statusLabel.font = UIFont.PFSC_R(ofSize: 10)
statusLabel.textColor = UIColor.init(hex: 0xFF9900)
statusLabel.backgroundColor = UIColor.init(hex:0xFF9900, alpha:0.3)
statusLabel.text = "审核中"
statusLabel.layer.cornerRadius = 4.0
statusLabel.clipsToBounds = true
grayView.addSubview(statusLabel)
detailLabel = UILabel()
detailLabel.numberOfLines = 0
detailLabel.font = UIFont.PFSC_R(ofSize: 12)
detailLabel.textColor = UIColor.labelTextColor2
detailLabel.text = "1.新公司在职证明(在申请期间更换了工作时必传)\n2.主申人的曾用名证明文件,例如户口本副本\n3.主申请人的中国无刑事罪行记录证明书副本(由公安局开具)"
grayView.addSubview(detailLabel)
listView = UIView()
grayView.addSubview(listView)
iconImgV.snp.makeConstraints { make in
make.left.equalTo(24)
make.width.height.equalTo(14.0)
make.centerY.equalTo(titleLabel)
}
titleLabel.snp.makeConstraints { make in
make.left.equalTo(iconImgV.snp.right).offset(8)
make.right.equalTo(-24)
make.top.equalTo(0)
make.height.equalTo(22)
}
grayView.snp.makeConstraints { make in
make.top.equalTo(titleLabel.snp.bottom).offset(12)
make.left.right.equalTo(titleLabel)
make.bottom.equalToSuperview()
}
listTitleLabel.snp.makeConstraints { make in
make.left.equalTo(16)
make.top.equalTo(16)
make.height.equalTo(24)
}
statusLabel.snp.makeConstraints { make in
make.left.equalTo(listTitleLabel.snp.right).offset(8)
make.size.equalTo(CGSize(width: 38, height: 15))
make.centerY.equalTo(listTitleLabel)
make.right.lessThanOrEqualTo(-16)
}
detailLabel.snp.makeConstraints { make in
make.left.equalTo(16)
make.right.equalTo(-16)
make.top.equalTo(listTitleLabel.snp.bottom).offset(28)
}
listView.snp.makeConstraints { make in
make.left.right.equalTo(0)
make.top.equalTo(detailLabel.snp.bottom).offset(16)
make.bottom.equalTo(-16)
}
updateList(["新公司在职证明.pdf",
"主申人的曾用名证明文件.pdf",
"无刑事罪行记录证明.pdf"])
}
}
{
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "Group 33333268@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "Group 33333268@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
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