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
85508782
Commit
85508782
authored
Dec 07, 2020
by
lujunye
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
完善选择逻辑
parent
e495da43
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
32 additions
and
5 deletions
+32
-5
GeliBusinessPlatform.xcworkspace/xcuserdata/junyelu.xcuserdatad/UserInterfaceState.xcuserstate
...erdata/junyelu.xcuserdatad/UserInterfaceState.xcuserstate
+0
-0
GeliBusinessPlatform/ViewController/分销商品管理/FX_Product_GuanLiVC.swift
...sPlatform/ViewController/分销商品管理/FX_Product_GuanLiVC.swift
+30
-3
GeliBusinessPlatform/ViewController/分销商品管理/FX_Product_GuanLiVC.xib
...essPlatform/ViewController/分销商品管理/FX_Product_GuanLiVC.xib
+2
-2
No files found.
GeliBusinessPlatform.xcworkspace/xcuserdata/junyelu.xcuserdatad/UserInterfaceState.xcuserstate
View file @
85508782
No preview for this file type
GeliBusinessPlatform/ViewController/分销商品管理/FX_Product_GuanLiVC.swift
View file @
85508782
...
...
@@ -17,6 +17,7 @@ class FX_Product_GuanLiVC: BaseViewController,UITableViewDelegate,UITableViewDat
}
let
vc
=
DistributorSettingAlertView
(
frame
:
self
.
view
.
bounds
)
vc
.
delegate
=
self
if
selectItem
.
count
>
1
{
vc
.
is_all_select_mode
=
is_Edit
}
...
...
@@ -26,13 +27,16 @@ class FX_Product_GuanLiVC: BaseViewController,UITableViewDelegate,UITableViewDat
func
DistributorSettingAlertViewSubmitAction
(
tag
:
Int
,
operation_type
:
Int
,
dbt_price
:
String
,
commission_type
:
Int
,
commission_per
:
String
,
commission_val
:
String
,
view
:
DistributorSettingAlertView
)
{
HUD
.
flash
(
.
progress
,
delay
:
1.2
)
if
is_Edit
{
var
sku_id
=
""
for
i
in
0
..<
selectItem
.
count
{
let
model
=
datas
[
i
]
let
model
=
selectItem
[
i
]
if
i
<
selectItem
.
count
-
1
{
sku_id
+=
StringByInt
(
number
:
model
.
sku_id
!
)
+
","
sku_id
+=
StringByInt
(
number
:
model
)
+
","
}
else
{
sku_id
+=
StringByInt
(
number
:
model
.
sku_id
!
)
sku_id
+=
StringByInt
(
number
:
model
)
}
}
...
...
@@ -208,6 +212,8 @@ class FX_Product_GuanLiVC: BaseViewController,UITableViewDelegate,UITableViewDat
selectItem
.
append
(
model
.
sku_id
!
)
}
}
all_select_btn
.
setTitle
(
" 全选(已选 "
+
StringByInt
(
number
:
selectItem
.
count
)
+
" 件商品)"
,
for
:
.
normal
)
all_select_btn
.
setTitle
(
" 全选(已选 "
+
StringByInt
(
number
:
selectItem
.
count
)
+
" 件商品)"
,
for
:
.
selected
)
home_list_tbv
.
reloadData
()
}
...
...
@@ -387,6 +393,7 @@ class FX_Product_GuanLiVC: BaseViewController,UITableViewDelegate,UITableViewDat
selectItem
.
append
(
model
.
sku_id
!
)
}
all_select_btn
.
isSelected
=
false
all_select_btn
.
setTitle
(
" 全选(已选 "
+
StringByInt
(
number
:
selectItem
.
count
)
+
" 件商品)"
,
for
:
.
normal
)
home_list_tbv
.
reloadData
()
}
...
...
@@ -400,9 +407,12 @@ class FX_Product_GuanLiVC: BaseViewController,UITableViewDelegate,UITableViewDat
var
is_show
=
1
var
goods_type
=
1
//MARK:--加载数据
@objc
func
loadData
(){
print
(
"加载数据"
)
page
=
1
isUpData
=
true
goods_type
=
selectIndexArr
.
first
!
+
1
...
...
@@ -412,6 +422,8 @@ class FX_Product_GuanLiVC: BaseViewController,UITableViewDelegate,UITableViewDat
is_show
=
1
}
let
dic
=
[
"user_token"
:
UserToken
as
Any
,
"keyword"
:
keyword
as
Any
,
"page"
:
page
as
Any
,
"goods_type"
:
goods_type
as
Any
,
"is_show"
:
is_show
as
Any
]
supGoodsList
(
dic
)
{
(
data
)
in
...
...
@@ -429,6 +441,21 @@ class FX_Product_GuanLiVC: BaseViewController,UITableViewDelegate,UITableViewDat
self
.
home_list_tbv
?
.
mj_header
?
.
endRefreshing
()
self
.
page
=
2
if
self
.
selectItem
.
count
>
0
{
var
temp_arr
:
Array
<
Int
>
=
[]
self
.
datas
.
forEach
{
(
model
)
in
self
.
selectItem
.
forEach
{
(
idx
)
in
if
model
.
sku_id
==
idx
{
temp_arr
.
append
(
idx
)
}
}
}
self
.
selectItem
.
removeAll
()
temp_arr
.
forEach
{
(
sku_id
)
in
self
.
selectItem
.
append
(
sku_id
)
}
self
.
all_select_btn
.
setTitle
(
" 全选(已选 "
+
StringByInt
(
number
:
self
.
selectItem
.
count
)
+
" 件商品)"
,
for
:
.
normal
)
}
if
model
.
data
?
.
res
?
.
count
==
0
{
self
.
home_list_tbv
?
.
mj_footer
?
.
endRefreshingWithNoMoreData
()
self
.
all_select_btn
.
isUserInteractionEnabled
=
false
...
...
GeliBusinessPlatform/ViewController/分销商品管理/FX_Product_GuanLiVC.xib
View file @
85508782
...
...
@@ -180,9 +180,9 @@
</connections>
</button>
<button
opaque=
"NO"
contentMode=
"scaleToFill"
contentHorizontalAlignment=
"center"
contentVerticalAlignment=
"center"
lineBreakMode=
"middleTruncation"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"60k-Z3-oI0"
>
<rect
key=
"frame"
x=
"15"
y=
"15"
width=
"
56
"
height=
"19"
/>
<rect
key=
"frame"
x=
"15"
y=
"15"
width=
"
154
"
height=
"19"
/>
<fontDescription
key=
"fontDescription"
type=
"system"
pointSize=
"14"
/>
<state
key=
"normal"
title=
" 全选"
image=
"daixuan"
>
<state
key=
"normal"
title=
" 全选
(已选 0 件商品)
"
image=
"daixuan"
>
<color
key=
"titleColor"
name=
"标题字颜色"
/>
</state>
<state
key=
"selected"
title=
" 全选"
image=
"yuxuan"
/>
...
...
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