示例#1
0
 def buildList(self, prebattles):
     self.__list = []
     for item in prebattles:
         self.__list.append({'prbID': item.prbID,
          'creatorName': item.getCreatorFullName(),
          'comment': item.getCensoredComment(),
          'playersCount': item.playersCount,
          'division': getCompanyDivisionString(item.getDivisionName()),
          'players': []})
示例#2
0
def getDivisionsList(addAll = True):
    result = []
    if addAll:
        result.append({'data': 0,
         'label': i18n.makeString('#prebattle:labels/company/division/ALL')})
    for divID in PREBATTLE_COMPANY_DIVISION.RANGE:
        divName = PREBATTLE_COMPANY_DIVISION_NAMES[divID]
        result.append({'data': divID,
         'label': getCompanyDivisionString(divName)})

    return result
示例#3
0
def getDivisionsList(addAll = True):
    result = []
    if addAll:
        result.append({'data': 0,
         'label': i18n.makeString('#prebattle:labels/company/division/ALL')})
    for divID in PREBATTLE_COMPANY_DIVISION.RANGE:
        divName = PREBATTLE_COMPANY_DIVISION_NAMES[divID]
        result.append({'data': divID,
         'label': getCompanyDivisionString(divName)})

    return result
示例#4
0
 def buildList(self, prebattles):
     self.__list = []
     for item in prebattles:
         self.__list.append({'prbID': item.prbID,
          'creatorName': item.creator,
          'creatorClan': item.clanAbbrev,
          'creatorIgrType': item.creatorIgrType,
          'creatorRegion': g_lobbyContext.getRegionCode(item.creatorDbId),
          'comment': item.getCensoredComment(),
          'playersCount': item.playersCount,
          'division': getCompanyDivisionString(item.getDivisionName()),
          'players': []})
示例#5
0
 def buildList(self, prebattles):
     self.__list = []
     for item in prebattles:
         self.__list.append({'prbID': item.prbID,
          'creatorName': item.creator,
          'creatorClan': item.clanAbbrev,
          'creatorIgrType': item.creatorIgrType,
          'creatorRegion': g_lobbyContext.getRegionCode(item.creatorDbId),
          'comment': item.getCensoredComment(),
          'playersCount': item.playersCount,
          'division': getCompanyDivisionString(item.getDivisionName()),
          'players': []})
示例#6
0
def getDivisionsList(addAll = True):
    result = []
    if addAll:
        result.append({'data': 0,
         'label': i18n.makeString('#prebattle:labels/company/division/ALL')})
    isEventEnabled = g_eventsCache.isEventEnabled()
    for divID in PREBATTLE_COMPANY_DIVISION.RANGE:
        if divID in PREBATTLE_COMPANY_DIVISION.EVENT_ONLY and not isEventEnabled:
            continue
        divName = PREBATTLE_COMPANY_DIVISION_NAMES[divID]
        result.append({'data': divID,
         'label': getCompanyDivisionString(divName)})

    return result