public OperationEntryCellViewModel(ServiceOrderOperationViewModel parent, DayOfWeekViewModel day) : base() { Guard.NotNull(() => parent, parent); Guard.NotNull(() => day, day); this._parent = parent; this._day = day; }
public OperationEntryCellViewModel GetEntryCellForDay(DayOfWeekViewModel day) { Guard.NotNull(() => day, day); OperationEntryCellViewModel result = null; lock (_entryCells) { if (!_entryCells.TryGetValue(day.Index, out result)) { _entryCells.Add(day.Index, result = new OperationEntryCellViewModel(this, day)); } } return(result); }
public EnosixTimesheet_LINE_ITEM CreateNewTimeSheetItem(DayOfWeekViewModel day) { var item = new EnosixTimesheet_LINE_ITEM() { WorkDate = day.Day, ActivityType = Operation.ActivityType, ActivityNumber = Operation.OperationActivityNumber, AttendanceOrAbsenceType = AttendanceOrAbsenceType, ReceiverOrder = Parent.ServiceOrder.ServiceOrderNumber, }; _parent.AddTimesheetLineItem(item); return(item); }
public static ConditionViewModel ToConditionViewModel(this DayOfWeekViewModel dayOfWeekViewModel) { return(dayOfWeekViewModel.GenerateCondition()); }