7049e8e723
Fix bug introduced in last PR
2022-12-30 06:09:58 -08:00
3e77365635
Refactor #create
...
This method is humongous and very confusing, and often gives double render errors. This refactor breaks things up into smaller methods to help make it a bit more readable.
2022-12-30 05:08:40 -08:00
6f588386d0
Filter out grids that don't have more than two distinct weapons
2022-12-29 02:36:52 -08:00
1752081f3f
Output theme
2022-12-25 20:17:20 -08:00
383d59703f
Add theme to user table and blueprint
2022-12-25 16:01:40 -08:00
e2332f9652
Allow searching only for extra or subaura objects
2022-12-25 00:29:55 -08:00
adbb5b6c7d
Disallow adding arbitrary weapons to Extra slots
2022-12-25 00:23:27 -08:00
ec25230bc5
Implement detecting and resolving weapon conflicts
2022-12-24 23:30:10 -08:00
7a8cf30ffb
Fix series for Class Champion emblems
2022-12-24 04:55:11 -08:00
ae1da20f27
Fix fetching weapon keys so you dont need filters
2022-12-24 04:54:50 -08:00
4f4d9e27a7
Add slug to weapon key table
2022-12-23 23:31:34 -08:00
ddae480f48
Merge branch 'main' into awakening
2022-12-23 19:28:03 -08:00
f17be0ea03
Merge branch 'main' of github.com:jedmund/hensei-api
2022-12-23 19:24:12 -08:00
e0df40f035
Remove log
2022-12-23 19:22:45 -08:00
574d8e0b3e
Normalize constants in ApiController
2022-12-23 19:08:36 -08:00
6ccc8fd338
Add awakenings to blueprints
2022-12-23 16:40:42 -08:00
13dae81737
Fix bug preventing selecting Row IV, V and EXII
2022-12-23 15:49:30 -08:00
8b69a44d83
Allow unsetting of jobs
...
Unsetting a job also removes all of its skills
2022-12-23 15:42:46 -08:00
464fe2f1aa
Update output for GridObjects when uncapping
2022-12-22 23:41:04 -08:00
a837210029
Removed current job's subskills from search
2022-12-22 23:27:46 -08:00
874c20245d
Refined selecting skills based on job
...
* Bugfix: You can now select a third subskill on Rows 1, 2 and 3
* Edgecase: When switching from a Row 1, 2 or 3 class to Row 4, 5 or EX2, the third EMP skill set is removed
2022-12-22 23:27:24 -08:00
8c1d51fb4f
Updated getting skills assignable to a job
...
This endpoint isn't used though
2022-12-22 23:26:23 -08:00
b7a537f540
Fix token generation on signup
2022-12-22 21:27:38 -08:00
041f8ee189
Fix errors with error handling
2022-12-22 18:12:47 -08:00
e91e1664a6
Update blueprint for availability endpoints
2022-12-22 18:12:34 -08:00
153d36be5a
We need to include the User in the Party
2022-12-22 01:40:02 -08:00
a397fc722d
Pass root when rendering in SearchController
2022-12-22 01:01:03 -08:00
c5391a6683
Fix bug where now wasn't replaced
2022-12-22 00:44:39 -08:00
7ddc916216
Remove rabl views
...
Our work here is done
2022-12-21 23:29:20 -08:00
c0be03dcb6
Finish migrating ApiController error methods
2022-12-21 23:28:54 -08:00
415ef39158
Add per_page to methods that return collections
2022-12-21 23:15:17 -08:00
5c97488a20
Update UsersController to use blueprinter
2022-12-21 23:13:19 -08:00
41c031092e
Update weapon_keys_controller.rb
2022-12-21 22:10:35 -08:00
89e666219a
Update SearchController for blueprinter
2022-12-21 22:10:31 -08:00
9a27ac853d
Update JobsController and JobSkillsController for blueprinter
2022-12-21 21:46:35 -08:00
349c42f839
Update blueprints to remove id field or identifier
...
This is built into ApiBlueprint
2022-12-21 21:07:26 -08:00
3b6edfae5d
Update WeaponKey output for blueprinter
2022-12-21 21:04:42 -08:00
116ec9dbbc
Refactor GridObjectControllers to use blueprinter
2022-12-21 20:53:48 -08:00
2a74b8aa4d
Add minimal view to Party and use in GridObject
2022-12-21 20:53:34 -08:00
a15ba3c376
Correct ConflictBlueprint
...
ConflictBlueprint uses `options` to display arbitrary values, but I think those are only available behind conditional statements. This adds those statements and checks if the key that will be used exists on the hash.
ConflictBlueprint was also inheriting from ApiBlueprint which requires a real object (with an ID), so instead we inherit from Blueprinter::Base
2022-12-21 20:40:27 -08:00
747ffbc4ff
Update GridObject blueprints with view
2022-12-21 20:39:17 -08:00
33775539cd
Add ConflictBlueprint
...
This should be used for character conflicts (implemented) and weapon conflicts (to-do in a future PR)
2022-12-21 19:27:55 -08:00
bf04ddcbba
Fix GridObject blueprints
2022-12-21 19:27:33 -08:00
979d28be75
Update party_blueprint.rb
2022-12-21 16:20:04 -08:00
af51869927
Fix build_conditions method
...
The method of assigning values was assigning nil if the value wasn't present in `params`, which is bad
2022-12-21 16:20:00 -08:00
5b37e480f8
Refactor FavoritesController for blueprinter
2022-12-21 16:10:53 -08:00
f86aa30791
GranblueError should not require input param
2022-12-21 15:50:06 -08:00
44e92733d3
Refactor RaidsController for blueprinter
2022-12-21 15:35:05 -08:00
290099e2f4
Refactor PartiesController for blueprinter
...
* Refactored and tried to simplify methods in PartiesController
* Implemented new error render methods in ApiController
* Removed parties/[weapons, summons, characters] routes
2022-12-21 15:34:54 -08:00
e541182e36
Add all blueprints and associate with models
2022-12-21 03:31:55 -08:00
a1ff18092d
Create error_blueprint.rb
2022-12-21 01:20:55 -08:00
31e62e073c
Create api_blueprint.rb
2022-12-21 01:20:13 -08:00
712c866296
Remove rabl
2022-12-21 01:16:34 -08:00
c1716c1e4f
Run RuboCop on everything
...
yolo
2022-12-21 00:22:47 -08:00
9e2f9c0af1
Fix job creation
2022-12-03 20:13:48 -08:00
a8301019f5
Fix search for base skills
...
Before they didn't really show up at all, then they showed up on everything, then they showed up on EX1 and EX2, now they only show up on EX2.
2022-12-03 18:34:38 -08:00
fc7cde4c5a
Fix race condition for base skill mismatch check
2022-12-03 18:21:15 -08:00
a08421722f
Add GranblueError and move app errors to extend it
2022-12-03 18:21:01 -08:00
6ba5335668
Fix last bugs around adding skills with 0~3 existing
2022-12-03 16:39:38 -08:00
813c2ba202
Fix bug regarding finding old_position
2022-12-03 14:51:01 -08:00
243ba2de3e
Fix bug when desired position is empty
2022-12-03 14:10:18 -08:00
27d31d61c0
Fix race condition
2022-12-03 13:55:41 -08:00
ec3b42101b
Move logic to JobsController
...
It was getting too heavy to keep in PartiesController
2022-12-03 11:45:00 -08:00
bd33ee44fc
Update Job model to reference base_job
2022-12-03 11:44:09 -08:00
4ee90f6c09
Add new errors and fix handling in ApiController
2022-12-03 11:43:56 -08:00
5c9a2b8d7a
Refactor job skill assignment a bit
2022-12-02 20:46:51 -08:00
f6613d6e91
Add TooManySkillsOfTypeError
2022-12-02 20:45:46 -08:00
644ffd74e5
Added logic for swapping and replacing job skills
2022-12-02 11:20:43 -08:00
d1eba7aed8
Add == and update search
2022-12-02 11:20:22 -08:00
aa5d2451a8
Add skill uniqueness validation to Party
2022-12-02 11:20:11 -08:00
741d20aa70
Send job and skills when party is updated
2022-12-01 04:47:31 -08:00
296fa0187c
Save base job skills on job change
2022-12-01 04:46:53 -08:00
1ba16a2c61
Export job skills in template
2022-12-01 04:46:44 -08:00
ae36ff59b4
Properly gate group conditions
...
The default group ("All Skills") is technically -1, not null
2022-11-30 05:17:40 -08:00
a69fda5ead
Small refactor of handling groups
...
Using the `filters` key so we can hook into existing search infrastructure on the frontend
2022-11-30 02:51:58 -08:00
c0bdb47d43
Add scoped search for job skills
2022-11-30 02:03:28 -08:00
353db31ef7
Move to JobSkillsController
...
It makes more sense to pre-fetch all job skills and filter on the client, so we're consolidating into a JobSkillsController
2022-11-27 19:27:45 -08:00
5755aab240
Disable object root
2022-11-27 18:54:32 -08:00
5fe712c31a
Add route to get skills for given job
2022-11-27 14:12:52 -08:00
b9bea3ecf4
Add model
2022-11-27 14:12:33 -08:00
559507977b
Added logic for conflict resolution
...
* Conflict is detected when attempting to save a new GridCharacter
* New `resolve` method executes the replacement
* Template to render a decision on the frontend
2022-11-19 06:03:39 -08:00
c45a54e222
Added character_id to character template
2022-11-19 06:02:33 -08:00
9967d36f89
Fix race condition
2022-11-17 02:25:22 -08:00
ba632af5e7
Add gender to user database
2022-04-10 13:25:57 -07:00
cf132e20f5
Receive and output job data in templates
2022-04-04 23:41:00 -07:00
c3566944cd
Add endpoint for fetching all jobs
2022-03-22 03:41:00 -07:00
698968dbfe
Create job.rb
2022-03-22 02:56:34 -07:00
483e9fe226
Update templates
2022-03-21 03:54:13 -07:00
5d45b8898e
Add favorites to parties
2022-03-21 03:53:59 -07:00
a99f0c31c5
Add pagination to favorites and teams
2022-03-21 03:53:52 -07:00
6756c24896
Remove duplicate current_user method
2022-03-21 03:53:34 -07:00
1f3ba2307f
Add pagination for collections
2022-03-14 19:42:29 -07:00
e6a09ab29b
Make has_many readable
2022-03-14 18:21:54 -07:00
c7196f7c79
Add a permanent weapon count condition to Teams
...
This way, Discover Teams will only show high quality parties
2022-03-14 18:21:40 -07:00
72c144ef65
Add counter_cache flag to GridWeapon
2022-03-14 18:20:29 -07:00
0561c11ebc
Update path
2022-03-11 01:12:54 -08:00
6a2f5e1a5c
Updated search templates
2022-03-11 01:12:45 -08:00
0584ac84e5
Added filters to summons and characters
2022-03-11 01:12:35 -08:00
14260e4ce0
Add filtering to weapon search
2022-03-09 11:02:51 -08:00
88f316d6a7
Implement JP search and trigram for EN
2022-03-08 17:43:40 -08:00
3fc09d9f12
Add slug to output
2022-03-07 18:25:38 -08:00
62543858bd
Fix a small variable bug in GridWeapons Controller
2022-03-06 03:47:28 -08:00
b62465539e
All canonical objects return "ja" instead of "jp" now
2022-03-04 17:59:05 -08:00
1c08d64b55
Fix grid_weapon not being able to be created
2022-03-04 14:54:36 -08:00
49e4a02150
Add update and info method on User
2022-03-04 05:14:36 -08:00
b5ba7725d2
Add picture node to user template
2022-03-04 03:57:35 -08:00
5e2a28c340
Add new fields to json template
2022-03-04 01:33:48 -08:00
b7500617e3
Trying to fix DoubleRenderError
2022-03-03 17:10:03 -08:00
1b28de1bda
Add order to WeaponKey
...
There is a specific order for keys in game, so we want to mirror that.
2022-03-03 01:31:04 -08:00
92ef43abcd
Add a rudimentary update method
...
We still need to do server-side validation since a lot of things can go wrong here if users get cheeky
2022-03-03 00:22:11 -08:00
5ef04f9d13
Make GridWeapon/WeaponKey association optional
...
Otherwise, we can't save a record without weapon keys, which is not ideal
2022-03-03 00:17:47 -08:00
0ee5fc765c
Update weapon key method to have conditions
...
We never want all keys, only ever a subset for the weapon we're currently working on
2022-03-02 14:39:44 -08:00
cb4ff0e1f2
Add rendering for all the new stuff
2022-03-01 23:33:53 -08:00
45c4cc5af6
Create weapon_keys_controller.rb
2022-03-01 23:33:28 -08:00
82a6b0d598
Add WeaponKey associations to GridWeapon
2022-03-01 23:33:21 -08:00
c7d53d4ffd
Remove print log
2022-03-01 12:51:11 -08:00
d5ed98f0cf
Implement filters on profiles
2022-03-01 02:19:44 -08:00
96adcc9540
Don't run set_from_slug before destroying parties
...
This caused a 500 that caused parties to be unable to deleted
2022-02-28 16:55:42 -08:00
186fde79be
Enable filtering list of favorite parties
2022-02-27 22:52:25 -08:00
86640d5986
Remove log
2022-02-27 22:28:42 -08:00
07dc8dd457
Refactor how we output favorite bool on parties
2022-02-27 22:28:17 -08:00
8d9b434d1e
Add attr_accessor for favorited
2022-02-27 22:27:10 -08:00
e295df0fdd
Remove log and unused parameter
2022-02-27 22:12:57 -08:00
6afe242abe
Return a boolean indicating favorite in party object
2022-02-27 21:14:37 -08:00
57b6f2a7b4
Add back render call
2022-02-27 20:55:55 -08:00
09ef36cfe6
Update base.json.rabl
2022-02-27 20:00:33 -08:00
7feb5157c8
Add method for displaying a user's favorites
2022-02-27 20:00:29 -08:00
a45193d1b8
Association update and favorites method on User
2022-02-27 20:00:18 -08:00
b9140430e2
Add favorites controller and templates
...
Allows saving and deleting favorites
2022-02-27 19:05:25 -08:00
b2adbd0400
Add favorites model
2022-02-27 19:04:51 -08:00
438fc7294d
Add custom errors
2022-02-27 19:03:04 -08:00
4907f7c584
Properly implement filtering
2022-02-27 00:33:00 -08:00
0c405d7f5a
Add user object to JSON templates
...
instead of just user id
2022-02-27 00:32:50 -08:00
af8b9d3570
Implement filterable endpoint for all parties
2022-02-26 20:57:24 -08:00
2a40abf08f
Save the party's element when the mainhand is changed
2022-02-26 20:47:09 -08:00
f5a4afc01d
Begrudgingly adding an element field to parties
...
Also added it in the JSON template
2022-02-26 20:44:16 -08:00
3f979f6d62
Add endpoint for getting all parties
...
No filters yet
2022-02-26 19:29:19 -08:00
47d5de057c
Remove ap call
2022-02-26 18:40:32 -08:00
a04a1cb5c8
Fix bug with wrong key when creating party
2022-02-26 18:25:54 -08:00
5338e83be3
Add timestamps to party json output
2022-02-26 17:45:17 -08:00
5dd25e1953
Add element to raid json template
2022-02-26 15:59:41 -08:00
374e294a33
Change permitted param for extra toggle
2022-02-23 19:22:42 -08:00
09a009ccfb
Add team details to all existing templates
2022-02-23 19:04:54 -08:00
edf489ce31
Add route to get all raids
2022-02-23 19:04:34 -08:00
ace4fb8568
Permit detail attributes and update all attributes instead of just extra
2022-02-23 18:11:19 -08:00
bb736ce084
Add Raid model and add Parties as belonging to Raids
2022-02-23 18:11:03 -08:00
29c3415df2
Don't allow destroy if owner is not current user
2022-02-23 16:34:36 -08:00
53e6e8bd39
Add destroy dependencies to models
2022-02-23 16:31:01 -08:00
18049385ce
Add destroy implementation and json template
2022-02-23 16:30:52 -08:00
8362fcf770
Refactor how GridCharacters are saved
2022-02-23 13:49:40 -08:00