Tell us what you are trying to do?
I'm really not sure what's going on here but I have a Cred form that inserts a post. One of it's fields is a relationship select for it's agent (the current user). All I'm trying to do is populate the default value with current user but it's not working at all.
Here's the form shortcode im using in the cred form -
Agent to Property relationship
[cred_field field='@agent-property.parent' value='[wpv-current-user]' class='form-control' output='bootstrap' select_text='--- not set ---' required='false']
Test correct user or author is found -
[wpv-current-user]
[wpv-post-author]
[wpv-user field="display_name"]
Hello. Thank you for contacting the Toolset support.
You need to make sure the value you pass should be match to the post ID of agent post. Toolset offers post relationship between post types so current user ID and the post type Agent's post ID should be different that is what I can see should be the issue there.
Can you please share problem URL where you added the form and admin access details.
*** Please make a FULL BACKUP of your database and website.***
I would also eventually need to request temporary access (WP-Admin) to your site. Preferably to a test site where the problem has been replicated if possible in order to be of better help and check if some configurations might need to be changed.
I have set the next reply to private which means only you and I have access to it.
Thank you for sharing admin access details but can you please share problem URL where you added the form where I can see the parent field you are talking about?
It's the New property form - hidden link
This form is then called in the prop count view - hidden link
And prop count view is nested inside Agent property count view - hidden link
The reason there is nothing in the prop count is that I only need a[wpv-found-count]. I don't need any data in the loop. The reason the prop count view is nested in agent property count view is so that I can use conditional on the button so if agent cf > [wpv-found-count] the button will display.
I've created an agent for your account so you can see.
Here's how it flows front end -
1) Dashboard where you start. Here you can click create property button - hidden link
2) This takes you to add property where you can see the issue front end. The relationship field agent property parent is not populated by default. - hidden link
So I just want the relationship selects default value to be the current agent. The agent is also the author and the logged in user.
My issue is resolved now. Thank you!
The issue was that I wasn't using child post link from parent post, instead I linked to the post which contained the form. It looks like it's working now.