def _update_positions(product):
    for i, pa in enumerate(ProductAccessories.objects.filter(product=product)):
        pa.position = (i + 1) * 10
        pa.save()
Updates positions of product accessories for given product.
dataset/ETHPy150Open diefenbach/django-lfs/lfs/manage/product/accessories.py/_update_positions