chat employee id changes.

design_3.0_demo_module
Sikander Saleem 2 months ago
parent 267a4445d1
commit df8d22f792

@ -53,8 +53,7 @@ class _MedicalGasInspectionDetailPageState extends State<MedicalGasInspectionDet
Widget build(BuildContext context) {
return Scaffold(
appBar: const DefaultAppBar(title: "Request Details"),
body: SafeArea(
child: _isLoading
body: _isLoading
? SizedBox.expand(child: const CircularProgressIndicator(color: AppColor.primary10).center)
: model == null
? const NoDataFound().center
@ -135,7 +134,6 @@ class _MedicalGasInspectionDetailPageState extends State<MedicalGasInspectionDet
}),
),
],
),
));
}

@ -80,8 +80,7 @@ class _UpdateDeliveryNotesState extends State<UpdateDeliveryNotes> {
// _update(context: context);
// },
),
body: SafeArea(
child: Form(
body: Form(
key: _formKey,
child: Column(
children: [
@ -285,7 +284,6 @@ class _UpdateDeliveryNotesState extends State<UpdateDeliveryNotes> {
),
],
),
),
));
// .handlePopScope(
// cxt: context,

@ -228,7 +228,7 @@ class _DeviceTransferDetailsState extends State<DeviceTransferDetails> {
requestId: widget.model.id!.toInt(),
assigneeEmployeeNumber: _model!.senderAssignedEmployeeNumber,
myLoginUserID: context.userProvider.user!.employeeId ?? context.userProvider.user!.username!,
contactEmployeeINumber: _model!.assetTransferContactPersons!.first.employeeNumber,
contactEmployeeINumber: _model!.assetTransferContactPersons!.first.employeeId ?? _model!.assetTransferContactPersons!.first.employeeNumber,
),
if ((_userProvider!.user?.type == UsersTypes.engineer))
if (isCurrentEngineerEligibleForEdit && isCurrentRequestEditAble)
@ -289,7 +289,7 @@ class _DeviceTransferDetailsState extends State<DeviceTransferDetails> {
requestId: widget.model.id!.toInt(),
assigneeEmployeeNumber: isSender ? _deviceTransfer.senderAssignedEmployeeNumber! : _deviceTransfer.receiverAssignedEmployeeNumber!,
myLoginUserID: context.userProvider.user!.employeeId ?? context.userProvider.user!.username!,
contactEmployeeINumber: _deviceTransfer.assetTransferContactPersons!.first.employeeNumber,
contactEmployeeINumber: _model!.assetTransferContactPersons!.first.employeeId ?? _deviceTransfer.assetTransferContactPersons!.first.employeeNumber,
),
if ((_userProvider!.user?.type == UsersTypes.engineer))
if (isCurrentEngineerEligibleForEdit && !isCurrentRequestClosed)

@ -73,7 +73,7 @@ class _GasRefillDetailsPageState extends State<GasRefillDetailsPage> {
requestId: widget.model.id!.toInt(),
assigneeEmployeeNumber: _gasRefillModel.assignedEmployee?.employeeId!,
myLoginUserID: context.userProvider.user!.employeeId ?? context.userProvider.user!.username!,
contactEmployeeINumber: _gasRefillModel.gasRefillContactPerson!.first.employeeCode!,
contactEmployeeINumber: _gasRefillModel.gasRefillContactPerson!.first.employeeId ?? _gasRefillModel.gasRefillContactPerson!.first.employeeCode!,
);
})
],

@ -254,7 +254,6 @@ class _UpdateGasRefillRequestState extends State<UpdateGasRefillRequest> {
child: Column(
crossAxisAlignment: CrossAxisAlignment.stretch,
children: [
8.height,
SingleItemDropDownMenu<Lookup, NullableLoadingProvider>(
context: context,
title: context.translation.quantity,

@ -116,11 +116,9 @@ class CreateRequestModel {
if (context.userProvider.isQualityUser && context.settingProvider.isUserFlowMedical) {
list.add(CreateRequestModel("Equipment Internal Audit Checklist".addTranslation, "add_icon", CreateEquipmentInternalAuditForm.id));
list.add(CreateRequestModel("System Internal Audit Checklist".addTranslation, "add_icon", CreateSystemInternalAuditForm.id));
}
else if (context.userProvider.isAssessor) {
} else if (context.userProvider.isAssessor) {
list.add(CreateRequestModel("TRAF".addTranslation, "add_icon", CreateTRAFRequestPage.id));
}
else if (context.userProvider.isEngineer) {
} else if (context.userProvider.isEngineer) {
if (Provider.of<SettingProvider>(context, listen: false).engineerCanCreateCM) {
list.add(CreateRequestModel(context.translation.correctiveMaintenance, "add_icon", CreateCMRequest.id));
}
@ -128,16 +126,18 @@ class CreateRequestModel {
//TODO uncommit this to enable task.
list.add(CreateRequestModel(context.translation.task, "add_icon", CreateTaskView.id));
//Need to add check from permission Api.
// if (Provider.of<SettingProvider>(context, listen: false).engineerCanCreateCM) {
if ((context.settingProvider.isUserFlowMedical)) {
list.add(CreateRequestModel('Medical Gas'.addTranslation, "add_icon", CreateMedicalGasRequestPage.id));
// }
}
} else {
list.add(CreateRequestModel(context.translation.correctiveMaintenance, "add_icon", CreateCMRequest.id));
list.add(CreateRequestModel(context.translation.gasRefill, "add_icon", GasRefillRequestForm.routeName));
list.add(CreateRequestModel(context.translation.transferAsset, "add_icon", CreateDeviceTransferRequest.id));
//TODO uncommit this to enable task.
list.add(CreateRequestModel(context.translation.task, "add_icon", CreateTaskView.id));
if ((context.settingProvider.isUserFlowMedical)) {
list.add(CreateRequestModel("TRAF".addTranslation, "add_icon", CreateTRAFRequestPage.id));
}
// Hide Loan
// list.add(CreateRequestModel('Loan Equipment Request'.addTranslation, "add_icon", CreateLoanRequestPage.id));
}

@ -97,11 +97,11 @@ class _AllRequestsFilterPageState extends State<AllRequestsFilterPage> {
}
});
//Hide traf
if (!isEngineer) {
if (!isEngineer && context.settingProvider.isUserFlowMedical) {
types['TRAF'] = 9;
}
if (context.userProvider.isAssessor) {
if (context.settingProvider.isUserFlowMedical && context.userProvider.isAssessor) {
types = {"TRAF": 9};
}
if (context.userProvider.isQualityUser) {

@ -63,7 +63,7 @@ class _MyRequestsPageState extends State<MyRequestsPage> {
}
});
//Hide TRAF.
if (context.userProvider.user!.type == UsersTypes.normal_user) {
if (context.settingProvider.isUserFlowMedical && context.userProvider.user!.type == UsersTypes.normal_user) {
requestsList.add(Request(9, 'TRAF'));
}
if (context.userProvider.isEngineer && context.settingProvider.isUserFlowMedical) {
@ -74,7 +74,6 @@ class _MyRequestsPageState extends State<MyRequestsPage> {
requestsList.add(Request(14, "Medical Gas Inspection"));
}
// Hide Loan
// requestsList.add(Request(12, "Loan Equipment"));

Loading…
Cancel
Save