namespace VECV_WebApi.Models.Ticket { using DocumentFormat.OpenXml; using DocumentFormat.OpenXml.Packaging; using DocumentFormat.OpenXml.Spreadsheet; using LoggingHelper; #region Namespaces using System; using System.Collections.Generic; using System.ComponentModel.DataAnnotations; using System.Configuration; using System.Data; using System.Diagnostics; using System.IO.IsolatedStorage; using System.Linq; using System.Reflection; using System.Web; #endregion #region Model Classes public class ConsolidatedReportModelClosed { public string ticketid_alias { get; set; } public string call_assigned_to { get; set; } public string created_by { get; set; } //[DisplayFormat(ApplyFormatInEditMode = true, DataFormatString = "{0:dd MMM yyyy HH:mm:ss}")] //public DateTime creation_time { get; set; } public string creation_time { get; set; } public string time_slot { get; set; } public string customer_name { get; set; } public string customer_contact_no { get; set; } public string organization { get; set; } public string state { get; set; } public string city { get; set; } public string language_name { get; set; } public string owner_name { get; set; } public string owner_contact_number { get; set; } public string customer_vehicle_regn_no { get; set; } public string vehicle_name { get; set; } public string vehicle_type { get; set; } public string chassis_number { get; set; } public string vehicle_instalation_date { get; set; } public string breakdown_location { get; set; } public string landmark { get; set; } public string warranty { get; set; } public string how_did_you_come_to_know_of_eos { get; set; } public string type_of_load_carried { get; set; } public string nature_of_problem { get; set; } public string estimated_cost_string { get { if (Convert.ToString(call_assigned_to).ToLower().Trim() != "dealer") return estimated_cost; else return "NA"; } set { } } public string estimated_time_string { get { if (Convert.ToString(call_assigned_to).ToLower().Trim() != "dealer") return estimated_time; else return "NA"; } set { } } public string dealer_code { get; set; } public string dealer_name { get; set; } /// /// get or set wm name /// public string wm_name { get; set; } public string dealer_contact_no { get; set; } public string eos_team_member_and_van { get; set; } public string open_call_hrs { get; set; } public string time_stamps_status_1 { get; set; } public string time_stamps_status_3 { get; set; } public string time_stamps_status_4 { get; set; } public string time_stamps_status_5 { get; set; } public string escalation_level_van_not_move_1 { get; set; } public string escalation_level_ticket_closer_1 { get; set; } public string call_closure_status { get; set; }//reason for 24 hrs public string KmCovered { get; set; } public string feedback_taken { get; set; }//feedback public string feedback_ease_of_getting_call { get; set; } public string feedback_response_of_call_center { get; set; } public string feedback_timely_updation_by_dealer { get; set; } public string feedback_total_repair_time { get; set; } public string feedback_eos_charges { get; set; } public string feedback_over_all_experience { get; set; } public string closure_remarks { get; set; } public string response_string { get { if (Convert.ToString(call_assigned_to).ToLower().Trim() != "dealer") return response; else return "NA"; } set { } } public string feedback_count { get; set; } public string call_status { get; set; } public string complaints { get; set; } public string suggestion { get; set; } public string feedback_agent { get; set; } public string other_remarks { get; set; } public string DealerTicketOtherRemark { get; set; } public string estimated_distance { get; set; } public string van_covered_distance { get; set; } public string trip_start_time { get; set; } public string trip_end_time { get; set; } public string _eicher_promise { get; set; } public string opportunity_loss { get; set; } public string opportunity_loss_remark { get; set; } public string opportunity_lost_remarks { get; set; } public string remark_ticket_not_closed_24_hours { get; set; } public string remark_ticket_not_closed_24_hours_remarks { get; set; } public int reopen_count { get; set; } public string ChassisNo { get; set; } public double OdometerReading { get; set; } public string _call_closed_within_24_hours { get; set; } //public string Region { get; set; } public string load_carried { get; set; } public string feedback_parameter_wise_score { get; set; } public string total_inbound_calls { get; set; } public string total_outbound_calls { get; set; } public string time_stamps_status_2 { get; set; } public string escalation_level_van_not_move_2 { get; set; } public string escalation_level_van_not_move_3 { get; set; } public string escalation_level_van_not_move_4 { get; set; } public string escalation_level_van_not_move_5 { get; set; } public string escalation_level_van_not_move_6 { get; set; } public string escalation_level_van_not_move_7 { get; set; } public string escalation_level_van_not_move_8 { get; set; } public string escalation_level_van_not_move_9 { get; set; } public string escalation_level_van_not_move_10 { get; set; } public string escalation_level_ticket_closer_2 { get; set; } public string escalation_level_ticket_closer_3 { get; set; } public string escalation_level_ticket_closer_4 { get; set; } public string escalation_level_ticket_closer_5 { get; set; } public string escalation_level_ticket_closer_6 { get; set; } public string escalation_level_ticket_closer_7 { get; set; } public string escalation_level_ticket_closer_8 { get; set; } public string escalation_level_ticket_closer_9 { get; set; } public string escalation_level_ticket_closer_10 { get; set; } public string month_name { get; set; } public string default_sla_time { get; set; } public string region { get; set; } public string vehicle_model { get; set; } public List CloseTicketCountInTimeSlot { get; set; } public string estimated_time { get; set; } public string response { get; set; } public string estimated_cost { get; set; } public string ticket_id { get; set; } /// /// Get or set last updated time(for consolidate report) /// [Display(Name = "Reassignment Date and Time")] public string last_Updated_Time { get; set; } /// /// Get or set are_you_satisfied /// [Display(Name = "Overall Customer Satisfied")] public string are_you_satisfied { get; set; } /// /// Get or set not_satisfied_option /// [Display(Name = "Reason for dissatisfaction")] public string not_satisfied_option { get; set; } /// /// Get or set not_satisfied_reason /// [Display(Name = "Feedback Comments")] public string not_satisfied_reason { get; set; } public double? response_time_reassignment { get; set; } //added on 03/12/2020 public string vehicle_warranty { get; set; } public string vehicle_amc { get; set; } public string vehicle_emission_norms { get; set; } public string vehicle_sales_date { get; set; } //ended on 03/12/2020 public string van_reached_punch_time { get; set; } //added on 23-12-2020 public string ticket_closed_reason { get; set; } //added on 25-11-2020 [Display(Name = "Location change Reassignment Date and Time")] public string location_change_time { get; set; } [Display(Name = "Is Location changed")] public string is_location_change { get; set; } [Display(Name = "Dealer Change Reason")] public string dealer_change_reason { get; set; } [Display(Name = "Dealer Change Reason Remarks")] public string dealer_change_reason_other_remark { get; set; } [Display(Name = "Vehicle Status")] public string vehicle_status { get; set; } [Display(Name = "Fuel Type")] public string fuel_type { get; set; } public string breakdown_latitude { get; set; } public string breakdown_longitude { get; set; } } public class WhatupAPIModel { public string templateId { get; set; } public string mobileNumber { get; set; } public int? Status { get; set; } public string Message { get; set; } } public class WhatupModel { public string Token { get; set; } public string MobileNumber { get; set; } public double Latitude { get; set; } public double Longitude { get; set; } public int? Status { get; set; } public string Message { get; set; } public string errorMessage { get; set; } } /// /// This class contain customer ehicle properties /// public class CustomerVehicleModel { /// /// Get or set token /// public string Token { get; set; } /// /// Get or set Status /// public int? Status { get; set; } /// /// Get or set Utc Minute /// public int? UtcMinute { get; set; } /// /// Get or set Message /// public string Message { get; set; } /// /// Get or set Ticket No /// public string TicketNo { get; set; } /// /// Get or set Customer Id /// public string CustomerId { get; set; } /// /// Get or set Customer Name /// public string CustomerName { get; set; } /// /// Get or set Customer Alias /// public string CustomerAlias { get; set; } /// /// Get or set CustomerMobile1 /// public string CustomerMobile1 { get; set; } /// Get or set CustomerMobile2 /// public string CustomerMobile2 { get; set; } /// /// Get or set CustomerMobile3 /// public string CustomerMobile3 { get; set; } /// /// Get or set CustomerAddress /// public string CustomerAddress { get; set; } /// /// Get or set CustomerEmailId /// public string CustomerEmailId { get; set; } /// /// Get or set CustomerCity /// public string CustomerCity { get; set; } /// /// Get or set CustomerState /// public string CustomerState { get; set; } /// /// Get or set CustomerVehicleCustomerId /// public string CustomerVehicleCustomerId { get; set; } /// /// Get or set CustomerVehicleVehicleId /// public string CustomerVehicleVehicleId { get; set; } /// /// Get or set CustomerVehicleIsOwnwer /// public Boolean? CustomerVehicleIsOwnwer { get; set; } /// /// Get or set VehicleId /// public string VehicleId { get; set; } /// /// Get or set VehicleRegistrationNumber /// public string VehicleRegistrationNumber { get; set; } /// /// Get or set VehicleNumberPlate /// public string VehicleNumberPlate { get; set; } /// /// Get or set VehicleModelNumber /// public string VehicleModelNumber { get; set; } /// /// Get or set Vehicle Type /// public string VehicleType { get; set; } } public class Response { public VehicleData[] vehicleData { get; set; } public string errorMessage { get; set; } } public class VehicleData { public string vehicleNo { get; set; } public string chassisNo { get; set; } public double latitude { get; set; } public double longitude { get; set; } public string deviceStatus { get; set; } public long lastUpdated { get; set; } public double vehicleSpeed { get; set; } public string lifeTimeFuelLtr { get; set; } public double engineOperatingHours { get; set; } public double odometer { get; set; } public double heading { get; set; } public double fuelLevelInPer { get; set; } public double fuelLevelInLtr { get; set; } public double defLevelInLtr { get; set; } public string deviceId { get; set; } } public class DeviceData { public string DeviceId { get; set; } public string EDateTime { get; set; } public string MainInputVoltage { get; set; } public string vehicleBattery { get; set; } } public class Telematic_Model { public string status { get; set; } public string latitude { get; set; } public string longitude { get; set; } public string chassis_no { get; set; } public string positionDateTime { get; set; } public string odometer { get; set; } public string lastdate { get; set; } } public class Telematic_Model_new { public string status { get; set; } public string latitude { get; set; } public string longitude { get; set; } public string chassis_no { get; set; } public string positionDateTime { get; set; } // public DateTime positionDateTime { get; set; } public string odometer { get; set; } public string lastdate { get; set; } } /// /// This class contain open ticket properties /// public class TicketOpenModel { /// [Display(Name = "ASM")] public string ASMName { get; set; } /// /// Get or set Customer Contact No. /// [Display(Name = "ASM Contact No.")] public string ASMNo { get; set; } /// /// Get or set customer name /// [Display(Name = "CSM")] public string CSMName { get; set; } /// /// Get or set Customer Contact No. /// [Display(Name = "CSM Contact No.")] public string CSMNo { get; set; } /// /// Get or set customer name /// [Display(Name = "RSM")] public string RSMName { get; set; } /// /// Get or set Customer Contact No. /// [Display(Name = "RSM Contact No.")] public string RSMNo { get; set; } [Display(Name = "Dealer 1s code")] public string dealer1scode { get; set; } private string _PreClosureTime = ""; /// /// Get or set Token /// public String Token { get; set; } /// /// Get or set KAM Id /// public string KamId { get; set; } /// /// Get or set ticket id alias /// public string ticketid_alias { get; set; } //--- added on 06-01-2020 start ----------- //public string vehicle_warranty { get; set; } //public string vehicle_amc { get; set; } public double odometer_reading { get; set; } //public string vehicle_sales_date { get; set; } public string ticket_source { get; set; } public string customer_id { get; set; } public string customer_type { get; set; } public string owner_name { get; set; } public Boolean? is_kam { get; set; } public string NewVehicleType { get; set; } //added on 11-01-2021 //--- added on 06-01-2020 end ------------- /// /// Get or set Status /// public string Status { get; set; } /// /// Get or set Message /// public string Message { get; set; } /// /// Get or set Id /// public string Id { get; set; } /// /// Get or set Description /// public string Description { get; set; } /// /// Get or set Assigned To /// public string AssignedTo { get; set; } /// /// Get or set Reported Via /// public string ReportedVia { get; set; } /// /// Get or set Ticket Status /// public int? TicketStatus { get; set; } /// /// Get or set Priority /// public int? Priority { get; set; } /// /// Get or set Cutomer Score /// public string CutomerScore { get; set; } /// /// Get or set Created By /// public string CreatedBy { get; set; } /// /// Get or set Creation Time /// public string CreationTime { get; set; } /// /// Get or set Last Modified By /// public string LastModifiedBy { get; set; } /// /// Get or set Last Modified Time /// public string LastModifiedTime { get; set; } /// /// Get or set Break Down Location /// public string BreakDownLocation { get; set; } /// /// Get or set Breack Down Longitude /// public string BreackDownLongitude { get; set; } /// /// Get or set Breack Down Latitude /// public string BreackDownLatitude { get; set; } /// /// Get or set Assigned To User Id /// public string AssignedToUserId { get; set; } /// /// Get or set Assigned To User Longitude /// public string AssignedToUserLongitude { get; set; } /// /// Get or set Assigned To User Latitude /// public string AssignedToUserLatitude { get; set; } /// /// Get or set Is Declined /// public Boolean? IsDeclined { get; set; } /// /// Get or set Estimated Time For Job Complition /// public int? EstimatedTimeForJobComplition { get; set; } /// /// Get or set Total Ticket Life Cycle Time Slab /// public int? TotalTicketLifeCycleTimeSlab { get; set; } /// /// Get or set Estimated Time For Job Complition Submit Time /// public string EstimatedTimeForJobComplitionSubmitTime { get; set; } /// /// Get or set Vehicle Registration No /// public string VehicleRegistrationNo { get; set; } /// /// Get or set Estimated Time For Job Completion Submit Time /// public string EstimatedTimeForJobCompletionSubmitTime { get; set; } /// /// Get or set Break down Location Landmark /// public string BreakdownLocationLandmark { get; set; } /// /// Get or set Activity Tickets Open Created By /// public string ActivityTicketsOpenCreatedBy { get; set; } /// /// Get or set Activity Tickets Open Creation Time /// public string ActivityTicketsOpenCreationTime { get; set; } /// /// Get or set Remarks /// public string Remarks { get; set; } /// /// Get or set Ticket Activity Status /// public string TicketActivityStatus { get; set; } /// /// Get or set Ticket Status Alias /// public string TicketStatusAlias { get; set; } /// /// Get or set Ticket Status Sequence Order /// public string TicketStatusSequenceOrder { get; set; } /// /// Get or set Ticket Status Name /// public string TicketStatusStatusName { get; set; } /// /// Get or set User Id /// public string UserId { get; set; } /// /// Get or set Auth Engine Id /// public string AuthEngineId { get; set; } /// /// Get or set User Name /// public string UserName { get; set; } /// /// Get or set Designation /// public string Designation { get; set; } /// /// Get or set Object Id /// public string ObjectId { get; set; } /// /// Get or set Organization Id /// public int? OrganizationId { get; set; } /// /// Get or set City /// public string City { get; set; } /// /// Get or set State /// public string State { get; set; } /// /// Get or set Region /// public string Region { get; set; } /// /// Get or set Language /// public string Language { get; set; } /// /// Get or set Timezone Id /// public Int64? TimezoneId { get; set; } /// /// Get or set Display Name /// public string DisplayName { get; set; } /// /// Get or set Offset In Minutes /// public string OffsetInMinutes { get; set; } /// /// Get or set Display Id /// public string DisplayId { get; set; } /// /// Get or set User Organization Name /// public string UserOrganizationName { get; set; } /// /// Get or set User Organization Alias /// public string UserOrganizationAlias { get; set; } /// /// Get or set User Organization City /// public string UserOrganizationCity { get; set; } /// /// Get or set User Organization State /// public string UserOrganizationState { get; set; } /// /// Get or set User Asorganization Country /// public string UserAsorganizationCountry { get; set; } /// /// Get or set User Organization Description /// public string UserOrganizationDescription { get; set; } /// /// Get or set User Org Path /// public string UserOrgPath { get; set; } /// /// Get or set User Org Depth /// public string UserOrgDepth { get; set; } /// /// Get or set User Org Color /// public string UserOrgColor { get; set; } /// /// Get or set User Organization Region /// public string UserOrganizationRegion { get; set; } /// /// Get or set Dealer Id /// public string DealerId { get; set; } /// /// Get or set Organization Id /// public int? DealerOrganizationId { get; set; } /// /// Get or set Dealer Name /// public string DealerDealerName { get; set; } /// /// Get or set Dealer City /// public string DealerCity { get; set; } /// /// Get or set Dealer State /// public string DealerState { get; set; } /// /// Get or set Dealer Default Lattitude /// public string DealerDealerDefaultLattitude { get; set; } /// /// Get or set Dealer Default Longitude /// public string DealerDealerDefaultLongitude { get; set; } /// /// Get or set Van Id /// public string VanId { get; set; } /// /// Get or set Van Alias /// public string VanAlias { get; set; } /// /// Get or set Van Default Lattitude /// public string VanVanDefaultLattitude { get; set; } /// /// Get or set Van Default Longitude /// public string VanVanDefaultLongitude { get; set; } /// /// Get or set Van City /// public string VanCity { get; set; } /// /// Get or set Van State /// public string VanState { get; set; } /// /// Get or set Van Model /// public string VanVanModel { get; set; } /// /// Get or set Van Registration Number /// public string VanRegistrationNumber { get; set; } /// /// Get or set Van Registered As /// public string VanVanRegisteredAs { get; set; } /// /// Get or set Organization Name /// public string DealerVanOrganizationName { get; set; } /// /// Get or set Organization Alias /// public string DealerVanOrganizationOrganizationAlias { get; set; } /// /// Get or set Organization City /// public string DealerVanOrganizationOrganizationCity { get; set; } /// /// Get or set Organization State /// public string DealerVanOrganizationOrganizationState { get; set; } /// /// Get or set Organization Country /// public string DealerVanOrganizationOrganizationCountry { get; set; } /// /// Get or set Organization Description /// public string DealerVanOrganizationOrganizationDescription { get; set; } /// /// Get or set Organization Path /// public string DealerVanOrganizationOrganizationPath { get; set; } /// /// Get or set Organization Depth /// public string DealerVanOrganizationOrganizationDepth { get; set; } /// /// Get or set Organization Color /// public string DealerVanOrganizationOrganizationColor { get; set; } /// /// Get or set Organization Region /// public string DealerVanOrganizationOrganizationRegion { get; set; } /// /// Get or set Service Engineer Id /// public string ServiceEngineerId { get; set; } /// /// Get or set Service Engineer Name /// public string ServiceEngineerName { get; set; } /// /// Get or set Service Engineer Alias /// public string ServiceEngineerAlias { get; set; } /// /// Get or set Service Engineer Imei Number /// public string ServiceEngineerImeiNumber { get; set; } /// /// Get or set Service Engineer Contact Number /// public string ServiceEngineerContactNumber { get; set; } /// /// Get or set Service Engineer Application License Key /// public string ServiceEngineerApplicationLicenseKey { get; set; } /// /// Get or set Service Engineer Mobile Application Blocked /// public Boolean? ServiceEngineerMobileApplicationBlocked { get; set; } /// /// Get or set Service Engineer Device Alias /// public Int64? ServiceEngineerDeviceAlias { get; set; } /// /// Get or set Service Engineer Pin Password /// public string ServiceEngineerPinPassword { get; set; } /// /// Get or set Route Id /// public int? RouteId { get; set; } /// /// Get or set Custome Contact_no /// public string CustomeContact_no { get; set; } /// /// Get or set Vehicle Type /// public string VehicleType { get; set; } /// /// Get or set Repair Cost /// public string RepairCost { get; set; } /// /// Get or set Default Sla Time /// public int? DefaultSlaTime { get; set; } /// /// Get or set Device Alias /// public int? DeviceAlias { get; set; } /// /// Get or set Iemi number /// public string Ieminumber { get; set; } /// /// Get or set Sla Missed Reason /// public string SlaMissedReason { get; set; } /// /// Get or set Suggestion Comment /// public string SuggestionComment { get; set; } /// /// Get or set Job Complete Response Time /// public string JobCompleteResponseTime { get; set; } /// /// Get or set Default Col 2 /// public string DefaultCol2 { get; set; } /// /// Get or set Default Col 3 /// public string DefaultCol3 { get; set; } /// /// Get or set Vehicle Tagging /// public string VehicleTagging { get; set; } /// /// Get or set Customer Name /// public string CustomerName { get; set; } /// /// Get or set /// public string EstimatedDistance { get; set; } /// /// Get or set Age(Ticket life cycle time creation to closed time) /// public double? Age { get; set; } /// /// Get or set Custome Contact_no /// public string OwnerContact_no { get; set; } /// /// Get or set Custome Contact_no /// public string CallStatus { get; set; } /// /// Get or set Custome Contact_no /// public string caller_language { get; set; } /// /// Get or set Security Token /// public string feedback_call_status { get; set; } /// /// Get or set Status /// public string total_count { get; set; } public string reopen_count { get; set; } /// /// Get or set Message /// public string gps_status { get; set; } public string PreClosureTime { get { if (_PreClosureTime == "01 Jan 0001 05:30:00") { _PreClosureTime = ""; } return _PreClosureTime; } set { _PreClosureTime = value; } } /// /// Get or set Is Deleted /// public bool? IsDeleted { get; set; } public string Score { get; set; } public string current_latitude { get; set; } public string current_longitude { get; set; } public string ChassisNo { get; set; } public double OdometerReading { get; set; } //added on 25-09-2020 public string VanReachedPunchTime { get; set; } //added on 23-12-2020 public string VanLatitudeAtTripStart { get; set; } //[Display(Name = "Van Trip Start Longitude")] public string VanLongitudeAtTripStart { get; set; } //[Display(Name = "Van Reached Latitude")] public string VanLatitudeAtVanReached { get; set; } //[Display(Name = "Van Reached Longitude")] public string VanLongitudeAtVanReached { get; set; } //[Display(Name = "Van Trip End Latitude")] public string VanLatitudeAtTripEnd { get; set; } //[Display(Name = "Van Reached Longitude")] public string VanLongitudeAtTripEnd { get; set; } public string BreakdownLocationLatitude { get; set; } public string BreakdownLocationLongitude { get; set; } public string TicketClosedReason { get; set; } //added on 25-11-2020 //added on 03/12/2020 public string vehicle_warranty { get; set; } public string vehicle_amc { get; set; } public string vehicle_emission_norms { get; set; } public string vehicle_sales_date { get; set; } public string WM_Contact_No { get; set; } public string WM_Name { get; set; } public string plant_code { get; set; } public string caseid { get; set; } //ended on 03/12/2020 } public class TicketOpenModelWise { public List ModelList { get; set; } } /// /// contains properties for close ticket details /// public class TicketCloseModel { /// /// Get or set Token /// public String Token { get; set; } /// /// Get or set Status /// public string Status { get; set; } /// /// Get or set Message /// public string Message { get; set; } /// /// Get or set Id /// public string Id { get; set; } /// /// Get or set Description /// public string Description { get; set; } /// /// Get or set Assigned To /// public string AssignedTo { get; set; } /// /// Get or set Reported Via /// public string ReportedVia { get; set; } /// /// Get or set Ticket Status /// public int? TicketStatus { get; set; } /// /// Get or set Priority /// public int? Priority { get; set; } /// /// Get or set Cutomer Score /// public string CutomerScore { get; set; } /// /// Get or set Created By /// public string CreatedBy { get; set; } /// /// Get or set Creation Time /// public string CreationTime { get; set; } /// /// Get or set Last Modified By /// public string LastModifiedBy { get; set; } /// /// Get or set Last Modified Time /// public string LastModifiedTime { get; set; } /// /// Get or set Break Down Location /// public string BreakDownLocation { get; set; } /// /// Get or set Breack Down Longitude /// public string BreackDownLongitude { get; set; } /// /// Get or set Breack Down Latitude /// public string BreackDownLatitude { get; set; } /// /// Get or set Assigned To User Id /// public string AssignedToUserId { get; set; } /// /// Get or set Assigned To User Longitude /// public string AssignedToUserLongitude { get; set; } /// /// Get or set Assigned To User Latitude /// public string AssignedToUserLatitude { get; set; } /// /// Get or set Is Declined /// public Boolean? IsDeclined { get; set; } /// /// Get or set Estimated Time For Job Complition /// public int? EstimatedTimeForJobComplition { get; set; } /// /// Get or set Total Ticket Life Cycle Time Slab /// public int? TotalTicketLifeCycleTimeSlab { get; set; } /// /// Get or set Estimated Time For Job Complition Submit Time /// public string EstimatedTimeForJobComplitionSubmitTime { get; set; } /// /// Get or set Vehicle Registration No /// public string VehicleRegistrationNo { get; set; } /// /// Get or set Estimated Time For Job Completion Submit Time /// public string EstimatedTimeForJobCompletionSubmitTime { get; set; } /// /// Get or set Break down Location Landmark /// public string BreakdownLocationLandmark { get; set; } /// /// Get or set Activity Tickets Open Created By /// public string ActivityTicketsOpenCreatedBy { get; set; } /// /// Get or set Activity Tickets Open Creation Time /// public string ActivityTicketsOpenCreationTime { get; set; } /// /// Get or set Remarks /// public string Remarks { get; set; } /// /// Get or set Ticket Activity Status /// public string TicketActivityStatus { get; set; } /// /// Get or set Ticket Status Alias /// public string TicketStatusAlias { get; set; } /// /// Get or set Ticket Status Sequence Order /// public string TicketStatusSequenceOrder { get; set; } /// /// Get or set Ticket Status Name /// public string TicketStatusStatusName { get; set; } /// /// Get or set User Id /// public string UserId { get; set; } /// /// Get or set Auth Engine Id /// public string AuthEngineId { get; set; } /// /// Get or set User Name /// public string UserName { get; set; } /// /// Get or set Designation /// public string Designation { get; set; } /// /// Get or set Object Id /// public string ObjectId { get; set; } /// /// Get or set Organization Id /// public int? OrganizationId { get; set; } /// /// Get or set City /// public string City { get; set; } /// /// Get or set State /// public string State { get; set; } /// /// Get or set Region /// public string Region { get; set; } /// /// Get or set Language /// public string Language { get; set; } /// /// Get or set Timezone Id /// public Int64? TimezoneId { get; set; } /// /// Get or set Display Name /// public string DisplayName { get; set; } /// /// Get or set Offset In Minutes /// public string OffsetInMinutes { get; set; } /// /// Get or set Display Id /// public string DisplayId { get; set; } /// /// Get or set User Organization Name /// public string UserOrganizationName { get; set; } /// /// Get or set User Organization Alias /// public string UserOrganizationAlias { get; set; } /// /// Get or set User Organization City /// public string UserOrganizationCity { get; set; } /// /// Get or set User Organization State /// public string UserOrganizationState { get; set; } /// /// Get or set User Asorganization Country /// public string UserAsorganizationCountry { get; set; } /// /// Get or set User Organization Description /// public string UserOrganizationDescription { get; set; } /// /// Get or set User Org Path /// public string UserOrgPath { get; set; } /// /// Get or set User Org Depth /// public string UserOrgDepth { get; set; } /// /// Get or set User Org Color /// public string UserOrgColor { get; set; } /// /// Get or set User Organization Region /// public string UserOrganizationRegion { get; set; } /// /// Get or set Dealer Id /// public string DealerId { get; set; } /// /// Get or set Organization Id /// public int? DealerOrganizationId { get; set; } /// /// Get or set Dealer Name /// public string DealerDealerName { get; set; } /// /// Get or set Dealer City /// public string DealerCity { get; set; } /// /// Get or set Dealer State /// public string DealerState { get; set; } /// /// Get or set Dealer Default Lattitude /// public string DealerDealerDefaultLattitude { get; set; } /// /// Get or set Dealer Default Longitude /// public string DealerDealerDefaultLongitude { get; set; } /// /// Get or set Van Id /// public string VanId { get; set; } /// /// Get or set Van Alias /// public string VanAlias { get; set; } /// /// Get or set Van Default Lattitude /// public string VanVanDefaultLattitude { get; set; } /// /// Get or set Van Default Longitude /// public string VanVanDefaultLongitude { get; set; } /// /// Get or set Van City /// public string VanCity { get; set; } /// /// Get or set Van State /// public string VanState { get; set; } /// /// Get or set Van Model /// public string VanVanModel { get; set; } /// /// Get or set Van Registration Number /// public string VanRegistrationNumber { get; set; } /// /// Get or set Van Registered As /// public string VanVanRegisteredAs { get; set; } /// /// Get or set Organization Name /// public string DealerVanOrganizationName { get; set; } /// /// Get or set Organization Alias /// public string DealerVanOrganizationOrganizationAlias { get; set; } /// /// Get or set Organization City /// public string DealerVanOrganizationOrganizationCity { get; set; } /// /// Get or set Organization State /// public string DealerVanOrganizationOrganizationState { get; set; } /// /// Get or set Organization Country /// public string DealerVanOrganizationOrganizationCountry { get; set; } /// /// Get or set Organization Description /// public string DealerVanOrganizationOrganizationDescription { get; set; } /// /// Get or set Organization Path /// public string DealerVanOrganizationOrganizationPath { get; set; } /// /// Get or set Organization Depth /// public string DealerVanOrganizationOrganizationDepth { get; set; } /// /// Get or set Organization Color /// public string DealerVanOrganizationOrganizationColor { get; set; } /// /// Get or set Organization Region /// public string DealerVanOrganizationOrganizationRegion { get; set; } /// /// Get or set Service Engineer Id /// public string ServiceEngineerId { get; set; } /// /// Get or set Service Engineer Name /// public string ServiceEngineerName { get; set; } /// /// Get or set Service Engineer Alias /// public string ServiceEngineerAlias { get; set; } /// /// Get or set Service Engineer Imei Number /// public string ServiceEngineerImeiNumber { get; set; } /// /// Get or set Service Engineer Contact Number /// public string ServiceEngineerContactNumber { get; set; } /// /// Get or set Service Engineer Application License Key /// public string ServiceEngineerApplicationLicenseKey { get; set; } /// /// Get or set Service Engineer Mobile Application Blocked /// public Boolean? ServiceEngineerMobileApplicationBlocked { get; set; } /// /// Get or set Service Engineer Device Alias /// public Int64? ServiceEngineerDeviceAlias { get; set; } /// /// Get or set Service Engineer Pin Password /// public string ServiceEngineerPinPassword { get; set; } } /// /// This class contain customer ticket history properties /// public class CustomerTicketHistory { /// /// Get or set Status /// public string Status { get; set; } /// /// Get or set Message /// public string Message { get; set; } /// /// Get or set List of Open Ticket /// public List ListOpenTicket { get; set; } /// /// Get or set List of close Ticket /// public List ListCloseTicket { get; set; } } /// /// This class contain ticket status properties /// public class TicketStatus { /// /// Get or set id /// public Int64? Id { get; set; } /// /// Get or set alias /// public string Alias { get; set; } /// /// Get or set Sequence No /// public int? SequenceNo { get; set; } /// /// Get or set Status Name /// public string StatusName { get; set; } /// /// Get or set Status /// public string Status { get; set; } /// /// Get or set Token /// public string Token { get; set; } /// /// Get or set Message /// public String Message { get; set; } } /// /// contains properties for van-dealer list /// public class VanDealerListStateWise { /// /// Get or set user id /// public int? UserId { get; set; } /// /// Get or set state name /// public string StateName { get; set; } /// /// Get or set limit /// public string Limit { get; set; } /// /// Get or set dealer van id /// public string DealerSCode { get; set; } /// /// Get or set dealer van id /// public string DealerOrVanContactNo { get; set; } /// /// Get or set dealer van id /// public string DealerVanId { get; set; } /// /// Get or set dealer van name /// public string DealerVanName { get; set; } /// /// Get or set dealer van latitude /// public string DealerVanLattitude { get; set; } /// /// Get or set dealer van longitude /// public string DealerVanLongitude { get; set; } /// /// Get or set dealer van city /// public string DealerVanCity { get; set; } /// /// Get or set dealer van state /// public string DealerVanState { get; set; } /// /// Get or set device alias /// public string DeviceAlias { get; set; } /// /// Get or set no. of assigned ticket /// public Int64? NoOfAssignedTicket { get; set; } /// /// Get or set remaining time /// public string RemainingTime { get; set; } /// /// Get or set type /// public string Type { get; set; } /// /// Get or set device status /// public string DeviceStatus { get; set; } /// /// Get or set security token /// public string Token { get; set; } /// /// Get or set status /// public string Status { get; set; } /// /// Get or set message /// public string Message { get; set; } /// /// Get or set message /// public string Fuel_type { get; set; } /// /// Get or set UTC minute /// public int UtcMinute { get; set; } public bool islocationChange { get; set; } } public class SVCDetails { /// /// Get or set KAM ticket id /// public string CustomerName { get; set; } public string CustomerNumber { get; set; } public string Address { get; set; } public string isoem { get; set; } public string oemName { get; set; } public string CreatedBy { get; set; } public string creation_time { get; set; } public string Quantity { get; set; } } public class AccidentalDetails { /// /// Get or set KAM ticket id /// public string CustomerName { get; set; } public string CustomerNumber { get; set; } public string Location { get; set; } public string isabulancesupportrequired { get; set; } public string isdealersupportrequired { get; set; } public string Dealer_Connect { get; set; } public string CreatedBy { get; set; } public string creation_time { get; set; } public string Registration_number { get; set; } } public class EPSSalesDetails { /// /// Get or set KAM ticket id /// public string CustomerName { get; set; } public string CustomerNumber { get; set; } public string Location { get; set; } public string ProductType { get; set; } public string Qunatity { get; set; } public string CreatedBy { get; set; } public string creation_time { get; set; } } /// /// Get or set ticket id /// /// } /// /// contains properties for open ticket /// /// public class InsertOpenTicket { /// /// Get or set KAM ticket id /// public string KamTicketId { get; set; } /// /// Get or set ticket id /// public string TicketId { get; set; } /// /// Get or set description /// public string Description { get; set; } /// /// Get or set assigned to /// public string AssignedTo { get; set; } /// /// Get or set reported via /// public string ReportedVia { get; set; } /// /// Get or set ticket status /// public int? TicketStatus { get; set; } /// /// Get or set priority /// public int? Priority { get; set; } /// /// Get or set customer score /// public string CustomerScore { get; set; } /// /// Get or set created by /// public string CreatedBy { get; set; } /// /// Get or set creation time /// public DateTime? CreationTime { get; set; } /// /// Get or set last modified by /// public string LastModifiedBy { get; set; } /// /// Get or set last modified time /// public DateTime? LastModifiedTime { get; set; } /// /// Get or set breakdown location /// public string BreakdownLocation { get; set; } /// /// Get or set breakdown longitude /// public string BreakdownLongitude { get; set; } /// /// Get or set breakdown latitude /// public string BreakdownLattitude { get; set; } /// /// Get or set assigned to user id /// public string AssignedToUserId { get; set; } /// /// Get or set assigned to user latitude /// public string AssignedToUserLattitude { get; set; } /// /// Get or set assigned to user longitude /// public string AssignedToUserLongitude { get; set; } /// /// Get or set IsDeclined /// public Boolean? IsDeclined { get; set; } /// /// Get or set estimated time for job completion /// public int? EstimatedTimeForJobCompletion { get; set; } /// /// Get or set ticket life cycle time /// public int? TotalTicketLifecycleTimeSla { get; set; } /// /// Get or set estimated time for job completion /// public DateTime? EstimatedTimeForJobCompletionSubmitTime { get; set; } /// /// Get or set vehicle registration number /// //[RegularExpression(@"[a-zA-Z][a-zA-Z]\d\d[a-zA-Z]{1,2}\d\d\d\d", ErrorMessage = "Entered Registration Number format is not valid.")] public string VehicleRegistrationNumber { get; set; } /// /// Get or set breakdown landmark /// public string BreakdownLocationLandmark { get; set; } /// /// Get or set route id /// public int? RouteId { get; set; } /// /// Get or set customer contact number /// //[Required(ErrorMessage = "*")] [RegularExpression(@"^\(?([0-9]{3})\)?[-. ]?([0-9]{3})[-. ]?([0-9]{4})$", ErrorMessage = "Entered phone format is not valid.")] public string CustomerContactNo { get; set; } /// /// Get or set repair cost /// public string RepairCost { get; set; } /// /// Get or set default sla time /// public int? DefaultSlaTime { get; set; } /// /// Get or set sla missed reason /// public string SlaMissedReason { get; set; } /// /// Get or set suggestion comment /// public string SuggestionComment { get; set; } /// /// Get or set job complete response time /// public string JobCompleteResponseTime { get; set; } /// /// Get or set extra property /// public string DefaultCol2 { get; set; } /// /// Get or set extra property /// public string DefaultCol3 { get; set; } /// /// Get or set security token /// public string Token { get; set; } /// /// Get or set status /// public string Status { get; set; } /// /// Get or set message /// public string Message { get; set; } /// /// Get or set UTC minute /// public int UtcMinute { get; set; } /// /// Get or set sender id /// public string SenderId { get; set; } /// /// Get or set state name /// public string StateName { get; set; } /// /// Get or set city name /// public string CityName { get; set; } /// /// Get or set caller language /// public string CallerLanguage { get; set; } /// /// Get or set warrenty /// public string Warranty { get; set; } /// /// Get or set toll free number source /// public string TollFreeeNoSource { get; set; } /// /// Get or set opportunity lost /// public string OpportunityLost { get; set; } /// /// Get or set 24 hrs reason /// public string _24HrsReason { get; set; } /// /// Get or set Vehicle Tagging like(LMD,BUS,HD) /// public string VehicleTagging { get; set; } /// /// Get or set distance between brackdown loction and service engg. /// public string EstimateDistance { get; set; } /// /// Get or set km covered /// public double KmCovered { get; set; } /// /// Get or set km Ticket Id Alias /// public string TicketIdAlias { get; set; } public string OtherRemarks { get; set; } public string Flag { get; set; } public string TicketPrevStatusAliasId { get; set; } public string ChassisNo { get; set; } public double OdometerReading { get; set; } public double PreviousOdometerReading { get; set; } public string VehicleType { get; set; } public string OdometerUnit { get; set; } public string EOSMessage { get; set; } //added on 13-07-2020 /// /// Get or set IsKamUser /// public bool IsKamUser { get; set; } ///// ///// Get or set Comments ///// public string Comments { get; set; } /// /// Get or set reported via /// public string TollFreeNoSource { get; set; } /// /// Get or set customer contact number /// [Required(ErrorMessage = "*")] [RegularExpression(@"^\(?([0-9]{3})\)?[-. ]?([0-9]{3})[-. ]?([0-9]{4})$", ErrorMessage = "Entered phone format is not valid.")] public string DriverContactNo { get; set; } public string DriverName { get; set; } public string VanLatitude { get; set; } public string VanLongitude { get; set; } //added on 26/11/2020 public string vehicle_warranty { get; set; } public string vehicle_amc { get; set; } public string vehicle_emission_norms { get; set; } public string vehicle_sales_date { get; set; } //ended on 26/11/2020 public string TicketClosedReason { get; set; } //added on 25-11-2020 //added on 2/1/2021 public string KamChampId { get; set; } public string KamChampName { get; set; } public string KamChampTel { get; set; } public string KamChampEmail { get; set; } public string KamRegHId { get; set; } public string KamRegHName { get; set; } public string KamRegHTel { get; set; } public string KamRegHEmail { get; set; } public string KamNatHId { get; set; } public string KamNatHName { get; set; } public string KamNatHTel { get; set; } public string KamNatHEmail { get; set; } public DateTime positionDateTime { get; set; }//added on 23/06/2021 Telematic insert //added on 13-07-2020 /// /// Get or set IsKamUser /// public Boolean? IsMobileRequest { get; set; } public string estimatedVAnReachTime { get; set; } /// /// Get or set KAM ticket id /// public string preclosure_reason { get; set; } /// /// Get or set KAM ticket id /// public string TicketStatusAlias { get; set; } public string TicketStatusPrevious { get; set; } public string DBMData { get; set; } public string sendMessage { get; set; } //added by mayuri khandelwal on 28 July 2025 public bool IsEPS { get; set; } public string EPS_prod_type { get; set; } } //---------------added on 23-12-2020(start)----------------------------- public class VanReachedTimeModel { public string Token { get; set; } //public string VanReachedTime { get; set; } public DateTime? VanReachedTime { get; set; } public string TicketIdAlias { get; set; } public string Status { get; set; } public string Message { get; set; } } //---------------added on 23-12-2020 (end)---------------------------------- /// /// This class contain ticket full details properties. /// public class CustomerOpenTicketFullDetailsTicketWise { private string _SuggestionComment = ""; /// /// Get or set id /// public string Id { get; set; } /// /// Get or set ticket id /// public string KamTicketId { get; set; } /// /// Get or set ticket id /// public string TicketId { get; set; } /// /// Get or set ticket id alias /// public string TicketIdAlias { get; set; } /// /// Get or set description /// public string Description { get; set; } /// /// Get or set assigned to /// public string AssignedTo { get; set; } /// /// Get or set reported via /// public string ReportedVia { get; set; } /// /// Get or set ticket status /// public int? TicketStatus { get; set; } /// /// Get or set priority /// public int? Priority { get; set; } /// /// Get or set customer source /// public string CustomerScore { get; set; } /// /// Get or set craeted by /// public string CreatedBy { get; set; } /// /// Get or set creation time /// public string CreationTime { get; set; } /// /// Get or set last modified by /// public string LastModifiedBy { get; set; } /// /// Get or set last modified time /// public string LastModifiedTime { get; set; } /// /// Get or set Breakdown Location /// public string BreakdownLocation { get; set; } /// /// Get or set Breakdown longitude /// public string BreakdownLongitude { get; set; } /// /// Get or set Breakdown latitide /// public string BreakdownLattitude { get; set; } /// /// Get or set assigned to user id /// public string AssignedToUserId { get; set; } /// /// Get or set assigned to user latutude /// public string AssignedToUserLattitude { get; set; } /// /// Get or set assigned to user longitude /// public string AssignedToUserLongitude { get; set; } /// /// Get or set IsDeclined /// public Boolean? Isdeclined { get; set; } /// /// Get or set estimated time for job completion /// public int? EstimatedTimeForJobCompletion { get; set; } /// /// Get or set ticket life cycle time /// public int? TotalTicketLifecycleTimeSla { get; set; } /// /// Get or set estimated time for job completion submit time /// public string EstimatedTimeForJobCompletionSubmitTime { get; set; } /// /// Get or set vehicle registration number /// public string VehicleRegisterNumber { get; set; } /// /// Get or set Breakdown landmark /// public string BreakdownLocationLandmark { get; set; } /// /// Get or set Breakdown state /// public string BreakdownLocationState { get; set; } /// /// Get or set Breakdown city /// public string BreakdownLocationCity { get; set; } /// /// Get or set route id /// public int? RouteId { get; set; } /// /// Get or set customer conatct number /// public string CustomerContactNo { get; set; } /// /// Get or set user id /// public long? UsersId { get; set; } /// /// Get or set user auth engine id /// public string UsersAuthEngineId { get; set; } /// /// Get or set user name /// public string UsersUserName { get; set; } /// /// Get or set user designation /// public string UsersDesignation { get; set; } /// /// Get or set user object id /// public string UsersObjectId { get; set; } /// /// Get or set user city /// public string UsersCity { get; set; } /// /// Get or set user state /// public string UsersState { get; set; } /// /// Get or set user region /// public string UsersRegion { get; set; } /// /// Get or set user language /// public string UsersLanguage { get; set; } /// /// Get or set timezone info display name /// public string TimezoneInfoDisplayName { get; set; } /// /// Get or set user organization name /// public string UserOrganizationName { get; set; } /// /// Get or set user organization alias /// public string UserOrganizationAlias { get; set; } /// /// Get or set user organization city /// public string UserOrganizationCity { get; set; } /// /// Get or set user organization state /// public string UserOrganizationState { get; set; } /// /// Get or set user organization country /// public string UserOrganizationCountry { get; set; } /// /// Get or set user organization region /// public string UserOrganizationRegion { get; set; } /// /// Get or set dealer/van id /// public string DealerOrVanId { get; set; } /// /// Get or set dealer/van name /// public string DealerOrVanName { get; set; } /// /// Get or set dealer/van latitude /// public string DealerOrVanDefaultLattitude { get; set; } /// /// Get or set dealer/van longitude /// public string DealerOrVanDefaultLongitude { get; set; } /// /// Get or set dealer/van city /// public string DealerOrVanCity { get; set; } /// /// Get or set dealer/van state /// public string DealerOrVanState { get; set; } /// /// Get or set ticket status alias /// public string TicketStatusAlias { get; set; } /// /// Get or set repair cost /// public string RepairCost { get; set; } /// /// Get or set default sla time /// public int? DefaultSlaTime { get; set; } /// /// Get or set sla missed reason /// public string SlaMissedReason { get; set; } /// /// Get or set suggestion comment /// public string SuggestionComment { get { if (!string.IsNullOrEmpty(_SuggestionComment)) { _SuggestionComment = _SuggestionComment.Replace("/", ""); _SuggestionComment = _SuggestionComment.Replace(@"\", ""); } return _SuggestionComment; } set { _SuggestionComment = value; } } public string TicketClosedReason { get; set; } //added on 25-11-2020 /// /// Get or set job complete response time /// public string JobCompleteResponseTime { get; set; } /// /// Get or set extra property /// public string DefaultCol2 { get; set; } /// /// Get or set extra property /// public string DefaultCol3 { get; set; } /// /// Get or set security token /// public string Token { get; set; } /// /// Get or set status /// public string Status { get; set; } /// /// Get or set message /// public string Message { get; set; } /// /// Get or set UTC minute /// public int UtcMinute { get; set; } /// /// Get or set openClose ticket status /// public string OpenCloseStatus { get; set; } /// /// Get or set dealer/service engineer contact number /// public string DealerOrServiceEnggContactNumber { get; set; } /// /// Get or set opoortunity lost reason /// public string OpportunityLossReason { get; set; } /// /// Get or set estimated distance /// public string EstimatedDistance { get; set; } /// /// Get or set dealer name /// public string Dealerdealer_name { get; set; } /// /// Get or set dealer contact number /// public string DealerContactNumber1 { get; set; } /// /// Get or set dealer city /// public string DealerCity { get; set; } /// /// Get or set dealer state /// public string DealerState { get; set; } /// /// Get or set chasis number /// public string ChassisNo { get; set; } /// /// Get or set KMs covered /// public double? KmCovered { get; set; } /// /// Get or set actual distance /// public string ActualDistance { get; set; } /// /// Get or set WM name /// public string WM_Name { get; set; } /// /// Get or set dealer id /// public string Dealer_Id { get; set; } /// /// Get or set vehicle tagging /// public string Vehicle_tagging { get; set; } /// /// Get or set van device alias /// public string Device_Alias { get; set; } /// /// Get or set van Caller Language /// public string CallerLanguage { get; set; } /// /// Get or set van warrenty /// public string Warrenty { get; set; } /// /// Get or set van Toll Free No Source /// public string TollFreeNoSource { get; set; } /// /// Get or set Reason For More Than 24 Hrs /// public string ReasonForMoreThan24Hrs { get; set; } /// /// Get or set Call Status /// public string CallStatus { get; set; } /// /// Get or set Suggestion Complaint /// public string SuggestionComplaint { get; set; } /// /// Get or set Driver Name /// public string CustomerCustomerName { get; set; } public string TripStart { get; set; } public string TripEnd { get; set; } public double? VanKmCovered { get; set; } public string RemarkTicketNotClosed24Hours { get; set; } public string current_lat { get; set; } public string current_long { get; set; } public string ChassisNumber { get; set; } public double OdoMeter { get; set; } public double PreviousOdometerReading { get; set; } public string VehicleType { get; set; } //added on 06-05-2020 public string FeedbackCallStatus { get; set; } //added on 27/11/2020 public string vehicle_warranty { get; set; } public string vehicle_amc { get; set; } public string vehicle_emission_norms { get; set; } public string vehicle_sales_date { get; set; } public string customer_type { get; set; } //ended on 27/11/2020 //Mobile OTP CR public string OTP { get; set; } //Mobile OTP CR public string van_reached_punched_time { get; set; } //added on 23-12-2020 } /// /// contains properties for customer open tickets /// public class CustomerOpenTicketDetail { /// /// Get or set ticket id /// public string TicketId { get; set; } /// /// Get or set ticket id alias /// public string TicketIdAlias { get; set; } /// /// Get or set description /// public string Description { get; set; } /// /// Get or set assigned to /// public string AssignedTo { get; set; } /// /// Get or set reported via /// public string ReportedVia { get; set; } /// /// Get or set ticket status /// public int? TicketStatus { get; set; } /// /// Get or set priority /// public int? Priority { get; set; } /// /// Get or set customer score /// public string CustomerScore { get; set; } /// /// Get or set created by /// public string CreatedBy { get; set; } /// /// Get or set creation time /// public string CreationTime { get; set; } /// /// Get or set last modified by /// public string LastModifiedBy { get; set; } /// /// Get or set last modified time /// public string LastModifiedTime { get; set; } /// /// Get or set breakdown location /// public string BreakdownLocation { get; set; } /// /// Get or set breakdown longitude /// public string BreakdownLongitude { get; set; } /// /// Get or set breakdown latitude /// public string BreakdownLattitude { get; set; } /// /// Get or set assigned to user id /// public string AssignedToUserId { get; set; } /// /// Get or set assigned to user latitude /// public string AssignedToUserLattitude { get; set; } /// /// Get or set assigned to user longitude /// public string AssignedToUserLongitude { get; set; } /// /// Get or set IsDeclined bit /// public Boolean? Isdeclined { get; set; } /// /// Get or set estimated time for job completion /// public int? EstimatedTimeForJobCompletion { get; set; } /// /// Get or set ticket life cycle time /// public int? TotalTicketLifecycleTimeSla { get; set; } /// /// Get or set estimated time for job completion submit time /// public string EstimatedTimeForJobCompletionSubmitTime { get; set; } /// /// Get or set vehicle registration number /// public string VehicleRegisterNumber { get; set; } /// /// Get or set breakdown landmark /// public string BreakdownLocationLandmark { get; set; } /// /// Get or set Breakdown state /// public string BreakdownLocationState { get; set; } /// /// Get or set Breakdown city /// public string BreakdownLocationCity { get; set; } /// /// Get or set route id /// public int? RouteId { get; set; } /// /// Get or set customer contact number /// public string CustomerContactNo { get; set; } /// /// Get or set ticket status alias /// public string TicketStatusAlias { get; set; } /// /// Get or set repair cost /// public string RepairCost { get; set; } /// /// Get or set defalut sla time /// public int? DefaultSlaTime { get; set; } /// /// Get or set sla missed reason /// public string SlaMissedReason { get; set; } /// /// Get or set suggestion comment /// public string SuggestionComment { get; set; } /// /// Get or set job complete response time /// public string JobCompleteResponseTime { get; set; } /// /// Get or set extra property /// public string DefaultCol2 { get; set; } /// /// Get or set extra property /// public string DefaultCol3 { get; set; } /// /// Get or set security token /// public string Token { get; set; } /// /// Get or set status /// public string Status { get; set; } /// /// Get or set message /// public string Message { get; set; } /// /// Get or set UTC minute /// public int UtcMinute { get; set; } public string Engine_number { get; set; } public bool isEPS { get; set; } public string van_reached_punch_time { get; set; } //added on 23-12-2020 } /// /// contains properties for Customer Close tickets /// public class CustomerCloseTicketDetail { /// /// Get or set ticket id /// public string TicketId { get; set; } /// /// Get or set ticket id alias /// public string TicketIdAlias { get; set; } /// /// Get or set description /// public string Description { get; set; } /// /// Get or set assinged to /// public string AssignedTo { get; set; } /// /// Get or set reported via /// public string ReportedVia { get; set; } /// /// Get or set ticket status /// public int? TicketStatus { get; set; } /// /// Get or set priority /// public int? Priority { get; set; } /// /// Get or set customer score /// public string CustomerScore { get; set; } /// /// Get or set created by /// public string CreatedBy { get; set; } /// /// Get or set creation time /// public string CreationTime { get; set; } /// /// Get or set last modified by /// public string LastModifiedBy { get; set; } /// /// Get or set last modified time /// public string LastModifiedTime { get; set; } /// /// Get or set breakdown location /// public string BreakdownLocation { get; set; } /// /// Get or set breakdown longitude /// public string BreakdownLongitude { get; set; } /// /// Get or set breakdown latitude /// public string BreakdownLattitude { get; set; } /// /// Get or set assigned to user id /// public string AssignedToUserId { get; set; } /// /// Get or set assigned to user latitude /// public string AssignedToUserLattitude { get; set; } /// /// Get or set assigned to longitude /// public string AssignedToUserLongitude { get; set; } /// /// Get or set IsDeclined bit /// public Boolean? Isdeclined { get; set; } /// /// Get or set estimated time for job completion /// public int? EstimatedTimeForJobCompletion { get; set; } /// /// Get or set ticket life cycle time /// public int? TotalTicketLifecycleTimeSla { get; set; } /// /// Get or set estimated time for job compeltion submit time /// public string EstimatedTimeForJobCompletionSubmitTime { get; set; } /// /// Get or set vehicle registration number /// public string VehicleRegisterNumber { get; set; } /// /// Get or set breakdown landmark /// public string BreakdownLocationLandmark { get; set; } /// /// Get or set route id /// public int? RouteId { get; set; } /// /// Get or set customer contact number /// public string CustomerContactNo { get; set; } /// /// Get or set ticket status alias /// public string TicketStatusAlias { get; set; } /// /// Get or set repair cost /// public string RepairCost { get; set; } /// /// Get or set default sla time /// public int? DefaultSlaTime { get; set; } /// /// Get or set sla missed rason /// public string SlaMissedReason { get; set; } /// /// Get or set suggestion /// public string SuggestionComment { get; set; } /// /// Get or set job completed response time /// public string JobCompleteResponseTime { get; set; } /// /// Get or set extra property /// public string DefaultCol2 { get; set; } /// /// Get or set extra property /// public string DefaultCol3 { get; set; } /// /// Get or set security token /// public string Token { get; set; } /// /// Get or set status /// public string Status { get; set; } /// /// Get or set message /// public string Message { get; set; } /// /// Get or set UTC minute /// public int UtcMinute { get; set; } /// /// Get or set total ticket closed hours /// public double? TotalTicketCloseHours { get; set; } /// /// Get or set feedback agent name /// public string FeedBackAgenName { get; set; } /// /// Get or set call status /// public string CallStatus { get; set; } /// /// Get or set reason > 24 hrs /// public string ReasonBeyond24Hrs { get; set; } public string van_reached_punch_time { get; set; } //added on 23-12-2020 public bool isEPS { get; set; } public string Engine_Number { get; set; } } /// /// contains properties for ticket notifications /// public class TicketNotificationModel { /// /// Get or set id /// public string Id { get; set; } /// /// Get or set keyname /// public string KeyName { get; set; } /// /// Get or set key value /// public int? KeyValue { get; set; } /// /// Get or set ticket status /// public int? TicketStatus { get; set; } /// /// Get or set security token /// public string Token { get; set; } /// /// Get or set message /// public string Message { get; set; } } /// /// contains for open + close ticket notification /// public class CloseOpenNotification { /// /// Get or set ticket status /// public int? TicketStatus { get; set; } /// /// Get or set ticket id /// public string TicketId { get; set; } /// /// Get or set security token /// public string Token { get; set; } /// /// Get or set status /// public string Status { get; set; } /// /// Get or set mesage /// public string Message { get; set; } /// /// Get or set notification id /// public Int64? NotificationId { get; set; } } /// /// contains properties for ticket notifications /// public class TicketNotificationsWithTicketId { /// /// Get or set ticket id /// public string TicketId { get; set; } /// /// Get or set ticket id alias /// public string TicketIdAlias { get; set; } /// /// Get or set ticket status /// public int? TicketStatus { get; set; } /// /// Get or set ticket status alias /// public string TickeStatusAlias { get; set; } /// /// Get or set notification time /// public string NotificationTime { get; set; } /// /// Get or set dealer name /// public string DealerDealerName { get; set; } /// /// Get or set van id /// public string VanId { get; set; } /// /// Get or set van registration number /// public string VanRegistrationNumber { get; set; } /// /// Get or set service engineer name /// public string ServiceEngineerName { get; set; } /// /// Get or set creation time /// public string CreationTime { get; set; } /// /// Get or set created by /// public string CreatedBy { get; set; } /// /// Get or set UTC minute /// public int UtcMinute { get; set; } /// /// Get or set security token /// public string Token { get; set; } /// /// Get or set message /// public string Message { get; set; } /// /// Get or set user id /// public int? UserId { get; set; } /// /// Get or set notification id /// public Int64? NotificationId { get; set; } } /// /// THis class contain ticket request properties /// public class TicketRequestModel { /// /// Get or set Ticket Type /// public string TicketType { get; set; } /// /// Get or set KAM Ticket Id /// public int KamTicketId { get; set; } /// /// Get or set Token /// public string Token { get; set; } /// /// Get or set Status /// public string Status { get; set; } /// /// Get or set Message /// public string Message { get; set; } /// /// Get or set User Id /// public int? UserId { get; set; } /// /// Get or set User Id /// public string KamUserId { get; set; } /// /// Get or set From Date /// public DateTime FromDate { get; set; } /// /// Get or set To Date /// public DateTime ToDate { get; set; } /// /// Get or set Limit /// public int? Limit { get; set; } /// /// Get or set OffSet /// public int? OffSet { get; set; } /// /// Get or set Ticket List /// public List TicketList { get; set; } /// /// Get or set Ticket List /// public List DummyTicketList { get; set; } /// /// Get or set /// public List ConsolidatedReportModelList { get; set; } /// /// Get or set /// public Int64? TicketCount { get; set; } /// /// Get or set /// public string Condition { get; set; } /// /// Get or set /// public int? UtcMinute { get; set; } /// /// get or set vehicle type /// public string VehicleType { get; set; } /// /// get or set organization /// public string Organization { get; set; } /// /// Get or set Ticket Type /// public string StartDate { get; set; } /// /// Get or set Ticket Type /// public string EndDate { get; set; } public string consolidaetype { get; set; } } /// /// contains property for consolidated report /// public class ConsolidatedReportModel { /// /// Get or set ticket id /// public string ticket_id { get; set; } /// /// Get or set customer name /// public string customer_name { get; set; } /// /// Get or set customer contact number /// public string customer_contact_no { get; set; } /// /// Get or set customer vehicle regitration number /// public string customer_vehicle_regn_no { get; set; } /// /// Get or set vehicle type /// public string vehicle_type { get; set; } /// /// Get or set chasis number /// public string chassis_number { get; set; } /// /// Get or set vehicle installation date /// public string vehicle_instalation_date { get; set; } /// /// Get or set breakdown location /// public string breakdown_location { get; set; } /// /// Get or set dwaler code /// public string dealer_code { get; set; } /// /// Get or set dealer name /// public string dealer_name { get; set; } /// /// Get or set dealer contact number /// public string dealer_contact_no { get; set; } /// /// Get or set created by /// public string created_by { get; set; } /// /// Get or set creation time /// public string creation_time { get; set; } /// /// Get or set city /// public string city { get; set; } /// /// Get or set state /// public string state { get; set; } /// /// Get or set language name /// public string language_name { get; set; } /// /// Get or set open call hrs /// public string open_call_hrs { get; set; } /// /// Get or set landmark /// public string landmark { get; set; } /// /// Get or set warrenty /// public string warranty { get; set; } /// /// Get or set vehicle model /// public string vehicle_model { get; set; } /// /// Get or set load carried /// public string load_carried { get; set; } /// /// Get or set type of load carried /// public string type_of_load_carried { get; set; } /// /// Get or set call assigned to /// public string call_assigned_to { get; set; } /// /// Get or set owner name /// public string owner_name { get; set; } /// /// Get or set owner conatct number /// public string owner_contact_number { get; set; } /// /// Get or set nature of problem /// public string nature_of_problem { get; set; } /// /// Get or set estimated cost /// public string estimated_cost { get; set; } /// /// Get or set estimated time /// public string estimated_time { get; set; } /// /// Get or set feedback taken /// public string feedback_taken { get; set; } /// /// Get or set call closure status /// public string call_closure_status { get; set; } /// /// Get or set feedback Qs no 1 /// public string how_did_you_come_to_know_of_eos { get; set; } /// /// Get or set feedback Qs no 2 /// public string feedback_parameter_wise_score { get; set; } /// /// Get or set feedback Qs no 3 /// public string feedback_ease_of_getting_call { get; set; } /// /// Get or set feedback Qs no 4 /// public string feedback_response_of_call_center { get; set; } /// /// Get or set feedback Qs no 5 /// public string feedback_timely_updation_by_dealer { get; set; } /// /// Get or set feedback total repair time /// public string feedback_total_repair_time { get; set; } /// /// Get or set feedback eos charges /// public string feedback_eos_charges { get; set; } /// /// Get or set feedback overall experience /// public string feedback_over_all_experience { get; set; } /// /// Get or set other remarks /// public string other_remarks { get; set; } /// /// Get or set feedback agent /// public string feedback_agent { get; set; } /// /// Get or set total inbound calls /// public string total_inbound_calls { get; set; } /// /// Get or set total outbound calls /// public string total_outbound_calls { get; set; } /// /// Get or set time stamp status 1 /// public string time_stamps_status_1 { get; set; } /// /// Get or set time stamp status 2 /// public string time_stamps_status_2 { get; set; } /// /// Get or set time stamp status 3 /// public string time_stamps_status_3 { get; set; } /// /// Get or set time stamp status 4 /// public string time_stamps_status_4 { get; set; } /// /// Get or set time stamp status 5 /// public string time_stamps_status_5 { get; set; } /// /// Get or set escalation level van not move 1 /// public string escalation_level_van_not_move_1 { get; set; } /// /// Get or set escalation level van not move 2 /// public string escalation_level_van_not_move_2 { get; set; } /// /// Get or set escalation level van not move 3 /// public string escalation_level_van_not_move_3 { get; set; } /// /// Get or set escalation level van not move 4 /// public string escalation_level_van_not_move_4 { get; set; } /// /// Get or set escalation level van not move 5 /// public string escalation_level_van_not_move_5 { get; set; } /// /// Get or set escalation level van not move 6 /// public string escalation_level_van_not_move_6 { get; set; } /// /// Get or set escalation level van not move 7 /// public string escalation_level_van_not_move_7 { get; set; } /// /// Get or set escalation level van not move 8 /// public string escalation_level_van_not_move_8 { get; set; } /// /// Get or set escalation level van not move 9 /// public string escalation_level_van_not_move_9 { get; set; } /// /// Get or set escalation level van not move 10 /// public string escalation_level_van_not_move_10 { get; set; } /// /// Get or set escalation level ticket closure 1 /// public string escalation_level_ticket_closer_1 { get; set; } /// /// Get or set escalation level ticket closure 2 /// public string escalation_level_ticket_closer_2 { get; set; } /// /// Get or set escalation level ticket closure 3 /// public string escalation_level_ticket_closer_3 { get; set; } /// /// Get or set escalation level ticket closure 4 /// public string escalation_level_ticket_closer_4 { get; set; } /// /// Get or set escalation level ticket closure 5 /// public string escalation_level_ticket_closer_5 { get; set; } /// /// Get or set escalation level ticket closure 6 /// public string escalation_level_ticket_closer_6 { get; set; } /// /// Get or set escalation level ticket closure 7 /// public string escalation_level_ticket_closer_7 { get; set; } /// /// Get or set escalation level ticket closure 8 /// public string escalation_level_ticket_closer_8 { get; set; } /// /// Get or set escalation level ticket closure 9 /// public string escalation_level_ticket_closer_9 { get; set; } /// /// Get or set escalation level ticket closure 10 /// public string escalation_level_ticket_closer_10 { get; set; } /// /// Get or set month name /// public string month_name { get; set; } /// /// Get or set default sla time /// public string default_sla_time { get; set; } /// /// Get or set response /// public string response { get; set; } /// /// Get or set eos team member and van /// public string eos_team_member_and_van { get; set; } /// /// Get or set tme slot /// public string time_slot { get; set; } /// /// Get or set region /// public string region { get; set; } /// /// Get or set closure remarks /// public string closure_remarks { get; set; } /// /// Get or set vehicle name /// public string vehicle_name { get; set; } /// /// Get or set organiation /// public string organization { get; set; } /// /// get or set call status /// public string call_status { get; set; } /// /// get or set complaints /// public string complaints { get; set; } /// /// get or set suggestions /// public string suggestion { get; set; } /// /// get or set feedback count /// public string feedback_count { get; set; } /// /// get or set ticket Id alias /// public string ticketid_alias { get; set; } /// /// get or set wm name /// public string wm_name { get; set; } /// /// get or set wm name /// public string DealerTicketOtherRemark { get; set; } public string KmCovered { get; set; } public string estimated_distance { get; set; } public string van_covered_distance { get; set; } public string trip_start_time { get; set; } public string trip_end_time { get; set; } public string _call_closed_within_24_hours { get; set; } public string _eicher_promise { get; set; } public string opportunity_loss_remark { get; set; } public string opportunity_loss { get; set; } public string remark_ticket_not_closed_24_hours { get; set; } public int reopen_count { get; set; } public string remark_ticket_not_closed_24_hours_remarks { get; set; } public string opportunity_lost_remarks { get; set; } public string ChassisNo { get; set; } public double OdometerReading { get; set; } /// /// Get or set last updated time /// public string last_Updated_Time { get; set; } /// /// Get or set are_you_satisfied /// public string are_you_satisfied { get; set; } /// /// Get or set not_satisfied_option /// public string not_satisfied_option { get; set; } /// /// Get or set not_satisfied_reason /// public string not_satisfied_reason { get; set; } /// /// Get or set response_time_reassignment /// public double? response_time_reassignment { get; set; } //added on 03/12/2020 public string vehicle_warranty { get; set; } public string vehicle_amc { get; set; } public string vehicle_emission_norms { get; set; } public string vehicle_sales_date { get; set; } //ended on 03/12/2020 public string van_reached_punch_time { get; set; } //added on 23-12-2020 public string ticket_closed_reason { get; set; } //added on 25-11-2020 public string product_variant_name { get; set; } //added on 25-11-2020 } #region Offline Model /// /// This class is used for insert bulk ticket detail in database /// public class OfflineTicket { /// /// Get or set Token /// public string Token { get; set; } /// /// Get or set Message /// public string Message { get; set; } /// /// Get or set status /// public string Status { get; set; } /// /// Get or set Bulk Ticket Detail /// public List BulkTicketDetail { get; set; } /// /// get or set Bulk ticket string /// public String BulkTicketStr { get; set; } /// /// Get or set utc minute /// public int UtcMinute { get; set; } } #endregion /// /// contains properties ticket report details /// public class TicketReportModel { /// /// Get or set Token /// public String Token { get; set; } /// /// Get or set Status /// public string Status { get; set; } /// /// Get or set Message /// public string Message { get; set; } /// /// Get or set Id /// public string id { get; set; } /// /// Get or set Description /// public string _customer_customer_name { get; set; } /// /// Get or set Assigned To /// public int? total_ticket_lifecycle_time_sla { get; set; } /// /// Get or set Reported Via /// public string customer_contact_no { get; set; } /// /// Get or set Ticket Status /// public int? default_sla_time { get; set; } /// /// Get or set Priority /// public string assigned_to_user_id { get; set; } /// /// Get or set Cutomer Score /// public string vehicle_registration_number { get; set; } /// /// Get or set Created By /// public string ticket_status_alias { get; set; } /// /// Get or set Creation Time /// public string name { get; set; } /// /// Get or set Last Modified By /// public string dealer_name { get; set; } /// /// Get or set Last Modified Time /// public string dealer_contact_number1 { get; set; } /// /// Get or set Break Down Location /// public string customer_vehicle_model_tagging { get; set; } /// /// Get or set Breack Down Longitude /// public string BreackDownLongitude { get; set; } /// /// Get or set Breack Down Latitude /// public string BreackDownLatitude { get; set; } /// /// Get or set Assigned To User Id /// public string AssignedToUserId { get; set; } /// /// Get or set Assigned To User Longitude /// public string AssignedToUserLongitude { get; set; } /// /// Get or set Assigned To User Latitude /// public string AssignedToUserLatitude { get; set; } } /// /// contains Escalation level input properties /// public class EscalationLevelInputModel { /// /// get or set security token /// public string Token { get; set; } /// /// get or set message /// public string Message { get; set; } /// /// get or set deler id /// public string DelerId { get; set; } /// /// get or set vehicle type /// public string VehicleType { get; set; } /// /// get or set vehicle type /// public string ProductVariant { get; set; } public string ModelNumber { get; set; } } public class sendSMSInputModel { /// /// get or set security token /// public string Token { get; set; } /// /// get or set message /// public string Message { get; set; } /// /// get or set deler id /// public string DelerId { get; set; } /// /// get or set vehicle type /// public string MobileNumber { get; set; } /// /// get or set vehicle type /// public string DealerName { get; set; } public string ManagerName { get; set; } public string ManagerNo { get; set; } } /// /// contains escalation level properties /// public class EscalationLevel { /// /// get or set delaer id /// public string DelaerId { get; set; } /// /// get or set manager name /// public string ManagerName { get; set; } /// /// get or set manager level /// public string ManagerLevel { get; set; } /// /// get or set manager phone number /// public string ManagerPhoneNo { get; set; } /// /// get or set vehicle type /// public string VehicleType { get; set; } } /// /// contains Escalation level output properties and lists /// public class EscalationLevelOutputModel { /// /// get or set message /// public string Message { get; set; } /// /// get or set status /// public string Status { get; set; } /// /// get or set escalation levels list /// public List EscalationLevelList { get; set; } } /// /// contains properties for customer open tickets /// public class DummyOpenTicketDetail { public string _CreationTime = ""; public string _DurationTime = ""; /// /// Get or set extra property /// public Int32 DummyId { get; set; } /// /// Get or set ticket id /// public string TicketId { get; set; } /// /// Get or set ticket id alias /// public string TicketIdAlias { get; set; } /// /// Get or set description /// public string Description { get; set; } /// /// Get or set assigned to /// public string AssignedTo { get; set; } /// /// Get or set reported via /// public string ReportedVia { get; set; } /// /// Get or set ticket status /// public int? TicketStatus { get; set; } /// /// Get or set priority /// public int? Priority { get; set; } /// /// Get or set customer score /// public string CustomerScore { get; set; } /// /// Get or set created by /// public string CreatedBy { get; set; } /// /// Get or set creation time /// public string CreationTime { get { return _CreationTime; } set { _CreationTime = value; } } /// /// Get or set last modified by /// public string LastModifiedBy { get; set; } /// /// Get or set last modified time /// public string LastModifiedTime { get; set; } /// /// Get or set breakdown location /// public string BreakdownLocation { get; set; } /// /// Get or set breakdown longitude /// public string BreakdownLongitude { get; set; } /// /// Get or set breakdown latitude /// public string BreakdownLattitude { get; set; } /// /// Get or set assigned to user id /// public string AssignedToUserId { get; set; } /// /// Get or set assigned to user latitude /// public string AssignedToUserLattitude { get; set; } /// /// Get or set assigned to user longitude /// public string AssignedToUserLongitude { get; set; } /// /// Get or set IsDeclined bit /// public Boolean? Isdeclined { get; set; } /// /// Get or set estimated time for job completion /// public int? EstimatedTimeForJobCompletion { get; set; } /// /// Get or set ticket life cycle time /// public int? TotalTicketLifecycleTimeSla { get; set; } /// /// Get or set estimated time for job completion submit time /// public string EstimatedTimeForJobCompletionSubmitTime { get; set; } /// /// Get or set vehicle registration number /// public string VehicleRegisterNumber { get; set; } /// /// Get or set breakdown landmark /// public string BreakdownLocationLandmark { get; set; } /// /// Get or set Breakdown state /// public string BreakdownLocationState { get; set; } /// /// Get or set Breakdown city /// public string BreakdownLocationCity { get; set; } /// /// Get or set route id /// public int? RouteId { get; set; } /// /// Get or set customer contact number /// public string CustomerContactNo { get; set; } /// /// Get or set ticket status alias /// public string TicketStatusAlias { get; set; } /// /// Get or set repair cost /// public string RepairCost { get; set; } /// /// Get or set defalut sla time /// public int? DefaultSlaTime { get; set; } /// /// Get or set sla missed reason /// public string SlaMissedReason { get; set; } /// /// Get or set suggestion comment /// public string SuggestionComment { get; set; } /// /// Get or set job complete response time /// public string JobCompleteResponseTime { get; set; } /// /// Get or set extra property /// public string DefaultCol2 { get; set; } /// /// Get or set extra property /// public string DefaultCol3 { get; set; } /// /// Get or set extra property /// public string CallerLanguage { get; set; } /// /// Get or set extra property /// public string Warranty { get; set; } /// /// Get or set extra property /// public string TollFreeNoSource { get; set; } /// /// Get or set extra property /// public string StateName { get; set; } /// /// Get or set extra property /// public string CityName { get; set; } /// /// Get or set extra property /// public string EstimatedDistance { get; set; } /// /// Get or set extra property /// public string OpportunityLoss { get; set; } /// /// Get or set extra property /// public string KmCovered { get; set; } /// /// Get or set extra property /// public string VehicleTagging { get; set; } /// /// Get or set extra property /// public string ReasonForMoreThan24Hours { get; set; } /// /// Get or set extra property /// public string CallStatus { get; set; } /// /// Get or set extra property /// public string SuggestionComplaint { get; set; } /// /// Get or set extra property /// public string CustomerName { get; set; } /// /// Get or set security token /// public string Token { get; set; } /// /// Get or set status /// public string Status { get; set; } /// /// Get or set message /// public string Message { get; set; } /// /// Get or set UTC minute /// public int UtcMinute { get; set; } public string DurationTime { get { if (!string.IsNullOrEmpty(_CreationTime)) { DateTime durationDate; if (DateTime.TryParse(_CreationTime, out durationDate)) { TimeSpan difference = DateTime.Now - durationDate; _DurationTime = Math.Floor(difference.TotalHours).ToString("N0") + ":" + difference.Minutes; } } return _DurationTime; } } public string vehicle_model_number { get; set; } public string customer_id { get; set; } public string customer_address_id { get; set; } public string product_variant { get; set; } public string customer_mobile_number { get; set; } public string driver_mobile_number { get; set; } public string driver_name { get; set; } public string vehicle_installation_date { get; set; } public string iskam { get; set; } public string customer_address { get; set; } public string vehicle_emission_norms { get; set; } public string vehicle_warranty { get; set; } public string vehicle_type { get; set; } public string customer_type { get; set; } } public class AppModel { /// /// Get or set token /// public string Token { get; set; } /// /// Get or set Status /// public int? Status { get; set; } /// /// Get or set Utc Minute /// public int? UtcMinute { get; set; } /// /// Get or set Message /// public string Message { get; set; } public string AppCode { get; set; } public string AppVersion { get; set; } public string AppName { get; set; } public string ModifiedDate { get; set; } } /// /// CMS login model /// public class CustomerOpenTicketFullDetailTicketWise { public string AssignedTo { get; set; } public string BreakdownLocation { get; set; } public string ChassisNo { get; set; } public string CustomerContactNo { get; set; } public string CustomerCustomerName { get; set; } public string DealerCode { get; set; } public string DealerContactNumber1 { get; set; } public string DealerOrServiceEnggContactNumber { get; set; } public string Dealerdealer_name { get; set; } public string KmCovered { get; set; } public string ModelNumber { get; set; } public string OpenCloseStatus { get; set; } public string ProductVarient { get; set; } public string TicketIdAlias { get; set; } public string TripEnd { get; set; } public string TripStart { get; set; } public string VehicleRegisterNumber { get; set; } } // added on 18-06-2020 /// /// contains properties for open ticket /// /// public class GetDummyTicket { /// /// Get or set KAM ticket id /// public string KamTicketId { get; set; } /// /// Get or set ticket id /// public int DummyTicketId { get; set; } /// /// Get or set description /// public string Description { get; set; } /// /// Get or set assigned to /// public string AssignedTo { get; set; } /// /// Get or set reported via /// public string ReportedVia { get; set; } /// /// Get or set ticket status /// public int? TicketStatus { get; set; } /// /// Get or set priority /// public int? Priority { get; set; } /// /// Get or set customer score /// public string CustomerScore { get; set; } /// /// Get or set created by /// public string CreatedBy { get; set; } /// /// Get or set creation time /// //public DateTime? CreationTime { get; set; } public string CreationTime { get; set; } //added on 26-10-2020 /// /// Get or set last modified by /// public string LastModifiedBy { get; set; } /// /// Get or set last modified time /// public DateTime? LastModifiedTime { get; set; } /// /// Get or set breakdown location /// public string BreakdownLocation { get; set; } /// /// Get or set breakdown longitude /// public string BreakdownLongitude { get; set; } /// /// Get or set breakdown latitude /// public string BreakdownLattitude { get; set; } /// /// Get or set assigned to user id /// public string AssignedToUserId { get; set; } /// /// Get or set assigned to user latitude /// public string AssignedToUserLattitude { get; set; } /// /// Get or set assigned to user longitude /// public string AssignedToUserLongitude { get; set; } /// /// Get or set IsDeclined /// public Boolean? IsDeclined { get; set; } /// /// Get or set estimated time for job completion /// public int? EstimatedTimeForJobCompletion { get; set; } /// /// Get or set ticket life cycle time /// public int? TotalTicketLifecycleTimeSla { get; set; } /// /// Get or set estimated time for job completion /// public DateTime? EstimatedTimeForJobCompletionSubmitTime { get; set; } /// /// Get or set vehicle registration number /// public string VehicleRegistrationNumber { get; set; } /// /// Get or set breakdown landmark /// public string BreakdownLocationLandmark { get; set; } /// /// Get or set route id /// public int? RouteId { get; set; } /// /// Get or set customer contact number /// public string CustomerContactNo { get; set; } /// /// Get or set repair cost /// public string RepairCost { get; set; } /// /// Get or set default sla time /// public int? DefaultSlaTime { get; set; } /// /// Get or set sla missed reason /// public string SlaMissedReason { get; set; } /// /// Get or set suggestion comment /// public string SuggestionComment { get; set; } /// /// Get or set job complete response time /// public string JobCompleteResponseTime { get; set; } /// /// Get or set extra property /// public string DefaultCol2 { get; set; } /// /// Get or set extra property /// public string DefaultCol3 { get; set; } /// /// Get or set security token /// public string Token { get; set; } /// /// Get or set status /// public string Status { get; set; } /// /// Get or set message /// public string Message { get; set; } /// /// Get or set UTC minute /// public int UtcMinute { get; set; } /// /// Get or set sender id /// public string SenderId { get; set; } /// /// Get or set state name /// public string StateName { get; set; } /// /// Get or set city name /// public string CityName { get; set; } /// /// Get or set caller language /// public string CallerLanguage { get; set; } /// /// Get or set warrenty /// public string Warranty { get; set; } /// /// Get or set toll free number source /// public string TollFreeeNoSource { get; set; } /// /// Get or set opportunity lost /// public string OpportunityLost { get; set; } /// /// Get or set 24 hrs reason /// public string _24HrsReason { get; set; } /// /// Get or set Vehicle Tagging like(LMD,BUS,HD) /// public string VehicleTagging { get; set; } /// /// Get or set distance between brackdown loction and service engg. /// public string EstimateDistance { get; set; } /// /// Get or set km covered /// public double KmCovered { get; set; } /// /// Get or set km Ticket Id Alias /// public string TicketIdAlias { get; set; } public string OtherRemarks { get; set; } public string Flag { get; set; } public string TicketPrevStatusAliasId { get; set; } public string ChassisNo { get; set; } public double OdometerReading { get; set; } public double PreviousOdometerReading { get; set; } public string VehicleType { get; set; } public string OdometerUnit { get; set; } public string EOSMessage { get; set; } //added on 18-06-2020 /// /// Get or set Customer or Owner Name /// public string CustomerCustomerName { get; set; } /// /// Get or set ModelNumber /// public string ModelNumber { get; set; } /// /// Get or set Vehicle Number Plate /// public string VehicleNumberPlate { get; set; } public string Comments { get; set; } public bool? KamUser { get; set; } public string DriverName { get; set; } } public class InsertDraftTicket { /// /// Get or set KAM ticket id /// public string KamTicketId { get; set; } /// /// Get or set ticket id /// public string TicketId { get; set; } /// /// Get or set description /// public string Description { get; set; } /// /// Get or set assigned to /// public string AssignedTo { get; set; } /// /// Get or set reported via /// public string ReportedVia { get; set; } /// /// Get or set ticket status /// public int? TicketStatus { get; set; } /// /// Get or set priority /// public int? Priority { get; set; } /// /// Get or set customer score /// public string CustomerScore { get; set; } /// /// Get or set created by /// public string CreatedBy { get; set; } /// /// Get or set creation time /// public DateTime? CreationTime { get; set; } /// /// Get or set last modified by /// public string LastModifiedBy { get; set; } /// /// Get or set last modified time /// public DateTime? LastModifiedTime { get; set; } /// /// Get or set breakdown location /// public string BreakdownLocation { get; set; } /// /// Get or set breakdown longitude /// public string BreakdownLongitude { get; set; } /// /// Get or set breakdown latitude /// public string BreakdownLattitude { get; set; } /// /// Get or set assigned to user id /// public string AssignedToUserId { get; set; } /// /// Get or set assigned to user latitude /// public string AssignedToUserLattitude { get; set; } /// /// Get or set assigned to user longitude /// public string AssignedToUserLongitude { get; set; } /// /// Get or set IsDeclined /// public Boolean? IsDeclined { get; set; } /// /// Get or set estimated time for job completion /// public int? EstimatedTimeForJobCompletion { get; set; } /// /// Get or set ticket life cycle time /// public int? TotalTicketLifecycleTimeSla { get; set; } /// /// Get or set estimated time for job completion /// public DateTime? EstimatedTimeForJobCompletionSubmitTime { get; set; } /// /// Get or set vehicle registration number /// public string VehicleRegistrationNumber { get; set; } /// /// Get or set breakdown landmark /// public string BreakdownLocationLandmark { get; set; } /// /// Get or set route id /// public int? RouteId { get; set; } /// /// Get or set customer contact number /// public string CustomerContactNo { get; set; } /// /// Get or set repair cost /// public string RepairCost { get; set; } /// /// Get or set default sla time /// public int? DefaultSlaTime { get; set; } /// /// Get or set sla missed reason /// public string SlaMissedReason { get; set; } /// /// Get or set suggestion comment /// public string SuggestionComment { get; set; } /// /// Get or set job complete response time /// public string JobCompleteResponseTime { get; set; } /// /// Get or set extra property /// public string DefaultCol2 { get; set; } /// /// Get or set extra property /// public string DefaultCol3 { get; set; } /// /// Get or set security token /// public string Token { get; set; } /// /// Get or set status /// public string Status { get; set; } /// /// Get or set message /// public string Message { get; set; } /// /// Get or set UTC minute /// public int UtcMinute { get; set; } /// /// Get or set sender id /// public string SenderId { get; set; } /// /// Get or set state name /// public string StateName { get; set; } /// /// Get or set city name /// public string CityName { get; set; } /// /// Get or set caller language /// public string CallerLanguage { get; set; } /// /// Get or set warrenty /// public string Warranty { get; set; } /// /// Get or set toll free number source /// public string TollFreeeNoSource { get; set; } /// /// Get or set opportunity lost /// public string OpportunityLost { get; set; } /// /// Get or set 24 hrs reason /// public string _24HrsReason { get; set; } /// /// Get or set Vehicle Tagging like(LMD,BUS,HD) /// public string VehicleTagging { get; set; } /// /// Get or set distance between brackdown loction and service engg. /// public string EstimateDistance { get; set; } /// /// Get or set km covered /// public double KmCovered { get; set; } /// /// Get or set km Ticket Id Alias /// public string TicketIdAlias { get; set; } public string OtherRemarks { get; set; } public string Flag { get; set; } public string TicketPrevStatusAliasId { get; set; } public string ChassisNo { get; set; } public double OdometerReading { get; set; } public double PreviousOdometerReading { get; set; } public string VehicleType { get; set; } public string OdometerUnit { get; set; } public string EOSMessage { get; set; } } public class GetVanReachDetails { /// /// Get or set status /// // public string Status { get; set; } /// /// Get or set message /// public string Message { get; set; } /// /// Get or set message /// public string Token { get; set; } /// /// Get or set message /// public string TicketId { get; set; } /// /// Get or set message /// public string assigned_to_user_longitude { get; set; } /// /// Get or set message /// public string assigned_to_user_lattitude { get; set; } /// /// Get or set message /// public string ticketid_alias { get; set; } /// /// Get or set message /// public string service_engineer_name { get; set; } /// /// Get or set message /// public string contact_number { get; set; } } public class DraftTicketResponseModel { /// /// Get or set KAM ticket id /// public string TicketId { get; set; } /// /// Get or set Message /// public string Message { get; set; } } //------ added on 19-01-2021 start--------------------- public class DraftTicketDetailModel { public string Token { get; set; } public int DraftTicketId { get; set; } public string TollFreeNoSource { get; set; } public string RegistrationNumber { get; set; } public string ChassisNumber { get; set; } public string Message { get; set; } public string Status { get; set; } public string DraftTicketCancelReasonID { get; set; } public string DraftTicketCancelReason { get; set; } public string OthersReason { get; set; } } //------ added on 19-01-2021 end ---------------------- //------- added on 09-03-2021 start -------------------- public class CancelledDraftTicketModel { public string Token { get; set; } public string Message { get; set; } public int UtcMinute { get; set; } public int DraftTicketId { get; set; } public string VehicleRegistrationNumber { get; set; } public string ChassisNumber { get; set; } public string Comments { get; set; } public string ContactNumber { get; set; } public string DriverName { get; set; } public bool? KamUser { get; set; } public string CreationTime { get; set; } public string TollFreeNoSource { get; set; } public string TicketCancelReason { get; set; } public string TicketCancelRemark { get; set; } } public class CancelledDraftTicketReportModel { public string Token { get; set; } public string Status { get; set; } public string Message { get; set; } public int UtcMinute { get; set; } public List CancelledDraftTicketList { get; set; } } //------- added on 09-03-2021 end ---------------------- // Added by Priya for consolidate report download // public class ConsolidatedReportModelNew { public string ticketid_alias { get; set; } public string call_assigned_to { get; set; } public string created_by { get; set; } //[DisplayFormat(ApplyFormatInEditMode = true, DataFormatString = "{0:dd MMM yyyy HH:mm:ss}")] //public DateTime creation_time { get; set; } public string creation_time { get; set; } public string time_slot { get; set; } public string customer_name { get; set; } public string customer_contact_no { get; set; } public string organization { get; set; } public string state { get; set; } public string city { get; set; } public string language_name { get; set; } public string owner_name { get; set; } public string owner_contact_number { get; set; } public string customer_vehicle_regn_no { get; set; } public string vehicle_name { get; set; } public string vehicle_type { get; set; } public string chassis_number { get; set; } public string vehicle_instalation_date { get; set; } public string breakdown_location { get; set; } public string landmark { get; set; } public string warranty { get; set; } public string how_did_you_come_to_know_of_eos { get; set; } public string type_of_load_carried { get; set; } public string nature_of_problem { get; set; } public string estimated_cost_string { get { if (Convert.ToString(call_assigned_to).ToLower().Trim() != "dealer") return estimated_cost; else return "NA"; } set { } } public string estimated_time_string { get { if (Convert.ToString(call_assigned_to).ToLower().Trim() != "dealer") return estimated_time; else return "NA"; } set { } } public string dealer_code { get; set; } public string dealer_name { get; set; } /// /// get or set wm name /// public string wm_name { get; set; } public string dealer_contact_no { get; set; } public string eos_team_member_and_van { get; set; } public string open_call_hrs { get; set; } public string time_stamps_status_1 { get; set; } public string time_stamps_status_3 { get; set; } public string time_stamps_status_4 { get; set; } public string time_stamps_status_5 { get; set; } public string escalation_level_van_not_move_1 { get; set; } public string escalation_level_ticket_closer_1 { get; set; } public string call_closure_status { get; set; }//reason for 24 hrs public string KmCovered { get; set; } public string feedback_taken { get; set; }//feedback public string feedback_ease_of_getting_call { get; set; } public string feedback_response_of_call_center { get; set; } public string feedback_timely_updation_by_dealer { get; set; } public string feedback_total_repair_time { get; set; } public string feedback_eos_charges { get; set; } public string feedback_over_all_experience { get; set; } public string closure_remarks { get; set; } public string response_string { get { if (Convert.ToString(call_assigned_to).ToLower().Trim() != "dealer") return response; else return "NA"; } set { } } public string feedback_count { get; set; } public string call_status { get; set; } public string complaints { get; set; } public string suggestion { get; set; } public string feedback_agent { get; set; } public string other_remarks { get; set; } public string DealerTicketOtherRemark { get; set; } public string estimated_distance { get; set; } public string van_covered_distance { get; set; } public string trip_start_time { get; set; } public string trip_end_time { get; set; } public string _eicher_promise { get; set; } public string opportunity_loss { get; set; } public string opportunity_loss_remark { get; set; } public string opportunity_lost_remarks { get; set; } public string remark_ticket_not_closed_24_hours { get; set; } public string remark_ticket_not_closed_24_hours_remarks { get; set; } public int reopen_count { get; set; } public string ChassisNo { get; set; } public double OdometerReading { get; set; } public string _call_closed_within_24_hours { get; set; } //public string Region { get; set; } public string load_carried { get; set; } public string feedback_parameter_wise_score { get; set; } public string total_inbound_calls { get; set; } public string total_outbound_calls { get; set; } public string time_stamps_status_2 { get; set; } public string escalation_level_van_not_move_2 { get; set; } public string escalation_level_van_not_move_3 { get; set; } public string escalation_level_van_not_move_4 { get; set; } public string escalation_level_van_not_move_5 { get; set; } public string escalation_level_van_not_move_6 { get; set; } public string escalation_level_van_not_move_7 { get; set; } public string escalation_level_van_not_move_8 { get; set; } public string escalation_level_van_not_move_9 { get; set; } public string escalation_level_van_not_move_10 { get; set; } public string escalation_level_ticket_closer_2 { get; set; } public string escalation_level_ticket_closer_3 { get; set; } public string escalation_level_ticket_closer_4 { get; set; } public string escalation_level_ticket_closer_5 { get; set; } public string escalation_level_ticket_closer_6 { get; set; } public string escalation_level_ticket_closer_7 { get; set; } public string escalation_level_ticket_closer_8 { get; set; } public string escalation_level_ticket_closer_9 { get; set; } public string escalation_level_ticket_closer_10 { get; set; } public string month_name { get; set; } public string default_sla_time { get; set; } public string region { get; set; } public string vehicle_model { get; set; } public List CloseTicketCountInTimeSlot { get; set; } public string estimated_time { get; set; } public string response { get; set; } public string estimated_cost { get; set; } public string ticket_id { get; set; } /// /// Get or set last updated time(for consolidate report) /// [Display(Name = "Reassignment Date and Time")] public string last_Updated_Time { get; set; } /// /// Get or set are_you_satisfied /// [Display(Name = "Overall Customer Satisfied")] public string are_you_satisfied { get; set; } /// /// Get or set not_satisfied_option /// [Display(Name = "Reason for dissatisfaction")] public string not_satisfied_option { get; set; } /// /// Get or set not_satisfied_reason /// [Display(Name = "Feedback Comments")] public string not_satisfied_reason { get; set; } public double? response_time_reassignment { get; set; } //added on 03/12/2020 public string vehicle_warranty { get; set; } public string vehicle_amc { get; set; } public string vehicle_emission_norms { get; set; } public string vehicle_sales_date { get; set; } //ended on 03/12/2020 public string van_reached_punch_time { get; set; } //added on 23-12-2020 public string ticket_closed_reason { get; set; } //added on 25-11-2020 [Display(Name = "Location change Reassignment Date and Time")] public string location_change_time { get; set; } [Display(Name = "Is Location changed")] public string is_location_change { get; set; } [Display(Name = "Dealer Change Reason")] public string dealer_change_reason { get; set; } [Display(Name = "Dealer Change Reason Remarks")] public string dealer_change_reason_other_remark { get; set; } [Display(Name = "Vehicle Status")] public string vehicle_status { get; set; } [Display(Name = "Fuel Type")] public string fuel_type { get; set; } } public class kendoChartModel { public int Id { get; set; } public string xAxis { get; set; } public int yAxis { get; set; } } public class ReportOpenTicketModel { public string TicketType { get; set; } public string Token { get; set; } public string Status { get; set; } public string Message { get; set; } public string UserId { get; set; } public string FromDate { get; set; } public string ToDate { get; set; } public string Limit { get; set; } public string OffSet { get; set; } public Int32 TicketCount { get; set; } public List TicketList { get; set; } public List TicketopenList { get; set; } public List TicketcloseList { get; set; } public List TicketListNew { get; set; } // public List TicketScoreList { get; set; } public List ConsolidatedReportModelList { get; set; } public List TicketOpenModelList { get; set; } } /* public class TicketListOpenTickets { public string _CreationTime = ""; /// /// Get or set Ticket id /// [Display(Name = "Ticket Id")] public string ticketid_alias { get; set; } /// /// Get or set Ticket status alias /// [Display(Name = "Ticket Status")] public string TicketStatusAlias { get; set; } /// /// Get or set creation time of ticket /// [Display(Name = "Ticket Creation Time")] public string CreationTime { get { return _CreationTime; } set { _CreationTime = value; } } /// /// Get or set customer name /// [Display(Name = "Customer Name")] public string CustomerName { get; set; } /// /// Get or set Customer Contact No. /// [Display(Name = "Customer Contact No.")] public string CustomeContact_no { get; set; } /// /// Get or set customer's vehicle registration no. /// public string VehicleRegistrationNo { get; set; } /// /// Get or set Vehicle Tagging /// public string VehicleTagging { get; set; } /// /// Get or set Default SLA Time /// public int DefaultSlaTime { get; set; } /// /// Get or set Response Time /// [Display(Name = "Response(In min)")] public int? TotalTicketLifeCycleTimeSlab { get; set; } /// /// Get or set Service Engineer Name /// // [Display(Name = "Van SE Name")] public string ServiceEngineerName { get; set; } /// /// Get or set Dealer Name /// [Display(Name = "Dealer Name")] public string DealerDealerName { get; set; } /// /// Get or set Dealer Contact No. /// [Display(Name = "Dealer Contact No.")] public string ServiceEngineerContactNumber { get; set; } public string caller_language { get; set; } /// /// Get or set default column /// public string PreClosureTime { get; set; } public string ChassisNo { get; set; } public double OdometerReading { get; set; } public string VanReachedPunchTime { get; set; } //added on 23-12-2020 /// /// Get or set Description /// [Display(Name = "Nature of Problem")] public string Description { get; set; } /// /// Get or set remarks /// [Display(Name = "Last Remarks")] public string Remarks { get; set; } /// /// Get or set customer name /// [Display(Name = "ASM")] public string ASMName { get; set; } /// /// Get or set Customer Contact No. /// [Display(Name = "ASM Contact No.")] public string ASMNo { get; set; } /// /// Get or set customer name /// [Display(Name = "CSM")] public string CSMName { get; set; } /// /// Get or set Customer Contact No. /// [Display(Name = "CSM Contact No.")] public string CSMNo { get; set; } /// /// Get or set customer name /// [Display(Name = "RSM")] public string RSMName { get; set; } /// /// Get or set Customer Contact No. /// [Display(Name = "RSM Contact No.")] public string RSMNo { get; set; } [Display(Name = "Dealer 1s code")] public string dealer1scode { get; set; } [Display(Name = "Assigned to")] public string assigned_to { get; set; } [Display(Name = "Vehicle Status")] public string Vehicle_Status { get; set; } /// /// Get or set Last Modified Time /// public string LastModifiedTime { get; set; } /// /// Get or set assigned to /// public string AssignedTo { get; set; } public string vehicle_warranty { get; set; } public string vehicle_amc { get; set; } public string vehicle_emission_norms { get; set; } public string vehicle_sales_date { get; set; } //ended on 03/12/2020 /// /// Get or set assigned van/dealer longitude /// public string AssignedToUserLongitude { get; set; } /// /// Get or set assigned van/dealer latitude /// public string AssignedToUserLatitude { get; set; } /// /// Get or set Breack Down Longitude /// public string BreackDownLongitude { get; set; } /// /// Get or set Security Token /// public string feedback_call_status { get; set; } /// /// Get or set Estimated Time For Job Complition /// public int? EstimatedTimeForJobComplition { get; set; } /// /// Get or set Status /// public string total_count { get; set; } public string reopen_count { get; set; } public string Score { get; set; } /// /// Get or set Age(Ticket life cycle time creation to closed time) /// public double? Age { get; set; } /// /// Get or set Default Col 2 /// public string DefaultCol2 { get; set; } /// /// Get or set Custome Contact_no /// public string CallStatus { get; set; } /// /// Get or set Default Col 3 /// public string DefaultCol3 { get; set; } public string Id { get; set; } //added on 25-09-2020 //[Display(Name = "Van Trip Start Latitude")] public string VanLatitudeAtTripStart { get; set; } //[Display(Name = "Van Trip Start Longitude")] public string VanLongitudeAtTripStart { get; set; } //[Display(Name = "Van Reached Latitude")] public string VanLatitudeAtVanReached { get; set; } //[Display(Name = "Van Reached Longitude")] public string VanLongitudeAtVanReached { get; set; } //[Display(Name = "Van Trip End Latitude")] public string VanLatitudeAtTripEnd { get; set; } //[Display(Name = "Van Reached Longitude")] public string VanLongitudeAtTripEnd { get; set; } public string BreakdownLocationLatitude { get; set; } public string BreakdownLocationLongitude { get; set; } public string TicketClosedReason { get; set; } //added on 25-11-2020 } */ public class TicketListOpenTickets { public string _CreationTime = ""; /// /// Get or set Ticket id /// [Display(Name = "Ticket Id")] public string ticketid_alias { get; set; } public string CreatedBy { get; set; } /// /// Get or set Ticket status alias /// [Display(Name = "Ticket Status")] public string TicketStatusAlias { get; set; } /// /// Get or set creation time of ticket /// [Display(Name = "Ticket Creation Time")] public string CreationTime { get { return _CreationTime; } set { _CreationTime = value; } } public string caller_language { get; set; } [Display(Name = "Nature of Problem")] public string Description { get; set; } /// /// Get or set customer's vehicle registration no. /// public string VehicleRegistrationNo { get; set; } public string ChassisNo { get; set; } /// /// Get or set Vehicle Tagging /// public string VehicleTagging { get; set; } public string vehicle_emission_norms { get; set; } [Display(Name = "Vehicle Status")] public string Vehicle_Status { get; set; } public double OdometerReading { get; set; } /// /// Get or set customer name /// [Display(Name = "Customer Name")] public string CustomerName { get; set; } /// /// Get or set Customer Contact No. /// [Display(Name = "Customer Contact No.")] public string CustomeContact_no { get; set; } /// /// Get or set Region /// public string Region { get; set; } [Display(Name = "Dealer 1s code")] public string dealer1scode { get; set; } /// /// Get or set Dealer Name /// [Display(Name = "Dealer Name")] public string DealerDealerName { get; set; } /// /// Get or set Dealer Contact No. /// [Display(Name = "Dealer Contact No.")] public string ServiceEngineerContactNumber { get; set; } /// /// Get or set Service Engineer Name /// // [Display(Name = "Van SE Name")] public string ServiceEngineerName { get; set; } [Display(Name = "CSM")] public string CSMName { get; set; } /// /// Get or set Customer Contact No. /// [Display(Name = "CSM Contact No.")] public string CSMNo { get; set; } [Display(Name = "ASM")] public string ASMName { get; set; } /// /// Get or set Customer Contact No. /// [Display(Name = "ASM Contact No.")] public string ASMNo { get; set; } /// /// Get or set customer name /// [Display(Name = "RSM")] public string RSMName { get; set; } /// /// Get or set Customer Contact No. /// [Display(Name = "RSM Contact No.")] public string RSMNo { get; set; } [Display(Name = "Last Remarks")] public string Remarks { get; set; } /// /// Get or set Default SLA Time /// public int DefaultSlaTime { get; set; } /// /// Get or set Response Time /// [Display(Name = "Response(In min)")] public int? TotalTicketLifeCycleTimeSlab { get; set; } /// /// Get or set default column /// public string PreClosureTime { get; set; } public string VanReachedPunchTime { get; set; } //added on 23-12-2020 [Display(Name = "Assigned to")] public string assigned_to { get; set; } [Display(Name = "Fuel Type")] public string fuel_type { get; set; } [Display(Name = "Vehicle Model Number")] public string model_number { get; set; } [Display(Name = "Battery Volatge")] public string battery_voltage { get; set; } // public string fuelLevelInPer { get; set; } public string fuelLevelInLtr { get; set; } public string defLevelInLtr { get; set; } public string preclosurereason { get; set; } } public class TicketListCloseTickets { public string _CreationTime = ""; /// /// Get or set Ticket id /// [Display(Name = "Ticket Id")] public string ticketid_alias { get; set; } /// /// Get or set Ticket status alias /// [Display(Name = "Ticket Status")] public string TicketStatusAlias { get; set; } /// /// Get or set creation time of ticket /// [Display(Name = "Ticket Creation Time")] public string CreationTime { get { return _CreationTime; } set { _CreationTime = value; } } /// /// Get or set customer name /// [Display(Name = "Customer Name")] public string CustomerName { get; set; } /// /// Get or set Customer Contact No. /// [Display(Name = "Customer Contact No.")] public string CustomeContact_no { get; set; } /// /// Get or set customer's vehicle registration no. /// public string VehicleRegistrationNo { get; set; } /// /// Get or set Vehicle Tagging /// public string VehicleTagging { get; set; } /// /// Get or set Default SLA Time /// public int DefaultSlaTime { get; set; } /// /// Get or set Response Time /// [Display(Name = "Response(In min)")] public int? TotalTicketLifeCycleTimeSlab { get; set; } /// /// Get or set Service Engineer Name /// // [Display(Name = "Van SE Name")] public string ServiceEngineerName { get; set; } /// /// Get or set Dealer Name /// [Display(Name = "Dealer Name")] public string DealerDealerName { get; set; } /// /// Get or set Dealer Contact No. /// [Display(Name = "Dealer Contact No.")] public string ServiceEngineerContactNumber { get; set; } public string caller_language { get; set; } /// /// Get or set default column /// public string DefaultCol2 { get; set; } /// /// Get or set Security Token /// public string feedback_call_status { get; set; } /// /// Get or set Status /// public string total_count { get; set; } public string reopen_count { get; set; } public string PreClosureTime { get; set; } public string ChassisNo { get; set; } public double OdometerReading { get; set; } public string VanReachedPunchTime { get; set; } //added on 23-12-2020 //added on 25-09-2020 //[Display(Name = "Van Trip Start Latitude")] public string VanLatitudeAtTripStart { get; set; } //[Display(Name = "Van Trip Start Longitude")] public string VanLongitudeAtTripStart { get; set; } //[Display(Name = "Van Reached Latitude")] public string VanLatitudeAtVanReached { get; set; } //[Display(Name = "Van Reached Longitude")] public string VanLongitudeAtVanReached { get; set; } //[Display(Name = "Van Trip End Latitude")] public string VanLatitudeAtTripEnd { get; set; } //[Display(Name = "Van Reached Longitude")] public string VanLongitudeAtTripEnd { get; set; } public string BreakdownLocationLatitude { get; set; } public string BreakdownLocationLongitude { get; set; } //added on 03/12/2020 public string vehicle_warranty { get; set; } public string vehicle_amc { get; set; } public string vehicle_emission_norms { get; set; } public string vehicle_sales_date { get; set; } //ended on 03/12/2020 public string TicketClosedReason { get; set; } //added on 25-11-2020 public string LastModifiedTime { get; set; } public string EstimatedVanReachTime { get; set; } public string fuel_type { get; set; } [Display(Name = "Vehicle Model Number")] public string model_number { get; set; } [Display(Name = "Battery Volatge")] public string battery_voltage { get; set; } public string fuelLevelInLtr { get; set; } public string defLevelInLtr { get; set; } public string TripENDBY { get; set; } public string VanAssignedLat { get; set; } public string VanAssignedLong { get; set; } /// /// Get or set Message /// public string gps_status { get; set; } public string Score { get; set; } /// /// Get or set Security Token /// public string Token { get; set; } /// /// Get or set Status /// public string Status { get; set; } /// /// Get or set Message /// public string Message { get; set; } /// /// Get or set Description /// public string Description { get; set; } /// /// Get or set ticket assigned to (van/dealer) /// public string AssignedTo { get; set; } /// /// Get or set Reported bu which user /// public string ReportedVia { get; set; } /// /// Get or set Ticket status /// public string TicketStatus { get; set; } /// /// Get or set priority /// public string Priority { get; set; } /// /// Get or set customer score /// public string CutomerScore { get; set; } /// /// Get or set created by which user /// public string CreatedBy { get; set; } /// /// Get or set last modified by which user /// public string LastModifiedBy { get; set; } /// /// Get or set last modified time /// // public string LastModifiedTime { get; set; } /// /// Get or set breakdown location /// public string BreakDownLocation { get; set; } /// /// Get or set breakdown longitude /// public string BreackDownLongitude { get; set; } /// /// Get or set breakdown latitude /// public string BreackDownLatitude { get; set; } /// /// Get or set assigned to van/dealer id /// public string AssignedToUserId { get; set; } /// /// Get or set assigned van/dealer longitude /// public string AssignedToUserLongitude { get; set; } /// /// Get or set assigned van/dealer latitude /// public string AssignedToUserLatitude { get; set; } /// /// Get or set is declined bit /// public string IsDeclined { get; set; } /// /// Get or set Estimated Time For Job Completion /// public int? EstimatedTimeForJobComplition { get; set; } /// /// Get or set submit time /// public string EstimatedTimeForJobComplitionSubmitTime { get; set; } /// /// Get or set submit time /// public string EstimatedTimeForJobCompletionSubmitTime { get; set; } /// /// Get or set breakdown location landmark /// public string BreakdownLocationLandmark { get; set; } /// /// Get or set open ticket activity created by /// public string ActivityTicketsOpenCreatedBy { get; set; } /// /// Get or set open ticket activity creation time /// public string ActivityTicketsOpenCreationTime { get; set; } /// /// Get or set remarks /// public string Remarks { get; set; } /// /// Get or set Ticket activity status /// public string TicketActivityStatus { get; set; } /// /// Get or set Ticket status sequence for activity /// public string TicketStatusSequenceOrder { get; set; } /// /// Get or set Ticket status name /// public string TicketStatusStatusName { get; set; } /// /// Get or set user id /// public string UserId { get; set; } /// /// Get or set auth engine id/email id /// public string AuthEngineId { get; set; } /// /// Get or set User name /// public string UserName { get; set; } /// /// Get or set Designation /// public string Designation { get; set; } /// /// Get or set Object Id /// public string ObjectId { get; set; } /// /// Get or set Organization Id /// public string OrganizationId { get; set; } /// /// Get or set City /// public string City { get; set; } /// /// Get or set State /// public string State { get; set; } /// /// Get or set Region /// public string Region { get; set; } /// /// Get or set Language /// public string Language { get; set; } /// /// Get or set Time Zone ID /// public string TimezoneId { get; set; } /// /// Get or set display name /// public string DisplayName { get; set; } /// /// Get or set off set minutes for server side paging /// public string OffsetInMinutes { get; set; } /// /// Get or set Display Id /// public string DisplayId { get; set; } /// /// Get or set User Organization Name /// public string UserOrganizationName { get; set; } /// /// Get or set User Organization Alias /// public string UserOrganizationAlias { get; set; } /// /// Get or set User Organization City /// public string UserOrganizationCity { get; set; } /// /// Get or set User Organization State /// public string UserOrganizationState { get; set; } /// /// Get or set User Organization Country /// public string UserAsorganizationCountry { get; set; } /// /// Get or set User Organization Description /// public string UserOrganizationDescription { get; set; } /// /// Get or set User Organization Path /// public string UserOrgPath { get; set; } /// /// Get or set User Organization Depth (Levels) /// public string UserOrgDepth { get; set; } /// /// Get or set User Organization Color code /// public string UserOrgColor { get; set; } /// /// Get or set User Organization Region /// public string UserOrganizationRegion { get; set; } /// /// Get or set Dealer Id /// public string DealerId { get; set; } /// /// Get or set Dealer Organization Id /// public string DealerOrganizationId { get; set; } /// /// Get or set Dealer City /// public string DealerCity { get; set; } /// /// Get or set Dealer State /// public string DealerState { get; set; } /// /// Get or set Dealer Default latitude /// public string DealerDealerDefaultLattitude { get; set; } /// /// Get or set Dealer Default longitude /// public string DealerDealerDefaultLongitude { get; set; } /// /// Get or set van id /// public string VanId { get; set; } /// /// Get or set van alias /// public string VanAlias { get; set; } /// /// Get or set van Default latitude /// public string VanVanDefaultLattitude { get; set; } /// /// Get or set van Default longitude /// public string VanVanDefaultLongitude { get; set; } /// /// Get or set van city /// public string VanCity { get; set; } /// /// Get or set van state /// public string VanState { get; set; } /// /// Get or set van model /// public string VanVanModel { get; set; } /// /// Get or set van registration no. /// public string VanRegistrationNumber { get; set; } /// /// Get or set van registration no. /// public string VanVanRegisteredAs { get; set; } /// /// Get or set van/dealer organization name /// public string DealerVanOrganizationName { get; set; } /// /// Get or set van/dealer organization alias /// public string DealerVanOrganizationOrganizationAlias { get; set; } /// /// Get or set van/dealer organization city /// public string DealerVanOrganizationOrganizationCity { get; set; } /// /// Get or set van/dealer organization state /// public string DealerVanOrganizationOrganizationState { get; set; } /// /// Get or set van/dealer organization country /// public string DealerVanOrganizationOrganizationCountry { get; set; } /// /// Get or set van/dealer organization description /// public string DealerVanOrganizationOrganizationDescription { get; set; } /// /// Get or set van/dealer organization path /// public string DealerVanOrganizationOrganizationPath { get; set; } /// /// Get or set van/dealer organization depth /// public string DealerVanOrganizationOrganizationDepth { get; set; } /// /// Get or set van/dealer organization color code /// public string DealerVanOrganizationOrganizationColor { get; set; } /// /// Get or set van/dealer organization region /// public string DealerVanOrganizationOrganizationRegion { get; set; } /// /// Get or set service engineer id /// public string ServiceEngineerId { get; set; } /// /// Get or set service engineer alias /// public string ServiceEngineerAlias { get; set; } /// /// Get or set service engineer imei no. /// public string ServiceEngineerImeiNumber { get; set; } /// /// Get or set service engineer license key /// public string ServiceEngineerApplicationLicenseKey { get; set; } /// /// Get or set service engineer Mobile Application Blocked (true/false) /// public string ServiceEngineerMobileApplicationBlocked { get; set; } /// /// Get or set service engineer device alias /// public string ServiceEngineerDeviceAlias { get; set; } /// /// Get or set service engineer pin password /// public string ServiceEngineerPinPassword { get; set; } /// /// Get or set route id /// public string RouteId { get; set; } /// /// Get or set vehicle type /// public string VehicleType { get; set; } /// /// Get or set repair cost /// public string RepairCost { get; set; } /// /// Get or set device alias /// public string DeviceAlias { get; set; } /// /// Get or set imei no. /// public string Ieminumber { get; set; } /// /// Get or set SLA missed reason /// public string SlaMissedReason { get; set; } /// /// Get or set suggestion comment /// public string SuggestionComment { get; set; } /// /// Get or set Job Complete Response Time /// public string JobCompleteResponseTime { get; set; } /// /// Get or set default column /// public string DefaultCol3 { get; set; } // public string CustomerName { get; set; } /// /// Get or set Estimated Distance /// public string EstimatedDistance { get; set; } /// /// Get or set age /// public double? Age { get; set; } public string CallStatus { get; set; } public string Id { get; set; } public bool CreationTimeMorethan24Hrs { get { bool _CreationTimeMorethan24Hrs = false; if (_CreationTime != "") { DateTime dtNow = DateTime.Parse(_CreationTime); double dtDiff = (DateTime.Now - dtNow).TotalMinutes; if (dtDiff > 1440) { _CreationTimeMorethan24Hrs = true; } } return _CreationTimeMorethan24Hrs; } } } public class TicketList { public string _CreationTime = ""; /// /// Get or set Ticket id /// [Display(Name = "Ticket Id")] public string ticketid_alias { get; set; } /// /// Get or set Ticket status alias /// [Display(Name = "Ticket Status")] public string TicketStatusAlias { get; set; } /// /// Get or set creation time of ticket /// [Display(Name = "Ticket Creation Time")] public string CreationTime { get { return _CreationTime; } set { _CreationTime = value; } } /// /// Get or set customer name /// [Display(Name = "Customer Name")] public string CustomerName { get; set; } /// /// Get or set Customer Contact No. /// [Display(Name = "Customer Contact No.")] public string CustomeContact_no { get; set; } /// /// Get or set customer's vehicle registration no. /// public string VehicleRegistrationNo { get; set; } /// /// Get or set Vehicle Tagging /// public string VehicleTagging { get; set; } /// /// Get or set Default SLA Time /// public int DefaultSlaTime { get; set; } /// /// Get or set Response Time /// [Display(Name = "Response(In min)")] public int? TotalTicketLifeCycleTimeSlab { get; set; } /// /// Get or set Service Engineer Name /// // [Display(Name = "Van SE Name")] public string ServiceEngineerName { get; set; } /// /// Get or set Dealer Name /// [Display(Name = "Dealer Name")] public string DealerDealerName { get; set; } /// /// Get or set Dealer Contact No. /// [Display(Name = "Dealer Contact No.")] public string ServiceEngineerContactNumber { get; set; } public string caller_language { get; set; } /// /// Get or set default column /// public string DefaultCol2 { get; set; } /// /// Get or set Security Token /// public string feedback_call_status { get; set; } /// /// Get or set Status /// public string total_count { get; set; } public string reopen_count { get; set; } public string PreClosureTime { get; set; } public string ChassisNo { get; set; } public double OdometerReading { get; set; } public string VanReachedPunchTime { get; set; } //added on 23-12-2020 //added on 25-09-2020 //[Display(Name = "Van Trip Start Latitude")] public string VanLatitudeAtTripStart { get; set; } //[Display(Name = "Van Trip Start Longitude")] public string VanLongitudeAtTripStart { get; set; } //[Display(Name = "Van Reached Latitude")] public string VanLatitudeAtVanReached { get; set; } //[Display(Name = "Van Reached Longitude")] public string VanLongitudeAtVanReached { get; set; } //[Display(Name = "Van Trip End Latitude")] public string VanLatitudeAtTripEnd { get; set; } //[Display(Name = "Van Reached Longitude")] public string VanLongitudeAtTripEnd { get; set; } public string BreakdownLocationLatitude { get; set; } public string BreakdownLocationLongitude { get; set; } //added on 03/12/2020 public string vehicle_warranty { get; set; } public string vehicle_amc { get; set; } public string vehicle_emission_norms { get; set; } public string vehicle_sales_date { get; set; } //ended on 03/12/2020 public string TicketClosedReason { get; set; } //added on 25-11-2020 public string LastModifiedTime { get; set; } /// /// Get or set Message /// public string gps_status { get; set; } public string Score { get; set; } /// /// Get or set Security Token /// public string Token { get; set; } /// /// Get or set Status /// public string Status { get; set; } /// /// Get or set Message /// public string Message { get; set; } /// /// Get or set Description /// public string Description { get; set; } /// /// Get or set ticket assigned to (van/dealer) /// public string AssignedTo { get; set; } /// /// Get or set Reported bu which user /// public string ReportedVia { get; set; } /// /// Get or set Ticket status /// public string TicketStatus { get; set; } /// /// Get or set priority /// public string Priority { get; set; } /// /// Get or set customer score /// public string CutomerScore { get; set; } /// /// Get or set created by which user /// public string CreatedBy { get; set; } /// /// Get or set last modified by which user /// public string LastModifiedBy { get; set; } /// /// Get or set last modified time /// // public string LastModifiedTime { get; set; } /// /// Get or set breakdown location /// public string BreakDownLocation { get; set; } /// /// Get or set breakdown longitude /// public string BreackDownLongitude { get; set; } /// /// Get or set breakdown latitude /// public string BreackDownLatitude { get; set; } /// /// Get or set assigned to van/dealer id /// public string AssignedToUserId { get; set; } /// /// Get or set assigned van/dealer longitude /// public string AssignedToUserLongitude { get; set; } /// /// Get or set assigned van/dealer latitude /// public string AssignedToUserLatitude { get; set; } /// /// Get or set is declined bit /// public string IsDeclined { get; set; } /// /// Get or set Estimated Time For Job Completion /// public string EstimatedTimeForJobComplition { get; set; } /// /// Get or set submit time /// public string EstimatedTimeForJobComplitionSubmitTime { get; set; } /// /// Get or set submit time /// public string EstimatedTimeForJobCompletionSubmitTime { get; set; } /// /// Get or set breakdown location landmark /// public string BreakdownLocationLandmark { get; set; } /// /// Get or set open ticket activity created by /// public string ActivityTicketsOpenCreatedBy { get; set; } /// /// Get or set open ticket activity creation time /// public string ActivityTicketsOpenCreationTime { get; set; } /// /// Get or set remarks /// public string Remarks { get; set; } /// /// Get or set Ticket activity status /// public string TicketActivityStatus { get; set; } /// /// Get or set Ticket status sequence for activity /// public string TicketStatusSequenceOrder { get; set; } /// /// Get or set Ticket status name /// public string TicketStatusStatusName { get; set; } /// /// Get or set user id /// public string UserId { get; set; } /// /// Get or set auth engine id/email id /// public string AuthEngineId { get; set; } /// /// Get or set User name /// public string UserName { get; set; } /// /// Get or set Designation /// public string Designation { get; set; } /// /// Get or set Object Id /// public string ObjectId { get; set; } /// /// Get or set Organization Id /// public string OrganizationId { get; set; } /// /// Get or set City /// public string City { get; set; } /// /// Get or set State /// public string State { get; set; } /// /// Get or set Region /// public string Region { get; set; } /// /// Get or set Language /// public string Language { get; set; } /// /// Get or set Time Zone ID /// public string TimezoneId { get; set; } /// /// Get or set display name /// public string DisplayName { get; set; } /// /// Get or set off set minutes for server side paging /// public string OffsetInMinutes { get; set; } /// /// Get or set Display Id /// public string DisplayId { get; set; } /// /// Get or set User Organization Name /// public string UserOrganizationName { get; set; } /// /// Get or set User Organization Alias /// public string UserOrganizationAlias { get; set; } /// /// Get or set User Organization City /// public string UserOrganizationCity { get; set; } /// /// Get or set User Organization State /// public string UserOrganizationState { get; set; } /// /// Get or set User Organization Country /// public string UserAsorganizationCountry { get; set; } /// /// Get or set User Organization Description /// public string UserOrganizationDescription { get; set; } /// /// Get or set User Organization Path /// public string UserOrgPath { get; set; } /// /// Get or set User Organization Depth (Levels) /// public string UserOrgDepth { get; set; } /// /// Get or set User Organization Color code /// public string UserOrgColor { get; set; } /// /// Get or set User Organization Region /// public string UserOrganizationRegion { get; set; } /// /// Get or set Dealer Id /// public string DealerId { get; set; } /// /// Get or set Dealer Organization Id /// public string DealerOrganizationId { get; set; } /// /// Get or set Dealer City /// public string DealerCity { get; set; } /// /// Get or set Dealer State /// public string DealerState { get; set; } /// /// Get or set Dealer Default latitude /// public string DealerDealerDefaultLattitude { get; set; } /// /// Get or set Dealer Default longitude /// public string DealerDealerDefaultLongitude { get; set; } /// /// Get or set van id /// public string VanId { get; set; } /// /// Get or set van alias /// public string VanAlias { get; set; } /// /// Get or set van Default latitude /// public string VanVanDefaultLattitude { get; set; } /// /// Get or set van Default longitude /// public string VanVanDefaultLongitude { get; set; } /// /// Get or set van city /// public string VanCity { get; set; } /// /// Get or set van state /// public string VanState { get; set; } /// /// Get or set van model /// public string VanVanModel { get; set; } /// /// Get or set van registration no. /// public string VanRegistrationNumber { get; set; } /// /// Get or set van registration no. /// public string VanVanRegisteredAs { get; set; } /// /// Get or set van/dealer organization name /// public string DealerVanOrganizationName { get; set; } /// /// Get or set van/dealer organization alias /// public string DealerVanOrganizationOrganizationAlias { get; set; } /// /// Get or set van/dealer organization city /// public string DealerVanOrganizationOrganizationCity { get; set; } /// /// Get or set van/dealer organization state /// public string DealerVanOrganizationOrganizationState { get; set; } /// /// Get or set van/dealer organization country /// public string DealerVanOrganizationOrganizationCountry { get; set; } /// /// Get or set van/dealer organization description /// public string DealerVanOrganizationOrganizationDescription { get; set; } /// /// Get or set van/dealer organization path /// public string DealerVanOrganizationOrganizationPath { get; set; } /// /// Get or set van/dealer organization depth /// public string DealerVanOrganizationOrganizationDepth { get; set; } /// /// Get or set van/dealer organization color code /// public string DealerVanOrganizationOrganizationColor { get; set; } /// /// Get or set van/dealer organization region /// public string DealerVanOrganizationOrganizationRegion { get; set; } /// /// Get or set service engineer id /// public string ServiceEngineerId { get; set; } /// /// Get or set service engineer alias /// public string ServiceEngineerAlias { get; set; } /// /// Get or set service engineer imei no. /// public string ServiceEngineerImeiNumber { get; set; } /// /// Get or set service engineer license key /// public string ServiceEngineerApplicationLicenseKey { get; set; } /// /// Get or set service engineer Mobile Application Blocked (true/false) /// public string ServiceEngineerMobileApplicationBlocked { get; set; } /// /// Get or set service engineer device alias /// public string ServiceEngineerDeviceAlias { get; set; } /// /// Get or set service engineer pin password /// public string ServiceEngineerPinPassword { get; set; } /// /// Get or set route id /// public string RouteId { get; set; } /// /// Get or set vehicle type /// public string VehicleType { get; set; } /// /// Get or set repair cost /// public string RepairCost { get; set; } /// /// Get or set device alias /// public string DeviceAlias { get; set; } /// /// Get or set imei no. /// public string Ieminumber { get; set; } /// /// Get or set SLA missed reason /// public string SlaMissedReason { get; set; } /// /// Get or set suggestion comment /// public string SuggestionComment { get; set; } /// /// Get or set Job Complete Response Time /// public string JobCompleteResponseTime { get; set; } /// /// Get or set default column /// public string DefaultCol3 { get; set; } // public string CustomerName { get; set; } /// /// Get or set Estimated Distance /// public string EstimatedDistance { get; set; } /// /// Get or set age /// public double? Age { get; set; } public string CallStatus { get; set; } public string Id { get; set; } public bool CreationTimeMorethan24Hrs { get { bool _CreationTimeMorethan24Hrs = false; if (_CreationTime != "") { DateTime dtNow = DateTime.Parse(_CreationTime); double dtDiff = (DateTime.Now - dtNow).TotalMinutes; if (dtDiff > 1440) { _CreationTimeMorethan24Hrs = true; } } return _CreationTimeMorethan24Hrs; } } } public class TicketListNew { public string _CreationTime = ""; /// /// Get or set Ticket id /// [Display(Name = "Ticket Id")] public string ticketid_alias { get; set; } /// /// Get or set Ticket status alias /// [Display(Name = "Ticket Status")] public string TicketStatusAlias { get; set; } /// /// Get or set creation time of ticket /// [Display(Name = "Ticket Creation Time")] public string CreationTime { get { return _CreationTime; } set { _CreationTime = value; } } /// /// Get or set customer name /// [Display(Name = "Customer Name")] public string CustomerName { get; set; } /// /// Get or set Customer Contact No. /// [Display(Name = "Customer Contact No.")] public string CustomeContact_no { get; set; } /// /// Get or set customer's vehicle registration no. /// public string VehicleRegistrationNo { get; set; } /// /// Get or set Vehicle Tagging /// public string VehicleTagging { get; set; } /// /// Get or set Default SLA Time /// public int DefaultSlaTime { get; set; } /// /// Get or set Response Time /// [Display(Name = "Response(In min)")] public int? TotalTicketLifeCycleTimeSlab { get; set; } /// /// Get or set Service Engineer Name /// // [Display(Name = "Van SE Name")] public string ServiceEngineerName { get; set; } /// /// Get or set Dealer Name /// [Display(Name = "Dealer Name")] public string DealerDealerName { get; set; } /// /// Get or set Dealer Contact No. /// [Display(Name = "Dealer Contact No.")] public string ServiceEngineerContactNumber { get; set; } public string caller_language { get; set; } /// /// Get or set default column /// public string DefaultCol2 { get; set; } /// /// Get or set Security Token /// public string feedback_call_status { get; set; } /// /// Get or set Status /// public string total_count { get; set; } public string reopen_count { get; set; } public string PreClosureTime { get; set; } public string ChassisNo { get; set; } public double OdometerReading { get; set; } public string VanReachedPunchTime { get; set; } //added on 23-12-2020 //added on 25-09-2020 //[Display(Name = "Van Trip Start Latitude")] public string VanLatitudeAtTripStart { get; set; } //[Display(Name = "Van Trip Start Longitude")] public string VanLongitudeAtTripStart { get; set; } //[Display(Name = "Van Reached Latitude")] public string VanLatitudeAtVanReached { get; set; } //[Display(Name = "Van Reached Longitude")] public string VanLongitudeAtVanReached { get; set; } //[Display(Name = "Van Trip End Latitude")] public string VanLatitudeAtTripEnd { get; set; } //[Display(Name = "Van Reached Longitude")] public string VanLongitudeAtTripEnd { get; set; } public string BreakdownLocationLatitude { get; set; } public string BreakdownLocationLongitude { get; set; } //added on 03/12/2020 public string vehicle_warranty { get; set; } public string vehicle_amc { get; set; } public string vehicle_emission_norms { get; set; } public string vehicle_sales_date { get; set; } //ended on 03/12/2020 public string TicketClosedReason { get; set; } //added on 25-11-2020 public string LastModifiedTime { get; set; } /// /// Get or set Message /// public string gps_status { get; set; } public string Score { get; set; } /// /// Get or set Security Token /// public string Token { get; set; } /// /// Get or set Status /// public string Status { get; set; } /// /// Get or set Message /// public string Message { get; set; } /// /// Get or set Description /// public string Description { get; set; } /// /// Get or set ticket assigned to (van/dealer) /// public string AssignedTo { get; set; } /// /// Get or set Reported bu which user /// public string ReportedVia { get; set; } /// /// Get or set Ticket status /// public string TicketStatus { get; set; } /// /// Get or set priority /// public string Priority { get; set; } /// /// Get or set customer score /// public string CutomerScore { get; set; } /// /// Get or set created by which user /// public string CreatedBy { get; set; } /// /// Get or set last modified by which user /// public string LastModifiedBy { get; set; } /// /// Get or set last modified time /// // public string LastModifiedTime { get; set; } /// /// Get or set breakdown location /// public string BreakDownLocation { get; set; } /// /// Get or set breakdown longitude /// public string BreackDownLongitude { get; set; } /// /// Get or set breakdown latitude /// public string BreackDownLatitude { get; set; } /// /// Get or set assigned to van/dealer id /// public string AssignedToUserId { get; set; } /// /// Get or set assigned van/dealer longitude /// public string AssignedToUserLongitude { get; set; } /// /// Get or set assigned van/dealer latitude /// public string AssignedToUserLatitude { get; set; } /// /// Get or set is declined bit /// public string IsDeclined { get; set; } /// /// Get or set Estimated Time For Job Completion /// public string EstimatedTimeForJobComplition { get; set; } /// /// Get or set submit time /// public string EstimatedTimeForJobComplitionSubmitTime { get; set; } /// /// Get or set submit time /// public string EstimatedTimeForJobCompletionSubmitTime { get; set; } /// /// Get or set breakdown location landmark /// public string BreakdownLocationLandmark { get; set; } /// /// Get or set open ticket activity created by /// public string ActivityTicketsOpenCreatedBy { get; set; } /// /// Get or set open ticket activity creation time /// public string ActivityTicketsOpenCreationTime { get; set; } /// /// Get or set remarks /// public string Remarks { get; set; } /// /// Get or set Ticket activity status /// public string TicketActivityStatus { get; set; } /// /// Get or set Ticket status sequence for activity /// public string TicketStatusSequenceOrder { get; set; } /// /// Get or set Ticket status name /// public string TicketStatusStatusName { get; set; } /// /// Get or set user id /// public string UserId { get; set; } /// /// Get or set auth engine id/email id /// public string AuthEngineId { get; set; } /// /// Get or set User name /// public string UserName { get; set; } /// /// Get or set Designation /// public string Designation { get; set; } /// /// Get or set Object Id /// public string ObjectId { get; set; } /// /// Get or set Organization Id /// public string OrganizationId { get; set; } /// /// Get or set City /// public string City { get; set; } /// /// Get or set State /// public string State { get; set; } /// /// Get or set Region /// public string Region { get; set; } /// /// Get or set Language /// public string Language { get; set; } /// /// Get or set Time Zone ID /// public string TimezoneId { get; set; } /// /// Get or set display name /// public string DisplayName { get; set; } /// /// Get or set off set minutes for server side paging /// public string OffsetInMinutes { get; set; } /// /// Get or set Display Id /// public string DisplayId { get; set; } /// /// Get or set User Organization Name /// public string UserOrganizationName { get; set; } /// /// Get or set User Organization Alias /// public string UserOrganizationAlias { get; set; } /// /// Get or set User Organization City /// public string UserOrganizationCity { get; set; } /// /// Get or set User Organization State /// public string UserOrganizationState { get; set; } /// /// Get or set User Organization Country /// public string UserAsorganizationCountry { get; set; } /// /// Get or set User Organization Description /// public string UserOrganizationDescription { get; set; } /// /// Get or set User Organization Path /// public string UserOrgPath { get; set; } /// /// Get or set User Organization Depth (Levels) /// public string UserOrgDepth { get; set; } /// /// Get or set User Organization Color code /// public string UserOrgColor { get; set; } /// /// Get or set User Organization Region /// public string UserOrganizationRegion { get; set; } /// /// Get or set Dealer Id /// public string DealerId { get; set; } /// /// Get or set Dealer Organization Id /// public string DealerOrganizationId { get; set; } /// /// Get or set Dealer City /// public string DealerCity { get; set; } /// /// Get or set Dealer State /// public string DealerState { get; set; } /// /// Get or set Dealer Default latitude /// public string DealerDealerDefaultLattitude { get; set; } /// /// Get or set Dealer Default longitude /// public string DealerDealerDefaultLongitude { get; set; } /// /// Get or set van id /// public string VanId { get; set; } /// /// Get or set van alias /// public string VanAlias { get; set; } /// /// Get or set van Default latitude /// public string VanVanDefaultLattitude { get; set; } /// /// Get or set van Default longitude /// public string VanVanDefaultLongitude { get; set; } /// /// Get or set van city /// public string VanCity { get; set; } /// /// Get or set van state /// public string VanState { get; set; } /// /// Get or set van model /// public string VanVanModel { get; set; } /// /// Get or set van registration no. /// public string VanRegistrationNumber { get; set; } /// /// Get or set van registration no. /// public string VanVanRegisteredAs { get; set; } /// /// Get or set van/dealer organization name /// public string DealerVanOrganizationName { get; set; } /// /// Get or set van/dealer organization alias /// public string DealerVanOrganizationOrganizationAlias { get; set; } /// /// Get or set van/dealer organization city /// public string DealerVanOrganizationOrganizationCity { get; set; } /// /// Get or set van/dealer organization state /// public string DealerVanOrganizationOrganizationState { get; set; } /// /// Get or set van/dealer organization country /// public string DealerVanOrganizationOrganizationCountry { get; set; } /// /// Get or set van/dealer organization description /// public string DealerVanOrganizationOrganizationDescription { get; set; } /// /// Get or set van/dealer organization path /// public string DealerVanOrganizationOrganizationPath { get; set; } /// /// Get or set van/dealer organization depth /// public string DealerVanOrganizationOrganizationDepth { get; set; } /// /// Get or set van/dealer organization color code /// public string DealerVanOrganizationOrganizationColor { get; set; } /// /// Get or set van/dealer organization region /// public string DealerVanOrganizationOrganizationRegion { get; set; } /// /// Get or set service engineer id /// public string ServiceEngineerId { get; set; } /// /// Get or set service engineer alias /// public string ServiceEngineerAlias { get; set; } /// /// Get or set service engineer imei no. /// public string ServiceEngineerImeiNumber { get; set; } /// /// Get or set service engineer license key /// public string ServiceEngineerApplicationLicenseKey { get; set; } /// /// Get or set service engineer Mobile Application Blocked (true/false) /// public string ServiceEngineerMobileApplicationBlocked { get; set; } /// /// Get or set service engineer device alias /// public string ServiceEngineerDeviceAlias { get; set; } /// /// Get or set service engineer pin password /// public string ServiceEngineerPinPassword { get; set; } /// /// Get or set route id /// public string RouteId { get; set; } /// /// Get or set vehicle type /// public string VehicleType { get; set; } /// /// Get or set repair cost /// public string RepairCost { get; set; } /// /// Get or set device alias /// public string DeviceAlias { get; set; } /// /// Get or set imei no. /// public string Ieminumber { get; set; } /// /// Get or set SLA missed reason /// public string SlaMissedReason { get; set; } /// /// Get or set suggestion comment /// public string SuggestionComment { get; set; } /// /// Get or set Job Complete Response Time /// public string JobCompleteResponseTime { get; set; } /// /// Get or set default column /// public string DefaultCol3 { get; set; } // public string CustomerName { get; set; } /// /// Get or set Estimated Distance /// public string EstimatedDistance { get; set; } /// /// Get or set age /// public double? Age { get; set; } public string CallStatus { get; set; } public string Id { get; set; } public bool CreationTimeMorethan24Hrs { get { bool _CreationTimeMorethan24Hrs = false; if (_CreationTime != "") { DateTime dtNow = DateTime.Parse(_CreationTime); double dtDiff = (DateTime.Now - dtNow).TotalMinutes; if (dtDiff > 1440) { _CreationTimeMorethan24Hrs = true; } } return _CreationTimeMorethan24Hrs; } } } public class TicketOpenModelNew { private string _PreClosureTime = ""; /// /// Get or set Token /// public String Token { get; set; } /// /// Get or set KAM Id /// public string KamId { get; set; } /// /// Get or set ticket id alias /// public string ticketid_alias { get; set; } //--- added on 06-01-2020 start ----------- //public string vehicle_warranty { get; set; } //public string vehicle_amc { get; set; } public double odometer_reading { get; set; } //public string vehicle_sales_date { get; set; } public string ticket_source { get; set; } public string customer_id { get; set; } public string customer_type { get; set; } public string owner_name { get; set; } public Boolean? is_kam { get; set; } public string NewVehicleType { get; set; } //added on 11-01-2021 //--- added on 06-01-2020 end ------------- /// /// Get or set Status /// public string Status { get; set; } /// /// Get or set Message /// public string Message { get; set; } /// /// Get or set Id /// public string Id { get; set; } /// /// Get or set Description /// public string Description { get; set; } /// /// Get or set Assigned To /// public string AssignedTo { get; set; } /// /// Get or set Reported Via /// public string ReportedVia { get; set; } /// /// Get or set Ticket Status /// public int? TicketStatus { get; set; } /// /// Get or set Priority /// public int? Priority { get; set; } /// /// Get or set Cutomer Score /// public string CutomerScore { get; set; } /// /// Get or set Created By /// public string CreatedBy { get; set; } /// /// Get or set Creation Time /// public string CreationTime { get; set; } /// /// Get or set Last Modified By /// public string LastModifiedBy { get; set; } /// /// Get or set Last Modified Time /// public string LastModifiedTime { get; set; } /// /// Get or set Break Down Location /// public string BreakDownLocation { get; set; } /// /// Get or set Breack Down Longitude /// public string BreackDownLongitude { get; set; } /// /// Get or set Breack Down Latitude /// public string BreackDownLatitude { get; set; } /// /// Get or set Assigned To User Id /// public string AssignedToUserId { get; set; } /// /// Get or set Assigned To User Longitude /// public string AssignedToUserLongitude { get; set; } /// /// Get or set Assigned To User Latitude /// public string AssignedToUserLatitude { get; set; } /// /// Get or set Is Declined /// public Boolean? IsDeclined { get; set; } /// /// Get or set Estimated Time For Job Complition /// public int? EstimatedTimeForJobComplition { get; set; } /// /// Get or set Total Ticket Life Cycle Time Slab /// public int? TotalTicketLifeCycleTimeSlab { get; set; } /// /// Get or set Estimated Time For Job Complition Submit Time /// public string EstimatedTimeForJobComplitionSubmitTime { get; set; } /// /// Get or set Vehicle Registration No /// public string VehicleRegistrationNo { get; set; } /// /// Get or set Estimated Time For Job Completion Submit Time /// public string EstimatedTimeForJobCompletionSubmitTime { get; set; } /// /// Get or set Break down Location Landmark /// public string BreakdownLocationLandmark { get; set; } /// /// Get or set Activity Tickets Open Created By /// public string ActivityTicketsOpenCreatedBy { get; set; } /// /// Get or set Activity Tickets Open Creation Time /// public string ActivityTicketsOpenCreationTime { get; set; } /// /// Get or set Remarks /// public string Remarks { get; set; } /// /// Get or set Ticket Activity Status /// public string TicketActivityStatus { get; set; } /// /// Get or set Ticket Status Alias /// public string TicketStatusAlias { get; set; } /// /// Get or set Ticket Status Sequence Order /// public string TicketStatusSequenceOrder { get; set; } /// /// Get or set Ticket Status Name /// public string TicketStatusStatusName { get; set; } /// /// Get or set User Id /// public string UserId { get; set; } /// /// Get or set Auth Engine Id /// public string AuthEngineId { get; set; } /// /// Get or set User Name /// public string UserName { get; set; } /// /// Get or set Designation /// public string Designation { get; set; } /// /// Get or set Object Id /// public string ObjectId { get; set; } /// /// Get or set Organization Id /// public int? OrganizationId { get; set; } /// /// Get or set City /// public string City { get; set; } /// /// Get or set State /// public string State { get; set; } /// /// Get or set Region /// public string Region { get; set; } /// /// Get or set Language /// public string Language { get; set; } /// /// Get or set Timezone Id /// public Int64? TimezoneId { get; set; } /// /// Get or set Display Name /// public string DisplayName { get; set; } /// /// Get or set Offset In Minutes /// public string OffsetInMinutes { get; set; } /// /// Get or set Display Id /// public string DisplayId { get; set; } /// /// Get or set User Organization Name /// public string UserOrganizationName { get; set; } /// /// Get or set User Organization Alias /// public string UserOrganizationAlias { get; set; } /// /// Get or set User Organization City /// public string UserOrganizationCity { get; set; } /// /// Get or set User Organization State /// public string UserOrganizationState { get; set; } /// /// Get or set User Asorganization Country /// public string UserAsorganizationCountry { get; set; } /// /// Get or set User Organization Description /// public string UserOrganizationDescription { get; set; } /// /// Get or set User Org Path /// public string UserOrgPath { get; set; } /// /// Get or set User Org Depth /// public string UserOrgDepth { get; set; } /// /// Get or set User Org Color /// public string UserOrgColor { get; set; } /// /// Get or set User Organization Region /// public string UserOrganizationRegion { get; set; } /// /// Get or set Dealer Id /// public string DealerId { get; set; } /// /// Get or set Organization Id /// public int? DealerOrganizationId { get; set; } /// /// Get or set Dealer Name /// public string DealerDealerName { get; set; } /// /// Get or set Dealer City /// public string DealerCity { get; set; } /// /// Get or set Dealer State /// public string DealerState { get; set; } /// /// Get or set Dealer Default Lattitude /// public string DealerDealerDefaultLattitude { get; set; } /// /// Get or set Dealer Default Longitude /// public string DealerDealerDefaultLongitude { get; set; } /// /// Get or set Van Id /// public string VanId { get; set; } /// /// Get or set Van Alias /// public string VanAlias { get; set; } /// /// Get or set Van Default Lattitude /// public string VanVanDefaultLattitude { get; set; } /// /// Get or set Van Default Longitude /// public string VanVanDefaultLongitude { get; set; } /// /// Get or set Van City /// public string VanCity { get; set; } /// /// Get or set Van State /// public string VanState { get; set; } /// /// Get or set Van Model /// public string VanVanModel { get; set; } /// /// Get or set Van Registration Number /// public string VanRegistrationNumber { get; set; } /// /// Get or set Van Registered As /// public string VanVanRegisteredAs { get; set; } /// /// Get or set Organization Name /// public string DealerVanOrganizationName { get; set; } /// /// Get or set Organization Alias /// public string DealerVanOrganizationOrganizationAlias { get; set; } /// /// Get or set Organization City /// public string DealerVanOrganizationOrganizationCity { get; set; } /// /// Get or set Organization State /// public string DealerVanOrganizationOrganizationState { get; set; } /// /// Get or set Organization Country /// public string DealerVanOrganizationOrganizationCountry { get; set; } /// /// Get or set Organization Description /// public string DealerVanOrganizationOrganizationDescription { get; set; } /// /// Get or set Organization Path /// public string DealerVanOrganizationOrganizationPath { get; set; } /// /// Get or set Organization Depth /// public string DealerVanOrganizationOrganizationDepth { get; set; } /// /// Get or set Organization Color /// public string DealerVanOrganizationOrganizationColor { get; set; } /// /// Get or set Organization Region /// public string DealerVanOrganizationOrganizationRegion { get; set; } /// /// Get or set Service Engineer Id /// public string ServiceEngineerId { get; set; } /// /// Get or set Service Engineer Name /// public string ServiceEngineerName { get; set; } /// /// Get or set Service Engineer Alias /// public string ServiceEngineerAlias { get; set; } /// /// Get or set Service Engineer Imei Number /// public string ServiceEngineerImeiNumber { get; set; } /// /// Get or set Service Engineer Contact Number /// public string ServiceEngineerContactNumber { get; set; } /// /// Get or set Service Engineer Application License Key /// public string ServiceEngineerApplicationLicenseKey { get; set; } /// /// Get or set Service Engineer Mobile Application Blocked /// public Boolean? ServiceEngineerMobileApplicationBlocked { get; set; } /// /// Get or set Service Engineer Device Alias /// public Int64? ServiceEngineerDeviceAlias { get; set; } /// /// Get or set Service Engineer Pin Password /// public string ServiceEngineerPinPassword { get; set; } /// /// Get or set Route Id /// public int? RouteId { get; set; } /// /// Get or set Custome Contact_no /// public string CustomeContact_no { get; set; } /// /// Get or set Vehicle Type /// public string VehicleType { get; set; } /// /// Get or set Repair Cost /// public string RepairCost { get; set; } /// /// Get or set Default Sla Time /// public int? DefaultSlaTime { get; set; } /// /// Get or set Device Alias /// public int? DeviceAlias { get; set; } /// /// Get or set Iemi number /// public string Ieminumber { get; set; } /// /// Get or set Sla Missed Reason /// public string SlaMissedReason { get; set; } /// /// Get or set Suggestion Comment /// public string SuggestionComment { get; set; } /// /// Get or set Job Complete Response Time /// public string JobCompleteResponseTime { get; set; } /// /// Get or set Default Col 2 /// public string DefaultCol2 { get; set; } /// /// Get or set Default Col 3 /// public string DefaultCol3 { get; set; } /// /// Get or set Vehicle Tagging /// public string VehicleTagging { get; set; } /// /// Get or set Customer Name /// public string CustomerName { get; set; } /// /// Get or set /// public string EstimatedDistance { get; set; } /// /// Get or set Age(Ticket life cycle time creation to closed time) /// public double? Age { get; set; } /// /// Get or set Custome Contact_no /// public string OwnerContact_no { get; set; } /// /// Get or set Custome Contact_no /// public string CallStatus { get; set; } /// /// Get or set Custome Contact_no /// public string caller_language { get; set; } /// /// Get or set Security Token /// public string feedback_call_status { get; set; } /// /// Get or set Status /// public string total_count { get; set; } public string reopen_count { get; set; } /// /// Get or set Message /// public string gps_status { get; set; } public string PreClosureTime { get { if (_PreClosureTime == "01 Jan 0001 05:30:00") { _PreClosureTime = ""; } return _PreClosureTime; } set { _PreClosureTime = value; } } /// /// Get or set Is Deleted /// public bool? IsDeleted { get; set; } public string Score { get; set; } public string current_latitude { get; set; } public string current_longitude { get; set; } public string ChassisNo { get; set; } public double OdometerReading { get; set; } //added on 25-09-2020 public string VanReachedPunchTime { get; set; } //added on 23-12-2020 public string VanLatitudeAtTripStart { get; set; } //[Display(Name = "Van Trip Start Longitude")] public string VanLongitudeAtTripStart { get; set; } //[Display(Name = "Van Reached Latitude")] public string VanLatitudeAtVanReached { get; set; } //[Display(Name = "Van Reached Longitude")] public string VanLongitudeAtVanReached { get; set; } //[Display(Name = "Van Trip End Latitude")] public string VanLatitudeAtTripEnd { get; set; } //[Display(Name = "Van Reached Longitude")] public string VanLongitudeAtTripEnd { get; set; } public string BreakdownLocationLatitude { get; set; } public string BreakdownLocationLongitude { get; set; } public string TicketClosedReason { get; set; } //added on 25-11-2020 //added on 03/12/2020 public string vehicle_warranty { get; set; } public string vehicle_amc { get; set; } public string vehicle_emission_norms { get; set; } public string vehicle_sales_date { get; set; } //ended on 03/12/2020 } public class RabittMqDataModel { public string temporary_eos_ticket_number { get; set; } public string eos_ticket_number { get; set; } public int? ticket_status { get; set; } public string ticket_status_description { get; set; } public string assigned_to_user_id { get; set; } public string van_number { get; set; } public string technician_name { get; set; } public string technician_number { get; set; } public string last_modified_time { get; set; } public string eos_ticket_closure_comment { get; set; } public string vehicle_registration_number { get; set; } public string chassis_number { get; set; } public string dealer_code { get; set; } public string breakdown_location { get; set; } public string breakdown_longitude { get; set; } public string breakdown_lattitude { get; set; } } public class VECVReportRequestModel { public string Token { get; set; } public string Status { get; set; } public string Message { get; set; } public int? UserId { get; set; } public string KamUserId { get; set; } public DateTime FromDate { get; set; } public DateTime ToDate { get; set; } public int? Limit { get; set; } public int? OffSet { get; set; } public List TicketList { get; set; } public int? UtcMinute { get; set; } public string EndDate { get; set; } public string StartDate { get; set; } } public class ReportRequestModel { public string Token { get; set; } public string Status { get; set; } public string Message { get; set; } public int? UserId { get; set; } public string KamUserId { get; set; } public DateTime FromDate { get; set; } public DateTime ToDate { get; set; } public int? Limit { get; set; } public int? OffSet { get; set; } public List VanList { get; set; } public List DelearList { get; set; } public List MoodelList { get; set; } public List TechnicianReport { get; set; } public List ReassignmentReportNew { get; set; } public List ReassignmentReport { get; set; } public List DTCReport { get; set; } public List VAHANAPIErrorReport { get; set; } public List VAHANAPIReport { get; set; } public int? UtcMinute { get; set; } public string EndDate { get; set; } public string StartDate { get; set; } } public class ReassignmentReport { public string TicketIdAlias { get; set; } public string CreationTime { get; set; } public string Dealer1SCode { get; set; } public string DealerName { get; set; } public string TicketStatus { get; set; } public string Reassign_to { get; set; } public string Reassign_Reason { get; set; } public string ReassignTime { get; set; } public string ReassignStatus { get; set; } } public class ReassignmentReportNew { public string TicketIdAlias { get; set; } public string CreationTime { get; set; } public string Dealer1SCode { get; set; } public string DealerName { get; set; } public string TicketStatus { get; set; } public string Reassign_to { get; set; } public string Reassign_Reason { get; set; } public string ReassignTime { get; set; } public string reassignstatus { get; set; } public string ReassignRemarks { get; set; } public string Fuel_type { get; set; } public string organization { get; set; } public string state { get; set; } public string Vehicle_Owner_Name { get; set; } public string Vehicle_Owner_Contact_No { get; set; } public string Vehicle_Reg_No { get; set; } public string Vehicle_Model { get; set; } public string Vehicle_Type { get; set; } public string BreakDownLocation { get; set; } public string BreackDownLatitude { get; set; } public string BreackDownLongitude { get; set; } public string BreakDownLandmark { get; set; } public string nature_of_problem { get; set; } public string opportunity_loss { get; set; } public string opportunity_loss_remark { get; set; } public string assigned_to { get; set; } public string call_preclosed { get; set; } public string pre_closure_remarks { get; set; } public string isPreclosed { get; set; } public string call_closure { get; set; } public string estimated_distance { get; set; } public string ticket_accepted { get; set; } public string time_slot { get; set; } public string Preclosure_reason { get; set; } } public class DTCReport { public string TicketIdAlias { get; set; } public string CreationTime { get; set; } public string Organization { get; set; } public string Dealer1SCode { get; set; } public string DealerName { get; set; } public string Opp_lost { get; set; } public string Opp_lost_reason { get; set; } public string DTC_CODE { get; set; } public string DTC_Description { get; set; } public string DTC_Occurance_Date { get; set; } public string Occurence_count { get; set; } public string Registration_no { get; set; } /// /// Get or set vehicle type /// public string vehicle_type { get; set; } /// /// Get or set chasis number /// public string chassis_number { get; set; } /// /// Get or set vehicle installation date/Vehicle Type/Vehicle Emission Norms /// public string Vehicle_Model { get; set; } public string Vehicle_Emission_Norms { get; set; } public string status { get; set; } } public class VECVCalculation { public string TicketIdAlias { get; set; } public string AssignedTo { get; set; } public string TicketStatus { get; set; } public string TicketStatusAlias { get; set; } public string CreationTime { get; set; } public string VanReachedTime { get; set; } public string AssignedToUserId { get; set; } public string LastModifiedTime { get; set; } public string Ticket_Accepted { get; set; } public string Call_Preclosed { get; set; } public string Call_Closure { get; set; } public string Reassignment_Time { get; set; } public string DealerCode { get; set; } public string Dealer_name { get; set; } public string Van_Reached { get; set; } } public class DealerReport { public string Dealer1Scode { get; set; } public string DealerName { get; set; } public string State { get; set; } public string City { get; set; } public string Latitude { get; set; } public string Longitude { get; set; } public string FuelType { get; set; } public string Organisation { get; set; } public string AppVersion { get; set; } } public class TechnicianReport { public string TicketIdAlias { get; set; } public string CreationTime { get; set; } public string TechnicianNumber { get; set; } public string Ticket_status { get; set; } } public class ModelReport { public string ticketid_alias { get; set; } public string ServiceEngineerAlias { get; set; } public string CreationTime { get; set; } public string Description { get; set; } public string ChassisNo { get; set; } public string Dealer1Scode { get; set; } public string VehicleRegistrationNo { get; set; } public string ServiceEngineerContactNumber { get; set; } public string VanVanModel { get; set; } public string WM_Contact_No { get; set; } public string WM_Name { get; set; } public string plant_code { get; set; } public string CaseId { get; set; } public string TicketStatus { get; set; } } public class VanReport { public string Dealer1Scode { get; set; } public string DealerName { get; set; } public string State { get; set; } public string City { get; set; } public string LicenseKey { get; set; } public string RegistrationNumber { get; set; } public string FuelType { get; set; } public string MobileNumber { get; set; } public string TechnicianName { get; set; } public string VanStatus { get; set; } public string AppVersion { get; set; } } public class TicketOpenModelCogentAPI { public string TicketIdAlias { get; set; } public string TicketStatus { get; set; } public string TicketStatusAlias { get; set; } public string CustomeContact_no { get; set; } public string CustomerName { get; set; } public string VehicleRegistrationNo { get; set; } public string Status { get; set; } public string Message { get; set; } public bool isExists { get; set; } } public class VanDealerListStateWiseGetAllVan { /// /// Get or set user id /// public int? UserId { get; set; } /// /// Get or set state name /// public string StateName { get; set; } /// /// Get or set limit /// public string Limit { get; set; } /// /// Get or set dealer van id /// public string DealerSCode { get; set; } /// /// Get or set dealer van id /// public string DealerOrVanContactNo { get; set; } /// /// Get or set dealer van id /// public string DealerVanId { get; set; } /// /// Get or set dealer van name /// public string DealerVanName { get; set; } /// /// Get or set dealer van latitude /// public string DealerVanLattitude { get; set; } /// /// Get or set dealer van longitude /// public string DealerVanLongitude { get; set; } /// /// Get or set dealer van city /// public string DealerVanCity { get; set; } /// /// Get or set dealer van state /// public string DealerVanState { get; set; } /// /// Get or set device alias /// public string DeviceAlias { get; set; } /// /// Get or set no. of assigned ticket /// public Int64? NoOfAssignedTicket { get; set; } /// /// Get or set remaining time /// public string RemainingTime { get; set; } /// /// Get or set type /// public string Type { get; set; } /// /// Get or set device status /// public string DeviceStatus { get; set; } /// /// Get or set security token /// public string Token { get; set; } /// /// Get or set UTC minute /// public int UtcMinute { get; set; } /// /// Get or set Log id /// public int LogId { get; set; } /// /// Get or set latitude value /// public string Latitude { get; set; } /// /// Get or set logitude value /// public string Longitude { get; set; } /// /// Get or set log time /// public string LogTime { get; set; } /// /// Get or set security token value for service access /// // public List TrackingDetail { get; set; } /// /// Get or set isconnected flag /// public string IsConnected { get; set; } /// /// Get or set x cordinate /// public string Xcordinate { get; set; } /// /// Get or set y cordinate /// public string Ycordinate { get; set; } /// /// Get or set z cordinate /// public string Zcordinate { get; set; } /// /// Get or set creation time /// public string CreationTime { get; set; } /// /// Get or set BatteryStatus /// public string BatteryStatus { get; set; } /// /// Get or set GpsStatus /// public string GpsStatus { get; set; } /// /// Get or set IsCharging /// public string IsCharging { get; set; } /// /// Get or set IsPowerSaving /// public string IsPowerSaving { get; set; } /// /// Get or set status /// public string status { get; set; } /// /// Get or set Message /// public string Message { get; set; } /// /// Get or set trackind detail /// public List BulkTrackngDetail { get; set; } } public class PaymentDropDown { /// /// Get or set token /// public string Name { get; set; } /// /// Get or set Status /// public int? Id { get; set; } } public class EPSEmailSendModel { public string TicketId { get; set; } public string Creation_time { get; set; } public string City { get; set; } public string State { get; set; } public string Product_type { get; set; } public string EngineNumber { get; set; } public string DealerCode { get; set; } public string Description { get; set; } public string ContactNo { get; set; } //Added by Mayuri Khandelwal public string Region { get; set; } } public class CustomerVehicleModelDBM { /// /// Get or set token /// public string Token { get; set; } /// /// Get or set Status /// public int? Status { get; set; } /// /// Get or set Utc Minute /// public int? UtcMinute { get; set; } /// /// Get or set Message /// public string Message { get; set; } /// /// Get or set Ticket No /// public string TicketNo { get; set; } /// /// Get or set Customer Id /// public string CustomerId { get; set; } /// /// Get or set Customer Name /// public string CustomerName { get; set; } /// /// Get or set Customer Alias /// public string OdoMeterReading { get; set; } /// /// Get or set CustomerMobile1 /// public string CustomerMobile1 { get; set; } /// Get or set CustomerMobile2 /// public string CustomerMobile2 { get; set; } /// /// Get or set CustomerMobile3 /// public string CustomerMobile3 { get; set; } /// /// Get or set CustomerAddress /// public string CustomerAddress { get; set; } /// /// Get or set CustomerEmailId /// public string CustomerType { get; set; } public string VehicleSalesDate { get; set; } public string VehicleFuelType { get; set; } public string VehicleEmissionNorms { get; set; } /// Get or set CustomerCity /// /// /// public string CustomerCity { get; set; } /// /// Get or set CustomerState /// public string CustomerState { get; set; } /// /// Get or set CustomerVehicleCustomerId /// public string CustomerVehicleCustomerId { get; set; } /// /// Get or set CustomerVehicleVehicleId /// public string CustomerVehicleVehicleId { get; set; } /// /// Get or set CustomerVehicleIsOwnwer /// public Boolean? CustomerVehicleIsOwnwer { get; set; } /// /// Get or set VehicleId /// public string VehicleId { get; set; } /// /// Get or set VehicleRegistrationNumber /// public string VehicleRegistrationNumber { get; set; } /// /// Get or set VehicleNumberPlate /// public string VehicleNumberPlate { get; set; } /// /// Get or set VehicleModelNumber /// public string VehicleModelNumber { get; set; } /// /// Get or set Vehicle Type /// public string VehicleType { get; set; } public string vehicle_warranty { get; set; } public string product_variant { get; set; } public string vehicle_amc { get; set; } public string vehicle_installation_date { get; set; } public string AMCType { get; set; } public string AMCDate { get; set; } public string extended_warranty { get; set; } public string warranty_end_date { get; set; } /// /// Get or set token /// public string userType { get; set; } public string TicketStatusCreation { get; set; } public string AssignedToCreation { get; set; } public string BatteryVoltage { get; set; } public string vehicleManufacturerName { get; set; } public string fuelLevelInPer { get; set; } public string fuelLevelInLtr { get; set; } public string defLevelInLtr { get; set; } public bool isEPS { get; set; } public string Engine_number { get; set; } public string SALES_DATE { get; set; } public string Fert { get; set; } } public class VAHANAPIError { public string message { get; set; } public string status { get; set; } public string reason { get; set; } public string type { get; set; } public string statusCode { get; set; } public string registration_number { get; set; } // public string chassis_number { get; set; } public string creation_time { get; set; } } public class ErrorResponse { public VAHANAPIError Error { get; set; } } public class DBMPayloadCreation { public string Creation_Time { get; set; } public string Vehicle_Owner_Contact_No { get; set; } public string Dealer_SCode { get; set; } public string Ticket_Id { get; set; } public string Vehicle_Model { get; set; } public string Vehicle_Reg_No { get; set; } public string Vehicle_Owner_Name { get; set; } /// /// Get or set token /// public string Vehicle_Type { get; set; } public string fuel_type { get; set; } public string Van_Reached { get; set; } } public class DBMPayloadClosed { public string Ticket_Id { get; set; } public string Estimated_KM { get; set; } public string Van_Reached { get; set; } public string fuel_type { get; set; } } public class DBMPayloadTripEnd { public string Ticket_Id { get; set; } public string Actual_KM { get; set; } public string Estimated_KM { get; set; } public string fuel_type { get; set; } public string Van_Reached { get; set; } } public class PaymentDetailsModel { /// /// Get or set token /// public string DateAlias { get; set; } /// /// Get or set token /// public string TimeAlias { get; set; } /// /// Get or set Customer Name /// public string CustomerName { get; set; } /// /// Get or set Customer Id /// public string CustomerMobileNumber { get; set; } /// /// Get or set Customer Alias /// public string Amount { get; set; } public string ModeOfPayment { get; set; } /// /// Get or set creation time /// public string remarks { get; set; } /// /// Get or set Ticket No /// public string TicketId_Alias { get; set; } /// /// Get or set Ticket No /// public string Created_By { get; set; } /// /// Get or set Ticket No /// public string Created_By_type { get; set; } /// /// Get or set token /// public string addstatus { get; set; } /// /// Get or set token /// public string Token { get; set; } /// /// Get or set Status /// public int? Status { get; set; } /// /// Get or set Utc Minute /// public int? UtcMinute { get; set; } /// /// Get or set Message /// public string Message { get; set; } /// /// Get or set Ticket No /// public string TicketId { get; set; } /// /// Get or set utc minute /// public int UtcMinutes { get; set; } /// /// Get or set creation time /// public string creation_time { get; set; } /// /// Get or set creation time /// public DateTime payment_date { get; set; } public string RegistrationNumber { get; set; } public string DealerName { get; set; } } public class LiveTrackingDetailsModel { public string VehicleTagging { get; set; } /// /// Get or set token /// public string WMName { get; set; } /// /// Get or set token /// public string WMNumber { get; set; } /// /// Get or set Customer Name /// public string TechnicianName { get; set; } /// /// Get or set Customer Id /// public string TechnicianMobileNumber { get; set; } /// /// Get or set Customer Alias /// public string SiteInchargeName { get; set; } public string SiteInchargeNo { get; set; } /// /// Get or set creation time /// public string BreakdownLat { get; set; } /// /// Get or set creation time /// public string mobileOTP { get; set; } /// /// Get or set Ticket No /// public string TicketId_Alias { get; set; } /// /// Get or set Ticket No /// public string BreakdownLong { get; set; } /// /// Get or set Ticket No /// public string tabLiveLat { get; set; } /// /// Get or set token /// public string tabLiveLong { get; set; } /// /// Get or set Ticket No /// public string tabLat { get; set; } /// /// Get or set token /// public string tabLong { get; set; } /// /// Get or set token /// public string Token { get; set; } /// /// Get or set Status /// public int? Status { get; set; } /// /// Get or set Utc Minute /// public int? UtcMinute { get; set; } /// /// Get or set Message /// public string Message { get; set; } /// /// Get or set Ticket No /// public string TicketId { get; set; } /// /// Get or set Ticket No /// public string brkLocation { get; set; } /// /// Get or set utc minute /// public int UtcMinutes { get; set; } /// /// Get or set creation time /// public string creation_time { get; set; } public string RegistrationNumber { get; set; } public string DealerName { get; set; } } public class ParttDetailsModel { /// /// Get or set token /// public string DateAliascreation { get; set; } /// /// Get or set token /// public string TimeAliascreation { get; set; } public string DateAliasupdation { get; set; } /// /// Get or set token /// public string TimeAliasupdation { get; set; } /// /// Get or set Customer Name /// public string PartName { get; set; } /// /// Get or set Customer Id /// public string PartNumber { get; set; } /// /// Get or set Customer Alias /// public string QuantityReturned { get; set; } public Int32 QuantityIssued { get; set; } /// /// Get or set creation time /// public string remarks { get; set; } /// /// Get or set Ticket No /// public string TicketId_Alias { get; set; } /// /// Get or set Ticket No /// public string Created_By { get; set; } /// /// Get or set token /// public string Token { get; set; } /// /// Get or set Status /// public int? Status { get; set; } /// /// Get or set Utc Minute /// public int? UtcMinute { get; set; } /// /// Get or set Message /// public string Message { get; set; } /// /// Get or set Ticket No /// public string TicketId { get; set; } /// /// Get or set Ticket No /// public Int64? PartId { get; set; } /// /// Get or set utc minute /// public int UtcMinutes { get; set; } /// /// Get or set creation time /// public string creation_date { get; set; } /// /// Get or set creation time /// public string update_date { get; set; } /// /// Get or set token /// public string addstatus { get; set; } } public class CaseManagementAPIModel { /// /// Get or set token /// public string EOS_Ticket_Id { get; set; } public string Dealer_Code { get; set; } public string Dealer_Name { get; set; } public string Registration_number { get; set; } public string Dealer_Contact_Number { get; set; } public string CSM_Name { get; set; } public string ASM_Name { get; set; } public string RSM_Name { get; set; } public string WM_Name { get; set; } public string CSM_Contact { get; set; } public string ASM_Contact { get; set; } public string RSM_contact { get; set; } public string WM_contact { get; set; } public string creation_time { get; set; } public string EOS_Aging_Hrs { get; set; } public string Latest_Remark { get; set; } public string EOS_Ticket_Status { get; set; } public string chassis_no { get; set; } public string VehicleTagging { get; set; } public string ModelNumber { get; set; } public string CutomerType { get; set; } public string Region { get; set; } } public class APIValueModel { /// /// Get or set token /// public string ticket_Id { get; set; } public string subject { get; set; } public string body { get; set; } public string recipients { get; set; } public string caseId { get; set; } public string caseType { get; set; } public string ticketIdAlias { get; set; } public string dealerName { get; set; } public string dealerId { get; set; } public string creation_time { get; set; } public string VehicleRegistrationNumber { get; set; } public string ownerName { get; set; } public string VehicleModelNumber { get; set; } } public class ApiResponse { public string Message { get; set; } public data data { get; set; } } public class SMSApiResponse { public string VehicleType { get; set; } public string ProductVariant { get; set; } public string WmNo { get; set; } public string WMName { get; set; } public string EOSSiteNo { get; set; } public string DealerName { get; set; } public string DealerNo { get; set; } public string EOSSiteName { get; set; } public string ModelNumber { get; set; } public string OTP { get; set; } public string ticket_id { get; set; } public string Customer_name { get; set; } public string Dealer_code { get; set; } } public class ClodantAPIModel { public string ticket_id { get; set; } public string chassis_no { get; set; } /// /// Get or set token /// public string packet_info { get; set; } public string device_id { get; set; } public long startdate { get; set; } public long enddate { get; set; } } public class data { public string case_number { get; set; } public string case_status { get; set; } public string created_at { get; set; } } public class ElectricServiceStationModel { public string token { get; set; } public string lattitude { get; set; } public string longitude { get; set; } public string name { get; set; } public string city { get; set; } public string state { get; set; } public string address { get; set; } public string MobileNumber { get; set; } } public class ValueModel { /// /// Get or set token /// public string dealerId { get; set; } /// /// Get or set token /// public string fuelId { get; set; } /// /// Get or set token /// public string fuelValue { get; set; } /// /// Get or set to /// public string regNo { get; set; } } public class VAHANAPI { public string chassis_number { get; set; } public string vehicleManufacturerName { get; set; } public string model { get; set; } public string normsType { get; set; } public string type { get; set; } public string owner { get; set; } public string creation_time { get; set; } public string Registration_Number { get; set; } } public class TicketInfoModel { /// /// Get or set Ticket Type /// public string TicketStatusAlias { get; set; } public string CreationTime { get; set; } public string VehicleRegistrationNo { get; set; } public string ticketid_alias { get; set; } public string ChassisNo { get; set; } public string TicketStatus { get; set; } public string Status { get; set; } public string Message { get; set; } public string TicketStatusId { get; set; } } public class VanDealerListStateWiseVanSearch { /// /// Get or set user id /// public int? UserId { get; set; } /// /// Get or set state name /// public string StateName { get; set; } /// /// Get or set limit /// public string Limit { get; set; } /// /// Get or set dealer van id /// public string DealerSCode { get; set; } /// /// Get or set dealer van id /// public string DealerOrVanContactNo { get; set; } /// /// Get or set dealer van id /// public string DealerVanId { get; set; } /// /// Get or set dealer van name /// public string DealerVanName { get; set; } /// /// Get or set dealer van latitude /// public string DealerVanLattitude { get; set; } /// /// Get or set dealer van longitude /// public string DealerVanLongitude { get; set; } /// /// Get or set dealer van city /// public string DealerVanCity { get; set; } /// /// Get or set dealer van state /// public string DealerVanState { get; set; } /// /// Get or set device alias /// public string DeviceAlias { get; set; } /// /// Get or set no. of assigned ticket /// public Int64? NoOfAssignedTicket { get; set; } /// /// Get or set remaining time /// public string RemainingTime { get; set; } /// /// Get or set type /// public string Type { get; set; } /// /// Get or set device status /// public string DeviceStatus { get; set; } /// /// Get or set security token /// public string Token { get; set; } /// /// Get or set status /// public string Status { get; set; } /// /// Get or set message /// public string Message { get; set; } /// /// Get or set message /// public string Fuel_type { get; set; } /// /// Get or set UTC minute /// public int UtcMinute { get; set; } public bool islocationChange { get; set; } } #region for excel report public static class ListToDatatableHelper { /// /// Converts a list to data-table /// /// type of list /// list /// data-table public static DataTable ToDataTable(this IList data) { DataTable dataTable = new DataTable(typeof(TSource).Name); PropertyInfo[] props = typeof(TSource).GetProperties(BindingFlags.Public | BindingFlags.Instance); foreach (PropertyInfo prop in props) { dataTable.Columns.Add(prop.Name, Nullable.GetUnderlyingType(prop.PropertyType) ?? prop.PropertyType); } foreach (TSource item in data) { var values = new object[props.Length]; for (int i = 0; i < props.Length; i++) { values[i] = props[i].GetValue(item, null); } dataTable.Rows.Add(values); } return dataTable; } } public class CreateExcelFile { public static bool CreateExcelDocument(List list, string xlsxFilePath) { DataSet ds = new DataSet(); ds.Tables.Add(ListToDataTable(list)); return CreateExcelDocument(ds, xlsxFilePath); } #region HELPER_FUNCTIONS // This function is adapated from: http://www.codeguru.com/forum/showthread.php?t=450171 // My thanks to Carl Quirion, for making it "nullable-friendly". public static DataTable ListToDataTable(List list) { DataTable dt = new DataTable(); foreach (PropertyInfo info in typeof(T).GetProperties()) { dt.Columns.Add(new DataColumn(info.Name, GetNullableType(info.PropertyType))); } foreach (T t in list) { DataRow row = dt.NewRow(); foreach (PropertyInfo info in typeof(T).GetProperties()) { if (!IsNullableType(info.PropertyType)) row[info.Name] = info.GetValue(t, null); else row[info.Name] = (info.GetValue(t, null) ?? DBNull.Value); } dt.Rows.Add(row); } return dt; } private static Type GetNullableType(Type t) { Type returnType = t; if (t.IsGenericType && t.GetGenericTypeDefinition().Equals(typeof(Nullable<>))) { returnType = Nullable.GetUnderlyingType(t); } return returnType; } private static bool IsNullableType(Type type) { return (type == typeof(string) || type.IsArray || (type.IsGenericType && type.GetGenericTypeDefinition().Equals(typeof(Nullable<>)))); } public static bool CreateExcelDocument(DataTable dt, string xlsxFilePath) { DataSet ds = new DataSet(); ds.Tables.Add(dt); bool result = CreateExcelDocument(ds, xlsxFilePath); ds.Tables.Remove(dt); return result; } #endregion // End of "INCLUDE_WEB_FUNCTIONS" section /// /// Create an Excel file, and write it to a file. /// /// DataSet containing the data to be written to the Excel. /// Name of file to be written. /// True if successful, false if something went wrong. public static bool CreateExcelDocument(DataSet ds, string excelFilename) { /// /// making object of LoggingUtility class available to this class /// LoggingUtility objLog = new LoggingUtility(); /// /// making the data-log file path available to this class /// string path = HttpContext.Current.Server.MapPath(ConfigurationManager.AppSettings["PathLog"]); /// /// making error log file path available to this class /// string errorlogtf = (ConfigurationManager.AppSettings["ErrorLog"]); /// /// making data log file path available to this class /// string logtf = (ConfigurationManager.AppSettings["Log"]); try { using (SpreadsheetDocument document = SpreadsheetDocument.Create(excelFilename, SpreadsheetDocumentType.Workbook)) { WriteExcelFile(ds, document); } Trace.WriteLine("Successfully created: " + excelFilename); return true; } catch (Exception ex) { Trace.WriteLine("Failed, exception thrown: " + ex.Message); objLog.ErrorLogFile("ConsolidatedDataReport excel CreateExcelDocument", ex.StackTrace + "message :" + ex.Message, path, errorlogtf); return false; } } private static void WriteExcelFile(DataSet ds, SpreadsheetDocument spreadsheet) { // Create the Excel file contents. This function is used when creating an Excel file either writing // to a file, or writing to a MemoryStream. spreadsheet.AddWorkbookPart(); spreadsheet.WorkbookPart.Workbook = new DocumentFormat.OpenXml.Spreadsheet.Workbook(); // My thanks to James Miera for the following line of code (which prevents crashes in Excel 2010) spreadsheet.WorkbookPart.Workbook.Append(new BookViews(new WorkbookView())); // If we don't add a "WorkbookStylesPart", OLEDB will refuse to connect to this .xlsx file ! WorkbookStylesPart workbookStylesPart = spreadsheet.WorkbookPart.AddNewPart("rIdStyles"); Stylesheet stylesheet = new Stylesheet(); workbookStylesPart.Stylesheet = stylesheet; // Loop through each of the DataTables in our DataSet, and create a new Excel Worksheet for each. uint worksheetNumber = 1; foreach (DataTable dt in ds.Tables) { // For each worksheet you want to create string workSheetID = "rId" + worksheetNumber.ToString(); string worksheetName = dt.TableName; WorksheetPart newWorksheetPart = spreadsheet.WorkbookPart.AddNewPart(); newWorksheetPart.Worksheet = new DocumentFormat.OpenXml.Spreadsheet.Worksheet(); // create sheet data newWorksheetPart.Worksheet.AppendChild(new DocumentFormat.OpenXml.Spreadsheet.SheetData()); // save worksheet WriteDataTableToExcelWorksheet(dt, newWorksheetPart); newWorksheetPart.Worksheet.Save(); // create the worksheet to workbook relation if (worksheetNumber == 1) spreadsheet.WorkbookPart.Workbook.AppendChild(new DocumentFormat.OpenXml.Spreadsheet.Sheets()); spreadsheet.WorkbookPart.Workbook.GetFirstChild().AppendChild(new DocumentFormat.OpenXml.Spreadsheet.Sheet() { Id = spreadsheet.WorkbookPart.GetIdOfPart(newWorksheetPart), SheetId = (uint)worksheetNumber, Name = dt.TableName }); worksheetNumber++; } spreadsheet.WorkbookPart.Workbook.Save(); } private static void WriteDataTableToExcelWorksheet(DataTable dt, WorksheetPart worksheetPart) { var worksheet = worksheetPart.Worksheet; var sheetData = worksheet.GetFirstChild(); string cellValue = ""; // Create a Header Row in our Excel file, containing one header for each Column of data in our DataTable. // // We'll also create an array, showing which type each column of data is (Text or Numeric), so when we come to write the actual // cells of data, we'll know if to write Text values or Numeric cell values. int numberOfColumns = dt.Columns.Count; bool[] IsNumericColumn = new bool[numberOfColumns]; string[] excelColumnNames = new string[numberOfColumns]; for (int n = 0; n < numberOfColumns; n++) excelColumnNames[n] = GetExcelColumnName(n); // // Create the Header row in our Excel Worksheet // uint rowIndex = 1; var headerRow = new Row { RowIndex = rowIndex }; // add a row at the top of spreadsheet sheetData.Append(headerRow); for (int colInx = 0; colInx < numberOfColumns; colInx++) { DataColumn col = dt.Columns[colInx]; AppendTextCell(excelColumnNames[colInx] + "1", col.ColumnName, headerRow); IsNumericColumn[colInx] = (col.DataType.FullName == "System.Decimal") || (col.DataType.FullName == "System.Int32"); } // // Now, step through each row of data in our DataTable... // double cellNumericValue = 0; foreach (DataRow dr in dt.Rows) { // ...create a new row, and append a set of this row's data to it. ++rowIndex; var newExcelRow = new Row { RowIndex = rowIndex }; // add a row at the top of spreadsheet sheetData.Append(newExcelRow); for (int colInx = 0; colInx < numberOfColumns; colInx++) { cellValue = dr.ItemArray[colInx].ToString(); // Create cell with data if (IsNumericColumn[colInx]) { // For numeric cells, make sure our input data IS a number, then write it out to the Excel file. // If this numeric value is NULL, then don't write anything to the Excel file. cellNumericValue = 0; if (double.TryParse(cellValue, out cellNumericValue)) { cellValue = cellNumericValue.ToString(); AppendNumericCell(excelColumnNames[colInx] + rowIndex.ToString(), cellValue, newExcelRow); } } else { // For text cells, just write the input data straight out to the Excel file. AppendTextCell(excelColumnNames[colInx] + rowIndex.ToString(), cellValue, newExcelRow); } } } } private static void AppendTextCell(string cellReference, string cellStringValue, Row excelRow) { // Add a new Excel Cell to our Row Cell cell = new Cell() { CellReference = cellReference, DataType = CellValues.String }; CellValue cellValue = new CellValue(); cellValue.Text = cellStringValue; cell.Append(cellValue); excelRow.Append(cell); } private static void AppendNumericCell(string cellReference, string cellStringValue, Row excelRow) { // Add a new Excel Cell to our Row Cell cell = new Cell() { CellReference = cellReference }; CellValue cellValue = new CellValue(); cellValue.Text = cellStringValue; cell.Append(cellValue); excelRow.Append(cell); } private static string GetExcelColumnName(int columnIndex) { // Convert a zero-based column index into an Excel column reference (A, B, C.. Y, Y, AA, AB, AC... AY, AZ, B1, B2..) // // eg GetExcelColumnName(0) should return "A" // GetExcelColumnName(1) should return "B" // GetExcelColumnName(25) should return "Z" // GetExcelColumnName(26) should return "AA" // GetExcelColumnName(27) should return "AB" // ..etc.. // if (columnIndex < 26) return ((char)('A' + columnIndex)).ToString(); char firstChar = (char)('A' + (columnIndex / 26) - 1); char secondChar = (char)('A' + (columnIndex % 26)); return string.Format("{0}{1}", firstChar, secondChar); } /// /// This class contain customer ehicle properties /// } #endregion #endregion }