Jump to content

Pay to Pin Topics


Adriano Faria
 Share

Recommended Posts

Posted (edited)
4 hours ago, ahc said:

Er, I'm not sure if a log would be present for my specific issue?  It's just about the button not reappearing when an invoice expires.

If it’s not running for yiu, then something should be logged in System Logs or Error Logs.

Can you provide ACP access? I’ll have to debug in your install. 

Edited by Adriano Faria
Link to comment
Share on other sites

7 hours ago, Adriano Faria said:

If it’s not running for yiu, then something should be logged in System Logs or Error Logs.

Can you provide ACP access? I’ll have to debug in your install. 

Yeah no problem. Dawpi is helping me out with something else as well so I’ll need to make a new acc for you both to use when I get home from work. 

Link to comment
Share on other sites

  • 5 weeks later...

I am getting an error in the cron and it is in the logs. Is there something that i am missing int he DB?

SELECT * FROM `paytopintopics_topics`  LEFT JOIN `forums_topics` ON paytopintopics_topics.ptpt_topic_id=forums_topics.tid WHERE pinned=1 AND ptpt_status='pinned' AND ptpt_limit<1630680301 ORDER BY tid DESC LIMIT 25
Column 'ptpt_status' in where clause is ambiguous

 

 

#0 /home/skupper/www.bmw2002faq.com/system/Db/Select.php(383): IPS\_Db->preparedQuery('/*ipb_prd::ipdb...', Array, true)
#1 /home/skupper/www.bmw2002faq.com/system/Db/Select.php(577): IPS\Db\_Select->runQuery()
#2 /home/skupper/www.bmw2002faq.com/applications/paytopintopics/tasks/pinRequest.php(42): IPS\Db\_Select->count()
#3 /home/skupper/www.bmw2002faq.com/system/Task/Task.php(367): IPS\paytopintopics\tasks\_pinRequest->IPS\paytopintopics\tasks\{closure}()
#4 /home/skupper/www.bmw2002faq.com/applications/paytopintopics/tasks/pinRequest.php(66): IPS\_Task->runUntilTimeout(Object(Closure))
#5 /home/skupper/www.bmw2002faq.com/system/Task/Task.php(266): IPS\paytopintopics\tasks\_pinRequest->execute()
#6 /home/skupper/www.bmw2002faq.com/system/Task/Task.php(229): IPS\_Task->run()
#7 /home/skupper/www.bmw2002faq.com/applications/core/interface/task/task.php(58): IPS\_Task->runAndLog()
#8 {main}

 

Thanks for the help!

Steve K.

Edited by misfit76
Link to comment
Share on other sites

On 9/3/2021 at 12:48 PM, misfit76 said:

SELECT * FROM `paytopintopics_topics`  LEFT JOIN `forums_topics` ON paytopintopics_topics.ptpt_topic_id=forums_topics.tid WHERE pinned=1 AND ptpt_status='pinned' AND ptpt_limit<1630680301 ORDER BY tid DESC LIMIT 25
Column 'ptpt_status' in where clause is ambiguous

Not sure how you're getting this error:

	public function execute()
	{
		$this->runUntilTimeout( function()
		{
			$sql = \IPS\Db::i()->select( '*', 'paytopintopics_topics', array( "pinned=1 AND ptpt_status=? AND ptpt_limit<?", 'pinned', time() ), 'tid DESC', 25 )->join( 'forums_topics', 'paytopintopics_topics.ptpt_topic_id=forums_topics.tid' );
			if ( !$sql->count() )
			{
				return FALSE;
			}

There's only one ptpt_status column in the app and it's not duplicated in the query, etc.

You probably still have these columns in your topics table from the old plugin; it should have been dropped. Make sure you don't have them in forums_topics table. If you have, drop them. Let me know if you need help to check and drop the columns.

Link to comment
Share on other sites

10 hours ago, Adriano Faria said:

Not sure how you're getting this error:

	public function execute()
	{
		$this->runUntilTimeout( function()
		{
			$sql = \IPS\Db::i()->select( '*', 'paytopintopics_topics', array( "pinned=1 AND ptpt_status=? AND ptpt_limit<?", 'pinned', time() ), 'tid DESC', 25 )->join( 'forums_topics', 'paytopintopics_topics.ptpt_topic_id=forums_topics.tid' );
			if ( !$sql->count() )
			{
				return FALSE;
			}

There's only one ptpt_status column in the app and it's not duplicated in the query, etc.

You probably still have these columns in your topics table from the old plugin; it should have been dropped. Make sure you don't have them in forums_topics table. If you have, drop them. Let me know if you need help to check and drop the columns.

 

Help finding if they exist and dropping them is appreciated

steve

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...