Exemplo n.º 1
0
        public IActionResult OnPost()
        {
            IActionResult temp;

            if (ModelState.IsValid == false) //If there are errors, go to this page
            {
                temp = Page();
            }
            else
            {
                if (song is null == false)
                {
                    SongDataAccessLayer factory = new SongDataAccessLayer(_configuration);
                    factory.Create(song);
                }
                temp = Page();
            }
            return(temp);
        }
Exemplo n.º 2
0
 public ControlPanelModel(IConfiguration configuration)
 {
     _configuration = configuration;
     factory        = new SongDataAccessLayer(_configuration);
 }
Exemplo n.º 3
0
 public EditSongModel(IConfiguration configuration)
 {
     _configuration = configuration;
     factory        = new SongDataAccessLayer(_configuration);
 }