|  |  |  | 
|---|
|  |  |  | int HYear = DBUtility.ClsPub.isInt(DateTime.Now.Year); | 
|---|
|  |  |  | double HPeriod = DBUtility.ClsPub.isLong(DateTime.Now.Month); | 
|---|
|  |  |  | string HMouldNo = mainList[0].HMouldNo; | 
|---|
|  |  |  | string HBarCode = mainList[0].HBarCode; | 
|---|
|  |  |  | string HName = mainList[0].HName; | 
|---|
|  |  |  | string HModel = mainList[0].HModel; | 
|---|
|  |  |  | string HModel2 = mainList[0].HModel2; | 
|---|
|  |  |  | 
|---|
|  |  |  | ",HSPGroupID=" + HSPGroupID.ToString() + | 
|---|
|  |  |  | ",HSPID=" + HSPID.ToString() + | 
|---|
|  |  |  | ",HDesignLife=" + HDesignLife.ToString() + | 
|---|
|  |  |  | ",HCaveQty="+ HCaveQty.ToString()+ | 
|---|
|  |  |  | ",HCaveQty=" + HCaveQty.ToString() + | 
|---|
|  |  |  | ",HUseLife=" + HUseLife.ToString() + | 
|---|
|  |  |  | ",HLeaveLife=" + HLeaveLife.ToString() + | 
|---|
|  |  |  | ",HProdQty=" + HProdQty.ToString() + | 
|---|
|  |  |  | ",HMouldDotCheckRuleInterID="+ HMouldDotCheckRuleInterID.ToString()+ | 
|---|
|  |  |  | ",HMouldDotCheckRuleInterID=" + HMouldDotCheckRuleInterID.ToString() + | 
|---|
|  |  |  | ",HMouldMaintainRuleInterID=" + HMouldMaintainRuleInterID.ToString() + | 
|---|
|  |  |  | ",HMouldOWNER='" + HMouldOWNER + "'" + | 
|---|
|  |  |  | ",HNowSupID="+HNowSupID.ToString()+ | 
|---|
|  |  |  | ",HNowSupTypeID="+HNowSupTypeID.ToString()+ | 
|---|
|  |  |  | ",HNowSupID=" + HNowSupID.ToString() + | 
|---|
|  |  |  | ",HNowSupTypeID=" + HNowSupTypeID.ToString() + | 
|---|
|  |  |  | ",HProdWeight=" + HProdWeight.ToString() + | 
|---|
|  |  |  | ",HBarCode="+ HBarCode.ToString()+ | 
|---|
|  |  |  | " where HInterID=" + HInterID.ToString()); | 
|---|
|  |  |  |  | 
|---|
|  |  |  | //修改子项目代码 | 
|---|
|  |  |  | 
|---|
|  |  |  | DataSet ds = new DataSet(); | 
|---|
|  |  |  | ds = oCN.RunProcReturn("select * from Gy_MouldFileMain where HInterID=" + HInterID, "Gy_MouldFileMain"); | 
|---|
|  |  |  | DataRow dr = ds.Tables[0].Rows[0]; | 
|---|
|  |  |  | string Num = dr["HBillNo"].ToString(); | 
|---|
|  |  |  | string Num = dr["HBarCode"].ToString(); | 
|---|
|  |  |  | string Num1 = Num.Substring(0,(Num.Length)-5); | 
|---|
|  |  |  | oCN.BeginTran(); | 
|---|
|  |  |  | for (int i = StarNum1; i <= EndNum1; i++) | 
|---|
|  |  |  | 
|---|
|  |  |  | if (ds1.Tables[0].Rows.Count == 0 || ds1 == null) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | long HItemID = DBUtility.ClsPub.CreateBillID("3899", ref DBUtility.ClsPub.sExeReturnInfo); | 
|---|
|  |  |  | //string HBillNo = DBUtility.ClsPub.CreateBillCode("3899", ref DBUtility.ClsPub.sExeReturnInfo, true); | 
|---|
|  |  |  | string sql = string.Format(@"Insert Into Gy_MouldFileMain   " + | 
|---|
|  |  |  | "(HBillType,HBillSubType,HInterID,HBillNo,HDate" + | 
|---|
|  |  |  | ",HYear,HPeriod,HRemark,HMaker,HMakeDate,HBarCode" + | 
|---|