mirror of
https://github.com/kuaifan/dootask.git
synced 2025-12-16 14:12:51 +00:00
no message
This commit is contained in:
parent
80507cab27
commit
182f061354
@ -3,8 +3,6 @@
|
|||||||
namespace App\Http\Controllers\Api;
|
namespace App\Http\Controllers\Api;
|
||||||
|
|
||||||
use App\Models\UserDevice;
|
use App\Models\UserDevice;
|
||||||
use App\Models\WebSocketDialog;
|
|
||||||
use App\Models\WebSocketDialogMsg;
|
|
||||||
use Request;
|
use Request;
|
||||||
use Session;
|
use Session;
|
||||||
use Response;
|
use Response;
|
||||||
|
|||||||
@ -577,6 +577,7 @@ export default {
|
|||||||
this.autoTheme()
|
this.autoTheme()
|
||||||
$A.updateTimezone()
|
$A.updateTimezone()
|
||||||
$A.IDBTest()
|
$A.IDBTest()
|
||||||
|
this.$store.dispatch("safeAreaInsets")
|
||||||
const nowYmd = $A.daytz().format('YYYY-MM-DD')
|
const nowYmd = $A.daytz().format('YYYY-MM-DD')
|
||||||
if (this.lastCheckUpgradeYmd != nowYmd) {
|
if (this.lastCheckUpgradeYmd != nowYmd) {
|
||||||
this.lastCheckUpgradeYmd = nowYmd
|
this.lastCheckUpgradeYmd = nowYmd
|
||||||
|
|||||||
11
resources/assets/js/app.js
vendored
11
resources/assets/js/app.js
vendored
@ -340,16 +340,7 @@ const $preload = async () => {
|
|||||||
}
|
}
|
||||||
const pageInfo = $A.eeuiAppGetPageInfo() || {};
|
const pageInfo = $A.eeuiAppGetPageInfo() || {};
|
||||||
store.state.isFirstPage = pageInfo.pageName === 'firstPage'
|
store.state.isFirstPage = pageInfo.pageName === 'firstPage'
|
||||||
if (store.state.isFirstPage) {
|
await store.dispatch("safeAreaInsets")
|
||||||
$A.eeuiAppGetSafeAreaInsets().then(data => {
|
|
||||||
const proportion = data.height / window.outerHeight
|
|
||||||
store.state.safeAreaSize = {
|
|
||||||
top: Math.round(data.top / proportion * 100) / 100,
|
|
||||||
bottom: Math.round(data.bottom / proportion * 100) / 100,
|
|
||||||
data
|
|
||||||
}
|
|
||||||
}).catch(console.warn)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
await store.dispatch("preload");
|
await store.dispatch("preload");
|
||||||
|
|||||||
25
resources/assets/js/store/actions.js
vendored
25
resources/assets/js/store/actions.js
vendored
@ -156,6 +156,31 @@ export default {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取安全区域
|
||||||
|
* @param state
|
||||||
|
* @returns {Promise<unknown>}
|
||||||
|
*/
|
||||||
|
safeAreaInsets({state}) {
|
||||||
|
return new Promise(resolve => {
|
||||||
|
if (!state.isFirstPage) {
|
||||||
|
return resolve(null)
|
||||||
|
}
|
||||||
|
$A.eeuiAppGetSafeAreaInsets().then(data => {
|
||||||
|
const proportion = data.height / window.outerHeight
|
||||||
|
state.safeAreaSize = {
|
||||||
|
top: Math.round(data.top / proportion * 100) / 100,
|
||||||
|
bottom: Math.round(data.bottom / proportion * 100) / 100,
|
||||||
|
data
|
||||||
|
}
|
||||||
|
resolve(state.safeAreaSize)
|
||||||
|
}).catch(e => {
|
||||||
|
console.warn(e)
|
||||||
|
resolve(null)
|
||||||
|
})
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 访问接口
|
* 访问接口
|
||||||
* @param state
|
* @param state
|
||||||
|
|||||||
@ -1 +1 @@
|
|||||||
Subproject commit 6f75cd3e8687996031a8497cd6af1f210363827e
|
Subproject commit 51b61159deaff528c4def5bbdc5d0153f7f508a4
|
||||||
Loading…
x
Reference in New Issue
Block a user