Did I find the right examples for you? yes no

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

src/l/f/lfs-buildout-development-HEAD/scripts/load_data.py   lfs-buildout-development(Download)
    site.save()
 
    ie = Country.objects.get(code="ie")
    gb = Country.objects.get(code="gb")
    de = Country.objects.get(code="de")
    us = Country.objects.get(code="us")
    fr = Country.objects.get(code="fr")

src/d/j/django-lfs-HEAD/lfs/checkout/views.py   django-lfs(Download)
    country_iso = request.POST.get("invoice-country")
    if address and country_iso:
        address.country = Country.objects.get(code=country_iso.lower())
        address.save()
        customer.sync_selected_to_default_invoice_address()
    country_iso = request.POST.get("shipping-country")
    if address:
        address.country = Country.objects.get(code=country_iso.lower())
        address.save()
        customer.sync_selected_to_default_shipping_address()
 
        if country_iso is not None:
            country = Country.objects.get(code=country_iso.lower())
            if customer.selected_shipping_address:
                customer.selected_shipping_address.country = country
            country_iso = request.POST.get("shipping-country", None)
            if country_iso is not None:
                country = Country.objects.get(code=country_iso.lower())
                if customer.selected_invoice_address:
                    customer.selected_invoice_address.country = country

src/d/j/django-lfs-0.7.7/lfs/order/utils.py   django-lfs(Download)
        invoice_state=invoice_address.state,
        invoice_code=invoice_address.zip_code,
        invoice_country=Country.objects.get(code=invoice_address.country.code),
        invoice_phone=customer.selected_invoice_address.phone,
 
        shipping_state=shipping_address.state,
        shipping_code=shipping_address.zip_code,
        shipping_country=Country.objects.get(code=shipping_address.country.code),
        shipping_phone=shipping_address.phone,
 

src/d/j/django-lfs-0.7.7/lfs/customer/views.py   django-lfs(Download)
            customer_selected_address.state = request.POST.get(prefix + "-state", "")
            customer_selected_address.zip_code = request.POST.get(prefix + "-code", "")
            customer_selected_address.country = Country.objects.get(code=country_iso.lower())
            customer_selected_address.save()
    if not existing_address:
                                                           state=request.POST.get(prefix + "-state", ""),
                                                           zip_code=request.POST.get(prefix + "-code", ""),
                                                           country=Country.objects.get(code=country_iso.lower()))
    setattr(customer, address_attribute, customer_selected_address)
    customer.save()

src/d/j/django-lfs-0.7.7/lfs/checkout/forms.py   django-lfs(Download)
            shipping_country_code = self.data.get("shipping-country", None)
            if shipping_country_code:
                shipping_country = Country.objects.get(code=shipping_country_code.lower())
            if shipping_country:
                if shipping_country not in shipping_countries:
            shipping_country_code = self.data.get("invoice-country", None)
            if shipping_country_code:
                shipping_country = Country.objects.get(code=shipping_country_code.lower())
 
        # Check data of selected payment method

src/d/j/django-lfs-0.7.7/lfs/checkout/views.py   django-lfs(Download)
 
    if country_iso is not None:
        country = Country.objects.get(code=country_iso.lower())
        if customer.selected_shipping_address:
            customer.selected_shipping_address.country = country

src/d/j/django-lfs-0.7.7/lfs/cart/views.py   django-lfs(Download)
    country_iso = request.POST.get("country")
    if country_iso:
        selected_country = Country.objects.get(code=country_iso.lower())
        customer.selected_country_id = selected_country.id
        if customer.selected_shipping_address:

src/d/j/django-lfs-HEAD/lfs/cart/views.py   django-lfs(Download)
    country_iso = request.POST.get("country")
    if country_iso:
        selected_country = Country.objects.get(code=country_iso.lower())
        customer.selected_country_id = selected_country.id
        if customer.selected_shipping_address:

src/d/j/django-lfs-HEAD/lfs/addresses/utils.py   django-lfs(Download)
 
            try:
                country = Country.objects.get(code__iexact=self.data.get("%s-country" % self.type))
                self.address.country = country
            except Country.DoesNotExist:

src/d/j/django-lfs-0.7.7/lfs/checkout/tests/test_checkout.py   django-lfs(Download)
    def setUp(self):
        """
        """
        ie = Country.objects.get(code="ie")
        gb = Country.objects.get(code="gb")
        de = Country.objects.get(code="de")
        us = Country.objects.get(code="us")
        fr = Country.objects.get(code="fr")

  1 | 2 | 3  Next