Add awakenings to blueprints
This commit is contained in:
parent
7bdee95c0e
commit
6ccc8fd338
3 changed files with 16 additions and 1 deletions
|
|
@ -10,6 +10,14 @@ module Api
|
||||||
|
|
||||||
view :nested do
|
view :nested do
|
||||||
fields :position, :uncap_level, :perpetuity
|
fields :position, :uncap_level, :perpetuity
|
||||||
|
|
||||||
|
field :awakening do |c|
|
||||||
|
{
|
||||||
|
type: c.awakening_type,
|
||||||
|
level: c.awakening_level
|
||||||
|
}
|
||||||
|
end
|
||||||
|
|
||||||
association :character, name: :object, blueprint: CharacterBlueprint
|
association :character, name: :object, blueprint: CharacterBlueprint
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -32,6 +32,13 @@ module Api
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
field :awakening, if: ->(_field_name, w, _options) { w.weapon.awakening } do |w|
|
||||||
|
{
|
||||||
|
type: w.awakening_type,
|
||||||
|
level: w.awakening_level
|
||||||
|
}
|
||||||
|
end
|
||||||
|
|
||||||
view :full do
|
view :full do
|
||||||
include_view :nested
|
include_view :nested
|
||||||
association :party, blueprint: PartyBlueprint, view: :minimal
|
association :party, blueprint: PartyBlueprint, view: :minimal
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,7 @@ module Api
|
||||||
|
|
||||||
fields :granblue_id, :element, :proficiency,
|
fields :granblue_id, :element, :proficiency,
|
||||||
:max_level, :max_skill_level, :limit, :rarity,
|
:max_level, :max_skill_level, :limit, :rarity,
|
||||||
:series, :ax
|
:series, :ax, :awakening
|
||||||
|
|
||||||
field :uncap do |w|
|
field :uncap do |w|
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue