Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
G
gm_flutter
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
林生雨
gm_flutter
Commits
11a4f46c
Commit
11a4f46c
authored
Jul 08, 2020
by
林生雨
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
commit
parent
44fc10b9
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
64 additions
and
14 deletions
+64
-14
LevelOnePage.dart
lib/ClueModel/page/levelOne/LevelOnePage.dart
+3
-1
LevelTwoPage.dart
lib/ClueModel/page/levelTwo/LevelTwoPage.dart
+3
-1
PlanList.dart
lib/ClueModel/page/plan/PlanList.dart
+30
-0
PlanModel.dart
lib/ClueModel/page/plan/PlanModel.dart
+13
-2
PlanPage.dart
lib/ClueModel/page/plan/PlanPage.dart
+0
-0
TopPage.dart
lib/ClueModel/page/top/TopPage.dart
+4
-1
PlanBean.dart
lib/ClueModel/server/entity/PlanBean.dart
+1
-1
PlanFeedBean.dart
lib/ClueModel/server/entity/PlanFeedBean.dart
+3
-3
MainManager.dart
lib/MainRouter/manager/MainManager.dart
+7
-5
No files found.
lib/ClueModel/page/levelOne/LevelOnePage.dart
View file @
11a4f46c
...
...
@@ -125,7 +125,9 @@ class LevelOneState extends BaseState<LevelOnePage>
_model
.
init
(()
{
_initTabBar
();
});
})));
},
paddingTop:
stateBarHeight
+
kToolbarHeight
)
)
);
}
Widget
newHomeWarp
()
{
...
...
lib/ClueModel/page/levelTwo/LevelTwoPage.dart
View file @
11a4f46c
...
...
@@ -130,7 +130,9 @@ class LevelTwoState extends BaseState<LevelTwoPage>
_model
.
init
(()
{
_initTabBar
();
});
})));
},
paddingTop:
MediaQueryData
.
fromWindow
(
window
).
padding
.
top
+
kToolbarHeight
)));
}
Widget
newHomeWarp
()
{
...
...
lib/ClueModel/page/plan/PlanList.dart
0 → 100644
View file @
11a4f46c
/*
* @author lsy
* @date 2020/7/8
**/
import
'package:flutter/cupertino.dart'
;
class
PlanList
extends
StatefulWidget
{
@override
State
<
StatefulWidget
>
createState
()
=>
PlanListState
();
}
class
PlanListState
extends
State
<
PlanList
>{
@override
void
initState
()
{
// TODO: implement initState
super
.
initState
();
}
@override
void
dispose
()
{
super
.
dispose
();
}
@override
Widget
build
(
BuildContext
context
)
{
}
}
\ No newline at end of file
lib/ClueModel/page/plan/PlanModel.dart
View file @
11a4f46c
...
...
@@ -40,10 +40,11 @@ class PlanModel extends BaseModel {
String
min_price
=
""
;
String
max_price
=
""
;
String
rank_type
=
""
;
int
page
=
1
;
int
sortPos
=
0
;
void
init
()
{
void
init
(
{
VoidCallback
call
}
)
{
ClueApiImpl
.
getInstance
()
.
getPlan
(
DioUtil
.
getInstance
().
getDio
())
.
listen
((
event
)
{
...
...
@@ -52,6 +53,9 @@ class PlanModel extends BaseModel {
sortList
=
event
.
data
.
orders
;
picLive
.
notifyView
(
event
.
data
.
ranks
);
stateLive
.
notifyView
(
ENDLOADING
);
if
(
call
!=
null
)
{
call
();
}
refreshFeed
(
true
);
}
else
{
stateLive
.
notifyView
(
FAIL
);
...
...
@@ -77,6 +81,7 @@ class PlanModel extends BaseModel {
void
refreshFeed
(
bool
clear
,
{
RefreshController
controller
})
{
if
(
clear
)
{
page
=
1
;
feedDatas
.
clear
();
}
ClueApiImpl
.
getInstance
()
...
...
@@ -85,7 +90,11 @@ class PlanModel extends BaseModel {
.
listen
((
event
)
{
if
(
event
.
error
==
0
)
{
if
(
event
.
data
.
plans
==
null
||
event
.
data
.
plans
.
isEmpty
)
{
feedsLive
.
notifyView
(
Pair
(
ENDLOADING
,
[]));
if
(
page
==
1
){
feedsLive
.
notifyView
(
Pair
(
EMPTY
,
[]));
}
else
{
feedsLive
.
notifyView
(
Pair
(
ENDLOADING
,
[]));
}
}
else
{
feedDatas
.
addAll
(
event
.
data
.
plans
);
feedsLive
.
notifyView
(
Pair
(
ENDLOADING
,
feedDatas
));
...
...
@@ -134,6 +143,7 @@ class PlanModel extends BaseModel {
}
sortPos
=
index
;
order_by
=
sortList
[
index
].
id
.
toString
();
feedsLive
.
notifyView
(
Pair
(
LOADING
,
null
));
refreshFeed
(
true
);
}
...
...
@@ -143,6 +153,7 @@ class PlanModel extends BaseModel {
}
max_price
=
max
.
toString
();
min_price
=
min
.
toString
();
feedsLive
.
notifyView
(
Pair
(
LOADING
,
null
));
refreshFeed
(
true
);
}
}
lib/ClueModel/page/plan/PlanPage.dart
View file @
11a4f46c
This diff is collapsed.
Click to expand it.
lib/ClueModel/page/top/TopPage.dart
View file @
11a4f46c
...
...
@@ -43,6 +43,7 @@ class TopPageState extends BaseState<TopPage> with TickerProviderStateMixin {
@override
void
initState
()
{
// DioUtil.getInstance().setProxy("172.30.8.245");
_model
.
rank_type
=
widget
.
rank_type
;
init
();
super
.
initState
();
...
...
@@ -94,7 +95,9 @@ class TopPageState extends BaseState<TopPage> with TickerProviderStateMixin {
child:
homeWarp
()),
),
()
{
init
();
}),
},
paddingTop:
MediaQueryData
.
fromWindow
(
window
).
padding
.
top
+
kToolbarHeight
),
);
}
...
...
lib/ClueModel/server/entity/PlanBean.dart
View file @
11a4f46c
...
...
@@ -57,7 +57,7 @@ class Data {
tags
=
new
List
<
Tags
>();
json
[
'tags'
].
forEach
((
v
)
{
tags
.
add
(
new
Tags
.
fromJson
(
v
));
});
}
areas
=
json
[
'areas'
]
!=
null
?
new
Areas
.
fromJson
(
json
[
'areas'
])
:
null
;
//
areas = json['areas'] != null ? new Areas.fromJson(json['areas']) : null;
if
(
json
[
'orders'
]
!=
null
)
{
orders
=
new
List
<
Orders
>();
json
[
'orders'
].
forEach
((
v
)
{
orders
.
add
(
new
Orders
.
fromJson
(
v
));
});
...
...
lib/ClueModel/server/entity/PlanFeedBean.dart
View file @
11a4f46c
...
...
@@ -6,7 +6,7 @@ class PlanFeedBean {
int
error
;
String
message
;
Map
extra
;
Map
errorCode
;
int
errorCode
;
Map
errorExtra
;
Data
data
;
UserType
userType
;
...
...
@@ -101,8 +101,8 @@ class Plans {
positiveRate
=
json
[
'positive_rate'
];
salesCount
=
json
[
'sales_count'
];
baseAttrs
=
json
[
'base_attrs'
].
cast
<
String
>();
minPrice
=
json
[
'min_price'
];
maxPrice
=
json
[
'max_price'
];
minPrice
=
json
[
'min_price'
]
is
int
?
"
${json['min_price']}
"
:
json
[
'min_price'
]
;
maxPrice
=
json
[
'max_price'
]
is
int
?
"
${json['max_price']}
"
:
json
[
'max_price'
]
;
projectImage
=
json
[
'project_image'
];
}
...
...
lib/MainRouter/manager/MainManager.dart
View file @
11a4f46c
...
...
@@ -59,18 +59,20 @@ class MainManager {
innerSetData
(
map
,
IS_WIFI
);
innerSetData
(
map
,
HARDWARE_MODEL
);
innerSetData
(
map
,
USER_ID
);
// innerSetData(map, COOKIE);
innerSetData
(
map
,
USER_AGENT
);
if
(
map
[
COOKIE
]
==
null
)
{
CacheManager
.
getInstance
().
get
(
MEMORY_CACHE
).
save
(
COOKIE
,
"_gm_token=1da6071594101423; csrftoken=rUrkkYYMOVZfIIQnU2IH09QIGmsfe8tE; sessionid=uz7f70uap76r6og48znci5l2hbr9vm5c; _gtid=5af9a5deba8511ea8d4082a085c393c93393"
);
}
else
{
innerSetData
(
map
,
COOKIE
);
}
innerSetData
(
map
,
BASE_URL
);
DioUtil
.
setDefOptions
(
baseUrl:
"
${map[BASE_URL]}
/"
,
cookie:
map
[
COOKIE
],
agent:
map
[
USER_AGENT
]);
if
(
map
[
COOKIE
]
==
null
)
{
CacheManager
.
getInstance
().
get
(
MEMORY_CACHE
).
save
(
COOKIE
,
"_gm_token=1da6071594101423; csrftoken=rUrkkYYMOVZfIIQnU2IH09QIGmsfe8tE; sessionid=uz7f70uap76r6og48znci5l2hbr9vm5c; _gtid=5af9a5deba8511ea8d4082a085c393c93393"
);
}
print
(
"LSY QQWWEERRTTYY
${CacheManager.getInstance().get(MEMORY_CACHE).get(COOKIE)}
"
);
DioUtil
.
getInstance
().
changeOpt
();
...
...
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