Fix: Product Category save + filter debugging.
This commit is contained in:
Binary file not shown.
Binary file not shown.
@@ -21,6 +21,7 @@ class Base():
|
||||
ATTR_ID_ACCESS_LEVEL: ClassVar[str] = 'id_access_level'
|
||||
ATTR_ID_ADDRESS: ClassVar[str] = 'id_address'
|
||||
ATTR_ID_CURRENCY: ClassVar[str] = 'id_currency'
|
||||
ATTR_ID_MSG_ERROR_TYPE: ClassVar[str] = 'id_type'
|
||||
ATTR_ID_REGION: ClassVar[str] = 'id_region'
|
||||
ATTR_ID_USER: ClassVar[str] = 'id_user'
|
||||
ATTR_ID_USER_MANAGER: ClassVar[str] = 'id_user_manager'
|
||||
@@ -49,6 +50,7 @@ class Base():
|
||||
FLAG_GUID: ClassVar[str] = 'guid'
|
||||
FLAG_IS_NOT_EMPTY: ClassVar[str] = 'is_not_empty'
|
||||
# FLAG_KEY_PRIMARY: ClassVar[str] = 'key_primary'
|
||||
FLAG_MESSAGE: ClassVar[str] = 'message'
|
||||
FLAG_NAME: ClassVar[str] = 'name'
|
||||
FLAG_NAME_ATTR_OPTION_TEXT: ClassVar[str] = 'NAME_ATTR_OPTION_TEXT'
|
||||
FLAG_NAME_ATTR_OPTION_VALUE: ClassVar[str] = 'NAME_ATTR_OPTION_VALUE'
|
||||
|
||||
@@ -10,13 +10,8 @@ Description:
|
||||
Business object for SQL errors
|
||||
"""
|
||||
|
||||
# IMPORTS
|
||||
# VARIABLE INSTANTIATION
|
||||
# CLASSES
|
||||
# METHODS
|
||||
|
||||
# IMPORTS
|
||||
# internal
|
||||
from business_objects.base import Base
|
||||
import lib.argument_validation as av
|
||||
from lib import data_types
|
||||
from forms.forms import Form_Basket_Add, Form_Basket_Edit # Form_Product
|
||||
@@ -64,4 +59,13 @@ class SQL_Error(db.Model):
|
||||
error.msg = record[3]
|
||||
error.name = record[4]
|
||||
error.description = record[5]
|
||||
return error
|
||||
return error
|
||||
def to_json(self):
|
||||
return {
|
||||
Base.FLAG_DISPLAY_ORDER: self.display_order,
|
||||
Base.ATTR_ID_MSG_ERROR_TYPE: self.id_type,
|
||||
Base.FLAG_CODE: self.code,
|
||||
Base.FLAG_MESSAGE: self.msg,
|
||||
Base.FLAG_NAME: self.name,
|
||||
Base.FLAG_DESCRIPTION: self.description,
|
||||
}
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -603,7 +603,7 @@ class Parameters_Product(Get_Many_Parameters_Base):
|
||||
def from_filters_product_category(cls, filters_category):
|
||||
return cls(
|
||||
get_all_product_category = True,
|
||||
get_inactive_product_category = filters_category.active.data,
|
||||
get_inactive_product_category = not filters_category.active.data,
|
||||
ids_product_category = '',
|
||||
get_all_product = True,
|
||||
get_inactive_product = False,
|
||||
|
||||
@@ -524,3 +524,6 @@ class Product_Category_Temp(db.Model, Store_Base):
|
||||
'created_on': self.created_on,
|
||||
'created_by': self.created_by
|
||||
"""
|
||||
|
||||
def __repr__(self):
|
||||
return str(self.__dict__)
|
||||
@@ -124,4 +124,6 @@ class Store_Base(Base):
|
||||
FLAG_UNIT_MEASUREMENT_LATENCY_MANUFACTURE: ClassVar[str] = 'unit_measurement_latency_manufacture'
|
||||
FLAG_UNIT_MEASUREMENT_QUANTITY: ClassVar[str] = 'unit_measurement_quantity'
|
||||
FLAG_VALUE_TEXT: ClassVar[str] = 'value_text'
|
||||
|
||||
|
||||
def __repr__(self):
|
||||
return str(self.__dict__)
|
||||
Reference in New Issue
Block a user