/// <summary> /// Constructor /// </summary> public CheckInOrderComponentControl(CheckInOrderComponent component) : base(component) { InitializeComponent(); _component = component; _orderTableView.Table = _component.OrderTable; _checkInDate.DataBindings.Add("Value", _component, "CheckInTime", true, DataSourceUpdateMode.OnPropertyChanged); _checkInDate.DataBindings.Add("Visible", _component, "CheckInTimeVisible"); _checkInTime.DataBindings.Add("Value", _component, "CheckInTime", true, DataSourceUpdateMode.OnPropertyChanged); _checkInTime.DataBindings.Add("Visible", _component, "CheckInTimeVisible"); _okButton.DataBindings.Add("Enabled", _component, "AcceptEnabled", false, DataSourceUpdateMode.OnPropertyChanged); }
public static bool CheckIn(EntityRef orderRef, string title, IDesktopWindow desktopWindow) { List<ProcedureSummary> procedures = null; Platform.GetService((IRegistrationWorkflowService service) => procedures = service.ListProceduresForCheckIn(new ListProceduresForCheckInRequest(orderRef)).Procedures); if(procedures.Count == 0) { desktopWindow.ShowMessageBox(SR.MessageNoProceduresCanBeCheckedIn, MessageBoxActions.Ok); return false; } var checkInComponent = new CheckInOrderComponent(procedures); var exitCode = ApplicationComponent.LaunchAsDialog( desktopWindow, checkInComponent, title); return (exitCode == ApplicationComponentExitCode.Accepted); }
public void SetComponent(IApplicationComponent component) { _component = (CheckInOrderComponent)component; }