mirror of
https://github.com/guohuadeng/app-odoo.git
synced 2025-02-23 04:11:36 +02:00
update common add core
This commit is contained in:
@@ -20,9 +20,9 @@ from odoo import api, fields, models, exceptions, _
|
||||
class ProductCategory(models.Model):
|
||||
_inherit = 'product.category'
|
||||
|
||||
# 更新 complete_name 算法,当有context: show_short =1 时,只显示短名
|
||||
# 更新 complete_name 算法,当有context: show_short_category =1 时,只显示短名
|
||||
def name_get(self):
|
||||
if self._context.get('show_short'):
|
||||
if self._context.get('show_short_category'):
|
||||
new_res = []
|
||||
for category in self:
|
||||
name = category.name
|
||||
|
||||
Reference in New Issue
Block a user