123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164 |
- using System;
- using System.Collections.Generic;
- using System.ComponentModel;
- using System.Data;
- using System.Drawing;
- using System.Linq;
- using System.Text;
- using System.Windows.Forms;
- using LYFZ.Command;
- using LYFZ.ComponentLibrary;
- using System.Collections;
- using LYFZ.Software.MainBusiness.DoorCityProcess;
- using LYFZ.Software.MainBusiness.InitialSet;
- using LYFZ.Model;
- using System.Net;
- using System.IO;
- namespace LYFZ.Software.MainBusiness.MicroApplet
- {
- public partial class frmPackagesUpload : LYFZ.Software.MicroApplet.frmPackagesUpload
- {
- LYFZ.BLL.BLL_ErpOrder orbll = new BLL.BLL_ErpOrder();
- LYFZ.BLL.BLL_ErpProduct ptbll = new BLL.BLL_ErpProduct();
- LYFZ.BLL.BLL_ErpPackages pkbll = new BLL.BLL_ErpPackages();
- LYFZ.BLL.BLL_ErpTheScenery tsbll = new BLL.BLL_ErpTheScenery();
- LYFZ.BLL.BLL_ErpPackagesGiftMerchandise pgmbll = new BLL.BLL_ErpPackagesGiftMerchandise();
- public frmPackagesUpload(string StrType = "0")
- {
- if (!string.IsNullOrEmpty(StrType))
- {
- this.StrPackagesType = Convert.ToInt32(StrType);
- }
- else
- {
- this.StrPackagesType = 0;
- }
- this.Load += PackagesGoodsSetFormMain_Load;
- this.Shown += PackagesGoodsSetFormMain_Shown;
- this.cmbtreev_PackageName.ComboBoxTree_NodeMouseClick += cmbtreev_PackageName_ComboBoxTree_NodeMouseClick;
- this.btnSaveed.Click += btnSaveed_Click;
- this.btnCloseed.Click += btnCloseed_Click;
- this.TabControl.SelectedIndexChanged += TabControl_SelectedIndexChanged;
- this.btnPicSelect.Click += BtnPicSelect_Click;
- this.btnListImgSelect.Click += BtnListImgSelect_Click;
- this.btnSelectVideo_url.Click += BtnSelectVideo_url_Click;
- }
- /// <summary>
- /// 选择视频
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- private void BtnSelectVideo_url_Click(object sender, EventArgs e)
- {
- OpenFileDialog open = new OpenFileDialog();
- open.Multiselect = false;
- open.Title = "选择图片";
- open.Filter = "视频|*.mp4;*.flv;*.mov;*.wmv;*.avi;*.mpeg;*.mpeg;";
- if (open.ShowDialog() == DialogResult.OK)
- {
- this.txtVideo_url.Text = open.FileName;
- Video_url = open.FileName;
- }
- }
- MicroAppLoginReturn _appLoginModel = new MicroAppLoginReturn();
- public MicroAppLoginReturn AppLoginModel
- {
- get { return _appLoginModel; }
- set { _appLoginModel = value; }
- }
- /// <summary>
- /// 上传套系
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void btnSaveed_Click(object sender, EventArgs e)
- {
- try
- {
- if (packModel != null && !string.IsNullOrEmpty(this.cmbtreev_PackageName.Text.Trim()))
- {
- LYFZ.Command.Result<dynamic> res = (LYFZ.Command.Result<dynamic>)pkbll.GetSelectTaoXiLeiXing(packModel);
- MicroAppReturn returnData = new MicroAppReturn();
- if (!this.rdoErTong.Checked && !this.rdoHungSha.Checked && !this.rdoPuTong.Checked)
- {
- MessageBoxCustom.Show("请选择套系类型");
- return;
- }
- //小程序套系分类
- int categoty_id = -1;
- try
- {
- if (this.cbxFengLie.SelectedItem == null)
- {
- MessageBoxCustom.Show("请选择套系分类");
- return;
- }
- else
- {
- ItemValue item = (ItemValue)this.cbxFengLie.SelectedItem;
- categoty_id = Convert.ToInt32(item.Value);
- }
- }
- catch (Exception ex)
- {
- MessageBoxCustom.Show("选择套系分类时出错:{0}", ex.Message);
- return;
- }
- this.picImagePath = this.txtPicImage.Text.Trim();
- List<string> UpdoadImageList = new List<string>();
- if (this.listImageList.Items.Count > 0)
- {
- foreach (string path in this.listImageList.Items)
- {
- UpdoadImageList.Add(path);
- }
- }
- //服务装套数
- int clothCount = 1;
- //景点
- string sceneName = "";
- //入底
- int negativeCount = 0;
- //入册
- int meticulouslyCount = 0;
- if (this.rdoErTong.Checked)
- {
- clothCount = ErTongFuZhuangShu;
- sceneName = String.Join(", ", this.ErTongJingDianList.ToArray());
- negativeCount = ErTongRuDiShu;
- meticulouslyCount = ErTongRuCheShu;
- }
- else
- {
- clothCount = PuTongFuZhuangShu;
- sceneName = String.Join(", ", this.PuTongJingDianList.ToArray());
- negativeCount = PuTongRuDiShu;
- meticulouslyCount = PuTongRuCheShu;
- }
- dynamic TaoXiData = new
- {
- TaoXiBianMa = this.packModel.Pak_PackagesID,
- TaoXiMingCheng = this.packModel.Pak_Name,
- TaoXiJiaGe = this.packModel.Pak_UnitPrice,
- TaoXiLeiYongData = res.Data,
- };
- if (String.IsNullOrEmpty(sceneName))
- {
- MessageBoxCustom.Show("当前套系未设置对应的景点或拍摄阶段");
- return;
- }
- LYFZ.ComponentLibrary.FrmLoadHandling.LoadDoWorkMethod(delegate (object obj, BackgroundWorker backgroundWorker)
- {
- try
- {
- string uploadVideo_url = "";
- if (this.Video_url.Trim().Length > 0)
- {
- backgroundWorker.ReportProgress(0, "正在上传视频...");
- MicroAppReturn returnUploadPicData = UploadPhoto(this.Video_url.Trim());
- if (returnUploadPicData.Code == 200)
- {
- dynamic PicData = Newtonsoft.Json.JsonConvert.DeserializeObject(returnUploadPicData.Data);
- uploadVideo_url = PicData["img_route"];
- }
- else
- {
- returnData.Message = String.Format("视频上传失败:{0}", returnUploadPicData.Message);
- return;
- }
- }
- backgroundWorker.ReportProgress(0, "正在上传图片...");
- string picImageUrl = "";
- if (this.picImagePath.Trim().Length > 0)
- {
- MicroAppReturn returnUploadPicData = UploadPhoto(this.picImagePath.Trim());
- if (returnUploadPicData.Code == 200)
- {
- dynamic PicData = Newtonsoft.Json.JsonConvert.DeserializeObject(returnUploadPicData.Data);
- picImageUrl = PicData["img_route"];
- }
- else
- {
- returnData.Message = returnUploadPicData.Message; return;
- }
- }
- else
- {
- returnData.Message = "请选择标题图片"; return;
- }
- List<string> imageUrlList = new List<string>();
- if (UpdoadImageList.Count > 0)
- {
- foreach (string path in UpdoadImageList)
- {
- MicroAppReturn tUploadPicData = UploadPhoto(path.Trim());
- if (tUploadPicData.Code == 200)
- {
- dynamic tPicData = Newtonsoft.Json.JsonConvert.DeserializeObject(tUploadPicData.Data);
- string tempImageUrl = tPicData["img_route"];
- imageUrlList.Add(tempImageUrl);
- }
- else
- {
- returnData.Message = tUploadPicData.Message; return;
- }
- }
- }
- else
- {
- returnData.Message = "请选择展示图片"; return;
- }
- backgroundWorker.ReportProgress(0, "正在上传套系数据...");
- string tempstr = Newtonsoft.Json.JsonConvert.SerializeObject(TaoXiData);
- dynamic extraData = new
- {
- clothCount = clothCount.ToString(),
- sceneName = sceneName,
- duration = this.txtFuWuShiChang.Text.Trim(),
- negativeCount = negativeCount,
- meticulouslyCount = meticulouslyCount,
- orderDetail = this.ShangPingList.ToArray(),
- agreement = txtXieYi.lines,
- sceneIntro = this.HuFuList.ToArray(),
- purchaseNotes = txtGouMaiXuZhi.Text.Trim(),
- pictureUrl = imageUrlList.ToArray(),
- imgUrl = picImageUrl
- };
- int series_type = this.rdoErTong.Checked ? 2 : this.rdoHungSha.Checked ? 1 : 3;
- dynamic PackageData = new
- {
- title = this.packModel.Pak_Name,
- categoty_id = categoty_id,
- price = this.nuDingJing.Value,
- price_original = this.packModel.Pak_UnitPrice,
- series_type = series_type,
- cover_url = picImageUrl,
- video_url = uploadVideo_url,
- series_id = "",
- extra = extraData,
- extra_id = String.Format("{0}{1}", this.packModel.Pak_PackagesID, series_type),
- third_party_data = TaoXiData
- };
- string postData = Newtonsoft.Json.JsonConvert.SerializeObject(PackageData);
- string PostReturnString = frmMicroAppletAdmin.HttpWebRequestPOST(frmSynchronousData.addSeriesData, postData, _appLoginModel, Encoding.UTF8);
- if (PostReturnString.IndexOf("{") == 0)
- {
- dynamic postReturnObj = Newtonsoft.Json.JsonConvert.DeserializeObject(PostReturnString);
- if (Convert.ToInt32(postReturnObj["meta"]["code"]) == 200)
- {
- returnData.Code = 200;
- returnData.Data = Newtonsoft.Json.JsonConvert.SerializeObject(postReturnObj["body"]);
- }
- else
- {
- returnData.Message = postReturnObj["meta"]["message"];
- }
- }
- else
- {
- returnData.Message = PostReturnString;
- }
- }
- catch (Exception ex)
- {
- MessageBoxCustom.Show(String.Format("上传套系数据时错误:{0}", ex.Message));
- }
- });
- if (returnData.Code == 200)
- {
- MessageBoxCustom.Show(String.Format("上传套系数据已上传成功"));
- }
- else
- {
- MessageBoxCustom.Show(String.Format("上传套系数据时失败:{0}", returnData.Message));
- }
- }
- else
- {
- MessageBoxCustom.Show("请选择套系");
- }
- }
- catch (Exception ex)
- {
- MessageBoxCustom.Show(String.Format("上传套系数据时出错误:{0}", ex.Message));
- }
- }
- MicroAppReturn UploadPhoto(string photoPath)
- {
- MicroAppReturn data = new MicroAppReturn();
- string PostReturnString = SendHttpRequestPost(frmSynchronousData.uploadImg, photoPath, _appLoginModel, Encoding.UTF8);
- if (PostReturnString.IndexOf("{") == 0)
- {
- dynamic postReturnObj = Newtonsoft.Json.JsonConvert.DeserializeObject(PostReturnString);
- if (Convert.ToInt32(postReturnObj["meta"]["code"]) == 200)
- {
- data.Code = 200;
- data.Data = Newtonsoft.Json.JsonConvert.SerializeObject(postReturnObj["body"]);
- }
- else
- {
- data.Message = postReturnObj["meta"]["message"];
- }
- }
- else
- {
- data.Message = PostReturnString;
- }
- return data;
- }
- /// <summary>
- /// 向指定的URL地址发起一个POST请求,同时可以上传一些数据项以及上传文件。
- /// </summary>
- /// <param name="url">要请求的URL地址</param>
- /// <param name="fileList">要上传的文件列表</param>
- /// <param name="encoding">发送数据项,接收的字符编码方式</param>
- /// <returns>服务器的返回结果</returns>
- public string SendHttpRequestPost(string url, string filePath, MicroAppLoginReturn appLogin, Encoding encoding=null)
- {
- if (string.IsNullOrEmpty(url))
- throw new ArgumentNullException("url");
- if (encoding == null)
- encoding = Encoding.UTF8;
- HttpWebRequest request = (HttpWebRequest)WebRequest.Create(url);
- request.Method = "POST"; // 要上传文件,一定要是POST方法
- request.Headers.Add("token", appLogin.AppToken);
- request.Headers.Add("bindcode", appLogin.Bind_code);
- // 数据块的分隔标记,用于设置请求头,注意:这个地方最好不要使用汉字。
- string boundary = "---------------------------" + Guid.NewGuid().ToString("N");
- // 数据块的分隔标记,用于写入请求体。
- // 注意:前面多了一段: "--" ,而且它们将独占一行。
- byte[] boundaryBytes = Encoding.ASCII.GetBytes("\r\n--" + boundary + "\r\n");
- // 设置请求头。指示是一个上传表单,以及各数据块的分隔标记。
- request.ContentType = "multipart/form-data; boundary=" + boundary;
-
- // 先得到请求流,准备写入数据。
- Stream stream = request.GetRequestStream();
-
- // 写入要上传的文件
- // foreach (DictionaryEntry kvp in fileList)//KeyValuePair<string, string> kvp
- {
- // 写入数据块的分隔标记
- stream.Write(boundaryBytes, 0, boundaryBytes.Length);
- string photoFile = filePath;// kvp.Value.ToString();
- /* if (".jpg,.png.jpge".Contains(System.IO.Path.GetExtension(photoFile).ToLower().Trim()))
- {
- Bitmap bmp = LYFZ.BLL.SelectPhotoHandling.GeneratePreviewBitmap(photoFile, 640, 960);
- photoFile = LYFZ.ImageFunction.ThumbImgae.SaveTemporaryCompressionImage(bmp, System.IO.Path.GetFileName(photoFile));
- }*/
- // 写入文件描述,这里设置一个通用的类型描述:application/octet-stream,具体的描述在注册表里有。
- string description = string.Format(
- "Content-Disposition: form-data; name=\"file\"; filename=\"{0}\"\r\n" +
- "Content-Type: application/octet-stream\r\n\r\n",
- Path.GetFileName(photoFile.Trim()));
- // 注意:这里如果不使用UTF-8,对于汉字会有乱码。
- byte[] header = Encoding.UTF8.GetBytes(description);
- stream.Write(header, 0, header.Length);
- // 写入文件内容
- byte[] body = File.ReadAllBytes(photoFile.Trim());
- stream.Write(body, 0, body.Length);
- /* if (".jpg,.png.jpge".Contains(System.IO.Path.GetExtension(photoFile).ToLower().Trim()))
- {
- LYFZ.ImageFunction.ThumbImgae.DeleteTemporaryCompressionImage(photoFile);
- }*/
- }
- // 写入结束标记
- boundaryBytes = Encoding.ASCII.GetBytes("\r\n--" + boundary + "--\r\n");
- stream.Write(boundaryBytes, 0, boundaryBytes.Length);
- stream.Close();
- try
- {
- // 开始发起请求,并获取服务器返回的结果。
- using (WebResponse response = request.GetResponse())
- {
- request.Timeout = 300000;
- using (StreamReader reader = new StreamReader(response.GetResponseStream(), encoding))
- {
- return reader.ReadToEnd();
- }
- }
- }
- catch (Exception ex){ return ex.Message; }
- }
- string Video_url = "";
- string picImagePath = "";
- List<string> appImageList = new List<string>();
- private void BtnListImgSelect_Click(object sender, EventArgs e)
- {
- OpenFileDialog open = new OpenFileDialog();
- open.Title = "选择图片";
- open.Multiselect = true;
- open.Filter = "图片|*.jpg;*.png;*.gif;*.jpeg;";
- if (open.ShowDialog() == DialogResult.OK)
- {
- appImageList.Clear();
- this.listImageList.Items.Clear();
- this.listImageList.Items.AddRange(open.FileNames);
- appImageList.AddRange(open.FileNames);
- }
- }
- private void BtnPicSelect_Click(object sender, EventArgs e)
- {
- OpenFileDialog open = new OpenFileDialog();
- open.Multiselect = false;
- open.Title = "选择图片";
- open.Filter = "图片|*.jpg;*.png;*.gif;*.jpeg;";
- if (open.ShowDialog() == DialogResult.OK)
- {
- this.txtPicImage.Text = open.FileName;
- picImagePath = open.FileName;
- }
- }
- /// <summary>
- /// 套系大类类型
- /// </summary>
- public int StrPackagesType;
- /// <summary>
- /// 是否保存
- /// </summary>
- public bool IsSaveed = false;
- /// <summary>
- /// 存储产品略图集合
- /// </summary>
- ImageList mlistImage = new ImageList();
- /// <summary>
- /// true为首次运行
- /// </summary>
- private bool IsFirstLoad = true;
- /// <summary>
- /// 窗体加载事件
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void PackagesGoodsSetFormMain_Load(object sender, EventArgs e)
- {
- this.Location = new Point(LYFZ.EnumPublic.FormLocation_X, LYFZ.EnumPublic.FormLocation_Y);
- this.Size = new Size(LYFZ.EnumPublic.FormSize_Width, LYFZ.EnumPublic.FormSize_Height);
- switch (LYFZ.Software.MainBusiness.CommonLogical.SuccessfulLogin.GetBusinessType())
- {
- case EnumPermissions.BusinessType.儿童版:
- this.rdoErTong.Checked = true;
- this.rdoHungSha.Hide();
- break;
- case EnumPermissions.BusinessType.婚纱版:
- this.rdoHungSha.Checked = true;
- this.rdoErTong.Hide();
- break;
- }
- if (this.StrPackagesType == 1)
- {
- // this.panelEx4.Visible = false;
- this.Text = "礼包套系商品设置";
- this.labelEx6.Text = "套系礼包商品";
- this.labelEx8.Text = "套系礼包服务";
- }
- else
- {
- this.txtIntoBottom.WaterText = "-1表示全送";
- }
- }
- /// <summary>
- /// 窗体加载事件
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void PackagesGoodsSetFormMain_Shown(object sender, EventArgs e)
- {
- dynamic returnData = null;
- string errorMsg = "";
- LYFZ.ComponentLibrary.FrmLoadHandling.LoadDoWorkMethod(delegate (object obj, BackgroundWorker backgroundWorker)
- {
- try
- {
- string postData = Newtonsoft.Json.JsonConvert.SerializeObject(new { page = 1 });
- string PostReturnString = frmMicroAppletAdmin.HttpWebRequestPOST(frmSynchronousData.categotyData, postData, _appLoginModel, Encoding.UTF8);
- if (PostReturnString.IndexOf("{") == 0)
- {
- dynamic postReturnObj = Newtonsoft.Json.JsonConvert.DeserializeObject(PostReturnString);
- if (Convert.ToInt32(postReturnObj["meta"]["code"]) == 200)
- {
- returnData = postReturnObj["body"]["data_list"];// Newtonsoft.Json.JsonConvert.SerializeObject(postReturnObj["body"]);
- }
- else
- {
- errorMsg = postReturnObj["meta"]["message"];
- }
- }
- else
- {
- errorMsg = PostReturnString;
- }
- }
- catch (Exception ex)
- {
- errorMsg = ex.Message;
- }
- });
-
- if (returnData != null)
- {
- try
- {
- foreach (dynamic itemObj in returnData)
- {
- ItemValue item = new ItemValue(Convert.ToInt32(itemObj.id), itemObj.name.ToString());
- this.cbxFengLie.Items.Add(item);
- }
- }
- catch (Exception ex)
- {
- MessageBoxCustom.Show(String.Format("绑定小程序套系分类时出错:{0}",ex.Message));
- }
- }
- else {
- MessageBoxCustom.Show(String.Format("获取小程序套系分类失败:{0}",errorMsg));
- }
- //获取绑定拍摄次数 获取绑定套系名称
- LYFZ.Software.MainBusiness.DoorCityProcess.PublicCodeClasses.BindComboBoxTreeView_PackagesCategoryAndName(this.cmbtreev_PackageName, StrParentCode: Enum.GetName(typeof(LYFZ.EnumPublic.EnumPackagesType), StrPackagesType).ToString().Trim());
- this.tabPage1.Parent = null;
- this.tabPage2.Parent = null;
- switch (LYFZ.Software.MainBusiness.CommonLogical.SuccessfulLogin.GetBusinessType())
- {
- case LYFZ.Software.MainBusiness.EnumPermissions.BusinessType.儿童版:
- if (!LYFZ.Software.MainBusiness.CommonLogical.SuccessfulLogin.IsEnablePhotoEdition)
- {
- this.tabPage2.Parent = this.TabControl;
- }
- else
- {
- this.tabPage1.Parent = this.TabControl;
- this.tabPage2.Parent = this.TabControl;
- }
- break;
- case LYFZ.Software.MainBusiness.EnumPermissions.BusinessType.婚纱版:
- this.tabPage1.Parent = this.TabControl;
- break;
- default:
- this.tabPage1.Parent = this.TabControl;
- this.tabPage2.Parent = this.TabControl;
- break;
- }
- #region 设置列表标题
- #region 商品表标题
- this.listViewData_Product.View = View.Details;
- this.listViewData_Product.GridLines = true;
- string[] StrColumns = "商品名称,数量,进货价格,销售单价".Split(',');
- int SurplusCount = 90 + 85 + 85 + 23;
- for (int i = 0; i < StrColumns.Length; i++)
- {
- ColumnHeader ch = new ColumnHeader();
- ch.Text = StrColumns[i].Trim();
- ch.TextAlign = HorizontalAlignment.Left;
- if (i == 0)
- { ch.Width = this.listViewData_Product.Width - SurplusCount; }
- else if (i == StrColumns.Length - 1)
- { ch.Width = 90; }
- else
- { ch.Width = 85; }
- switch (StrColumns[i].Trim())
- {
- case "进货价格":
- case "销售单价":
- ch.TextAlign = HorizontalAlignment.Right;
- break;
- default:
- ch.TextAlign = HorizontalAlignment.Center;
- break;
- }
- this.listViewData_Product.Columns.Add(ch);
- }
- this.mlistImage.ImageSize = new Size(25, 25);
- this.mlistImage.ColorDepth = ColorDepth.Depth32Bit;
- this.listViewData_Product.SmallImageList = mlistImage;
- this.listViewData_Product.MultiSelect = true;
- #endregion
- #region 服务表标题
- this.listViewData_Service.View = View.Details;
- this.listViewData_Service.GridLines = true;
- for (int i = 0; i < StrColumns.Length; i++)
- {
- ColumnHeader ch = new ColumnHeader();
- ch.Text = StrColumns[i].Trim();
- ch.TextAlign = HorizontalAlignment.Left;
- if (i == 0)
- {
- ch.Width = this.listViewData_Service.Width - SurplusCount;
- }
- else if (i == StrColumns.Length - 1)
- {
- ch.Width = 90;
- }
- else
- {
- ch.Width = 85;
- }
- switch (StrColumns[i].Trim())
- {
- case "进货价格":
- case "销售单价":
- ch.TextAlign = HorizontalAlignment.Right;
- break;
- default:
- ch.TextAlign = HorizontalAlignment.Center;
- break;
- }
- this.listViewData_Service.Columns.Add(ch);
- }
- this.listViewData_Service.SmallImageList = mlistImage;
- this.listViewData_Service.MultiSelect = true;
- #endregion
- #region 景点表标题
- this.listViewData_Sights.View = View.Details;
- this.listViewData_Sights.GridLines = true;
- ImageList imgList = new ImageList();
- imgList.ImageSize = new Size(1, 25);
- this.listViewData_Sights.SmallImageList = imgList;
- StrColumns = "景点名称,服装套数,成本单价,销售单价".Split(',');
- SurplusCount = 90 + 85 + 85 + 23;
- for (int i = 0; i < StrColumns.Length; i++)
- {
- ColumnHeader ch = new ColumnHeader();
- ch.Text = StrColumns[i].Trim();
- ch.TextAlign = HorizontalAlignment.Left;
- if (i == 0)
- {
- ch.Width = this.listViewData_Sights.Width - SurplusCount;
- }
- else if (i == StrColumns.Length - 1)
- {
- ch.Width = 90;
- }
- else
- {
- ch.Width = 85;
- }
- switch (StrColumns[i].Trim())
- {
- case "成本单价":
- case "销售单价":
- ch.TextAlign = HorizontalAlignment.Right;
- break;
- default:
- ch.TextAlign = HorizontalAlignment.Center;
- break;
- }
- this.listViewData_Sights.Columns.Add(ch);
- }
- #endregion
- #region 拍摄次数表标题
- this.listViewData_Stages.View = View.Details;
- this.listViewData_Stages.GridLines = true;
- this.listViewData_Stages.SmallImageList = imgList;
- StrColumns = "次数名称,入册,入底,服装套数".Split(',');
- for (int i = 0; i < StrColumns.Length; i++)
- {
- ColumnHeader ch = new ColumnHeader();
- ch.Text = StrColumns[i].Trim();
- switch (StrColumns[i].Trim())
- {
- case "次数名称": ch.Width = this.listViewData_Stages.Width - 270 - 23; break;
- case "入册": ch.Width = 90; break;
- case "入底": ch.Width = 90; break;
- case "服装套数": ch.Width = 90; break;
- }
- switch (StrColumns[i].Trim())
- {
- case "次数名称": ch.TextAlign = HorizontalAlignment.Left; break;
- case "入册":
- case "入底":
- case "服装套数": ch.TextAlign = HorizontalAlignment.Center; break;
- }
- this.listViewData_Stages.Columns.Add(ch);
- }
- #endregion
- #endregion
- this.IsFirstLoad = false;
- }
- LYFZ.Model.Model_ErpPackages packModel = null;
- //普通单
- List<string> PuTongJingDianList = new List<string>();
- int PuTongRuDiShu = 0;
- int PuTongRuCheShu = 0;
- int PuTongFuZhuangShu = 0;
- //儿童单
- List<string> ErTongJingDianList = new List<string>();
- int ErTongRuDiShu = 0;
- int ErTongRuCheShu = 0;
- int ErTongFuZhuangShu = 0;
- List<string> ShangPingList = new List<string>();
- List<string> HuFuList = new List<string>();
- /// <summary>
- /// 套系名称选择设置
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void cmbtreev_PackageName_ComboBoxTree_NodeMouseClick(object sender, TreeNodeMouseClickEventArgs e)
- {
- this.listViewData_Product.Items.Clear();
- this.listViewData_Product.Groups.Clear();
- this.listViewData_Service.Items.Clear();
- this.listViewData_Service.Groups.Clear();
- this.listViewData_Sights.Items.Clear();
- this.listViewData_Stages.Items.Clear();
- this.PuTongJingDianList.Clear();
- this.ErTongJingDianList.Clear();
- this.ShangPingList.Clear();
- this.HuFuList.Clear();
- PuTongRuDiShu = 0;
- PuTongRuCheShu = 0;
- PuTongFuZhuangShu = 0;
- ErTongRuDiShu = 0;
- ErTongRuCheShu = 0;
- ErTongFuZhuangShu = 0;
- packModel = null;
- // this.IsDataChange = false;
- //获取套系名称资料
- packModel = pkbll.GetModel("Pak_PackagesID", this.cmbtreev_PackageName.Tag.ToString().Trim());
- // DataTable dt = orbll.GetView_Custom("tb_ErpPackages", StrWhere: "Pak_PackagesID='" + this.cmbtreev_PackageName.Tag.ToString().Trim() + "'", ShowColumnName: "Pak_UnitPrice,Pak_IntoTheArchive,Pak_IntoTheBook").Tables[0];
- if (packModel.ID > 0)
- {
- this.lblPakUnitPrice.Text = "套系价格:" + packModel.Pak_UnitPrice.ToString();// dt.Rows[0]["Pak_UnitPrice"].ToString().Trim();
- this.txtIntoRegister.Text = packModel.Pak_IntoTheBook.ToString();// dt.Rows[0]["Pak_IntoTheBook"].ToString().Trim();
- this.txtIntoBottom.Text = packModel.Pak_IntoTheArchive.ToString();// dt.Rows[0]["Pak_IntoTheArchive"].ToString().Trim();
- this.PuTongRuDiShu = packModel.Pak_IntoTheArchive;
- this.PuTongRuCheShu = packModel.Pak_IntoTheBook;
- #region 景点与次数
- DataTable tblSights = orbll.GetView_Custom("tb_ErpPackagesGiftMerchandise Left Join tb_ErpTheScenery on tb_ErpTheScenery.ID = Pgm_ProductNumber", StrWhere: "Tsc_Name is not null And Pgm_PackagesCode = '" + this.cmbtreev_PackageName.Tag.ToString().Trim() + "' And Pgm_GiveType in (2,3)", ShowColumnName: "tb_ErpPackagesGiftMerchandise.ID,Pgm_GiveType,Pgm_PackagesCode,Pgm_ProductNumber,Pgm_Quantity,Tsc_Name,Tsc_CostPrice,Tsc_SalesPrice,Pgm_IntoRegisterQuantity,Pgm_IntoBottomQuantity").Tables[0];
- for (int i = 0; i < tblSights.Rows.Count; i++)
- {
- ListViewItem lvItem = new ListViewItem();
- lvItem.Tag = tblSights.Rows[i]["Pgm_ProductNumber"].ToString().Trim() + "|" + tblSights.Rows[i]["ID"].ToString().Trim();
- lvItem.Text = tblSights.Rows[i]["Tsc_Name"].ToString().Trim();
- if (tblSights.Rows[i]["Pgm_GiveType"].ToString().Trim() == "2")
- {
- this.PuTongJingDianList.Add(lvItem.Text);
- try
- {
- this.PuTongFuZhuangShu += Convert.ToInt32(tblSights.Rows[i]["Pgm_Quantity"].ToString());
-
- }
- catch { }
- ListViewItem.ListViewSubItem ListSubItem = new ListViewItem.ListViewSubItem();
- ListSubItem.Name = "服装套数";
- ListSubItem.Text = tblSights.Rows[i]["Pgm_Quantity"].ToString().Trim();
- lvItem.SubItems.Add(ListSubItem);
- ListSubItem = new ListViewItem.ListViewSubItem();
- ListSubItem.Name = "成本单价";
- ListSubItem.Text = tblSights.Rows[i]["Tsc_CostPrice"].ToString().Trim();
- lvItem.SubItems.Add(ListSubItem);
- ListSubItem = new ListViewItem.ListViewSubItem();
- ListSubItem.Name = "销售单价";
- ListSubItem.Text = tblSights.Rows[i]["Tsc_SalesPrice"].ToString().Trim();
- lvItem.SubItems.Add(ListSubItem);
- if ((this.listViewData_Sights.Items.Count % 2) > 0)
- { lvItem.BackColor = System.Drawing.Color.PapayaWhip; }
- else
- { lvItem.BackColor = System.Drawing.Color.PowderBlue; }
- this.listViewData_Sights.Items.Add(lvItem);
- }
- else if (tblSights.Rows[i]["Pgm_GiveType"].ToString().Trim() == "3")
- {
- this.ErTongJingDianList.Add(lvItem.Text);
- try
- {
- this.ErTongFuZhuangShu += Convert.ToInt32(tblSights.Rows[i]["Pgm_Quantity"].ToString());
- this.ErTongRuDiShu += Convert.ToInt32(tblSights.Rows[i]["Pgm_IntoBottomQuantity"].ToString());
- this.ErTongRuCheShu += Convert.ToInt32(tblSights.Rows[i]["Pgm_IntoRegisterQuantity"].ToString());
- }
- catch { }
- ListViewItem.ListViewSubItem ListSubItem = new ListViewItem.ListViewSubItem();
- ListSubItem.Name = "入册";
- ListSubItem.Text = tblSights.Rows[i]["Pgm_IntoRegisterQuantity"].ToString().Trim();
- lvItem.SubItems.Add(ListSubItem);
- ListSubItem = new ListViewItem.ListViewSubItem();
- ListSubItem.Name = "入底";
- ListSubItem.Text = tblSights.Rows[i]["Pgm_IntoBottomQuantity"].ToString().Trim();
- lvItem.SubItems.Add(ListSubItem);
- ListSubItem = new ListViewItem.ListViewSubItem();
- ListSubItem.Name = "服装套数";
- ListSubItem.Text = tblSights.Rows[i]["Pgm_Quantity"].ToString().Trim();
- lvItem.SubItems.Add(ListSubItem);
- if ((this.listViewData_Stages.Items.Count % 2) > 0)
- { lvItem.BackColor = System.Drawing.Color.PapayaWhip; }
- else
- { lvItem.BackColor = System.Drawing.Color.PowderBlue; }
- ListViewGroup man_lvg = new ListViewGroup();
- man_lvg.Tag = lvItem.Text;
- man_lvg.Name = lvItem.Text;
- man_lvg.Header = lvItem.Text;
- man_lvg.HeaderAlignment = HorizontalAlignment.Left;
- this.listViewData_Product.Groups.Add(man_lvg);
- man_lvg = new ListViewGroup();
- man_lvg.Tag = lvItem.Text;
- man_lvg.Name = lvItem.Text;
- man_lvg.Header = lvItem.Text;
- man_lvg.HeaderAlignment = HorizontalAlignment.Left;
- this.listViewData_Service.Groups.Add(man_lvg);
- this.listViewData_Stages.Items.Add(lvItem);
- }
- }
- #endregion
- #region 商品与服务
- if (this.tabPage2.Parent == null)
- {
- string StrTableName = "(select Prod_Class,Sc_ClassName,Pgm_GiveType,Pgm_PackagesCode from tb_ErpPackagesGiftMerchandise Left Join tb_ErpProduct on Prod_Number = Pgm_ProductNumber " +
- "Left Join tb_ErpSystemCategory on Prod_Class = Sc_ClassCode Group by Prod_Class,Sc_ClassName,Pgm_GiveType,Pgm_PackagesCode ) as tb";
- DataTable dtGroup = orbll.GetView_Custom(StrTableName, StrWhere: "Pgm_PackagesCode = '" + this.cmbtreev_PackageName.Tag.ToString().Trim() + "' And Pgm_GiveType in ('0','1')", ShowColumnName: "*").Tables[0];
- ListViewGroup man_lvg = null;
- for (int i = 0; i < dtGroup.Rows.Count; i++)
- {
- man_lvg = new ListViewGroup();
- man_lvg.Tag = dtGroup.Rows[i]["Sc_ClassName"].ToString().Trim();
- man_lvg.Name = dtGroup.Rows[i]["Prod_Class"].ToString().Trim();
- man_lvg.Header = dtGroup.Rows[i]["Sc_ClassName"].ToString().Trim();
- man_lvg.HeaderAlignment = HorizontalAlignment.Left;
- if (dtGroup.Rows[i]["Pgm_GiveType"].ToString().Trim() == "0")
- { this.listViewData_Product.Groups.Add(man_lvg); }
- else if (dtGroup.Rows[i]["Pgm_GiveType"].ToString().Trim() == "1")
- { this.listViewData_Service.Groups.Add(man_lvg); }
- }
- }
- else
- {
- ListViewGroup man_lvg = new ListViewGroup();
- man_lvg.Tag = "";
- man_lvg.Name = "NotGroup";
- man_lvg.Header = "未分组";
- man_lvg.HeaderAlignment = HorizontalAlignment.Left;
- this.listViewData_Product.Groups.Add(man_lvg);
- man_lvg = new ListViewGroup();
- man_lvg.Tag = "";
- man_lvg.Name = "NotGroup";
- man_lvg.Header = "未分组";
- man_lvg.HeaderAlignment = HorizontalAlignment.Left;
- this.listViewData_Service.Groups.Add(man_lvg);
- }
- DataTable tblProduct = orbll.GetView_Custom("tb_ErpPackagesGiftMerchandise Left Join tb_ErpProduct on Prod_Number = Pgm_ProductNumber", StrWhere: "Pgm_PackagesCode = '" + this.cmbtreev_PackageName.Tag.ToString().Trim() + "' And Pgm_GiveType in ('0','1')", ShowColumnName: "tb_ErpPackagesGiftMerchandise.ID,Pgm_GiveType,Pgm_PackagesCode,Pgm_Quantity,Prod_Number,Prod_Name,Prod_Unit,Prod_CostPrice,Prod_SalesPrice,Prod_Thumbnail,Prod_Class,Pgm_ProductGroupName").Tables[0];
- for (int i = 0; i < tblProduct.Rows.Count; i++)
- {
- if (!this.mlistImage.Images.Keys.Contains(tblProduct.Rows[i]["Prod_Number"].ToString().Trim()))
- {
- Image img = LYFZ.Software.MainBusiness.DoorCityProcess.PublicCodeClasses.GetProductImage(tblProduct.Rows[i]["Prod_Thumbnail"].ToString().Trim());
- this.mlistImage.Images.Add(tblProduct.Rows[i]["Prod_Number"].ToString().Trim(), img);
- }
- ListViewItem lvItem = new ListViewItem();
- lvItem.Tag = tblProduct.Rows[i]["Prod_Number"].ToString().Trim() + "|" + tblProduct.Rows[i]["ID"].ToString().Trim();
- lvItem.ImageKey = tblProduct.Rows[i]["Prod_Number"].ToString().Trim();
- lvItem.Text = tblProduct.Rows[i]["Prod_Name"].ToString().Trim();
- if (tblProduct.Rows[i]["Prod_Number"] == null || string.IsNullOrEmpty(tblProduct.Rows[i]["Prod_Number"].ToString()))
- {
- lvItem.Text = "此产品已在产品设置表中删除";
- lvItem.ForeColor = Color.Red;
- }
- ListViewItem.ListViewSubItem ListSubItem = new ListViewItem.ListViewSubItem();
- ListSubItem.Name = "数量";
- ListSubItem.Text = tblProduct.Rows[i]["Pgm_Quantity"].ToString().Trim();
- lvItem.SubItems.Add(ListSubItem);
- ListSubItem = new ListViewItem.ListViewSubItem();
- ListSubItem.Name = "进货价格";
- ListSubItem.Text = tblProduct.Rows[i]["Prod_CostPrice"].ToString().Trim();
- lvItem.SubItems.Add(ListSubItem);
- ListSubItem = new ListViewItem.ListViewSubItem();
- ListSubItem.Name = "销售单价";
- ListSubItem.Text = tblProduct.Rows[i]["Prod_SalesPrice"].ToString().Trim();
- lvItem.SubItems.Add(ListSubItem);
- if (tblProduct.Rows[i]["Pgm_GiveType"].ToString().Trim() == "0")
- {
- this.ShangPingList.Add(String.Format("{0} {1} {2}",lvItem.Text, tblProduct.Rows[i]["Pgm_Quantity"].ToString().Trim(), tblProduct.Rows[i]["Prod_Unit"].ToString().Trim()));
- if (this.tabPage2.Parent == null)
- {
- if (this.listViewData_Product.Groups.Count > 0)
- { this.listViewData_Product.Groups[tblProduct.Rows[i]["Prod_Class"].ToString().Trim()].Items.Add(lvItem); }
- }
- else
- {
- if (!string.IsNullOrEmpty(tblProduct.Rows[i]["Pgm_ProductGroupName"].ToString().Trim()))
- {
- if (this.listViewData_Product.Groups[tblProduct.Rows[i]["Pgm_ProductGroupName"].ToString().Trim()] != null)
- {
- this.listViewData_Product.Groups[tblProduct.Rows[i]["Pgm_ProductGroupName"].ToString().Trim()].Items.Add(lvItem);
- }
- else
- {
- this.listViewData_Product.Groups["NotGroup"].Items.Add(lvItem);
- }
- }
- else
- {
- this.listViewData_Product.Groups["NotGroup"].Items.Add(lvItem);
- }
- }
- this.listViewData_Product.Items.Add(lvItem);
- }
- else if (tblProduct.Rows[i]["Pgm_GiveType"].ToString().Trim() == "1")
- {
- this.HuFuList.Add(String.Format("{0} {1} {2}", lvItem.Text, tblProduct.Rows[i]["Pgm_Quantity"].ToString().Trim(), tblProduct.Rows[i]["Prod_Unit"].ToString().Trim()));
- if (this.tabPage2.Parent == null)
- {
- if (this.listViewData_Service.Groups[tblProduct.Rows[i]["Prod_Class"].ToString().Trim()] != null)
- { this.listViewData_Service.Groups[tblProduct.Rows[i]["Prod_Class"].ToString().Trim()].Items.Add(lvItem); }
- }
- else
- {
- if (!string.IsNullOrEmpty(tblProduct.Rows[i]["Pgm_ProductGroupName"].ToString().Trim()))
- {
- if (this.listViewData_Service.Groups.Count > 0 && this.listViewData_Service.Groups[tblProduct.Rows[i]["Pgm_ProductGroupName"].ToString().Trim()] != null)
- { this.listViewData_Service.Groups[tblProduct.Rows[i]["Pgm_ProductGroupName"].ToString().Trim()].Items.Add(lvItem); }
- else
- { this.listViewData_Service.Groups["NotGroup"].Items.Add(lvItem); }
- }
- else
- { this.listViewData_Service.Groups["NotGroup"].Items.Add(lvItem); }
- }
- this.listViewData_Service.Items.Add(lvItem);
- }
- }
- this.ListViewDrawSingleOrDoubleRows(ListViewType.套系商品);
- this.ListViewDrawSingleOrDoubleRows(ListViewType.套系服务);
- #endregion
- }
- else
- {
- this.lblPakUnitPrice.Text = "套系价格:0";
- MessageBoxCustom.Show(this.cmbtreev_PackageName.Text.ToString() + " 此类型无套系名称!请添加套系名称");
- this.cmbtreev_PackageName.SetTextAndTag_ValueNull();
- }
- this.GetSeriesCostsPriceStatistics();
-
- }
-
- /// <summary>
- /// 关闭
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void btnCloseed_Click(object sender, EventArgs e)
- {
- this.Close();
- }
- /// <summary>
- /// 选择版本获取商品成本价,卖价
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void TabControl_SelectedIndexChanged(object sender, EventArgs e)
- {
- if (!this.IsFirstLoad)
- {
- if (this.TabControl.SelectedTab != null)
- {
-
- this.GetSeriesCostsPriceStatistics();
- }
- }
- }
-
-
- #region
- /// <summary>
- /// 获取套系成本统计
- /// </summary>
- void GetSeriesCostsPriceStatistics()
- {
- decimal CostPrice = 0;
- decimal SalePrice = 0;
- if (this.TabControl.SelectedTab.Name.Trim() == "tabPage1")
- {
- this.GetProductPrice(ref CostPrice, ref SalePrice);
- this.GetServicePrice(ref CostPrice, ref SalePrice);
- this.GetSightsPrice(ref CostPrice, ref SalePrice);
- this.lblCostPrice.Text = Convert.ToDecimal(CostPrice).ToString("N2");
- this.lblSalePrice.Text = Convert.ToDecimal(SalePrice).ToString("N2");
- }
- else
- {
- this.GetProductPrice(ref CostPrice, ref SalePrice);
- this.GetServicePrice(ref CostPrice, ref SalePrice);
- this.lblCostPrice.Text = Convert.ToDecimal(CostPrice).ToString("N2");
- this.lblSalePrice.Text = Convert.ToDecimal(SalePrice).ToString("N2");
- }
-
- }
- decimal ConvertToDecimal(object obj)
- {
- try
- {
- if (obj != null && !string.IsNullOrEmpty(obj.ToString()))
- {
- decimal outdec = 0.00m;
- decimal.TryParse(obj.ToString().Trim(), out outdec);
- return outdec;
- }
- else
- {
- return 0.00m;
- }
- }
- catch
- {
- return 0.00m;
- }
- }
- /// <summary>
- /// 获取商品成本价
- /// </summary>
- /// <param name="CostPrice"></param>
- /// <param name="SalesPrice"></param>
- void GetProductPrice(ref decimal CostPrice, ref decimal SalesPrice)
- {
- for (int i = 0; i < this.listViewData_Product.Items.Count; i++)
- {
- CostPrice += ConvertToDecimal(this.listViewData_Product.Items[i].SubItems["数量"].Text.Trim()) * ConvertToDecimal(this.listViewData_Product.Items[i].SubItems["进货价格"].Text.Trim());
- SalesPrice += ConvertToDecimal(this.listViewData_Product.Items[i].SubItems["数量"].Text.Trim()) * ConvertToDecimal(this.listViewData_Product.Items[i].SubItems["销售单价"].Text.Trim());
- }
- }
- /// <summary>
- /// 获取服务成本价
- /// </summary>
- /// <param name="CostPrice"></param>
- /// <param name="SalesPrice"></param>
- void GetServicePrice(ref decimal CostPrice, ref decimal SalesPrice)
- {
- for (int i = 0; i < this.listViewData_Service.Items.Count; i++)
- {
- CostPrice += ConvertToDecimal(this.listViewData_Service.Items[i].SubItems["数量"].Text.Trim()) * ConvertToDecimal(this.listViewData_Service.Items[i].SubItems["进货价格"].Text.Trim());
- SalesPrice += ConvertToDecimal(this.listViewData_Service.Items[i].SubItems["数量"].Text.Trim()) * ConvertToDecimal(this.listViewData_Service.Items[i].SubItems["销售单价"].Text.Trim());
- }
- }
- /// <summary>
- /// 获取景点成本价
- /// </summary>
- /// <param name="CostPrice"></param>
- /// <param name="SalesPrice"></param>
- void GetSightsPrice(ref decimal CostPrice, ref decimal SalesPrice)
- {
- for (int i = 0; i < this.listViewData_Sights.Items.Count; i++)
- {
- CostPrice += ConvertToDecimal(this.listViewData_Sights.Items[i].SubItems["成本单价"].Text.Trim());
- SalesPrice += ConvertToDecimal(this.listViewData_Sights.Items[i].SubItems["销售单价"].Text.Trim());
- }
- }
- /// <summary>
- /// 绘制列表单双行
- /// </summary>
- /// <param name="ProcessType"></param>
- void ListViewDrawSingleOrDoubleRows(ListViewType ProcessType)
- {
- if (ProcessType == ListViewType.套系商品)
- {
- LYFZ.Software.MainBusiness.DoorCityProcess.PublicCodeClasses.ListViewDrawSingleOrDoubleRows(this.listViewData_Product);
- }
- else if (ProcessType == ListViewType.套系服务)
- {
- LYFZ.Software.MainBusiness.DoorCityProcess.PublicCodeClasses.ListViewDrawSingleOrDoubleRows(this.listViewData_Service);
- }
- else if (ProcessType == ListViewType.套系景点)
- {
- LYFZ.Software.MainBusiness.DoorCityProcess.PublicCodeClasses.ListViewDrawSingleOrDoubleRows(this.listViewData_Sights);
- }
- else if (ProcessType == ListViewType.套系次数)
- {
- LYFZ.Software.MainBusiness.DoorCityProcess.PublicCodeClasses.ListViewDrawSingleOrDoubleRows(this.listViewData_Stages);
- }
- }
- #endregion
- enum ListViewType
- {
- 套系商品,
- 套系服务,
- 套系景点,
- 套系次数
- }
- }
- }
|