示例#1
0
 def new_id(cls):
     id = tools.id_generator('A')
     while len(cls.objects.filter(preamble_id=id)):
         id = tools.id_generator('A')
     return id
示例#2
0
 def new_id(cls):
     id = tools.id_generator('V')
     while len(cls.objects.filter(vertex_id=id)):
         id = tools.id_generator('V')
     return id
示例#3
0
 def new_id(cls):
     id = tools.id_generator('E')
     while len(cls.objects.filter(edge_id=id)):
         id = tools.id_generator('E')
     return id