def update(self, sync=False):
     if self.card._ticket_system_data and self.card.id:
         if sync:
             self.actually_update()
         else:
             update_ticket.apply_async((self.card.id,))
     else:
         # first fetch
         self.actually_update()
Esempio n. 2
0
 def update(self, issue=None, sync=False):
     if self.card._ticket_system_data and self.card.id:
         if sync:
             self.actually_update(issue)
         else:
             update_ticket.apply_async((self.card.id, ))
     else:
         # first fetch
         self.actually_update(issue)
Esempio n. 3
0
from kardboard.models import Kard
from kardboard.tasks import update_ticket

for k in Kard.objects.all():
    if not k._ticket_system_data:
        print "Scheduling update for %s" % k.key
        update_ticket.apply_async((k.id, ))
Esempio n. 4
0
from kardboard.models import Kard
from kardboard.tasks import update_ticket

for k in Kard.objects.all():
    if not k._ticket_system_data:
        print "Scheduling update for %s" % k.key
        update_ticket.apply_async((k.id,))