Beispiel #1
0
        public DataTable Get_By_Section(long SectionID, MR.Status Status)
        {
            try
            {
                SqlParameter[] paramList = new SqlParameter[] {
                    new SqlParameter("@MRSectionID", SectionID),
                    new SqlParameter("@MRStatus", Status)
                };

                return(Execute.RunSP_DataTable(Connection, "SPGET_MR_View_By_SectionID", paramList));
            }
            catch (Exception ex)
            {
                throw new Exception(ex.Message, ex);
            }
        }
Beispiel #2
0
        public int GET_Issue_Count(String EmpID, MR.Status Status)
        {
            try
            {
                SqlParameter[] paramList = new SqlParameter[] {
                    new SqlParameter("@EmpID", EmpID),
                    new SqlParameter("@MRStatus", Status)
                };

                return(Execute.RunSP_Int(Connection, "SPGET_MR_CHECKED_Approval", paramList));
            }
            catch (Exception ex)
            {
                throw new Exception(ex.Message, ex);
            }
        }
Beispiel #3
0
        public DataTable Get_By_Employee(String EmpID, MR.Status Status)
        {
            try
            {
                SqlParameter[] paramList = new SqlParameter[] {
                    new SqlParameter("@EmpID", EmpID),
                    new SqlParameter("@MRStatus", Status)
                };

                return(Execute.RunSP_DataTable(Connection, "SPGET_MR_User", paramList));
            }
            catch (Exception ex)
            {
                throw new Exception(ex.Message, ex);
            }
        }
Beispiel #4
0
        public DataTable GetDataView_Item(String Item, MR.Status Status)
        {
            try
            {
                SqlParameter[] paramList = new SqlParameter[] {
                    new SqlParameter("@ItemCode", Item),
                    new SqlParameter("@Status", Status)
                };

                return(Execute.RunSP_DataTable(Connection, "SPGET_MR_By_Item", paramList));
            }
            catch (Exception ex)
            {
                throw new Exception(ex.Message, ex);
            }
        }
Beispiel #5
0
        public DataTable GetDataView_Material(String MaterialCode, MR.Status Status)
        {
            try
            {
                SqlParameter[] paramList = new SqlParameter[] {
                    new SqlParameter("@MRMaterialCode", MaterialCode),
                    new SqlParameter("@Status", Status)
                };

                return(Execute.RunSP_DataTable(Connection, "SPGET_MR_By_Material", paramList));
            }
            catch (Exception ex)
            {
                throw new Exception(ex.Message, ex);
            }
        }
Beispiel #6
0
        public DataTable GetDataView_FinishProduct(String FinishProduct, MR.Status Status)
        {
            try
            {
                SqlParameter[] paramList = new SqlParameter[] {
                    new SqlParameter("@MRFinishProductID", FinishProduct),
                    new SqlParameter("@Status", Status)
                };

                return(Execute.RunSP_DataTable(Connection, "SPGET_MR_By_FinishProduct", paramList));
            }
            catch (Exception ex)
            {
                throw new Exception(ex.Message, ex);
            }
        }
Beispiel #7
0
        public System.Data.DataTable GetDataView(String StoreID, MR.Status Status)
        {
            try
            {
                SqlParameter[] paramList = new SqlParameter[] {
                    new SqlParameter("@StoreID", StoreID),
                    new SqlParameter("@Status", Status)
                };

                return(Execute.RunSP_DataTable(Connection, "SPGET_MR_ByStoreNoStatus", paramList));
            }
            catch (Exception ex)
            {
                throw new Exception(ex.Message, ex);
            }
        }
Beispiel #8
0
        public System.Data.DataTable GetDataView(long UserID, MR.Status Status, MR.Origin OriginType)
        {
            try
            {
                SqlParameter[] paramList = new SqlParameter[] {
                    new SqlParameter("@UserID", UserID),
                    new SqlParameter("@Status", Status),
                    new SqlParameter("@OriginType", OriginType)
                };

                return(Execute.RunSP_DataTable(Connection, "SPGET_MR_ByDepID_Status_Origin", paramList));
            }
            catch (Exception ex)
            {
                throw new Exception(ex.Message, ex);
            }
        }
