Click here to Skip to main content
15,896,437 members
Articles / Web Development / ASP.NET

Developing and Unit Testing an ASP.NET MVC 2 Application

Rate me:
Please Sign up or sign in to vote.
4.68/5 (36 votes)
28 Jun 2010CPOL13 min read 132.7K   7.2K   96  
An introduction with AJAX, jQuery, JSON, MvcContrib and NUnit
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using DataModels;
using System.Reflection;
using CodeProjectBLL;

namespace MVCWebSite.Models
{
    public class PatientViewModel : DataModels.Patient
    {
        
        public long CurrentPageNumber { get; set; }     
  
        public long PageSize { get; set; }      
 
        public long TotalPages { get; set; }

        public long TotalRows { get; set; }

        public List<string> ReturnMessage { get; set; }

        public bool ReturnStatus { get; set; }

        public string SortBy { get; set; }

        public string SortAscendingDescending { get; set; }

        /// <summary>
        /// Update View Model
        /// </summary>
        /// <param name="fromRecord"></param>
        /// <param name="fromFields"></param>
        public void UpdateViewModel(object fromRecord, PropertyInfo[] fromFields)
        {
            UtilitiesBLL.SetProperties(fromFields, fromRecord, this);
        }
      
    }    

}

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Software Developer Joey Software Solutions
United States United States
Mark Caplin has specialized in Information Technology solutions for the past 30 years. Specializing in full life-cycle development projects for both enterprise-wide systems and Internet/Intranet based solutions.

For the past fifteen years, Mark has specialized in the Microsoft .NET framework using C# as his tool of choice. For the past four years Mark has been implementing Single Page Applications using the Angular platform.

When not coding, Mark enjoys playing tennis, listening to U2 music, watching Miami Dolphins football and watching movies in Blu-Ray technology.

In between all this, his wife of over 25 years, feeds him well with some great home cooked meals.

You can contact Mark at mark.caplin@gmail.com

...

Comments and Discussions