Commit graph

4244 commits

Author SHA1 Message Date
snipe
ef9b6e3b07 Code cleanup
Signed-off-by: snipe <snipe@snipe.net>
2024-10-21 16:34:54 +01:00
Marcus Moore
7e1b47708e
Fix failing test ensuring company id is an integer 2024-10-17 15:18:41 -07:00
snipe
c01190fac2 Conditionally add content-type
Signed-off-by: snipe <snipe@snipe.net>
2024-10-17 00:18:34 +01:00
snipe
c49921f50f Removed unused (maybe?) API endpoint
Signed-off-by: snipe <snipe@snipe.net>
2024-10-17 00:08:54 +01:00
snipe
c49abb6aea Refactor the UserFilesController show method for simpler inlining
Signed-off-by: snipe <snipe@snipe.net>
2024-10-17 00:08:38 +01:00
snipe
ccd2019448 Removed unusded use statements
Signed-off-by: snipe <snipe@snipe.net>
2024-10-17 00:08:04 +01:00
akemidx
f0d3a6e2d3 removing some comments/merging in develop 2024-10-16 18:35:31 -04:00
akemidx
5cb940c2ee Merge branch 'refs/heads/upstream/dev' into feature/sc-26415 2024-10-16 18:32:36 -04:00
Brady Wetherington
3cf746d7df Rework the bulk checkout to not change how all checkouts work 2024-10-16 23:13:32 +01:00
Brady Wetherington
6b7af802af Add 'bulk checkout' as one of the bulk actions in the bulk actions toolbar 2024-10-16 22:02:45 +01:00
Godfrey M
3ab2521cb0 email comes through, no picture and html markup appear though. 2024-10-16 12:21:33 -07:00
Tobias Regnery
fdcc17ca2c Fix user creation with FullMultipleCompanySupport enabled over API
It is currently possible as a non-superuser to create a new user or patch an existing user with arbitrary company over the API if FullMultipleCompanySupport is enabled.
Altough a highly unlikely scenario as the user needs permission to create API keys and new users, it is a bug that should get fixed.

