from django.shortcuts import render
from .models import Destination

# Create your views here.

def index(request):

      dest1 = Destination()
      dest1.name = 'Islamabad'
      dest1.desc = '2nd Most Beautiful Capital of World'
      dest1.img = 'destination_1.jpg'
      dest1.price = 800
      dest1.offer = True

      dest2 = Destination()
      dest2.name = 'Lahore'
      dest2.desc = 'Food Capital of Pakistan'
      dest2.img = 'destination_2.jpg'
      dest2.price = 650
      dest2.offer = True

      dest3 = Destination()
      dest3.name = 'Karachi'
      dest3.desc = 'Financial Hub'
      dest3.img = 'destination_3.jpg'
      dest3.price = 750
      dest3.offer = False

      dests = [dest1,dest2,dest3]

      return render(request, "index.html", {'destinations': dests})