Automattic / WP-Job-Manager

Manage job listings from the WordPress admin panel, and allow users to post jobs directly to your site.
https://wpjobmanager.com
GNU General Public License v3.0
901 stars 368 forks source link

Client/author unable to see listings created by admin published privately #1381

Open jeleanor opened 6 years ago

jeleanor commented 6 years ago

Steps to Reproduce

  1. Create user profile for client
  2. Create job in WP Job Manager backend. Set client as author. Publish privately.
  3. Login as client and view a page with [job_dashboard] shortcode. Job doesn't show in table.

What I Expected

Client to be able to view job preview which I created through the backend and they view through their frontend dashboard.

What Happened Instead

Private jobs don't show. No option to set review status through backend.

WordPress / WP Job Manager Version

Up to date

Browser / OS Version

Mac OS X 10.12.6 & Safari 11.0.3

Screenshot / Video

https://imgur.com/a/sV9A2

Context / Source

Hi. I create job listings on behalf of my employers in the backend. I want them to be able to login to the Employer Dashboard (page with [job_dashboard] shortcode) and review their listing before it goes live. I can't seem to find a way of setting a job listing for review through the back end or smoothly giving my clients a frontend private preview/review option.

fsj-digital commented 6 years ago

Many many thanks for posting - I am so glad to see your posting here. KEEP up the great work - it rocks. Wordpress is the most intriguing commuinty - i love it!!! many greetings from Europe;)

jom commented 3 years ago

It seems safe to add private to the list of post_status here: https://github.com/Automattic/wp-job-manager/blob/7feb1353fba0b94a67d34c6f741b05b9edc77fde/includes/class-wp-job-manager-shortcodes.php#L269-L277

If the logged in user is set as the author, they do have access (via direct URL) to the private posts even if they aren't an admin.

For anyone who needs this before it is implemented, they can use the job_manager_get_dashboard_jobs_args filter.