Add a call to getIdForCurrentUser() to normalize the company_id if FullMultipleCompanySupport is enabled.
2024-10-16 11:47:18 +02:00
Marcus Moore
5306e1cd15
Merge branch 'develop' into saving_custom_report_template
# Conflicts:
#	resources/views/partials/forms/edit/location-select.blade.php
#	resources/views/partials/forms/edit/manufacturer-select.blade.php
#	resources/views/partials/forms/edit/model-select.blade.php
#	resources/views/partials/forms/edit/supplier-select.blade.php
#	resources/views/reports/custom.blade.php
2024-10-15 12:32:01 -07:00
snipe
0ae9ce0aa9 Cannot sort by updated at on Users [sc-27147]
Signed-off-by: snipe <snipe@snipe.net>
2024-10-15 16:41:45 +01:00
snipe
50b8f180b3 More logical grouping in allow_columns
Signed-off-by: snipe <snipe@snipe.net>
2024-10-15 16:41:39 +01:00
Tobias Regnery
f3c4e55667 Refactor asset creation with API
Commit fb4fe3004 restored the previous behaviour to check the company_id in case of FullMultipleCompanySupport.
But after rereading the code and the laravel documentation, the check is already there where it belongs in AssetStoreRequest::prepareForValidation()
The bug is the is_int-check of the request input in prepareForValidation(). Is is of type string even if it is a numeric value, so the call to getIdForCurrentUser() never happend.
Fix this by removing the check and the now redundant call to getIdForCurrentUser().
Wrong values will get caught by the model-level validation rules.
2024-10-14 15:14:41 +02:00
snipe
0d35335da7 Removed debugging
Signed-off-by: snipe <snipe@snipe.net>
2024-10-11 16:06:17 +01:00
snipe
e1a70023b1
Merge pull request #15655 from Toreg87/fixes/api_asset_create_fmcs
Fixes #15654 Fix asset creation with API and FullMultipleCompanySupport
2024-10-11 11:45:48 +01:00
snipe
de62359c67
Merge pull request #15533 from marcusmoore/testing/fmcs-accessories
Added tests for accessory api controller
2024-10-11 11:29:34 +01:00
Tobias Regnery
fb4fe30049 Fix asset creation with API and FullMultipleCompanySupport
It is currently possible to create an asset with arbitrary company without being superuser and FullMultipleCompanySupport enabled.
This bug goes back to 75ac7f80b9 which is part of version 6.3.0.
Fix this by restoring the previous behaviour to check the company_id with getIdForCurrentUser().
2024-10-11 12:19:20 +02:00
snipe
b054017c9f Fixed #15651 - admin user now displaying on maintenances page
Signed-off-by: snipe <snipe@snipe.net>
2024-10-11 11:16:24 +01:00
snipe
8aa298f6b0
Merge pull request #15644 from snipe/form_requests_for_settings
Form requests for settings
2024-10-10 12:30:53 +01:00
snipe
94a074a193
Merge pull request #15601 from snipe/check_db_on_healthcheck
Fixed #15439 - check database on healthcheck
2024-10-10 01:11:10 +01:00
snipe
3886da8941 Remove form request from get LDAP method
Signed-off-by: snipe <snipe@snipe.net>
2024-10-09 22:15:49 +01:00
snipe
130e0c6242 More validation
Signed-off-by: snipe <snipe@snipe.net>
2024-10-09 22:15:37 +01:00
snipe
3705b91439 Added more validation
Signed-off-by: snipe <snipe@snipe.net>
2024-10-09 20:51:34 +01:00
snipe
ded79469c1 Remove unused controller method
Signed-off-by: snipe <snipe@snipe.net>
2024-10-09 20:33:29 +01:00
snipe
d9fbf330e5 Fixed translations
Signed-off-by: snipe <snipe@snipe.net>
2024-10-09 20:33:15 +01:00
snipe
3a77b83e9c Added space
Signed-off-by: snipe <snipe@snipe.net>
2024-10-09 19:30:34 +01:00
snipe
4f957bcf71 Required flag
Signed-off-by: snipe <snipe@snipe.net>
2024-10-09 18:34:53 +01:00
snipe
5cda7cce48 Only accept a positive number for thresholds
Signed-off-by: snipe <snipe@snipe.net>
2024-10-09 18:21:40 +01:00
snipe
aa55fa6ff4 Switch to form requests for settings
Signed-off-by: snipe <snipe@snipe.net>
2024-10-09 18:16:34 +01:00
akemidx
299e743848 weird requesting 2024-10-08 15:51:53 -04:00
snipe
7461c3e0ca Change controller to assume a collection. (This is dumb, but whatever)
Signed-off-by: snipe <snipe@snipe.net>
2024-10-03 16:19:27 +01:00
Brady Wetherington
350b627ce1 Fix numeric sort 'ambiguous order clause' error 2024-10-03 14:23:40 +01:00
akemidx
0c84904bf9 un'required'ing the rule. not sure what's breaking here but looking 2024-10-02 18:56:41 -04:00
akemidx
e00a1aec02 note box is now missing when unchecking setting 2024-10-02 18:52:33 -04:00
akemidx
06e3bb7fd1 requested changes 2024-10-02 18:37:11 -04:00
akemidx
17706f150e requested changes 2024-10-02 18:15:53 -04:00
akemidx
6fef127cd1 missing closing ) 2024-10-02 18:15:53 -04:00
akemidx
f45b836010 backend form validation. +cleanup 2024-10-02 18:15:53 -04:00
akemidx
925aea8531 back to having tests pass. needed to comment out the notes rules() i added 2024-10-02 18:15:53 -04:00
akemidx
bd6698de2a fixing some formatting 2024-10-02 18:15:53 -04:00
akemidx
515f59fed9 more test work 2024-10-02 18:15:52 -04:00
akemidx
700647c53f setting created 2024-10-02 18:15:52 -04:00
snipe
b34a7c8aad Removed die()
Signed-off-by: snipe <snipe@snipe.net>
2024-10-02 15:48:35 +01:00
snipe
f92bf5dc20 Updated language for failure
Signed-off-by: snipe <snipe@snipe.net>
2024-10-02 15:39:27 +01:00
snipe
4d9e85026a Fixed #15439 - check database on healthcheck
Signed-off-by: snipe <snipe@snipe.net>
2024-10-02 15:36:01 +01:00
snipe
4db7358086
Merge pull request #15593 from Godmartinz/Fixed-divide-by-zero-bug
Fixed divide by zero bug in depreciation transformer
2024-10-02 12:38:46 +01:00
spencerrlongg
3153bbb13f dumb fix 2024-10-01 17:04:18 -05:00