示例#1
0
        public void AddEditDel_Case(DO_Case objcase, DA_Case.Case flag)
        {
            SqlConnection conn = new SqlConnection();
            SQLManager    co   = new SQLManager();

            conn = co.GetConnection();

            cmd             = new SqlCommand("scrl_AddEditDeleteCase_SP", conn);
            cmd.CommandType = CommandType.StoredProcedure;
            cmd.Parameters.Add("@FlagNo", SqlDbType.Int).Value                  = flag;
            cmd.Parameters.Add("@CaseId", SqlDbType.BigInt).Value               = objcase.CaseId;
            cmd.Parameters.Add("@CaseTitle", SqlDbType.VarChar, 200).Value      = objcase.CaseTitle;
            cmd.Parameters.Add("@Citation", SqlDbType.VarChar, 200).Value       = objcase.Citation;
            cmd.Parameters.Add("@EnactmentCites", SqlDbType.VarChar, 200).Value = objcase.EnactmentCites;
            cmd.Parameters.Add("@Jurisdiction", SqlDbType.VarChar, 200).Value   = objcase.Jurisdiction;
            cmd.Parameters.Add("@ProvisionofLaw", SqlDbType.VarChar).Value      = objcase.ProvisionofLaw;
            cmd.Parameters.Add("@JudgementDate", SqlDbType.DateTime).Value      = objcase.JudgementDate;
            cmd.Parameters.Add("@Cites", SqlDbType.VarChar, 200).Value          = objcase.Cites;
            cmd.Parameters.Add("@CitedBy", SqlDbType.VarChar, 200).Value        = objcase.CitedBy;
            cmd.Parameters.Add("@PartyNames", SqlDbType.VarChar, 200).Value     = objcase.PartyNames;
            cmd.Parameters.Add("@BenchStrength", SqlDbType.VarChar, 200).Value  = objcase.BenchStrength;
            cmd.Parameters.Add("@ContentSource", SqlDbType.VarChar, 200).Value  = objcase.ContentSource;
            cmd.Parameters.Add("@Description", SqlDbType.VarChar, 8000).Value   = objcase.Description;
            cmd.Parameters.Add("@JudgeNames", SqlDbType.VarChar, 200).Value     = objcase.JudgeNames;

            cmd.ExecuteNonQuery();
            co.CloseConnection(conn);
        }
        public void AddEditDel_Case(DO_Case objcase, DA_CaseComment.CaseComment flag)
        {
            SqlConnection conn = new SqlConnection();
            SQLManager    co   = new SQLManager();

            conn = co.GetConnection();

            cmd             = new SqlCommand("Scrl_AddEditDelCaseComment", conn);
            cmd.CommandType = CommandType.StoredProcedure;
            cmd.Parameters.Add("@FlagNo", SqlDbType.Int).Value                 = flag;
            cmd.Parameters.Add("@CaseId", SqlDbType.BigInt).Value              = objcase.CaseId;
            cmd.Parameters.Add("@Description", SqlDbType.Text).Value           = objcase.Description;
            cmd.Parameters.Add("@strCaseTitle", SqlDbType.VarChar, 1000).Value = objcase.CaseTitle;
            cmd.Parameters.Add("@strFilePath", SqlDbType.VarChar, 100).Value   = objcase.strFilePath;
            cmd.ExecuteNonQuery();
            co.CloseConnection(conn);
        }
示例#3
0
        public DataTable GetDataTable(DO_Case objcase, DA_Case.Case flag)
        {
            DataTable     dt   = new DataTable();
            SqlConnection conn = new SqlConnection();
            SQLManager    co   = new SQLManager();

            conn = co.GetConnection();
            SqlDataAdapter da = new SqlDataAdapter();

            da.SelectCommand             = new SqlCommand("scrl_AddEditDeleteCase_SP", conn);
            da.SelectCommand.CommandType = CommandType.StoredProcedure;
            da.SelectCommand.Parameters.Add("@FlagNo", SqlDbType.Int).Value                = flag;
            da.SelectCommand.Parameters.Add("@CaseId", SqlDbType.BigInt).Value             = objcase.CaseId;
            da.SelectCommand.Parameters.Add("@AddedBy", SqlDbType.BigInt).Value            = objcase.AddedBy;
            da.SelectCommand.Parameters.Add("@Condition", SqlDbType.VarChar, 500).Value    = objcase.Condition;
            da.SelectCommand.Parameters.Add("@Jurisdiction", SqlDbType.VarChar, 500).Value = objcase.Jurisdiction;
            da.SelectCommand.Parameters.Add("@year", SqlDbType.Int).Value        = objcase.year;
            da.SelectCommand.Parameters.Add("@Currentpage", SqlDbType.Int).Value = objcase.CurrentPage;
            da.SelectCommand.Parameters.Add("@pagesize", SqlDbType.Int).Value    = objcase.PageSize;
            da.Fill(dt);
            co.CloseConnection(conn);
            return(dt);
        }
        public DataTable GetDataTable(DO_Case objcase, DA_CaseComment.CaseComment flag)
        {
            DataTable     dt   = new DataTable();
            SqlConnection conn = new SqlConnection();
            SQLManager    co   = new SQLManager();

            conn = co.GetConnection();
            SqlDataAdapter da = new SqlDataAdapter();

            da.SelectCommand             = new SqlCommand("Scrl_AddEditDelCaseComment", conn);
            da.SelectCommand.CommandType = CommandType.StoredProcedure;
            da.SelectCommand.Parameters.Add("@FlagNo", SqlDbType.Int).Value           = flag;
            da.SelectCommand.Parameters.Add("@CaseId", SqlDbType.BigInt).Value        = objcase.CaseId;
            da.SelectCommand.Parameters.Add("@ContentTypeId", SqlDbType.BigInt).Value = objcase.ContentTypeID;
            da.SelectCommand.Parameters.Add("@CommentID", SqlDbType.Int).Value        = objcase.CommnetId;
            da.SelectCommand.Parameters.Add("@intAddedBy", SqlDbType.Int).Value       = objcase.AddedBy;
            da.SelectCommand.Parameters.Add("@TagId", SqlDbType.Int).Value            = objcase.TagId;
            da.SelectCommand.Parameters.Add("@CommnetAddedFor", SqlDbType.Int).Value  = objcase.CommnetAddedFor;

            da.Fill(dt);
            co.CloseConnection(conn);
            return(dt);
        }