Merge branch 'develop' of http://123.57.20.168:4000/admin/ys-app into develop
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"id" : "H5E705637",
|
"id" : "H5E705637",
|
||||||
"name" : "718友晟",
|
"name" : "718友晟",
|
||||||
"appid" : "__UNI__4C459F4",
|
"appid" : "__UNI__0B682E1",
|
||||||
"description" : "",
|
"description" : "",
|
||||||
"versionName" : "1.0.2",
|
"versionName" : "1.0.2",
|
||||||
"versionCode" : "100",
|
"versionCode" : "100",
|
||||||
@@ -62,7 +62,8 @@
|
|||||||
"<uses-permission android:name=\"android.permission.RESTART_PACKAGES\" />",
|
"<uses-permission android:name=\"android.permission.RESTART_PACKAGES\" />",
|
||||||
"<uses-permission android:name=\"android.permission.REQUEST_INSTALL_PACKAGES\" />",
|
"<uses-permission android:name=\"android.permission.REQUEST_INSTALL_PACKAGES\" />",
|
||||||
"<uses-permission android:name=\"android.permission.NFC\"/>",
|
"<uses-permission android:name=\"android.permission.NFC\"/>",
|
||||||
"<uses-feature android:name=\"android.hardware.nfc\" android:required=\"true\"/>"
|
"<uses-feature android:name=\"android.hardware.nfc\" android:required=\"true\"/>",
|
||||||
|
"<uses-permission android:name=\"android.permission.POST_NOTIFICATIONS\"/>"
|
||||||
],
|
],
|
||||||
"abiFilters" : [ "armeabi-v7a", "arm64-v8a" ],
|
"abiFilters" : [ "armeabi-v7a", "arm64-v8a" ],
|
||||||
"minSdkVersion" : 23,
|
"minSdkVersion" : 23,
|
||||||
@@ -86,15 +87,22 @@
|
|||||||
"unipush" : {
|
"unipush" : {
|
||||||
"version" : "2",
|
"version" : "2",
|
||||||
"offline" : true,
|
"offline" : true,
|
||||||
"icons" : {
|
"icons" : {
|
||||||
"small" : {
|
"push" : {
|
||||||
"ldpi" : "/static/images/icon.png",
|
"ldpi" : "/static/images/icon.png",
|
||||||
"mdpi" : "/static/images/icon.png",
|
"mdpi" : "/static/images/icon.png",
|
||||||
"hdpi" : "/static/images/icon.png",
|
"hdpi" : "/static/images/icon.png",
|
||||||
"xhdpi" : "/static/images/icon.png",
|
"xhdpi" : "/static/images/icon.png",
|
||||||
"xxhdpi" : "/static/images/icon.png"
|
"xxhdpi" : "/static/images/icon.png"
|
||||||
}
|
},
|
||||||
}
|
"small" : {
|
||||||
|
"ldpi" : "/static/images/icon_small.png",
|
||||||
|
"mdpi" : "/static/images/icon_small.png",
|
||||||
|
"hdpi" : "/static/images/icon_small.png",
|
||||||
|
"xhdpi" : "/static/images/icon_small.png",
|
||||||
|
"xxhdpi" : "/static/images/icon_small.png"
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -85,7 +85,7 @@ onShow(()=>{
|
|||||||
try {
|
try {
|
||||||
showLoading("加载中...")
|
showLoading("加载中...")
|
||||||
getList();
|
getList();
|
||||||
getTaskCount();
|
// getTaskCount();
|
||||||
hideLoading();
|
hideLoading();
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
hideLoading();
|
hideLoading();
|
||||||
@@ -164,7 +164,7 @@ const downOption = ref({
|
|||||||
const downCallback = async (mescroll) => {
|
const downCallback = async (mescroll) => {
|
||||||
try {
|
try {
|
||||||
setTimeout(async ()=>{
|
setTimeout(async ()=>{
|
||||||
getTaskCount();
|
// getTaskCount();
|
||||||
getList();
|
getList();
|
||||||
mescroll.resetUpScroll();
|
mescroll.resetUpScroll();
|
||||||
},500);
|
},500);
|
||||||
|
|||||||
@@ -75,6 +75,8 @@ export default {
|
|||||||
let ndef = new IntentFilter("android.nfc.action.TECH_DISCOVERED");
|
let ndef = new IntentFilter("android.nfc.action.TECH_DISCOVERED");
|
||||||
ndef.addDataType("*/*");
|
ndef.addDataType("*/*");
|
||||||
let intentFiltersArray = [ndef];
|
let intentFiltersArray = [ndef];
|
||||||
|
|
||||||
|
console.log('newintent running==>',intentFiltersArray);
|
||||||
|
|
||||||
plus.globalEvent.addEventListener('newintent',function() {
|
plus.globalEvent.addEventListener('newintent',function() {
|
||||||
console.log('newintent running');
|
console.log('newintent running');
|
||||||
|
|||||||
@@ -202,7 +202,7 @@ const initLoad =()=>{
|
|||||||
getSalesTask();
|
getSalesTask();
|
||||||
getCommonServices();
|
getCommonServices();
|
||||||
getNewsList();
|
getNewsList();
|
||||||
getTaskCount();
|
// getTaskCount();
|
||||||
hideLoading();
|
hideLoading();
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
hideLoading();
|
hideLoading();
|
||||||
|
|||||||
@@ -55,6 +55,9 @@ onLoad(async(opt) => {
|
|||||||
// uni.preloadPage({url: "/pages/home/home"});
|
// uni.preloadPage({url: "/pages/home/home"});
|
||||||
|
|
||||||
// #ifdef APP-PLUS
|
// #ifdef APP-PLUS
|
||||||
|
//手机通知授权
|
||||||
|
noticMsgTool();
|
||||||
|
|
||||||
// 查询版本接口
|
// 查询版本接口
|
||||||
await getOSVesion();
|
await getOSVesion();
|
||||||
|
|
||||||
@@ -91,9 +94,9 @@ onLoad(async(opt) => {
|
|||||||
// #endif
|
// #endif
|
||||||
|
|
||||||
// 内网才有minio参数
|
// 内网才有minio参数
|
||||||
if(networkEnv.value==1){
|
// if(networkEnv.value==1){
|
||||||
getMinioParam();
|
// getMinioParam();
|
||||||
}
|
// }
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -216,6 +219,78 @@ const handleClose=()=>{
|
|||||||
selectDeviceId()
|
selectDeviceId()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//通知授权
|
||||||
|
const noticMsgTool=()=>{
|
||||||
|
if (uni.getSystemInfoSync().platform == "ios") {
|
||||||
|
// iOS: 使用 iOS API 检查通知权限
|
||||||
|
plus.ios.import('UserNotifications');
|
||||||
|
var UNNotificationSettings = plus.ios.invoke('UNUserNotificationCenter', 'currentNotificationCenter');
|
||||||
|
plus.ios.invoke(UNNotificationSettings, 'getNotificationSettingsWithCompletionHandler', function(settings) {
|
||||||
|
var authorizationStatus = plus.ios.invoke(settings, 'authorizationStatus');
|
||||||
|
if (authorizationStatus !== 3) { // 3表示已授权
|
||||||
|
//苹果打开对应的通知栏
|
||||||
|
uni.showModal({
|
||||||
|
title: '通知权限开启提醒',
|
||||||
|
content: '您还没有开启通知权限,无法接受到消息通知,请前往设置!',
|
||||||
|
showCancel: false,
|
||||||
|
confirmText: '去设置',
|
||||||
|
success: function(res) {
|
||||||
|
if (res.confirm) {
|
||||||
|
var app = plus.ios.invoke('UIApplication', 'sharedApplication');
|
||||||
|
var setting = plus.ios.invoke('NSURL', 'URLWithString:','app-settings:');
|
||||||
|
plus.ios.invoke(app, 'openURL:', setting);
|
||||||
|
plus.ios.deleteObject(setting);
|
||||||
|
plus.ios.deleteObject(app);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
} else {
|
||||||
|
//android打开对应的通知栏
|
||||||
|
var main = plus.android.runtimeMainActivity();
|
||||||
|
var pkName = main.getPackageName();
|
||||||
|
var uid = main.getApplicationInfo().plusGetAttribute("uid");
|
||||||
|
var context = main.getApplicationContext();
|
||||||
|
var NotificationManager = plus.android.importClass('android.app.NotificationManager');
|
||||||
|
var notificationManager = context.getSystemService(context.NOTIFICATION_SERVICE);
|
||||||
|
var areNotificationsEnabled = notificationManager.areNotificationsEnabled();
|
||||||
|
|
||||||
|
if (!areNotificationsEnabled) {
|
||||||
|
// 提示用户开启通知权限
|
||||||
|
uni.showModal({
|
||||||
|
title: '通知权限开启提醒',
|
||||||
|
content: '您还没有开启通知权限,无法接受到消息通知,请前往设置!',
|
||||||
|
showCancel: false,
|
||||||
|
confirmText: '去设置',
|
||||||
|
success: function(res) {
|
||||||
|
if (res.confirm) {
|
||||||
|
var Intent = plus.android.importClass('android.content.Intent');
|
||||||
|
var Build = plus.android.importClass("android.os.Build");
|
||||||
|
//android 8.0引导
|
||||||
|
if (Build.VERSION.SDK_INT >= 26) {
|
||||||
|
var intent = new Intent('android.settings.APP_NOTIFICATION_SETTINGS');
|
||||||
|
intent.putExtra('android.provider.extra.APP_PACKAGE', pkName);
|
||||||
|
} else if (Build.VERSION.SDK_INT >= 21) { //android 5.0-7.0
|
||||||
|
var intent = new Intent('android.settings.APP_NOTIFICATION_SETTINGS');
|
||||||
|
intent.putExtra("app_package", pkName);
|
||||||
|
intent.putExtra("app_uid", uid);
|
||||||
|
} else { //(<21)其他--跳转到该应用管理的详情页
|
||||||
|
intent.setAction(Settings.ACTION_APPLICATION_DETAILS_SETTINGS);
|
||||||
|
var uri = Uri.fromParts("package", mainActivity.getPackageName(), null);
|
||||||
|
intent.setData(uri);
|
||||||
|
}
|
||||||
|
// 跳转到该应用的系统通知设置页
|
||||||
|
main.startActivity(intent);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
|
|||||||
@@ -260,7 +260,7 @@ const handleJump = (item)=>{
|
|||||||
}
|
}
|
||||||
.scroll-h{
|
.scroll-h{
|
||||||
/* #ifdef APP-PLUS */
|
/* #ifdef APP-PLUS */
|
||||||
height: calc(100vh - 120px);
|
height: calc(100vh - 150px);
|
||||||
/* #endif */
|
/* #endif */
|
||||||
/* #ifndef APP-PLUS */
|
/* #ifndef APP-PLUS */
|
||||||
height: calc(100vh - 160px);
|
height: calc(100vh - 160px);
|
||||||
|
|||||||
BIN
src/static/images/icon_small.png
Normal file
BIN
src/static/images/icon_small.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 16 KiB |
Reference in New Issue
Block a user