Skip to content

NEW FEATURES ( a lot of good stuff ) : added restore + a lot of customization for date, datetime, icon , ....#71

Merged
rmsramos merged 13 commits intormsramos:mainfrom
phpust:main
Jul 3, 2025
Merged

NEW FEATURES ( a lot of good stuff ) : added restore + a lot of customization for date, datetime, icon , ....#71
rmsramos merged 13 commits intormsramos:mainfrom
phpust:main

Conversation

@phpust
Copy link
Copy Markdown
Contributor

@phpust phpust commented Dec 7, 2024

  1. updated lang files and timeline strings
  2. added restore event + made event name translatable
  3. being able to inject different calendar type, by passing closure in panelprovider
  4. being able to pass custom trans file inside panelprovider so subject become translatable
  5. replace sprintf's with translation method and passing variable to it.
  6. remove garbage inside style file
  7. and much more

you can see an example of some feature bellow:

ActivitylogPlugin::make()
                    ->navigationIcon('heroicon-o-cursor-arrow-rays')
                    ->navigationSort(2)
                    ->translateSubject(fn($label) => __("navarak.".$label))
                    ->navigationGroup(fn () => __('navarak.management'))
                    ->pluralLabel(fn () => __("navarak.activity_logs"))
                    ->isRestoreActionHidden(true)
                    ->isResourceActionHidden(true)
                    ->resourceActionLabel(fn () => __('activitylog::action.view'))
                    ->dateParser(
                        fn($date) => auth()->user()->isJalaliCalendar() ? 
                            Jalalian::fromDateTime($date) :  
                            Carbon::parse($date)
                    )
                    ->dateFormat(fn() => auth()->user()->getFilamentDateFormat())
                    ->datetimeFormat(fn() => auth()->user()->getFilamentDateTimeFormat())
                    ->customizeDatetimeColumn(function ($column) {
                        return $column->when(
                                auth()->user()->isJalaliCalendar(), 
                                function ($column) {
                                    return $column->jalaliDateTime();
                                }
                            );
                    })
                    ->customizeDatePicker(function ($field) {
                        return $field->when(
                                auth()->user()->isJalaliCalendar(),
                                function ($field) {
                                    return $field->jalali();
                                }
                            );
                    })

i changed menu icon, menu sort, custom translation file base on my loggable resource to translate resource name in texts, changed navigation group and plural label, I set a condition so that in that case, the calendar changes to the Jalali calendar. made date and datetime format customizable here (it accept closure , so i get user prefered style from user model ), also made datepicker inside filter and created_at column customizable , so i can change them to jalali

@phpust
Copy link
Copy Markdown
Contributor Author

phpust commented Dec 7, 2024

@rmsramos dear ramos, could you please merge this pr.

@rmsramos
Copy link
Copy Markdown
Owner

rmsramos commented Dec 8, 2024

How cool your contributions are, I'll really take some time this week to analyze everything and release a new version of the plugin

@phpust
Copy link
Copy Markdown
Contributor Author

phpust commented Dec 8, 2024

@rmsramos thank you :)

@rmsramos
Copy link
Copy Markdown
Owner

Hello @phpust , sorry for the delay in getting back to you, today I managed to take a look at the overdue PRs and when I did yours it ended up with a lot of conflicts, I know it's asking a lot, but could you analyze it and resend it to me?

@stvieira
Copy link
Copy Markdown

stvieira commented Mar 27, 2025

@phpust can you resolve the conflicts mentioned by @rmsramos ? Your contribution is very relevant to the project.

@phpust
Copy link
Copy Markdown
Contributor Author

phpust commented May 11, 2025

@phpust can you resolve the conflicts mentioned by @rmsramos ? Your contribution is very relevant to the project.

Hello @phpust , sorry for the delay in getting back to you, today I managed to take a look at the overdue PRs and when I did yours it ended up with a lot of conflicts, I know it's asking a lot, but could you analyze it and resend it to me?

Sorry for the delay — I've been caught up with other work lately.
I hope the recent changes help move things forward

@rmsramos rmsramos merged commit 067767e into rmsramos:main Jul 3, 2025
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.

3 participants