示例#1
0
 public SellingPriceManagerImpl(AddSellingPrice addSellingPrice)
 {
     this.addSellingPrice = addSellingPrice;
     dao = SellingPriceDao.getInstance();
 }
示例#2
0
 public static void sellingPriceForItemAndMode(MSComboBox comboBox, int itemId, String mode, AddSellingPrice addSellingPrice)
 {
     try {
         DataTable dataTable = new DataTable();
         dataTable.Columns.Add("ID", typeof(int));
         dataTable.Columns.Add("price", typeof(String));
         List <SellingPrice> list = sellingPriceManagerImpl.getSellingPriceByItemAndMode(itemId, mode);
         foreach (SellingPrice sellingPrice in list)
         {
             dataTable.Rows.Add(sellingPrice.Id, sellingPrice.Price.ToString("#,##0.00"));
         }
         if (Session.Permission["canAddSellingPrice"] == 1)
         {
             comboBox.AddLinkWindow   = addSellingPrice;
             addSellingPrice.Mode     = mode;
             addSellingPrice.ItemId   = itemId;
             addSellingPrice.ComboBox = comboBox;
         }
         else
         {
             comboBox.AddLinkWindow = null;
         }
         int index = dataTable.Rows.Count - 1;
         comboBox.OptionGroup = dataTable;
         if (index > -1)
         {
             comboBox.SelectedIndex = index;
         }
     } catch (Exception) {
     }
 }
示例#3
0
 public SellingPriceManagerControler(AddSellingPrice addSellingPrice)
 {
     this.addSellingPrice    = addSellingPrice;
     sellingPriceManagerImpl = new SellingPriceManagerImpl(addSellingPrice);
 }