[3.2][BETA] User Topic Count

A place for Extension Authors to post and receive feedback on Extensions still in development. No Extensions within this forum should be used within a live environment!
Anti-Spam Guide
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

IMPORTANT: Extensions Development rules

IMPORTANT FOR NEEDED EVENTS!!!
If you need an event for your extension please read this for the steps to follow to request the event(s)
User avatar
eunaumtenhoid
Registered User
Posts: 884
Joined: Wed Jun 03, 2009 12:46 am
Location: ????

Re: [ALPHA] User Topic Count

Post by eunaumtenhoid » Sun Sep 18, 2016 4:22 pm

martti wrote:
eunaumtenhoid wrote:MANY users are with the number of topics to 0 , it's a bug? and the same has various topics
It's ALPHA. This project is on halt because lack of the right event-triggers.
but it shows the topics of some users of other non

will fix?


it is possible to add the option to select which acp forums want to show the topics

e g
I want to show somento the topics of the forum id = 27 and no more
My translations of the extensions for Brazilian Portuguese
https://github.com/phpBBTraducoes

back4ever
Registered User
Posts: 19
Joined: Tue Oct 04, 2016 5:52 pm

Re: [ALPHA] User Topic Count

Post by back4ever » Fri Oct 21, 2016 4:17 pm

not possible to download more ?

User avatar
Galixte de EzCom
Registered User
Posts: 1041
Joined: Mon Oct 04, 2004 11:14 pm
Location: France
Name: Raphaël M.
Contact:

Re: [ALPHA] User Topic Count

Post by Galixte de EzCom » Fri Oct 21, 2016 5:48 pm

back4ever wrote:not possible to download more ?
On first post, it’s indicated: viewtopic.php?p=13890606#p13890606.
Communau EzCom
📖 « Traductions d’extensions & styles pour phpBB 3.1.x & 3.2.x ».
📋 Lists of all extensions identified for phpBB 3.1.x & 3.2.x.
📋 Lists of all styles identified for phpBB 3.1.x & 3.2.x.
Image Tu as un forum et tu veux aussi un site web ? Regarde par ici.

User avatar
martti
Registered User
Posts: 762
Joined: Thu Jul 31, 2014 8:23 am
Location: Belgium

Re: [ALPHA] User Topic Count

Post by martti » Fri Oct 21, 2016 9:27 pm

@back4ever Github was one of the sites that was victime of massive ddos attack today.

https://www.nixcraft.com/ddos-attack-ag ... t-2016/53/

User avatar
martti
Registered User
Posts: 762
Joined: Thu Jul 31, 2014 8:23 am
Location: Belgium

Re: [ALPHA] User Topic Count

Post by martti » Tue Jun 05, 2018 9:34 am

This extension has been updated to version 0.2.1 and uses now the strategy of recounting all the topics for a user instead of adding/substracting from previous count.
To resyncronise all the topic counts you can always disable/enable the extension.
Notice that the result number of the topics in the search page may be different due to the permissions of the current user.

User avatar
martti
Registered User
Posts: 762
Joined: Thu Jul 31, 2014 8:23 am
Location: Belgium

Re: [ALPHA] User Topic Count

Post by martti » Tue Jun 05, 2018 9:39 am

And the requirements are now moved to phpBB 3.2.2+, PHP 7+

User avatar
Galixte de EzCom
Registered User
Posts: 1041
Joined: Mon Oct 04, 2004 11:14 pm
Location: France
Name: Raphaël M.
Contact:

Re: [3.2][BETA] User Topic Count

Post by Galixte de EzCom » Tue Jun 05, 2018 10:04 pm

Thanks for this update!
Communau EzCom
📖 « Traductions d’extensions & styles pour phpBB 3.1.x & 3.2.x ».
📋 Lists of all extensions identified for phpBB 3.1.x & 3.2.x.
📋 Lists of all styles identified for phpBB 3.1.x & 3.2.x.
Image Tu as un forum et tu veux aussi un site web ? Regarde par ici.

User avatar
martti
Registered User
Posts: 762
Joined: Thu Jul 31, 2014 8:23 am
Location: Belgium

Re: [3.2][BETA] User Topic Count

Post by martti » Sat Jun 16, 2018 6:43 am

Somebody reported an issue on enabling this extension.

Is anyone else experiencing this?

User avatar
Toxyy
Registered User
Posts: 702
Joined: Mon Oct 24, 2016 3:22 pm
Location: Namek
Contact:

Re: [3.2][BETA] User Topic Count

Post by Toxyy » Sat Jun 16, 2018 8:21 am

martti wrote:
Sat Jun 16, 2018 6:43 am
Somebody reported an issue on enabling this extension.

Is anyone else experiencing this?
That's a strange issue. It almost seems like migration didn't add the column at all.
I am a web developer/administrator, specializing in forums. If you have work you need done or are too lazy to do, pm me!

My extensions:
[3.2][BETA] Anonymous Posts || [3.2][BETA] Sticky Ad || [3.2][RC] Show User Activity ||
[3.2][DEV] User Delete Topics

