Skip to content

Commit

Permalink
MAT-7968 re-rendering the UI builder tables when a measure is drafted…
Browse files Browse the repository at this point in the history
… from Edit Page
  • Loading branch information
RohitKandimalla committed Jan 21, 2025
1 parent 8171185 commit 850a2fd
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/CqlBuilderPanel/Includes/Results/Results.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@ const Results = ({
...columnDefs,
]
: columnDefs;
}, [cqlLibraries, isCQLUnchanged]);
}, [canEdit, cqlLibraries, isCQLUnchanged]);

Check warning on line 280 in src/CqlBuilderPanel/Includes/Results/Results.tsx

View workflow job for this annotation

GitHub Actions / Checkout, install, lint, build and test with coverage

React Hook useMemo has missing dependencies: 'showAlias', 'showDeleteConfirmation', and 'showLibraryDetails'. Either include them or remove the dependency array

const table = useReactTable({
data,
Expand Down
2 changes: 1 addition & 1 deletion src/CqlBuilderPanel/Parameters/SavedParameters.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ const SavedParameters = ({
},
},
],
[parameters, isCQLUnchanged]
[canEdit, parameters, isCQLUnchanged]

Check warning on line 151 in src/CqlBuilderPanel/Parameters/SavedParameters.tsx

View workflow job for this annotation

GitHub Actions / Checkout, install, lint, build and test with coverage

React Hook useMemo has a missing dependency: 'table'. Either include it or remove the dependency array
);

const table = useReactTable({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,8 @@ export default function SavedCodesSubSection({
setTotalPages,
]);

console.log("canEdit in saved components", canEdit);

Check failure on line 172 in src/CqlBuilderPanel/codesSection/codesSubSection/savedCodesSubSection/SavedCodesSubSection.tsx

View workflow job for this annotation

GitHub Actions / Checkout, install, lint, build and test with coverage

Unexpected console statement

const TH = tw.th`p-3 text-left text-sm font-bold capitalize`;
const columns = useMemo<ColumnDef<SavedCodesColumnRow>[]>(
() => [
Expand Down Expand Up @@ -246,7 +248,7 @@ export default function SavedCodesSubSection({
),
},
],
[isCQLUnchanged]
[canEdit, isCQLUnchanged, measureModel]
);

const table = useReactTable({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ const Definitions = ({
},
},
],
[definitions]
[canEdit, definitions]
);

const table = useReactTable({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ const Functions = ({
},
},
],
[functions, isCQLUnchanged]
[canEdit, functions, isCQLUnchanged]
);

const table = useReactTable({
Expand Down

0 comments on commit 850a2fd

Please sign in to comment.