mirror of
https://github.com/grocy/grocy.git
synced 2025-10-16 02:07:56 +00:00
Compare commits
277 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
66571f662f | ||
|
e5aebad5d9 | ||
|
f3a1489abf | ||
|
6ca694226b | ||
|
5d5cfb1548 | ||
|
1a7be05e3f | ||
|
f7c4662e2b | ||
|
4c57bf8b9d | ||
|
e5530e2058 | ||
|
363dcf448e | ||
|
d16f3c2daf | ||
|
51e0154101 | ||
|
fc2a37d3fc | ||
|
c32ea087df | ||
|
4eabee3db7 | ||
|
95478cbb18 | ||
|
d8360993cc | ||
|
6e4117526b | ||
|
e4437f5db1 | ||
|
b57fd83cb8 | ||
|
327c1f4fb3 | ||
|
ab44566890 | ||
|
d2a841143e | ||
|
d580990b25 | ||
|
78b658e86e | ||
|
051cb816fe | ||
|
91c275e66b | ||
|
653098a81e | ||
|
c228126c3a | ||
|
1ae5f552d1 | ||
|
63d7f8f36d | ||
|
4754cc306a | ||
|
339a25d1e3 | ||
|
5a91c86b81 | ||
|
292b652437 | ||
|
399ebbe14a | ||
|
a95d6be4f4 | ||
|
ca9b8d068a | ||
|
58890f6bec | ||
|
9f8216378e | ||
|
d4c76aaa76 | ||
|
6ce4e6cb37 | ||
|
aa670adefc | ||
|
1d92e6a4ab | ||
|
e720311572 | ||
|
7c114cfec3 | ||
|
35a409f462 | ||
|
412653d67d | ||
|
58a69d650f | ||
|
a4d479d047 | ||
|
cbf1d1ca40 | ||
|
5e9a7fb7ca | ||
|
9f18b75526 | ||
|
346b589534 | ||
|
8f798a94d1 | ||
|
991706920f | ||
|
ce12202c86 | ||
|
ca470ed4ee | ||
|
2237e2f8f4 | ||
|
2522b3748c | ||
|
096fb7a116 | ||
|
918f84f568 | ||
|
d209c0bd22 | ||
|
ba089a3d79 | ||
|
3df44697bf | ||
|
e326e69d49 | ||
|
bbd8e8c1fa | ||
|
9b5f3ba7b8 | ||
|
0fa0138972 | ||
|
6aa278c19c | ||
|
3fd0f44fe4 | ||
|
0c27157db6 | ||
|
bbd5ce1dc4 | ||
|
0771d58fe7 | ||
|
db0c4f78bd | ||
|
ef8f6b6d42 | ||
|
4dd804003b | ||
|
182d063886 | ||
|
bc487b4867 | ||
|
b5b2f9c5b9 | ||
|
b5761ae544 | ||
|
597a9e3d21 | ||
|
1b19940aba | ||
|
74f9470769 | ||
|
3dcd513094 | ||
|
a799f2b43f | ||
|
c532a67884 | ||
|
6094096675 | ||
|
30d89f4529 | ||
|
a0a0e104b0 | ||
|
26ebeec74f | ||
|
a4454f825a | ||
|
6ec3872518 | ||
|
d4eb767f1b | ||
|
afa4165d1c | ||
|
f9036f0248 | ||
|
257dd644aa | ||
|
be4b5c81b2 | ||
|
f88ed1ee8a | ||
|
411aad2398 | ||
|
7004cf4400 | ||
|
28716ed96c | ||
|
d6e9dc1b59 | ||
|
19935276e9 | ||
|
fa326fdfda | ||
|
e6020432c6 | ||
|
12a2c0945e | ||
|
cc1c6a6442 | ||
|
c757ee3874 | ||
|
1e33975a96 | ||
|
1a23eaabf1 | ||
|
3dbce7547f | ||
|
0bb3e0ae28 | ||
|
8d4a2d0ff9 | ||
|
3234a97b3c | ||
|
b61d569247 | ||
|
0daf0aeb61 | ||
|
889f520afb | ||
|
c6420a74ba | ||
|
e3f53aaebd | ||
|
94e2ec5e15 | ||
|
0a61ea0fcf | ||
|
091145c62c | ||
|
197b83fee8 | ||
|
430286ae9e | ||
|
6e3407b157 | ||
|
13c432b0cf | ||
|
4822d9a4b8 | ||
|
52dd01f313 | ||
|
87976b86d9 | ||
|
84e6e253ea | ||
|
001d5c5d1d | ||
|
b4d2e2a20a | ||
|
914dde4609 | ||
|
1eb1aa8b11 | ||
|
09b23847b5 | ||
|
8c205941c7 | ||
|
b24683f954 | ||
|
e4d26bb8fd | ||
|
c6c10c87e4 | ||
|
df529c3c0b | ||
|
482a520062 | ||
|
ddef58e2a9 | ||
|
d34c7b0a87 | ||
|
b76e51ba41 | ||
|
67cfd0ba5f | ||
|
3fcede0b7c | ||
|
0c0e8c6957 | ||
|
86f5667039 | ||
|
a01a80578c | ||
|
7a51fb77b0 | ||
|
511c95070e | ||
|
eec6270cb7 | ||
|
7c7c5db28c | ||
|
6b98fa85d3 | ||
|
825be63b93 | ||
|
a56f8be19e | ||
|
f736c4de44 | ||
|
56217804b7 | ||
|
43710b5062 | ||
|
b1adaa24cf | ||
|
9e7d62b62d | ||
|
9f2481a6a8 | ||
|
2b77bc6ae6 | ||
|
91116ee768 | ||
|
167e57ef3f | ||
|
3321bcd683 | ||
|
41b8b5d11e | ||
|
0a4ea6861a | ||
|
8f9c3c66f7 | ||
|
d412b81eae | ||
|
55e5fd7bf1 | ||
|
1787690795 | ||
|
3eb8b5f381 | ||
|
d8cefeffb7 | ||
|
5da50d1e1e | ||
|
de89fee5bb | ||
|
338c6c0a9d | ||
|
8504eb9b38 | ||
|
3f53919ddd | ||
|
57233dba1a | ||
|
e240260f9f | ||
|
dd148a8fc3 | ||
|
153ac61867 | ||
|
9ef55f1f01 | ||
|
98fcd767b3 | ||
|
fe8bb43996 | ||
|
328d96ed60 | ||
|
970e5edfa3 | ||
|
12ba99f649 | ||
|
314e434fd1 | ||
|
29f69c92e9 | ||
|
0eb974bd92 | ||
|
bcd6dd4b20 | ||
|
6cecb2ca7b | ||
|
bcae9f9292 | ||
|
8138dd43ac | ||
|
78a230c5d5 | ||
|
4c2cf4944d | ||
|
bd296f8fe1 | ||
|
24680154d8 | ||
|
dfd501c515 | ||
|
dae5bb2b34 | ||
|
595171afa5 | ||
|
7fc4992b3a | ||
|
618ff5609f | ||
|
94c6e634b8 | ||
|
b310aa55c5 | ||
|
3cf8ebeb89 | ||
|
ae156ed0e6 | ||
|
4912dd56d1 | ||
|
5d3f248d94 | ||
|
9b2dba2397 | ||
|
40b5afe926 | ||
|
6ceb6e3643 | ||
|
a999112a21 | ||
|
310cdd7d4c | ||
|
77f094810b | ||
|
b6b8c76d3a | ||
|
6442665f6c | ||
|
04ca6edbd3 | ||
|
c5993ad994 | ||
|
72a3f63546 | ||
|
eae8536c9b | ||
|
fc11da3c3f | ||
|
77f3b80540 | ||
|
d72fe69a17 | ||
|
162adeb359 | ||
|
49d16b458d | ||
|
cdd02efcc6 | ||
|
c1674d33b4 | ||
|
41988aa1ee | ||
|
18b8712369 | ||
|
42a9d5af2b | ||
|
c4d377ce4e | ||
|
50a782c8c0 | ||
|
fa6f09679f | ||
|
25c257bb2c | ||
|
0496ae9e00 | ||
|
45ae386005 | ||
|
b6e80580ed | ||
|
886e272c03 | ||
|
40cc0ff280 | ||
|
3a0bb913d5 | ||
|
12082b52ab | ||
|
2d3df2024a | ||
|
a9c0539305 | ||
|
5b304c5e97 | ||
|
1b26a6277b | ||
|
353a65d41c | ||
|
bfcd05473a | ||
|
3d485d4850 | ||
|
9d02fbc13c | ||
|
27ba2bfd55 | ||
|
61f582554f | ||
|
75241fc61f | ||
|
91289588b5 | ||
|
3f4a5cc0d6 | ||
|
e693460894 | ||
|
47a6260d27 | ||
|
bfd29def8d | ||
|
cd0ca4a67c | ||
|
659d60b235 | ||
|
8efcb79ed7 | ||
|
5ba55823c9 | ||
|
6de4b120b3 | ||
|
8fec262184 | ||
|
bd483ec8b0 | ||
|
4d215edbd0 | ||
|
a3d4fd834f | ||
|
2d0c0bf34f | ||
|
0f03420808 | ||
|
ba319dc6f1 | ||
|
c10890205c | ||
|
643f6272e4 | ||
|
cad5e9ef79 | ||
|
01fdfe1a0c |
@@ -1,3 +1,4 @@
|
|||||||
pushd ..
|
pushd ..
|
||||||
tx pull --all --minimum-perc=90
|
tx pull --all --minimum-perc=90
|
||||||
|
tx pull --language en_GB
|
||||||
popd
|
popd
|
||||||
|
57
.tx/config
57
.tx/config
@@ -1,37 +1,44 @@
|
|||||||
[main]
|
[main]
|
||||||
host = https://www.transifex.com
|
host = https://www.transifex.com
|
||||||
|
|
||||||
[grocy.stringsphp]
|
[grocy.chore_period_types]
|
||||||
file_filter = localization/<lang>/strings.php
|
file_filter = localization/<lang>/chore_period_types.po
|
||||||
minimum_perc = 0
|
source_file = localization/chore_period_types.pot
|
||||||
source_file = localization/en/strings.php
|
|
||||||
source_lang = en
|
source_lang = en
|
||||||
type = PHP_ARRAY
|
type = PO
|
||||||
|
|
||||||
[grocy.stock_transaction_typesphp]
|
[grocy.chore_assignment_types]
|
||||||
file_filter = localization/<lang>/stock_transaction_types.php
|
file_filter = localization/<lang>/chore_assignment_types.po
|
||||||
minimum_perc = 0
|
source_file = localization/chore_assignment_types.pot
|
||||||
source_file = localization/en/stock_transaction_types.php
|
|
||||||
source_lang = en
|
source_lang = en
|
||||||
type = PHP_ARRAY
|
type = PO
|
||||||
|
|
||||||
[grocy.chore_typesphp]
|
[grocy.component_translations]
|
||||||
file_filter = localization/<lang>/chore_types.php
|
file_filter = localization/<lang>/component_translations.po
|
||||||
minimum_perc = 0
|
source_file = localization/component_translations.pot
|
||||||
source_file = localization/en/chore_types.php
|
|
||||||
source_lang = en
|
source_lang = en
|
||||||
type = PHP_ARRAY
|
type = PO
|
||||||
|
|
||||||
[grocy.component_translationsphp]
|
[grocy.demo_data]
|
||||||
file_filter = localization/<lang>/component_translations.php
|
file_filter = localization/<lang>/demo_data.po
|
||||||
minimum_perc = 0
|
source_file = localization/demo_data.pot
|
||||||
source_file = localization/en/component_translations.php
|
|
||||||
source_lang = en
|
source_lang = en
|
||||||
type = PHP_ARRAY
|
type = PO
|
||||||
|
|
||||||
[grocy.demo_dataphp]
|
[grocy.stock_transaction_types]
|
||||||
file_filter = localization/<lang>/demo_data.php
|
file_filter = localization/<lang>/stock_transaction_types.po
|
||||||
minimum_perc = 0
|
source_file = localization/stock_transaction_types.pot
|
||||||
source_file = localization/en/demo_data.php
|
|
||||||
source_lang = en
|
source_lang = en
|
||||||
type = PHP_ARRAY
|
type = PO
|
||||||
|
|
||||||
|
[grocy.strings]
|
||||||
|
file_filter = localization/<lang>/strings.po
|
||||||
|
source_file = localization/strings.pot
|
||||||
|
source_lang = en
|
||||||
|
type = PO
|
||||||
|
|
||||||
|
[grocy.userfield_types]
|
||||||
|
file_filter = localization/<lang>/userfield_types.po
|
||||||
|
source_file = localization/userfield_types.pot
|
||||||
|
source_lang = en
|
||||||
|
type = PO
|
||||||
|
34
README.md
34
README.md
@@ -5,17 +5,21 @@ ERP beyond your fridge
|
|||||||
- Public demo of the latest stable version → [https://demo.grocy.info](https://demo.grocy.info)
|
- Public demo of the latest stable version → [https://demo.grocy.info](https://demo.grocy.info)
|
||||||
- Public demo of the latest pre-release version (current master branch) → [https://demo-prerelease.grocy.info](https://demo-prerelease.grocy.info)
|
- Public demo of the latest pre-release version (current master branch) → [https://demo-prerelease.grocy.info](https://demo-prerelease.grocy.info)
|
||||||
|
|
||||||
|
## Getting in touch
|
||||||
|
There is the [r/grocy subreddit](https://www.reddit.com/r/grocy) to connect with other grocy users. If you've found something that does not work or if you have an idea for an improvement or new things which you would find useful, feel free to open an issue in the [issue tracker](https://github.com/grocy/grocy/issues) here.
|
||||||
|
|
||||||
|
## Community contributions
|
||||||
|
See the website for a list of community contributed Add-ons / Tools: [https://grocy.info/#addons](https://grocy.info/#addons)
|
||||||
|
|
||||||
## Motivation
|
## Motivation
|
||||||
A household needs to be managed. I did this so far (almost 10 years) with my first self written software (a C# windows forms application) and with a bunch of Excel sheets. The software is a pain to use and Excel is Excel. So I searched for and tried different things for a (very) long time, nothing 100 % fitted, so this is my aim for a "complete household management"-thing. ERP your fridge!
|
A household needs to be managed. I did this so far (almost 10 years) with my first self written software (a C# windows forms application) and with a bunch of Excel sheets. The software is a pain to use and Excel is Excel. So I searched for and tried different things for a (very) long time, nothing 100 % fitted, so this is my aim for a "complete household management"-thing. ERP your fridge!
|
||||||
|
|
||||||
## How to install
|
## How to install
|
||||||
> **NEW**
|
> Checkout grocy-desktop, if you want to run grocy without a webserver just like a normal (windows) desktop application.
|
||||||
>
|
|
||||||
> There is now grocy-desktop if you want to run grocy without a webserver just like a normal (windows) desktop application.
|
|
||||||
>
|
>
|
||||||
> See https://github.com/grocy/grocy-desktop or directly download the [latest release](https://releases.grocy.info/latest-desktop) - the installation is nothing more than just clicking 2 times "next"...
|
> See https://github.com/grocy/grocy-desktop or directly download the [latest release](https://releases.grocy.info/latest-desktop) - the installation is nothing more than just clicking 2 times "next"...
|
||||||
|
|
||||||
Just unpack the [latest release](https://releases.grocy.info/latest) on your PHP (SQLite (3.8.3 or higher) extension required, currently only tested with PHP 7.2) enabled webserver (webservers root should point to the `public` directory), copy `config-dist.php` to `data/config.php`, edit it to your needs, ensure that the `data` directory is writable and you're ready to go, (to make writable `chown -R www-data:www-data data/`). Default login is user `admin` with password `admin`, please change the password immediately (see user menu).
|
Just unpack the [latest release](https://releases.grocy.info/latest) on your PHP (SQLite (3.8.3 or higher) extension required, currently only tested with PHP 7.3) enabled webserver (webservers root should point to the `public` directory), copy `config-dist.php` to `data/config.php`, edit it to your needs, ensure that the `data` directory is writable and you're ready to go, (to make it writable, maybe use `chown -R www-data:www-data data/`). Default login is user `admin` with password `admin`, please change the password immediately (see user menu).
|
||||||
|
|
||||||
Alternatively clone this repository and install Composer and Yarn dependencies manually.
|
Alternatively clone this repository and install Composer and Yarn dependencies manually.
|
||||||
|
|
||||||
@@ -23,31 +27,34 @@ If you use nginx as your webserver, please include `try_files $uri /index.php;`
|
|||||||
|
|
||||||
If, however, your webserver does not support URL rewriting, set `DISABLE_URL_REWRITING` in `data/config.php` (`Setting('DISABLE_URL_REWRITING', true);`).
|
If, however, your webserver does not support URL rewriting, set `DISABLE_URL_REWRITING` in `data/config.php` (`Setting('DISABLE_URL_REWRITING', true);`).
|
||||||
|
|
||||||
|
See the website for further installation guides and troubleshooting help: https://grocy.info/links
|
||||||
|
|
||||||
## How to run using Docker
|
## How to run using Docker
|
||||||
|
|
||||||
See [grocy/grocy-docker](https://github.com/grocy/grocy-docker) for instructions.
|
See [grocy/grocy-docker](https://github.com/grocy/grocy-docker) or [linuxserver/docker-grocy](https://github.com/linuxserver/docker-grocy) for instructions.
|
||||||
|
|
||||||
## How to update
|
## How to update
|
||||||
Just overwrite everything with the latest release while keeping the `data` directory, check `config-dist.php` for new configuration options and add them to your `data/config.php` (the default from values `config-dist.php` will be used for not in `data/config.php` defined settings). Just to be sure, please empty `data/viewcache`.
|
Just overwrite everything with the latest release while keeping the `data` directory, check `config-dist.php` for new configuration options and add them to your `data/config.php` where appropriate (the default values from `config-dist.php` will be used for not in `data/config.php` defined settings). Just to be sure, please empty `data/viewcache`.
|
||||||
|
|
||||||
If you run grocy on Linux, there is also `update.sh` (remember to make the script executable, `chmod +x update.sh` and ensure that you have `unzip` installed) which does exactly this and additionally creates a backup (`.tgz` archive) of the current installation in `data/backups` (backups older than 60 days will be deleted during the update).
|
If you run grocy on Linux, there is also `update.sh` (remember to make the script executable (`chmod +x update.sh`) and ensure that you have `unzip` installed) which does exactly this and additionally creates a backup (`.tgz` archive) of the current installation in `data/backups` (backups older than 60 days will be deleted during the update).
|
||||||
|
|
||||||
## Localization
|
## Localization
|
||||||
grocy is fully localizable - the default language is English (integrated into code), a German localization is always maintained by me.
|
grocy is fully localizable - the default language is English (integrated into code), a German localization is always maintained by me.
|
||||||
You can easily help translating grocy at https://www.transifex.com/grocy/grocy, if your language is incomplete or not available yet.
|
You can easily help translating grocy at https://www.transifex.com/grocy/grocy, if your language is incomplete or not available yet.
|
||||||
(Language can be changed in `data/config.php`, e. g. `Setting('CULTURE', 'it');`)
|
(Language can be changed in `data/config.php`, e. g. `Setting('CULTURE', 'it');`)
|
||||||
|
|
||||||
### Maintaining your own localization
|
The [pre-release demo](https://demo-prerelease.grocy.info) is available for any translation which is at least 80 % complete and will pull the translations from Transifex 10 minutes past every hour, so you can have a kind of instant preview of your contributed translations. Thank you!
|
||||||
As the German translation will always be the most complete one, for maintaining your localization it would be easiest when you compare your localization with the German one with a diff tool of your choice.
|
|
||||||
|
|
||||||
## Things worth to know
|
## Things worth to know
|
||||||
|
|
||||||
### REST API & data model documentation
|
### REST API & data model documentation
|
||||||
See the integrated Swagger UI instance on [/api](https://demo-en.grocy.info/api).
|
See the integrated Swagger UI instance on [/api](https://demo.grocy.info/api).
|
||||||
|
|
||||||
### Barcode readers
|
### Barcode readers & camera scanning
|
||||||
Some fields also allow to select a value by scanning a barcode. It works best when your barcode reader prefixes every barcode with a letter which is normally not part of a item name (I use a `$`) and sends a `TAB` after a scan.
|
Some fields also allow to select a value by scanning a barcode. It works best when your barcode reader prefixes every barcode with a letter which is normally not part of a item name (I use a `$`) and sends a `TAB` after a scan.
|
||||||
|
|
||||||
|
Additionally it's also possible to use your device camera to scan a barcode by using the camera button on the right side of the corresponding field (powered by [QuaggaJS](https://github.com/serratus/quaggaJS), totally offline / client-side camera stream processing). Quick video demo: https://www.youtube.com/watch?v=Y5YH6IJFnfc
|
||||||
|
|
||||||
### Input shorthands for date fields
|
### Input shorthands for date fields
|
||||||
For (productivity) reasons all date (and time) input fields use the ISO-8601 format regardless of localization.
|
For (productivity) reasons all date (and time) input fields use the ISO-8601 format regardless of localization.
|
||||||
The following shorthands are available:
|
The following shorthands are available:
|
||||||
@@ -88,6 +95,11 @@ When the file `embedded.txt` exists, it must contain a valid and writable path w
|
|||||||
|
|
||||||
In embedded mode, settings can be overridden by text files in `data/settingoverrides`, the file name must be `<SettingName>.txt` (e. g. `BASE_URL.txt`) and the content must be the setting value (normally one single line).
|
In embedded mode, settings can be overridden by text files in `data/settingoverrides`, the file name must be `<SettingName>.txt` (e. g. `BASE_URL.txt`) and the content must be the setting value (normally one single line).
|
||||||
|
|
||||||
|
## Contributing / Say thanks
|
||||||
|
Any help is more than appreciated. Feel free to pick any open unassigned issue and submit a pull request, but please leave a short comment or assign the issue yourself, to avoid working on the same thing.
|
||||||
|
|
||||||
|
See https://grocy.info/#say-thanks for more ideas if you just want to say thanks.
|
||||||
|
|
||||||
## Screenshots
|
## Screenshots
|
||||||
#### Dashboard
|
#### Dashboard
|
||||||

|

|
||||||
|
11
app.php
11
app.php
@@ -38,7 +38,16 @@ require_once __DIR__ . '/vendor/autoload.php';
|
|||||||
|
|
||||||
// Load config files
|
// Load config files
|
||||||
require_once GROCY_DATAPATH . '/config.php';
|
require_once GROCY_DATAPATH . '/config.php';
|
||||||
require_once __DIR__ . '/config-dist.php'; //For not in own config defined values we use the default ones
|
require_once __DIR__ . '/config-dist.php'; // For not in own config defined values we use the default ones
|
||||||
|
|
||||||
|
// Definitions for disabled authentication mode
|
||||||
|
if (GROCY_DISABLE_AUTH === true)
|
||||||
|
{
|
||||||
|
if (!defined('GROCY_USER_ID'))
|
||||||
|
{
|
||||||
|
define('GROCY_USER_ID', 1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Setup base application
|
// Setup base application
|
||||||
$appContainer = new \Slim\Container([
|
$appContainer = new \Slim\Container([
|
||||||
|
1
changelog/10_1.4.0_2017-06-04.md
Normal file
1
changelog/10_1.4.0_2017-06-04.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
- Added a login screen and switched to cookie/session based authentication instead of HTTP-basic-auth
|
2
changelog/11_1.5.0_2017-07-25.md
Normal file
2
changelog/11_1.5.0_2017-07-25.md
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
- New feature: Habit tracking
|
||||||
|
- Fixed an issue which prevented that the databse is correctly created on unix systems
|
2
changelog/12_1.6.0_2017-11-06.md
Normal file
2
changelog/12_1.6.0_2017-11-06.md
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
- New feature: Rechargeable battery management
|
||||||
|
- Improved productivity of input forms
|
1
changelog/13_1.6.1_2017-11-09.md
Normal file
1
changelog/13_1.6.1_2017-11-09.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
- Improved sidebar responsiveness
|
2
changelog/14_1.7.0_2018-04-15.md
Normal file
2
changelog/14_1.7.0_2018-04-15.md
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
- Allow to add anything to the shopping list, not only products
|
||||||
|
- Major project refactoring
|
1
changelog/15_1.8.0_2018-04-16.md
Normal file
1
changelog/15_1.8.0_2018-04-16.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
- grocy is now fully localizable and ships by default with English and German translations
|
2
changelog/16_1.8.1_2018-04-18.md
Normal file
2
changelog/16_1.8.1_2018-04-18.md
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
- New configuration option "BASE_URL" to define base installation URL (should make subdirectory installations possible, see #3)
|
||||||
|
- Added some missing translations
|
1
changelog/17_1.8.2_2018-04-18.md
Normal file
1
changelog/17_1.8.2_2018-04-18.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
- Fixed login form didn't respect the configured BASE_URL
|
1
changelog/18_1.9.0_2018-04-21.md
Normal file
1
changelog/18_1.9.0_2018-04-21.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
- Documented the REST API and data model, see the integrated instance of Swagger UI at [/api](https://demo.grocy.info/api)
|
1
changelog/19_1.9.1_2018-04-22.md
Normal file
1
changelog/19_1.9.1_2018-04-22.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
- Added validation of all API requests and improved Swagger/OpenAPI description
|
1
changelog/1_0.1.0_2017-04-15.md
Normal file
1
changelog/1_0.1.0_2017-04-15.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
- Basic features, mainly about a interface to record grocery purchases and consumptions
|
1
changelog/20_1.9.2_2018-04-22.md
Normal file
1
changelog/20_1.9.2_2018-04-22.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
- Added a plugin system for looking up products against external services by barcode, see #6 for reference
|
4
changelog/21_1.10.0_2018-05-12.md
Normal file
4
changelog/21_1.10.0_2018-05-12.md
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
- It's now possible to consume products directly from stock overview with one click
|
||||||
|
- Added due/overdue info on bateries- and habits overview (like on stock overview)
|
||||||
|
- Reworked general page layout and improved responsiveness (see #9 and thanks @d-Rickyy-b)
|
||||||
|
- Translations fixes
|
1
changelog/22_1.11.0_2018-06-15.md
Normal file
1
changelog/22_1.11.0_2018-06-15.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
- Added an option to not use URL rewriting (for webservers which, however, don't support URL rewriting)
|
2
changelog/23_1.12.0_2018-07-08.md
Normal file
2
changelog/23_1.12.0_2018-07-08.md
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
- On the stockoverview it's now possible to filter the products by location
|
||||||
|
- All dropdowns are now sorted alphabetically
|
1
changelog/24_1.12.1_2018-07-08.md
Normal file
1
changelog/24_1.12.1_2018-07-08.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
- Bug fix for location filtering on stock overview page did not work in all browsers
|
3
changelog/25_1.13.0_2018-07-12.md
Normal file
3
changelog/25_1.13.0_2018-07-12.md
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
- Upgraded Bootstrap and some other dependencies (grocy now looks even better!)
|
||||||
|
- Added Italian translation (thanks @davidoskky)
|
||||||
|
- => Demo for this language available at: https://it.demo.grocy.info
|
5
changelog/26_1.13.1_2018-07-12.md
Normal file
5
changelog/26_1.13.1_2018-07-12.md
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
This was released shortly after the last release to fix a small regression bug, original changes from Version 1.13.0:
|
||||||
|
|
||||||
|
- Upgraded Bootstrap and some other dependencies (grocy now looks even better!)
|
||||||
|
- Added Italian translation (thanks @davidoskky)
|
||||||
|
- => Demo for this language available at: https://it.demo.grocy.info
|
13
changelog/27_1.14.0_2018-07-15.md
Normal file
13
changelog/27_1.14.0_2018-07-15.md
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
- New feature: **Recipes**
|
||||||
|
- Organize a list of products, amounts and a description into recipes and see at a glance if everything needed is in stock or put the missing things with one click on the shopping list
|
||||||
|
- Try it live on the demo page: => https://demo.grocy.info/recipes
|
||||||
|
- Added norwegian translation (thanks @BlizzWave)
|
||||||
|
- Demo available at: => https://no.demo.grocy.info
|
||||||
|
- A lot of small UI improvements
|
||||||
|
- Columns in tables can now be reordered
|
||||||
|
- Show a calendar on the shopping list page (useful, at least for me)
|
||||||
|
- Table column ordering and sorting is now remembered
|
||||||
|
- Sidebar collapse state is now remembered
|
||||||
|
- Fixed datetimepicker border
|
||||||
|
- Keep the parent sidebar menu item expanded if the active page is a sub menu item
|
||||||
|
- Custom JS/CSS file names have changed [see README](https://github.com/berrnd/grocy#adding-your-own-css-or-js-without-to-have-to-modify-the-application-itself)
|
9
changelog/28_1.15.0_2018-07-22.md
Normal file
9
changelog/28_1.15.0_2018-07-22.md
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
- New related project: **grocy-desktop**
|
||||||
|
- => https://github.com/berrnd/grocy-desktop
|
||||||
|
- Run grocy without a webserver just like a normal (windows) desktop application
|
||||||
|
- New "embedded mode" for grocy to help running in "desktop application mode" [see README](https://github.com/berrnd/grocy#embedded-mode)
|
||||||
|
- New datepicker shorthands and improvements
|
||||||
|
- `YYYYMMe` or `YYYYMM+` gets expanded to the end of the given month in the given year in proper notation
|
||||||
|
- Changed: `MMDD` will be expanded to the given day next year if > today
|
||||||
|
- [see README](https://github.com/berrnd/grocy#input-shorthands-for-date-fields)
|
||||||
|
- Some other small bug fixes
|
8
changelog/29_1.16.0_2018-07-25.md
Normal file
8
changelog/29_1.16.0_2018-07-25.md
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
- Replaced the single user (so far defined in `/data/config.php`) with a multi-user management
|
||||||
|
- The currently defined user will automatically be migrated, please remove `HTTP_USER` and `HTTP_PASSWORD` from your config file afterwards
|
||||||
|
- For this it was necessary to delete all sessions and API keys during the migration
|
||||||
|
- Added an update script (`/update.sh`) to make updates (on Linux machines) easier
|
||||||
|
- See also ["How to update" in README](https://github.com/berrnd/grocy#how-to-update)
|
||||||
|
- Added the possibility to track who did a habit
|
||||||
|
- Added a rudimentary habit analysis possibility
|
||||||
|
- Different small UI, code and translation improvements
|
1
changelog/2_0.2.0_2017-04-16.md
Normal file
1
changelog/2_0.2.0_2017-04-16.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
- General improvements, the work goes on...
|
4
changelog/30_1.17.0_2018-08-04.md
Normal file
4
changelog/30_1.17.0_2018-08-04.md
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
- Basic product price tracking (can be entered on purchase, a little price history chart is shown in the product card - right side on purchase/consume/etc. pages)
|
||||||
|
- Proper pluralization of everything (for quantity units you can enter the plural form in master data)
|
||||||
|
- On all overview pages the statistics shown in the header are now updated when doing changes directly on the page (e. g. consuming a product)
|
||||||
|
- Lots of small fixes and improvements (form validation, translations - thanks for keeping the norwegian translation always updated @BlizzWave, other small bugs)
|
5
changelog/31_1.18.0_2018-08-11.md
Normal file
5
changelog/31_1.18.0_2018-08-11.md
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
- The complete row is now refreshed on changes on all overview pages
|
||||||
|
- Added a checkbox to set the "never expires date" in best before date inputs (alternative to shortcut "x")
|
||||||
|
- Recipes can now have arbitrary quantity units and stock is only checked for one unit then (imagine you have sugar in "Packs" in stock but your recipe "Pancakes" needs 200 grams)
|
||||||
|
- Added a "consume this recipe button" to remove all ingredients of a recipe from stock with one click
|
||||||
|
- Other small UI changes/improvements
|
1
changelog/32_1.18.1_2018-09-08.md
Normal file
1
changelog/32_1.18.1_2018-09-08.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
- Some smaller UI bug fixes and enhancements (thanks again for all the testing @BlizzWave)
|
6
changelog/33_1.19.0_2018-09-24.md
Normal file
6
changelog/33_1.19.0_2018-09-24.md
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
- New feature: Tasks / To-do list
|
||||||
|
- Renamed habits to chores as this is more what it is about
|
||||||
|
- Products can now be organized in product groups, this group is also used to group the items on the shopping list (you can use this to optimize your way in the supermarket for example)
|
||||||
|
- Added an option to stay logged in permanently (checkbox on the login page)
|
||||||
|
- When the database was changed externally, the current page is automatically reloaded when there was no input for at least 50 seconds
|
||||||
|
- Fixed some minor UI bugs
|
2
changelog/34_1.19.1_2018-09-27.md
Normal file
2
changelog/34_1.19.1_2018-09-27.md
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
- The colored info bars on top of all (overview)pages can now be clicked to filter the table accordingly
|
||||||
|
- Fixed some minor mostly UI related bugs
|
2
changelog/35_1.19.2_2018-09-29.md
Normal file
2
changelog/35_1.19.2_2018-09-29.md
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
- Important bug fix: All forms were submitted twice when using ENTER instead of the OK/Save button
|
||||||
|
- Norwegian translation updates (thanks @BlizzWave )
|
3
changelog/36_1.20.0_2018-09-30.md
Normal file
3
changelog/36_1.20.0_2018-09-30.md
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
- New optional "Night Mode" (thanks a lot @BlizzWave, can also be activated automatically by a time range - see the new dropdown menu next to the user menu)
|
||||||
|
- Docker support (thanks @talmai)
|
||||||
|
- Fixed some minor UI bugs
|
6
changelog/37_1.21.0_2018-10-06.md
Normal file
6
changelog/37_1.21.0_2018-10-06.md
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
- New feature: Equipment
|
||||||
|
- Manage all your household equipment/devices in one place and have the information/instruction manual at hand when needed
|
||||||
|
- New feature: Products can now have pictures
|
||||||
|
- Add them in the product edit page
|
||||||
|
- Will be shown in the productcard (purchase/consume/etc. pages) and when you click the product name on the stock overview page (a little image icon next to the product name indicates if the product has an image)
|
||||||
|
- Recipes and the new equipment edit page now have a little editor with text formatting capabilities
|
14
changelog/38_1.22.0_2018-10-27.md
Normal file
14
changelog/38_1.22.0_2018-10-27.md
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
- Added a journal for stock bookings, chore executions and battery charge cycles
|
||||||
|
- => Button in each line on the overview pages or the "Journal" button next to the headline on every overview page
|
||||||
|
- Added the possibility to undo any stock booking, chore execution and battery charge cycle
|
||||||
|
- => Button in the success popup while booking a purchase/consume/etc. or on the new journal pages (see above)
|
||||||
|
- Presets for new products are now configurable
|
||||||
|
- => "Presets for new products" button next to the headline on the products list page
|
||||||
|
- Recipes can now be nested (include a recipe into another one)
|
||||||
|
- Recipe ingredients can now be grouped together which will result in headlines per group in the rendered recipe
|
||||||
|
- => Group can be set on the recipe position edit page, demo recipe is "Pizza")
|
||||||
|
- On the stock overview page, the product card is now shown when clicking the product name
|
||||||
|
- Added option to filter by product group on stock overview page
|
||||||
|
- When auto reloading on external changes is enabled, the page is not reloaded when there is a fullscreen card active (recipe/equipment instruction manual)
|
||||||
|
- On the product-/chore-/batterycard there is now a link to the edit page of the corresponding item
|
||||||
|
- Some other minor bug fixes
|
18
changelog/39_1.23.0_2018-11-24.md
Normal file
18
changelog/39_1.23.0_2018-11-24.md
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
- New feature: "Shopping list to stock workflow"
|
||||||
|
- Add a single shopping list item or all at once to stock directly from the shopping list
|
||||||
|
- There are new "stock settings" under settings menu in the top right corner
|
||||||
|
- You can enable there, that all products which have "Default best before days" set, are added without confirmation in this workflow
|
||||||
|
- => This means, you can add the whole shopping list to stock with one click, if you want
|
||||||
|
- Improved stock handling
|
||||||
|
- On consume, a specific stock item can now be picked
|
||||||
|
- A stock item can now be marked as "opened" (on the consume page or directly from stock overview, visible in the product card and on the stock overview page)
|
||||||
|
- New feature: Calendar
|
||||||
|
- Shows all upcoming product expirations, due chores, due tasks and due battery charge cycles
|
||||||
|
- New translation: French (thanks all the translators)
|
||||||
|
- As for all languages, a demo is available at: https://fr.demo.grocy.info
|
||||||
|
- Small other improvements
|
||||||
|
- Allow fraction numbers for recipe ingredients when not checked against stock and add an option to not check stock for a recipe position
|
||||||
|
- The current time can now be shown in the header (see the settings menu next to the user icon)
|
||||||
|
- Changed: Docker related things are now in a separate repository: https://github.com/grocy/grocy-docker
|
||||||
|
- Changed: Translations are now managed with Transifex: https://www.transifex.com/grocy/grocy
|
||||||
|
|
1
changelog/3_0.3.0_2017-04-17.md
Normal file
1
changelog/3_0.3.0_2017-04-17.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
- Form validation and barcode input handling improvements
|
2
changelog/40_1.23.1_2018-11-27.md
Normal file
2
changelog/40_1.23.1_2018-11-27.md
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
- Added a skip button when adding all shopping list items in "Shopping list to stock workflow"
|
||||||
|
- Fixed some minor UI related bugs
|
1
changelog/41_1.24.0_2018-12-30.md
Normal file
1
changelog/41_1.24.0_2018-12-30.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
- All `config.php` settings can now also be set via environment variables (for [grocy-docker](https://github.com/grocy/grocy-docker))
|
5
changelog/42_1.24.1_2019-01-10.md
Normal file
5
changelog/42_1.24.1_2019-01-10.md
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
- Fixed a SQL error during database migration when using SQLite >= 3.25.2
|
||||||
|
- Improved data tables loading time
|
||||||
|
- Location edit form did not work (master data)
|
||||||
|
- Quantity unit "purchase to stock factor" was not respected when putting a recipe on the shopping list or when comparing the already on the shopping list amount
|
||||||
|
- Better API response for POST routes when there is no or invalid JSON request body content
|
23
changelog/43_2.0.0_2019-03-06.md
Normal file
23
changelog/43_2.0.0_2019-03-06.md
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
- Breaking change: The API has been completely reworked, please review [the documentation](https://demo.grocy.info/api) before updating when you are using the API
|
||||||
|
- New feature: Tare weight handling
|
||||||
|
- An option per product
|
||||||
|
- Imagine this: You have flour in jars, the jar weighs 500 grams, currently there are 1000 grams in stock, the new weight including the jar is 1100 grams - grocy can now calculate the used amount on consume/purchase/inventory automatically, you only have to enter the weighed amount including the jar (demo product to showcase this "Flour")
|
||||||
|
- Recipe improvements
|
||||||
|
- Recipes are now scalable - define per recipe for how much servings it is, change the desired servings on the fly when the recipe is displayed, ingredient amounts are scaled accordingly
|
||||||
|
- The cost of a recipe is now displayed based on the last purchase price per ingredient (recipe scaling also applies)
|
||||||
|
- When putting all missing recipe ingredients on the shopping list, it is now possible to ignore certain ingredients (in the popup when clicking the "Put missing items on shopping list" button)
|
||||||
|
- A new option per recipe to not check against the amount already on the shopping list when putting all missing ingredients on it (by default, only the amount not already on the shopping list is added, when this is enabled, always the whole missing amount will be put on the shopping list)
|
||||||
|
- On consume, there can now be tracked for which recipe it was, this is also tracked automatically when using the "Consume all ingredients needed by this recipe" button (for future statistical purposes)
|
||||||
|
- Recipes can now have pictures
|
||||||
|
- New "gallery view" for recipes (demo available at https://demo.grocy.info/recipes?tab=gallery)
|
||||||
|
- Stock improvements
|
||||||
|
- It is now optionally possible to have partial units in stock (option per product)
|
||||||
|
- On purchase, a different location can now be assigned (imagine you have two freezers, by default you store your pizza there, but sometimes there)
|
||||||
|
- New translations: (thanks all the translators)
|
||||||
|
- Spanish (demo available at https://es.demo.grocy.info)
|
||||||
|
- Turkish (demo available at https://tr.demo.grocy.info)
|
||||||
|
- Other improvements
|
||||||
|
- The calendar can now be shared/integrated in iCal format (button in the header on the calendar page)
|
||||||
|
- Added feature flags to hide/disable certain parts of grocy when you don't use them (for example hide "Chores" and all related UI elements, when you don't use it, see `config-dist.php`)
|
||||||
|
- Added a "Apple Touch Icon" and a "Web App Manifest" which should improve grocy on mobile devices and also enables "Add to Home screen" on major mobile browsers
|
||||||
|
- A lot of other minor small and bigger UI improvements
|
10
changelog/44_2.1.0_2019-03-09.md
Normal file
10
changelog/44_2.1.0_2019-03-09.md
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
- Some small UI fixes & improvements
|
||||||
|
- Recipe ingredient notes were not displayed
|
||||||
|
- Edit/delete buttons on the equipment page had no icons
|
||||||
|
- Improved the overview pages "action buttons column" (e. g. hide more rarely used actions behind a context/dropdown menu)
|
||||||
|
- The "purchase to stock conversion factor" is now displayed on the purchase page when QU units are different (above the amount field)
|
||||||
|
- Some JS files were not loaded correctly on case sensitive file systems
|
||||||
|
- The changelog is now included as markdown files (in `/changelog` directory, one file per release with a filename in format `<ReleaseNumber>_<Version>_<ReleaseDateIso>.md`) and shown in the about dialog
|
||||||
|
- Please review your `CURRENCY` setting in `data/config.php`, see also `config-dist.php` - this should be the ISO 4217 code of the currency to properly work with the JS `toLocaleString` function
|
||||||
|
- New translation: (thanks all the translators)
|
||||||
|
- Russian (demo available at https://ru.demo.grocy.info)
|
5
changelog/45_2.2.0_2019-03-10.md
Normal file
5
changelog/45_2.2.0_2019-03-10.md
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
- New API method to get a product by its barcode (`/stock/products/by-barcode/{barcode}`, thanks @matejdro)
|
||||||
|
- The best before date on the purchase and inventory page can now also be today or earlier, but when so, a short hint is displayed
|
||||||
|
- Fixed some UI bugs
|
||||||
|
- When consuming a product with "Allow partial units in stock" enabled from the stock overview page, the displayed amount after the stock booking was wrong
|
||||||
|
- The inventory form was not validated with certain click paths
|
17
changelog/46_2.3.0_2019-04-06.md
Normal file
17
changelog/46_2.3.0_2019-04-06.md
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
- Stock improvements
|
||||||
|
- A different location can now also be set during inventory (as for purchases)
|
||||||
|
- A partial minimum stock amount can now be set when "Allow partial units in stock" is enabled (product option)
|
||||||
|
- Recipe improvements
|
||||||
|
- There is now a default per product for "Disable stock fulfillment checking for this ingredient" (ingredient option, default can be defined as a product option)
|
||||||
|
- Some small UI fixes & improvements
|
||||||
|
- THe "Mark as open" button on the stock overview page was disabled when the current stock amount was exactly 1
|
||||||
|
- The number in the "x products expiring within the next 5 days" badge was incorrect for products expiring exactly in 5 days
|
||||||
|
- On the product groups page there is now a new column which displays the product count per group (+ a link to the products page filtered by that product group)
|
||||||
|
- Added a message to clarify that in product dropdowns also something unknown can be entered to start a workflow
|
||||||
|
- Some other small CSS fixes (context menus were not fully displayed when the parent container was to small, improved padding for text inputs)
|
||||||
|
- As always: Updated translations (thanks all the translators)
|
||||||
|
|
||||||
|
### Self promotion
|
||||||
|
[grocy-desktop](https://github.com/grocy/grocy-desktop) is now also available through the Microsoft Store
|
||||||
|
|
||||||
|
<a href="//www.microsoft.com/store/apps/9nwb1trnnksf?cid=storebadge&ocid=badge"><img src="https://assets.windowsphone.com/85864462-9c82-451e-9355-a3d5f874397a/English_get-it-from-MS_InvariantCulture_Default.png" alt="Get it from Microsoft" width="150px" /></a>
|
34
changelog/47_2.4.0_2019-05-10.md
Normal file
34
changelog/47_2.4.0_2019-05-10.md
Normal file
@@ -0,0 +1,34 @@
|
|||||||
|
- New feature: Userfields
|
||||||
|
- Attach any custom field to any entity (Products, Locations, Euqipment, etc.)
|
||||||
|
- Userfields can have types (Text, Number, Date, etc.)
|
||||||
|
- Will be shown / can be filled on the edit page of the corresponding entity and will also optionally show in the corresponding tables (inclcudes overview pages)
|
||||||
|
- => Can be configured under Master data / Userfields
|
||||||
|
- New feature: Meal planning
|
||||||
|
- Simple approach for the beginning (more to come): A week view where you can add recipes for each day (new menu entry in the sidebar, below calendar)
|
||||||
|
- Of course it's also possible to put missing things directly on the shopping list from there, also for a complete week at once
|
||||||
|
- General improvements
|
||||||
|
- The "expires soon" or "due soon" days (yelllow bar at the top of each overview page) can now be configured
|
||||||
|
- => New settings page for each area under the settings icon at the top right
|
||||||
|
- Stock improvements
|
||||||
|
- It's now possible to have multiple / named shopping lists
|
||||||
|
- Automations still use the default shopping list and also the default shopping list cannot be deleted
|
||||||
|
- More information on the product card like "Spoil rate" or "Average shelf life"
|
||||||
|
- It's now possible to set a price for added products during inventory
|
||||||
|
- It's now possible to customize the default amount for purchase/consume (see stock settings under the settings icon on the top right)
|
||||||
|
- Chores improvements
|
||||||
|
- New recurrence patterns - chores can now also be "scheduled" to repat daily/weekly/monthly
|
||||||
|
- It's now possible to track the day of a chore execution only (without the time, option per chore)
|
||||||
|
- Recipe improvements
|
||||||
|
- It's now possible to enter a "variable amount" (e. g. if a recipe needs "1 - 2 cups"), the original amount is still used for stock fulfillment checking (if enabled for that recipe ingredient)
|
||||||
|
- New translations: (thanks all the translators)
|
||||||
|
- Swedish (demo available at https://sv.demo.grocy.info)
|
||||||
|
- Polish (demo available at https://pl.demo.grocy.info)
|
||||||
|
- Internal improvement: Localizations are now handled via gettext, both on server and client side
|
||||||
|
- Mainly to properly handle languages with more than 2 plural forms
|
||||||
|
- This involved some string changes which results in a needed (re)translation of about 20 strings (excluding demo data)
|
||||||
|
- Also applies to quantity units, n-plural forms can be entered on the quantity unit edit page
|
||||||
|
- It's not required to install the PHP gettext extension, on both, server and client, managed implementations of gettext are used ([oscarotero/Gettext](https://github.com/oscarotero/Gettext) & [oscarotero/gettext-translator](https://github.com/oscarotero/gettext-translator))
|
||||||
|
- Some other small fixes and improvements
|
||||||
|
- The "Add as barcode to existing product" productpicker workflow failed to add the barcode to the given product
|
||||||
|
- Recipes can now be filter by stock availability
|
||||||
|
- Added a feature flag (`config.php` setting) to also be able to hide all stock related UI elements and routes
|
2
changelog/48_2.4.1_2019-05-16.md
Normal file
2
changelog/48_2.4.1_2019-05-16.md
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
- Fixed a performance problem for loading data tables related to the new Userfields feature
|
||||||
|
- Fixed that when using single quotes in a product name did not trigger the workflow popup
|
11
changelog/49_2.4.2_2019-06-09.md
Normal file
11
changelog/49_2.4.2_2019-06-09.md
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
- Fixed that deleting meal plan entries did not work
|
||||||
|
- Fixed a problem that the user settings were not properly initialized for the frontend JS part when not logged only (so potentially affected only the login page)
|
||||||
|
- Fixed an issue that the shopping list did not load when a plural translation for a quantity unit was missing
|
||||||
|
- Fixed that tooltips were visible forever when consuming all products on the stock overview page
|
||||||
|
- Fixed that login did not work when "Stay logged in permanently" was set and grocy runs on a 32-bit system (thanks @matejdro)
|
||||||
|
- Fixed page reloads when "Auto reload on external changes" is enabled and there is unsaved form data (the detection did not work for forms in modal dialogs, e. g. when adding a entry to the meal plan)
|
||||||
|
- Fixed (again) that the product picker did not work properly when the product name contains single quotes
|
||||||
|
- Fixed that a entered barcode on the product edit page was only saved when "adding" it to the barcodes list by pressing `TAB` (is now automatically added to the list also when just leaving the field)
|
||||||
|
- Improved that errors/messages from the API are shown properly when undoing a stock booking is not possible (stock journal page)
|
||||||
|
- Improved night mode CSS (done by @BlizzWave, thanks!)
|
||||||
|
- A new localization for `en_GB` is now always included - nothing is really translated there, it's only about component "translations" that e. g. the first day of the week is correct for calendars
|
1
changelog/4_0.4.0_2017-04-18.md
Normal file
1
changelog/4_0.4.0_2017-04-18.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
- Add possibility to have multiple barcodes per product
|
16
changelog/50_2.4.3_2019-07-06.md
Normal file
16
changelog/50_2.4.3_2019-07-06.md
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
- Fixed the messed up message/toast after consuming a product from the stock overview page
|
||||||
|
- Fixed that "Track date only" chores were always tracked today, regardless of the given date
|
||||||
|
- Fixed that the "week costs" were wrong after removing a meal plan entry
|
||||||
|
- Fixed wrong recipes costs calculation with nested recipes when the base recipe servings are > 1 (also affected the meal plan when adding such a recipe there)
|
||||||
|
- Fixed consuming recipes did not consume ingredients of the nested recipes
|
||||||
|
- Improved recipes API - added new endpoints to get stock fulfillment information (thanks @Aerex)
|
||||||
|
- Improved date display for products that never expires (instead of "2999-12-31" now just "Never" will be shown)
|
||||||
|
- Improved date display for dates of today and no time (instead of the hours since midnight now just "Today" will be shown)
|
||||||
|
- Improved shopping list handling
|
||||||
|
- Items can now be switched between lists (there is a shopping list dropdown on the item edit page)
|
||||||
|
- Items can now be marked as "done" (new check mark button per item, when clicked, the item will be displayed greyed out, when clicked again the item will be displayed normally again)
|
||||||
|
- Improved that products can now also be consumed as spoiled from the stock overview page (option in the more/context menu per line)
|
||||||
|
- Added a "consume this recipe"-button to the meal plan (and also a button to consume all recipes for a whole week)
|
||||||
|
- Added the possibility to undo a task (new button per task, only visible when task is already completed) and also a corresponding API endpoint
|
||||||
|
- Added a new `config.php` setting `DISABLE_AUTH` to be able to disable authentication / the login screen, defaults to `false`
|
||||||
|
- Added a new `config.php` setting `CALENDAR_FIRST_DAY_OF_WEEK` to be able to change the first day of a week used for calendar views (meal plan for example) in the frontend, defaults to locale default
|
6
changelog/51_2.4.4_2019-07-07.md
Normal file
6
changelog/51_2.4.4_2019-07-07.md
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
- Fixed that price data (last price & chart) was not taken from inventory correction bookings, only purchases
|
||||||
|
- Fixed weekly chores were scheduled on the same day after execution
|
||||||
|
- Fixed that undone chores were also included in "Last tracked"
|
||||||
|
- Fixed the date-time-picker width was too narrow sometimes
|
||||||
|
- Improved that execution dates of "Track date only" chores will never display the time part
|
||||||
|
- Improved date display for products that never expire (again, there was a display problem after consuming an item on the stock overview page)
|
107
changelog/52_2.5.0_2019-09-22.md
Normal file
107
changelog/52_2.5.0_2019-09-22.md
Normal file
@@ -0,0 +1,107 @@
|
|||||||
|
### New feature: Custom entities / objects / lists
|
||||||
|
- Custom entities are based on Userfields and can be used to add any custom lists you want to have in grocy
|
||||||
|
- They can have an own menu entry in the sidebar
|
||||||
|
- => See "Manage master data" -> "Userentities" or try it on the demo: https://demo.grocy.info/userobjects/exampleuserentity
|
||||||
|
|
||||||
|
### New feature: Use the device camera for barcode scanning
|
||||||
|
- Available on any barcode-enabled field (so currently only for picking products) - a new camera button at the right of side the text field
|
||||||
|
- Implemented using [QuaggaJS](https://github.com/serratus/quaggaJS) - camera stream processing happens totally offline / client-side
|
||||||
|
- Please note due to browser security restrictions, this only works when serving grocy via a secure connection (`https://`)
|
||||||
|
- There is also a `config.php` setting `DISABLE_BROWSER_BARCODE_CAMERA_SCANNING` to disable this, if you don't need it at all (defaults to `false`)
|
||||||
|
- I you have problems that barcocdes are not recognized properly, there is a little "barcode scanner testing page" at [/barcodescannertesting](https://demo.grocy.info/barcodescannertesting)
|
||||||
|
- => Quick video demo: https://www.youtube.com/watch?v=Y5YH6IJFnfc
|
||||||
|
|
||||||
|
### Stock improvements/fixes
|
||||||
|
- Products can now have variations (nested products)
|
||||||
|
- Define the parent product for a product on the product edit page (only one level is possible, means a product which is used as a parent product in another product, cannot have a parent product itself)
|
||||||
|
- Parent and sub products can have stock (both are regular products, no difference from that side)
|
||||||
|
- On the stock overview page the aggregated amount is displayed next to the amount (sigma sign)
|
||||||
|
- When a recipe needs a parent product, the need is also fulfilled when enough sub product(s) are in stock
|
||||||
|
- Quantity units can now be linked (related measurements / unit conversion)
|
||||||
|
- On the quantity unit edit page default conversion can be defined for each unit
|
||||||
|
- Products "inherit" the default conversion and additionally can have their own / override the default ones
|
||||||
|
- It's now possible to print a "Location Content Sheet" with the current stock per location - new button at the top of the stock overview page (thought to hang it at the location, note used amounts on paper and track it in grocy later)
|
||||||
|
- Stock overview page improvements
|
||||||
|
- Options in the more/context-menu to directly open the purchase/consume/inventory pages prefilled with the current product in an popup/dialog
|
||||||
|
- Option in the more/context-menu to add the current product directly to a shopping list
|
||||||
|
- Option in the more/context-menu to search for recipes containing the current product
|
||||||
|
- It's now possible to undo stock bookings ("Undo"-button in the success message, like it was already possible on the purchase/consume/inventory pages)
|
||||||
|
- Improved that on any stock changes the corresponding product table row is properly refreshed
|
||||||
|
- New `config.php` setting `FEATURE_SETTING_STOCK_COUNT_OPENED_PRODUCTS_AGAINST_MINIMUM_STOCK_AMOUNT` to configure if opened products should be considered for minimum stock amounts (defaults to `true`, so opened products will now be considered missing by default - please change this setting if you want the old behaviour)
|
||||||
|
- The product description now can have formattings (HTML/WYSIWYG editor like for recipes)
|
||||||
|
- Products now have a new field for calories (kcal, per stock quantity unit)
|
||||||
|
- "Factor purchase to stock quantity unit" (product option) can now also be a decimal number when "Allow partial units in stock" is enabled
|
||||||
|
- New "Sub feature flags" in `config.php` to disable some sub-features (hide the corresponding UI elements) if you don't need them (all new feature flags default to `true`, so no changed behaviour when not configured)
|
||||||
|
- `FEATURE_FLAG_STOCK_PRICE_TRACKING` to disable product price tracking
|
||||||
|
- `FEATURE_FLAG_STOCK_LOCATION_TRACKING` to disable product location tracking
|
||||||
|
- `FEATURE_FLAG_STOCK_BEST_BEFORE_DATE_TRACKING` to disable product best before date tracking
|
||||||
|
- `FEATURE_FLAG_STOCK_PRODUCT_OPENED_TRACKING` to disable product opened tracking
|
||||||
|
- Fixed/refined some things regarding purchase/consume/inventory of products with enabled tare weight handling (nothing was broken, but the success popups may not displayed the correct amount that was posted)
|
||||||
|
- Fixed that "Spoil rate" and "Average shelf life" on the product card was wrong in most cases
|
||||||
|
- When going to the product edit page, after saving the product, it will now always return to the previous page
|
||||||
|
|
||||||
|
### Shopping list improvements
|
||||||
|
- Shopping lists now have a notes field (HTML/WYSIWYG editor, just to save some notes per shopping list)
|
||||||
|
- Shopping lists can now be printed (new button next to the add/delete shopping list button)
|
||||||
|
|
||||||
|
### Recipe improvements
|
||||||
|
- Based on the new linked quantity units, recipe ingredients can now use any product related unit, the amount is calculated according to the cnoversion factor of the unit relation
|
||||||
|
- Based on the new calories field per product, the calories per recipe are now shown based on the selected servings (in the header, next to the costs)
|
||||||
|
- New option "price factor" per recipe ingredient (defaults to `1`) - the resulting costs of the recipe ingredient will be multiplied by that factor
|
||||||
|
- Use this for example for spices in combination with "Only check if a single unit is in stock" to not take the full price of a pack of pepper into account for a recipe
|
||||||
|
- The search field on the recipe overview page now also searches for product names of recipe ingredients (means it's possible to search an recipe by a product name)
|
||||||
|
- Fixed a problem where the meal plan did not load when a recipe, which was already added to a the meal plan, was deleted
|
||||||
|
|
||||||
|
### Chores improvements
|
||||||
|
- Chores can now be assigned to users
|
||||||
|
- Option per chore, different "assignment types" like "Random", "Who least did first", etc.
|
||||||
|
- On the chores overview page the list can be filterd to only show chores assigned to the currently logged in user (or to any other user)
|
||||||
|
- New option "Due date rollover" per chore which means the chore can never be overdue, the due date will shift forward each day when due
|
||||||
|
- New option "Consume product on chore execution" per chore to automatically consume a product when a chore execution is tracked
|
||||||
|
- When tracking an execution from the chores overview page, filters are re-applied afterwards (means when you have filtered the page to only show overdue chores and after the execution the chore is not overdue anymore, it will now be immediately hidden)
|
||||||
|
|
||||||
|
### Equipment improvements/fixes
|
||||||
|
- Fixed that the delete button not always deleted the currently selected equipment item
|
||||||
|
|
||||||
|
### Userfield improvements/fixes
|
||||||
|
- New Userfield type "Select list" for a list of predefined values where a single or also multiple values can then be selected on the entity object
|
||||||
|
- New Userfield type "Link" - a single-line-textbox where the content will be rendered as a clickable link
|
||||||
|
- Userfields of type "checkbox" are rendered as a checkmark in tables when checked (instead of "1" as till now)
|
||||||
|
- Product Userfields are now also rendered on the shopping list (for items which have a product referenced)
|
||||||
|
- Fixed that the Userfield type "Preset list" had always the caption "Product group" instead of the configured one (thanks @oncleben31)
|
||||||
|
|
||||||
|
### General & other improvements/fixes
|
||||||
|
- Added a new `config.php` setting `CALENDAR_SHOW_WEEK_OF_YEAR` to configure if calendars should show week numbers (defaults to `true`)
|
||||||
|
- Fixed that date/time pickers not considered the `config.php` setting `CALENDAR_FIRST_DAY_OF_WEEK`
|
||||||
|
- Improved the handling which entry page to use with disabled feature flags (thanks @nielstholenaar)
|
||||||
|
- Boolean settings provided via environment variables (so the strings `true` and `false`) are now parsed correctly (thanks @mduret)
|
||||||
|
- All uploaded pictures (currently for products and recipes) are now automatically downscaled to the appropriate size when serving them to improve page load times (this requires the `php-gd` extension, if not installed, images will not be downscaled)
|
||||||
|
- It's now possible to test plural forms of quantity units (button on the quantity unit edit page, only visible if the current language requires more than 2 plural forms)
|
||||||
|
- On the login page no menus and the sidebar is now hidden
|
||||||
|
- New translations: (thanks all the translators)
|
||||||
|
- Danish (demo available at https://da.demo.grocy.info)
|
||||||
|
- Dutch (demo available at https://nl.demo.grocy.info)
|
||||||
|
- Internal change for how the localizations for the demo instances are handled
|
||||||
|
- For the pre-release demo now all currently supported languages are available (was already the case for the stable demo)
|
||||||
|
- Additionally all language files which reached the completion limit of 80 % will now be automatically pulled from Transifex 10 minutes past every hour (to have a kind of instant preview of changed tranlsations)
|
||||||
|
- The URLs have changed, I'll try to keep all existing URLs redirecting properly for a long time
|
||||||
|
- If you want to link to the demo, please only use https://demo.grocy.info (stable demo) or https://demo-prerelease.grocy.info (current master branch demo)
|
||||||
|
|
||||||
|
### API improvements & non-breaking changes
|
||||||
|
- New endpoint `/objects/{entity}/search/{searchString}` to search for objects by name (contains search)
|
||||||
|
- New endpoint `/stock/shoppinglist/add-product` to add a product to a shopping list (thanks @Forceu)
|
||||||
|
- New endpoint `/stock/shoppinglist/remove-product` to remove a product from a shopping list (thanks @Forceu)
|
||||||
|
- New endpoint `/chores/executions/calculate-next-assignments` to (re)calculate next user assignments for a single or all chores
|
||||||
|
- New endpoint `/stock/products/by-barcode/{barcode}/add` to add a product to stock by its barcode
|
||||||
|
- New endpoint `/stock/products/by-barcode/{barcode}/consume` to remove a product to stock by its barcode
|
||||||
|
- New endpoint `/stock/products/by-barcode/{barcode}/inventory` to inventory a product by its barcode
|
||||||
|
- New endpoint `/stock/products/by-barcode/{barcode}/open` to mark a product as opened by its barcode
|
||||||
|
- New endpoint `/stock/bookings/{bookingId}` to retrieve a single stock booking
|
||||||
|
- Endpoint `GET /files/{group}/{fileName}` can now also downscale pictures (see API documentation on [/api](https://demo.grocy.info/api))
|
||||||
|
- When adding a product (through `stock/product/{productId}/add` or `stock/product/{productId}/inventory`) with omitted best before date and if the given product has "Default best before days" set, the best before date is calculated based on that (so far always today was used which is still the case when no date is supplied and also the product has no "Default best before days set) (thanks @Forceu)
|
||||||
|
- Field `stock_amount` of endpoint `/stock/products/{productId}` now returns `0` instead of `null` when the given product is not in stock (thanks @Forceu)
|
||||||
|
- Fixed that `/system/db-changed-time` always returned the current time (more or less) due to that that time is the database file modification time and the database is effectively changed on each request because of session information tracking - which now explicitly does not change the database file modification time, so this should work again to determine if any data changes happened
|
||||||
|
- It's now also possible to provide the API key via a query parameter (same name as the header, so `GROCY-API-KEY`)
|
||||||
|
|
||||||
|
#### Say thanks
|
||||||
|
Because there were some questions about that in the past: If grocy is useful for you, [say thanks](https://grocy.info/#say-thanks)!
|
1
changelog/5_1.0.0_2017-04-20.md
Normal file
1
changelog/5_1.0.0_2017-04-20.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
- Ready to ERP your fridge!
|
1
changelog/6_1.0.1_2017-04-20.md
Normal file
1
changelog/6_1.0.1_2017-04-20.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
- Added flow to directly add products and barcodes from purchase and inventory view
|
2
changelog/7_1.1.0_2017-04-21.md
Normal file
2
changelog/7_1.1.0_2017-04-21.md
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
* New feature: Shopping list (which is also automatically filled based on defined min. stock amount)
|
||||||
|
* Small UI changes for better productivity
|
1
changelog/8_1.2.0_2017-04-21.md
Normal file
1
changelog/8_1.2.0_2017-04-21.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
- Added a flow to add a new product with prefilled barcode
|
1
changelog/9_1.3.0_2017-04-22.md
Normal file
1
changelog/9_1.3.0_2017-04-22.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
- Added a favicon and more productivity improvements
|
@@ -1,11 +1,14 @@
|
|||||||
{
|
{
|
||||||
"require": {
|
"require": {
|
||||||
"php": ">=7.2",
|
"php": ">=7.2",
|
||||||
"slim/slim": "^3.8",
|
"slim/slim": "^3.12.2",
|
||||||
"morris/lessql": "^0.3.4",
|
"morris/lessql": "^0.4.1",
|
||||||
"rubellum/slim-blade-view": "^0.1.1",
|
"rubellum/slim-blade-view": "^0.1.1",
|
||||||
"tuupola/cors-middleware": "^0.7.0",
|
"tuupola/cors-middleware": "^1.0.0",
|
||||||
"eluceo/ical": "^0.15.0"
|
"eluceo/ical": "^0.15.1",
|
||||||
|
"erusev/parsedown": "^1.7.3",
|
||||||
|
"gettext/gettext": "^4.6.3",
|
||||||
|
"gumlet/php-image-resize": "^1.9.2"
|
||||||
},
|
},
|
||||||
"autoload": {
|
"autoload": {
|
||||||
"psr-4": {
|
"psr-4": {
|
||||||
|
677
composer.lock
generated
677
composer.lock
generated
File diff suppressed because it is too large
Load Diff
@@ -14,17 +14,27 @@
|
|||||||
# The settings defined here below
|
# The settings defined here below
|
||||||
|
|
||||||
|
|
||||||
# Either "production", "dev" or "prerelease"
|
# Either "production", "dev", "demo" or "prerelease"
|
||||||
|
# ("demo" and "prerelease" is reserved to be used only on the offical demo instances)
|
||||||
Setting('MODE', 'production');
|
Setting('MODE', 'production');
|
||||||
|
|
||||||
# Either "en" or "de" or the filename (without extension) of
|
# Either "en" or "de" or the directory name of
|
||||||
# one of the other available localization files in the "/localization" directory
|
# one of the other available localization folders in the "/localization" directory
|
||||||
Setting('CULTURE', 'en');
|
Setting('CULTURE', 'en');
|
||||||
|
|
||||||
|
# This is used to define the first day of a week for calendar views in the frontend,
|
||||||
|
# leave empty to use the locale default
|
||||||
|
# Needs to be a number where Sunday = 0, Monday = 1 and so forth
|
||||||
|
Setting('CALENDAR_FIRST_DAY_OF_WEEK', '');
|
||||||
|
|
||||||
|
# If calendars should show week numbers
|
||||||
|
Setting('CALENDAR_SHOW_WEEK_OF_YEAR', true);
|
||||||
|
|
||||||
# To keep it simple: grocy does not handle any currency conversions,
|
# To keep it simple: grocy does not handle any currency conversions,
|
||||||
# this here is used to format all money values,
|
# this here is used to format all money values,
|
||||||
# so can be anything (e. g. "USD" OR "$", doesn't matter...)
|
# so doesn't matter really matter, but should be the
|
||||||
Setting('CURRENCY', '$');
|
# ISO 4217 code of the currency ("USD", "EUR", "GBP", etc.)
|
||||||
|
Setting('CURRENCY', 'USD');
|
||||||
|
|
||||||
# The base url of your installation,
|
# The base url of your installation,
|
||||||
# should be just "/" when running directly under the root of a (sub)domain
|
# should be just "/" when running directly under the root of a (sub)domain
|
||||||
@@ -36,11 +46,20 @@ Setting('BASE_URL', '/');
|
|||||||
# see /data/plugins/DemoBarcodeLookupPlugin.php for an example implementation
|
# see /data/plugins/DemoBarcodeLookupPlugin.php for an example implementation
|
||||||
Setting('STOCK_BARCODE_LOOKUP_PLUGIN', 'DemoBarcodeLookupPlugin');
|
Setting('STOCK_BARCODE_LOOKUP_PLUGIN', 'DemoBarcodeLookupPlugin');
|
||||||
|
|
||||||
# If, however, your webserver does not support URL rewriting,
|
# If, however, your webserver does not support URL rewriting, set this to true
|
||||||
# set this to true
|
|
||||||
Setting('DISABLE_URL_REWRITING', false);
|
Setting('DISABLE_URL_REWRITING', false);
|
||||||
|
|
||||||
|
# Specify an custom homepage if desired - by default the homepage will be set to the stock overview,
|
||||||
|
# this needs to be one of the following values:
|
||||||
|
# stock, shoppinglist, recipes, chores, tasks, batteries, equipment, calendar
|
||||||
|
Setting('ENTRY_PAGE', 'stock');
|
||||||
|
|
||||||
|
# Set this to true if you want to disable authentication / the login screen,
|
||||||
|
# places where user context is needed will then use the default (first existing) user
|
||||||
|
Setting('DISABLE_AUTH', false);
|
||||||
|
|
||||||
|
# Set this to true if you want to disable the ability to scan a barcode via the device camera (Browser API)
|
||||||
|
Setting('DISABLE_BROWSER_BARCODE_CAMERA_SCANNING', false);
|
||||||
|
|
||||||
|
|
||||||
# Default user settings
|
# Default user settings
|
||||||
@@ -54,9 +73,23 @@ DefaultUserSetting('auto_night_mode_time_range_from', "20:00"); // Format HH:mm
|
|||||||
DefaultUserSetting('auto_night_mode_time_range_to', "07:00"); // Format HH:mm
|
DefaultUserSetting('auto_night_mode_time_range_to', "07:00"); // Format HH:mm
|
||||||
DefaultUserSetting('auto_night_mode_time_range_goes_over_midnight', true); // If the time range above goes over midnight
|
DefaultUserSetting('auto_night_mode_time_range_goes_over_midnight', true); // If the time range above goes over midnight
|
||||||
DefaultUserSetting('currently_inside_night_mode_range', false); // If we're currently inside of night mode time range (this is not user configurable, but stored as a user setting because it's evaluated client side to be able to use the client time instead of the maybe different server time)
|
DefaultUserSetting('currently_inside_night_mode_range', false); // If we're currently inside of night mode time range (this is not user configurable, but stored as a user setting because it's evaluated client side to be able to use the client time instead of the maybe different server time)
|
||||||
|
|
||||||
|
# Stock settings
|
||||||
DefaultUserSetting('product_presets_location_id', -1); // Default location id for new products (-1 means no location is preset)
|
DefaultUserSetting('product_presets_location_id', -1); // Default location id for new products (-1 means no location is preset)
|
||||||
DefaultUserSetting('product_presets_product_group_id', -1); // Default product group id for new products (-1 means no product group is preset)
|
DefaultUserSetting('product_presets_product_group_id', -1); // Default product group id for new products (-1 means no product group is preset)
|
||||||
DefaultUserSetting('product_presets_qu_id', -1); // Default quantity unit id for new products (-1 means no quantity unit is preset)
|
DefaultUserSetting('product_presets_qu_id', -1); // Default quantity unit id for new products (-1 means no quantity unit is preset)
|
||||||
|
DefaultUserSetting('stock_expring_soon_days', 5);
|
||||||
|
DefaultUserSetting('stock_default_purchase_amount', 0);
|
||||||
|
DefaultUserSetting('stock_default_consume_amount', 1);
|
||||||
|
|
||||||
|
# Chores settings
|
||||||
|
DefaultUserSetting('chores_due_soon_days', 5);
|
||||||
|
|
||||||
|
# Batteries settings
|
||||||
|
DefaultUserSetting('batteries_due_soon_days', 5);
|
||||||
|
|
||||||
|
# Tasks settings
|
||||||
|
DefaultUserSetting('tasks_due_soon_days', 5);
|
||||||
|
|
||||||
# If the page should be automatically reloaded when there was
|
# If the page should be automatically reloaded when there was
|
||||||
# an external change
|
# an external change
|
||||||
@@ -71,13 +104,12 @@ DefaultUserSetting('show_clock_in_header', false);
|
|||||||
DefaultUserSetting('shopping_list_to_stock_workflow_auto_submit_when_prefilled', false);
|
DefaultUserSetting('shopping_list_to_stock_workflow_auto_submit_when_prefilled', false);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# Feature flags
|
# Feature flags
|
||||||
# grocy was initially about "stock management for your household", many other things
|
# grocy was initially about "stock management for your household", many other things
|
||||||
# came and still come by, because they are useful - here you can disable the parts
|
# came and still come by, because they are useful - here you can disable the parts
|
||||||
# which you don't need to have a less cluttered UI
|
# which you don't need to have a less cluttered UI
|
||||||
# (set the setting to "false" to disable the corresponding part, which should be self explanatory)
|
# (set the setting to "false" to disable the corresponding part, which should be self explanatory)
|
||||||
|
Setting('FEATURE_FLAG_STOCK', true);
|
||||||
Setting('FEATURE_FLAG_SHOPPINGLIST', true);
|
Setting('FEATURE_FLAG_SHOPPINGLIST', true);
|
||||||
Setting('FEATURE_FLAG_RECIPES', true);
|
Setting('FEATURE_FLAG_RECIPES', true);
|
||||||
Setting('FEATURE_FLAG_CHORES', true);
|
Setting('FEATURE_FLAG_CHORES', true);
|
||||||
@@ -85,3 +117,14 @@ Setting('FEATURE_FLAG_TASKS', true);
|
|||||||
Setting('FEATURE_FLAG_BATTERIES', true);
|
Setting('FEATURE_FLAG_BATTERIES', true);
|
||||||
Setting('FEATURE_FLAG_EQUIPMENT', true);
|
Setting('FEATURE_FLAG_EQUIPMENT', true);
|
||||||
Setting('FEATURE_FLAG_CALENDAR', true);
|
Setting('FEATURE_FLAG_CALENDAR', true);
|
||||||
|
|
||||||
|
|
||||||
|
# Sub feature flags
|
||||||
|
Setting('FEATURE_FLAG_STOCK_PRICE_TRACKING', true);
|
||||||
|
Setting('FEATURE_FLAG_STOCK_LOCATION_TRACKING', true);
|
||||||
|
Setting('FEATURE_FLAG_STOCK_BEST_BEFORE_DATE_TRACKING', true);
|
||||||
|
Setting('FEATURE_FLAG_STOCK_PRODUCT_OPENED_TRACKING', true);
|
||||||
|
|
||||||
|
|
||||||
|
# Feature settings
|
||||||
|
Setting('FEATURE_SETTING_STOCK_COUNT_OPENED_PRODUCTS_AGAINST_MINIMUM_STOCK_AMOUNT', true); // When set to false, opened products will not be considered for minimum stock amounts
|
||||||
|
@@ -16,27 +16,21 @@ class BaseController
|
|||||||
$localizationService = new LocalizationService(GROCY_CULTURE);
|
$localizationService = new LocalizationService(GROCY_CULTURE);
|
||||||
$this->LocalizationService = $localizationService;
|
$this->LocalizationService = $localizationService;
|
||||||
|
|
||||||
if (GROCY_MODE === 'prerelease')
|
$applicationService = new ApplicationService();
|
||||||
{
|
$versionInfo = $applicationService->GetInstalledVersion();
|
||||||
$commitHash = trim(exec('git log --pretty="%h" -n1 HEAD'));
|
$container->view->set('version', $versionInfo->Version);
|
||||||
$commitDate = trim(exec('git log --date=iso --pretty="%cd" -n1 HEAD'));
|
$container->view->set('releaseDate', $versionInfo->ReleaseDate);
|
||||||
|
|
||||||
$container->view->set('version', "pre-release-$commitHash");
|
|
||||||
$container->view->set('releaseDate', \substr($commitDate, 0, 19));
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
$applicationService = new ApplicationService();
|
|
||||||
$versionInfo = $applicationService->GetInstalledVersion();
|
|
||||||
$container->view->set('version', $versionInfo->Version);
|
|
||||||
$container->view->set('releaseDate', $versionInfo->ReleaseDate);
|
|
||||||
}
|
|
||||||
|
|
||||||
$container->view->set('localizationStrings', $localizationService->GetCurrentCultureLocalizations());
|
$container->view->set('__t', function(string $text, ...$placeholderValues) use($localizationService)
|
||||||
$container->view->set('L', function($text, ...$placeholderValues) use($localizationService)
|
|
||||||
{
|
{
|
||||||
return $localizationService->Localize($text, ...$placeholderValues);
|
return $localizationService->__t($text, $placeholderValues);
|
||||||
});
|
});
|
||||||
|
$container->view->set('__n', function($number, $singularForm, $pluralForm) use($localizationService)
|
||||||
|
{
|
||||||
|
return $localizationService->__n($number, $singularForm, $pluralForm);
|
||||||
|
});
|
||||||
|
$container->view->set('GettextPo', $localizationService->GetPoAsJsonString());
|
||||||
|
|
||||||
$container->view->set('U', function($relativePath, $isResource = false) use($container)
|
$container->view->set('U', function($relativePath, $isResource = false) use($container)
|
||||||
{
|
{
|
||||||
return $container->UrlManager->ConstructUrl($relativePath, $isResource);
|
return $container->UrlManager->ConstructUrl($relativePath, $isResource);
|
||||||
@@ -59,6 +53,8 @@ class BaseController
|
|||||||
}
|
}
|
||||||
$container->view->set('featureFlags', $constants);
|
$container->view->set('featureFlags', $constants);
|
||||||
|
|
||||||
|
$container->view->set('userentitiesForSidebar', $this->Database->userentities()->where('show_in_sidebar_menu = 1')->orderBy('name'));
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
$usersService = new UsersService();
|
$usersService = new UsersService();
|
||||||
@@ -66,6 +62,10 @@ class BaseController
|
|||||||
{
|
{
|
||||||
$container->view->set('userSettings', $usersService->GetUserSettings(GROCY_USER_ID));
|
$container->view->set('userSettings', $usersService->GetUserSettings(GROCY_USER_ID));
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$container->view->set('userSettings', null);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
catch (\Exception $ex)
|
catch (\Exception $ex)
|
||||||
{
|
{
|
||||||
|
@@ -3,6 +3,8 @@
|
|||||||
namespace Grocy\Controllers;
|
namespace Grocy\Controllers;
|
||||||
|
|
||||||
use \Grocy\Services\BatteriesService;
|
use \Grocy\Services\BatteriesService;
|
||||||
|
use \Grocy\Services\UsersService;
|
||||||
|
use \Grocy\Services\UserfieldsService;
|
||||||
|
|
||||||
class BatteriesController extends BaseController
|
class BatteriesController extends BaseController
|
||||||
{
|
{
|
||||||
@@ -10,16 +12,23 @@ class BatteriesController extends BaseController
|
|||||||
{
|
{
|
||||||
parent::__construct($container);
|
parent::__construct($container);
|
||||||
$this->BatteriesService = new BatteriesService();
|
$this->BatteriesService = new BatteriesService();
|
||||||
|
$this->UserfieldsService = new UserfieldsService();
|
||||||
}
|
}
|
||||||
|
|
||||||
protected $BatteriesService;
|
protected $BatteriesService;
|
||||||
|
protected $UserfieldsService;
|
||||||
|
|
||||||
public function Overview(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function Overview(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
|
$usersService = new UsersService();
|
||||||
|
$nextXDays = $usersService->GetUserSettings(GROCY_USER_ID)['batteries_due_soon_days'];
|
||||||
|
|
||||||
return $this->AppContainer->view->render($response, 'batteriesoverview', [
|
return $this->AppContainer->view->render($response, 'batteriesoverview', [
|
||||||
'batteries' => $this->Database->batteries()->orderBy('name'),
|
'batteries' => $this->Database->batteries()->orderBy('name'),
|
||||||
'current' => $this->BatteriesService->GetCurrent(),
|
'current' => $this->BatteriesService->GetCurrent(),
|
||||||
'nextXDays' => 5
|
'nextXDays' => $nextXDays,
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('batteries'),
|
||||||
|
'userfieldValues' => $this->UserfieldsService->GetAllValues('batteries')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -33,7 +42,9 @@ class BatteriesController extends BaseController
|
|||||||
public function BatteriesList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function BatteriesList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'batteries', [
|
return $this->AppContainer->view->render($response, 'batteries', [
|
||||||
'batteries' => $this->Database->batteries()->orderBy('name')
|
'batteries' => $this->Database->batteries()->orderBy('name'),
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('batteries'),
|
||||||
|
'userfieldValues' => $this->UserfieldsService->GetAllValues('batteries')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -42,14 +53,16 @@ class BatteriesController extends BaseController
|
|||||||
if ($args['batteryId'] == 'new')
|
if ($args['batteryId'] == 'new')
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'batteryform', [
|
return $this->AppContainer->view->render($response, 'batteryform', [
|
||||||
'mode' => 'create'
|
'mode' => 'create',
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('batteries')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'batteryform', [
|
return $this->AppContainer->view->render($response, 'batteryform', [
|
||||||
'battery' => $this->Database->batteries($args['batteryId']),
|
'battery' => $this->Database->batteries($args['batteryId']),
|
||||||
'mode' => 'edit'
|
'mode' => 'edit',
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('batteries')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -61,4 +74,9 @@ class BatteriesController extends BaseController
|
|||||||
'batteries' => $this->Database->batteries()->orderBy('name')
|
'batteries' => $this->Database->batteries()->orderBy('name')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function BatteriesSettings(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
return $this->AppContainer->view->render($response, 'batteriessettings');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@@ -21,7 +21,7 @@ class ChoresApiController extends BaseApiController
|
|||||||
try
|
try
|
||||||
{
|
{
|
||||||
$trackedTime = date('Y-m-d H:i:s');
|
$trackedTime = date('Y-m-d H:i:s');
|
||||||
if (array_key_exists('tracked_time', $requestBody) && IsIsoDateTime($requestBody['tracked_time']))
|
if (array_key_exists('tracked_time', $requestBody) && (IsIsoDateTime($requestBody['tracked_time']) || IsIsoDate($requestBody['tracked_time'])))
|
||||||
{
|
{
|
||||||
$trackedTime = $requestBody['tracked_time'];
|
$trackedTime = $requestBody['tracked_time'];
|
||||||
}
|
}
|
||||||
@@ -70,4 +70,37 @@ class ChoresApiController extends BaseApiController
|
|||||||
return $this->GenericErrorResponse($response, $ex->getMessage());
|
return $this->GenericErrorResponse($response, $ex->getMessage());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function CalculateNextExecutionAssignments(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
$requestBody = $request->getParsedBody();
|
||||||
|
|
||||||
|
$choreId = null;
|
||||||
|
if (array_key_exists('chore_id', $requestBody) && !empty($requestBody['chore_id']) && is_numeric($requestBody['chore_id']))
|
||||||
|
{
|
||||||
|
$choreId = intval($requestBody['chore_id']);
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($choreId === null)
|
||||||
|
{
|
||||||
|
$chores = $this->Database->chores();
|
||||||
|
foreach ($chores as $chore)
|
||||||
|
{
|
||||||
|
$this->ChoresService->CalculateNextExecutionAssignment($chore->id);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$this->ChoresService->CalculateNextExecutionAssignment($choreId);
|
||||||
|
}
|
||||||
|
|
||||||
|
return $this->EmptyApiResponse($response);
|
||||||
|
}
|
||||||
|
catch (\Exception $ex)
|
||||||
|
{
|
||||||
|
return $this->GenericErrorResponse($response, $ex->getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@@ -3,6 +3,8 @@
|
|||||||
namespace Grocy\Controllers;
|
namespace Grocy\Controllers;
|
||||||
|
|
||||||
use \Grocy\Services\ChoresService;
|
use \Grocy\Services\ChoresService;
|
||||||
|
use \Grocy\Services\UsersService;
|
||||||
|
use \Grocy\Services\UserfieldsService;
|
||||||
|
|
||||||
class ChoresController extends BaseController
|
class ChoresController extends BaseController
|
||||||
{
|
{
|
||||||
@@ -10,16 +12,24 @@ class ChoresController extends BaseController
|
|||||||
{
|
{
|
||||||
parent::__construct($container);
|
parent::__construct($container);
|
||||||
$this->ChoresService = new ChoresService();
|
$this->ChoresService = new ChoresService();
|
||||||
|
$this->UserfieldsService = new UserfieldsService();
|
||||||
}
|
}
|
||||||
|
|
||||||
protected $ChoresService;
|
protected $ChoresService;
|
||||||
|
protected $UserfieldsService;
|
||||||
|
|
||||||
public function Overview(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function Overview(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
|
$usersService = new UsersService();
|
||||||
|
$nextXDays = $usersService->GetUserSettings(GROCY_USER_ID)['chores_due_soon_days'];
|
||||||
|
|
||||||
return $this->AppContainer->view->render($response, 'choresoverview', [
|
return $this->AppContainer->view->render($response, 'choresoverview', [
|
||||||
'chores' => $this->Database->chores()->orderBy('name'),
|
'chores' => $this->Database->chores()->orderBy('name'),
|
||||||
'currentChores' => $this->ChoresService->GetCurrent(),
|
'currentChores' => $this->ChoresService->GetCurrent(),
|
||||||
'nextXDays' => 5
|
'nextXDays' => $nextXDays,
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('chores'),
|
||||||
|
'userfieldValues' => $this->UserfieldsService->GetAllValues('chores'),
|
||||||
|
'users' => $usersService->GetUsersAsDto()
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -34,7 +44,9 @@ class ChoresController extends BaseController
|
|||||||
public function ChoresList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function ChoresList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'chores', [
|
return $this->AppContainer->view->render($response, 'chores', [
|
||||||
'chores' => $this->Database->chores()->orderBy('name')
|
'chores' => $this->Database->chores()->orderBy('name'),
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('chores'),
|
||||||
|
'userfieldValues' => $this->UserfieldsService->GetAllValues('chores')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -49,20 +61,36 @@ class ChoresController extends BaseController
|
|||||||
|
|
||||||
public function ChoreEditForm(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function ChoreEditForm(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
|
$usersService = new UsersService();
|
||||||
|
$users = $usersService->GetUsersAsDto();
|
||||||
|
|
||||||
if ($args['choreId'] == 'new')
|
if ($args['choreId'] == 'new')
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'choreform', [
|
return $this->AppContainer->view->render($response, 'choreform', [
|
||||||
'periodTypes' => GetClassConstants('\Grocy\Services\ChoresService'),
|
'periodTypes' => GetClassConstants('\Grocy\Services\ChoresService', 'CHORE_PERIOD_TYPE_'),
|
||||||
'mode' => 'create'
|
'mode' => 'create',
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('chores'),
|
||||||
|
'assignmentTypes' => GetClassConstants('\Grocy\Services\ChoresService', 'CHORE_ASSIGNMENT_TYPE_'),
|
||||||
|
'users' => $users,
|
||||||
|
'products' => $this->Database->products()->orderBy('name')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'choreform', [
|
return $this->AppContainer->view->render($response, 'choreform', [
|
||||||
'chore' => $this->Database->chores($args['choreId']),
|
'chore' => $this->Database->chores($args['choreId']),
|
||||||
'periodTypes' => GetClassConstants('\Grocy\Services\ChoresService'),
|
'periodTypes' => GetClassConstants('\Grocy\Services\ChoresService', 'CHORE_PERIOD_TYPE_'),
|
||||||
'mode' => 'edit'
|
'mode' => 'edit',
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('chores'),
|
||||||
|
'assignmentTypes' => GetClassConstants('\Grocy\Services\ChoresService', 'CHORE_ASSIGNMENT_TYPE_'),
|
||||||
|
'users' => $users,
|
||||||
|
'products' => $this->Database->products()->orderBy('name')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function ChoresSettings(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
return $this->AppContainer->view->render($response, 'choressettings');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@@ -2,13 +2,24 @@
|
|||||||
|
|
||||||
namespace Grocy\Controllers;
|
namespace Grocy\Controllers;
|
||||||
|
|
||||||
|
use \Grocy\Services\UserfieldsService;
|
||||||
|
|
||||||
class EquipmentController extends BaseController
|
class EquipmentController extends BaseController
|
||||||
{
|
{
|
||||||
|
public function __construct(\Slim\Container $container)
|
||||||
|
{
|
||||||
|
parent::__construct($container);
|
||||||
|
$this->UserfieldsService = new UserfieldsService();
|
||||||
|
}
|
||||||
|
|
||||||
|
protected $UserfieldsService;
|
||||||
|
|
||||||
public function Overview(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function Overview(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'equipment', [
|
return $this->AppContainer->view->render($response, 'equipment', [
|
||||||
'equipment' => $this->Database->equipment()->orderBy('name')
|
'equipment' => $this->Database->equipment()->orderBy('name'),
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('equipment'),
|
||||||
|
'userfieldValues' => $this->UserfieldsService->GetAllValues('equipment')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -17,14 +28,16 @@ class EquipmentController extends BaseController
|
|||||||
if ($args['equipmentId'] == 'new')
|
if ($args['equipmentId'] == 'new')
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'equipmentform', [
|
return $this->AppContainer->view->render($response, 'equipmentform', [
|
||||||
'mode' => 'create'
|
'mode' => 'create',
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('equipment')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'equipmentform', [
|
return $this->AppContainer->view->render($response, 'equipmentform', [
|
||||||
'equipment' => $this->Database->equipment($args['equipmentId']),
|
'equipment' => $this->Database->equipment($args['equipmentId']),
|
||||||
'mode' => 'edit'
|
'mode' => 'edit',
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('equipment')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -51,7 +51,32 @@ class FilesApiController extends BaseApiController
|
|||||||
throw new \Exception('Invalid filename');
|
throw new \Exception('Invalid filename');
|
||||||
}
|
}
|
||||||
|
|
||||||
$filePath = $this->FilesService->GetFilePath($args['group'], $fileName);
|
$forceServeAs = null;
|
||||||
|
if (isset($request->getQueryParams()['force_serve_as']) && !empty($request->getQueryParams()['force_serve_as']))
|
||||||
|
{
|
||||||
|
$forceServeAs = $request->getQueryParams()['force_serve_as'];
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($forceServeAs == FilesService::FILE_SERVE_TYPE_PICTURE)
|
||||||
|
{
|
||||||
|
$bestFitHeight = null;
|
||||||
|
if (isset($request->getQueryParams()['best_fit_height']) && !empty($request->getQueryParams()['best_fit_height']) && is_numeric($request->getQueryParams()['best_fit_height']))
|
||||||
|
{
|
||||||
|
$bestFitHeight = $request->getQueryParams()['best_fit_height'];
|
||||||
|
}
|
||||||
|
|
||||||
|
$bestFitWidth = null;
|
||||||
|
if (isset($request->getQueryParams()['best_fit_width']) && !empty($request->getQueryParams()['best_fit_width']) && is_numeric($request->getQueryParams()['best_fit_width']))
|
||||||
|
{
|
||||||
|
$bestFitWidth = $request->getQueryParams()['best_fit_width'];
|
||||||
|
}
|
||||||
|
|
||||||
|
$filePath = $this->FilesService->DownscaleImage($args['group'], $fileName, $bestFitHeight, $bestFitWidth);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$filePath = $this->FilesService->GetFilePath($args['group'], $fileName);
|
||||||
|
}
|
||||||
|
|
||||||
if (file_exists($filePath))
|
if (file_exists($filePath))
|
||||||
{
|
{
|
||||||
|
@@ -2,8 +2,18 @@
|
|||||||
|
|
||||||
namespace Grocy\Controllers;
|
namespace Grocy\Controllers;
|
||||||
|
|
||||||
|
use \Grocy\Services\UserfieldsService;
|
||||||
|
|
||||||
class GenericEntityApiController extends BaseApiController
|
class GenericEntityApiController extends BaseApiController
|
||||||
{
|
{
|
||||||
|
public function __construct(\Slim\Container $container)
|
||||||
|
{
|
||||||
|
parent::__construct($container);
|
||||||
|
$this->UserfieldsService = new UserfieldsService();
|
||||||
|
}
|
||||||
|
|
||||||
|
protected $UserfieldsService;
|
||||||
|
|
||||||
public function GetObjects(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function GetObjects(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
if ($this->IsValidEntity($args['entity']) && !$this->IsEntityWithPreventedListing($args['entity']))
|
if ($this->IsValidEntity($args['entity']) && !$this->IsEntityWithPreventedListing($args['entity']))
|
||||||
@@ -44,7 +54,9 @@ class GenericEntityApiController extends BaseApiController
|
|||||||
$newRow = $this->Database->{$args['entity']}()->createRow($requestBody);
|
$newRow = $this->Database->{$args['entity']}()->createRow($requestBody);
|
||||||
$newRow->save();
|
$newRow->save();
|
||||||
$success = $newRow->isClean();
|
$success = $newRow->isClean();
|
||||||
return $this->EmptyApiResponse($response);
|
return $this->ApiResponse(array(
|
||||||
|
'created_object_id' => $this->Database->lastInsertId()
|
||||||
|
));
|
||||||
}
|
}
|
||||||
catch (\Exception $ex)
|
catch (\Exception $ex)
|
||||||
{
|
{
|
||||||
@@ -101,6 +113,57 @@ class GenericEntityApiController extends BaseApiController
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function SearchObjects(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
if ($this->IsValidEntity($args['entity']) && !$this->IsEntityWithPreventedListing($args['entity']))
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
return $this->ApiResponse($this->Database->{$args['entity']}()->where('name LIKE ?', '%' . $args['searchString'] . '%'));
|
||||||
|
}
|
||||||
|
catch (\PDOException $ex)
|
||||||
|
{
|
||||||
|
return $this->GenericErrorResponse($response, 'The given entity has no field "name"');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
return $this->GenericErrorResponse($response, 'Entity does not exist or is not exposed');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public function GetUserfields(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
return $this->ApiResponse($this->UserfieldsService->GetValues($args['entity'], $args['objectId']));
|
||||||
|
}
|
||||||
|
catch (\Exception $ex)
|
||||||
|
{
|
||||||
|
return $this->GenericErrorResponse($response, $ex->getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public function SetUserfields(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
$requestBody = $request->getParsedBody();
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if ($requestBody === null)
|
||||||
|
{
|
||||||
|
throw new \Exception('Request body could not be parsed (probably invalid JSON format or missing/wrong Content-Type header)');
|
||||||
|
}
|
||||||
|
|
||||||
|
$this->UserfieldsService->SetValues($args['entity'], $args['objectId'], $requestBody);
|
||||||
|
return $this->EmptyApiResponse($response);
|
||||||
|
}
|
||||||
|
catch (\Exception $ex)
|
||||||
|
{
|
||||||
|
return $this->GenericErrorResponse($response, $ex->getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
private function IsValidEntity($entity)
|
private function IsValidEntity($entity)
|
||||||
{
|
{
|
||||||
return in_array($entity, $this->OpenApiSpec->components->internalSchemas->ExposedEntity->enum);
|
return in_array($entity, $this->OpenApiSpec->components->internalSchemas->ExposedEntity->enum);
|
||||||
|
104
controllers/GenericEntityController.php
Normal file
104
controllers/GenericEntityController.php
Normal file
@@ -0,0 +1,104 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace Grocy\Controllers;
|
||||||
|
|
||||||
|
use \Grocy\Services\UserfieldsService;
|
||||||
|
|
||||||
|
class GenericEntityController extends BaseController
|
||||||
|
{
|
||||||
|
public function __construct(\Slim\Container $container)
|
||||||
|
{
|
||||||
|
parent::__construct($container);
|
||||||
|
$this->UserfieldsService = new UserfieldsService();
|
||||||
|
}
|
||||||
|
|
||||||
|
protected $UserfieldsService;
|
||||||
|
|
||||||
|
public function UserfieldsList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
return $this->AppContainer->view->render($response, 'userfields', [
|
||||||
|
'userfields' => $this->UserfieldsService->GetAllFields(),
|
||||||
|
'entities' => $this->UserfieldsService->GetEntities()
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
|
||||||
|
public function UserentitiesList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
return $this->AppContainer->view->render($response, 'userentities', [
|
||||||
|
'userentities' => $this->Database->userentities()->orderBy('name')
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
|
||||||
|
public function UserobjectsList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
$userentity = $this->Database->userentities()->where('name = :1', $args['userentityName'])->fetch();
|
||||||
|
|
||||||
|
return $this->AppContainer->view->render($response, 'userobjects', [
|
||||||
|
'userentity' => $userentity,
|
||||||
|
'userobjects' => $this->Database->userobjects()->where('userentity_id = :1', $userentity->id),
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('userentity-' . $args['userentityName']),
|
||||||
|
'userfieldValues' => $this->UserfieldsService->GetAllValues('userentity-' . $args['userentityName'])
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
|
||||||
|
public function UserfieldEditForm(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
if ($args['userfieldId'] == 'new')
|
||||||
|
{
|
||||||
|
return $this->AppContainer->view->render($response, 'userfieldform', [
|
||||||
|
'mode' => 'create',
|
||||||
|
'userfieldTypes' => $this->UserfieldsService->GetFieldTypes(),
|
||||||
|
'entities' => $this->UserfieldsService->GetEntities()
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
return $this->AppContainer->view->render($response, 'userfieldform', [
|
||||||
|
'mode' => 'edit',
|
||||||
|
'userfield' => $this->UserfieldsService->GetField($args['userfieldId']),
|
||||||
|
'userfieldTypes' => $this->UserfieldsService->GetFieldTypes(),
|
||||||
|
'entities' => $this->UserfieldsService->GetEntities()
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public function UserentityEditForm(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
if ($args['userentityId'] == 'new')
|
||||||
|
{
|
||||||
|
return $this->AppContainer->view->render($response, 'userentityform', [
|
||||||
|
'mode' => 'create'
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
return $this->AppContainer->view->render($response, 'userentityform', [
|
||||||
|
'mode' => 'edit',
|
||||||
|
'userentity' => $this->Database->userentities($args['userentityId'])
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public function UserobjectEditForm(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
$userentity = $this->Database->userentities()->where('name = :1', $args['userentityName'])->fetch();
|
||||||
|
|
||||||
|
if ($args['userobjectId'] == 'new')
|
||||||
|
{
|
||||||
|
return $this->AppContainer->view->render($response, 'userobjectform', [
|
||||||
|
'userentity' => $userentity,
|
||||||
|
'mode' => 'create',
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('userentity-' . $args['userentityName'])
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
return $this->AppContainer->view->render($response, 'userobjectform', [
|
||||||
|
'userentity' => $userentity,
|
||||||
|
'mode' => 'edit',
|
||||||
|
'userobject' => $this->Database->userobjects($args['userobjectId']),
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('userentity-' . $args['userentityName'])
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@@ -30,7 +30,7 @@ class LoginController extends BaseController
|
|||||||
if ($user !== null && password_verify($inputPassword, $user->password))
|
if ($user !== null && password_verify($inputPassword, $user->password))
|
||||||
{
|
{
|
||||||
$sessionKey = $this->SessionService->CreateSession($user->id, $stayLoggedInPermanently);
|
$sessionKey = $this->SessionService->CreateSession($user->id, $stayLoggedInPermanently);
|
||||||
setcookie($this->SessionCookieName, $sessionKey, intval(time() + 31220640000)); // Cookie expires in 999 years, but session validity is up to SessionService
|
setcookie($this->SessionCookieName, $sessionKey, PHP_INT_SIZE == 4 ? PHP_INT_MAX : PHP_INT_MAX>>32); // Cookie expires never, but session validity is up to SessionService
|
||||||
|
|
||||||
if (password_needs_rehash($user->password, PASSWORD_DEFAULT))
|
if (password_needs_rehash($user->password, PASSWORD_DEFAULT))
|
||||||
{
|
{
|
||||||
|
@@ -1,43 +1,68 @@
|
|||||||
<?php
|
<?php
|
||||||
|
|
||||||
namespace Grocy\Controllers;
|
namespace Grocy\Controllers;
|
||||||
|
|
||||||
use \Grocy\Services\RecipesService;
|
use \Grocy\Services\RecipesService;
|
||||||
|
|
||||||
class RecipesApiController extends BaseApiController
|
class RecipesApiController extends BaseApiController
|
||||||
{
|
{
|
||||||
public function __construct(\Slim\Container $container)
|
public function __construct(\Slim\Container $container)
|
||||||
{
|
{
|
||||||
parent::__construct($container);
|
parent::__construct($container);
|
||||||
$this->RecipesService = new RecipesService();
|
$this->RecipesService = new RecipesService();
|
||||||
}
|
}
|
||||||
|
|
||||||
protected $RecipesService;
|
protected $RecipesService;
|
||||||
|
|
||||||
public function AddNotFulfilledProductsToShoppingList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function AddNotFulfilledProductsToShoppingList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
$requestBody = $request->getParsedBody();
|
$requestBody = $request->getParsedBody();
|
||||||
$excludedProductIds = null;
|
$excludedProductIds = null;
|
||||||
|
|
||||||
if ($requestBody !== null && array_key_exists('excludedProductIds', $requestBody))
|
if ($requestBody !== null && array_key_exists('excludedProductIds', $requestBody))
|
||||||
{
|
{
|
||||||
$excludedProductIds = $requestBody['excludedProductIds'];
|
$excludedProductIds = $requestBody['excludedProductIds'];
|
||||||
}
|
}
|
||||||
|
|
||||||
$this->RecipesService->AddNotFulfilledProductsToShoppingList($args['recipeId'], $excludedProductIds);
|
$this->RecipesService->AddNotFulfilledProductsToShoppingList($args['recipeId'], $excludedProductIds);
|
||||||
return $this->EmptyApiResponse($response);
|
return $this->EmptyApiResponse($response);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function ConsumeRecipe(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function ConsumeRecipe(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
$this->RecipesService->ConsumeRecipe($args['recipeId']);
|
$this->RecipesService->ConsumeRecipe($args['recipeId']);
|
||||||
return $this->EmptyApiResponse($response);
|
return $this->EmptyApiResponse($response);
|
||||||
}
|
}
|
||||||
catch (\Exception $ex)
|
catch (\Exception $ex)
|
||||||
{
|
{
|
||||||
return $this->GenericErrorResponse($response, $ex->getMessage());
|
return $this->GenericErrorResponse($response, $ex->getMessage());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
public function GetRecipeFulfillment(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if(!isset($args['recipeId']))
|
||||||
|
{
|
||||||
|
return $this->ApiResponse($this->RecipesService->GetRecipesResolved());
|
||||||
|
}
|
||||||
|
|
||||||
|
$recipeResolved = FindObjectInArrayByPropertyValue($this->RecipesService->GetRecipesResolved(), 'recipe_id', $args['recipeId']);
|
||||||
|
if(!$recipeResolved)
|
||||||
|
{
|
||||||
|
throw new \Exception('Recipe does not exist');
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
return $this->ApiResponse($recipeResolved);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (\Exception $ex)
|
||||||
|
{
|
||||||
|
return $this->GenericErrorResponse($response, $ex->getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@@ -3,6 +3,7 @@
|
|||||||
namespace Grocy\Controllers;
|
namespace Grocy\Controllers;
|
||||||
|
|
||||||
use \Grocy\Services\RecipesService;
|
use \Grocy\Services\RecipesService;
|
||||||
|
use \Grocy\Services\UserfieldsService;
|
||||||
|
|
||||||
class RecipesController extends BaseController
|
class RecipesController extends BaseController
|
||||||
{
|
{
|
||||||
@@ -10,13 +11,22 @@ class RecipesController extends BaseController
|
|||||||
{
|
{
|
||||||
parent::__construct($container);
|
parent::__construct($container);
|
||||||
$this->RecipesService = new RecipesService();
|
$this->RecipesService = new RecipesService();
|
||||||
|
$this->UserfieldsService = new UserfieldsService();
|
||||||
}
|
}
|
||||||
|
|
||||||
protected $RecipesService;
|
protected $RecipesService;
|
||||||
|
protected $UserfieldsService;
|
||||||
|
|
||||||
public function Overview(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function Overview(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
$recipes = $this->Database->recipes()->orderBy('name');
|
if (isset($request->getQueryParams()['include-internal']))
|
||||||
|
{
|
||||||
|
$recipes = $this->Database->recipes()->orderBy('name');
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$recipes = $this->Database->recipes()->where('type', RecipesService::RECIPE_TYPE_NORMAL)->orderBy('name');
|
||||||
|
}
|
||||||
$recipesResolved = $this->RecipesService->GetRecipesResolved();
|
$recipesResolved = $this->RecipesService->GetRecipesResolved();
|
||||||
|
|
||||||
$selectedRecipe = null;
|
$selectedRecipe = null;
|
||||||
@@ -53,11 +63,15 @@ class RecipesController extends BaseController
|
|||||||
'selectedRecipe' => $selectedRecipe,
|
'selectedRecipe' => $selectedRecipe,
|
||||||
'selectedRecipePositionsResolved' => $selectedRecipePositionsResolved,
|
'selectedRecipePositionsResolved' => $selectedRecipePositionsResolved,
|
||||||
'products' => $this->Database->products(),
|
'products' => $this->Database->products(),
|
||||||
'quantityunits' => $this->Database->quantity_units(),
|
'quantityUnits' => $this->Database->quantity_units(),
|
||||||
'selectedRecipeSubRecipes' => $selectedRecipeSubRecipes,
|
'selectedRecipeSubRecipes' => $selectedRecipeSubRecipes,
|
||||||
'selectedRecipeSubRecipesPositions' => $selectedRecipeSubRecipesPositions,
|
'selectedRecipeSubRecipesPositions' => $selectedRecipeSubRecipesPositions,
|
||||||
'includedRecipeIdsAbsolute' => $includedRecipeIdsAbsolute,
|
'includedRecipeIdsAbsolute' => $includedRecipeIdsAbsolute,
|
||||||
'selectedRecipeTotalCosts' => FindObjectInArrayByPropertyValue($recipesResolved, 'recipe_id', $selectedRecipe->id)->costs
|
'selectedRecipeTotalCosts' => FindObjectInArrayByPropertyValue($recipesResolved, 'recipe_id', $selectedRecipe->id)->costs,
|
||||||
|
'selectedRecipeTotalCalories' => FindObjectInArrayByPropertyValue($recipesResolved, 'recipe_id', $selectedRecipe->id)->calories,
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('recipes'),
|
||||||
|
'userfieldValues' => $this->UserfieldsService->GetAllValues('recipes'),
|
||||||
|
'quantityUnitConversionsResolved' => $this->Database->quantity_unit_conversions_resolved()
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -66,8 +80,8 @@ class RecipesController extends BaseController
|
|||||||
$recipeId = $args['recipeId'];
|
$recipeId = $args['recipeId'];
|
||||||
if ($recipeId == 'new')
|
if ($recipeId == 'new')
|
||||||
{
|
{
|
||||||
$newRecipe = $this->Database->recipes()->createRow(array(
|
$newRecipe = $this->Database->recipes()->where('type', RecipesService::RECIPE_TYPE_NORMAL)->createRow(array(
|
||||||
'name' => $this->LocalizationService->Localize('New recipe')
|
'name' => $this->LocalizationService->__t('New recipe')
|
||||||
));
|
));
|
||||||
$newRecipe->save();
|
$newRecipe->save();
|
||||||
|
|
||||||
@@ -82,8 +96,10 @@ class RecipesController extends BaseController
|
|||||||
'quantityunits' => $this->Database->quantity_units(),
|
'quantityunits' => $this->Database->quantity_units(),
|
||||||
'recipePositionsResolved' => $this->RecipesService->GetRecipesPosResolved(),
|
'recipePositionsResolved' => $this->RecipesService->GetRecipesPosResolved(),
|
||||||
'recipesResolved' => $this->RecipesService->GetRecipesResolved(),
|
'recipesResolved' => $this->RecipesService->GetRecipesResolved(),
|
||||||
'recipes' => $this->Database->recipes()->orderBy('name'),
|
'recipes' => $this->Database->recipes()->where('type', RecipesService::RECIPE_TYPE_NORMAL)->orderBy('name'),
|
||||||
'recipeNestings' => $this->Database->recipes_nestings()->where('recipe_id', $recipeId)
|
'recipeNestings' => $this->Database->recipes_nestings()->where('recipe_id', $recipeId),
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('recipes'),
|
||||||
|
'quantityUnitConversionsResolved' => $this->Database->quantity_unit_conversions_resolved()
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -94,8 +110,10 @@ class RecipesController extends BaseController
|
|||||||
return $this->AppContainer->view->render($response, 'recipeposform', [
|
return $this->AppContainer->view->render($response, 'recipeposform', [
|
||||||
'mode' => 'create',
|
'mode' => 'create',
|
||||||
'recipe' => $this->Database->recipes($args['recipeId']),
|
'recipe' => $this->Database->recipes($args['recipeId']),
|
||||||
|
'recipePos' => new \stdClass(),
|
||||||
'products' => $this->Database->products()->orderBy('name'),
|
'products' => $this->Database->products()->orderBy('name'),
|
||||||
'quantityUnits' => $this->Database->quantity_units()->orderBy('name')
|
'quantityUnits' => $this->Database->quantity_units()->orderBy('name'),
|
||||||
|
'quantityUnitConversionsResolved' => $this->Database->quantity_unit_conversions_resolved()
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@@ -105,8 +123,41 @@ class RecipesController extends BaseController
|
|||||||
'recipe' => $this->Database->recipes($args['recipeId']),
|
'recipe' => $this->Database->recipes($args['recipeId']),
|
||||||
'recipePos' => $this->Database->recipes_pos($args['recipePosId']),
|
'recipePos' => $this->Database->recipes_pos($args['recipePosId']),
|
||||||
'products' => $this->Database->products()->orderBy('name'),
|
'products' => $this->Database->products()->orderBy('name'),
|
||||||
'quantityUnits' => $this->Database->quantity_units()->orderBy('name')
|
'quantityUnits' => $this->Database->quantity_units()->orderBy('name'),
|
||||||
|
'quantityUnitConversionsResolved' => $this->Database->quantity_unit_conversions_resolved()
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function MealPlan(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
$recipes = $this->Database->recipes()->where('type', RecipesService::RECIPE_TYPE_NORMAL)->fetchAll();
|
||||||
|
|
||||||
|
$events = array();
|
||||||
|
foreach($this->Database->meal_plan() as $mealPlanEntry)
|
||||||
|
{
|
||||||
|
$recipe = FindObjectInArrayByPropertyValue($recipes, 'id', $mealPlanEntry['recipe_id']);
|
||||||
|
$title = '';
|
||||||
|
if ($recipe !== null)
|
||||||
|
{
|
||||||
|
$title = $recipe->name;
|
||||||
|
}
|
||||||
|
|
||||||
|
$events[] = array(
|
||||||
|
'id' => $mealPlanEntry['id'],
|
||||||
|
'title' => $title,
|
||||||
|
'start' => $mealPlanEntry['day'],
|
||||||
|
'date_format' => 'date',
|
||||||
|
'recipe' => json_encode($recipe),
|
||||||
|
'mealPlanEntry' => json_encode($mealPlanEntry)
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
return $this->AppContainer->view->render($response, 'mealplan', [
|
||||||
|
'fullcalendarEventSources' => $events,
|
||||||
|
'recipes' => $recipes,
|
||||||
|
'internalRecipes' => $this->Database->recipes()->whereNot('type', RecipesService::RECIPE_TYPE_NORMAL)->fetchAll(),
|
||||||
|
'recipesResolved' => $this->RecipesService->GetRecipesResolved()
|
||||||
|
]);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@@ -26,6 +26,19 @@ class StockApiController extends BaseApiController
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function ProductDetailsByBarcode(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
$productId = $this->StockService->GetProductIdFromBarcode($args['barcode']);
|
||||||
|
return $this->ApiResponse($this->StockService->GetProductDetails($productId));
|
||||||
|
}
|
||||||
|
catch (\Exception $ex)
|
||||||
|
{
|
||||||
|
return $this->GenericErrorResponse($response, $ex->getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public function ProductPriceHistory(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function ProductPriceHistory(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
@@ -54,7 +67,7 @@ class StockApiController extends BaseApiController
|
|||||||
throw new \Exception('An amount is required');
|
throw new \Exception('An amount is required');
|
||||||
}
|
}
|
||||||
|
|
||||||
$bestBeforeDate = date('Y-m-d');
|
$bestBeforeDate = null;
|
||||||
if (array_key_exists('best_before_date', $requestBody) && IsIsoDate($requestBody['best_before_date']))
|
if (array_key_exists('best_before_date', $requestBody) && IsIsoDate($requestBody['best_before_date']))
|
||||||
{
|
{
|
||||||
$bestBeforeDate = $requestBody['best_before_date'];
|
$bestBeforeDate = $requestBody['best_before_date'];
|
||||||
@@ -87,6 +100,19 @@ class StockApiController extends BaseApiController
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function AddProductByBarcode(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
$args['productId'] = $this->StockService->GetProductIdFromBarcode($args['barcode']);
|
||||||
|
return $this->AddProduct($request, $response, $args);
|
||||||
|
}
|
||||||
|
catch (\Exception $ex)
|
||||||
|
{
|
||||||
|
return $this->GenericErrorResponse($response, $ex->getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public function ConsumeProduct(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function ConsumeProduct(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
$requestBody = $request->getParsedBody();
|
$requestBody = $request->getParsedBody();
|
||||||
@@ -136,6 +162,19 @@ class StockApiController extends BaseApiController
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function ConsumeProductByBarcode(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
$args['productId'] = $this->StockService->GetProductIdFromBarcode($args['barcode']);
|
||||||
|
return $this->ConsumeProduct($request, $response, $args);
|
||||||
|
}
|
||||||
|
catch (\Exception $ex)
|
||||||
|
{
|
||||||
|
return $this->GenericErrorResponse($response, $ex->getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public function InventoryProduct(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function InventoryProduct(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
$requestBody = $request->getParsedBody();
|
$requestBody = $request->getParsedBody();
|
||||||
@@ -152,13 +191,25 @@ class StockApiController extends BaseApiController
|
|||||||
throw new \Exception('An new amount is required');
|
throw new \Exception('An new amount is required');
|
||||||
}
|
}
|
||||||
|
|
||||||
$bestBeforeDate = date('Y-m-d');
|
$bestBeforeDate = null;
|
||||||
if (array_key_exists('best_before_date', $requestBody) && IsIsoDate($requestBody['best_before_date']))
|
if (array_key_exists('best_before_date', $requestBody) && IsIsoDate($requestBody['best_before_date']))
|
||||||
{
|
{
|
||||||
$bestBeforeDate = $requestBody['best_before_date'];
|
$bestBeforeDate = $requestBody['best_before_date'];
|
||||||
}
|
}
|
||||||
|
|
||||||
$bookingId = $this->StockService->InventoryProduct($args['productId'], $requestBody['new_amount'], $bestBeforeDate);
|
$locationId = null;
|
||||||
|
if (array_key_exists('location_id', $requestBody) && is_numeric($requestBody['location_id']))
|
||||||
|
{
|
||||||
|
$locationId = $requestBody['location_id'];
|
||||||
|
}
|
||||||
|
|
||||||
|
$price = null;
|
||||||
|
if (array_key_exists('price', $requestBody) && is_numeric($requestBody['price']))
|
||||||
|
{
|
||||||
|
$price = $requestBody['price'];
|
||||||
|
}
|
||||||
|
|
||||||
|
$bookingId = $this->StockService->InventoryProduct($args['productId'], $requestBody['new_amount'], $bestBeforeDate, $locationId, $price);
|
||||||
return $this->ApiResponse($this->Database->stock_log($bookingId));
|
return $this->ApiResponse($this->Database->stock_log($bookingId));
|
||||||
}
|
}
|
||||||
catch (\Exception $ex)
|
catch (\Exception $ex)
|
||||||
@@ -167,6 +218,19 @@ class StockApiController extends BaseApiController
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function InventoryProductByBarcode(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
$args['productId'] = $this->StockService->GetProductIdFromBarcode($args['barcode']);
|
||||||
|
return $this->InventoryProduct($request, $response, $args);
|
||||||
|
}
|
||||||
|
catch (\Exception $ex)
|
||||||
|
{
|
||||||
|
return $this->GenericErrorResponse($response, $ex->getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public function OpenProduct(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function OpenProduct(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
$requestBody = $request->getParsedBody();
|
$requestBody = $request->getParsedBody();
|
||||||
@@ -198,6 +262,19 @@ class StockApiController extends BaseApiController
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function OpenProductByBarcode(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
$args['productId'] = $this->StockService->GetProductIdFromBarcode($args['barcode']);
|
||||||
|
return $this->OpenProduct($request, $response, $args);
|
||||||
|
}
|
||||||
|
catch (\Exception $ex)
|
||||||
|
{
|
||||||
|
return $this->GenericErrorResponse($response, $ex->getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public function CurrentStock(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function CurrentStock(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
return $this->ApiResponse($this->StockService->GetCurrentStock());
|
return $this->ApiResponse($this->StockService->GetCurrentStock());
|
||||||
@@ -223,14 +300,117 @@ class StockApiController extends BaseApiController
|
|||||||
|
|
||||||
public function AddMissingProductsToShoppingList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function AddMissingProductsToShoppingList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
$this->StockService->AddMissingProductsToShoppingList();
|
try
|
||||||
return $this->EmptyApiResponse($response);
|
{
|
||||||
|
$requestBody = $request->getParsedBody();
|
||||||
|
|
||||||
|
$listId = 1;
|
||||||
|
if (array_key_exists('list_id', $requestBody) && !empty($requestBody['list_id']) && is_numeric($requestBody['list_id']))
|
||||||
|
{
|
||||||
|
$listId = intval($requestBody['list_id']);
|
||||||
|
}
|
||||||
|
|
||||||
|
$this->StockService->AddMissingProductsToShoppingList($listId);
|
||||||
|
return $this->EmptyApiResponse($response);
|
||||||
|
}
|
||||||
|
catch (\Exception $ex)
|
||||||
|
{
|
||||||
|
return $this->GenericErrorResponse($response, $ex->getMessage());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public function ClearShoppingList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function ClearShoppingList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
$this->StockService->ClearShoppingList();
|
try
|
||||||
return $this->EmptyApiResponse($response);
|
{
|
||||||
|
$requestBody = $request->getParsedBody();
|
||||||
|
|
||||||
|
$listId = 1;
|
||||||
|
if (array_key_exists('list_id', $requestBody) && !empty($requestBody['list_id']) && is_numeric($requestBody['list_id']))
|
||||||
|
{
|
||||||
|
$listId = intval($requestBody['list_id']);
|
||||||
|
}
|
||||||
|
|
||||||
|
$this->StockService->ClearShoppingList($listId);
|
||||||
|
return $this->EmptyApiResponse($response);
|
||||||
|
}
|
||||||
|
catch (\Exception $ex)
|
||||||
|
{
|
||||||
|
return $this->GenericErrorResponse($response, $ex->getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public function AddItemToShoppingList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
$requestBody = $request->getParsedBody();
|
||||||
|
|
||||||
|
$listId = 1;
|
||||||
|
$amount = 1;
|
||||||
|
$productId = null;
|
||||||
|
if (array_key_exists('list_id', $requestBody) && !empty($requestBody['list_id']) && is_numeric($requestBody['list_id']))
|
||||||
|
{
|
||||||
|
$listId = intval($requestBody['list_id']);
|
||||||
|
}
|
||||||
|
if (array_key_exists('product_amount', $requestBody) && !empty($requestBody['product_amount']) && is_numeric($requestBody['product_amount']))
|
||||||
|
{
|
||||||
|
$amount = intval($requestBody['product_amount']);
|
||||||
|
}
|
||||||
|
if (array_key_exists('product_id', $requestBody) && !empty($requestBody['product_id']) && is_numeric($requestBody['product_id']))
|
||||||
|
{
|
||||||
|
$productId = intval($requestBody['product_id']);
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($productId == null)
|
||||||
|
{
|
||||||
|
throw new \Exception("No product id was supplied");
|
||||||
|
}
|
||||||
|
|
||||||
|
$this->StockService->AddProductToShoppingList($productId, $amount, $listId);
|
||||||
|
return $this->EmptyApiResponse($response);
|
||||||
|
}
|
||||||
|
catch (\Exception $ex)
|
||||||
|
{
|
||||||
|
return $this->GenericErrorResponse($response, $ex->getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public function RemoveItemFromShoppingList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
$requestBody = $request->getParsedBody();
|
||||||
|
|
||||||
|
$listId = 1;
|
||||||
|
$amount = 1;
|
||||||
|
$productId = null;
|
||||||
|
if (array_key_exists('list_id', $requestBody) && !empty($requestBody['list_id']) && is_numeric($requestBody['list_id']))
|
||||||
|
{
|
||||||
|
$listId = intval($requestBody['list_id']);
|
||||||
|
}
|
||||||
|
if (array_key_exists('product_amount', $requestBody) && !empty($requestBody['product_amount']) && is_numeric($requestBody['product_amount']))
|
||||||
|
{
|
||||||
|
$amount = intval($requestBody['product_amount']);
|
||||||
|
}
|
||||||
|
if (array_key_exists('product_id', $requestBody) && !empty($requestBody['product_id']) && is_numeric($requestBody['product_id']))
|
||||||
|
{
|
||||||
|
$productId = intval($requestBody['product_id']);
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($productId == null)
|
||||||
|
{
|
||||||
|
throw new \Exception("No product id was supplied");
|
||||||
|
}
|
||||||
|
|
||||||
|
$this->StockService->RemoveProductFromShoppingList($productId, $amount, $listId);
|
||||||
|
return $this->EmptyApiResponse($response);
|
||||||
|
}
|
||||||
|
catch (\Exception $ex)
|
||||||
|
{
|
||||||
|
return $this->GenericErrorResponse($response, $ex->getMessage());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public function ExternalBarcodeLookup(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function ExternalBarcodeLookup(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
@@ -268,4 +448,23 @@ class StockApiController extends BaseApiController
|
|||||||
{
|
{
|
||||||
return $this->ApiResponse($this->StockService->GetProductStockEntries($args['productId']));
|
return $this->ApiResponse($this->StockService->GetProductStockEntries($args['productId']));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function StockBooking(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
$stockLogRow = $this->Database->stock_log($args['bookingId']);
|
||||||
|
|
||||||
|
if ($stockLogRow === null)
|
||||||
|
{
|
||||||
|
throw new \Exception('Stock booking does not exist');
|
||||||
|
}
|
||||||
|
|
||||||
|
return $this->ApiResponse($stockLogRow);
|
||||||
|
}
|
||||||
|
catch (\Exception $ex)
|
||||||
|
{
|
||||||
|
return $this->GenericErrorResponse($response, $ex->getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@@ -3,6 +3,8 @@
|
|||||||
namespace Grocy\Controllers;
|
namespace Grocy\Controllers;
|
||||||
|
|
||||||
use \Grocy\Services\StockService;
|
use \Grocy\Services\StockService;
|
||||||
|
use \Grocy\Services\UsersService;
|
||||||
|
use \Grocy\Services\UserfieldsService;
|
||||||
|
|
||||||
class StockController extends BaseController
|
class StockController extends BaseController
|
||||||
{
|
{
|
||||||
@@ -11,12 +13,17 @@ class StockController extends BaseController
|
|||||||
{
|
{
|
||||||
parent::__construct($container);
|
parent::__construct($container);
|
||||||
$this->StockService = new StockService();
|
$this->StockService = new StockService();
|
||||||
|
$this->UserfieldsService = new UserfieldsService();
|
||||||
}
|
}
|
||||||
|
|
||||||
protected $StockService;
|
protected $StockService;
|
||||||
|
protected $UserfieldsService;
|
||||||
|
|
||||||
public function Overview(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function Overview(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
|
$usersService = new UsersService();
|
||||||
|
$nextXDays = $usersService->GetUserSettings(GROCY_USER_ID)['stock_expring_soon_days'];
|
||||||
|
|
||||||
return $this->AppContainer->view->render($response, 'stockoverview', [
|
return $this->AppContainer->view->render($response, 'stockoverview', [
|
||||||
'products' => $this->Database->products()->orderBy('name'),
|
'products' => $this->Database->products()->orderBy('name'),
|
||||||
'quantityunits' => $this->Database->quantity_units()->orderBy('name'),
|
'quantityunits' => $this->Database->quantity_units()->orderBy('name'),
|
||||||
@@ -24,8 +31,10 @@ class StockController extends BaseController
|
|||||||
'currentStock' => $this->StockService->GetCurrentStock(),
|
'currentStock' => $this->StockService->GetCurrentStock(),
|
||||||
'currentStockLocations' => $this->StockService->GetCurrentStockLocations(),
|
'currentStockLocations' => $this->StockService->GetCurrentStockLocations(),
|
||||||
'missingProducts' => $this->StockService->GetMissingProducts(),
|
'missingProducts' => $this->StockService->GetMissingProducts(),
|
||||||
'nextXDays' => 5,
|
'nextXDays' => $nextXDays,
|
||||||
'productGroups' => $this->Database->product_groups()->orderBy('name')
|
'productGroups' => $this->Database->product_groups()->orderBy('name'),
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('products'),
|
||||||
|
'userfieldValues' => $this->UserfieldsService->GetAllValues('products')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -48,18 +57,29 @@ class StockController extends BaseController
|
|||||||
public function Inventory(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function Inventory(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'inventory', [
|
return $this->AppContainer->view->render($response, 'inventory', [
|
||||||
'products' => $this->Database->products()->orderBy('name')
|
'products' => $this->Database->products()->orderBy('name'),
|
||||||
|
'locations' => $this->Database->locations()->orderBy('name')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function ShoppingList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function ShoppingList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
|
$listId = 1;
|
||||||
|
if (isset($request->getQueryParams()['list']))
|
||||||
|
{
|
||||||
|
$listId = $request->getQueryParams()['list'];
|
||||||
|
}
|
||||||
|
|
||||||
return $this->AppContainer->view->render($response, 'shoppinglist', [
|
return $this->AppContainer->view->render($response, 'shoppinglist', [
|
||||||
'listItems' => $this->Database->shopping_list(),
|
'listItems' => $this->Database->shopping_list()->where('shopping_list_id = :1', $listId),
|
||||||
'products' => $this->Database->products()->orderBy('name'),
|
'products' => $this->Database->products()->orderBy('name'),
|
||||||
'quantityunits' => $this->Database->quantity_units()->orderBy('name'),
|
'quantityunits' => $this->Database->quantity_units()->orderBy('name'),
|
||||||
'missingProducts' => $this->StockService->GetMissingProducts(),
|
'missingProducts' => $this->StockService->GetMissingProducts(),
|
||||||
'productGroups' => $this->Database->product_groups()->orderBy('name')
|
'productGroups' => $this->Database->product_groups()->orderBy('name'),
|
||||||
|
'shoppingLists' => $this->Database->shopping_lists()->orderBy('name'),
|
||||||
|
'selectedShoppingListId' => $listId,
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('products'),
|
||||||
|
'userfieldValues' => $this->UserfieldsService->GetAllValues('products')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -69,7 +89,9 @@ class StockController extends BaseController
|
|||||||
'products' => $this->Database->products()->orderBy('name'),
|
'products' => $this->Database->products()->orderBy('name'),
|
||||||
'locations' => $this->Database->locations()->orderBy('name'),
|
'locations' => $this->Database->locations()->orderBy('name'),
|
||||||
'quantityunits' => $this->Database->quantity_units()->orderBy('name'),
|
'quantityunits' => $this->Database->quantity_units()->orderBy('name'),
|
||||||
'productGroups' => $this->Database->product_groups()->orderBy('name')
|
'productGroups' => $this->Database->product_groups()->orderBy('name'),
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('products'),
|
||||||
|
'userfieldValues' => $this->UserfieldsService->GetAllValues('products')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -85,21 +107,28 @@ class StockController extends BaseController
|
|||||||
public function LocationsList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function LocationsList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'locations', [
|
return $this->AppContainer->view->render($response, 'locations', [
|
||||||
'locations' => $this->Database->locations()->orderBy('name')
|
'locations' => $this->Database->locations()->orderBy('name'),
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('locations'),
|
||||||
|
'userfieldValues' => $this->UserfieldsService->GetAllValues('locations')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function ProductGroupsList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function ProductGroupsList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'productgroups', [
|
return $this->AppContainer->view->render($response, 'productgroups', [
|
||||||
'productGroups' => $this->Database->product_groups()->orderBy('name')
|
'productGroups' => $this->Database->product_groups()->orderBy('name'),
|
||||||
|
'products' => $this->Database->products()->orderBy('name'),
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('product_groups'),
|
||||||
|
'userfieldValues' => $this->UserfieldsService->GetAllValues('product_groups')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function QuantityUnitsList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function QuantityUnitsList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'quantityunits', [
|
return $this->AppContainer->view->render($response, 'quantityunits', [
|
||||||
'quantityunits' => $this->Database->quantity_units()->orderBy('name')
|
'quantityunits' => $this->Database->quantity_units()->orderBy('name'),
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('quantity_units'),
|
||||||
|
'userfieldValues' => $this->UserfieldsService->GetAllValues('quantity_units')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -111,17 +140,26 @@ class StockController extends BaseController
|
|||||||
'locations' => $this->Database->locations()->orderBy('name'),
|
'locations' => $this->Database->locations()->orderBy('name'),
|
||||||
'quantityunits' => $this->Database->quantity_units()->orderBy('name'),
|
'quantityunits' => $this->Database->quantity_units()->orderBy('name'),
|
||||||
'productgroups' => $this->Database->product_groups()->orderBy('name'),
|
'productgroups' => $this->Database->product_groups()->orderBy('name'),
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('products'),
|
||||||
|
'products' => $this->Database->products()->where('parent_product_id IS NULL')->orderBy('name'),
|
||||||
|
'isSubProductOfOthers' => false,
|
||||||
'mode' => 'create'
|
'mode' => 'create'
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
$product = $this->Database->products($args['productId']);
|
||||||
|
|
||||||
return $this->AppContainer->view->render($response, 'productform', [
|
return $this->AppContainer->view->render($response, 'productform', [
|
||||||
'product' => $this->Database->products($args['productId']),
|
'product' => $product,
|
||||||
'locations' => $this->Database->locations()->orderBy('name'),
|
'locations' => $this->Database->locations()->orderBy('name'),
|
||||||
'quantityunits' => $this->Database->quantity_units()->orderBy('name'),
|
'quantityunits' => $this->Database->quantity_units()->orderBy('name'),
|
||||||
'productgroups' => $this->Database->product_groups()->orderBy('name'),
|
'productgroups' => $this->Database->product_groups()->orderBy('name'),
|
||||||
'mode' => 'edit'
|
'userfields' => $this->UserfieldsService->GetFields('products'),
|
||||||
|
'products' => $this->Database->products()->where('id != :1 AND parent_product_id IS NULL', $product->id)->orderBy('name'),
|
||||||
|
'isSubProductOfOthers' => $this->Database->products()->where('parent_product_id = :1', $product->id)->count() !== 0,
|
||||||
|
'mode' => 'edit',
|
||||||
|
'quConversions' => $this->Database->quantity_unit_conversions()
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -131,14 +169,16 @@ class StockController extends BaseController
|
|||||||
if ($args['locationId'] == 'new')
|
if ($args['locationId'] == 'new')
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'locationform', [
|
return $this->AppContainer->view->render($response, 'locationform', [
|
||||||
'mode' => 'create'
|
'mode' => 'create',
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('locations')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'locationform', [
|
return $this->AppContainer->view->render($response, 'locationform', [
|
||||||
'location' => $this->Database->locations($args['locationId']),
|
'location' => $this->Database->locations($args['locationId']),
|
||||||
'mode' => 'edit'
|
'mode' => 'edit',
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('locations')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -148,14 +188,16 @@ class StockController extends BaseController
|
|||||||
if ($args['productGroupId'] == 'new')
|
if ($args['productGroupId'] == 'new')
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'productgroupform', [
|
return $this->AppContainer->view->render($response, 'productgroupform', [
|
||||||
'mode' => 'create'
|
'mode' => 'create',
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('product_groups')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'productgroupform', [
|
return $this->AppContainer->view->render($response, 'productgroupform', [
|
||||||
'group' => $this->Database->product_groups($args['productGroupId']),
|
'group' => $this->Database->product_groups($args['productGroupId']),
|
||||||
'mode' => 'edit'
|
'mode' => 'edit',
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('product_groups')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -165,14 +207,24 @@ class StockController extends BaseController
|
|||||||
if ($args['quantityunitId'] == 'new')
|
if ($args['quantityunitId'] == 'new')
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'quantityunitform', [
|
return $this->AppContainer->view->render($response, 'quantityunitform', [
|
||||||
'mode' => 'create'
|
'mode' => 'create',
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('quantity_units'),
|
||||||
|
'pluralCount' => $this->LocalizationService->GetPluralCount(),
|
||||||
|
'pluralRule' => $this->LocalizationService->GetPluralDefinition()
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
$quantityUnit = $this->Database->quantity_units($args['quantityunitId']);
|
||||||
|
|
||||||
return $this->AppContainer->view->render($response, 'quantityunitform', [
|
return $this->AppContainer->view->render($response, 'quantityunitform', [
|
||||||
'quantityunit' => $this->Database->quantity_units($args['quantityunitId']),
|
'quantityUnit' => $quantityUnit,
|
||||||
'mode' => 'edit'
|
'mode' => 'edit',
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('quantity_units'),
|
||||||
|
'pluralCount' => $this->LocalizationService->GetPluralCount(),
|
||||||
|
'pluralRule' => $this->LocalizationService->GetPluralDefinition(),
|
||||||
|
'defaultQuConversions' => $this->Database->quantity_unit_conversions()->where('from_qu_id = :1 AND product_id IS NULL', $quantityUnit->id),
|
||||||
|
'quantityUnits' => $this->Database->quantity_units()
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -181,16 +233,35 @@ class StockController extends BaseController
|
|||||||
{
|
{
|
||||||
if ($args['itemId'] == 'new')
|
if ($args['itemId'] == 'new')
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'shoppinglistform', [
|
return $this->AppContainer->view->render($response, 'shoppinglistitemform', [
|
||||||
'products' => $this->Database->products()->orderBy('name'),
|
'products' => $this->Database->products()->orderBy('name'),
|
||||||
|
'shoppingLists' => $this->Database->shopping_lists()->orderBy('name'),
|
||||||
|
'mode' => 'create'
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
return $this->AppContainer->view->render($response, 'shoppinglistitemform', [
|
||||||
|
'listItem' => $this->Database->shopping_list($args['itemId']),
|
||||||
|
'products' => $this->Database->products()->orderBy('name'),
|
||||||
|
'shoppingLists' => $this->Database->shopping_lists()->orderBy('name'),
|
||||||
|
'mode' => 'edit'
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public function ShoppingListEditForm(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
if ($args['listId'] == 'new')
|
||||||
|
{
|
||||||
|
return $this->AppContainer->view->render($response, 'shoppinglistform', [
|
||||||
'mode' => 'create'
|
'mode' => 'create'
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'shoppinglistform', [
|
return $this->AppContainer->view->render($response, 'shoppinglistform', [
|
||||||
'listItem' => $this->Database->shopping_list($args['itemId']),
|
'shoppingList' => $this->Database->shopping_lists($args['listId']),
|
||||||
'products' => $this->Database->products()->orderBy('name'),
|
|
||||||
'mode' => 'edit'
|
'mode' => 'edit'
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
@@ -204,4 +275,58 @@ class StockController extends BaseController
|
|||||||
'quantityunits' => $this->Database->quantity_units()->orderBy('name')
|
'quantityunits' => $this->Database->quantity_units()->orderBy('name')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function LocationContentSheet(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
return $this->AppContainer->view->render($response, 'locationcontentsheet', [
|
||||||
|
'products' => $this->Database->products()->orderBy('name'),
|
||||||
|
'quantityunits' => $this->Database->quantity_units()->orderBy('name'),
|
||||||
|
'locations' => $this->Database->locations()->orderBy('name'),
|
||||||
|
'currentStockLocationContent' => $this->StockService->GetCurrentStockLocationContent()
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
|
||||||
|
public function QuantityUnitConversionEditForm(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
$product = null;
|
||||||
|
if (isset($request->getQueryParams()['product']))
|
||||||
|
{
|
||||||
|
$product = $this->Database->products($request->getQueryParams()['product']);
|
||||||
|
}
|
||||||
|
|
||||||
|
$defaultQuUnit = null;
|
||||||
|
if (isset($request->getQueryParams()['qu-unit']))
|
||||||
|
{
|
||||||
|
$defaultQuUnit = $this->Database->quantity_units($request->getQueryParams()['qu-unit']);
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($args['quConversionId'] == 'new')
|
||||||
|
{
|
||||||
|
return $this->AppContainer->view->render($response, 'quantityunitconversionform', [
|
||||||
|
'mode' => 'create',
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('quantity_unit_conversions'),
|
||||||
|
'quantityunits' => $this->Database->quantity_units()->orderBy('name'),
|
||||||
|
'product' => $product,
|
||||||
|
'defaultQuUnit' => $defaultQuUnit
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
return $this->AppContainer->view->render($response, 'quantityunitconversionform', [
|
||||||
|
'quConversion' => $this->Database->quantity_unit_conversions($args['quConversionId']),
|
||||||
|
'mode' => 'edit',
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('quantity_unit_conversions'),
|
||||||
|
'quantityunits' => $this->Database->quantity_units()->orderBy('name'),
|
||||||
|
'product' => $product,
|
||||||
|
'defaultQuUnit' => $defaultQuUnit
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public function QuantityUnitPluralFormTesting(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
return $this->AppContainer->view->render($response, 'quantityunitpluraltesting', [
|
||||||
|
'quantityUnits' => $this->Database->quantity_units()->orderBy('name')
|
||||||
|
]);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@@ -32,7 +32,7 @@ class SystemApiController extends BaseApiController
|
|||||||
{
|
{
|
||||||
$requestBody = $request->getParsedBody();
|
$requestBody = $request->getParsedBody();
|
||||||
|
|
||||||
$this->LocalizationService->LogMissingLocalization(GROCY_CULTURE, $requestBody['text']);
|
$this->LocalizationService->CheckAndAddMissingTranslationToPot($requestBody['text']);
|
||||||
return $this->EmptyApiResponse($response);
|
return $this->EmptyApiResponse($response);
|
||||||
}
|
}
|
||||||
catch (\Exception $ex)
|
catch (\Exception $ex)
|
||||||
|
@@ -8,14 +8,14 @@ use \Grocy\Services\DemoDataGeneratorService;
|
|||||||
|
|
||||||
class SystemController extends BaseController
|
class SystemController extends BaseController
|
||||||
{
|
{
|
||||||
|
protected $ApplicationService;
|
||||||
|
|
||||||
public function __construct(\Slim\Container $container)
|
public function __construct(\Slim\Container $container)
|
||||||
{
|
{
|
||||||
parent::__construct($container);
|
parent::__construct($container);
|
||||||
$this->ApplicationService = new ApplicationService();
|
$this->ApplicationService = new ApplicationService();
|
||||||
}
|
}
|
||||||
|
|
||||||
protected $ApplicationService;
|
|
||||||
|
|
||||||
public function Root(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function Root(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
// Schema migration is done here
|
// Schema migration is done here
|
||||||
@@ -28,13 +28,77 @@ class SystemController extends BaseController
|
|||||||
$demoDataGeneratorService->PopulateDemoData();
|
$demoDataGeneratorService->PopulateDemoData();
|
||||||
}
|
}
|
||||||
|
|
||||||
return $response->withRedirect($this->AppContainer->UrlManager->ConstructUrl('/stockoverview'));
|
return $response->withRedirect($this->AppContainer->UrlManager->ConstructUrl($this->GetEntryPageRelative()));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get the entry page of the application based on the value of the entry page setting.
|
||||||
|
*
|
||||||
|
* We fallback to the about page when no entry page is specified or
|
||||||
|
* when the specified entry page has been disabled.
|
||||||
|
*
|
||||||
|
* @return string
|
||||||
|
*/
|
||||||
|
private function GetEntryPageRelative()
|
||||||
|
{
|
||||||
|
if (defined('GROCY_ENTRY_PAGE')) {
|
||||||
|
$entryPage = constant('GROCY_ENTRY_PAGE');
|
||||||
|
} else {
|
||||||
|
$entryPage = 'stock';
|
||||||
|
}
|
||||||
|
|
||||||
|
// Stock
|
||||||
|
if ($entryPage === 'stock' && constant('GROCY_FEATURE_FLAG_STOCK')) {
|
||||||
|
return '/stockoverview';
|
||||||
|
}
|
||||||
|
|
||||||
|
// Shoppinglist
|
||||||
|
if ($entryPage === 'shoppinglist' && constant('GROCY_FEATURE_FLAG_SHOPPINGLIST')) {
|
||||||
|
return '/shoppinglist';
|
||||||
|
}
|
||||||
|
|
||||||
|
// Recipes
|
||||||
|
if ($entryPage === 'recipes' && constant('GROCY_FEATURE_FLAG_RECIPES')) {
|
||||||
|
return '/recipes';
|
||||||
|
}
|
||||||
|
|
||||||
|
// Chores
|
||||||
|
if ($entryPage === 'chores' && constant('GROCY_FEATURE_FLAG_CHORES')) {
|
||||||
|
return '/choresoverview';
|
||||||
|
}
|
||||||
|
|
||||||
|
// Tasks
|
||||||
|
if ($entryPage === 'tasks' && constant('GROCY_FEATURE_FLAG_TASKS')) {
|
||||||
|
return '/tasks';
|
||||||
|
}
|
||||||
|
|
||||||
|
// Batteries
|
||||||
|
if ($entryPage === 'batteries' && constant('GROCY_FEATURE_FLAG_BATTERIES')) {
|
||||||
|
return '/batteriesoverview';
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($entryPage === 'equipment' && constant('GROCY_FEATURE_FLAG_EQUIPMENT')) {
|
||||||
|
return '/equipment';
|
||||||
|
}
|
||||||
|
|
||||||
|
// Calendar
|
||||||
|
if ($entryPage === 'calendar' && constant('GROCY_FEATURE_FLAG_CALENDAR')) {
|
||||||
|
return '/calendar';
|
||||||
|
}
|
||||||
|
|
||||||
|
return '/about';
|
||||||
}
|
}
|
||||||
|
|
||||||
public function About(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function About(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'about', [
|
return $this->AppContainer->view->render($response, 'about', [
|
||||||
'system_info' => $this->ApplicationService->GetSystemInfo()
|
'system_info' => $this->ApplicationService->GetSystemInfo(),
|
||||||
|
'changelog' => $this->ApplicationService->GetChangelog()
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function BarcodeScannerTesting(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
return $this->AppContainer->view->render($response, 'barcodescannertesting');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@@ -39,4 +39,17 @@ class TasksApiController extends BaseApiController
|
|||||||
return $this->GenericErrorResponse($response, $ex->getMessage());
|
return $this->GenericErrorResponse($response, $ex->getMessage());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function UndoTask(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
$this->TasksService->UndoTask($args['taskId']);
|
||||||
|
return $this->EmptyApiResponse($response);
|
||||||
|
}
|
||||||
|
catch (\Exception $ex)
|
||||||
|
{
|
||||||
|
return $this->GenericErrorResponse($response, $ex->getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@@ -3,6 +3,8 @@
|
|||||||
namespace Grocy\Controllers;
|
namespace Grocy\Controllers;
|
||||||
|
|
||||||
use \Grocy\Services\TasksService;
|
use \Grocy\Services\TasksService;
|
||||||
|
use \Grocy\Services\UsersService;
|
||||||
|
use \Grocy\Services\UserfieldsService;
|
||||||
|
|
||||||
class TasksController extends BaseController
|
class TasksController extends BaseController
|
||||||
{
|
{
|
||||||
@@ -10,9 +12,11 @@ class TasksController extends BaseController
|
|||||||
{
|
{
|
||||||
parent::__construct($container);
|
parent::__construct($container);
|
||||||
$this->TasksService = new TasksService();
|
$this->TasksService = new TasksService();
|
||||||
|
$this->UserfieldsService = new UserfieldsService();
|
||||||
}
|
}
|
||||||
|
|
||||||
protected $TasksService;
|
protected $TasksService;
|
||||||
|
protected $UserfieldsService;
|
||||||
|
|
||||||
public function Overview(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function Overview(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
@@ -25,11 +29,16 @@ class TasksController extends BaseController
|
|||||||
$tasks = $this->TasksService->GetCurrent();
|
$tasks = $this->TasksService->GetCurrent();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$usersService = new UsersService();
|
||||||
|
$nextXDays = $usersService->GetUserSettings(GROCY_USER_ID)['tasks_due_soon_days'];
|
||||||
|
|
||||||
return $this->AppContainer->view->render($response, 'tasks', [
|
return $this->AppContainer->view->render($response, 'tasks', [
|
||||||
'tasks' => $tasks,
|
'tasks' => $tasks,
|
||||||
'nextXDays' => 5,
|
'nextXDays' => $nextXDays,
|
||||||
'taskCategories' => $this->Database->task_categories()->orderBy('name'),
|
'taskCategories' => $this->Database->task_categories()->orderBy('name'),
|
||||||
'users' => $this->Database->users()
|
'users' => $this->Database->users(),
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('tasks'),
|
||||||
|
'userfieldValues' => $this->UserfieldsService->GetAllValues('tasks')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -40,7 +49,8 @@ class TasksController extends BaseController
|
|||||||
return $this->AppContainer->view->render($response, 'taskform', [
|
return $this->AppContainer->view->render($response, 'taskform', [
|
||||||
'mode' => 'create',
|
'mode' => 'create',
|
||||||
'taskCategories' => $this->Database->task_categories()->orderBy('name'),
|
'taskCategories' => $this->Database->task_categories()->orderBy('name'),
|
||||||
'users' => $this->Database->users()->orderBy('username')
|
'users' => $this->Database->users()->orderBy('username'),
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('tasks')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@@ -49,7 +59,8 @@ class TasksController extends BaseController
|
|||||||
'task' => $this->Database->tasks($args['taskId']),
|
'task' => $this->Database->tasks($args['taskId']),
|
||||||
'mode' => 'edit',
|
'mode' => 'edit',
|
||||||
'taskCategories' => $this->Database->task_categories()->orderBy('name'),
|
'taskCategories' => $this->Database->task_categories()->orderBy('name'),
|
||||||
'users' => $this->Database->users()->orderBy('username')
|
'users' => $this->Database->users()->orderBy('username'),
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('tasks')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -57,7 +68,9 @@ class TasksController extends BaseController
|
|||||||
public function TaskCategoriesList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
public function TaskCategoriesList(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'taskcategories', [
|
return $this->AppContainer->view->render($response, 'taskcategories', [
|
||||||
'taskCategories' => $this->Database->task_categories()->orderBy('name')
|
'taskCategories' => $this->Database->task_categories()->orderBy('name'),
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('task_categories'),
|
||||||
|
'userfieldValues' => $this->UserfieldsService->GetAllValues('task_categories')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -66,15 +79,22 @@ class TasksController extends BaseController
|
|||||||
if ($args['categoryId'] == 'new')
|
if ($args['categoryId'] == 'new')
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'taskcategoryform', [
|
return $this->AppContainer->view->render($response, 'taskcategoryform', [
|
||||||
'mode' => 'create'
|
'mode' => 'create',
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('task_categories')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return $this->AppContainer->view->render($response, 'taskcategoryform', [
|
return $this->AppContainer->view->render($response, 'taskcategoryform', [
|
||||||
'category' => $this->Database->task_categories($args['categoryId']),
|
'category' => $this->Database->task_categories($args['categoryId']),
|
||||||
'mode' => 'edit'
|
'mode' => 'edit',
|
||||||
|
'userfields' => $this->UserfieldsService->GetFields('task_categories')
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function TasksSettings(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args)
|
||||||
|
{
|
||||||
|
return $this->AppContainer->view->render($response, 'taskssettings');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
2
data/viewcache/.gitignore
vendored
2
data/viewcache/.gitignore
vendored
@@ -1,2 +0,0 @@
|
|||||||
*
|
|
||||||
!.gitignore
|
|
1228
grocy.openapi.json
1228
grocy.openapi.json
File diff suppressed because it is too large
Load Diff
@@ -88,10 +88,20 @@ function SumArrayValue($array, $propertyName)
|
|||||||
return $sum;
|
return $sum;
|
||||||
}
|
}
|
||||||
|
|
||||||
function GetClassConstants($className)
|
function GetClassConstants($className, $prefix = null)
|
||||||
{
|
{
|
||||||
$r = new ReflectionClass($className);
|
$r = new ReflectionClass($className);
|
||||||
return $r->getConstants();
|
$constants = $r->getConstants();
|
||||||
|
|
||||||
|
if ($prefix === null)
|
||||||
|
{
|
||||||
|
return $constants;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$matchingKeys = preg_grep('!^' . $prefix . '!', array_keys($constants));
|
||||||
|
return array_intersect_key($constants, array_flip($matchingKeys));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function RandomString($length, $allowedChars = '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ')
|
function RandomString($length, $allowedChars = '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ')
|
||||||
@@ -140,7 +150,18 @@ function Setting(string $name, $value)
|
|||||||
}
|
}
|
||||||
elseif (getenv('GROCY_' . $name) !== false) // An environment variable with the same name and prefix GROCY_ overwrites the given setting
|
elseif (getenv('GROCY_' . $name) !== false) // An environment variable with the same name and prefix GROCY_ overwrites the given setting
|
||||||
{
|
{
|
||||||
define('GROCY_' . $name, getenv('GROCY_' . $name));
|
if (strtolower(getenv('GROCY_' . $name)) === "true")
|
||||||
|
{
|
||||||
|
define('GROCY_' . $name, true);
|
||||||
|
}
|
||||||
|
elseif (strtolower(getenv('GROCY_' . $name)) === "false")
|
||||||
|
{
|
||||||
|
define('GROCY_' . $name, false);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
define('GROCY_' . $name, getenv('GROCY_' . $name));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -163,7 +184,7 @@ function DefaultUserSetting(string $name, $value)
|
|||||||
function GetUserDisplayName($user)
|
function GetUserDisplayName($user)
|
||||||
{
|
{
|
||||||
$displayName = '';
|
$displayName = '';
|
||||||
|
|
||||||
if (empty($user->first_name) && !empty($user->last_name))
|
if (empty($user->first_name) && !empty($user->last_name))
|
||||||
{
|
{
|
||||||
$displayName = $user->last_name;
|
$displayName = $user->last_name;
|
||||||
@@ -184,16 +205,6 @@ function GetUserDisplayName($user)
|
|||||||
return $displayName;
|
return $displayName;
|
||||||
}
|
}
|
||||||
|
|
||||||
function Pluralize($number, $singularForm, $pluralForm)
|
|
||||||
{
|
|
||||||
$text = $singularForm;
|
|
||||||
if ($number != 1 && $pluralForm !== null && !empty($pluralForm))
|
|
||||||
{
|
|
||||||
$text = $pluralForm;
|
|
||||||
}
|
|
||||||
return $text;
|
|
||||||
}
|
|
||||||
|
|
||||||
function IsValidFileName($fileName)
|
function IsValidFileName($fileName)
|
||||||
{
|
{
|
||||||
if(preg_match('=^[^/?*;:{}\\\\]+\.[^/?*;:{}\\\\]+$=', $fileName))
|
if(preg_match('=^[^/?*;:{}\\\\]+\.[^/?*;:{}\\\\]+$=', $fileName))
|
||||||
@@ -203,3 +214,25 @@ function IsValidFileName($fileName)
|
|||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function IsJsonString($text)
|
||||||
|
{
|
||||||
|
json_decode($text);
|
||||||
|
return (json_last_error() == JSON_ERROR_NONE);
|
||||||
|
}
|
||||||
|
|
||||||
|
function string_starts_with($haystack, $needle)
|
||||||
|
{
|
||||||
|
return (substr($haystack, 0, strlen($needle)) === $needle);
|
||||||
|
}
|
||||||
|
|
||||||
|
function string_ends_with($haystack, $needle)
|
||||||
|
{
|
||||||
|
$length = strlen($needle);
|
||||||
|
if ($length == 0)
|
||||||
|
{
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
return (substr($haystack, -$length) === $needle);
|
||||||
|
}
|
||||||
|
25
localization/chore_assignment_types.pot
Normal file
25
localization/chore_assignment_types.pot
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: \n"
|
||||||
|
"Report-Msgid-Bugs-To: \n"
|
||||||
|
"Last-Translator: Translation migration from old PHP array files\n"
|
||||||
|
"Language-Team: http://www.transifex.com/grocy/grocy/language/en\n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
|
"POT-Creation-Date: 2019-05-01T17:59:17+00:00\n"
|
||||||
|
"PO-Revision-Date: 2019-05-01T17:59:17+00:00\n"
|
||||||
|
"Language: en\n"
|
||||||
|
"X-Domain: grocy/chore_assignment_types\n"
|
||||||
|
|
||||||
|
msgid "no-assignment"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "who-least-did-first"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "random"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "in-alphabetical-order"
|
||||||
|
msgstr ""
|
28
localization/chore_period_types.pot
Normal file
28
localization/chore_period_types.pot
Normal file
@@ -0,0 +1,28 @@
|
|||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: \n"
|
||||||
|
"Report-Msgid-Bugs-To: \n"
|
||||||
|
"Last-Translator: Translation migration from old PHP array files\n"
|
||||||
|
"Language-Team: http://www.transifex.com/grocy/grocy/language/en\n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
|
"POT-Creation-Date: 2019-05-01T17:59:17+00:00\n"
|
||||||
|
"PO-Revision-Date: 2019-05-01T17:59:17+00:00\n"
|
||||||
|
"Language: en\n"
|
||||||
|
"X-Domain: grocy/chore_types\n"
|
||||||
|
|
||||||
|
msgid "manually"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "dynamic-regular"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "daily"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "weekly"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "monthly"
|
||||||
|
msgstr ""
|
34
localization/component_translations.pot
Normal file
34
localization/component_translations.pot
Normal file
@@ -0,0 +1,34 @@
|
|||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: \n"
|
||||||
|
"Report-Msgid-Bugs-To: \n"
|
||||||
|
"Last-Translator: Translation migration from old PHP array files\n"
|
||||||
|
"Language-Team: http://www.transifex.com/grocy/grocy/language/en\n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
|
"POT-Creation-Date: 2019-05-01T17:59:17+00:00\n"
|
||||||
|
"PO-Revision-Date: 2019-05-01T17:59:17+00:00\n"
|
||||||
|
"Language: en\n"
|
||||||
|
"X-Domain: grocy/component_translations\n"
|
||||||
|
|
||||||
|
msgid "timeago_locale"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "timeago_nan"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "moment_locale"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "datatables_localization"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "summernote_locale"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "fullcalendar_locale"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "bootstrap-select_locale"
|
||||||
|
msgstr ""
|
29
localization/da/chore_assignment_types.po
Normal file
29
localization/da/chore_assignment_types.po
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
# Translators:
|
||||||
|
# Troels Siggaard <troels@siggaard.com>, 2019
|
||||||
|
#
|
||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: \n"
|
||||||
|
"Report-Msgid-Bugs-To: \n"
|
||||||
|
"POT-Creation-Date: 2019-05-01T17:59:17+00:00\n"
|
||||||
|
"PO-Revision-Date: 2019-09-17 10:45+0000\n"
|
||||||
|
"Last-Translator: Troels Siggaard <troels@siggaard.com>, 2019\n"
|
||||||
|
"Language-Team: Danish (https://www.transifex.com/grocy/teams/93189/da/)\n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
|
"Language: da\n"
|
||||||
|
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||||
|
"X-Domain: grocy/chore_assignment_types\n"
|
||||||
|
|
||||||
|
msgid "no-assignment"
|
||||||
|
msgstr "ingen-tildeling"
|
||||||
|
|
||||||
|
msgid "who-least-did-first"
|
||||||
|
msgstr "hvem-mindst-gjorde-først"
|
||||||
|
|
||||||
|
msgid "random"
|
||||||
|
msgstr "tilfældig"
|
||||||
|
|
||||||
|
msgid "in-alphabetical-order"
|
||||||
|
msgstr "i-alfabetisk-rækkefølge"
|
32
localization/da/chore_period_types.po
Normal file
32
localization/da/chore_period_types.po
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
# Translators:
|
||||||
|
# Troels Siggaard <troels@siggaard.com>, 2019
|
||||||
|
#
|
||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: \n"
|
||||||
|
"Report-Msgid-Bugs-To: \n"
|
||||||
|
"POT-Creation-Date: 2019-05-01T17:59:17+00:00\n"
|
||||||
|
"PO-Revision-Date: 2019-05-01 17:42+0000\n"
|
||||||
|
"Last-Translator: Troels Siggaard <troels@siggaard.com>, 2019\n"
|
||||||
|
"Language-Team: Danish (https://www.transifex.com/grocy/teams/93189/da/)\n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
|
"Language: da\n"
|
||||||
|
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||||
|
"X-Domain: grocy/chore_types\n"
|
||||||
|
|
||||||
|
msgid "manually"
|
||||||
|
msgstr "manuelt"
|
||||||
|
|
||||||
|
msgid "dynamic-regular"
|
||||||
|
msgstr "gentagende-dynamisk"
|
||||||
|
|
||||||
|
msgid "daily"
|
||||||
|
msgstr "daglig"
|
||||||
|
|
||||||
|
msgid "weekly"
|
||||||
|
msgstr "ugentlig"
|
||||||
|
|
||||||
|
msgid "monthly"
|
||||||
|
msgstr "månedlig"
|
@@ -1,6 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
return array(
|
|
||||||
'manually' => 'Manuelt',
|
|
||||||
'dynamic-regular' => 'Dynamic regular'
|
|
||||||
);
|
|
@@ -1,10 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
return array(
|
|
||||||
'timeago_locale' => 'en',
|
|
||||||
'timeago_nan' => 'NaN years ago',
|
|
||||||
'moment_locale' => 'x',
|
|
||||||
'datatables_localization' => '{"sEmptyTable":"No data available in table","sInfo":"Showing _START_ to _END_ of _TOTAL_ entries","sInfoEmpty":"Showing 0 to 0 of 0 entries","sInfoFiltered":"(filtered from _MAX_ total entries)","sInfoPostFix":"","sInfoThousands":",","sLengthMenu":"Show _MENU_ entries","sLoadingRecords":"Loading...","sProcessing":"Processing...","sSearch":"Search:","sZeroRecords":"No matching records found","oPaginate":{"sFirst":"First","sLast":"Last","sNext":"Next","sPrevious":"Previous"},"oAria":{"sSortAscending":": activate to sort column ascending","sSortDescending":": activate to sort column descending"}}',
|
|
||||||
'summernote_locale' => 'x',
|
|
||||||
'fullcalendar_locale' => 'x'
|
|
||||||
);
|
|
55
localization/da/component_translations.po
Normal file
55
localization/da/component_translations.po
Normal file
@@ -0,0 +1,55 @@
|
|||||||
|
# Translators:
|
||||||
|
# Bernd Bestel <bernd@berrnd.de>, 2019
|
||||||
|
#
|
||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: \n"
|
||||||
|
"Report-Msgid-Bugs-To: \n"
|
||||||
|
"POT-Creation-Date: 2019-05-01T17:59:17+00:00\n"
|
||||||
|
"PO-Revision-Date: 2019-05-01 17:42+0000\n"
|
||||||
|
"Last-Translator: Bernd Bestel <bernd@berrnd.de>, 2019\n"
|
||||||
|
"Language-Team: Danish (https://www.transifex.com/grocy/teams/93189/da/)\n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
|
"Language: da\n"
|
||||||
|
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||||
|
"X-Domain: grocy/component_translations\n"
|
||||||
|
|
||||||
|
msgid "timeago_locale"
|
||||||
|
msgstr "da"
|
||||||
|
|
||||||
|
msgid "timeago_nan"
|
||||||
|
msgstr "for NaN år"
|
||||||
|
|
||||||
|
msgid "moment_locale"
|
||||||
|
msgstr "da"
|
||||||
|
|
||||||
|
msgid "datatables_localization"
|
||||||
|
msgstr ""
|
||||||
|
"{\n"
|
||||||
|
"\"sProcessing\": \"Henter...\",\n"
|
||||||
|
"\"sLengthMenu\": \"Vis _MENU_ linjer\",\n"
|
||||||
|
"\"sZeroRecords\": \"Ingen linjer matcher søgningen\",\n"
|
||||||
|
"\"sInfo\": \"Viser _START_ til _END_ af _TOTAL_ linjer\",\n"
|
||||||
|
"\"sInfoEmpty\": \"Viser 0 til 0 af 0 linjer\",\n"
|
||||||
|
"\"sInfoFiltered\": \"(filtreret fra _MAX_ linjer)\",\n"
|
||||||
|
"\"sInfoPostFix\": \"\",\n"
|
||||||
|
"\"sSearch\": \"Søg:\",\n"
|
||||||
|
"\"sUrl\": \"\",\n"
|
||||||
|
"\"oPaginate\": {\n"
|
||||||
|
"\"sFirst\": \"Første\",\n"
|
||||||
|
"\"sPrevious\": \"Forrige\",\n"
|
||||||
|
"\"sNext\": \"Næste\",\n"
|
||||||
|
"\"sLast\": \"Sidste\"\n"
|
||||||
|
"}\n"
|
||||||
|
"}"
|
||||||
|
|
||||||
|
msgid "summernote_locale"
|
||||||
|
msgstr "da-DK"
|
||||||
|
|
||||||
|
msgid "fullcalendar_locale"
|
||||||
|
msgstr "da"
|
||||||
|
|
||||||
|
msgid "bootstrap-select_locale"
|
||||||
|
msgstr "da_DK"
|
@@ -1,89 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
return array(
|
|
||||||
'Cookies' => 'Småkager',
|
|
||||||
'Chocolate' => 'chokolade',
|
|
||||||
'Pantry' => 'Spisekammer',
|
|
||||||
'Candy cupboard' => 'Slik skuffe',
|
|
||||||
'Tinned food cupboard' => 'Dåsemadsskab',
|
|
||||||
'Fridge' => 'Køleskab',
|
|
||||||
'Piece' => 'Styk',
|
|
||||||
'Pieces' => 'Stykker',
|
|
||||||
'Pack' => 'Pakke',
|
|
||||||
'Packs' => 'Pakker',
|
|
||||||
'Glass' => 'Glas',
|
|
||||||
'Glasses' => 'Glas',
|
|
||||||
'Tin' => 'Beholder',
|
|
||||||
'Tins' => 'Beholdere',
|
|
||||||
'Can' => 'Dåse',
|
|
||||||
'Cans' => 'Dåser',
|
|
||||||
'Bunch' => 'Bundt',
|
|
||||||
'Bunches' => 'Bundt',
|
|
||||||
'Gummy bears' => 'Vingummi bamser',
|
|
||||||
'Crisps' => 'Chips',
|
|
||||||
'Eggs' => 'Æg',
|
|
||||||
'Noodles' => 'Nudler',
|
|
||||||
'Pickles' => 'Syltede agurker',
|
|
||||||
'Gulash soup' => 'Gulash',
|
|
||||||
'Yogurt' => 'Yoghurt',
|
|
||||||
'Cheese' => 'Ost',
|
|
||||||
'Cold cuts' => 'Pålæg',
|
|
||||||
'Paprika' => 'Paprika',
|
|
||||||
'Cucumber' => 'Agurk',
|
|
||||||
'Radish' => 'Radisse',
|
|
||||||
'Tomato' => 'Tomat',
|
|
||||||
'Changed towels in the bathroom' => 'Skiftede håndklæder i badeværelset',
|
|
||||||
'Cleaned the kitchen floor' => 'Gjorde køkkengulvet rent',
|
|
||||||
'Warranty ends' => 'Reklamationsret udløber',
|
|
||||||
'TV remote control' => 'Fjernbetjening',
|
|
||||||
'Alarm clock' => 'Vægge ur',
|
|
||||||
'Heat remote control' => 'Varmefjernbetjening',
|
|
||||||
'Lawn mowed in the garden' => 'Græs slået',
|
|
||||||
'Some good snacks' => 'Nogle gode snacks',
|
|
||||||
'Pizza dough' => 'Pizza dej',
|
|
||||||
'Sieved tomatoes' => 'Sigtede tomater',
|
|
||||||
'Salami' => 'Salami',
|
|
||||||
'Toast' => 'Toast',
|
|
||||||
'Minced meat' => 'Hakkekød',
|
|
||||||
'Pizza' => 'Pizza',
|
|
||||||
'Spaghetti bolognese' => 'Spaghetti bolognese',
|
|
||||||
'Sandwiches' => 'Sandwiches',
|
|
||||||
'English' => 'Engelsk',
|
|
||||||
'German' => 'Tysk',
|
|
||||||
'Italian' => 'Italiænsk',
|
|
||||||
'Demo in different language' => 'Demo i et andet sprog',
|
|
||||||
'This is the note content of the recipe ingredient' => 'Dette er indholdet af opskrift ingrediensens notefelt',
|
|
||||||
'Demo User' => 'Demo Bruger',
|
|
||||||
'Gram' => 'Gram',
|
|
||||||
'Grams' => 'Gram',
|
|
||||||
'Flour' => 'Mel',
|
|
||||||
'Pancakes' => 'Pandekager',
|
|
||||||
'Sugar' => 'Sukker',
|
|
||||||
'Home' => 'Hjem',
|
|
||||||
'Life' => 'Liv',
|
|
||||||
'Projects' => 'Projekter',
|
|
||||||
'Repair the garage door' => 'Reparér garagedøren',
|
|
||||||
'Fork and improve grocy' => 'Fork og forbedre grocy',
|
|
||||||
'Find a solution for what to do when I forget the door keys' => 'Find en løsning for når jeg glemmer husnøglen',
|
|
||||||
'Sweets' => 'Slik',
|
|
||||||
'Bakery products' => 'Bageriprodukter',
|
|
||||||
'Tinned food' => 'Dåsemad',
|
|
||||||
'Butchery products' => 'Slagteriprodukter',
|
|
||||||
'Vegetables/Fruits' => 'Frugt og grønt',
|
|
||||||
'Refrigerated products' => 'Nedkølede produkter',
|
|
||||||
'Coffee machine' => 'Kaffemaskine',
|
|
||||||
'Dishwasher' => 'Opvasker',
|
|
||||||
'Liter' => 'Liter',
|
|
||||||
'Liters' => 'Liter',
|
|
||||||
'Bottle' => 'Flaske',
|
|
||||||
'Bottles' => 'Flasker',
|
|
||||||
'Milk' => 'Mælk',
|
|
||||||
'Chocolate sauce' => 'Chokoladesauce',
|
|
||||||
'Milliliters' => 'Milliliter',
|
|
||||||
'Milliliter' => 'Milliliter',
|
|
||||||
'Bottom' => 'Bund',
|
|
||||||
'Topping' => 'Topping',
|
|
||||||
'French' => 'Fransk',
|
|
||||||
'Turkish' => 'Turkish',
|
|
||||||
'Spanish' => 'Spanish'
|
|
||||||
);
|
|
310
localization/da/demo_data.po
Normal file
310
localization/da/demo_data.po
Normal file
@@ -0,0 +1,310 @@
|
|||||||
|
# Translators:
|
||||||
|
# dark159123 <r.j.hansen@protonmail.com>, 2019
|
||||||
|
# Troels Siggaard <troels@siggaard.com>, 2019
|
||||||
|
#
|
||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: \n"
|
||||||
|
"Report-Msgid-Bugs-To: \n"
|
||||||
|
"POT-Creation-Date: 2019-05-01T17:59:17+00:00\n"
|
||||||
|
"PO-Revision-Date: 2019-05-01 17:42+0000\n"
|
||||||
|
"Last-Translator: Troels Siggaard <troels@siggaard.com>, 2019\n"
|
||||||
|
"Language-Team: Danish (https://www.transifex.com/grocy/teams/93189/da/)\n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
|
"Language: da\n"
|
||||||
|
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||||
|
"X-Domain: grocy/demo_data\n"
|
||||||
|
|
||||||
|
msgid "Cookies"
|
||||||
|
msgstr "Småkager"
|
||||||
|
|
||||||
|
msgid "Chocolate"
|
||||||
|
msgstr "Chokolade"
|
||||||
|
|
||||||
|
msgid "Pantry"
|
||||||
|
msgstr "Spisekammer"
|
||||||
|
|
||||||
|
msgid "Candy cupboard"
|
||||||
|
msgstr "Slikskuffe"
|
||||||
|
|
||||||
|
msgid "Tinned food cupboard"
|
||||||
|
msgstr "Dåsemadsskab"
|
||||||
|
|
||||||
|
msgid "Fridge"
|
||||||
|
msgstr "Køleskab"
|
||||||
|
|
||||||
|
msgid "Piece"
|
||||||
|
msgid_plural "Pieces"
|
||||||
|
msgstr[0] "Styk"
|
||||||
|
msgstr[1] "Stykker"
|
||||||
|
|
||||||
|
msgid "Pack"
|
||||||
|
msgid_plural "Packs"
|
||||||
|
msgstr[0] "Pakke"
|
||||||
|
msgstr[1] "Pakker"
|
||||||
|
|
||||||
|
msgid "Glass"
|
||||||
|
msgid_plural "Glasses"
|
||||||
|
msgstr[0] "Glas"
|
||||||
|
msgstr[1] "Glas"
|
||||||
|
|
||||||
|
msgid "Tin"
|
||||||
|
msgid_plural "Tins"
|
||||||
|
msgstr[0] "Dåse"
|
||||||
|
msgstr[1] "Dåser"
|
||||||
|
|
||||||
|
msgid "Can"
|
||||||
|
msgid_plural "Cans"
|
||||||
|
msgstr[0] "Dåse"
|
||||||
|
msgstr[1] "Dåser"
|
||||||
|
|
||||||
|
msgid "Bunch"
|
||||||
|
msgid_plural "Bunches"
|
||||||
|
msgstr[0] "Klase"
|
||||||
|
msgstr[1] "Klaser"
|
||||||
|
|
||||||
|
msgid "Gummy bears"
|
||||||
|
msgstr "Vingummibamser"
|
||||||
|
|
||||||
|
msgid "Crisps"
|
||||||
|
msgstr "Chips"
|
||||||
|
|
||||||
|
msgid "Eggs"
|
||||||
|
msgstr "Æg"
|
||||||
|
|
||||||
|
msgid "Noodles"
|
||||||
|
msgstr "Nudler"
|
||||||
|
|
||||||
|
msgid "Pickles"
|
||||||
|
msgstr "Syltede agurker"
|
||||||
|
|
||||||
|
msgid "Gulash soup"
|
||||||
|
msgstr "Gulash"
|
||||||
|
|
||||||
|
msgid "Yogurt"
|
||||||
|
msgstr "Yoghurt"
|
||||||
|
|
||||||
|
msgid "Cheese"
|
||||||
|
msgstr "Ost"
|
||||||
|
|
||||||
|
msgid "Cold cuts"
|
||||||
|
msgstr "Pålæg"
|
||||||
|
|
||||||
|
msgid "Paprika"
|
||||||
|
msgstr "Paprika"
|
||||||
|
|
||||||
|
msgid "Cucumber"
|
||||||
|
msgstr "Agurk"
|
||||||
|
|
||||||
|
msgid "Radish"
|
||||||
|
msgstr "Radisse"
|
||||||
|
|
||||||
|
msgid "Tomato"
|
||||||
|
msgstr "Tomat"
|
||||||
|
|
||||||
|
msgid "Changed towels in the bathroom"
|
||||||
|
msgstr "Skiftede håndklæder i badeværelset"
|
||||||
|
|
||||||
|
msgid "Cleaned the kitchen floor"
|
||||||
|
msgstr "Gjorde køkkengulvet rent"
|
||||||
|
|
||||||
|
msgid "Warranty ends"
|
||||||
|
msgstr "Reklamationsret udløber"
|
||||||
|
|
||||||
|
msgid "TV remote control"
|
||||||
|
msgstr "Fjernbetjening til TV'et"
|
||||||
|
|
||||||
|
msgid "Alarm clock"
|
||||||
|
msgstr "Væggeur"
|
||||||
|
|
||||||
|
msgid "Heat remote control"
|
||||||
|
msgstr "Fjernbetjening til varme"
|
||||||
|
|
||||||
|
msgid "Lawn mowed in the garden"
|
||||||
|
msgstr "Græsset blev slået i haven"
|
||||||
|
|
||||||
|
msgid "Some good snacks"
|
||||||
|
msgstr "Nogle gode snacks"
|
||||||
|
|
||||||
|
msgid "Pizza dough"
|
||||||
|
msgstr "Pizzadej"
|
||||||
|
|
||||||
|
msgid "Sieved tomatoes"
|
||||||
|
msgstr "Sigtede tomater"
|
||||||
|
|
||||||
|
msgid "Salami"
|
||||||
|
msgstr "Salami"
|
||||||
|
|
||||||
|
msgid "Toast"
|
||||||
|
msgstr "Toast"
|
||||||
|
|
||||||
|
msgid "Minced meat"
|
||||||
|
msgstr "Hakkekød"
|
||||||
|
|
||||||
|
msgid "Pizza"
|
||||||
|
msgstr "Pizza"
|
||||||
|
|
||||||
|
msgid "Spaghetti bolognese"
|
||||||
|
msgstr "Spaghetti bolognese"
|
||||||
|
|
||||||
|
msgid "Sandwiches"
|
||||||
|
msgstr "Sandwich"
|
||||||
|
|
||||||
|
msgid "English"
|
||||||
|
msgstr "Engelsk"
|
||||||
|
|
||||||
|
msgid "German"
|
||||||
|
msgstr "Tysk"
|
||||||
|
|
||||||
|
msgid "Italian"
|
||||||
|
msgstr "Italiensk"
|
||||||
|
|
||||||
|
msgid "Demo in different language"
|
||||||
|
msgstr "Demo på et andet sprog"
|
||||||
|
|
||||||
|
msgid "This is the note content of the recipe ingredient"
|
||||||
|
msgstr "Dette er indholdet af opskrift-ingrediensens notefeltet"
|
||||||
|
|
||||||
|
msgid "Demo User"
|
||||||
|
msgstr "Demo Bruger"
|
||||||
|
|
||||||
|
msgid "Gram"
|
||||||
|
msgid_plural "Grams"
|
||||||
|
msgstr[0] "Gram"
|
||||||
|
msgstr[1] "Gram"
|
||||||
|
|
||||||
|
msgid "Flour"
|
||||||
|
msgstr "Mel"
|
||||||
|
|
||||||
|
msgid "Pancakes"
|
||||||
|
msgstr "Pandekager"
|
||||||
|
|
||||||
|
msgid "Sugar"
|
||||||
|
msgstr "Sukker"
|
||||||
|
|
||||||
|
msgid "Home"
|
||||||
|
msgstr "Hjem"
|
||||||
|
|
||||||
|
msgid "Life"
|
||||||
|
msgstr "Livet"
|
||||||
|
|
||||||
|
msgid "Projects"
|
||||||
|
msgstr "Projekter"
|
||||||
|
|
||||||
|
msgid "Repair the garage door"
|
||||||
|
msgstr "Reparer garagedøren"
|
||||||
|
|
||||||
|
msgid "Fork and improve grocy"
|
||||||
|
msgstr "Fork og forbedre grocy"
|
||||||
|
|
||||||
|
msgid "Find a solution for what to do when I forget the door keys"
|
||||||
|
msgstr "Find en løsning på hvad jeg gør, når jeg glemmer nøglen til huset"
|
||||||
|
|
||||||
|
msgid "Sweets"
|
||||||
|
msgstr "Slik"
|
||||||
|
|
||||||
|
msgid "Bakery products"
|
||||||
|
msgstr "Bagværk"
|
||||||
|
|
||||||
|
msgid "Tinned food"
|
||||||
|
msgstr "Dåsemad"
|
||||||
|
|
||||||
|
msgid "Butchery products"
|
||||||
|
msgstr "Slagteriprodukter"
|
||||||
|
|
||||||
|
msgid "Vegetables/Fruits"
|
||||||
|
msgstr "Frugt og grønt"
|
||||||
|
|
||||||
|
msgid "Refrigerated products"
|
||||||
|
msgstr "Køleskabsprodukter"
|
||||||
|
|
||||||
|
msgid "Coffee machine"
|
||||||
|
msgstr "Kaffemaskine"
|
||||||
|
|
||||||
|
msgid "Dishwasher"
|
||||||
|
msgstr "Opvaskemaskine"
|
||||||
|
|
||||||
|
msgid "Liter"
|
||||||
|
msgstr "Liter"
|
||||||
|
|
||||||
|
msgid "Liters"
|
||||||
|
msgstr "Liter"
|
||||||
|
|
||||||
|
msgid "Bottle"
|
||||||
|
msgstr "Flaske"
|
||||||
|
|
||||||
|
msgid "Bottles"
|
||||||
|
msgstr "Flasker"
|
||||||
|
|
||||||
|
msgid "Milk"
|
||||||
|
msgstr "Mælk"
|
||||||
|
|
||||||
|
msgid "Chocolate sauce"
|
||||||
|
msgstr "Chokoladesauce"
|
||||||
|
|
||||||
|
msgid "Milliliters"
|
||||||
|
msgstr "Milliliter"
|
||||||
|
|
||||||
|
msgid "Milliliter"
|
||||||
|
msgstr "Milliliter"
|
||||||
|
|
||||||
|
msgid "Bottom"
|
||||||
|
msgstr "Bund"
|
||||||
|
|
||||||
|
msgid "Topping"
|
||||||
|
msgstr "Topping"
|
||||||
|
|
||||||
|
msgid "French"
|
||||||
|
msgstr "Fransk"
|
||||||
|
|
||||||
|
msgid "Turkish"
|
||||||
|
msgstr "Tyrkisk"
|
||||||
|
|
||||||
|
msgid "Spanish"
|
||||||
|
msgstr "Spansk"
|
||||||
|
|
||||||
|
msgid "Russian"
|
||||||
|
msgstr "Russisk"
|
||||||
|
|
||||||
|
msgid "The thing which happens on the 5th of every month"
|
||||||
|
msgstr "Det der sker hver den 5. i måneden"
|
||||||
|
|
||||||
|
msgid "The thing which happens daily"
|
||||||
|
msgstr "Det der sker dagligt"
|
||||||
|
|
||||||
|
msgid "The thing which happens on Mondays and Wednesdays"
|
||||||
|
msgstr "Det der sker på mandage og onsdage"
|
||||||
|
|
||||||
|
msgid "Swedish"
|
||||||
|
msgstr "Svensk"
|
||||||
|
|
||||||
|
msgid "Polish"
|
||||||
|
msgstr "Polsk"
|
||||||
|
|
||||||
|
msgid "Milk Chocolate"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "Dark Chocolate"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "Slice"
|
||||||
|
msgid_plural "Slices"
|
||||||
|
msgstr[0] ""
|
||||||
|
msgstr[1] ""
|
||||||
|
|
||||||
|
msgid "Example userentity"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "This is an example user entity..."
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "Custom field"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "Example field value..."
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "Waffle rolls"
|
||||||
|
msgstr ""
|
@@ -1,8 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
return array(
|
|
||||||
'purchase' => 'Køb',
|
|
||||||
'consume' => 'Brug',
|
|
||||||
'inventory-correction' => 'Beholdningsrettelse',
|
|
||||||
'product-opened' => 'Produkt åbnet'
|
|
||||||
);
|
|
29
localization/da/stock_transaction_types.po
Normal file
29
localization/da/stock_transaction_types.po
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
# Translators:
|
||||||
|
# Troels Siggaard <troels@siggaard.com>, 2019
|
||||||
|
#
|
||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: \n"
|
||||||
|
"Report-Msgid-Bugs-To: \n"
|
||||||
|
"POT-Creation-Date: 2019-05-01T17:59:17+00:00\n"
|
||||||
|
"PO-Revision-Date: 2019-05-01 17:42+0000\n"
|
||||||
|
"Last-Translator: Troels Siggaard <troels@siggaard.com>, 2019\n"
|
||||||
|
"Language-Team: Danish (https://www.transifex.com/grocy/teams/93189/da/)\n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
|
"Language: da\n"
|
||||||
|
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||||
|
"X-Domain: grocy/stock_transaction_types\n"
|
||||||
|
|
||||||
|
msgid "purchase"
|
||||||
|
msgstr "køb"
|
||||||
|
|
||||||
|
msgid "consume"
|
||||||
|
msgstr "forbrug"
|
||||||
|
|
||||||
|
msgid "inventory-correction"
|
||||||
|
msgstr "beholdningsrettelse"
|
||||||
|
|
||||||
|
msgid "product-opened"
|
||||||
|
msgstr "produkt-åbnet"
|
@@ -1,348 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
return array(
|
|
||||||
'Stock overview' => 'Beholdnings oversigt',
|
|
||||||
'#1 products expiring within the next #2 days' => '#1 produkter der udløber inden for de næste #2 dage',
|
|
||||||
'#1 products are already expired' => '#1 produkter er allerede udløbede',
|
|
||||||
'#1 products are below defined min. stock amount' => 'Beholdningen af #1 produkter er under minimums antallet',
|
|
||||||
'Product' => 'Produkt',
|
|
||||||
'Amount' => 'Mængde',
|
|
||||||
'Next best before date' => 'Næste bedst før dato',
|
|
||||||
'Logout' => 'Log ud',
|
|
||||||
'Chores overview' => 'Pligt oversigt',
|
|
||||||
'Batteries overview' => 'Batteri oversigt',
|
|
||||||
'Purchase' => 'Køb',
|
|
||||||
'Consume' => 'Brug',
|
|
||||||
'Inventory' => 'Beholdning',
|
|
||||||
'Shopping list' => 'Indkøbsliste',
|
|
||||||
'Chore tracking' => 'Pligt overvågning',
|
|
||||||
'Battery tracking' => 'Batteri overvågning',
|
|
||||||
'Products' => 'Produkter',
|
|
||||||
'Locations' => 'Steder',
|
|
||||||
'Quantity units' => 'Mængde enheder',
|
|
||||||
'Chores' => 'Pligter',
|
|
||||||
'Batteries' => 'Batterier',
|
|
||||||
'Chore' => 'Pligt',
|
|
||||||
'Next estimated tracking' => 'Next estimated tracking',
|
|
||||||
'Last tracked' => 'Sidst overvåget',
|
|
||||||
'Battery' => 'Batteri',
|
|
||||||
'Last charged' => 'Sidst opladt',
|
|
||||||
'Next planned charge cycle' => 'Næste planlagte opladning',
|
|
||||||
'Best before' => 'Bedst før',
|
|
||||||
'OK' => 'OK',
|
|
||||||
'Product overview' => 'Produkt oversigt',
|
|
||||||
'Stock quantity unit' => 'Standard enhed',
|
|
||||||
'Stock amount' => 'Standard mængde',
|
|
||||||
'Last purchased' => 'Sidst købt',
|
|
||||||
'Last used' => 'Sidst brugt',
|
|
||||||
'Spoiled' => 'Udløbet',
|
|
||||||
'Barcode lookup is disabled' => 'Stregkode opslag er slået fra',
|
|
||||||
'will be added to the list of barcodes for the selected product on submit' => 'Bliver tilføjet til stregkodelisten for det valgte produkt når du sender',
|
|
||||||
'New amount' => 'Ny mængde',
|
|
||||||
'Note' => 'Note',
|
|
||||||
'Tracked time' => 'Overvåget tid',
|
|
||||||
'Chore overview' => 'Pligt oversigt',
|
|
||||||
'Tracked count' => 'Antal overvågede',
|
|
||||||
'Battery overview' => 'Batteri oversigt',
|
|
||||||
'Charge cycles count' => 'Antal opladninger',
|
|
||||||
'Create shopping list item' => 'Lav indkøbsliste punkt',
|
|
||||||
'Edit shopping list item' => 'Ændr indkøbsliste punkt',
|
|
||||||
'Save' => 'Gem',
|
|
||||||
'Add' => 'Tilføj',
|
|
||||||
'Name' => 'Navn',
|
|
||||||
'Location' => 'Sted',
|
|
||||||
'Min. stock amount' => 'Mindste beholdning',
|
|
||||||
'QU purchase' => 'QU køb',
|
|
||||||
'QU stock' => 'QU beholdning',
|
|
||||||
'QU factor' => 'QU factor',
|
|
||||||
'Description' => 'Beskrivelse',
|
|
||||||
'Create product' => 'Lav produkt',
|
|
||||||
'Barcode(s)' => 'Stegkode(r)',
|
|
||||||
'Minimum stock amount' => 'Minimum mængde',
|
|
||||||
'Default best before days' => 'Standard bedst før dage',
|
|
||||||
'Quantity unit purchase' => 'Quantity unit purchase',
|
|
||||||
'Quantity unit stock' => 'Quantity unit stock',
|
|
||||||
'Factor purchase to stock quantity unit' => 'Factor purchase to stock quantity unit',
|
|
||||||
'Create location' => 'Lav placering',
|
|
||||||
'Create quantity unit' => 'Lav mængde enhed',
|
|
||||||
'Period type' => 'Periode type',
|
|
||||||
'Period days' => 'Period days',
|
|
||||||
'Create chore' => 'Lav pligt',
|
|
||||||
'Used in' => 'Brugt i',
|
|
||||||
'Create battery' => 'Lav batteri',
|
|
||||||
'Edit battery' => 'Ændr batteri',
|
|
||||||
'Edit chore' => 'Ændr pligt',
|
|
||||||
'Edit quantity unit' => 'Ændr mængde enhed',
|
|
||||||
'Edit product' => 'Ændr produkt',
|
|
||||||
'Edit location' => 'Ændr placering',
|
|
||||||
'Record data' => 'Optag data',
|
|
||||||
'Manage master data' => 'Manage master data',
|
|
||||||
'This will apply to added products' => 'Dette vil gælde tilføjede produkter',
|
|
||||||
'never' => 'aldrig',
|
|
||||||
'Add products that are below defined min. stock amount' => 'Tilføj produkter der er under minimumsantallet',
|
|
||||||
'For purchases this amount of days will be added to today for the best before date suggestion' => 'For purchases this amount of days will be added to today for the best before date suggestion',
|
|
||||||
'This means 1 #1 purchased will be converted into #2 #3 in stock' => 'Dette betyder at 1 #1 bliver lavet om til #2 #3 i beholdningen',
|
|
||||||
'Login' => 'Login',
|
|
||||||
'Username' => 'Brugernavn',
|
|
||||||
'Password' => 'Kode',
|
|
||||||
'Invalid credentials, please try again' => 'Ugyldige informationer, prøv igen',
|
|
||||||
'Are you sure to delete battery "#1"?' => 'Er du sikker på du vil slette batteriet "#1"?',
|
|
||||||
'Yes' => 'Ja',
|
|
||||||
'No' => 'Nej',
|
|
||||||
'Are you sure to delete chore "#1"?' => 'Er du sikker på du vil slette pligten "#1"?',
|
|
||||||
'"#1" could not be resolved to a product, how do you want to proceed?' => '"#1" kunne ikke findes som produkt. Hvordan vil du fortsætte?',
|
|
||||||
'Create or assign product' => 'Lav eller tilknyt produkt',
|
|
||||||
'Cancel' => 'Afbryd',
|
|
||||||
'Add as new product' => 'Tilføj som nyt produkt',
|
|
||||||
'Add as barcode to existing product' => 'Tilføj som stregkode til et eksisterende produkt',
|
|
||||||
'Add as new product and prefill barcode' => 'Tilføj som nyt produkt og udfyld stregkoden på forhånd',
|
|
||||||
'Are you sure to delete quantity unit "#1"?' => 'Er du sikker på du vil slette mængde enheden "#1"?',
|
|
||||||
'Are you sure to delete product "#1"?' => 'Er du sikker på du vil slette produktet "#1"?',
|
|
||||||
'Are you sure to delete location "#1"?' => 'Er du sikker på du vil slette placeringen "#1"?',
|
|
||||||
'Manage API keys' => 'Styr API nøgler',
|
|
||||||
'REST API & data model documentation' => 'REST API & datamodel dokumentation',
|
|
||||||
'API keys' => 'API nøgler',
|
|
||||||
'Create new API key' => 'Lav ny API nøgle',
|
|
||||||
'API key' => 'API nøgle',
|
|
||||||
'Expires' => 'Udløber',
|
|
||||||
'Created' => 'Lavet',
|
|
||||||
'This product is not in stock' => 'Dette produkt er ikke i beholdningen',
|
|
||||||
'This means #1 will be added to stock' => 'Dette betyder #1 bliver tilføjet til beholdningen',
|
|
||||||
'This means #1 will be removed from stock' => 'Dette betyder at #1 bliver fjernet fra beholdningen',
|
|
||||||
'This means it is estimated that a new execution of this chore is tracked #1 days after the last was tracked' => 'This means it is estimated that a new execution of this chore is tracked #1 days after the last was tracked',
|
|
||||||
'Removed #1 #2 of #3 from stock' => 'Fjernede #1 #2 af #3 fra beholdningen',
|
|
||||||
'About grocy' => 'Omkring Grocy',
|
|
||||||
'Close' => 'Luk',
|
|
||||||
'#1 batteries are due to be charged within the next #2 days' => '#1 batterier skal oplades indenfor de næste #2 dage',
|
|
||||||
'#1 batteries are overdue to be charged' => '#1 batterier trænger til at blive opladt',
|
|
||||||
'#1 chores are due to be done within the next #2 days' => '#1 pligter skal udfyldes indenfor de næste #2 dage',
|
|
||||||
'#1 chores are overdue to be done' => '#1 pligter skulle have været gjort',
|
|
||||||
'Released on' => 'Released on',
|
|
||||||
'Consume #3 #1 of #2' => 'Brug #3 #1 af #2',
|
|
||||||
'Added #1 #2 of #3 to stock' => 'Tilføjede #1 #2 af #3 til beholdningen',
|
|
||||||
'Stock amount of #1 is now #2 #3' => 'Mængden af #1 er nu #2 #3',
|
|
||||||
'Tracked execution of chore #1 on #2' => 'Overvågede udførslen af pligt #1 på #2',
|
|
||||||
'Tracked charge cycle of battery #1 on #2' => 'Tracked charge cycle of battery #1 on #2',
|
|
||||||
'Consume all #1 which are currently in stock' => 'Brug alle #1 i beholdningen',
|
|
||||||
'All' => 'Alle',
|
|
||||||
'Track charge cycle of battery #1' => 'Overvåg opladningscyklus af batteri #1',
|
|
||||||
'Track execution of chore #1' => 'Track execution of chore #1',
|
|
||||||
'Filter by location' => 'Filtre med placering',
|
|
||||||
'Search' => 'Søg',
|
|
||||||
'Not logged in' => 'Ikke logget ind',
|
|
||||||
'You have to select a product' => 'Du skal vælge et produkt',
|
|
||||||
'You have to select a chore' => 'Du skal vælge en pligt',
|
|
||||||
'You have to select a battery' => 'Du skal vælge et batteri',
|
|
||||||
'A name is required' => 'Du skal vælge et navn',
|
|
||||||
'A location is required' => 'Du skal vælge en placering',
|
|
||||||
'The amount cannot be lower than #1' => 'Mængden kan ikek kvære lavere end #1',
|
|
||||||
'This cannot be negative' => 'Dette kan ikke være negativt',
|
|
||||||
'A quantity unit is required' => 'Du skal vælge en enhed for mængden',
|
|
||||||
'A period type is required' => 'Du skal vælge en slags periode',
|
|
||||||
'A best before date is required and must be later than today' => 'Du skal vælge en bedst før dato som er senere end i dag',
|
|
||||||
'Settings' => 'Indstillinger',
|
|
||||||
'This can only be before now' => 'Dette skal være før nu',
|
|
||||||
'Calendar' => 'Kalender',
|
|
||||||
'Recipes' => 'Opskrifter',
|
|
||||||
'Edit recipe' => 'Ændr opskrift',
|
|
||||||
'New recipe' => 'Ny opskrift',
|
|
||||||
'Ingredients list' => 'Ingrediens liste',
|
|
||||||
'Add recipe ingredient' => 'Tilføj ingrediens til opskrift',
|
|
||||||
'Edit recipe ingredient' => 'Ændr ingrediens til opskrift',
|
|
||||||
'Are you sure to delete recipe "#1"?' => 'Er du sikker på du vil slette opskriften "#1"?',
|
|
||||||
'Are you sure to delete recipe ingredient "#1"?' => 'Er du sikker på du vil slette ingrediensen "#1" fra opskriften?',
|
|
||||||
'Are you sure to empty the shopping list?' => 'Er du sikker på du vil tømme indkøbslisten?',
|
|
||||||
'Clear list' => 'Ryd liste',
|
|
||||||
'Requirements fulfilled' => 'Skal udfyldes',
|
|
||||||
'Put missing products on shopping list' => 'Sæt manglende produkter på en indkøbsliste',
|
|
||||||
'Not enough in stock, #1 ingredients missing' => 'Der er ikke nok i beholdningen. Der mangler #1 ingredienser. ',
|
|
||||||
'Enough in stock' => 'Der er nok i beholdningen',
|
|
||||||
'Not enough in stock, #1 ingredients missing but already on the shopping list' => 'Der er ikke nok i beholdningen. Der mangler #1 ingredienser som allerede er på indkøbslisten',
|
|
||||||
'Expand to fullscreen' => 'Udvid til fuldskærm',
|
|
||||||
'Ingredients' => 'Ingredienser',
|
|
||||||
'Preparation' => 'Tilberedning',
|
|
||||||
'Recipe' => 'Opskrift',
|
|
||||||
'Not enough in stock, #1 missing, #2 already on shopping list' => 'Der er ikke nok i beholdningen. Der mangler #1, #2 er allerede i beholdningen',
|
|
||||||
'Show notes' => 'Vis noter',
|
|
||||||
'Put missing amount on shopping list' => 'Put manglende mængde på indkøbsliste',
|
|
||||||
'Are you sure to put all missing ingredients for recipe "#1" on the shopping list?' => 'Er du sikker på du vil sætte alle manglende ingredienser til "#1" på indkøbslisten?',
|
|
||||||
'Added for recipe #1' => 'Tilføjet til opskriften #1',
|
|
||||||
'Manage users' => 'Manage users',
|
|
||||||
'User' => 'Bruger',
|
|
||||||
'Users' => 'Brugere',
|
|
||||||
'Are you sure to delete user "#1"?' => 'Er du sikker på du vil slette brugeren "#1"?',
|
|
||||||
'Create user' => 'Lav bruger',
|
|
||||||
'Edit user' => 'Ændr bruger',
|
|
||||||
'First name' => 'First name',
|
|
||||||
'Last name' => 'Last name',
|
|
||||||
'A username is required' => 'A username is required',
|
|
||||||
'Confirm password' => 'Confirm password',
|
|
||||||
'Passwords do not match' => 'Passwords do not match',
|
|
||||||
'Change password' => 'Change password',
|
|
||||||
'Done by' => 'Done by',
|
|
||||||
'Last done by' => 'Last done by',
|
|
||||||
'Unknown' => 'Unknown',
|
|
||||||
'Filter by chore' => 'Filter by chore',
|
|
||||||
'Chores journal' => 'Chores journal',
|
|
||||||
'0 means suggestions for the next charge cycle are disabled' => '0 means suggestions for the next charge cycle are disabled',
|
|
||||||
'Charge cycle interval (days)' => 'Charge cycle interval (days)',
|
|
||||||
'Last price' => 'Last price',
|
|
||||||
'Price history' => 'Price history',
|
|
||||||
'No price history available' => 'No price history available',
|
|
||||||
'Price' => 'Price',
|
|
||||||
'in #1 per purchase quantity unit' => 'in #1 per purchase quantity unit',
|
|
||||||
'The price cannot be lower than #1' => 'The price cannot be lower than #1',
|
|
||||||
'#1 product expires within the next #2 days' => '#1 product expires within the next #2 days',
|
|
||||||
'#1 product is already expired' => '#1 product is already expired',
|
|
||||||
'#1 product is below defined min. stock amount' => '#1 product is below defined min. stock amount',
|
|
||||||
'Unit' => 'Unit',
|
|
||||||
'Units' => 'Units',
|
|
||||||
'#1 chore is due to be done within the next #2 days' => '#1 chore is due to be done within the next #2 days',
|
|
||||||
'#1 chore is overdue to be done' => '#1 chore is overdue to be done',
|
|
||||||
'#1 battery is due to be charged within the next #2 days' => '#1 battery is due to be charged within the next #2 days',
|
|
||||||
'#1 battery is overdue to be charged' => '#1 battery is overdue to be charged',
|
|
||||||
'#1 unit was automatically added and will apply in addition to the amount entered here' => '#1 unit was automatically added and will apply in addition to the amount entered here',
|
|
||||||
'in singular form' => 'in singular form',
|
|
||||||
'in plural form' => 'in plural form',
|
|
||||||
'Never expires' => 'Never expires',
|
|
||||||
'This cannot be lower than #1' => 'This cannot be lower than #1',
|
|
||||||
'-1 means that this product never expires' => '-1 means that this product never expires',
|
|
||||||
'Quantity unit' => 'Quantity unit',
|
|
||||||
'Only check if a single unit is in stock (a different quantity can then be used above)' => 'Only check if a single unit is in stock (a different quantity can then be used above)',
|
|
||||||
'Are you sure to consume all ingredients needed by recipe "#1" (ingredients marked with "check only if a single unit is in stock" will be ignored)?' => 'Are you sure to consume all ingredients needed by recipe "#1" (ingredients marked with "check only if a single unit is in stock" will be ignored)?',
|
|
||||||
'Removed all ingredients of recipe "#1" from stock' => 'Removed all ingredients of recipe "#1" from stock',
|
|
||||||
'Consume all ingredients needed by this recipe' => 'Consume all ingredients needed by this recipe',
|
|
||||||
'Click to show technical details' => 'Click to show technical details',
|
|
||||||
'Error while saving, probably this item already exists' => 'Error while saving, probably this item already exists',
|
|
||||||
'Error details' => 'Error details',
|
|
||||||
'Tasks' => 'Tasks',
|
|
||||||
'Show done tasks' => 'Show done tasks',
|
|
||||||
'Task' => 'Task',
|
|
||||||
'Due' => 'Due',
|
|
||||||
'Assigned to' => 'Assigned to',
|
|
||||||
'Mark task "#1" as completed' => 'Mark task "#1" as completed',
|
|
||||||
'Uncategorized' => 'Uncategorized',
|
|
||||||
'Task categories' => 'Task categories',
|
|
||||||
'Create task' => 'Create task',
|
|
||||||
'A due date is required' => 'A due date is required',
|
|
||||||
'Category' => 'Category',
|
|
||||||
'Edit task' => 'Edit task',
|
|
||||||
'Are you sure to delete task "#1"?' => 'Are you sure to delete task "#1"?',
|
|
||||||
'#1 task is due to be done within the next #2 days' => '#1 task is due to be done within the next #2 days',
|
|
||||||
'#1 tasks are due to be done within the next #2 days' => '#1 tasks are due to be done within the next #2 days',
|
|
||||||
'#1 task is overdue to be done' => '#1 task is overdue to be done',
|
|
||||||
'#1 tasks are overdue to be done' => '#1 tasks are overdue to be done',
|
|
||||||
'Edit task category' => 'Edit task category',
|
|
||||||
'Create task category' => 'Create task category',
|
|
||||||
'Product groups' => 'Product groups',
|
|
||||||
'Ungrouped' => 'Ungrouped',
|
|
||||||
'Create product group' => 'Create product group',
|
|
||||||
'Edit product group' => 'Edit product group',
|
|
||||||
'Product group' => 'Product group',
|
|
||||||
'Are you sure to delete product group "#1"?' => 'Are you sure to delete product group "#1"?',
|
|
||||||
'Stay logged in permanently' => 'Stay logged in permanently',
|
|
||||||
'When not set, you will get logged out at latest after 30 days' => 'When not set, you will get logged out at latest after 30 days',
|
|
||||||
'Filter by status' => 'Filter by status',
|
|
||||||
'Below min. stock amount' => 'Below min. stock amount',
|
|
||||||
'Expiring soon' => 'Expiring soon',
|
|
||||||
'Already expired' => 'Already expired',
|
|
||||||
'Due soon' => 'Due soon',
|
|
||||||
'Overdue' => 'Overdue',
|
|
||||||
'View settings' => 'View settings',
|
|
||||||
'Auto reload on external changes' => 'Auto reload on external changes',
|
|
||||||
'Enable night mode' => 'Enable night mode',
|
|
||||||
'Auto enable in time range' => 'Auto enable in time range',
|
|
||||||
'From' => 'From',
|
|
||||||
'in format' => 'in format',
|
|
||||||
'To' => 'To',
|
|
||||||
'Time range goes over midnight' => 'Time range goes over midnight',
|
|
||||||
'Product picture' => 'Product picture',
|
|
||||||
'No file selected' => 'No file selected',
|
|
||||||
'If you don\'t select a file, the current picture will not be altered' => 'If you don\'t select a file, the current picture will not be altered',
|
|
||||||
'Delete' => 'Delete',
|
|
||||||
'The current picture will be deleted when you save the product' => 'The current picture will be deleted when you save the product',
|
|
||||||
'Select file' => 'Select file',
|
|
||||||
'Image of product #1' => 'Image of product #1',
|
|
||||||
'This product cannot be deleted because it is in stock, please remove the stock amount first.' => 'This product cannot be deleted because it is in stock, please remove the stock amount first.',
|
|
||||||
'Delete not possible' => 'Delete not possible',
|
|
||||||
'Equipment' => 'Equipment',
|
|
||||||
'Instruction manual' => 'Instruction manual',
|
|
||||||
'The selected equipment has no instruction manual' => 'The selected equipment has no instruction manual',
|
|
||||||
'Notes' => 'Notes',
|
|
||||||
'Edit equipment' => 'Edit equipment',
|
|
||||||
'Create equipment' => 'Create equipment',
|
|
||||||
'If you don\'t select a file, the current instruction manual will not be altered' => 'If you don\'t select a file, the current instruction manual will not be altered',
|
|
||||||
'No instruction manual available' => 'No instruction manual available',
|
|
||||||
'The current instruction manual will be deleted when you save the equipment' => 'The current instruction manual will be deleted when you save the equipment',
|
|
||||||
'No picture available' => 'No picture available',
|
|
||||||
'Filter by product group' => 'Filter by product group',
|
|
||||||
'Presets for new products' => 'Presets for new products',
|
|
||||||
'Included recipes' => 'Included recipes',
|
|
||||||
'A recipe is required' => 'A recipe is required',
|
|
||||||
'Add included recipe' => 'Add included recipe',
|
|
||||||
'Edit included recipe' => 'Edit included recipe',
|
|
||||||
'Group' => 'Group',
|
|
||||||
'This will be used as a headline to group ingredients together' => 'This will be used as a headline to group ingredients together',
|
|
||||||
'Journal' => 'Journal',
|
|
||||||
'Stock journal' => 'Stock journal',
|
|
||||||
'Filter by product' => 'Filter by product',
|
|
||||||
'Booking time' => 'Booking time',
|
|
||||||
'Booking type' => 'Booking type',
|
|
||||||
'Undo booking' => 'Undo booking',
|
|
||||||
'Undone on' => 'Undone on',
|
|
||||||
'Batteries journal' => 'Batteries journal',
|
|
||||||
'Filter by battery' => 'Filter by battery',
|
|
||||||
'Undo charge cycle' => 'Undo charge cycle',
|
|
||||||
'Undo chore execution' => 'Undo chore execution',
|
|
||||||
'Chore execution successfully undone' => 'Chore execution successfully undone',
|
|
||||||
'Undo' => 'Undo',
|
|
||||||
'Booking successfully undone' => 'Booking successfully undone',
|
|
||||||
'Charge cycle successfully undone' => 'Charge cycle successfully undone',
|
|
||||||
'This cannot be negative and must be an integral number' => 'This cannot be negative and must be an integral number',
|
|
||||||
'Disable stock fulfillment checking for this ingredient' => 'Disable stock fulfillment checking for this ingredient',
|
|
||||||
'Add all list items to stock' => 'Add all list items to stock',
|
|
||||||
'Add #3 #1 of #2 to stock' => 'Add #3 #1 of #2 to stock',
|
|
||||||
'Adding shopping list item #1 of #2' => 'Adding shopping list item #1 of #2',
|
|
||||||
'Use a specific stock item' => 'Use a specific stock item',
|
|
||||||
'The first item in this list would be picked by the default rule which is "First expiring first, then first in first out"' => 'The first item in this list would be picked by the default rule which is "First expiring first, then first in first out"',
|
|
||||||
'Mark #3 #1 of #2 as open' => 'Mark #3 #1 of #2 as open',
|
|
||||||
'When a product was marked as opened, the best before date will be replaced by today + this amount of days (a value of 0 disables this)' => 'When a product was marked as opened, the best before date will be replaced by today + this amount of days (a value of 0 disables this)',
|
|
||||||
'Default best before days after opened' => 'Default best before days after opened',
|
|
||||||
'Marked #1 #2 of #3 as opened' => 'Marked #1 #2 of #3 as opened',
|
|
||||||
'Mark as opened' => 'Mark as opened',
|
|
||||||
'Expires on #1; Bought on #2' => 'Expires on #1; Bought on #2',
|
|
||||||
'Not opened' => 'Not opened',
|
|
||||||
'Opened' => 'Opened',
|
|
||||||
'Mark #3 #1 of #2 as open' => 'Mark #3 #1 of #2 as open',
|
|
||||||
'#1 opened' => '#1 opened',
|
|
||||||
'Product expires' => 'Product expires',
|
|
||||||
'Task due' => 'Task due',
|
|
||||||
'Chore due' => 'Chore due',
|
|
||||||
'Battery charge cycle due' => 'Battery charge cycle due',
|
|
||||||
'Show clock in header' => 'Show clock in header',
|
|
||||||
'Stock settings' => 'Stock settings',
|
|
||||||
'Shopping list to stock workflow' => 'Shopping list to stock workflow',
|
|
||||||
'Automatically do the booking using the last price and the amount of the shopping list item, if the product has "Default best before days" set' => 'Automatically do the booking using the last price and the amount of the shopping list item, if the product has "Default best before days" set',
|
|
||||||
'Skip' => 'Skip',
|
|
||||||
'Servings' => 'Servings',
|
|
||||||
'Costs' => 'Costs',
|
|
||||||
'Based on the prices of the last purchase per product' => 'Based on the prices of the last purchase per product',
|
|
||||||
'The ingredients listed here result in this amount of servings' => 'The ingredients listed here result in this amount of servings',
|
|
||||||
'Do not check against the shopping list when adding missing items to it' => 'Do not check against the shopping list when adding missing items to it',
|
|
||||||
'By default the amount to be added to the shopping list is "needed amount - stock amount - shopping list amount" - when this is enabled, it is only checked against the stock amount, not against what is already on the shopping list' => 'By default the amount to be added to the shopping list is "needed amount - stock amount - shopping list amount" - when this is enabled, it is only checked against the stock amount, not against what is already on the shopping list',
|
|
||||||
'Picture' => 'Picture',
|
|
||||||
'Uncheck ingredients to not put them on the shopping list' => 'Uncheck ingredients to not put them on the shopping list',
|
|
||||||
'This is for statistical purposes only' => 'This is for statistical purposes only',
|
|
||||||
'You have to select a recipe' => 'You have to select a recipe',
|
|
||||||
'Key type' => 'Key type',
|
|
||||||
'Share/Integrate calendar (iCal)' => 'Share/Integrate calendar (iCal)',
|
|
||||||
'Use the following (public) URL to share or integrate the calendar in iCal format' => 'Use the following (public) URL to share or integrate the calendar in iCal format',
|
|
||||||
'Allow partial units in stock' => 'Allow partial units in stock',
|
|
||||||
'Enable tare weight handling' => 'Enable tare weight handling',
|
|
||||||
'This is useful e.g. for flour in jars - on purchase/consume/inventory you always weigh the whole jar, the amount to be posted is then automatically calculated based on what is in stock and the tare weight defined below' => 'This is useful e.g. for flour in jars - on purchase/consume/inventory you always weigh the whole jar, the amount to be posted is then automatically calculated based on what is in stock and the tare weight defined below',
|
|
||||||
'Tare weight' => 'Tare weight',
|
|
||||||
'Tare weight handling enabled - please weigh the whole container, the amount to be posted will be automatically calculcated' => 'Tare weight handling enabled - please weigh the whole container, the amount to be posted will be automatically calculcated',
|
|
||||||
'You have to select a location' => 'You have to select a location',
|
|
||||||
'List' => 'List',
|
|
||||||
'Gallery' => 'Gallery'
|
|
||||||
);
|
|
1252
localization/da/strings.po
Normal file
1252
localization/da/strings.po
Normal file
File diff suppressed because it is too large
Load Diff
35
localization/da/userfield_types.po
Normal file
35
localization/da/userfield_types.po
Normal file
@@ -0,0 +1,35 @@
|
|||||||
|
#
|
||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: \n"
|
||||||
|
"Report-Msgid-Bugs-To: \n"
|
||||||
|
"POT-Creation-Date: 2019-05-01T17:59:17+00:00\n"
|
||||||
|
"PO-Revision-Date: 2019-05-01 17:43+0000\n"
|
||||||
|
"Language-Team: Danish (https://www.transifex.com/grocy/teams/93189/da/)\n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
|
"Language: da\n"
|
||||||
|
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||||
|
"X-Domain: grocy/userfield_types\n"
|
||||||
|
|
||||||
|
msgid "text-single-line"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "text-multi-line"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "number-integral"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "number-decimal"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "date"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "datetime"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
msgid "checkbox"
|
||||||
|
msgstr ""
|
29
localization/de/chore_assignment_types.po
Normal file
29
localization/de/chore_assignment_types.po
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
# Translators:
|
||||||
|
# Bernd Bestel <bernd@berrnd.de>, 2019
|
||||||
|
#
|
||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: \n"
|
||||||
|
"Report-Msgid-Bugs-To: \n"
|
||||||
|
"POT-Creation-Date: 2019-05-01T17:59:17+00:00\n"
|
||||||
|
"PO-Revision-Date: 2019-09-17 10:45+0000\n"
|
||||||
|
"Last-Translator: Bernd Bestel <bernd@berrnd.de>, 2019\n"
|
||||||
|
"Language-Team: German (https://www.transifex.com/grocy/teams/93189/de/)\n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
|
"Language: de\n"
|
||||||
|
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||||
|
"X-Domain: grocy/chore_assignment_types\n"
|
||||||
|
|
||||||
|
msgid "no-assignment"
|
||||||
|
msgstr "Niemandem zuweisen"
|
||||||
|
|
||||||
|
msgid "who-least-did-first"
|
||||||
|
msgstr "Wer es am seltensten gemacht hat zuerst"
|
||||||
|
|
||||||
|
msgid "random"
|
||||||
|
msgstr "Zufällig"
|
||||||
|
|
||||||
|
msgid "in-alphabetical-order"
|
||||||
|
msgstr "In alphabetischer Reihenfolge"
|
32
localization/de/chore_period_types.po
Normal file
32
localization/de/chore_period_types.po
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
# Translators:
|
||||||
|
# Bernd Bestel <bernd@berrnd.de>, 2019
|
||||||
|
#
|
||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: \n"
|
||||||
|
"Report-Msgid-Bugs-To: \n"
|
||||||
|
"POT-Creation-Date: 2019-05-01T17:59:17+00:00\n"
|
||||||
|
"PO-Revision-Date: 2019-05-01 17:42+0000\n"
|
||||||
|
"Last-Translator: Bernd Bestel <bernd@berrnd.de>, 2019\n"
|
||||||
|
"Language-Team: German (https://www.transifex.com/grocy/teams/93189/de/)\n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
|
"Language: de\n"
|
||||||
|
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||||
|
"X-Domain: grocy/chore_types\n"
|
||||||
|
|
||||||
|
msgid "manually"
|
||||||
|
msgstr "Manuell"
|
||||||
|
|
||||||
|
msgid "dynamic-regular"
|
||||||
|
msgstr "Dynamisch regelmäßig"
|
||||||
|
|
||||||
|
msgid "daily"
|
||||||
|
msgstr "Täglich"
|
||||||
|
|
||||||
|
msgid "weekly"
|
||||||
|
msgstr "Wöchentlich"
|
||||||
|
|
||||||
|
msgid "monthly"
|
||||||
|
msgstr "Monatlich"
|
@@ -1,6 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
return array(
|
|
||||||
'manually' => 'Manuell',
|
|
||||||
'dynamic-regular' => 'Dynamisch regelmäßig'
|
|
||||||
);
|
|
@@ -1,10 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
return array(
|
|
||||||
'timeago_locale' => 'de',
|
|
||||||
'timeago_nan' => 'vor NaN Jahren',
|
|
||||||
'moment_locale' => 'de',
|
|
||||||
'datatables_localization' => '{"sEmptyTable":"Keine Daten in der Tabelle vorhanden","sInfo":"_START_ bis _END_ von _TOTAL_ Einträgen","sInfoEmpty":"Keine Daten vorhanden","sInfoFiltered":"(gefiltert von _MAX_ Einträgen)","sInfoPostFix":"","sInfoThousands":".","sLengthMenu":"_MENU_ Einträge anzeigen","sLoadingRecords":"Wird geladen ..","sProcessing":"Bitte warten ..","sSearch":"Suchen","sZeroRecords":"Keine Einträge vorhanden","oPaginate":{"sFirst":"Erste","sPrevious":"Zurück","sNext":"Nächste","sLast":"Letzte"},"oAria":{"sSortAscending":": aktivieren, um Spalte aufsteigend zu sortieren","sSortDescending":": aktivieren, um Spalte absteigend zu sortieren"},"select":{"rows":{"0":"Zum Auswählen auf eine Zeile klicken","1":"1 Zeile ausgewählt","_":"%d Zeilen ausgewählt"}},"buttons":{"print":"Drucken","colvis":"Spalten","copy":"Kopieren","copyTitle":"In Zwischenablage kopieren","copyKeys":"Taste <i>ctrl</i> oder <i>⌘</i> + <i>C</i> um Tabelle<br>in Zwischenspeicher zu kopieren.<br><br>Um abzubrechen die Nachricht anklicken oder Escape drücken.","copySuccess":{"1":"1 Spalte kopiert","_":"%d Spalten kopiert"}}}',
|
|
||||||
'summernote_locale' => 'de-DE',
|
|
||||||
'fullcalendar_locale' => 'de'
|
|
||||||
);
|
|
57
localization/de/component_translations.po
Normal file
57
localization/de/component_translations.po
Normal file
@@ -0,0 +1,57 @@
|
|||||||
|
# Translators:
|
||||||
|
# Bernd Bestel <bernd@berrnd.de>, 2019
|
||||||
|
#
|
||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: \n"
|
||||||
|
"Report-Msgid-Bugs-To: \n"
|
||||||
|
"POT-Creation-Date: 2019-05-01T17:59:17+00:00\n"
|
||||||
|
"PO-Revision-Date: 2019-05-01 17:42+0000\n"
|
||||||
|
"Last-Translator: Bernd Bestel <bernd@berrnd.de>, 2019\n"
|
||||||
|
"Language-Team: German (https://www.transifex.com/grocy/teams/93189/de/)\n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
|
"Language: de\n"
|
||||||
|
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||||
|
"X-Domain: grocy/component_translations\n"
|
||||||
|
|
||||||
|
msgid "timeago_locale"
|
||||||
|
msgstr "de"
|
||||||
|
|
||||||
|
msgid "timeago_nan"
|
||||||
|
msgstr "vor NaN Jahren"
|
||||||
|
|
||||||
|
msgid "moment_locale"
|
||||||
|
msgstr "de"
|
||||||
|
|
||||||
|
msgid "datatables_localization"
|
||||||
|
msgstr ""
|
||||||
|
"{\"sEmptyTable\":\"Keine Daten in der Tabelle "
|
||||||
|
"vorhanden\",\"sInfo\":\"_START_ bis _END_ von _TOTAL_ "
|
||||||
|
"Einträgen\",\"sInfoEmpty\":\"Keine Daten "
|
||||||
|
"vorhanden\",\"sInfoFiltered\":\"(gefiltert von _MAX_ "
|
||||||
|
"Einträgen)\",\"sInfoPostFix\":\"\",\"sInfoThousands\":\".\",\"sLengthMenu\":\"_MENU_"
|
||||||
|
" Einträge anzeigen\",\"sLoadingRecords\":\"Wird geladen "
|
||||||
|
"..\",\"sProcessing\":\"Bitte warten "
|
||||||
|
"..\",\"sSearch\":\"Suchen\",\"sZeroRecords\":\"Keine Einträge "
|
||||||
|
"vorhanden\",\"oPaginate\":{\"sFirst\":\"Erste\",\"sPrevious\":\"Zurück\",\"sNext\":\"Nächste\",\"sLast\":\"Letzte\"},\"oAria\":{\"sSortAscending\":\":"
|
||||||
|
" aktivieren, um Spalte aufsteigend zu sortieren\",\"sSortDescending\":\": "
|
||||||
|
"aktivieren, um Spalte absteigend zu "
|
||||||
|
"sortieren\"},\"select\":{\"rows\":{\"0\":\"Zum Auswählen auf eine Zeile "
|
||||||
|
"klicken\",\"1\":\"1 Zeile ausgewählt\",\"_\":\"%d Zeilen "
|
||||||
|
"ausgewählt\"}},\"buttons\":{\"print\":\"Drucken\",\"colvis\":\"Spalten\",\"copy\":\"Kopieren\",\"copyTitle\":\"In"
|
||||||
|
" Zwischenablage kopieren\",\"copyKeys\":\"Taste <i>ctrl</i> oder <i>⌘</i> + "
|
||||||
|
"<i>C</i> um Tabelle<br>in Zwischenspeicher zu kopieren.<br><br>Um "
|
||||||
|
"abzubrechen die Nachricht anklicken oder Escape "
|
||||||
|
"drücken.\",\"copySuccess\":{\"1\":\"1 Spalte kopiert\",\"_\":\"%d Spalten "
|
||||||
|
"kopiert\"}}}"
|
||||||
|
|
||||||
|
msgid "summernote_locale"
|
||||||
|
msgstr "de-DE"
|
||||||
|
|
||||||
|
msgid "fullcalendar_locale"
|
||||||
|
msgstr "de"
|
||||||
|
|
||||||
|
msgid "bootstrap-select_locale"
|
||||||
|
msgstr "de_DE"
|
@@ -1,89 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
return array(
|
|
||||||
'Cookies' => 'Cookies',
|
|
||||||
'Chocolate' => 'Schokolade',
|
|
||||||
'Pantry' => 'Vorratskammer',
|
|
||||||
'Candy cupboard' => 'Süßigkeitenschrank',
|
|
||||||
'Tinned food cupboard' => 'Konservenschrank',
|
|
||||||
'Fridge' => 'Kühlschrank',
|
|
||||||
'Piece' => 'Stück',
|
|
||||||
'Pieces' => 'Stücke',
|
|
||||||
'Pack' => 'Packung',
|
|
||||||
'Packs' => 'Packungen',
|
|
||||||
'Glass' => 'Glas',
|
|
||||||
'Glasses' => 'Gläser',
|
|
||||||
'Tin' => 'Dose',
|
|
||||||
'Tins' => 'Dosen',
|
|
||||||
'Can' => 'Becher',
|
|
||||||
'Cans' => 'Becher',
|
|
||||||
'Bunch' => 'Bund',
|
|
||||||
'Bunches' => 'Bunde',
|
|
||||||
'Gummy bears' => 'Gummibärchen',
|
|
||||||
'Crisps' => 'Chips',
|
|
||||||
'Eggs' => 'Eier',
|
|
||||||
'Noodles' => 'Nudeln',
|
|
||||||
'Pickles' => 'Essiggurken',
|
|
||||||
'Gulash soup' => 'Gulaschsuppe',
|
|
||||||
'Yogurt' => 'Joghurt',
|
|
||||||
'Cheese' => 'Käse',
|
|
||||||
'Cold cuts' => 'Aufschnitt',
|
|
||||||
'Paprika' => 'Paprika',
|
|
||||||
'Cucumber' => 'Gurke',
|
|
||||||
'Radish' => 'Radieschen',
|
|
||||||
'Tomato' => 'Tomaten',
|
|
||||||
'Changed towels in the bathroom' => 'Handtücher im Bad gewechselt',
|
|
||||||
'Cleaned the kitchen floor' => 'Küchenboden gewischt',
|
|
||||||
'Warranty ends' => 'Garantie endet',
|
|
||||||
'TV remote control' => 'TV Fernbedienung',
|
|
||||||
'Alarm clock' => 'Wecker',
|
|
||||||
'Heat remote control' => 'Fernbedienung Heizung',
|
|
||||||
'Lawn mowed in the garden' => 'Rasen im Garten gemäht',
|
|
||||||
'Some good snacks' => 'Paar gute Snacks',
|
|
||||||
'Pizza dough' => 'Pizzateig',
|
|
||||||
'Sieved tomatoes' => 'Passierte Tomaten',
|
|
||||||
'Salami' => 'Salami',
|
|
||||||
'Toast' => 'Toast',
|
|
||||||
'Minced meat' => 'Hackfleisch',
|
|
||||||
'Pizza' => 'Pizza',
|
|
||||||
'Spaghetti bolognese' => 'Spaghetti Bolognese',
|
|
||||||
'Sandwiches' => 'Belegte Toasts',
|
|
||||||
'English' => 'Englisch',
|
|
||||||
'German' => 'Deutsch',
|
|
||||||
'Italian' => 'Italienisch',
|
|
||||||
'Demo in different language' => 'Demo in anderer Sprache',
|
|
||||||
'This is the note content of the recipe ingredient' => 'Dies ist der Inhalt der Notiz der Zutat',
|
|
||||||
'Demo User' => 'Demo Benutzer',
|
|
||||||
'Gram' => 'Gramm',
|
|
||||||
'Grams' => 'Gramm',
|
|
||||||
'Flour' => 'Mehl',
|
|
||||||
'Pancakes' => 'Pfannkuchen',
|
|
||||||
'Sugar' => 'Zucker',
|
|
||||||
'Home' => 'Zuhause',
|
|
||||||
'Life' => 'Leben',
|
|
||||||
'Projects' => 'Projekte',
|
|
||||||
'Repair the garage door' => 'Garagentor reparieren',
|
|
||||||
'Fork and improve grocy' => 'grocy forken und verbessern',
|
|
||||||
'Find a solution for what to do when I forget the door keys' => 'Eine Lösung für "Haustürschlüssel vergessen" finden',
|
|
||||||
'Sweets' => 'Süßigkeiten',
|
|
||||||
'Bakery products' => 'Bäckerei Produkte',
|
|
||||||
'Tinned food' => 'Konservern',
|
|
||||||
'Butchery products' => 'Metzgerei',
|
|
||||||
'Vegetables/Fruits' => 'Obst/Gemüse',
|
|
||||||
'Refrigerated products' => 'Kühlregal',
|
|
||||||
'Coffee machine' => 'Kaffeemaschine',
|
|
||||||
'Dishwasher' => 'Spülmaschine',
|
|
||||||
'Liter' => 'Liter',
|
|
||||||
'Liters' => 'Liter',
|
|
||||||
'Bottle' => 'Flasche',
|
|
||||||
'Bottles' => 'Flaschen',
|
|
||||||
'Milk' => 'Milch',
|
|
||||||
'Chocolate sauce' => 'Schokoladensoße',
|
|
||||||
'Milliliters' => 'Milliliter',
|
|
||||||
'Milliliter' => 'Milliliter',
|
|
||||||
'Bottom' => 'Boden',
|
|
||||||
'Topping' => 'Belag',
|
|
||||||
'French' => 'Französisch',
|
|
||||||
'Turkish' => 'Türkisch',
|
|
||||||
'Spanish' => 'Spanisch'
|
|
||||||
);
|
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user