public CemeteryInformation(VeteranDBInfo record)
        {
            InitializeComponent();

            WindowState = WindowState.Maximized;

            DataContext = this;

            Veteran = record;

            LoadCemeteryPictures();
        }
예제 #2
0
        private void LoadAllData(int recordId)
        {
            // If recordIds == null, it's a single record, the buttons are hidden
            if (recordIds != null)
            {
                if (recordIds.IndexOf(recordId) == 0)
                {
                    Btn_Previous.IsEnabled = false;
                    Btn_Next.IsEnabled     = true;
                }
                else if (recordIds.IndexOf(recordId) == (recordIds.Count - 1))
                {
                    Btn_Previous.IsEnabled = true;
                    Btn_Next.IsEnabled     = false;
                }
                else
                {
                    Btn_Previous.IsEnabled = true;
                    Btn_Next.IsEnabled     = true;
                }
            }

            DataContext = null;

            currentId = recordId;
            Veteran   = new VeteranDBInfo(currentId);

            DataContext = this;

            ClearFields();

            BuildServiceDetails();
            LoadVeteranPictures();
            BuildConflictsList();
            BuildAwardsList();
        }