Commit 356d4821 authored by 刘俊宏's avatar 刘俊宏

分销订单管理

parent eae5f8f2
......@@ -583,6 +583,10 @@
F96E9D5D246656A700B5B94A /* HGImagePickerController.swift in Sources */ = {isa = PBXBuildFile; fileRef = F96E9D58246656A700B5B94A /* HGImagePickerController.swift */; };
F96E9D60246657B500B5B94A /* HGImage.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = F96E9D5E246657B500B5B94A /* HGImage.xcassets */; };
F96E9D61246657B500B5B94A /* HGImage.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = F96E9D5F246657B500B5B94A /* HGImage.storyboard */; };
F970B3672550F5AA0026F9D5 /* RetailManageViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = F970B3652550F5AA0026F9D5 /* RetailManageViewController.swift */; };
F970B3682550F5AA0026F9D5 /* RetailManageViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = F970B3662550F5AA0026F9D5 /* RetailManageViewController.xib */; };
F970B3702551280B0026F9D5 /* TimeShowDownView.xib in Resources */ = {isa = PBXBuildFile; fileRef = F970B36F2551280B0026F9D5 /* TimeShowDownView.xib */; };
F970B3752551281A0026F9D5 /* TimeShowDownView.swift in Sources */ = {isa = PBXBuildFile; fileRef = F970B3742551281A0026F9D5 /* TimeShowDownView.swift */; };
F971D7B3248B6432007F1619 /* address_new.json in Resources */ = {isa = PBXBuildFile; fileRef = F971D7B2248B6432007F1619 /* address_new.json */; };
F993C66E24CADE2400493CC7 /* WayBillStautsTableViewCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = F993C66C24CADE2400493CC7 /* WayBillStautsTableViewCell.swift */; };
F993C66F24CADE2400493CC7 /* WayBillStautsTableViewCell.xib in Resources */ = {isa = PBXBuildFile; fileRef = F993C66D24CADE2400493CC7 /* WayBillStautsTableViewCell.xib */; };
......@@ -1285,6 +1289,10 @@
F96E9D58246656A700B5B94A /* HGImagePickerController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = HGImagePickerController.swift; sourceTree = "<group>"; };
F96E9D5E246657B500B5B94A /* HGImage.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = HGImage.xcassets; sourceTree = "<group>"; };
F96E9D5F246657B500B5B94A /* HGImage.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; path = HGImage.storyboard; sourceTree = "<group>"; };
F970B3652550F5AA0026F9D5 /* RetailManageViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RetailManageViewController.swift; sourceTree = "<group>"; };
F970B3662550F5AA0026F9D5 /* RetailManageViewController.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = RetailManageViewController.xib; sourceTree = "<group>"; };
F970B36F2551280B0026F9D5 /* TimeShowDownView.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = TimeShowDownView.xib; sourceTree = "<group>"; };
F970B3742551281A0026F9D5 /* TimeShowDownView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TimeShowDownView.swift; sourceTree = "<group>"; };
F971D7B2248B6432007F1619 /* address_new.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = address_new.json; sourceTree = "<group>"; };
F993C66C24CADE2400493CC7 /* WayBillStautsTableViewCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = WayBillStautsTableViewCell.swift; sourceTree = "<group>"; };
F993C66D24CADE2400493CC7 /* WayBillStautsTableViewCell.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = WayBillStautsTableViewCell.xib; sourceTree = "<group>"; };
......@@ -2002,6 +2010,7 @@
E077DC6725512E73000B0DA5 /* 分销商品管理 */,
E077DC5C25512489000B0DA5 /* 供应商合作管理 */,
E0AD92E62550E4DD00D82C17 /* 供应商分销商品管理 */,
F970B3642550F59D0026F9D5 /* 分销订单管理 */,
F9C2F6EF254FDEAC00516E00 /* 分销商分账设置 */,
F9A4AB6A24C9220C00094BD1 /* 货拉拉 */,
F90F881B24C822750050EF02 /* 城市列表 */,
......@@ -2677,6 +2686,8 @@
F9956B1B2463D941001A617D /* WorkSelectTimeView.xib */,
F9956B1D2463D94E001A617D /* WorkSelectTimeView.swift */,
F93E31FC24727A2D00524DFC /* ShowTimeSelectView.swift */,
F970B36F2551280B0026F9D5 /* TimeShowDownView.xib */,
F970B3742551281A0026F9D5 /* TimeShowDownView.swift */,
);
path = TimeSelectView;
sourceTree = "<group>";
......@@ -3050,6 +3061,15 @@
path = HGImage;
sourceTree = "<group>";
};
F970B3642550F59D0026F9D5 /* 分销订单管理 */ = {
isa = PBXGroup;
children = (
F970B3652550F5AA0026F9D5 /* RetailManageViewController.swift */,
F970B3662550F5AA0026F9D5 /* RetailManageViewController.xib */,
);
path = "分销订单管理";
sourceTree = "<group>";
};
F9956B1F24640865001A617D /* 商品分类 */ = {
isa = PBXGroup;
children = (
......@@ -3323,6 +3343,7 @@
F9A4AB7424C933A700094BD1 /* XiaDanUserInfoViewController.xib in Resources */,
F9A4F25024C9689600D1DD13 /* OtherDemandViewController.xib in Resources */,
E09B03C12445B96500211A51 /* FgPassViewController.xib in Resources */,
F970B3702551280B0026F9D5 /* TimeShowDownView.xib in Resources */,
E06524EE2458008900CA22E2 /* RuKuViewController.xib in Resources */,
F96E48A824CA90DC000AB8D4 /* DriverItemTableViewCell.xib in Resources */,
E06524F624580BB600CA22E2 /* BaoZhiQiCell.xib in Resources */,
......@@ -3470,6 +3491,7 @@
E0A2E82C24555D8600D6DB34 /* KuCunXiangQingCell.xib in Resources */,
E020632D246CDD3F007A40C4 /* OrderDViewFooterView.xib in Resources */,
E02392072490819600C4C632 /* CGDListCell.xib in Resources */,
F970B3682550F5AA0026F9D5 /* RetailManageViewController.xib in Resources */,
E0F3C2CC24590C86006F0D1F /* XinZengAndBianJiKeHuViewController.xib in Resources */,
E02C88272456B24F00925766 /* WuLiuGenZongViewController.xib in Resources */,
F9D44E8924CBC6A400FBD8DB /* ToAndFormSelectViewController.xib in Resources */,
......@@ -3815,6 +3837,7 @@
F9697248248F88C70010D39B /* GeliAltetCodeView.swift in Sources */,
F93615DB2480B421004187F9 /* WorkInterface.swift in Sources */,
F956D5A0246A2D9C003FF510 /* LMNImageView.m in Sources */,
F970B3672550F5AA0026F9D5 /* RetailManageViewController.swift in Sources */,
E0E341EA246E95EE0060AC20 /* PingLunCell.swift in Sources */,
F950FDDF24518B9500C40530 /* FSCalendarSeparatorDecorationView.m in Sources */,
F9023F692449A50900DD5A63 /* TitleContentCell.swift in Sources */,
......@@ -3829,6 +3852,7 @@
E040399824D14E0E008CF965 /* LalamoveInterface.swift in Sources */,
F933F6CE2452C68B00189561 /* PKHUDSquareBaseView.swift in Sources */,
E0B5308424728D7E00FFCC15 /* ShopWarehouseListModel.swift in Sources */,
F970B3752551281A0026F9D5 /* TimeShowDownView.swift in Sources */,
E06524F524580BB600CA22E2 /* BaoZhiQiCell.swift in Sources */,
E0BE8AA4245AA31400E80134 /* YingFuZhangKuanXQViewController.swift in Sources */,
F94A315324626D7800FEC38E /* WorkCViewController.swift in Sources */,
......
......@@ -29,8 +29,8 @@ class SelectContentView: UIView, UITableViewDelegate, UITableViewDataSource {
var dataArr : [String] = []{
didSet{
if dataArr.count > 3 {
if dataArr.count > 6 {
tabContentHeight.constant = 50 * 5 * glscale + 5
if dataArr.count > 8 {
tabContentHeight.constant = 50 * 7 * glscale + 5
}else{
tabContentHeight.constant = CGFloat((50 * Int(glscale)) * dataArr.count + 5)
......@@ -44,8 +44,6 @@ class SelectContentView: UIView, UITableViewDelegate, UITableViewDataSource {
func setTabv() {
tableV = UITableView()
tableV.showsVerticalScrollIndicator = false
tableV.showsHorizontalScrollIndicator = false
tabContentV.addSubview(tableV);
tableV.snp.makeConstraints { (make) in
make.left.right.bottom.equalToSuperview()
......
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="16097" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES">
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="17156" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES">
<device id="retina4_7" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="16087"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="17126"/>
<capability name="Named colors" minToolsVersion="9.0"/>
<capability name="System colors in document resources" minToolsVersion="11.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<objects>
......@@ -29,7 +30,7 @@
</view>
<view clipsSubviews="YES" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="bMO-eQ-C5Q">
<rect key="frame" x="0.0" y="-5" width="375" height="155"/>
<color key="backgroundColor" systemColor="systemBackgroundColor" cocoaTouchSystemColor="whiteColor"/>
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
<constraints>
<constraint firstAttribute="height" constant="155" id="S1h-DP-cWZ"/>
</constraints>
......@@ -63,5 +64,8 @@
<namedColor name="提示视图背景色">
<color red="0.1803921568627451" green="0.1803921568627451" blue="0.1803921568627451" alpha="0.5" colorSpace="custom" customColorSpace="sRGB"/>
</namedColor>
<systemColor name="systemBackgroundColor">
<color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</systemColor>
</resources>
</document>
//
// TimeShowDownView.swift
// GeliBusinessPlatform
//
// Created by 刘俊宏 on 2020/11/3.
// Copyright © 2020 junye lu. All rights reserved.
//
import UIKit
protocol TimeShowDownViewDeleagte {
func TimeShowDownViewRemoveForSup()
}
class TimeShowDownView: UIView,TimeSelectViewDelgate {
var delegate:TimeShowDownViewDeleagte?
@IBAction func resetAction(_ sender: UIButton) {
self.delegate?.TimeShowDownViewRemoveForSup()
self.removeFromSuperview()
}
@IBAction func sureAction(_ sender: UIButton) {
self.delegate?.TimeShowDownViewRemoveForSup()
self.removeFromSuperview()
}
@IBAction func balckTapAction(_ sender: UITapGestureRecognizer) {
self.delegate?.TimeShowDownViewRemoveForSup()
self.removeFromSuperview()
}
var BeginDate: Date! = nil
var EndDate: Date! = nil
func selectMoreDate(beginDate: Date, endginDate: Date) {
let timeInterval:TimeInterval = beginDate.timeIntervalSince1970
let timeIntervalEnd:TimeInterval = endginDate.timeIntervalSince1970
startTimeBtn.setTitle(dayByDouble(sender: timeInterval), for: .normal)
endTimeBtn.setTitle(dayByDouble(sender: timeIntervalEnd), for: .normal)
EndDate = endginDate
BeginDate = beginDate
}
@IBOutlet weak var startTimeBtn: UIButton!
@IBOutlet weak var endTimeBtn: UIButton!
var contentView:UIView!
@IBOutlet weak var timeBgView: UIView!
weak var CalendarV:TimeSelectView?
func addTimeView() {
let calendarV = TimeSelectView(frame: CGRect(x: 0, y: 8, width: fullScreenWidth, height: 230*glscale))
calendarV.moreSelection = true
timeBgView.addSubview(calendarV)
calendarV.delegate = self
CalendarV = calendarV
}
//初始化时将xib中的view添加进来
override init(frame: CGRect) {
super.init(frame: frame)
contentView = loadViewFromNib()
addSubview(contentView)
contentView.snp.makeConstraints { (make) in
make.left.top.right.bottom.equalToSuperview()
}
addTimeView()
}
// /初始化时将xib中的view添加进来
required init?(coder aDecoder: NSCoder) {
super.init(coder: aDecoder)
contentView = loadViewFromNib()
addSubview(contentView)
contentView.snp.makeConstraints { (make) in
make.left.top.right.bottom.equalToSuperview()
}
addTimeView()
}
//加载xib
func loadViewFromNib() -> UIView {
let className = type(of: self)
let bundle = Bundle(for: className)
let name = NSStringFromClass(className).components(separatedBy: ".").last
let nib = UINib(nibName: name!, bundle: bundle)
let view = nib.instantiate(withOwner: self, options: nil).first as! UIView
return view
}
}
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="17156" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina6_1" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="17126"/>
<capability name="Named colors" minToolsVersion="9.0"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="System colors in document resources" minToolsVersion="11.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<objects>
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="TimeShowDownView" customModule="TestClass" customModuleProvider="target">
<connections>
<outlet property="endTimeBtn" destination="lOj-Sp-Mq5" id="i23-XS-tZz"/>
<outlet property="startTimeBtn" destination="Bka-6f-M62" id="FAS-aY-imF"/>
<outlet property="timeBgView" destination="8TJ-1r-W1j" id="9ca-lc-jmr"/>
</connections>
</placeholder>
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
<view contentMode="scaleToFill" id="iN0-l3-epB">
<rect key="frame" x="0.0" y="0.0" width="414" height="896"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="VkG-BE-lVe">
<rect key="frame" x="0.0" y="0.0" width="414" height="896"/>
<color key="backgroundColor" name="提示视图背景色"/>
<gestureRecognizers/>
<connections>
<outletCollection property="gestureRecognizers" destination="bN2-Bv-N8T" appends="YES" id="MQY-Ub-Mhv"/>
</connections>
</view>
<view clipsSubviews="YES" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="5Di-C5-h0s">
<rect key="frame" x="0.0" y="-5" width="414" height="380"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="cdh-oT-OkP">
<rect key="frame" x="0.0" y="329" width="414" height="1"/>
<color key="backgroundColor" name="灰色分界线"/>
<constraints>
<constraint firstAttribute="height" constant="1" id="NOQ-S6-SQo"/>
</constraints>
</view>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="KFw-TT-sC6">
<rect key="frame" x="206.5" y="332" width="1" height="46"/>
<color key="backgroundColor" name="灰色分界线"/>
<constraints>
<constraint firstAttribute="width" constant="1" id="Umf-pJ-aUE"/>
</constraints>
</view>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="VP4-kd-r6a">
<rect key="frame" x="0.0" y="330" width="206.5" height="50"/>
<fontDescription key="fontDescription" name="PingFangSC-Regular" family="PingFang SC" pointSize="13"/>
<state key="normal" title="重置">
<color key="titleColor" name="灰色字体颜色"/>
</state>
<connections>
<action selector="resetAction:" destination="-1" eventType="touchUpInside" id="JKc-Gc-qd2"/>
</connections>
</button>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="Eo9-sA-fJo">
<rect key="frame" x="207.5" y="330" width="206.5" height="50"/>
<fontDescription key="fontDescription" name="PingFangSC-Regular" family="PingFang SC" pointSize="13"/>
<state key="normal" title="确定">
<color key="titleColor" name="按钮渐变色下,字体颜色"/>
</state>
<connections>
<action selector="sureAction:" destination="-1" eventType="touchUpInside" id="CcB-c6-yqO"/>
</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="OdE-m8-Pqd">
<rect key="frame" x="15" y="20" width="52" height="19"/>
<fontDescription key="fontDescription" name="PingFangSC-Regular" family="PingFang SC" pointSize="13"/>
<color key="textColor" name="标题字颜色"/>
<nil key="highlightedColor"/>
</label>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="g6F-W3-qNw">
<rect key="frame" x="15" y="49" width="230" height="32"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="至" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="7BC-YI-l1f">
<rect key="frame" x="108.5" y="6.5" width="13" height="19"/>
<fontDescription key="fontDescription" name="PingFangSC-Regular" family="PingFang SC" pointSize="13"/>
<color key="textColor" name="标题字颜色"/>
<nil key="highlightedColor"/>
</label>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="Bka-6f-M62">
<rect key="frame" x="5" y="0.5" width="98.5" height="31"/>
<fontDescription key="fontDescription" name="PingFangSC-Regular" family="PingFang SC" pointSize="13"/>
<state key="normal" title="开始时间">
<color key="titleColor" name="灰色字体颜色"/>
</state>
</button>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="lOj-Sp-Mq5">
<rect key="frame" x="126.5" y="0.5" width="98.5" height="31"/>
<fontDescription key="fontDescription" name="PingFangSC-Regular" family="PingFang SC" pointSize="13"/>
<state key="normal" title="结束时间">
<color key="titleColor" name="灰色字体颜色"/>
</state>
</button>
</subviews>
<color key="backgroundColor" name="白色背景色"/>
<constraints>
<constraint firstItem="lOj-Sp-Mq5" firstAttribute="leading" secondItem="7BC-YI-l1f" secondAttribute="trailing" constant="5" id="3rb-p5-Pi0"/>
<constraint firstItem="7BC-YI-l1f" firstAttribute="centerY" secondItem="g6F-W3-qNw" secondAttribute="centerY" id="65e-HR-rxc"/>
<constraint firstItem="7BC-YI-l1f" firstAttribute="centerX" secondItem="g6F-W3-qNw" secondAttribute="centerX" id="9P2-s2-mxP"/>
<constraint firstAttribute="height" constant="32" id="KFt-MQ-KQi"/>
<constraint firstItem="lOj-Sp-Mq5" firstAttribute="centerY" secondItem="g6F-W3-qNw" secondAttribute="centerY" id="ekp-kX-cvq"/>
<constraint firstItem="7BC-YI-l1f" firstAttribute="leading" secondItem="Bka-6f-M62" secondAttribute="trailing" constant="5" id="gSI-lk-EWt"/>
<constraint firstItem="Bka-6f-M62" firstAttribute="leading" secondItem="g6F-W3-qNw" secondAttribute="leading" constant="5" id="pV7-bH-H9v"/>
<constraint firstItem="Bka-6f-M62" firstAttribute="centerY" secondItem="g6F-W3-qNw" secondAttribute="centerY" id="ucB-Tg-VSD"/>
<constraint firstAttribute="trailing" secondItem="lOj-Sp-Mq5" secondAttribute="trailing" constant="5" id="vM9-22-Zto"/>
<constraint firstAttribute="width" constant="230" id="z6Y-Hn-anQ"/>
</constraints>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute type="number" keyPath="cornerRadius">
<integer key="value" value="3"/>
</userDefinedRuntimeAttribute>
<userDefinedRuntimeAttribute type="color" keyPath="borderColor">
<color key="value" name="app底色"/>
</userDefinedRuntimeAttribute>
<userDefinedRuntimeAttribute type="number" keyPath="borderWidth">
<real key="value" value="1"/>
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
</view>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="(可单选日期)" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="dFF-qZ-fnm">
<rect key="frame" x="250" y="65" width="77" height="16"/>
<fontDescription key="fontDescription" name="PingFangSC-Regular" family="PingFang SC" pointSize="11"/>
<color key="textColor" name="密码错误字体颜色"/>
<nil key="highlightedColor"/>
</label>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="8TJ-1r-W1j">
<rect key="frame" x="0.0" y="81" width="414" height="248"/>
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
</view>
</subviews>
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
<constraints>
<constraint firstAttribute="bottom" secondItem="cdh-oT-OkP" secondAttribute="bottom" constant="50" id="06F-no-02h"/>
<constraint firstAttribute="trailing" secondItem="8TJ-1r-W1j" secondAttribute="trailing" id="2Kq-gt-GTJ"/>
<constraint firstAttribute="bottom" secondItem="Eo9-sA-fJo" secondAttribute="bottom" id="4D8-QW-Iao"/>
<constraint firstItem="cdh-oT-OkP" firstAttribute="leading" secondItem="5Di-C5-h0s" secondAttribute="leading" id="4rO-1Q-hhB"/>
<constraint firstItem="KFw-TT-sC6" firstAttribute="top" secondItem="cdh-oT-OkP" secondAttribute="bottom" constant="2" id="5dN-3N-TiO"/>
<constraint firstAttribute="bottom" secondItem="VP4-kd-r6a" secondAttribute="bottom" id="5gV-lx-Z0L"/>
<constraint firstItem="8TJ-1r-W1j" firstAttribute="leading" secondItem="5Di-C5-h0s" secondAttribute="leading" id="72v-pe-DLz"/>
<constraint firstItem="8TJ-1r-W1j" firstAttribute="top" secondItem="g6F-W3-qNw" secondAttribute="bottom" id="Afq-V4-ZmB"/>
<constraint firstItem="g6F-W3-qNw" firstAttribute="leading" secondItem="5Di-C5-h0s" secondAttribute="leading" constant="15" id="BTp-rj-NhC"/>
<constraint firstItem="OdE-m8-Pqd" firstAttribute="leading" secondItem="5Di-C5-h0s" secondAttribute="leading" constant="15" id="Dss-cM-j9i"/>
<constraint firstItem="g6F-W3-qNw" firstAttribute="top" secondItem="OdE-m8-Pqd" secondAttribute="bottom" constant="10" id="HxH-gX-Bfg"/>
<constraint firstAttribute="trailing" secondItem="Eo9-sA-fJo" secondAttribute="trailing" id="IKR-3p-9t7"/>
<constraint firstAttribute="trailing" secondItem="cdh-oT-OkP" secondAttribute="trailing" id="O1z-Ao-zF3"/>
<constraint firstItem="OdE-m8-Pqd" firstAttribute="top" secondItem="5Di-C5-h0s" secondAttribute="top" constant="20" id="OBt-JV-2AF"/>
<constraint firstItem="KFw-TT-sC6" firstAttribute="leading" secondItem="VP4-kd-r6a" secondAttribute="trailing" id="OWz-XO-aHK"/>
<constraint firstItem="Eo9-sA-fJo" firstAttribute="leading" secondItem="KFw-TT-sC6" secondAttribute="trailing" id="RXv-0M-0FZ"/>
<constraint firstItem="VP4-kd-r6a" firstAttribute="leading" secondItem="5Di-C5-h0s" secondAttribute="leading" id="X5O-l4-s0Q"/>
<constraint firstAttribute="bottom" secondItem="KFw-TT-sC6" secondAttribute="bottom" constant="2" id="Yl6-2u-Rca"/>
<constraint firstAttribute="height" constant="380" id="g4V-9a-VpW"/>
<constraint firstItem="VP4-kd-r6a" firstAttribute="top" secondItem="cdh-oT-OkP" secondAttribute="bottom" id="geg-5Q-YK8"/>
<constraint firstItem="cdh-oT-OkP" firstAttribute="top" secondItem="8TJ-1r-W1j" secondAttribute="bottom" id="jQs-Ae-MM6"/>
<constraint firstItem="Eo9-sA-fJo" firstAttribute="top" secondItem="cdh-oT-OkP" secondAttribute="bottom" id="lZg-7A-b2u"/>
<constraint firstItem="dFF-qZ-fnm" firstAttribute="leading" secondItem="g6F-W3-qNw" secondAttribute="trailing" constant="5" id="nfT-EE-BlW"/>
<constraint firstItem="dFF-qZ-fnm" firstAttribute="bottom" secondItem="g6F-W3-qNw" secondAttribute="bottom" id="o9s-m8-8bm"/>
<constraint firstItem="KFw-TT-sC6" firstAttribute="centerX" secondItem="5Di-C5-h0s" secondAttribute="centerX" id="r2Z-gt-psP"/>
</constraints>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute type="number" keyPath="cornerRadius">
<real key="value" value="5"/>
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
</view>
</subviews>
<viewLayoutGuide key="safeArea" id="vUN-kp-3ea"/>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="5Di-C5-h0s" firstAttribute="leading" secondItem="vUN-kp-3ea" secondAttribute="leading" id="C2W-sC-XhP"/>
<constraint firstItem="VkG-BE-lVe" firstAttribute="top" secondItem="iN0-l3-epB" secondAttribute="top" id="Lee-Oc-esb"/>
<constraint firstItem="VkG-BE-lVe" firstAttribute="leading" secondItem="vUN-kp-3ea" secondAttribute="leading" id="fl8-jc-Gew"/>
<constraint firstItem="5Di-C5-h0s" firstAttribute="top" secondItem="iN0-l3-epB" secondAttribute="top" constant="-5" id="inl-Tl-SWv"/>
<constraint firstAttribute="bottom" secondItem="VkG-BE-lVe" secondAttribute="bottom" id="lIk-ms-h23"/>
<constraint firstItem="vUN-kp-3ea" firstAttribute="trailing" secondItem="VkG-BE-lVe" secondAttribute="trailing" id="mfk-AJ-2RR"/>
<constraint firstItem="vUN-kp-3ea" firstAttribute="trailing" secondItem="5Di-C5-h0s" secondAttribute="trailing" id="xBc-Ou-JLX"/>
</constraints>
<freeformSimulatedSizeMetrics key="simulatedDestinationMetrics"/>
<point key="canvasLocation" x="-1025" y="74"/>
</view>
<tapGestureRecognizer id="bN2-Bv-N8T">
<connections>
<action selector="balckTapAction:" destination="-1" id="pTn-ZG-RDp"/>
</connections>
</tapGestureRecognizer>
</objects>
<resources>
<namedColor name="app底色">
<color red="0.94509803921568625" green="0.94509803921568625" blue="0.94509803921568625" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</namedColor>
<namedColor name="密码错误字体颜色">
<color red="0.88999998569488525" green="0.27799999713897705" blue="0.27799999713897705" 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>
<namedColor name="提示视图背景色">
<color red="0.1803921568627451" green="0.1803921568627451" blue="0.1803921568627451" alpha="0.5" colorSpace="custom" customColorSpace="sRGB"/>
</namedColor>
<namedColor name="标题字颜色">
<color red="0.18000000715255737" green="0.18000000715255737" blue="0.18000000715255737" 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>
<systemColor name="systemBackgroundColor">
<color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</systemColor>
</resources>
</document>
//
// RetailManageViewController.swift
// GeliBusinessPlatform
//
// Created by 刘俊宏 on 2020/11/3.
// Copyright © 2020 junye lu. All rights reserved.
//
import UIKit
class RetailManageViewController: BaseViewController,UISearchBarDelegate,SearchBarViewDelegate,HeaderSelectViewDelegate ,SelectContentViewDelegate,TimeShowDownViewDeleagte{
@IBOutlet weak var listView: UITableView!
@IBOutlet weak var searchBgView: UIView!
@IBOutlet weak var changeBgView: UIView!
override func viewDidLoad() {
super.viewDidLoad()
navbar.title = "分销订单管理"
navbar.lineView.isHidden = true
self.view.addSubview(navbar)
SetTopFrame(view: searchBgView, height: 45)
//searchbar
initSearchBar()
initHeaderSelectView()
}
//MARK:--initSearchBar
weak var searchV: SearchBarView? = nil
var keyword = ""
func initSearchBar() {
let searchBr = SearchBarView.init()
self.searchBgView.addSubview(searchBr)
searchBr.snp.makeConstraints { (make) in
make.left.right.equalTo(0)
make.centerY.equalToSuperview()
make.height.equalTo(35)
}
searchV = searchBr
searchBr.placeholderStr = "分销员/分销商"
searchBr.cornerRadius = 35/2.0
searchBr.delegate = self
searchBr.delegateL = self
}
//MARK: - searchView delegate
func clearSearchAction() {
print("取消搜索代理了--")
}
//MARK:--编辑即将结束
func searchBarTextDidEndEditing(_ searchBar: UISearchBar) {
if keyword.count > 0 {
keyword = searchBar.text!
if keyword.count == 0 {
loadData()
}
}
removeBlackBtnView()
}
func searchBarSearchButtonClicked(_ searchBar: UISearchBar) {
print("点击搜索进行--")
searchBar.resignFirstResponder()
keyword = searchBar.text!
removeBlackBtnView()
// listView.mj_header?.beginRefreshing()
}
func searchBarShouldBeginEditing(_ searchBar: UISearchBar) -> Bool {
if showSelectV != nil {
showSelectV.removeFromSuperview()
selectV.colseBytitleArr(arr: [], index:showSelectvIndex)
}
if timeShowDView != nil {
timeShowDView.removeFromSuperview()
selectV.colseBytitleArr(arr: [], index:showSelectvIndex)
}
blackBtnView = UIButton ()
blackBtnView.backgroundColor = UIColor.init(named: "提示视图背景色")
self.view.addSubview(blackBtnView)
blackBtnView.snp.makeConstraints { (make) in
make.top.equalTo(searchBgView.snp_bottom)
make.left.right.bottom.equalToSuperview()
}
blackBtnView.addTarget(self, action: #selector(removeBlackBtnView), for: .touchUpInside)
return true
}
@objc func removeBlackBtnView(){
if blackBtnView != nil {
blackBtnView.removeFromSuperview()
searchV!.resignFirstResponder()
}
}
var blackBtnView:UIButton! = nil
//MARK:--HeaderSelectView
weak var selectV: HeaderSelectView! = nil
var showSelectvIndex = 0
weak var showSelectV: SelectContentView! = nil
weak var timeShowDView: TimeShowDownView! = nil
var selectIndexArr = [0,0,0]
func initHeaderSelectView() {
let selectView = HeaderSelectView()
selectView.firstBtn.setTitle("结算方式", for: .normal)
selectView.secBtn.setTitle("订单类型", for: .normal)
selectView.thereBtn.setTitle("结算时间", for: .normal)
changeBgView.addSubview(selectView)
selectView.snp.makeConstraints { (make) in
make.left.top.right.bottom.equalTo(0);
}
selectView.delegate = self
selectV = selectView
}
//MARK:--下拉视图模块
func showAction(sender: Int) {
showSelectvIndex = sender
switch sender {
case 0:
do {
let showSelectView = SelectContentView()
showSelectView.delegate = self
self.view.addSubview(showSelectView)
showSelectView.snp.makeConstraints { (make) in
make.left.right.bottom.equalToSuperview()
make.top.equalTo(changeBgView.snp_bottom)
}
showSelectV = showSelectView
showSelectView.dataArr = ["全部", "人工结算", "自动结算", "待自动结算", "已自动结算", "待人工结算", "已人工结算"]
showSelectView.selectIndx = selectIndexArr[0]
}
break
case 1:
do {
let showSelectView = SelectContentView()
showSelectView.delegate = self
self.view.addSubview(showSelectView)
showSelectView.snp.makeConstraints { (make) in
make.left.right.bottom.equalToSuperview()
make.top.equalTo(changeBgView.snp_bottom)
}
showSelectV = showSelectView
showSelectView.dataArr = ["全部", "分销员订单", "分销商订单"]
showSelectView.selectIndx = selectIndexArr[1]
}
break
case 2:
do {
//选择时间
let timeShowDownView = TimeShowDownView()
self.view.addSubview(timeShowDownView)
timeShowDownView.snp.makeConstraints { (make) in
make.left.right.bottom.equalToSuperview()
make.top.equalTo(changeBgView.snp_bottom)
}
timeShowDView = timeShowDownView
timeShowDownView.delegate = self
}
break
default: break
}
}
func colseAction(sender: Int) {
if showSelectV != nil {
showSelectV.removeFromSuperview()
}
if timeShowDView != nil {
timeShowDView.removeFromSuperview()
}
}
//MARK:--SelectContentViewDelegate
func didselectCell(sender: Int) {
selectIndexArr[showSelectvIndex] = sender
selectV.colseBytitleArr(arr: [], index:showSelectvIndex)
// listView.mj_header?.beginRefreshing()
}
func selectContentvRemoveForSup() {
selectV.colseBytitleArr(arr: [], index:showSelectvIndex)
}
//MARK:--TimeShowDownViewDeleagte
func TimeShowDownViewRemoveForSup() {
selectV.colseBytitleArr(arr: [], index:showSelectvIndex)
}
//MARK:--loadData
@objc func loadData(){
}
}
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="17156" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina6_1" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="17126"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="System colors in document resources" minToolsVersion="11.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<objects>
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="RetailManageViewController" customModule="TestClass" customModuleProvider="target">
<connections>
<outlet property="changeBgView" destination="Dne-dW-uPU" id="U0z-0u-4EA"/>
<outlet property="listView" destination="rD1-9Z-Grg" id="zax-lF-6eL"/>
<outlet property="searchBgView" destination="9De-Db-9oa" id="i9d-Xs-UPi"/>
<outlet property="view" destination="i5M-Pr-FkT" id="sfx-zR-JGt"/>
</connections>
</placeholder>
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
<view clearsContextBeforeDrawing="NO" contentMode="scaleToFill" id="i5M-Pr-FkT">
<rect key="frame" x="0.0" y="0.0" width="414" height="896"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="9De-Db-9oa">
<rect key="frame" x="0.0" y="44" width="414" height="45"/>
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
<constraints>
<constraint firstAttribute="height" constant="45" id="Ypr-rF-zvE"/>
</constraints>
</view>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="Dne-dW-uPU">
<rect key="frame" x="0.0" y="89" width="414" height="45"/>
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
<constraints>
<constraint firstAttribute="height" constant="45" id="6Ma-LE-6Vg"/>
</constraints>
</view>
<tableView clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" style="plain" separatorStyle="default" rowHeight="-1" estimatedRowHeight="-1" sectionHeaderHeight="28" sectionFooterHeight="28" translatesAutoresizingMaskIntoConstraints="NO" id="rD1-9Z-Grg">
<rect key="frame" x="0.0" y="134" width="414" height="762"/>
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
</tableView>
</subviews>
<viewLayoutGuide key="safeArea" id="fnl-2z-Ty3"/>
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
<constraints>
<constraint firstItem="fnl-2z-Ty3" firstAttribute="trailing" secondItem="rD1-9Z-Grg" secondAttribute="trailing" id="I3i-6b-ylF"/>
<constraint firstItem="9De-Db-9oa" firstAttribute="leading" secondItem="fnl-2z-Ty3" secondAttribute="leading" id="IMa-9D-pY4"/>
<constraint firstItem="Dne-dW-uPU" firstAttribute="leading" secondItem="i5M-Pr-FkT" secondAttribute="leading" id="RTk-rs-WuV"/>
<constraint firstItem="rD1-9Z-Grg" firstAttribute="leading" secondItem="fnl-2z-Ty3" secondAttribute="leading" id="aEw-6L-Zh2"/>
<constraint firstAttribute="bottom" secondItem="rD1-9Z-Grg" secondAttribute="bottom" id="eeT-2r-TnA"/>
<constraint firstItem="fnl-2z-Ty3" firstAttribute="trailing" secondItem="Dne-dW-uPU" secondAttribute="trailing" id="iCd-pX-M1p"/>
<constraint firstItem="fnl-2z-Ty3" firstAttribute="trailing" secondItem="9De-Db-9oa" secondAttribute="trailing" id="iEb-Y0-FwM"/>
<constraint firstItem="9De-Db-9oa" firstAttribute="top" secondItem="fnl-2z-Ty3" secondAttribute="top" id="rx4-C1-4Ad"/>
<constraint firstItem="rD1-9Z-Grg" firstAttribute="top" secondItem="Dne-dW-uPU" secondAttribute="bottom" id="vjO-k6-gBs"/>
<constraint firstItem="Dne-dW-uPU" firstAttribute="top" secondItem="9De-Db-9oa" secondAttribute="bottom" id="xzt-pE-zLt"/>
</constraints>
<point key="canvasLocation" x="109" y="127"/>
</view>
</objects>
<resources>
<systemColor name="systemBackgroundColor">
<color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</systemColor>
</resources>
</document>
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