コード例 #1
0
        private void SaveAgriculturalYear(object agriculturalYearInstance)
        {
            AgriculturalYearViewModel agriculturalYear = agriculturalYearInstance as AgriculturalYearViewModel;

            if (agriculturalYear != null && agriculturalYear.IsValid)
            {
                AgriculturalYears.Add(agriculturalYear);
            }
            Back();
        }
コード例 #2
0
        private void DeleteAgriculturalYear(object agriculturalYearObject)
        {
            AgriculturalYearViewModel agriculturalYear = agriculturalYearObject as AgriculturalYearViewModel;

            if (agriculturalYear != null)
            {
                AgriculturalYears.Remove(agriculturalYear);
            }
            Back();
        }