Beispiel #1
0
        private void btnDepot_Click(object sender, EventArgs e)
        {
            FormDepotType form = new FormDepotType();

            if (form.ShowDialog() == DialogResult.OK)
            {
                txtDepot.Tag  = form.SelectedDepotType.仓库编码;
                txtDepot.Text = form.SelectedDepotType.仓库名称;
            }
        }
Beispiel #2
0
        private void btnFindMaterialType_Click(object sender, EventArgs e)
        {
            FormDepotType form = form = new FormDepotType();

            if (form.ShowDialog() == DialogResult.OK)
            {
                txtMaterialType.Text = form.SelectedDepotType.仓库名称;
                txtMaterialType.Tag  = form.SelectedDepotType.仓库编码;
                cmbGoodsStatus.Text  = "正常";
            }
        }
        private void btnFindMaterialType_Click(object sender, EventArgs e)
        {
            if (lblBillStatus.Text != OrdinaryInDepotBillStatus.新建单据.ToString())
            {
                return;
            }

            FormDepotType form = new FormDepotType();

            if (form.ShowDialog() == DialogResult.OK)
            {
                txtMaterialType.Text = form.SelectedDepotType.仓库名称;
                txtMaterialType.Tag  = form.SelectedDepotType.仓库编码;
            }
        }
        private void btnFindDepot_Click(object sender, EventArgs e)
        {
            if (m_operateMode == CE_BusinessOperateMode.仓库核实)
            {
                FormDepotType form = new FormDepotType();

                if (form.ShowDialog() == DialogResult.OK)
                {
                    txtMaterialType.Text = form.SelectedDepotType.仓库名称;
                    txtMaterialType.Tag  = form.SelectedDepotType.仓库编码;
                }
            }
            else
            {
                MessageDialog.ShowPromptMessage("只有仓库管理员才可以使用此功能");
            }
        }
        private void 修正材料类别ToolStripMenuItem_Click(object sender, EventArgs e)
        {
            if (!CheckSelectedRow())
            {
                return;
            }

            if (dataGridView1.SelectedRows[0].Cells["单据状态"].Value.ToString() != OrdinaryInDepotBillStatus.等待入库.ToString())
            {
                MessageDialog.ShowPromptMessage("请选择等待入库的记录后再进行此操作!");
                return;
            }

            if (MessageDialog.ShowEnquiryMessage("此操作将会修改此单据所有物品在计划价格表中的材料类别,是否继续?") == DialogResult.No)
            {
                return;
            }

            FormDepotType form   = new FormDepotType();
            string        billNo = txtOrderFormNumber.Text;

            if (form.ShowDialog() == DialogResult.OK)
            {
                txtMaterialType.Text = form.SelectedDepotType.仓库名称;
                txtMaterialType.Tag  = form.SelectedDepotType.仓库编码;

                if (!m_billServer.UpdateGoodsType(txtBill_ID.Text, form.SelectedDepotType.仓库编码, out m_queryResult, out m_error))
                {
                    MessageDialog.ShowErrorMessage(m_error);
                }
                else
                {
                    RefreshDataGridView(m_queryResult);
                    PositioningRecord(billNo);
                }
            }
        }