Reports
This commit is contained in:
parent
91ec72bac1
commit
4b38870c71
|
|
@ -81,9 +81,8 @@ UserCompanyEntity loadCompanySuccessReducer(
|
|||
|
||||
// Check user has a blank user settings object
|
||||
if (userCompany?.settings?.accentColor == null) {
|
||||
userCompany = userCompany.rebuild((b) => b
|
||||
..settings.replace(UserSettingsEntity())
|
||||
);
|
||||
userCompany =
|
||||
userCompany.rebuild((b) => b..settings.replace(UserSettingsEntity()));
|
||||
}
|
||||
|
||||
userCompany = userCompany.rebuild((b) => b.company
|
||||
|
|
@ -118,13 +117,14 @@ UserCompanyEntity loadCompanySuccessReducer(
|
|||
}
|
||||
*/
|
||||
|
||||
return userCompany
|
||||
..company.rebuild((b) => b
|
||||
..userMap.addAll(Map.fromIterable(
|
||||
action.userCompany.company.users,
|
||||
key: (dynamic item) => item.id,
|
||||
value: (dynamic item) => item,
|
||||
)));
|
||||
userCompany = userCompany.rebuild((b) => b
|
||||
..company.userMap.addAll(Map.fromIterable(
|
||||
action.userCompany.company.users,
|
||||
key: (dynamic item) => item.id,
|
||||
value: (dynamic item) => item,
|
||||
)));
|
||||
|
||||
return userCompany;
|
||||
}
|
||||
|
||||
UserCompanyEntity saveCompanySuccessReducer(
|
||||
|
|
|
|||
|
|
@ -71,6 +71,7 @@ ReportResult clientReport(UserCompanyEntity userCompany,
|
|||
value = client.assignedUserId;
|
||||
break;
|
||||
case ClientFields.createdBy:
|
||||
print('## USER ARRAY ${userCompany.company.users}');
|
||||
print('## USER MAP ${userCompany.company.userMap}');
|
||||
value = userCompany
|
||||
.company.userMap[client.createdUserId]?.listDisplayName ??
|
||||
|
|
|
|||
|
|
@ -150,7 +150,7 @@ class ReportsScreen extends StatelessWidget {
|
|||
),
|
||||
FormCard(
|
||||
child: ReportDataTable(
|
||||
//key: ObjectKey(state.uiState.reportsUIState),
|
||||
//key: ObjectKey(viewModel.reportResult.columns),
|
||||
viewModel: viewModel,
|
||||
),
|
||||
)
|
||||
|
|
|
|||
Loading…
Reference in New Issue