mirror of
https://github.com/Deutscher-Tischfussballbund/com_sportsmanager.git
synced 2026-06-10 14:37:52 +00:00
Compare commits
220 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 7b1cc50943 | |||
| 133a983685 | |||
| 20b956b239 | |||
| fedb300d8f | |||
| 07121c2233 | |||
| 8dab7fa74f | |||
| 1bd53893a8 | |||
| acfcbb1010 | |||
| a6aee26211 | |||
| b24203ccb9 | |||
| 2ff39cf086 | |||
| 0729291afc | |||
| f3c2040632 | |||
| 1235edde82 | |||
| 763fd7d386 | |||
| 77e2c6e910 | |||
| a2aee3b135 | |||
| 9a7f8acc3b | |||
| 9091b22859 | |||
| 839b27756a | |||
| 0d0ee08199 | |||
| 6609a4ca78 | |||
| 4ecf48d02e | |||
| 40633f864a | |||
| 8e6aa127c6 | |||
| 9289843cb1 | |||
| 7a70500175 | |||
| 31b8e5251e | |||
| 455f845ab0 | |||
| f55d89827a | |||
| 874e06e061 | |||
| 83b8e1c25f | |||
| 3c9fac7e1a | |||
| 4ec02e5f02 | |||
| 4d1573729d | |||
| 6da371569a | |||
| fdede4a4a7 | |||
| 7ced30cf5b | |||
| 934b5b4971 | |||
| 085e5a8aeb | |||
| 53ada7c6b0 | |||
| 29dbfaeea4 | |||
| 95e02435fd | |||
| 32eacde07d | |||
| 2b19aee00f | |||
| 8b6ad5103c | |||
| 743f2b4013 | |||
| 2d2a124239 | |||
| d1e0dec74a | |||
| c4c3ea88fc | |||
| 761e04b6f2 | |||
| 089796d201 | |||
| e2b6f48498 | |||
| 3422813152 | |||
| 67b46f121a | |||
| 6c3c9badfd | |||
| e05d107af3 | |||
| 2f94c29c7e | |||
| b656cb5df3 | |||
| af97c59960 | |||
| ebb3580fad | |||
| 4a313d5914 | |||
| 771856b842 | |||
| 0c4d0820d1 | |||
| 8a0ad8d8e9 | |||
| 03a448f4cc | |||
| 9d75619c2c | |||
| a1890c51c0 | |||
| 51ee656f66 | |||
| 6d9df0e769 | |||
| a74bcb0ee8 | |||
| 6399eab0af | |||
| 9cde84a1d0 | |||
| 76738ec307 | |||
| 59e1a4571b | |||
| 7952c95217 | |||
| 56d8be9a55 | |||
| 29f0e6842b | |||
| 22e96bf49d | |||
| 1e4e34ef71 | |||
| d98f7da7b9 | |||
| 94e768ef51 | |||
| 36dbfdb7c4 | |||
| 5cfd8f3c1a | |||
| 1d7369e456 | |||
| de467c0d4a | |||
| 0225e49beb | |||
| e1ecec502b | |||
| 000731a289 | |||
| 385bef0752 | |||
| 902ae55a9a | |||
| feb08ff903 | |||
| a922b11b6d | |||
| 254d556899 | |||
| 6793c53002 | |||
| 984156ca95 | |||
| 8b671fd005 | |||
| 37ad8dd24c | |||
| 6ae7388a44 | |||
| 4f78e31277 | |||
| 35f128d949 | |||
| 825e643959 | |||
| eb6b81b3dd | |||
| 8638311065 | |||
| 67c91c65ab | |||
| 365e7f00fd | |||
| d54e248d02 | |||
| ec54893106 | |||
| fe7c45a635 | |||
| 2dddfa473a | |||
| c59728c5a8 | |||
| 8f3c1bcef9 | |||
| 45558f3228 | |||
| a1ae678f6d | |||
| 82c0f3a58b | |||
| a6fe497cad | |||
| e3283af13f | |||
| e205382f52 | |||
| a235ee9abc | |||
| 6a4748e4d6 | |||
| a32cbdcb35 | |||
| 5c026641c7 | |||
| 43ebed6b39 | |||
| c7e9f664e2 | |||
| 10032fd6a9 | |||
| ddec58e302 | |||
| 047e6c46af | |||
| 9f215b9dfa | |||
| cc2a411480 | |||
| c246328540 | |||
| 021283fe7e | |||
| bf25471571 | |||
| 8d50de12d7 | |||
| dbdf7be51a | |||
| d5eee17e8f | |||
| 82a7bbe63c | |||
| 7435db170c | |||
| fe453a8454 | |||
| fc37696779 | |||
| d0ada72b68 | |||
| e3167e7175 | |||
| 541a20c694 | |||
| 5d3f26dfee | |||
| c59a0be5ec | |||
| fea9f4089c | |||
| cac8f33aa7 | |||
| 543aceaeab | |||
| 1d2e3bb52f | |||
| 98f8b5904c | |||
| cfdbeb7ecb | |||
| 57fcd04ff7 | |||
| 993490e4bf | |||
| 448fbfd19a | |||
| 9e1df7c03d | |||
| d06a4b433a | |||
| 16bc0d3188 | |||
| 65152e51d3 | |||
| a589ca8337 | |||
| 067e67e08b | |||
| 0f4a3242b1 | |||
| 1af673df17 | |||
| 31a3eeef12 | |||
| 4ca16747af | |||
| 563e0e6294 | |||
| 5d85be8937 | |||
| 1eed53ae9c | |||
| fcc6c7e538 | |||
| eeb423fcbc | |||
| 0c9a94a07f | |||
| 9e730ad179 | |||
| 4ba20a793d | |||
| e725f0fcea | |||
| e8af5349e6 | |||
| 870b15d947 | |||
| eb751f28fc | |||
| 0d59ed7003 | |||
| 57048d3a3f | |||
| 6645678ed2 | |||
| 621f7d3d64 | |||
| b9a7a6f222 | |||
| e5f3d15ac1 | |||
| b776cea826 | |||
| d4c7bbc183 | |||
| ee4799c287 | |||
| fbdcfacb21 | |||
| f0e7a20e6b | |||
| 5a25f6d398 | |||
| b92b973f8f | |||
| 322906ff70 | |||
| 2c3fef03fb | |||
| 10cd39073d | |||
| 935f8ef7d8 | |||
| 640a6d6f26 | |||
| 92785965b2 | |||
| 405f030364 | |||
| c89ce6cba0 | |||
| 6995e87fe3 | |||
| a48742b681 | |||
| fb14e3135c | |||
| 169e35fc36 | |||
| 08d093915d | |||
| a41115819e | |||
| c954eca13c | |||
| 948add8978 | |||
| a9b088dcda | |||
| 3872d33547 | |||
| 51389c00d4 | |||
| 5c6b7601ff | |||
| c90bbfd66e | |||
| 5c089a4325 | |||
| 47c149cbe8 | |||
| 7b5f6cb9f1 | |||
| 3a04f00f93 | |||
| 79f7a3db03 | |||
| ac6a0085be | |||
| 89ae0e3177 | |||
| 81020b66ba | |||
| 4ee2806d28 | |||
| 988f8f5ed6 | |||
| ada68f2ce7 |
@@ -0,0 +1,25 @@
|
|||||||
|
name-template: "Release $COMPLETE"
|
||||||
|
tag-template: "v$COMPLETE"
|
||||||
|
draft: false
|
||||||
|
|
||||||
|
exclude:
|
||||||
|
pulls: true
|
||||||
|
exclude-labels:
|
||||||
|
- changelog-ignore
|
||||||
|
|
||||||
|
categories:
|
||||||
|
- title: "Features"
|
||||||
|
labels: ["feature", "enhancement"]
|
||||||
|
- title: "Fixes"
|
||||||
|
labels: ["bug"]
|
||||||
|
- title: "Maintenance"
|
||||||
|
labels: ["chore", "refactor"]
|
||||||
|
|
||||||
|
change-template: "- $TITLE [#$NUMBER]"
|
||||||
|
|
||||||
|
template: |
|
||||||
|
# Release $RESOLVED_VERSION
|
||||||
|
|
||||||
|
## Changes
|
||||||
|
|
||||||
|
$CHANGES
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
name-template: "Release $COMPLETE"
|
||||||
|
tag-template: "v$COMPLETE"
|
||||||
|
draft: false
|
||||||
|
|
||||||
|
exclude:
|
||||||
|
pulls: true
|
||||||
|
exclude-labels:
|
||||||
|
- changelog-ignore
|
||||||
|
|
||||||
|
categories:
|
||||||
|
- title: "Features"
|
||||||
|
labels: ["feature", "enhancement"]
|
||||||
|
- title: "Fixes"
|
||||||
|
labels: ["bug"]
|
||||||
|
- title: "Maintenance"
|
||||||
|
labels: ["chore", "refactor"]
|
||||||
|
|
||||||
|
change-template: "- $TITLE [#$NUMBER]"
|
||||||
|
|
||||||
|
template: |
|
||||||
|
## Changes
|
||||||
|
|
||||||
|
$CHANGES
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
name: Auto-label PRs
|
||||||
|
|
||||||
|
on:
|
||||||
|
pull_request:
|
||||||
|
types: [opened, reopened, synchronize, edited]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
label-changelog-ignore:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Label PRs
|
||||||
|
uses: actions/github-script@v7
|
||||||
|
with:
|
||||||
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
script: |
|
||||||
|
const base = context.payload.pull_request.base.ref;
|
||||||
|
const head = context.payload.pull_request.head.ref;
|
||||||
|
|
||||||
|
if ((base === 'sportsmanager2-prod' && head === 'sportsmanager2-stage') || (base === 'sportsmanager2-stage' && head === 'sportsmanager2-dev')) {
|
||||||
|
await github.rest.issues.addLabels({
|
||||||
|
...context.repo,
|
||||||
|
issue_number: context.payload.pull_request.number,
|
||||||
|
labels: ['changelog-ignore']
|
||||||
|
});
|
||||||
|
}
|
||||||
@@ -0,0 +1,81 @@
|
|||||||
|
# This workflow will run release using node and then publish a package to GitHub Packages when a release is created
|
||||||
|
# For more information see: https://docs.github.com/en/actions/publishing-packages/publishing-nodejs-packages
|
||||||
|
|
||||||
|
name: Sportsmanager Release
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
tags:
|
||||||
|
- 'v[0-9]+.[0-9]+.[0-9]+' # run only on version tags like v1.0.0
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Checkout code
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
ref: sportsmanager2-prod
|
||||||
|
|
||||||
|
- name: Set up Node.js
|
||||||
|
uses: actions/setup-node@v4
|
||||||
|
with:
|
||||||
|
node-version: 20
|
||||||
|
|
||||||
|
- name: Install npm dependencies
|
||||||
|
run: npm ci
|
||||||
|
|
||||||
|
- name: Generate release notes
|
||||||
|
id: release_notes_extension
|
||||||
|
uses: release-drafter/release-drafter@v6
|
||||||
|
with:
|
||||||
|
config-name: release-drafter_extension.yml
|
||||||
|
version: ${{ github.ref_name }}
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
|
- name: Save release notes to file
|
||||||
|
run: |
|
||||||
|
echo "${{ steps.release_notes_extension.outputs.body }}" > RELEASE_NOTES.md
|
||||||
|
|
||||||
|
- name: Run build script
|
||||||
|
run: npm run release
|
||||||
|
|
||||||
|
- name: Generate release notes
|
||||||
|
id: release_notes_github
|
||||||
|
uses: release-drafter/release-drafter@v6
|
||||||
|
with:
|
||||||
|
config-name: release-drafter_github.yml
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
|
- name: Save release notes to file
|
||||||
|
run: |
|
||||||
|
echo "${{ steps.release_notes_github.outputs.body }}" > RELEASE_NOTES.md
|
||||||
|
|
||||||
|
- name: Create GitHub Release
|
||||||
|
uses: softprops/action-gh-release@v2
|
||||||
|
with:
|
||||||
|
tag_name: "${{ github.ref_name }}"
|
||||||
|
name: "Release ${{ github.ref_name }}"
|
||||||
|
files: package/packages/com_sportsmanager.zip
|
||||||
|
body_path: "RELEASE_NOTES.md"
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
|
- name: Delete draft release via API # workaround: remove leftover draft by release-drafter
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
REPO: ${{ github.repository }}
|
||||||
|
run: |
|
||||||
|
drafts=$(curl -s -H "Authorization: token $GITHUB_TOKEN" \
|
||||||
|
https://api.github.com/repos/$REPO/releases | jq '.[] | select(.draft == true)')
|
||||||
|
|
||||||
|
if [ -n "$drafts" ]; then
|
||||||
|
id=$(echo "$drafts" | jq -r '.id')
|
||||||
|
curl -s -X DELETE -H "Authorization: token $GITHUB_TOKEN" \
|
||||||
|
https://api.github.com/repos/$REPO/releases/$id
|
||||||
|
echo "Deleted draft release with ID: $id"
|
||||||
|
else
|
||||||
|
echo "No draft releases found"
|
||||||
|
fi
|
||||||
@@ -0,0 +1,39 @@
|
|||||||
|
# This workflow will run release using node and then publish a package to GitHub Packages when a release is created
|
||||||
|
# For more information see: https://docs.github.com/en/actions/publishing-packages/publishing-nodejs-packages
|
||||||
|
|
||||||
|
name: Snapshot Release
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
tags:
|
||||||
|
- 'v[0-9]+.[0-9]+.[0-9]+-snapshot' # run only on version tags like v1.0.0-snapshot
|
||||||
|
# - 'v*' # Run only on version tags like v1.0.0
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Checkout code
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
ref: sportsmanager2-stage
|
||||||
|
|
||||||
|
- name: Set up Node.js
|
||||||
|
uses: actions/setup-node@v4
|
||||||
|
with:
|
||||||
|
node-version: 20
|
||||||
|
|
||||||
|
- name: Install npm dependencies
|
||||||
|
run: npm ci
|
||||||
|
|
||||||
|
- name: Run build script
|
||||||
|
run: npm run release
|
||||||
|
|
||||||
|
- name: Create GitHub Release
|
||||||
|
uses: softprops/action-gh-release@v2
|
||||||
|
with:
|
||||||
|
prerelease: true
|
||||||
|
name: "Snapshot ${{ github.ref_name }}"
|
||||||
|
files: package/packages/com_sportsmanager.zip
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
name: Deploy production branch to dtfb.de
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches: ['production']
|
||||||
|
paths: ['src/structure/**']
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
deploy:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- name: rsync deployments
|
||||||
|
uses: burnett01/rsync-deployments@7.0.1
|
||||||
|
with:
|
||||||
|
switches: -avzr
|
||||||
|
path: src/structure/
|
||||||
|
remote_path: ${{ secrets.DTFB_PROD_PATH }}
|
||||||
|
remote_host: ${{ secrets.DTFB_PROD_HOST }}
|
||||||
|
remote_port: ${{ secrets.DTFB_PROD_PORT }}
|
||||||
|
remote_user: ${{ secrets.DTFB_PROD_USER }}
|
||||||
|
remote_key: ${{ secrets.DTFB_PROD_KEY }}
|
||||||
|
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
name: Deploy dev branch to stage.dtfb.de
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches: ['dev']
|
||||||
|
paths: ['src/structure/**']
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
deploy:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- name: rsync deployments
|
||||||
|
uses: burnett01/rsync-deployments@7.0.1
|
||||||
|
with:
|
||||||
|
switches: -avzr
|
||||||
|
path: src/structure/
|
||||||
|
remote_path: ${{ secrets.DTFB_STAGE_PATH }}
|
||||||
|
remote_host: ${{ secrets.DTFB_STAGE_HOST }}
|
||||||
|
remote_port: ${{ secrets.DTFB_STAGE_PORT }}
|
||||||
|
remote_user: ${{ secrets.DTFB_STAGE_USER }}
|
||||||
|
remote_key: ${{ secrets.DTFB_STAGE_KEY }}
|
||||||
|
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
name: Deploy production branch to kickern-hamburg.de
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches: ['production']
|
||||||
|
paths: ['src/structure/**']
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
deploy:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- name: rsync deployments
|
||||||
|
uses: burnett01/rsync-deployments@7.0.1
|
||||||
|
with:
|
||||||
|
switches: -avzr
|
||||||
|
path: src/structure/
|
||||||
|
remote_path: ${{ secrets.KICKERN_PROD_PATH }}
|
||||||
|
remote_host: ${{ secrets.KICKERN_PROD_HOST }}
|
||||||
|
remote_port: ${{ secrets.KICKERN_PROD_PORT }}
|
||||||
|
remote_user: ${{ secrets.KICKERN_PROD_USER }}
|
||||||
|
remote_key: ${{ secrets.KICKERN_PROD_KEY }}
|
||||||
|
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
name: Deploy dev branch to stage.kickern-hamburg.de
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches: ['dev']
|
||||||
|
paths: ['src/structure/**']
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
deploy:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- name: rsync deployments
|
||||||
|
uses: burnett01/rsync-deployments@7.0.1
|
||||||
|
with:
|
||||||
|
switches: -avzr
|
||||||
|
path: src/structure/
|
||||||
|
remote_path: ${{ secrets.KICKERN_STAGE_PATH }}
|
||||||
|
remote_host: ${{ secrets.KICKERN_STAGE_HOST }}
|
||||||
|
remote_port: ${{ secrets.KICKERN_STAGE_PORT }}
|
||||||
|
remote_user: ${{ secrets.KICKERN_STAGE_USER }}
|
||||||
|
remote_key: ${{ secrets.KICKERN_STAGE_KEY }}
|
||||||
|
|
||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
### WebStorm/IntelliJ ###
|
### WebStorm/IntelliJ ###
|
||||||
/.idea
|
/.idea
|
||||||
|
.DS_Store
|
||||||
# Dependency directories
|
# Dependency directories
|
||||||
/node_modules
|
/node_modules
|
||||||
|
|
||||||
|
|||||||
@@ -1,22 +1,85 @@
|
|||||||
# SportsManager
|
# SportsManager
|
||||||
|
|
||||||
## Deploy status
|
## DEV/STAGE environments
|
||||||
|
|
||||||
### DEV environment
|
| LV | HOSTER | DOMAIN | BRANCH |
|
||||||
[](https://buddy.kicktemp.com/kicktemp/com-sportsmanager/pipelines/pipeline/173) [Preview: sportsmanager.s10.kicktemp.dev](https://sportsmanager.s10.kicktemp.dev)
|
| ------ | -------- | ------------------------------------------------------------ | -------------------- |
|
||||||
|
| DTFB | Kicktemp | [stage.dtfb.de](https://stage.dtfb.de) | dev |
|
||||||
|
| TFVHH | Kicktemp | [stage.kickern-hamburg.de](https://stage.kickern-hamburg.de) | dev |
|
||||||
|
| STFVH | DTFB | [stage.stfv.de](https://stage.stfv.de/) | sportsmanager2-stage |
|
||||||
|
| MTFV | DTFB | [stage.mtfv.de](https://stage.mtfv.de/) | ? |
|
||||||
|
| TFVSH | DTFB | [relaunch.tfvsh.de](https://relaunch.tfvsh.de) | ? |
|
||||||
|
|
||||||
[](https://buddy.kicktemp.com/kicktemp/com-sportsmanager/pipelines/pipeline/204) [Preview: stage.kickern-hamburg.de](https://stage.kickern-hamburg.de)
|
|
||||||
|
|
||||||
### PROD environment
|
## PROD environments
|
||||||
[](https://buddy.kicktemp.com/kicktemp/com-sportsmanager/pipelines/pipeline/145) [Preview: dtfb.de](https://dtfb.de)
|
|
||||||
|
|
||||||
[](https://buddy.kicktemp.com/kicktemp/com-sportsmanager/pipelines/pipeline/174) [Preview: kickern-hamburg.de](https://kickern-hamburg.de)
|
| LV | HOSTER | DOMAIN | BRANCH |
|
||||||
|
| ------ | -------- | ------------------------------------------------ | ------------------- |
|
||||||
|
| DTFB | Kicktemp | [dtfb.de](https://dtfb.de) | production |
|
||||||
|
| TFVHH | Kicktemp | [kickern-hamburg.de](https://kickern-hamburg.de) | production |
|
||||||
|
| MTFV | DTFB | [mtfv.de](https://mtfv.de/) | sportsmanager2-prod |
|
||||||
|
| TFVSH | DTFB | [tfvsh.de](https://tfvsh.de/) | sportsmanager2-prod |
|
||||||
|
| STFVH | DTFB | [stfv.de](https://stfv.de/) | sportsmanager2-prod |
|
||||||
|
|
||||||
## local dev environment
|
|
||||||
- install docker
|
|
||||||
- docker-compose up
|
|
||||||
- in data/joomla_data/ die kickstarter datei von akeeba ablegen und das backup von der dtfb seite
|
|
||||||
- https://www.akeeba.com/download/akeeba-kickstart/7-1-2/kickstart-core-7-1-2-zip.raw
|
|
||||||
- das auspacke
|
|
||||||
- localhost/kickstart.php aufrufen
|
|
||||||
|
|
||||||
|
## Test setup
|
||||||
|
### Installation
|
||||||
|
To start joomla and the database, run
|
||||||
|
|
||||||
|
```shell
|
||||||
|
docker-compose up -d
|
||||||
|
```
|
||||||
|
|
||||||
|
### Release creation
|
||||||
|
To create a release execute
|
||||||
|
```shell
|
||||||
|
npm run release
|
||||||
|
```
|
||||||
|
|
||||||
|
### Deployment
|
||||||
|
Deployment can only be done manually right now (sad)
|
||||||
|
To do this go to
|
||||||
|
[Testserver Extension Installer Site](http://localhost:8080/administrator/index.php?option=com_installer&view=install)
|
||||||
|
and upload the zip file found in `./package/packages`
|
||||||
|
|
||||||
|
|
||||||
|
### Development Tools
|
||||||
|
If you are using Intellij, there is a plugin named Joomla! which helps with resolving
|
||||||
|
joomla specific database prefixes like #__
|
||||||
|
To set it up, insert into the configuration popup which follows after you enable the framework support:
|
||||||
|
Joomla install path: `./data/joomla_data`
|
||||||
|
JConfig: `./data/joomla_data/configuration.php`
|
||||||
|
> This works only with mounted volumes. However, mounted volumes will slow down the joomla instance significantly.
|
||||||
|
> The current setup does not use mounted volumes.
|
||||||
|
> An alternative would be to download joomla and use that installation
|
||||||
|
|
||||||
|
### Debugging (with Docker/Intellij)
|
||||||
|
1. Start Docker Container (see above)
|
||||||
|
2. Create a terminal for that container
|
||||||
|
```shell
|
||||||
|
docker exec -it <container_name> bash
|
||||||
|
```
|
||||||
|
3. install xdebug within the container since joomla does not come with xdebug preinstalled
|
||||||
|
```shell
|
||||||
|
pecl install xdebug
|
||||||
|
```
|
||||||
|
4. restart the container
|
||||||
|
5. In Intellij Go to [File | Settings | Languages & Frameworks | PHP | Servers](jetbrains://idea/settings?name=Languages+%26+Frameworks--PHP--Servers) and setup your server
|
||||||
|
|
||||||
|
| | |
|
||||||
|
|----------|-----------|
|
||||||
|
| name | anything |
|
||||||
|
| host | localhost |
|
||||||
|
| port | 8080 |
|
||||||
|
| debugger | xdebug |
|
||||||
|
|
||||||
|
use the path mapping and map the repo structure to the container content
|
||||||
|
|
||||||
|
| File/Directory | path on server |
|
||||||
|
|------------------------------------------------------------------|----------------------------------------|
|
||||||
|
| \<path>/com_sportsmanager/src/structure/administrator/components | /var/www/html/administrator/components |
|
||||||
|
| \<path>/com_sportsmanager/src/structure/components | /var/www/html/components |
|
||||||
|
|
||||||
|
7. Click on "Start Listening for PHP Debug Connections" in the top row of intellij
|
||||||
|
8. (Not sure if optional) Install a browser extension by Jetbrains
|
||||||
|
https://chromewebstore.google.com/detail/xdebug-helper-by-jetbrain/aoelhdemabeimdhedkidlnbkfhnhgnhm
|
||||||
|
|||||||
@@ -0,0 +1,2 @@
|
|||||||
|
This is no official release!
|
||||||
|
The Release and the release notes will be generated by github actions
|
||||||
+37
-24
@@ -1,30 +1,43 @@
|
|||||||
version: '2'
|
|
||||||
services:
|
services:
|
||||||
mariadb:
|
joomla:
|
||||||
image: docker.io/bitnami/mariadb:10.3
|
image: joomla:5.2.4
|
||||||
|
restart: always
|
||||||
|
ports:
|
||||||
|
- '8080:80'
|
||||||
|
environment:
|
||||||
|
JOOMLA_DB_HOST: db
|
||||||
|
JOOMLA_DB_USER: joomla
|
||||||
|
JOOMLA_DB_PASSWORD: examplepass
|
||||||
|
JOOMLA_DB_NAME: joomla_db
|
||||||
|
JOOMLA_SITE_NAME: Sportsmanager Testserver
|
||||||
|
JOOMLA_ADMIN_USER: Joomla Hero
|
||||||
|
JOOMLA_ADMIN_USERNAME: joomla
|
||||||
|
JOOMLA_ADMIN_PASSWORD: joomla@secured
|
||||||
|
JOOMLA_ADMIN_EMAIL: joomla@example.com
|
||||||
|
volumes:
|
||||||
|
- joomla_data:/var/www/html
|
||||||
|
- './docker/php.ini:/usr/local/etc/php/php.ini'
|
||||||
|
networks:
|
||||||
|
- joomla_network
|
||||||
|
|
||||||
|
db:
|
||||||
|
image: mysql:8.0
|
||||||
|
restart: always
|
||||||
ports:
|
ports:
|
||||||
- '3306:3306'
|
- '3306:3306'
|
||||||
environment:
|
environment:
|
||||||
# ALLOW_EMPTY_PASSWORD is recommended only for development.
|
MYSQL_DATABASE: joomla_db
|
||||||
- ALLOW_EMPTY_PASSWORD=yes
|
MYSQL_USER: joomla
|
||||||
- MARIADB_USER=bn_joomla
|
MYSQL_PASSWORD: examplepass
|
||||||
- MARIADB_DATABASE=bitnami_joomla
|
MYSQL_RANDOM_ROOT_PASSWORD: '1'
|
||||||
|
TZ: Europe/Berlin
|
||||||
volumes:
|
volumes:
|
||||||
- './data/mariadb_data:/bitnami/mariadb'
|
- joomla_database:/var/lib/mysql
|
||||||
joomla:
|
networks:
|
||||||
image: docker.io/bitnami/joomla:3
|
- joomla_network
|
||||||
ports:
|
|
||||||
- '80:8080'
|
networks:
|
||||||
- '443:8443'
|
joomla_network:
|
||||||
environment:
|
|
||||||
- JOOMLA_DATABASE_HOST=mariadb
|
|
||||||
- JOOMLA_DATABASE_PORT_NUMBER=3306
|
|
||||||
- JOOMLA_DATABASE_USER=bn_joomla
|
|
||||||
- JOOMLA_DATABASE_NAME=bitnami_joomla
|
|
||||||
# ALLOW_EMPTY_PASSWORD is recommended only for development.
|
|
||||||
- ALLOW_EMPTY_PASSWORD=yes
|
|
||||||
volumes:
|
volumes:
|
||||||
- './data/joomla_data:/bitnami/joomla'
|
joomla_data:
|
||||||
- './docker/php.ini:/opt/bitnami/php/etc/php.ini:ro'
|
joomla_database:
|
||||||
depends_on:
|
|
||||||
- mariadb
|
|
||||||
|
|||||||
+77
-130
@@ -9,15 +9,15 @@
|
|||||||
; PHP attempts to find and load this configuration from a number of locations.
|
; PHP attempts to find and load this configuration from a number of locations.
|
||||||
; The following is a summary of its search order:
|
; The following is a summary of its search order:
|
||||||
; 1. SAPI module specific location.
|
; 1. SAPI module specific location.
|
||||||
; 2. The PHPRC environment variable. (As of PHP 5.2.0)
|
; 2. The PHPRC environment variable.
|
||||||
; 3. A number of predefined registry keys on Windows (As of PHP 5.2.0)
|
; 3. A number of predefined registry keys on Windows
|
||||||
; 4. Current working directory (except CLI)
|
; 4. Current working directory (except CLI)
|
||||||
; 5. The web server's directory (for SAPI modules), or directory of PHP
|
; 5. The web server's directory (for SAPI modules), or directory of PHP
|
||||||
; (otherwise in Windows)
|
; (otherwise in Windows)
|
||||||
; 6. The directory from the --with-config-file-path compile time option, or the
|
; 6. The directory from the --with-config-file-path compile time option, or the
|
||||||
; Windows directory (usually C:\windows)
|
; Windows directory (usually C:\windows)
|
||||||
; See the PHP docs for more specific information.
|
; See the PHP docs for more specific information.
|
||||||
; http://php.net/configuration.file
|
; https://php.net/configuration.file
|
||||||
|
|
||||||
; The syntax of the file is extremely simple. Whitespace and lines
|
; The syntax of the file is extremely simple. Whitespace and lines
|
||||||
; beginning with a semicolon are silently ignored (as you probably guessed).
|
; beginning with a semicolon are silently ignored (as you probably guessed).
|
||||||
@@ -31,7 +31,7 @@
|
|||||||
; special sections cannot be overridden by user-defined INI files or
|
; special sections cannot be overridden by user-defined INI files or
|
||||||
; at runtime. Currently, [PATH=] and [HOST=] sections only work under
|
; at runtime. Currently, [PATH=] and [HOST=] sections only work under
|
||||||
; CGI/FastCGI.
|
; CGI/FastCGI.
|
||||||
; http://php.net/ini.sections
|
; https://php.net/ini.sections
|
||||||
|
|
||||||
; Directives are specified using the following syntax:
|
; Directives are specified using the following syntax:
|
||||||
; directive = value
|
; directive = value
|
||||||
@@ -75,7 +75,7 @@
|
|||||||
|
|
||||||
; php.ini-production contains settings which hold security, performance and
|
; php.ini-production contains settings which hold security, performance and
|
||||||
; best practices at its core. But please be aware, these settings may break
|
; best practices at its core. But please be aware, these settings may break
|
||||||
; compatibility with older or less security conscience applications. We
|
; compatibility with older or less security-conscious applications. We
|
||||||
; recommending using the production ini in production and testing environments.
|
; recommending using the production ini in production and testing environments.
|
||||||
|
|
||||||
; php.ini-development is very similar to its production variant, except it is
|
; php.ini-development is very similar to its production variant, except it is
|
||||||
@@ -756,7 +756,7 @@ user_dir =
|
|||||||
|
|
||||||
; Directory in which the loadable extensions (modules) reside.
|
; Directory in which the loadable extensions (modules) reside.
|
||||||
; http://php.net/extension-dir
|
; http://php.net/extension-dir
|
||||||
extension_dir = /opt/bitnami/php/lib/php/extensions
|
;extension_dir = /usr/local/lib/php/extensions
|
||||||
; On windows:
|
; On windows:
|
||||||
;extension_dir = "ext"
|
;extension_dir = "ext"
|
||||||
|
|
||||||
@@ -839,7 +839,7 @@ file_uploads = On
|
|||||||
; Temporary directory for HTTP uploaded files (will use system default if not
|
; Temporary directory for HTTP uploaded files (will use system default if not
|
||||||
; specified).
|
; specified).
|
||||||
; http://php.net/upload-tmp-dir
|
; http://php.net/upload-tmp-dir
|
||||||
upload_tmp_dir = /opt/bitnami/php/tmp
|
upload_tmp_dir = /tmp
|
||||||
|
|
||||||
; Maximum allowed size for uploaded files.
|
; Maximum allowed size for uploaded files.
|
||||||
; http://php.net/upload-max-filesize
|
; http://php.net/upload-max-filesize
|
||||||
@@ -1318,7 +1318,7 @@ session.save_handler = files
|
|||||||
;
|
;
|
||||||
; The path can be defined as:
|
; The path can be defined as:
|
||||||
;
|
;
|
||||||
session.save_path = /opt/bitnami/php/var/run/session
|
session.save_path = /tmp/session
|
||||||
;
|
;
|
||||||
; where N is an integer. Instead of storing all the session files in
|
; where N is an integer. Instead of storing all the session files in
|
||||||
; /path, what this will do is use subdirectories N-levels deep, and
|
; /path, what this will do is use subdirectories N-levels deep, and
|
||||||
@@ -1334,12 +1334,10 @@ session.save_path = /opt/bitnami/php/var/run/session
|
|||||||
; The file storage module creates files using mode 600 by default.
|
; The file storage module creates files using mode 600 by default.
|
||||||
; You can change that by using
|
; You can change that by using
|
||||||
;
|
;
|
||||||
session.save_path = /opt/bitnami/php/var/run/session
|
|
||||||
;
|
;
|
||||||
; where MODE is the octal representation of the mode. Note that this
|
; where MODE is the octal representation of the mode. Note that this
|
||||||
; does not overwrite the process's umask.
|
; does not overwrite the process's umask.
|
||||||
; http://php.net/session.save-path
|
; http://php.net/session.save-path
|
||||||
session.save_path = /opt/bitnami/php/var/run/session
|
|
||||||
|
|
||||||
; Whether to use strict session mode.
|
; Whether to use strict session mode.
|
||||||
; Strict session mode does not accept an uninitialized session ID, and
|
; Strict session mode does not accept an uninitialized session ID, and
|
||||||
@@ -1539,18 +1537,18 @@ session.sid_bits_per_character = 5
|
|||||||
; Default Value: "1%"
|
; Default Value: "1%"
|
||||||
; Development Value: "1%"
|
; Development Value: "1%"
|
||||||
; Production Value: "1%"
|
; Production Value: "1%"
|
||||||
; http://php.net/session.upload-progress.freq
|
; https://php.net/session.upload-progress.freq
|
||||||
;session.upload_progress.freq = "1%"
|
;session.upload_progress.freq = "1%"
|
||||||
|
|
||||||
; The minimum delay between updates, in seconds
|
; The minimum delay between updates, in seconds
|
||||||
; Default Value: 1
|
; Default Value: 1
|
||||||
; Development Value: 1
|
; Development Value: 1
|
||||||
; Production Value: 1
|
; Production Value: 1
|
||||||
; http://php.net/session.upload-progress.min-freq
|
; https://php.net/session.upload-progress.min-freq
|
||||||
;session.upload_progress.min_freq = "1"
|
;session.upload_progress.min_freq = "1"
|
||||||
|
|
||||||
; Only write session data when session data is changed. Enabled by default.
|
; Only write session data when session data is changed. Enabled by default.
|
||||||
; http://php.net/session.lazy-write
|
; https://php.net/session.lazy-write
|
||||||
;session.lazy_write = On
|
;session.lazy_write = On
|
||||||
|
|
||||||
[Assertion]
|
[Assertion]
|
||||||
@@ -1558,67 +1556,47 @@ session.sid_bits_per_character = 5
|
|||||||
; -1: Do not compile at all
|
; -1: Do not compile at all
|
||||||
; 0: Jump over assertion at run-time
|
; 0: Jump over assertion at run-time
|
||||||
; 1: Execute assertions
|
; 1: Execute assertions
|
||||||
; Changing from or to a negative value is only possible in php.ini! (For turning assertions on and off at run-time, see assert.active, when zend.assertions = 1)
|
; Changing from or to a negative value is only possible in php.ini!
|
||||||
|
; (For turning assertions on and off at run-time, toggle zend.assertions between the values 1 and 0)
|
||||||
; Default Value: 1
|
; Default Value: 1
|
||||||
; Development Value: 1
|
; Development Value: 1
|
||||||
; Production Value: -1
|
; Production Value: -1
|
||||||
; http://php.net/zend.assertions
|
; https://php.net/zend.assertions
|
||||||
zend.assertions = -1
|
zend.assertions = -1
|
||||||
|
|
||||||
; Assert(expr); active by default.
|
|
||||||
; http://php.net/assert.active
|
|
||||||
;assert.active = On
|
|
||||||
|
|
||||||
; Throw an AssertionError on failed assertions
|
|
||||||
; http://php.net/assert.exception
|
|
||||||
;assert.exception = On
|
|
||||||
|
|
||||||
; Issue a PHP warning for each failed assertion. (Overridden by assert.exception if active)
|
|
||||||
; http://php.net/assert.warning
|
|
||||||
;assert.warning = On
|
|
||||||
|
|
||||||
; Don't bail out by default.
|
|
||||||
; http://php.net/assert.bail
|
|
||||||
;assert.bail = Off
|
|
||||||
|
|
||||||
; User-function to be called if an assertion fails.
|
|
||||||
; http://php.net/assert.callback
|
|
||||||
;assert.callback = 0
|
|
||||||
|
|
||||||
; Eval the expression with current error_reporting(). Set to true if you want
|
|
||||||
; error_reporting(0) around the eval().
|
|
||||||
; http://php.net/assert.quiet-eval
|
|
||||||
;assert.quiet_eval = 0
|
|
||||||
|
|
||||||
[COM]
|
[COM]
|
||||||
; path to a file containing GUIDs, IIDs or filenames of files with TypeLibs
|
; path to a file containing GUIDs, IIDs or filenames of files with TypeLibs
|
||||||
; http://php.net/com.typelib-file
|
; https://php.net/com.typelib-file
|
||||||
;com.typelib_file =
|
;com.typelib_file =
|
||||||
|
|
||||||
; allow Distributed-COM calls
|
; allow Distributed-COM calls
|
||||||
; http://php.net/com.allow-dcom
|
; https://php.net/com.allow-dcom
|
||||||
;com.allow_dcom = true
|
;com.allow_dcom = true
|
||||||
|
|
||||||
; autoregister constants of a component's typlib on com_load()
|
; autoregister constants of a component's typelib on com_load()
|
||||||
; http://php.net/com.autoregister-typelib
|
; https://php.net/com.autoregister-typelib
|
||||||
;com.autoregister_typelib = true
|
;com.autoregister_typelib = true
|
||||||
|
|
||||||
; register constants casesensitive
|
; register constants casesensitive
|
||||||
; http://php.net/com.autoregister-casesensitive
|
; https://php.net/com.autoregister-casesensitive
|
||||||
;com.autoregister_casesensitive = false
|
;com.autoregister_casesensitive = false
|
||||||
|
|
||||||
; show warnings on duplicate constant registrations
|
; show warnings on duplicate constant registrations
|
||||||
; http://php.net/com.autoregister-verbose
|
; https://php.net/com.autoregister-verbose
|
||||||
;com.autoregister_verbose = true
|
;com.autoregister_verbose = true
|
||||||
|
|
||||||
; The default character set code-page to use when passing strings to and from COM objects.
|
; The default character set code-page to use when passing strings to and from COM objects.
|
||||||
; Default: system ANSI code page
|
; Default: system ANSI code page
|
||||||
;com.code_page=
|
;com.code_page=
|
||||||
|
|
||||||
|
; The version of the .NET framework to use. The value of the setting are the first three parts
|
||||||
|
; of the framework's version number, separated by dots, and prefixed with "v", e.g. "v4.0.30319".
|
||||||
|
;com.dotnet_version=
|
||||||
|
|
||||||
[mbstring]
|
[mbstring]
|
||||||
; language for internal character representation.
|
; language for internal character representation.
|
||||||
; This affects mb_send_mail() and mbstring.detect_order.
|
; This affects mb_send_mail() and mbstring.detect_order.
|
||||||
; http://php.net/mbstring.language
|
; https://php.net/mbstring.language
|
||||||
;mbstring.language = Japanese
|
;mbstring.language = Japanese
|
||||||
|
|
||||||
; Use of this INI entry is deprecated, use global internal_encoding instead.
|
; Use of this INI entry is deprecated, use global internal_encoding instead.
|
||||||
@@ -1633,7 +1611,7 @@ zend.assertions = -1
|
|||||||
; mbstring.encoding_translation = On is needed to use this setting.
|
; mbstring.encoding_translation = On is needed to use this setting.
|
||||||
; If empty, default_charset or input_encoding or mbstring.input is used.
|
; If empty, default_charset or input_encoding or mbstring.input is used.
|
||||||
; The precedence is: default_charset < input_encoding < mbstring.http_input
|
; The precedence is: default_charset < input_encoding < mbstring.http_input
|
||||||
; http://php.net/mbstring.http-input
|
; https://php.net/mbstring.http-input
|
||||||
;mbstring.http_input =
|
;mbstring.http_input =
|
||||||
|
|
||||||
; Use of this INI entry is deprecated, use global output_encoding instead.
|
; Use of this INI entry is deprecated, use global output_encoding instead.
|
||||||
@@ -1643,7 +1621,7 @@ zend.assertions = -1
|
|||||||
; The precedence is: default_charset < output_encoding < mbstring.http_output
|
; The precedence is: default_charset < output_encoding < mbstring.http_output
|
||||||
; To use an output encoding conversion, mbstring's output handler must be set
|
; To use an output encoding conversion, mbstring's output handler must be set
|
||||||
; otherwise output encoding conversion cannot be performed.
|
; otherwise output encoding conversion cannot be performed.
|
||||||
; http://php.net/mbstring.http-output
|
; https://php.net/mbstring.http-output
|
||||||
;mbstring.http_output =
|
;mbstring.http_output =
|
||||||
|
|
||||||
; enable automatic encoding translation according to
|
; enable automatic encoding translation according to
|
||||||
@@ -1651,54 +1629,40 @@ zend.assertions = -1
|
|||||||
; converted to internal encoding by setting this to On.
|
; converted to internal encoding by setting this to On.
|
||||||
; Note: Do _not_ use automatic encoding translation for
|
; Note: Do _not_ use automatic encoding translation for
|
||||||
; portable libs/applications.
|
; portable libs/applications.
|
||||||
; http://php.net/mbstring.encoding-translation
|
; https://php.net/mbstring.encoding-translation
|
||||||
;mbstring.encoding_translation = Off
|
;mbstring.encoding_translation = Off
|
||||||
|
|
||||||
; automatic encoding detection order.
|
; automatic encoding detection order.
|
||||||
; "auto" detect order is changed according to mbstring.language
|
; "auto" detect order is changed according to mbstring.language
|
||||||
; http://php.net/mbstring.detect-order
|
; https://php.net/mbstring.detect-order
|
||||||
;mbstring.detect_order = auto
|
;mbstring.detect_order = auto
|
||||||
|
|
||||||
; substitute_character used when character cannot be converted
|
; substitute_character used when character cannot be converted
|
||||||
; one from another
|
; one from another
|
||||||
; http://php.net/mbstring.substitute-character
|
; https://php.net/mbstring.substitute-character
|
||||||
;mbstring.substitute_character = none
|
;mbstring.substitute_character = none
|
||||||
|
|
||||||
; overload(replace) single byte functions by mbstring functions.
|
; Enable strict encoding detection.
|
||||||
; mail(), ereg(), etc are overloaded by mb_send_mail(), mb_ereg(),
|
;mbstring.strict_detection = Off
|
||||||
; etc. Possible values are 0,1,2,4 or combination of them.
|
|
||||||
; For example, 7 for overload everything.
|
|
||||||
; 0: No overload
|
|
||||||
; 1: Overload mail() function
|
|
||||||
; 2: Overload str*() functions
|
|
||||||
; 4: Overload ereg*() functions
|
|
||||||
; http://php.net/mbstring.func-overload
|
|
||||||
;mbstring.func_overload = 0
|
|
||||||
|
|
||||||
; enable strict encoding detection.
|
|
||||||
; Default: Off
|
|
||||||
;mbstring.strict_detection = On
|
|
||||||
|
|
||||||
; This directive specifies the regex pattern of content types for which mb_output_handler()
|
; This directive specifies the regex pattern of content types for which mb_output_handler()
|
||||||
; is activated.
|
; is activated.
|
||||||
; Default: mbstring.http_output_conv_mimetype=^(text/|application/xhtml\+xml)
|
; Default: mbstring.http_output_conv_mimetypes=^(text/|application/xhtml\+xml)
|
||||||
;mbstring.http_output_conv_mimetype=
|
;mbstring.http_output_conv_mimetypes=
|
||||||
|
|
||||||
; This directive specifies maximum stack depth for mbstring regular expressions. It is similar
|
; This directive specifies maximum stack depth for mbstring regular expressions. It is similar
|
||||||
; to the pcre.recursion_limit for PCRE.
|
; to the pcre.recursion_limit for PCRE.
|
||||||
; Default: 100000
|
|
||||||
;mbstring.regex_stack_limit=100000
|
;mbstring.regex_stack_limit=100000
|
||||||
|
|
||||||
; This directive specifies maximum retry count for mbstring regular expressions. It is similar
|
; This directive specifies maximum retry count for mbstring regular expressions. It is similar
|
||||||
; to the pcre.backtrack_limit for PCRE.
|
; to the pcre.backtrack_limit for PCRE.
|
||||||
; Default: 1000000
|
|
||||||
;mbstring.regex_retry_limit=1000000
|
;mbstring.regex_retry_limit=1000000
|
||||||
|
|
||||||
[gd]
|
[gd]
|
||||||
; Tell the jpeg decode to ignore warnings and try to create
|
; Tell the jpeg decode to ignore warnings and try to create
|
||||||
; a gd image. The warning will then be displayed as notices
|
; a gd image. The warning will then be displayed as notices
|
||||||
; disabled by default
|
; disabled by default
|
||||||
; http://php.net/gd.jpeg-ignore-warning
|
; https://php.net/gd.jpeg-ignore-warning
|
||||||
;gd.jpeg_ignore_warning = 1
|
;gd.jpeg_ignore_warning = 1
|
||||||
|
|
||||||
[exif]
|
[exif]
|
||||||
@@ -1706,48 +1670,48 @@ zend.assertions = -1
|
|||||||
; With mbstring support this will automatically be converted into the encoding
|
; With mbstring support this will automatically be converted into the encoding
|
||||||
; given by corresponding encode setting. When empty mbstring.internal_encoding
|
; given by corresponding encode setting. When empty mbstring.internal_encoding
|
||||||
; is used. For the decode settings you can distinguish between motorola and
|
; is used. For the decode settings you can distinguish between motorola and
|
||||||
; intel byte order. A decode setting cannot be empty.
|
; intel byte order. A decode setting must not be empty.
|
||||||
; http://php.net/exif.encode-unicode
|
; https://php.net/exif.encode-unicode
|
||||||
;exif.encode_unicode = ISO-8859-15
|
;exif.encode_unicode = ISO-8859-15
|
||||||
|
|
||||||
; http://php.net/exif.decode-unicode-motorola
|
; https://php.net/exif.decode-unicode-motorola
|
||||||
;exif.decode_unicode_motorola = UCS-2BE
|
;exif.decode_unicode_motorola = UCS-2BE
|
||||||
|
|
||||||
; http://php.net/exif.decode-unicode-intel
|
; https://php.net/exif.decode-unicode-intel
|
||||||
;exif.decode_unicode_intel = UCS-2LE
|
;exif.decode_unicode_intel = UCS-2LE
|
||||||
|
|
||||||
; http://php.net/exif.encode-jis
|
; https://php.net/exif.encode-jis
|
||||||
;exif.encode_jis =
|
;exif.encode_jis =
|
||||||
|
|
||||||
; http://php.net/exif.decode-jis-motorola
|
; https://php.net/exif.decode-jis-motorola
|
||||||
;exif.decode_jis_motorola = JIS
|
;exif.decode_jis_motorola = JIS
|
||||||
|
|
||||||
; http://php.net/exif.decode-jis-intel
|
; https://php.net/exif.decode-jis-intel
|
||||||
;exif.decode_jis_intel = JIS
|
;exif.decode_jis_intel = JIS
|
||||||
|
|
||||||
[Tidy]
|
[Tidy]
|
||||||
; The path to a default tidy configuration file to use when using tidy
|
; The path to a default tidy configuration file to use when using tidy
|
||||||
; http://php.net/tidy.default-config
|
; https://php.net/tidy.default-config
|
||||||
;tidy.default_config = /usr/local/lib/php/default.tcfg
|
;tidy.default_config = /usr/local/lib/php/default.tcfg
|
||||||
|
|
||||||
; Should tidy clean and repair output automatically?
|
; Should tidy clean and repair output automatically?
|
||||||
; WARNING: Do not use this option if you are generating non-html content
|
; WARNING: Do not use this option if you are generating non-html content
|
||||||
; such as dynamic images
|
; such as dynamic images
|
||||||
; http://php.net/tidy.clean-output
|
; https://php.net/tidy.clean-output
|
||||||
tidy.clean_output = Off
|
tidy.clean_output = Off
|
||||||
|
|
||||||
[soap]
|
[soap]
|
||||||
; Enables or disables WSDL caching feature.
|
; Enables or disables WSDL caching feature.
|
||||||
; http://php.net/soap.wsdl-cache-enabled
|
; https://php.net/soap.wsdl-cache-enabled
|
||||||
soap.wsdl_cache_enabled=1
|
soap.wsdl_cache_enabled=1
|
||||||
|
|
||||||
; Sets the directory name where SOAP extension will put cache files.
|
; Sets the directory name where SOAP extension will put cache files.
|
||||||
; http://php.net/soap.wsdl-cache-dir
|
; https://php.net/soap.wsdl-cache-dir
|
||||||
soap.wsdl_cache_dir="/tmp"
|
soap.wsdl_cache_dir="/tmp"
|
||||||
|
|
||||||
; (time to live) Sets the number of second while cached file will be used
|
; (time to live) Sets the number of second while cached file will be used
|
||||||
; instead of original one.
|
; instead of original one.
|
||||||
; http://php.net/soap.wsdl-cache-ttl
|
; https://php.net/soap.wsdl-cache-ttl
|
||||||
soap.wsdl_cache_ttl=86400
|
soap.wsdl_cache_ttl=86400
|
||||||
|
|
||||||
; Sets the size of the cache limit. (Max. number of WSDL files to cache)
|
; Sets the size of the cache limit. (Max. number of WSDL files to cache)
|
||||||
@@ -1806,6 +1770,11 @@ opcache.revalidate_freq = 60
|
|||||||
; size of the optimized code.
|
; size of the optimized code.
|
||||||
;opcache.save_comments=1
|
;opcache.save_comments=1
|
||||||
|
|
||||||
|
; If enabled, compilation warnings (including notices and deprecations) will
|
||||||
|
; be recorded and replayed each time a file is included. Otherwise, compilation
|
||||||
|
; warnings will only be emitted when the file is first cached.
|
||||||
|
;opcache.record_warnings=0
|
||||||
|
|
||||||
; Allow file existence override (file_exists, etc.) performance feature.
|
; Allow file existence override (file_exists, etc.) performance feature.
|
||||||
;opcache.enable_file_override=0
|
;opcache.enable_file_override=0
|
||||||
|
|
||||||
@@ -1827,10 +1796,6 @@ opcache.revalidate_freq = 60
|
|||||||
; are cached.
|
; are cached.
|
||||||
;opcache.max_file_size=0
|
;opcache.max_file_size=0
|
||||||
|
|
||||||
; Check the cache checksum each N requests.
|
|
||||||
; The default value of "0" means that the checks are disabled.
|
|
||||||
;opcache.consistency_checks=0
|
|
||||||
|
|
||||||
; How long to wait (in seconds) for a scheduled restart to begin if the cache
|
; How long to wait (in seconds) for a scheduled restart to begin if the cache
|
||||||
; is not being accessed.
|
; is not being accessed.
|
||||||
;opcache.force_restart_timeout=180
|
;opcache.force_restart_timeout=180
|
||||||
@@ -1868,7 +1833,16 @@ opcache.revalidate_freq = 60
|
|||||||
; Enables and sets the second level cache directory.
|
; Enables and sets the second level cache directory.
|
||||||
; It should improve performance when SHM memory is full, at server restart or
|
; It should improve performance when SHM memory is full, at server restart or
|
||||||
; SHM reset. The default "" disables file based caching.
|
; SHM reset. The default "" disables file based caching.
|
||||||
opcache.file_cache = /opt/bitnami/php/var/run/opcache_file
|
opcache.file_cache = /tmp/opcache_file
|
||||||
|
|
||||||
|
; Enables or disables read-only mode for the second level cache directory.
|
||||||
|
; It should improve performance for read-only containers,
|
||||||
|
; when the cache is pre-warmed and packaged alongside the application.
|
||||||
|
; Best used with `opcache.validate_timestamps=0`, `opcache.enable_file_override=1`
|
||||||
|
; and `opcache.file_cache_consistency_checks=0`.
|
||||||
|
; Note: A cache generated with a different build of PHP, a different file path,
|
||||||
|
; or different settings (including which extensions are loaded), may be ignored.
|
||||||
|
;opcache.file_cache_read_only=0
|
||||||
|
|
||||||
; Enables or disables opcode caching in shared memory.
|
; Enables or disables opcode caching in shared memory.
|
||||||
;opcache.file_cache_only=0
|
;opcache.file_cache_only=0
|
||||||
@@ -1882,8 +1856,13 @@ opcache.file_cache = /opt/bitnami/php/var/run/opcache_file
|
|||||||
;opcache.file_cache_fallback=1
|
;opcache.file_cache_fallback=1
|
||||||
|
|
||||||
; Enables or disables copying of PHP code (text segment) into HUGE PAGES.
|
; Enables or disables copying of PHP code (text segment) into HUGE PAGES.
|
||||||
; This should improve performance, but requires appropriate OS configuration.
|
; Under certain circumstances (if only a single global PHP process is
|
||||||
;opcache.huge_code_pages=1
|
; started from which all others fork), this can increase performance
|
||||||
|
; by a tiny amount because TLB misses are reduced. On the other hand, this
|
||||||
|
; delays PHP startup, increases memory usage and degrades performance
|
||||||
|
; under memory pressure - use with care.
|
||||||
|
; Requires appropriate OS configuration.
|
||||||
|
;opcache.huge_code_pages=0
|
||||||
|
|
||||||
; Validate cached file permissions.
|
; Validate cached file permissions.
|
||||||
;opcache.validate_permission=0
|
;opcache.validate_permission=0
|
||||||
@@ -1897,12 +1876,12 @@ opcache.file_cache = /opt/bitnami/php/var/run/opcache_file
|
|||||||
|
|
||||||
; Specifies a PHP script that is going to be compiled and executed at server
|
; Specifies a PHP script that is going to be compiled and executed at server
|
||||||
; start-up.
|
; start-up.
|
||||||
; http://php.net/opcache.preload
|
; https://php.net/opcache.preload
|
||||||
;opcache.preload=
|
;opcache.preload=
|
||||||
|
|
||||||
; Preloading code as root is not allowed for security reasons. This directive
|
; Preloading code as root is not allowed for security reasons. This directive
|
||||||
; facilitates to let the preloading to be run as another user.
|
; facilitates to let the preloading to be run as another user.
|
||||||
; http://php.net/opcache.preload_user
|
; https://php.net/opcache.preload_user
|
||||||
;opcache.preload_user=
|
;opcache.preload_user=
|
||||||
|
|
||||||
; Prevents caching files that are less than this number of seconds old. It
|
; Prevents caching files that are less than this number of seconds old. It
|
||||||
@@ -1945,44 +1924,12 @@ opcache.file_cache = /opt/bitnami/php/var/run/opcache_file
|
|||||||
|
|
||||||
; List of headers files to preload, wildcard patterns allowed.
|
; List of headers files to preload, wildcard patterns allowed.
|
||||||
;ffi.preload=
|
;ffi.preload=
|
||||||
zend_extension = opcache
|
|
||||||
opcache.fast_shutdown = 1
|
|
||||||
;extension = pdo_dblib
|
|
||||||
;extension = apcu
|
|
||||||
;extension = mcrypt
|
|
||||||
;extension = imagick
|
|
||||||
;extension = memcached
|
|
||||||
;extension = maxminddb
|
|
||||||
;extension = mongodb
|
|
||||||
|
|
||||||
;[XDebug]
|
zend_extension=xdebug.so
|
||||||
zend_extension = xdebug
|
|
||||||
xdebug.mode=debug
|
xdebug.mode=debug
|
||||||
;xdebug.client_host = 127.0.0.1
|
|
||||||
;xdebug.client_port = 9000
|
|
||||||
;xdebug.output_dir = /tmp
|
|
||||||
;xdebug.remote_handler = dbgp
|
|
||||||
|
|
||||||
;xdebug.remote_port=9000
|
|
||||||
;xdebug.remote_host=10.254.254.254
|
|
||||||
;xdebug.remote_autostart=1
|
|
||||||
;xdebug.remote_enable=1
|
|
||||||
;xdebug.default_enable=0
|
|
||||||
;xdebug.remote_host=host.docker.internal
|
|
||||||
;xdebug.remote_port=9000
|
|
||||||
;xdebug.remote_connect_back=0
|
|
||||||
;xdebug.profiler_enable=0
|
|
||||||
;xdebug.remote_log="/tmp/xdebug.log"
|
|
||||||
xdebug.mode=debug
|
|
||||||
xdebug.client_port=9000
|
|
||||||
xdebug.client_host=host.docker.internal
|
|
||||||
xdebug.remote_handler=dbgp
|
|
||||||
;xdebug.remote_host=host.docker.internal
|
|
||||||
;xdebug.remote_port=9000
|
|
||||||
xdebug.start_with_request=yes
|
xdebug.start_with_request=yes
|
||||||
xdebug.discover_client_host=0
|
xdebug.client_host=host.docker.internal
|
||||||
xdebug.idekey=PHPSTORM
|
xdebug.client_port=9003
|
||||||
xdebug.show_error_trace = 1
|
xdebug.log=/tmp/xdebug.log
|
||||||
xdebug.max_nesting_level=250
|
xdebug.discover_client_host=false
|
||||||
xdebug.var_display_max_depth=10
|
xdebug.log_level=7
|
||||||
;xdebug.log=/tmp/xdebug.log
|
|
||||||
|
|||||||
+33
-17
@@ -43,7 +43,7 @@ export const config = {
|
|||||||
watch: ['src/structure/**/*.{php,html,xml,ini,less,json,js,css}'],
|
watch: ['src/structure/**/*.{php,html,xml,ini,less,json,js,css}'],
|
||||||
},
|
},
|
||||||
copyrelease: {
|
copyrelease: {
|
||||||
src: ['src/structure/**/**', 'src/structure/**/.*', '!src/structure/**/*.{php,html,xml,ini,less,json,js,css}', '!src/structure/**/.*.{php,html,xml,ini,less,json,js,css}'],
|
src: ['RELEASE_NOTES.md','src/structure/**/**', 'src/structure/**/.*', '!src/structure/**/*.{php,html,xml,ini,less,json,js,css}', '!src/structure/**/.*.{php,html,xml,ini,less,json,js,css}'],
|
||||||
replacesrc: ['src/structure/**/**.{php,html,xml,ini,less,json,js,css}', 'src/structure/**/.*.{php,html,xml,ini,less,json,js,css}'],
|
replacesrc: ['src/structure/**/**.{php,html,xml,ini,less,json,js,css}', 'src/structure/**/.*.{php,html,xml,ini,less,json,js,css}'],
|
||||||
dest: 'releasefiles/'
|
dest: 'releasefiles/'
|
||||||
},
|
},
|
||||||
@@ -56,28 +56,44 @@ export const config = {
|
|||||||
},
|
},
|
||||||
packagefiles: [
|
packagefiles: [
|
||||||
{
|
{
|
||||||
src: './releasefiles/components/com_kickboilerplate/**/**',
|
src: './releasefiles/components/com_sportsmanager/**/**',
|
||||||
dest: 'sourcefiles/com_kickboilerplate/site'
|
dest: 'sourcefiles/com_sportsmanager/site'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
src: './releasefiles/administrator/components/com_kickboilerplate/**/**',
|
src: './releasefiles/language/**/**',
|
||||||
dest: 'sourcefiles/com_kickboilerplate/admin'
|
dest: 'sourcefiles/com_sportsmanager/site/language'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
src: './releasefiles/administrator/components/com_kickboilerplate/kickboilerplate.xml',
|
src: './releasefiles/administrator/components/com_sportsmanager/**/**',
|
||||||
dest: 'sourcefiles/com_kickboilerplate/'
|
dest: 'sourcefiles/com_sportsmanager/admin'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
src: './releasefiles/administrator/components/com_kickboilerplate/script.php',
|
src: './releasefiles/administrator/language/**/**',
|
||||||
dest: 'sourcefiles/com_kickboilerplate/'
|
dest: 'sourcefiles/com_sportsmanager/admin/language'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
src: './releasefiles/media/com_kickboilerplate/**/**',
|
src: './releasefiles/administrator/services/**/**',
|
||||||
dest: 'sourcefiles/com_kickboilerplate/media'
|
dest: 'sourcefiles/com_sportsmanager/admin/services'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
src: './releasefiles/plugins/system/kickboilerplate/**/**',
|
src: './releasefiles/sportsmanager.xml',
|
||||||
dest: 'sourcefiles/plg_system_kickboilerplate'
|
dest: 'sourcefiles/com_sportsmanager/'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
src: './releasefiles/script.php',
|
||||||
|
dest: 'sourcefiles/com_sportsmanager/'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
src: './releasefiles/media/com_sportsmanager/**/**',
|
||||||
|
dest: 'sourcefiles/com_sportsmanager/media'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
src: './releasefiles/plugins/system/kickyootheme/**/**',
|
||||||
|
dest: 'sourcefiles/plg_system_kickyootheme'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
src: './releasefiles/RELEASE_NOTES.md',
|
||||||
|
dest: 'sourcefiles/com_sportsmanager/admin/'
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
package: [
|
package: [
|
||||||
@@ -100,7 +116,7 @@ export const config = {
|
|||||||
archiver: [
|
archiver: [
|
||||||
{
|
{
|
||||||
destination : 'package/packages/',
|
destination : 'package/packages/',
|
||||||
name: 'plg_system_kickboilerplate',
|
name: 'plg_system_kickyootheme',
|
||||||
suffixversion: false,
|
suffixversion: false,
|
||||||
types: [
|
types: [
|
||||||
{
|
{
|
||||||
@@ -112,14 +128,14 @@ export const config = {
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
folders: [
|
folders: [
|
||||||
'sourcefiles/plg_system_kickboilerplate'
|
'sourcefiles/plg_system_kickyootheme'
|
||||||
],
|
],
|
||||||
files: [
|
files: [
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
destination : 'package/packages/',
|
destination : 'package/packages/',
|
||||||
name: 'com_kickboilerplate',
|
name: 'com_sportsmanager',
|
||||||
suffixversion: false,
|
suffixversion: false,
|
||||||
types: [
|
types: [
|
||||||
{
|
{
|
||||||
@@ -131,7 +147,7 @@ export const config = {
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
folders: [
|
folders: [
|
||||||
'sourcefiles/com_kickboilerplate'
|
'sourcefiles/com_sportsmanager'
|
||||||
],
|
],
|
||||||
files: [
|
files: [
|
||||||
]
|
]
|
||||||
|
|||||||
+2
-2
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "sportsmanager",
|
"name": "sportsmanager",
|
||||||
"description": "",
|
"description": "",
|
||||||
"version": "0.0.1",
|
"version": "2.0.0",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"boilerplate": "cross-env NODE_ENV=development gulp boilerplate",
|
"boilerplate": "cross-env NODE_ENV=development gulp boilerplate",
|
||||||
"build": "cross-env NODE_ENV=production gulp build",
|
"build": "cross-env NODE_ENV=production gulp build",
|
||||||
@@ -16,7 +16,7 @@
|
|||||||
},
|
},
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "git+https://github.com/nielsnuebel/com_sportsmanager.git"
|
"url": "https://github.com/Deutscher-Tischfussballbund/com_sportsmanager.git"
|
||||||
},
|
},
|
||||||
"keywords": [],
|
"keywords": [],
|
||||||
"author": {
|
"author": {
|
||||||
|
|||||||
@@ -0,0 +1 @@
|
|||||||
|
ALTER TABLE `#__sportsmanager_rangliste` ADD COLUMN `lizenzen` varchar(50) NULL DEFAULT '';
|
||||||
@@ -1,23 +0,0 @@
|
|||||||
<?php
|
|
||||||
// no direct access
|
|
||||||
defined('_JEXEC') or die('Restricted access');
|
|
||||||
|
|
||||||
// Require the base controller
|
|
||||||
require_once (JPATH_COMPONENT.DS.'controller.php');
|
|
||||||
|
|
||||||
// Require specific controller if requested
|
|
||||||
//if($controller = JRequest::getVar('controller')) {
|
|
||||||
// require_once (JPATH_COMPONENT.DS.'controllers'.DS.$controller.'.php');
|
|
||||||
//}
|
|
||||||
|
|
||||||
// Create the controller
|
|
||||||
//$classname = 'AutosController'.$controller;
|
|
||||||
//$controller = new $classname( );
|
|
||||||
|
|
||||||
// Perform the Request task
|
|
||||||
//$controller->execute( JRequest::getVar('task'));
|
|
||||||
|
|
||||||
// Redirect if set by the controller
|
|
||||||
//$controller->redirect();
|
|
||||||
|
|
||||||
?>
|
|
||||||
@@ -1,31 +0,0 @@
|
|||||||
<?php
|
|
||||||
/*
|
|
||||||
* Sports Manager (C) 2006-2020, Sven Nickel
|
|
||||||
*/
|
|
||||||
|
|
||||||
// No direct access to this file
|
|
||||||
defined('_JEXEC') or die('Restricted access');
|
|
||||||
|
|
||||||
// import Joomla controller library
|
|
||||||
jimport('joomla.application.component.controller');
|
|
||||||
|
|
||||||
/**
|
|
||||||
* General Controller of SportsManager component
|
|
||||||
*/
|
|
||||||
class SportsManagerController extends JControllerLegacy
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* display task
|
|
||||||
*
|
|
||||||
* @return void
|
|
||||||
*/
|
|
||||||
function display($cachable = false, $urlparams = false)
|
|
||||||
{
|
|
||||||
// set default view if not set
|
|
||||||
$input = JFactory::getApplication()->input;
|
|
||||||
$input->set('view', $input->getCmd('view', 'SportsManager'));
|
|
||||||
|
|
||||||
// call parent behavior
|
|
||||||
parent::display($cachable);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -0,0 +1,61 @@
|
|||||||
|
<?php
|
||||||
|
/**
|
||||||
|
* @package Joomla.Administrator
|
||||||
|
* @subpackage com_inlinecontact
|
||||||
|
*
|
||||||
|
* @copyright (C) Alexander Niklaus. All rights reserved.
|
||||||
|
* @license GNU General Public License version 2 or later
|
||||||
|
* @link https://an-software.net
|
||||||
|
*/
|
||||||
|
|
||||||
|
defined('_JEXEC') or die;
|
||||||
|
|
||||||
|
use Dtfb\Component\com_sportsmanager\Administrator\Extension\SportsmanagerComponent;
|
||||||
|
use Joomla\CMS\Dispatcher\ComponentDispatcherFactoryInterface;
|
||||||
|
use Joomla\CMS\Extension\ComponentInterface;
|
||||||
|
use Joomla\CMS\Extension\Service\Provider\ComponentDispatcherFactory;
|
||||||
|
use Joomla\CMS\Extension\Service\Provider\MVCFactory;
|
||||||
|
use Joomla\CMS\Log\Log;
|
||||||
|
use Joomla\CMS\MVC\Factory\MVCFactoryInterface;
|
||||||
|
use Joomla\DI\Container;
|
||||||
|
use Joomla\DI\ServiceProviderInterface;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The contact service provider.
|
||||||
|
*
|
||||||
|
* @since 1.0.0
|
||||||
|
*/
|
||||||
|
return new class implements ServiceProviderInterface {
|
||||||
|
/**
|
||||||
|
* Registers the service provider with a DI container.
|
||||||
|
*
|
||||||
|
* @param Container $container The DI container.
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
*
|
||||||
|
* @since 1.0.0
|
||||||
|
*/
|
||||||
|
public function register(Container $container): void
|
||||||
|
{
|
||||||
|
Log::addLogger(
|
||||||
|
[
|
||||||
|
'text_file' => 'com_sportsmanager.php',
|
||||||
|
],
|
||||||
|
Log::ALL,
|
||||||
|
['com_sportsmanager']
|
||||||
|
);
|
||||||
|
|
||||||
|
$container->registerServiceProvider(new MVCFactory('\\Dtfb\\Component\\com_sportsmanager'));
|
||||||
|
$container->registerServiceProvider(new ComponentDispatcherFactory('\\Dtfb\\Component\\com_sportsmanager'));
|
||||||
|
|
||||||
|
$container->set(
|
||||||
|
ComponentInterface::class,
|
||||||
|
function (Container $container) {
|
||||||
|
$component = new SportsmanagerComponent($container->get(ComponentDispatcherFactoryInterface::class));
|
||||||
|
$component->setMVCFactory($container->get(MVCFactoryInterface::class));
|
||||||
|
|
||||||
|
return $component;
|
||||||
|
}
|
||||||
|
);
|
||||||
|
}
|
||||||
|
};
|
||||||
@@ -1,19 +0,0 @@
|
|||||||
<?php
|
|
||||||
// No direct access to this file
|
|
||||||
defined('_JEXEC') or die('Restricted access');
|
|
||||||
|
|
||||||
// import joomla controller library
|
|
||||||
jimport('joomla.application.component.controller');
|
|
||||||
|
|
||||||
// Get an instance of the controller prefixed by HelloWorld
|
|
||||||
$controller = JControllerLegacy::getInstance('SportsManager');
|
|
||||||
|
|
||||||
// Get the task
|
|
||||||
$jinput = JFactory::getApplication()->input;
|
|
||||||
$task = $jinput->get('task', "", 'STR' );
|
|
||||||
|
|
||||||
// Perform the Request task
|
|
||||||
$controller->execute($task);
|
|
||||||
|
|
||||||
// Redirect if set by the controller
|
|
||||||
$controller->redirect();
|
|
||||||
+19
@@ -0,0 +1,19 @@
|
|||||||
|
<?php
|
||||||
|
namespace Dtfb\Component\com_sportsmanager\Administrator\Controller;
|
||||||
|
/*
|
||||||
|
* Sports Manager (C) 2006-2020, Sven Nickel
|
||||||
|
*/
|
||||||
|
|
||||||
|
// No direct access to this file
|
||||||
|
use Joomla\CMS\MVC\Controller\BaseController;
|
||||||
|
|
||||||
|
defined('_JEXEC') or die('Restricted access');
|
||||||
|
|
||||||
|
/**
|
||||||
|
* General Controller of SportsManager component
|
||||||
|
* @since 1.0.0
|
||||||
|
*/
|
||||||
|
class DisplayController extends BaseController
|
||||||
|
{
|
||||||
|
protected $default_view = 'sportsmanager';
|
||||||
|
}
|
||||||
+14
@@ -0,0 +1,14 @@
|
|||||||
|
<?php
|
||||||
|
namespace Dtfb\Component\com_sportsmanager\Administrator\Extension;
|
||||||
|
|
||||||
|
defined('JPATH_PLATFORM') or die;
|
||||||
|
|
||||||
|
use Joomla\CMS\Extension\MVCComponent;
|
||||||
|
use function defined;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Component class for com_sportsmanager
|
||||||
|
*
|
||||||
|
* @since 2.0.0
|
||||||
|
*/
|
||||||
|
class SportsmanagerComponent extends MVCComponent {}
|
||||||
+40
@@ -0,0 +1,40 @@
|
|||||||
|
<?php
|
||||||
|
namespace Dtfb\Component\com_sportsmanager\Administrator\View\Sportsmanager;
|
||||||
|
/*
|
||||||
|
* Sports Manager (C) 2006-2020, Sven Nickel
|
||||||
|
*/
|
||||||
|
|
||||||
|
// No direct access to this file
|
||||||
|
use Joomla\CMS\Language\Text;
|
||||||
|
use Joomla\CMS\MVC\View\HtmlView as BaseHtmlView;
|
||||||
|
use Joomla\CMS\Toolbar\ToolbarHelper;
|
||||||
|
|
||||||
|
defined('_JEXEC') or die('Restricted access');
|
||||||
|
|
||||||
|
/**
|
||||||
|
* SportsManager View
|
||||||
|
* @since 1.0.0
|
||||||
|
*/
|
||||||
|
class HtmlView extends BaseHtmlView
|
||||||
|
{
|
||||||
|
function display($tpl = null): void
|
||||||
|
{
|
||||||
|
ToolbarHelper::title(Text::_('COM_SPORTSMANAGER'));
|
||||||
|
|
||||||
|
?>
|
||||||
|
<h3><?php echo Text::_('COM_SPORTSMANAGER'); ?> – Created by Sven Nickel | Maintained by DTFB</h3>
|
||||||
|
<?php
|
||||||
|
|
||||||
|
$notesPath = JPATH_COMPONENT_ADMINISTRATOR . '/RELEASE_NOTES.md';
|
||||||
|
if (file_exists($notesPath)) {
|
||||||
|
$notes = file_get_contents($notesPath);
|
||||||
|
echo '<div style="padding:1em;"><h3>Release Notes</h3><pre>' .
|
||||||
|
htmlspecialchars($notes) . '</pre></div>';
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// Display the template
|
||||||
|
parent::display($tpl);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
[.ShellClassInfo]
|
|
||||||
InfoTip=Dieser Ordner wird online freigegeben.
|
|
||||||
IconFile=C:\Program Files (x86)\Google\Drive\googledrivesync.exe
|
|
||||||
IconIndex=16
|
|
||||||
|
|
||||||
-5
@@ -1,5 +0,0 @@
|
|||||||
[.ShellClassInfo]
|
|
||||||
InfoTip=Dieser Ordner wird online freigegeben.
|
|
||||||
IconFile=C:\Program Files (x86)\Google\Drive\googledrivesync.exe
|
|
||||||
IconIndex=16
|
|
||||||
|
|
||||||
-1
@@ -1 +0,0 @@
|
|||||||
<html><body bgcolor="#FFFFFF"></body></html>
|
|
||||||
-5
@@ -1,5 +0,0 @@
|
|||||||
[.ShellClassInfo]
|
|
||||||
InfoTip=Dieser Ordner wird online freigegeben.
|
|
||||||
IconFile=C:\Program Files (x86)\Google\Drive\googledrivesync.exe
|
|
||||||
IconIndex=16
|
|
||||||
|
|
||||||
-1
@@ -1 +0,0 @@
|
|||||||
<html><body bgcolor="#FFFFFF"></body></html>
|
|
||||||
-49
@@ -1,49 +0,0 @@
|
|||||||
<?php
|
|
||||||
/*
|
|
||||||
* Sports Manager (C) 2006-2020, Sven Nickel
|
|
||||||
*/
|
|
||||||
|
|
||||||
// No direct access to this file
|
|
||||||
defined('_JEXEC') or die('Restricted access');
|
|
||||||
|
|
||||||
// import Joomla view library
|
|
||||||
jimport('joomla.application.component.view');
|
|
||||||
|
|
||||||
/**
|
|
||||||
* SportsManager View
|
|
||||||
*/
|
|
||||||
|
|
||||||
class SportsManagerViewSportsManager extends JViewLegacy
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* SportsManager view display method
|
|
||||||
* @return void
|
|
||||||
*/
|
|
||||||
function display($tpl = null)
|
|
||||||
{
|
|
||||||
JToolbarHelper::title(JText::_('COM_SPORTSMANAGER'));
|
|
||||||
|
|
||||||
?>
|
|
||||||
<h2><?php echo JText::_('COM_SPORTSMANAGER'); ?> Copyright © 2006 – 2014 Sven Nickel</h2>
|
|
||||||
<?php
|
|
||||||
/*
|
|
||||||
// Get data from the model
|
|
||||||
$items = $this->get('Items');
|
|
||||||
$pagination = $this->get('Pagination');
|
|
||||||
|
|
||||||
// Check for errors.
|
|
||||||
if (count($errors = $this->get('Errors')))
|
|
||||||
{
|
|
||||||
JError::raiseError(500, implode('<br />', $errors));
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
// Assign data to the view
|
|
||||||
$this->items = $items;
|
|
||||||
$this->pagination = $pagination;
|
|
||||||
*/
|
|
||||||
|
|
||||||
// Display the template
|
|
||||||
parent::display($tpl);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
File diff suppressed because it is too large
Load Diff
@@ -2,35 +2,52 @@
|
|||||||
/*
|
/*
|
||||||
* Sports Manager API Extension
|
* Sports Manager API Extension
|
||||||
*/
|
*/
|
||||||
defined('_JEXEC') or die();
|
|
||||||
|
|
||||||
$secret = JFactory::$config['secret'];
|
use JetBrains\PhpStorm\NoReturn;
|
||||||
|
use Joomla\CMS\Application\AdministratorApplication;
|
||||||
|
use Joomla\CMS\Application\SiteApplication;
|
||||||
|
use Joomla\CMS\Factory;
|
||||||
|
use Joomla\CMS\User\UserFactory;
|
||||||
|
use Joomla\CMS\User\UserFactoryInterface;
|
||||||
|
use Joomla\Registry\Registry;
|
||||||
|
|
||||||
function abortWithError($error) {
|
defined("_JEXEC") or die();
|
||||||
|
|
||||||
|
require_once JPATH_SITE . '/components/com_sportsmanager/database/init.php';
|
||||||
|
|
||||||
|
Factory::getContainer()->set(Registry::class, function () {
|
||||||
|
return new Registry();
|
||||||
|
});
|
||||||
|
|
||||||
|
$secret = Factory::getContainer()->get(Registry::class)->get("secret");
|
||||||
|
|
||||||
|
#[NoReturn] function abortWithError($error): void
|
||||||
|
{
|
||||||
if (isJson()) {
|
if (isJson()) {
|
||||||
header('content-type: application/json');
|
header("content-type: application/json");
|
||||||
die(json_encode(['error' => $error]));
|
die(json_encode(["error" => $error]));
|
||||||
} else {
|
} else {
|
||||||
die($error);
|
die($error);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function isJson() {
|
function isJson(): bool
|
||||||
$jinput = JFactory::getApplication()->input;
|
{
|
||||||
|
$jInput = Factory::getContainer()->get(SiteApplication::class)->input;
|
||||||
return $jinput->get('format') === 'json';
|
return $jInput->get('format') === 'json';
|
||||||
}
|
}
|
||||||
|
|
||||||
function notifyChange($data) {
|
function notifyChange($data): void
|
||||||
|
{
|
||||||
|
|
||||||
try {
|
try {
|
||||||
$db = &getDatabase();
|
$db = getDatabase();
|
||||||
$query = "SELECT wert from #__sportsmanager_einstellungen WHERE name='api_push_key'";
|
$query = "SELECT wert from #__sportsmanager_einstellungen WHERE name='api_push_key'";
|
||||||
$db->setQuery($query);
|
$db->setQuery($query);
|
||||||
$push_key = $db->loadResult();
|
$push_key = $db->loadResult();
|
||||||
$push_server = !empty($push_key) && isset(_payload($push_key)->aud) ? _payload($push_key)->aud : '';
|
$push_server = !empty($push_key) && isset(_payload($push_key)->aud) ? _payload($push_key)->aud : '';
|
||||||
if ($push_server != '' && $push_key != '') {
|
if ($push_server != '' && $push_key != '') {
|
||||||
$url = $push_server . (substr($push_server, -1) == '/' ? '' : '/') . 'v1/notifications/send';
|
$url = $push_server . (str_ends_with($push_server, '/') ? '' : '/') . 'v1/notifications/send';
|
||||||
$key = 'key=' . $push_key;
|
$key = 'key=' . $push_key;
|
||||||
|
|
||||||
$ch = curl_init($url);
|
$ch = curl_init($url);
|
||||||
@@ -46,7 +63,7 @@ function notifyChange($data) {
|
|||||||
CURLOPT_POSTFIELDS => json_encode($data),
|
CURLOPT_POSTFIELDS => json_encode($data),
|
||||||
));
|
));
|
||||||
$resp = curl_exec($ch);
|
$resp = curl_exec($ch);
|
||||||
if ($resp == FALSE) {
|
if (!$resp) {
|
||||||
error_log("failed to send notification");
|
error_log("failed to send notification");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -55,7 +72,8 @@ function notifyChange($data) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function begegnungChanged($begegnung, $begegnung_vorher, $modus, $heim_team, $gast_team, $spiele) {
|
function begegnungChanged($begegnung, $begegnung_vorher, $modus, $heim_team, $gast_team, $spiele): void
|
||||||
|
{
|
||||||
notifyChange(['payload' => [
|
notifyChange(['payload' => [
|
||||||
'begegnung' => $begegnung,
|
'begegnung' => $begegnung,
|
||||||
'begegnung_vorher' => $begegnung_vorher,
|
'begegnung_vorher' => $begegnung_vorher,
|
||||||
@@ -66,7 +84,8 @@ function begegnungChanged($begegnung, $begegnung_vorher, $modus, $heim_team, $ga
|
|||||||
], 'type' => 'FIXTURE_RESULT_CHANGED']);
|
], 'type' => 'FIXTURE_RESULT_CHANGED']);
|
||||||
}
|
}
|
||||||
|
|
||||||
function begegnungTischChanged($begegnung, $heim_team, $gast_team) {
|
function begegnungTischChanged($begegnung, $heim_team, $gast_team): void
|
||||||
|
{
|
||||||
notifyChange(['payload' => [
|
notifyChange(['payload' => [
|
||||||
'begegnung' => $begegnung,
|
'begegnung' => $begegnung,
|
||||||
'heim_team' => $heim_team,
|
'heim_team' => $heim_team,
|
||||||
@@ -74,7 +93,8 @@ function begegnungTischChanged($begegnung, $heim_team, $gast_team) {
|
|||||||
], 'type' => 'TABLE_CHANGED']);
|
], 'type' => 'TABLE_CHANGED']);
|
||||||
}
|
}
|
||||||
|
|
||||||
function begegnungVerlegenNotify($begegnung, $users, $vorschlagendes_team_id, $heim_team, $gast_team) {
|
function begegnungVerlegenNotify($begegnung, $users, $vorschlagendes_team_id, $heim_team, $gast_team): void
|
||||||
|
{
|
||||||
notifyChange([
|
notifyChange([
|
||||||
'payload' => [
|
'payload' => [
|
||||||
'begegnung' => $begegnung,
|
'begegnung' => $begegnung,
|
||||||
@@ -92,7 +112,8 @@ function begegnungVerlegenNotify($begegnung, $users, $vorschlagendes_team_id, $h
|
|||||||
* @reponse body
|
* @reponse body
|
||||||
* { data: { token: "reqest_token", access_for_team: ["team_id_1", "team_id_2"]}, expires: 1520013747000}
|
* { data: { token: "reqest_token", access_for_team: ["team_id_1", "team_id_2"]}, expires: 1520013747000}
|
||||||
*/
|
*/
|
||||||
function userToken() {
|
#[NoReturn] function userToken(): void
|
||||||
|
{
|
||||||
global $secret;
|
global $secret;
|
||||||
if (!isJson()) {
|
if (!isJson()) {
|
||||||
abortWithError("JSON Request only");
|
abortWithError("JSON Request only");
|
||||||
@@ -100,19 +121,21 @@ function userToken() {
|
|||||||
if (isExternalDatabase()) {
|
if (isExternalDatabase()) {
|
||||||
abortWithError("Local Database only");
|
abortWithError("Local Database only");
|
||||||
}
|
}
|
||||||
$jinput = JFactory::getApplication()->input->json;
|
$container = Factory::getContainer();
|
||||||
$access_key = $jinput->getString('access_key');
|
$jInput = $container->get(SiteApplication::class)->input->json;
|
||||||
|
$access_key = $jInput->getString('access_key');
|
||||||
|
|
||||||
$user_id = _payload($access_key)->sub;
|
$user_id = _payload($access_key)->sub;
|
||||||
$user = JFactory::getUser($user_id);
|
$user = $container->get(UserFactoryInterface::class)->loadUserById($user_id);
|
||||||
|
|
||||||
if (!jwt_validate($access_key, $secret . $user->password)) {
|
if (!jwt_validate($access_key, $secret . $user->password)) {
|
||||||
abortWithError('Access Key is invalid');
|
abortWithError('Access Key is invalid');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
$expires = new DateTime();
|
$expires = new DateTime();
|
||||||
$expires->modify('+16 hours');
|
$expires->modify('+16 hours');
|
||||||
$db = &getDatabase();
|
$db = getDatabase();
|
||||||
$query = "SELECT berechtigt_team_id from #__sportsmanager_berechtigt_fuer_team where berechtigt_user_id = $user_id";
|
$query = "SELECT berechtigt_team_id from #__sportsmanager_berechtigt_fuer_team where berechtigt_user_id = $user_id";
|
||||||
$db->setQuery($query);
|
$db->setQuery($query);
|
||||||
if (!$db->execute()) {
|
if (!$db->execute()) {
|
||||||
@@ -124,9 +147,15 @@ function userToken() {
|
|||||||
'sub' => $user_id,
|
'sub' => $user_id,
|
||||||
'exp' => $expires->getTimestamp(),
|
'exp' => $expires->getTimestamp(),
|
||||||
], $secret),
|
], $secret),
|
||||||
'access_for_teams' => array_map(function($item) { return $item->berechtigt_team_id; }, $team_id),
|
'access_for_teams' => array_map(function ($item) {
|
||||||
|
return $item->berechtigt_team_id;
|
||||||
|
}, $team_id),
|
||||||
'expires' => $expires->getTimestamp() * 1000, //
|
'expires' => $expires->getTimestamp() * 1000, //
|
||||||
]);
|
]);
|
||||||
|
} catch (Exception $ex) {
|
||||||
|
error_log($ex);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@@ -134,7 +163,8 @@ function userToken() {
|
|||||||
* @response body
|
* @response body
|
||||||
* { data: { token: "api_acccess_token" }}
|
* { data: { token: "api_acccess_token" }}
|
||||||
*/
|
*/
|
||||||
function userAuth() {
|
#[NoReturn] function userAuth(): void
|
||||||
|
{
|
||||||
global $secret;
|
global $secret;
|
||||||
if (!isJson()) {
|
if (!isJson()) {
|
||||||
die();
|
die();
|
||||||
@@ -142,18 +172,20 @@ function userAuth() {
|
|||||||
if (isExternalDatabase()) {
|
if (isExternalDatabase()) {
|
||||||
abortWithError("Local Database only");
|
abortWithError("Local Database only");
|
||||||
}
|
}
|
||||||
$jinput = JFactory::getApplication()->input->json;
|
$container = Factory::getContainer();
|
||||||
$username = $jinput->getString('username');
|
$jInput = $container->get(SiteApplication::class)->input->json;
|
||||||
$password = $jinput->getString('password');
|
$username = $jInput->getString('username');
|
||||||
|
$password = $jInput->getString('password');
|
||||||
|
|
||||||
$db = &getDatabase();
|
$db = getDatabase();
|
||||||
$query = $db->getQuery(true);
|
$query = $db->getQuery(true);
|
||||||
$query->select('id')->from('#__users')->where('username = "' . $username . '"')->limit(1);
|
$query->select('id')->from('#__users')->where('username = "' . $username . '"')->setLimit(1);
|
||||||
$db->setQuery($query);
|
$db->setQuery($query);
|
||||||
$user_id = $db->loadResult();
|
$user_id = $db->loadResult();
|
||||||
$user = JFactory::getUser($user_id);
|
$user = $container->get(UserFactoryInterface::class)->loadUserById($user_id);
|
||||||
|
|
||||||
if (JUserHelper::verifyPassword($password, $user->password, $user->id)) {
|
//TODO: pw verification modernising: use php native methods, however this also needs new pw hashing. maybe force a pw reset on all accounts
|
||||||
|
if (password_verify($password, $user->password)) {
|
||||||
|
|
||||||
JSON_sportsmanager::JSON([
|
JSON_sportsmanager::JSON([
|
||||||
'token' => jwt_token([
|
'token' => jwt_token([
|
||||||
@@ -161,24 +193,27 @@ function userAuth() {
|
|||||||
'iat' => (new DateTime())->getTimestamp(),
|
'iat' => (new DateTime())->getTimestamp(),
|
||||||
], $secret . $user->password)
|
], $secret . $user->password)
|
||||||
]);
|
]);
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
abortWithError('Wrong credentials');
|
abortWithError('Wrong credentials');
|
||||||
}
|
}
|
||||||
|
|
||||||
function getUserID() {
|
function getUserID(): int
|
||||||
|
{
|
||||||
global $secret;
|
global $secret;
|
||||||
$token = JFactory::getApplication()->input->server->getString('HTTP_SECRET', NULL);
|
$container = Factory::getContainer();
|
||||||
|
$input = $container->get(SiteApplication::class)->input;
|
||||||
|
$token = $input->server->getString('HTTP_SECRET', NULL);
|
||||||
|
|
||||||
return $token != NULL && jwt_validate($token, $secret) && isset(_payload($token)->sub)
|
return $token != NULL && jwt_validate($token, $secret) && isset(_payload($token)->sub)
|
||||||
? (int)_payload($token)->sub
|
? (int)_payload($token)->sub
|
||||||
: 0;
|
: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
function getColorOfImage($image) {
|
function getColorOfImage($image)
|
||||||
|
{
|
||||||
if ($image != NULL) {
|
if ($image != NULL) {
|
||||||
|
|
||||||
if (strpos($image, '.png') !== false) {
|
if (str_contains($image, '.png')) {
|
||||||
$img = imagecreatefrompng($image);
|
$img = imagecreatefrompng($image);
|
||||||
} else {
|
} else {
|
||||||
$img = imagecreatefromjpeg($image);
|
$img = imagecreatefromjpeg($image);
|
||||||
@@ -210,7 +245,8 @@ function getColorOfImage($image) {
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
function colorKey($rgb) {
|
function colorKey($rgb): string
|
||||||
|
{
|
||||||
|
|
||||||
$r = (int)($rgb['red'] / 100);
|
$r = (int)($rgb['red'] / 100);
|
||||||
$g = (int)($rgb['green'] / 100);
|
$g = (int)($rgb['green'] / 100);
|
||||||
@@ -219,7 +255,8 @@ function colorKey($rgb) {
|
|||||||
return $r . '-' . $g . '-' . $b;
|
return $r . '-' . $g . '-' . $b;
|
||||||
}
|
}
|
||||||
|
|
||||||
function hex($rgb) {
|
function hex($rgb): ?string
|
||||||
|
{
|
||||||
$r = $rgb['red'];
|
$r = $rgb['red'];
|
||||||
$g = $rgb['green'];
|
$g = $rgb['green'];
|
||||||
$b = $rgb['blue'];
|
$b = $rgb['blue'];
|
||||||
@@ -244,14 +281,16 @@ function hex($rgb) {
|
|||||||
/*
|
/*
|
||||||
* sign string with secret
|
* sign string with secret
|
||||||
*/
|
*/
|
||||||
function _sign($data, $secret, $algo = 'sha256') {
|
function _sign($data, $secret): string
|
||||||
|
{
|
||||||
return base64_encode(hash_hmac('sha256', $data, $secret));
|
return base64_encode(hash_hmac('sha256', $data, $secret));
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* get payload from jwt token
|
* get payload from jwt token
|
||||||
*/
|
*/
|
||||||
function _payload($token) {
|
function _payload($token)
|
||||||
|
{
|
||||||
$jwt = explode('.', $token);
|
$jwt = explode('.', $token);
|
||||||
return json_decode(base64_decode($jwt[0]));
|
return json_decode(base64_decode($jwt[0]));
|
||||||
}
|
}
|
||||||
@@ -259,7 +298,8 @@ function _payload($token) {
|
|||||||
/*
|
/*
|
||||||
* headless signed jwt token
|
* headless signed jwt token
|
||||||
*/
|
*/
|
||||||
function jwt_token($payload, $secret) {
|
function jwt_token($payload, $secret): string
|
||||||
|
{
|
||||||
$data = base64_encode(json_encode($payload));
|
$data = base64_encode(json_encode($payload));
|
||||||
|
|
||||||
return $data . '.' . _sign($data, $secret);
|
return $data . '.' . _sign($data, $secret);
|
||||||
@@ -268,7 +308,8 @@ function jwt_token($payload, $secret) {
|
|||||||
/*
|
/*
|
||||||
* validate token
|
* validate token
|
||||||
*/
|
*/
|
||||||
function jwt_validate($token, $secret) {
|
function jwt_validate($token, $secret): bool
|
||||||
|
{
|
||||||
$jwt = explode('.', $token);
|
$jwt = explode('.', $token);
|
||||||
if (sizeof($jwt) == 2 && $jwt[1] == _sign($jwt[0], $secret)) {
|
if (sizeof($jwt) == 2 && $jwt[1] == _sign($jwt[0], $secret)) {
|
||||||
if (isset(_payload($token)->exp)) {
|
if (isset(_payload($token)->exp)) {
|
||||||
|
|||||||
@@ -1,24 +0,0 @@
|
|||||||
<?php
|
|
||||||
/*
|
|
||||||
* Sports Manager (C) 2006-2020, Sven Nickel
|
|
||||||
*/
|
|
||||||
|
|
||||||
// Check to ensure this file is included in Joomla!
|
|
||||||
defined('_JEXEC') or die();
|
|
||||||
jimport('joomla.application.component.controller');
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Auto Component Controller
|
|
||||||
*/
|
|
||||||
class SportsManagerController extends JControllerLegacy
|
|
||||||
{
|
|
||||||
function display()
|
|
||||||
{
|
|
||||||
// Setzt einen Standard view
|
|
||||||
if ( ! JRequest::getCmd( 'view' ) ) {
|
|
||||||
JRequest::setVar('view', 'categories' );
|
|
||||||
}
|
|
||||||
parent::display();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,120 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
use Joomla\CMS\Factory;
|
||||||
|
use Joomla\CMS\Language\Text;
|
||||||
|
use Joomla\CMS\Uri\Uri;
|
||||||
|
use Joomla\Database\DatabaseInterface;
|
||||||
|
use Joomla\Database\Mysql\MysqlDriver;
|
||||||
|
use Joomla\Database\Mysqli\MysqliDriver;
|
||||||
|
|
||||||
|
function initDatabase(): void
|
||||||
|
{
|
||||||
|
global $sportsmanager_database_local;
|
||||||
|
global $sportsmanager_database_external;
|
||||||
|
global $sportsmanager_joomla_path;
|
||||||
|
global $sportsmanager_joomla_url;
|
||||||
|
|
||||||
|
$sportsmanager_database_local = NULL;
|
||||||
|
$sportsmanager_database_external = NULL;
|
||||||
|
$sportsmanager_joomla_path = JPATH_ROOT;
|
||||||
|
$sportsmanager_joomla_url = Uri::base();
|
||||||
|
|
||||||
|
$sportsmanager_database_local = Factory::getContainer()->get(DatabaseInterface::class);
|
||||||
|
|
||||||
|
$query = "SELECT * FROM #__sportsmanager_einstellungen";
|
||||||
|
$sportsmanager_database_local->setQuery($query);
|
||||||
|
if (!$sportsmanager_database_local->execute()) {
|
||||||
|
die($sportsmanager_database_local->stderr(true));
|
||||||
|
}
|
||||||
|
$rows = $sportsmanager_database_local->loadObjectList();
|
||||||
|
|
||||||
|
$database_driver = "mysql";
|
||||||
|
$database_host = "";
|
||||||
|
$database_user = "";
|
||||||
|
$database_password = "";
|
||||||
|
$database_database = "";
|
||||||
|
$database_prefix = "jos_";
|
||||||
|
$joomla_path = "";
|
||||||
|
$joomla_url = "";
|
||||||
|
foreach ($rows as $row) {
|
||||||
|
$name = mb_strtolower($row->name);
|
||||||
|
if ($name == "database_driver")
|
||||||
|
$database_driver = $row->wert;
|
||||||
|
else if ($name == "database_host")
|
||||||
|
$database_host = $row->wert;
|
||||||
|
else if ($name == "database_user")
|
||||||
|
$database_user = $row->wert;
|
||||||
|
else if ($name == "database_password")
|
||||||
|
$database_password = $row->wert;
|
||||||
|
else if ($name == "database_database")
|
||||||
|
$database_database = $row->wert;
|
||||||
|
else if ($name == "database_prefix")
|
||||||
|
$database_prefix = $row->wert;
|
||||||
|
else if ($name == "joomla_path")
|
||||||
|
$joomla_path = $row->wert;
|
||||||
|
else if ($name == "joomla_url")
|
||||||
|
$joomla_url = $row->wert;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!empty($database_driver) && !empty($database_host) && !empty($database_user) && !empty($database_database) && !empty($database_prefix) && !empty($joomla_path) && !empty($joomla_url)) {
|
||||||
|
$option = array(); //prevent problems
|
||||||
|
|
||||||
|
$option['driver'] = $database_driver; // Database driver name
|
||||||
|
$option['host'] = $database_host; // Database host name
|
||||||
|
$option['user'] = $database_user; // User for database authentication
|
||||||
|
$option['password'] = $database_password; // Password for database authentication
|
||||||
|
$option['database'] = $database_database; // Database name
|
||||||
|
$option['prefix'] = $database_prefix; // Database prefix (may be empty)
|
||||||
|
|
||||||
|
$sportsmanager_database_external = match ($option['driver']) {
|
||||||
|
'mysql' => new MysqlDriver($option),
|
||||||
|
'mysqli' => new MysqliDriver($option),
|
||||||
|
default => NULL,
|
||||||
|
};
|
||||||
|
|
||||||
|
if ($sportsmanager_database_external === NULL) {
|
||||||
|
echo "<strong>" . Text::_('COM_SPORTSMANAGER_CONNECTION_EXTERNAL_DB_FAILURE') . "</strong><br><br>";
|
||||||
|
} else {
|
||||||
|
$query = "SELECT wert FROM #__sportsmanager_einstellungen WHERE name = 'datenbank_version'";
|
||||||
|
$sportsmanager_database_external->setQuery($query);
|
||||||
|
try {
|
||||||
|
if (!$sportsmanager_database_external->execute()) {
|
||||||
|
echo "<strong>" . Text::_('COM_SPORTSMANAGER_EXTERNAL_DB_NO_SM_TABLES') . "</strong><br><br>";
|
||||||
|
$sportsmanager_database_external = NULL;
|
||||||
|
} else {
|
||||||
|
$db_version = $sportsmanager_database_external->loadResult();
|
||||||
|
if ($db_version < 38) {
|
||||||
|
echo "<strong>" . Text::_('COM_SPORTSMANAGER_EXTERNAL_DB_NO_SM_VERSION') . "</strong><br><br>";
|
||||||
|
$sportsmanager_database_external = NULL;
|
||||||
|
} else if (!is_dir($joomla_path . DIRECTORY_SEPARATOR . "images" . DIRECTORY_SEPARATOR . "sportsmanager")) {
|
||||||
|
echo "<strong>" . Text::_('COM_SPORTSMANAGER_EXTERNAL_NO_IMAGES_FOLDER') . " '/images/sportsmanager'!</strong><br><br>";
|
||||||
|
$sportsmanager_database_external = NULL;
|
||||||
|
} else {
|
||||||
|
$sportsmanager_joomla_path = $joomla_path;
|
||||||
|
$sportsmanager_joomla_url = $joomla_url;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} catch (Exception $e) {
|
||||||
|
error_log($e->getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function isExternalDatabase(): bool
|
||||||
|
{
|
||||||
|
global $sportsmanager_database_external;
|
||||||
|
return $sportsmanager_database_external != NULL;
|
||||||
|
}
|
||||||
|
|
||||||
|
function getDatabase($forceLocalDB = FALSE)
|
||||||
|
{
|
||||||
|
global $sportsmanager_database_local;
|
||||||
|
global $sportsmanager_database_external;
|
||||||
|
if ($forceLocalDB || $sportsmanager_database_external == NULL)
|
||||||
|
$db = $sportsmanager_database_local;
|
||||||
|
else
|
||||||
|
$db = $sportsmanager_database_external;
|
||||||
|
|
||||||
|
return $db;
|
||||||
|
}
|
||||||
File diff suppressed because it is too large
Load Diff
@@ -1,5 +0,0 @@
|
|||||||
[.ShellClassInfo]
|
|
||||||
InfoTip=Dieser Ordner wird online freigegeben.
|
|
||||||
IconFile=C:\Program Files (x86)\Google\Drive\googledrivesync.exe
|
|
||||||
IconIndex=16
|
|
||||||
|
|
||||||
File diff suppressed because it is too large
Load Diff
@@ -1,5 +0,0 @@
|
|||||||
[.ShellClassInfo]
|
|
||||||
InfoTip=Dieser Ordner wird online freigegeben.
|
|
||||||
IconFile=C:\Program Files (x86)\Google\Drive\googledrivesync.exe
|
|
||||||
IconIndex=16
|
|
||||||
|
|
||||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,45 @@
|
|||||||
|
<?php
|
||||||
|
namespace Dtfb\Component\com_sportsmanager\Site\Controller;
|
||||||
|
/*
|
||||||
|
* Sports Manager (C) 2006-2020, Sven Nickel
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Check to ensure this file is included in Joomla!
|
||||||
|
defined('_JEXEC') or die();
|
||||||
|
|
||||||
|
use Joomla\CMS\Factory;
|
||||||
|
use Joomla\CMS\MVC\Controller\BaseController;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @package SportsManager.Site
|
||||||
|
* @subpackage com_sportsmanager
|
||||||
|
*
|
||||||
|
* @copyright Copyright (C) 2020 John Smith. All rights reserved.
|
||||||
|
* @license GNU General Public License version 3; see LICENSE
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Class DisplayController
|
||||||
|
* @since 2.0.0
|
||||||
|
* The DisplayController class handles the display of views in the application.
|
||||||
|
* It extends the BaseController class.
|
||||||
|
*/
|
||||||
|
class DisplayController extends BaseController {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Displays the view for the given URL parameters.
|
||||||
|
*
|
||||||
|
* @param bool $cachable Whether the view can be cached or not. Default is false.
|
||||||
|
* @param array $urlparams The URL parameters to be passed to the view. Default is an empty array.
|
||||||
|
* @param array|null $safeurlparams An associative array of 'safe' URL parameters and their variable types.
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
* @throws Exception
|
||||||
|
* @since 2.0.0
|
||||||
|
*/
|
||||||
|
public function display($cachable = false, $urlparams = array(), array $safeurlparams = null): void
|
||||||
|
{
|
||||||
|
require_once JPATH_SITE . '/components/com_sportsmanager/sportsmanager.php';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@@ -4,49 +4,70 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
// kein direkter Zugriff
|
// kein direkter Zugriff
|
||||||
|
use JetBrains\PhpStorm\NoReturn;
|
||||||
|
use Joomla\CMS\Application\SiteApplication;
|
||||||
|
use Joomla\CMS\Factory;
|
||||||
|
use Joomla\CMS\Log\Log;
|
||||||
|
use Joomla\CMS\Router\Route;
|
||||||
|
use Joomla\CMS\Uri\Uri;
|
||||||
|
use Joomla\CMS\User\User;
|
||||||
|
use Joomla\CMS\Version;
|
||||||
|
|
||||||
defined('_JEXEC') or die('Restricted access');
|
defined('_JEXEC') or die('Restricted access');
|
||||||
|
|
||||||
require_once (JPATH_COMPONENT.DIRECTORY_SEPARATOR.'mathparser.php');
|
require_once JPATH_SITE . '/components/com_sportsmanager/mathparser.php';
|
||||||
|
require_once JPATH_SITE . '/components/com_sportsmanager/database/init.php';
|
||||||
|
|
||||||
|
/** @noinspection PhpUnused */
|
||||||
function mathParserVerteilung($rohpunkte, $platz, $teilnehmer, $multiplikator) {
|
function mathParserVerteilung($rohpunkte, $platz, $teilnehmer, $multiplikator) {
|
||||||
return max(round($multiplikator * round(((($rohpunkte - 1) * (-log($platz / $teilnehmer) * (1 - ($platz / $teilnehmer)))) / (-log(1 / $teilnehmer) * (1 - (1 / $teilnehmer)))) + 1)), 1);
|
return max(round($multiplikator * round(((($rohpunkte - 1) * (-log($platz / $teilnehmer) * (1 - ($platz / $teilnehmer)))) / (-log(1 / $teilnehmer) * (1 - (1 / $teilnehmer)))) + 1)), 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** @noinspection PhpUnused */
|
||||||
function mathParserVerteilungR($rohpunkte, $platz, $teilnehmer, $multiplikator) {
|
function mathParserVerteilungR($rohpunkte, $platz, $teilnehmer, $multiplikator) {
|
||||||
return max(round(((($multiplikator * $rohpunkte - 1) * (-log($platz / $teilnehmer) * (1 - ($platz / $teilnehmer)))) / (-log(1 / $teilnehmer) * (1 - (1 / $teilnehmer)))) + 1), 1);
|
return max(round(((($multiplikator * $rohpunkte - 1) * (-log($platz / $teilnehmer) * (1 - ($platz / $teilnehmer)))) / (-log(1 / $teilnehmer) * (1 - (1 / $teilnehmer)))) + 1), 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
class MathParserSM extends MathParser {
|
class MathParserSM extends MathParser
|
||||||
|
{
|
||||||
// Verteilung nach Klostermann/Wahle
|
// Verteilung nach Klostermann/Wahle
|
||||||
public function __construct() {
|
public function __construct()
|
||||||
MathParser::__construct();
|
{
|
||||||
$this->createFunc("ROUND", round, 1);
|
parent::__construct();
|
||||||
$this->createFunc("VERTEILUNG", mathParserVerteilung, 4);
|
try {
|
||||||
$this->createFunc("VERTEILUNGR", mathParserVerteilungR, 4);
|
$this->createFunc("ROUND", 'round', 1);
|
||||||
|
$this->createFunc("VERTEILUNG", 'mathParserVerteilung', 4);
|
||||||
|
$this->createFunc("VERTEILUNGR", 'mathParserVerteilungR', 4);
|
||||||
|
} catch (Exception $e) {
|
||||||
|
Log::add('an error occurred: ' . $e->getMessage(), Log::ERROR, 'com_sportsmanager');
|
||||||
|
throw new RuntimeException('An error occurred.', 500);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function keinZugriff($login = FALSE) {
|
#[NoReturn] function keinZugriff($login = FALSE): void
|
||||||
|
{
|
||||||
if (isJson()) {
|
if (isJson()) {
|
||||||
abortWithError(401 . ' Unauthorized');
|
abortWithError(401 . ' Unauthorized');
|
||||||
}
|
}
|
||||||
if (!$login || JFactory::getUser()->id) {
|
if (!$login || Factory::getContainer()->get(SiteApplication::class)->getIdentity()->id) {
|
||||||
JError::raiseError(500, JText::_('JERROR_ALERTNOAUTHOR'));
|
Log::add('Unauthorized user with id ' . Factory::getContainer()->get(SiteApplication::class)->getIdentity()->id, Log::WARNING, 'com_sportsmanager');
|
||||||
jexit();
|
throw new RuntimeException('Not authorized!', 401);
|
||||||
}
|
}
|
||||||
$version = new JVersion;
|
$version = new Version();
|
||||||
$joomla = $version->getShortVersion();
|
$joomla = $version->getShortVersion();
|
||||||
$u =& JFactory::getURI();
|
$u = Uri::getInstance();
|
||||||
$redirectUrl = urlencode(base64_encode($u->toString()));
|
$redirectUrl = urlencode(base64_encode($u->toString()));
|
||||||
$redirectUrl = '&return=' . $redirectUrl;
|
$redirectUrl = '&return=' . $redirectUrl;
|
||||||
$joomlaLoginUrl = 'index.php?option=' . (substr($joomla, 0, 3) != '1.5' ? 'com_users' : 'com_user') . '&view=login';
|
$joomlaLoginUrl = 'index.php?option=' . (!str_starts_with($joomla, '1.5') ? 'com_users' : 'com_user') . '&view=login';
|
||||||
$finalUrl = $joomlaLoginUrl . $redirectUrl;
|
$finalUrl = $joomlaLoginUrl . $redirectUrl;
|
||||||
$app = &JFactory::getApplication();
|
$app = Factory::getContainer()->get(SiteApplication::class);
|
||||||
$app->redirect(JRoute::_($finalUrl));
|
$app->redirect(Route::_($finalUrl));
|
||||||
jexit();
|
jexit();
|
||||||
}
|
}
|
||||||
|
|
||||||
function bereinigterDateiname($dateiname) {
|
function bereinigterDateiname($dateiname): array|string
|
||||||
|
{
|
||||||
$_convertTable = array(
|
$_convertTable = array(
|
||||||
'&' => 'and', '@' => 'at', '©' => 'c', '®' => 'r', 'À' => 'a',
|
'&' => 'and', '@' => 'at', '©' => 'c', '®' => 'r', 'À' => 'a',
|
||||||
'Á' => 'a', 'Â' => 'a', 'Ä' => 'a', 'Å' => 'a', 'Æ' => 'ae', 'Ç' => 'c',
|
'Á' => 'a', 'Â' => 'a', 'Ä' => 'a', 'Å' => 'a', 'Æ' => 'ae', 'Ç' => 'c',
|
||||||
@@ -109,27 +130,30 @@ function bereinigterDateiname($dateiname) {
|
|||||||
return str_replace($bad, "", strtr($dateiname, $_convertTable));
|
return str_replace($bad, "", strtr($dateiname, $_convertTable));
|
||||||
}
|
}
|
||||||
|
|
||||||
function setMinMemoryLimit($memDestSize) {
|
function setMinMemoryLimit($memDestSize): void
|
||||||
|
{
|
||||||
if (getBytes(ini_get('memory_limit')) < getBytes($memDestSize))
|
if (getBytes(ini_get('memory_limit')) < getBytes($memDestSize))
|
||||||
ini_set('memory_limit', $memDestSize);
|
ini_set('memory_limit', $memDestSize);
|
||||||
}
|
}
|
||||||
|
|
||||||
function getBytes($val) {
|
function getBytes($val): int|string
|
||||||
|
{
|
||||||
$val = trim($val);
|
$val = trim($val);
|
||||||
$last = strtolower($val{strlen($val)-1});
|
$numeric = substr($val, 0, strlen($val) - 1);
|
||||||
|
$last = strtolower($val[strlen($val) - 1]);
|
||||||
switch ($last) {
|
switch ($last) {
|
||||||
// The 'G' modifier is available since PHP 5.1.0
|
// The 'G' modifier is available since PHP 5.1.0
|
||||||
case 'g':
|
|
||||||
$val *= 1024;
|
|
||||||
case 'm':
|
case 'm':
|
||||||
$val *= 1024;
|
case 'g':
|
||||||
case 'k':
|
case 'k':
|
||||||
$val *= 1024;
|
$numeric *= 1024;
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
return $val;
|
return $numeric;
|
||||||
}
|
}
|
||||||
|
|
||||||
function encrypt($str, $key){
|
function encrypt($str, $key): string
|
||||||
|
{
|
||||||
$result = "";
|
$result = "";
|
||||||
for ($i = 0; $i < strlen($str); $i++) {
|
for ($i = 0; $i < strlen($str); $i++) {
|
||||||
$char = substr($str, $i, 1);
|
$char = substr($str, $i, 1);
|
||||||
@@ -140,7 +164,8 @@ function encrypt($str, $key){
|
|||||||
return base64_encode($result);
|
return base64_encode($result);
|
||||||
}
|
}
|
||||||
|
|
||||||
function decrypt($str, $key){
|
function decrypt($str, $key): string
|
||||||
|
{
|
||||||
$str = base64_decode($str);
|
$str = base64_decode($str);
|
||||||
$result = "";
|
$result = "";
|
||||||
for ($i = 0; $i < strlen($str); $i++) {
|
for ($i = 0; $i < strlen($str); $i++) {
|
||||||
@@ -152,13 +177,14 @@ function decrypt($str, $key){
|
|||||||
return $result;
|
return $result;
|
||||||
}
|
}
|
||||||
|
|
||||||
function individualwettbewerbFilter($prefix) {
|
function individualwettbewerbFilter($prefix): string
|
||||||
$db =& getDatabase();
|
{
|
||||||
$user_id = isExternalDatabase() ? 0 : JFactory::getUser()->id;
|
$user_id = isExternalDatabase() ? 0 : Factory::getContainer()->get(SiteApplication::class)->getIdentity()->id;
|
||||||
return " " . $prefix . " (SELECT berechtigt_individualwettbewerb_id FROM #__sportsmanager_berechtigt_fuer_individualwettbewerb INNER JOIN #__sportsmanager_individualwettbewerb ON individualwettbewerb_id = berechtigt_individualwettbewerb_id WHERE berechtigt_user_id = $user_id) ";
|
return " " . $prefix . " (SELECT berechtigt_individualwettbewerb_id FROM #__sportsmanager_berechtigt_fuer_individualwettbewerb INNER JOIN #__sportsmanager_individualwettbewerb ON individualwettbewerb_id = berechtigt_individualwettbewerb_id WHERE berechtigt_user_id = $user_id) ";
|
||||||
}
|
}
|
||||||
|
|
||||||
function kategorieFilter($prefix, $suffix = "") {
|
function kategorieFilter($prefix, $suffix = ""): string
|
||||||
|
{
|
||||||
global $params;
|
global $params;
|
||||||
$kategorien = explode(",", $params->get('kategorien'));
|
$kategorien = explode(",", $params->get('kategorien'));
|
||||||
$filter = "";
|
$filter = "";
|
||||||
@@ -173,32 +199,33 @@ function kategorieFilter($prefix, $suffix = "") {
|
|||||||
return empty($filter) ? "" : (" " . $prefix . " (" . $filter . ") " . $suffix);
|
return empty($filter) ? "" : (" " . $prefix . " (" . $filter . ") " . $suffix);
|
||||||
}
|
}
|
||||||
|
|
||||||
function turnierFilter($prefix) {
|
function turnierFilter($prefix): string
|
||||||
$db =& getDatabase();
|
{
|
||||||
$user_id = isExternalDatabase() ? 0 : JFactory::getUser()->id;
|
$user_id = isExternalDatabase() ? 0 : Factory::getContainer()->get(SiteApplication::class)->getIdentity()->id;
|
||||||
return " " . $prefix . " (SELECT berechtigt_turnier_id FROM #__sportsmanager_berechtigt_fuer_turnier WHERE berechtigt_user_id = $user_id AND DATEDIFF(letzter_tag, NOW()) >= -14) ";
|
return " " . $prefix . " (SELECT berechtigt_turnier_id FROM #__sportsmanager_berechtigt_fuer_turnier WHERE berechtigt_user_id = $user_id AND DATEDIFF(letzter_tag, NOW()) >= -14) ";
|
||||||
}
|
}
|
||||||
|
|
||||||
function vereinFilter($prefix) {
|
function vereinFilter($prefix): string
|
||||||
$db =& getDatabase();
|
{
|
||||||
$user_id = isExternalDatabase() ? 0 : JFactory::getUser()->id;
|
$user_id = isExternalDatabase() ? 0 : Factory::getContainer()->get(SiteApplication::class)->getIdentity()->id;
|
||||||
return " " . $prefix . " (SELECT berechtigt_verein_id FROM #__sportsmanager_berechtigt_fuer_verein INNER JOIN #__sportsmanager_verein ON berechtigt_verein_id = verein_id WHERE berechtigt_user_id = $user_id AND NOT ausgetreten) ";
|
return " " . $prefix . " (SELECT berechtigt_verein_id FROM #__sportsmanager_berechtigt_fuer_verein INNER JOIN #__sportsmanager_verein ON berechtigt_verein_id = verein_id WHERE berechtigt_user_id = $user_id AND NOT ausgetreten) ";
|
||||||
}
|
}
|
||||||
|
|
||||||
function veranstalterFilter($prefix) {
|
function veranstalterFilter($prefix): string
|
||||||
$db =& getDatabase();
|
{
|
||||||
$user_id = isExternalDatabase() ? 0 : JFactory::getUser()->id;
|
$user_id = isExternalDatabase() ? 0 : Factory::getContainer()->get(SiteApplication::class)->getIdentity()->id;
|
||||||
return " " . $prefix . " (SELECT berechtigt_veranstalter_id FROM #__sportsmanager_berechtigt_fuer_veranstalter WHERE berechtigt_user_id = $user_id) ";
|
return " " . $prefix . " (SELECT berechtigt_veranstalter_id FROM #__sportsmanager_berechtigt_fuer_veranstalter WHERE berechtigt_user_id = $user_id) ";
|
||||||
}
|
}
|
||||||
|
|
||||||
function veranstaltungFilter($prefix) {
|
function veranstaltungFilter($prefix): string
|
||||||
$db =& getDatabase();
|
{
|
||||||
$user_id = isExternalDatabase() ? 0 : JFactory::getUser()->id;
|
$user_id = isExternalDatabase() ? 0 : Factory::getContainer()->get(SiteApplication::class)->getIdentity()->id;
|
||||||
return " " . $prefix . " (SELECT berechtigt_veranstaltung_id FROM #__sportsmanager_berechtigt_fuer_veranstaltung INNER JOIN #__sportsmanager_veranstaltung ON veranstaltung_id = berechtigt_veranstaltung_id WHERE berechtigt_user_id = $user_id AND DATEDIFF(letzter_tag, NOW()) >= -14) ";
|
return " " . $prefix . " (SELECT berechtigt_veranstaltung_id FROM #__sportsmanager_berechtigt_fuer_veranstaltung INNER JOIN #__sportsmanager_veranstaltung ON veranstaltung_id = berechtigt_veranstaltung_id WHERE berechtigt_user_id = $user_id AND DATEDIFF(letzter_tag, NOW()) >= -14) ";
|
||||||
}
|
}
|
||||||
|
|
||||||
// Berechnet Datum zum Montag der ersten Kalenderwoche eines Jahres
|
// Berechnet Datum zum Montag der ersten Kalenderwoche eines Jahres
|
||||||
function firstkw($jahr) {
|
function firstkw($jahr): bool|int
|
||||||
|
{
|
||||||
$erster = mktime(0, 0, 0, 1, 1, $jahr);
|
$erster = mktime(0, 0, 0, 1, 1, $jahr);
|
||||||
$wtag = date('w', $erster);
|
$wtag = date('w', $erster);
|
||||||
if ($wtag <= 4) {
|
if ($wtag <= 4) {
|
||||||
@@ -206,8 +233,7 @@ function firstkw($jahr) {
|
|||||||
* Donnerstag oder kleiner: auf den Montag zurückrechnen.
|
* Donnerstag oder kleiner: auf den Montag zurückrechnen.
|
||||||
*/
|
*/
|
||||||
$montag = mktime(0, 0, 0, 1, 1 - ($wtag - 1), $jahr);
|
$montag = mktime(0, 0, 0, 1, 1 - ($wtag - 1), $jahr);
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
/**
|
/**
|
||||||
* auf den Montag nach vorne rechnen.
|
* auf den Montag nach vorne rechnen.
|
||||||
*/
|
*/
|
||||||
@@ -217,32 +243,34 @@ function firstkw($jahr) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Berechnet Wochentag über Kalenderwoche, Jahr und Wochentag (0 = Montag, ..., 6 = Sonntag)
|
// Berechnet Wochentag über Kalenderwoche, Jahr und Wochentag (0 = Montag, ..., 6 = Sonntag)
|
||||||
function mondaykw($kw, $jahr, $weekday) {
|
function mondaykw($kw, $jahr, $weekday): bool|int
|
||||||
|
{
|
||||||
$firstmonday = firstkw($jahr);
|
$firstmonday = firstkw($jahr);
|
||||||
$mon_monat = date('m', $firstmonday);
|
$mon_monat = date('m', $firstmonday);
|
||||||
$mon_jahr = date('Y', $firstmonday);
|
$mon_jahr = date('Y', $firstmonday);
|
||||||
$mon_tage = date('d',$firstmonday);
|
$mon_tage = (int)date('d', $firstmonday);
|
||||||
$tage = ($kw - 1) * 7;
|
$tage = ($kw - 1) * 7;
|
||||||
$daykw = mktime(0,0,0,$mon_monat,$mon_tage+$tage+$weekday,$mon_jahr);
|
return mktime(0, 0, 0, $mon_monat, $mon_tage + $tage + $weekday, $mon_jahr);
|
||||||
return $daykw;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Berechnet Termin am Wochentag (0 = Montag, ..., 6 = Sonntag) in Kalenderwoche zum Datum
|
// Berechnet Termin am Wochentag (0 = Montag, ..., 6 = Sonntag) in Kalenderwoche zum Datum
|
||||||
function geaenderterWochentag($datum, $wochentag) {
|
function geaenderterWochentag($datum, $wochentag): bool|int
|
||||||
|
{
|
||||||
$wtag = date('w', $datum);
|
$wtag = date('w', $datum);
|
||||||
if ($wtag == 0) // Sonntag
|
if ($wtag == 0) // Sonntag
|
||||||
$wtag = 7;
|
$wtag = 7;
|
||||||
$mon_monat = date('m', $datum);
|
$mon_monat = date('m', $datum);
|
||||||
$mon_jahr = date('Y', $datum);
|
$mon_jahr = date('Y', $datum);
|
||||||
$mon_tage = date('d', $datum);
|
$mon_tage = (int)date('d', $datum);
|
||||||
return mktime(0, 0, 0, $mon_monat, $mon_tage + 1 - $wtag + $wochentag, $mon_jahr);
|
return mktime(0, 0, 0, $mon_monat, $mon_tage + 1 - $wtag + $wochentag, $mon_jahr);
|
||||||
}
|
}
|
||||||
|
|
||||||
function normalisiertesDatum($datum) {
|
function normalisiertesDatum($datum): ?string
|
||||||
|
{
|
||||||
if ($datum == NULL)
|
if ($datum == NULL)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
if (strpos($datum, "-") !== false)
|
if (str_contains($datum, "-"))
|
||||||
$trennzeichen = "-";
|
$trennzeichen = "-";
|
||||||
else
|
else
|
||||||
$trennzeichen = ".";
|
$trennzeichen = ".";
|
||||||
@@ -256,37 +284,35 @@ function normalisiertesDatum($datum) {
|
|||||||
$jahr = intval(substr($s, 0, 4));
|
$jahr = intval(substr($s, 0, 4));
|
||||||
$monat = intval(substr($s, 4, 2));
|
$monat = intval(substr($s, 4, 2));
|
||||||
$tag = intval(substr($s, 6, 2));
|
$tag = intval(substr($s, 6, 2));
|
||||||
}
|
} else if ($n == 3) {
|
||||||
else if ($n == 3) {
|
|
||||||
if ($trennzeichen != ".") {
|
if ($trennzeichen != ".") {
|
||||||
$jahr = intval($t[0]);
|
$jahr = intval($t[0]);
|
||||||
if (strlen($t[0]) <= 2)
|
if (strlen($t[0]) <= 2)
|
||||||
$jahr += 1900;
|
$jahr += 1900;
|
||||||
$monat = intval($t[1]);
|
$monat = intval($t[1]);
|
||||||
$tag = intval($t[2]);
|
$tag = intval($t[2]);
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
$tag = intval($t[0]);
|
$tag = intval($t[0]);
|
||||||
$monat = intval($t[1]);
|
$monat = intval($t[1]);
|
||||||
$jahr = intval($t[2]);
|
$jahr = intval($t[2]);
|
||||||
if (strlen($t[2]) <= 2)
|
if (strlen($t[2]) <= 2)
|
||||||
$jahr += 1900;
|
$jahr += 1900;
|
||||||
}
|
}
|
||||||
}
|
} else
|
||||||
else
|
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
if (!checkdate($monat, $tag, $jahr))
|
if (!checkdate($monat, $tag, $jahr))
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
return sprintf("%04d-%02d-%02d", $jahr, $monat, $tag);;
|
return sprintf("%04d-%02d-%02d", $jahr, $monat, $tag);
|
||||||
}
|
}
|
||||||
|
|
||||||
function normalisierteUhrzeit($uhrzeit) {
|
function normalisierteUhrzeit($uhrzeit): ?string
|
||||||
|
{
|
||||||
if ($uhrzeit == NULL)
|
if ($uhrzeit == NULL)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
if (strpos($uhrzeit, "-") !== FALSE)
|
if (str_contains($uhrzeit, "-"))
|
||||||
$trennzeichen = "-";
|
$trennzeichen = "-";
|
||||||
else
|
else
|
||||||
$trennzeichen = ":";
|
$trennzeichen = ":";
|
||||||
@@ -301,22 +327,21 @@ function normalisierteUhrzeit($uhrzeit) {
|
|||||||
$stunden = intval(substr($s, 0, 2));
|
$stunden = intval(substr($s, 0, 2));
|
||||||
$minuten = intval(substr($s, 2, 2));
|
$minuten = intval(substr($s, 2, 2));
|
||||||
$sekunden = $len != 6 ? 0 : intval(substr($s, 4, 2));
|
$sekunden = $len != 6 ? 0 : intval(substr($s, 4, 2));
|
||||||
}
|
} else if ($n == 2 || $n == 3) {
|
||||||
else if ($n == 2 || $n == 3) {
|
|
||||||
$stunden = intval($t[0]);
|
$stunden = intval($t[0]);
|
||||||
$minuten = intval($t[1]);
|
$minuten = intval($t[1]);
|
||||||
$sekunden = $n != 3 ? 0 : intval($t[2]);
|
$sekunden = $n != 3 ? 0 : intval($t[2]);
|
||||||
}
|
} else
|
||||||
else
|
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
if ($stunden < 0 || $stunden > 23 || $minuten < 0 || $minuten > 59 || $sekunden < 0 || $sekunden > 59)
|
if ($stunden < 0 || $stunden > 23 || $minuten < 0 || $minuten > 59 || $sekunden < 0 || $sekunden > 59)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
return sprintf("%02d:%02d:%02d", $stunden, $minuten, $sekunden);;
|
return sprintf("%02d:%02d:%02d", $stunden, $minuten, $sekunden);
|
||||||
}
|
}
|
||||||
|
|
||||||
function runden_detailliert_invers($runden) {
|
function runden_detailliert_invers($runden): ?string
|
||||||
|
{
|
||||||
if ($runden == null)
|
if ($runden == null)
|
||||||
return null;
|
return null;
|
||||||
$runden_invers = "";
|
$runden_invers = "";
|
||||||
@@ -330,7 +355,8 @@ function runden_detailliert_invers($runden) {
|
|||||||
return $runden_invers;
|
return $runden_invers;
|
||||||
}
|
}
|
||||||
|
|
||||||
function runden_detailliert_auswertung($runden) {
|
function runden_detailliert_auswertung($runden): array
|
||||||
|
{
|
||||||
$ergebnis = 0;
|
$ergebnis = 0;
|
||||||
$heim_saetze = 0;
|
$heim_saetze = 0;
|
||||||
$unentschieden_saetze = 0;
|
$unentschieden_saetze = 0;
|
||||||
@@ -360,7 +386,8 @@ function runden_detailliert_auswertung($runden) {
|
|||||||
|
|
||||||
// pass two file names
|
// pass two file names
|
||||||
// returns TRUE if files are the same, FALSE otherwise
|
// returns TRUE if files are the same, FALSE otherwise
|
||||||
function files_identical($fn1, $fn2) {
|
function files_identical($fn1, $fn2): bool
|
||||||
|
{
|
||||||
if (!is_file($fn1) || !is_file($fn2))
|
if (!is_file($fn1) || !is_file($fn2))
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
@@ -390,4 +417,4 @@ function files_identical($fn1, $fn2) {
|
|||||||
|
|
||||||
return $same;
|
return $same;
|
||||||
}
|
}
|
||||||
?>
|
|
||||||
|
|||||||
@@ -0,0 +1,477 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
use JetBrains\PhpStorm\NoReturn;
|
||||||
|
use Joomla\CMS\Application\SiteApplication;
|
||||||
|
use Joomla\CMS\Factory;
|
||||||
|
use Joomla\CMS\Uri\Uri;
|
||||||
|
use Joomla\Filesystem\File;
|
||||||
|
use Joomla\Filesystem\Folder;
|
||||||
|
|
||||||
|
const SPORTSMANAGER_JOOMLA_PATH = JPATH_ROOT;
|
||||||
|
define("SPORTSMANAGER_JOOMLA_URL", Uri::base());
|
||||||
|
|
||||||
|
function bildKopierenAngepasst($quelle, $ziel, $ziel_breite, $ziel_hoehe, $zuschneiden): bool
|
||||||
|
{
|
||||||
|
$len = strlen($ziel);
|
||||||
|
if ($len < 4 || $ziel[$len - 4] != ".")
|
||||||
|
return false;
|
||||||
|
$ext = strtolower(substr($ziel, $len - 3));
|
||||||
|
if ($ext != "jpg" && $ext != "png")
|
||||||
|
return false;
|
||||||
|
$quelle_image = $ext == "png" ? imagecreatefrompng($quelle) : imagecreatefromjpeg($quelle);
|
||||||
|
if ($quelle_image === false)
|
||||||
|
return false;
|
||||||
|
$quelle_breite = imagesx($quelle_image);
|
||||||
|
$quelle_hoehe = imagesy($quelle_image);
|
||||||
|
if ($quelle_breite == $ziel_breite && $quelle_hoehe == $ziel_hoehe)
|
||||||
|
return File::copy($quelle, $ziel);
|
||||||
|
|
||||||
|
$ziel_image = imagecreatetruecolor($ziel_breite, $ziel_hoehe);
|
||||||
|
$hintergrund = $ext == "png" ? imagecolorallocatealpha($ziel_image, 0, 0, 0, 127) : imagecolorallocate($ziel_image, 64, 64, 64);
|
||||||
|
imagefill($ziel_image, 0, 0, $hintergrund);
|
||||||
|
$quelle_proportionen = $quelle_breite / $quelle_hoehe;
|
||||||
|
$ziel_proportionen = $ziel_breite / $ziel_hoehe;
|
||||||
|
if ($zuschneiden) {
|
||||||
|
if ($ziel_proportionen >= $quelle_proportionen) {
|
||||||
|
$quelle_teilhoehe = round($quelle_breite / $ziel_proportionen);
|
||||||
|
if (!imagecopyresampled($ziel_image, $quelle_image, 0, 0, 0, round(($quelle_hoehe - $quelle_teilhoehe) / 2), $ziel_breite, $ziel_hoehe, $quelle_breite, $quelle_teilhoehe))
|
||||||
|
return false;
|
||||||
|
} else {
|
||||||
|
$quelle_teilbreite = round($quelle_hoehe * $ziel_proportionen);
|
||||||
|
if (!imagecopyresampled($ziel_image, $quelle_image, 0, 0, round(($quelle_breite - $quelle_teilbreite) / 2), 0, $ziel_breite, $ziel_hoehe, $quelle_teilbreite, $quelle_hoehe))
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if ($ziel_proportionen >= $quelle_proportionen) {
|
||||||
|
$ziel_teilbreite = round($ziel_hoehe * $quelle_proportionen);
|
||||||
|
if (!imagecopyresampled($ziel_image, $quelle_image, round(($ziel_breite - $ziel_teilbreite) / 2), 0, 0, 0, $ziel_teilbreite, $ziel_hoehe, $quelle_breite, $quelle_hoehe))
|
||||||
|
return false;
|
||||||
|
} else {
|
||||||
|
$ziel_teilhoehe = round($ziel_breite / $quelle_proportionen);
|
||||||
|
if (!imagecopyresampled($ziel_image, $quelle_image, 0, round(($ziel_hoehe - $ziel_teilhoehe) / 2), 0, 0, $ziel_breite, $ziel_teilhoehe, $quelle_breite, $quelle_hoehe))
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
ob_start();
|
||||||
|
if ($ext == "png") {
|
||||||
|
imagesavealpha($ziel_image, true);
|
||||||
|
if (!imagepng($ziel_image))
|
||||||
|
return false;
|
||||||
|
} else {
|
||||||
|
if (!imagejpeg($ziel_image))
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
$output = ob_get_contents();
|
||||||
|
ob_end_clean();
|
||||||
|
File::write($ziel, $output);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
#[NoReturn] function bildAnpassen($typ, $id = 0): void
|
||||||
|
{
|
||||||
|
$jInput = Factory::getContainer()->get(SiteApplication::class)->input;
|
||||||
|
|
||||||
|
if (empty($id))
|
||||||
|
$id = $jInput->get('id', 0, 'INT');
|
||||||
|
$fixed_width = $jInput->get('w', 0, 'INT');
|
||||||
|
$fixed_height = $jInput->get('h', 0, 'INT');
|
||||||
|
$max_width = $jInput->get('mw', 0, 'INT');
|
||||||
|
$max_height = $jInput->get('mh', 0, 'INT');
|
||||||
|
$no_cache = $jInput->get('nc', 0, 'INT');
|
||||||
|
|
||||||
|
$pfad = SPORTSMANAGER_JOOMLA_PATH . DIRECTORY_SEPARATOR . 'images' . DIRECTORY_SEPARATOR . 'sportsmanager' . DIRECTORY_SEPARATOR . $typ . DIRECTORY_SEPARATOR . $id . '.';
|
||||||
|
if (file_exists($pfad . 'png') && is_file($pfad . 'png'))
|
||||||
|
$ext = "png";
|
||||||
|
else if (file_exists($pfad . 'png') && is_file($pfad . 'png'))
|
||||||
|
$ext = "jpg";
|
||||||
|
else {
|
||||||
|
ob_end_clean(); // Wegen UTF-8-Zeichen, die in der ausgabe vorhanden sind
|
||||||
|
header('HTTP/1.1 404 Not Found');
|
||||||
|
die();
|
||||||
|
}
|
||||||
|
|
||||||
|
$filemtime = filemtime($pfad . $ext);
|
||||||
|
$last_modified = gmdate('D, d M Y H:i:s', $filemtime) . " GMT";
|
||||||
|
$etag = md5($id . '.' . $ext . $filemtime);
|
||||||
|
|
||||||
|
// Prüfung, ob die im Browsercache vorhandene Datei der hiesigen entspricht
|
||||||
|
if ($_SERVER['HTTP_IF_NONE_MATCH'] == '"' . $etag . '"' || $last_modified == $_SERVER['HTTP_IF_MODIFIED_SINCE']) {
|
||||||
|
ob_end_clean(); // Wegen UTF-8-Zeichen, die in der ausgabe vorhanden sind
|
||||||
|
header('HTTP/1.1 304 Not Modified');
|
||||||
|
if ($no_cache)
|
||||||
|
header("Cache-Control: must-revalidate"); // Bewirkt, dass der Browser jedesmal die Datei neu prüft
|
||||||
|
else
|
||||||
|
header("Cache-Control: max-age=2592000"); // Bewirkt, dass nach dreißig Tagen die Datei vom Browser auf eine Aktualisierung geprüft wird.
|
||||||
|
header("Last-Modified: " . $last_modified);
|
||||||
|
header('ETag: "' . $etag . '"');
|
||||||
|
die();
|
||||||
|
}
|
||||||
|
|
||||||
|
$image = $ext == "png" ? imagecreatefrompng($pfad . $ext) : imagecreatefromjpeg($pfad . $ext);
|
||||||
|
if ($image === false) {
|
||||||
|
ob_end_clean(); // Wegen UTF-8-Zeichen, die in der ausgabe vorhanden sind
|
||||||
|
header('HTTP/1.1 404 Not Found');
|
||||||
|
die();
|
||||||
|
}
|
||||||
|
|
||||||
|
ob_end_clean(); // Wegen UTF-8-Zeichen, die in der ausgabe vorhanden sind
|
||||||
|
header("Content-type: image/" . ($ext == "png" ? "png" : "jpeg"));
|
||||||
|
if ($no_cache)
|
||||||
|
header("Cache-Control: must-revalidate"); // Bewirkt, dass der Browser jedesmal die Datei neu prüft
|
||||||
|
else
|
||||||
|
header("Cache-Control: max-age=2592000"); // Bewirkt, dass nach dreißig Tagen die Datei vom Browser auf eine Aktualisierung geprüft wird.
|
||||||
|
header("Last-Modified: " . $last_modified);
|
||||||
|
header('ETag: "' . $etag . '"');
|
||||||
|
|
||||||
|
$width = imagesx($image);
|
||||||
|
$height = imagesy($image);
|
||||||
|
|
||||||
|
if (($fixed_width == 0 || $width == $fixed_width) && ($fixed_height == 0 || $height == $fixed_height) && ($fixed_width != 0 || $max_width == 0 || $width <= $max_width) && ($fixed_height != 0 || $max_height == 0 || $height <= $max_height)) {
|
||||||
|
if ($ext == "png") {
|
||||||
|
imagesavealpha($image, true);
|
||||||
|
imagepng($image);
|
||||||
|
} else
|
||||||
|
imagejpeg($image);
|
||||||
|
die();
|
||||||
|
}
|
||||||
|
|
||||||
|
$new_width = $width;
|
||||||
|
$new_height = $height;
|
||||||
|
|
||||||
|
if ($max_height > 0 && $new_height > $max_height) {
|
||||||
|
$new_width = max(round($new_width * $max_height / $new_height), 1);
|
||||||
|
$new_height = $max_height;
|
||||||
|
}
|
||||||
|
if ($max_width > 0 && $new_width > $max_width) {
|
||||||
|
$new_height = max(round($new_height * $max_width / $new_width), 1);
|
||||||
|
$new_width = $max_width;
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($max_width > 0 && (($max_width - $new_width) % 2) == 1) // Toleranz bei nur 1 Pixel Unterschied
|
||||||
|
$new_width += 1;
|
||||||
|
if ($max_height > 0 && (($max_height - $new_height) % 2) == 1) // Toleranz bei nur 1 Pixel Unterschied
|
||||||
|
$new_height += 1;
|
||||||
|
|
||||||
|
$image_resized = imagecreatetruecolor(max($fixed_width, $new_width), max($fixed_height, $new_height));
|
||||||
|
$color = $ext == "png" ? imagecolorallocatealpha($image_resized, 0, 0, 0, 127) : imagecolorallocate($image_resized, 64, 64, 64);
|
||||||
|
imagefill($image_resized, 0, 0, $color);
|
||||||
|
imagecopyresampled($image_resized, $image, round((imagesx($image_resized) - $new_width) / 2), round((imagesy($image_resized) - $new_height) / 2), 0, 0, $new_width, $new_height, $width, $height);
|
||||||
|
if ($ext == "png") {
|
||||||
|
imagesavealpha($image_resized, true);
|
||||||
|
imagepng($image_resized);
|
||||||
|
} else
|
||||||
|
imagejpeg($image_resized);
|
||||||
|
die();
|
||||||
|
}
|
||||||
|
|
||||||
|
function bildLoeschen($typ, $id): void
|
||||||
|
{
|
||||||
|
$typ_exploded = explode("/", $typ);
|
||||||
|
$typ = $typ_exploded[0];
|
||||||
|
$typ_prefix = count($typ_exploded) > 1 ? $typ_exploded[1] : "";
|
||||||
|
$bilder_pfad = SPORTSMANAGER_JOOMLA_PATH . DIRECTORY_SEPARATOR . 'images' . DIRECTORY_SEPARATOR . 'sportsmanager' . DIRECTORY_SEPARATOR . $typ;
|
||||||
|
$pfad = $bilder_pfad . '/' . $typ_prefix . $id . ".";
|
||||||
|
if (!is_file($pfad . 'png') && !is_file($pfad . 'jpg'))
|
||||||
|
return;
|
||||||
|
$alte_bilder = Folder::files($bilder_pfad, '^' . $typ_prefix . $id . '\.|^' . $typ_prefix . 'I' . $id . 'T');
|
||||||
|
foreach ($alte_bilder as $fn)
|
||||||
|
File::delete($bilder_pfad . DIRECTORY_SEPARATOR . $fn);
|
||||||
|
}
|
||||||
|
|
||||||
|
function bildIdentisch($typ1, $id1, $typ2, $id2): bool
|
||||||
|
{
|
||||||
|
$typ1_exploded = explode("/", $typ1);
|
||||||
|
$typ1 = $typ1_exploded[0];
|
||||||
|
$typ1_prefix = count($typ1_exploded) > 1 ? $typ1_exploded[1] : "";
|
||||||
|
$bilder_pfad1 = SPORTSMANAGER_JOOMLA_PATH . DIRECTORY_SEPARATOR . 'images' . DIRECTORY_SEPARATOR . 'sportsmanager' . DIRECTORY_SEPARATOR . $typ1;
|
||||||
|
$pfad1 = $bilder_pfad1 . '/' . $typ1_prefix . $id1 . ".";
|
||||||
|
if (is_file($pfad1 . "png"))
|
||||||
|
$ext = "png";
|
||||||
|
else if (is_file($pfad1 . "jpg"))
|
||||||
|
$ext = "jpg";
|
||||||
|
else
|
||||||
|
$ext = "";
|
||||||
|
$pfad1 .= $ext;
|
||||||
|
|
||||||
|
$typ2_exploded = explode("/", $typ2);
|
||||||
|
$typ2 = $typ2_exploded[0];
|
||||||
|
$typ2_prefix = count($typ2_exploded) > 1 ? $typ2_exploded[1] : "";
|
||||||
|
$bilder_pfad2 = SPORTSMANAGER_JOOMLA_PATH . DIRECTORY_SEPARATOR . 'images' . DIRECTORY_SEPARATOR . 'sportsmanager' . DIRECTORY_SEPARATOR . $typ2;
|
||||||
|
$pfad2 = $bilder_pfad2 . '/' . $typ2_prefix . $id2 . "." . $ext;
|
||||||
|
|
||||||
|
return files_identical($pfad1, $pfad2);
|
||||||
|
}
|
||||||
|
|
||||||
|
function teamImage($teamId, $vereinId, $width = 240, $height = 240): ?string
|
||||||
|
{
|
||||||
|
$url = bildURL("mannschaften", $teamId, 0, 0, $width, $height);
|
||||||
|
|
||||||
|
if ($url == null) {
|
||||||
|
$url = bildURL("vereine", $vereinId, 0, 0, $width, $height);
|
||||||
|
}
|
||||||
|
|
||||||
|
return $url;
|
||||||
|
}
|
||||||
|
|
||||||
|
function playerImage($playerId, $gender, $width = 180, $height = 240): ?string
|
||||||
|
{
|
||||||
|
$url = bildURL("spieler", $playerId, $width, $height, 0,0, $gender == 'M' ? 'm' : 'w');
|
||||||
|
if ($url == null) {
|
||||||
|
$url = bildURL("mannschaftsmitglieder", $playerId, $width, $height);
|
||||||
|
}
|
||||||
|
|
||||||
|
return $url;
|
||||||
|
}
|
||||||
|
|
||||||
|
#[NoReturn] function spielerbild(): void
|
||||||
|
{
|
||||||
|
$db = getDatabase();
|
||||||
|
$jInput = Factory::getContainer()->get(SiteApplication::class)->input;
|
||||||
|
|
||||||
|
$spielernr = $db->escape(trim($jInput->get('spielernr', '', 'RAW')));
|
||||||
|
$lizenznr = $db->escape(trim($jInput->get('lizenznr', '', 'RAW')));
|
||||||
|
|
||||||
|
if (empty($spielernr) && empty($lizenznr)) {
|
||||||
|
ob_end_clean(); // Wegen UTF-8-Zeichen, die in der ausgabe vorhanden sind
|
||||||
|
header('HTTP/1.1 404 Not Found');
|
||||||
|
die();
|
||||||
|
}
|
||||||
|
|
||||||
|
$query = "SELECT spieler_id"
|
||||||
|
. "\n FROM #__sportsmanager_spieler"
|
||||||
|
. "\n WHERE NOT ISNULL(aktueller_verein_id) AND NOT bild_ausblenden" . (!empty($spielernr) ? " AND spielernr = '$spielernr'" : " AND lizenznr = '$lizenznr'")
|
||||||
|
. "\n ORDER BY spieler_id DESC";
|
||||||
|
$db->setQuery($query);
|
||||||
|
if (!$db->execute()) {
|
||||||
|
die($db->stderr(true));
|
||||||
|
}
|
||||||
|
$rows = $db->loadObjectList();
|
||||||
|
if (count($rows) < 1) {
|
||||||
|
ob_end_clean(); // Wegen UTF-8-Zeichen, die in der ausgabe vorhanden sind
|
||||||
|
header('HTTP/1.1 404 Not Found');
|
||||||
|
die();
|
||||||
|
}
|
||||||
|
|
||||||
|
$id = $rows[0]->spieler_id;
|
||||||
|
bildAnpassen("spieler", $id);
|
||||||
|
}
|
||||||
|
|
||||||
|
function bildURL($typ, $id, $fixed_width = 0, $fixed_height = 0, $max_width = 0, $max_height = 0, $alternativ = ""): ?string
|
||||||
|
{
|
||||||
|
$typ_exploded = explode("/", $typ);
|
||||||
|
$typ = $typ_exploded[0];
|
||||||
|
$typ_prefix = count($typ_exploded) > 1 ? $typ_exploded[1] : "";
|
||||||
|
|
||||||
|
$pfad = SPORTSMANAGER_JOOMLA_PATH . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . $id . ".";
|
||||||
|
if (is_file($pfad . "png"))
|
||||||
|
$ext = "png";
|
||||||
|
else if (is_file($pfad . "jpg"))
|
||||||
|
$ext = "jpg";
|
||||||
|
else if (!empty($alternativ)) {
|
||||||
|
$id = $alternativ;
|
||||||
|
$pfad = SPORTSMANAGER_JOOMLA_PATH . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . $id . ".";
|
||||||
|
if (is_file($pfad . "png"))
|
||||||
|
$ext = "png";
|
||||||
|
else if (is_file($pfad . "jpg"))
|
||||||
|
$ext = "jpg";
|
||||||
|
else
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
return null;
|
||||||
|
|
||||||
|
$time = filemtime($pfad . $ext);
|
||||||
|
|
||||||
|
if ($fixed_width > 0 && $fixed_height > 0) {
|
||||||
|
$pfad_angepasst = SPORTSMANAGER_JOOMLA_PATH . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . "I" . $id . "T" . $time . "W" . $fixed_width . "H" . $fixed_height . "." . $ext;
|
||||||
|
if (is_file($pfad_angepasst)) {
|
||||||
|
return SPORTSMANAGER_JOOMLA_URL . 'images/sportsmanager/' . $typ . '/' . basename($pfad_angepasst);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$size = getimagesize($pfad . $ext);
|
||||||
|
$width = $size[0];
|
||||||
|
$height = $size[1];
|
||||||
|
|
||||||
|
$max_width = $fixed_width > 0 ? $fixed_width : $max_width;
|
||||||
|
$max_height = $fixed_height > 0 ? $fixed_height : $max_height;
|
||||||
|
|
||||||
|
if (($fixed_width == 0 || $width == $fixed_width) && ($fixed_height == 0 || $height == $fixed_height) && ($fixed_width != 0 || $max_width == 0 || $width <= $max_width) && ($fixed_height != 0 || $max_height == 0 || $height <= $max_height)) {
|
||||||
|
$pfad_angepasst = SPORTSMANAGER_JOOMLA_PATH . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . "I" . $id . "T" . $time . "W" . $width . "H" . $height . "." . $ext;
|
||||||
|
if (!is_file($pfad_angepasst)) {
|
||||||
|
if (!copy($pfad . $ext, $pfad_angepasst))
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
return SPORTSMANAGER_JOOMLA_URL . 'images/sportsmanager/' . $typ . '/' . basename($pfad_angepasst);
|
||||||
|
}
|
||||||
|
|
||||||
|
$new_width = $width;
|
||||||
|
$new_height = $height;
|
||||||
|
|
||||||
|
if ($max_height > 0 && $new_height > $max_height) {
|
||||||
|
$new_width = max(round($new_width * $max_height / $new_height), 1);
|
||||||
|
$new_height = $max_height;
|
||||||
|
}
|
||||||
|
if ($max_width > 0 && $new_width > $max_width) {
|
||||||
|
$new_height = max(round($new_height * $max_width / $new_width), 1);
|
||||||
|
$new_width = $max_width;
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($max_width > 0 && (($max_width - $new_width) % 2) == 1) // Toleranz bei nur 1 Pixel Unterschied
|
||||||
|
$new_width += 1;
|
||||||
|
if ($max_height > 0 && (($max_height - $new_height) % 2) == 1) // Toleranz bei nur 1 Pixel Unterschied
|
||||||
|
$new_height += 1;
|
||||||
|
|
||||||
|
$pfad_angepasst = SPORTSMANAGER_JOOMLA_PATH . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . "I" . $id . "T" . $time . "W" . max($fixed_width, $new_width) . "H" . max($fixed_height, $new_height) . "." . $ext;
|
||||||
|
|
||||||
|
if (!is_file($pfad_angepasst)) {
|
||||||
|
$image = $ext == "png" ? imagecreatefrompng($pfad . $ext) : imagecreatefromjpeg($pfad . $ext);
|
||||||
|
if ($image === false)
|
||||||
|
return null;
|
||||||
|
|
||||||
|
$image_resized = imagecreatetruecolor(max($fixed_width, $new_width), max($fixed_height, $new_height));
|
||||||
|
$color = $ext == "png" ? imagecolorallocatealpha($image_resized, 0, 0, 0, 127) : imagecolorallocate($image_resized, 64, 64, 64);
|
||||||
|
imagefill($image_resized, 0, 0, $color);
|
||||||
|
imagecopyresampled($image_resized, $image, round((imagesx($image_resized) - $new_width) / 2), round((imagesy($image_resized) - $new_height) / 2), 0, 0, $new_width, $new_height, $width, $height);
|
||||||
|
if ($ext == "png") {
|
||||||
|
imagesavealpha($image_resized, true);
|
||||||
|
imagepng($image_resized, $pfad_angepasst);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
imagejpeg($image_resized, $pfad_angepasst);
|
||||||
|
}
|
||||||
|
|
||||||
|
return SPORTSMANAGER_JOOMLA_URL . 'images/sportsmanager/' . $typ . '/' . basename($pfad_angepasst);
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* #resize=250
|
||||||
|
#resize=250,250,blue
|
||||||
|
#resize=250,250,blue
|
||||||
|
#resize=250,250&sizes=60%,80%,200%
|
||||||
|
#resize=250,250,cover&sizes=60%,80%,200%
|
||||||
|
#resize=250,250,fill&sizes=60%,80%,200%
|
||||||
|
#crop=250,250,center,top
|
||||||
|
#crop=250,250
|
||||||
|
#crop=250,250,center,bottom
|
||||||
|
#crop=250,250,left
|
||||||
|
#crop=250,250,right
|
||||||
|
*/
|
||||||
|
function yoothemeBild($typ, $id, $alternativ, $resize = '', $zusatz = ""): ?string
|
||||||
|
{
|
||||||
|
$typ_exploded = explode("/", $typ);
|
||||||
|
$typ = $typ_exploded[0];
|
||||||
|
$typ_prefix = count($typ_exploded) > 1 ? $typ_exploded[1] : "";
|
||||||
|
$pfad = SPORTSMANAGER_JOOMLA_PATH . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . $id . ".";
|
||||||
|
|
||||||
|
if (is_file($pfad . "png"))
|
||||||
|
$ext = "png";
|
||||||
|
else if (is_file($pfad . "jpg"))
|
||||||
|
$ext = "jpg";
|
||||||
|
else if (!empty($alternativ)) {
|
||||||
|
$id = $alternativ;
|
||||||
|
$pfad = SPORTSMANAGER_JOOMLA_PATH . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . $id . ".";
|
||||||
|
if (is_file($pfad . "png"))
|
||||||
|
$ext = "png";
|
||||||
|
else if (is_file($pfad . "jpg"))
|
||||||
|
$ext = "jpg";
|
||||||
|
else
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
return null;
|
||||||
|
|
||||||
|
$bildpfad = SPORTSMANAGER_JOOMLA_URL . "images/sportsmanager/" . $typ . "/" . $typ_prefix . $id . "." . $ext;
|
||||||
|
|
||||||
|
return '<img class="el-image" data-src="' . $bildpfad . $resize . '" ' . $zusatz . ' uk-img />';
|
||||||
|
}
|
||||||
|
|
||||||
|
function bildHTML($typ, $id, $fixed_width = 0, $fixed_height = 0, $max_width = 0, $max_height = 0, $zusatz = "", $alternativ = ""): ?string
|
||||||
|
{
|
||||||
|
$typ_exploded = explode("/", $typ);
|
||||||
|
$typ = $typ_exploded[0];
|
||||||
|
$typ_prefix = count($typ_exploded) > 1 ? $typ_exploded[1] : "";
|
||||||
|
|
||||||
|
$pfad = SPORTSMANAGER_JOOMLA_PATH . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . $id . ".";
|
||||||
|
if (is_file($pfad . "png"))
|
||||||
|
$ext = "png";
|
||||||
|
else if (is_file($pfad . "jpg"))
|
||||||
|
$ext = "jpg";
|
||||||
|
else if (!empty($alternativ)) {
|
||||||
|
$id = $alternativ;
|
||||||
|
$pfad = SPORTSMANAGER_JOOMLA_PATH . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . $id . ".";
|
||||||
|
if (is_file($pfad . "png"))
|
||||||
|
$ext = "png";
|
||||||
|
else if (is_file($pfad . "jpg"))
|
||||||
|
$ext = "jpg";
|
||||||
|
else
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
return null;
|
||||||
|
|
||||||
|
$time = filemtime($pfad . $ext);
|
||||||
|
|
||||||
|
if ($fixed_width > 0 && $fixed_height > 0) {
|
||||||
|
$pfad_angepasst = SPORTSMANAGER_JOOMLA_PATH . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . "I" . $id . "T" . $time . "W" . $fixed_width . "H" . $fixed_height . "." . $ext;
|
||||||
|
if (is_file($pfad_angepasst)) {
|
||||||
|
return '<img src="' . SPORTSMANAGER_JOOMLA_URL . 'images/sportsmanager/' . $typ . '/' . basename($pfad_angepasst) . '" width="' . $fixed_width . '" height="' . $fixed_height . '" ' . $zusatz . ' />';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$size = getimagesize($pfad . $ext);
|
||||||
|
$width = $size[0];
|
||||||
|
$height = $size[1];
|
||||||
|
|
||||||
|
$max_width = $fixed_width > 0 ? $fixed_width : $max_width;
|
||||||
|
$max_height = $fixed_height > 0 ? $fixed_height : $max_height;
|
||||||
|
|
||||||
|
if (($fixed_width == 0 || $width == $fixed_width) && ($fixed_height == 0 || $height == $fixed_height) && ($fixed_width != 0 || $max_width == 0 || $width <= $max_width) && ($fixed_height != 0 || $max_height == 0 || $height <= $max_height)) {
|
||||||
|
$pfad_angepasst = SPORTSMANAGER_JOOMLA_PATH . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . "I" . $id . "T" . $time . "W" . $width . "H" . $height . "." . $ext;
|
||||||
|
if (!is_file($pfad_angepasst)) {
|
||||||
|
if (!copy($pfad . $ext, $pfad_angepasst))
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
return '<img src="' . SPORTSMANAGER_JOOMLA_URL . 'images/sportsmanager/' . $typ . '/' . basename($pfad_angepasst) . '" width="' . $width . '" height="' . $height . '" ' . $zusatz . ' />';
|
||||||
|
}
|
||||||
|
|
||||||
|
$new_width = $width;
|
||||||
|
$new_height = $height;
|
||||||
|
|
||||||
|
if ($max_height > 0 && $new_height > $max_height) {
|
||||||
|
$new_width = max(round($new_width * $max_height / $new_height), 1);
|
||||||
|
$new_height = $max_height;
|
||||||
|
}
|
||||||
|
if ($max_width > 0 && $new_width > $max_width) {
|
||||||
|
$new_height = max(round($new_height * $max_width / $new_width), 1);
|
||||||
|
$new_width = $max_width;
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($max_width > 0 && (($max_width - $new_width) % 2) == 1) // Toleranz bei nur 1 Pixel Unterschied
|
||||||
|
$new_width += 1;
|
||||||
|
if ($max_height > 0 && (($max_height - $new_height) % 2) == 1) // Toleranz bei nur 1 Pixel Unterschied
|
||||||
|
$new_height += 1;
|
||||||
|
|
||||||
|
$pfad_angepasst = SPORTSMANAGER_JOOMLA_PATH . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . "I" . $id . "T" . $time . "W" . max($fixed_width, $new_width) . "H" . max($fixed_height, $new_height) . "." . $ext;
|
||||||
|
|
||||||
|
if (!is_file($pfad_angepasst)) {
|
||||||
|
$image = $ext == "png" ? imagecreatefrompng($pfad . $ext) : imagecreatefromjpeg($pfad . $ext);
|
||||||
|
if ($image === false)
|
||||||
|
return null;
|
||||||
|
|
||||||
|
$image_resized = imagecreatetruecolor(max($fixed_width, $new_width), max($fixed_height, $new_height));
|
||||||
|
$color = $ext == "png" ? imagecolorallocatealpha($image_resized, 0, 0, 0, 127) : imagecolorallocate($image_resized, 64, 64, 64);
|
||||||
|
imagefill($image_resized, 0, 0, $color);
|
||||||
|
imagecopyresampled($image_resized, $image, round((imagesx($image_resized) - $new_width) / 2), round((imagesy($image_resized) - $new_height) / 2), 0, 0, $new_width, $new_height, $width, $height);
|
||||||
|
if ($ext == "png") {
|
||||||
|
imagesavealpha($image_resized, true);
|
||||||
|
imagepng($image_resized, $pfad_angepasst);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
imagejpeg($image_resized, $pfad_angepasst);
|
||||||
|
}
|
||||||
|
|
||||||
|
return '<img src="' . SPORTSMANAGER_JOOMLA_URL . 'images/sportsmanager/' . $typ . '/' . basename($pfad_angepasst) . '" width="' . max($fixed_width, $new_width) . '" height="' . max($fixed_height, $new_height) . '" ' . $zusatz . ' />';
|
||||||
|
}
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
[.ShellClassInfo]
|
|
||||||
InfoTip=Dieser Ordner wird online freigegeben.
|
|
||||||
IconFile=C:\Program Files (x86)\Google\Drive\googledrivesync.exe
|
|
||||||
IconIndex=16
|
|
||||||
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
[.ShellClassInfo]
|
|
||||||
InfoTip=Dieser Ordner wird online freigegeben.
|
|
||||||
IconFile=C:\Program Files (x86)\Google\Drive\googledrivesync.exe
|
|
||||||
IconIndex=16
|
|
||||||
|
|
||||||
BIN
Binary file not shown.
@@ -1,5 +0,0 @@
|
|||||||
[.ShellClassInfo]
|
|
||||||
InfoTip=Dieser Ordner wird online freigegeben.
|
|
||||||
IconFile=C:\Program Files (x86)\Google\Drive\googledrivesync.exe
|
|
||||||
IconIndex=16
|
|
||||||
|
|
||||||
File diff suppressed because it is too large
Load Diff
@@ -1,12 +1,18 @@
|
|||||||
<?php
|
<?php
|
||||||
|
|
||||||
|
use JetBrains\PhpStorm\NoReturn;
|
||||||
|
|
||||||
defined('_JEXEC') or die('Restricted access');
|
defined('_JEXEC') or die('Restricted access');
|
||||||
|
|
||||||
require_once(JPATH_COMPONENT . DIRECTORY_SEPARATOR . 'views/sportsmanager/view_tools.php');
|
require_once JPATH_SITE . '/components/com_sportsmanager/views/sportsmanager/view_tools.php';
|
||||||
|
require_once JPATH_SITE . '/components/com_sportsmanager/util/image.php';
|
||||||
|
|
||||||
|
|
||||||
class JSON_sportsmanager {
|
class JSON_sportsmanager
|
||||||
|
{
|
||||||
|
|
||||||
static function mannschaften($veranstaltung, $rows) {
|
static function mannschaften($veranstaltung, $rows): array
|
||||||
|
{
|
||||||
$teams = [];
|
$teams = [];
|
||||||
foreach ($rows as $team) {
|
foreach ($rows as $team) {
|
||||||
$team->teambild = teamImage($team->team_id, $team->verein_id);
|
$team->teambild = teamImage($team->team_id, $team->verein_id);
|
||||||
@@ -22,7 +28,8 @@ class JSON_sportsmanager {
|
|||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
static function tabelleAnzeigen($veranstaltung, $modus, $teams, $spieltag, $spieltage, $alleine_angezeigt, $praesentation) {
|
static function tabelleAnzeigen($modus, $teams): array
|
||||||
|
{
|
||||||
foreach ($teams as $team) {
|
foreach ($teams as $team) {
|
||||||
$team->teambild = teamImage($team->team_id, $team->verein_id);
|
$team->teambild = teamImage($team->team_id, $team->verein_id);
|
||||||
}
|
}
|
||||||
@@ -33,7 +40,8 @@ class JSON_sportsmanager {
|
|||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
static function tabelleEigeneAnzeigen($veranstaltung, $modus, $teams, $alleine_angezeigt, $praesentation) {
|
static function tabelleEigeneAnzeigen($modus, $teams): array
|
||||||
|
{
|
||||||
foreach ($teams as $team) {
|
foreach ($teams as $team) {
|
||||||
$team->teambild = teamImage($team->team_id, $team->verein_id);
|
$team->teambild = teamImage($team->team_id, $team->verein_id);
|
||||||
}
|
}
|
||||||
@@ -43,7 +51,8 @@ class JSON_sportsmanager {
|
|||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
static function _getPlayerDetails($game, $home_player_map, $away_player_map) {
|
static function _getPlayerDetails($game, $home_player_map, $away_player_map): void
|
||||||
|
{
|
||||||
// TODO dynamisch machen
|
// TODO dynamisch machen
|
||||||
$game->heim_spieler_1_vorname = isset($home_player_map[$game->heim_spieler_1_id])
|
$game->heim_spieler_1_vorname = isset($home_player_map[$game->heim_spieler_1_id])
|
||||||
? $home_player_map[$game->heim_spieler_1_id]->vorname
|
? $home_player_map[$game->heim_spieler_1_id]->vorname
|
||||||
@@ -87,7 +96,8 @@ class JSON_sportsmanager {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static function adminEditBegegnungSpielplan($bestaetigen, $veranstaltung, $begegnung, $heim_team, $gast_team, $spiele, $heim_spieler, $gast_spieler, $teamspiel_modus, $encrypted_pin, $count_verlegen_aktionen, $erneut_oeffnen, $aus_uebersicht) {
|
static function adminEditBegegnungSpielplan($bestaetigen, $veranstaltung, $begegnung, $heim_team, $gast_team, $spiele, $heim_spieler, $gast_spieler, $teamspiel_modus): array
|
||||||
|
{
|
||||||
$heim_team->teambild = teamImage($heim_team->team_id, $heim_team->verein_id);
|
$heim_team->teambild = teamImage($heim_team->team_id, $heim_team->verein_id);
|
||||||
$gast_team->teambild = teamImage($gast_team->team_id, $gast_team->verein_id);
|
$gast_team->teambild = teamImage($gast_team->team_id, $gast_team->verein_id);
|
||||||
$heim_spieler_map = [];
|
$heim_spieler_map = [];
|
||||||
@@ -119,7 +129,8 @@ class JSON_sportsmanager {
|
|||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
static function mannschaftDetails($veranstaltung, $team, $mitglieder, $mailverteiler, $mitglieder_statistiken, $teamansprechpartner, $begegnungen, $vorheriges_team_id, $naechstes_team_id, $team_moderator, $details_anzeigen, $ansprechpartner_anzeigen, $weitere_veranstaltungen, $veranstaltungsbezeichnungen, $spielberechtigungen, $ansicht_vereinigt, $ist_vergangen) {
|
static function mannschaftDetails($veranstaltung, $team, $mitglieder, $teamansprechpartner, $begegnungen, $ansprechpartner_anzeigen, $veranstaltungsbezeichnungen): array
|
||||||
|
{
|
||||||
global $sportsmanager_joomla_path;
|
global $sportsmanager_joomla_path;
|
||||||
global $sportsmanager_joomla_url;
|
global $sportsmanager_joomla_url;
|
||||||
|
|
||||||
@@ -156,25 +167,27 @@ class JSON_sportsmanager {
|
|||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
static function JSON($data, $meta = NULL) {
|
#[NoReturn] static function JSON($data, $meta = NULL): void
|
||||||
|
{
|
||||||
$response = [
|
$response = [
|
||||||
'data' => $data
|
'data' => $data
|
||||||
];
|
];
|
||||||
if ($meta != NULL) {
|
if ($meta != NULL) {
|
||||||
$response['meta'] = $meta;
|
$response['meta'] = $meta;
|
||||||
}
|
}
|
||||||
header('Content-Type: application/json; charset=utf-8', true);
|
header('Content-Type: application/json; charset=utf-8');
|
||||||
echo json_encode($response);
|
echo json_encode($response);
|
||||||
jexit();
|
jexit();
|
||||||
}
|
}
|
||||||
|
|
||||||
static function spielerstatistik($spielerstatistik, $spielerstatistik_punkte, $allein_angezeigt, $filter_saison_id, $vorherige_spielerstatistik_id, $naechste_spielerstatistik_id, $details_anzeigen) {
|
#[NoReturn] static function spielerstatistik($spielerstatistik_punkte): void
|
||||||
|
{
|
||||||
$rank = 1;
|
$rank = 1;
|
||||||
foreach ($spielerstatistik_punkte as $s) {
|
foreach ($spielerstatistik_punkte as $s) {
|
||||||
$s->spieler_bild = playerImage($s->spieler_id, $s->geschlecht);
|
$s->spieler_bild = playerImage($s->spieler_id, $s->geschlecht);
|
||||||
$s->spieler_2_bild = playerImage($s->spieler_2_id, $s->geschlecht_2);
|
$s->spieler_2_bild = playerImage($s->spieler_2_id, $s->geschlecht_2);
|
||||||
$s->quote = ($s->spielpunkte_gewonnen > 0 || $s->spielpunkte_verloren > 0)
|
$s->quote = ($s->spielpunkte_gewonnen > 0 || $s->spielpunkte_verloren > 0)
|
||||||
? round($s->spielpunkte_gewonnen * 100 / ($s->spielpunkte_gewonnen + $s->spielpunkte_verloren), 0) . '%'
|
? round($s->spielpunkte_gewonnen * 100 / ($s->spielpunkte_gewonnen + $s->spielpunkte_verloren)) . '%'
|
||||||
: '-';
|
: '-';
|
||||||
$s->rank = '' . $rank;
|
$s->rank = '' . $rank;
|
||||||
$rank++;
|
$rank++;
|
||||||
@@ -182,7 +195,8 @@ class JSON_sportsmanager {
|
|||||||
self::JSON($spielerstatistik_punkte);
|
self::JSON($spielerstatistik_punkte);
|
||||||
}
|
}
|
||||||
|
|
||||||
static function spielerDetails($spieler, $vereine, $veranstalter, $spieler_elo_verlauf_einzel, $spieler_elo_verlauf_doppel, $spielerNamen, $teamNamen, $veranstaltungBezeichnungen, $turnierdisziplinBezeichnungen, $individualwettbewerbBezeichnungen, $ranglistenplatzierungen, $turnierplatzierungen, $teams, $sortierung, $vorheriger_spieler_id, $naechster_spieler_id, $elo_detailliert, $statistik, $beginn, $kategorie, $einstufungen, $filter, $veranstaltungid, $veranstalterid, $einstufungid, $unabhaengige_ansicht, $details_anzeigen) {
|
#[NoReturn] static function spielerDetails($spieler, $vereine, $veranstalter, $spieler_elo_verlauf_einzel, $spieler_elo_verlauf_doppel, $spielerNamen, $teamNamen, $veranstaltungBezeichnungen, $turnierdisziplinBezeichnungen, $individualwettbewerbBezeichnungen, $ranglistenplatzierungen, $turnierplatzierungen, $teams, $elo_detailliert, $statistik, $einstufungen): void
|
||||||
|
{
|
||||||
$letzte_einzel = [];
|
$letzte_einzel = [];
|
||||||
$spieler->bild = playerImage($spieler->spieler_id, $spieler->geschlecht);
|
$spieler->bild = playerImage($spieler->spieler_id, $spieler->geschlecht);
|
||||||
for ($i = sizeof($spieler_elo_verlauf_einzel) - 1; $i >= max(sizeof($spieler_elo_verlauf_einzel) - 10, 0); $i--) {
|
for ($i = sizeof($spieler_elo_verlauf_einzel) - 1; $i >= max(sizeof($spieler_elo_verlauf_einzel) - 10, 0); $i--) {
|
||||||
@@ -285,13 +299,14 @@ class JSON_sportsmanager {
|
|||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
static function begegnungVerlegen($veranstaltung, $begegnung, $heim_team, $gast_team, $verlegen_aktionen, $berechtigt_fuer_akzeptieren, $aus_uebersicht, $vorschlagendes_team_id) {
|
#[NoReturn] static function begegnungVerlegen($veranstaltung, $verlegen_aktionen, $berechtigt_fuer_akzeptieren, $vorschlagendes_team_id): void
|
||||||
|
{
|
||||||
$letzte_aktionen = array();
|
$letzte_aktionen = array();
|
||||||
foreach ($verlegen_aktionen as $aktion) {
|
foreach ($verlegen_aktionen as $aktion) {
|
||||||
if ($aktion->aktion == 1 || $aktion->aktion == 5 || $aktion == 10) {
|
if ($aktion->aktion == 1 || $aktion->aktion == 5 || $aktion == 10) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
array_push($letzte_aktionen, $aktion);
|
$letzte_aktionen[] = $aktion;
|
||||||
}
|
}
|
||||||
$termine = array();
|
$termine = array();
|
||||||
if (count($letzte_aktionen) > 0) {
|
if (count($letzte_aktionen) > 0) {
|
||||||
@@ -300,7 +315,7 @@ class JSON_sportsmanager {
|
|||||||
if ($aktion->eingetragen != $eingetragen || $aktion->aktion != 0 || $aktion->zeitpunkt == NULL) {
|
if ($aktion->eingetragen != $eingetragen || $aktion->aktion != 0 || $aktion->zeitpunkt == NULL) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
array_push($termine, $aktion);
|
$termine[] = $aktion;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -328,7 +343,7 @@ class JSON_sportsmanager {
|
|||||||
'termine' => $response,
|
'termine' => $response,
|
||||||
'berechtigt_anfordern' => $berechtigt_anfordern,
|
'berechtigt_anfordern' => $berechtigt_anfordern,
|
||||||
'berechtigt_ablehnen' => $berechtigt_ablehnen,
|
'berechtigt_ablehnen' => $berechtigt_ablehnen,
|
||||||
'berechtigt_akzeptieren' => $berechtigt_fuer_akzeptieren ? TRUE : FALSE,
|
'berechtigt_akzeptieren' => (bool)$berechtigt_fuer_akzeptieren,
|
||||||
'termine_minimal' => $veranstaltung->termine_minimal,
|
'termine_minimal' => $veranstaltung->termine_minimal,
|
||||||
'termine_maximal' => $veranstaltung->termine_maximal,
|
'termine_maximal' => $veranstaltung->termine_maximal,
|
||||||
]);
|
]);
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -3,29 +3,32 @@
|
|||||||
* Sports Manager (C) 2006-2020, Sven Nickel
|
* Sports Manager (C) 2006-2020, Sven Nickel
|
||||||
*/
|
*/
|
||||||
|
|
||||||
// kein direkter Zugriff
|
use Joomla\Filesystem\Folder;
|
||||||
defined('_JEXEC') or die('Restricted access');
|
use Joomla\CMS\Router\Route;
|
||||||
|
use Joomla\CMS\Language\Text;
|
||||||
|
use Joomla\CMS\Uri\Uri;
|
||||||
|
|
||||||
function htmlentities_utf8($s) {
|
// kein direkter Zugriff
|
||||||
|
defined("_JEXEC") or die("Restricted access");
|
||||||
|
|
||||||
|
function htmlentities_utf8($s): string
|
||||||
|
{
|
||||||
return htmlentities($s, ENT_QUOTES, "UTF-8");
|
return htmlentities($s, ENT_QUOTES, "UTF-8");
|
||||||
}
|
}
|
||||||
|
|
||||||
function htmlentities_noquotes_utf8($s) {
|
function addOnLoad($function): void
|
||||||
return htmlentities($s, ENT_NOQUOTES, "UTF-8");
|
{
|
||||||
}
|
|
||||||
|
|
||||||
function addOnLoad($function) {
|
|
||||||
?>
|
?>
|
||||||
<script language="JavaScript">
|
<script language="JavaScript">
|
||||||
function addLoadEvent(func) {
|
function addLoadEvent(func) {
|
||||||
var oldonload = window.onload;
|
const oldOnload = window.onload;
|
||||||
if (typeof window.onload != 'function') {
|
if (typeof window.onload != 'function') {
|
||||||
window.onload = func;
|
window.onload = func;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
window.onload = function () {
|
window.onload = function () {
|
||||||
if (oldonload) {
|
if (oldOnload) {
|
||||||
oldonload();
|
oldOnload();
|
||||||
}
|
}
|
||||||
func();
|
func();
|
||||||
}
|
}
|
||||||
@@ -37,57 +40,87 @@ function addOnLoad($function) {
|
|||||||
<?php
|
<?php
|
||||||
}
|
}
|
||||||
|
|
||||||
function SportsManagerURL($weitereParameter = null, $ssl = 0) {
|
function SportsManagerURL($weitereParameter = "", $ssl = 0): ?string
|
||||||
return JRoute::_('index.php' . ($weitereParameter != null ? ("?" . ltrim($weitereParameter, "&")) : ""), false, $ssl);
|
{
|
||||||
|
$urlPath = handleFilter($weitereParameter);
|
||||||
|
$joomlaBaseUrl = Uri::getInstance()->toString([
|
||||||
|
"scheme",
|
||||||
|
"host",
|
||||||
|
"port",
|
||||||
|
"path",
|
||||||
|
]);
|
||||||
|
|
||||||
|
if (str_contains($joomlaBaseUrl, "?")) {
|
||||||
|
// Base URL already contains a query string, append with '&'
|
||||||
|
$finalUrl = $joomlaBaseUrl . "&" . ltrim($urlPath, "&");
|
||||||
|
} else {
|
||||||
|
// Base URL does not contain a query string, append with '?'
|
||||||
|
$finalUrl = $joomlaBaseUrl . "?" . ltrim($urlPath, "&");
|
||||||
}
|
}
|
||||||
|
|
||||||
function NichtLeererString($s, $ersatz = "Keiner") {
|
return Route::_($finalUrl, false, $ssl);
|
||||||
|
}
|
||||||
|
|
||||||
|
function handleFilter($urlPart)
|
||||||
|
{
|
||||||
|
// Check if both '&filter=' and '#' are present in the URL part
|
||||||
|
if (
|
||||||
|
str_contains($urlPart, "&filter=") &&
|
||||||
|
str_contains($urlPart, "#")
|
||||||
|
) {
|
||||||
|
// Split the string by '#' to remove the hash part
|
||||||
|
$parts = explode("#", $urlPart, 2);
|
||||||
|
$query = $parts[0];
|
||||||
|
|
||||||
|
// Parse the query string into an associative array
|
||||||
|
parse_str($query, $queryParams);
|
||||||
|
|
||||||
|
// Remove the 'filter' parameter if it exists
|
||||||
|
unset($queryParams["filter"]);
|
||||||
|
|
||||||
|
// Rebuild the query string without the 'filter' parameter
|
||||||
|
return http_build_query($queryParams);
|
||||||
|
} else {
|
||||||
|
// Return the original URL part if either '&filter=' or '#' is not present
|
||||||
|
return $urlPart;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function NichtLeererString($s, $ersatz = "Keiner")
|
||||||
|
{
|
||||||
return !empty($s) ? $s : $ersatz;
|
return !empty($s) ? $s : $ersatz;
|
||||||
}
|
}
|
||||||
|
|
||||||
function hervorheben($titel) {
|
function hervorheben($titel) {
|
||||||
if (empty($titel))
|
if (empty($titel)) {
|
||||||
return $titel;
|
return $titel;
|
||||||
|
|
||||||
return $titel . ' *';
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function Laenderkennungen() {
|
return $titel . " *";
|
||||||
$kennungen = array("AUT", "BEL", "BUL", "CZE", "DEN", "FRA", "GBR", "GER", "LUX", "NED", "SUI", "USA");
|
|
||||||
|
|
||||||
return $kennungen;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function rundenstufe($stufe) {
|
function Laenderkennungen(): array
|
||||||
switch ($stufe) {
|
{
|
||||||
case 0:
|
return array("AUT", "BEL", "BUL", "CZE", "DEN", "FRA", "GBR", "GER", "LUX", "NED", "SUI", "USA");
|
||||||
$bezeichnung = JText::_('COM_SPORTSMANAGER_FINAL_RANKS');
|
}
|
||||||
break;
|
|
||||||
case 1:
|
|
||||||
$bezeichnung = JText::_('COM_SPORTSMANAGER_MAIN_ROUND');
|
|
||||||
break;
|
|
||||||
case 2:
|
|
||||||
$bezeichnung = JText::_('COM_SPORTSMANAGER_ADDITIONAL_ROUND');
|
|
||||||
break;
|
|
||||||
case 3:
|
|
||||||
$bezeichnung = JText::_('COM_SPORTSMANAGER_2ND_ADDITIONAL_ROUND');
|
|
||||||
break;
|
|
||||||
case 10:
|
|
||||||
$bezeichnung = JText::_('COM_SPORTSMANAGER_PRELIMINARY_ROUND');
|
|
||||||
break;
|
|
||||||
case 20:
|
|
||||||
$bezeichnung = JText::_('COM_SPORTSMANAGER_REGISTRATIONS');
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
$bezeichnung = "";
|
|
||||||
} // switch
|
|
||||||
|
|
||||||
return $bezeichnung;
|
function rundenstufe($stufe): string
|
||||||
|
{
|
||||||
|
return match ($stufe) {
|
||||||
|
0 => Text::_("COM_SPORTSMANAGER_FINAL_RANKS"),
|
||||||
|
1 => Text::_("COM_SPORTSMANAGER_MAIN_ROUND"),
|
||||||
|
2 => Text::_("COM_SPORTSMANAGER_ADDITIONAL_ROUND"),
|
||||||
|
3 => Text::_("COM_SPORTSMANAGER_2ND_ADDITIONAL_ROUND"),
|
||||||
|
10 => Text::_("COM_SPORTSMANAGER_PRELIMINARY_ROUND"),
|
||||||
|
20 => Text::_("COM_SPORTSMANAGER_REGISTRATIONS"),
|
||||||
|
default => "",
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
function StringsZusammenfassen($titel1, $titel2, $ersatz = null, $separator = " / ") {
|
function StringsZusammenfassen($titel1, $titel2, $ersatz = null, $separator = " / ") {
|
||||||
if ($ersatz == null)
|
if ($ersatz == null) {
|
||||||
$ersatz = JText::_('COM_SPORTSMANAGER_NONE');
|
$ersatz = Text::_("COM_SPORTSMANAGER_NONE");
|
||||||
|
}
|
||||||
$t1 = NichtLeererString($titel1, $ersatz);
|
$t1 = NichtLeererString($titel1, $ersatz);
|
||||||
$t2 = NichtLeererString($titel2, $ersatz);
|
$t2 = NichtLeererString($titel2, $ersatz);
|
||||||
|
|
||||||
@@ -97,65 +130,59 @@ function StringsZusammenfassen($titel1, $titel2, $ersatz = null, $separator = "
|
|||||||
function Rundenbezeichnung($runde, $spieltag = false, $bezeichnung_verstecken = false, $kurzform = false) {
|
function Rundenbezeichnung($runde, $spieltag = false, $bezeichnung_verstecken = false, $kurzform = false) {
|
||||||
if ($kurzform) {
|
if ($kurzform) {
|
||||||
if ($runde >= 20000)
|
if ($runde >= 20000)
|
||||||
return JText::sprintf('COM_SPORTSMANAGER_PLACE_FROM_TO_SHORTCUT', 99 - $runde % 100, 99 - floor(($runde - 20000) / 100) + 99 - ($runde % 100));
|
return Text::sprintf("COM_SPORTSMANAGER_PLACE_FROM_TO_SHORTCUT", 99 - $runde % 100, 99 - floor(($runde - 20000) / 100) + 99 - ($runde % 100));
|
||||||
|
|
||||||
switch ($runde) {
|
return match ($runde) {
|
||||||
case 0:
|
0 => $spieltag
|
||||||
return $spieltag ? JText::_('COM_SPORTSMANAGER_MATCH_DAY_NONE') : JText::_('COM_SPORTSMANAGER_ROUND_NONE');
|
? Text::_("COM_SPORTSMANAGER_MATCH_DAY_NONE")
|
||||||
case 19999:
|
: Text::_("COM_SPORTSMANAGER_ROUND_NONE"),
|
||||||
return JText::_('COM_SPORTSMANAGER_FINAL_SHORTCUT');
|
19999 => Text::_("COM_SPORTSMANAGER_FINAL_SHORTCUT"),
|
||||||
case 19998:
|
19998 => Text::_("COM_SPORTSMANAGER_3RD_PLACE_SHORTCUT"),
|
||||||
return JText::_('COM_SPORTSMANAGER_3RD_PLACE_SHORTCUT');
|
19997 => Text::_("COM_SPORTSMANAGER_HALF_FINAL_SHORTCUT"),
|
||||||
case 19997:
|
19996 => Text::_("COM_SPORTSMANAGER_QUARTER_FINAL_SHORTCUT"),
|
||||||
return JText::_('COM_SPORTSMANAGER_HALF_FINAL_SHORTCUT');
|
19995 => Text::_("COM_SPORTSMANAGER_ROUND_OF_16_SHORTCUT"),
|
||||||
case 19996:
|
19994 => Text::_("COM_SPORTSMANAGER_ROUND_OF_32_SHORTCUT"),
|
||||||
return JText::_('COM_SPORTSMANAGER_QUARTER_FINAL_SHORTCUT');
|
19993 => Text::_("COM_SPORTSMANAGER_ROUND_OF_64_SHORTCUT"),
|
||||||
case 19995:
|
19992 => Text::_("COM_SPORTSMANAGER_ROUND_OF_128_SHORTCUT"),
|
||||||
return JText::_('COM_SPORTSMANAGER_ROUND_OF_16_SHORTCUT');
|
default => $bezeichnung_verstecken ? $runde : Text::sprintf($spieltag ? "COM_SPORTSMANAGER_MATCH_DAY_NR_SHORTCUT" : "COM_SPORTSMANAGER_ROUND_NR_SHORTCUT", $runde),
|
||||||
case 19994:
|
};
|
||||||
return JText::_('COM_SPORTSMANAGER_ROUND_OF_32_SHORTCUT');
|
|
||||||
case 19993:
|
|
||||||
return JText::_('COM_SPORTSMANAGER_ROUND_OF_64_SHORTCUT');
|
|
||||||
case 19992:
|
|
||||||
return JText::_('COM_SPORTSMANAGER_ROUND_OF_128_SHORTCUT');
|
|
||||||
}
|
|
||||||
|
|
||||||
return $bezeichnung_verstecken ? $runde : JText::sprintf($spieltag ? 'COM_SPORTSMANAGER_MATCH_DAY_NR_SHORTCUT' : 'COM_SPORTSMANAGER_ROUND_NR_SHORTCUT', $runde);
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
if ($runde >= 20000)
|
if ($runde >= 20000)
|
||||||
return JText::sprintf('COM_SPORTSMANAGER_PLACE_FROM_TO', 99 - $runde % 100, 99 - floor(($runde - 20000) / 100) + 99 - ($runde % 100));
|
return Text::sprintf("COM_SPORTSMANAGER_PLACE_FROM_TO", 99 - $runde % 100, 99 - floor(($runde - 20000) / 100) + 99 - ($runde % 100));
|
||||||
|
|
||||||
switch ($runde) {
|
return match ($runde) {
|
||||||
case 0:
|
0 => $spieltag
|
||||||
return $spieltag ? JText::_('COM_SPORTSMANAGER_MATCH_DAY_NONE') : JText::_('COM_SPORTSMANAGER_ROUND_NONE');
|
? Text::_("COM_SPORTSMANAGER_MATCH_DAY_NONE")
|
||||||
case 19999:
|
: Text::_("COM_SPORTSMANAGER_ROUND_NONE"),
|
||||||
return JText::_('COM_SPORTSMANAGER_FINAL');
|
19999 => Text::_("COM_SPORTSMANAGER_FINAL"),
|
||||||
case 19998:
|
19998 => Text::_("COM_SPORTSMANAGER_3RD_PLACE"),
|
||||||
return JText::_('COM_SPORTSMANAGER_3RD_PLACE');
|
19997 => Text::_("COM_SPORTSMANAGER_HALF_FINAL"),
|
||||||
case 19997:
|
19996 => Text::_("COM_SPORTSMANAGER_QUARTER_FINAL"),
|
||||||
return JText::_('COM_SPORTSMANAGER_HALF_FINAL');
|
19995 => Text::_("COM_SPORTSMANAGER_ROUND_OF_16"),
|
||||||
case 19996:
|
19994 => Text::_("COM_SPORTSMANAGER_ROUND_OF_32"),
|
||||||
return JText::_('COM_SPORTSMANAGER_QUARTER_FINAL');
|
19993 => Text::_("COM_SPORTSMANAGER_ROUND_OF_64"),
|
||||||
case 19995:
|
19992 => Text::_("COM_SPORTSMANAGER_ROUND_OF_128"),
|
||||||
return JText::_('COM_SPORTSMANAGER_ROUND_OF_16');
|
default => $bezeichnung_verstecken
|
||||||
case 19994:
|
? $runde
|
||||||
return JText::_('COM_SPORTSMANAGER_ROUND_OF_32');
|
: Text::sprintf(
|
||||||
case 19993:
|
$spieltag
|
||||||
return JText::_('COM_SPORTSMANAGER_ROUND_OF_64');
|
? "COM_SPORTSMANAGER_MATCH_DAY_NR"
|
||||||
case 19992:
|
: "COM_SPORTSMANAGER_ROUND_NR",
|
||||||
return JText::_('COM_SPORTSMANAGER_ROUND_OF_128');
|
$runde
|
||||||
}
|
),
|
||||||
|
};
|
||||||
|
|
||||||
return $bezeichnung_verstecken ? $runde : JText::sprintf($spieltag ? 'COM_SPORTSMANAGER_MATCH_DAY_NR' : 'COM_SPORTSMANAGER_ROUND_NR', $runde);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function FormatiertesDatum($s, $zeit_anzeigen = true, $wochentag_anzeigen = true) {
|
function FormatiertesDatum($s, $zeit_anzeigen = true, $wochentag_anzeigen = true): string
|
||||||
|
{
|
||||||
if ($s != null && strlen($s) > 0) {
|
if ($s != null && strlen($s) > 0) {
|
||||||
$ts = getdate(strtotime($s));
|
$ts = getdate(strtotime($s));
|
||||||
if ($wochentag_anzeigen) {
|
if ($wochentag_anzeigen) {
|
||||||
$wochentage = array(JText::_('COM_SPORTSMANAGER_DAY_0_SHORTCUT'), JText::_('COM_SPORTSMANAGER_DAY_1_SHORTCUT'), JText::_('COM_SPORTSMANAGER_DAY_2_SHORTCUT'), JText::_('COM_SPORTSMANAGER_DAY_3_SHORTCUT'), JText::_('COM_SPORTSMANAGER_DAY_4_SHORTCUT'), JText::_('COM_SPORTSMANAGER_DAY_5_SHORTCUT'), JText::_('COM_SPORTSMANAGER_DAY_6_SHORTCUT'));
|
$wochentage = array(Text::_("COM_SPORTSMANAGER_DAY_0_SHORTCUT"), Text::_("COM_SPORTSMANAGER_DAY_1_SHORTCUT"), Text::_("COM_SPORTSMANAGER_DAY_2_SHORTCUT"), Text::_("COM_SPORTSMANAGER_DAY_3_SHORTCUT"), Text::_("COM_SPORTSMANAGER_DAY_4_SHORTCUT"), Text::_("COM_SPORTSMANAGER_DAY_5_SHORTCUT"), Text::_("COM_SPORTSMANAGER_DAY_6_SHORTCUT"));
|
||||||
if ($zeit_anzeigen)
|
if ($zeit_anzeigen)
|
||||||
return sprintf("%s, %02d.%02d.%04d %02d:%02d", $wochentage[$ts["wday"]], $ts["mday"], $ts["mon"], $ts["year"], $ts["hours"], $ts["minutes"]);
|
return sprintf("%s, %02d.%02d.%04d %02d:%02d", $wochentage[$ts["wday"]], $ts["mday"], $ts["mon"], $ts["year"], $ts["hours"], $ts["minutes"]);
|
||||||
|
|
||||||
@@ -167,10 +194,11 @@ function FormatiertesDatum($s, $zeit_anzeigen = true, $wochentag_anzeigen = true
|
|||||||
return sprintf("%02d.%02d.%04d", $ts["mday"], $ts["mon"], $ts["year"]);
|
return sprintf("%02d.%02d.%04d", $ts["mday"], $ts["mon"], $ts["year"]);
|
||||||
}
|
}
|
||||||
|
|
||||||
return JText::_('COM_SPORTSMANAGER_DATE_NONE');
|
return Text::_("COM_SPORTSMANAGER_DATE_NONE");
|
||||||
}
|
}
|
||||||
|
|
||||||
function FormatierterTermin($erster_tag, $letzter_tag, $jahr_anzeigen = false, $filter_jahr = null) {
|
function FormatierterTermin($erster_tag, $letzter_tag, $jahr_anzeigen = false, $filter_jahr = null): string
|
||||||
|
{
|
||||||
$erster_ts = getdate(strtotime($erster_tag));
|
$erster_ts = getdate(strtotime($erster_tag));
|
||||||
$letzter_ts = getdate(strtotime($letzter_tag));
|
$letzter_ts = getdate(strtotime($letzter_tag));
|
||||||
if (!empty($filter_jahr))
|
if (!empty($filter_jahr))
|
||||||
@@ -188,401 +216,12 @@ function FormatierterTermin($erster_tag, $letzter_tag, $jahr_anzeigen = false, $
|
|||||||
return $erster_termin . "-" . $letzter_termin;
|
return $erster_termin . "-" . $letzter_termin;
|
||||||
}
|
}
|
||||||
|
|
||||||
function bildLoeschen($typ, $id) {
|
function terminDokumentname($id): bool|string
|
||||||
global $sportsmanager_joomla_path;
|
|
||||||
$typ_exploded = explode("/", $typ);
|
|
||||||
$typ = $typ_exploded[0];
|
|
||||||
$typ_prefix = count($typ_exploded) > 1 ? $typ_exploded[1] : "";
|
|
||||||
$bilder_pfad = $sportsmanager_joomla_path . DIRECTORY_SEPARATOR . 'images' . DIRECTORY_SEPARATOR . 'sportsmanager' . DIRECTORY_SEPARATOR . $typ;
|
|
||||||
$pfad = $bilder_pfad . '/' . $typ_prefix . $id . ".";
|
|
||||||
if (!is_file($pfad . 'png') && !is_file($pfad . 'jpg'))
|
|
||||||
return;
|
|
||||||
$alte_bilder = JFolder::files($bilder_pfad, '^' . $typ_prefix . $id . '\.|^' . $typ_prefix . 'I' . $id . 'T');
|
|
||||||
foreach ($alte_bilder as $fn)
|
|
||||||
JFile::delete($bilder_pfad . DIRECTORY_SEPARATOR . $fn);
|
|
||||||
}
|
|
||||||
|
|
||||||
function bildIdentisch($typ1, $id1, $typ2, $id2) {
|
|
||||||
global $sportsmanager_joomla_path;
|
|
||||||
$typ1_exploded = explode("/", $typ1);
|
|
||||||
$typ1 = $typ1_exploded[0];
|
|
||||||
$typ1_prefix = count($typ1_exploded) > 1 ? $typ1_exploded[1] : "";
|
|
||||||
$bilder_pfad1 = $sportsmanager_joomla_path . DIRECTORY_SEPARATOR . 'images' . DIRECTORY_SEPARATOR . 'sportsmanager' . DIRECTORY_SEPARATOR . $typ1;
|
|
||||||
$pfad1 = $bilder_pfad1 . '/' . $typ1_prefix . $id1 . ".";
|
|
||||||
if (is_file($pfad1 . "png"))
|
|
||||||
$ext = "png";
|
|
||||||
else if (is_file($pfad1 . "jpg"))
|
|
||||||
$ext = "jpg";
|
|
||||||
else
|
|
||||||
$ext = "";
|
|
||||||
$pfad1 .= $ext;
|
|
||||||
|
|
||||||
$typ2_exploded = explode("/", $typ2);
|
|
||||||
$typ2 = $typ2_exploded[0];
|
|
||||||
$typ2_prefix = count($typ2_exploded) > 1 ? $typ2_exploded[1] : "";
|
|
||||||
$bilder_pfad2 = $sportsmanager_joomla_path . DIRECTORY_SEPARATOR . 'images' . DIRECTORY_SEPARATOR . 'sportsmanager' . DIRECTORY_SEPARATOR . $typ2;
|
|
||||||
$pfad2 = $bilder_pfad2 . '/' . $typ2_prefix . $id2 . "." . $ext;
|
|
||||||
|
|
||||||
return files_identical($pfad1, $pfad2);
|
|
||||||
}
|
|
||||||
|
|
||||||
function teamImage($teamId, $vereinId, $width = 240, $height = 240) {
|
|
||||||
$url = bildURL("mannschaften", $teamId, 0, 0, $width, $height);
|
|
||||||
|
|
||||||
if ($url == null) {
|
|
||||||
$url = bildURL("vereine", $vereinId, 0, 0, $width, $height);
|
|
||||||
}
|
|
||||||
|
|
||||||
return $url;
|
|
||||||
}
|
|
||||||
|
|
||||||
function playerImage($playerId, $gender, $width = 180, $height = 240) {
|
|
||||||
$url = bildURL("spieler", $playerId, $width, $height, 0,0,'', $gender == 'M' ? 'm' : 'w');
|
|
||||||
if ($url == null) {
|
|
||||||
$url = bildURL("mannschaftsmitglieder", $playerId, $width, $height, 0,0,'');
|
|
||||||
}
|
|
||||||
|
|
||||||
return $url;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
function bildURL($typ, $id, $fixed_width = 0, $fixed_height = 0, $max_width = 0, $max_height = 0, $zusatz = "", $alternativ = "") {
|
|
||||||
global $sportsmanager_joomla_path;
|
|
||||||
global $sportsmanager_joomla_url;
|
|
||||||
|
|
||||||
$typ_exploded = explode("/", $typ);
|
|
||||||
$typ = $typ_exploded[0];
|
|
||||||
$typ_prefix = count($typ_exploded) > 1 ? $typ_exploded[1] : "";
|
|
||||||
|
|
||||||
$pfad = $sportsmanager_joomla_path . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . $id . ".";
|
|
||||||
if (is_file($pfad . "png"))
|
|
||||||
$ext = "png";
|
|
||||||
else if (is_file($pfad . "jpg"))
|
|
||||||
$ext = "jpg";
|
|
||||||
else if (!empty($alternativ)) {
|
|
||||||
$id = $alternativ;
|
|
||||||
$pfad = $sportsmanager_joomla_path . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . $id . ".";
|
|
||||||
if (is_file($pfad . "png"))
|
|
||||||
$ext = "png";
|
|
||||||
else if (is_file($pfad . "jpg"))
|
|
||||||
$ext = "jpg";
|
|
||||||
else
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
return null;
|
|
||||||
|
|
||||||
$time = filemtime($pfad . $ext);
|
|
||||||
|
|
||||||
if ($fixed_width > 0 && $fixed_height > 0) {
|
|
||||||
$pfad_angepasst = $sportsmanager_joomla_path . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . "I" . $id . "T" . $time . "W" . $fixed_width . "H" . $fixed_height . "." . $ext;
|
|
||||||
if (is_file($pfad_angepasst)) {
|
|
||||||
return $sportsmanager_joomla_url . 'images/sportsmanager/' . $typ . '/' . basename($pfad_angepasst);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
$size = getimagesize($pfad . $ext);
|
|
||||||
$width = $size[0];
|
|
||||||
$height = $size[1];
|
|
||||||
|
|
||||||
$max_width = $fixed_width > 0 ? $fixed_width : $max_width;
|
|
||||||
$max_height = $fixed_height > 0 ? $fixed_height : $max_height;
|
|
||||||
|
|
||||||
if (($fixed_width == 0 || $width == $fixed_width) && ($fixed_height == 0 || $height == $fixed_height) && ($fixed_width != 0 || $max_width == 0 || $width <= $max_width) && ($fixed_height != 0 || $max_height == 0 || $height <= $max_height)) {
|
|
||||||
$pfad_angepasst = $sportsmanager_joomla_path . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . "I" . $id . "T" . $time . "W" . $width . "H" . $height . "." . $ext;
|
|
||||||
if (!is_file($pfad_angepasst)) {
|
|
||||||
if (!copy($pfad . $ext, $pfad_angepasst))
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
|
|
||||||
return $sportsmanager_joomla_url . 'images/sportsmanager/' . $typ . '/' . basename($pfad_angepasst);
|
|
||||||
}
|
|
||||||
|
|
||||||
$new_width = $width;
|
|
||||||
$new_height = $height;
|
|
||||||
|
|
||||||
if ($max_height > 0 && $new_height > $max_height) {
|
|
||||||
$new_width = max(round($new_width * $max_height / $new_height), 1);
|
|
||||||
$new_height = $max_height;
|
|
||||||
}
|
|
||||||
if ($max_width > 0 && $new_width > $max_width) {
|
|
||||||
$new_height = max(round($new_height * $max_width / $new_width), 1);
|
|
||||||
$new_width = $max_width;
|
|
||||||
}
|
|
||||||
|
|
||||||
if ($max_width > 0 && (($max_width - $new_width) % 2) == 1) // Toleranz bei nur 1 Pixel Unterschied
|
|
||||||
$new_width += 1;
|
|
||||||
if ($max_height > 0 && (($max_height - $new_height) % 2) == 1) // Toleranz bei nur 1 Pixel Unterschied
|
|
||||||
$new_height += 1;
|
|
||||||
|
|
||||||
$pfad_angepasst = $sportsmanager_joomla_path . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . "I" . $id . "T" . $time . "W" . max($fixed_width, $new_width) . "H" . max($fixed_height, $new_height) . "." . $ext;
|
|
||||||
|
|
||||||
if (!is_file($pfad_angepasst)) {
|
|
||||||
$image = $ext == "png" ? imagecreatefrompng($pfad . $ext) : imagecreatefromjpeg($pfad . $ext);
|
|
||||||
if ($image === false)
|
|
||||||
return null;
|
|
||||||
|
|
||||||
$image_resized = imagecreatetruecolor(max($fixed_width, $new_width), max($fixed_height, $new_height));
|
|
||||||
$color = $ext == "png" ? imagecolorallocatealpha($image_resized, 0, 0, 0, 127) : imagecolorallocate($image_resized, 64, 64, 64);
|
|
||||||
imagefill($image_resized, 0, 0, $color);
|
|
||||||
imagecopyresampled($image_resized, $image, round((imagesx($image_resized) - $new_width) / 2), round((imagesy($image_resized) - $new_height) / 2), 0, 0, $new_width, $new_height, $width, $height);
|
|
||||||
if ($ext == "png") {
|
|
||||||
imagesavealpha($image_resized, true);
|
|
||||||
imagepng($image_resized, $pfad_angepasst);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
imagejpeg($image_resized, $pfad_angepasst);
|
|
||||||
}
|
|
||||||
|
|
||||||
return $sportsmanager_joomla_url . 'images/sportsmanager/' . $typ . '/' . basename($pfad_angepasst);
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* #resize=250
|
|
||||||
#resize=250,250,blue
|
|
||||||
#resize=250,250,blue
|
|
||||||
#resize=250,250&sizes=60%,80%,200%
|
|
||||||
#resize=250,250,cover&sizes=60%,80%,200%
|
|
||||||
#resize=250,250,fill&sizes=60%,80%,200%
|
|
||||||
#crop=250,250,center,top
|
|
||||||
#crop=250,250
|
|
||||||
#crop=250,250,center,bottom
|
|
||||||
#crop=250,250,left
|
|
||||||
#crop=250,250,right
|
|
||||||
*/
|
|
||||||
function yoothemeBild($typ, $id, $resize = '', $zusatz = "", $alternativ)
|
|
||||||
{
|
{
|
||||||
global $sportsmanager_joomla_path;
|
global $sportsmanager_joomla_path;
|
||||||
global $sportsmanager_joomla_url;
|
|
||||||
|
|
||||||
$typ_exploded = explode("/", $typ);
|
|
||||||
$typ = $typ_exploded[0];
|
|
||||||
$typ_prefix = count($typ_exploded) > 1 ? $typ_exploded[1] : "";
|
|
||||||
$pfad = $sportsmanager_joomla_path . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . $id . ".";
|
|
||||||
|
|
||||||
if (is_file($pfad . "png"))
|
|
||||||
$ext = "png";
|
|
||||||
else if (is_file($pfad . "jpg"))
|
|
||||||
$ext = "jpg";
|
|
||||||
else if (!empty($alternativ)) {
|
|
||||||
$id = $alternativ;
|
|
||||||
$pfad = $sportsmanager_joomla_path . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . $id . ".";
|
|
||||||
if (is_file($pfad . "png"))
|
|
||||||
$ext = "png";
|
|
||||||
else if (is_file($pfad . "jpg"))
|
|
||||||
$ext = "jpg";
|
|
||||||
else
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
return null;
|
|
||||||
|
|
||||||
$time = filemtime($pfad . $ext);
|
|
||||||
|
|
||||||
$bildpfad = "images/sportsmanager/" . $typ . "/" . $typ_prefix . $id . "." . $ext;
|
|
||||||
|
|
||||||
|
|
||||||
return '<img class="el-image" data-src="' . $bildpfad . $resize . '" ' . $zusatz . ' uk-img />';
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
Quick and dirty DTFL Logo Bilder
|
|
||||||
*/
|
|
||||||
|
|
||||||
function logoBilder($typ, $id, $resize = '', $zusatz = "", $alternativ)
|
|
||||||
{
|
|
||||||
global $sportsmanager_joomla_path;
|
|
||||||
global $sportsmanager_joomla_url;
|
|
||||||
|
|
||||||
$typ_exploded = explode("/", $typ);
|
|
||||||
$typ = $typ_exploded[0];
|
|
||||||
$typ_prefix = count($typ_exploded) > 1 ? $typ_exploded[1] : "";
|
|
||||||
$pfad = $sportsmanager_joomla_path . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . $id . ".";
|
|
||||||
|
|
||||||
if (is_file($pfad . "png"))
|
|
||||||
$ext = "png";
|
|
||||||
else if (is_file($pfad . "jpg"))
|
|
||||||
$ext = "jpg";
|
|
||||||
else if (!empty($alternativ)) {
|
|
||||||
$id = $alternativ;
|
|
||||||
$pfad = $sportsmanager_joomla_path . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . $id . ".";
|
|
||||||
if (is_file($pfad . "png"))
|
|
||||||
$ext = "png";
|
|
||||||
else if (is_file($pfad . "jpg"))
|
|
||||||
$ext = "jpg";
|
|
||||||
else
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
return null;
|
|
||||||
|
|
||||||
$time = filemtime($pfad . $ext);
|
|
||||||
|
|
||||||
$bildpfad = "images/sportsmanager/" . $typ . "/" . $typ_prefix . $id . "." . $ext;
|
|
||||||
|
|
||||||
|
|
||||||
return '<img class="el-image" data-src="' . $bildpfad . $resize . '" ' . $zusatz . ' uk-img />';
|
|
||||||
}
|
|
||||||
|
|
||||||
function bildHTML($typ, $id, $fixed_width = 0, $fixed_height = 0, $max_width = 0, $max_height = 0, $zusatz = "", $alternativ = "") {
|
|
||||||
global $sportsmanager_joomla_path;
|
|
||||||
global $sportsmanager_joomla_url;
|
|
||||||
|
|
||||||
$typ_exploded = explode("/", $typ);
|
|
||||||
$typ = $typ_exploded[0];
|
|
||||||
$typ_prefix = count($typ_exploded) > 1 ? $typ_exploded[1] : "";
|
|
||||||
|
|
||||||
$pfad = $sportsmanager_joomla_path . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . $id . ".";
|
|
||||||
if (is_file($pfad . "png"))
|
|
||||||
$ext = "png";
|
|
||||||
else if (is_file($pfad . "jpg"))
|
|
||||||
$ext = "jpg";
|
|
||||||
else if (!empty($alternativ)) {
|
|
||||||
$id = $alternativ;
|
|
||||||
$pfad = $sportsmanager_joomla_path . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . $id . ".";
|
|
||||||
if (is_file($pfad . "png"))
|
|
||||||
$ext = "png";
|
|
||||||
else if (is_file($pfad . "jpg"))
|
|
||||||
$ext = "jpg";
|
|
||||||
else
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
return null;
|
|
||||||
|
|
||||||
$time = filemtime($pfad . $ext);
|
|
||||||
|
|
||||||
if ($fixed_width > 0 && $fixed_height > 0) {
|
|
||||||
$pfad_angepasst = $sportsmanager_joomla_path . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . "I" . $id . "T" . $time . "W" . $fixed_width . "H" . $fixed_height . "." . $ext;
|
|
||||||
if (is_file($pfad_angepasst)) {
|
|
||||||
return '<img src="' . $sportsmanager_joomla_url . 'images/sportsmanager/' . $typ . '/' . basename($pfad_angepasst) . '" width="' . $fixed_width . '" height="' . $fixed_height . '" ' . $zusatz . ' />';
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
$size = getimagesize($pfad . $ext);
|
|
||||||
$width = $size[0];
|
|
||||||
$height = $size[1];
|
|
||||||
|
|
||||||
$max_width = $fixed_width > 0 ? $fixed_width : $max_width;
|
|
||||||
$max_height = $fixed_height > 0 ? $fixed_height : $max_height;
|
|
||||||
|
|
||||||
if (($fixed_width == 0 || $width == $fixed_width) && ($fixed_height == 0 || $height == $fixed_height) && ($fixed_width != 0 || $max_width == 0 || $width <= $max_width) && ($fixed_height != 0 || $max_height == 0 || $height <= $max_height)) {
|
|
||||||
$pfad_angepasst = $sportsmanager_joomla_path . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . "I" . $id . "T" . $time . "W" . $width . "H" . $height . "." . $ext;
|
|
||||||
if (!is_file($pfad_angepasst)) {
|
|
||||||
if (!copy($pfad . $ext, $pfad_angepasst))
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
|
|
||||||
return '<img src="' . $sportsmanager_joomla_url . 'images/sportsmanager/' . $typ . '/' . basename($pfad_angepasst) . '" width="' . $width . '" height="' . $height . '" ' . $zusatz . ' />';
|
|
||||||
}
|
|
||||||
|
|
||||||
$new_width = $width;
|
|
||||||
$new_height = $height;
|
|
||||||
|
|
||||||
if ($max_height > 0 && $new_height > $max_height) {
|
|
||||||
$new_width = max(round($new_width * $max_height / $new_height), 1);
|
|
||||||
$new_height = $max_height;
|
|
||||||
}
|
|
||||||
if ($max_width > 0 && $new_width > $max_width) {
|
|
||||||
$new_height = max(round($new_height * $max_width / $new_width), 1);
|
|
||||||
$new_width = $max_width;
|
|
||||||
}
|
|
||||||
|
|
||||||
if ($max_width > 0 && (($max_width - $new_width) % 2) == 1) // Toleranz bei nur 1 Pixel Unterschied
|
|
||||||
$new_width += 1;
|
|
||||||
if ($max_height > 0 && (($max_height - $new_height) % 2) == 1) // Toleranz bei nur 1 Pixel Unterschied
|
|
||||||
$new_height += 1;
|
|
||||||
|
|
||||||
$pfad_angepasst = $sportsmanager_joomla_path . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . "I" . $id . "T" . $time . "W" . max($fixed_width, $new_width) . "H" . max($fixed_height, $new_height) . "." . $ext;
|
|
||||||
|
|
||||||
if (!is_file($pfad_angepasst)) {
|
|
||||||
$image = $ext == "png" ? imagecreatefrompng($pfad . $ext) : imagecreatefromjpeg($pfad . $ext);
|
|
||||||
if ($image === false)
|
|
||||||
return null;
|
|
||||||
|
|
||||||
$image_resized = imagecreatetruecolor(max($fixed_width, $new_width), max($fixed_height, $new_height));
|
|
||||||
$color = $ext == "png" ? imagecolorallocatealpha($image_resized, 0, 0, 0, 127) : imagecolorallocate($image_resized, 64, 64, 64);
|
|
||||||
imagefill($image_resized, 0, 0, $color);
|
|
||||||
imagecopyresampled($image_resized, $image, round((imagesx($image_resized) - $new_width) / 2), round((imagesy($image_resized) - $new_height) / 2), 0, 0, $new_width, $new_height, $width, $height);
|
|
||||||
if ($ext == "png") {
|
|
||||||
imagesavealpha($image_resized, true);
|
|
||||||
imagepng($image_resized, $pfad_angepasst);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
imagejpeg($image_resized, $pfad_angepasst);
|
|
||||||
}
|
|
||||||
|
|
||||||
return '<img src="' . $sportsmanager_joomla_url . 'images/sportsmanager/' . $typ . '/' . basename($pfad_angepasst) . '" width="' . max($fixed_width, $new_width) . '" height="' . max($fixed_height, $new_height) . '" ' . $zusatz . ' />';
|
|
||||||
}
|
|
||||||
|
|
||||||
function terminDokumentname($id) {
|
|
||||||
global $sportsmanager_joomla_path;
|
|
||||||
|
|
||||||
$pfad = $sportsmanager_joomla_path . "/images/sportsmanager/termine";
|
$pfad = $sportsmanager_joomla_path . "/images/sportsmanager/termine";
|
||||||
$dokumente = JFolder::files($pfad, '^' . $id . ' ');
|
$dokumente = Folder::files($pfad, '^' . $id . ' ');
|
||||||
|
|
||||||
return !empty($dokumente) ? substr($dokumente[0], strlen((string) $id) + 1) : false;
|
return !empty($dokumente) ? substr($dokumente[0], strlen((string) $id) + 1) : false;
|
||||||
}
|
}
|
||||||
|
|
||||||
function lightBoxJSShow($lightbox_class = "lightbox") {
|
|
||||||
return "show" . $lightbox_class . "();";
|
|
||||||
}
|
|
||||||
|
|
||||||
function lightBoxJSHide($lightbox_class = "lightbox") {
|
|
||||||
return "hide" . $lightbox_class . "();";
|
|
||||||
}
|
|
||||||
|
|
||||||
function lightBoxClassHide($lightbox_class = "lightbox") {
|
|
||||||
return $lightbox_class . "_close";
|
|
||||||
}
|
|
||||||
|
|
||||||
function lightBoxHeader($lightbox_class = "lightbox") {
|
|
||||||
?>
|
|
||||||
<style type="text/css">
|
|
||||||
div<?php echo "#" . $lightbox_class; ?> {
|
|
||||||
position: fixed;
|
|
||||||
left: 50px;
|
|
||||||
right: 50px;
|
|
||||||
top: 50px;
|
|
||||||
bottom: 50px;
|
|
||||||
border: 1px solid #999999;
|
|
||||||
overflow: scroll;
|
|
||||||
background-color: #e4e4e4;
|
|
||||||
padding: 20px;
|
|
||||||
display: none;
|
|
||||||
visibility: hidden;
|
|
||||||
}
|
|
||||||
|
|
||||||
div<?php echo "#" . $lightbox_class . "_close"; ?> {
|
|
||||||
position: fixed;
|
|
||||||
right: 0px;
|
|
||||||
top: 0px;
|
|
||||||
bottom: 0px;
|
|
||||||
left: 0px;
|
|
||||||
overflow: hidden;
|
|
||||||
display: none;
|
|
||||||
visibility: hidden;
|
|
||||||
background-color: rgba(0, 0, 0, 0.8);
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
||||||
<script type="text/javascript">
|
|
||||||
//<!--
|
|
||||||
function show<?php echo $lightbox_class; ?>() {
|
|
||||||
document.getElementById("<?php echo $lightbox_class; ?>").style.display = "inline";
|
|
||||||
document.getElementById("<?php echo $lightbox_class; ?>").style.visibility = "visible";
|
|
||||||
document.getElementById("<?php echo $lightbox_class . "_close"; ?>").style.display = "inline";
|
|
||||||
document.getElementById("<?php echo $lightbox_class . "_close"; ?>").style.visibility = "visible";
|
|
||||||
}
|
|
||||||
|
|
||||||
function hide<?php echo $lightbox_class; ?>() {
|
|
||||||
document.getElementById("<?php echo $lightbox_class; ?>").style.display = "none";
|
|
||||||
document.getElementById("<?php echo $lightbox_class; ?>").style.visibility = "hidden";
|
|
||||||
document.getElementById("<?php echo $lightbox_class . "_close"; ?>").style.display = "none";
|
|
||||||
document.getElementById("<?php echo $lightbox_class . "_close"; ?>").style.visibility = "hidden";
|
|
||||||
}
|
|
||||||
|
|
||||||
//-->
|
|
||||||
</script>
|
|
||||||
<?php
|
|
||||||
}
|
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
; Sports Manager (C) 2006-2020, Sven Nickel
|
; Sports Manager (C) 2006-2020, Sven Nickel (Test)
|
||||||
COM_SPORTSMANAGER="Sports Manager"
|
COM_SPORTSMANAGER="Sports Manager"
|
||||||
COM_SPORTSMANAGER_PLAYERS="Spieler"
|
COM_SPORTSMANAGER_PLAYERS="Spieler"
|
||||||
COM_SPORTSMANAGER_CLUBS="Vereine"
|
COM_SPORTSMANAGER_CLUBS="Vereine"
|
||||||
@@ -70,17 +70,18 @@ COM_SPORTSMANAGER_CONFIRM_REMOVE_RANKING="Willst du die Rangliste wirklich entfe
|
|||||||
COM_SPORTSMANAGER_ADD_INDIVIDUAL_COMPETITION="Individualwettbewerb hinzufügen"
|
COM_SPORTSMANAGER_ADD_INDIVIDUAL_COMPETITION="Individualwettbewerb hinzufügen"
|
||||||
COM_SPORTSMANAGER_INDIVIDUAL_COMPETITION="Individualwettbewerb"
|
COM_SPORTSMANAGER_INDIVIDUAL_COMPETITION="Individualwettbewerb"
|
||||||
COM_SPORTSMANAGER_INDIVIDUAL_COMPETITIONS="Individualwettbewerbe"
|
COM_SPORTSMANAGER_INDIVIDUAL_COMPETITIONS="Individualwettbewerbe"
|
||||||
|
COM_SPORTSMANAGER_ASSOCIATION_BODIES="Verbandsorgane"
|
||||||
COM_SPORTSMANAGER_GAME="Spiel"
|
COM_SPORTSMANAGER_GAME="Spiel"
|
||||||
COM_SPORTSMANAGER_GAMES="Spiele"
|
COM_SPORTSMANAGER_GAMES="Spiele"
|
||||||
COM_SPORTSMANAGER_GAMES_SHORTCUT="S"
|
COM_SPORTSMANAGER_GAMES_SHORTCUT="S"
|
||||||
COM_SPORTSMANAGER_ADD_PLAYER_STATISTICS="Spielerstatistik hinzufügen"
|
COM_SPORTSMANAGER_ADD_PLAYER_STATISTICS="Spielerstatistik hinzufügen"
|
||||||
COM_SPORTSMANAGER_PLAYER_STATISTICS="Spielerstatistik"
|
COM_SPORTSMANAGER_PLAYER_STATISTIC="Spielerstatistik"
|
||||||
COM_SPORTSMANAGER_COMPETITION="Wettbewerb"
|
COM_SPORTSMANAGER_COMPETITION="Wettbewerb"
|
||||||
COM_SPORTSMANAGER_COMPETITIONS="Wettbewerbe"
|
COM_SPORTSMANAGER_COMPETITIONS="Wettbewerbe"
|
||||||
COM_SPORTSMANAGER_IN_COMPETITIONS="in Wettbewerb"
|
COM_SPORTSMANAGER_IN_COMPETITIONS="in Wettbewerb"
|
||||||
COM_SPORTSMANAGER_COMPETITIONS_SHORTCUT="W"
|
COM_SPORTSMANAGER_COMPETITIONS_SHORTCUT="W"
|
||||||
COM_SPORTSMANAGER_DUPLICATE="Duplizieren"
|
COM_SPORTSMANAGER_DUPLICATE="Duplizieren"
|
||||||
COM_SPORTSMANAGER_CONFIRM_REMOVE_RANKING="Willst du die Spielerstatistik wirklich entfernen?"
|
COM_SPORTSMANAGER_CONFIRM_REMOVE_PLAYER_STATISTICS="Willst du die Spielerstatistik wirklich entfernen?"
|
||||||
COM_SPORTSMANAGER_LIVE_TICKER="Live-Ticker"
|
COM_SPORTSMANAGER_LIVE_TICKER="Live-Ticker"
|
||||||
COM_SPORTSMANAGER_PLACE="Platz"
|
COM_SPORTSMANAGER_PLACE="Platz"
|
||||||
COM_SPORTSMANAGER_TEAM="Mannschaft"
|
COM_SPORTSMANAGER_TEAM="Mannschaft"
|
||||||
@@ -289,7 +290,6 @@ COM_SPORTSMANAGER_REQUEST_MESSAGE_PLURAL="Es müssen mindestens %d Termine v
|
|||||||
COM_SPORTSMANAGER_REJECT_SHIFT="Verschiebung ablehnen"
|
COM_SPORTSMANAGER_REJECT_SHIFT="Verschiebung ablehnen"
|
||||||
COM_SPORTSMANAGER_TO="bis"
|
COM_SPORTSMANAGER_TO="bis"
|
||||||
COM_SPORTSMANAGER_PLAYER_STATISTICS="Spielerstatistiken"
|
COM_SPORTSMANAGER_PLAYER_STATISTICS="Spielerstatistiken"
|
||||||
COM_SPORTSMANAGER_PERFORMANCE_INDEX="Leistungsindex"
|
|
||||||
COM_SPORTSMANAGER_PERFORMANCE_INDEX_SHORTCUT="LI"
|
COM_SPORTSMANAGER_PERFORMANCE_INDEX_SHORTCUT="LI"
|
||||||
COM_SPORTSMANAGER_WON="gewonnen"
|
COM_SPORTSMANAGER_WON="gewonnen"
|
||||||
COM_SPORTSMANAGER_LOST="verloren"
|
COM_SPORTSMANAGER_LOST="verloren"
|
||||||
@@ -649,6 +649,10 @@ COM_SPORTSMANAGER_IMAGE_WITHIN_TEAM="Bild innerhalb Mannschaft"
|
|||||||
COM_SPORTSMANAGER_ADD_MEETING="Begegnung hinzufügen"
|
COM_SPORTSMANAGER_ADD_MEETING="Begegnung hinzufügen"
|
||||||
COM_SPORTSMANAGER_ROUND_GENERATION="Runde erzeugen"
|
COM_SPORTSMANAGER_ROUND_GENERATION="Runde erzeugen"
|
||||||
COM_SPORTSMANAGER_GENERATE_GROUP_GAME="Gruppenspiele erzeugen"
|
COM_SPORTSMANAGER_GENERATE_GROUP_GAME="Gruppenspiele erzeugen"
|
||||||
|
COM_SPORTSMANAGER_IMPORT_GROUP_GAME="Gruppenspiele importieren"
|
||||||
|
COM_SPORTSMANAGER_IMPORT_GROUP_GAME2="Gruppenspiele: Importieren"
|
||||||
|
COM_SPORTSMANAGER_IMPORT_GROUP_GAME_IMPORTED="Begegnungen wurden importiert"
|
||||||
|
COM_SPORTSMANAGER_IMPORT_GROUP_GAME_CREATED="Begegnungen wurden erstellt"
|
||||||
COM_SPORTSMANAGER_REMOVE_ALL_ENCOUNTERS="Willst du wirklich alle Begegnungen entfernen?"
|
COM_SPORTSMANAGER_REMOVE_ALL_ENCOUNTERS="Willst du wirklich alle Begegnungen entfernen?"
|
||||||
COM_SPORTSMANAGER_REMOVE_ALL_MATCHES="Alle Begegnungen entfernen"
|
COM_SPORTSMANAGER_REMOVE_ALL_MATCHES="Alle Begegnungen entfernen"
|
||||||
COM_SPORTSMANAGER_HOME_TEAM="Heimteam"
|
COM_SPORTSMANAGER_HOME_TEAM="Heimteam"
|
||||||
@@ -694,6 +698,7 @@ COM_SPORTSMANAGER_NUMBER_DAYS="%d Tage"
|
|||||||
COM_SPORTSMANAGER_CALENDAR_WEEK="Kalenderwoche"
|
COM_SPORTSMANAGER_CALENDAR_WEEK="Kalenderwoche"
|
||||||
COM_SPORTSMANAGER_CALENDAR_WEEK_SHORTCUT="KW"
|
COM_SPORTSMANAGER_CALENDAR_WEEK_SHORTCUT="KW"
|
||||||
COM_SPORTSMANAGER_PAIRING="Paarung"
|
COM_SPORTSMANAGER_PAIRING="Paarung"
|
||||||
|
COM_SPORTSMANAGER_SETTING="Setzen"
|
||||||
COM_SPORTSMANAGER_PAIRINGS="Paarungen"
|
COM_SPORTSMANAGER_PAIRINGS="Paarungen"
|
||||||
COM_SPORTSMANAGER_INTERMITTENT="Aussetzend"
|
COM_SPORTSMANAGER_INTERMITTENT="Aussetzend"
|
||||||
COM_SPORTSMANAGER_MAXIMUM_SETS="Sätze maximal"
|
COM_SPORTSMANAGER_MAXIMUM_SETS="Sätze maximal"
|
||||||
@@ -827,7 +832,6 @@ COM_SPORTSMANAGER_REMOVE_STATE_REALLY="Willst du das Land wirklich entfernen?"
|
|||||||
COM_SPORTSMANAGER_DATES_STATE="Termine Land"
|
COM_SPORTSMANAGER_DATES_STATE="Termine Land"
|
||||||
COM_SPORTSMANAGER_RENAME_APPOINTMENTS_STATE="Termine mit dem bisherigen Land umbenennen"
|
COM_SPORTSMANAGER_RENAME_APPOINTMENTS_STATE="Termine mit dem bisherigen Land umbenennen"
|
||||||
COM_SPORTSMANAGER_FINAL_RANKING="FINAL RANKING"
|
COM_SPORTSMANAGER_FINAL_RANKING="FINAL RANKING"
|
||||||
COM_SPORTSMANAGER_HOME_TEAM2="Heimmanschaft"
|
|
||||||
COM_SPORTSMANAGER_RESULTS2="Resultat"
|
COM_SPORTSMANAGER_RESULTS2="Resultat"
|
||||||
COM_SPORTSMANAGER_NO_GAMES="Keine Spiele"
|
COM_SPORTSMANAGER_NO_GAMES="Keine Spiele"
|
||||||
COM_SPORTSMANAGER_END_GAME="Endspiel"
|
COM_SPORTSMANAGER_END_GAME="Endspiel"
|
||||||
@@ -925,3 +929,67 @@ COM_SPORTSMANAGER_RANK="Rang"
|
|||||||
|
|
||||||
; SPIELER BEARBEITEN
|
; SPIELER BEARBEITEN
|
||||||
COM_SPORTSMANAGER_LIZENZ="Lizenz"
|
COM_SPORTSMANAGER_LIZENZ="Lizenz"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_MATCHDAY_SELECT="Wähle einen Spieltag"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PROPOSAL_DAY="Wähle den Tag des Begegnungsvorschlags"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PROPOSAL_MONTH="Wähle den Monat des Begegnungsvorschlags"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PROPOSAL_YEAR="Wähle das Jahr des Begegnungsvorschlags"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PROPOSAL_HOUR="Wähle die Stunde des Begegnungsvorschlags"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PROPOSAL_MINUTE="Wähle die Minute des Begegnungsvorschlags"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_SPECIAL_FILTER="Erweiterter Filter"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PLACE="Ort"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_ELIGIBLE_CLUB="Wähle berechtigten Verein"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_TOURNAMENT_START_MONTH="Monat des Turnierbeginns"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_TOURNAMENT_START_YEAR="Jahr des Turnierbeginns"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_TOURNAMENT_END_MONTH="Monat des Turnierendes"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_TOURNAMENT_END_YEAR="Jahr des Turnierendes"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_ELIGIBLE_USER="Wähle berechtigten Anwender"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_POINTS_GUEST="Punkte Gast"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_POINTS_HOME="Punkte Heim"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PLAYER_GUEST="Spieler Gast"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PLAYER_HOME="Spieler Heim"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_SCHEDULE_DATE_MONTH="Wähle den Monat"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_SCHEDULE_DATE_YEAR="Wähle das Jahr"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_SCHEDULE_DATE_HOUR="Wähle eine Stunde"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_SCHEDULE_DATE_MINUTE="Wähle eine Minute"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_GAME_NUMBER_GUEST="Spiel Gast"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_GAME_NUMBER_HOME="Spiel Heim"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_GAME_LINK_DOUBLE="Verknüpfung Doppel"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_GAME_LINK_SINGLE="Verknüpfung Einzel"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PLACEMENT_MIN="Platzierung Min."
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PLACEMENT_MAX="Platzierung Max."
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PARTICIPANT_MIN="Teilnehmer Min."
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PARTICIPANT_MAX="Teilnehmer Max."
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_RANKING_START_MONTH="Monat des Ranglistenbeginns"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_RANKING_START_YEAR="Jahr des Ranglistenbeginns"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_RANKING_END_MONTH="Monat des Ranglistenendes"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_RANKING_END_YEAR="Jahr des Ranglistenendes"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_MAXIMUM_EVALUATED_COUNT="Maximal gewertete Teilnahmen"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_STATISTICS_START_MONTH="Monat des Statistikbeginns"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_STATISTICS_START_YEAR="Jahr des Statistikbeginns"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_STATISTICS_END_MONTH="Monat des Statistikendes"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_STATISTICS_END_YEAR="Jahr des Statistikendes"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_ELIGIBLE_ORGANIZER="Wähle berechtigten Veranstalter"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_EVENT_START_MONTH="Monat des Veranstaltungsbeginns"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_EVENT_START_YEAR="Jahr des Veranstaltungsbeginns"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_EVENT_END_MONTH="Monat des Veranstaltungsendes"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_EVENT_END_YEAR="Jahr des Veranstaltungsendes"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_FIRST_ROUND="Erste Runde"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_FIRST_ROUND_TYPE="Erste Runde Typ"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_FIRST_ROUND_PLACE="Erste Runde Platzierung"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_LAST_ROUND="Letzte Runde"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_LAST_ROUND_TYPE="Letzte Runde Typ"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_LAST_ROUND_PLACE="Letzte Runde Platzierung"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_ROUND_TYPE="Rundentyp"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_ROUND_PLACE="Rundenplatzierung"
|
||||||
|
COM_SPORTSMANAGER_HOME_POINTS="Heim Punkte"
|
||||||
|
COM_SPORTSMANAGER_GUEST_POINTS="Gast Punkte"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_ENCOUNTER_YEAR="Jahr der Begegnung"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PAIRING_TEAM="Team für Paarung"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_ELIGIBLE_COMPETITION="Wähle berechtigten Anwender"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_RANKING_EVALUATION="Ranking Wertung"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_LASTNAME="Nachname"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_FIRSTNAME="Vorname"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_CLUB="Verein"
|
||||||
|
COM_SPORTSMANAGER_NUM_REQUESTED_SHIFTS="Verschiebungen"
|
||||||
|
COM_SPORTSMANAGER_NUM_REQUESTED_SHFITS_TOOLTIP="Spielverschiebungen durch diese Mannschaft"
|
||||||
|
COM_SPORTSMANAGER_GAME_RESULT_DELAYS="Verzögerung"
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
; Sports Manager (C) 2006-2020, Sven Nickel
|
; Sports Manager (C) 2006-2020, Sven Nickel
|
||||||
COM_SPORTSMANAGER="Sports Manager"
|
COM_SPORTSMANAGER="Sports Manager"
|
||||||
COM_SPORTSMANAGER_PLAYERS="Players"
|
COM_SPORTSMANAGER_PLAYERS="Players"
|
||||||
COM_SPORTSMANAGER_CLUBS="Clubs"
|
COM_SPORTSMANAGER_CLUBS="Clubs"
|
||||||
@@ -70,17 +70,18 @@ COM_SPORTSMANAGER_CONFIRM_REMOVE_RANKING="Do you really want to remove the ranki
|
|||||||
COM_SPORTSMANAGER_ADD_INDIVIDUAL_COMPETITION="Add individual competition"
|
COM_SPORTSMANAGER_ADD_INDIVIDUAL_COMPETITION="Add individual competition"
|
||||||
COM_SPORTSMANAGER_INDIVIDUAL_COMPETITION="Individual competition"
|
COM_SPORTSMANAGER_INDIVIDUAL_COMPETITION="Individual competition"
|
||||||
COM_SPORTSMANAGER_INDIVIDUAL_COMPETITIONS="Individual competitions"
|
COM_SPORTSMANAGER_INDIVIDUAL_COMPETITIONS="Individual competitions"
|
||||||
|
COM_SPORTSMANAGER_ASSOCIATION_BODIES="Association bodies"
|
||||||
COM_SPORTSMANAGER_GAME="Game"
|
COM_SPORTSMANAGER_GAME="Game"
|
||||||
COM_SPORTSMANAGER_GAMES="Games"
|
COM_SPORTSMANAGER_GAMES="Games"
|
||||||
COM_SPORTSMANAGER_GAMES_SHORTCUT="G"
|
COM_SPORTSMANAGER_GAMES_SHORTCUT="G"
|
||||||
COM_SPORTSMANAGER_ADD_PLAYER_STATISTICS="Add player statistics"
|
COM_SPORTSMANAGER_ADD_PLAYER_STATISTICS="Add player statistics"
|
||||||
COM_SPORTSMANAGER_PLAYER_STATISTICS="Player statistics"
|
COM_SPORTSMANAGER_PLAYER_STATISTIC="Player statistics"
|
||||||
COM_SPORTSMANAGER_COMPETITION="Competition"
|
COM_SPORTSMANAGER_COMPETITION="Competition"
|
||||||
COM_SPORTSMANAGER_COMPETITIONS="Competitions"
|
COM_SPORTSMANAGER_COMPETITIONS="Competitions"
|
||||||
COM_SPORTSMANAGER_IN_COMPETITIONS="in competition"
|
COM_SPORTSMANAGER_IN_COMPETITIONS="in competition"
|
||||||
COM_SPORTSMANAGER_COMPETITIONS_SHORTCUT="C"
|
COM_SPORTSMANAGER_COMPETITIONS_SHORTCUT="C"
|
||||||
COM_SPORTSMANAGER_DUPLICATE="Duplicate"
|
COM_SPORTSMANAGER_DUPLICATE="Duplicate"
|
||||||
COM_SPORTSMANAGER_CONFIRM_REMOVE_RANKING="Do you really want to remove the player statistics?"
|
COM_SPORTSMANAGER_CONFIRM_REMOVE_PLAYER_STATISTICS="Do you really want to remove the player statistics?"
|
||||||
COM_SPORTSMANAGER_LIVE_TICKER="Live ticker"
|
COM_SPORTSMANAGER_LIVE_TICKER="Live ticker"
|
||||||
COM_SPORTSMANAGER_PLACE="Place"
|
COM_SPORTSMANAGER_PLACE="Place"
|
||||||
COM_SPORTSMANAGER_TEAM="Team"
|
COM_SPORTSMANAGER_TEAM="Team"
|
||||||
@@ -289,7 +290,6 @@ COM_SPORTSMANAGER_REQUEST_MESSAGE_PLURAL="At least %d dates must be given comple
|
|||||||
COM_SPORTSMANAGER_REJECT_SHIFT="Reject shift"
|
COM_SPORTSMANAGER_REJECT_SHIFT="Reject shift"
|
||||||
COM_SPORTSMANAGER_TO="until"
|
COM_SPORTSMANAGER_TO="until"
|
||||||
COM_SPORTSMANAGER_PLAYER_STATISTICS="Player statistics"
|
COM_SPORTSMANAGER_PLAYER_STATISTICS="Player statistics"
|
||||||
COM_SPORTSMANAGER_PERFORMANCE_INDEX="Performance index"
|
|
||||||
COM_SPORTSMANAGER_PERFORMANCE_INDEX_SHORTCUT="PI"
|
COM_SPORTSMANAGER_PERFORMANCE_INDEX_SHORTCUT="PI"
|
||||||
COM_SPORTSMANAGER_WON="won"
|
COM_SPORTSMANAGER_WON="won"
|
||||||
COM_SPORTSMANAGER_LOST="lost"
|
COM_SPORTSMANAGER_LOST="lost"
|
||||||
@@ -362,7 +362,7 @@ COM_SPORTSMANAGER_IDENTICAL_NAME="Identical name"
|
|||||||
COM_SPORTSMANAGER_IDENTICAL_NAME_BIRTHYEAR="Identical name and birth year"
|
COM_SPORTSMANAGER_IDENTICAL_NAME_BIRTHYEAR="Identical name and birth year"
|
||||||
COM_SPORTSMANAGER_NO_PLAYERS="No player number"
|
COM_SPORTSMANAGER_NO_PLAYERS="No player number"
|
||||||
COM_SPORTSMANAGER_LAST_FIRST_NAME="Last name, first name"
|
COM_SPORTSMANAGER_LAST_FIRST_NAME="Last name, first name"
|
||||||
COM_SPORTSMANAGER_BIRTHYEAR="birthyear"
|
COM_SPORTSMANAGER_BIRTHYEAR="Birthyear"
|
||||||
COM_SPORTSMANAGER_NAT="Nat. #"
|
COM_SPORTSMANAGER_NAT="Nat. #"
|
||||||
COM_SPORTSMANAGER_INT="Intern. #"
|
COM_SPORTSMANAGER_INT="Intern. #"
|
||||||
COM_SPORTSMANAGER_REMOVE_MESSAGE="Do you really want to remove the player?"
|
COM_SPORTSMANAGER_REMOVE_MESSAGE="Do you really want to remove the player?"
|
||||||
@@ -444,7 +444,7 @@ COM_SPORTSMANAGER_NOTE="Note"
|
|||||||
COM_SPORTSMANAGER_WANT_REALLY_REMOVE="Do you really want to remove the club?"
|
COM_SPORTSMANAGER_WANT_REALLY_REMOVE="Do you really want to remove the club?"
|
||||||
COM_SPORTSMANAGER_ADD="Add"
|
COM_SPORTSMANAGER_ADD="Add"
|
||||||
COM_SPORTSMANAGER_REMOVE_ACCOUNT="Remove account"
|
COM_SPORTSMANAGER_REMOVE_ACCOUNT="Remove account"
|
||||||
COM_SPORTSMANAGER_DISTRICT="Ristrict"
|
COM_SPORTSMANAGER_DISTRICT="District"
|
||||||
COM_SPORTSMANAGER_ELIGIBLE_FOR_TEAM="Eligible for team"
|
COM_SPORTSMANAGER_ELIGIBLE_FOR_TEAM="Eligible for team"
|
||||||
COM_SPORTSMANAGER_ELIGIBLE_FOR_CLUB="Eligible for club"
|
COM_SPORTSMANAGER_ELIGIBLE_FOR_CLUB="Eligible for club"
|
||||||
COM_SPORTSMANAGER_SAVED_CLUB="Club to maintain"
|
COM_SPORTSMANAGER_SAVED_CLUB="Club to maintain"
|
||||||
@@ -649,6 +649,10 @@ COM_SPORTSMANAGER_IMAGE_WITHIN_TEAM="Image within team"
|
|||||||
COM_SPORTSMANAGER_ADD_MEETING="Add match"
|
COM_SPORTSMANAGER_ADD_MEETING="Add match"
|
||||||
COM_SPORTSMANAGER_ROUND_GENERATION="Generate round"
|
COM_SPORTSMANAGER_ROUND_GENERATION="Generate round"
|
||||||
COM_SPORTSMANAGER_GENERATE_GROUP_GAME="Generate group games"
|
COM_SPORTSMANAGER_GENERATE_GROUP_GAME="Generate group games"
|
||||||
|
COM_SPORTSMANAGER_Import_GROUP_GAME="Import group games"
|
||||||
|
COM_SPORTSMANAGER_Import_GROUP_GAME2="Group games: Import"
|
||||||
|
COM_SPORTSMANAGER_IMPORT_GROUP_GAME_IMPORTED="matches were imported"
|
||||||
|
COM_SPORTSMANAGER_IMPORT_GROUP_GAME_CREATED="matches were created"
|
||||||
COM_SPORTSMANAGER_REMOVE_ALL_ENCOUNTERS="Do you really want to remove all matches?"
|
COM_SPORTSMANAGER_REMOVE_ALL_ENCOUNTERS="Do you really want to remove all matches?"
|
||||||
COM_SPORTSMANAGER_REMOVE_ALL_MATCHES="Remove all matches"
|
COM_SPORTSMANAGER_REMOVE_ALL_MATCHES="Remove all matches"
|
||||||
COM_SPORTSMANAGER_HOME_TEAM="Home team"
|
COM_SPORTSMANAGER_HOME_TEAM="Home team"
|
||||||
@@ -694,6 +698,7 @@ COM_SPORTSMANAGER_NUMBER_DAYS="%d days"
|
|||||||
COM_SPORTSMANAGER_CALENDAR_WEEK="Calendar week"
|
COM_SPORTSMANAGER_CALENDAR_WEEK="Calendar week"
|
||||||
COM_SPORTSMANAGER_CALENDAR_WEEK_SHORTCUT="CW"
|
COM_SPORTSMANAGER_CALENDAR_WEEK_SHORTCUT="CW"
|
||||||
COM_SPORTSMANAGER_PAIRING="Fixture"
|
COM_SPORTSMANAGER_PAIRING="Fixture"
|
||||||
|
COM_SPORTSMANAGER_SETTING="Setting"
|
||||||
COM_SPORTSMANAGER_PAIRINGS="Fixtures"
|
COM_SPORTSMANAGER_PAIRINGS="Fixtures"
|
||||||
COM_SPORTSMANAGER_INTERMITTENT="Skipping"
|
COM_SPORTSMANAGER_INTERMITTENT="Skipping"
|
||||||
COM_SPORTSMANAGER_MAXIMUM_SETS="Maximum sets"
|
COM_SPORTSMANAGER_MAXIMUM_SETS="Maximum sets"
|
||||||
@@ -827,7 +832,6 @@ COM_SPORTSMANAGER_REMOVE_STATE_REALLY="Do you really want to remove the country?
|
|||||||
COM_SPORTSMANAGER_DATES_STATE="Appointments country"
|
COM_SPORTSMANAGER_DATES_STATE="Appointments country"
|
||||||
COM_SPORTSMANAGER_RENAME_APPOINTMENTS_STATE="Rename appointments with the preset country"
|
COM_SPORTSMANAGER_RENAME_APPOINTMENTS_STATE="Rename appointments with the preset country"
|
||||||
COM_SPORTSMANAGER_FINAL_RANKING="FINAL RANKING"
|
COM_SPORTSMANAGER_FINAL_RANKING="FINAL RANKING"
|
||||||
COM_SPORTSMANAGER_HOME_TEAM2="Home team"
|
|
||||||
COM_SPORTSMANAGER_RESULTS2="Result"
|
COM_SPORTSMANAGER_RESULTS2="Result"
|
||||||
COM_SPORTSMANAGER_NO_GAMES="No games"
|
COM_SPORTSMANAGER_NO_GAMES="No games"
|
||||||
COM_SPORTSMANAGER_END_GAME="Final"
|
COM_SPORTSMANAGER_END_GAME="Final"
|
||||||
@@ -921,3 +925,69 @@ COM_SPORTSMANAGER_NON_SMOKING_PROTECTION_MARK_NO=" (Kein Nichtraucherschutz)"
|
|||||||
COM_SPORTSMANAGER_POINTS_TABLE="Points table"
|
COM_SPORTSMANAGER_POINTS_TABLE="Points table"
|
||||||
COM_SPORTSMANAGER_EVALUATION="Auswertung"
|
COM_SPORTSMANAGER_EVALUATION="Auswertung"
|
||||||
COM_SPORTSMANAGER_FUNCTION_DESCRIPTION="Variables: n = number of participants, p = place, m = multiplier of rating and in doubles possibly additionally reduced rating<br />Functions: +, -, *, /, round(x), pow(x), if(a > b, x, y), min(x, y), max(x, y), log(x), ln(x), logn(b, x)<br />VerteilungR(r, p, n, m) := max(round((((m * r - 1) * (-log(p / n) * (1 - (p / n)))) / (-log(1 / n) * (1 - (1 / n)))) + 1), 1)<br />Verteilung(r, p, n, m) := max(round(m * round((((r - 1) * (-log(p / n) * (1 - (p / n)))) / (-log(1 / n) * (1 - (1 / n)))) + 1)), 1)<br /><br />The functions VerteilungR() and Verteilung() distribute points for place 1 (r) descending to the individual places (p) of the number of participants (n).<br />VerteilungR() applies the multiplier (m) to the points for 1st place and then distributes down to 1 point for the last place.<br />Verteilung() applies the multiplier (m) to the points after the calculation, i.e. the last place receives 1 * m points."
|
COM_SPORTSMANAGER_FUNCTION_DESCRIPTION="Variables: n = number of participants, p = place, m = multiplier of rating and in doubles possibly additionally reduced rating<br />Functions: +, -, *, /, round(x), pow(x), if(a > b, x, y), min(x, y), max(x, y), log(x), ln(x), logn(b, x)<br />VerteilungR(r, p, n, m) := max(round((((m * r - 1) * (-log(p / n) * (1 - (p / n)))) / (-log(1 / n) * (1 - (1 / n)))) + 1), 1)<br />Verteilung(r, p, n, m) := max(round(m * round((((r - 1) * (-log(p / n) * (1 - (p / n)))) / (-log(1 / n) * (1 - (1 / n)))) + 1)), 1)<br /><br />The functions VerteilungR() and Verteilung() distribute points for place 1 (r) descending to the individual places (p) of the number of participants (n).<br />VerteilungR() applies the multiplier (m) to the points for 1st place and then distributes down to 1 point for the last place.<br />Verteilung() applies the multiplier (m) to the points after the calculation, i.e. the last place receives 1 * m points."
|
||||||
|
COM_SPORTSMANAGER_LIZENZ="License"
|
||||||
|
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_MATCHDAY_SELECT="Choose a match day"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PROPOSAL_DAY="Choose the day of the match proposal"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PROPOSAL_MONTH="Choose the month of the match proposal"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PROPOSAL_YEAR="Choose the year of the match proposal"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PROPOSAL_HOUR="Choose the hour of the match proposal"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PROPOSAL_MINUTE="Choose the minute of the match proposal"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_SPECIAL_FILTER="Advanced Filter"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PLACE="Location"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_ELIGIBLE_CLUB="Choose eligible club"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_TOURNAMENT_START_MONTH="Month of tournament start"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_TOURNAMENT_START_YEAR="Year of tournament start"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_TOURNAMENT_END_MONTH="Month of tournament end"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_TOURNAMENT_END_YEAR="Year of tournament end"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_ELIGIBLE_USER="Choose eligible user"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_POINTS_GUEST="Points away"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_POINTS_HOME="Points home"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PLAYER_GUEST="Player away"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PLAYER_HOME="Player home"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_SCHEDULE_DATE_MONTH="Choose a Month"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_SCHEDULE_DATE_YEAR="Choose a Year"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_SCHEDULE_DATE_HOUR="Choose an Hour"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_SCHEDULE_DATE_MINUTE="Choose a Minute"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_GAME_NUMBER_GUEST="Game away"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_GAME_NUMBER_HOME="Game home"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_GAME_LINK_DOUBLE="Game link double"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_GAME_LINK_SINGLE="Game link single"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PLACEMENT_MIN="Placement min."
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PLACEMENT_MAX="Placement max."
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PARTICIPANT_MIN="Participant min."
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PARTICIPANT_MAX="Participant max."
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_RANKING_START_MONTH="Month of ranking start"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_RANKING_START_YEAR="Year of ranking start"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_RANKING_END_MONTH="Month of ranking end"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_RANKING_END_YEAR="Year of ranking end"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_MAXIMUM_EVALUATED_COUNT="Maximum number of evaluated participations"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_STATISTICS_START_MONTH="Month of statistics start"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_STATISTICS_START_YEAR="Year of statistics start"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_STATISTICS_END_MONTH="Month of statistics end"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_STATISTICS_END_YEAR="Year of statistics end"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_ELIGIBLE_ORGANIZER="Choose eligible organizer"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_EVENT_START_MONTH="Month of event start"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_EVENT_START_YEAR="Year of event start"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_EVENT_END_MONTH="Month of event end"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_EVENT_END_YEAR="Year of event end"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_FIRST_ROUND="First round"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_FIRST_ROUND_TYPE="First round type"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_FIRST_ROUND_PLACE="First round place"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_LAST_ROUND="Last round"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_LAST_ROUND_TYPE="Last round type"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_LAST_ROUND_PLACE="Last round place"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_ROUND_TYPE="round type"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_ROUND_PLACE="round place"
|
||||||
|
COM_SPORTSMANAGER_HOME_POINTS="Home points"
|
||||||
|
COM_SPORTSMANAGER_GUEST_POINTS="Guest points"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_ENCOUNTER_YEAR="Year of encounter"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_PAIRING_TEAM="Team for fixture"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_ELIGIBLE_COMPETITION="Choose eligible user"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_RANKING_EVALUATION="Ranking evaluation"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_LASTNAME="Lastname"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_FIRSTNAME="Firstname"
|
||||||
|
COM_SPORTSMANAGER_ARIA_LABEL_CLUB="Club"
|
||||||
|
COM_SPORTSMANAGER_NUM_REQUESTED_SHIFTS="Shifts"
|
||||||
|
COM_SPORTSMANAGER_NUM_REQUESTED_SHFITS_TOOLTIP="Game shifts caused by this team"
|
||||||
|
COM_SPORTSMANAGER_GAME_RESULT_DELAYS="Delay"
|
||||||
|
|||||||
+259
-236
File diff suppressed because it is too large
Load Diff
+14
-12
@@ -1,26 +1,27 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<!DOCTYPE install SYSTEM "http://dev.joomla.org/xml/1.5/component-install.dtd">
|
<extension type="component" version="5.0" method="upgrade">
|
||||||
<extension type="component" version="3.0" method="upgrade">
|
|
||||||
<name>Sports manager</name>
|
<name>Sports manager</name>
|
||||||
<creationDate>2020-09-30</creationDate>
|
<creationDate>2025-03-12</creationDate>
|
||||||
<author>Sven Nickel</author>
|
<author>Deutscher Tischfußball Verband</author>
|
||||||
<authorEmail>sven.nickel@gmail.com</authorEmail>
|
<authorEmail>it@dtfb.de</authorEmail>
|
||||||
<copyright>All rights reserved</copyright>
|
<copyright>All rights reserved</copyright>
|
||||||
<license>GNU/GPL</license>
|
<license>GNU/GPL</license>
|
||||||
<version>1.7.1</version>
|
<version>2.0.0</version>
|
||||||
<description>Verwaltung von Spielern und Vereinen in Mannschafts- und Individualwettbewerben</description>
|
<description>Verwaltung von Spielern und Vereinen in Mannschafts- und Individualwettbewerben</description>
|
||||||
|
<namespace path="src">Dtfb\Component\com_sportsmanager</namespace>
|
||||||
<files folder="site">
|
<files folder="site">
|
||||||
<filename>index.html</filename>
|
<filename>index.html</filename>
|
||||||
<filename>admin.php</filename>
|
<filename>admin.php</filename>
|
||||||
<filename>api.php</filename>
|
<filename>api.php</filename>
|
||||||
<filename>controller.php</filename>
|
|
||||||
<filename>database.php</filename>
|
|
||||||
<filename>sportsmanager.php</filename>
|
<filename>sportsmanager.php</filename>
|
||||||
<filename>mathparser.php</filename>
|
<filename>mathparser.php</filename>
|
||||||
<filename>tools.php</filename>
|
<filename>tools.php</filename>
|
||||||
<filename>js/jquery.min.js</filename>
|
<filename>js/jquery.min.js</filename>
|
||||||
|
<folder>database</folder>
|
||||||
<folder>images</folder>
|
<folder>images</folder>
|
||||||
<folder>models</folder>
|
<folder>models</folder>
|
||||||
|
<folder>src</folder>
|
||||||
|
<folder>util</folder>
|
||||||
<folder>views</folder>
|
<folder>views</folder>
|
||||||
</files>
|
</files>
|
||||||
<languages folder="site">
|
<languages folder="site">
|
||||||
@@ -31,14 +32,15 @@
|
|||||||
<language tag="nl-NL">language/nl-NL/nl-NL.com_sportsmanager.ini
|
<language tag="nl-NL">language/nl-NL/nl-NL.com_sportsmanager.ini
|
||||||
</language>
|
</language>
|
||||||
</languages>
|
</languages>
|
||||||
<scriptfile>install.php</scriptfile>
|
<scriptfile>script.php</scriptfile>
|
||||||
<administration>
|
<administration>
|
||||||
<files folder="admin">
|
<files folder="admin">
|
||||||
<filename>access.xml</filename>
|
<filename>access.xml</filename>
|
||||||
<filename>sportsmanager.php</filename>
|
|
||||||
<filename>controller.php</filename>
|
|
||||||
<filename>index.html</filename>
|
<filename>index.html</filename>
|
||||||
<folder>views</folder>
|
<filename>RELEASE_NOTES.md</filename>
|
||||||
|
<folder>services</folder>
|
||||||
|
<folder>src</folder>
|
||||||
|
<folder>tmpl</folder>
|
||||||
</files>
|
</files>
|
||||||
<languages folder="admin">
|
<languages folder="admin">
|
||||||
<language tag="en-GB">language/en-GB/en-GB.com_sportsmanager.ini
|
<language tag="en-GB">language/en-GB/en-GB.com_sportsmanager.ini
|
||||||
Reference in New Issue
Block a user