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

Annotations router custom action pre-format callback #14819

Merged
merged 7 commits into from
Feb 5, 2020
Merged

Annotations router custom action pre-format callback #14819

merged 7 commits into from
Feb 5, 2020

Conversation

BeMySlaveDarlin
Copy link
Contributor

Hello!

  • Type: new feature

In raising this pull request, I confirm the following:

  • I have read and understood the Contributing Guidelines
  • I have checked that another pull request for this purpose does not exist
  • I wrote some tests for this PR
  • I have updated the relevant CHANGELOG
  • I have created a PR for the documentation about this change

Added method to set callback handler to pre-format action name in Annotation Router.
Default behavior of action name processing:
PostsController::getLastUpdatedAction() equals to uri /posts/getlastupdated via strtolower formatting.
New behavior allows to set callback, which does user defined pre-format to action name:
PostsController::getLastUpdatedAction() equals to uri /posts/get-last-updated via uncamelize passed as callback

Thanks

@niden niden added 4.1.0 documentation Documentation required new feature request Planned Feature or New Feature Request labels Feb 5, 2020
niden
niden previously approved these changes Feb 5, 2020
@niden niden dismissed their stale review February 5, 2020 22:55

Changelog

Copy link
Member

@niden niden left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@BeMySlaveDarlin could you please update the 4.1 changelog with this functionality?

Other than that this is ready

@BeMySlaveDarlin
Copy link
Contributor Author

@BeMySlaveDarlin could you please update the 4.1 changelog with this functionality?

Other than that this is ready

Looks like it was lost through rebase. Added.

@niden niden merged commit fbbcacd into phalcon:4.1.x Feb 5, 2020
@niden
Copy link
Member

niden commented Feb 5, 2020

Thank you @BeMySlaveDarlin

@BeMySlaveDarlin BeMySlaveDarlin deleted the f/annotations-router-custom-action-preformat branch February 5, 2020 23:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Documentation required new feature request Planned Feature or New Feature Request
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

3 participants