Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

fix: use callback function if exportRender method is set #177

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

Merged
yajra merged 2 commits into yajra:master from mrezagolestan:master
Jul 31, 2023

Conversation

@mrezagolestan
Copy link
Contributor

@mrezagolestan mrezagolestan commented May 7, 2023

this commit is paired with another commit d48dc1bbe8bc860070240d6f1444e7a861c53789 which should be pushed together to make final result:

this commit is about development not bug fix:

i realize a need to render column data for export, i found it by adding Export Class to set how to render export
but i couldn't find any thing for render print
and i need a centralized render for print & export (for simplicity & integrity)
so i added exportRender method to be used for pass a callback function to determine how targeted column data should be rendered for print & export, sample code is shown below:
Column::make('used')->title('Use Status')->exportRender(function($row,$data){return $data == 1 ? 'Yes' : 'Not Yet'});

but in this commit we write just use of callback function for rendering column to print or export as we expected
but commit d48dc1bbe8bc860070240d6f1444e7a861c53789 in laravel-datatable-html repo should be pushed to exportRender method added to Column Builder for adding callback function

please accept that pull request before this pull request

...parse print + exports as expected (commit d48dc1bbe8bc860070240d6f1444e7a861c53789 in laravel-datatables-html)
Copy link
Contributor Author

#195 pull request should be accept before this pull request

Copy link
Owner

yajra commented May 8, 2023

Can you also fix the failing checks here? Thanks!

Copy link

sonarqubecloud bot commented May 9, 2023

Copy link
Contributor Author

why it hadn't merged ? i read PHPStan error & didn't get any idea for

@yajra yajra changed the title (削除) use callback function which was set in colum->exportRender method to ... (削除ここまで) (追記) fix: use callback function if exportRender method is set (追記ここまで) Jul 31, 2023
@yajra yajra merged commit 4a2cafe into yajra:master Jul 31, 2023
Copy link
Owner

yajra commented Jul 31, 2023

Released in v10.0.7 🚀 Thanks!

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

Reviewers

@yajra yajra yajra left review comments

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /