updated code for shared_tasks
This commit is contained in:
		@@ -7,8 +7,6 @@ from billard import utils
 | 
			
		||||
from django.contrib.auth.models import User
 | 
			
		||||
from django.db.models.signals import post_save
 | 
			
		||||
from django.dispatch import receiver
 | 
			
		||||
from celery import shared_task
 | 
			
		||||
from .tasks import process_location_data
 | 
			
		||||
 | 
			
		||||
log = logging.getLogger(__name__)
 | 
			
		||||
 | 
			
		||||
@@ -116,6 +114,7 @@ class Accounting(models.Model):
 | 
			
		||||
 | 
			
		||||
@receiver(post_save, sender=LocationData)
 | 
			
		||||
def test(sender, **kwargs):
 | 
			
		||||
    from .tasks import process_location_data
 | 
			
		||||
    process_location_data.delay()
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user