diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index c5fcc10b..55811bd6 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -67,8 +67,12 @@ variables:
# - flutter pub get
- export PATH="/opt/homebrew/bin:$PATH"
- eval "$(rbenv init -)"
- - bundle config mirror.https://rubygems.org https://gems.ruby-china.com
- - bundle install --gemfile android/Gemfile --quiet
+ - rbenv global 2.6.10 # 你实际用的 Ruby 版本
+ - ruby -v
+ - which ruby
+ - gem env
+ - bundle config mirror.https://rubygems.org https://mirrors.aliyun.com/rubygems/
+ - bundle install --gemfile android/Gemfile --path vendor/bundle_android --quiet
cache:
paths:
- app_new.version
@@ -80,11 +84,14 @@ variables:
- export FLUTTER_STORAGE_BASE_URL=https://storage.flutter-io.cn
- ls -li
- export NEXT_VERSION="$(cat app_new.version)"
-# - flutter pub get
- export PATH="/opt/homebrew/bin:$PATH"
- eval "$(rbenv init -)"
- - bundle config mirror.https://rubygems.org https://gems.ruby-china.com
- - bundle install --gemfile ios/Gemfile --quiet
+ - rbenv global 2.6.10 # 你实际用的 Ruby 版本
+ - ruby -v
+ - which ruby
+ - gem env
+ - bundle config mirror.https://rubygems.org https://mirrors.aliyun.com/rubygems/
+ - bundle install --gemfile ios/Gemfile --path vendor/bundle_ios --quiet
cache:
paths:
- app_new.version
diff --git a/android/app/build.gradle b/android/app/build.gradle
index 33672031..043bedcc 100755
--- a/android/app/build.gradle
+++ b/android/app/build.gradle
@@ -358,8 +358,14 @@ dependencies {
implementation 'com.umeng.umsdk:asms:1.8.5'
//
//
- implementation 'cn.jiguang.sdk.plugin:fcm:5.2.3'
- implementation 'com.google.firebase:firebase-messaging:23.0.5'
+// implementation 'cn.jiguang.sdk.plugin:fcm:5.2.3'
+// implementation 'com.google.firebase:firebase-messaging:23.0.5'
//
+ //FCM云消息与极光FCM插件
+ implementation 'com.google.firebase:firebase-messaging:23.2.1'
+ implementation 'cn.jiguang.sdk.plugin:fcm:5.2.2'
+
+
+
}
diff --git a/images/guide/1.png b/images/guide/1.png
new file mode 100644
index 00000000..66d037f7
Binary files /dev/null and b/images/guide/1.png differ
diff --git a/images/guide/2.png b/images/guide/2.png
new file mode 100644
index 00000000..78933d9f
Binary files /dev/null and b/images/guide/2.png differ
diff --git a/images/guide/3.png b/images/guide/3.png
new file mode 100644
index 00000000..d9e61aaf
Binary files /dev/null and b/images/guide/3.png differ
diff --git a/images/guide/4.png b/images/guide/4.png
new file mode 100644
index 00000000..e30e0064
Binary files /dev/null and b/images/guide/4.png differ
diff --git a/lib/appRouters.dart b/lib/appRouters.dart
index 0a06445a..495b54c7 100755
--- a/lib/appRouters.dart
+++ b/lib/appRouters.dart
@@ -60,6 +60,7 @@ import 'package:star_lock/mine/mineSet/transferSmartLock/transferSmartLockList/t
import 'package:star_lock/mine/valueAddedServices/advancedFeaturesWeb/advancedFeaturesWeb_page.dart';
import 'package:star_lock/mine/valueAddedServices/advancedFunctionRecord/advancedFunctionRecord_page.dart';
import 'package:star_lock/mine/valueAddedServices/valueAddedServicesRecord/value_added_services_record_page.dart';
+import 'package:star_lock/talk/starChart/views/guide/permission_guidance_page.dart';
import 'package:star_lock/talk/starChart/views/native/talk_view_native_decode_page.dart';
import 'package:star_lock/talk/starChart/views/talkView/talk_view_page.dart';
import 'package:star_lock/talk/starChart/webView/h264_web_view.dart';
@@ -518,6 +519,8 @@ abstract class Routers {
static const String h264WebView = '/h264WebView'; //星图对讲页面
static const String imageTransmissionView =
'/imageTransmissionView'; //星图对讲页面(图传)
+ static const String permissionGuidancePage =
+ '/permissionGuidancePage'; // 锁屏权限通知引导页面
}
abstract class AppRouters {
@@ -1194,6 +1197,10 @@ abstract class AppRouters {
GetPage(
name: Routers.imageTransmissionView,
page: () => ImageTransmissionPage()),
+
+ GetPage(
+ name: Routers.permissionGuidancePage,
+ page: () => PermissionGuidancePage()),
// 插件播放页面
// GetPage(name: Routers.h264WebView, page: () => H264WebView()), // webview播放页面
];
diff --git a/lib/main/lockDetail/fingerprint/addFingerprintSelectType/addFingerprintType_page.dart b/lib/main/lockDetail/fingerprint/addFingerprintSelectType/addFingerprintType_page.dart
index ce684a51..e8804ac8 100755
--- a/lib/main/lockDetail/fingerprint/addFingerprintSelectType/addFingerprintType_page.dart
+++ b/lib/main/lockDetail/fingerprint/addFingerprintSelectType/addFingerprintType_page.dart
@@ -128,6 +128,15 @@ class _AddFingerprintTypePageState extends State
// 限时顶部选择日期
Widget keyTimeLimitWidget() {
+ // 获取当前时间
+ DateTime now = DateTime.now();
+
+ // 获取各个部分
+ int year = now.year;
+ int month = now.month;
+ int day = now.day;
+ int hour = now.hour;
+ int minute = now.minute;
return Column(
children: [
Obx(() => CommonItem(
@@ -139,6 +148,13 @@ class _AddFingerprintTypePageState extends State
final PDuration selectDate = PDuration.parse(
DateTime.tryParse(state.timeLimitBeginTime.value));
Pickers.showDatePicker(context,
+ minDate: PDuration(
+ year: year,
+ month: month,
+ day: day,
+ hour: hour,
+ minute: minute,
+ ),
selectDate: selectDate,
mode: DateMode.YMDHM, onConfirm: (PDuration p) {
state.timeLimitBeginTime.value =
@@ -153,6 +169,13 @@ class _AddFingerprintTypePageState extends State
final PDuration selectDate = PDuration.parse(
DateTime.tryParse(state.timeLimitEndTime.value));
Pickers.showDatePicker(context,
+ minDate: PDuration(
+ year: year,
+ month: month,
+ day: day,
+ hour: hour,
+ minute: minute,
+ ),
selectDate: selectDate,
mode: DateMode.YMDHM, onConfirm: (PDuration p) {
state.timeLimitEndTime.value =
diff --git a/lib/talk/starChart/handle/impl/udp_talk_expect_handler.dart b/lib/talk/starChart/handle/impl/udp_talk_expect_handler.dart
index 792e7f2c..d500fd44 100644
--- a/lib/talk/starChart/handle/impl/udp_talk_expect_handler.dart
+++ b/lib/talk/starChart/handle/impl/udp_talk_expect_handler.dart
@@ -4,7 +4,9 @@ import 'dart:typed_data';
import 'package:flutter/services.dart';
import 'package:flutter_easyloading/flutter_easyloading.dart';
import 'package:get/get.dart';
+import 'package:star_lock/appRouters.dart';
import 'package:star_lock/app_settings/app_settings.dart';
+import 'package:star_lock/main/lockMian/entity/lockListInfo_entity.dart';
import 'package:star_lock/talk/starChart/constant/message_type_constant.dart';
import 'package:star_lock/talk/starChart/constant/talk_status.dart';
import 'package:star_lock/talk/starChart/entity/scp_message.dart';
@@ -16,6 +18,8 @@ import 'package:star_lock/talk/starChart/proto/talk_data.pb.dart';
import 'package:star_lock/talk/starChart/proto/talk_expect.pb.dart';
import 'package:star_lock/talk/starChart/views/talkView/talk_view_logic.dart';
import 'package:star_lock/talk/starChart/views/talkView/talk_view_state.dart';
+import 'package:star_lock/tools/commonDataManage.dart';
+import 'package:star_lock/tools/storage.dart';
import '../../star_chart_manage.dart';
@@ -32,10 +36,14 @@ class UdpTalkExpectHandler extends ScpMessageBaseHandle
}
@override
- void handleResp(ScpMessage scpMessage) {
+ void handleResp(ScpMessage scpMessage) async {
// 收到预期音视频数据回复
final TalkExpectResp talkExpectResp = scpMessage.Payload;
+
if (talkExpectResp != null) {
+ // 播放铃声
+ //test:使用自定义铃声
+ playRingtone();
// print('收到预期音视频数据回复,scpMessage:$scpMessage');
// 停止发送预期数据的定时器
startChartManage.stopTalkExpectMessageTimer();
@@ -45,7 +53,7 @@ class UdpTalkExpectHandler extends ScpMessageBaseHandle
startChartManage.rotateAngle = talkExpectResp.rotate;
startChartManage.videoWidth = talkExpectResp.width;
startChartManage.videoHeight = talkExpectResp.height;
- AppLog.log('视频画面需要旋转:${talkExpectResp.rotate},画面宽高:${talkExpectResp.width}-${talkExpectResp.height}');
+
// 收到预期数据的应答后,代表建立了连接,启动通话保持的监听
// 启动通话保持监听定时器(用来判断如果x秒内没有收到通话保持则执行的操作);
talkePingOverTimeTimerManager.start();
@@ -59,6 +67,50 @@ class UdpTalkExpectHandler extends ScpMessageBaseHandle
// 主动呼叫时需要启动ping
startChartManage.startTalkPingMessageTimer();
}
+ AppLog.log(
+ '视频画面需要旋转:${talkExpectResp.rotate},画面宽高:${talkExpectResp.width}-${talkExpectResp.height}');
+ // 获取锁支持项
+ final LockListInfoItemEntity currentKeyInfo =
+ CommonDataManage().currentKeyInfo;
+ // 0、wifi保活 1、wifi不保活图传 2、wifi不保活可视对讲
+ var isWifiLockType = currentKeyInfo.lockFeature?.wifiLockType == 1;
+
+ final LockListInfoGroupEntity? lockListInfoGroupEntity =
+ await Storage.getLockMainListData();
+ if (lockListInfoGroupEntity != null) {
+ lockListInfoGroupEntity!.groupList?.forEach((element) {
+ final lockList = element.lockList;
+ if (lockList != null && lockList.length != 0) {
+ for (var lockInfo in lockList) {
+ final peerId = lockInfo.network?.peerId;
+ if (peerId != null && peerId != '') {
+ if (peerId == scpMessage.FromPeerId) {
+ isWifiLockType = lockInfo.lockFeature?.wifiLockType == 1;
+ }
+ }
+ }
+ }
+ });
+ }
+ if (isWifiLockType ||
+ (talkExpectResp.rotate == 0 &&
+ talkExpectResp.width == 640 &&
+ talkExpectResp.height == 480)) {
+ Get.toNamed(Routers.imageTransmissionView);
+ return;
+ }
+ if (startChartManage
+ .getDefaultTalkExpect()
+ .videoType
+ .contains(VideoTypeE.H264)) {
+ Get.toNamed(
+ Routers.h264WebView,
+ );
+ } else {
+ Get.toNamed(
+ Routers.starChartTalkView,
+ );
+ }
}
}
diff --git a/lib/talk/starChart/handle/impl/udp_talk_request_handler.dart b/lib/talk/starChart/handle/impl/udp_talk_request_handler.dart
index 195c2ab6..4f3a002f 100644
--- a/lib/talk/starChart/handle/impl/udp_talk_request_handler.dart
+++ b/lib/talk/starChart/handle/impl/udp_talk_request_handler.dart
@@ -90,52 +90,10 @@ class UdpTalkRequestHandler extends ScpMessageBaseHandle
}) async {
// 发送预期数据、通知锁板需要获取视频数据
_handleRequestSendExpect(lockPeerID: lockPeerID);
- // 播放铃声
- //test:使用自定义铃声
- playRingtone();
// 显示状态栏弹窗
// _showTalkRequestNotification(talkObjectName: talkObjectName);
// 设置为等待接听状态
talkStatus.setPassiveCallWaitingAnswer();
-
- // 获取锁支持项
- final LockListInfoItemEntity currentKeyInfo =
- CommonDataManage().currentKeyInfo;
- var isWifiLockType = currentKeyInfo.lockFeature?.wifiLockType == 1;
-
- final LockListInfoGroupEntity? lockListInfoGroupEntity =
- await Storage.getLockMainListData();
- if (lockListInfoGroupEntity != null) {
- lockListInfoGroupEntity!.groupList?.forEach((element) {
- final lockList = element.lockList;
- if (lockList != null && lockList.length != 0) {
- for (var lockInfo in lockList) {
- final peerId = lockInfo.network?.peerId;
- if (peerId != null && peerId != '') {
- if (peerId == lockPeerID) {
- isWifiLockType = lockInfo.lockFeature?.wifiLockType == 1;
- }
- }
- }
- }
- });
- }
- if (isWifiLockType) {
- Get.toNamed(Routers.imageTransmissionView);
- return;
- }
- if (startChartManage
- .getDefaultTalkExpect()
- .videoType
- .contains(VideoTypeE.H264)) {
- Get.toNamed(
- Routers.h264WebView,
- );
- } else {
- Get.toNamed(
- Routers.starChartTalkView,
- );
- }
}
// 收到来电请求时进行本地通知
diff --git a/lib/talk/starChart/views/guide/permission_guidance_logic.dart b/lib/talk/starChart/views/guide/permission_guidance_logic.dart
new file mode 100644
index 00000000..d111726c
--- /dev/null
+++ b/lib/talk/starChart/views/guide/permission_guidance_logic.dart
@@ -0,0 +1,3 @@
+import 'package:star_lock/tools/baseGetXController.dart';
+
+class PermissionGuidanceLogic extends BaseGetXController {}
diff --git a/lib/talk/starChart/views/guide/permission_guidance_page.dart b/lib/talk/starChart/views/guide/permission_guidance_page.dart
new file mode 100644
index 00000000..08850eab
--- /dev/null
+++ b/lib/talk/starChart/views/guide/permission_guidance_page.dart
@@ -0,0 +1,109 @@
+import 'package:flutter/cupertino.dart';
+import 'package:flutter/material.dart';
+import 'package:flutter_screenutil/flutter_screenutil.dart';
+import 'package:get/get.dart';
+import 'package:star_lock/app_settings/app_colors.dart';
+import 'package:star_lock/tools/titleAppBar.dart';
+
+class PermissionGuidancePage extends StatefulWidget {
+ const PermissionGuidancePage({Key? key}) : super(key: key);
+
+ @override
+ State createState() => _PermissionGuidancePageState();
+}
+
+class _PermissionGuidancePageState extends State {
+ final PageController _pageController = PageController();
+ int _currentPage = 0;
+
+ final List