当前位置: 首页>>代码示例>>C#>>正文


C# Business.SCommBB类代码示例

本文整理汇总了C#中HS.Business.SCommBB的典型用法代码示例。如果您正苦于以下问题:C# SCommBB类的具体用法?C# SCommBB怎么用?C# SCommBB使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


SCommBB类属于HS.Business命名空间,在下文中一共展示了SCommBB类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: BindGrid

    /// <summary>
    /// 绑定Grid
    /// </summary>
    protected void BindGrid()
    {
        SCommBB commBB = new SCommBB();
        DataSet ds = new DataSet();

        try
        {
            string arriveBillNo = "", FinanceBillNo = "", Material = "", custno = "";
            arriveBillNo = this.tbArriveBillNo.Text.Trim();
            FinanceBillNo = this.tbFinanceBillNo.Text.Trim();
            Material = this.tbMaterial.Text.Trim();
            custno = this.tbCustNO.Text.Trim();
            if (!Checkbox.Checked)
            {
                ds = commBB.Query("exec Proc_GetSapInStockArriveBillListNew '" + arriveBillNo + "','" + FinanceBillNo + "','" + Material + "','" + custno + "'");//查询的是没有同步的
            }
            else
            {
                //[Proc_GetSapInStockArriveBillListNewAreadyInstocked] 这个是获取已经入库的
                ds = commBB.Query("exec Proc_GetSapInStockArriveBillListNewAreadyInstocked '" + arriveBillNo + "','" + FinanceBillNo + "','" + Material + "','" + custno + "'");//查询的是没有同步的
            }

            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
        {
            commBB.Dispose();
        }
    }
开发者ID:wanghouxian2015,项目名称:GMWJGit,代码行数:38,代码来源:SapInStock.aspx.cs

示例2: BindGrid

    /// <summary>
    /// 绑定库存汇总列表
    /// </summary>
    protected void BindGrid()
    {
        SCommBB commBB = new SCommBB();

        try
        {
            DataSet ds = new DataSet();

            ds = commBB.Query("exec proc_StockTotalReportNew '" + this.ddlWare.SelectedValue + "','"
                + this.ddlWareLocater.SelectedValue + "','" + this.tbFinanceBillNo.Text.Trim().Replace("'", "''").Trim() + "','"
                + this.tbMaterial.Text.Trim().Replace("'", "''").Trim() + "','" + this.ddlIsOutStocking.SelectedValue + "','" + this.ddlCheckResult.SelectedValue + "'");

            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
        {
            commBB.Dispose();
        }
    }
开发者ID:wanghouxian2015,项目名称:GMWJGit,代码行数:28,代码来源:StockReport.aspx.cs

示例3: BindGrid

    protected void BindGrid()
    {
        SCommBB commBB = new SCommBB();
        DataSet ds = new DataSet();

        try
        {
            string arriveBillNo = "", FinanceBillNo = "", Material = "", custno = "";
            arriveBillNo = this.tbarrivebillNo.Text.ToString();
            FinanceBillNo = "";
            Material = this.tbMaterial.Text.Trim();

            ds = commBB.Query("exec [Proc_GetSapOtherInStockArriveBillListNew] '" + arriveBillNo + "','" + FinanceBillNo + "','" + Material + "','" + custno + "'");

            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
        {
            commBB.Dispose();
        }
    }
开发者ID:wanghouxian2015,项目名称:GMWJGit,代码行数:27,代码来源:OtherOutInSAPIN.aspx.cs

示例4: Page_Load

    protected void Page_Load(object sender, EventArgs e)
    {
        if (!Page.IsPostBack)
        {
            if (Request.Params["functionNo"] != null && Request.Params["functionNo"].Trim() != "")
            {
                this.FunctionNo = Request.Params["functionNo"];
            }
        }

        if (this.SET_SQL.Value != "")
        {
            this.SET_SQL.Value = this.SET_SQL.Value.Substring(0, this.SET_SQL.Value.Length - 1);
            SCommBB commBB = new SCommBB();
            try
            {
                string[] updateSqls = this.SET_SQL.Value.Split(';');
                foreach (string updateSql in updateSqls)
                {
                    commBB.ExecuteSql(updateSql);
                }
            }
            finally
            {
                commBB.Dispose();
            }
            this.SET_SQL.Value = "";
        }

        this.ShowPullInfo(this.FunctionNo);
    }
开发者ID:wanghouxian2015,项目名称:GMWJGit,代码行数:31,代码来源:WFunctionStepPull.aspx.cs

示例5: BindGrid

    /// <summary>
    /// 绑定Grid
    /// </summary>
    protected void BindGrid()
    {
        SCommBB commBB = new SCommBB();
        DataSet ds = new DataSet();

        try
        {
            //ds = commBB.Query("exec Proc_GetSapOutStockSaleBillList '" + this.tbAbsEntry.Text.Trim().Replace("'", "''")
            //    + "','" + this.tbSaleBillNo.Text.Trim().Replace("'", "''") + "','"
            //    + this.tbMaterial.Text.Trim().Replace("'", "''") + "'");
            string AbsEntry = "";
            string SaleBillNo = this.tbSaleBillNo.Text.Trim();
            string material = this.tbMaterial.Text.Trim();
            string invoiceNo = this.tbinvoiceNo.Text;
            string custNo = this.tbcustNo.Text;
            //ds = commBB.Query("exec [dbo].[Proc_ newGetSapOutStockSaleBillList] '" + this.tbAbsEntry.Text.Trim().Replace("'", "''")
            //    + "','" + this.tbSaleBillNo.Text.Trim().Replace("'", "''") + "','"
            //    + "','" + this.tbMaterial.Text.Trim().Replace("'", "''") + "','"
            //    + this.tbinvoiceNo.Text.Trim().Replace("'", "''") + "'");

            ds = commBB.Query("exec [dbo].[Proc_GetSapOutStockSaleBillListNew] '" + AbsEntry + "','" + SaleBillNo + "','" + material + "','" + invoiceNo + "','"+custNo+"'");
            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
        {
            commBB.Dispose();
        }
    }
开发者ID:wanghouxian2015,项目名称:GMWJGit,代码行数:37,代码来源:SapOutStock.aspx.cs

示例6: ShowInfo

 /// <summary>
 /// չʾ����
 /// </summary>
 /// <param name="id">��¼Id</param>
 private void ShowInfo(int id)
 {
     SFileBB fileBB = new SFileBB();
     LMessageBB messageBB = new LMessageBB();
     vLMessageData model = new vLMessageData();
     try
     {
         model = messageBB.GetVModel(id);
         this.title.Text = model.title;
         this.content.Text = model.content;
         this.fileId.Text = fileBB.GetDownBatchFileNm(model.fileId);
         this.sort.Text = model.sortNm;
         this.author.Text = model.author;
     }
     finally
     {
         fileBB.Dispose();
         messageBB.Dispose();
     }
     //�����Ѷ��˴�
     SCommBB commBB = new SCommBB();
     try
     {
         string strSql = "select count(distinct empId) from LMessageReaded where messageId=" + id.ToString();
         this.readedEmpCount.Text = commBB.ExecuteScalar(strSql).ToString();
     }
     finally
     {
         commBB.Dispose();
     }
 }
开发者ID:wanghouxian2015,项目名称:GMWJGit,代码行数:35,代码来源:LMessageShow.aspx.cs

示例7: btnCommit_Click

    protected void btnCommit_Click(object sender, EventArgs e)
    {
        //判断上传控件是否为空
        if (this.FileInsertImg.PostedFile.FileName == "")
        {
            this.ClientScript.RegisterStartupScript(this.GetType(), "alert", "alert(\"请首先选择一个图片文件!\");", true);
            return;
        }
        this.btnCommit.Enabled = false;

        //判断文件格式(0无限制、1图片)
        FileInfo file = new FileInfo(this.FileInsertImg.PostedFile.FileName);
        string extension = file.Extension;
        SCommBB commBB = new SCommBB();
        try
        {
            //查看文件格式是否存在与系统表“图片文件格式”中
            if (commBB.Query("select 1 from SImageFileType where fileExtension='" + extension + "'").Tables[0].Rows.Count == 0)
            {
                this.ClientScript.RegisterStartupScript(this.GetType(), "alert", "alert(\"本次附件上传要求为图片格式文件,请重新选择!\");", true);
                this.btnCommit.Enabled = true;
                return;
            }
        }
        finally
        {
            commBB.Dispose();
        }

        string fileId = "";
        string insertImgPath = "";
        if (this.FileId == "")
        {
            //获取文件名称
            string fileNm = DateTime.Now.ToString("yyyyMMddHHmmss");
            Random ro = new Random();
            fileNm += ro.Next(1000, 9999).ToString() + extension;
            //上传文件到指定目录
            this.FileInsertImg.PostedFile.SaveAs(System.AppDomain.CurrentDomain.SetupInformation.ApplicationBase + "\\Images\\UpImg\\" + fileNm);

            string level = "";
            for (int i = 0; i < Convert.ToInt32(DirectLevel); i++)
            {
                level += "../";
            }
            insertImgPath = level + "Images/UpImg/" + fileNm;
        }
        else
        {
            SFileData fileData = this.UpImg(this.FileInsertImg.PostedFile);
            fileId = fileData.fileId.ToString();
            insertImgPath = fileData.preFileNm;
        }

        this.btnCommit.Enabled = true;

        this.ClientScript.RegisterStartupScript(this.GetType(), "returnParent", "returnParent('" + fileId + "','" + insertImgPath + "');", true);
    }
开发者ID:wanghouxian2015,项目名称:GMWJGit,代码行数:58,代码来源:SImageUp.aspx.cs

示例8: btnInsertImg_Click

    /// <summary>
    /// ���ͼƬ
    /// </summary>
    /// <param name="sender"></param>
    /// <param name="e"></param>
    protected void btnInsertImg_Click(object sender, EventArgs e)
    {
        //�ж��ϴ��ؼ��Ƿ�Ϊ��
        if (this.FileInsertImg.PostedFile.FileName == "")
        {
            this.ClientScript.RegisterStartupScript(this.GetType(), "alert", "alert(\"������ѡ��һ��ͼƬ�ļ�!\");", true);
            return;
        }
        this.btnInsertImg.Enabled = false;

        //�ж��ļ���ʽ��0�����ơ�1ͼƬ��
        FileInfo file = new FileInfo(this.FileInsertImg.PostedFile.FileName);
        string extension = file.Extension;
        SCommBB commBB = new SCommBB();
        try
        {
            //�鿴�ļ���ʽ�Ƿ������ϵͳ���ͼƬ�ļ���ʽ����
            if (commBB.Query("select 1 from SImageFileType where fileExtension='" + extension + "'").Tables[0].Rows.Count == 0)
            {
                this.ClientScript.RegisterStartupScript(this.GetType(), "alert", "alert(\"���θ����ϴ�Ҫ��ΪͼƬ��ʽ�ļ���������ѡ��!\");", true);
                this.btnInsertImg.Enabled = true;
                return;
            }
        }
        finally
        {
            commBB.Dispose();
        }

        //��ȡ�ļ�����
        string fileNm = DateTime.Now.ToString("yyyyMMddHHmmss");
        Random ro = new Random();
        fileNm += ro.Next(1000, 9999).ToString() + extension;
        //�ϴ��ļ���ָ��Ŀ¼
        this.FileInsertImg.PostedFile.SaveAs(System.AppDomain.CurrentDomain.SetupInformation.ApplicationBase + "\\Images\\UpImg\\" + fileNm);

        //�ж�ͼƬ�ߴ磬�����ʾΪ400/300
        System.Drawing.Image image = System.Drawing.Image.FromFile(System.AppDomain.CurrentDomain.SetupInformation.ApplicationBase + "\\Images\\UpImg\\" + fileNm);

        if (image.Width > 400)
        {
            this.content.Value += "<img alt=\"\" src=\"../../../Images/UpImg/" + fileNm + "\" width=\"400\" height=\"" + 400 * image.Height / image.Width + "\" />";
        }
        else if (image.Height > 300)
        {
            this.content.Value += "<img alt=\"\" src=\"../../../Images/UpImg/" + fileNm + "\" width=\"" + 300 * image.Width / image.Height + "\" height=\"300\" />";
        }
        else
        {
            this.content.Value += "<img alt=\"\" src=\"../../../Images/UpImg/" + fileNm + "\" />";
        }

        this.btnInsertImg.Enabled = true;
    }
开发者ID:wanghouxian2015,项目名称:GMWJGit,代码行数:59,代码来源:LMessage.aspx.cs

示例9: btnSave_Click

    protected void btnSave_Click(object sender, EventArgs e)
    {
        PRolePermissionsData rolePermissionsData = new PRolePermissionsData();
        SCommBB commBB = new SCommBB();
        PRolePermissionsBB rolePermissionsBB = new PRolePermissionsBB();
        try
        {
            //删除当前角色所有权限
            rolePermissionsBB.DeleteRecordByRole(this.RoleId, 2);

            //保存权限
            string strPermissions = "";
            CheckBox checkBox = new CheckBox();
            foreach (DataListItem item in this.DataList1.Items)
            {
                //获取ItemoNo
                Label label = (Label)item.FindControl("itemNo");
                string itemNo = label.Text;
                if (itemNo.IndexOf('-') >= 0)
                {
                    itemNo = itemNo.Substring(itemNo.LastIndexOf('-') + 1);
                }

                foreach (System.Web.UI.Control control in item.Controls)
                {
                    if (control.GetType() == checkBox.GetType())
                    {
                        if (((CheckBox)control).Checked == true)
                        {
                            strPermissions += itemNo + "," + ((CheckBox)control).ToolTip + ",0|";
                        }
                    }
                }
            }
            //保存权限
            commBB.ExecuteSql("exec sys_BatchSavePermissions " + this.RoleId.ToString() + ",'" + strPermissions.Remove(strPermissions.Length - 1) + "'");
        }
        catch (Exception ex)
        {
            this.ClientScript.RegisterStartupScript(this.GetType(), "ShowErr", "ShowErr(\"" + Server.UrlEncode(ex.Message) + "\",3);", true);
            return;
        }
        finally
        {
            commBB.Dispose();
            rolePermissionsBB.Dispose();
        }

        this.ClientScript.RegisterStartupScript(this.GetType(), "alert", "alert('保存成功!');", true);
    }
开发者ID:wanghouxian2015,项目名称:GMWJGit,代码行数:50,代码来源:PRolePermissions.aspx.cs

示例10: BindGrid

 private void BindGrid()
 {
     string billNo = this.tbBillNo.Text.ToString();
     string material = this.tbMaterial.Text.ToString();
     string saleBillNo = this.tbsaleBillNo.Text.ToString();
     SCommBB commBB = new SCommBB();
     try
     {
         this.gridSaleBill.DataSource = commBB.Query("exec [dbo].[pro_GetoutSaleDetailShow] '" + material + "','" + billNo + "','" + saleBillNo + "'").Tables[0];
         this.gridSaleBill.DataBind();
     }
     catch { }
     finally
     {
         commBB.Dispose();
     }
 }
开发者ID:wanghouxian2015,项目名称:GMWJGit,代码行数:17,代码来源:outStockBillShow.aspx.cs

示例11: BindGrid

    private void BindGrid()
    {
        SCommBB commbb = new SCommBB();
        try
        {
            string material = this.tbMaterial.Text.ToString();
            string arriveBillNo = this.tbBillNo.Text.ToString();
            string financeBillNo = this.tbfinanceBillNo.Text.ToString();

            this.gridSaleBill.DataSource = commbb.Query(" exec [dbo].[pro_GetinSaleDetailShow] '" + material + "','" + arriveBillNo + "','" + financeBillNo + "'").Tables[0];
            this.gridSaleBill.DataBind();
        }
        catch { }
        finally
        {
            commbb.Dispose();
        }
    }
开发者ID:wanghouxian2015,项目名称:GMWJGit,代码行数:18,代码来源:inStockBillShow.aspx.cs

示例12: ShowInfo

 private void ShowInfo()
 {
     string id = Request.Params["id"];
     string sql = " select  stockUpBillNo,saleBillNo ,materialNo from vCStockUpDetail  where id ='"+id+"'";
     SCommBB commBB = new SCommBB();
     try
     {
         DataTable dt = commBB.Query(sql).Tables[0];
         for (int i = 0; i < dt.Rows.Count; i++)
         {
             this.tbBillNo.Text = dt.Rows[i][0].ToString();
             this.tbsaleBillNo.Text = dt.Rows[i][1].ToString();
             this.tbMaterial.Text = dt.Rows[i][2].ToString();
         }
     }
     catch { }
     finally
     {
         commBB.Dispose();
     }
 }
开发者ID:wanghouxian2015,项目名称:GMWJGit,代码行数:21,代码来源:outStockBillShow.aspx.cs

示例13: btnData_Click

    /// <summary>
    /// 获取SAP数据
    /// </summary>
    /// <param name="sender"></param>
    /// <param name="e"></param>
    protected void btnData_Click(object sender, EventArgs e)
    {
        SCommBB commBB = new SCommBB();

        try
        {
            //获取SAP到货单、销售订单
            commBB.ExecuteSql("exec up_SAP_GetNewData");

            this.ClientScript.RegisterStartupScript(this.GetType(), "alert", "alert('同步SAP到货\\拣货数据成功!');", true);
        }
        catch (Exception ex)
        {
            this.ClientScript.RegisterStartupScript(this.GetType(), "ShowErr", "ShowErr(\"" + Server.UrlEncode(ex.Message) + "\",3);", true);
            return;
        }
        finally
        {
            commBB.Dispose();
        }
    }
开发者ID:wanghouxian2015,项目名称:GMWJGit,代码行数:26,代码来源:SAPDataPhase.aspx.cs

示例14: btnChangeBox_Click

    /// <summary>
    /// 修改关联的托盘号
    /// </summary>
    /// <param name="sender"></param>
    /// <param name="e"></param>
    protected void btnChangeBox_Click(object sender, EventArgs e)
    {
        if (txtBoxNo.Text.ToString() == "")
        {
            this.ClientScript.RegisterStartupScript(this.GetType(), "alert", "alert(\"箱号不能为空!\");", true);
            return;
        }
        if (txtPalletNewNo.Text.ToString()=="")
        {
            this.ClientScript.RegisterStartupScript(this.GetType(), "alert", "alert(\"托盘号不能为空!\");", true);
            return;
        }
        if (txtBoxNo.Text.ToString().ToUpper().Substring(0, 1) != "X" || txtPalletNewNo.Text.ToString().ToUpper().Substring(0,1)!="T")
        {
            this.ClientScript.RegisterStartupScript(this.GetType(), "alert", "alert(\"箱号或是托盘号不正确!\");", true);
            return;
        }

        SCommBB comm = new SCommBB();
        try
        {
            comm.ExecuteSql("Update BarrangeBillBox set PalletNo = '" + txtPalletNewNo.Text.Trim().ToUpper() + "' where boxNo = '" + txtBoxNo.Text.Trim().ToUpper() + "'");

            this.ClientScript.RegisterStartupScript(this.GetType(), "alert", "alert(\"更新托盘号成功 箱号 " + txtBoxNo.Text.Trim().ToUpper() + " 更新后的托盘是" + txtPalletNewNo.Text.Trim().ToUpper() + "!\");", true);

        }
        catch (Exception ee)
        {

            this.ClientScript.RegisterStartupScript(this.GetType(), "alert", "alert(\"更新托盘号失败 " + ee.Message + "!\");", true);

        }
        finally
        {
            txtBoxNo.Text = "";
            txtPalletNewNo.Text = "";
            comm.Dispose();

        }
    }
开发者ID:wanghouxian2015,项目名称:GMWJGit,代码行数:45,代码来源:TestCreateTask.aspx.cs

示例15: BindGrid

    /// <summary>
    /// 绑定集货区库位使用情况列表
    /// </summary>
    protected void BindGrid()
    {
        SCommBB commBB = new SCommBB();

        try
        {
            DataSet ds = new DataSet();

            ds = commBB.Query("exec Proc_GetJHQWareInfo '" + this.tbCustNo.Text.Trim().Replace("'", "''") + "'");

            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
        {
            commBB.Dispose();
        }
    }
开发者ID:wanghouxian2015,项目名称:GMWJGit,代码行数:26,代码来源:JHQWareReport.aspx.cs


注:本文中的HS.Business.SCommBB类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。