更新
This commit is contained in:
13
Python-100-Days/Day41-55/shop_origin/cart/models.py
Normal file
13
Python-100-Days/Day41-55/shop_origin/cart/models.py
Normal file
@@ -0,0 +1,13 @@
|
||||
from django.db import models
|
||||
|
||||
|
||||
class Goods(models.Model):
|
||||
|
||||
id = models.AutoField(primary_key=True, db_column='gid')
|
||||
name = models.CharField(max_length=50, db_column='gname')
|
||||
price = models.DecimalField(max_digits=10, decimal_places=2, db_column='gprice')
|
||||
image = models.CharField(max_length=255, db_column='gimage')
|
||||
|
||||
class Meta:
|
||||
db_table = 'tb_goods'
|
||||
ordering = ('id',)
|
||||
Reference in New Issue
Block a user