• Resolved Jack

    (@jack1132132)


    When I’m selling content, there’s a constant struggle to get the right point type to be attributed to the paid content.

    I have two points types, and I sell different content with different point types. I choose the options to sell ‘All Posts’ and ‘Pages I manually select’. I want to sell all posts with the “Points” type but there’s no way to set this up in the settings without the the plugin offering to sell with the other point type.

    With the ‘Posts I manuanly select’ option I can choose between active default types, which doesn’t make sense to be able to select multiple default types but that’s what I have to do it be able to select a point type on pages I’m selling, this causes a lot of problems because then I want to sell “All Posts” by default with a certain point type and when those run out it defaults to the other default…

    I can’t go into every post created and choose the point type, I want to be set a a point type for All Posts, and it’s impossible to do because I have to enable the Default Status of both “Credits” and “Points” so I can choose which type is being sold for the “Pages I manually select”.

    Is there any way I can force “All Posts” to be sold only by one point type?

    Thank you

Viewing 6 replies - 1 through 6 (of 6 total)
  • Thread Starter Jack

    (@jack1132132)

    To better understand the problem, here’s screenshots with explanation: https://i.imgur.com/nphtfDi.png

    Thread Starter Jack

    (@jack1132132)

    I solved it by editing these files:

    mycred/addons/sell-content/myCRED-addon-sell-content.php

    mycred/addons/sell-content/includes/mycred-sell-functions.php

    Just removed the “$setup[‘status’] === ‘disabled'” conditions from the functions mycred_sell_content_new_purchase() and metabox().

    A.Tariq

    (@arsalantariq)

    Hi @jack1132132,

    Thank you for contacting us, It could be your site-specific issue. If you select all posts the user can sell content for the default point type only. When a user selects pages I select manually you don’t need to enable both point types to show the point type on WordPress pages. Only the checkbox of a certain point type needs to be enabled to show it on WordPress pages. It is working fine as we have tested it on your environment.

    Great to know that you have found a solution to your issue. As per the discussion with our development team, we will not remove these conditions from our plugin.

    Thread Starter Jack

    (@jack1132132)

    @arsalantariq Hello,

    Has this issue been fixed yet? I still have to comment out those lines of code, anyone who uses two point types will face this issue if he/she needs to sell posts with different points.

    Thank you.

    Thread Starter Jack

    (@jack1132132)

    By adding this code to functions.php, it seems to work. it checks if it’s on the correct page then disables the points that aren’t sold there.

    
    function option_mycred_sell_this_mycred_points2_func($setup){
    	$setup['status'] = 'enabled';
    	
    	if(is_page(50) || is_page(2047) || is_page(2131))
    		$setup['status'] = 'disabled';
    	
    	return $setup;
    }
    
    function option_mycred_sell_this_points1_func($setup){
    	$setup['status'] = 'enabled';
    	
    	if(!(is_page(50) || is_page(2047) || is_page(2131)))
    		$setup['status'] = 'disabled';
    	
    	return $setup;
    }
    
    add_filter( 'option_mycred_sell_this_points2', 'option_mycred_sell_this_mycred_points2_func' , 10 ,1);
    add_filter( 'option_mycred_sell_this_points1', 'option_mycred_sell_this_points1_func' , 10 ,1);
    A.Tariq

    (@arsalantariq)

    @jack1132132,

    As per discussion with our team, we have not removed the conditions from our plugin. We have tested it on our environment. It is working fine. We can consider it as a possibility for the future but we will finalize the things after discussing it with our development team.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Multiple default Point Types need to be Enabled to be able to manually select.’ is closed to new replies.