Did I find the right examples for you? yes no

All Samples(8)  |  Call(8)  |  Derive(0)  |  Import(0)

src/d/j/django-lfs-0.7.7/lfs/manage/shipping_methods/views.py   django-lfs(Download)
    """
    try:
        shipping_method = ShippingMethod.objects.all()[0]
    except IndexError:
        url = reverse("lfs_manage_no_shipping_methods")
    return render_to_string(template_name, RequestContext(request, {
        "current_id": current_id,
        "shipping_methods": ShippingMethod.objects.all(),
    }))
 

src/d/j/django-lfs-HEAD/lfs/manage/shipping_methods/views.py   django-lfs(Download)
    """
    try:
        shipping_method = ShippingMethod.objects.all()[0]
    except IndexError:
        url = reverse("lfs_manage_no_shipping_methods")
    return render_to_string(template_name, RequestContext(request, {
        "current_id": current_id,
        "shipping_methods": ShippingMethod.objects.all(),
    }))
 

src/l/f/lfs-HEAD/manage/views/shipping.py   lfs(Download)
    """
    try:
        shipping_method = ShippingMethod.objects.all()[0]
    except IndexError:
        url = reverse("lfs.manage.views.add_shipping_method")
    return render_to_string(template_name, RequestContext(request, {
        "current_id" : current_id,
        "shipping_methods" : ShippingMethod.objects.all(),
    }))
 

src/d/j/django-lfs-0.7.7/lfs/core/management/commands/lfs_migrate.py   django-lfs(Download)
        # Shipping Method
        db.add_column("shipping_shippingmethod", "price_calculator", models.CharField(max_length=200, choices=settings.LFS_SHIPPING_METHOD_PRICE_CALCULATORS, default=settings.LFS_SHIPPING_METHOD_PRICE_CALCULATORS[0][0]))
        for shipping_method in ShippingMethod.objects.all():
            shipping_method.price_calculator = settings.LFS_SHIPPING_METHOD_PRICE_CALCULATORS[0][0]
            shipping_method.save()

src/d/j/django-lfs-HEAD/lfs/core/management/commands/lfs_migrate.py   django-lfs(Download)
        # Shipping Method
        db.add_column("shipping_shippingmethod", "price_calculator", models.CharField(max_length=200, choices=settings.LFS_SHIPPING_METHOD_PRICE_CALCULATORS, default=settings.LFS_SHIPPING_METHOD_PRICE_CALCULATORS[0][0]))
        for shipping_method in ShippingMethod.objects.all():
            shipping_method.price_calculator = settings.LFS_SHIPPING_METHOD_PRICE_CALCULATORS[0][0]
            shipping_method.save()