Example #1
0
    public int Insert_Employee_Customer_Data(_Utility utl, string typ)
    {
        int x = 0;

        if (typ == "I")
        {
            x = _cs.ExecuteQuery("insert into TBL_EMPLOYEE_CUSTOMER_MST(ECM_ECAT_CD,ECM_UPR_ID,ECM_NAME,ECM_PHNO,ECM_ADD,ECM_EMAIL,ECM_PWD,ECM_BANK_DETAILS,ECM_PHOTO) values('" + utl.User_Type + "','" + utl.UpperId + "','" + utl.Name + "','" + utl.Phone + "','" + utl.Address + "','" + utl.Email + "','" + utl.Password + "','" + utl.BankDetails + "','" + utl.Photo + "')");
        }
        else if (typ == "U")
        {
            x = _cs.ExecuteQuery("UPDATE TBL_EMPLOYEE_CUSTOMER_MST SET ECM_ECAT_CD='" + utl.User_Type + "',ECM_UPR_ID='" + utl.UpperId + "',ECM_NAME='" + utl.Name + "',ECM_PHNO='" + utl.Phone + "',ECM_ADD='" + utl.Address + "',ECM_EMAIL='" + utl.Email + "',ECM_PWD='" + utl.Password + "',ECM_BANK_DETAILS='" + utl.BankDetails + "',ECM_PHOTO='" + utl.Photo + "' WHERE ECM_CODE='" + utl.Code + "'");
        }
        return(x);
    }
Example #2
0
    public string _Insert_CapitalAmount(_Utility utl)
    {
        string re = "";

        if (_cs.ExecuteQuery("insert into TBL_CAPITAL_INVESTMENT_MST(CAP_DT,CAP_VEN_CD,CAP_DESC,CAP_AMOUNT) values('" + utl.Date + "','" + utl.Emp_Cust_Code + "','" + utl.Purpose + "','" + utl.Amount + "')") == 1)
        {
            re = "Success";
        }
        else
        {
            re = "Error";
        }
        return(re);
    }
Example #3
0
    public string _Insert_Expenses(_Utility utl)
    {
        string re = "";

        if (_cs.ExecuteQuery("insert into TBL_GLUE_EXPENSES_MST(EXP_DT,EXP_VEN_CODE,EXP_PURPOSE,EXP_AMOUNT) values('" + utl.Date + "','" + utl.Emp_Cust_Code + "','" + utl.Purpose + "','" + utl.Amount + "')") == 1)
        {
            re = "Success";
        }
        else
        {
            re = "Error";
        }
        return(re);
    }
Example #4
0
    public string _Insert_Payment(_Utility utl)
    {
        string re = "";

        if (_cs.ExecuteQuery("insert into TBL_GLUE_VENDOR_PAYMENT_INF(PAY_DT,PAY_VEN_CD,PAY_AMOUNT) values('" + utl.Date + "','" + utl.Emp_Cust_Code + "','" + utl.Amount + "')") == 1)
        {
            re = "Success";
        }
        else
        {
            re = "Error";
        }
        return(re);
    }
Example #5
0
    public string _Inser_Sale(_Utility utl)
    {
        string re = "";

        if (_cs.ExecuteQuery("insert into TBL_GLUE_SALE_MST(SAL_DT,SAL_VENDOR_CD,SAL_PRD_CD,SAL_QNTY,SAL_PRICE_PC,SAL_TOT_AMT,SAL_TYPE,SAL_REMARKS) values('" + utl.Date + "','" + utl.Emp_Cust_Code + "','" + utl.Product_Code + "','" + utl.Product_Qnty + "','" + utl.Product_Price + "','" + utl.Amount + "','" + utl.Type + "','" + utl.Remarks + "')") == 1)
        {
            re = "Success";
        }
        else
        {
            re = "Error";
        }
        return(re);
    }
 protected void btnSave_Click(object sender, EventArgs e)
 {
     //if (_cs.ExecuteQuery("insert into TBL_GLEU_SALE_MST(SAL_DT,PUR_VENDOR_CD,PUR_PRD_CD,SAL_QNTY,SAL_PRICE_PC,SAL_TOT_AMT) values('" + utl.Date + "','" + utl.Emp_Cust_Code + "','" + utl.Product_Code + "','" + utl.Product_Price + "','" + utl.Amount + "')") == 1)
     _utl.Date          = txtDate.Text;
     _utl.Emp_Cust_Code = ddlVendorName.SelectedValue.ToString();
     _utl.Amount        = txtTotal.Text;
     if (_utl._Insert_Payment(_utl) == "Success")
     {
         DataSet ds = new _Utility().Get_Employee_Customer_Data_Individual(_utl.Emp_Cust_Code);
         Sms._Vendor_Payment(ddlVendorName.SelectedItem.Text.ToString(), ds.Tables[0].Rows[0]["ECM_PHNO"].ToString(), txtTotal.Text, ds.Tables[0].Rows[0]["BALANCE_AMT"].ToString());
         liMsg.Visible   = true;
         liMsg.InnerHtml = " <span class='bg-red'>Payment Received Successfully</span>";
         Reset();
     }
 }
