Page 13 of 18

Re: [BETA] Advanced Polls 1.2

Posted: Fri Dec 02, 2016 1:44 pm
by javiexin
javiexin wrote:Yes, this is a known error that I have been unable to chase down. I will have to find out what is going on, and where are my calculations failing. This is due to the fact that phpbb stores the poll duration in seconds, but presents it to the user in full days, so rounded, and therefore you have to recalculate and fake the poll start date to be able to have the exact date/time when you want it finished. Somehow, I have a case (that I have not been able to reproduce) that this calculation is wrong...
Finally, I have been able to reproduce the error, and chase it down to a string formatting issue!
I would like that people that have noticed this problem go ahead and perform the following change, and test it:
Open ext\wolfsblvt\advancedpolls\core\advancedpolls.php
Find '%d-%d-%d-%d-%d'
Replace in-line with '%d-%d-%d-%02d-%02d'

If you find any issues, please report them here, stating the data input into the poll configuration (for/until and date for duration.
I will include this in the next version, but in the meantime, you may test it and provide feedback.

Apologies,
-javiexin

Re: [BETA] Advanced Polls 1.2

Posted: Tue Dec 06, 2016 6:45 pm
by Clemse
javiexin wrote:I am planning on releasing a new version within a month or two, to be submitted to the CDB.

There are only a few changes that I am planning:
- Vote removal
- Improvements on the poll definition page
- Chasing the inconsistent issue with some polls failing with the "Out of range value for column 'poll_start'" error

I will then work on the migration of the extension to 3.2.

Regards,
-javiexin
Sounds very great! It's one of the best/useful extensions, especially in the context of polls, so if you keep it up to date, that's strongly appreciated.

Also your Msg gave me confidence to update/upgrade to 3.2.0 RC1. Advanced Polls seems to work so far.
However my problem of beingt unable to "activate, [that] votes can be seen" is still there.
Not in a hurry right now but if you have any idea what's the reason or how to fix it for the coming update(s), would be great.

One more thing: how is the translation process for the german version going?
v1.2 misses translation for AP_RUN_POLL, AP_POLL_MAX_VALUE, AP_POLL_TOTAL_VALUE, AP_POLL_SHOW_ORDERED. Is there help needed?

Best greetings


P.S. just as a hint: the used source page contains old (advanced polls) version (1.1)

Re: [BETA] Advanced Polls 1.2

Posted: Tue Dec 06, 2016 7:51 pm
by javiexin
Clemse wrote:One more thing: how is the translation process for the german version going?
v1.2 misses translation for AP_RUN_POLL, AP_POLL_MAX_VALUE, AP_POLL_TOTAL_VALUE, AP_POLL_SHOW_ORDERED. Is there help needed?

P.S. just as a hint: the used source page contains old (advanced polls) version (1.1)
The two issues you mention are due to the fact that wolfsblvt is "missing", and therefore these things have not progressed. On the language issue, if you can complete the german translation, all the better. The main repository is still wolfsblvt, but I will switch it when I go to the next major release (3.2 likely).

I will take a look at your issue again, and report back. Regards,
-javiexin

Re: [3.1][BETA] Advanced Polls 1.2

Posted: Wed Dec 07, 2016 12:32 pm
by Clemse
Sure, if wolfsblvt did stop developing the project (hope he's fine), but it fortunately lives further through you (nothing unusual in the opensource software world), then it would make sense to change the repository/source/path.

So till then, https://github.com/Wolfsblvt/advancedpo ... r/language is the right way to go, if I want to contribute translation update?

Btw, by lookin into the language files, I now also found the name of the KEY - which I miss at my board under ADM/permessions to show: ACL_U_SEE_VOTERS
Thanks for having a look into that!

Re: [3.1][BETA] Advanced Polls 1.2

Posted: Wed Dec 07, 2016 12:38 pm
by javiexin
Clemse wrote:So till then, https://github.com/Wolfsblvt/advancedpo ... r/language is the right way to go, if I want to contribute translation update?

Btw, by lookin into the language files, I now also found the name of the KEY - which I miss at my board under ADM/permessions to show: ACL_U_SEE_VOTERS
Thanks for having a look into that!
Yes please, use the current repository for contributions now.

And if the language key was missing, that might have caused that the permission didn't show up...

Regards,
-javiexin

Re: [3.1][BETA] Advanced Polls 1.2

Posted: Wed Dec 07, 2016 6:28 pm
by Clemse
Well, in fact there is some inconsistency in the language files:
1.1.0-b1
\en\permissions_advancedpolls.php
'ACL_U_SEE_VOTERS' => 'Can see poll voters if activated',
\de\permissions_advancedpolls.php
'ACL_U_SEE_VOTERS' => 'Kann die Benutzer sehen, abgestimmt haben, wenn aktiviert',

1.2.1-b1
\en\permissions_advancedpolls.php
'ACL_F_SEEVOTERS' => 'Can see poll voters',
'ACL_M_SEEVOTERS' => 'Can view poll voters',
\de\permissions_advancedpolls.php
'ACL_U_SEE_VOTERS' => 'Kann die Benutzer sehen, abgestimmt haben, wenn aktiviert',
However, after fixing the language files by adding the english versions' keys+strings and deactivating+activating the extension, my issue of not showing the permission settings line stays (the translation in other areas worked - by showing the english strings instead of key names).
In general I would consider, that it isn't a translation issue, because otherwise it would at least be shown as the key name (ACL_F_SEEVOTERS/ACL_M_SEEVOTERS --what's the difference by the way?) under permissions, wouldn't it?

What wonders me too is that the netherland sentence "Hvis aktiveret kan afgivne stemmer ses." (as posted by PELP) is not in any language files foundable.
Instead the nl-translation file contains:
\nl\permissions_advancedpolls.php says:
'ACL_F_SEEVOTERS' => 'Kunnen stemmers van de peilingen zien',
'ACL_M_SEEVOTERS' => 'Kunnen stemmers van de peilingen bekijken',
I also wanted to try to reach the permission settings with the CLI, which output is unsatisfying:
$ bin\php phpbbcli.php config:get 'ACL_F_SEEVOTERS'
Config ACL_F_SEEVOTERS does not exist
Thanks that you take your time for this extension and its challenges!
and kind regards

Re: [3.1][BETA] Advanced Polls 1.2

Posted: Wed Dec 07, 2016 6:46 pm
by javiexin
What I can think of is that migrations have not run properly...

If you can, disable, delete data, then copy the new files, including language, ant then reenable.

The difference between the permissions is that the F one is for general users, per forum, to allow or deny seeing poll votes if enabled on the poll. The M permission is for moderators, to allow seeing poll votes regardless of the poll configuration.

Hope this helps,
-javiexin

Re: [3.1][BETA] Advanced Polls 1.2

Posted: Wed Dec 07, 2016 7:37 pm
by JimA
Clemse wrote: What wonders me too is that the netherland sentence "Hvis aktiveret kan afgivne stemmer ses." (as posted by PELP) is not in any language files foundable.
That's not a Dutch sentence, I can assure you of that. Google Translate identifies it as Danish. :)

Re: [3.1][BETA] Advanced Polls 1.2

Posted: Fri Jan 13, 2017 8:13 pm
by janus_zonstraal
In phpbb 3.2 the settings of the notifications is no longer working with this extension.

Re: [3.1][BETA] Advanced Polls 1.2

Posted: Fri Jan 13, 2017 8:17 pm
by javiexin
janus_zonstraal wrote:
Fri Jan 13, 2017 8:13 pm
In phpbb 3.2 the settings of the notifications is no longer working with this extension.
No wonder it clearly states in the title that it is a 3.1 extension.

I have not started porting it yet. I will in the near future, but for the moment... you will have to wait.
-javiexin

Re: [BETA] Advanced Polls 1.2

Posted: Wed Feb 22, 2017 6:46 am
by Bruce Banner
javiexin wrote:
Fri Dec 02, 2016 1:44 pm
javiexin wrote:Yes, this is a known error that I have been unable to chase down. I will have to find out what is going on, and where are my calculations failing. This is due to the fact that phpbb stores the poll duration in seconds, but presents it to the user in full days, so rounded, and therefore you have to recalculate and fake the poll start date to be able to have the exact date/time when you want it finished. Somehow, I have a case (that I have not been able to reproduce) that this calculation is wrong...
Finally, I have been able to reproduce the error, and chase it down to a string formatting issue!
I would like that people that have noticed this problem go ahead and perform the following change, and test it:
Open ext\wolfsblvt\advancedpolls\core\advancedpolls.php
Find '%d-%d-%d-%d-%d'
Replace in-line with '%d-%d-%d-%02d-%02d'

If you find any issues, please report them here, stating the data input into the poll configuration (for/until and date for duration.
I will include this in the next version, but in the meantime, you may test it and provide feedback.

Apologies,
-javiexin
Hi. Just tested this. Unfortunately, can still only select a duration but not a date.

Re: [3.1][BETA] Advanced Polls 1.2

Posted: Wed Feb 22, 2017 10:29 am
by javiexin
I will test it again, but in the meantime, could you provide the error details?
Bruce Banner wrote:
Wed Feb 22, 2017 6:46 am
javiexin wrote:
Fri Dec 02, 2016 1:44 pm
If you find any issues, please report them here, stating the data input into the poll configuration (for/until and date for duration).
Hi. Just tested this. Unfortunately, can still only select a duration but not a date.
Thanks for reporting,
-javiexin

Re: [3.1][BETA] Advanced Polls 1.2

Posted: Wed Feb 22, 2017 9:42 pm
by BlackGirl
Hello, when you delete a user who has participated in a poll, this error appears (invited).
http://i.imgur.com/qPD2rcp.png

Re: [3.1][BETA] Advanced Polls 1.2

Posted: Wed Feb 22, 2017 11:41 pm
by javiexin
BlackGirl wrote:
Wed Feb 22, 2017 9:42 pm
Hello, when you delete a user who has participated in a poll, this error appears (invited).
http://i.imgur.com/qPD2rcp.png
I will look into it. To be precise the error happens when visualizing the poll AFTER a user that has voted in it has been deleted from the forum. I see you have enabled the "see poll voters" option. And in this case, what is the name of the deleted user? "Invitado"/Guest? Question: how did you specify the user removal? Keep posts assigned to guest, or remove?

In any case, what should be the "correct" behavior? Deleting a user who has poll votes should change those votes to "guest" votes if posts are retained, but then, if the poll does not allow votes from guests, it would be strange to see those in the list of poll voters. And in case posts are deleted, should votes also be deleted? There is no easy way around something like this, as the user name (in the user table) is lost when the user is deleted from the forum... The user id is what is stored in the voting table.

Thanks for reporting,
-javiexin

Re: [3.1][BETA] Advanced Polls 1.2

Posted: Thu Feb 23, 2017 12:22 am
by 3Di
Hi Javier,
in case of "delete user but retain posts" the only reference you could play with is the index post_username in the POSTS table, the poster_id will be set to ANONYMOUS (1).
Like adding a vote_user_name to the VOTES_TABLE and do some magic.

If you retain posts whilst deleting an user IMO the votes should be retained as well, removed in case of "delete user and posts". But that's just my opinion. :)

Regards.