snipe
941582ac2a
Properly scope archived based on settings
...
Signed-off-by: snipe <snipe@snipe.net>
2024-06-18 10:27:11 +01:00
snipe
233e4af7f8
Added base asset models test
...
Signed-off-by: snipe <snipe@snipe.net>
2024-06-17 11:57:30 +01:00
snipe
df1cef59d5
Fixes path for redirect response
...
Signed-off-by: snipe <snipe@snipe.net>
2024-05-29 18:01:40 +01:00
snipe
92ba889cae
Updated/removed facades
...
Signed-off-by: snipe <snipe@snipe.net>
2024-05-29 12:53:51 +01:00
snipe
fb233c0aa4
Cleaned up facade names and references
...
Signed-off-by: snipe <snipe@snipe.net>
2024-05-29 12:38:15 +01:00
snipe
850f85ff59
Merge pull request #14369 from spencerrlongg/bug/sc-24343
...
Add new validator for custom field checkboxes and fix asset model default updates
2024-03-26 19:22:29 +00:00
snipe
972b198248
Removed debugging
...
Signed-off-by: snipe <snipe@snipe.net>
2024-02-20 17:27:16 +00:00
spencerrlongg
1ceb703129
rm var
2024-02-14 12:44:09 -06:00
spencerrlongg
d9c61fdb02
validation msg
2024-02-14 11:52:25 -06:00
spencerrlongg
25241542d2
progress, going to sleep
2024-02-14 02:12:31 -06:00
spencerrlongg
d55358652b
cleanup for pr
2024-02-13 13:45:56 -06:00
spencerrlongg
bcfa913450
condition makes this work, needs more testing
2024-02-07 20:03:37 -06:00
spencerrlongg
43d8474caa
a note to remember this tomorrow
2024-02-06 17:45:46 -06:00
Marcus Moore
f5dafc477a
Avoid unnecessary model hydration on asset model show page
2024-01-24 16:14:51 -08:00
snipe
016ca1adc1
Fixed HTML for checkboxes
...
Signed-off-by: snipe <snipe@snipe.net>
2023-12-13 06:27:50 +00:00
snipe
d06cfe6502
Changed verb to “restore” from “restored”
...
Signed-off-by: snipe <snipe@snipe.net>
2023-11-22 20:08:41 +00:00
snipe
f7ccef16e7
Refactorer controller restore methods
...
Signed-off-by: snipe <snipe@snipe.net>
2023-11-22 18:02:47 +00:00
Robert-Azelis
58062ff9f5
Update AssetModelsController.php
...
if EOL of model has been changed and value is >0 assets will be updates with new EOL rate, date
if EOL of model has been changes and value is null or 0 then assets will be updates by null EOL rate, date
*asset with set expilicity market will not be updated
2023-10-22 17:56:38 +02:00
spencerrlongg
d65d1930e4
asset models
2023-09-19 19:24:53 -05:00
slong753
774f21bb7f
some more cleanup
2023-09-11 17:17:59 -05:00
slong753
1ea0de8bca
prevent injection, fix asset update
2023-09-11 17:15:25 -05:00
slong753
c1daabef08
progress
2023-09-11 17:10:41 -05:00
Godfrey Martinez
a26b96185b
Merge branch 'develop' into asset-model-notifs
2023-09-11 09:37:22 -07:00
Ivan Nieto Vivanco
4e4ba38038
Pass the model_id variable in the controller and get it only if we are cloning the asset model
2023-08-28 16:23:26 -06:00
Godfrey M
8ebb9afedd
adds min_amt to asset model edit, index, and table
2023-08-24 10:30:07 -07:00
snipe
e869b1fd53
Fixed #12724 - fieldset not saving on model
...
Signed-off-by: snipe <snipe@snipe.net>
2023-03-24 06:11:24 -07:00
Ivan Nieto Vivanco
1ff2d15c4a
Replace 'required' rule with 'nullable' to allow blank default customfields values
2022-08-25 18:16:50 -05:00
Ivan Nieto Vivanco
6e85c2e5cb
Delete unused import
2022-08-24 16:30:25 -05:00
Ivan Nieto Vivanco
30d0125cbd
Remove the rule 'required' for default values, if custom field is obligatory
2022-08-24 16:18:11 -05:00
Ivan Nieto Vivanco
7976401aa2
Add error message when the default customfield values can't be validated
2022-06-22 22:17:05 -05:00
Ivan Nieto Vivanco
321367b974
Adds validation to custom fields' default values
2022-06-22 21:06:07 -05:00
snipe
dd5f812d88
Merge remote-tracking branch 'origin/master' into develop
...
Signed-off-by: snipe <snipe@snipe.net>
# Conflicts:
# .all-contributorsrc
# README.md
# app/Console/Commands/FixDoubleEscape.php
# app/Console/Commands/LdapSync.php
# app/Exceptions/Handler.php
# app/Http/Controllers/Api/AssetMaintenancesController.php
# app/Http/Controllers/Api/AssetModelsController.php
# app/Http/Controllers/Api/AssetsController.php
# app/Http/Controllers/Api/CategoriesController.php
# app/Http/Controllers/Api/CompaniesController.php
# app/Http/Controllers/Api/DepartmentsController.php
# app/Http/Controllers/Api/LicensesController.php
# app/Http/Controllers/Api/LocationsController.php
# app/Http/Controllers/Api/ManufacturersController.php
# app/Http/Controllers/Api/SettingsController.php
# app/Http/Controllers/Api/SuppliersController.php
# app/Http/Controllers/AssetModelsController.php
# app/Http/Controllers/Auth/LoginController.php
# app/Http/Controllers/CustomFieldsController.php
# app/Http/Controllers/SettingsController.php
# app/Models/Loggable.php
# app/Providers/AuthServiceProvider.php
# config/version.php
# database/migrations/2014_11_04_231416_update_group_field_for_reporting.php
# database/migrations/2015_11_08_222305_add_ldap_fields_to_settings.php
# package-lock.json
# package.json
# public/js/build/app.js
# public/js/dist/all.js
# public/mix-manifest.json
# resources/assets/js/components/forms/asset-models/fieldset-default-values.vue
# resources/views/hardware/view.blade.php
2022-02-20 13:29:12 -08:00
Ivan Nieto Vivanco
6d79c9f3e2
Save the default values for custom fields with same format than Assets do for actual values
2022-02-09 13:41:33 -06:00
Ivan Nieto Vivanco
a36957dd77
Finish the implementation of custom fields default values for checkboxes
2022-02-09 13:12:42 -06:00
Ivan Nieto Vivanco
2f3499e4b9
Show checkboxes a little less assy, actually save the data checked by them
2022-02-09 10:49:10 -06:00
snipe
c3d55ee27e
Merge master down into develop
...
Signed-off-by: snipe <snipe@snipe.net>
# Conflicts:
# .all-contributorsrc
# README.md
# app/Exceptions/Handler.php
# app/Http/Controllers/Api/AssetsController.php
# app/Http/Controllers/Api/SettingsController.php
# app/Http/Controllers/CustomFieldsController.php
# app/Http/Controllers/SettingsController.php
# app/Http/Transformers/AssetsTransformer.php
# app/Models/Setting.php
# config/version.php
# resources/lang/af/button.php
# resources/lang/ar/button.php
# resources/lang/bg/button.php
# resources/lang/cs/button.php
# resources/lang/cy/button.php
# resources/lang/da/button.php
# resources/lang/de/button.php
# resources/lang/el/button.php
# resources/lang/en-GB/button.php
# resources/lang/en-ID/button.php
# resources/lang/es-CO/admin/groups/message.php
# resources/lang/es-MX/button.php
# resources/lang/et/admin/custom_fields/general.php
# resources/lang/et/admin/hardware/table.php
# resources/lang/et/admin/kits/general.php
# resources/lang/et/admin/manufacturers/message.php
# resources/lang/et/admin/models/general.php
# resources/lang/et/admin/settings/general.php
# resources/lang/et/button.php
# resources/lang/et/mail.php
# resources/lang/fa/button.php
# resources/lang/fa/help.php
# resources/lang/fi/button.php
# resources/lang/fil/button.php
# resources/lang/fr/button.php
# resources/lang/ga-IE/button.php
# resources/lang/he/button.php
# resources/lang/hr/button.php
# resources/lang/hu/admin/settings/general.php
# resources/lang/hu/auth/message.php
# resources/lang/hu/button.php
# resources/lang/hu/mail.php
# resources/lang/id/admin/hardware/table.php
# resources/lang/id/button.php
# resources/lang/it/button.php
# resources/lang/iu/button.php
# resources/lang/ja/button.php
# resources/lang/ko/button.php
# resources/lang/lt/button.php
# resources/lang/lv/button.php
# resources/lang/mi/button.php
# resources/lang/mk/button.php
# resources/lang/ml-IN/button.php
# resources/lang/mn/button.php
# resources/lang/ms/admin/hardware/table.php
# resources/lang/ms/admin/kits/general.php
# resources/lang/ms/admin/models/general.php
# resources/lang/ms/admin/models/message.php
# resources/lang/ms/admin/settings/general.php
# resources/lang/ms/button.php
# resources/lang/nl/button.php
# resources/lang/no/admin/hardware/table.php
# resources/lang/no/admin/kits/general.php
# resources/lang/no/admin/settings/general.php
# resources/lang/no/auth/message.php
# resources/lang/no/button.php
# resources/lang/no/help.php
# resources/lang/no/mail.php
# resources/lang/pl/button.php
# resources/lang/pt-BR/button.php
# resources/lang/pt-PT/auth/message.php
# resources/lang/pt-PT/button.php
# resources/lang/pt-PT/mail.php
# resources/lang/ro/button.php
# resources/lang/ru/admin/settings/general.php
# resources/lang/ru/button.php
# resources/lang/ru/help.php
# resources/lang/sl/admin/custom_fields/general.php
# resources/lang/sl/admin/hardware/table.php
# resources/lang/sl/admin/kits/general.php
# resources/lang/sl/admin/manufacturers/message.php
# resources/lang/sl/admin/models/general.php
# resources/lang/sl/admin/settings/general.php
# resources/lang/sl/admin/users/general.php
# resources/lang/sl/auth/message.php
# resources/lang/sl/button.php
# resources/lang/sl/help.php
# resources/lang/sr-CS/button.php
# resources/lang/ta/button.php
# resources/lang/th/button.php
# resources/lang/th/mail.php
# resources/lang/tl/button.php
# resources/lang/tr/admin/settings/general.php
# resources/lang/tr/auth/message.php
# resources/lang/tr/button.php
# resources/lang/uk/button.php
# resources/lang/ur-PK/button.php
# resources/lang/vi/button.php
# resources/lang/zh-CN/button.php
# resources/lang/zh-HK/button.php
# resources/lang/zh-TW/admin/hardware/table.php
# resources/lang/zh-TW/button.php
# resources/lang/zu/button.php
# resources/views/models/custom_fields_form.blade.php
# resources/views/reports/custom.blade.php
# resources/views/settings/slack.blade.php
2021-12-16 14:26:24 -08:00
Haxatron
1699c09758
Update AssetModelsController.php
2021-12-09 21:42:18 +08:00
Haxatron
918e7c8dae
Fix access control - https://huntr.dev/bounties/19453ef1-4d77-4cff-b7e8-1bc8f3af0862/
2021-12-09 12:57:04 +08:00
Laravel Shift
934afa036f
Adopt Laravel coding style
...
Shift automatically applies the Laravel coding style - which uses the PSR-2 coding style as a base with some minor additions.
You may customize the adopted coding style by adding your own [PHP CS Fixer][1] `.php_cs` config file to your project root. Feel free to use [Shift's Laravel ruleset][2] to help you get started.
[1]: https://github.com/FriendsOfPHP/PHP-CS-Fixer
[2]: https://gist.github.com/laravel-shift/cab527923ed2a109dda047b97d53c200
2021-06-10 20:15:52 +00:00
snipe
fa2dfc3e87
Use updated request signature for models
2020-08-26 11:59:30 -07:00
snipe
d25a05d748
Misc Flysystem/image upload request fixes
2020-08-26 11:53:36 -07:00
snipe
de21f00771
Fixed assetmodels upload
2020-08-26 02:29:37 -07:00
snipe
69a1732245
Removed duplicate form request in asset models controller
...
Signed-off-by: snipe <snipe@snipe.net>
2020-04-22 03:51:10 -07:00
snipe
87464e6ec0
Merge branch 'develop' into integrations/2020-04-15-v5-merge
...
# Conflicts:
# README.md
# app/Http/Controllers/AccessoriesController.php
# app/Http/Controllers/Api/AssetsController.php
# app/Http/Controllers/Api/LicensesController.php
# app/Http/Controllers/Api/LocationsController.php
# app/Http/Controllers/Api/SettingsController.php
# app/Http/Controllers/Api/UsersController.php
# app/Http/Controllers/AssetModelsController.php
# app/Http/Controllers/Assets/AssetsController.php
# app/Http/Controllers/Auth/ForgotPasswordController.php
# app/Http/Controllers/CategoriesController.php
# app/Http/Controllers/CompaniesController.php
# app/Http/Controllers/ComponentsController.php
# app/Http/Controllers/ConsumablesController.php
# app/Http/Controllers/CustomFieldsetsController.php
# app/Http/Controllers/DepartmentsController.php
# app/Http/Controllers/LicensesController.php
# app/Http/Controllers/LocationsController.php
# app/Http/Controllers/ManufacturersController.php
# app/Http/Controllers/SettingsController.php
# app/Http/Controllers/SuppliersController.php
# app/Http/Controllers/UsersController.php
# app/Http/Requests/AssetRequest.php
# app/Http/Requests/ImageUploadRequest.php
# app/Models/LicenseSeat.php
# app/Models/Location.php
# app/Models/Setting.php
# composer.json
# composer.lock
# config/database.php
# config/version.php
# npm-shrinkwrap.json
# package.json
# public/css/AdminLTE.css
# public/css/AdminLTE.css.map
# public/css/overrides.css
# public/css/overrides.css.map
# public/css/skins/skin-blue-light.css
# public/css/skins/skin-blue.css
# public/css/skins/skin-green-dark.min.css
# public/js/app.js
# public/js/bootstrap-table.js
# public/js/bootstrap/js/bootstrap.js
# public/js/bootstrap/js/bootstrap.min.js
# public/js/build/all.js
# public/js/build/vue.js
# public/js/build/vue.js.map
# public/js/demo.js
# public/js/ekko-lightbox.js
# public/js/ekko-lightbox.min.js
# public/js/extensions/export/bootstrap-table-export.js
# public/js/extensions/multiple-sort/bootstrap-table-multiple-sort.js
# public/js/extensions/multiple-sort/bootstrap-table-multiple-sort.min.js
# public/js/extensions/toolbar/bootstrap-table-toolbar.min.js
# public/js/plugins/bootstrap-wysihtml5/bootstrap3-wysihtml5.all.js
# public/js/plugins/bootstrap-wysihtml5/bootstrap3-wysihtml5.all.min.js
# public/js/plugins/timepicker/bootstrap-timepicker.js
# public/js/plugins/timepicker/bootstrap-timepicker.min.js
# public/js/vue.js
# public/mix-manifest.json
# resources/assets/js/bootstrap-js.js
# resources/assets/js/bootstrap.min.js
# resources/assets/js/ekko-lightbox.js
# resources/assets/js/ekko-lightbox.min.js
# resources/assets/js/plugins/bootstrap-wysihtml5/bootstrap3-wysihtml5.all.js
# resources/assets/js/plugins/bootstrap-wysihtml5/bootstrap3-wysihtml5.all.min.js
# resources/assets/js/plugins/chartjs/Chart.js
# resources/assets/js/plugins/timepicker/bootstrap-timepicker.js
# resources/assets/js/plugins/timepicker/bootstrap-timepicker.min.js
# resources/assets/less/AdminLTE.less
# resources/assets/less/overrides.less
# resources/assets/less/skins/_all-skins.less
# resources/assets/less/skins/skin-black.less
# resources/assets/less/skins/skin-blue.less
# resources/assets/less/skins/skin-green.less
# resources/assets/less/skins/skin-purple.less
# resources/assets/less/skins/skin-red.less
# resources/assets/less/skins/skin-yellow.less
# resources/assets/less/variables.less
# resources/js/components/importer/importer-file.vue
# resources/lang/en/auth/message.php
# resources/lang/en/passwords.php
# resources/lang/es-CO/general.php
# resources/lang/es-ES/general.php
# resources/lang/es-VE/general.php
# resources/less/skins/skin-black-dark.less
# resources/less/skins/skin-blue-dark.less
# resources/less/skins/skin-contrast.less
# resources/less/skins/skin-green-dark.less
# resources/less/skins/skin-orange-dark.less
# resources/less/skins/skin-orange.less
# resources/less/skins/skin-purple-dark.less
# resources/less/skins/skin-red-dark.less
# resources/less/skins/skin-yellow-dark.less
# resources/views/accessories/checkin.blade.php
# resources/views/accessories/checkout.blade.php
# resources/views/accessories/edit.blade.php
# resources/views/account/profile.blade.php
# resources/views/account/view-assets.blade.php
# resources/views/asset_maintenances/edit.blade.php
# resources/views/auth/passwords/email.blade.php
# resources/views/auth/passwords/reset.blade.php
# resources/views/categories/edit.blade.php
# resources/views/companies/edit.blade.php
# resources/views/components/checkin.blade.php
# resources/views/components/checkout.blade.php
# resources/views/components/edit.blade.php
# resources/views/consumables/checkout.blade.php
# resources/views/consumables/edit.blade.php
# resources/views/custom_fields/fields/edit.blade.php
# resources/views/custom_fields/fieldsets/edit.blade.php
# resources/views/dashboard.blade.php
# resources/views/departments/edit.blade.php
# resources/views/groups/edit.blade.php
# resources/views/hardware/audit.blade.php
# resources/views/hardware/bulk-checkout.blade.php
# resources/views/hardware/bulk.blade.php
# resources/views/hardware/checkin.blade.php
# resources/views/hardware/checkout.blade.php
# resources/views/hardware/edit.blade.php
# resources/views/hardware/index.blade.php
# resources/views/hardware/quickscan.blade.php
# resources/views/hardware/view.blade.php
# resources/views/importer/import.blade.php
# resources/views/layouts/basic.blade.php
# resources/views/layouts/default.blade.php
# resources/views/layouts/edit-form.blade.php
# resources/views/licenses/checkin.blade.php
# resources/views/licenses/checkout.blade.php
# resources/views/licenses/edit.blade.php
# resources/views/locations/edit.blade.php
# resources/views/manufacturers/edit.blade.php
# resources/views/modals/upload-file.blade.php
# resources/views/models/bulk-edit.blade.php
# resources/views/models/custom_fields_form.blade.php
# resources/views/models/edit.blade.php
# resources/views/partials/bootstrap-table.blade.php
# resources/views/partials/forms/edit/address.blade.php
# resources/views/partials/forms/edit/asset-select.blade.php
# resources/views/partials/forms/edit/category-select.blade.php
# resources/views/partials/forms/edit/category.blade.php
# resources/views/partials/forms/edit/company-select.blade.php
# resources/views/partials/forms/edit/company.blade.php
# resources/views/partials/forms/edit/department-select.blade.php
# resources/views/partials/forms/edit/depreciation.blade.php
# resources/views/partials/forms/edit/email.blade.php
# resources/views/partials/forms/edit/image-upload.blade.php
# resources/views/partials/forms/edit/item_number.blade.php
# resources/views/partials/forms/edit/location-profile-select.blade.php
# resources/views/partials/forms/edit/location-select.blade.php
# resources/views/partials/forms/edit/location.blade.php
# resources/views/partials/forms/edit/maintenance_type.blade.php
# resources/views/partials/forms/edit/manufacturer-select.blade.php
# resources/views/partials/forms/edit/manufacturer.blade.php
# resources/views/partials/forms/edit/minimum_quantity.blade.php
# resources/views/partials/forms/edit/model-select.blade.php
# resources/views/partials/forms/edit/model_number.blade.php
# resources/views/partials/forms/edit/name.blade.php
# resources/views/partials/forms/edit/notes.blade.php
# resources/views/partials/forms/edit/order_number.blade.php
# resources/views/partials/forms/edit/phone.blade.php
# resources/views/partials/forms/edit/purchase_cost.blade.php
# resources/views/partials/forms/edit/purchase_date.blade.php
# resources/views/partials/forms/edit/quantity.blade.php
# resources/views/partials/forms/edit/serial.blade.php
# resources/views/partials/forms/edit/status.blade.php
# resources/views/partials/forms/edit/submit.blade.php
# resources/views/partials/forms/edit/supplier-select.blade.php
# resources/views/partials/forms/edit/supplier.blade.php
# resources/views/partials/forms/edit/user-select.blade.php
# resources/views/reports/custom.blade.php
# resources/views/settings/alerts.blade.php
# resources/views/settings/asset_tags.blade.php
# resources/views/settings/barcodes.blade.php
# resources/views/settings/branding.blade.php
# resources/views/settings/general.blade.php
# resources/views/settings/labels.blade.php
# resources/views/settings/ldap.blade.php
# resources/views/settings/localization.blade.php
# resources/views/settings/security.blade.php
# resources/views/setup/user.blade.php
# resources/views/suppliers/edit.blade.php
# resources/views/users/bulk-edit.blade.php
# resources/views/users/edit.blade.php
# resources/views/users/ldap.blade.php
# resources/views/users/print.blade.php
# resources/views/users/view.blade.php
# routes/api.php
# routes/web/hardware.php
# webpack.mix.js
2020-04-20 23:20:34 -07:00
snipe
0b3f511534
Fixed compact() errors
2020-04-07 17:26:56 -07:00
snipe
c31e150935
Use $request->input over Request::get()
2019-12-11 11:09:54 -08:00
snipe
df778cdb80
Include storage in use statements
2019-12-10 22:03:15 -08:00
snipe
d7c51f1a2c
Added Request to use statements
2019-12-10 20:39:29 -08:00
snipe
296de34e8a
WIP: Upgrade develop to Laravel 6.6.1 ( #7637 )
...
I'm going ahead and merging this, since the upgrade doesn't break Flysystem any worse than the current develop is broken, so far as I can tell.
* Upgraded framework to Laravel 6
### TO DO:
- Fix password restriction rules- the old library isn’t compatible with Laravel 6 :(
- Figure out why in-app API calls are returning “Unauthorized”
* More updates from Input:: to Request:: helper
* Switch to Request:: from Input
* Added passport config
* Fixed goofy password minimum in seeder
* Added laravel/helpers
* Changed ($item) to ($item->id) in forms
I have no idea why this is necessary
* Changed ($item) to ($item->id) in forms
* Updated API middleware to auth:api
* Updated with added laravel auth.php values
* FIxed *&!^$%^&$^%!!!! ajax issue
* Switch to Request::get from Input::get
* Switched to Request facade
* Added password security minimums back in
The package we were using has not been updated to Laravel v6, so I created custom validators instead
* Added language strings for error messages for password rules
* Fixed `($item)` issue in formActions for partials
2019-12-10 19:32:50 -08:00
snipe
e71e57f16a
Fixed XSS vulnerability in SVG image uploads [ch10476] ( #7639 )
...
* Added enshrined/svg-sanitize
* Added modular image resizing/SVG cleaning method
(This already exists in v5, so I mostly ported it forward and added the SVG sanitizer.)
* Use improved handleImages method to upload/resize/clean images
* Removed $old_image
This is handled in the ImageUpload request now
2019-12-05 22:23:05 -08:00