Beispiel #9
0
        public System.Data.DataTable GetMR_ToBatch(long UserID, MR.Status Status, MR.Origin ToBatch)
        {
            try
            {
                SqlParameter[] paramList = new SqlParameter[] {
                    new SqlParameter("@UserID", UserID),
                    new SqlParameter("@Status", Status),
                    new SqlParameter("@Origin", ToBatch)
                };

                return(Execute.RunSP_DataTable(Connection, "SPGET_MR_ByProduct_Status", paramList));
            }
            catch (Exception ex)
            {
                throw new Exception(ex.Message, ex);
            }
        }
Beispiel #10
0
        public DataTable Get_By_Manage(long DepID, MR.Status Status, DateTime ToDate, DateTime FromDate)
        {
            try
            {
                SqlParameter[] paramList = new SqlParameter[] {
                    new SqlParameter("@DepID", DepID),
                    new SqlParameter("@MRStatus", Status),
                    new SqlParameter("@ToDate", ToDate),
                    new SqlParameter("@FromDate", FromDate)
                };

                return(Execute.RunSP_DataTable(Connection, "SPGET_MR_DataView_Manage", paramList));
            }
            catch (Exception ex)
            {
                throw new Exception(ex.Message, ex);
            }
        }
Beispiel #11
0
        public System.Data.DataTable GetMR_BulkPrint_Material(string StoreID, MR.Status MRIssued, MR.Status MRReceived, MR.Status MRReceivedGRN, MR.Status MRReceivedSubStock)
        {
            try
            {
                SqlParameter[] paramList = new SqlParameter[] {
                    new SqlParameter("@StoreID", StoreID),
                    new SqlParameter("@MRStatus_Issued", (int)MRIssued),
                    new SqlParameter("@MRStatus_Received", (int)MRReceived),
                    new SqlParameter("@MRStatus_ReceviedGRN", (int)MRReceivedGRN),
                    new SqlParameter("@MRStatus_ReceviedSubStock", (int)MRReceivedSubStock)
                };

                return(Execute.RunSP_DataTable(Connection, "SPGET_MRMaterial_BulkPrint_Dataview", paramList));
            }
            catch (Exception ex)
            {
                throw new Exception(ex.Message, ex);
            }
        }
Beispiel #12
0
        public int Add_BatchMR(string Part, string BatchID, string StoreID, string RequestedBy, string Remarks, MR.Status MRStatus, MR.Type MRType, int OriginType)
        {
            try
            {
                SqlParameter[] paramList = new SqlParameter[] {
                    new SqlParameter("@Part", Part),
                    new SqlParameter("@BatchID", BatchID),
                    new SqlParameter("@MRStore", StoreID),
                    new SqlParameter("@MREnterdBy", RequestedBy),
                    new SqlParameter("@MRRemarks", Remarks),
                    new SqlParameter("@MRStatus", MRStatus),
                    new SqlParameter("@MRType", MRType),
                    new SqlParameter("@OriginType", OriginType),
                    new SqlParameter("@outParam", SqlDbType.Int)
                    {
                        Direction = ParameterDirection.Output
                    }
                };

                return(Execute.RunSP_Output(Connection, "SPADD_BatchMR_SendMR", paramList));
            }
            catch (Exception ex)
            {
                throw new Exception(ex.Message, ex);
            }
        }
Beispiel #13
0
        public int Add_Packing_ToSections(string StoreID, int SectionID, int DepID, string RequestedBy, string Remarks, MR.Status MRStatus, MR.Type MRType, int OriginType)
        {
            try
            {
                SqlParameter[] paramList = new SqlParameter[] {
                    new SqlParameter("@MRStore", StoreID),
                    new SqlParameter("@SectionID", SectionID),
                    new SqlParameter("@DepID", DepID),
                    new SqlParameter("@MREnterdBy", RequestedBy),
                    new SqlParameter("@MRRemarks", Remarks),
                    new SqlParameter("@MRStatus", MRStatus),
                    new SqlParameter("@MRType", MRType),
                    new SqlParameter("@OriginType", OriginType),
                    new SqlParameter("@outParam", SqlDbType.Int)
                    {
                        Direction = ParameterDirection.Output
                    }
                };

                return(Execute.RunSP_Output(Connection, "SPADD_MR_Packing_ToSections", paramList));
            }
            catch (Exception ex)
            {
                throw new Exception(ex.Message, ex);
            }
        }