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

Feature: #1081 Add a way to hide unneeded form fields from clients #1082

Merged

Conversation

Tthecreator
Copy link
Contributor

@Tthecreator Tthecreator commented May 28, 2021

This is my pull request portraying to issue #1081.
So far I've:

  • Added DB settings (including migration)
  • Added frontend hiding of fields
  • Added backend enabling/disabling of fields
  • Maintain Language files

@Tthecreator Tthecreator changed the title [WIP] [1081] Add new settings in db [1081] Add new settings in db May 30, 2021
@Tthecreator
Copy link
Contributor Author

Tthecreator commented May 30, 2021

I've now finished all tasks to make this feature function.
This screen has been added to settings:
image
I've also moved some settings from general to this screen for consistency.

The translations that I've added are automatically translated. I don't know what the official process for this is for this repository. So the translations are not perfect. In fact, I think "Client Form" may have been translated to mean "the state in which the client is/how the client looks" instead of "the form that the client can fill in".

The eye icons have been picked from here: https://www.iconfinder.com/icons/314276/hidden_eye_icon. It seems that the license allows us to use these icons. Attribution would be nice but not necessary. I wouldn't know where to add this attribution.

Also, before using this you may need to update your database by going to http:///backend/update.

@Tthecreator Tthecreator changed the title [1081] Add new settings in db Feature: #1081 Add a way to hide unneeded form fields from clients May 30, 2021
Copy link
Contributor

@vitormattos vitormattos left a comment

Choose a reason for hiding this comment

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

I tested your PR and I really liked it!
Congratulations on your contribution to the project!
As I need to run Easy!Appointments with the PR I also made, I've already merged your PR into my develop branch. I identified a problem running the npm start command when building the front, which I solved with the suggestions I requested here in your PR

assets/js/backend_settings.js Outdated Show resolved Hide resolved
assets/js/backend_settings.js Outdated Show resolved Hide resolved
assets/js/backend_settings_system.js Outdated Show resolved Hide resolved
Apply suggestions from @vitormattos.

Co-authored-by: Vitor Mattos <[email protected]>
@Tthecreator
Copy link
Contributor Author

Hi @vitormattos, Thanks for the review and the changes. I've committed and implemented them. Let's hope we can merge soon then.

Copy link
Contributor

@vitormattos vitormattos left a comment

Choose a reason for hiding this comment

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

What do you think of this change?

application/views/backend/settings.php Outdated Show resolved Hide resolved
application/views/backend/settings.php Outdated Show resolved Hide resolved
@priverop
Copy link

@Tthecreator i think you need to review @vitormattos last suggestion?

@alextselegidis any chance we can merge this finally? Thanks!

@alextselegidis
Copy link
Owner

Greetings!

Thanks for this PR! I'm currently undergoing the PR merging phase so this will be reviewed soon.

FYI the settings page will be completely reworked, so chances are that the user interface will change drastically.

In one way or the other, 1.5 will allow you to select which fields to display to the booking page.

Alex Tselegidis, Easy!Appointments Creator
Need a customization? Get a free quote!

Copy link
Contributor Author

@Tthecreator Tthecreator left a comment

Choose a reason for hiding this comment

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

Still seems to work after merge

@Tthecreator
Copy link
Contributor Author

I accepted the changes by @vitormattos. Not sure how I forgot about those, but here we are anyways. I think this PR is now ready for final review. What do you suggest with the drastic UI changed @alextselegidis, still merge this?

@alextselegidis
Copy link
Owner

@Tthecreator More setting capabilities need to be added to the settings page and we cannot always add tabs to the form.

For that a different menu structure and rendering will be prepared.

This is where the will be some incompatibility, but before I proceed of the new markup, I will partially merge your solution so that the field toggling works.

Alex Tselegidis, Easy!Appointments Creator
Need a customization? Get a free quote!

@alextselegidis alextselegidis merged commit 4646a03 into alextselegidis:develop Oct 21, 2021
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.

4 participants