Exemplo n.º 1
0
    /// <summary>
    /// 显示销售订单信息
    /// </summary>
    private void ShowInfo()
    {
        TSOutBillBB otherOutInBill = new TSOutBillBB();
        TSOutDetailBB otherOutInDetailBill = new TSOutDetailBB();

        try
        {
            string id = Request.Params["id"];
            TSOutBillData otherOutInBIllData = otherOutInBill.GetModel(Convert.ToInt32(id));
            DataSet ds = new DataSet();

            this.lblBillNo.Text = otherOutInBIllData.stockupBillNo;
            this.mark.Text = otherOutInBIllData.remark;

            //根据提货单号、销售订单号、采购合同号,查找销售订单明细
            ds = otherOutInDetailBill.GetList("tsOutBillNo = '" + otherOutInBIllData.tsOutBill + "'");

            if (ds != null && ds.Tables[0] != null && ds.Tables[0].Rows.Count > 0)
            {
                this.grid.DataSource = ds;
                this.grid.DataBind();
            }
        }
        finally
        {
            otherOutInBill.Dispose();
            otherOutInDetailBill.Dispose();
        }
    }
Exemplo n.º 2
0
    /// <summary>
    /// 绑定Grid
    /// </summary>
    protected void BindGrid()
    {
        TSOutBillBB arriveBillBB = new TSOutBillBB();

        try
        {
            string strWhere = this.StrWhere;
            DataSet ds = new DataSet();

            //到货通知单编号
            if (txtBillNo.Text.Trim() != "")
            {
                strWhere += " and  tsOutBill like '%" + txtBillNo.Text.Replace("'", "''") + "%'";
            }

            //是否收货完成
            if (this.ddlIsFinishReceive.SelectedValue != "")
            {
                if (this.ddlIsFinishReceive.SelectedValue == "02")//生成拣货单
                {
                    strWhere += " and instantState = '02'";
                }
                else//没有生成拣货单
                {
                    strWhere += " and  instantState = '01'";
                }
            }

            ds = arriveBillBB.GetList(strWhere);
            this.grid.DataSource = ds.Tables[0];
            this.grid.DataBind();

            //赋值记录条数、页面总数
            this.Label3.Text = ds.Tables[0].Rows.Count.ToString();
            this.Label2.Text = this.grid.PageCount.ToString();
            this.currPage.Text = (this.grid.PageIndex + 1).ToString();
        }
        finally
        {
            arriveBillBB.Dispose();
        }
    }
Exemplo n.º 3
0
 private void ShowArriveBillNo()
 {
     TSOutBillBB bb = new TSOutBillBB();
     lbCheckBillNo.Text =  bb.GetCurrentArriveBillNo();
 }