终端一体化运控平台
No puede seleccionar más de 25 temas Los temas deben comenzar con una letra o número, pueden incluir guiones ('-') y pueden tener hasta 35 caracteres de largo.
 
 
 

62 líneas
1.9 KiB

  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6. namespace BPASmartClient.Academy.ViewModel
  7. {
  8. internal class HistoryChartViewModel : NotifyBase
  9. {
  10. public HistoryChartViewModel()
  11. {
  12. Sqlite.GetInstance.FindDateList(DateTime.Now);
  13. Select = new BPARelayCommand(() =>
  14. {
  15. Sqlite.GetInstance.FindDateList(SelectTime);
  16. //HistorySqlite.GetInstance.DateString = SelectTime.ToString("yyyy-MM-dd");
  17. //HistorySqlite.GetInstance.FindDateList();
  18. });
  19. FindProductCommand = new BPARelayCommand(() =>
  20. {
  21. Sqlite.GetInstance.FindName(ProductNum);
  22. });
  23. }
  24. public ObservableCollection<RecipeChart> RecipeCharts { get; set; } = Sqlite.GetInstance.recipeCharts;
  25. private DateTime _selectTime = DateTime.Now;
  26. public DateTime SelectTime
  27. {
  28. get { return _selectTime; }
  29. set { _selectTime = value; OnPropertyChanged(); }
  30. }
  31. public string ProductNum { get { return _mProductNum; } set { _mProductNum = value; OnPropertyChanged(); } }
  32. private string _mProductNum;
  33. public BPARelayCommand Select { get; set; }
  34. public BPARelayCommand FindProductCommand { get; set; }
  35. }
  36. public class RecipeChart : NotifyBase
  37. {
  38. public int Num { get { return _mNum; } set { _mNum = value; OnPropertyChanged(); } }
  39. private int _mNum;
  40. public string Name { get { return _mName; } set { _mName = value; OnPropertyChanged(); } }
  41. private string _mName;
  42. public DateTime CreateTime { get { return _mCreateTime; } set { _mCreateTime = value; OnPropertyChanged(); } }
  43. private DateTime _mCreateTime;
  44. public string Id { get { return _id; } set { _id = value; OnPropertyChanged(); } }
  45. private string _id;
  46. }
  47. }