public void BatchSavePictures(string pjnd, List <AssetsData> lstAssetsData, Size size) { DecParams decParams = new DecParams(); PictureCreator pictureCreator = new PictureCreator(); foreach (AssetsData item in lstAssetsData) { decParams.ProID = item.ProID; //decParams.Pjnd = item.Pjnd; decParams.Dydm = item.DYDM; decParams.Dymc = item.DYMC; //decParams.Ycqsrq = item. EvaluationOptionsService evalOptionService = new EvaluationOptionsService(); DataTable dtEvalOption = evalOptionService.GetDataTable(item.ProID, item.Pjnd, item.DYDM); if (dtEvalOption == null || dtEvalOption.Rows.Count <= 0) { continue; } string ycqsrq = dtEvalOption.Rows[0]["startNy"].ToString(); decParams.PreStartDate = ycqsrq.ToDateTime(); Bitmap bmp = pictureCreator.CreateBitmap(decParams, size); bmp.Save(@"e:\\" + decParams.Dymc + ".png"); } }
private void FrmPjndEdit_Load(object sender, EventArgs e) { if (eos == null) { eos = new EvaluationOptionsService(); } DataTable dtData = eos.GetDataTable(proID); string newPjnd = GetNewPjnd(dtData); DateTime dtNewYcqsrq = new DateTime(DateTime.Now.Year, DateTime.Now.Month, 1); this.uctEvaluationOptions1.Init(newPjnd, dtNewYcqsrq); }
private bool DeletePJND(string proID, string pjnd) { if (curPjndDelete == false && pjnd == CurPjnd) { curPjndDelete = true; } //string err; //EvaluationOptionsService eos = new EvaluationOptionsService(); //err = eos.DeleteAllPjndInfo(proID, pjnd); //if (string.IsNullOrEmpty(err) == false) //{ // PublicMethods.WarnMessageBox("删除评价年度数据失败,原因:\n" + err); // return false; //} EvaluationOptionsService eos = new EvaluationOptionsService(); C_DeletePJNDInfo opDelPJND = new C_DeletePJNDInfo(this, proID, pjnd, eos.DBAccessEx); opDelPJND.DeletePJND(); return(true); }
void backgroundWorker_DoWork(object sender, DoWorkEventArgs e) { EvaluationOptionsService eos = new EvaluationOptionsService(); this.dtOptions = eos.GetDictPjnd(proID); }