예제 #1
0
        private void AddDealList_Click(object sender, RoutedEventArgs e)
        {
            AddDealList ADL = new AddDealList();

            ADL.name.Text       = StockName;
            ADL.id.Text         = StockID;
            ADL.date.Text       = DateTime.Now.ToString();
            ADL.money.Text      = price.Text;
            ADL.taxrate.Text    = "1‰";
            ADL.commission.Text = "0.3‰";
            ADL.ShowDialog();
        }
예제 #2
0
        private void DList_MouseDoubleClick(object sender, MouseButtonEventArgs e)
        {
            object o = DList.SelectedItem;

            if (o == null)
            {
                return;
            }
            ItemData    item = o as ItemData;
            AddDealList adl  = new AddDealList(user.Text, item.deal);

            adl.ShowDialog();
            DealListEntity DLE   = UserPanelController.Handler().DBControllerByName(user.Text).DealListReadByDeal(item.deal);
            int            index = DList.SelectedIndex;

            DList.Items.Remove(item);
            if (DLE.id == item.id)
            {
                item = new ItemData(DLE.deal, DLE.name, DLE.id, DLE.date.ToString("yyyy/MM/dd"), DLE.type, DLE.money.ToString(), DLE.number.ToString(), DLE.taxrate.ToString(), DLE.commission.ToString(), DLE.explain, DLE.remark);
                DList.Items.Insert(index, item);
            }
            DList.UpdateLayout();
            //MessageBox.Show("暂时未提供修改功能!");
        }
예제 #3
0
 private void AddDealList_Click(object sender, RoutedEventArgs e)
 {
     AddDealList ADL = new AddDealList();
     ADL.name.Text = StockName;
     ADL.id.Text = StockID;
     ADL.date.Text = DateTime.Now.ToString();
     ADL.money.Text = price.Text;
     ADL.taxrate.Text = "1‰";
     ADL.commission.Text = "0.3‰";
     ADL.ShowDialog();
 }
예제 #4
0
 private void DList_MouseDoubleClick(object sender, MouseButtonEventArgs e)
 {
     object o = DList.SelectedItem;
     if (o == null)
         return;
     ItemData item = o as ItemData;
     AddDealList adl = new AddDealList(user.Text, item.deal);
     adl.ShowDialog();
     DealListEntity DLE = UserPanelController.Handler().DBControllerByName(user.Text).DealListReadByDeal(item.deal);
     int index = DList.SelectedIndex;
     DList.Items.Remove(item);
     if (DLE.id == item.id)
     {
         item = new ItemData(DLE.deal, DLE.name, DLE.id, DLE.date.ToString("yyyy/MM/dd"), DLE.type, DLE.money.ToString(), DLE.number.ToString(), DLE.taxrate.ToString(), DLE.commission.ToString(), DLE.explain, DLE.remark);
         DList.Items.Insert(index, item);
     }
     DList.UpdateLayout();
     //MessageBox.Show("暂时未提供修改功能!");
 }