//
        //Bound diem den
        public ActionResult TimDiemDen(string maNoiDi)
        {
            if (string.IsNullOrEmpty(maNoiDi))
            {
                return(Json(null));
            }
            var lstNoiDen = DiaDiemQueries.TimDiemDen(int.Parse(maNoiDi));

            return(Json(lstNoiDen));
        }
示例#2
0
        public ThaoTacTourViewModel(string maTour)
        {
            TourChiTietViewModel tour = TourQueries.TimTour(maTour);

            Tour          = tour.Tour;
            DiemDis       = DiaDiemQueries.LoadDiaDiem(tour.Tour.MaDiaDiemDi.ToString());
            DiemDens      = DiaDiemQueries.LoadDiaDiem(tour.Tour.MaDiaDiemDen.ToString());
            KhachSans     = KhachSanQueries.LayDsKhachSan(tour.MaKS);
            LoaiTours     = TourQueries.LoadLoaiTour(tour.Tour.LoaiTour);
            HuongDanViens = NhanVienQueries.LoadHuongDanVien(tour.Tour.MaHDV);
        }
示例#3
0
        public ThaoTacTourViewModel()
        {
            DiemDis = DiaDiemQueries.LoadDiaDiem();
            //DiemDis.SelectedValue = DiemDis.FirstOrDefault().Value;
            int?maDiemDi = int.Parse(DiemDis.SelectedValue.ToString());

            DiemDens      = DiaDiemQueries.TimDiemDen2(maDiemDi);//
            KhachSans     = KhachSanQueries.LayDsKhachSan();
            LoaiTours     = TourQueries.LoadLoaiTour();
            HuongDanViens = NhanVienQueries.LoadHuongDanVien();//
        }
        //
        // GET: /TrangChu/
        public ActionResult Index(int?page)
        {
            int pageSize = 8;

            int pageIndex = 1;

            pageIndex     = page.HasValue ? Convert.ToInt32(page) : 1;
            ViewBag.Tours = TourQueries.LoadDSTour().ToPagedList(pageIndex, pageSize);

            ViewBag.MaDiaDiemDi  = DiaDiemQueries.LoadDiaDiem();;
            ViewBag.MaDiaDiemDen = DiaDiemQueries.TimDiemDen2(int.Parse(ViewBag.MaDiaDiemDi.SelectedValue.ToString()));

            //List<string> lst = new List<string>();
            //lst = TourQueries.Loc_CollaborativeFiltering("1885", "15", 9);


            return(View(new TimKiemTourViewModel()));
        }
 public HanhTrinhViewModel()
 {
     DiaDiem = DiaDiemQueries.LoadDiaDiem();
 }