Bring projects, wikis, and teams together with AI. AppFlowy is the AI collaborative workspace where you achieve more without losing control of your data. The leading open source Notion alternative.
Dart blogconfluence-alternativecontent-managementcontent-servicesdocumentationflutternote-takingnotion-alternativeproject-managementtask-managementteam-collaborationwiki
fix: switch format style of the date after creating
appflowy082b0d2f5d8e
diff --git a/frontend/app_flowy/lib/plugins/grid/application/cell/cell_service/cell_controller.dart b/frontend/app_flowy/lib/plugins/grid/application/cell/cell_service/cell_controller.dartindex 29fb521976..cf578f8b6c 100644--- a/frontend/app_flowy/lib/plugins/grid/application/cell/cell_service/cell_controller.dart+++ b/frontend/app_flowy/lib/plugins/grid/application/cell/cell_service/cell_controller.dart@@ -149,18 +149,13 @@ class IGridCellController<T, D> extends Equatable {_cellDataPersistence = cellDataPersistence,_fieldNotifier = fieldNotifier,_fieldService = FieldService(- gridId: cellId.gridId, fieldId: cellId.fieldContext.id),+ gridId: cellId.gridId,+ fieldId: cellId.fieldContext.id,+ ),_cacheKey = GridCellCacheKey(- rowId: cellId.rowId, fieldId: cellId.fieldContext.id);-- IGridCellController<T, D> clone() {- return IGridCellController(- cellId: cellId,- cellDataLoader: _cellDataLoader,- cellCache: _cellsCache,- fieldNotifier: _fieldNotifier,- cellDataPersistence: _cellDataPersistence);- }+ rowId: cellId.rowId,+ fieldId: cellId.fieldContext.id,+ );String get gridId => cellId.gridId;@@ -172,9 +167,10 @@ class IGridCellController<T, D> extends Equatable {FieldType get fieldType => cellId.fieldContext.fieldType;- VoidCallback? startListening(- {required void Function(T?) onCellChanged,- VoidCallback? onCellFieldChanged}) {+ VoidCallback? startListening({+ required void Function(T?) onCellChanged,+ VoidCallback? onCellFieldChanged,+ }) {if (isListening) {Log.error("Already started. It seems like you should call clone first");return null;diff --git a/frontend/app_flowy/lib/plugins/grid/presentation/widgets/cell/date_cell/date_cell.dart b/frontend/app_flowy/lib/plugins/grid/presentation/widgets/cell/date_cell/date_cell.dartindex d55ad8ada0..f90b8d06f1 100644--- a/frontend/app_flowy/lib/plugins/grid/presentation/widgets/cell/date_cell/date_cell.dart+++ b/frontend/app_flowy/lib/plugins/grid/presentation/widgets/cell/date_cell/date_cell.dart@@ -80,9 +80,9 @@ class _DateCellState extends GridCellState<GridDateCell> {),),popupBuilder: (BuildContext popoverContent) {- final bloc = context.read<DateCellBloc>();return DateCellEditor(- cellController: bloc.cellController.clone(),+ cellController: widget.cellControllerBuilder.build()+ as GridDateCellController,onDismissed: () => widget.onCellEditing.value = false,);},diff --git a/frontend/app_flowy/lib/plugins/grid/presentation/widgets/cell/url_cell/url_cell.dart b/frontend/app_flowy/lib/plugins/grid/presentation/widgets/cell/url_cell/url_cell.dartindex 16f96421d8..5ed184aafb 100644--- a/frontend/app_flowy/lib/plugins/grid/presentation/widgets/cell/url_cell/url_cell.dart+++ b/frontend/app_flowy/lib/plugins/grid/presentation/widgets/cell/url_cell/url_cell.dart@@ -54,13 +54,11 @@ class GridURLCell extends GridCellWidget {GridURLCellAccessoryType ty, GridCellAccessoryBuildContext buildContext) {switch (ty) {case GridURLCellAccessoryType.edit:- final cellController =- cellControllerBuilder.build() as GridURLCellController;return GridCellAccessoryBuilder(builder: (Key key) => _EditURLAccessory(key: key,- cellContext: cellController,anchorContext: buildContext.anchorContext,+ cellControllerBuilder: cellControllerBuilder,),);@@ -191,10 +189,10 @@ class _GridURLCellState extends GridCellState<GridURLCell> {}class _EditURLAccessory extends StatefulWidget {- final GridURLCellController cellContext;+ final GridCellControllerBuilder cellControllerBuilder;final BuildContext anchorContext;const _EditURLAccessory({- required this.cellContext,+ required this.cellControllerBuilder,required this.anchorContext,Key? key,}) : super(key: key);@@ -224,7 +222,8 @@ class _EditURLAccessoryState extends State<_EditURLAccessory>child: svgWidget("editor/edit", color: theme.iconColor),popupBuilder: (BuildContext popoverContext) {return URLEditorPopover(- cellController: widget.cellContext.clone(),+ cellController:+ widget.cellControllerBuilder.build() as GridURLCellController,);},);