示例#1
0
    def __init__(self, *args, **kwargs):
        max_length = kwargs.pop('size', 20)

        if 'type_' in kwargs:
            del kwargs['type_']

        self.sqlalchemy_type = ColorType(max_length)
        super(Color, self).__init__(*args, **kwargs)
示例#2
0
文件: column.py 项目: Gnonpi/AnyBlok
 def __init__(self, *args, **kwargs):
     self.max_length = max_length = kwargs.pop('size', 20)
     kwargs.pop('type_', None)
     self.sqlalchemy_type = ColorType(max_length)
     super(Color, self).__init__(*args, **kwargs)