操作记录新增清空记录权限(仅锁的拥有者可清空)
This commit is contained in:
parent
de060cdae8
commit
df3e763fd3
@ -143,7 +143,7 @@ class DoorLockLogLogic extends BaseGetXController {
|
|||||||
DoorLockLogEntity entity = await ApiRepository.to.lockEventList(
|
DoorLockLogEntity entity = await ApiRepository.to.lockEventList(
|
||||||
lockId: state.keyInfos.value.lockId!,
|
lockId: state.keyInfos.value.lockId!,
|
||||||
lockEventType: state.dropdownValue.value,
|
lockEventType: state.dropdownValue.value,
|
||||||
pageNo: pageNo, // 根据是否是下拉刷新决定页码
|
pageNo: pageNo,
|
||||||
pageSize: int.parse(pageSize),
|
pageSize: int.parse(pageSize),
|
||||||
startDate: state.startDate.value,
|
startDate: state.startDate.value,
|
||||||
endDate: state.endDate.value);
|
endDate: state.endDate.value);
|
||||||
|
|||||||
@ -7,6 +7,7 @@ import 'package:star_lock/main/lockDetail/doorLockLog/doorLockLog_entity.dart';
|
|||||||
import 'package:star_lock/main/lockDetail/doorLockLog/doorLockLog_logic.dart';
|
import 'package:star_lock/main/lockDetail/doorLockLog/doorLockLog_logic.dart';
|
||||||
import 'package:star_lock/tools/EasyRefreshTool.dart';
|
import 'package:star_lock/tools/EasyRefreshTool.dart';
|
||||||
import 'package:star_lock/tools/advancedCalendar/src/widget.dart';
|
import 'package:star_lock/tools/advancedCalendar/src/widget.dart';
|
||||||
|
import 'package:star_lock/tools/commonDataManage.dart';
|
||||||
import 'package:star_lock/tools/menuItem/xsDropDownWidget.dart';
|
import 'package:star_lock/tools/menuItem/xsDropDownWidget.dart';
|
||||||
import 'package:star_lock/tools/noData.dart';
|
import 'package:star_lock/tools/noData.dart';
|
||||||
import 'package:star_lock/tools/showCupertinoAlertView.dart';
|
import 'package:star_lock/tools/showCupertinoAlertView.dart';
|
||||||
@ -37,7 +38,11 @@ class _DoorLockLogPageState extends State<DoorLockLogPage> with RouteAware {
|
|||||||
haveBack: true,
|
haveBack: true,
|
||||||
backgroundColor: AppColors.mainColor,
|
backgroundColor: AppColors.mainColor,
|
||||||
actionsList: [
|
actionsList: [
|
||||||
TextButton(
|
Visibility(
|
||||||
|
visible: CommonDataManage().currentKeyInfo.isLockOwner == 1
|
||||||
|
? true
|
||||||
|
: false,
|
||||||
|
child: TextButton(
|
||||||
onPressed: () {
|
onPressed: () {
|
||||||
ShowCupertinoAlertView().showClearOperationRecordAlert(
|
ShowCupertinoAlertView().showClearOperationRecordAlert(
|
||||||
clearClick: () {
|
clearClick: () {
|
||||||
@ -47,7 +52,7 @@ class _DoorLockLogPageState extends State<DoorLockLogPage> with RouteAware {
|
|||||||
child: Text(
|
child: Text(
|
||||||
'清空记录'.tr,
|
'清空记录'.tr,
|
||||||
style: TextStyle(color: Colors.white, fontSize: 24.sp),
|
style: TextStyle(color: Colors.white, fontSize: 24.sp),
|
||||||
)),
|
))),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
body: Column(
|
body: Column(
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user