Пример #1
0
 def get_data(self):
     date = self.date
     data = InviteCount.aggregate(date)
     if data:
         return list(data.items())
     else:
         return None
Пример #2
0
    def set_increment_invite_tutoend_count(self, cnt=1, now=None):
        """招待成功してチュートリアルも終わった数.
        """
        def func(pipe):
            InviteCount.incrby(now or OSAUtil.get_now(),
                               InviteCount.TARGET.TUTOEND, cnt, pipe)

        self.__append_process(InviteCount.getDBName(), func)
        return self
Пример #3
0
    def set_increment_invite_success_count(self, cnt=1, now=None):
        """招待成功数.
        """
        def func(pipe):
            InviteCount.incrby(now or OSAUtil.get_now(),
                               InviteCount.TARGET.SUCCESS, cnt, pipe)

        self.__append_process(InviteCount.getDBName(), func)
        return self
Пример #4
0
 def func(pipe):
     InviteCount.incrby(now or OSAUtil.get_now(),
                        InviteCount.TARGET.TUTOEND, cnt, pipe)
Пример #5
0
 def func(pipe):
     InviteCount.incrby(now or OSAUtil.get_now(),
                        InviteCount.TARGET.SUCCESS, cnt, pipe)
Пример #6
0
 def deleteInviteCount(self, date):
     date = self.date
     InviteCount.deleteByDate(date)