/// <summary> /// Add Customer Requirement(Post) /// </summary> /// <param name="post">Post</param> /// <returns>status</returns> public static int AddPost(Post post) { int result; var objpost = new TMSDataLibrary.Post(); result = objpost.AddPost(post.UserId, post.SourceCity, post.DestinationCity, post.Weight, post.SchdDate, post.MaterialTypeId, post.VehicleTypeId); return result; }
/// <summary> /// Get Total Count for Transporter,Customer,Vehicle /// </summary> /// <returns></returns> public static Post GetTotalNumber() { DataTable dt = new DataTable(); Post post = new Post(); TMSDataLibrary.Post _post = new TMSDataLibrary.Post(); dt = _post.GetTotalNumber(); if (dt.Rows.Count > 0) { post.Transporter = Convert.ToInt32(dt.Rows[0]["TotalCount"]); post.Customer = Convert.ToInt32(dt.Rows[1]["TotalCount"]); post.Vehicle = Convert.ToInt32(dt.Rows[2]["TotalCount"]); post.BookingCount = Convert.ToInt32(dt.Rows[3]["TotalCount"]); } return post; }