mirror of
https://github.com/yweber/lodel2.git
synced 2026-06-14 06:20:48 +02:00
Created the class MlString and fixing syntax error
Created the class Lodel.utils.mlstring.MlString needed by EditorialModel.lib.component.EmComponent The first test pass ! =)
This commit is contained in:
parent
8f2a3655bb
commit
eeaaf945d2
3 changed files with 9 additions and 2 deletions
|
|
@ -5,7 +5,7 @@
|
|||
@see EmClass, EmType, EmFieldGroup, EmField
|
||||
"""
|
||||
|
||||
from ml_string import MlString
|
||||
from Lodel.utils.mlstring import MlString
|
||||
|
||||
class EmComponent(object):
|
||||
|
||||
|
|
@ -18,7 +18,7 @@ class EmComponent(object):
|
|||
raise EnvironmentError('Abstract class')
|
||||
if id_or_name is int:
|
||||
self.id = id_or_name
|
||||
else if id_or_name is str:
|
||||
elif id_or_name is str:
|
||||
self.name = id_or_name
|
||||
self.populate()
|
||||
else:
|
||||
|
|
|
|||
0
Lodel/utils/__init__.py
Normal file
0
Lodel/utils/__init__.py
Normal file
7
Lodel/utils/mlstring.py
Normal file
7
Lodel/utils/mlstring.py
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
|
||||
class MlString(object):
|
||||
""" Handle string with translations """
|
||||
|
||||
def __init__(self, default_str, translations = dict()):
|
||||
pass
|
||||
Loading…
Add table
Add a link
Reference in a new issue