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

how to get user_meta_data and product_meta_data #20

Open
hmoshfegh opened this issue Apr 22, 2020 · 4 comments
Open

how to get user_meta_data and product_meta_data #20

hmoshfegh opened this issue Apr 22, 2020 · 4 comments

Comments

@hmoshfegh
Copy link

hi. i collect some informations from user into the customer's metadata like membership state and some infos for products into the product's metadata that is important for app. but the wooDroid lib not return customer metadata and return product metadata without value. how i can resolve this?

@ronnyvillamar99
Copy link

hello, this problem is due to the fact that when the request is made the app searches for users with the role of customer, but registered users are generally subscribers, this is solved by adding this code in this line:

/app/repo/CustomerRepository.kt
lin 29: customerFilter.setRole("all");

adding that line should work

I'm also the same as you, I'm not a collaborator of this project haha

@zubusoomro
Copy link

Can any one help me in getting value of meta data ?

@ronnyvillamar99
Copy link

add a metadata variable in this file it should be a Metadata list, and serialize it,
Here
WooDroid/woodroid/src/main/java/me/gilo/woodroid/models/Customer.kt

and also in
WooDroid/woodroid/src/main/java/me/gilo/woodroid/models/Metadata.kt
, you should also serialize it, with that you should get a metadata list

@ronnyvillamar99
Copy link

I give you an idea, I haven't done it but it should work by adding that list in Customer.kt

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

No branches or pull requests

3 participants