|  |  | 
 |  |  |                       ") "); | 
 |  |  |                 } | 
 |  |  |  | 
 |  |  |                 //根据内码 委外工单表头供应商 回填对应流转卡 供应商,有委外标记才回填..并且回填 关联数量 | 
 |  |  |                 oCn.RunProc("exec h_p_WW_EntrustWorkOrderToProcExch " + omodel.HInterID.ToString()); | 
 |  |  |                 // | 
 |  |  |                 DataSet Ds; | 
 |  |  |                 Ds = oCn.RunProcReturn("exec h_p_WW_EntrustWorkOrderToProcExch_QtyCtrl " + omodel.HInterID.ToString() + "", "h_p_WW_EntrustWorkOrderToProcExch_QtyCtrl"); | 
 |  |  |                 if (Ds == null) | 
 |  |  |                 { | 
 |  |  |                     sReturn = "判断数量失败!"; | 
 |  |  |                     oCn.RollBack(); | 
 |  |  |                     return false; | 
 |  |  |                 } | 
 |  |  |                 if (Ds.Tables[0].Rows.Count == 0) | 
 |  |  |                 { | 
 |  |  |                     sReturn = "判断数量失败!"; | 
 |  |  |                     oCn.RollBack(); | 
 |  |  |                     return false; | 
 |  |  |                 } | 
 |  |  |                 if (DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["HBack"]) == "2") | 
 |  |  |                 { | 
 |  |  |                     sReturn = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["HBackRemark"]); | 
 |  |  |                     oCn.RollBack(); | 
 |  |  |                     return false; | 
 |  |  |                 } | 
 |  |  |                 ////根据内码 委外工单表头供应商 回填对应流转卡 供应商,有委外标记才回填..并且回填 关联数量 | 
 |  |  |                 //oCn.RunProc("exec h_p_WW_EntrustWorkOrderToProcExch " + omodel.HInterID.ToString()); | 
 |  |  |                 //// | 
 |  |  |                 //DataSet Ds; | 
 |  |  |                 //Ds = oCn.RunProcReturn("exec h_p_WW_EntrustWorkOrderToProcExch_QtyCtrl " + omodel.HInterID.ToString() + "", "h_p_WW_EntrustWorkOrderToProcExch_QtyCtrl"); | 
 |  |  |                 //if (Ds == null) | 
 |  |  |                 //{ | 
 |  |  |                 //    sReturn = "判断数量失败!"; | 
 |  |  |                 //    oCn.RollBack(); | 
 |  |  |                 //    return false; | 
 |  |  |                 //} | 
 |  |  |                 //if (Ds.Tables[0].Rows.Count == 0) | 
 |  |  |                 //{ | 
 |  |  |                 //    sReturn = "判断数量失败!"; | 
 |  |  |                 //    oCn.RollBack(); | 
 |  |  |                 //    return false; | 
 |  |  |                 //} | 
 |  |  |                 //if (DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["HBack"]) == "2") | 
 |  |  |                 //{ | 
 |  |  |                 //    sReturn = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["HBackRemark"]); | 
 |  |  |                 //    oCn.RollBack(); | 
 |  |  |                 //    return false; | 
 |  |  |                 //} | 
 |  |  |                 // | 
 |  |  |                 sReturn = "新增单据成功!"; | 
 |  |  |                 oCn.Commit(); |