Commit 43e610df authored by Edwise's avatar Edwise 🍷

Merge remote-tracking branch 'refs/remotes/origin/tianmaoxiaoyuan' into tianmaoxiaoyuan

parents b6c8708a 9587d85e
...@@ -72,7 +72,7 @@ Page({ ...@@ -72,7 +72,7 @@ Page({
const t3 = new Date(endTime).getMinutes() + ''; //获取分 const t3 = new Date(endTime).getMinutes() + ''; //获取分
const t4 = new Date(endTime).getSeconds() + ''; //获取秒 const t4 = new Date(endTime).getSeconds() + ''; //获取秒
console.log(endTime, new Date(endTime + 48 * 60 * 60 * 1000).toLocaleString(), 'endTime'); console.log(endTime, new Date(endTime + 48 * 60 * 60 * 1000).toLocaleString(), 'endTime');
console.log('endtime str',t1 + "" + t2.padStart(2, '0') + ":" + t3.padStart(2, '0') + ":" + t4.padStart(2, '0')) console.log('endtime str', t1 + "" + t2.padStart(2, '0') + ":" + t3.padStart(2, '0') + ":" + t4.padStart(2, '0'))
this.setData({ this.setData({
endTime: t1 + "" + t2.padStart(2, '0') + ":" + t3.padStart(2, '0') + ":" + t4.padStart(2, '0') endTime: t1 + "" + t2.padStart(2, '0') + ":" + t3.padStart(2, '0') + ":" + t4.padStart(2, '0')
}) })
...@@ -132,7 +132,7 @@ Page({ ...@@ -132,7 +132,7 @@ Page({
* 发奖 * 发奖
*/ */
async cloudTBIssue(params) { async cloudTBIssue(params) {
console.log('cloudTBIssue params',JSON.stringify(params)) console.log('cloudTBIssue params', JSON.stringify(params))
const { const {
cloud cloud
} = app; } = app;
...@@ -185,17 +185,17 @@ Page({ ...@@ -185,17 +185,17 @@ Page({
strategyCode, strategyCode,
code, code,
channel channel
}).then(()=>{ }).then(() => {
API.receivLaFeiPrize({id}).then((res)=>{ API.receivLaFeiPrize({ id }).then((res) => {
console.log('receivLaFeiPrize res',res) console.log('receivLaFeiPrize res', res)
this.getMyPrize() this.getMyPrize()
}) })
.catch((error)=>{ .catch((error) => {
console.log('receivLaFeiPrize error',error) console.log('receivLaFeiPrize error', error)
}) })
}) })
.catch(err=>{ .catch(err => {
API.receivLaFeiPrize({result:err}) API.receivLaFeiPrize({ result: err })
}) })
// const { activityId } = app; // const { activityId } = app;
// console.log(item, '领取权益') // console.log(item, '领取权益')
...@@ -218,25 +218,36 @@ Page({ ...@@ -218,25 +218,36 @@ Page({
}, },
// 领取实物前询问 // 领取实物前询问
async handleGetEntity(e) { async handleGetEntity(e) {
my.confirm({
title: '领取奖品',
content: '是否允许访问您的粘贴板',
confirmButtonText: '确认',
cancelButtonText: '取消',
success: (result) => {
if (result.confirm) {
const text = 'zzzxxx' const text = 'zzzxxx'
commonToast('请前去钉钉领取,钉钉号为:' + text + '。钉钉号已经复制成功。', 3000);
setClipboard({ setClipboard({
text: `${text}` text: `${text}`
}).then(() => {
commonToast(' ' + text + '。钉钉号已经复制成功。', 3000);
}).catch(err=>{
console.log('handleGetEntity error',err)
}) })
}
},
fail: (result) =>{ // my.confirm({
commonToast('访问剪贴板失败') // title: '领取奖品',
} // content: '是否允许访问您的粘贴板',
}); // confirmButtonText: '确认',
// cancelButtonText: '取消',
// success: (result) => {
// if (result.confirm) {
// const text = 'zzzxxx'
// setClipboard({
// text: `${text}`
// })
// commonToast('请前去钉钉领取,钉钉号为:' + text + '。钉钉号已经复制成功。', 3000);
// }
// },
// fail: (result) =>{
// commonToast('访问剪贴板失败')
// }
// });
// if (flag) { // if (flag) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment