hxp
2020-12-21 5a5967cf491cd6ddac4a1cc5f9b9ead029212f18
ServerPython/CoreServerGroup/GameServer/Script/Player/PlayerCompensation.py
@@ -207,8 +207,51 @@
    limitLVType = (mailInfo - checkState * 1000000) / 100000
    return checkState, limitLVType, limitLV
def QueryCompensationPersonalInfo(playerID):
    '''个人补偿邮件查询
    '''
    retList = []
    compensationMgr = GameWorld.GetCompensationMgr()
    tempSign = "<MailTemplate>"
    tempSignEnd = "</MailTemplate>"
    curPersonalCount = compensationMgr.GetPersonalCompensationCount(playerID)
    GameWorld.DebugLog("QueryCompensationPersonalInfo %s" % curPersonalCount)
    for i in xrange(curPersonalCount):
        compensation = compensationMgr.PersonalCompensationAt(playerID, i)
        contentList = compensation.Text.split("<$_$>")
        if len(contentList) != 3:
            continue
        sender, title, content = contentList
        if tempSign in content and tempSignEnd in content:
            title = content[content.index(tempSign) + len(tempSign):content.index(tempSignEnd)]
            content = ""
        GUID = compensation.GUID
        itemList = []
        curGUIDItemCount = compensationMgr.FindItemCount(GUID)
        for i in xrange(curGUIDItemCount):
            curItem = compensationMgr.FindItemAt(GUID, i)
            itemID = curItem.ItemID
            if not itemID:
                continue
            itemList.append([itemID, curItem.Count, curItem.IsBind, curItem.UserData])
        recState = compensationMgr.FindPlayerRecState(playerID, GUID)
        infoDict = {"GUID":GUID, "Gold":compensation.Gold, "GoldPaper":compensation.GoldPaper, "Silver":compensation.Silver,
                    "Sender":sender, "Title":title, "Content":content, "RecState":recState,
                    "CreateTime":compensation.CreateTime, "LimitTime":compensation.LimitTime, "ItemList":itemList}
        retList.append(infoDict)
    return retList
def QueryCompensationInfo(fromDate, toDate, guid, searchTitle, searchContent, searchState=None, maxCount=10):
    '''补偿邮件查询
    '''全服补偿邮件查询
    '''
    
    compensationMgr = GameWorld.GetCompensationMgr()