Commit 352db1fa authored by lujunye's avatar lujunye

运单列表

parent a4fd38ad
{
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "daoda@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "daoda@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{ {
"info" : {
"version" : 1,
"author" : "xcode"
},
"colors" : [ "colors" : [
{ {
"idiom" : "universal",
"color" : { "color" : {
"color-space" : "srgb", "color-space" : "srgb",
"components" : { "components" : {
"red" : "0.392",
"alpha" : "1.000", "alpha" : "1.000",
"blue" : "0x64", "blue" : "0.392",
"green" : "0x64", "green" : "0.392"
"red" : "0x64"
} }
}, }
"idiom" : "universal"
} }
], ]
"info" : { }
"author" : "xcode", \ No newline at end of file
"version" : 1
}
}
{ {
"info" : {
"version" : 1,
"author" : "xcode"
},
"colors" : [ "colors" : [
{ {
"idiom" : "universal",
"color" : { "color" : {
"color-space" : "srgb", "color-space" : "srgb",
"components" : { "components" : {
"red" : "0.412",
"alpha" : "1.000", "alpha" : "1.000",
"blue" : "0x69", "blue" : "0.412",
"green" : "0x69", "green" : "0.412"
"red" : "0x69"
} }
}, }
"idiom" : "universal"
} }
], ]
"info" : { }
"author" : "xcode", \ No newline at end of file
"version" : 1
}
}
{ {
"info" : {
"version" : 1,
"author" : "xcode"
},
"colors" : [ "colors" : [
{ {
"idiom" : "universal",
"color" : { "color" : {
"color-space" : "srgb", "color-space" : "srgb",
"components" : { "components" : {
"red" : "0.839",
"alpha" : "1.000", "alpha" : "1.000",
"blue" : "0xEA", "blue" : "0.918",
"green" : "0xDF", "green" : "0.875"
"red" : "0xD6"
} }
}, }
"idiom" : "universal"
} }
], ]
"info" : { }
"author" : "xcode", \ No newline at end of file
"version" : 1
}
}
{ {
"info" : {
"version" : 1,
"author" : "xcode"
},
"colors" : [ "colors" : [
{ {
"idiom" : "universal",
"color" : { "color" : {
"color-space" : "srgb", "color-space" : "srgb",
"components" : { "components" : {
"red" : "0.180",
"alpha" : "1.000", "alpha" : "1.000",
"blue" : "0x2E", "blue" : "0.180",
"green" : "0x2E", "green" : "0.180"
"red" : "0x2E"
} }
}, }
"idiom" : "universal"
} }
], ]
"info" : { }
"author" : "xcode", \ No newline at end of file
"version" : 1
}
}
{ {
"info" : {
"version" : 1,
"author" : "xcode"
},
"colors" : [ "colors" : [
{ {
"idiom" : "universal",
"color" : { "color" : {
"color-space" : "srgb", "color-space" : "srgb",
"components" : { "components" : {
"red" : "0.400",
"alpha" : "1.000", "alpha" : "1.000",
"blue" : "0x66", "blue" : "0.400",
"green" : "0x66", "green" : "0.400"
"red" : "0x66"
} }
}, }
"idiom" : "universal"
} }
], ]
"info" : { }
"author" : "xcode", \ No newline at end of file
"version" : 1
}
}
{ {
"info" : {
"version" : 1,
"author" : "xcode"
},
"colors" : [ "colors" : [
{ {
"idiom" : "universal",
"color" : { "color" : {
"color-space" : "srgb", "color-space" : "srgb",
"components" : { "components" : {
"red" : "0.278",
"alpha" : "1.000", "alpha" : "1.000",
"blue" : "0xE3", "blue" : "0.890",
"green" : "0x8F", "green" : "0.561"
"red" : "0x47"
} }
}, }
"idiom" : "universal"
} }
], ]
"info" : { }
"author" : "xcode", \ No newline at end of file
"version" : 1
}
}
{
"info" : {
"version" : 1,
"author" : "xcode"
},
"colors" : [
{
"idiom" : "universal",
"color" : {
"color-space" : "srgb",
"components" : {
"red" : "1.000",
"alpha" : "1.000",
"blue" : "0.471",
"green" : "0.690"
}
}
}
]
}
\ No newline at end of file
...@@ -20,7 +20,7 @@ class SceneDelegate: UIResponder, UIWindowSceneDelegate { ...@@ -20,7 +20,7 @@ class SceneDelegate: UIResponder, UIWindowSceneDelegate {
// This delegate does not imply the connecting scene or session are new (see `application:configurationForConnectingSceneSession` instead). // This delegate does not imply the connecting scene or session are new (see `application:configurationForConnectingSceneSession` instead).
// Create the SwiftUI view that provides the window contents. // Create the SwiftUI view that provides the window contents.
let contentView = ProductDetailViewController() let contentView = XiaYunDanViewController()
// Use a UIHostingController as window root view controller. // Use a UIHostingController as window root view controller.
if let windowScene = scene as? UIWindowScene { if let windowScene = scene as? UIWindowScene {
......
//
// AdressSelectCell.swift
// GeliBusinessPlatform
//
// Created by junye lu on 2020/4/24.
// Copyright © 2020 junye lu. All rights reserved.
//
import UIKit
class AdressSelectCell: UITableViewCell {
@objc func tapAction(gesture:UITapGestureRecognizer){
}
@IBAction func btnClick(_ sender: UIButton) {
}
@IBOutlet weak var titleLbl: UILabel!
@IBOutlet weak var contentLbl: UILabel!
override func awakeFromNib() {
super.awakeFromNib()
selectionStyle = .none
let tap = UITapGestureRecognizer()
tap.addTarget(self, action: #selector(tapAction(gesture:)))
titleLbl.isUserInteractionEnabled = true
titleLbl.addGestureRecognizer(tap)
// Initialization code
}
override func setSelected(_ selected: Bool, animated: Bool) {
super.setSelected(selected, animated: animated)
// Configure the view for the selected state
}
}
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="15702" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina6_1" orientation="portrait" appearance="light"/>
<dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="15704"/>
<capability name="Named colors" minToolsVersion="9.0"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<objects>
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner"/>
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
<tableViewCell contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" id="KGk-i7-Jjw" customClass="AdressSelectCell" customModule="GeliBusinessPlatform" customModuleProvider="target">
<rect key="frame" x="0.0" y="0.0" width="375" height="70"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="KGk-i7-Jjw" id="H2p-sc-9uM">
<rect key="frame" x="0.0" y="0.0" width="375" height="70"/>
<autoresizingMask key="autoresizingMask"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="标" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="XGU-Qy-3Mg">
<rect key="frame" x="30" y="24" width="22" height="22"/>
<color key="backgroundColor" name="按钮渐变色下,字体颜色"/>
<constraints>
<constraint firstAttribute="height" constant="22" id="8pu-Kr-aHF"/>
<constraint firstAttribute="width" constant="22" id="Zgq-ag-dte"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="13"/>
<color key="textColor" name="白色背景色"/>
<nil key="highlightedColor"/>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute type="number" keyPath="cornerRadius">
<real key="value" value="11"/>
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
</label>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="rbl-Qi-BcX">
<rect key="frame" x="306" y="0.0" width="69" height="70"/>
<constraints>
<constraint firstAttribute="width" constant="69" id="GQw-Lu-Lar">
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute type="boolean" keyPath="isAdaptateScreen" value="YES"/>
</userDefinedRuntimeAttributes>
</constraint>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="13"/>
<state key="normal" title="地址簿">
<color key="titleColor" name="蓝色字体颜色"/>
</state>
<connections>
<action selector="btnClick:" destination="KGk-i7-Jjw" eventType="touchUpInside" id="fWZ-oJ-ihQ"/>
</connections>
</button>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="QuB-p7-CHF">
<rect key="frame" x="305" y="17.5" width="1" height="35"/>
<color key="backgroundColor" name="灰色分界线"/>
<constraints>
<constraint firstAttribute="width" constant="1" id="569-vG-wD0"/>
<constraint firstAttribute="height" constant="35" id="7n2-7k-i1h"/>
</constraints>
</view>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="请填写寄件人信息" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="hMc-rU-TYs">
<rect key="frame" x="62" y="0.0" width="233" height="70"/>
<fontDescription key="fontDescription" type="system" pointSize="13"/>
<color key="textColor" name="灰色字体颜色"/>
<nil key="highlightedColor"/>
</label>
</subviews>
<constraints>
<constraint firstAttribute="bottom" secondItem="rbl-Qi-BcX" secondAttribute="bottom" id="2TY-y3-1H7"/>
<constraint firstItem="rbl-Qi-BcX" firstAttribute="top" secondItem="H2p-sc-9uM" secondAttribute="top" id="9Hb-Xl-fM8"/>
<constraint firstItem="QuB-p7-CHF" firstAttribute="centerY" secondItem="H2p-sc-9uM" secondAttribute="centerY" id="ANp-As-KpI"/>
<constraint firstItem="XGU-Qy-3Mg" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="30" id="Q0Z-zW-A2s"/>
<constraint firstItem="rbl-Qi-BcX" firstAttribute="leading" secondItem="QuB-p7-CHF" secondAttribute="trailing" id="aOg-4L-fmY"/>
<constraint firstAttribute="trailing" secondItem="rbl-Qi-BcX" secondAttribute="trailing" id="aaI-ng-Fx1"/>
<constraint firstItem="QuB-p7-CHF" firstAttribute="leading" secondItem="hMc-rU-TYs" secondAttribute="trailing" constant="10" id="awM-tZ-yzY"/>
<constraint firstItem="hMc-rU-TYs" firstAttribute="top" secondItem="H2p-sc-9uM" secondAttribute="top" id="fuf-Fc-Try"/>
<constraint firstAttribute="bottom" secondItem="hMc-rU-TYs" secondAttribute="bottom" id="gxe-bT-IsT"/>
<constraint firstItem="XGU-Qy-3Mg" firstAttribute="centerY" secondItem="H2p-sc-9uM" secondAttribute="centerY" id="nro-GX-XJb"/>
<constraint firstItem="hMc-rU-TYs" firstAttribute="leading" secondItem="XGU-Qy-3Mg" secondAttribute="trailing" constant="10" id="yVj-9o-zzg"/>
</constraints>
</tableViewCellContentView>
<viewLayoutGuide key="safeArea" id="njF-e1-oar"/>
<connections>
<outlet property="contentLbl" destination="hMc-rU-TYs" id="82E-gu-O7F"/>
<outlet property="titleLbl" destination="XGU-Qy-3Mg" id="sZy-8Z-owR"/>
</connections>
<point key="canvasLocation" x="131.15942028985509" y="121.875"/>
</tableViewCell>
</objects>
<resources>
<namedColor name="按钮渐变色下,字体颜色">
<color red="0.27450980392156865" green="0.5607843137254902" blue="0.88627450980392153" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</namedColor>
<namedColor name="灰色分界线">
<color red="0.92941176470588238" green="0.92941176470588238" blue="0.92941176470588238" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</namedColor>
<namedColor name="灰色字体颜色">
<color red="0.40000000000000002" green="0.40000000000000002" blue="0.40000000000000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</namedColor>
<namedColor name="白色背景色">
<color red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</namedColor>
<namedColor name="蓝色字体颜色">
<color red="0.27843137254901962" green="0.5607843137254902" blue="0.8901960784313725" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</namedColor>
</resources>
</document>
...@@ -172,7 +172,7 @@ ...@@ -172,7 +172,7 @@
<color red="0.1803921568627451" green="0.1803921568627451" blue="0.1803921568627451" alpha="1" colorSpace="custom" customColorSpace="sRGB"/> <color red="0.1803921568627451" green="0.1803921568627451" blue="0.1803921568627451" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</namedColor> </namedColor>
<namedColor name="灰色字体颜色"> <namedColor name="灰色字体颜色">
<color red="0.59999999999999998" green="0.59999999999999998" blue="0.59999999999999998" alpha="1" colorSpace="custom" customColorSpace="sRGB"/> <color red="0.40000000000000002" green="0.40000000000000002" blue="0.40000000000000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</namedColor> </namedColor>
</resources> </resources>
</document> </document>
...@@ -9,12 +9,24 @@ ...@@ -9,12 +9,24 @@
import UIKit import UIKit
class PersonCenterCell: UITableViewCell { class PersonCenterCell: UITableViewCell {
///默认隐藏contentLbl
var contentStr:String = ""{
didSet{
contentLbl.isHidden = false
contentLbl.text = contentStr
}
}
@IBOutlet weak var contentLbl: UILabel!
@IBOutlet weak var introLbl: UILabel!
@IBOutlet weak var titleLbl: UILabel! @IBOutlet weak var titleLbl: UILabel!
override func awakeFromNib() { override func awakeFromNib() {
super.awakeFromNib() super.awakeFromNib()
// Initialization code // Initialization code
self.selectionStyle = .none self.selectionStyle = .none
self.introLbl.isHidden = true
} }
override func setSelected(_ selected: Bool, animated: Bool) { override func setSelected(_ selected: Bool, animated: Bool) {
......
...@@ -24,37 +24,63 @@ ...@@ -24,37 +24,63 @@
<constraint firstAttribute="height" constant="1" id="aD2-Df-mLu"/> <constraint firstAttribute="height" constant="1" id="aD2-Df-mLu"/>
</constraints> </constraints>
</view> </view>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Til-B7-hcz">
<rect key="frame" x="15" y="0.0" width="360" height="49"/>
<fontDescription key="fontDescription" type="system" pointSize="13"/>
<color key="textColor" name="标题字颜色"/>
<nil key="highlightedColor"/>
</label>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="jinru" translatesAutoresizingMaskIntoConstraints="NO" id="vKJ-Fp-ACU"> <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="jinru" translatesAutoresizingMaskIntoConstraints="NO" id="vKJ-Fp-ACU">
<rect key="frame" x="353" y="21" width="7" height="7"/> <rect key="frame" x="353" y="21.5" width="7" height="7"/>
<constraints> <constraints>
<constraint firstAttribute="width" constant="7" id="6dp-c6-A0b"/> <constraint firstAttribute="width" constant="7" id="6dp-c6-A0b"/>
<constraint firstAttribute="height" constant="7" id="Vre-gs-ydB"/> <constraint firstAttribute="height" constant="7" id="Vre-gs-ydB"/>
</constraints> </constraints>
</imageView> </imageView>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="增值服务" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="r8W-Gd-bzH">
<rect key="frame" x="15" y="17" width="54" height="16"/>
<constraints>
<constraint firstAttribute="width" constant="54" id="9kz-mh-I2k"/>
<constraint firstAttribute="height" constant="16" id="BuR-Ip-85l"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="13"/>
<color key="textColor" name="标题字颜色"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="(非必填)" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="0zA-eN-Xzx">
<rect key="frame" x="69" y="19" width="71" height="14"/>
<constraints>
<constraint firstAttribute="height" constant="14" id="FXT-XS-rEn"/>
<constraint firstAttribute="width" constant="71" id="wDQ-ox-ORg"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="11"/>
<color key="textColor" name="灰色字体颜色"/>
<nil key="highlightedColor"/>
</label>
<label hidden="YES" opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="content" textAlignment="right" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="wma-4b-cBC">
<rect key="frame" x="145" y="0.0" width="203" height="49"/>
<fontDescription key="fontDescription" type="system" pointSize="13"/>
<color key="textColor" name="标题字颜色"/>
<nil key="highlightedColor"/>
</label>
</subviews> </subviews>
<constraints> <constraints>
<constraint firstAttribute="trailing" secondItem="vKJ-Fp-ACU" secondAttribute="trailing" constant="15" id="0rT-l5-ttB"/> <constraint firstAttribute="trailing" secondItem="vKJ-Fp-ACU" secondAttribute="trailing" constant="15" id="0rT-l5-ttB"/>
<constraint firstItem="Til-B7-hcz" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="7H1-9D-7gb"/> <constraint firstItem="vKJ-Fp-ACU" firstAttribute="leading" secondItem="wma-4b-cBC" secondAttribute="trailing" constant="5" id="8lV-gq-GiY"/>
<constraint firstItem="S2b-Xn-LyD" firstAttribute="top" secondItem="wma-4b-cBC" secondAttribute="bottom" id="BIb-fv-IRd"/>
<constraint firstAttribute="trailing" secondItem="S2b-Xn-LyD" secondAttribute="trailing" id="HOO-OY-7gP"/> <constraint firstAttribute="trailing" secondItem="S2b-Xn-LyD" secondAttribute="trailing" id="HOO-OY-7gP"/>
<constraint firstItem="S2b-Xn-LyD" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="OVv-wO-fUC"/> <constraint firstItem="S2b-Xn-LyD" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="OVv-wO-fUC"/>
<constraint firstItem="Til-B7-hcz" firstAttribute="top" secondItem="H2p-sc-9uM" secondAttribute="top" id="Pt4-HX-3yw"/> <constraint firstItem="wma-4b-cBC" firstAttribute="leading" secondItem="0zA-eN-Xzx" secondAttribute="trailing" constant="5" id="YiM-Ut-GRm"/>
<constraint firstItem="vKJ-Fp-ACU" firstAttribute="centerY" secondItem="Til-B7-hcz" secondAttribute="centerY" id="bKb-kI-U02"/> <constraint firstItem="0zA-eN-Xzx" firstAttribute="leading" secondItem="r8W-Gd-bzH" secondAttribute="trailing" id="cc1-W3-2Ik"/>
<constraint firstAttribute="bottom" secondItem="S2b-Xn-LyD" secondAttribute="bottom" id="dql-i2-0iM"/> <constraint firstAttribute="bottom" secondItem="S2b-Xn-LyD" secondAttribute="bottom" id="dql-i2-0iM"/>
<constraint firstItem="S2b-Xn-LyD" firstAttribute="top" secondItem="Til-B7-hcz" secondAttribute="bottom" id="kuV-8Y-pOI"/> <constraint firstItem="wma-4b-cBC" firstAttribute="top" secondItem="H2p-sc-9uM" secondAttribute="top" id="hn0-zH-mGO"/>
<constraint firstAttribute="trailing" secondItem="Til-B7-hcz" secondAttribute="trailing" id="uFb-2R-JmN"/> <constraint firstItem="0zA-eN-Xzx" firstAttribute="bottom" secondItem="r8W-Gd-bzH" secondAttribute="bottom" id="nwS-xT-OSO"/>
<constraint firstItem="vKJ-Fp-ACU" firstAttribute="centerY" secondItem="H2p-sc-9uM" secondAttribute="centerY" id="rgH-am-JQz"/>
<constraint firstItem="r8W-Gd-bzH" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="smd-ak-Gq4"/>
<constraint firstItem="r8W-Gd-bzH" firstAttribute="centerY" secondItem="H2p-sc-9uM" secondAttribute="centerY" id="xfp-iK-ulr"/>
</constraints> </constraints>
</tableViewCellContentView> </tableViewCellContentView>
<viewLayoutGuide key="safeArea" id="njF-e1-oar"/> <viewLayoutGuide key="safeArea" id="njF-e1-oar"/>
<connections> <connections>
<outlet property="titleLbl" destination="Til-B7-hcz" id="dBR-zb-pVr"/> <outlet property="contentLbl" destination="wma-4b-cBC" id="F9e-4X-dX4"/>
<outlet property="introLbl" destination="0zA-eN-Xzx" id="BHy-NY-n0W"/>
<outlet property="titleLbl" destination="r8W-Gd-bzH" id="XDg-o3-bpD"/>
</connections> </connections>
<point key="canvasLocation" x="133" y="111"/> <point key="canvasLocation" x="132.60869565217394" y="110.49107142857143"/>
</tableViewCell> </tableViewCell>
</objects> </objects>
<resources> <resources>
...@@ -65,5 +91,8 @@ ...@@ -65,5 +91,8 @@
<namedColor name="灰色分界线"> <namedColor name="灰色分界线">
<color red="0.92941176470588238" green="0.92941176470588238" blue="0.92941176470588238" alpha="1" colorSpace="custom" customColorSpace="sRGB"/> <color red="0.92941176470588238" green="0.92941176470588238" blue="0.92941176470588238" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</namedColor> </namedColor>
<namedColor name="灰色字体颜色">
<color red="0.40000000000000002" green="0.40000000000000002" blue="0.40000000000000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</namedColor>
</resources> </resources>
</document> </document>
...@@ -86,13 +86,41 @@ ...@@ -86,13 +86,41 @@
<color key="titleColor" name="蓝色字体颜色"/> <color key="titleColor" name="蓝色字体颜色"/>
</state> </state>
</button> </button>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="K2a-dA-ghw">
<rect key="frame" x="187" y="14.5" width="1" height="20"/>
<color key="backgroundColor" name="灰色分界线"/>
<constraints>
<constraint firstAttribute="width" constant="1" id="6as-Vx-EHs"/>
<constraint firstAttribute="height" constant="20" id="Zk4-lb-j5t"/>
</constraints>
</view>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="OfO-Ur-eKC">
<rect key="frame" x="187" y="64.5" width="1" height="20"/>
<color key="backgroundColor" name="灰色分界线"/>
<constraints>
<constraint firstAttribute="height" constant="20" id="H93-wO-ov1"/>
<constraint firstAttribute="width" constant="1" id="gMw-rz-zUi"/>
</constraints>
</view>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="7kc-iX-5UF">
<rect key="frame" x="187" y="114.5" width="1" height="20"/>
<color key="backgroundColor" name="灰色分界线"/>
<constraints>
<constraint firstAttribute="width" constant="1" id="IOJ-D4-uLs"/>
<constraint firstAttribute="height" constant="20" id="ye5-4z-tTY"/>
</constraints>
</view>
</subviews> </subviews>
<constraints> <constraints>
<constraint firstItem="7kc-iX-5UF" firstAttribute="centerY" secondItem="bIm-PK-kvk" secondAttribute="centerY" id="4Gk-GB-sLe"/>
<constraint firstItem="OfO-Ur-eKC" firstAttribute="centerY" secondItem="GPm-DS-HCD" secondAttribute="centerY" id="4IO-rL-OHY"/>
<constraint firstItem="yWF-ML-clI" firstAttribute="top" secondItem="dLV-gy-4MF" secondAttribute="bottom" id="4Z4-S5-zYD"/> <constraint firstItem="yWF-ML-clI" firstAttribute="top" secondItem="dLV-gy-4MF" secondAttribute="bottom" id="4Z4-S5-zYD"/>
<constraint firstItem="OfO-Ur-eKC" firstAttribute="centerX" secondItem="H2p-sc-9uM" secondAttribute="centerX" id="5oD-0l-oNl"/>
<constraint firstItem="EeX-7S-sb3" firstAttribute="leading" secondItem="GPm-DS-HCD" secondAttribute="trailing" id="6he-O7-qaA"/> <constraint firstItem="EeX-7S-sb3" firstAttribute="leading" secondItem="GPm-DS-HCD" secondAttribute="trailing" id="6he-O7-qaA"/>
<constraint firstItem="GPm-DS-HCD" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" id="8ap-Jh-WKN"/> <constraint firstItem="GPm-DS-HCD" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" id="8ap-Jh-WKN"/>
<constraint firstAttribute="trailing" secondItem="K8k-YW-neS" secondAttribute="trailing" constant="15" id="Ai9-Wm-Kly"/> <constraint firstAttribute="trailing" secondItem="K8k-YW-neS" secondAttribute="trailing" constant="15" id="Ai9-Wm-Kly"/>
<constraint firstItem="oOy-dE-JIB" firstAttribute="width" secondItem="Mw0-dB-6KQ" secondAttribute="width" id="CTH-cF-Vv9"/> <constraint firstItem="oOy-dE-JIB" firstAttribute="width" secondItem="Mw0-dB-6KQ" secondAttribute="width" id="CTH-cF-Vv9"/>
<constraint firstItem="7kc-iX-5UF" firstAttribute="centerX" secondItem="H2p-sc-9uM" secondAttribute="centerX" id="GRb-ta-B5q"/>
<constraint firstItem="yWF-ML-clI" firstAttribute="leading" secondItem="bIm-PK-kvk" secondAttribute="trailing" id="I4O-7p-T2E"/> <constraint firstItem="yWF-ML-clI" firstAttribute="leading" secondItem="bIm-PK-kvk" secondAttribute="trailing" id="I4O-7p-T2E"/>
<constraint firstItem="oOy-dE-JIB" firstAttribute="top" secondItem="H2p-sc-9uM" secondAttribute="top" id="Jsj-Z5-Czt"/> <constraint firstItem="oOy-dE-JIB" firstAttribute="top" secondItem="H2p-sc-9uM" secondAttribute="top" id="Jsj-Z5-Czt"/>
<constraint firstItem="Mw0-dB-6KQ" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" id="PcZ-yC-jNk"/> <constraint firstItem="Mw0-dB-6KQ" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" id="PcZ-yC-jNk"/>
...@@ -101,8 +129,10 @@ ...@@ -101,8 +129,10 @@
<constraint firstItem="oOy-dE-JIB" firstAttribute="leading" secondItem="Mw0-dB-6KQ" secondAttribute="trailing" id="XhB-sH-Fd1"/> <constraint firstItem="oOy-dE-JIB" firstAttribute="leading" secondItem="Mw0-dB-6KQ" secondAttribute="trailing" id="XhB-sH-Fd1"/>
<constraint firstAttribute="trailing" secondItem="yWF-ML-clI" secondAttribute="trailing" id="XmT-41-e7C"/> <constraint firstAttribute="trailing" secondItem="yWF-ML-clI" secondAttribute="trailing" id="XmT-41-e7C"/>
<constraint firstItem="dLV-gy-4MF" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="bOL-OP-9Kw"/> <constraint firstItem="dLV-gy-4MF" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="bOL-OP-9Kw"/>
<constraint firstItem="K2a-dA-ghw" firstAttribute="centerY" secondItem="Mw0-dB-6KQ" secondAttribute="centerY" id="bt0-NL-DgF"/>
<constraint firstAttribute="trailing" secondItem="EeX-7S-sb3" secondAttribute="trailing" id="drL-r7-Erz"/> <constraint firstAttribute="trailing" secondItem="EeX-7S-sb3" secondAttribute="trailing" id="drL-r7-Erz"/>
<constraint firstItem="K8k-YW-neS" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="hLc-yF-uxx"/> <constraint firstItem="K8k-YW-neS" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="hLc-yF-uxx"/>
<constraint firstItem="K2a-dA-ghw" firstAttribute="centerX" secondItem="H2p-sc-9uM" secondAttribute="centerX" id="lAL-H6-q1X"/>
<constraint firstItem="bIm-PK-kvk" firstAttribute="top" secondItem="dLV-gy-4MF" secondAttribute="bottom" id="lLs-EN-Mbn"/> <constraint firstItem="bIm-PK-kvk" firstAttribute="top" secondItem="dLV-gy-4MF" secondAttribute="bottom" id="lLs-EN-Mbn"/>
<constraint firstItem="EeX-7S-sb3" firstAttribute="width" secondItem="GPm-DS-HCD" secondAttribute="width" id="nbk-Dm-GIi"/> <constraint firstItem="EeX-7S-sb3" firstAttribute="width" secondItem="GPm-DS-HCD" secondAttribute="width" id="nbk-Dm-GIi"/>
<constraint firstItem="bIm-PK-kvk" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" id="qQi-us-lCp"/> <constraint firstItem="bIm-PK-kvk" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" id="qQi-us-lCp"/>
......
//
// TitleAndOnlyBtnCell.swift
// GeliBusinessPlatform
//
// Created by junye lu on 2020/4/24.
// Copyright © 2020 junye lu. All rights reserved.
//
import UIKit
class TitleAndOnlyBtnCell: UITableViewCell {
@IBAction func editAction(_ sender: Any) {
}
@IBOutlet weak var titleLbl: UILabel!
override func awakeFromNib() {
super.awakeFromNib()
selectionStyle = .none
// Initialization code
}
override func setSelected(_ selected: Bool, animated: Bool) {
super.setSelected(selected, animated: animated)
// Configure the view for the selected state
}
}
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="15702" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina6_1" orientation="portrait" appearance="light"/>
<dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="15704"/>
<capability name="Named colors" minToolsVersion="9.0"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<objects>
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner"/>
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
<tableViewCell contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" id="KGk-i7-Jjw" customClass="TitleAndOnlyBtnCell" customModule="GeliBusinessPlatform" customModuleProvider="target">
<rect key="frame" x="0.0" y="0.0" width="375" height="49"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="KGk-i7-Jjw" id="H2p-sc-9uM">
<rect key="frame" x="0.0" y="0.0" width="375" height="49"/>
<autoresizingMask key="autoresizingMask"/>
<subviews>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="7yt-Tb-VMT">
<rect key="frame" x="325" y="0.0" width="50" height="49"/>
<constraints>
<constraint firstAttribute="width" constant="50" id="wBf-0M-8Ms"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="13"/>
<state key="normal" title="编辑">
<color key="titleColor" name="蓝色字体颜色"/>
</state>
<connections>
<action selector="editAction:" destination="KGk-i7-Jjw" eventType="touchUpInside" id="9ec-99-TPg"/>
</connections>
</button>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="标题" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="kTB-YG-ytP">
<rect key="frame" x="15" y="0.0" width="295" height="49"/>
<fontDescription key="fontDescription" type="system" pointSize="13"/>
<color key="textColor" name="标题字颜色"/>
<nil key="highlightedColor"/>
</label>
</subviews>
<constraints>
<constraint firstAttribute="bottom" secondItem="7yt-Tb-VMT" secondAttribute="bottom" id="24H-Sg-Iph"/>
<constraint firstAttribute="trailing" secondItem="7yt-Tb-VMT" secondAttribute="trailing" id="2Tc-i4-mW1"/>
<constraint firstAttribute="bottom" secondItem="kTB-YG-ytP" secondAttribute="bottom" id="CaJ-8I-iuq"/>
<constraint firstItem="kTB-YG-ytP" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="bxu-g8-wDJ"/>
<constraint firstItem="7yt-Tb-VMT" firstAttribute="top" secondItem="H2p-sc-9uM" secondAttribute="top" id="eM4-V3-51T"/>
<constraint firstItem="kTB-YG-ytP" firstAttribute="top" secondItem="H2p-sc-9uM" secondAttribute="top" id="mvZ-WJ-rH9"/>
<constraint firstItem="7yt-Tb-VMT" firstAttribute="leading" secondItem="kTB-YG-ytP" secondAttribute="trailing" constant="15" id="w12-Rj-bJg"/>
</constraints>
</tableViewCellContentView>
<viewLayoutGuide key="safeArea" id="njF-e1-oar"/>
<connections>
<outlet property="titleLbl" destination="kTB-YG-ytP" id="Apa-4p-tAX"/>
</connections>
<point key="canvasLocation" x="132" y="122"/>
</tableViewCell>
</objects>
<resources>
<namedColor name="标题字颜色">
<color red="0.1803921568627451" green="0.1803921568627451" blue="0.1803921568627451" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</namedColor>
<namedColor name="蓝色字体颜色">
<color red="0.27843137254901962" green="0.5607843137254902" blue="0.8901960784313725" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</namedColor>
</resources>
</document>
//
// WenDuCell.swift
// GeliBusinessPlatform
//
// Created by junye lu on 2020/4/24.
// Copyright © 2020 junye lu. All rights reserved.
//
import UIKit
class WenDuCell: UITableViewCell {
@IBAction func selectAction(_ sender: UIButton) {
if sender == rightBtn {
if rightBtn.isSelected == true {
rightBtn.isSelected = false
rightBtn.backgroundColor = UIColor.clear
rightBtn.layer.borderWidth = 1
}else{
leftBtn.backgroundColor = UIColor.clear
leftBtn.isSelected = false
leftBtn.layer.borderWidth = 1
rightBtn.isSelected = true
rightBtn.backgroundColor = UIColor(named: "蓝色字体颜色")
rightBtn.layer.borderWidth = 0
}
}else{
if leftBtn.isSelected == true {
leftBtn.isSelected = false
leftBtn.backgroundColor = UIColor.clear
leftBtn.layer.borderWidth = 1
}else{
leftBtn.isSelected = true
leftBtn.backgroundColor = UIColor(named: "蓝色字体颜色")
leftBtn.layer.borderWidth = 0
rightBtn.isSelected = false
rightBtn.backgroundColor = UIColor.clear
rightBtn.layer.borderWidth = 1
}
}
}
@IBOutlet weak var rightBtn: UIButton!
@IBOutlet weak var leftBtn: UIButton!
@IBOutlet weak var titleLbl: UILabel!
override func awakeFromNib() {
super.awakeFromNib()
selectionStyle = .none
// Initialization code
}
override func setSelected(_ selected: Bool, animated: Bool) {
super.setSelected(selected, animated: animated)
// Configure the view for the selected state
}
}
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="15702" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina6_1" orientation="portrait" appearance="light"/>
<dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="15704"/>
<capability name="Named colors" minToolsVersion="9.0"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<objects>
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner"/>
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
<tableViewCell contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" id="KGk-i7-Jjw" customClass="WenDuCell" customModule="GeliBusinessPlatform" customModuleProvider="target">
<rect key="frame" x="0.0" y="0.0" width="375" height="96"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="KGk-i7-Jjw" id="H2p-sc-9uM">
<rect key="frame" x="0.0" y="0.0" width="375" height="96"/>
<autoresizingMask key="autoresizingMask"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="温控范围" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="JnY-gg-St4">
<rect key="frame" x="15" y="15" width="360" height="18.5"/>
<constraints>
<constraint firstAttribute="height" constant="18.5" id="jFr-dJ-OV0"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="13"/>
<color key="textColor" name="标题字颜色"/>
<nil key="highlightedColor"/>
</label>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="tF5-tz-dRM">
<rect key="frame" x="80.5" y="48.5" width="99.5" height="27.5"/>
<constraints>
<constraint firstAttribute="height" constant="27.5" id="8Fw-OQ-zSs"/>
<constraint firstAttribute="width" constant="99.5" id="Idg-9Y-p0v"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="13"/>
<color key="tintColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<state key="normal" title="冷冻 ≤-18℃">
<color key="titleColor" name="灰色字体颜色"/>
</state>
<state key="selected" title="冷冻 ≤-18℃">
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</state>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute type="color" keyPath="borderColor">
<color key="value" name="灰色字体颜色"/>
</userDefinedRuntimeAttribute>
<userDefinedRuntimeAttribute type="number" keyPath="borderWidth">
<real key="value" value="1"/>
</userDefinedRuntimeAttribute>
<userDefinedRuntimeAttribute type="number" keyPath="cornerRadius">
<real key="value" value="2"/>
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
<connections>
<action selector="selectAction:" destination="KGk-i7-Jjw" eventType="touchUpInside" id="oYl-EP-Nes"/>
</connections>
</button>
<button opaque="NO" tag="1" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="h2T-BN-NH0">
<rect key="frame" x="195.5" y="48.5" width="99.5" height="27.5"/>
<constraints>
<constraint firstAttribute="height" constant="27.5" id="Jx2-BC-ktn"/>
<constraint firstAttribute="width" constant="99.5" id="kd5-Do-hKy"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="13"/>
<color key="tintColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<state key="normal" title="冷藏 (0~10)℃">
<color key="titleColor" name="灰色字体颜色"/>
</state>
<state key="selected" title="冷藏 (0~10)℃">
<color key="titleColor" name="白色背景色"/>
</state>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute type="color" keyPath="borderColor">
<color key="value" name="灰色字体颜色"/>
</userDefinedRuntimeAttribute>
<userDefinedRuntimeAttribute type="number" keyPath="borderWidth">
<real key="value" value="1"/>
</userDefinedRuntimeAttribute>
<userDefinedRuntimeAttribute type="number" keyPath="cornerRadius">
<real key="value" value="2"/>
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
<connections>
<action selector="selectAction:" destination="KGk-i7-Jjw" eventType="touchUpInside" id="ASu-Rq-WvM"/>
</connections>
</button>
</subviews>
<constraints>
<constraint firstItem="h2T-BN-NH0" firstAttribute="centerY" secondItem="tF5-tz-dRM" secondAttribute="centerY" id="8pZ-yF-B56"/>
<constraint firstItem="tF5-tz-dRM" firstAttribute="top" secondItem="JnY-gg-St4" secondAttribute="bottom" constant="15" id="E7e-03-cRk"/>
<constraint firstItem="JnY-gg-St4" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="M79-37-xDi"/>
<constraint firstAttribute="trailing" secondItem="JnY-gg-St4" secondAttribute="trailing" id="Msc-qF-5LC"/>
<constraint firstItem="JnY-gg-St4" firstAttribute="top" secondItem="H2p-sc-9uM" secondAttribute="top" constant="15" id="ge8-Tx-M4d"/>
<constraint firstItem="h2T-BN-NH0" firstAttribute="centerX" secondItem="H2p-sc-9uM" secondAttribute="centerX" constant="57.5" id="oT0-UH-ugj"/>
<constraint firstItem="tF5-tz-dRM" firstAttribute="centerX" secondItem="H2p-sc-9uM" secondAttribute="centerX" constant="-57.5" id="vd1-tZ-Jp8"/>
</constraints>
</tableViewCellContentView>
<viewLayoutGuide key="safeArea" id="njF-e1-oar"/>
<connections>
<outlet property="leftBtn" destination="tF5-tz-dRM" id="bcn-Og-ulZ"/>
<outlet property="rightBtn" destination="h2T-BN-NH0" id="XCI-bz-MzV"/>
<outlet property="titleLbl" destination="JnY-gg-St4" id="e8o-ee-aFV"/>
</connections>
<point key="canvasLocation" x="132" y="122"/>
</tableViewCell>
</objects>
<resources>
<namedColor name="标题字颜色">
<color red="0.1803921568627451" green="0.1803921568627451" blue="0.1803921568627451" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</namedColor>
<namedColor name="灰色字体颜色">
<color red="0.40000000000000002" green="0.40000000000000002" blue="0.40000000000000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</namedColor>
<namedColor name="白色背景色">
<color red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</namedColor>
</resources>
</document>
//
// XiaYunDanViewController.swift
// GeliBusinessPlatform
//
// Created by junye lu on 2020/4/24.
// Copyright © 2020 junye lu. All rights reserved.
//
import UIKit
class XiaYunDanViewController: BaseViewController,UITableViewDelegate,UITableViewDataSource {
var selectBtn:UIButton?
let titleArr = ["物品寄托","寄派方式","增值服务","温控范围"]
let title2Arr = ["关联订单号","关联平台"]
@IBOutlet weak var priceLbl: UILabel!
@IBAction func orderAction(_ sender: Any) {
}
@IBOutlet weak var bottomView: UIView!
@IBOutlet weak var listView: UITableView!
override func viewDidLoad() {
super.viewDidLoad()
navbar.title = "运单列表"
self.view.addSubview(navbar)
listView.snp.makeConstraints { (make) in
make.top.equalTo(NavCGRect.height)
make.left.right.equalTo(0)
make.bottom.equalTo(bottomView.snp_top)
}
listView.separatorStyle = .none
listView.register(UINib(nibName: "AdressSelectCell", bundle: nil), forCellReuseIdentifier: "AdressSelect")
listView.register(UINib(nibName: "PersonCenterCell", bundle: nil), forCellReuseIdentifier: "PersonCenter")
listView.register(UINib(nibName: "TitleAndOnlyBtnCell", bundle: nil), forCellReuseIdentifier: "TitleAndOnlyBtn")
listView.register(UINib(nibName: "WenDuCell", bundle: nil), forCellReuseIdentifier: "WenDu")
// Do any additional setup after loading the view.
}
@objc func selectBtnClick(sender:UIButton){
if sender.tag == 99 {
//跳转查看合同页面
print("跳转查看合同页面")
return
}
selectBtn!.isSelected = !selectBtn!.isSelected
}
//MARK: - CELL DELEGATE
func tableView(_ tableView: UITableView, viewForFooterInSection section: Int) -> UIView? {
if section == 2 {
let view = UIView(frame: CGRect(x: 0, y: 0, width: fullScreenWidth, height: 41.5*glscale))
view.backgroundColor = UIColor(named: "app底色")
let btn = UIButton()
view.addSubview(btn)
btn.setImage(UIImage(named: "daixuan"), for: .normal)
btn.setImage(UIImage(named: "yuxuan"), for: .selected)
btn.snp.makeConstraints { (make) in
make.centerY.equalTo(view.snp_centerY)
make.left.equalTo(15)
make.width.height.equalTo(12.5)
}
selectBtn = btn
let btn2 = UIButton()
view.addSubview(btn2)
btn2.addTarget(self, action: #selector(selectBtnClick(sender:)), for: .touchUpInside)
btn2.snp.makeConstraints { (make) in
make.top.left.bottom.equalTo(0)
make.width.equalTo(30)
}
let lbl1 = UILabel()
lbl1.text = "我已阅读并同意"
lbl1.textColor = UIColor(named: "标题字颜色")
lbl1.font = UIFont.systemFont(ofSize: 11)
lbl1.sizeToFit()
view.addSubview(lbl1)
lbl1.snp.makeConstraints { (make) in
make.left.equalTo(btn2.snp_right).offset(3)
make.top.bottom.equalTo(0)
make.width.equalTo(lbl1.bounds.size.width)
}
let btn3 = UIButton()
btn3.setTitle("《快件服务协议》", for: .normal)
btn3.titleLabel?.font = UIFont.systemFont(ofSize: 11)
btn3.setTitleColor(UIColor(named: "蓝色字体颜色"), for: .normal)
btn3.tag = 99
view.addSubview(btn3)
btn3.sizeToFit()
btn3.addTarget(self, action: #selector(selectBtnClick(sender:)), for: .touchUpInside)
btn3.snp.makeConstraints { (make) in
make.left.equalTo(lbl1.snp_right)
make.top.bottom.equalTo(0)
make.width.equalTo(btn3.bounds.size.width)
}
return view
}
let view = UIView()
view.backgroundColor = UIColor(named: "app底色")
return view
}
func tableView(_ tableView: UITableView, heightForFooterInSection section: Int) -> CGFloat {
if section == 0 {
return 10*glscale
}
if section == 1 {
return 5*glscale
}
return 41.5*glscale
}
func numberOfSections(in tableView: UITableView) -> Int {
return 3
}
func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
switch section {
case 0:return 2
case 1:return 4
default: return 2
}
}
func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat {
if indexPath.section == 0 {
return 70
}
if indexPath.section == 1{
if indexPath.row == 3 {
return 96
}
return 49
}
return 49
}
func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
switch indexPath.section {
case 0:
let cell = tableView.dequeueReusableCell(withIdentifier: "AdressSelect") as! AdressSelectCell
cell.titleLbl.text = "寄"
if indexPath.row == 1 {
cell.titleLbl.backgroundColor = UIColor(named: "标题背景色")
cell.titleLbl.text = "收"
}
return cell
case 1:
let cell = tableView.dequeueReusableCell(withIdentifier: "PersonCenter") as! PersonCenterCell
cell.titleLbl.text = titleArr[indexPath.row]
if indexPath.row == 0 {
cell.introLbl.text = "(必填)"
cell.introLbl.textColor = UIColor(named: "蓝色字体颜色")
cell.introLbl.isHidden = false
}
if indexPath.row == 2 {
cell.introLbl.isHidden = false
}
if indexPath.row == 3 {
let cell = tableView.dequeueReusableCell(withIdentifier: "WenDu") as! WenDuCell
cell.titleLbl.text = titleArr[indexPath.row]
return cell
}
cell.contentStr = "1"
return cell
default:
let cell = tableView.dequeueReusableCell(withIdentifier: "TitleAndOnlyBtn") as! TitleAndOnlyBtnCell
cell.titleLbl.text = title2Arr[indexPath.row]
return cell
}
}
}
//
// YunDanLieBiaoCell.swift
// GeliBusinessPlatform
//
// Created by junye lu on 2020/4/24.
// Copyright © 2020 junye lu. All rights reserved.
//
import UIKit
class YunDanLieBiaoCell: UITableViewCell {
/// 订单号
@IBOutlet weak var orderNumLbl: UILabel!
/// 时间
@IBOutlet weak var timeLbl: UILabel!
/// 平台
@IBOutlet weak var standerLbl: UILabel!
/// 左上角标题
@IBOutlet weak var title1: UILabel!
/// 右上角标题
@IBOutlet weak var title2: UILabel!
/// 订单状态
@IBOutlet weak var statusLbl: UILabel!
/// 发货人
@IBOutlet weak var senderLbl: UILabel!
/// 收货人
@IBOutlet weak var receiverLbl: UILabel!
/// 货品名称
@IBOutlet weak var productNameLbl: UILabel!
/// 签收状态
@IBOutlet weak var signLbl: UILabel!
override func awakeFromNib() {
super.awakeFromNib()
selectionStyle = .none
// Initialization code
}
override func setSelected(_ selected: Bool, animated: Bool) {
super.setSelected(selected, animated: animated)
// Configure the view for the selected state
}
}
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