yourWidget method

  1. @override
Widget yourWidget(
  1. BuildContext context,
  2. AssignmentViewModel? value
)
override

Implementation

@override
Widget yourWidget(BuildContext context, AssignmentViewModel? value) {
  //theInstance = context;
  return BlocBuilder<AccessBloc, AccessState>(
      builder: (context, accessState) {
    if (accessState is AccessDetermined) {
      return BlocProvider<AssignmentListBloc>(
        create: (context) => AssignmentListBloc(
          eliudQuery: WorkflowPackage.getOpenAssignmentsQuery(
              app.documentID, accessState.getMember()!.documentID),
          assignmentRepository: assignmentRepository(appId: app.documentID)!,
        )..add(LoadAssignmentList()),
        child: AssignmentListWidget(
            app: app,
            readOnly: true,
            widgetProvider: widgetProvider,
            listBackground: BackgroundModel()),
      );
    } else {
      return progressIndicator(app, context);
    }
  });
}