Commit graph

36 commits

Author SHA1 Message Date
19b7fff24f Remove v12 upgrade findings
Ignore false positives for extension scanner.
Migrate TCA and keep old v11 within condition for backwards
compatibility.

Relates: #110
2023-05-11 15:58:22 +02:00
feeb7d4235 Migrate to php-cs-fixer 2023-04-27 11:12:10 +02:00
9f24518a0b
Support TYPO3 v12.1 (#96)
* Support TYPO3 v12.0

All dependencies are compatible now.
We can update to support v12.0.

This commit will shift TYPO3 support from 10 and 11 to 11 and 12.
See Changelog entry.

Update dev dependencies to our latest best practice.
Auto migrate code base to follow CGL and use PHP 7.4.
2022-12-07 13:37:19 +01:00
f0bb1d03a8 Fix broken recordview introduced with last commit
Relates: #86
2022-09-16 15:03:47 +02:00
39529be49a Allow to use expressions with PHP 8.x
Introduce new traverse function taken from TYPO3 TypoScript conditions.

Relates: #86
2022-09-16 14:45:54 +02:00
5b4a379978 Add strict_types and move namespace definition
To follow my new conventions.
2022-09-16 14:11:58 +02:00
456c86b492 Update PHPStan
PHPStan was released with first stable public version 1.x.
The version is updated together with extensions.

The new version finds new issues which are solved right away to not
break CI.
2022-01-06 08:10:02 +01:00
67c2d22f15 Fix performance issue of PageviewsPerDay widget
Issue a single query with native group by instead of x queries.

Resolves: #63
2021-08-03 12:04:55 +02:00
9a4f71bce4 Allow copy of pages
Pages can not be copied by administrators as DataHandler will copy all
pages, including tx_tracking_* tables.
Those are not allowed on tables which will result in error messages.

A test is added to simulate the action and ensure it doesn't fail with
errors.

Results: #52
2021-06-02 06:25:27 +02:00
adb73eeffc Switch to ECS for coding style
This allows configuration via PHP.
It also combines code sniffer and php cs fixer.

Used commands:

composer remove --dev squizlabs/php_codesniffer
composer req --dev symplify/easy-coding-standard
./vendor/bin/ecs --fix
2021-05-24 22:11:46 +02:00
3c10aa6d10 Support TYPO3 v11.2 and PHP 8.0 beside current v10.4 and 7.4. 2021-05-19 22:21:17 +02:00
930903e39f Fix SQL query for pageviewsperpage widget
The existing query was not fully working as intended.
Also it did not work with proper MySQL sql_mode settings.

This is fixed by building a proper query which delivers expected and
deterministic results.

We now always have latest records first.

Also there is no need to fetch the sys_language_uid, as we only fetch
localized record if only one language is allowed. That way we can just
check configuration and use the configuration to do language overlay.

Also there was no need for an join, therefore query was reduced to
necessary stuff.

Relates:  #35
2020-08-13 10:11:45 +02:00
27e0623794 Fix SQL query for recordviews widget
The existing query was not fully working as intended.
Also it did not work with proper MySQL sql_mode settings.

This is fixed by building a proper query which delivers expected and
deterministic results.

We now always have latest records first.

Also there is no need to fetch the sys_language_uid, as we only fetch
localized record if only one language is allowed. That way we can just
check configuration and use the configuration to do language overlay.

Relates:  #35
2020-08-13 10:11:45 +02:00
42f75a75a0 Remove HTML Tags from dashboard widget labels
BackendUtility::getRecordTitle might contain HTML tags like "span".
Those might result in broken rendering. As we don't need this markup
anyway, we remove it.
2020-08-04 09:16:33 +02:00
1cbec2e51d Support language restriction for all widgets
Relates: #15
2020-08-03 14:29:42 +02:00
f3d69eed45 Add multi language support
Allow integrator to limit results in widget to certain languages.
If only one language is allowed, labels will be translated.
Otherwise default system language is used.

E.g. one record will be displayed in multiple languages, it would be
confusing to show him multiple times for each language.

Add TYPO3 extension for phpstan as many things would break within tests.

Relates: #15
2020-08-03 08:46:31 +02:00
a387580df7 !!!|Rename bad phrases like blacklist
This involves changed inside of Services.yaml if those configuration
options were used before.

Relates: #17
2020-07-30 14:00:22 +02:00
33685d1735 Add tracking of record views
Allow Integrator to define rules to track views of records.
This allows to add tracking to extensions like tx_news.
Integrators are able to define matching rules on current request. If a
request matches, the record is stored as individual view beside existing
pageview.

Relates: #14
2020-07-30 13:52:33 +02:00
44ca6a2d3c Add operating system to page view record
Extract operating system from user agent and store it in database
record.

Another widget is added which displays the page views per operating
system.

An command is provided which will update existing data.
2020-07-29 09:07:43 +02:00
b732cc0cd2 Update interface namespace for ext:dashboard
As Interfaces was moved to a different namespace,
import statements need to be adjusted.
2020-04-17 16:18:28 +02:00
0927683926 Migrate dashboard part to be compatible with v10.4
10.4 introduced breaking changes for dashboard widgets.
The necessary changes to stay compatible are done within this commit.

No need anymore to configure widget through PHP, instead DI is used.
Instead only PHP to provide data is used.
2020-04-16 11:54:42 +02:00
669d75ce86 Add PHPStan to ensure code quality and prevent bugs 2020-04-01 20:43:30 +02:00
382f58a6ec
Cast string to int to fulfill interface 2020-04-01 11:38:48 +02:00
be0e13416c
Truncate page title for graph
In order to not break layout.
2020-04-01 11:38:09 +02:00
b19eb00329
Properly use order by doctrine api (#7) 2020-02-26 23:14:04 +01:00
763769b4d2 Add list widget with newest page views
Still very basic, no custom template or fancy information or styling.
2020-02-26 23:05:07 +01:00
db2b0e13ed Make max results of doughnut graph configurable 2020-02-26 23:05:07 +01:00
e237941e07 Fix wrong label identifier 2020-02-26 23:05:07 +01:00
548ad0b07c
Make widgets configurable via DI
As no configuration API is provided, we use Services.yaml for now.
2020-02-25 22:35:30 +01:00
50dcb619ea
Add PSR-12 2020-02-25 22:35:29 +01:00
ab6c7d2967
Use DI instead of unnecessary code 2020-02-25 22:35:27 +01:00
2e718d41c9
Take current day into account for page views per day 2020-02-25 22:35:27 +01:00
b1a7226ed8
Add tracking widgets 2020-02-25 22:35:26 +01:00
6a2cd9bc50
Add rules to prevent tracking of certain requests 2020-02-25 22:35:25 +01:00
27819c73ef
Add user agent to tracking
To enable fine grained filtering, and detect further bots / crawler to
block.
2020-02-25 22:35:25 +01:00
cece44c735
Add first basic tracking for page views 2020-02-25 22:35:25 +01:00