日期:2014-05-17 浏览次数:20410 次
public string Constr = System.Configuration.ConfigurationManager.AppSettings["sqlConn.ConnectionString"].ToString();
public void tranClas()
{
using (SqlConnection con = new SqlConnection(Constr))
{
con.Open();
SqlTransaction ts = con.BeginTransaction();
SqlCommand cmd = new SqlCommand();
cmd.Connection = con;
cmd.Transaction = ts;
try
{
Ent_Class_Profile claPro = new Ent_Class_Profile();
Ent_Class_Detail detail = new Ent_Class_Detail();
string str = Request.QueryString["data"].ToString();
JieXiJson[] jsda = new JavaScriptSerializer().Deserialize<JieXiJson[]>(str);
claPro.Category_ID = jsda[0].dlCourse;
claPro.Category_2nd_ID = jsda[0].dlSort;
claPro.Attendee_min = jsda[0].Attendee_min;
claPro.Attendee_Max = jsda[0].Attendee_Max;
claPro.Forct_Date =Convert.ToDateTime(jsda[0].Forct_Date);
claPro.Class_Qty = jsda[0].Class_Qty;
claPro.Class_Points = jsda[0].Class_Points;