Skip to content

Commit

Permalink
Revert status fields for stock items (inventree#7965)
Browse files Browse the repository at this point in the history
* Revert status fields for stock items

* Fix PUI fields too

* Bump API version
  • Loading branch information
SchrodingersGat authored Aug 23, 2024
1 parent cf9dcf0 commit b9b4412
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 5 deletions.
5 changes: 4 additions & 1 deletion src/backend/InvenTree/InvenTree/api_version.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
"""InvenTree API version information."""

# InvenTree API version
INVENTREE_API_VERSION = 247
INVENTREE_API_VERSION = 248

"""Increment this API version number whenever there is a significant change to the API that any clients need to know about."""


INVENTREE_API_TEXT = """
v248 - 2024-08-23 : https://github.com/inventree/InvenTree/pull/7965
- Small adjustments to labels for new custom status fields
v247 - 2024-08-22 : https://github.com/inventree/InvenTree/pull/7956
- Adjust "attachment" field on StockItemTestResult serializer
- Allow null values for attachment
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ class Migration(migrations.Migration):
models.CharField(
help_text="Label that will be displayed in the frontend",
max_length=250,
verbose_name="label",
verbose_name="Label",
),
),
(
Expand Down
2 changes: 1 addition & 1 deletion src/backend/InvenTree/common/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -3355,7 +3355,7 @@ class InvenTreeCustomUserStateModel(models.Model):
)
label = models.CharField(
max_length=250,
verbose_name=_('label'),
verbose_name=_('Label'),
help_text=_('Label that will be displayed in the frontend'),
)
color = models.CharField(
Expand Down
2 changes: 1 addition & 1 deletion src/backend/InvenTree/templates/js/translated/stock.js
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,7 @@ function stockItemFields(options={}) {
batch: {
icon: 'fa-layer-group',
},
status_custom_key: {},
status: {},
expiry_date: {
icon: 'fa-calendar-alt',
},
Expand Down
2 changes: 1 addition & 1 deletion src/frontend/src/forms/StockForms.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ export function useStockFields({
value: batchCode,
onValueChange: (value) => setBatchCode(value)
},
status_custom_key: {},
status: {},
expiry_date: {
// TODO: icon
},
Expand Down

0 comments on commit b9b4412

Please sign in to comment.