Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
taobaominiDemo
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
taobaominiDemo
Commits
2c6bbebc
Commit
2c6bbebc
authored
Jul 01, 2020
by
lujinlei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
-a
parent
c83e8a59
Changes
3
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
50 additions
and
33 deletions
+50
-33
index$.worker.js
.tea/entryFiles-production/index$.worker.js
+1
-28
index.js
client/pages/index/index.js
+14
-0
output.js
client/pages/index/output.js
+35
-5
No files found.
.tea/entryFiles-production/index$.worker.js
View file @
2c6bbebc
This diff is collapsed.
Click to expand it.
client/pages/index/index.js
View file @
2c6bbebc
...
...
@@ -168,6 +168,16 @@ Page({
this
.
postMessage
(
'mine.favorShop'
,
{
success
:
true
})
}
},
async
isFavorShop
(){
const
isTmpFollow
=
await
checkShopFavoredStatus
(
app
.
sellerId
).
catch
(()
=>
{})
console
.
warn
(
'查询是否已关注过店铺'
,
isTmpFollow
);
if
(
isTmpFollow
){
this
.
postMessage
(
'isFavorShop'
,
{
success
:
true
})
}
else
{
this
.
postMessage
(
'isFavorShop'
,
{
success
:
false
})
}
},
//和main通信的方法,接收main的信息
onMessage
(
e
)
{
try
{
...
...
@@ -188,6 +198,10 @@ Page({
//关注店铺的操作
else
if
(
netName
==
"mine.favorShop"
)
{
this
.
doFavorShop
()
}
//关注店铺的操作
else
if
(
netName
==
"mine.isFavorShop"
)
{
this
.
isFavorShop
();
}
//前端接口
else
if
(
netName
.
indexOf
(
"mine"
)
==
0
)
{
...
...
client/pages/index/output.js
View file @
2c6bbebc
...
...
@@ -4458,7 +4458,7 @@ exports.ResJson = {
}
}
],
"path"
:
"https://yun.duiba.com.cn/db_games/activity/kickball-feile/15935
88569
/resource/"
"path"
:
"https://yun.duiba.com.cn/db_games/activity/kickball-feile/15935
91887
/resource/"
};
...
...
@@ -4521,6 +4521,7 @@ var TbNetName;
TbNetName
[
"doAdopt"
]
=
"squirrelsAdopt2c.doAdopt"
;
TbNetName
[
"authorize"
]
=
"mine.authorize"
;
TbNetName
[
"favorShop"
]
=
"mine.favorShop"
;
TbNetName
[
"isFavorShop"
]
=
"mine.isFavorShop"
;
TbNetName
[
"getUserAddress"
]
=
"mine.getUserAddress"
;
TbNetName
[
"getAppData"
]
=
"mine.getAppData"
;
TbNetName
[
"navigateToOutside"
]
=
"mine.navigateToOutside"
;
...
...
@@ -9319,9 +9320,9 @@ var TaskPanel = (function (_super) {
Main_1
.
GDispatcher
.
removeEventListener
(
'onShow'
,
this
.
followBack
,
this
);
this
.
updateData
();
};
TaskPanel
.
prototype
.
favorShopBack
=
function
(
succes
s
)
{
TaskPanel
.
prototype
.
favorShopBack
=
function
(
re
s
)
{
Main_1
.
GDispatcher
.
removeEventListener
(
TaoBaoNet_1
.
TbNetName
.
favorShop
,
this
.
favorShopBack
,
this
);
if
(
success
)
{
if
(
res
.
data
.
success
)
{
sendLog_1
.
default
(
LogType_1
.
default
.
favorShop
);
this
.
clickComplete
(
TASK_TYPE_1
.
TASK_TYPE
.
FOLLOW
);
}
...
...
@@ -9362,8 +9363,8 @@ var TaskPanel = (function (_super) {
TaoBaoNet_1
.
sendTbNet
(
TaoBaoNet_1
.
TbNetName
.
navigateToOutside
,
{
url
:
taskData
.
value
});
}
if
(
taskData
.
taskType
==
TASK_TYPE_1
.
TASK_TYPE
.
FOLLOW
)
{
Main_1
.
GDispatcher
.
addEventListener
(
TaoBaoNet_1
.
TbNetName
.
favorShop
,
tmpThis
.
favorShopBack
,
tmpThis
);
TaoBaoNet_1
.
sendTbNet
(
TaoBaoNet_1
.
TbNetName
.
f
avorShop
);
Main_1
.
GDispatcher
.
addEventListener
(
'isFavorShop'
,
tmpThis
.
isFavorShop
,
tmpThis
);
TaoBaoNet_1
.
sendTbNet
(
TaoBaoNet_1
.
TbNetName
.
isF
avorShop
);
}
if
(
!
(
taskData
.
taskType
==
TASK_TYPE_1
.
TASK_TYPE
.
INVITE
))
return
[
3
,
5
];
sendLog_1
.
default
(
LogType_1
.
default
.
clickInvitation
);
...
...
@@ -9380,6 +9381,16 @@ var TaskPanel = (function (_super) {
});
});
};
TaskPanel
.
prototype
.
isFavorShop
=
function
(
res
)
{
console
.
log
(
'是否已关注店铺事件返回'
,
res
.
data
.
success
);
if
(
res
.
data
.
success
)
{
ctrls_1
.
showToast
(
'已关注过该店铺'
);
}
else
{
Main_1
.
GDispatcher
.
addEventListener
(
TaoBaoNet_1
.
TbNetName
.
favorShop
,
this
.
favorShopBack
,
this
);
TaoBaoNet_1
.
sendTbNet
(
TaoBaoNet_1
.
TbNetName
.
favorShop
);
}
};
TaskPanel
.
prototype
.
updateData
=
function
()
{
return
__awaiter
(
this
,
void
0
,
void
0
,
function
()
{
var
_a
,
success
,
code
,
data
,
message
,
index
,
tmpTask
,
index_1
,
tmpTaskData
;
...
...
@@ -10555,6 +10566,8 @@ var Scene_1 = __webpack_require__(/*! ../../module/views/Scene */ "./module/view
var
Tools_1
=
__webpack_require__
(
/*! ../Tools */
"./src/Tools.ts"
);
var
layers_1
=
__webpack_require__
(
/*! ../../module/views/layers */
"./module/views/layers.ts"
);
var
RES_1
=
__webpack_require__
(
/*! ../../module/RES */
"./module/RES.ts"
);
var
ctrls_1
=
__webpack_require__
(
/*! ../../module/ctrls */
"./module/ctrls/index.ts"
);
var
StartScene_1
=
__webpack_require__
(
/*! ./StartScene */
"./src/scenes/StartScene.ts"
);
var
doHelp_1
=
__webpack_require__
(
/*! ../ctrls/doHelp */
"./src/ctrls/doHelp.ts"
);
var
TaoBaoNet_1
=
__webpack_require__
(
/*! ../TaoBaoNet */
"./src/TaoBaoNet.ts"
);
var
Main_1
=
__webpack_require__
(
/*! ../Main */
"./src/Main.ts"
);
...
...
@@ -10602,6 +10615,7 @@ var AssistScene = (function (_super) {
case
1
:
_a
.
sent
();
console
.
log
(
'跳转活动界面'
);
ctrls_1
.
changeScene
(
StartScene_1
.
StartScene
);
return
[
2
];
}
});
...
...
@@ -10614,6 +10628,12 @@ var AssistScene = (function (_super) {
return
__generator
(
this
,
function
(
_b
)
{
switch
(
_b
.
label
)
{
case
0
:
if
(
global_1
.
getBeforeStartTime
())
{
return
[
2
,
toastCtrl_1
.
showToast
(
'活动未开始'
)];
}
if
(
global_1
.
getAfterEndTime
())
{
return
[
2
,
toastCtrl_1
.
showToast
(
'活动已结束'
)];
}
sendLog_1
.
default
(
LogType_1
.
default
.
clickAssistBtn
);
return
[
4
,
doRecord_1
.
default
(
'help'
)];
case
1
:
...
...
@@ -10631,12 +10651,16 @@ var AssistScene = (function (_super) {
else
if
(
code
==
"930005"
)
{
console
.
log
(
'邀请码'
,
global_1
.
getShareCode
());
toastCtrl_1
.
showToast
(
'邀请码无效'
);
this
.
_goPlayBtn
.
visible
=
true
;
this
.
_assistBtn
.
visible
=
false
;
}
else
if
(
code
==
"930003"
)
{
this
.
assistFailShow
();
}
else
{
toastCtrl_1
.
showToast
(
message
);
this
.
_goPlayBtn
.
visible
=
true
;
this
.
_assistBtn
.
visible
=
false
;
}
}
return
[
2
];
...
...
@@ -10698,6 +10722,9 @@ var AssistScene = (function (_super) {
assistSuccess
.
anchorTexture
.
set
(
0.5
,
0.5
);
assistSuccess
.
position
.
set
(
750
/
2
,
800
);
this
.
addChild
(
assistSuccess
);
setTimeout
(
function
()
{
assistSuccess
.
visible
=
false
;
},
1500
);
};
AssistScene
.
prototype
.
assistFailShow
=
function
()
{
this
.
_goPlayBtn
.
visible
=
true
;
...
...
@@ -10706,6 +10733,9 @@ var AssistScene = (function (_super) {
assistFail
.
anchorTexture
.
set
(
0.5
,
0.5
);
assistFail
.
position
.
set
(
750
/
2
,
820
);
this
.
addChild
(
assistFail
);
setTimeout
(
function
()
{
assistFail
.
visible
=
false
;
},
1500
);
};
return
AssistScene
;
}(
Scene_1
.
Scene
));
...
...
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