Commit Graph

55 Commits (839ddaa3547bb0042b6225edf2df7bff1831cdd5)

Author SHA1 Message Date
Vincent Petry 839ddaa354
feat: rename users to account or person
Replace translated text in most locations

Signed-off-by: Vincent Petry <vincent@nextcloud.com>
4 months ago
provokateurin b64ab5fba8
refactor: Migrate IgnoreOpenAPI attributes to OpenAPI
Signed-off-by: provokateurin <kate@provokateurin.de>
5 months ago
Joas Schilling aa5f037af7
chore: apply changes from Nextcloud coding standards 1.1.1
Signed-off-by: Joas Schilling <coding@schilljs.com>
Signed-off-by: Benjamin Gaussorgues <benjamin.gaussorgues@nextcloud.com>
6 months ago
Christoph Wurst dd3cd29224
Merge pull request #39175 from shdehnavi/settings_app_users_controller_square_bracket_syntax
use square bracket syntax to modify array
8 months ago
jld3103 da7062b939
settings: Add OpenAPI spec
Signed-off-by: jld3103 <jld3103yt@gmail.com>
11 months ago
Hamid Dehnavi 8850c66ab8 use square bracket syntax to modify array
Signed-off-by: Hamid Dehnavi <hamid.dev.pro@gmail.com>
11 months ago
julia.kirschenheuter 0cfbe54a5a Create headings for settings pages
Signed-off-by: julia.kirschenheuter <julia.kirschenheuter@nextcloud.com>
1 year ago
Carl Schwan 7f44a66296
Fix case sensitivity of email when saving settings
Otherwise we detect a email change all the time and since email are
immutable in ldap this prevent updating other fields.

Related: https://github.com/nextcloud/server/pull/33813

Signed-off-by: Carl Schwan <carl@carlschwan.eu>
1 year ago
Carl Schwan d1209d8302 Rename mastodon to fediverse
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2 years ago
Carl Schwan 86d9626901 Add mastodon personal info field
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2 years ago
Arthur Schiwon 27865d03c0
use specific email getter where necessary
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
3 years ago
Julien Veyssier 416d10f76c refs #21045 add app config to disable unlimited quota and to set max quota
avoid unlimited quota as default_quota fallback value if unlimited quota is not allowed
avoid getting/setting/displaying unlimited default quota if not allowed
implement tests for unlimited quota restrictions

Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
Signed-off-by: npmbuildbot-nextcloud[bot] <npmbuildbot-nextcloud[bot]@users.noreply.github.com>
3 years ago
John Molakvoæ (skjnldsv) 215aef3cbd
Update php licenses
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
3 years ago
Arthur Schiwon 847ed37afc
do not use private AccountManager in UsersController
- extends IAccountProperty for verificationData getters and setters
- implementation thereof ^
- and of course adaption of UsersController

Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
3 years ago
Joas Schilling aa651fd629
Merge pull request #26259 from nextcloud/feature/noid/validate-website-to-be-valid
Validate the website field input to be a valid URL
3 years ago
Daniel Calviño Sánchez 67dd087ce4 Fix deleting properties of user settings when not given explicitly
The controller can receive an optional subset of the properties of the
user settings; values not given are set to "null" by default. However,
those null values overwrote the previously existing values, so in
practice any value not given was deleted from the user settings. Now
only non null values overwrite the previous values.

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
3 years ago
Daniel Calviño Sánchez ac0c18327e Fix TypeError when "email" is not given in the controller request
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
3 years ago
Daniel Calviño Sánchez a7431817b9 Respect additional user settings not covered by the controller
"AccountManager::updateUser()" wipes previous user data with whichever
user data is given (except for some adjustments, like resetting the
verified status when needed). As the controller overrode the properties
those properties would lose some of their attributes even if they are
not affected by the changes made by the controller. Now the controller
only modifies the attributes set ("value" and "scope") to prevent that.

Note that with this change the controller no longer removes the
"verified" status, but this is not a problem because, as mentioned,
"AccountManager::updateUser()" resets them when needed (for example,
when the value of the website property changes).

This change is a previous step to fix overwritting properties with null
values, and it will prevent the controller from making unexpected
changes if more attributes are added in the future.

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
3 years ago
Daniel Calviño Sánchez 8cae515daa Use constants from interface rather than class
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
3 years ago
Joas Schilling d80cc76ee7
Validate the website field input to be a valid URL
Signed-off-by: Joas Schilling <coding@schilljs.com>
3 years ago
Vincent Petry 5d14fd4396
Make extra user profile fields always editable
The fields for phone number, address, website and twitter are now
editable regardless whether federated sharing and the lookup server
are enabled or not.

