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
0d81c224
Commit
0d81c224
authored
Aug 13, 2020
by
刘俊宏
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
取消货拉拉运单原因Vc修正
parent
b636f122
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
104 additions
and
34 deletions
+104
-34
GeliBusinessPlatform.xcworkspace/xcuserdata/liujunhong.xcuserdatad/UserInterfaceState.xcuserstate
...ata/liujunhong.xcuserdatad/UserInterfaceState.xcuserstate
+0
-0
GeliBusinessPlatform/Model/LalamoveInterface/LalamoveModel.swift
...inessPlatform/Model/LalamoveInterface/LalamoveModel.swift
+1
-0
GeliBusinessPlatform/ViewController/分类Cell/SecondCell.xib
GeliBusinessPlatform/ViewController/分类Cell/SecondCell.xib
+4
-3
GeliBusinessPlatform/ViewController/货拉拉/取消订单/HuolalaCancelViewController.swift
...ViewController/货拉拉/取消订单/HuolalaCancelViewController.swift
+99
-31
No files found.
GeliBusinessPlatform.xcworkspace/xcuserdata/liujunhong.xcuserdatad/UserInterfaceState.xcuserstate
View file @
0d81c224
No preview for this file type
GeliBusinessPlatform/Model/LalamoveInterface/LalamoveModel.swift
View file @
0d81c224
...
...
@@ -488,6 +488,7 @@ class orderCancelReasonDataModel: Mappable {
var
id
:
Int
?
var
category
:
String
?
//分类名称;示例:自己原因
var
sub_cat
:
Array
<
orderCancelReasonSubCatDataModel
>
?
var
isShow
:
Bool
=
false
required
init
?(
map
:
Map
)
{
...
...
GeliBusinessPlatform/ViewController/分类Cell/SecondCell.xib
View file @
0d81c224
<?xml version="1.0" encoding="UTF-8"?>
<document
type=
"com.apple.InterfaceBuilder3.CocoaTouch.XIB"
version=
"3.0"
toolsVersion=
"1609
6
"
targetRuntime=
"iOS.CocoaTouch"
propertyAccessControl=
"none"
useAutolayout=
"YES"
useTraitCollections=
"YES"
useSafeAreas=
"YES"
colorMatched=
"YES"
>
<document
type=
"com.apple.InterfaceBuilder3.CocoaTouch.XIB"
version=
"3.0"
toolsVersion=
"1609
7
"
targetRuntime=
"iOS.CocoaTouch"
propertyAccessControl=
"none"
useAutolayout=
"YES"
useTraitCollections=
"YES"
useSafeAreas=
"YES"
colorMatched=
"YES"
>
<device
id=
"retina6_1"
orientation=
"portrait"
appearance=
"light"
/>
<dependencies>
<plugIn
identifier=
"com.apple.InterfaceBuilder.IBCocoaTouchPlugin"
version=
"16086"
/>
<deployment
identifier=
"iOS"
/>
<plugIn
identifier=
"com.apple.InterfaceBuilder.IBCocoaTouchPlugin"
version=
"16087"
/>
<capability
name=
"Named colors"
minToolsVersion=
"9.0"
/>
<capability
name=
"Safe area layout guides"
minToolsVersion=
"9.0"
/>
<capability
name=
"documents saved in the Xcode 8 format"
minToolsVersion=
"8.0"
/>
...
...
@@ -10,7 +11,7 @@
<objects>
<placeholder
placeholderIdentifier=
"IBFilesOwner"
id=
"-1"
userLabel=
"File's Owner"
/>
<placeholder
placeholderIdentifier=
"IBFirstResponder"
id=
"-2"
customClass=
"UIResponder"
/>
<tableViewCell
contentMode=
"scaleToFill"
selectionStyle=
"default"
indentationWidth=
"10"
id=
"KGk-i7-Jjw"
customClass=
"SecondCell"
customModule=
"
GeliBusinessPlatform
"
customModuleProvider=
"target"
>
<tableViewCell
contentMode=
"scaleToFill"
selectionStyle=
"default"
indentationWidth=
"10"
id=
"KGk-i7-Jjw"
customClass=
"SecondCell"
customModule=
"
TestClass
"
customModuleProvider=
"target"
>
<rect
key=
"frame"
x=
"0.0"
y=
"0.0"
width=
"375"
height=
"49"
/>
<autoresizingMask
key=
"autoresizingMask"
flexibleMaxX=
"YES"
flexibleMaxY=
"YES"
/>
<tableViewCellContentView
key=
"contentView"
opaque=
"NO"
clipsSubviews=
"YES"
multipleTouchEnabled=
"YES"
contentMode=
"center"
tableViewCell=
"KGk-i7-Jjw"
id=
"H2p-sc-9uM"
>
...
...
GeliBusinessPlatform/ViewController/货拉拉/取消订单/HuolalaCancelViewController.swift
View file @
0d81c224
...
...
@@ -61,26 +61,29 @@ class HuolalaCancelViewController: BaseViewController ,UITableViewDelegate,UITab
return
reasonArr
.
count
}
func
tableView
(
_
tableView
:
UITableView
,
numberOfRowsInSection
section
:
Int
)
->
Int
{
let
sectionModel
=
reasonArr
[
section
]
if
reasonArr
.
count
==
1
{
return
sectionModel
.
sub_cat
!.
count
}
if
sectionModel
.
isShow
{
return
sectionModel
.
sub_cat
!.
count
}
else
{
return
0
}
return
sectionModel
.
sub_cat
!.
count
}
func
tableView
(
_
tableView
:
UITableView
,
heightForRowAt
indexPath
:
IndexPath
)
->
CGFloat
{
let
sectionModel
=
reasonArr
[
indexPath
.
section
]
let
rowModel
=
sectionModel
.
sub_cat
!
[
indexPath
.
row
]
if
rowModel
.
sub_name
==
"其他"
||
sectionModel
.
category
==
"其他"
{
if
reasonArr
.
count
==
1
{
if
selectID
==
rowModel
.
sub_id
{
return
175
}
else
{
return
50
}
if
selectID
==
rowModel
.
sub_id
{
return
175
}
else
{
return
50
}
return
50
}
return
50
}
...
...
@@ -93,21 +96,18 @@ class HuolalaCancelViewController: BaseViewController ,UITableViewDelegate,UITab
if
rowModel
.
sub_name
==
"其他"
||
sectionModel
.
category
==
"其他"
{
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
"OtherInfoTextViewTableViewCell"
)
as!
OtherInfoTextViewTableViewCell
if
reasonArr
.
count
==
1
{
if
rowModel
.
sub_id
==
selectID
{
cell
.
iconImV
.
image
=
UIImage
.
init
(
named
:
"yuxuan"
)
cell
.
nameLbl
.
textColor
=
UIColor
.
init
(
named
:
"蓝色字体颜色"
)
cell
.
textCountLbl
.
textColor
=
UIColor
.
init
(
named
:
"蓝色字体颜色"
)
cell
.
textViewBgV
.
isHidden
=
false
}
else
{
cell
.
iconImV
.
image
=
UIImage
.
init
(
named
:
"daixuan"
)
cell
.
nameLbl
.
textColor
=
UIColor
.
init
(
named
:
"标题字颜色"
)
cell
.
textCountLbl
.
textColor
=
UIColor
.
init
(
named
:
"标题字颜色"
)
cell
.
textViewBgV
.
isHidden
=
true
}
if
rowModel
.
sub_id
==
selectID
{
cell
.
iconImV
.
image
=
UIImage
.
init
(
named
:
"yuxuan"
)
cell
.
nameLbl
.
textColor
=
UIColor
.
init
(
named
:
"蓝色字体颜色"
)
cell
.
textCountLbl
.
textColor
=
UIColor
.
init
(
named
:
"蓝色字体颜色"
)
cell
.
textViewBgV
.
isHidden
=
false
}
else
{
cell
.
iconImV
.
image
=
UIImage
.
init
(
named
:
"daixuan"
)
cell
.
nameLbl
.
textColor
=
UIColor
.
init
(
named
:
"标题字颜色"
)
cell
.
textCountLbl
.
textColor
=
UIColor
.
init
(
named
:
"标题字颜色"
)
cell
.
textViewBgV
.
isHidden
=
true
}
return
cell
}
let
cell
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
"FirstCell"
)
as!
FirstCell
...
...
@@ -121,23 +121,91 @@ class HuolalaCancelViewController: BaseViewController ,UITableViewDelegate,UITab
cell
.
nameLbl
.
textColor
=
UIColor
.
init
(
named
:
"标题字颜色"
)
}
}
else
{
let
cellS
=
tableView
.
dequeueReusableCell
(
withIdentifier
:
"SecondCell"
)
as!
SecondCell
cellS
.
nameLbl
.
text
=
rowModel
.
sub_name
if
rowModel
.
sub_id
==
selectID
{
cellS
.
imgView
.
image
=
UIImage
.
init
(
named
:
"yuxuan"
)
cellS
.
nameLbl
.
textColor
=
UIColor
.
init
(
named
:
"蓝色字体颜色"
)
}
else
{
cellS
.
imgView
.
image
=
UIImage
.
init
(
named
:
"daixuan"
)
cellS
.
nameLbl
.
textColor
=
UIColor
.
init
(
named
:
"标题字颜色"
)
}
cellS
.
contentView
.
backgroundColor
=
UIColor
.
white
cellS
.
line
.
backgroundColor
=
UIColor
.
init
(
named
:
"灰色分界线"
)
return
cellS
}
return
cell
}
func
tableView
(
_
tableView
:
UITableView
,
didSelectRowAt
indexPath
:
IndexPath
)
{
let
sectionModel
=
reasonArr
[
indexPath
.
section
]
let
rowModel
=
sectionModel
.
sub_cat
!
[
indexPath
.
row
]
selectID
=
rowModel
.
sub_id
!
reason_id
=
selectID
reason
=
rowModel
.
sub_name
!
listView
.
reloadData
()
bottomLbl
.
text
=
"确定"
}
func
tableView
(
_
tableView
:
UITableView
,
viewForHeaderInSection
section
:
Int
)
->
UIView
?
{
if
reasonArr
.
count
==
1
{
selectID
=
rowModel
.
sub_id
!
reason_id
=
selectID
reason
=
rowModel
.
sub_name
!
listView
.
reloadData
()
}
else
{
return
nil
}
let
model
=
reasonArr
[
section
]
let
view
=
UIView
(
frame
:
CGRect
(
x
:
0
,
y
:
0
,
width
:
fullScreenWidth
,
height
:
50
))
view
.
backgroundColor
=
UIColor
.
white
let
nameLbl
=
UILabel
()
nameLbl
.
textColor
=
UIColor
.
init
(
named
:
"标题字颜色"
)
nameLbl
.
font
=
UIFont
.
systemFont
(
ofSize
:
13
)
view
.
addSubview
(
nameLbl
)
nameLbl
.
snp
.
makeConstraints
{
(
make
)
in
make
.
centerY
.
equalToSuperview
()
make
.
left
.
equalTo
(
15
)
}
var
img
=
UIImage
.
init
(
named
:
"3"
)
if
model
.
isShow
{
img
=
UIImage
.
init
(
named
:
"1"
)
}
let
imgV
=
UIImageView
.
init
(
image
:
img
)
view
.
addSubview
(
imgV
)
imgV
.
snp
.
makeConstraints
{
(
make
)
in
make
.
centerY
.
equalToSuperview
()
make
.
right
.
equalTo
(
-
15
)
}
let
line
=
UIView
()
line
.
backgroundColor
=
UIColor
.
init
(
named
:
"灰色分界线"
)
view
.
addSubview
(
line
)
line
.
snp
.
makeConstraints
{
(
make
)
in
make
.
left
.
equalTo
(
15
)
make
.
right
.
equalToSuperview
()
make
.
bottom
.
equalToSuperview
()
make
.
height
.
equalTo
(
1
)
}
let
showBtn
=
UIButton
()
showBtn
.
tag
=
section
view
.
addSubview
(
showBtn
)
showBtn
.
snp
.
makeConstraints
{
(
make
)
in
make
.
left
.
right
.
top
.
bottom
.
equalToSuperview
()
}
bottomLbl
.
text
=
"确定"
showBtn
.
addTarget
(
self
,
action
:
#selector(
headerShowBtnAction(sender:)
)
,
for
:
.
touchUpInside
)
nameLbl
.
text
=
model
.
category
return
view
}
@objc
func
headerShowBtnAction
(
sender
:
UIButton
)
{
reasonArr
[
sender
.
tag
]
.
isShow
=
!
reasonArr
[
sender
.
tag
]
.
isShow
listView
.
reloadData
()
}
func
tableView
(
_
tableView
:
UITableView
,
heightForHeaderInSection
section
:
Int
)
->
CGFloat
{
if
reasonArr
.
count
==
1
{
return
0.01
}
return
50
}
//MARK:--取消货拉拉运单
func
orderCancelOrder
(){
...
...
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