Skip to content

Commit

Permalink
Fixing some API generation stuff, bit of cleanup (#162)
Browse files Browse the repository at this point in the history
Figured out where the BasePermissionMetaclass error was coming from - "auth" in extend_schema isn't for what I was using it for. Also resolved some issues where ID types weren't being figured out, and where depth was tripping up the generator. Regenerated the OpenAPI spec.

Also cleaned up a few things while in here:
- Removed BasketItemViewSet (not used - we'll want a delete-only one later but for now it's not particularly useful)
- Updated BasketWithProductSerializer to pull some discount fields that aren't here (yet)
- Updated basket serializers in general - this had methods to pull stuff where we could just pass the serializer
- Updated basket endpoints that return stuff to use the ones with product info by default
- Updated BasketViewSet to just be a regular ReadOnlyModelViewSet and limit it to the current user's baskets
  • Loading branch information
jkachel authored Oct 18, 2024
1 parent 2f56b5a commit dd4f179
Show file tree
Hide file tree
Showing 11 changed files with 918 additions and 2,760 deletions.
5 changes: 5 additions & 0 deletions frontends/api/src/generated/v0/.openapi-generator-ignore
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,8 @@
#docs/*.md
# Then explicitly reverse the ignore rule for a single file:
#!docs/README.md

**/.npmignore
**/.gitignore
**/git_push.sh
**/.openapi-generator-ignore
Loading

0 comments on commit dd4f179

Please sign in to comment.