魏少阳 15af50d951 1、完善星锁APP国际化 36种语言。
2、修复国际化问题
2024-10-15 18:32:11 +08:00

91 lines
3.4 KiB
Dart
Executable File
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:get/get.dart';
import 'package:star_lock/main/lockDetail/checkingIn/checkingInStaff/checkingInStaffDetail/checkingInStaffDetail_state.dart';
import '../../../../../appRouters.dart';
import '../../../../../app_settings/app_colors.dart';
import '../../../../../tools/commonItem.dart';
import '../../../../../tools/titleAppBar.dart';
import 'checkingInStaffDetail_logic.dart';
class CheckingInStaffDetailPage extends StatefulWidget {
const CheckingInStaffDetailPage({Key? key}) : super(key: key);
@override
State<CheckingInStaffDetailPage> createState() => _CheckingInStaffDetailPageState();
}
class _CheckingInStaffDetailPageState extends State<CheckingInStaffDetailPage> {
final CheckingInStaffDetailLogic logic = Get.put(CheckingInStaffDetailLogic());
final CheckingInStaffDetailState state = Get.find<CheckingInStaffDetailLogic>().state;
@override
Widget build(BuildContext context) {
return Scaffold(
backgroundColor: AppColors.mainBackgroundColor,
appBar: TitleAppBar(
barTitle: '员工信息'.tr,
haveBack: true,
backgroundColor: AppColors.mainColor,
actionsList: <Widget>[
TextButton(
child: Text(
'编辑'.tr,
style: TextStyle(color: Colors.white, fontSize: 24.sp),
),
onPressed: () {
Get.toNamed(Routers.checkingInAddStaffPage, arguments: <String, Object>{
'getKeyInfosData': state.getKeyInfosData.value,
'companyId': state.companyId.value,
'staffListItem': state.staffListItemData.value,
'isAdd': '2',
});
},
),
],),
body: Column(
children: <Widget>[
Obx(() => CommonItem(
leftTitel: '姓名'.tr,
rightTitle: state.staffListItemData.value.staffName,
isHaveLine: true)),
Obx(() => CommonItem(
leftTitel: '打卡方式'.tr,
rightTitle: state.attendanceType.value,
isHaveLine: true)),
// Obx(() => CommonItem(
// leftTitel: "APP",
// rightTitle: state.staffListItemData.value.attendanceWay,
// isHaveLine: true)),
Obx(() => Visibility(
visible: state.staffListItemData.value.cardStatus == 1,
child: Row(
children: <Widget>[
Container(
width: 1.sw,
// height: 50.h,
padding: EdgeInsets.only(left: 20.w, right: 20.w, top: 10.h),
child: Text("${state.staffListItemData.value.reason}${"打卡方式无效".tr}", style: TextStyle(fontSize: 22.sp, color: AppColors.openPassageModeColor)))
],
),
)),
CommonItem(
leftTitel: '考勤记录'.tr,
rightTitle: '',
isHaveDirection: true,
action: (){
Get.toNamed(Routers.checkingInDetailPage, arguments: <String, Object?>{
// "getKeyInfosData": state.getKeyInfosData.value,
'companyId': state.companyId.value,
'staffId': state.staffListItemData.value.staffId,
'staffName': state.staffListItemData.value.staffName,
});
}),
],
),
);
}
}