This topic contains 3 reply and 2 voices, and was last updated by HispanicSearching 5 years, 11 months ago
Viewing 3 Posts - 1 through 3 (of 3 total)
Author Posts
November 7, 2013 at 7:40 pm 9833
HispanicSearching Hi Tareq, I've been searching in forum but I don't see how this can be done. I need different config options for dashboard depending on post_type that are been displayed. The wpuf_dashboard short code accept post_type but don't accept any other argument. I need to show featured image, change edit options, etc for each different post_type. Can it be done ? How ? I see that setting page set this options for all dashboard but it would be better a manner to control each dashboard display/function with each edit form option or more easily with arguments to wpuf_dashboard shortcode. Any thought? thanks.
November 7, 2013 at 10:19 pm 9836
Mahi Mahi

To show different types of posts use short-code like this:

[wpuf_dashboard post_type="post_type_name"]

Documentation: http://docs.wedevs.com/wp-user-frontend-pro/#user-dashboard

Sorry, currently there is not much setting options.

However, we wrote few tutorials here – http://docs.wedevs.com/category/wp-user-frontend/

It may helps you to achieve your goal.

November 7, 2013 at 11:16 pm 9838
HispanicSearching HispanicSearching

Ok, so there isn’t any way to have differentes options for each dasboard.

Do you plan to add it ?

It’s easy to add as extra parameter to wpuf_dashboard, like post_type.

Thanks.

November 7, 2013 at 11:30 pm 9839
HispanicSearching HispanicSearching

For featured image extra option, in class/frontend-dashboard.php

Line 25:


- extract( shortcode_atts( array('post_type' => 'post'), $atts ) );
+ extract( shortcode_atts( array('post_type' => 'post', 'featured_image' => '0' ), $atts ) );

Line 54:


- function post_listing( $post_type ) {
+ function post_listing( $post_type, $featured_image ) {

Aprox line 103:


- if ( 'on' == $featured_img ) {
+ if (
+     $featured_image == 'on' ||
+     (!$featured_image && 'on' == $featured_img )
+ ) {

Aprox line 127:


- <?php if ( 'on' == $featured_img ) { ?>
+ <?php if ( $featured_image == 'on' || (!$featured_image && 'on' == $featured_img )) { ?>

With this you can:


[wpuf_dashboard post_type="post_type_name" featured_image="on"]
[wpuf_dashboard post_type="post_type_name" featured_image="off"]
Viewing 3 Posts - 1 through 3 (of 3 total)