Ecodev / newsletter

TYPO3 extension to send newsletter
https://extensions.typo3.org/extension/newsletter/
25 stars 26 forks source link

Newsletter - statistics problem? #164

Closed netengine-at closed 5 years ago

netengine-at commented 6 years ago

TYPO3 7.6.26 Newsletter 3.3.1 Firefox 61.0.2 (64-Bit)

Hello,

we have a problem with the statics tab for the Newsletter-Extension. It seems there is some sort of JS- Problem. The "Overview" tab is empty and pagination in the "Emails" tab doesn't work.

newsletter1

newsletter2

Error in chrome when I click a pagination Link in "Emails" Tab:

newsletter3

Sorry, I know this is not much information... what can I do to help you with the debugging?

Best wishes.

PowerKiKi commented 6 years ago

Cannot reproduce on Firefox 61, TYPO3 7.6.31, newsletter 3.3.1. This is very far stretched, but maybe you could try upgrading to your TYPO3 to 7.6.31. Otherwise try another browser (Chrome) and/or have a look at the network panel, instead of JavaScript error. Maybe there is a file that could not be served properly ?

netengine-at commented 6 years ago

Hello Adrien,

I will try updating T3, although I don't think that will help.

Maybe some other extension is interfering, when I have some time I will make a dev-version and disable other extensions, one-by-one.

Thank you.

PS: don't know if this is helpful, when I click pagination I get the following:

newsletter4

newsletter5

netengine-at commented 6 years ago

Hello Adrien,

TYPO3 7.6.26 Newsletter 3.3.1

We have been having a new issue with the statistcs, in the json responce from TYPO3 we've been getting an fatal error (*). It seems this has to do with the left join you are using in NewsletterRepository.php. Not sure why _execSELECTquery (**) can't deal with this, if I create the SQL manually with your inputs everything works fine.

(*) > DBAL fatal error: No handler found in handler_getFromTableList() for:

\"tx_newsletter_domain_model_link LEFT JOIN tx_newsletter_domain_model_linkopened ON (tx_newsletter_domain_model_linkopened.link = tx_newsletter_domain_model_link.uid)\" (SQL engine parse ERROR: No join field found in parseFromTables()!: near \"(tx_newsletter_domain_model_linkopened.link = tx_n\")

newsletter/Classes/Domain/Repository/NewsletterRepository.php Line: 98 - 104

        $this->fillStateDifferences(
            $stateDifferences, 'tx_newsletter_domain_model_link LEFT JOIN tx_newsletter_domain_model_linkopened ON (tx_newsletter_domain_model_linkopened.link = tx_newsletter_domain_model_link.uid)', 'tx_newsletter_domain_model_link.newsletter = ' . $uidNewsletter, [
                'open_time' => ['increment' => 'linkOpenedCount'],
            ]
        );

This change in your code works for us:

        $this->fillStateDifferences(
            $stateDifferences, 'tx_newsletter_domain_model_link, tx_newsletter_domain_model_linkopened', '(tx_newsletter_domain_model_linkopened.link = tx_newsletter_domain_model_link.uid) AND tx_newsletter_domain_model_link.newsletter = ' . $uidNewsletter, [
                'open_time' => ['increment' => 'linkOpenedCount'],
            ]
        );

(**) this is the error that is thrown, don't ask me why TYPO3CMS: DatabaseConnection Class Reference

Best wishes, Ulf

netengine-at commented 6 years ago

Hi Adrian,

nearly forgot this, the Problem seem to be in connection with the DBAL Extension...

Database Abstraction Layer dbal 7.6.26

Best wishes, Ulf

PowerKiKi commented 6 years ago

Could you try reverting to the original line and only removing the parenthesis around the ON clause ?

Also next time, please open a new issue if it's a different problem.

PowerKiKi commented 5 years ago

Cannot reproduce, and no feedback, so closing for now.