public AddEditTimesheetCodeDialog()
        {
            InitializeComponent();

            AddEditTimesheetCodeModel viewModel = new AddEditTimesheetCodeModel();
            viewModel.View = this;
            DataContext = viewModel;

            Title = "Add Timesheet Code";
        }
        public AddEditTimesheetCodeDialog(int timesheetCodeId)
        {
            InitializeComponent();

            Title = "Edit Timesheet Code";
            AddEditTimesheetCodeModel viewModel = new AddEditTimesheetCodeModel(timesheetCodeId);
            viewModel.View = this;
            viewModel.DataLoaded += () =>
                {
                    DataContext = viewModel;
                    Utils.ResetOriginalValues(this);
                };
        }