private void AppendPublisher()
        {
            if (Page.IsValid)
            {
                string publisherName = txtPublisherName.Text;
                string country       = ddlCountries.SelectedValue;
                string description   = txtDescription.Text;

                //Creates an instance of Genre class
                Publisher publisher = new Publisher(publisherName, country, description);

                if (!publisher.CheckIfPublisherExists(publisherName))
                {
                    //Appends a new Genre into database
                    publisher.AddPublisher(publisher);
                    lblNewPublisher.Text = publisherName;
                    divSuccess.Visible   = true;
                    ClearTextFields();
                    txtPublisherName.Focus();
                }
                else
                {
                    publisher       = null;
                    divFail.Visible = true;
                }
            }
        }
 public ActionResult IndexPublisher(AuthBookPublish model)
 {
     if (ModelState.IsValid)
     {
         publisher.AddPublisher(model.publisher);
         AllViewBag();
         return(View("Index"));
     }
     else
     {
         AllViewBag();
         return(View("Index"));
     }
 }