toEntity method

  1. @override
PageEntity toEntity({
  1. String? appId,
})
override

Implementation

@override
PageEntity toEntity({String? appId}) {
  return PageEntity(
    appId: appId,
    description: (description != null) ? description : null,
    title: (title != null) ? title : null,
    appBarId: (appBar != null) ? appBar!.documentID : null,
    drawerId: (drawer != null) ? drawer!.documentID : null,
    endDrawerId: (endDrawer != null) ? endDrawer!.documentID : null,
    homeMenuId: (homeMenu != null) ? homeMenu!.documentID : null,
    bodyComponents: (bodyComponents != null)
        ? bodyComponents!.map((item) => item.toEntity(appId: appId)).toList()
        : null,
    backgroundOverride: (backgroundOverride != null)
        ? backgroundOverride!.toEntity(appId: appId)
        : null,
    layout: (layout != null) ? layout!.index : null,
    gridViewId: (gridView != null) ? gridView!.documentID : null,
    conditions:
        (conditions != null) ? conditions!.toEntity(appId: appId) : null,
  );
}