1,部分图片更新
2,部分空界面添加 3,部分界面更新 4,修改部分暂未开放提示为二级界面
BIN
star_lock/images/icon_about.png
Normal file
|
After Width: | Height: | Size: 213 KiB |
|
Before Width: | Height: | Size: 38 KiB After Width: | Height: | Size: 64 KiB |
BIN
star_lock/images/icon_noData.png
Normal file
|
After Width: | Height: | Size: 8.7 KiB |
@ -212,7 +212,7 @@
|
|||||||
"pushNotification":"消息推送",
|
"pushNotification":"消息推送",
|
||||||
"lockUserManagement":"锁用户管理",
|
"lockUserManagement":"锁用户管理",
|
||||||
"ownedKey":"拥有的钥匙",
|
"ownedKey":"拥有的钥匙",
|
||||||
"authorityManagement":"权限管理",
|
"authorityManagement":"批量授权",
|
||||||
"associatedDevice":"关联设备",
|
"associatedDevice":"关联设备",
|
||||||
"associatedName":"关联姓名",
|
"associatedName":"关联姓名",
|
||||||
"device":"设备",
|
"device":"设备",
|
||||||
|
|||||||
BIN
star_lock/images/lockType/addLock_entranceGuardBg.png
Normal file
|
After Width: | Height: | Size: 37 KiB |
BIN
star_lock/images/lockType/addLock_parkingBg.png
Normal file
|
After Width: | Height: | Size: 66 KiB |
BIN
star_lock/images/lockType/addLock_safeBg.png
Normal file
|
After Width: | Height: | Size: 73 KiB |
@ -1,122 +1,121 @@
|
|||||||
{
|
{
|
||||||
"images" : [
|
"images" : [
|
||||||
{
|
{
|
||||||
"size" : "20x20",
|
"filename" : "icon-20@2x.png",
|
||||||
"idiom" : "iphone",
|
"idiom" : "iphone",
|
||||||
"filename" : "Icon-App-20x20@2x.png",
|
"scale" : "2x",
|
||||||
"scale" : "2x"
|
"size" : "20x20"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"size" : "20x20",
|
"filename" : "icon-20@3x.png",
|
||||||
"idiom" : "iphone",
|
"idiom" : "iphone",
|
||||||
"filename" : "Icon-App-20x20@3x.png",
|
"scale" : "3x",
|
||||||
"scale" : "3x"
|
"size" : "20x20"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"size" : "29x29",
|
|
||||||
"idiom" : "iphone",
|
"idiom" : "iphone",
|
||||||
"filename" : "Icon-App-29x29@1x.png",
|
"scale" : "1x",
|
||||||
"scale" : "1x"
|
"size" : "29x29"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"size" : "29x29",
|
"filename" : "icon-29@2x.png",
|
||||||
"idiom" : "iphone",
|
"idiom" : "iphone",
|
||||||
"filename" : "Icon-App-29x29@2x.png",
|
"scale" : "2x",
|
||||||
"scale" : "2x"
|
"size" : "29x29"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"size" : "29x29",
|
"filename" : "icon-29@3x.png",
|
||||||
"idiom" : "iphone",
|
"idiom" : "iphone",
|
||||||
"filename" : "Icon-App-29x29@3x.png",
|
"scale" : "3x",
|
||||||
"scale" : "3x"
|
"size" : "29x29"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"size" : "40x40",
|
"filename" : "icon-40@2x.png",
|
||||||
"idiom" : "iphone",
|
"idiom" : "iphone",
|
||||||
"filename" : "Icon-App-40x40@2x.png",
|
"scale" : "2x",
|
||||||
"scale" : "2x"
|
"size" : "40x40"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"size" : "40x40",
|
"filename" : "icon-40@3x.png",
|
||||||
"idiom" : "iphone",
|
"idiom" : "iphone",
|
||||||
"filename" : "Icon-App-40x40@3x.png",
|
"scale" : "3x",
|
||||||
"scale" : "3x"
|
"size" : "40x40"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"size" : "60x60",
|
"filename" : "icon-60@2x.png",
|
||||||
"idiom" : "iphone",
|
"idiom" : "iphone",
|
||||||
"filename" : "Icon-App-60x60@2x.png",
|
"scale" : "2x",
|
||||||
"scale" : "2x"
|
"size" : "60x60"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"size" : "60x60",
|
"filename" : "icon-60@3x.png",
|
||||||
"idiom" : "iphone",
|
"idiom" : "iphone",
|
||||||
"filename" : "Icon-App-60x60@3x.png",
|
"scale" : "3x",
|
||||||
"scale" : "3x"
|
"size" : "60x60"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"size" : "20x20",
|
|
||||||
"idiom" : "ipad",
|
|
||||||
"filename" : "Icon-App-20x20@1x.png",
|
"filename" : "Icon-App-20x20@1x.png",
|
||||||
"scale" : "1x"
|
"idiom" : "ipad",
|
||||||
|
"scale" : "1x",
|
||||||
|
"size" : "20x20"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"size" : "20x20",
|
|
||||||
"idiom" : "ipad",
|
|
||||||
"filename" : "Icon-App-20x20@2x.png",
|
"filename" : "Icon-App-20x20@2x.png",
|
||||||
"scale" : "2x"
|
"idiom" : "ipad",
|
||||||
|
"scale" : "2x",
|
||||||
|
"size" : "20x20"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"size" : "29x29",
|
|
||||||
"idiom" : "ipad",
|
|
||||||
"filename" : "Icon-App-29x29@1x.png",
|
"filename" : "Icon-App-29x29@1x.png",
|
||||||
"scale" : "1x"
|
"idiom" : "ipad",
|
||||||
|
"scale" : "1x",
|
||||||
|
"size" : "29x29"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"size" : "29x29",
|
|
||||||
"idiom" : "ipad",
|
|
||||||
"filename" : "Icon-App-29x29@2x.png",
|
"filename" : "Icon-App-29x29@2x.png",
|
||||||
"scale" : "2x"
|
"idiom" : "ipad",
|
||||||
|
"scale" : "2x",
|
||||||
|
"size" : "29x29"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"size" : "40x40",
|
|
||||||
"idiom" : "ipad",
|
|
||||||
"filename" : "Icon-App-40x40@1x.png",
|
"filename" : "Icon-App-40x40@1x.png",
|
||||||
"scale" : "1x"
|
"idiom" : "ipad",
|
||||||
|
"scale" : "1x",
|
||||||
|
"size" : "40x40"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"size" : "40x40",
|
|
||||||
"idiom" : "ipad",
|
|
||||||
"filename" : "Icon-App-40x40@2x.png",
|
"filename" : "Icon-App-40x40@2x.png",
|
||||||
"scale" : "2x"
|
"idiom" : "ipad",
|
||||||
|
"scale" : "2x",
|
||||||
|
"size" : "40x40"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"size" : "76x76",
|
|
||||||
"idiom" : "ipad",
|
|
||||||
"filename" : "Icon-App-76x76@1x.png",
|
"filename" : "Icon-App-76x76@1x.png",
|
||||||
"scale" : "1x"
|
"idiom" : "ipad",
|
||||||
|
"scale" : "1x",
|
||||||
|
"size" : "76x76"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"size" : "76x76",
|
|
||||||
"idiom" : "ipad",
|
|
||||||
"filename" : "Icon-App-76x76@2x.png",
|
"filename" : "Icon-App-76x76@2x.png",
|
||||||
"scale" : "2x"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"size" : "83.5x83.5",
|
|
||||||
"idiom" : "ipad",
|
"idiom" : "ipad",
|
||||||
"filename" : "Icon-App-83.5x83.5@2x.png",
|
"scale" : "2x",
|
||||||
"scale" : "2x"
|
"size" : "76x76"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename" : "Icon-App-83.5x83.5@2x.png",
|
||||||
|
"idiom" : "ipad",
|
||||||
|
"scale" : "2x",
|
||||||
|
"size" : "83.5x83.5"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"size" : "1024x1024",
|
|
||||||
"idiom" : "ios-marketing",
|
|
||||||
"filename" : "Icon-App-1024x1024@1x.png",
|
"filename" : "Icon-App-1024x1024@1x.png",
|
||||||
"scale" : "1x"
|
"idiom" : "ios-marketing",
|
||||||
|
"scale" : "1x",
|
||||||
|
"size" : "1024x1024"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"info" : {
|
"info" : {
|
||||||
"version" : 1,
|
"author" : "xcode",
|
||||||
"author" : "xcode"
|
"version" : 1
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
|
Before Width: | Height: | Size: 1.6 KiB |
|
Before Width: | Height: | Size: 1.9 KiB |
|
Before Width: | Height: | Size: 2.6 KiB |
|
Before Width: | Height: | Size: 2.6 KiB |
|
Before Width: | Height: | Size: 3.7 KiB |
|
After Width: | Height: | Size: 1.2 KiB |
|
After Width: | Height: | Size: 1.6 KiB |
|
After Width: | Height: | Size: 1.4 KiB |
|
After Width: | Height: | Size: 4.1 KiB |
|
After Width: | Height: | Size: 3.8 KiB |
|
After Width: | Height: | Size: 6.0 KiB |
|
After Width: | Height: | Size: 6.0 KiB |
|
After Width: | Height: | Size: 9.7 KiB |
@ -7,7 +7,7 @@
|
|||||||
<key>CFBundleDevelopmentRegion</key>
|
<key>CFBundleDevelopmentRegion</key>
|
||||||
<string>$(DEVELOPMENT_LANGUAGE)</string>
|
<string>$(DEVELOPMENT_LANGUAGE)</string>
|
||||||
<key>CFBundleDisplayName</key>
|
<key>CFBundleDisplayName</key>
|
||||||
<string>Star Lock</string>
|
<string>星锁</string>
|
||||||
<key>CFBundleExecutable</key>
|
<key>CFBundleExecutable</key>
|
||||||
<string>$(EXECUTABLE_NAME)</string>
|
<string>$(EXECUTABLE_NAME)</string>
|
||||||
<key>CFBundleIdentifier</key>
|
<key>CFBundleIdentifier</key>
|
||||||
@ -15,7 +15,7 @@
|
|||||||
<key>CFBundleInfoDictionaryVersion</key>
|
<key>CFBundleInfoDictionaryVersion</key>
|
||||||
<string>6.0</string>
|
<string>6.0</string>
|
||||||
<key>CFBundleName</key>
|
<key>CFBundleName</key>
|
||||||
<string>star_lock</string>
|
<string>星锁</string>
|
||||||
<key>CFBundlePackageType</key>
|
<key>CFBundlePackageType</key>
|
||||||
<string>APPL</string>
|
<string>APPL</string>
|
||||||
<key>CFBundleShortVersionString</key>
|
<key>CFBundleShortVersionString</key>
|
||||||
@ -57,11 +57,11 @@
|
|||||||
</array>
|
</array>
|
||||||
<key>UILaunchStoryboardName</key>
|
<key>UILaunchStoryboardName</key>
|
||||||
<string>LaunchScreen</string>
|
<string>LaunchScreen</string>
|
||||||
<key>UIApplicationSceneManifest</key>
|
<key>UIApplicationSceneManifest</key>
|
||||||
<dict>
|
<dict>
|
||||||
<key>UISceneConfigurations</key>
|
<key>UISceneConfigurations</key>
|
||||||
<dict />
|
<dict/>
|
||||||
</dict>
|
</dict>
|
||||||
<key>UIMainStoryboardFile</key>
|
<key>UIMainStoryboardFile</key>
|
||||||
<string>Main</string>
|
<string>Main</string>
|
||||||
<key>UISupportedInterfaceOrientations</key>
|
<key>UISupportedInterfaceOrientations</key>
|
||||||
|
|||||||
@ -12,7 +12,7 @@ import 'package:star_lock/mine/about/webviewShow_page.dart';
|
|||||||
import 'package:star_lock/mine/mine/safeVerify/safeVerify_page.dart';
|
import 'package:star_lock/mine/mine/safeVerify/safeVerify_page.dart';
|
||||||
import 'package:star_lock/mine/minePersonInfo/minePersonInfoEmail/mineBindPhoneOrEmail_page.dart';
|
import 'package:star_lock/mine/minePersonInfo/minePersonInfoEmail/mineBindPhoneOrEmail_page.dart';
|
||||||
import 'package:star_lock/mine/minePersonInfo/minePersonInfoViewSafetyProblem/minePersonInfoViewSafetyProblem_page.dart';
|
import 'package:star_lock/mine/minePersonInfo/minePersonInfoViewSafetyProblem/minePersonInfoViewSafetyProblem_page.dart';
|
||||||
import 'package:star_lock/mine/mineSet/authorizedAdministrator/addAuthorizedAdministrator_page.dart';
|
import 'package:star_lock/mine/mineSet/addAuthorizedAdministrator/addAuthorizedAdministrator_page.dart';
|
||||||
import 'package:star_lock/mine/mineSet/authorizedAdministrator/administratorDetails/adminDetailChangeDate_page.dart';
|
import 'package:star_lock/mine/mineSet/authorizedAdministrator/administratorDetails/adminDetailChangeDate_page.dart';
|
||||||
import 'package:star_lock/mine/mineSet/authorizedAdministrator/administratorDetails/administratorDetails_page.dart';
|
import 'package:star_lock/mine/mineSet/authorizedAdministrator/administratorDetails/administratorDetails_page.dart';
|
||||||
import 'package:star_lock/mine/mineSet/lockGroup/lockGroupList_page.dart';
|
import 'package:star_lock/mine/mineSet/lockGroup/lockGroupList_page.dart';
|
||||||
@ -318,7 +318,7 @@ abstract class Routers {
|
|||||||
|
|
||||||
static const getDeviceListPage = '/getDeviceListPage'; //设备列表
|
static const getDeviceListPage = '/getDeviceListPage'; //设备列表
|
||||||
static const getNameListPage = '/getNameListPage'; //姓名列表
|
static const getNameListPage = '/getNameListPage'; //姓名列表
|
||||||
static const authorityManagementPage = '/authorityManagementPage'; //权限管理
|
static const authorityManagementPage = '/authorityManagementPage'; //批量授权
|
||||||
static const massSendLockGroupPage = '/massSendLockGroupPage'; //群发锁分组列表
|
static const massSendLockGroupPage = '/massSendLockGroupPage'; //群发锁分组列表
|
||||||
static const massSendReceiverPage = '/massSendReceiverPage'; //群发接收人
|
static const massSendReceiverPage = '/massSendReceiverPage'; //群发接收人
|
||||||
static const lockUserListPage = '/lockUserListPage'; //锁用户列表
|
static const lockUserListPage = '/lockUserListPage'; //锁用户列表
|
||||||
|
|||||||
@ -5,6 +5,7 @@ import 'package:star_lock/main/lockDetail/electronicKey/electronicKeyList/entity
|
|||||||
import 'package:star_lock/main/lockMian/entity/lockInfoEntity.dart';
|
import 'package:star_lock/main/lockMian/entity/lockInfoEntity.dart';
|
||||||
import 'package:star_lock/network/api_repository.dart';
|
import 'package:star_lock/network/api_repository.dart';
|
||||||
import 'package:star_lock/tools/baseGetXController.dart';
|
import 'package:star_lock/tools/baseGetXController.dart';
|
||||||
|
import 'package:star_lock/tools/noData.dart';
|
||||||
|
|
||||||
import '../../../../appRouters.dart';
|
import '../../../../appRouters.dart';
|
||||||
import '../../../../app_settings/app_colors.dart';
|
import '../../../../app_settings/app_colors.dart';
|
||||||
@ -116,32 +117,34 @@ class _AuthorizedAdminListPageState extends State<AuthorizedAdminListPage> {
|
|||||||
|
|
||||||
Widget _buildMainUI(itemData) {
|
Widget _buildMainUI(itemData) {
|
||||||
List<ElectronicKeyListItem> getItemData = itemData;
|
List<ElectronicKeyListItem> getItemData = itemData;
|
||||||
return ListView.builder(
|
return getItemData.isEmpty
|
||||||
itemCount: getItemData.length,
|
? const NoData()
|
||||||
itemBuilder: (c, index) {
|
: ListView.builder(
|
||||||
ElectronicKeyListItem indexEntity = getItemData[index];
|
itemCount: getItemData.length,
|
||||||
String useDateStr = ''; //使用期限
|
itemBuilder: (c, index) {
|
||||||
String keyStatus = ''; //钥匙状态
|
ElectronicKeyListItem indexEntity = getItemData[index];
|
||||||
|
String useDateStr = ''; //使用期限
|
||||||
|
String keyStatus = ''; //钥匙状态
|
||||||
|
|
||||||
//使用期限
|
//使用期限
|
||||||
useDateStr = getUseDateStr(indexEntity);
|
useDateStr = getUseDateStr(indexEntity);
|
||||||
|
|
||||||
//钥匙状态
|
//钥匙状态
|
||||||
keyStatus = getKeyStatus(indexEntity.keyStatus);
|
keyStatus = getKeyStatus(indexEntity.keyStatus);
|
||||||
|
|
||||||
//是否为管理钥匙
|
//是否为管理钥匙
|
||||||
bool isAdminKey = false;
|
bool isAdminKey = false;
|
||||||
if (indexEntity.keyRight == 1) {
|
if (indexEntity.keyRight == 1) {
|
||||||
isAdminKey = true;
|
isAdminKey = true;
|
||||||
} else {
|
} else {
|
||||||
isAdminKey = false;
|
isAdminKey = false;
|
||||||
}
|
}
|
||||||
return _electronicKeyItem('images/controls_user.png',
|
return _electronicKeyItem('images/controls_user.png',
|
||||||
indexEntity.keyName!, useDateStr, keyStatus, isAdminKey, () {
|
indexEntity.keyName!, useDateStr, keyStatus, isAdminKey, () {
|
||||||
Navigator.pushNamed(context, Routers.electronicKeyDetailPage,
|
Navigator.pushNamed(context, Routers.electronicKeyDetailPage,
|
||||||
arguments: {'itemData': indexEntity});
|
arguments: {'itemData': indexEntity});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
//使用期限
|
//使用期限
|
||||||
|
|||||||
@ -26,6 +26,7 @@ class VolumeAuthorizationLockPage extends StatefulWidget {
|
|||||||
_VolumeAuthorizationLockPageState();
|
_VolumeAuthorizationLockPageState();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//批量授权锁页面
|
||||||
class _VolumeAuthorizationLockPageState
|
class _VolumeAuthorizationLockPageState
|
||||||
extends State<VolumeAuthorizationLockPage> {
|
extends State<VolumeAuthorizationLockPage> {
|
||||||
final FlutterContactPicker _contactPicker = FlutterContactPicker();
|
final FlutterContactPicker _contactPicker = FlutterContactPicker();
|
||||||
|
|||||||
@ -5,6 +5,7 @@ import 'package:star_lock/app_settings/app_colors.dart';
|
|||||||
import 'package:star_lock/main/lockDetail/electronicKey/massSendElectronicKey/massSendLockGroupList/lockUserList/lockUserListEntity.dart';
|
import 'package:star_lock/main/lockDetail/electronicKey/massSendElectronicKey/massSendLockGroupList/lockUserList/lockUserListEntity.dart';
|
||||||
import 'package:star_lock/network/api_repository.dart';
|
import 'package:star_lock/network/api_repository.dart';
|
||||||
import 'package:star_lock/tools/baseGetXController.dart';
|
import 'package:star_lock/tools/baseGetXController.dart';
|
||||||
|
import 'package:star_lock/tools/noData.dart';
|
||||||
import 'package:star_lock/tools/submitBtn.dart';
|
import 'package:star_lock/tools/submitBtn.dart';
|
||||||
import 'package:star_lock/translations/trans_lib.dart';
|
import 'package:star_lock/translations/trans_lib.dart';
|
||||||
|
|
||||||
@ -56,16 +57,19 @@ class _LockUserListPageState extends State<LockUserListPage> {
|
|||||||
height: 20.h,
|
height: 20.h,
|
||||||
),
|
),
|
||||||
Expanded(
|
Expanded(
|
||||||
child: ListView.separated(
|
child: dataList.isEmpty
|
||||||
itemBuilder: (context, index) {
|
? const NoData()
|
||||||
LockUserData indexEntity = dataList[index];
|
: ListView.separated(
|
||||||
return _electronicKeyItem(indexEntity);
|
itemBuilder: (context, index) {
|
||||||
},
|
LockUserData indexEntity = dataList[index];
|
||||||
itemCount: dataList.length,
|
return _electronicKeyItem(indexEntity);
|
||||||
separatorBuilder: (context, index) {
|
},
|
||||||
return const Divider(height: 1, color: AppColors.greyLineColor);
|
itemCount: dataList.length,
|
||||||
},
|
separatorBuilder: (context, index) {
|
||||||
)),
|
return const Divider(
|
||||||
|
height: 1, color: AppColors.greyLineColor);
|
||||||
|
},
|
||||||
|
)),
|
||||||
Container(
|
Container(
|
||||||
height: 120.h,
|
height: 120.h,
|
||||||
padding: EdgeInsets.only(left: 20.w, right: 20.w, top: 0.h),
|
padding: EdgeInsets.only(left: 20.w, right: 20.w, top: 0.h),
|
||||||
|
|||||||
@ -122,6 +122,11 @@ class _MassSendLockGroupListPageState extends State<MassSendLockGroupListPage> {
|
|||||||
onTap: () {
|
onTap: () {
|
||||||
selectGroupIdList.add(index);
|
selectGroupIdList.add(index);
|
||||||
clickIndex = index;
|
clickIndex = index;
|
||||||
|
//是否选中组
|
||||||
|
if (itemData.isChecked) {
|
||||||
|
// lockItemList[selectIndex] =
|
||||||
|
}
|
||||||
|
print('选中了么0');
|
||||||
},
|
},
|
||||||
typeImgList: const [],
|
typeImgList: const [],
|
||||||
groupItem: itemData,
|
groupItem: itemData,
|
||||||
|
|||||||
@ -201,7 +201,9 @@ class _SendElectronicKeyPageState extends State<SendElectronicKeyPage> {
|
|||||||
isHaveRightWidget: true,
|
isHaveRightWidget: true,
|
||||||
rightWidget: SizedBox(
|
rightWidget: SizedBox(
|
||||||
width: 60.w, height: 50.h, child: _remoteSwitch(false)),
|
width: 60.w, height: 50.h, child: _remoteSwitch(false)),
|
||||||
action: () {}),
|
action: () {
|
||||||
|
// Toast.show(msg: '此功能暂未开放');
|
||||||
|
}),
|
||||||
],
|
],
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,6 +1,7 @@
|
|||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
||||||
import 'package:get/get.dart';
|
import 'package:get/get.dart';
|
||||||
|
import 'package:star_lock/tools/noData.dart';
|
||||||
|
|
||||||
import '../../../../../app_settings/app_colors.dart';
|
import '../../../../../app_settings/app_colors.dart';
|
||||||
import '../../../../../tools/titleAppBar.dart';
|
import '../../../../../tools/titleAppBar.dart';
|
||||||
@ -14,6 +15,7 @@ class NearbyDoorMagneticPage extends StatefulWidget {
|
|||||||
}
|
}
|
||||||
|
|
||||||
class _NearbyDoorMagneticPageState extends State<NearbyDoorMagneticPage> {
|
class _NearbyDoorMagneticPageState extends State<NearbyDoorMagneticPage> {
|
||||||
|
List dataList = [];
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return Scaffold(
|
return Scaffold(
|
||||||
@ -22,13 +24,16 @@ class _NearbyDoorMagneticPageState extends State<NearbyDoorMagneticPage> {
|
|||||||
barTitle: TranslationLoader.lanKeys!.nearbyEquipment!.tr,
|
barTitle: TranslationLoader.lanKeys!.nearbyEquipment!.tr,
|
||||||
haveBack: true,
|
haveBack: true,
|
||||||
backgroundColor: AppColors.mainColor),
|
backgroundColor: AppColors.mainColor),
|
||||||
body: ListView.builder(
|
body: dataList.isEmpty
|
||||||
itemCount: 20,
|
? const NoData()
|
||||||
itemBuilder: (c, index) {
|
: ListView.builder(
|
||||||
return nearbyLockItem('images/icon_lock.png', "MCBN01-ea9240", () {
|
itemCount: dataList.length,
|
||||||
// Navigator.pushNamed(context, Routers.saveLockPage);
|
itemBuilder: (c, index) {
|
||||||
});
|
return nearbyLockItem('images/icon_lock.png', "MCBN01-ea9240",
|
||||||
}),
|
() {
|
||||||
|
// Navigator.pushNamed(context, Routers.saveLockPage);
|
||||||
|
});
|
||||||
|
}),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -65,42 +65,65 @@ class _LockSetPageState extends State<LockSetPage> with RouteAware {
|
|||||||
'keyInfo': state.getKeyInfosData.value
|
'keyInfo': state.getKeyInfosData.value
|
||||||
});
|
});
|
||||||
}),
|
}),
|
||||||
SizedBox(height: 10.h,),
|
SizedBox(
|
||||||
|
height: 10.h,
|
||||||
|
),
|
||||||
// 门磁
|
// 门磁
|
||||||
Visibility(
|
Visibility(
|
||||||
visible: true,
|
visible: true,
|
||||||
child:CommonItem(
|
child: CommonItem(
|
||||||
leftTitel: TranslationLoader.lanKeys!.doorMagnetic!.tr,
|
leftTitel:
|
||||||
|
TranslationLoader.lanKeys!.doorMagnetic!.tr,
|
||||||
rightTitle: "",
|
rightTitle: "",
|
||||||
isHaveLine: true,
|
isHaveLine: true,
|
||||||
isHaveDirection: true,
|
isHaveDirection: true,
|
||||||
action: () {
|
action: () {
|
||||||
// Get.toNamed(Routers.doorMagneticPage);
|
Get.toNamed(Routers.doorMagneticPage);
|
||||||
Toast.show(msg: "功能暂未开放");
|
// Toast.show(msg: "功能暂未开放");
|
||||||
})
|
})),
|
||||||
),
|
|
||||||
// 无线键盘
|
// 无线键盘
|
||||||
Visibility(
|
Visibility(
|
||||||
visible: true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel:
|
leftTitel:
|
||||||
TranslationLoader.lanKeys!.wirelessKeyboard!.tr,
|
TranslationLoader.lanKeys!.wirelessKeyboard!.tr,
|
||||||
|
rightTitle: "",
|
||||||
|
isHaveLine: true,
|
||||||
|
isHaveDirection: true,
|
||||||
|
action: () {
|
||||||
|
Get.toNamed(Routers.wirelessKeyboardPage);
|
||||||
|
// Toast.show(msg: "功能暂未开放");
|
||||||
|
})),
|
||||||
|
Visibility(
|
||||||
|
visible: true,
|
||||||
|
child: CommonItem(
|
||||||
|
leftTitel: '照明',
|
||||||
|
rightTitle: "",
|
||||||
|
isHaveLine: true,
|
||||||
|
isHaveDirection: true,
|
||||||
|
action: () {
|
||||||
|
Toast.show(msg: "功能暂未开放");
|
||||||
|
})),
|
||||||
|
Visibility(
|
||||||
|
visible: true,
|
||||||
|
child: CommonItem(
|
||||||
|
leftTitel: '开门器',
|
||||||
rightTitle: "",
|
rightTitle: "",
|
||||||
isHaveLine: false,
|
isHaveLine: false,
|
||||||
isHaveDirection: true,
|
isHaveDirection: true,
|
||||||
action: () {
|
action: () {
|
||||||
// Get.toNamed(Routers.wirelessKeyboardPage);
|
|
||||||
Toast.show(msg: "功能暂未开放");
|
Toast.show(msg: "功能暂未开放");
|
||||||
})
|
})),
|
||||||
),
|
|
||||||
SizedBox(height: 10.h),
|
SizedBox(height: 10.h),
|
||||||
// 自动闭锁
|
// 自动闭锁
|
||||||
Obx(() => Visibility(
|
Obx(() => Visibility(
|
||||||
visible: true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel:
|
leftTitel:
|
||||||
TranslationLoader.lanKeys!.automaticBlocking!.tr,
|
TranslationLoader.lanKeys!.automaticBlocking!.tr,
|
||||||
rightTitle: state.getKeyInfosData.value.autoLockTime! > -1
|
rightTitle: state
|
||||||
|
.getKeyInfosData.value.autoLockTime! >
|
||||||
|
-1
|
||||||
? "${state.getKeyInfosData.value.autoLockTime!.toString()}s"
|
? "${state.getKeyInfosData.value.autoLockTime!.toString()}s"
|
||||||
: TranslationLoader.lanKeys!.closed!.tr,
|
: TranslationLoader.lanKeys!.closed!.tr,
|
||||||
isHaveLine: true,
|
isHaveLine: true,
|
||||||
@ -108,8 +131,7 @@ class _LockSetPageState extends State<LockSetPage> with RouteAware {
|
|||||||
action: () {
|
action: () {
|
||||||
Get.toNamed(Routers.automaticBlockingPage,
|
Get.toNamed(Routers.automaticBlockingPage,
|
||||||
arguments: state.getKeyInfosData.value);
|
arguments: state.getKeyInfosData.value);
|
||||||
}))
|
}))),
|
||||||
),
|
|
||||||
// 锁声音
|
// 锁声音
|
||||||
Obx(() {
|
Obx(() {
|
||||||
var titleStr = "";
|
var titleStr = "";
|
||||||
@ -144,144 +166,144 @@ class _LockSetPageState extends State<LockSetPage> with RouteAware {
|
|||||||
action: () {
|
action: () {
|
||||||
Get.toNamed(Routers.lockSoundSetPage,
|
Get.toNamed(Routers.lockSoundSetPage,
|
||||||
arguments: state.getKeyInfosData.value);
|
arguments: state.getKeyInfosData.value);
|
||||||
})
|
}));
|
||||||
);
|
|
||||||
}),
|
}),
|
||||||
// 防撬报警
|
// 防撬报警
|
||||||
Obx(() => Visibility(
|
Obx(() => Visibility(
|
||||||
visible: true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel: TranslationLoader.lanKeys!.burglarAlarm!.tr,
|
leftTitel:
|
||||||
rightTitle: state.getKeyInfosData.value.tamperAlert == 1
|
TranslationLoader.lanKeys!.burglarAlarm!.tr,
|
||||||
? TranslationLoader.lanKeys!.opened!.tr
|
rightTitle:
|
||||||
: TranslationLoader.lanKeys!.closed!.tr,
|
state.getKeyInfosData.value.tamperAlert == 1
|
||||||
isHaveLine: true,
|
? TranslationLoader.lanKeys!.opened!.tr
|
||||||
isHaveDirection: true,
|
: TranslationLoader.lanKeys!.closed!.tr,
|
||||||
action: () {
|
isHaveLine: true,
|
||||||
Get.toNamed(Routers.burglarAlarmPage,
|
isHaveDirection: true,
|
||||||
arguments: state.getKeyInfosData.value);
|
action: () {
|
||||||
}))),
|
Get.toNamed(Routers.burglarAlarmPage,
|
||||||
|
arguments: state.getKeyInfosData.value);
|
||||||
|
}))),
|
||||||
SizedBox(height: 10.h),
|
SizedBox(height: 10.h),
|
||||||
// 常开模式
|
// 常开模式
|
||||||
Obx(() => Visibility(
|
Obx(() => Visibility(
|
||||||
visible: true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel:
|
leftTitel:
|
||||||
TranslationLoader.lanKeys!.normallyOpenMode!.tr,
|
TranslationLoader.lanKeys!.normallyOpenMode!.tr,
|
||||||
rightTitle: state.getKeyInfosData.value.passageMode == 1
|
rightTitle:
|
||||||
? TranslationLoader.lanKeys!.opened!.tr
|
state.getKeyInfosData.value.passageMode == 1
|
||||||
: TranslationLoader.lanKeys!.closed!.tr,
|
? TranslationLoader.lanKeys!.opened!.tr
|
||||||
isHaveLine: true,
|
: TranslationLoader.lanKeys!.closed!.tr,
|
||||||
isHaveDirection: true,
|
isHaveLine: true,
|
||||||
action: () {
|
isHaveDirection: true,
|
||||||
Get.toNamed(Routers.normallyOpenModePage,
|
action: () {
|
||||||
arguments: state.getKeyInfosData.value);
|
Get.toNamed(Routers.normallyOpenModePage,
|
||||||
}))
|
arguments: state.getKeyInfosData.value);
|
||||||
),
|
}))),
|
||||||
// 远程开锁
|
// 远程开锁
|
||||||
Obx(() => Visibility(
|
Obx(() => Visibility(
|
||||||
visible:true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel: TranslationLoader.lanKeys!.remoteUnlocking!.tr,
|
leftTitel:
|
||||||
rightTitle: state.getKeyInfosData.value.remoteEnable == 1
|
TranslationLoader.lanKeys!.remoteUnlocking!.tr,
|
||||||
? TranslationLoader.lanKeys!.opened!.tr
|
rightTitle:
|
||||||
: TranslationLoader.lanKeys!.closed!.tr,
|
state.getKeyInfosData.value.remoteEnable == 1
|
||||||
isHaveLine: true,
|
? TranslationLoader.lanKeys!.opened!.tr
|
||||||
isHaveDirection: true,
|
: TranslationLoader.lanKeys!.closed!.tr,
|
||||||
action: () {
|
isHaveLine: true,
|
||||||
Get.toNamed(Routers.remoteUnlockingPage,
|
isHaveDirection: true,
|
||||||
arguments: state.getKeyInfosData.value);
|
action: () {
|
||||||
}))
|
Get.toNamed(Routers.remoteUnlockingPage,
|
||||||
),
|
arguments: state.getKeyInfosData.value);
|
||||||
|
}))),
|
||||||
// 重置键
|
// 重置键
|
||||||
Obx(() => Visibility(
|
Obx(() => Visibility(
|
||||||
visible: true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel: TranslationLoader.lanKeys!.resetButton!.tr,
|
leftTitel: TranslationLoader.lanKeys!.resetButton!.tr,
|
||||||
rightTitle: state.getKeyInfosData.value.resetButton == 1
|
rightTitle:
|
||||||
? TranslationLoader.lanKeys!.opened!.tr
|
state.getKeyInfosData.value.resetButton == 1
|
||||||
: TranslationLoader.lanKeys!.closed!.tr,
|
? TranslationLoader.lanKeys!.opened!.tr
|
||||||
isHaveLine: true,
|
: TranslationLoader.lanKeys!.closed!.tr,
|
||||||
isHaveDirection: true,
|
isHaveLine: true,
|
||||||
action: () {
|
isHaveDirection: true,
|
||||||
Get.toNamed(Routers.resetButtonPage,
|
action: () {
|
||||||
arguments: state.getKeyInfosData.value);
|
Get.toNamed(Routers.resetButtonPage,
|
||||||
}))
|
arguments: state.getKeyInfosData.value);
|
||||||
),
|
}))),
|
||||||
SizedBox(height: 10.h),
|
SizedBox(height: 10.h),
|
||||||
//---田总新增展示
|
//---田总新增展示
|
||||||
// Obx(() =>
|
// Obx(() =>
|
||||||
Visibility(
|
Visibility(
|
||||||
visible: true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel: '面容开锁',
|
leftTitel: '面容开锁',
|
||||||
rightTitle: "",
|
rightTitle: "",
|
||||||
isHaveLine: true,
|
isHaveLine: true,
|
||||||
isHaveRightWidget: true,
|
isHaveRightWidget: true,
|
||||||
rightWidget:
|
rightWidget: SizedBox(
|
||||||
SizedBox(width: 60.w, child: _otherUnHaveDoneSwitch()))),
|
width: 60.w, child: _otherUnHaveDoneSwitch()))),
|
||||||
// ),
|
// ),
|
||||||
// Obx(() =>
|
// Obx(() =>
|
||||||
Visibility(
|
Visibility(
|
||||||
visible: true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel: '感应距离',
|
leftTitel: '感应距离',
|
||||||
rightTitle: "",
|
rightTitle: "",
|
||||||
isHaveLine: true,
|
isHaveLine: true,
|
||||||
isHaveDirection: true,
|
isHaveDirection: true,
|
||||||
action: () {
|
action: () {
|
||||||
Toast.show(msg: "功能暂未开放");
|
Toast.show(msg: "功能暂未开放");
|
||||||
}
|
})),
|
||||||
)),
|
|
||||||
// ),
|
// ),
|
||||||
// Obx(() =>
|
// Obx(() =>
|
||||||
Visibility(
|
Visibility(
|
||||||
visible: true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel: '自动亮屏',
|
leftTitel: '自动亮屏',
|
||||||
rightTitle: "",
|
rightTitle: "",
|
||||||
isHaveLine: true,
|
isHaveLine: true,
|
||||||
isHaveRightWidget: true,
|
isHaveRightWidget: true,
|
||||||
rightWidget:
|
rightWidget: SizedBox(
|
||||||
SizedBox(width: 60.w, child: _otherUnHaveDoneSwitch()))),
|
width: 60.w, child: _otherUnHaveDoneSwitch()))),
|
||||||
// ),
|
// ),
|
||||||
// Obx(() =>
|
// Obx(() =>
|
||||||
Visibility(
|
Visibility(
|
||||||
visible: true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel: '逗留警告',
|
leftTitel: '逗留警告',
|
||||||
rightTitle: "",
|
rightTitle: "",
|
||||||
isHaveLine: true,
|
isHaveLine: true,
|
||||||
isHaveRightWidget: true,
|
isHaveRightWidget: true,
|
||||||
rightWidget:
|
rightWidget: SizedBox(
|
||||||
SizedBox(width: 60.w, child: _otherUnHaveDoneSwitch()))),
|
width: 60.w, child: _otherUnHaveDoneSwitch()))),
|
||||||
// ),
|
// ),
|
||||||
// Obx(() =>
|
// Obx(() =>
|
||||||
Visibility(
|
Visibility(
|
||||||
visible: true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel: '异常警告',
|
leftTitel: '异常警告',
|
||||||
rightTitle: "",
|
rightTitle: "",
|
||||||
isHaveLine: true,
|
isHaveLine: true,
|
||||||
isHaveRightWidget: true,
|
isHaveRightWidget: true,
|
||||||
rightWidget:
|
rightWidget: SizedBox(
|
||||||
SizedBox(width: 60.w, child: _otherUnHaveDoneSwitch()))),
|
width: 60.w, child: _otherUnHaveDoneSwitch()))),
|
||||||
// ),
|
// ),
|
||||||
// Obx(() =>
|
// Obx(() =>
|
||||||
Visibility(
|
Visibility(
|
||||||
visible: true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel: '开门方向设置',
|
leftTitel: '开门方向设置',
|
||||||
rightTitle: "",
|
rightTitle: "",
|
||||||
isHaveDirection: true,
|
isHaveDirection: true,
|
||||||
isHaveLine: true,
|
isHaveLine: true,
|
||||||
action: () {
|
action: () {
|
||||||
Toast.show(msg: "功能暂未开放");
|
Toast.show(msg: "功能暂未开放");
|
||||||
}
|
})),
|
||||||
)),
|
|
||||||
// ),
|
// ),
|
||||||
// Obx(() =>
|
// Obx(() =>
|
||||||
Visibility(
|
Visibility(
|
||||||
visible: true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel: '电机功率设置',
|
leftTitel: '电机功率设置',
|
||||||
@ -290,8 +312,7 @@ class _LockSetPageState extends State<LockSetPage> with RouteAware {
|
|||||||
isHaveDirection: true,
|
isHaveDirection: true,
|
||||||
action: () {
|
action: () {
|
||||||
Toast.show(msg: "功能暂未开放");
|
Toast.show(msg: "功能暂未开放");
|
||||||
}
|
})),
|
||||||
)),
|
|
||||||
// ),
|
// ),
|
||||||
SizedBox(height: 10.h),
|
SizedBox(height: 10.h),
|
||||||
//-----新增至此
|
//-----新增至此
|
||||||
@ -306,42 +327,41 @@ class _LockSetPageState extends State<LockSetPage> with RouteAware {
|
|||||||
visible: true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel:
|
leftTitel:
|
||||||
TranslationLoader.lanKeys!.markedHouseState!.tr,
|
TranslationLoader.lanKeys!.markedHouseState!.tr,
|
||||||
rightTitle: title,
|
rightTitle: title,
|
||||||
isHaveLine: true,
|
isHaveLine: true,
|
||||||
isHaveDirection: true,
|
isHaveDirection: true,
|
||||||
action: () {
|
action: () {
|
||||||
Get.toNamed(Routers.markedHouseStatePage,
|
Get.toNamed(Routers.markedHouseStatePage,
|
||||||
arguments: state.getKeyInfosData.value);
|
arguments: state.getKeyInfosData.value);
|
||||||
})
|
}));
|
||||||
);
|
|
||||||
}),
|
}),
|
||||||
// Obx(() =>
|
// Obx(() =>
|
||||||
Visibility(
|
Visibility(
|
||||||
visible: true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel: TranslationLoader.lanKeys!.checkingIn!.tr,
|
leftTitel: TranslationLoader.lanKeys!.checkingIn!.tr,
|
||||||
rightTitle: "",
|
rightTitle: "",
|
||||||
isHaveLine: true,
|
isHaveLine: true,
|
||||||
isHaveRightWidget: true,
|
isHaveRightWidget: true,
|
||||||
rightWidget:
|
rightWidget: SizedBox(
|
||||||
SizedBox(width: 60.w, child: _openCheckInSwitch())
|
width: 60.w, child: _openCheckInSwitch()))),
|
||||||
)),
|
|
||||||
// ),
|
// ),
|
||||||
// Obx(() =>
|
// Obx(() =>
|
||||||
Visibility(
|
Visibility(
|
||||||
visible: true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel: TranslationLoader.lanKeys!.unlockReminder!.tr,
|
leftTitel:
|
||||||
|
TranslationLoader.lanKeys!.unlockReminder!.tr,
|
||||||
rightTitle: "",
|
rightTitle: "",
|
||||||
isHaveLine: false,
|
isHaveLine: false,
|
||||||
isHaveRightWidget: true,
|
isHaveRightWidget: true,
|
||||||
rightWidget:
|
rightWidget: SizedBox(
|
||||||
SizedBox(width: 60.w, child: _lockRemindSwitch()))),
|
width: 60.w, child: _lockRemindSwitch()))),
|
||||||
// ),
|
// ),
|
||||||
SizedBox(height: 10.h),
|
SizedBox(height: 10.h),
|
||||||
// Obx(() =>
|
// Obx(() =>
|
||||||
Visibility(
|
Visibility(
|
||||||
visible: true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel: TranslationLoader
|
leftTitel: TranslationLoader
|
||||||
@ -354,20 +374,20 @@ class _LockSetPageState extends State<LockSetPage> with RouteAware {
|
|||||||
})),
|
})),
|
||||||
// ),
|
// ),
|
||||||
// Obx(() =>
|
// Obx(() =>
|
||||||
Visibility(
|
Visibility(
|
||||||
visible: true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel: TranslationLoader.lanKeys!.lockTime!.tr,
|
leftTitel: TranslationLoader.lanKeys!.lockTime!.tr,
|
||||||
rightTitle: "",
|
rightTitle: "",
|
||||||
isHaveLine: true,
|
isHaveLine: true,
|
||||||
isHaveDirection: true,
|
isHaveDirection: true,
|
||||||
action: () {
|
action: () {
|
||||||
Get.toNamed(Routers.lockTimePage,
|
Get.toNamed(Routers.lockTimePage,
|
||||||
arguments: state.getKeyInfosData.value);
|
arguments: state.getKeyInfosData.value);
|
||||||
})),
|
})),
|
||||||
// ),
|
// ),
|
||||||
// Obx(() =>
|
// Obx(() =>
|
||||||
Visibility(
|
Visibility(
|
||||||
visible: true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel: TranslationLoader.lanKeys!.diagnose!.tr,
|
leftTitel: TranslationLoader.lanKeys!.diagnose!.tr,
|
||||||
@ -380,7 +400,7 @@ class _LockSetPageState extends State<LockSetPage> with RouteAware {
|
|||||||
})),
|
})),
|
||||||
// ),
|
// ),
|
||||||
// Obx(() =>
|
// Obx(() =>
|
||||||
Visibility(
|
Visibility(
|
||||||
visible: true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel: TranslationLoader.lanKeys!.uploadData!.tr,
|
leftTitel: TranslationLoader.lanKeys!.uploadData!.tr,
|
||||||
@ -392,11 +412,11 @@ class _LockSetPageState extends State<LockSetPage> with RouteAware {
|
|||||||
})),
|
})),
|
||||||
// ),
|
// ),
|
||||||
// Obx(() =>
|
// Obx(() =>
|
||||||
Visibility(
|
Visibility(
|
||||||
visible: true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel:
|
leftTitel: TranslationLoader
|
||||||
TranslationLoader.lanKeys!.importOtherLockData!.tr,
|
.lanKeys!.importOtherLockData!.tr,
|
||||||
rightTitle: "",
|
rightTitle: "",
|
||||||
isHaveLine: true,
|
isHaveLine: true,
|
||||||
isHaveDirection: true,
|
isHaveDirection: true,
|
||||||
@ -405,10 +425,11 @@ class _LockSetPageState extends State<LockSetPage> with RouteAware {
|
|||||||
})),
|
})),
|
||||||
// ),
|
// ),
|
||||||
// Obx(() =>
|
// Obx(() =>
|
||||||
Visibility(
|
Visibility(
|
||||||
visible: true,
|
visible: true,
|
||||||
child: CommonItem(
|
child: CommonItem(
|
||||||
leftTitel: TranslationLoader.lanKeys!.lockEscalation!.tr,
|
leftTitel:
|
||||||
|
TranslationLoader.lanKeys!.lockEscalation!.tr,
|
||||||
rightTitle: "",
|
rightTitle: "",
|
||||||
isHaveLine: false,
|
isHaveLine: false,
|
||||||
isHaveDirection: true,
|
isHaveDirection: true,
|
||||||
@ -418,7 +439,8 @@ class _LockSetPageState extends State<LockSetPage> with RouteAware {
|
|||||||
// ),
|
// ),
|
||||||
SizedBox(height: 30.h),
|
SizedBox(height: 30.h),
|
||||||
Container(
|
Container(
|
||||||
padding: EdgeInsets.only(left: 20.w, right: 20.w, bottom: 30.h),
|
padding:
|
||||||
|
EdgeInsets.only(left: 20.w, right: 20.w, bottom: 30.h),
|
||||||
child: SubmitBtn(
|
child: SubmitBtn(
|
||||||
btnName: TranslationLoader.lanKeys!.delete!.tr,
|
btnName: TranslationLoader.lanKeys!.delete!.tr,
|
||||||
isDelete: true,
|
isDelete: true,
|
||||||
|
|||||||
@ -78,15 +78,15 @@ class _AddWirelessKeyboardPageState extends State<AddWirelessKeyboardPage> {
|
|||||||
SizedBox(
|
SizedBox(
|
||||||
height: 20.h,
|
height: 20.h,
|
||||||
),
|
),
|
||||||
Container(
|
// Container(
|
||||||
margin: EdgeInsets.only(left: 20.w, right: 20.w),
|
// margin: EdgeInsets.only(left: 20.w, right: 20.w),
|
||||||
child: SubmitBtn(
|
// child: SubmitBtn(
|
||||||
btnName: TranslationLoader.lanKeys!.theScreenNeverFlickered!.tr,
|
// btnName: TranslationLoader.lanKeys!.theScreenNeverFlickered!.tr,
|
||||||
onClick: () {
|
// onClick: () {
|
||||||
Navigator.pushNamed(
|
// Navigator.pushNamed(
|
||||||
context, Routers.addWirelessKeyboardScreenNotLightOnPage);
|
// context, Routers.addWirelessKeyboardScreenNotLightOnPage);
|
||||||
}),
|
// }),
|
||||||
),
|
// ),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
|
|||||||
@ -1,6 +1,7 @@
|
|||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
||||||
import 'package:get/get.dart';
|
import 'package:get/get.dart';
|
||||||
|
import 'package:star_lock/tools/noData.dart';
|
||||||
|
|
||||||
import '../../../../../app_settings/app_colors.dart';
|
import '../../../../../app_settings/app_colors.dart';
|
||||||
import '../../../../../tools/titleAppBar.dart';
|
import '../../../../../tools/titleAppBar.dart';
|
||||||
@ -15,6 +16,7 @@ class SeletWirelessKeyboardPage extends StatefulWidget {
|
|||||||
}
|
}
|
||||||
|
|
||||||
class _SeletWirelessKeyboardPageState extends State<SeletWirelessKeyboardPage> {
|
class _SeletWirelessKeyboardPageState extends State<SeletWirelessKeyboardPage> {
|
||||||
|
List dataList = [];
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return Scaffold(
|
return Scaffold(
|
||||||
@ -24,13 +26,16 @@ class _SeletWirelessKeyboardPageState extends State<SeletWirelessKeyboardPage> {
|
|||||||
"${TranslationLoader.lanKeys!.selet!.tr}${TranslationLoader.lanKeys!.wirelessKeyboard!.tr}",
|
"${TranslationLoader.lanKeys!.selet!.tr}${TranslationLoader.lanKeys!.wirelessKeyboard!.tr}",
|
||||||
haveBack: true,
|
haveBack: true,
|
||||||
backgroundColor: AppColors.mainColor),
|
backgroundColor: AppColors.mainColor),
|
||||||
body: ListView.builder(
|
body: dataList.isEmpty
|
||||||
itemCount: 20,
|
? const NoData()
|
||||||
itemBuilder: (c, index) {
|
: ListView.builder(
|
||||||
return nearbyLockItem('images/icon_lock.png', "MCBN01-ea9240", () {
|
itemCount: 20,
|
||||||
// Navigator.pushNamed(context, Routers.saveLockPage);
|
itemBuilder: (c, index) {
|
||||||
});
|
return nearbyLockItem('images/icon_lock.png', "MCBN01-ea9240",
|
||||||
}),
|
() {
|
||||||
|
// Navigator.pushNamed(context, Routers.saveLockPage);
|
||||||
|
});
|
||||||
|
}),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -2,6 +2,7 @@ import 'package:flutter/cupertino.dart';
|
|||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
||||||
import 'package:get/get.dart';
|
import 'package:get/get.dart';
|
||||||
|
import 'package:star_lock/tools/noData.dart';
|
||||||
|
|
||||||
import '../../../../../appRouters.dart';
|
import '../../../../../appRouters.dart';
|
||||||
import '../../../../../app_settings/app_colors.dart';
|
import '../../../../../app_settings/app_colors.dart';
|
||||||
@ -17,6 +18,7 @@ class WirelessKeyboardPage extends StatefulWidget {
|
|||||||
}
|
}
|
||||||
|
|
||||||
class _WirelessKeyboardPageState extends State<WirelessKeyboardPage> {
|
class _WirelessKeyboardPageState extends State<WirelessKeyboardPage> {
|
||||||
|
List dataList = [];
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return Scaffold(
|
return Scaffold(
|
||||||
@ -55,14 +57,16 @@ class _WirelessKeyboardPageState extends State<WirelessKeyboardPage> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
Widget _buildMainUI() {
|
Widget _buildMainUI() {
|
||||||
return ListView.builder(
|
return dataList.isEmpty
|
||||||
itemCount: 10,
|
? const NoData()
|
||||||
itemBuilder: (c, index) {
|
: ListView.builder(
|
||||||
return _electronicKeyItem('images/icon_password.png', "张三",
|
itemCount: 10,
|
||||||
"2023.6.21 11.15", "2023.6.21 11.15", () {
|
itemBuilder: (c, index) {
|
||||||
// Navigator.pushNamed(context, Routers.electronicKeyDetailPage);
|
return _electronicKeyItem('images/icon_password.png', "张三",
|
||||||
});
|
"2023.6.21 11.15", "2023.6.21 11.15", () {
|
||||||
});
|
// Navigator.pushNamed(context, Routers.electronicKeyDetailPage);
|
||||||
|
});
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
Widget _electronicKeyItem(String lockTypeIcon, String lockTypeTitle,
|
Widget _electronicKeyItem(String lockTypeIcon, String lockTypeTitle,
|
||||||
|
|||||||
@ -86,7 +86,7 @@ class _LockDetailPageState extends State<LockDetailPage> with RouteAware {
|
|||||||
// KeyInfos keyInfo = widget.lockMainEntity.data!.keyInfos![0];
|
// KeyInfos keyInfo = widget.lockMainEntity.data!.keyInfos![0];
|
||||||
return Column(
|
return Column(
|
||||||
children: [
|
children: [
|
||||||
SizedBox(height: 30.h),
|
SizedBox(height: 50.h),
|
||||||
Stack(
|
Stack(
|
||||||
alignment: Alignment.centerRight,
|
alignment: Alignment.centerRight,
|
||||||
children: [
|
children: [
|
||||||
@ -120,7 +120,7 @@ class _LockDetailPageState extends State<LockDetailPage> with RouteAware {
|
|||||||
Container(
|
Container(
|
||||||
// width: 1.sw,
|
// width: 1.sw,
|
||||||
color: Colors.white,
|
color: Colors.white,
|
||||||
height: 280.w,
|
height: 330.w,
|
||||||
child: Stack(
|
child: Stack(
|
||||||
children: [
|
children: [
|
||||||
Center(
|
Center(
|
||||||
@ -131,8 +131,11 @@ class _LockDetailPageState extends State<LockDetailPage> with RouteAware {
|
|||||||
// logic.editLockUserAction();
|
// logic.editLockUserAction();
|
||||||
// logic.factoryDataResetAction();
|
// logic.factoryDataResetAction();
|
||||||
},
|
},
|
||||||
child: Image.asset('images/main/icon_main_openLockBtn.png',
|
child: Image.asset(
|
||||||
width: 268.w, height: 268.w),
|
'images/main/icon_main_openLockBtn.png',
|
||||||
|
width: 330.w,
|
||||||
|
height: 330.w,
|
||||||
|
),
|
||||||
)),
|
)),
|
||||||
// Visibility(
|
// Visibility(
|
||||||
// visible:
|
// visible:
|
||||||
@ -150,21 +153,21 @@ class _LockDetailPageState extends State<LockDetailPage> with RouteAware {
|
|||||||
SizedBox(
|
SizedBox(
|
||||||
height: 30.h,
|
height: 30.h,
|
||||||
),
|
),
|
||||||
Row(
|
// Row(
|
||||||
mainAxisAlignment: MainAxisAlignment.center,
|
// mainAxisAlignment: MainAxisAlignment.center,
|
||||||
children: [
|
// children: [
|
||||||
Text(
|
// Text(
|
||||||
'门已上锁',
|
// '门已上锁',
|
||||||
style: TextStyle(
|
// style: TextStyle(
|
||||||
fontSize: 26.sp,
|
// fontSize: 26.sp,
|
||||||
color: Colors.black,
|
// color: Colors.black,
|
||||||
fontWeight: FontWeight.w500),
|
// fontWeight: FontWeight.w500),
|
||||||
),
|
// ),
|
||||||
],
|
// ],
|
||||||
),
|
// ),
|
||||||
SizedBox(
|
// SizedBox(
|
||||||
height: 6.h,
|
// height: 6.h,
|
||||||
),
|
// ),
|
||||||
Row(
|
Row(
|
||||||
mainAxisAlignment: MainAxisAlignment.center,
|
mainAxisAlignment: MainAxisAlignment.center,
|
||||||
children: [
|
children: [
|
||||||
@ -187,14 +190,15 @@ class _LockDetailPageState extends State<LockDetailPage> with RouteAware {
|
|||||||
'images/icon_electronicKey_admin.png',
|
'images/icon_electronicKey_admin.png',
|
||||||
width: 24.w,
|
width: 24.w,
|
||||||
height: 20.w,
|
height: 20.w,
|
||||||
|
color: AppColors.mainColor, //应根据状态显示(当前角色为超级管理员 应显示蓝色图标)
|
||||||
),
|
),
|
||||||
SizedBox(
|
SizedBox(
|
||||||
width: 6.w,
|
width: 6.w,
|
||||||
),
|
),
|
||||||
Text(
|
Text(
|
||||||
'超级管理员',
|
'超级管理员',
|
||||||
style:
|
style: TextStyle(
|
||||||
TextStyle(fontSize: 20.sp, color: AppColors.btnDisableColor),
|
fontSize: 20.sp, color: AppColors.darkGrayTextColor),
|
||||||
),
|
),
|
||||||
SizedBox(
|
SizedBox(
|
||||||
width: 80.w,
|
width: 80.w,
|
||||||
@ -265,10 +269,10 @@ class _LockDetailPageState extends State<LockDetailPage> with RouteAware {
|
|||||||
bottomItem('images/main/icon_main_electronicKey.png',
|
bottomItem('images/main/icon_main_electronicKey.png',
|
||||||
TranslationLoader.lanKeys!.electronicKey!.tr, () {
|
TranslationLoader.lanKeys!.electronicKey!.tr, () {
|
||||||
Get.toNamed(Routers.electronicKeyListPage, arguments: {
|
Get.toNamed(Routers.electronicKeyListPage, arguments: {
|
||||||
"lockMainEntity": widget.lockMainEntity,
|
"lockMainEntity": widget.lockMainEntity,
|
||||||
"keyInfo": widget.keyInfo
|
"keyInfo": widget.keyInfo
|
||||||
});
|
});
|
||||||
}),
|
}),
|
||||||
|
|
||||||
// 密码
|
// 密码
|
||||||
bottomItem('images/main/icon_main_password.png',
|
bottomItem('images/main/icon_main_password.png',
|
||||||
@ -280,28 +284,24 @@ class _LockDetailPageState extends State<LockDetailPage> with RouteAware {
|
|||||||
}),
|
}),
|
||||||
|
|
||||||
// ic卡
|
// ic卡
|
||||||
bottomItem('images/main/icon_main_icCard.png', TranslationLoader.lanKeys!.card!.tr, () {
|
bottomItem('images/main/icon_main_icCard.png',
|
||||||
Get.toNamed(Routers.otherTypeKeyListPage, arguments: {
|
TranslationLoader.lanKeys!.card!.tr, () {
|
||||||
"lockId": widget.keyInfo.lockId,
|
Get.toNamed(Routers.otherTypeKeyListPage,
|
||||||
"fromType": 0
|
arguments: {"lockId": widget.keyInfo.lockId, "fromType": 0});
|
||||||
});
|
}),
|
||||||
}),
|
|
||||||
|
|
||||||
// 指纹
|
// 指纹
|
||||||
bottomItem('images/main/icon_main_fingerprint.png', TranslationLoader.lanKeys!.fingerprint!.tr, () {
|
bottomItem('images/main/icon_main_fingerprint.png',
|
||||||
Get.toNamed(Routers.otherTypeKeyListPage, arguments: {
|
TranslationLoader.lanKeys!.fingerprint!.tr, () {
|
||||||
"lockId": widget.keyInfo.lockId,
|
Get.toNamed(Routers.otherTypeKeyListPage,
|
||||||
"fromType": 1
|
arguments: {"lockId": widget.keyInfo.lockId, "fromType": 1});
|
||||||
});
|
|
||||||
}),
|
}),
|
||||||
|
|
||||||
// 遥控
|
// 遥控
|
||||||
bottomItem('images/main/icon_main_remoteControl.png', TranslationLoader.lanKeys!.remoteControl!.tr, () {
|
bottomItem('images/main/icon_main_remoteControl.png',
|
||||||
// Get.toNamed(Routers.otherTypeKeyListPage, arguments: {
|
TranslationLoader.lanKeys!.remoteControl!.tr, () {
|
||||||
// "lockId": widget.keyInfo.lockId,
|
Get.toNamed(Routers.otherTypeKeyListPage,
|
||||||
// "fromType": 2
|
arguments: {"lockId": widget.keyInfo.lockId, "fromType": 2});
|
||||||
// });
|
|
||||||
Toast.show(msg: "功能暂未开放");
|
|
||||||
}),
|
}),
|
||||||
];
|
];
|
||||||
showWidgetArr.addAll(defaultWidgetArr);
|
showWidgetArr.addAll(defaultWidgetArr);
|
||||||
@ -345,7 +345,7 @@ class _LockDetailPageState extends State<LockDetailPage> with RouteAware {
|
|||||||
bottomItem(
|
bottomItem(
|
||||||
'images/main/icon_main_set.png', TranslationLoader.lanKeys!.set!.tr,
|
'images/main/icon_main_set.png', TranslationLoader.lanKeys!.set!.tr,
|
||||||
() {
|
() {
|
||||||
BlueManage().stopScan();
|
BlueManage().stopScan();
|
||||||
Get.toNamed(Routers.lockSetPage, arguments: widget.keyInfo);
|
Get.toNamed(Routers.lockSetPage, arguments: widget.keyInfo);
|
||||||
}),
|
}),
|
||||||
];
|
];
|
||||||
|
|||||||
@ -1,4 +1,3 @@
|
|||||||
|
|
||||||
import 'dart:math';
|
import 'dart:math';
|
||||||
|
|
||||||
import 'package:get/get.dart';
|
import 'package:get/get.dart';
|
||||||
@ -13,19 +12,19 @@ class OtherTypeAddKeyLogic extends BaseGetXController {
|
|||||||
OtherTypeAddKeyState state = OtherTypeAddKeyState();
|
OtherTypeAddKeyState state = OtherTypeAddKeyState();
|
||||||
|
|
||||||
// 添加指纹
|
// 添加指纹
|
||||||
void addFingerprintsData() async{
|
void addFingerprintsData() async {
|
||||||
var fingerprintType = 0;// 永久:1;限时2,单次3,循环:4
|
var fingerprintType = 0; // 永久:1;限时2,单次3,循环:4
|
||||||
var startDate = "";
|
var startDate = "";
|
||||||
var endDate = "";
|
var endDate = "";
|
||||||
if(state.seletType.value == "0"){
|
if (state.seletType.value == "0") {
|
||||||
fingerprintType = 1;
|
fingerprintType = 1;
|
||||||
}else if(state.seletType.value == "1"){
|
} else if (state.seletType.value == "1") {
|
||||||
fingerprintType = 2;
|
fingerprintType = 2;
|
||||||
if(state.beginTimeTimestamp.value.isEmpty){
|
if (state.beginTimeTimestamp.value.isEmpty) {
|
||||||
Toast.show(msg: "请选择开始时间");
|
Toast.show(msg: "请选择开始时间");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if(state.endTimeTimestamp.value.isEmpty){
|
if (state.endTimeTimestamp.value.isEmpty) {
|
||||||
Toast.show(msg: "请选择开始时间");
|
Toast.show(msg: "请选择开始时间");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -35,25 +34,27 @@ class OtherTypeAddKeyLogic extends BaseGetXController {
|
|||||||
// return;
|
// return;
|
||||||
// }
|
// }
|
||||||
|
|
||||||
print("fasdfasdfasdf:${int.parse(state.beginTimeTimestamp.value)} == ${int.parse(state.endTimeTimestamp.value)}");
|
print(
|
||||||
if(int.parse(state.beginTimeTimestamp.value) >= int.parse(state.endTimeTimestamp.value)){
|
"fasdfasdfasdf:${int.parse(state.beginTimeTimestamp.value)} == ${int.parse(state.endTimeTimestamp.value)}");
|
||||||
|
if (int.parse(state.beginTimeTimestamp.value) >=
|
||||||
|
int.parse(state.endTimeTimestamp.value)) {
|
||||||
Toast.show(msg: "失效时间要大于生效时间");
|
Toast.show(msg: "失效时间要大于生效时间");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
startDate = state.beginTimeTimestamp.value;
|
startDate = state.beginTimeTimestamp.value;
|
||||||
endDate = state.endTimeTimestamp.value;
|
endDate = state.endTimeTimestamp.value;
|
||||||
}else if(state.seletType.value == "2"){
|
} else if (state.seletType.value == "2") {
|
||||||
if(state.effectiveDateTime.value <= 0){
|
if (state.effectiveDateTime.value <= 0) {
|
||||||
Toast.show(msg: "请选择生效时间");
|
Toast.show(msg: "请选择生效时间");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if(state.failureDateTime.value <= 0){
|
if (state.failureDateTime.value <= 0) {
|
||||||
Toast.show(msg: "请选择失效时间");
|
Toast.show(msg: "请选择失效时间");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(state.weekdaysList.value.isEmpty){
|
if (state.weekdaysList.value.isEmpty) {
|
||||||
Toast.show(msg: "请选择有效日");
|
Toast.show(msg: "请选择有效日");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -63,7 +64,7 @@ class OtherTypeAddKeyLogic extends BaseGetXController {
|
|||||||
// return;
|
// return;
|
||||||
// }
|
// }
|
||||||
|
|
||||||
if(state.effectiveDateTime.value >= state.failureDateTime.value){
|
if (state.effectiveDateTime.value >= state.failureDateTime.value) {
|
||||||
Toast.show(msg: "失效时间要大于生效时间");
|
Toast.show(msg: "失效时间要大于生效时间");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -81,7 +82,8 @@ class OtherTypeAddKeyLogic extends BaseGetXController {
|
|||||||
"endDate": endDate,
|
"endDate": endDate,
|
||||||
"addType": "1",
|
"addType": "1",
|
||||||
"cardName": state.nameController.text,
|
"cardName": state.nameController.text,
|
||||||
"cardNumber": (Random().nextInt(100000000) + 10000000).floor().toString(),
|
"cardNumber":
|
||||||
|
(Random().nextInt(100000000) + 10000000).floor().toString(),
|
||||||
"cardType": fingerprintType.toString(),
|
"cardType": fingerprintType.toString(),
|
||||||
"isCoerced": state.isStressFingerprint.value ? "1" : "2",
|
"isCoerced": state.isStressFingerprint.value ? "1" : "2",
|
||||||
"startDate": startDate,
|
"startDate": startDate,
|
||||||
@ -108,6 +110,20 @@ class OtherTypeAddKeyLogic extends BaseGetXController {
|
|||||||
break;
|
break;
|
||||||
case 1:
|
case 1:
|
||||||
// 指纹
|
// 指纹
|
||||||
|
Get.toNamed(Routers.addFingerprintPage, arguments: {
|
||||||
|
"lockId": state.lockId.value,
|
||||||
|
"endDate": endDate,
|
||||||
|
"addType": "1",
|
||||||
|
"fingerprintName": state.nameController.text,
|
||||||
|
"fingerprintNumber": "123456",
|
||||||
|
"fingerprintType": fingerprintType.toString(),
|
||||||
|
"isCoerced": state.isStressFingerprint.value ? "1" : "2",
|
||||||
|
"startDate": startDate,
|
||||||
|
"weekDay": state.weekdaysList.value,
|
||||||
|
"fromType": state.fromType.value,
|
||||||
|
});
|
||||||
|
|
||||||
|
/* 根据田总需求 无需tips页面 直接跳转到添加页面
|
||||||
Get.toNamed(Routers.addFingerprintTipPage, arguments: {
|
Get.toNamed(Routers.addFingerprintTipPage, arguments: {
|
||||||
"lockId": state.lockId.value,
|
"lockId": state.lockId.value,
|
||||||
"endDate": endDate,
|
"endDate": endDate,
|
||||||
@ -120,6 +136,7 @@ class OtherTypeAddKeyLogic extends BaseGetXController {
|
|||||||
"weekDay": state.weekdaysList.value,
|
"weekDay": state.weekdaysList.value,
|
||||||
"fromType": state.fromType.value,
|
"fromType": state.fromType.value,
|
||||||
});
|
});
|
||||||
|
*/
|
||||||
|
|
||||||
// var entity = await ApiRepository.to.addFingerprintsData(
|
// var entity = await ApiRepository.to.addFingerprintsData(
|
||||||
// lockId: state.lockId.value.toString(),
|
// lockId: state.lockId.value.toString(),
|
||||||
@ -138,34 +155,28 @@ class OtherTypeAddKeyLogic extends BaseGetXController {
|
|||||||
// }
|
// }
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
// 遥控
|
// 遥控
|
||||||
|
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
void onReady() {
|
void onReady() {
|
||||||
// TODO: implement onReady
|
// TODO: implement onReady
|
||||||
super.onReady();
|
super.onReady();
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
void onInit() {
|
void onInit() {
|
||||||
// TODO: implement onInit
|
// TODO: implement onInit
|
||||||
super.onInit();
|
super.onInit();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
void onClose() {
|
void onClose() {
|
||||||
// TODO: implement onClose
|
// TODO: implement onClose
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -5,6 +5,7 @@ import 'package:flutter_screenutil/flutter_screenutil.dart';
|
|||||||
import 'package:get/get.dart';
|
import 'package:get/get.dart';
|
||||||
import 'package:pull_to_refresh/pull_to_refresh.dart';
|
import 'package:pull_to_refresh/pull_to_refresh.dart';
|
||||||
import 'package:star_lock/app_settings/app_colors.dart';
|
import 'package:star_lock/app_settings/app_colors.dart';
|
||||||
|
import 'package:star_lock/tools/submitBtn.dart';
|
||||||
|
|
||||||
import '../../../appRouters.dart';
|
import '../../../appRouters.dart';
|
||||||
import '../../../baseWidget.dart';
|
import '../../../baseWidget.dart';
|
||||||
@ -99,7 +100,7 @@ class _StarLockMainPageState extends State<StarLockMainPage> with BaseWidget {
|
|||||||
|
|
||||||
Widget unHaveData() {
|
Widget unHaveData() {
|
||||||
return Column(
|
return Column(
|
||||||
mainAxisAlignment: MainAxisAlignment.center,
|
// mainAxisAlignment: MainAxisAlignment.center,
|
||||||
children: [
|
children: [
|
||||||
Row(
|
Row(
|
||||||
mainAxisAlignment: MainAxisAlignment.center,
|
mainAxisAlignment: MainAxisAlignment.center,
|
||||||
@ -107,6 +108,7 @@ class _StarLockMainPageState extends State<StarLockMainPage> with BaseWidget {
|
|||||||
Container(
|
Container(
|
||||||
width: 330.w,
|
width: 330.w,
|
||||||
height: 330.w,
|
height: 330.w,
|
||||||
|
margin: EdgeInsets.only(top: 180.h),
|
||||||
// decoration: BoxDecoration(
|
// decoration: BoxDecoration(
|
||||||
// border: Border.all(width: 4.w, color: AppColors.mainColor),
|
// border: Border.all(width: 4.w, color: AppColors.mainColor),
|
||||||
// borderRadius: BorderRadius.circular(110.w),
|
// borderRadius: BorderRadius.circular(110.w),
|
||||||
@ -133,11 +135,8 @@ class _StarLockMainPageState extends State<StarLockMainPage> with BaseWidget {
|
|||||||
)),
|
)),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
SizedBox(
|
|
||||||
height: h(50.h),
|
|
||||||
),
|
|
||||||
Container(
|
Container(
|
||||||
padding: EdgeInsets.all(30.w),
|
padding: EdgeInsets.only(top: 10.h),
|
||||||
child: Text(
|
child: Text(
|
||||||
TranslationLoader
|
TranslationLoader
|
||||||
.lanKeys!.whenAddingLockThePhoneMustBeNextToTheLock!.tr,
|
.lanKeys!.whenAddingLockThePhoneMustBeNextToTheLock!.tr,
|
||||||
@ -145,7 +144,11 @@ class _StarLockMainPageState extends State<StarLockMainPage> with BaseWidget {
|
|||||||
fontSize: 26.sp,
|
fontSize: 26.sp,
|
||||||
// fontWeight: FontWeight.w800,
|
// fontWeight: FontWeight.w800,
|
||||||
color: Colors.black),
|
color: Colors.black),
|
||||||
))
|
)),
|
||||||
|
SizedBox(
|
||||||
|
height: 200.h,
|
||||||
|
),
|
||||||
|
SubmitBtn(btnName: '演示模式')
|
||||||
],
|
],
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -12,10 +12,14 @@ import '../../translations/trans_lib.dart';
|
|||||||
// 网页的宏定义网址
|
// 网页的宏定义网址
|
||||||
class XSWebviewURLMacro {
|
class XSWebviewURLMacro {
|
||||||
static const baseWebURL = 'https://pre.lock.star-lock.cn:8093'; //baseURL
|
static const baseWebURL = 'https://pre.lock.star-lock.cn:8093'; //baseURL
|
||||||
static const userAgreementURL =
|
static const userAgreementURL = '$baseWebURL/app/userAgreement'; //用户协议
|
||||||
'$baseWebURL/page/detail?pageId=1&lang=cn'; //1用户协议
|
static const privacyPolicyURL = '$baseWebURL/app/privacy'; //隐私政策
|
||||||
static const privacyPolicyURL =
|
static const collectionListURL =
|
||||||
'$baseWebURL/page/detail?pageId=2&lang=cn'; //2隐私政策
|
'$baseWebURL/app/personalInformationCollectionList'; //个人信息收集清单
|
||||||
|
static const thirdPartyInfShareListURL =
|
||||||
|
'$baseWebURL/app/thirdPartyInformationSharingList'; //第三方信息共享清单
|
||||||
|
static const appPermissionDescURL =
|
||||||
|
'$baseWebURL/app/applicationPermissionDescription'; //应用权限说明
|
||||||
}
|
}
|
||||||
|
|
||||||
class AbountPage extends StatefulWidget {
|
class AbountPage extends StatefulWidget {
|
||||||
@ -66,7 +70,11 @@ class _AbountPageState extends State<AbountPage> {
|
|||||||
isHaveLine: false,
|
isHaveLine: false,
|
||||||
isHaveDirection: true,
|
isHaveDirection: true,
|
||||||
action: () {
|
action: () {
|
||||||
Toast.show(msg: "功能暂未开放");
|
Navigator.pushNamed(context, Routers.webviewShowPage,
|
||||||
|
arguments: {
|
||||||
|
"url": XSWebviewURLMacro.userAgreementURL,
|
||||||
|
"title": '介绍'
|
||||||
|
});
|
||||||
}),
|
}),
|
||||||
Divider(
|
Divider(
|
||||||
height: 1,
|
height: 1,
|
||||||
@ -117,7 +125,11 @@ class _AbountPageState extends State<AbountPage> {
|
|||||||
isHaveLine: false,
|
isHaveLine: false,
|
||||||
isHaveDirection: true,
|
isHaveDirection: true,
|
||||||
action: () {
|
action: () {
|
||||||
Toast.show(msg: "功能暂未开放");
|
Navigator.pushNamed(context, Routers.webviewShowPage,
|
||||||
|
arguments: {
|
||||||
|
"url": XSWebviewURLMacro.collectionListURL,
|
||||||
|
"title": '个人信息收集清单'
|
||||||
|
});
|
||||||
}),
|
}),
|
||||||
Divider(
|
Divider(
|
||||||
height: 1,
|
height: 1,
|
||||||
@ -132,7 +144,11 @@ class _AbountPageState extends State<AbountPage> {
|
|||||||
isHaveLine: false,
|
isHaveLine: false,
|
||||||
isHaveDirection: true,
|
isHaveDirection: true,
|
||||||
action: () {
|
action: () {
|
||||||
Toast.show(msg: "功能暂未开放");
|
Navigator.pushNamed(context, Routers.webviewShowPage,
|
||||||
|
arguments: {
|
||||||
|
"url": XSWebviewURLMacro.appPermissionDescURL,
|
||||||
|
"title": '应用权限说明'
|
||||||
|
});
|
||||||
}),
|
}),
|
||||||
Divider(
|
Divider(
|
||||||
height: 1,
|
height: 1,
|
||||||
@ -147,7 +163,11 @@ class _AbountPageState extends State<AbountPage> {
|
|||||||
isHaveLine: false,
|
isHaveLine: false,
|
||||||
isHaveDirection: true,
|
isHaveDirection: true,
|
||||||
action: () {
|
action: () {
|
||||||
Toast.show(msg: "功能暂未开放");
|
Navigator.pushNamed(context, Routers.webviewShowPage,
|
||||||
|
arguments: {
|
||||||
|
"url": XSWebviewURLMacro.thirdPartyInfShareListURL,
|
||||||
|
"title": '第三方信息共享清单'
|
||||||
|
});
|
||||||
}),
|
}),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
|
|||||||
23
star_lock/lib/mine/addLock/addLock/addLock_logic.dart
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
import 'package:star_lock/mine/addLock/addLock/addLock_state.dart';
|
||||||
|
import 'package:star_lock/tools/baseGetXController.dart';
|
||||||
|
|
||||||
|
class AddLockLogic extends BaseGetXController {
|
||||||
|
final AddLockState state = AddLockState();
|
||||||
|
|
||||||
|
@override
|
||||||
|
void onReady() {
|
||||||
|
// TODO: implement onReady
|
||||||
|
super.onReady();
|
||||||
|
}
|
||||||
|
|
||||||
|
@override
|
||||||
|
void onInit() {
|
||||||
|
// TODO: implement onInit
|
||||||
|
super.onInit();
|
||||||
|
}
|
||||||
|
|
||||||
|
@override
|
||||||
|
void onClose() {
|
||||||
|
// TODO: implement onClose
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -4,6 +4,7 @@ import 'package:flutter/material.dart';
|
|||||||
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
||||||
import 'package:get/get.dart';
|
import 'package:get/get.dart';
|
||||||
import 'package:permission_handler/permission_handler.dart';
|
import 'package:permission_handler/permission_handler.dart';
|
||||||
|
import 'package:star_lock/mine/addLock/addLock/addLock_logic.dart';
|
||||||
|
|
||||||
import '../../../appRouters.dart';
|
import '../../../appRouters.dart';
|
||||||
import '../../../app_settings/app_colors.dart';
|
import '../../../app_settings/app_colors.dart';
|
||||||
@ -20,6 +21,9 @@ class AddLockPage extends StatefulWidget {
|
|||||||
}
|
}
|
||||||
|
|
||||||
class _AddLockPageState extends State<AddLockPage> with BaseWidget {
|
class _AddLockPageState extends State<AddLockPage> with BaseWidget {
|
||||||
|
final logic = Get.put(AddLockLogic());
|
||||||
|
final state = Get.find<AddLockLogic>().state;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return Scaffold(
|
return Scaffold(
|
||||||
@ -49,11 +53,11 @@ class _AddLockPageState extends State<AddLockPage> with BaseWidget {
|
|||||||
SizedBox(
|
SizedBox(
|
||||||
height: 120.h,
|
height: 120.h,
|
||||||
),
|
),
|
||||||
Image.asset(
|
Obx(() => Image.asset(
|
||||||
'images/lockType/addLock_touchScreen.png',
|
state.lockTypeImg.value,
|
||||||
width: 278.w,
|
width: 278.w,
|
||||||
height: 278.w,
|
height: 278.w,
|
||||||
),
|
)),
|
||||||
SizedBox(
|
SizedBox(
|
||||||
height: 120.h,
|
height: 120.h,
|
||||||
),
|
),
|
||||||
@ -73,17 +77,16 @@ class _AddLockPageState extends State<AddLockPage> with BaseWidget {
|
|||||||
btnName: TranslationLoader.lanKeys!.next!.tr,
|
btnName: TranslationLoader.lanKeys!.next!.tr,
|
||||||
borderRadius: 20.w,
|
borderRadius: 20.w,
|
||||||
onClick: () {
|
onClick: () {
|
||||||
if(Platform.isIOS){
|
if (Platform.isIOS) {
|
||||||
Navigator.pushNamed(context, Routers.nearbyLockPage);
|
Navigator.pushNamed(context, Routers.nearbyLockPage);
|
||||||
}else {
|
} else {
|
||||||
getMicrophonePermission()
|
getMicrophonePermission().then((value) {
|
||||||
.then((value) {
|
|
||||||
if (value) {
|
if (value) {
|
||||||
// 有权限
|
// 有权限
|
||||||
Navigator.pushNamed(context, Routers.nearbyLockPage);
|
Navigator.pushNamed(context, Routers.nearbyLockPage);
|
||||||
}else{
|
} else {
|
||||||
//没有权限
|
//没有权限
|
||||||
openAppSettings();//打开app系统设置
|
openAppSettings(); //打开app系统设置
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
29
star_lock/lib/mine/addLock/addLock/addLock_state.dart
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
import 'package:get/get.dart';
|
||||||
|
|
||||||
|
class AddLockState {
|
||||||
|
var getLockType = 1.obs; //0-所有锁;1-门锁;2-NFC无源锁;3-挂锁;4-保险箱锁;5-车位锁;6-智能门禁;7-网关
|
||||||
|
var lockTypeImg = 'images/lockType/addLock_touchScreen.png'.obs; //不同类型锁图片更换
|
||||||
|
|
||||||
|
AddLockState() {
|
||||||
|
Map map = Get.arguments;
|
||||||
|
if (map.isNotEmpty) {
|
||||||
|
if (map["getLockType"] != null) {
|
||||||
|
getLockType.value = map["getLockType"];
|
||||||
|
//保险箱锁
|
||||||
|
if (getLockType.value == 4) {
|
||||||
|
lockTypeImg.value = "images/lockType/addLock_safeBg.png";
|
||||||
|
} else if (getLockType.value == 5) {
|
||||||
|
//车位锁
|
||||||
|
lockTypeImg.value = "images/lockType/addLock_parkingBg.png";
|
||||||
|
} else if (getLockType.value == 6) {
|
||||||
|
//智能门禁
|
||||||
|
lockTypeImg.value = "images/lockType/addLock_entranceGuardBg.png";
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
lockTypeImg.value = 'images/lockType/addLock_touchScreen.png';
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
lockTypeImg.value = 'images/lockType/addLock_touchScreen.png';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -1,6 +1,9 @@
|
|||||||
|
import 'dart:io';
|
||||||
|
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
||||||
import 'package:get/get.dart';
|
import 'package:get/get.dart';
|
||||||
|
import 'package:permission_handler/permission_handler.dart';
|
||||||
|
|
||||||
import '../../../appRouters.dart';
|
import '../../../appRouters.dart';
|
||||||
import '../../../app_settings/app_colors.dart';
|
import '../../../app_settings/app_colors.dart';
|
||||||
@ -40,33 +43,34 @@ class _SeletLockTypePageState extends State<SeletLockTypePage> with BaseWidget {
|
|||||||
children: [
|
children: [
|
||||||
lockTypeItem('images/lockType/lockType_doorLock.png',
|
lockTypeItem('images/lockType/lockType_doorLock.png',
|
||||||
TranslationLoader.lanKeys!.doorLock!.tr, () {
|
TranslationLoader.lanKeys!.doorLock!.tr, () {
|
||||||
Navigator.pushNamed(context, Routers.addLockPage);
|
Navigator.pushNamed(context, Routers.addLockPage,
|
||||||
|
arguments: {'getLockType': 1});
|
||||||
}),
|
}),
|
||||||
lockTypeItem('images/lockType/lockType_NFCLock.png',
|
lockTypeItem('images/lockType/lockType_NFCLock.png',
|
||||||
TranslationLoader.lanKeys!.NFCPassiveLock!.tr, () {
|
TranslationLoader.lanKeys!.NFCPassiveLock!.tr, () {
|
||||||
// Navigator.pushNamed(context, Routers.addLockPage);
|
// Navigator.pushNamed(context, Routers.addLockPage);
|
||||||
Toast.show(msg: "功能暂未开放");
|
getNearByLimits();
|
||||||
}),
|
}),
|
||||||
lockTypeItem('images/lockType/lockType_padlock.png',
|
lockTypeItem('images/lockType/lockType_padlock.png',
|
||||||
TranslationLoader.lanKeys!.padlock!.tr, () {
|
TranslationLoader.lanKeys!.padlock!.tr, () {
|
||||||
// Navigator.pushNamed(context, Routers.addLockPage);
|
// Navigator.pushNamed(context, Routers.addLockPage);
|
||||||
Toast.show(msg: "功能暂未开放");
|
getNearByLimits();
|
||||||
}),
|
}),
|
||||||
lockTypeItem('images/lockType/lockType_safeLock.png',
|
lockTypeItem('images/lockType/lockType_safeLock.png',
|
||||||
TranslationLoader.lanKeys!.safeLock!.tr, () {
|
TranslationLoader.lanKeys!.safeLock!.tr, () {
|
||||||
// Navigator.pushNamed(context, Routers.addLockPage);
|
Navigator.pushNamed(context, Routers.addLockPage,
|
||||||
Toast.show(msg: "功能暂未开放");
|
arguments: {'getLockType': 4});
|
||||||
}),
|
}),
|
||||||
lockTypeItem('images/lockType/lockType_parkingLock.png',
|
lockTypeItem('images/lockType/lockType_parkingLock.png',
|
||||||
TranslationLoader.lanKeys!.parkingLock!.tr, () {
|
TranslationLoader.lanKeys!.parkingLock!.tr, () {
|
||||||
// Navigator.pushNamed(context, Routers.addLockPage);
|
Navigator.pushNamed(context, Routers.addLockPage,
|
||||||
Toast.show(msg: "功能暂未开放");
|
arguments: {'getLockType': 5});
|
||||||
}),
|
}),
|
||||||
lockTypeItem('images/lockType/lockType_entranceGuardLock.png',
|
lockTypeItem('images/lockType/lockType_entranceGuardLock.png',
|
||||||
TranslationLoader.lanKeys!.itelligentAccessControl!.tr,
|
TranslationLoader.lanKeys!.itelligentAccessControl!.tr,
|
||||||
() {
|
() {
|
||||||
// Navigator.pushNamed(context, Routers.addLockPage);
|
Navigator.pushNamed(context, Routers.addLockPage,
|
||||||
Toast.show(msg: "功能暂未开放");
|
arguments: {'getLockType': 6});
|
||||||
}),
|
}),
|
||||||
|
|
||||||
// lockTypeItem('images/lockType/lockType_bicycleLock.png',
|
// lockTypeItem('images/lockType/lockType_bicycleLock.png',
|
||||||
@ -76,7 +80,7 @@ class _SeletLockTypePageState extends State<SeletLockTypePage> with BaseWidget {
|
|||||||
lockTypeItem('images/lockType/lockType_gatewayLock.png',
|
lockTypeItem('images/lockType/lockType_gatewayLock.png',
|
||||||
TranslationLoader.lanKeys!.gateway!.tr, () {
|
TranslationLoader.lanKeys!.gateway!.tr, () {
|
||||||
// Navigator.pushNamed(context, Routers.gatewayListPage);
|
// Navigator.pushNamed(context, Routers.gatewayListPage);
|
||||||
Toast.show(msg: "功能暂未开放");
|
getNearByLimits();
|
||||||
}),
|
}),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
@ -90,7 +94,8 @@ class _SeletLockTypePageState extends State<SeletLockTypePage> with BaseWidget {
|
|||||||
Widget allLock() {
|
Widget allLock() {
|
||||||
return GestureDetector(
|
return GestureDetector(
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Navigator.pushNamed(context, Routers.addLockPage);
|
Navigator.pushNamed(context, Routers.addLockPage,
|
||||||
|
arguments: {'getLockType': 0});
|
||||||
},
|
},
|
||||||
child: Container(
|
child: Container(
|
||||||
height: 150.h,
|
height: 150.h,
|
||||||
@ -174,6 +179,41 @@ class _SeletLockTypePageState extends State<SeletLockTypePage> with BaseWidget {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//跳转到附近的锁页面先判断权限
|
||||||
|
void getNearByLimits() {
|
||||||
|
if (Platform.isIOS) {
|
||||||
|
Navigator.pushNamed(context, Routers.nearbyLockPage);
|
||||||
|
} else {
|
||||||
|
getMicrophonePermission().then((value) {
|
||||||
|
if (value) {
|
||||||
|
// 有权限
|
||||||
|
Navigator.pushNamed(context, Routers.nearbyLockPage);
|
||||||
|
} else {
|
||||||
|
//没有权限
|
||||||
|
openAppSettings(); //打开app系统设置
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
///请求权限
|
||||||
|
Future<bool> getMicrophonePermission() async {
|
||||||
|
// You can request multiple permissions at once.
|
||||||
|
Map<Permission, PermissionStatus> statuses = await [
|
||||||
|
Permission.bluetoothScan,
|
||||||
|
Permission.bluetoothConnect,
|
||||||
|
Permission.location,
|
||||||
|
].request();
|
||||||
|
|
||||||
|
//granted 通过,denied 被拒绝,permanentlyDenied 拒绝且不在提示
|
||||||
|
if (statuses[Permission.bluetoothScan]!.isGranted &&
|
||||||
|
statuses[Permission.bluetoothConnect]!.isGranted &&
|
||||||
|
statuses[Permission.location]!.isGranted) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
void onShow() {}
|
void onShow() {}
|
||||||
|
|
||||||
void onHide() {}
|
void onHide() {}
|
||||||
|
|||||||
@ -1,6 +1,7 @@
|
|||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
||||||
import 'package:get/get.dart';
|
import 'package:get/get.dart';
|
||||||
|
import 'package:star_lock/tools/noData.dart';
|
||||||
|
|
||||||
import '../../appRouters.dart';
|
import '../../appRouters.dart';
|
||||||
import '../../app_settings/app_colors.dart';
|
import '../../app_settings/app_colors.dart';
|
||||||
@ -15,6 +16,7 @@ class MessageListPage extends StatefulWidget {
|
|||||||
}
|
}
|
||||||
|
|
||||||
class _MessageListPageState extends State<MessageListPage> {
|
class _MessageListPageState extends State<MessageListPage> {
|
||||||
|
List dataList = [];
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return Scaffold(
|
return Scaffold(
|
||||||
@ -23,14 +25,17 @@ class _MessageListPageState extends State<MessageListPage> {
|
|||||||
barTitle: TranslationLoader.lanKeys!.message!.tr,
|
barTitle: TranslationLoader.lanKeys!.message!.tr,
|
||||||
haveBack: true,
|
haveBack: true,
|
||||||
backgroundColor: AppColors.mainColor),
|
backgroundColor: AppColors.mainColor),
|
||||||
body: ListView.builder(
|
body: dataList.isEmpty
|
||||||
itemCount: 10,
|
? const NoData()
|
||||||
itemBuilder: (c, index) {
|
: ListView.builder(
|
||||||
return _seletGatewayListListItem(
|
itemCount: 10,
|
||||||
'images/controls_user.png', "您的钥匙已发送成功", "2023.6.21 11.15", () {
|
itemBuilder: (c, index) {
|
||||||
// Navigator.pushNamed(context, Routers.gatewayConfigurationWifiPage);
|
return _seletGatewayListListItem(
|
||||||
});
|
'images/controls_user.png', "您的钥匙已发送成功", "2023.6.21 11.15",
|
||||||
}),
|
() {
|
||||||
|
// Navigator.pushNamed(context, Routers.gatewayConfigurationWifiPage);
|
||||||
|
});
|
||||||
|
}),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -136,8 +136,8 @@ class _StarLockMinePageState extends State<StarLockMinePage> with BaseWidget {
|
|||||||
// }),
|
// }),
|
||||||
mineItem('images/mine/icon_mine_main_message.png',
|
mineItem('images/mine/icon_mine_main_message.png',
|
||||||
TranslationLoader.lanKeys!.message!.tr, () {
|
TranslationLoader.lanKeys!.message!.tr, () {
|
||||||
// Navigator.pushNamed(context, Routers.messageListPage);
|
Navigator.pushNamed(context, Routers.messageListPage);
|
||||||
Toast.show(msg: "功能暂未开放");
|
// Toast.show(msg: "功能暂未开放");
|
||||||
}),
|
}),
|
||||||
//删除“客服”行
|
//删除“客服”行
|
||||||
// mineItem('images/mine/icon_mine_main_supportStaff.png',
|
// mineItem('images/mine/icon_mine_main_supportStaff.png',
|
||||||
|
|||||||
@ -0,0 +1,124 @@
|
|||||||
|
import 'package:flutter/cupertino.dart';
|
||||||
|
import 'package:get/get.dart';
|
||||||
|
import 'package:star_lock/appRouters.dart';
|
||||||
|
import 'package:star_lock/mine/mineSet/addAuthorizedAdministrator/AddAuthorizedAdministrator_state.dart';
|
||||||
|
import 'package:star_lock/network/api_repository.dart';
|
||||||
|
import 'package:star_lock/tools/baseGetXController.dart';
|
||||||
|
import 'package:star_lock/tools/toast.dart';
|
||||||
|
import 'package:star_lock/translations/trans_lib.dart';
|
||||||
|
|
||||||
|
class AddAuthorizedAdministratorLogic extends BaseGetXController {
|
||||||
|
final AddAuthorizedAdministratorState state =
|
||||||
|
AddAuthorizedAdministratorState();
|
||||||
|
|
||||||
|
//发送批量授权管理员
|
||||||
|
Future<void> addAuthorizedAdminRequest() async {
|
||||||
|
String getFailureDateTime = '0';
|
||||||
|
String getEffectiveDateTime = '0';
|
||||||
|
if (state.tabController!.index == 1) {
|
||||||
|
getFailureDateTime =
|
||||||
|
state.failureDateTime.value.millisecondsSinceEpoch.toString();
|
||||||
|
getEffectiveDateTime =
|
||||||
|
state.effectiveDateTime.value.millisecondsSinceEpoch.toString();
|
||||||
|
}
|
||||||
|
var entity = await ApiRepository.to.addAuthorizedAdmin(
|
||||||
|
state.isCreateUser.value ? "1" : "0",
|
||||||
|
getFailureDateTime,
|
||||||
|
state.isRemoteUnlock.value == true ? '1' : '2',
|
||||||
|
[],
|
||||||
|
state.lockIdList,
|
||||||
|
state.keyNameController.text,
|
||||||
|
getEffectiveDateTime,
|
||||||
|
state.emailOrPhoneController.text,
|
||||||
|
state.countryCode.value,
|
||||||
|
'1',
|
||||||
|
);
|
||||||
|
if (entity.errorCode!.codeIsSuccessful) {
|
||||||
|
print('发送电子钥匙成功');
|
||||||
|
state.isSendSuccess.value = true;
|
||||||
|
} else {
|
||||||
|
Toast.show(msg: '${entity.errorMsg}');
|
||||||
|
if (entity.errorCode == 425) {
|
||||||
|
//用户未注册
|
||||||
|
state.isCreateUser.value = true;
|
||||||
|
addAuthorizedAdminRequest();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//发送钥匙请求
|
||||||
|
Future<void> sendElectronicKeyRequest(BuildContext widgetContext) async {
|
||||||
|
String getFailureDateTime = '0';
|
||||||
|
String getEffectiveDateTime = '0';
|
||||||
|
String lockID = state.keyInfo.value.lockId.toString();
|
||||||
|
String getKeyType = (int.parse(state.type.value) + 1).toString();
|
||||||
|
if (state.type.value == '0') {
|
||||||
|
getFailureDateTime =
|
||||||
|
state.failureDateTime.value.millisecondsSinceEpoch.toString();
|
||||||
|
getEffectiveDateTime =
|
||||||
|
state.effectiveDateTime.value.millisecondsSinceEpoch.toString();
|
||||||
|
}
|
||||||
|
|
||||||
|
var entity = await ApiRepository.to.sendElectronicKey(
|
||||||
|
createUser: state.isCreateUser.value ? "1" : "0",
|
||||||
|
countryCode: state.countryCode.value,
|
||||||
|
usernameType: '1',
|
||||||
|
endDate: getFailureDateTime,
|
||||||
|
faceAuthentication: state.isAuthentication.value == true ? '1' : '2',
|
||||||
|
isCameraEnable: '2',
|
||||||
|
isRemoteUnlock: state.isRemoteUnlock.value == true ? '1' : '2',
|
||||||
|
keyNameForAdmin: state.keyNameController.text,
|
||||||
|
keyRight: '0',
|
||||||
|
keyType: getKeyType,
|
||||||
|
lockId: lockID,
|
||||||
|
operatorUid: '',
|
||||||
|
receiverUsername: state.emailOrPhoneController.text,
|
||||||
|
remarks: '',
|
||||||
|
startDate: getEffectiveDateTime,
|
||||||
|
weekDays: state.weekdaysList);
|
||||||
|
if (entity.errorCode!.codeIsSuccessful) {
|
||||||
|
print('发送电子钥匙成功');
|
||||||
|
state.isSendSuccess.value = true;
|
||||||
|
} else {
|
||||||
|
if (entity.errorCode == 425) {
|
||||||
|
//用户未注册
|
||||||
|
_showDialog(widgetContext, '${entity.errorMsg}');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//用户未注册确认弹窗
|
||||||
|
void _showDialog(widgetContext, String errMsg) {
|
||||||
|
showCupertinoDialog(
|
||||||
|
context: widgetContext,
|
||||||
|
builder: (context) {
|
||||||
|
return CupertinoAlertDialog(
|
||||||
|
title: const Text('接收者号码未注册,请选择号码所在的国家并重新发送'),
|
||||||
|
actions: [
|
||||||
|
CupertinoDialogAction(
|
||||||
|
child: Text(TranslationLoader.lanKeys!.cancel!.tr),
|
||||||
|
onPressed: () {
|
||||||
|
Navigator.of(context).pop();
|
||||||
|
},
|
||||||
|
),
|
||||||
|
CupertinoDialogAction(
|
||||||
|
child: Text(TranslationLoader.lanKeys!.selet!.tr),
|
||||||
|
onPressed: () async {
|
||||||
|
//选择国家代码
|
||||||
|
state.isCreateUser.value = true;
|
||||||
|
Navigator.of(context).pop();
|
||||||
|
|
||||||
|
var result = await Get.toNamed(Routers.seletCountryRegionPage);
|
||||||
|
if (result != null) {
|
||||||
|
result as Map<String, dynamic>;
|
||||||
|
state.countryCode.value = result['code'];
|
||||||
|
state.countryName.value = result['countryName'];
|
||||||
|
}
|
||||||
|
},
|
||||||
|
),
|
||||||
|
],
|
||||||
|
);
|
||||||
|
},
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,39 @@
|
|||||||
|
import 'package:flutter/material.dart';
|
||||||
|
import 'package:flutter_native_contact_picker/flutter_native_contact_picker.dart';
|
||||||
|
import 'package:get/get.dart';
|
||||||
|
import 'package:star_lock/main/lockMian/entity/lockInfoEntity.dart';
|
||||||
|
|
||||||
|
class AddAuthorizedAdministratorState {
|
||||||
|
late TabController? tabController;
|
||||||
|
TextEditingController emailOrPhoneController =
|
||||||
|
TextEditingController(); //邮箱/手机号输入框
|
||||||
|
TextEditingController keyNameController = TextEditingController(); //钥匙名输入框
|
||||||
|
|
||||||
|
final FlutterContactPicker contactPicker = FlutterContactPicker();
|
||||||
|
late Contact contact;
|
||||||
|
var type = ''.obs;
|
||||||
|
var lockIdList = [].obs;
|
||||||
|
var weekdaysList = [].obs;
|
||||||
|
var isCreateUser = false.obs; //用户未注册时传1 已注册传0
|
||||||
|
var selectEffectiveDate =
|
||||||
|
'${DateTime.now().year}-${DateTime.now().month}-${DateTime.now().day} ${DateTime.now().hour}:${DateTime.now().minute}'
|
||||||
|
.obs; //默认为当前时间
|
||||||
|
var selectFailureDate =
|
||||||
|
'${DateTime.now().year}-${DateTime.now().month}-${DateTime.now().day} ${DateTime.now().hour}:${DateTime.now().minute}'
|
||||||
|
.obs; //默认为当前时间
|
||||||
|
final effectiveDateTime = DateTime.now().obs;
|
||||||
|
final failureDateTime = DateTime.now().obs;
|
||||||
|
var countryName = '中国'.obs;
|
||||||
|
var countryCode = '86'.obs;
|
||||||
|
var isSendSuccess = false.obs;
|
||||||
|
final isRemoteUnlock = false.obs; //是否允许远程开锁
|
||||||
|
final isAuthentication = false.obs; //是否允许实名认证
|
||||||
|
final keyInfo = KeyInfos().obs;
|
||||||
|
final lockMainEntity = LockMainEntity().obs;
|
||||||
|
|
||||||
|
AddAuthorizedAdministratorState() {
|
||||||
|
Map map = Get.arguments;
|
||||||
|
lockMainEntity.value = map["lockMainEntity"];
|
||||||
|
keyInfo.value = map["keyInfo"];
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -6,6 +6,7 @@ import 'package:star_lock/appRouters.dart';
|
|||||||
import 'package:star_lock/app_settings/app_colors.dart';
|
import 'package:star_lock/app_settings/app_colors.dart';
|
||||||
import 'package:star_lock/main/lockDetail/electronicKey/massSendElectronicKey/massSendLockGroupList/massSendLockGroupListEntity.dart';
|
import 'package:star_lock/main/lockDetail/electronicKey/massSendElectronicKey/massSendLockGroupList/massSendLockGroupListEntity.dart';
|
||||||
import 'package:star_lock/tools/ExpandedListView.dart';
|
import 'package:star_lock/tools/ExpandedListView.dart';
|
||||||
|
import 'package:star_lock/tools/noData.dart';
|
||||||
import 'package:star_lock/tools/submitBtn.dart';
|
import 'package:star_lock/tools/submitBtn.dart';
|
||||||
import 'package:star_lock/translations/trans_lib.dart';
|
import 'package:star_lock/translations/trans_lib.dart';
|
||||||
|
|
||||||
@ -28,6 +29,7 @@ class _AuthorityManagementPageState extends State<AuthorityManagementPage>
|
|||||||
bool isDeviceSelect = false;
|
bool isDeviceSelect = false;
|
||||||
int selectDeviceIndex = 0;
|
int selectDeviceIndex = 0;
|
||||||
int selectNameIndex = 0;
|
int selectNameIndex = 0;
|
||||||
|
List dataList = [];
|
||||||
|
|
||||||
List tabs = [
|
List tabs = [
|
||||||
TranslationLoader.lanKeys!.name!.tr,
|
TranslationLoader.lanKeys!.name!.tr,
|
||||||
@ -83,9 +85,10 @@ class _AuthorityManagementPageState extends State<AuthorityManagementPage>
|
|||||||
)),
|
)),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
body: TabBarView(
|
body: TabBarView(controller: _tabController, children: [
|
||||||
controller: _tabController,
|
dataList.isEmpty ? const NoData() : _permissionNameList(),
|
||||||
children: [_permissionNameList(), _permissionDeviceList()])));
|
dataList.isEmpty ? const NoData() : _permissionDeviceList()
|
||||||
|
])));
|
||||||
}
|
}
|
||||||
|
|
||||||
//姓名列表
|
//姓名列表
|
||||||
|
|||||||
@ -4,6 +4,7 @@ import 'package:get/get.dart';
|
|||||||
import 'package:star_lock/mine/mineSet/authorizedAdministrator/authorizedAdminListEntity.dart';
|
import 'package:star_lock/mine/mineSet/authorizedAdministrator/authorizedAdminListEntity.dart';
|
||||||
import 'package:star_lock/network/api_repository.dart';
|
import 'package:star_lock/network/api_repository.dart';
|
||||||
import 'package:star_lock/tools/baseGetXController.dart';
|
import 'package:star_lock/tools/baseGetXController.dart';
|
||||||
|
import 'package:star_lock/tools/noData.dart';
|
||||||
|
|
||||||
import '../../../../appRouters.dart';
|
import '../../../../appRouters.dart';
|
||||||
import '../../../../app_settings/app_colors.dart';
|
import '../../../../app_settings/app_colors.dart';
|
||||||
@ -131,12 +132,14 @@ class _AuthorizedAdministratorListPageState
|
|||||||
}
|
}
|
||||||
|
|
||||||
Widget _buildMainUI(List itemList) {
|
Widget _buildMainUI(List itemList) {
|
||||||
return ListView.builder(
|
return itemList.isEmpty
|
||||||
itemCount: itemList.length,
|
? const NoData()
|
||||||
itemBuilder: (c, index) {
|
: ListView.builder(
|
||||||
AuthorizedAdminListItem itemData = itemList[index];
|
itemCount: itemList.length,
|
||||||
return _electronicKeyItem(itemData);
|
itemBuilder: (c, index) {
|
||||||
});
|
AuthorizedAdminListItem itemData = itemList[index];
|
||||||
|
return _electronicKeyItem(itemData);
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
Widget _electronicKeyItem(AuthorizedAdminListItem itemData) {
|
Widget _electronicKeyItem(AuthorizedAdminListItem itemData) {
|
||||||
|
|||||||
@ -2,6 +2,7 @@ import 'package:flutter/material.dart';
|
|||||||
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
||||||
import 'package:get/get.dart';
|
import 'package:get/get.dart';
|
||||||
import 'package:star_lock/main/lockDetail/electronicKey/massSendElectronicKey/massSendLockGroupList/massSendLockGroupListEntity.dart';
|
import 'package:star_lock/main/lockDetail/electronicKey/massSendElectronicKey/massSendLockGroupList/massSendLockGroupListEntity.dart';
|
||||||
|
import 'package:star_lock/tools/noData.dart';
|
||||||
|
|
||||||
import '../../../../../app_settings/app_colors.dart';
|
import '../../../../../app_settings/app_colors.dart';
|
||||||
import '../../../../../tools/titleAppBar.dart';
|
import '../../../../../tools/titleAppBar.dart';
|
||||||
@ -55,7 +56,7 @@ class _LockItemListPageState extends State<LockItemListPage> {
|
|||||||
);
|
);
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
: Container(),
|
: const NoData(),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -4,6 +4,7 @@ import 'package:get/get.dart';
|
|||||||
import 'package:star_lock/main/lockDetail/electronicKey/massSendElectronicKey/massSendLockGroupList/lockUserList/lockUserListEntity.dart';
|
import 'package:star_lock/main/lockDetail/electronicKey/massSendElectronicKey/massSendLockGroupList/lockUserList/lockUserListEntity.dart';
|
||||||
import 'package:star_lock/network/api_repository.dart';
|
import 'package:star_lock/network/api_repository.dart';
|
||||||
import 'package:star_lock/tools/baseGetXController.dart';
|
import 'package:star_lock/tools/baseGetXController.dart';
|
||||||
|
import 'package:star_lock/tools/noData.dart';
|
||||||
|
|
||||||
import '../../../../appRouters.dart';
|
import '../../../../appRouters.dart';
|
||||||
import '../../../../app_settings/app_colors.dart';
|
import '../../../../app_settings/app_colors.dart';
|
||||||
@ -119,19 +120,21 @@ class _LockUserManageListPageState extends State<LockUserManageListPage> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
Widget _buildMainUI() {
|
Widget _buildMainUI() {
|
||||||
return ListView.separated(
|
return dataList.isEmpty
|
||||||
itemCount: dataList.length,
|
? const NoData()
|
||||||
itemBuilder: (c, index) {
|
: ListView.separated(
|
||||||
LockUserData indexEntity = dataList[index];
|
itemCount: dataList.length,
|
||||||
return _electronicKeyItem(indexEntity);
|
itemBuilder: (c, index) {
|
||||||
},
|
LockUserData indexEntity = dataList[index];
|
||||||
separatorBuilder: (BuildContext context, int index) {
|
return _electronicKeyItem(indexEntity);
|
||||||
return const Divider(
|
},
|
||||||
height: 1,
|
separatorBuilder: (BuildContext context, int index) {
|
||||||
color: AppColors.greyLineColor,
|
return const Divider(
|
||||||
);
|
height: 1,
|
||||||
},
|
color: AppColors.greyLineColor,
|
||||||
);
|
);
|
||||||
|
},
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
//请求锁用户列表
|
//请求锁用户列表
|
||||||
|
|||||||
@ -93,15 +93,15 @@ class _MineSetPageState extends State<MineSetPage> {
|
|||||||
Navigator.pushNamed(
|
Navigator.pushNamed(
|
||||||
context, Routers.authorizedAdministratorListPage);
|
context, Routers.authorizedAdministratorListPage);
|
||||||
}),
|
}),
|
||||||
//by DaisyWu 新增--权限管理
|
//by DaisyWu 新增--批量授权
|
||||||
CommonItem(
|
CommonItem(
|
||||||
leftTitel: TranslationLoader.lanKeys!.authorityManagement!.tr,
|
leftTitel: TranslationLoader.lanKeys!.authorityManagement!.tr,
|
||||||
rightTitle: "",
|
rightTitle: "",
|
||||||
isHaveLine: true,
|
isHaveLine: true,
|
||||||
isHaveDirection: true,
|
isHaveDirection: true,
|
||||||
action: () {
|
action: () {
|
||||||
// Navigator.pushNamed(context, Routers.authorityManagementPage);
|
Navigator.pushNamed(context, Routers.authorityManagementPage);
|
||||||
Toast.show(msg: "功能暂未开放");
|
// Toast.show(msg: "功能暂未开放");
|
||||||
}),
|
}),
|
||||||
CommonItem(
|
CommonItem(
|
||||||
leftTitel: TranslationLoader.lanKeys!.lockGroup!.tr,
|
leftTitel: TranslationLoader.lanKeys!.lockGroup!.tr,
|
||||||
|
|||||||
@ -31,59 +31,51 @@ class _ValueAddedServicesPageListState
|
|||||||
_valueAddedServicesItem(
|
_valueAddedServicesItem(
|
||||||
Image.asset('images/mine/icon_mine_valueAddedServices_note.png'),
|
Image.asset('images/mine/icon_mine_valueAddedServices_note.png'),
|
||||||
TranslationLoader.lanKeys!.note!.tr, () {
|
TranslationLoader.lanKeys!.note!.tr, () {
|
||||||
Toast.show(msg: "功能暂未开放");
|
Navigator.pushNamed(
|
||||||
// Navigator.pushNamed(
|
context, Routers.valueAddedServicesNoteAndEmailDetailPage,
|
||||||
// context, Routers.valueAddedServicesNoteAndEmailDetailPage,
|
arguments: 1);
|
||||||
// arguments: 1);
|
|
||||||
}),
|
}),
|
||||||
_valueAddedServicesItem(
|
_valueAddedServicesItem(
|
||||||
Image.asset('images/mine/icon_mine_valueAddedServices_email.png'),
|
Image.asset('images/mine/icon_mine_valueAddedServices_email.png'),
|
||||||
TranslationLoader.lanKeys!.mail!.tr, () {
|
TranslationLoader.lanKeys!.mail!.tr, () {
|
||||||
Toast.show(msg: "功能暂未开放");
|
Navigator.pushNamed(
|
||||||
// Navigator.pushNamed(
|
context, Routers.valueAddedServicesNoteAndEmailDetailPage,
|
||||||
// context, Routers.valueAddedServicesNoteAndEmailDetailPage,
|
arguments: 2);
|
||||||
// arguments: 2);
|
|
||||||
}),
|
}),
|
||||||
_valueAddedServicesItem(
|
_valueAddedServicesItem(
|
||||||
Image.asset(
|
Image.asset(
|
||||||
'images/mine/icon_mine_valueAddedServices_realName.png'),
|
'images/mine/icon_mine_valueAddedServices_realName.png'),
|
||||||
TranslationLoader.lanKeys!.realNameAuthentication!.tr, () {
|
TranslationLoader.lanKeys!.realNameAuthentication!.tr, () {
|
||||||
Toast.show(msg: "功能暂未开放");
|
Navigator.pushNamed(
|
||||||
// Navigator.pushNamed(
|
context, Routers.valueAddedServicesRealNamePage);
|
||||||
// context, Routers.valueAddedServicesRealNamePage);
|
|
||||||
}),
|
}),
|
||||||
_valueAddedServicesItem(
|
_valueAddedServicesItem(
|
||||||
Image.asset('images/mine/icon_mine_valueAddedServices_vip.png'),
|
Image.asset('images/mine/icon_mine_valueAddedServices_vip.png'),
|
||||||
TranslationLoader.lanKeys!.advancedFunction!.tr, () {
|
TranslationLoader.lanKeys!.advancedFunction!.tr, () {
|
||||||
Toast.show(msg: "功能暂未开放");
|
Navigator.pushNamed(
|
||||||
// Navigator.pushNamed(
|
context, Routers.valueAddedServicesHighFunctionPage);
|
||||||
// context, Routers.valueAddedServicesHighFunctionPage);
|
|
||||||
}),
|
}),
|
||||||
_valueAddedServicesItem(
|
_valueAddedServicesItem(
|
||||||
Image.asset('images/mine/icon_mine_valueAddedServices_push.png'),
|
Image.asset('images/mine/icon_mine_valueAddedServices_push.png'),
|
||||||
TranslationLoader.lanKeys!.pushMessage!.tr, () {
|
TranslationLoader.lanKeys!.pushMessage!.tr, () {
|
||||||
Toast.show(msg: "功能暂未开放");
|
Navigator.pushNamed(context, Routers.gatewayDetailPage);
|
||||||
// Navigator.pushNamed(context, Routers.gatewayDetailPage);
|
|
||||||
}),
|
}),
|
||||||
_valueAddedServicesItem(
|
_valueAddedServicesItem(
|
||||||
Image.asset(
|
Image.asset(
|
||||||
'images/mine/icon_mine_valueAddedServices_checkIn.png'),
|
'images/mine/icon_mine_valueAddedServices_checkIn.png'),
|
||||||
TranslationLoader.lanKeys!.checkingIn!.tr, () {
|
TranslationLoader.lanKeys!.checkingIn!.tr, () {
|
||||||
Toast.show(msg: "功能暂未开放");
|
Navigator.pushNamed(context, Routers.gatewayDetailPage);
|
||||||
// Navigator.pushNamed(context, Routers.gatewayDetailPage);
|
|
||||||
}),
|
}),
|
||||||
_valueAddedServicesItem(
|
_valueAddedServicesItem(
|
||||||
Image.asset(
|
Image.asset(
|
||||||
'images/mine/icon_mine_valueAddedServices_storage.png'),
|
'images/mine/icon_mine_valueAddedServices_storage.png'),
|
||||||
TranslationLoader.lanKeys!.recordsRetention!.tr, () {
|
TranslationLoader.lanKeys!.recordsRetention!.tr, () {
|
||||||
Toast.show(msg: "功能暂未开放");
|
Navigator.pushNamed(context, Routers.gatewayDetailPage);
|
||||||
// Navigator.pushNamed(context, Routers.gatewayDetailPage);
|
|
||||||
}),
|
}),
|
||||||
_valueAddedServicesItem(
|
_valueAddedServicesItem(
|
||||||
Image.asset('images/mine/icon_mine_valueAddedServices_vip.png'),
|
Image.asset('images/mine/icon_mine_valueAddedServices_vip.png'),
|
||||||
'可视对讲', () {
|
'可视对讲', () {
|
||||||
Toast.show(msg: "功能暂未开放");
|
Navigator.pushNamed(context, Routers.gatewayDetailPage);
|
||||||
// Navigator.pushNamed(context, Routers.gatewayDetailPage);
|
|
||||||
}),
|
}),
|
||||||
_valueAddedServicesItem(
|
_valueAddedServicesItem(
|
||||||
Text(
|
Text(
|
||||||
@ -94,8 +86,7 @@ class _ValueAddedServicesPageListState
|
|||||||
fontWeight: FontWeight.w600),
|
fontWeight: FontWeight.w600),
|
||||||
),
|
),
|
||||||
"Amazon Alexa", () {
|
"Amazon Alexa", () {
|
||||||
Toast.show(msg: "功能暂未开放");
|
Navigator.pushNamed(context, Routers.gatewayDetailPage);
|
||||||
// Navigator.pushNamed(context, Routers.gatewayDetailPage);
|
|
||||||
}),
|
}),
|
||||||
_valueAddedServicesItem(
|
_valueAddedServicesItem(
|
||||||
Text(
|
Text(
|
||||||
@ -106,8 +97,7 @@ class _ValueAddedServicesPageListState
|
|||||||
fontWeight: FontWeight.w600),
|
fontWeight: FontWeight.w600),
|
||||||
),
|
),
|
||||||
"Google Home", () {
|
"Google Home", () {
|
||||||
Toast.show(msg: "功能暂未开放");
|
Navigator.pushNamed(context, Routers.gatewayDetailPage);
|
||||||
// Navigator.pushNamed(context, Routers.gatewayDetailPage);
|
|
||||||
}),
|
}),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
|
|||||||
@ -107,7 +107,7 @@ class _ExpandedListTileState extends State<ExpandedListTile> {
|
|||||||
width: 10.w,
|
width: 10.w,
|
||||||
)),
|
)),
|
||||||
AnimatedRotation(
|
AnimatedRotation(
|
||||||
turns: _isExpanded ? 0 : -0.5,
|
turns: _isExpanded ? -0.5 : 0,
|
||||||
duration: _animationDuration,
|
duration: _animationDuration,
|
||||||
child: const Icon(Icons.keyboard_arrow_down),
|
child: const Icon(Icons.keyboard_arrow_down),
|
||||||
),
|
),
|
||||||
|
|||||||
@ -1,5 +1,6 @@
|
|||||||
import 'package:flutter/cupertino.dart';
|
import 'package:flutter/cupertino.dart';
|
||||||
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
||||||
|
import 'package:star_lock/app_settings/app_colors.dart';
|
||||||
|
|
||||||
class NoData extends StatelessWidget {
|
class NoData extends StatelessWidget {
|
||||||
const NoData({Key? key}) : super(key: key);
|
const NoData({Key? key}) : super(key: key);
|
||||||
@ -10,8 +11,22 @@ class NoData extends StatelessWidget {
|
|||||||
width: 1.sw,
|
width: 1.sw,
|
||||||
height: 1.sh - ScreenUtil().statusBarHeight,
|
height: 1.sh - ScreenUtil().statusBarHeight,
|
||||||
child: Center(
|
child: Center(
|
||||||
child: Image.asset('images/icon_unHaveData.png',width: 300.w,height: 240.w),
|
child: Column(
|
||||||
),
|
mainAxisAlignment: MainAxisAlignment.center,
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.center,
|
||||||
|
children: [
|
||||||
|
Image.asset(
|
||||||
|
'images/icon_noData.png',
|
||||||
|
width: 160.w,
|
||||||
|
height: 180.h,
|
||||||
|
),
|
||||||
|
Text(
|
||||||
|
'暂无数据',
|
||||||
|
style:
|
||||||
|
TextStyle(color: AppColors.darkGrayTextColor, fontSize: 22.sp),
|
||||||
|
)
|
||||||
|
],
|
||||||
|
)),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||