User avatar
martti
Registered User
Posts: 762
Joined: Thu Jul 31, 2014 8:23 am
Location: Belgium

Re: [3.2][BETA] User Topic Count

Post by martti » Sat Jun 16, 2018 8:30 am

Toxyy wrote:
Sat Jun 16, 2018 8:21 am
martti wrote:
Sat Jun 16, 2018 6:43 am
Somebody reported an issue on enabling this extension.

Is anyone else experiencing this?
That's a strange issue. It almost seems like migration didn't add the column at all.
The error occurs in ext.php and that's were the column is add in the first step:

Code: Select all

	/**
	* @param mixed $old_state
	* @return mixed false after last step, otherwise temporary state
	*/
	public function enable_step($old_state)
	{
		$db = $this->container->get('dbal.conn');
		$posts_table = $this->container->getParameter('tables.posts');
		$topics_table = $this->container->getParameter('tables.topics');
		$users_table = $this->container->getParameter('tables.users');		

		if (!$old_state)
		{
			$db_tools = $this->container->get('dbal.tools');

			// the user_topic_count column has to be present
			$db_tools->perform_schema_changes([
				'add_columns'	=> [
					$users_table	=> [
						'user_topic_count'		=> ['UINT', 0],
					],
				],
			]);
// ...
Maybe it has something to do with a difference between MySQL and SQLite3 (what I am using). That's why I ask if anyone (with another database than me and especially MySQL or MariaDB) is experiencing this.

User avatar
david63
Registered User
Posts: 16683
Joined: Thu Dec 19, 2002 8:08 am
Location: Lancashire, UK
Name: David Wood
Contact:

Re: [3.2][BETA] User Topic Count

Post by david63 » Sat Jun 16, 2018 8:37 am

Out of curiosity why are you adding this in ext.php and not in migration where you have the update_schema and revert_schema functions to handle this?
David
Remember: You only know what you know and - you don't know what you don't know!
My CDB Contributions | How to install an extension
I will not be accepting translations for any of my extensions in Github - please post any translations in the appropriate topic.
No support requests via PM or email as they will be ignored

User avatar
martti
Registered User
Posts: 762
Joined: Thu Jul 31, 2014 8:23 am
Location: Belgium

Re: [3.2][BETA] User Topic Count

Post by martti » Sat Jun 16, 2018 8:42 am

david63 wrote:
Sat Jun 16, 2018 8:37 am
Out of curiosity why are you adding this in ext.php and not in migration where you have the update_schema and revert_schema functions to handle this?
Because the "Topic Count" for all users is calculated and stored in the column when enabling the extension.

User avatar
Galixte de EzCom
Registered User
Posts: 1041
Joined: Mon Oct 04, 2004 11:14 pm
Location: France
Name: Raphaël M.
Contact:

Re: [3.2][BETA] User Topic Count

Post by Galixte de EzCom » Sat Jun 16, 2018 10:45 am

martti wrote:
Sat Jun 16, 2018 8:42 am
david63 wrote:
Sat Jun 16, 2018 8:37 am
Out of curiosity why are you adding this in ext.php and not in migration where you have the update_schema and revert_schema functions to handle this?
Because the "Topic Count" for all users is calculated and stored in the column when enabling the extension.
Is the only way to resyncronise all the topic counts?
Communau EzCom
📖 « Traductions d’extensions & styles pour phpBB 3.1.x & 3.2.x ».
📋 Lists of all extensions identified for phpBB 3.1.x & 3.2.x.
📋 Lists of all styles identified for phpBB 3.1.x & 3.2.x.
Image Tu as un forum et tu veux aussi un site web ? Regarde par ici.

User avatar
david63
Registered User
Posts: 16683
Joined: Thu Dec 19, 2002 8:08 am
Location: Lancashire, UK
Name: David Wood
Contact:

Re: [3.2][BETA] User Topic Count

Post by david63 » Sat Jun 16, 2018 10:52 am

martti wrote:
Sat Jun 16, 2018 8:42 am
Because the "Topic Count" for all users is calculated and stored in the column when enabling the extension.
Fair enough - I was just curious
David
Remember: You only know what you know and - you don't know what you don't know!
My CDB Contributions | How to install an extension
I will not be accepting translations for any of my extensions in Github - please post any translations in the appropriate topic.
No support requests via PM or email as they will be ignored

User avatar
martti
Registered User
Posts: 762
Joined: Thu Jul 31, 2014 8:23 am
Location: Belgium

Re: [3.2][BETA] User Topic Count

Post by martti » Sat Jun 16, 2018 10:59 am

Galixte de EzCom wrote:
Sat Jun 16, 2018 10:45 am
Is the only way to resyncronise all the topic counts?
Yes, disable and enable. But if you need to resynchronize it means something is missing in the extension.
Do you have the extension installed with MySQL/MariaDB?

Post Reply

Return to “Extensions in Development”