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

Fetching twice for another user #32

Closed
kendepelchin opened this issue Oct 16, 2015 · 3 comments
Closed

Fetching twice for another user #32

kendepelchin opened this issue Oct 16, 2015 · 3 comments
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@kendepelchin
Copy link

Hey,
I want to fetch settings for a user after the initial fetch is done for the current logged in user (in a route middleware). I have an email that has to be translated to the locale of the user which will receive it.

In the repo $this->loaded is set to true when the initial fetch is done, so the second time it skips this and returns the data.
Any hints or tips on how to conquer this problem?

@anlutro
Copy link
Owner

anlutro commented Oct 16, 2015

A way to run a single settings get/set with a custom constraint would probably be a good feature.

For now, I suggest you either just write some custom code to do it, or use Setting::setConstraint or Setting::setPath appropriately to make the setting store get that user's settings that way.

@anlutro anlutro added the enhancement New feature or request label Nov 19, 2015
@anlutro anlutro added the help wanted Extra attention is needed label Apr 29, 2016
@arcanedev-maroc
Copy link

I think it's better to reset the loaded property to false when the setExtraColumns is called.

@bweston92
Copy link
Collaborator

Closing as stale.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

4 participants