Ejemplo n.º 1
0
 //
 //入库
 //
 private void btn_Storage_Click(object sender, RoutedEventArgs e)
 {
     _ConsumOperation.Operation = Maticsoft.BLL.cls_Consumable.ConsumableOperation.Storage;  //模式为入库模式
     MCP_CS.SetControl(grd_Rec_Or_Stog, true, true);
     MCP_CS.SetControl_Button(grd_Rec_Or_Stog, true, false);
     grd_Rec_Or_Stog.DataContext    = new Maticsoft.Model.ConsumableStorage();
     dgv_ConsumableList.ItemsSource = _dataList_Storage;
     lab_title.Content = "耗材入库";
     lab_User.Content  = "入库人:";
     txb_Consumable_Barcode.IsEnabled = false;
     txb_ConsumableName.IsEnabled     = false;
 }
Ejemplo n.º 2
0
 //
 //领料
 //
 private void btn_Receive_Click(object sender, RoutedEventArgs e)
 {
     _ConsumOperation.Operation = Maticsoft.BLL.cls_Consumable.ConsumableOperation.Receive; //模式为领料模式
     MCP_CS.SetControl(grd_Rec_Or_Stog, true, true);                                        //Text控件可编辑
     MCP_CS.SetControl_Button(grd_Rec_Or_Stog, true, false);                                //按钮可编辑
     grd_Rec_Or_Stog.DataContext    = new Maticsoft.Model.ConsumableReceive();              //数据显示控件指定数据源
     dgv_ConsumableList.ItemsSource = _dataList_Receive;
     lab_title.Content = "耗材领料";
     lab_User.Content  = "领用人:";
     txb_Consumable_Barcode.IsEnabled = false;
     txb_ConsumableName.IsEnabled     = false;
 }
Ejemplo n.º 3
0
        //
        //保存
        //
        private void btn_Save_Click(object sender, RoutedEventArgs e)
        {
            int tem = _ConsumOperation.ConsumableSave(dgv_ConsumableList);

            if (tem > 0)
            {
                My_MessageBox.My_MessageBox_Message("保存成功记录 " + tem + "条!");
                _dataList_Receive.Clear();
                _dataList_Storage.Clear();
                MCP_CS.SetControl(grd_Rec_Or_Stog, false, true);
                MCP_CS.SetControl_Button(grd_Rec_Or_Stog, false, false);
            }
            else
            {
                My_MessageBox.My_MessageBox_Message("保存失败!请重试");
            }
        }