| | |
| | | HttpPostedFile files = HttpContext.Current.Request.Files["file"]; //忮䏻å
ç |
| | | string path = HttpContext.Current.Server.MapPath("~/../Files/" + HBillNo); |
| | | //string path = @"D:\\Files\\"+ HBillNo; |
| | | dynamic dyResult = UpLoadFile(files, path, HBillNo, HInterID, HUserName); |
| | | Int64 HEntryID = Convert.ToInt64(HttpContext.Current.Request.Params["HEntryID"]); //åå
ç |
| | | dynamic dyResult = UpLoadFile(files, path, HBillNo, HInterID, HUserName, HEntryID); |
| | | if (dyResult != null && dyResult.result == 1) |
| | | { |
| | | objJsonResult.code = "1"; |
| | |
| | | |
| | | } |
| | | |
| | | public dynamic UpLoadFile(HttpPostedFile files, string path, string HBillNo, string HInterID, string HUserName) |
| | | public dynamic UpLoadFile(HttpPostedFile files, string path, string HBillNo, string HInterID, string HUserName,Int64 HEntryID) |
| | | { |
| | | dynamic Result_Ob = new { result = 1, returnval = "ä¸ä¼ æåï¼" }; |
| | | string filePath = Path.GetFullPath(files.FileName);//æä»¶ä¸ä¼ è·¯å¾ |
| | |
| | | ",HUpMan,HUpTime,HInterID,HEntryID,HSno,HFileID,HFileSize" + |
| | | ") values('" |
| | | + filename.ToString() + "','" + filePath.ToString() + "','" + fileExtension.ToString() + "'" + |
| | | ",'" + HUserName + "',getdate()" + ",'" + HInterID + "','" + 0 + "','" + Sno + "','" + lID + "','" + 0 + |
| | | ",'" + HUserName + "',getdate()" + ",'" + HInterID + "','" + HEntryID + "','" + Sno + "','" + lID + "','" + filesize + |
| | | "') "); |
| | | } |
| | | else |
| | |
| | | ",HUpMan,HUpTime,HInterID,HEntryID,HSno,HFileID,HFileSize" + |
| | | ") values('" |
| | | + filename.ToString() + "','" + filePath.ToString() + "','" + fileExtension.ToString() + "'" + |
| | | ",'" + HUserName + "',getdate()" + ",'" + HInterID + "','" + 222 + "','" + 333 + "','" + 444 + "','" + 555 + |
| | | ",'" + HUserName + "',getdate()" + ",'" + HInterID + "','" + HEntryID + "','" + Sno + "','" + lID + "','" + filesize + |
| | | "') "); |
| | | } |
| | | else |
| | |
| | | ",HContext,HDeptID,HDescription,HSendMan,HReceiveMan" + |
| | | ",HCopyMan,HHasten,HLevel,HReTransmitMan,HBillTypeName"+ |
| | | ",HPlanBillNo,HMaterName,HMaterModel,HQty,HSendType"+ |
| | | ",HSourceInterID,HSourceEntryID,HSourceBillNo,HSourceBillType" + |
| | | ",HSourceInterID,HSourceEntryID,HSourceBillNo,HSourceBillType,HRecDeptID,HMaterNumber" + |
| | | ") " + |
| | | " values('" + this.BillType + "','" + this.HBillSubType + "'," +omodel.HInterID.ToString() + ",'" + omodel.HBillNo + "','" + omodel.HDate + "'" + |
| | | "," + omodel.HYear.ToString() + "," + omodel.HPeriod.ToString() + ",'" + omodel.HRemark + "','" + DBUtility.ClsPub.CurUserName + "',getdate()" + |
| | |
| | | ",'" + omodel.HCopyMan + "'," + omodel.HHasten.ToString() + ",'" + omodel.HLevel + "','" + omodel.HReTransmitMan + "','" + omodel.HBillTypeName + "'" + |
| | | ",'" + omodel.HPlanBillNo + "','" + omodel.HMaterName + "','" + omodel.HMaterModel + "'," + omodel.HQty.ToString() + ",'" + omodel.HSendType + "'" + |
| | | ",'" + omodel.HMainSourceInterID + "','" + omodel.HMainSourceEntryID + "','" + omodel.HMainSourceBillNo + "','" + omodel.HMainSourceBillType + "'" + |
| | | "," + omodel.HRecDeptID + ",'" + omodel.HMaterNumber + "'" + |
| | | ") "); |
| | | //æå
¥å表 |
| | | //foreach (Models.ClsOA_ErrMsgBackBillSub oSub in DetailColl) |
| | |
| | | public string HMaterModel;// varchar(100) --è§æ ¼åå· |
| | | public double HQty;// money --æ°é |
| | | public string HSendType;// varchar(6) --åéç±»åï¼å
Œ
±ï¼ä¸ªäººï¼ |
| | | |
| | | public string HMaterNumber;// varchar(100) ç©æç¼ç |
| | | public Int64 HRecDeptID;// int --æ¥æ¶é¨é¨ |
| | | } |
| | | } |