Skip to content

fix rendering issues#5

Open
theabhirock74 wants to merge 1 commit into
nesscale-com:mainfrom
theabhirock74:fix-child-table-issues
Open

fix rendering issues#5
theabhirock74 wants to merge 1 commit into
nesscale-com:mainfrom
theabhirock74:fix-child-table-issues

Conversation

@theabhirock74

Copy link
Copy Markdown

Fix child table rendering issue caused by invalid dependency refresh

Description

This PR fixes a child table rendering issue in Material Request caused by calling refresh_dependency() on child document rows. Since child document objects do not implement this method, it resulted in the following runtime error:

TypeError: row.refresh_dependency is not a function

Before

image

Changes

  • Removed the invalid row.refresh_dependency() call.
  • Replaced row-level dependency refresh with a supported grid refresh mechanism.
  • Prevented child table rendering from breaking during form load and field updates.

After

image
  • Child table rows render correctly.
  • No console errors are thrown during Material Request load.
  • Field dependencies are refreshed using supported Frappe APIs.

Testing

  • Verified that existing and new Material Requests load successfully.
  • Confirmed that the Items child table renders correctly.
  • Confirmed that no row.refresh_dependency is not a function errors are logged in the browser console.
  • Verified that field updates and dependencies continue to work as expected.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant