Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add item endpoint #61

Merged
merged 34 commits into from
Jul 22, 2024
Merged

feat: Add item endpoint #61

merged 34 commits into from
Jul 22, 2024

Conversation

RakuJa
Copy link
Owner

@RakuJa RakuJa commented Jul 10, 2024

  • add "total number of element" field in response, to help FE paginate. This is different from count. count only tells the current pagination number, total the sum for all the paginations;
  • solve filter bug ignoring pf version
  • add item shop listing
  • add random item listing generator
  • fix ranged/melee bug (they were exclusive, while a creature can be both melee and ranged)
  • add weapon, armor, shield sub structure of item
  • update dockerfile to work with libraries update (missing build dependency)
  • add safe guarantees around n of forged items range gen, now it is formally proved that it will not panic and isolated in a method to reduce redundancy.
  • filter item by pathfinder version;
  • allow upper and lower case alternative for encounter difficulty and pathfinder version.

RakuJa added 30 commits May 19, 2024 18:41
* introduce shop endpoint with listing and single item fetch
* introduce db communication for items
* reorganize code structure
* introduce random shop
* split raw query in sub methods
* introduce dice structure
# Conflicts:
#	cliff.toml
#	src/db/cr_core_initializer.rs
#	src/db/data_providers/creature_fetcher.rs
#	src/db/data_providers/raw_query_builder.rs
#	src/models/creature/creature_struct.rs
#	src/models/creature_component/filter_struct.rs
#	src/models/creature_filter_enum.rs
#	src/models/encounter_structs.rs
#	src/models/mod.rs
#	src/models/pf_version_enum.rs
#	src/models/routers_validator_structs.rs
#	src/routes/bestiary.rs
#	src/services/encounter_service.rs
…elee bug, update libraries, update item struct
… wrong id, update swagger, introduce generic type for weapon with runes (to sell and loot)
* add shield item and type;
* fetch item traits for creature items;
* item quantity is now 1 by default and initialized only if it's a creature's item;
* update dependencies.
RakuJa added 4 commits July 8, 2024 00:13
* add shield in random gen;
* lower minimum size of dice to 1 (to allow fixed numbers aka 100d1 => 100;
* add safe guarantees around n of forged items range gen, now it is formally proved that it will not panic and isolated in a method to reduce redundancy.
…ce. It saves a few seconds in boot (I should really think about a method to save a few minutes, not seconds..)
* filter item by pathfinder version;
* allow upper and lower case alternative for encounter difficulty and pathfinder version.
@RakuJa RakuJa added enhancement New feature or request shop labels Jul 10, 2024
@RakuJa RakuJa requested a review from TheAsel July 10, 2024 23:30
@RakuJa RakuJa linked an issue Jul 10, 2024 that may be closed by this pull request
@RakuJa RakuJa self-assigned this Jul 20, 2024
Copy link
Collaborator

@TheAsel TheAsel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@RakuJa RakuJa merged commit 2443ca4 into master Jul 22, 2024
3 of 4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request shop
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement shop endpoint
2 participants