public winSaleEdit(HCSController controller,saleproduct productSold) { InitializeComponent(); CONTROLLER = controller; soldProduct = productSold; }
private void MainWindow_Loaded(object sender, RoutedEventArgs e) { MainWin = new MainWin(); CONTROLLER = new HCSController(canUserEdit); setLanguage(); this.grdModel.DataContext = CONTROLLER; MainWin.isenglishvisible = CONTROLLER.ISENGLISHVISIBLE; MainWin.isurduvisible = CONTROLLER.ISURDUVISIBLE; }
private HCS.History getDetail(HCSController p_controller, Khata khata) { HCS.History history = new HCS.History(); Controller = p_controller; m_History = new HCS.History() { }; return history; }
private void ucIndividualUser_Loaded(object sender, RoutedEventArgs e) { if(CONTROLLER==null) { CONTROLLER = new HCSController(); } individualUser = new individualuser() { date=DateTime.Now, isenglishvisible = CONTROLLER.ISENGLISHVISIBLE, isurduvisible = CONTROLLER.ISURDUVISIBLE }; grdIndividualDetail.DataContext = individualUser; this.grdUploadImage.DataContext = individualUser; this.grdModel.DataContext = individualUser; if (CONTROLLER.ISENGLISHVISIBLE) { dgExistingIndividual.Columns[1].Visibility = Visibility.Collapsed; dgExistingIndividual.Columns[3].Visibility = Visibility.Collapsed; dgExistingIndividual.Columns[5].Visibility = Visibility.Collapsed; dgExistingIndividual.Columns[7].Visibility = Visibility.Collapsed; dgExistingIndividual.Columns[9].Visibility = Visibility.Collapsed; dgExistingIndividual.Columns[11].Visibility = Visibility.Collapsed; dgExistingIndividual.Columns[13].Visibility = Visibility.Collapsed; dgExistingIndividual.Columns[15].Visibility = Visibility.Collapsed; dgExistingIndividual.Columns[17].Visibility = Visibility.Collapsed; } if (CONTROLLER.ISURDUVISIBLE) { dgExistingIndividual.Columns[0].Visibility = Visibility.Collapsed; dgExistingIndividual.Columns[2].Visibility = Visibility.Collapsed; dgExistingIndividual.Columns[4].Visibility = Visibility.Collapsed; dgExistingIndividual.Columns[6].Visibility = Visibility.Collapsed; dgExistingIndividual.Columns[8].Visibility = Visibility.Collapsed; dgExistingIndividual.Columns[10].Visibility = Visibility.Collapsed; dgExistingIndividual.Columns[12].Visibility = Visibility.Collapsed; dgExistingIndividual.Columns[14].Visibility = Visibility.Collapsed; dgExistingIndividual.Columns[16].Visibility = Visibility.Collapsed; } // this.dgExistingIndividual.ItemsSource = CONTROLLER.INDIVIDUALUSERS; RefreshUsers(); }
private void winSaleProduct_Loaded(object sender, RoutedEventArgs e) { if (CONTROLLER == null) { CONTROLLER = new HCSController(); } saleProduct = new saleproduct() { date = DateTime.Now, isenglishvisible = CONTROLLER.ISENGLISHVISIBLE, isurduvisible = CONTROLLER.ISURDUVISIBLE }; bindProducts(); bindFeedMillUsers(); bindPurchaserTypes(); bindSalType(); this.grdSaleProduct.DataContext = CONTROLLER.SALEPRODUCT; this.grdModel.DataContext = CONTROLLER.SALEPRODUCT; }
private void ucPurchaserUser_Loaded(object sender, RoutedEventArgs e) { if(CONTROLLER==null) { CONTROLLER = new HCSController(); } Purchaser = new purchaseruser() {date=DateTime.Now, isenglishvisible = CONTROLLER.ISENGLISHVISIBLE, isurduvisible = CONTROLLER.ISURDUVISIBLE }; this.grdPurchaserDetail.DataContext = Purchaser; this.grdUploadImage.DataContext = Purchaser; this.grdModel.DataContext = Purchaser; RefreshUsers(); }
private void winPurchaseProduct_Loaded(object sender, RoutedEventArgs e) { if (CONTROLLER == null) { CONTROLLER = new HCSController(); } purchaseProduct = new purchaseproduct() { date= DateTime.Now , isenglishvisible=CONTROLLER.ISENGLISHVISIBLE,isurduvisible=CONTROLLER.ISURDUVISIBLE }; this.grdPurchaseProduct.DataContext = CONTROLLER.PURCHASEPRODUCT; this.grdModel.DataContext = CONTROLLER.PURCHASEPRODUCT; bindProducts(); bindSellerType(); bindPurchasers(); bindPurchaserType(); bindBank(); }
private void ucFeedMillUser_Loaded(object sender, RoutedEventArgs e) { if(CONTROLLER==null) { CONTROLLER = new HCSController(); } FeedMillUser = new feedmilluser() { date=DateTime.Now, isenglishvisible = CONTROLLER.ISENGLISHVISIBLE, isurduvisible = CONTROLLER.ISURDUVISIBLE }; this.grdFeedMillDetail.DataContext = FeedMillUser; this.grdUploadImage.DataContext = FeedMillUser; this.grdModel.DataContext = FeedMillUser; if (CONTROLLER.ISENGLISHVISIBLE) { dgExistingFeedMill.Columns[1].Visibility = Visibility.Collapsed; dgExistingFeedMill.Columns[3].Visibility = Visibility.Collapsed; dgExistingFeedMill.Columns[5].Visibility = Visibility.Collapsed; dgExistingFeedMill.Columns[7].Visibility = Visibility.Collapsed; dgExistingFeedMill.Columns[9].Visibility = Visibility.Collapsed; dgExistingFeedMill.Columns[11].Visibility = Visibility.Collapsed; dgExistingFeedMill.Columns[13].Visibility = Visibility.Collapsed; dgExistingFeedMill.Columns[15].Visibility = Visibility.Collapsed; } if (CONTROLLER.ISURDUVISIBLE) { dgExistingFeedMill.Columns[0].Visibility = Visibility.Collapsed; dgExistingFeedMill.Columns[2].Visibility = Visibility.Collapsed; dgExistingFeedMill.Columns[4].Visibility = Visibility.Collapsed; dgExistingFeedMill.Columns[6].Visibility = Visibility.Collapsed; dgExistingFeedMill.Columns[8].Visibility = Visibility.Collapsed; dgExistingFeedMill.Columns[10].Visibility = Visibility.Collapsed; dgExistingFeedMill.Columns[12].Visibility = Visibility.Collapsed; dgExistingFeedMill.Columns[14].Visibility = Visibility.Collapsed; } RefreshUsers(); }
private void winSaleEdit_Loaded(object sender, RoutedEventArgs e) { if(CONTROLLER==null) { CONTROLLER = new HCSController(); } if(soldProduct==null ) { soldProduct = new saleproduct() { date = DateTime.Now, isenglishvisible = CONTROLLER.ISENGLISHVISIBLE, isurduvisible = CONTROLLER.ISURDUVISIBLE }; } bindProducts(); bindFeedMillUsers(); this.grdSaleProduct.DataContext = soldProduct; this.grdModel.DataContext = soldProduct; }
private void ucOtherHistory_Loaded(object sender, RoutedEventArgs e) { HISTORY = new ObservableCollection<OtherKhata>(); if (CONTROLLER == null) { CONTROLLER = new HCSController(); } this.grdModel.DataContext = CONTROLLER; this.grdOtherHistory.DataContext = CONTROLLER; dgOtherHistory.ItemsSource = HISTORY; if (CONTROLLER.ISENGLISHVISIBLE) { dgOtherHistory.Columns[1].Visibility = Visibility.Collapsed; dgOtherHistory.Columns[3].Visibility = Visibility.Collapsed; dgOtherHistory.Columns[5].Visibility = Visibility.Collapsed; dgOtherHistory.Columns[7].Visibility = Visibility.Collapsed; dgOtherHistory.Columns[9].Visibility = Visibility.Collapsed; dgOtherHistory.Columns[11].Visibility = Visibility.Collapsed; dgOtherHistory.Columns[13].Visibility = Visibility.Collapsed; dgOtherHistory.Columns[15].Visibility = Visibility.Collapsed; dgOtherHistory.Columns[17].Visibility = Visibility.Collapsed; } if (CONTROLLER.ISURDUVISIBLE) { dgOtherHistory.Columns[0].Visibility = Visibility.Collapsed; dgOtherHistory.Columns[2].Visibility = Visibility.Collapsed; dgOtherHistory.Columns[4].Visibility = Visibility.Collapsed; dgOtherHistory.Columns[6].Visibility = Visibility.Collapsed; dgOtherHistory.Columns[8].Visibility = Visibility.Collapsed; dgOtherHistory.Columns[10].Visibility = Visibility.Collapsed; dgOtherHistory.Columns[12].Visibility = Visibility.Collapsed; dgOtherHistory.Columns[14].Visibility = Visibility.Collapsed; dgOtherHistory.Columns[16].Visibility = Visibility.Collapsed; } RefreshUsers(); bindSellerTypes(); }
private void ucFeedMillHistory_Loaded(object sender, RoutedEventArgs e) { if(CONTROLLER==null) { CONTROLLER = new HCSController(); } this.grdModel.DataContext = CONTROLLER; this.grdFeedMillHistory.DataContext = CONTROLLER; FEEDMILLHISTORY = new ObservableCollection<saleproduct>(); if (CONTROLLER.ISENGLISHVISIBLE) { dgSalesHistory.Columns[1].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[3].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[5].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[7].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[9].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[11].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[13].Visibility = Visibility.Collapsed; } if (CONTROLLER.ISURDUVISIBLE) { dgSalesHistory.Columns[0].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[2].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[4].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[6].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[8].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[10].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[12].Visibility = Visibility.Collapsed; } RefreshUsers(); bindFeedMill(); }
public ucPurchaseProduct(HCSController controller) { InitializeComponent(); CONTROLLER = controller; }
public ucSellerHistory(HCSController controller) { InitializeComponent(); CONTROLLER = controller; }
private void ucSellerHistory_Loaded(object sender, RoutedEventArgs e) { HISTORY = new ObservableCollection<Khata>(); if (CONTROLLER == null) { CONTROLLER = new HCSController(); } this.grdModel.DataContext = CONTROLLER; this.grdSellerHistory.DataContext = CONTROLLER; //PP_SELLERHSITORY = new ObservableCollection<purchaseproduct>(); //SP_SALEHISTORY = new ObservableCollection<saleproduct>(); //HISTORY = new ObservableCollection<HCS.History>(); dgSalesHistory.ItemsSource = HISTORY; if (CONTROLLER.ISENGLISHVISIBLE) { dgSalesHistory.Columns[1].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[3].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[5].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[7].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[9].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[11].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[13].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[15].Visibility = Visibility.Collapsed; } if (CONTROLLER.ISURDUVISIBLE) { dgSalesHistory.Columns[0].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[2].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[4].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[6].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[8].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[10].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[12].Visibility = Visibility.Collapsed; dgSalesHistory.Columns[14].Visibility = Visibility.Collapsed; } RefreshUsers(); bindSellerTypes(); }
public winSaleProductPopUp(HCSController controller) { InitializeComponent(); CONTROLLER = controller; }
public ucIndividualUser(HCSController controller) { InitializeComponent(); CONTROLLER = controller; }
public ucBankUser(HCSController controller) { InitializeComponent(); CONTROLLER = controller; }
public DetailedHistory(HCSController p_controller, Khata khata) { InitializeComponent(); HISTORY = getDetail(p_controller, khata); // grdDetailHistory.DataContext = HISTORY; }
public OtherHistory(HCSController p_controller) { InitializeComponent(); m_controller = p_controller; }