Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
GeliBusinessPlatform
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
CI / CD Analytics
Repository Analytics
Value Stream Analytics
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ljy
GeliBusinessPlatform
Commits
8618676d
Commit
8618676d
authored
May 25, 2020
by
lujunye
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
订单详情,编辑修改完成
parent
9fdd4c98
Changes
16
Show whitespace changes
Inline
Side-by-side
Showing
16 changed files
with
251 additions
and
93 deletions
+251
-93
GeliBusinessPlatform.xcworkspace/xcuserdata/junyelu.xcuserdatad/UserInterfaceState.xcuserstate
...erdata/junyelu.xcuserdatad/UserInterfaceState.xcuserstate
+0
-0
GeliBusinessPlatform/SceneDelegate.swift
GeliBusinessPlatform/SceneDelegate.swift
+7
-5
GeliBusinessPlatform/View/Cell/AddGuiGeCell.swift
GeliBusinessPlatform/View/Cell/AddGuiGeCell.swift
+3
-0
GeliBusinessPlatform/View/Cell/AddGuiGeCell.xib
GeliBusinessPlatform/View/Cell/AddGuiGeCell.xib
+22
-0
GeliBusinessPlatform/View/Cell/XuanZeShangPinCell.swift
GeliBusinessPlatform/View/Cell/XuanZeShangPinCell.swift
+1
-0
GeliBusinessPlatform/View/CollectionCell/GoodsCollectionViewCell.xib
...sPlatform/View/CollectionCell/GoodsCollectionViewCell.xib
+6
-6
GeliBusinessPlatform/View/TimeSelectView/ShowTimeSelectView.swift
...nessPlatform/View/TimeSelectView/ShowTimeSelectView.swift
+5
-0
GeliBusinessPlatform/View/TimeSelectView/TimeSelectView.swift
...BusinessPlatform/View/TimeSelectView/TimeSelectView.swift
+45
-14
GeliBusinessPlatform/ViewController/代客下单(购物)/XuanZeShangPinViewController.swift
...iewController/代客下单(购物)/XuanZeShangPinViewController.swift
+9
-2
GeliBusinessPlatform/ViewController/商品管理/GoodsManageListVC.swift
...inessPlatform/ViewController/商品管理/GoodsManageListVC.swift
+2
-1
GeliBusinessPlatform/ViewController/商品详情/EPViewController.swift
...sinessPlatform/ViewController/商品详情/EPViewController.swift
+24
-4
GeliBusinessPlatform/ViewController/商品详情/ProductDetailViewController.swift
...orm/ViewController/商品详情/ProductDetailViewController.swift
+20
-2
GeliBusinessPlatform/ViewController/新增、编辑品牌/PinPaiListViewController.swift
...orm/ViewController/新增、编辑品牌/PinPaiListViewController.swift
+19
-3
GeliBusinessPlatform/ViewController/新增规格/CreatNewSpecsViewController.swift
...orm/ViewController/新增规格/CreatNewSpecsViewController.swift
+63
-50
GeliBusinessPlatform/ViewController/新增规格/YuShouCell.swift
GeliBusinessPlatform/ViewController/新增规格/YuShouCell.swift
+22
-3
GeliBusinessPlatform/ViewController/新增规格/YuShouCell.xib
GeliBusinessPlatform/ViewController/新增规格/YuShouCell.xib
+3
-3
No files found.
GeliBusinessPlatform.xcworkspace/xcuserdata/junyelu.xcuserdatad/UserInterfaceState.xcuserstate
View file @
8618676d
No preview for this file type
GeliBusinessPlatform/SceneDelegate.swift
View file @
8618676d
...
@@ -43,12 +43,12 @@ class SceneDelegate: UIResponder, UIWindowSceneDelegate, UITabBarControllerDeleg
...
@@ -43,12 +43,12 @@ class SceneDelegate: UIResponder, UIWindowSceneDelegate, UITabBarControllerDeleg
//MARK:--loginVC
//MARK:--loginVC
func
addLoginVc
(
isAgain
:
Bool
){
func
addLoginVc
(
isAgain
:
Bool
){
let
vc
=
LoginViewController
()
// let vc = LoginViewController()
vc
.
delegate
=
self
// vc.delegate = self
let
contentView
=
vc
//
// let vc = DaiKeXiaDanGouWuViewController()
// let contentView = vc
// let contentView = vc
//
let
vc
=
EPViewController
()
let
contentView
=
vc
if
let
windowScene
=
sceneC
as?
UIWindowScene
{
if
let
windowScene
=
sceneC
as?
UIWindowScene
{
if
isAgain
{
if
isAgain
{
...
@@ -94,9 +94,11 @@ class SceneDelegate: UIResponder, UIWindowSceneDelegate, UITabBarControllerDeleg
...
@@ -94,9 +94,11 @@ class SceneDelegate: UIResponder, UIWindowSceneDelegate, UITabBarControllerDeleg
// Create the SwiftUI view that provides the window contents.
// Create the SwiftUI view that provides the window contents.
tabBarController
.
viewControllers
=
[
v1
,
v2
,
v3
,
v4
,
v5
]
tabBarController
.
viewControllers
=
[
v1
,
v2
,
v3
,
v4
,
v5
]
tabBarController
.
selectedIndex
=
2
tabBarController
.
selectedIndex
=
2
let
contentView
=
tabBarController
let
contentView
=
tabBarController
if
let
windowScene
=
sceneC
as?
UIWindowScene
{
if
let
windowScene
=
sceneC
as?
UIWindowScene
{
...
...
GeliBusinessPlatform/View/Cell/AddGuiGeCell.swift
View file @
8618676d
...
@@ -8,6 +8,7 @@
...
@@ -8,6 +8,7 @@
import
UIKit
import
UIKit
@objc
protocol
AddGuiGeCellDelegate
{
@objc
protocol
AddGuiGeCellDelegate
{
@objc
optional
func
AddGuiGeCellClick
(
cell
:
AddGuiGeCell
)
@objc
optional
func
AddGuiGeCellClick
(
cell
:
AddGuiGeCell
)
}
}
...
@@ -19,8 +20,10 @@ class AddGuiGeCell: UITableViewCell {
...
@@ -19,8 +20,10 @@ class AddGuiGeCell: UITableViewCell {
}
}
@IBOutlet
weak
var
webView
:
UIWebView
!
@IBOutlet
weak
var
webView
:
UIWebView
!
@IBOutlet
weak
var
imgBtn
:
UIButton
!
@IBOutlet
weak
var
imgBtn
:
UIButton
!
override
func
awakeFromNib
()
{
override
func
awakeFromNib
()
{
super
.
awakeFromNib
()
super
.
awakeFromNib
()
...
...
GeliBusinessPlatform/View/Cell/AddGuiGeCell.xib
View file @
8618676d
...
@@ -27,6 +27,7 @@
...
@@ -27,6 +27,7 @@
<action
selector=
"btnClick:"
destination=
"KGk-i7-Jjw"
eventType=
"touchUpInside"
id=
"f2z-zc-fd6"
/>
<action
selector=
"btnClick:"
destination=
"KGk-i7-Jjw"
eventType=
"touchUpInside"
id=
"f2z-zc-fd6"
/>
</connections>
</connections>
</button>
</button>
<<<<<<
< Updated
upstream
<webView
hidden=
"YES"
contentMode=
"scaleToFill"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"VPT-Oe-WSi"
>
<webView
hidden=
"YES"
contentMode=
"scaleToFill"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"VPT-Oe-WSi"
>
<rect
key=
"frame"
x=
"0.0"
y=
"0.0"
width=
"375"
height=
"123.5"
/>
<rect
key=
"frame"
x=
"0.0"
y=
"0.0"
width=
"375"
height=
"123.5"
/>
<color
key=
"backgroundColor"
red=
"0.36078431370000003"
green=
"0.38823529410000002"
blue=
"0.4039215686"
alpha=
"1"
colorSpace=
"custom"
customColorSpace=
"sRGB"
/>
<color
key=
"backgroundColor"
red=
"0.36078431370000003"
green=
"0.38823529410000002"
blue=
"0.4039215686"
alpha=
"1"
colorSpace=
"custom"
customColorSpace=
"sRGB"
/>
...
@@ -40,6 +41,23 @@
...
@@ -40,6 +41,23 @@
<constraint
firstItem=
"VPT-Oe-WSi"
firstAttribute=
"leading"
secondItem=
"H2p-sc-9uM"
secondAttribute=
"leading"
id=
"Req-lk-rDq"
/>
<constraint
firstItem=
"VPT-Oe-WSi"
firstAttribute=
"leading"
secondItem=
"H2p-sc-9uM"
secondAttribute=
"leading"
id=
"Req-lk-rDq"
/>
<constraint
firstAttribute=
"trailing"
secondItem=
"VPT-Oe-WSi"
secondAttribute=
"trailing"
id=
"Xg4-F3-bgr"
/>
<constraint
firstAttribute=
"trailing"
secondItem=
"VPT-Oe-WSi"
secondAttribute=
"trailing"
id=
"Xg4-F3-bgr"
/>
<constraint
firstAttribute=
"bottom"
secondItem=
"VPT-Oe-WSi"
secondAttribute=
"bottom"
id=
"kSn-lp-ILF"
/>
<constraint
firstAttribute=
"bottom"
secondItem=
"VPT-Oe-WSi"
secondAttribute=
"bottom"
id=
"kSn-lp-ILF"
/>
=======
<wkWebView
hidden=
"YES"
contentMode=
"scaleToFill"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"CAr-OI-1ll"
>
<rect
key=
"frame"
x=
"0.0"
y=
"0.0"
width=
"375"
height=
"123.5"
/>
<color
key=
"backgroundColor"
red=
"0.36078431370000003"
green=
"0.38823529410000002"
blue=
"0.4039215686"
alpha=
"1"
colorSpace=
"custom"
customColorSpace=
"sRGB"
/>
<wkWebViewConfiguration
key=
"configuration"
>
<audiovisualMediaTypes
key=
"mediaTypesRequiringUserActionForPlayback"
none=
"YES"
/>
<wkPreferences
key=
"preferences"
/>
</wkWebViewConfiguration>
</wkWebView>
</subviews>
<constraints>
<constraint
firstItem=
"FpT-RN-ad7"
firstAttribute=
"centerX"
secondItem=
"H2p-sc-9uM"
secondAttribute=
"centerX"
id=
"CTD-cA-1jp"
/>
<constraint
firstItem=
"CAr-OI-1ll"
firstAttribute=
"leading"
secondItem=
"H2p-sc-9uM"
secondAttribute=
"leading"
id=
"ONc-Hx-udy"
/>
<constraint
firstAttribute=
"trailing"
secondItem=
"CAr-OI-1ll"
secondAttribute=
"trailing"
id=
"TDz-Oa-TvQ"
/>
<constraint
firstItem=
"CAr-OI-1ll"
firstAttribute=
"top"
secondItem=
"H2p-sc-9uM"
secondAttribute=
"top"
id=
"YRm-tl-0No"
/>
<constraint
firstAttribute=
"bottom"
secondItem=
"CAr-OI-1ll"
secondAttribute=
"bottom"
id=
"jKB-ok-a3G"
/>
>>>>>>> Stashed changes
<constraint
firstAttribute=
"bottom"
secondItem=
"FpT-RN-ad7"
secondAttribute=
"bottom"
constant=
"50"
id=
"log-wz-xog"
/>
<constraint
firstAttribute=
"bottom"
secondItem=
"FpT-RN-ad7"
secondAttribute=
"bottom"
constant=
"50"
id=
"log-wz-xog"
/>
<constraint
firstItem=
"VPT-Oe-WSi"
firstAttribute=
"top"
secondItem=
"H2p-sc-9uM"
secondAttribute=
"top"
id=
"z8u-Ne-QN3"
/>
<constraint
firstItem=
"VPT-Oe-WSi"
firstAttribute=
"top"
secondItem=
"H2p-sc-9uM"
secondAttribute=
"top"
id=
"z8u-Ne-QN3"
/>
</constraints>
</constraints>
...
@@ -48,7 +66,11 @@
...
@@ -48,7 +66,11 @@
<connections>
<connections>
<outlet
property=
"btmH"
destination=
"log-wz-xog"
id=
"axu-Jf-zWN"
/>
<outlet
property=
"btmH"
destination=
"log-wz-xog"
id=
"axu-Jf-zWN"
/>
<outlet
property=
"imgBtn"
destination=
"FpT-RN-ad7"
id=
"DdI-mW-7wW"
/>
<outlet
property=
"imgBtn"
destination=
"FpT-RN-ad7"
id=
"DdI-mW-7wW"
/>
<<<<<<
< Updated
upstream
<outlet
property=
"webView"
destination=
"VPT-Oe-WSi"
id=
"zDL-Pq-yMr"
/>
<outlet
property=
"webView"
destination=
"VPT-Oe-WSi"
id=
"zDL-Pq-yMr"
/>
=======
<outlet
property=
"webView"
destination=
"CAr-OI-1ll"
id=
"L9y-OD-5rY"
/>
>>>>>>> Stashed changes
</connections>
</connections>
<point
key=
"canvasLocation"
x=
"131.15942028985509"
y=
"121.875"
/>
<point
key=
"canvasLocation"
x=
"131.15942028985509"
y=
"121.875"
/>
</tableViewCell>
</tableViewCell>
...
...
GeliBusinessPlatform/View/Cell/XuanZeShangPinCell.swift
View file @
8618676d
...
@@ -17,6 +17,7 @@ class XuanZeShangPinCell: UITableViewCell{
...
@@ -17,6 +17,7 @@ class XuanZeShangPinCell: UITableViewCell{
var
sku_id
:
Int
?
var
sku_id
:
Int
?
var
model
:
GetGoodsInfoDataModel
?
var
model
:
GetGoodsInfoDataModel
?
var
maxNum
:
Int
?
=
0
var
maxNum
:
Int
?
=
0
@IBOutlet
weak
var
iconImg
:
UIImageView
!
@IBOutlet
weak
var
iconImg
:
UIImageView
!
@IBOutlet
weak
var
priceLbl
:
UILabel
!
@IBOutlet
weak
var
priceLbl
:
UILabel
!
@IBOutlet
weak
var
yuShouImg
:
UIImageView
!
@IBOutlet
weak
var
yuShouImg
:
UIImageView
!
...
...
GeliBusinessPlatform/View/CollectionCell/GoodsCollectionViewCell.xib
View file @
8618676d
...
@@ -10,7 +10,7 @@
...
@@ -10,7 +10,7 @@
<objects>
<objects>
<placeholder
placeholderIdentifier=
"IBFilesOwner"
id=
"-1"
userLabel=
"File's Owner"
/>
<placeholder
placeholderIdentifier=
"IBFilesOwner"
id=
"-1"
userLabel=
"File's Owner"
/>
<placeholder
placeholderIdentifier=
"IBFirstResponder"
id=
"-2"
customClass=
"UIResponder"
/>
<placeholder
placeholderIdentifier=
"IBFirstResponder"
id=
"-2"
customClass=
"UIResponder"
/>
<collectionViewCell
opaque=
"NO"
clipsSubviews=
"YES"
multipleTouchEnabled=
"YES"
contentMode=
"center"
restorationIdentifier=
"GoodsCollectionViewCell"
id=
"gTV-IL-0wX"
customClass=
"GoodsCollectionViewCell"
customModule=
"
GeliBusinessPlatform
"
customModuleProvider=
"target"
>
<collectionViewCell
opaque=
"NO"
clipsSubviews=
"YES"
multipleTouchEnabled=
"YES"
contentMode=
"center"
restorationIdentifier=
"GoodsCollectionViewCell"
id=
"gTV-IL-0wX"
customClass=
"GoodsCollectionViewCell"
customModule=
"
TestClass
"
customModuleProvider=
"target"
>
<rect
key=
"frame"
x=
"0.0"
y=
"0.0"
width=
"165"
height=
"283"
/>
<rect
key=
"frame"
x=
"0.0"
y=
"0.0"
width=
"165"
height=
"283"
/>
<autoresizingMask
key=
"autoresizingMask"
/>
<autoresizingMask
key=
"autoresizingMask"
/>
<view
key=
"contentView"
opaque=
"NO"
clipsSubviews=
"YES"
multipleTouchEnabled=
"YES"
contentMode=
"center"
>
<view
key=
"contentView"
opaque=
"NO"
clipsSubviews=
"YES"
multipleTouchEnabled=
"YES"
contentMode=
"center"
>
...
@@ -41,7 +41,7 @@
...
@@ -41,7 +41,7 @@
<action
selector=
"lgBtnAction:"
destination=
"gTV-IL-0wX"
eventType=
"touchUpInside"
id=
"oZP-vs-LlL"
/>
<action
selector=
"lgBtnAction:"
destination=
"gTV-IL-0wX"
eventType=
"touchUpInside"
id=
"oZP-vs-LlL"
/>
</connections>
</connections>
</view>
</view>
<imageView
clipsSubviews=
"YES"
userInteractionEnabled=
"NO"
contentMode=
"scale
AspectFit
"
horizontalHuggingPriority=
"251"
verticalHuggingPriority=
"251"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"T8c-YA-14K"
>
<imageView
clipsSubviews=
"YES"
userInteractionEnabled=
"NO"
contentMode=
"scale
ToFill
"
horizontalHuggingPriority=
"251"
verticalHuggingPriority=
"251"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"T8c-YA-14K"
>
<rect
key=
"frame"
x=
"0.0"
y=
"0.0"
width=
"165"
height=
"165"
/>
<rect
key=
"frame"
x=
"0.0"
y=
"0.0"
width=
"165"
height=
"165"
/>
<color
key=
"backgroundColor"
white=
"0.0"
alpha=
"0.0"
colorSpace=
"custom"
customColorSpace=
"genericGamma22GrayColorSpace"
/>
<color
key=
"backgroundColor"
white=
"0.0"
alpha=
"0.0"
colorSpace=
"custom"
customColorSpace=
"genericGamma22GrayColorSpace"
/>
<constraints>
<constraints>
...
@@ -49,7 +49,7 @@
...
@@ -49,7 +49,7 @@
</constraints>
</constraints>
</imageView>
</imageView>
<button
opaque=
"NO"
contentMode=
"scaleToFill"
contentHorizontalAlignment=
"center"
contentVerticalAlignment=
"center"
lineBreakMode=
"middleTruncation"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"4Xi-Jf-NQw"
>
<button
opaque=
"NO"
contentMode=
"scaleToFill"
contentHorizontalAlignment=
"center"
contentVerticalAlignment=
"center"
lineBreakMode=
"middleTruncation"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"4Xi-Jf-NQw"
>
<rect
key=
"frame"
x=
"1
19"
y=
"0.0
"
width=
"46"
height=
"30"
/>
<rect
key=
"frame"
x=
"1
21"
y=
"-1
"
width=
"46"
height=
"30"
/>
<constraints>
<constraints>
<constraint
firstAttribute=
"width"
constant=
"46"
id=
"53T-yQ-mQh"
>
<constraint
firstAttribute=
"width"
constant=
"46"
id=
"53T-yQ-mQh"
>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttributes>
...
@@ -151,7 +151,7 @@
...
@@ -151,7 +151,7 @@
<color
key=
"backgroundColor"
systemColor=
"systemBackgroundColor"
cocoaTouchSystemColor=
"whiteColor"
/>
<color
key=
"backgroundColor"
systemColor=
"systemBackgroundColor"
cocoaTouchSystemColor=
"whiteColor"
/>
<constraints>
<constraints>
<constraint
firstAttribute=
"trailing"
secondItem=
"T8c-YA-14K"
secondAttribute=
"trailing"
id=
"0aE-7k-Jte"
/>
<constraint
firstAttribute=
"trailing"
secondItem=
"T8c-YA-14K"
secondAttribute=
"trailing"
id=
"0aE-7k-Jte"
/>
<constraint
firstItem=
"4Xi-Jf-NQw"
firstAttribute=
"top"
secondItem=
"
DBH-ay-Cni"
secondAttribute=
"top
"
id=
"5dP-Ts-A7R"
/>
<constraint
firstItem=
"4Xi-Jf-NQw"
firstAttribute=
"top"
secondItem=
"
T8c-YA-14K"
secondAttribute=
"top"
constant=
"-1
"
id=
"5dP-Ts-A7R"
/>
<constraint
firstItem=
"p8r-r3-3OB"
firstAttribute=
"leading"
secondItem=
"w99-DC-tI2"
secondAttribute=
"trailing"
id=
"6Hf-Yf-TPI"
/>
<constraint
firstItem=
"p8r-r3-3OB"
firstAttribute=
"leading"
secondItem=
"w99-DC-tI2"
secondAttribute=
"trailing"
id=
"6Hf-Yf-TPI"
/>
<constraint
firstAttribute=
"bottom"
secondItem=
"zEv-lz-wzj"
secondAttribute=
"bottom"
constant=
"30"
id=
"9hh-F4-uqi"
>
<constraint
firstAttribute=
"bottom"
secondItem=
"zEv-lz-wzj"
secondAttribute=
"bottom"
constant=
"30"
id=
"9hh-F4-uqi"
>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttributes>
...
@@ -170,7 +170,7 @@
...
@@ -170,7 +170,7 @@
<constraint
firstItem=
"w99-DC-tI2"
firstAttribute=
"leading"
secondItem=
"DBH-ay-Cni"
secondAttribute=
"leading"
id=
"TfR-Fm-4jT"
/>
<constraint
firstItem=
"w99-DC-tI2"
firstAttribute=
"leading"
secondItem=
"DBH-ay-Cni"
secondAttribute=
"leading"
id=
"TfR-Fm-4jT"
/>
<constraint
firstAttribute=
"trailing"
secondItem=
"MEL-J8-S3c"
secondAttribute=
"trailing"
id=
"To8-m8-AMm"
/>
<constraint
firstAttribute=
"trailing"
secondItem=
"MEL-J8-S3c"
secondAttribute=
"trailing"
id=
"To8-m8-AMm"
/>
<constraint
firstItem=
"50H-P6-uG6"
firstAttribute=
"leading"
secondItem=
"DBH-ay-Cni"
secondAttribute=
"leading"
constant=
"10"
id=
"U8x-b9-F6R"
/>
<constraint
firstItem=
"50H-P6-uG6"
firstAttribute=
"leading"
secondItem=
"DBH-ay-Cni"
secondAttribute=
"leading"
constant=
"10"
id=
"U8x-b9-F6R"
/>
<constraint
first
Attribute=
"trailing"
secondItem=
"4Xi-Jf-NQw"
secondAttribute=
"trailing
"
id=
"UE8-ZL-mKw"
/>
<constraint
first
Item=
"T8c-YA-14K"
firstAttribute=
"trailing"
secondItem=
"4Xi-Jf-NQw"
secondAttribute=
"trailing"
constant=
"-2
"
id=
"UE8-ZL-mKw"
/>
<constraint
firstItem=
"Ygg-2c-Pm9"
firstAttribute=
"leading"
secondItem=
"p8r-r3-3OB"
secondAttribute=
"trailing"
id=
"WYO-ft-e4n"
/>
<constraint
firstItem=
"Ygg-2c-Pm9"
firstAttribute=
"leading"
secondItem=
"p8r-r3-3OB"
secondAttribute=
"trailing"
id=
"WYO-ft-e4n"
/>
<constraint
firstAttribute=
"bottom"
secondItem=
"Ygg-2c-Pm9"
secondAttribute=
"bottom"
id=
"XGh-zL-1Lu"
/>
<constraint
firstAttribute=
"bottom"
secondItem=
"Ygg-2c-Pm9"
secondAttribute=
"bottom"
id=
"XGh-zL-1Lu"
/>
<constraint
firstAttribute=
"trailing"
secondItem=
"Ygg-2c-Pm9"
secondAttribute=
"trailing"
id=
"ZTd-5t-9tY"
/>
<constraint
firstAttribute=
"trailing"
secondItem=
"Ygg-2c-Pm9"
secondAttribute=
"trailing"
id=
"ZTd-5t-9tY"
/>
...
@@ -223,7 +223,7 @@
...
@@ -223,7 +223,7 @@
<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=
"灰色字体颜色"
>
<namedColor
name=
"灰色字体颜色"
>
<color
red=
"0.40000000
596046448"
green=
"0.40000000596046448"
blue=
"0.40000000596046448
"
alpha=
"1"
colorSpace=
"custom"
customColorSpace=
"sRGB"
/>
<color
red=
"0.40000000
000000002"
green=
"0.40000000000000002"
blue=
"0.40000000000000002
"
alpha=
"1"
colorSpace=
"custom"
customColorSpace=
"sRGB"
/>
</namedColor>
</namedColor>
<namedColor
name=
"白色背景色"
>
<namedColor
name=
"白色背景色"
>
<color
red=
"1"
green=
"1"
blue=
"1"
alpha=
"1"
colorSpace=
"custom"
customColorSpace=
"sRGB"
/>
<color
red=
"1"
green=
"1"
blue=
"1"
alpha=
"1"
colorSpace=
"custom"
customColorSpace=
"sRGB"
/>
...
...
GeliBusinessPlatform/View/TimeSelectView/ShowTimeSelectView.swift
View file @
8618676d
...
@@ -106,6 +106,11 @@ class ShowTimeSelectView: UIView ,TimeSelectViewDelgate{
...
@@ -106,6 +106,11 @@ class ShowTimeSelectView: UIView ,TimeSelectViewDelgate{
let
clearBtn
=
UIButton
(
type
:
.
custom
)
let
clearBtn
=
UIButton
(
type
:
.
custom
)
let
calendarV
=
TimeSelectView
(
frame
:
CGRect
(
x
:
0
,
y
:
105*
glscale
,
width
:
fullScreenWidth
,
height
:
235*
glscale
))
let
calendarV
=
TimeSelectView
(
frame
:
CGRect
(
x
:
0
,
y
:
105*
glscale
,
width
:
fullScreenWidth
,
height
:
235*
glscale
))
var
delegate
:
ShowTimeSelectViewDelegate
?
var
delegate
:
ShowTimeSelectViewDelegate
?
var
beginDateByWork
:
Date
?
=
nil
{
didSet
{
calendarV
.
beginDateByWork
=
beginDateByWork
}
}
var
BeginDate
:
Date
!
=
nil
var
BeginDate
:
Date
!
=
nil
var
EndDate
:
Date
!
=
nil
var
EndDate
:
Date
!
=
nil
...
...
GeliBusinessPlatform/View/TimeSelectView/TimeSelectView.swift
View file @
8618676d
...
@@ -88,6 +88,9 @@ class TimeSelectView: UIView, FSCalendarDataSource, FSCalendarDelegate {
...
@@ -88,6 +88,9 @@ class TimeSelectView: UIView, FSCalendarDataSource, FSCalendarDelegate {
var
EndDate
:
Date
!
var
EndDate
:
Date
!
var
SelectAction
:
Bool
=
false
var
SelectAction
:
Bool
=
false
//MARKl:--新增限定时间 ,如果不为nil就是有限定的时间
var
beginDateByWork
:
Date
?
=
nil
func
setOldDate
(
beginD
:
Date
,
endD
:
Date
)
{
func
setOldDate
(
beginD
:
Date
,
endD
:
Date
)
{
// let previousDate = self.gregorian.date(byAdding: .day, value: -1, to: beginD)!
// let previousDate = self.gregorian.date(byAdding: .day, value: -1, to: beginD)!
// let nextDate = self.gregorian.date(byAdding: .day, value: -1, to: endD)!
// let nextDate = self.gregorian.date(byAdding: .day, value: -1, to: endD)!
...
@@ -124,21 +127,37 @@ class TimeSelectView: UIView, FSCalendarDataSource, FSCalendarDelegate {
...
@@ -124,21 +127,37 @@ class TimeSelectView: UIView, FSCalendarDataSource, FSCalendarDelegate {
func
calendar
(
_
calendar
:
FSCalendar
,
didSelect
date
:
Date
,
at
monthPosition
:
FSCalendarMonthPosition
)
{
func
calendar
(
_
calendar
:
FSCalendar
,
didSelect
date
:
Date
,
at
monthPosition
:
FSCalendarMonthPosition
)
{
let
dateA
=
self
.
gregorian
.
date
(
byAdding
:
.
day
,
value
:
1
,
to
:
date
)
!
let
dateA
=
self
.
gregorian
.
date
(
byAdding
:
.
day
,
value
:
1
,
to
:
date
)
!
print
(
"第一次选中
\(
dateA
)
"
)
print
(
"第一次选中
\(
dateA
)
"
)
if
moreSelection
{
if
moreSelection
{
if
!
SelectAction
{
if
!
SelectAction
{
let
selectArr
=
calendar
.
selectedDates
let
selectArr
=
calendar
.
selectedDates
for
select
in
selectArr
{
for
select
in
selectArr
{
calendar
.
deselect
(
select
)
calendar
.
deselect
(
select
)
}
}
if
beginDateByWork
!=
nil
{
let
number
=
numberOfDaysWithFromDate
(
fromDate
:
beginDateByWork
!
,
toDate
:
date
)
!
if
number
<
0
{
let
beginDateByWorkT
:
TimeInterval
=
beginDateByWork
!.
timeIntervalSince1970
HUD
.
flash
(
.
label
(
"所选日期不得小于"
+
dayByDouble
(
sender
:
beginDateByWorkT
)),
delay
:
1.2
)
SelectAction
=
false
}
else
{
calendarC
.
select
(
date
)
calendarC
.
select
(
date
)
BeginDate
=
date
BeginDate
=
date
SelectAction
=
true
SelectAction
=
true
EndDate
=
nil
EndDate
=
nil
}
}
else
{
}
else
{
calendarC
.
select
(
date
)
BeginDate
=
date
SelectAction
=
true
EndDate
=
nil
}
}
else
{
//MARK:--日期小于方法
let
number
=
numberOfDaysWithFromDate
(
fromDate
:
BeginDate
,
toDate
:
date
)
!
let
number
=
numberOfDaysWithFromDate
(
fromDate
:
BeginDate
,
toDate
:
date
)
!
if
number
<
0
{
if
number
<
0
{
print
(
"小于开始日期,请重新选择"
)
print
(
"小于开始日期,请重新选择"
)
...
@@ -146,10 +165,26 @@ class TimeSelectView: UIView, FSCalendarDataSource, FSCalendarDelegate {
...
@@ -146,10 +165,26 @@ class TimeSelectView: UIView, FSCalendarDataSource, FSCalendarDelegate {
for
select
in
selectArr
{
for
select
in
selectArr
{
calendar
.
deselect
(
select
)
calendar
.
deselect
(
select
)
}
}
if
beginDateByWork
!=
nil
{
let
number
=
numberOfDaysWithFromDate
(
fromDate
:
beginDateByWork
!
,
toDate
:
date
)
!
if
number
<
0
{
let
beginDateByWorkT
:
TimeInterval
=
beginDateByWork
!.
timeIntervalSince1970
HUD
.
flash
(
.
label
(
"所选日期不得小于"
+
dayByDouble
(
sender
:
beginDateByWorkT
)),
delay
:
1.2
)
SelectAction
=
false
}
else
{
calendarC
.
select
(
date
)
BeginDate
=
date
SelectAction
=
true
EndDate
=
nil
}
}
else
{
calendarC
.
select
(
date
)
calendarC
.
select
(
date
)
BeginDate
=
date
BeginDate
=
date
SelectAction
=
true
SelectAction
=
true
EndDate
=
nil
EndDate
=
nil
}
}
else
{
}
else
{
SelectAction
=
false
SelectAction
=
false
...
@@ -159,10 +194,6 @@ class TimeSelectView: UIView, FSCalendarDataSource, FSCalendarDelegate {
...
@@ -159,10 +194,6 @@ class TimeSelectView: UIView, FSCalendarDataSource, FSCalendarDelegate {
calendarC
.
select
(
dateA
)
calendarC
.
select
(
dateA
)
}
}
// let previousDate = self.gregorian.date(byAdding: .day, value: 1, to: BeginDate)!
// print("选中开始时间\(previousDate)")
// let nextDate = self.gregorian.date(byAdding: .day, value: 1, to: EndDate)!
// print("选中结束时间\(nextDate)")
self
.
delegate
?
.
selectMoreDate
(
beginDate
:
BeginDate
,
endginDate
:
EndDate
)
self
.
delegate
?
.
selectMoreDate
(
beginDate
:
BeginDate
,
endginDate
:
EndDate
)
}
}
...
...
GeliBusinessPlatform/ViewController/代客下单(购物)/XuanZeShangPinViewController.swift
View file @
8618676d
...
@@ -121,6 +121,7 @@ class XuanZeShangPinViewController: BaseViewController,UITableViewDelegate,UITab
...
@@ -121,6 +121,7 @@ class XuanZeShangPinViewController: BaseViewController,UITableViewDelegate,UITab
searchBar
.
resignFirstResponder
()
searchBar
.
resignFirstResponder
()
}
}
func
getSearch
(
sender
:
String
)
{
func
getSearch
(
sender
:
String
)
{
seacrchArr
.
removeAll
()
seacrchArr
.
removeAll
()
datas
.
forEach
{
(
md
)
in
datas
.
forEach
{
(
md
)
in
...
@@ -147,6 +148,7 @@ class XuanZeShangPinViewController: BaseViewController,UITableViewDelegate,UITab
...
@@ -147,6 +148,7 @@ class XuanZeShangPinViewController: BaseViewController,UITableViewDelegate,UITab
}
}
}
}
func
textFieldShouldReturn
(
_
textField
:
UITextField
)
->
Bool
{
func
textFieldShouldReturn
(
_
textField
:
UITextField
)
->
Bool
{
textField
.
resignFirstResponder
()
textField
.
resignFirstResponder
()
if
barTitle
==
"修改价格"
{
if
barTitle
==
"修改价格"
{
...
@@ -272,8 +274,6 @@ class XuanZeShangPinViewController: BaseViewController,UITableViewDelegate,UITab
...
@@ -272,8 +274,6 @@ class XuanZeShangPinViewController: BaseViewController,UITableViewDelegate,UITab
cell
.
selectBtn
.
isSelected
=
false
cell
.
selectBtn
.
isSelected
=
false
cell
.
btmView
.
isHidden
=
true
cell
.
btmView
.
isHidden
=
true
cell
.
btmViewHeight
.
constant
=
0
cell
.
btmViewHeight
.
constant
=
0
var
isSelectByData
=
false
var
isSelectByData
=
false
selectArr
.
forEach
{
(
md
)
in
selectArr
.
forEach
{
(
md
)
in
if
md
.
sku_id
==
model
.
sku_id
{
if
md
.
sku_id
==
model
.
sku_id
{
...
@@ -286,11 +286,13 @@ class XuanZeShangPinViewController: BaseViewController,UITableViewDelegate,UITab
...
@@ -286,11 +286,13 @@ class XuanZeShangPinViewController: BaseViewController,UITableViewDelegate,UITab
cell
.
btmViewHeight
.
constant
=
89
cell
.
btmViewHeight
.
constant
=
89
}
}
}
}
}
}
return
cell
return
cell
}
}
func
XuanZeShangPinCellTextChange
(
index
:
IndexPath
,
sender
:
XuanZeShangPinCell
)
{
func
XuanZeShangPinCellTextChange
(
index
:
IndexPath
,
sender
:
XuanZeShangPinCell
)
{
...
@@ -298,6 +300,7 @@ class XuanZeShangPinViewController: BaseViewController,UITableViewDelegate,UITab
...
@@ -298,6 +300,7 @@ class XuanZeShangPinViewController: BaseViewController,UITableViewDelegate,UITab
let
item
=
inputData
[
i
]
let
item
=
inputData
[
i
]
if
sender
.
sku_id
==
item
.
sku_id
{
if
sender
.
sku_id
==
item
.
sku_id
{
inputData
.
insert
(
sender
,
at
:
i
)
inputData
.
insert
(
sender
,
at
:
i
)
inputData
.
remove
(
at
:
i
+
1
)
inputData
.
remove
(
at
:
i
+
1
)
}
}
}
}
...
@@ -326,11 +329,13 @@ class XuanZeShangPinViewController: BaseViewController,UITableViewDelegate,UITab
...
@@ -326,11 +329,13 @@ class XuanZeShangPinViewController: BaseViewController,UITableViewDelegate,UITab
func
XuanZeShangPinCellBtnClick
(
index
:
IndexPath
)
{
func
XuanZeShangPinCellBtnClick
(
index
:
IndexPath
)
{
let
cell
=
listView
.
cellForRow
(
at
:
index
)
as!
XuanZeShangPinCell
let
cell
=
listView
.
cellForRow
(
at
:
index
)
as!
XuanZeShangPinCell
if
isYuShou
{
//预售
if
isYuShou
{
//预售
let
model
=
datas
[
index
.
row
]
let
model
=
datas
[
index
.
row
]
if
model
.
adsale_inventory
==
0
{
if
model
.
adsale_inventory
==
0
{
HUD
.
flash
(
.
label
(
"库存为0,无法下单"
),
delay
:
1.2
)
HUD
.
flash
(
.
label
(
"库存为0,无法下单"
),
delay
:
1.2
)
return
return
}
}
idx
=
index
idx
=
index
inputData
.
removeAll
()
inputData
.
removeAll
()
inputData
.
append
(
cell
)
inputData
.
append
(
cell
)
...
@@ -366,9 +371,11 @@ class XuanZeShangPinViewController: BaseViewController,UITableViewDelegate,UITab
...
@@ -366,9 +371,11 @@ class XuanZeShangPinViewController: BaseViewController,UITableViewDelegate,UITab
if
barTitle
==
"修改价格"
{
if
barTitle
==
"修改价格"
{
return
inputData
.
count
return
inputData
.
count
}
}
if
isSearch
{
if
isSearch
{
return
seacrchArr
.
count
return
seacrchArr
.
count
}
}
return
datas
.
count
return
datas
.
count
}
}
...
...
GeliBusinessPlatform/ViewController/商品管理/GoodsManageListVC.swift
View file @
8618676d
...
@@ -376,7 +376,8 @@ class GoodsManageListVC: BaseViewController, UICollectionViewDelegate, UICollect
...
@@ -376,7 +376,8 @@ class GoodsManageListVC: BaseViewController, UICollectionViewDelegate, UICollect
cell
.
delegate
=
self
cell
.
delegate
=
self
cell
.
goodsName
.
text
=
rowModel
.
goods_name
cell
.
goodsName
.
text
=
rowModel
.
goods_name
cell
.
priceLbl
.
text
=
"¥"
+
rowModel
.
price
!
cell
.
priceLbl
.
text
=
"¥"
+
rowModel
.
price
!
// cell.goodsImgV.kf.setImage(with: URL.init(string:SERVERCE_ImageHost + rowModel.goods_thumb!)!, placeholder: nil, options: nil, progressBlock: nil, completionHandler: nil)
cell
.
goodsImgV
.
sd_setImage
(
with
:
URL
(
string
:
SERVERCE_ImageHost
+
rowModel
.
goods_thumb
!
))
if
rowModel
.
is_show
==
1
{
if
rowModel
.
is_show
==
1
{
cell
.
leftBtn
.
setTitle
(
"下架"
,
for
:
.
normal
)
cell
.
leftBtn
.
setTitle
(
"下架"
,
for
:
.
normal
)
...
...
GeliBusinessPlatform/ViewController/商品详情/EPViewController.swift
View file @
8618676d
...
@@ -12,8 +12,10 @@ import Photos
...
@@ -12,8 +12,10 @@ import Photos
import
IQKeyboardManagerSwift
import
IQKeyboardManagerSwift
import
Dollar
import
Dollar
class
EPViewController
:
BaseViewController
,
UITableViewDelegate
,
UITableViewDataSource
,
TitleAndBtnCellDelegate
,
GLAlertSelectViewDelegate
,
GoodsClassViewControllerDelegate
,
PinPaiListViewControllerDelegate
,
AddImgCellDelegate
,
AddGuiGeCellDelegate
,
CreatNewSpecsViewControllerDelegate
,
ShangPinGguiGeCellDelegate
,
UICollectionViewDelegate
,
UICollectionViewDataSource
,
UICollectionViewDelegateFlowLayout
,
TitleAndSwitchCellDelegate
,
TitleAndTFCellDelegate
,
YuShouWeiKuanFaHuoCellDelegate
,
UITextFieldDelegate
,
ShowTimeSelectViewDelegate
,
LMNoteViewControllerDelegate
{
class
EPViewController
:
BaseViewController
,
UITableViewDelegate
,
UITableViewDataSource
,
TitleAndBtnCellDelegate
,
GLAlertSelectViewDelegate
,
GoodsClassViewControllerDelegate
,
PinPaiListViewControllerDelegate
,
AddImgCellDelegate
,
AddGuiGeCellDelegate
,
CreatNewSpecsViewControllerDelegate
,
ShangPinGguiGeCellDelegate
,
UICollectionViewDelegate
,
UICollectionViewDataSource
,
UICollectionViewDelegateFlowLayout
,
TitleAndSwitchCellDelegate
,
TitleAndTFCellDelegate
,
YuShouWeiKuanFaHuoCellDelegate
,
UITextFieldDelegate
,
ShowTimeSelectViewDelegate
,
LMNoteViewControllerDelegate
{
@IBOutlet
weak
var
btmBtnViewH
:
NSLayoutConstraint
!
@IBOutlet
weak
var
btmBtnViewH
:
NSLayoutConstraint
!
@IBOutlet
weak
var
listTbv
:
UITableView
!
@IBOutlet
weak
var
listTbv
:
UITableView
!
...
@@ -79,7 +81,7 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
...
@@ -79,7 +81,7 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
var
shiFouXJ
=
false
//是否询价
var
shiFouXJ
=
false
//是否询价
var
keyWord
=
""
//关键字
var
keyWord
=
""
//关键字
var
wuLiuPrice
=
""
//物流费用
var
wuLiuPrice
=
""
//物流费用
var
countrySelect
:
Int
?
//选择国家
var
countrySelect
:
Int
?
=
0
//选择国家
var
guiGeArr
:
Array
<
GuiGeModel
>
=
[]
//规格数组,根据规格资料数量控制右上角新增按钮是否显示
var
guiGeArr
:
Array
<
GuiGeModel
>
=
[]
//规格数组,根据规格资料数量控制右上角新增按钮是否显示
var
shiFouSH
=
false
//是否审核
var
shiFouSH
=
false
//是否审核
var
faHuoTime
=
""
//发货时间
var
faHuoTime
=
""
//发货时间
...
@@ -452,17 +454,22 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
...
@@ -452,17 +454,22 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
self
.
shiFouSH
=
true
self
.
shiFouSH
=
true
}
}
//预设预付定金时间段
//预设预付定金时间段
// print("abcl === ",model.data?.goods_res!.dj_time_start!)
if
model
.
data
?
.
goods_res
!.
dj_time_start
!=
0
{
let
begin
=
dayByDouble
(
sender
:
(
model
.
data
?
.
goods_res
!.
dj_time_start
)
!
)
+
"-"
+
dayByDouble
(
sender
:
(
model
.
data
?
.
goods_res
!.
dj_time_end
)
!
)
let
begin
=
dayByDouble
(
sender
:
(
model
.
data
?
.
goods_res
!.
dj_time_start
)
!
)
+
"-"
+
dayByDouble
(
sender
:
(
model
.
data
?
.
goods_res
!.
dj_time_end
)
!
)
self
.
dj_time_start
=
(
model
.
data
?
.
goods_res
!.
dj_time_start
)
self
.
dj_time_start
=
(
model
.
data
?
.
goods_res
!.
dj_time_start
)
self
.
dj_time_end
=
(
model
.
data
?
.
goods_res
!.
dj_time_end
)
self
.
dj_time_end
=
(
model
.
data
?
.
goods_res
!.
dj_time_end
)
self
.
ysszHolder
.
insert
(
begin
,
at
:
1
)
self
.
ysszHolder
.
insert
(
begin
,
at
:
1
)
self
.
ysszHolder
.
remove
(
at
:
2
)
self
.
ysszHolder
.
remove
(
at
:
2
)
}
//预设预付尾款时间段
//预设预付尾款时间段
if
model
.
data
?
.
goods_res
!.
wk_time_start
!=
0
{
let
end
=
dayByDouble
(
sender
:
(
model
.
data
?
.
goods_res
!.
wk_time_start
)
!
)
+
"-"
+
dayByDouble
(
sender
:
(
model
.
data
?
.
goods_res
!.
wk_time_end
)
!
)
let
end
=
dayByDouble
(
sender
:
(
model
.
data
?
.
goods_res
!.
wk_time_start
)
!
)
+
"-"
+
dayByDouble
(
sender
:
(
model
.
data
?
.
goods_res
!.
wk_time_end
)
!
)
self
.
wk_time_start
=
(
model
.
data
?
.
goods_res
!.
wk_time_start
)
self
.
wk_time_start
=
(
model
.
data
?
.
goods_res
!.
wk_time_start
)
self
.
wk_time_end
=
(
model
.
data
?
.
goods_res
!.
wk_time_end
)
self
.
wk_time_end
=
(
model
.
data
?
.
goods_res
!.
wk_time_end
)
self
.
ysszHolder
.
insert
(
end
,
at
:
2
)
self
.
ysszHolder
.
insert
(
end
,
at
:
2
)
self
.
ysszHolder
.
remove
(
at
:
3
)
self
.
ysszHolder
.
remove
(
at
:
3
)
}
//发货时间
//发货时间
if
model
.
data
?
.
goods_res
?
.
set_time
!=
nil
{
if
model
.
data
?
.
goods_res
?
.
set_time
!=
nil
{
self
.
faHuoTime
=
"
\(
model
.
data
!.
goods_res
!.
set_time
!
)
"
self
.
faHuoTime
=
"
\(
model
.
data
!.
goods_res
!.
set_time
!
)
"
...
@@ -632,7 +639,7 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
...
@@ -632,7 +639,7 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
"AddGuiGe"
)
as!
AddGuiGeCell
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
"AddGuiGe"
)
as!
AddGuiGeCell
cell
.
imgBtn
.
isUserInteractionEnabled
=
isAllEditing
cell
.
imgBtn
.
isUserInteractionEnabled
=
isAllEditing
cell
.
imgBtn
.
setImage
(
UIImage
(
named
:
"xinzeng"
),
for
:
.
normal
)
cell
.
imgBtn
.
setImage
(
UIImage
(
named
:
"xinzeng"
),
for
:
.
normal
)
cell
.
imgBtn
.
addTarget
(
self
,
action
:
#selector(
addGuiGe(sender:)
)
,
for
:
.
touchUpInside
)
return
cell
return
cell
case
3
:
case
3
:
if
indexPath
.
row
==
0
{
if
indexPath
.
row
==
0
{
...
@@ -690,16 +697,18 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
...
@@ -690,16 +697,18 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
}
}
default
:
default
:
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
"AddGuiGe"
)
as!
AddGuiGeCell
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
"AddGuiGe"
)
as!
AddGuiGeCell
cell
.
delegate
=
self
cell
.
imgBtn
.
isUserInteractionEnabled
=
isAllEditing
cell
.
imgBtn
.
isUserInteractionEnabled
=
isAllEditing
cell
.
imgBtn
.
tag
=
indexPath
.
row
cell
.
imgBtn
.
tag
=
indexPath
.
row
if
goodsDesc
.
count
>
0
{
if
goodsDesc
.
count
>
0
{
cell
.
webView
.
isHidden
=
false
cell
.
webView
.
isHidden
=
false
let
goodsDescHmtl
=
"<html>"
+
goodsDesc
+
"</html>"
let
goodsDescHmtl
=
"<html>"
+
goodsDesc
+
"</html>"
cell
.
webView
.
loadHTMLString
(
goodsDescHmtl
,
baseURL
:
nil
)
cell
.
webView
.
loadHTMLString
(
goodsDescHmtl
,
baseURL
:
nil
)
}
}
cell
.
imgBtn
.
setImage
(
UIImage
(
named
:
"tjxq"
),
for
:
.
normal
)
cell
.
imgBtn
.
setImage
(
UIImage
(
named
:
"tjxq"
),
for
:
.
normal
)
cell
.
btmH
.
constant
=
25
cell
.
btmH
.
constant
=
25
cell
.
imgBtn
.
addTarget
(
self
,
action
:
#selector(
AddGuiGeCellClick(cell:)
)
,
for
:
.
touchUpInside
)
return
cell
return
cell
}
}
...
@@ -712,6 +721,7 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
...
@@ -712,6 +721,7 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
@objc
func
editHtml
(){
@objc
func
editHtml
(){
print
(
"编辑软文"
)
print
(
"编辑软文"
)
let
vc
=
LMNoteViewController
()
let
vc
=
LMNoteViewController
()
vc
.
htmlStr
=
goodsDesc
;
vc
.
htmlStr
=
goodsDesc
;
vc
.
delegatedata
=
self
vc
.
delegatedata
=
self
self
.
navigationController
?
.
pushViewController
(
vc
,
animated
:
true
)
self
.
navigationController
?
.
pushViewController
(
vc
,
animated
:
true
)
...
@@ -722,6 +732,7 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
...
@@ -722,6 +732,7 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
vc
.
htmlStr
=
goodsDesc
;
vc
.
htmlStr
=
goodsDesc
;
vc
.
delegatedata
=
self
vc
.
delegatedata
=
self
self
.
navigationController
?
.
pushViewController
(
vc
,
animated
:
true
)
self
.
navigationController
?
.
pushViewController
(
vc
,
animated
:
true
)
}
}
//MARK: -- 点击按钮事件,跳转或者展示选择界面
//MARK: -- 点击按钮事件,跳转或者展示选择界面
func
btnClick
(
content
:
String
,
cell
:
TitleAndBtnCell
)
{
func
btnClick
(
content
:
String
,
cell
:
TitleAndBtnCell
)
{
...
@@ -807,9 +818,11 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
...
@@ -807,9 +818,11 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
self
.
view
.
addSubview
(
view
)
self
.
view
.
addSubview
(
view
)
glSelectView
=
view
glSelectView
=
view
}
}
if
cell
.
nameLbl
.
text
==
"预设预付定金时间段"
{
if
cell
.
nameLbl
.
text
==
"预设预付定金时间段"
{
print
(
"定金时间段"
)
print
(
"定金时间段"
)
let
timeSelectV
=
ShowTimeSelectView
(
frame
:
self
.
view
.
window
!.
bounds
)
let
timeSelectV
=
ShowTimeSelectView
(
frame
:
self
.
view
.
window
!.
bounds
)
timeSelectV
.
beginDateByWork
=
Date
()
timeSelectV
.
titleLbl
.
text
=
"预设预付定金时间段"
timeSelectV
.
titleLbl
.
text
=
"预设预付定金时间段"
timeSelectV
.
delegate
=
self
timeSelectV
.
delegate
=
self
self
.
view
.
window
?
.
addSubview
(
timeSelectV
)
self
.
view
.
window
?
.
addSubview
(
timeSelectV
)
...
@@ -818,9 +831,16 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
...
@@ -818,9 +831,16 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
}
}
if
cell
.
nameLbl
.
text
==
"预设预付尾款时间段"
{
if
cell
.
nameLbl
.
text
==
"预设预付尾款时间段"
{
print
(
"预付尾款时"
)
print
(
"预付尾款时"
)
if
dj_time_start
==
0
{
HUD
.
flash
(
.
label
(
"请先选择预付定金时间段"
),
delay
:
1.2
)
return
}
let
timeSelectV
=
ShowTimeSelectView
(
frame
:
self
.
view
.
window
!.
bounds
)
let
timeSelectV
=
ShowTimeSelectView
(
frame
:
self
.
view
.
window
!.
bounds
)
timeSelectV
.
titleLbl
.
text
=
"预设预付尾款时间段"
timeSelectV
.
titleLbl
.
text
=
"预设预付尾款时间段"
timeSelectV
.
delegate
=
self
timeSelectV
.
delegate
=
self
let
dijitime
:
TimeInterval
=
TimeInterval
(
exactly
:
(
dj_time_start
!
+
(
24
*
60
*
60
)))
!
let
beginDate
=
Date
(
timeIntervalSince1970
:
dijitime
)
timeSelectV
.
beginDateByWork
=
beginDate
self
.
view
.
window
?
.
addSubview
(
timeSelectV
)
self
.
view
.
window
?
.
addSubview
(
timeSelectV
)
isWeiTime
=
true
isWeiTime
=
true
}
}
...
@@ -1597,8 +1617,8 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
...
@@ -1597,8 +1617,8 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
var
goodsDesc
=
""
var
goodsDesc
=
""
func
getHTMLByVc
(
_
model
:
String
!
)
{
func
getHTMLByVc
(
_
model
:
String
!
)
{
goodsDesc
=
model
goodsDesc
=
model
listTbv
.
reloadData
()
listTbv
.
reloadData
()
}
}
}
}
...
...
GeliBusinessPlatform/ViewController/商品详情/ProductDetailViewController.swift
View file @
8618676d
...
@@ -43,7 +43,7 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
...
@@ -43,7 +43,7 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
let
titleArr
=
[
"商品信息"
,
"商品图片"
,
"商品规格"
,
"预售设置"
,
"其它信息"
,
"商品详情"
]
let
titleArr
=
[
"商品信息"
,
"商品图片"
,
"商品规格"
,
"预售设置"
,
"其它信息"
,
"商品详情"
]
let
spxxArr
=
[
"商品名称"
,
"商品类型"
,
"商品分类"
,
"品牌"
,
"起卖数量"
,
"是否清真"
,
"是否询价"
]
let
spxxArr
=
[
"商品名称"
,
"商品类型"
,
"商品分类"
,
"品牌"
,
"起卖数量"
,
"是否清真"
,
"是否询价"
]
var
tishixxArr
=
[
"请输入商品名称"
,
"请选择商品类型"
,
"请选择商品分类"
,
"请选择品牌"
,
"请输入起卖数量"
]
var
tishixxArr
=
[
"请输入商品名称"
,
"请选择商品类型"
,
"请选择商品分类"
,
"请选择品牌"
,
"请输入起卖数量"
]
var
tishixxArr1
=
[
"请输入关键字"
,
"请输入物流费用"
,
"
请选择国家"
,
"请选择商品状态"
,
"请选择运输方式"
]
var
tishixxArr1
=
[
"请输入关键字"
,
"请输入物流费用"
,
"
中国"
,
"请选择商品状态"
,
"请选择运输方式"
]
//国家默认值
let
sptpArr
=
[
"商品封面图(限一张)"
,
"商品主图(限五张)"
]
let
sptpArr
=
[
"商品封面图(限一张)"
,
"商品主图(限五张)"
]
let
qtxxArr
=
[
"关键字"
,
"物流费用"
,
"国家"
,
"商品状态"
,
"运输方式"
]
let
qtxxArr
=
[
"关键字"
,
"物流费用"
,
"国家"
,
"商品状态"
,
"运输方式"
]
let
ysszArr
=
[
"用户付款是否需要审核"
,
"预设预付定金时间段"
,
"预设预付尾款时间段"
,
"预设预付尾款发货时间"
]
let
ysszArr
=
[
"用户付款是否需要审核"
,
"预设预付定金时间段"
,
"预设预付尾款时间段"
,
"预设预付尾款发货时间"
]
...
@@ -70,7 +70,7 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
...
@@ -70,7 +70,7 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
var
shiFouXJ
=
false
//是否询价
var
shiFouXJ
=
false
//是否询价
var
keyWord
=
""
//关键字
var
keyWord
=
""
//关键字
var
wuLiuPrice
=
""
//物流费用
var
wuLiuPrice
=
""
//物流费用
var
countrySelect
:
Int
?
//选择国家
var
countrySelect
:
Int
?
=
0
//选择国家
var
guiGeArr
:
Array
<
GuiGeModel
>
=
[]
//规格数组,根据规格资料数量控制右上角新增按钮是否显示
var
guiGeArr
:
Array
<
GuiGeModel
>
=
[]
//规格数组,根据规格资料数量控制右上角新增按钮是否显示
var
shiFouSH
=
false
//是否审核
var
shiFouSH
=
false
//是否审核
var
faHuoTime
=
""
//发货时间
var
faHuoTime
=
""
//发货时间
...
@@ -284,6 +284,8 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
...
@@ -284,6 +284,8 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
listTbv
.
register
(
UINib
(
nibName
:
"YuShouWeiKuanFaHuoCell"
,
bundle
:
nil
),
forCellReuseIdentifier
:
"YuShouWeiKuanFaHuoCell"
)
listTbv
.
register
(
UINib
(
nibName
:
"YuShouWeiKuanFaHuoCell"
,
bundle
:
nil
),
forCellReuseIdentifier
:
"YuShouWeiKuanFaHuoCell"
)
listTbv
.
register
(
UINib
(
nibName
:
"ShangPinGguiGeCell"
,
bundle
:
nil
),
forCellReuseIdentifier
:
"ShangPinGguiGeCell"
)
listTbv
.
register
(
UINib
(
nibName
:
"ShangPinGguiGeCell"
,
bundle
:
nil
),
forCellReuseIdentifier
:
"ShangPinGguiGeCell"
)
// Do any additional setup after loading the view.
// Do any additional setup after loading the view.
}
}
//MARK: - cell delegate
//MARK: - cell delegate
func
tableView
(
_
tableView
:
UITableView
,
cellForRowAt
indexPath
:
IndexPath
)
->
UITableViewCell
{
func
tableView
(
_
tableView
:
UITableView
,
cellForRowAt
indexPath
:
IndexPath
)
->
UITableViewCell
{
...
@@ -444,8 +446,10 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
...
@@ -444,8 +446,10 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
cell
.
imgBtn
.
tag
=
indexPath
.
row
cell
.
imgBtn
.
tag
=
indexPath
.
row
if
goodsDesc
.
count
>
0
{
if
goodsDesc
.
count
>
0
{
cell
.
webView
.
isHidden
=
false
cell
.
webView
.
isHidden
=
false
let
goodsDescHmtl
=
"<html>"
+
goodsDesc
+
"</html>"
let
goodsDescHmtl
=
"<html>"
+
goodsDesc
+
"</html>"
cell
.
webView
.
loadHTMLString
(
goodsDescHmtl
,
baseURL
:
nil
)
cell
.
webView
.
loadHTMLString
(
goodsDescHmtl
,
baseURL
:
nil
)
}
}
cell
.
imgBtn
.
setImage
(
UIImage
(
named
:
"tjxq"
),
for
:
.
normal
)
cell
.
imgBtn
.
setImage
(
UIImage
(
named
:
"tjxq"
),
for
:
.
normal
)
cell
.
btmH
.
constant
=
25
cell
.
btmH
.
constant
=
25
...
@@ -464,12 +468,14 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
...
@@ -464,12 +468,14 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
@objc
func
editHtml
(){
@objc
func
editHtml
(){
print
(
"编辑软文"
)
print
(
"编辑软文"
)
let
vc
=
LMNoteViewController
()
let
vc
=
LMNoteViewController
()
vc
.
htmlStr
=
goodsDesc
;
vc
.
htmlStr
=
goodsDesc
;
vc
.
delegatedata
=
self
vc
.
delegatedata
=
self
self
.
navigationController
?
.
pushViewController
(
vc
,
animated
:
true
)
self
.
navigationController
?
.
pushViewController
(
vc
,
animated
:
true
)
}
}
func
AddGuiGeCellClick
(
cell
:
AddGuiGeCell
)
{
func
AddGuiGeCellClick
(
cell
:
AddGuiGeCell
)
{
let
vc
=
LMNoteViewController
()
let
vc
=
LMNoteViewController
()
vc
.
htmlStr
=
goodsDesc
;
vc
.
htmlStr
=
goodsDesc
;
vc
.
delegatedata
=
self
vc
.
delegatedata
=
self
...
@@ -563,6 +569,7 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
...
@@ -563,6 +569,7 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
if
cell
.
nameLbl
.
text
==
"预设预付定金时间段"
{
if
cell
.
nameLbl
.
text
==
"预设预付定金时间段"
{
print
(
"定金时间段"
)
print
(
"定金时间段"
)
let
timeSelectV
=
ShowTimeSelectView
(
frame
:
self
.
view
.
window
!.
bounds
)
let
timeSelectV
=
ShowTimeSelectView
(
frame
:
self
.
view
.
window
!.
bounds
)
timeSelectV
.
beginDateByWork
=
Date
()
timeSelectV
.
titleLbl
.
text
=
"预设预付定金时间段"
timeSelectV
.
titleLbl
.
text
=
"预设预付定金时间段"
timeSelectV
.
delegate
=
self
timeSelectV
.
delegate
=
self
self
.
view
.
window
?
.
addSubview
(
timeSelectV
)
self
.
view
.
window
?
.
addSubview
(
timeSelectV
)
...
@@ -571,9 +578,16 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
...
@@ -571,9 +578,16 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
}
}
if
cell
.
nameLbl
.
text
==
"预设预付尾款时间段"
{
if
cell
.
nameLbl
.
text
==
"预设预付尾款时间段"
{
print
(
"预付尾款时"
)
print
(
"预付尾款时"
)
if
dj_time_start
==
0
{
HUD
.
flash
(
.
label
(
"请先选择预付定金时间段"
),
delay
:
1.2
)
return
}
let
timeSelectV
=
ShowTimeSelectView
(
frame
:
self
.
view
.
window
!.
bounds
)
let
timeSelectV
=
ShowTimeSelectView
(
frame
:
self
.
view
.
window
!.
bounds
)
timeSelectV
.
titleLbl
.
text
=
"预设预付尾款时间段"
timeSelectV
.
titleLbl
.
text
=
"预设预付尾款时间段"
timeSelectV
.
delegate
=
self
timeSelectV
.
delegate
=
self
let
dijitime
:
TimeInterval
=
TimeInterval
(
exactly
:
(
dj_time_start
!
+
(
24
*
60
*
60
)))
!
let
beginDate
=
Date
(
timeIntervalSince1970
:
dijitime
)
timeSelectV
.
beginDateByWork
=
beginDate
self
.
view
.
window
?
.
addSubview
(
timeSelectV
)
self
.
view
.
window
?
.
addSubview
(
timeSelectV
)
isWeiTime
=
true
isWeiTime
=
true
}
}
...
@@ -1063,7 +1077,9 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
...
@@ -1063,7 +1077,9 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
case
4
:
return
49
case
4
:
return
49
default
:
default
:
if
goodsDesc
.
count
>
0
{
if
goodsDesc
.
count
>
0
{
return
450*
glscale
return
450*
glscale
}
}
return
98
return
98
...
@@ -1223,6 +1239,7 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
...
@@ -1223,6 +1239,7 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
}
}
}
}
//MARK:---商品详情回调的数据
//MARK:---商品详情回调的数据
var
goodsDesc
=
""
var
goodsDesc
=
""
func
getHTMLByVc
(
_
model
:
String
!
)
{
func
getHTMLByVc
(
_
model
:
String
!
)
{
...
@@ -1230,5 +1247,6 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
...
@@ -1230,5 +1247,6 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
listTbv
.
reloadData
()
listTbv
.
reloadData
()
}
}
}
}
GeliBusinessPlatform/ViewController/新增、编辑品牌/PinPaiListViewController.swift
View file @
8618676d
...
@@ -20,6 +20,7 @@ class PinPaiListViewController: BaseViewController,UISearchBarDelegate,SearchBar
...
@@ -20,6 +20,7 @@ class PinPaiListViewController: BaseViewController,UISearchBarDelegate,SearchBar
@IBOutlet
weak
var
sureBtn
:
UIButton
!
@IBOutlet
weak
var
sureBtn
:
UIButton
!
@IBOutlet
weak
var
topView
:
UIView
!
@IBOutlet
weak
var
topView
:
UIView
!
@IBOutlet
weak
var
listView
:
UITableView
!
@IBOutlet
weak
var
listView
:
UITableView
!
var
tempArr
:
Array
<
GeneralInfoBrandModel
>
?
=
[]
var
searchV
:
SearchBarView
?
=
nil
var
searchV
:
SearchBarView
?
=
nil
override
func
viewDidLoad
()
{
override
func
viewDidLoad
()
{
super
.
viewDidLoad
()
super
.
viewDidLoad
()
...
@@ -50,7 +51,7 @@ class PinPaiListViewController: BaseViewController,UISearchBarDelegate,SearchBar
...
@@ -50,7 +51,7 @@ class PinPaiListViewController: BaseViewController,UISearchBarDelegate,SearchBar
searchBr
.
cornerRadius
=
35
/
2.0
searchBr
.
cornerRadius
=
35
/
2.0
searchBr
.
delegate
=
self
searchBr
.
delegate
=
self
searchBr
.
delegateL
=
self
searchBr
.
delegateL
=
self
tempArr
=
dataModelArray
listView
.
register
(
UINib
(
nibName
:
"TitleAndSelectCell"
,
bundle
:
nil
),
forCellReuseIdentifier
:
"TitleAndSelectCell"
)
listView
.
register
(
UINib
(
nibName
:
"TitleAndSelectCell"
,
bundle
:
nil
),
forCellReuseIdentifier
:
"TitleAndSelectCell"
)
// Do any additional setup after loading the view.
// Do any additional setup after loading the view.
}
}
...
@@ -59,13 +60,29 @@ class PinPaiListViewController: BaseViewController,UISearchBarDelegate,SearchBar
...
@@ -59,13 +60,29 @@ class PinPaiListViewController: BaseViewController,UISearchBarDelegate,SearchBar
vc
.
navTitle
=
"新增品牌"
vc
.
navTitle
=
"新增品牌"
self
.
navigationController
?
.
pushViewController
(
vc
,
animated
:
true
)
self
.
navigationController
?
.
pushViewController
(
vc
,
animated
:
true
)
}
}
func
clearSearchAction
()
{
func
clearSearchAction
()
{
print
(
"清楚搜索文字"
)
print
(
"清楚搜索文字"
)
dataModelArray
?
.
removeAll
()
dataModelArray
=
tempArr
listView
.
reloadData
()
}
}
func
searchBarSearchButtonClicked
(
_
searchBar
:
UISearchBar
)
{
func
searchBarSearchButtonClicked
(
_
searchBar
:
UISearchBar
)
{
print
(
"点击搜索进行--"
)
print
(
"点击搜索进行--"
)
searchBar
.
resignFirstResponder
()
searchBar
.
resignFirstResponder
()
if
searchBar
.
text
!.
count
>
0
{
dataModelArray
?
.
removeAll
()
let
str
=
searchBar
.
text
for
item
in
tempArr
!
{
let
strName
=
item
.
brand_name
as!
NSString
if
strName
.
contains
(
str
!
){
dataModelArray
?
.
append
(
item
)
}
}
}
listView
.
reloadData
()
}
}
func
tableView
(
_
tableView
:
UITableView
,
heightForRowAt
indexPath
:
IndexPath
)
->
CGFloat
{
func
tableView
(
_
tableView
:
UITableView
,
heightForRowAt
indexPath
:
IndexPath
)
->
CGFloat
{
return
49
return
49
...
@@ -109,7 +126,6 @@ class PinPaiListViewController: BaseViewController,UISearchBarDelegate,SearchBar
...
@@ -109,7 +126,6 @@ class PinPaiListViewController: BaseViewController,UISearchBarDelegate,SearchBar
print
(
"选择品牌确定按钮"
)
print
(
"选择品牌确定按钮"
)
if
selectModel
==
nil
{
if
selectModel
==
nil
{
HUD
.
flash
(
.
label
(
"请选择品牌"
),
delay
:
1.2
)
HUD
.
flash
(
.
label
(
"请选择品牌"
),
delay
:
1.2
)
}
else
{
}
else
{
self
.
delegate
?
.
blackSelectPinPaiData
(
sender
:
selectModel
!
)
self
.
delegate
?
.
blackSelectPinPaiData
(
sender
:
selectModel
!
)
self
.
navigationController
?
.
popViewController
(
animated
:
true
)
self
.
navigationController
?
.
popViewController
(
animated
:
true
)
...
...
GeliBusinessPlatform/ViewController/新增规格/CreatNewSpecsViewController.swift
View file @
8618676d
...
@@ -137,56 +137,63 @@ class CreatNewSpecsViewController: BaseViewController,UITableViewDelegate,UITabl
...
@@ -137,56 +137,63 @@ class CreatNewSpecsViewController: BaseViewController,UITableViewDelegate,UITabl
@IBAction
func
saveAction
(
_
sender
:
Any
)
{
@IBAction
func
saveAction
(
_
sender
:
Any
)
{
print
(
"save"
)
print
(
"save"
)
print
(
"open = "
,
isJieTiOpen
)
print
(
"open = "
,
isJieTiOpen
)
// if price.count == 0 {
if
price
.
count
==
0
{
// HUD.flash(.label("请输入售价"), delay: 1.2)
HUD
.
flash
(
.
label
(
"请输入售价"
),
delay
:
1.2
)
// return
return
// }
}
// if guiGe.count == 0 {
if
guiGe
.
count
==
0
{
// HUD.flash(.label("请输入规格"), delay: 1.2)
HUD
.
flash
(
.
label
(
"请输入规格"
),
delay
:
1.2
)
// return
return
// }
}
// if weight.count == 0 {
if
weight
.
count
==
0
{
// HUD.flash(.label("请输入重量"), delay: 1.2)
HUD
.
flash
(
.
label
(
"请输入重量"
),
delay
:
1.2
)
// return
return
// }
}
// if wenDu.count == 0 {
if
wenDu
.
count
==
0
{
// HUD.flash(.label("请选择温藏"), delay: 1.2)
HUD
.
flash
(
.
label
(
"请选择温藏"
),
delay
:
1.2
)
// return
return
// }
}
// if danWei.count == 0 {
if
danWei
.
count
==
0
{
// HUD.flash(.label("请选择单位"), delay: 1.2)
HUD
.
flash
(
.
label
(
"请选择单位"
),
delay
:
1.2
)
// return
return
// }
}
//
if
isYuShouSetting
{
// for item in jieTiArr {
if
isPurnNumber
(
str
:
yuShouPrice
)
==
false
{
// let str = item as! String
HUD
.
flash
(
.
label
(
"请输入正确的预售价格"
),
delay
:
1.2
)
// let arr = str.components(separatedBy: "_")
return
// for letter in arr {
// if letter.count == 0 {//提示阶梯数据未完整
}
// HUD.flash(.label("请完整填写数据"), delay: 1.2)
if
isPurnNumber
(
str
:
ysKuCun
)
==
false
{
// return
HUD
.
flash
(
.
label
(
"请输入正确的库存"
),
delay
:
1.2
)
// }
return
// }
}
// }
}
//
if
jieTiArr
.
count
>
0
{
// for item in specalArr {
for
item
in
jieTiArr
{
// let str = item as! String
let
str
=
item
as!
String
// let arr = str.components(separatedBy: "_")
let
arr
=
str
.
components
(
separatedBy
:
"_"
)
// for letter in arr {
for
letter
in
arr
{
// if letter.count == 0 {//提示预售阶梯数据未完整
if
letter
.
count
==
0
{
//提示阶梯数据未完整
// HUD.flash(.label("请完整填写数据"), delay: 1.2)
HUD
.
flash
(
.
label
(
"请完整填写阶梯价数据"
),
delay
:
1.2
)
// return
return
// }
}
// }
}
// }
}
//
}
// let letters = yuShouPrice.components(separatedBy: "_")
// for letter in letters {
if
specalArr
.
count
>
0
{
// if letter.count == 0 {//提示预售阶梯数据未完整
for
item
in
specalArr
{
// HUD.flash(.label("请完整填写数据"), delay: 1.2)
let
str
=
item
as!
String
// return
let
arr
=
str
.
components
(
separatedBy
:
"_"
)
// }
for
letter
in
arr
{
// }
if
letter
.
count
==
0
{
//提示预售阶梯数据未完整
HUD
.
flash
(
.
label
(
"请完整填写预售阶梯价数据"
),
delay
:
1.2
)
return
}
}
}
}
dataModel
.
price
=
price
dataModel
.
price
=
price
dataModel
.
guiGe
=
guiGe
dataModel
.
guiGe
=
guiGe
...
@@ -203,6 +210,9 @@ class CreatNewSpecsViewController: BaseViewController,UITableViewDelegate,UITabl
...
@@ -203,6 +210,9 @@ class CreatNewSpecsViewController: BaseViewController,UITableViewDelegate,UITabl
dataModel
.
tempSelect
=
tempSelect
dataModel
.
tempSelect
=
tempSelect
dataModel
.
isJieTiOpen
=
isJieTiOpen
dataModel
.
isJieTiOpen
=
isJieTiOpen
dataModel
.
isOpenYSSetting
=
isOpenYSSetting
dataModel
.
isOpenYSSetting
=
isOpenYSSetting
if
DJBiLi
.
count
==
0
{
DJBiLi
=
"0"
}
dataModel
.
DJBiLi
=
DJBiLi
dataModel
.
DJBiLi
=
DJBiLi
dataModel
.
ysKuCun
=
ysKuCun
dataModel
.
ysKuCun
=
ysKuCun
if
barTitle
?
.
contains
(
"编辑"
)
==
true
{
if
barTitle
?
.
contains
(
"编辑"
)
==
true
{
...
@@ -275,6 +285,9 @@ class CreatNewSpecsViewController: BaseViewController,UITableViewDelegate,UITabl
...
@@ -275,6 +285,9 @@ class CreatNewSpecsViewController: BaseViewController,UITableViewDelegate,UITabl
//keyboardType
//keyboardType
cell
.
textTF
.
returnKeyType
=
.
done
cell
.
textTF
.
returnKeyType
=
.
done
cell
.
textTF
.
delegate
=
self
cell
.
textTF
.
delegate
=
self
if
indexPath
.
row
==
0
||
indexPath
.
row
==
2
{
cell
.
textTF
.
keyboardType
=
.
decimalPad
}
let
str
=
NSAttributedString
(
string
:
pliceHolderArr
[
indexPath
.
row
],
attributes
:
[
NSAttributedString
.
Key
.
foregroundColor
:
UIColor
(
named
:
"灰色字体颜色"
)])
let
str
=
NSAttributedString
(
string
:
pliceHolderArr
[
indexPath
.
row
],
attributes
:
[
NSAttributedString
.
Key
.
foregroundColor
:
UIColor
(
named
:
"灰色字体颜色"
)])
cell
.
textTF
.
attributedPlaceholder
=
str
cell
.
textTF
.
attributedPlaceholder
=
str
if
datasArr
.
count
>
0
{
if
datasArr
.
count
>
0
{
...
...
GeliBusinessPlatform/ViewController/新增规格/YuShouCell.swift
View file @
8618676d
...
@@ -11,7 +11,7 @@ import UIKit
...
@@ -11,7 +11,7 @@ import UIKit
@objc
optional
func
YuShouCellSwitchStatus
(
sender
:
UISwitch
)
@objc
optional
func
YuShouCellSwitchStatus
(
sender
:
UISwitch
)
@objc
optional
func
YuShouCellTFContent
(
Price
:
NSString
)
@objc
optional
func
YuShouCellTFContent
(
Price
:
NSString
)
}
}
class
YuShouCell
:
UITableViewCell
{
class
YuShouCell
:
UITableViewCell
,
UITextFieldDelegate
{
var
delegate
:
YuShouCellDelegate
?
var
delegate
:
YuShouCellDelegate
?
@IBOutlet
weak
var
inputTF3
:
UITextField
!
@IBOutlet
weak
var
inputTF3
:
UITextField
!
@IBOutlet
weak
var
inputTF2
:
UITextField
!
@IBOutlet
weak
var
inputTF2
:
UITextField
!
...
@@ -23,15 +23,34 @@ var delegate:YuShouCellDelegate?
...
@@ -23,15 +23,34 @@ var delegate:YuShouCellDelegate?
infoSw
.
transform
=
CGAffineTransform
(
scaleX
:
0.8
,
y
:
0.8
)
infoSw
.
transform
=
CGAffineTransform
(
scaleX
:
0.8
,
y
:
0.8
)
infoSw
.
addTarget
(
self
,
action
:
#selector(
switchChange(sender:)
)
,
for
:
.
valueChanged
)
infoSw
.
addTarget
(
self
,
action
:
#selector(
switchChange(sender:)
)
,
for
:
.
valueChanged
)
inputTF3
.
returnKeyType
=
.
done
inputTF1
.
returnKeyType
=
.
done
inputTF3
.
keyboardType
=
.
decimalPad
inputTF1
.
keyboardType
=
.
decimalPad
inputTF1
.
delegate
=
self
inputTF3
.
delegate
=
self
inputTF2
.
keyboardType
=
.
numberPad
inputTF1
.
addTarget
(
self
,
action
:
#selector(
textTfValueChange(sender:)
)
,
for
:
.
editingChanged
)
inputTF1
.
addTarget
(
self
,
action
:
#selector(
textTfValueChange(sender:)
)
,
for
:
.
editingChanged
)
inputTF2
.
addTarget
(
self
,
action
:
#selector(
textTfValueChange(sender:)
)
,
for
:
.
editingChanged
)
inputTF2
.
addTarget
(
self
,
action
:
#selector(
textTfValueChange(sender:)
)
,
for
:
.
editingChanged
)
inputTF3
.
addTarget
(
self
,
action
:
#selector(
textTfValueChange(sender:)
)
,
for
:
.
editingChanged
)
inputTF3
.
addTarget
(
self
,
action
:
#selector(
textTfValueChange(sender:)
)
,
for
:
.
editingChanged
)
// Initialization code
// Initialization code
}
}
func
textFieldShouldReturn
(
_
textField
:
UITextField
)
->
Bool
{
textField
.
resignFirstResponder
()
}
@objc
func
textTfValueChange
(
sender
:
UITextField
){
@objc
func
textTfValueChange
(
sender
:
UITextField
){
delegate
?
.
YuShouCellTFContent
?(
Price
:
"
\(
inputTF1
.
text
!
)
_
\(
inputTF2
.
text
!
)
_
\(
inputTF3
.
text
!
)
"
as
NSString
)
if
sender
==
inputTF3
{
let
str
=
sender
.
text
as!
NSString
if
str
.
floatValue
>
20
{
HUD
.
flash
(
.
label
(
"预售定金比例不高于20%"
),
delay
:
1.2
)
inputTF3
.
text
=
"20"
}
}
}
delegate
?
.
YuShouCellTFContent
?(
Price
:
"
\(
inputTF1
.
text
!
)
_
\(
inputTF2
.
text
!
)
_
\(
inputTF3
.
text
!
)
"
as
NSString
)
}
@objc
func
switchChange
(
sender
:
UISwitch
){
@objc
func
switchChange
(
sender
:
UISwitch
){
delegate
?
.
YuShouCellSwitchStatus
?(
sender
:
sender
)
delegate
?
.
YuShouCellSwitchStatus
?(
sender
:
sender
)
}
}
...
...
GeliBusinessPlatform/ViewController/新增规格/YuShouCell.xib
View file @
8618676d
...
@@ -10,7 +10,7 @@
...
@@ -10,7 +10,7 @@
<objects>
<objects>
<placeholder
placeholderIdentifier=
"IBFilesOwner"
id=
"-1"
userLabel=
"File's Owner"
/>
<placeholder
placeholderIdentifier=
"IBFilesOwner"
id=
"-1"
userLabel=
"File's Owner"
/>
<placeholder
placeholderIdentifier=
"IBFirstResponder"
id=
"-2"
customClass=
"UIResponder"
/>
<placeholder
placeholderIdentifier=
"IBFirstResponder"
id=
"-2"
customClass=
"UIResponder"
/>
<tableViewCell
contentMode=
"scaleToFill"
selectionStyle=
"default"
indentationWidth=
"10"
id=
"KGk-i7-Jjw"
customClass=
"YuShouCell"
customModule=
"
GeliBusinessPlatform
"
customModuleProvider=
"target"
>
<tableViewCell
contentMode=
"scaleToFill"
selectionStyle=
"default"
indentationWidth=
"10"
id=
"KGk-i7-Jjw"
customClass=
"YuShouCell"
customModule=
"
TestClass
"
customModuleProvider=
"target"
>
<rect
key=
"frame"
x=
"0.0"
y=
"0.0"
width=
"320"
height=
"184.5"
/>
<rect
key=
"frame"
x=
"0.0"
y=
"0.0"
width=
"320"
height=
"184.5"
/>
<autoresizingMask
key=
"autoresizingMask"
flexibleMaxX=
"YES"
flexibleMaxY=
"YES"
/>
<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"
>
<tableViewCellContentView
key=
"contentView"
opaque=
"NO"
clipsSubviews=
"YES"
multipleTouchEnabled=
"YES"
contentMode=
"center"
tableViewCell=
"KGk-i7-Jjw"
id=
"H2p-sc-9uM"
>
...
@@ -77,7 +77,7 @@
...
@@ -77,7 +77,7 @@
<nil
key=
"highlightedColor"
/>
<nil
key=
"highlightedColor"
/>
</label>
</label>
<textField
opaque=
"NO"
tag=
"1"
contentMode=
"scaleToFill"
contentHorizontalAlignment=
"left"
contentVerticalAlignment=
"center"
placeholder=
"请输入预售库存"
textAlignment=
"right"
minimumFontSize=
"17"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"Qb7-aM-usa"
>
<textField
opaque=
"NO"
tag=
"1"
contentMode=
"scaleToFill"
contentHorizontalAlignment=
"left"
contentVerticalAlignment=
"center"
placeholder=
"请输入预售库存"
textAlignment=
"right"
minimumFontSize=
"17"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"Qb7-aM-usa"
>
<rect
key=
"frame"
x=
"100"
y=
"89"
width=
"20
4
"
height=
"34"
/>
<rect
key=
"frame"
x=
"100"
y=
"89"
width=
"20
5
"
height=
"34"
/>
<constraints>
<constraints>
<constraint
firstAttribute=
"height"
constant=
"34"
id=
"JmO-9y-uwH"
/>
<constraint
firstAttribute=
"height"
constant=
"34"
id=
"JmO-9y-uwH"
/>
</constraints>
</constraints>
...
@@ -114,10 +114,10 @@
...
@@ -114,10 +114,10 @@
</subviews>
</subviews>
<constraints>
<constraints>
<constraint
firstItem=
"COH-zY-OUo"
firstAttribute=
"leading"
secondItem=
"gDh-Mx-qdQ"
secondAttribute=
"trailing"
constant=
"15"
id=
"2Gu-fB-DY7"
/>
<constraint
firstItem=
"COH-zY-OUo"
firstAttribute=
"leading"
secondItem=
"gDh-Mx-qdQ"
secondAttribute=
"trailing"
constant=
"15"
id=
"2Gu-fB-DY7"
/>
<constraint
firstAttribute=
"trailingMargin"
secondItem=
"Qb7-aM-usa"
secondAttribute=
"trailing"
id=
"5OZ-X0-Dvh"
/>
<constraint
firstItem=
"65l-Cs-6yM"
firstAttribute=
"top"
secondItem=
"ZyU-aV-HmY"
secondAttribute=
"bottom"
constant=
"16"
id=
"5i4-Xk-Wrs"
/>
<constraint
firstItem=
"65l-Cs-6yM"
firstAttribute=
"top"
secondItem=
"ZyU-aV-HmY"
secondAttribute=
"bottom"
constant=
"16"
id=
"5i4-Xk-Wrs"
/>
<constraint
firstAttribute=
"trailing"
secondItem=
"7Ri-WT-Tkw"
secondAttribute=
"trailing"
id=
"8XF-H9-e6S"
/>
<constraint
firstAttribute=
"trailing"
secondItem=
"7Ri-WT-Tkw"
secondAttribute=
"trailing"
id=
"8XF-H9-e6S"
/>
<constraint
firstItem=
"ZyU-aV-HmY"
firstAttribute=
"leading"
secondItem=
"H2p-sc-9uM"
secondAttribute=
"leading"
constant=
"15"
id=
"Avr-9G-c2l"
/>
<constraint
firstItem=
"ZyU-aV-HmY"
firstAttribute=
"leading"
secondItem=
"H2p-sc-9uM"
secondAttribute=
"leading"
constant=
"15"
id=
"Avr-9G-c2l"
/>
<constraint
firstAttribute=
"trailing"
secondItem=
"Qb7-aM-usa"
secondAttribute=
"trailing"
constant=
"15"
id=
"BUC-XP-jMI"
/>
<constraint
firstAttribute=
"trailing"
secondItem=
"05q-1N-wvO"
secondAttribute=
"trailing"
constant=
"15"
id=
"BVi-tR-PMA"
/>
<constraint
firstAttribute=
"trailing"
secondItem=
"05q-1N-wvO"
secondAttribute=
"trailing"
constant=
"15"
id=
"BVi-tR-PMA"
/>
<constraint
firstItem=
"COH-zY-OUo"
firstAttribute=
"centerY"
secondItem=
"gDh-Mx-qdQ"
secondAttribute=
"centerY"
id=
"Cku-Mu-C62"
/>
<constraint
firstItem=
"COH-zY-OUo"
firstAttribute=
"centerY"
secondItem=
"gDh-Mx-qdQ"
secondAttribute=
"centerY"
id=
"Cku-Mu-C62"
/>
<constraint
firstItem=
"XRF-Gv-9pf"
firstAttribute=
"leading"
secondItem=
"H2p-sc-9uM"
secondAttribute=
"leading"
constant=
"15"
id=
"DFI-bQ-jVB"
/>
<constraint
firstItem=
"XRF-Gv-9pf"
firstAttribute=
"leading"
secondItem=
"H2p-sc-9uM"
secondAttribute=
"leading"
constant=
"15"
id=
"DFI-bQ-jVB"
/>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment