Commit graph

22 commits

Author SHA1 Message Date
snipe b26fbf986f Fixed issue where offset could be greater than total items, resulting in “No results” confusion 2019-02-14 14:49:08 -08:00
snipe d4fa81301d Check if user can see assets in statuslabels gate 2018-10-09 16:34:12 -07:00
Till Deeke 48bbbe0f40 Fixing authorization issues (#5807)
* adds permission checks for companies

* adds permission checks for depreciations

* adds permission check for all reports

* fixes permissions for departments

* fixes permission naming (edit -> update)

* fixes authorization checking wrong permission in API

The authorization was checking for the non-existent „edit“ method where it should have checked for the „update“ method.

* adds authorization checks for select2 lists

* adds missing authorization checks for api

* fixes user authorization check for creating users

* adds additional check viewing assets on showing a users assets

* Removes authorization checks for select2 lists

Reference: https://github.com/snipe/snipe-it/pull/5807#pullrequestreview-136018755
2018-07-12 18:28:02 -07:00
snipe 1e22b8e567 Fixed #5138 - added default_label flag to status labels 2018-03-05 22:04:16 -08:00
Daniel Meltzer 7de8f71f58 Api tests (#5096)
* Use the formated date helper to clean up verifications.

* Add Checkin/Checkout api tests.

* Accessories api test

* Add Companies API Test.

* Return ModelNotFound as a 404.

* Cleanups/simplficiations/updates.

* Locations api test.

* currency and image should be fillable on location.

* Update components api test.

* Use findOrFail so we return a 404 instead of a 200.  Matches other item types.

* order_number should be fillable in component.

* Add updated_at and permissions to information returned from api for a user.

* Add users test and flesh out factory and fillable fields.

* Add test for assets method

* API status label test.

* Disable php7.2 for now on travis until the count(null) issues are remedied

* Add serial to update.

* API model not found should return a 200
2018-02-24 19:01:34 -08:00
snipe f5e51897e3 Added - sort by color on status labels 2018-02-21 05:29:50 -08:00
snipe d36e8cfbd2 Dashbpoard pie fixes 2017-11-01 13:27:59 -07:00
snipe a9753eb646 Include asset count in status labels overview 2017-10-19 10:48:15 -07:00
snipe 707c4db881 API: Check there are no assets associated before allowing delete 2017-10-19 10:39:08 -07:00
snipe 282b3b5b0a Remove catch-all “deployed” from pie chart 2017-10-06 18:41:10 -07:00
snipe 1dcff8d463 Remove eager loading on pie
This was causing memory issues for large asset sets
2017-10-06 18:15:01 -07:00
snipe 659d953f3f Fixed custom error message for status labels 2017-08-24 22:40:07 -07:00
snipe 8c5312b931 Fixes #3866 - weird API behavior in status label types 2017-08-22 14:10:54 -07:00
snipe 464c524375 Depreciations API 2017-02-01 17:59:03 -08:00
snipe 7086ac8a8b Tweaks to status labelas listing display 2017-02-01 17:48:28 -08:00
snipe b019e6e950 Removed closures from routes files so that we can allow people to cache routes for performance optimization 2017-01-24 17:37:07 -08:00
snipe ad4bf83aaa Add ability to view assets by status label
This should be refactored. Lots of copypaste from the assets views here
2017-01-18 20:41:40 -08:00
snipe 66f724cd35 Added created_at to status labels for consistency 2017-01-13 07:55:03 -08:00
snipe b423fa3bd4 Added sorting, searching, etc to status labels index 2017-01-13 07:47:39 -08:00
snipe c7e1b426e7 Additional API routes and controllers for models, suppliers, users, locations and status labels 2017-01-13 04:50:20 -08:00
snipe bc5fcf8736 Fixed dashboard chart 2017-01-13 03:19:39 -08:00
snipe b11a951e95 Starter API controllers 2017-01-12 19:40:20 -08:00