From abaccac9f020e4208f8f0cd4571dbc2275d35a9e Mon Sep 17 00:00:00 2001 From: shibao Date: Mon, 10 Apr 2023 20:12:02 -0400 Subject: [PATCH] use :rifle as default ammo type --- CHANGELOG.md | 1 + lib/cannery/ammo/type.ex | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5ea90c85..0d4deea6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,7 @@ - Fix additional shotgun fields not being exportable - Fixes duplicate chamber size column for ammo types - Hide bullet type field when editing/creating shotgun ammo types +- Fix ammo type creation not displaying all the necessary fields on first load # v0.9.1 - Rename ammo type's "type" to "class" to avoid confusion diff --git a/lib/cannery/ammo/type.ex b/lib/cannery/ammo/type.ex index bdaef189..dc9ea9a3 100644 --- a/lib/cannery/ammo/type.ex +++ b/lib/cannery/ammo/type.ex @@ -52,7 +52,7 @@ defmodule Cannery.Ammo.Type do field :name, :string field :desc, :string - field :class, Ecto.Enum, values: [:rifle, :shotgun, :pistol] + field :class, Ecto.Enum, values: [:rifle, :shotgun, :pistol], default: :rifle # common fields field :bullet_core, :string