Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
X
xiaoxiaole
Project
Project
Details
Activity
Releases
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
wildfirecode13
xiaoxiaole
Commits
f2ac242d
Commit
f2ac242d
authored
Dec 04, 2019
by
邱旭
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
57aa4a66
Changes
11
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
92 additions
and
63 deletions
+92
-63
panelCtrl.ts
egret/libs/new_wx/ctrls/panelCtrl.ts
+33
-28
sign.tmproject
egret/resource/TextureMerger/sign.tmproject
+1
-1
sign_quan25.png
egret/resource/assets/sign/sign_quan25.png
+0
-0
sign_quan35.png
egret/resource/assets/sign/sign_quan35.png
+0
-0
default.res.json
egret/resource/default.res.json
+11
-1
SignItemSkin.exml
egret/resource/skins/SignItemSkin.exml
+2
-0
TaskCenterNoPrizeSkin.exml
egret/resource/skins/TaskCenterNoPrizeSkin.exml
+3
-3
TaskCenter.ts
egret/src/panels/TaskCenter/TaskCenter.ts
+11
-2
TaskCenterPrize.ts
egret/src/panels/TaskCenter/TaskCenterPrize.ts
+4
-1
getTaskInfo.json
mock/happyclear/getTaskInfo.json
+26
-26
taskAward.json
mock/happyclear/taskAward.json
+1
-1
No files found.
egret/libs/new_wx/ctrls/panelCtrl.ts
View file @
f2ac242d
...
@@ -2,41 +2,44 @@ import { ModuleTypes } from "../types/sceneTypes";
...
@@ -2,41 +2,44 @@ import { ModuleTypes } from "../types/sceneTypes";
import
Panel
from
"../components/Panel"
;
import
Panel
from
"../components/Panel"
;
import
Loading
from
"../components/Loading"
;
import
Loading
from
"../components/Loading"
;
import
wait
from
"../../new_tc/wait"
;
import
wait
from
"../../new_tc/wait"
;
export
default
class
PanelCtrl
{
export
default
class
PanelCtrl
{
addToShowPanels
(
panelName
:
string
)
{
addToShowPanels
(
panelName
:
string
)
{
this
.
_panels
.
unshift
(
panelName
);
this
.
_panels
.
unshift
(
panelName
);
}
}
_params
:
any
[]
private
_panels
:
any
[]
_params
:
any
[]
_callback
:
any
;
private
_panels
:
any
[]
showPanels
(
panels
:
any
[],
params
:
any
[],
callback
:
Function
)
{
_callback
:
any
;
this
.
_panels
=
panels
;
this
.
_params
=
params
;
showPanels
(
panels
:
any
[],
params
:
any
[],
callback
:
Function
)
{
this
.
_callback
=
callback
;
this
.
_panels
=
panels
;
if
(
panels
.
length
<=
0
)
{
this
.
_params
=
params
;
this
.
_callback
=
callback
;
if
(
panels
.
length
<=
0
)
{
this
.
_callback
();
this
.
_callback
();
this
.
_callback
=
null
;
this
.
_callback
=
null
;
}
}
if
(
this
.
_panels
.
length
<=
0
)
return
;
if
(
this
.
_panels
.
length
<=
0
)
return
;
const
panel
=
this
.
_panels
.
shift
();
const
panel
=
this
.
_panels
.
shift
();
const
param
=
this
.
_params
.
shift
();
const
param
=
this
.
_params
.
shift
();
PanelCtrl
.
instance
.
show
(
panel
,
param
);
PanelCtrl
.
instance
.
show
(
panel
,
param
);
}
}
checkPanels
(){
checkPanels
()
{
if
(
this
.
_panels
&&
this
.
_panels
.
length
<=
0
)
{
if
(
this
.
_panels
&&
this
.
_panels
.
length
<=
0
)
{
this
.
_panels
=
null
;
this
.
_panels
=
[]
;
if
(
this
.
_callback
)
this
.
_callback
();
if
(
this
.
_callback
)
this
.
_callback
();
}
}
if
(
!
this
.
_panels
||
this
.
_panels
.
length
<=
0
)
return
;
if
(
!
this
.
_panels
||
this
.
_panels
.
length
<=
0
)
return
;
wait
(
300
);
wait
(
300
);
const
panel
=
this
.
_panels
.
shift
();
const
panel
=
this
.
_panels
.
shift
();
const
param
=
this
.
_params
.
shift
();
const
param
=
this
.
_params
.
shift
();
PanelCtrl
.
instance
.
show
(
panel
,
param
);
PanelCtrl
.
instance
.
show
(
panel
,
param
);
}
}
private
_parent
:
egret
.
Sprite
;
private
_parent
:
egret
.
Sprite
;
_mask
:
egret
.
Sprite
;
_mask
:
egret
.
Sprite
;
static
_instance
:
PanelCtrl
;
static
_instance
:
PanelCtrl
;
static
get
instance
()
{
static
get
instance
()
{
return
PanelCtrl
.
_instance
||
(
PanelCtrl
.
_instance
=
new
PanelCtrl
())
return
PanelCtrl
.
_instance
||
(
PanelCtrl
.
_instance
=
new
PanelCtrl
())
...
@@ -46,13 +49,14 @@ export default class PanelCtrl {
...
@@ -46,13 +49,14 @@ export default class PanelCtrl {
this
.
_parent
=
parent
;
this
.
_parent
=
parent
;
}
}
private
noLoadingList
=
[
'StartPanel'
,
'failed'
,
'prize2'
,
ModuleTypes
.
PRIZE_PANEL
,
ModuleTypes
.
NO_PRIZE_PANEL
];
private
noLoadingList
=
[
'StartPanel'
,
'failed'
,
'prize2'
,
ModuleTypes
.
PRIZE_PANEL
,
ModuleTypes
.
NO_PRIZE_PANEL
];
show
(
type
:
any
,
data
?)
{
show
(
type
:
any
,
data
?)
{
this
.
closeCurrent
(
true
);
this
.
closeCurrent
(
true
);
const
cls
=
this
.
_panelClassMap
[
type
];
const
cls
=
this
.
_panelClassMap
[
type
];
const
panel
:
Panel
=
new
cls
(
data
);
const
panel
:
Panel
=
new
cls
(
data
);
this
.
addMask
();
this
.
addMask
();
if
(
!
window
[
'development'
])
{
if
(
!
window
[
'development'
])
{
if
(
this
.
noLoadingList
.
indexOf
(
type
)
==
-
1
)
if
(
this
.
noLoadingList
.
indexOf
(
type
)
==
-
1
)
Loading
.
instace
.
show
();
Loading
.
instace
.
show
();
const
key
=
panel
.
skinKey
.
toLowerCase
();
const
key
=
panel
.
skinKey
.
toLowerCase
();
...
@@ -78,7 +82,7 @@ export default class PanelCtrl {
...
@@ -78,7 +82,7 @@ export default class PanelCtrl {
}
}
addMask
()
{
addMask
()
{
if
(
!
this
.
_mask
)
{
if
(
!
this
.
_mask
)
{
this
.
_mask
=
new
egret
.
Sprite
();
this
.
_mask
=
new
egret
.
Sprite
();
this
.
_mask
.
touchEnabled
=
true
;
this
.
_mask
.
touchEnabled
=
true
;
this
.
_mask
.
graphics
.
beginFill
(
0
,
.
7
);
this
.
_mask
.
graphics
.
beginFill
(
0
,
.
7
);
...
@@ -90,11 +94,11 @@ export default class PanelCtrl {
...
@@ -90,11 +94,11 @@ export default class PanelCtrl {
}
}
removeMask
(
rightNow
=
false
)
{
removeMask
(
rightNow
=
false
)
{
if
(
this
.
_mask
)
{
if
(
this
.
_mask
)
{
if
(
rightNow
)
{
if
(
rightNow
)
{
this
.
_parent
.
removeChild
(
this
.
_mask
);
this
.
_parent
.
removeChild
(
this
.
_mask
);
}
else
}
else
egret
.
Tween
.
get
(
this
.
_mask
).
to
({
alpha
:
0
},
300
,
egret
.
Ease
.
quartIn
).
call
(
egret
.
Tween
.
get
(
this
.
_mask
).
to
({
alpha
:
0
},
300
,
egret
.
Ease
.
quartIn
).
call
(
()
=>
this
.
_parent
.
removeChild
(
this
.
_mask
),
this
);
()
=>
this
.
_parent
.
removeChild
(
this
.
_mask
),
this
);
}
}
}
}
...
@@ -105,13 +109,13 @@ export default class PanelCtrl {
...
@@ -105,13 +109,13 @@ export default class PanelCtrl {
}
}
private
remove
(
panel
:
Panel
,
rightNow
=
true
)
{
private
remove
(
panel
:
Panel
,
rightNow
=
true
)
{
if
(
rightNow
)
{
if
(
rightNow
)
{
this
.
_parent
.
removeChild
(
panel
);
this
.
_parent
.
removeChild
(
panel
);
this
.
removeMask
(
rightNow
);
this
.
removeMask
(
rightNow
);
return
;
return
;
}
}
const
tw
=
egret
.
Tween
.
get
(
panel
);
const
tw
=
egret
.
Tween
.
get
(
panel
);
tw
.
to
({
y
:
panel
.
stage
.
stageHeight
},
300
,
egret
.
Ease
.
quartIn
)
tw
.
to
({
y
:
panel
.
stage
.
stageHeight
},
300
,
egret
.
Ease
.
quartIn
)
.
call
(()
=>
{
.
call
(()
=>
{
this
.
_parent
.
removeChild
(
panel
);
this
.
_parent
.
removeChild
(
panel
);
this
.
removeMask
();
this
.
removeMask
();
...
@@ -122,11 +126,12 @@ export default class PanelCtrl {
...
@@ -122,11 +126,12 @@ export default class PanelCtrl {
const
panel
=
e
.
target
as
Panel
;
const
panel
=
e
.
target
as
Panel
;
panel
.
removeEventListener
(
'onDestroy'
,
this
.
onPanelHide
,
this
);
panel
.
removeEventListener
(
'onDestroy'
,
this
.
onPanelHide
,
this
);
this
.
remove
(
panel
);
this
.
remove
(
panel
);
this
.
_current
=
null
;
this
.
_current
=
null
;
this
.
checkPanels
();
this
.
checkPanels
();
}
}
private
_panelClassMap
:
any
;
private
_panelClassMap
:
any
;
registerPanel
(
name
,
config
)
{
registerPanel
(
name
,
config
)
{
this
.
_panelClassMap
=
this
.
_panelClassMap
||
{};
this
.
_panelClassMap
=
this
.
_panelClassMap
||
{};
this
.
_panelClassMap
[
name
]
=
config
.
cls
;
this
.
_panelClassMap
[
name
]
=
config
.
cls
;
...
@@ -136,7 +141,7 @@ export default class PanelCtrl {
...
@@ -136,7 +141,7 @@ export default class PanelCtrl {
_current
:
Panel
;
_current
:
Panel
;
closeCurrent
(
rightNow
=
false
)
{
closeCurrent
(
rightNow
=
false
)
{
if
(
this
.
_current
)
{
if
(
this
.
_current
)
{
this
.
remove
(
this
.
_current
,
rightNow
);
this
.
remove
(
this
.
_current
,
rightNow
);
this
.
_current
=
null
;
this
.
_current
=
null
;
}
}
...
...
egret/resource/TextureMerger/sign.tmproject
View file @
f2ac242d
{"options":{"layoutMath":"2","sizeMode":"2n","useExtension":1,"layoutGap":1,"extend":0},"projectName":"sign","version":5,"files":["../assets/sign/signitem.png","../assets/sign/signicon6.png","../assets/sign/signicon5.png","../assets/sign/signicon4.png","../assets/sign/signicon3.png","../assets/sign/signicon2.png","../assets/sign/signicon_blood.png","../assets/sign/signbtn4.png","../assets/sign/signbtn3.png","../assets/sign/signbtn2.png","../assets/sign/signbtn1.png","../assets/sign/signbg.png","../assets/sign/sign_quan88.png","../assets/sign/sign_quan8.png","../assets/sign/sign_quan58.png","../assets/sign/sign_quan38.png","../assets/sign/sign_quan28.png","../assets/sign/sign_quan16.png","../assets/sign/sign_quan15.png","../assets/sign/sign_quan12.png","../assets/sign/sign_line2.png","../assets/sign/sign_line.png","../assets/sign/sign_light.png","../assets/sign/sign_icon1.png","../assets/sign/sign_quan10.png","../assets/sign/sign_quan23.png","../assets/sign/sign_quan36.png"]}
{"options":{"layoutMath":"2","sizeMode":"2n","useExtension":1,"layoutGap":1,"extend":0},"projectName":"sign","version":5,"files":["../assets/sign/signitem.png","../assets/sign/signicon6.png","../assets/sign/signicon5.png","../assets/sign/signicon4.png","../assets/sign/signicon3.png","../assets/sign/signicon2.png","../assets/sign/signicon_blood.png","../assets/sign/signbtn4.png","../assets/sign/signbtn3.png","../assets/sign/signbtn2.png","../assets/sign/signbtn1.png","../assets/sign/signbg.png","../assets/sign/sign_quan88.png","../assets/sign/sign_quan8.png","../assets/sign/sign_quan58.png","../assets/sign/sign_quan38.png","../assets/sign/sign_quan28.png","../assets/sign/sign_quan16.png","../assets/sign/sign_quan15.png","../assets/sign/sign_quan12.png","../assets/sign/sign_line2.png","../assets/sign/sign_line.png","../assets/sign/sign_light.png","../assets/sign/sign_icon1.png","../assets/sign/sign_quan10.png","../assets/sign/sign_quan23.png","../assets/sign/sign_quan36.png","../assets/sign/sign_quan25.png","../assets/sign/sign_quan35.png"]}
\ No newline at end of file
\ No newline at end of file
egret/resource/assets/sign/sign_quan25.png
0 → 100644
View file @
f2ac242d
7.64 KB
egret/resource/assets/sign/sign_quan35.png
0 → 100644
View file @
f2ac242d
7.71 KB
egret/resource/default.res.json
View file @
f2ac242d
...
@@ -73,7 +73,7 @@
...
@@ -73,7 +73,7 @@
"name"
:
"exchange"
"name"
:
"exchange"
},
},
{
{
"keys"
:
"signitem_png,signicon6_png,signicon5_png,signicon4_png,signicon3_png,signicon2_png,signicon_blood_png,signbtn4_png,signbtn3_png,signbtn2_png,signbtn1_png,signbg_png,sign_quan88_png,sign_quan8_png,sign_quan58_png,sign_quan38_png,sign_quan28_png,sign_quan16_png,sign_quan15_png,sign_quan12_png,sign_line2_png,sign_line_png,sign_light_png,sign_icon1_png,sign_quan10_png,sign_quan23_png,sign_quan36_png"
,
"keys"
:
"signitem_png,signicon6_png,signicon5_png,signicon4_png,signicon3_png,signicon2_png,signicon_blood_png,signbtn4_png,signbtn3_png,signbtn2_png,signbtn1_png,signbg_png,sign_quan88_png,sign_quan8_png,sign_quan58_png,sign_quan38_png,sign_quan28_png,sign_quan16_png,sign_quan15_png,sign_quan12_png,sign_line2_png,sign_line_png,sign_light_png,sign_icon1_png,sign_quan10_png,sign_quan23_png,sign_quan36_png
,sign_quan25_png,sign_quan35_png
"
,
"name"
:
"sign"
"name"
:
"sign"
},
},
{
{
...
@@ -3675,6 +3675,16 @@
...
@@ -3675,6 +3675,16 @@
"url"
:
"assets/TaskCenterPanel/TaskCenter_btn.png"
,
"url"
:
"assets/TaskCenterPanel/TaskCenter_btn.png"
,
"type"
:
"image"
,
"type"
:
"image"
,
"name"
:
"TaskCenter_btn_png"
"name"
:
"TaskCenter_btn_png"
},
{
"url"
:
"assets/sign/sign_quan25.png"
,
"type"
:
"image"
,
"name"
:
"sign_quan25_png"
},
{
"url"
:
"assets/sign/sign_quan35.png"
,
"type"
:
"image"
,
"name"
:
"sign_quan35_png"
}
}
]
]
}
}
\ No newline at end of file
egret/resource/skins/SignItemSkin.exml
View file @
f2ac242d
...
@@ -24,6 +24,8 @@
...
@@ -24,6 +24,8 @@
<e:Image
id=
"quan28"
x=
"95"
y=
"56"
source=
"sign_quan28_png"
visible=
"false"
/>
<e:Image
id=
"quan28"
x=
"95"
y=
"56"
source=
"sign_quan28_png"
visible=
"false"
/>
<e:Image
id=
"quan8"
x=
"95"
y=
"56"
source=
"sign_quan8_png"
visible=
"false"
/>
<e:Image
id=
"quan8"
x=
"95"
y=
"56"
source=
"sign_quan8_png"
visible=
"false"
/>
<e:Image
id=
"quan88"
x=
"95"
y=
"56"
source=
"sign_quan88_png"
visible=
"false"
/>
<e:Image
id=
"quan88"
x=
"95"
y=
"56"
source=
"sign_quan88_png"
visible=
"false"
/>
<e:Image
id=
"quan35"
x=
"95"
y=
"56"
source=
"sign_quan35_png"
visible=
"false"
/>
<e:Image
id=
"quan25"
x=
"95"
y=
"56"
source=
"sign_quan25_png"
visible=
"false"
/>
<e:Button
id=
"btn1"
label=
""
x=
"364"
y=
"65"
>
<e:Button
id=
"btn1"
label=
""
x=
"364"
y=
"65"
>
<e:skinName>
<e:skinName>
<e:Skin
states=
"up,down,disabled"
>
<e:Skin
states=
"up,down,disabled"
>
...
...
egret/resource/skins/TaskCenterNoPrizeSkin.exml
View file @
f2ac242d
...
@@ -2,8 +2,8 @@
...
@@ -2,8 +2,8 @@
<e:Skin
class=
"SignPrizeSkin"
width=
"750"
height=
"1206"
xmlns:e=
"http://ns.egret.com/eui"
xmlns:w=
"http://ns.egret.com/wing"
>
<e:Skin
class=
"SignPrizeSkin"
width=
"750"
height=
"1206"
xmlns:e=
"http://ns.egret.com/eui"
xmlns:w=
"http://ns.egret.com/wing"
>
<w:Config
id=
"16d5c2563cb"
/>
<w:Config
id=
"16d5c2563cb"
/>
<e:Component
y=
"867.5"
skinName=
"ADSmallSkin"
x=
"84"
visible=
"false"
/>
<e:Component
y=
"867.5"
skinName=
"ADSmallSkin"
x=
"84"
visible=
"false"
/>
<e:Image
y=
"101.5"
horizontalCenter=
"-0.5"
source=
"TaskCenterNoPrizebg_png
"
/>
<e:Image
y=
"101.5"
source=
"TaskCenterNoPrizebg_png"
horizontalCenter=
"0
"
/>
<e:Button
id=
"closeBtn"
label=
""
x=
"6
13.5"
y=
"125.5
"
>
<e:Button
id=
"closeBtn"
label=
""
x=
"6
31"
y=
"136
"
>
<e:skinName>
<e:skinName>
<e:Skin
states=
"up,down,disabled"
>
<e:Skin
states=
"up,down,disabled"
>
<e:Image
width=
"100%"
height=
"100%"
source=
"closeCommonBtn_png"
source.down=
"closeCommonBtn_png"
source.disabled=
"closeCommonBtn_png"
/>
<e:Image
width=
"100%"
height=
"100%"
source=
"closeCommonBtn_png"
source.down=
"closeCommonBtn_png"
source.disabled=
"closeCommonBtn_png"
/>
...
@@ -18,7 +18,7 @@
...
@@ -18,7 +18,7 @@
<e:Label
id=
"suningLabel"
text=
"继续完成任务,还可以获得更多奖励哦~"
y=
"20"
fontFamily=
"FZY3JW"
size=
"28"
horizontalCenter=
"0"
x=
"10"
textColor=
"0xfb6300"
/>
<e:Label
id=
"suningLabel"
text=
"继续完成任务,还可以获得更多奖励哦~"
y=
"20"
fontFamily=
"FZY3JW"
size=
"28"
horizontalCenter=
"0"
x=
"10"
textColor=
"0xfb6300"
/>
<e:Label
text=
"换个姿势,再来一次!"
y=
"-40"
textColor=
"0xF54500"
fontFamily=
"FZY3JW"
size=
"46"
horizontalCenter=
"0"
x=
"-30"
scaleX=
"1"
scaleY=
"1"
/>
<e:Label
text=
"换个姿势,再来一次!"
y=
"-40"
textColor=
"0xF54500"
fontFamily=
"FZY3JW"
size=
"46"
horizontalCenter=
"0"
x=
"-30"
scaleX=
"1"
scaleY=
"1"
/>
</e:Group>
</e:Group>
<e:Group
id=
"btn"
x=
"194.5"
y=
"728.5"
width=
"358"
height=
"113
"
>
<e:Group
id=
"btn"
y=
"728.5"
width=
"358"
height=
"113"
horizontalCenter=
"0
"
>
<e:Button
label=
""
y=
"0"
x=
"0"
>
<e:Button
label=
""
y=
"0"
x=
"0"
>
<e:skinName>
<e:skinName>
<e:Skin
states=
"up,down,disabled"
>
<e:Skin
states=
"up,down,disabled"
>
...
...
egret/src/panels/TaskCenter/TaskCenter.ts
View file @
f2ac242d
...
@@ -74,7 +74,9 @@ class TaskCenterItem extends eui.ItemRenderer {
...
@@ -74,7 +74,9 @@ class TaskCenterItem extends eui.ItemRenderer {
dataChanged
()
{
dataChanged
()
{
// console.log(this.data);
// console.log(this.data);
this
.
taskImg
.
source
=
this
.
data
.
icon
;
if
(
this
.
data
.
icon
)
{
this
.
taskImg
.
source
=
(((
this
.
data
.
icon
[
0
]
+
this
.
data
.
icon
[
1
])
==
'//'
)
?
'http:'
:
''
)
+
this
.
data
.
icon
;
}
this
.
title
.
text
=
this
.
data
.
taskTitle
;
this
.
title
.
text
=
this
.
data
.
taskTitle
;
this
.
remark
.
text
=
this
.
data
.
remark
;
this
.
remark
.
text
=
this
.
data
.
remark
;
this
.
setBtn
();
// 设置按钮
this
.
setBtn
();
// 设置按钮
...
@@ -100,7 +102,14 @@ class TaskCenterItem extends eui.ItemRenderer {
...
@@ -100,7 +102,14 @@ class TaskCenterItem extends eui.ItemRenderer {
// 领奖
// 领奖
this
.
btnGroup
.
touchEnabled
=
false
;
this
.
btnGroup
.
touchEnabled
=
false
;
this
.
btnGroup
.
touchChildren
=
false
;
this
.
btnGroup
.
touchChildren
=
false
;
try
{
if
(
window
[
'getRST'
])
window
[
'getRST'
]();
}
catch
(
error
)
{
console
.
warn
(
error
)
}
NetManager
.
ins
.
taskAward
((
success
,
res
)
=>
{
NetManager
.
ins
.
taskAward
((
success
,
res
)
=>
{
this
.
btnGroup
.
touchEnabled
=
true
;
this
.
btnGroup
.
touchChildren
=
true
;
if
(
!
success
)
{
if
(
!
success
)
{
PanelCtrl
.
instance
.
show
(
'taskCenterNoPrize'
,
{
prizeData
:
res
,
taskData
:
this
.
data
});
PanelCtrl
.
instance
.
show
(
'taskCenterNoPrize'
,
{
prizeData
:
res
,
taskData
:
this
.
data
});
return
;
return
;
...
@@ -120,7 +129,7 @@ class TaskCenterItem extends eui.ItemRenderer {
...
@@ -120,7 +129,7 @@ class TaskCenterItem extends eui.ItemRenderer {
this
.
btnGroup
.
addEventListener
(
egret
.
TouchEvent
.
TOUCH_TAP
,
()
=>
{
this
.
btnGroup
.
addEventListener
(
egret
.
TouchEvent
.
TOUCH_TAP
,
()
=>
{
NetManager
.
ins
.
clickLog
(
getlogItem
(
63
));
NetManager
.
ins
.
clickLog
(
getlogItem
(
63
));
// 跳转任务链接
// 跳转任务链接
window
.
open
(
this
.
data
.
appIncompletelink
)
;
window
.
location
.
href
=
this
.
data
.
appIncompletelink
;
},
this
);
},
this
);
}
else
{
// 已完成
}
else
{
// 已完成
this
.
btnImg
.
source
=
'TaskCenter_'
+
'done'
+
'Btn_png'
;
this
.
btnImg
.
source
=
'TaskCenter_'
+
'done'
+
'Btn_png'
;
...
...
egret/src/panels/TaskCenter/TaskCenterPrize.ts
View file @
f2ac242d
...
@@ -5,7 +5,7 @@ import { NetManager } from "../../../libs/tw/manager/NetManager";
...
@@ -5,7 +5,7 @@ import { NetManager } from "../../../libs/tw/manager/NetManager";
import
{
getlogItem
}
from
"../../Main"
;
import
{
getlogItem
}
from
"../../Main"
;
import
getHomeData
from
"../../getHomeData"
;
import
getHomeData
from
"../../getHomeData"
;
import
{
changeMapScene
}
from
"../../startScene/StartScene"
;
import
{
changeMapScene
}
from
"../../startScene/StartScene"
;
import
{
GDispatcher
}
from
"../../../libs/tc/util/GDispatcher
"
;
import
SceneCtrl
from
"../../../libs/new_wx/ctrls/sceneCtrl
"
;
export
default
class
TaskCenterPrize
extends
Panel
{
export
default
class
TaskCenterPrize
extends
Panel
{
public
closeBtn
:
eui
.
Button
;
public
closeBtn
:
eui
.
Button
;
...
@@ -22,6 +22,9 @@ export default class TaskCenterPrize extends Panel {
...
@@ -22,6 +22,9 @@ export default class TaskCenterPrize extends Panel {
start
(
data
)
{
start
(
data
)
{
super
.
start
();
super
.
start
();
NetManager
.
ins
.
hc_home
(()
=>
{
SceneCtrl
.
instance
.
updateScene
();
},
window
[
'collectRuleId'
]);
// console.log(data);
// console.log(data);
...
...
mock/happyclear/getTaskInfo.json
View file @
f2ac242d
...
@@ -2,19 +2,19 @@
...
@@ -2,19 +2,19 @@
"success"
:
true
,
"success"
:
true
,
"code"
:
"0000000000"
,
"code"
:
"0000000000"
,
"desc"
:
"OK"
,
"desc"
:
"OK"
,
"timestamp"
:
1575
292008257
,
"timestamp"
:
1575
374211419
,
"data"
:
[
"data"
:
[
{
{
"subActivityId"
:
"
1
"
,
"subActivityId"
:
"
SUB446971598063218688
"
,
"subActivityName"
:
"狮狮连萌下单"
,
"subActivityName"
:
"狮狮连萌下单"
,
"status"
:
"0"
,
"status"
:
"0"
,
"taskStatus"
:
"0"
,
"taskStatus"
:
"0"
,
"remark"
:
"下单任务"
,
"remark"
:
"下单任务"
,
"taskTitle"
:
"狮狮连萌下单任务"
,
"taskTitle"
:
"狮狮连萌下单任务"
,
"taskViceTitle"
:
"狮狮连萌下单任务"
,
"taskViceTitle"
:
"狮狮连萌下单任务"
,
"icon"
:
"
http://uimgpre.cnsuning.com/uimg/
/scdc/exchange/152420922403871250.png"
,
"icon"
:
"
//uimgpre.cnsuning.com/uimg
/scdc/exchange/152420922403871250.png"
,
"limit"
:
"
5
"
,
"limit"
:
"
1
"
,
"done"
:
"
3
"
,
"done"
:
"
0
"
,
"appIncompleteText"
:
"去看看"
,
"appIncompleteText"
:
"去看看"
,
"appCompleteText"
:
"已完成"
,
"appCompleteText"
:
"已完成"
,
"appIncompletelink"
:
"http://cprexg.m.cnsuning.com/snWhale.html#/fight"
,
"appIncompletelink"
:
"http://cprexg.m.cnsuning.com/snWhale.html#/fight"
,
...
@@ -29,25 +29,25 @@
...
@@ -29,25 +29,25 @@
"incompleteLink"
:
null
,
"incompleteLink"
:
null
,
"completeLink"
:
null
,
"completeLink"
:
null
,
"terminalType"
:
"9"
,
"terminalType"
:
"9"
,
"taskName"
:
"狮狮连萌逛店铺"
,
"taskName"
:
null
,
"taskId"
:
"RW448429803289649152"
,
"taskId"
:
null
,
"count"
:
"2"
,
"count"
:
null
,
"tips"
:
"你好"
"tips"
:
"你好"
},
},
{
{
"subActivityId"
:
"
2
"
,
"subActivityId"
:
"
SUB446970931785445376
"
,
"subActivityName"
:
"狮狮连萌逛店铺"
,
"subActivityName"
:
"狮狮连萌逛店铺"
,
"status"
:
"
0
"
,
"status"
:
"
1
"
,
"taskStatus"
:
"99"
,
"taskStatus"
:
"99"
,
"remark"
:
"逛店铺呀"
,
"remark"
:
"逛店铺呀"
,
"taskTitle"
:
"狮狮连萌逛店铺"
,
"taskTitle"
:
"狮狮连萌逛店铺"
,
"taskViceTitle"
:
"200金币"
,
"taskViceTitle"
:
"200金币"
,
"icon"
:
"
http:
//uimgxgpre.cnsuning.com/uimg//scdc/exchange/157086878298813552.png"
,
"icon"
:
"//uimgxgpre.cnsuning.com/uimg//scdc/exchange/157086878298813552.png"
,
"limit"
:
"3"
,
"limit"
:
"3"
,
"done"
:
"
0
"
,
"done"
:
"
3
"
,
"appIncompleteText"
:
"去看看"
,
"appIncompleteText"
:
"去看看"
,
"appCompleteText"
:
"已完成"
,
"appCompleteText"
:
"已完成"
,
"appIncompletelink"
:
"
http://shopxgmpre.cnsuning.com/0070060496.html?scene=activityJr&activityCode=SL446689024459878400&taskCode=SUB446970931785445376&detailCode=0070060496&sourceFrom=ebuySngame
"
,
"appIncompletelink"
:
""
,
"appCompletelink"
:
"//m.suning.com"
,
"appCompletelink"
:
"//m.suning.com"
,
"pcIncompleteText"
:
null
,
"pcIncompleteText"
:
null
,
"pcCompleteText"
:
"已完成"
,
"pcCompleteText"
:
"已完成"
,
...
@@ -59,20 +59,20 @@
...
@@ -59,20 +59,20 @@
"incompleteLink"
:
"//uimgxgpre.cnsuning.com/uimg//scdc/exchange/157438697439978713.png"
,
"incompleteLink"
:
"//uimgxgpre.cnsuning.com/uimg//scdc/exchange/157438697439978713.png"
,
"completeLink"
:
"//uimgxgpre.cnsuning.com/uimg//scdc/exchange/157438697442128421.png"
,
"completeLink"
:
"//uimgxgpre.cnsuning.com/uimg//scdc/exchange/157438697442128421.png"
,
"terminalType"
:
"9"
,
"terminalType"
:
"9"
,
"taskName"
:
"狮狮连萌
浏览商品
"
,
"taskName"
:
"狮狮连萌
逛店铺
"
,
"taskId"
:
"RW4484
312610200043
52"
,
"taskId"
:
"RW4484
298032896491
52"
,
"count"
:
"
1
"
,
"count"
:
"
3
"
,
"tips"
:
"你好02"
"tips"
:
"你好02"
},
},
{
{
"subActivityId"
:
"
3
"
,
"subActivityId"
:
"
SUB446971290222411776
"
,
"subActivityName"
:
"狮狮连萌浏览商品"
,
"subActivityName"
:
"狮狮连萌浏览商品"
,
"status"
:
"0"
,
"status"
:
"0"
,
"taskStatus"
:
"99"
,
"taskStatus"
:
"99"
,
"remark"
:
"浏览商品聚合页"
,
"remark"
:
"浏览商品聚合页"
,
"taskTitle"
:
"狮狮连萌浏览商品"
,
"taskTitle"
:
"狮狮连萌浏览商品"
,
"taskViceTitle"
:
"200金币"
,
"taskViceTitle"
:
"200金币"
,
"icon"
:
"
http://uimgxgpre.cnsuning.com/uimg/
/scdc/exchange/157086878298813552.png"
,
"icon"
:
"
//uimgxgpre.cnsuning.com/uimg
/scdc/exchange/157086878298813552.png"
,
"limit"
:
"1"
,
"limit"
:
"1"
,
"done"
:
"0"
,
"done"
:
"0"
,
"appIncompleteText"
:
"去看看"
,
"appIncompleteText"
:
"去看看"
,
...
@@ -92,22 +92,22 @@
...
@@ -92,22 +92,22 @@
"taskName"
:
null
,
"taskName"
:
null
,
"taskId"
:
null
,
"taskId"
:
null
,
"count"
:
null
,
"count"
:
null
,
"tips"
:
"你好0
2
"
"tips"
:
"你好0
4
"
},
},
{
{
"subActivityId"
:
"
4
"
,
"subActivityId"
:
"
SUB446689681678090240
"
,
"subActivityName"
:
"狮狮连萌逛会场"
,
"subActivityName"
:
"狮狮连萌逛会场"
,
"status"
:
"
0
"
,
"status"
:
"
1
"
,
"taskStatus"
:
"99"
,
"taskStatus"
:
"99"
,
"remark"
:
"狮狮连萌浏览啦"
,
"remark"
:
"狮狮连萌浏览啦"
,
"taskTitle"
:
"狮狮连萌逛会场任务"
,
"taskTitle"
:
"狮狮连萌逛会场任务"
,
"taskViceTitle"
:
null
,
"taskViceTitle"
:
null
,
"icon"
:
"http://uimgpre.cnsuning.com/uimg//scdc/exchange/152420922403871250.png"
,
"icon"
:
null
,
"limit"
:
"8"
,
"limit"
:
"8"
,
"done"
:
"
0
"
,
"done"
:
"
8
"
,
"appIncompleteText"
:
"去看看"
,
"appIncompleteText"
:
"去看看"
,
"appCompleteText"
:
null
,
"appCompleteText"
:
null
,
"appIncompletelink"
:
"
http://cuxiaoprexg.m.cnsuning.com/scms/cx521.html?activityId=SL446689024459878400&subactivityId=SUB446689681678090240&businessid=cx521
"
,
"appIncompletelink"
:
""
,
"appCompletelink"
:
null
,
"appCompletelink"
:
null
,
"pcIncompleteText"
:
null
,
"pcIncompleteText"
:
null
,
"pcCompleteText"
:
null
,
"pcCompleteText"
:
null
,
...
@@ -121,8 +121,8 @@
...
@@ -121,8 +121,8 @@
"terminalType"
:
"9"
,
"terminalType"
:
"9"
,
"taskName"
:
"狮狮连萌逛会场任务"
,
"taskName"
:
"狮狮连萌逛会场任务"
,
"taskId"
:
"RW446695731227987968"
,
"taskId"
:
"RW446695731227987968"
,
"count"
:
"
1
"
,
"count"
:
"
2
"
,
"tips"
:
"你好0
4
"
"tips"
:
"你好0
3
"
}
}
]
]
}
}
\ No newline at end of file
mock/happyclear/taskAward.json
View file @
f2ac242d
{
{
"success"
:
tru
e
,
"success"
:
fals
e
,
"code"
:
"600064"
,
"code"
:
"600064"
,
"desc"
:
"OK"
,
"desc"
:
"OK"
,
"timestamp"
:
1572958024679
,
"timestamp"
:
1572958024679
,
...
...
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