/// <summary> /// Create new Work with Result /// </summary> /// <param name="data">Result</param> public Work(WorkResult data) { Data = data; ErrorMessage = Exceptions.Message; ErrorOccurred = Exceptions.ErrorOccurred; Response = Http.LastResponse; }
/// <summary> /// Create new Work with Result /// </summary> /// <param name="data">Result</param> public Work(WorkResult data) { if (data.Data == null || data.Data.Count == 0) { data.Data = new List <WorkData> { new WorkData() } } ; Data = data; ErrorMessage = Exceptions.Message; ErrorOccurred = Exceptions.ErrorOccurred; Response = Http.LastResponse; } }