Exemplo n.º 1
0
        public static ObservableCollection <EventViewModel> dbLoad(string itemCode)
        {
            ObservableCollection <EventViewModel> eventVMList = new ObservableCollection <EventViewModel>();

            EVENT_INFO_Table_DAOManager daoManager = new EVENT_INFO_Table_DAOManager();

            daoManager.KeyColumn_ = itemCode;

            daoManager.select(DataBaseConnectManager.ConnectionFactory("myDB"));

            foreach (var item in daoManager.DAOList_)
            {
                EventViewModel evm = new SettlementEventViewModel();

                evm.setFromDAO(item);

                eventVMList.Add(evm);
            }

            return(eventVMList);
        }
Exemplo n.º 2
0
        public void dbLoad()
        {
            this.eventVMList_ = new ObservableCollection <EventViewModel>();

            EVENT_INFO_Table_DAOManager daoManager = new EVENT_INFO_Table_DAOManager();

            daoManager.KeyColumn_ = this.itemCode_;

            daoManager.select(DataBaseConnectManager.ConnectionFactory("myDB"));

            foreach (var item in daoManager.DAOList_)
            {
                EventViewModel evm = new SettlementEventViewModel();

                evm.setFromDAO(item);

                this.eventVMList_.Add(evm);
            }

            //((EventManagerView)this.view_).refereshDataContext();
        }
        public static ObservableCollection<EventViewModel> dbLoad(string itemCode)
        {
            ObservableCollection<EventViewModel> eventVMList = new ObservableCollection<EventViewModel>();

            EVENT_INFO_Table_DAOManager daoManager = new EVENT_INFO_Table_DAOManager();

            daoManager.KeyColumn_ = itemCode;

            daoManager.select(DataBaseConnectManager.ConnectionFactory("myDB"));

            foreach (var item in daoManager.DAOList_)
	        {
                EventViewModel evm = new SettlementEventViewModel();

                evm.setFromDAO(item);

                eventVMList.Add(evm);
	        }

            return eventVMList;
            
            
        }
        public void dbLoad()
        {
            this.eventVMList_ = new ObservableCollection<EventViewModel>();

            EVENT_INFO_Table_DAOManager daoManager = new EVENT_INFO_Table_DAOManager();

            daoManager.KeyColumn_ = this.itemCode_;

            daoManager.select(DataBaseConnectManager.ConnectionFactory("myDB"));

            foreach (var item in daoManager.DAOList_)
            {
                EventViewModel evm = new SettlementEventViewModel();

                evm.setFromDAO(item);

                this.eventVMList_.Add(evm);
            }

            //((EventManagerView)this.view_).refereshDataContext();

        }