-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #165 from MySecondLanguage/added-product-attribute
Added product attribute
- Loading branch information
Showing
2 changed files
with
42 additions
and
4 deletions.
There are no files selected for viewing
27 changes: 27 additions & 0 deletions
27
nxtbn/product/migrations/0008_remove_productvariant_internal_metadata_and_more.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# Generated by Django 4.2.11 on 2024-10-11 10:06 | ||
|
||
from django.db import migrations, models | ||
import nxtbn.core.models | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
('product', '0007_productvariant_dimensions_and_more'), | ||
] | ||
|
||
operations = [ | ||
migrations.RemoveField( | ||
model_name='productvariant', | ||
name='internal_metadata', | ||
), | ||
migrations.RemoveField( | ||
model_name='productvariant', | ||
name='metadata', | ||
), | ||
migrations.AddField( | ||
model_name='productvariant', | ||
name='attributes', | ||
field=models.JSONField(blank=True, default=dict, help_text='A JSON field to store custom attributes for the variant. Primary attributes include color code, dimension, and weight value. Weight value and dimension are used for shipping calculations. This field allows adding as many custom attributes as needed.', null=True, validators=[nxtbn.core.models.no_nested_values]), | ||
), | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters