コード例 #1
0
 public void GetJournalsByCropId(Action<List<JournalModel>> callback, int cropId)
 {
     ViewGetJournalsByCropId = callback;
     JournalRepository journalRepository = new JournalRepository();
     GetJournalsByCropIdCallback handler = new GetJournalsByCropIdCallback(GetJournalByCropIdCompleted);
     journalRepository.GetJournalsByCropId(new Action<List<JournalModel>>(handler), cropId);
 }
コード例 #2
0
        protected override void OnNavigatedTo(System.Windows.Navigation.NavigationEventArgs e)
        {
            base.OnNavigatedTo(e);
            string cropIdValue = NavigationContext.QueryString["parameter"];
            cropId = Int16.Parse(cropIdValue);

            JournalRepository journalRep = new JournalRepository();
            GetJournalsByCropIdCallback handler = new GetJournalsByCropIdCallback(GetJournalsByCropIdCompleted);
            journalRep.GetJournalsByCropId(new Action<List<JournalModel>>(handler), cropId);
        }
コード例 #3
0
 public void SaveJournal(Action<int> callback, JournalModel journalModel)
 {
     ViewSaveCallback = callback;
     JournalRepository journalRepository = new JournalRepository();
     SaveJournalCallback handler = new SaveJournalCallback(SaveJournalCompleted);
     journalRepository.SaveJournal(new Action<int>(handler), journalModel);
 }