123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446 |
- 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;
- namespace LYFZ.Software.MainBusiness.CameraControlBook.SuperSmallForm
- {
- public partial class UnityArrangeWorkSuperSmallForm : LYFZ.Software.UI.CameraControlBook.SuperSmallForm.UnityArrangeWorkSuperSmallForm
- {
- public UnityArrangeWorkSuperSmallForm()
- {
- this.Load += UnityArrangeWorkSuperSmallForm_Load;
- this.Shown += UnityArrangeWorkSuperSmallForm_Shown;
- this.btnSaveed.Click += btnSaveed_Click;
- this.btnCancel.Click += btnCancel_Click;
- this.btnBootDivisionName.Click += btnBootDivisionName_Click;
- this.btnClothingName.Click += btnClothingName_Click;
- this.btnFilmSelectionName.Click += btnFilmSelectionName_Click;
- this.btnLookDesignName.Click += btnLookDesignName_Click;
- this.btnMakeupArtistName.Click += btnMakeupArtistName_Click;
- this.btnMakeupAssistantName.Click += btnMakeupAssistantName_Click;
- this.btnPhotographerName.Click += btnPhotographerName_Click;
- this.btnPhotographyAssistantName.Click += btnPhotographyAssistantName_Click;
- this.btnPickupName.Click += btnPickupName_Click;
- this.btnServiceName1.Click += btnServiceName1_Click;
- this.btnServiceName2.Click += btnServiceName2_Click;
- this.chkDateTime.Click += chkDateTime_Click;
- this.chkBootDivisionName.Click += chkBootDivisionName_Click;
- this.chkClothingName.Click += chkClothingName_Click;
- this.chkFilmSelectionName.Click += chkFilmSelectionName_Click;
- this.chkLookDesignName.Click += chkLookDesignName_Click;
- this.chkMakeupArtistName.Click += chkMakeupArtistName_Click;
- this.chkMakeupAssistantName.Click += chkMakeupAssistantName_Click;
- this.chkPhotographerName.Click += chkPhotographerName_Click;
- this.chkPhotographyAssistantName.Click += chkPhotographyAssistantName_Click;
- this.chkPickupName.Click += chkPickupName_Click;
- this.chkServiceName1.Click += chkServiceName1_Click;
- this.chkServiceName2.Click += chkServiceName2_Click;
- }
- /// <summary>
- /// 是否保存
- /// </summary>
- public bool IsSaveed = false;
- /// <summary>
- /// 返回的数据
- /// </summary>
- public LYFZ.BLL.CameraControlBookUnityArrangeWorkModel UnityArrangeWorkModel;
- /// <summary>
- /// 加载类型
- /// </summary>
- public LYFZ.EnumPublic.EnumUnityArrangeWorkType UnityArrangeWorkType;
- /// <summary>
- /// 窗体加载事件
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void UnityArrangeWorkSuperSmallForm_Load(object sender, EventArgs e)
- {
- switch (this.UnityArrangeWorkType)
- {
- case EnumPublic.EnumUnityArrangeWorkType.拍照客人:
- this.panelPhotographerName.Visible = true;
- this.panelPhotographyAssistantName.Visible = true;
- this.panelMakeupArtistName.Visible = true;
- this.panelMakeupAssistantName.Visible = true;
- this.panelBootDivisionName.Visible = true;
- this.panelBootDivisionAssistantName.Visible = true;
- break;
- case EnumPublic.EnumUnityArrangeWorkType.选片客人:
- this.panelFilmSelectionName.Visible = true;
- break;
- case EnumPublic.EnumUnityArrangeWorkType.看版客人:
- this.panelLookDesignName.Visible = true;
- break;
- case EnumPublic.EnumUnityArrangeWorkType.取件客人:
- this.panelPickupName.Visible = true;
- break;
- case EnumPublic.EnumUnityArrangeWorkType.服务客人:
- this.panelServiceName1.Visible = true;
- this.panelServiceName2.Visible = true;
- break;
- case EnumPublic.EnumUnityArrangeWorkType.选礼服客人:
- this.panelClothingName.Visible = true;
- break;
- }
- }
- /// <summary>
- /// 窗体加载事件
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void UnityArrangeWorkSuperSmallForm_Shown(object sender, EventArgs e)
- {
- this.dtpDate.DateValue = SDateTime.Now.ToString();
- }
- /// <summary>
- /// 保存
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void btnSaveed_Click(object sender, EventArgs e)
- {
- LYFZ.BLL.CameraControlBookUnityArrangeWorkModel WorkModel = new BLL.CameraControlBookUnityArrangeWorkModel();
- switch (this.UnityArrangeWorkType)
- {
- case EnumPublic.EnumUnityArrangeWorkType.拍照客人:
- WorkModel.IsPhotographerName = this.chkPhotographerName.Checked;
- WorkModel.PhotographerName = this.txtPhotographerName.Text.Trim();
- WorkModel.PhotographerTag = this.txtPhotographerName.Tag.ToString().Trim();
- WorkModel.IsPhotographyAssistantName = this.chkPhotographyAssistantName.Checked;
- WorkModel.PhotographyAssistantName = this.txtPhotographyAssistantName.Text.Trim();
- WorkModel.PhotographyAssistantTag = this.txtPhotographyAssistantName.Tag.ToString().Trim();
- WorkModel.IsMakeupArtistName = this.chkMakeupArtistName.Checked;
- WorkModel.MakeupArtistName = this.txtMakeupArtistName.Text.Trim();
- WorkModel.MakeupArtistTag = this.txtMakeupArtistName.Tag.ToString().Trim();
- WorkModel.IsMakeupAssistantName = this.chkMakeupAssistantName.Checked;
- WorkModel.MakeupAssistantName = this.txtMakeupAssistantName.Text.Trim();
- WorkModel.MakeupAssistantTag = this.txtMakeupAssistantName.Tag.ToString().Trim();
- WorkModel.IsBootDivisionName = this.chkBootDivisionName.Checked;
- WorkModel.BootDivisionName = this.txtBootDivisionName.Text.Trim();
- WorkModel.BootDivisionTag = this.txtBootDivisionName.Tag.ToString().Trim();
- WorkModel.IsBootDivisionAssistantName = this.chkBootDivisionAssistantName.Checked;
- WorkModel.BootDivisionAssistantName = this.txtBootDivisionAssistantName.Text.Trim();
- WorkModel.BootDivisionAssistantTag = this.txtBootDivisionAssistantName.Tag.ToString().Trim();
- break;
- case EnumPublic.EnumUnityArrangeWorkType.选片客人:
- WorkModel.IsFilmSelectionName = this.chkFilmSelectionName.Checked;
- WorkModel.FilmSelectionName = this.txtFilmSelectionName.Text.Trim();
- WorkModel.FilmSelectionTag = this.txtFilmSelectionName.Tag.ToString().Trim();
- break;
- case EnumPublic.EnumUnityArrangeWorkType.看版客人:
- WorkModel.IsLookDesignName = this.chkLookDesignName.Checked;
- WorkModel.LookDesignName = this.txtLookDesignName.Text.Trim();
- WorkModel.LookDesignTag = this.txtLookDesignName.Tag.ToString().Trim();
- break;
- case EnumPublic.EnumUnityArrangeWorkType.取件客人:
- WorkModel.IsPickupName = this.chkPickupName.Checked;
- WorkModel.PickupName = this.txtPickupName.Text.Trim();
- WorkModel.PickupTag = this.txtPickupName.Tag.ToString().Trim();
- break;
- case EnumPublic.EnumUnityArrangeWorkType.服务客人:
- WorkModel.IsServiceName1 = this.chkServiceName1.Checked;
- WorkModel.ServiceName1 = this.txtServiceName1.Text.Trim();
- WorkModel.ServiceTag1 = this.txtServiceName1.Tag.ToString().Trim();
- WorkModel.IsServiceName2 = this.chkServiceName2.Checked;
- WorkModel.ServiceName2 = this.txtServiceName2.Text.Trim();
- WorkModel.ServiceTag2 = this.txtServiceName2.Tag.ToString().Trim();
- break;
- case EnumPublic.EnumUnityArrangeWorkType.选礼服客人:
- WorkModel.IsClothingName = this.chkClothingName.Checked;
- WorkModel.ClothingName = this.txtClothingName.Text.Trim();
- WorkModel.ClothingTag = this.txtClothingName.Tag.ToString().Trim();
- break;
- }
- if (!string.IsNullOrEmpty(this.dtpDate.DateValue.Trim()) && this.chkDateTime.Checked)
- {
- try
- {
- if (!string.IsNullOrEmpty(this.txtTime.Text.Trim()) && this.txtTime.Text.Trim() != ":")
- {
- Convert.ToDateTime(SDateTime.Now.ToString("yyyy-MM-dd") + " " + this.txtTime.Text.Trim());
- WorkModel.StrDateTime = this.dtpDate.DateValue.Trim() + " " + this.txtTime.Text.Trim();
- }
- else
- { WorkModel.StrDateTime = this.dtpDate.DateValue.Trim(); }
- }
- catch
- { MessageBoxCustom.Show("时间格式出错!"); return; }
- }
- WorkModel.IsDateTime = this.chkDateTime.Checked;
- this.UnityArrangeWorkModel = WorkModel;
- this.IsSaveed = true;
- this.Close();
- }
- /// <summary>
- /// 取消
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void btnCancel_Click(object sender, EventArgs e)
- {
- this.Close();
- }
- /// <summary>
- /// 选择人员
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void btnBootDivisionName_Click(object sender, EventArgs e)
- {
- LYFZ.Software.MainBusiness.CameraControlBook.PublicClass.GetSelectWorkPerson(this.dtpDate.DateValue, this.txtBootDivisionName, LYFZ.EnumPublic.EnumWorkPersonType.引导师);
- }
- /// <summary>
- /// 选择人员
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void btnClothingName_Click(object sender, EventArgs e)
- {
- LYFZ.Software.MainBusiness.CameraControlBook.PublicClass.GetSelectWorkPerson(this.dtpDate.DateValue, this.txtClothingName, LYFZ.EnumPublic.EnumWorkPersonType.选礼服师);
- }
- /// <summary>
- /// 选择人员
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void btnFilmSelectionName_Click(object sender, EventArgs e)
- {
- LYFZ.Software.MainBusiness.CameraControlBook.PublicClass.GetSelectWorkPerson(this.dtpDate.DateValue, this.txtFilmSelectionName, LYFZ.EnumPublic.EnumWorkPersonType.选片师);
- }
- /// <summary>
- /// 选择人员
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void btnLookDesignName_Click(object sender, EventArgs e)
- {
- LYFZ.Software.MainBusiness.CameraControlBook.PublicClass.GetSelectWorkPerson(this.dtpDate.DateValue, this.txtLookDesignName, LYFZ.EnumPublic.EnumWorkPersonType.看设计师);
- }
- /// <summary>
- /// 选择人员
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void btnMakeupArtistName_Click(object sender, EventArgs e)
- {
- LYFZ.Software.MainBusiness.CameraControlBook.PublicClass.GetSelectWorkPerson(this.dtpDate.DateValue, this.txtMakeupArtistName, LYFZ.EnumPublic.EnumWorkPersonType.化妆师);
- }
- /// <summary>
- /// 选择人员
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void btnMakeupAssistantName_Click(object sender, EventArgs e)
- {
- LYFZ.Software.MainBusiness.CameraControlBook.PublicClass.GetSelectWorkPerson(this.dtpDate.DateValue, this.txtMakeupAssistantName, LYFZ.EnumPublic.EnumWorkPersonType.化妆助理);
- }
- /// <summary>
- /// 选择人员
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void btnPhotographerName_Click(object sender, EventArgs e)
- {
- LYFZ.Software.MainBusiness.CameraControlBook.PublicClass.GetSelectWorkPerson(this.dtpDate.DateValue, this.txtPhotographerName, LYFZ.EnumPublic.EnumWorkPersonType.摄影师);
- }
- /// <summary>
- /// 选择人员
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void btnPhotographyAssistantName_Click(object sender, EventArgs e)
- {
- LYFZ.Software.MainBusiness.CameraControlBook.PublicClass.GetSelectWorkPerson(this.dtpDate.DateValue, this.txtPhotographyAssistantName, LYFZ.EnumPublic.EnumWorkPersonType.摄影助理);
- }
- /// <summary>
- /// 选择人员
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void btnPickupName_Click(object sender, EventArgs e)
- {
- LYFZ.Software.MainBusiness.CameraControlBook.PublicClass.GetSelectWorkPerson(this.dtpDate.DateValue, this.txtPickupName, LYFZ.EnumPublic.EnumWorkPersonType.取件师);
- }
- /// <summary>
- /// 选择人员
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void btnServiceName1_Click(object sender, EventArgs e)
- {
- LYFZ.Software.MainBusiness.CameraControlBook.PublicClass.GetSelectWorkPerson(this.dtpDate.DateValue, this.txtServiceName1, LYFZ.EnumPublic.EnumWorkPersonType.服务师1);
- }
- /// <summary>
- /// 选择人员
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void btnServiceName2_Click(object sender, EventArgs e)
- {
- LYFZ.Software.MainBusiness.CameraControlBook.PublicClass.GetSelectWorkPerson(this.dtpDate.DateValue, this.txtServiceName2, LYFZ.EnumPublic.EnumWorkPersonType.服务师1);
- }
- /// <summary>
- ///
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void chkDateTime_Click(object sender, EventArgs e)
- {
- if (this.chkDateTime.Checked)
- {
- this.dtpDate.Enabled = true;
- this.txtTime.ReadOnly = false;
- }
- else
- {
- this.dtpDate.Enabled = false;
- this.txtTime.ReadOnly = true;
- }
- }
- /// <summary>
- ///
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void chkBootDivisionName_Click(object sender, EventArgs e)
- {
- if (this.chkBootDivisionName.Checked)
- { this.btnBootDivisionName.Enabled = true; }
- else
- { this.btnBootDivisionName.Enabled = false; }
- }
- /// <summary>
- ///
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void chkClothingName_Click(object sender, EventArgs e)
- {
- if (this.chkClothingName.Checked)
- { this.btnClothingName.Enabled = true; }
- else
- { this.btnClothingName.Enabled = false; }
- }
- /// <summary>
- ///
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void chkFilmSelectionName_Click(object sender, EventArgs e)
- {
- if (this.chkFilmSelectionName.Checked)
- { this.btnFilmSelectionName.Enabled = true; }
- else
- { this.btnFilmSelectionName.Enabled = false; }
- }
- /// <summary>
- ///
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void chkLookDesignName_Click(object sender, EventArgs e)
- {
- if (this.chkLookDesignName.Checked)
- { this.btnLookDesignName.Enabled = true; }
- else
- { this.btnLookDesignName.Enabled = false; }
- }
- /// <summary>
- ///
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void chkMakeupArtistName_Click(object sender, EventArgs e)
- {
- if (this.chkMakeupArtistName.Checked)
- { this.btnMakeupArtistName.Enabled = true; }
- else
- { this.btnMakeupArtistName.Enabled = false; }
- }
- /// <summary>
- ///
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void chkMakeupAssistantName_Click(object sender, EventArgs e)
- {
- if (this.chkMakeupAssistantName.Checked)
- { this.btnMakeupAssistantName.Enabled = true; }
- else
- { this.btnMakeupAssistantName.Enabled = false; }
- }
- /// <summary>
- ///
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void chkPhotographerName_Click(object sender, EventArgs e)
- {
- if (this.chkPhotographerName.Checked)
- { this.btnPhotographerName.Enabled = true; }
- else
- { this.btnPhotographerName.Enabled = false; }
- }
- /// <summary>
- ///
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void chkPhotographyAssistantName_Click(object sender, EventArgs e)
- {
- if (this.chkPhotographyAssistantName.Checked)
- { this.btnPhotographyAssistantName.Enabled = true; }
- else
- { this.btnPhotographyAssistantName.Enabled = false; }
- }
- /// <summary>
- ///
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void chkPickupName_Click(object sender, EventArgs e)
- {
- if (this.chkPickupName.Checked)
- { this.btnPickupName.Enabled = true; }
- else
- { this.btnPickupName.Enabled = false; }
- }
- /// <summary>
- ///
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void chkServiceName1_Click(object sender, EventArgs e)
- {
- if (this.chkServiceName1.Checked)
- { this.btnServiceName1.Enabled = true; }
- else
- { this.btnServiceName1.Enabled = false; }
- }
- /// <summary>
- ///
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- void chkServiceName2_Click(object sender, EventArgs e)
- {
- if (this.chkServiceName2.Checked)
- { this.btnServiceName2.Enabled = true; }
- else
- { this.btnServiceName2.Enabled = false; }
- }
- }
- }
|