1
0
Fork 0
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:
Yann 2015-05-27 10:54:31 +02:00
commit eeaaf945d2
3 changed files with 9 additions and 2 deletions

View file

@ -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
View file

7
Lodel/utils/mlstring.py Normal file
View file

@ -0,0 +1,7 @@
# -*- coding: utf-8 -*-
class MlString(object):
""" Handle string with translations """
def __init__(self, default_str, translations = dict()):
pass