Signed-off-by: Vincent Petry <vincent@nextcloud.com>
3 years ago
Joas Schilling 61ed57b757
Rename some parameters and methods to make the API more clear
Signed-off-by: Joas Schilling <coding@schilljs.com>
3 years ago
Joas Schilling 07095fd122
Also clear the knownUser when changing via the settings endpoint
Signed-off-by: Joas Schilling <coding@schilljs.com>
3 years ago
dependabot-preview[bot] eb502c02ff
Bump nextcloud/coding-standard from 0.3.0 to 0.5.0
Bumps [nextcloud/coding-standard](https://github.com/nextcloud/coding-standard) from 0.3.0 to 0.5.0.
- [Release notes](https://github.com/nextcloud/coding-standard/releases)
- [Changelog](https://github.com/nextcloud/coding-standard/blob/master/CHANGELOG.md)
- [Commits](https://github.com/nextcloud/coding-standard/compare/v0.3.0...v0.5.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
3 years ago
Christoph Wurst 90d0732828
Fix updating user settings
The requests dispatched from the personal settings page don't always
send all the possible params but just a subset. Hence requests currently
fail on master e.g. when you update your email. This makes the arguments
optional again.

Regression of da9462b482

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
3 years ago
Christoph Wurst d89a75be0b
Update all license headers for Nextcloud 21
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 years ago
Joas Schilling f648635758
Make the throwing optional, so background tasks don't break
Signed-off-by: Joas Schilling <coding@schilljs.com>
4 years ago
Joas Schilling 9e04e6f99a
Also translate the phone number when coming in via the accounts manager API directly
Signed-off-by: Joas Schilling <coding@schilljs.com>
4 years ago
Joas Schilling efe79f2937
Validate and standardize the phone number on saving
Signed-off-by: Joas Schilling <coding@schilljs.com>
4 years ago
Joas Schilling c2913f18d2
Also return the phone number and twitter handle on the API
Signed-off-by: Joas Schilling <coding@schilljs.com>
4 years ago
Joas Schilling da9462b482
Make code strict
Signed-off-by: Joas Schilling <coding@schilljs.com>
4 years ago
Morris Jobke a223f603f9
Simplify the check if admin can change password based on encryption status
Found by Psalm:
```
/home/runner/work/server/server/apps/settings/lib/Controller/UsersController.php:324:8:error - RedundantCondition: Type true for $isEncryptionModuleLoaded is never falsy
```

Signed-off-by: Morris Jobke <hey@morrisjobke.de>
4 years ago
Robin Appelman cbd6e65678
save email as lower case
email addresses are case insensitive

Signed-off-by: Robin Appelman <robin@icewind.nl>
4 years ago
Christoph Wurst d9015a8c94
Format code to a single space around binary operators
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 years ago
Roeland Jago Douma 05edd1e5d6
Merge pull request #22890 from nextcloud/techdebt/18680/help-static-code-analysis-understand-code
Help static code analysis to understand code
4 years ago
Daniel Kesselberg 096fe20611
Help static code analysis to understand code.
It adds proper type hints to private namespace to allow private namespace methods.

Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
4 years ago
Morris Jobke d3680e682a
Remove not needed semicolon and PHPDoc hint
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
4 years ago
Arthur Schiwon f959828616
emit typed event for user management
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
4 years ago
Christoph Wurst 2a054e6c04
Update the license headers for Nextcloud 20
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 years ago
Morris Jobke 7e281a07bb
Use IBootstrap for the app federatedfilesharing
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
4 years ago
Joas Schilling 6e46df26a8
Unify settings middleware with others
Signed-off-by: Joas Schilling <coding@schilljs.com>
4 years ago
GretaD fce716b905
Fix languages empty array
Signed-off-by: GretaD <gretadoci@gmail.com>
4 years ago
Christoph Wurst caff1023ea
Format control structures, classes, methods and function
To continue this formatting madness, here's a tiny patch that adds
unified formatting for control structures like if and loops as well as
classes, their methods and anonymous functions. This basically forces
the constructs to start on the same line. This is not exactly what PSR2
wants, but I think we can have a few exceptions with "our" style. The
starting of braces on the same line is pracrically standard for our
code.

This also removes and empty lines from method/function bodies at the
beginning and end.

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 years ago
Christoph Wurst afbd9c4e6e
Unify function spacing to PSR2 recommendation
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 years ago
Christoph Wurst 1a9330cd69
Update the license headers for Nextcloud 19
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 years ago
Christoph Wurst 463b388589
Merge pull request #20170 from nextcloud/techdebt/remove-unused-imports
Remove unused imports
4 years ago
Christoph Wurst b80ebc9674
Use the short array syntax, everywhere
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 years ago
Christoph Wurst 74936c49ea
Remove unused imports
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 years ago
Christoph Wurst d47daefe38
Revive the "send email to new users" toggle for the user form
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 years ago
Daniel Kesselberg 8e8e912015
Make sure quota_preset is using numerical indexes
If one set quota_present to "default, none, 1 GB, 5 GB, 10 GB" the old implementation will remove default and none but keep the array indexes. Later json_encode will recognize a array with 2 as first index as object and hence quotaPreset.reduce will fail.

Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
4 years ago