Example #7
0
    public string _Update_Stock_Approve(_Utility utl)
    {
        string re = "";

        //[dbo].[TBL_GLUE_PURCHASE_ORDER_MST] PUR_CODE, PUR_DT, PUR_PRD_CD, PUR_QNTY, PUR_PRICE_PC, PUR_TOT_AMT, PUR_APRV_DT, PUR_STS
        if (_cs.ExecuteQuery("update TBL_GLUE_PURCHASE_ORDER_MST set PUR_APRV_DT='" + utl.Date + "',PUR_STS='" + utl.Status + "' where PUR_CODE='" + utl.Product_Code + "'") == 1)
        {
            re = "Success";
        }
        else
        {
            re = "Error";
        }
        return(re);
    }
Example #8
0
    public string _Insert_Stock(_Utility utl)
    {
        string re = "";

        //[dbo].[TBL_GLUE_PURCHASE_ORDER_MST] PUR_CODE, PUR_DT, PUR_PRD_CD, PUR_QNTY, PUR_PRICE_PC, PUR_TOT_AMT, PUR_APRV_DT, PUR_STS
        if (_cs.ExecuteQuery("insert into TBL_GLUE_PURCHASE_ORDER_MST(PUR_DT,PUR_PRD_CD,PUR_QNTY,PUR_PRICE_PC,PUR_TOT_AMT) values('" + utl.Date + "','" + utl.Product_Code + "','" + utl.Product_Qnty + "','" + utl.Product_Price + "','" + utl.Amount + "')") == 1)
        {
            re = "Success";
        }
        else
        {
            re = "Error";
        }
        return(re);
    }
Example #9
0
    void Bind()
    {
        DataSet ds = new _Utility().Get_Employee_Customer_Data("5");

        if (ds.Tables.Count > 0)
        {
            if (ds.Tables[0].Rows.Count > 0)
            {
                for (int x = 0; x < ds.Tables[0].Rows.Count; x++)
                {
                    ul_Ledger.InnerHtml += "<li><a href='VendorReport.aspx?Cd=" + ds.Tables[0].Rows[x]["ECM_CODE"].ToString() + "'><i class='fa fa-user'></i>" + ds.Tables[0].Rows[x]["ECM_NAME"].ToString() + "</a></li>";
                }
                lbl_notification.Text    = ds.Tables[0].Rows.Count.ToString();
                lbl_notification1.Text   = ds.Tables[0].Rows.Count.ToString();
                ul_UserDetails.InnerHtml = ul_Ledger.InnerHtml;
            }
        }

        lbl_user_name.Text  = Session["NAME"].ToString();
        lbl_user_name1.Text = Session["NAME"].ToString();
        lbl_UserName2.Text  = Session["NAME"].ToString();
    }
Example #10
0
    public string Insert_User_Data(_Utility utl)
    {
        string  re = "";
        DataSet ds = _cs._Get_Dataset("select * from TBL_EMPLOYEE_CUSTOMER_MST where ECM_ECAT_CD='6' AND ECM_EMAIL='" + utl.Email + "'");

        if (ds.Tables[0].Rows.Count > 0)
        {
            re = "InvEmail";
        }
        else
        {
            if (_cs.ExecuteQuery("insert into TBL_EMPLOYEE_CUSTOMER_MST(ECM_ECAT_CD,ECM_NAME,ECM_PHNO,ECM_EMAIL,ECM_PWD) values('6','" + utl.Name + "','" + utl.Phone + "','" + utl.Email + "','" + utl.Password + "')") == 1)
            {
                re = "Success";
            }
            else
            {
                re = "Error";
            }
        }
        return(re);
    }
Example #11
0
 public int Insert_Journal_Data(_Utility utl)
 {
     return(_cs.ExecuteQuery("insert into TBL_JOURNAL_HDR(JRN_DT,JRN_ECM_CD,JRN_CR_DR,JRN_FRM_TO,JRN_DESC,JRN_AMT) values('" + Convert.ToDateTime(utl.Date).ToString("dd-MMM-yyyy") + "','" + utl.Emp_Cust_Code + "','" + utl.CR_DR + "','" + utl.Emp_Cust_Code_To + "','" + utl.Description + "','" + utl.Amount + "')"));
 }
Example #12
0
 public string Insert_New_Product(_Utility utl)
 {
     return(_cs.ExecuteCmd_WithOutput(_cs.ReturnCommand("USP_TBL_GLUE_PRODUCT_MST", "@PRD_CODE^@PRD_NAME^@PRD_SLE_PRC^@PRD_PUR_PRC^@PRD_BOX_SIZE^@PRD_TYPE_CD^@PRD_TAX_CD^@PRD_STS^@TYPE", utl.Product_Code + "^" + utl.Name + "^" + utl.Product_Price + "^" + utl.Product_Purchase_Price + "^" + utl.Product_Box_Size + "^" + utl.PrdType + "^" + utl.VAT + "^" + utl.Status + "^" + utl.Type, '^'), "@OUT"));
 }
Example #13
0
 public string Insert_Product(_Utility utl)
 {
     return(_cs.ExecuteCmd_WithOutput(_cs.ReturnCommand("USP_TBL_GLUE_SALE_PRICE_INF", "@SAL_VENDOR_CD^@SAL_PRD_CD^@SAL_PRICE_PC", utl.Emp_Cust_Code + "^" + utl.Product_Code + "^" + utl.Product_Price, '^'), "@OUT"));
 }