Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SfDataGrid] [BugFix] When only one row, ColumWidth fitByValue failed #860

Closed
YancyHsu opened this issue Jul 7, 2024 · 4 comments
Closed
Labels
bug Something isn't working data grid Data grid component fixed Fixed and delivered update

Comments

@YancyHsu
Copy link

YancyHsu commented Jul 7, 2024

two or more it works well, so maybe somewhere rowindex start from 1? i cant find it in the source code

@YancyHsu
Copy link
Author

YancyHsu commented Jul 8, 2024

https://github.com/syncfusion/flutter-widgets/blob/ee87b7b6a735a9a303d7e7973fa4540d0337b64e/packages/syncfusion_flutter_datagrid/lib/src/datagrid_widget/runtime/column.dart#L656

if (startRowIndex <= 0 && endRowIndex <= 0) {
      return column._actualWidth;
    }

just annotation it, or revise to:

if (startRowIndex < 0 && endRowIndex < 0) {
      return column._actualWidth;
    }

then it is ok to run only one row datasource

@YancyHsu YancyHsu changed the title DataGrid: When only one row, ColumWidth fitByValue failed [SfDataGrid] [BugFix] When only one row, ColumWidth fitByValue failed Jul 8, 2024
@VijayakumarMariappan VijayakumarMariappan added data grid Data grid component open Open and need to address labels Jul 8, 2024
@abineshPalanisamy
Copy link

Hi @YancyHsu ,

We have checked your query at our end, and we are able to replicate that issue at our end. We have considered this as a bug and logged a bug report regarding this in our feedback portal. We will fix the reported issue and include the changes in our upcoming weekly patch release, which is expected to be rolled out on August 20, 2024. We will let you know once released, and we appreciate your patience until then.

Disclaimer: Inclusion of this solution in the weekly release may change due to other factors including but not limited to QA checks and works reprioritization.

Regards,
Abinesh P

@abineshPalanisamy
Copy link

Hi @YancyHsu ,

We are glad to inform you that the reported problem has been resolved on our end. Therefore, kindly update SfDataGrid to the latest version(26.2.10).

Root cause : We previously implemented a condition to calculate the cell width when the effective rows are empty. This condition is the root cause of the bug. The issue occurs because the condition checks if endIndex <= 0. However, the endIndex is 0 whether the effective rows are empty or contain a single row.

If you have any further queries, please don't hesitate to reach out. We are more than happy to assist you.

Regards,
Abinesh P

@ashok-kuvaraja ashok-kuvaraja added waiting for customer Cannot make further progress until the customer responds bug Something isn't working fixed Fixed and delivered update and removed open Open and need to address labels Aug 20, 2024
@ashok-kuvaraja
Copy link
Collaborator

Hi @YancyHsu,

We believe that the reported issue has been resolved in the latest DataGrid version. Hence, we are closing this issue. If you need any further assistance, please reopen this ticket. We are always happy to help you.

Regards,
Ashok K

@ashok-kuvaraja ashok-kuvaraja removed the waiting for customer Cannot make further progress until the customer responds label Sep 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working data grid Data grid component fixed Fixed and delivered update
Projects
None yet
Development

No branches or pull requests

4 participants