我试图理解“目录\类别\产品”表的“位置”列的目的是什么:
+-------------+------------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+-------------+------------------+------+-----+---------+-------+
| category_id | int(10) unsigned | NO | PRI | 0 | |
| product_id | int(10) unsigned | NO | PRI | 0 | |
**| position | int(11) | NO | | 0 | |**
+-------------+------------------+------+-----+---------+-------+
表目录\类别\实体:
| Field | Type | Null | Key | Default |
+----------------------+------+-----+---------+---+
| entity_id | int(10) unsigned | NO | PRI | NULL | |
|entity_type_id | smallint(5) unsigned | NO | | 0 |
| attribute_set_id | smallint(5) unsigned | NO | | 0 |
| parent_id | int(10) unsigned | NO | | 0 |
| created_at | timestamp | YES | | NULL |
| updated_at | timestamp | YES | | NULL |
| path | varchar(255) | NO | MUL | NULL |
**| position | int(11) | NO | | NULL |**
| level | int(11) | NO | MUL | 0 |
| children_count | int(11) | NO | | NULL |
+----------------------+------+-----+---------+----------------+
1条答案
按热度按时间soat7uwm1#
根据我的理解,在分类中有两种定位,一种是属于分类相对的位置,另一种是为指定的产品按特定的顺序显示它们,这就是我认为设置位置栏的目的。
我希望我回答了你的问题。