Esempio n. 1
0
        public ActionResult AddArtWork()
        {
            ArtWorkModel am = new ArtWorkModel();

            am.YearList = dataService.YearPublishedService.YearList();
            am.ArtTypeList = dataService.ArtTypeService.ArtTypeList();
            am.ArtistList = dataService.ArtistService.ArtistList();

            return View(am);
        }
Esempio n. 2
0
        public ActionResult AddArtWork(ArtWorkModel model)
        {
            ArtWork art = new ArtWork();

            art.ArtistId = model.ArtistId;
            art.ArtTypeId = model.ArtTypeId;
            art.YearId = model.YearId;

            dataService.ArtWorkService.AddNew(art);

            return View("ThankYou");
        }
Esempio n. 3
0
        public ActionResult EditArtWork(ArtWorkModel model)
        {
            ArtWork am = new ArtWork();

            am.ArtId = model.ArtWorkId;

            //am.YearList = dataService.YearPublishedService.YearList();
            am.YearId = model.YearId;

            //am.ArtTypeList = dataService.ArtTypeService.ArtTypeList();
            am.ArtTypeId = model.ArtTypeId;

            //am.ArtistList = dataService.ArtistService.ArtistList();
            am.ArtistId = model.ArtistId;

            dataService.ArtWorkService.Edit(am);

            return View("ThankYou");
        }
Esempio n. 4
0
        public ActionResult EditArtWork()
        {
            ArtWorkModel am = new ArtWorkModel();

            var artwork = dataService.ArtWorkService.FindBy(2);

            am.ArtWorkId = artwork.ArtId;

            am.YearList = dataService.YearPublishedService.YearList();
            am.YearId = artwork.YearId;

            am.ArtTypeList = dataService.ArtTypeService.ArtTypeList();
            am.ArtTypeId = artwork.ArtTypeId;

            am.ArtistList = dataService.ArtistService.ArtistList();
            am.ArtistId = artwork.ArtistId;

            return View(am);
        }