117 lines
2.9 KiB
C#
117 lines
2.9 KiB
C#
|
using System;
|
|||
|
using System.Collections.Generic;
|
|||
|
using System.ComponentModel;
|
|||
|
using System.Data;
|
|||
|
using System.Drawing;
|
|||
|
using System.Text;
|
|||
|
using System.Linq;
|
|||
|
using System.Threading.Tasks;
|
|||
|
using System.Windows.Forms;
|
|||
|
using DevExpress.XtraEditors;
|
|||
|
using UI.Framework.Forms;
|
|||
|
using Activity.Properties;
|
|||
|
using Activity.Entitys;
|
|||
|
|
|||
|
namespace Activity
|
|||
|
{
|
|||
|
public partial class EditActivityForm : BaseForm
|
|||
|
{
|
|||
|
public EditActivityForm()
|
|||
|
{
|
|||
|
InitializeComponent();
|
|||
|
this.Text = Resources.EditActivityFormTitle;
|
|||
|
}
|
|||
|
|
|||
|
private void EditActivityForm_Load(object sender, EventArgs e)
|
|||
|
{
|
|||
|
try
|
|||
|
{
|
|||
|
|
|||
|
|
|||
|
}
|
|||
|
catch (Exception ex)
|
|||
|
{
|
|||
|
ShowError(ex);
|
|||
|
}
|
|||
|
|
|||
|
}
|
|||
|
|
|||
|
#region 右击菜单 奖品操作
|
|||
|
private void 增加奖品ToolStripMenuItem_Click(object sender, EventArgs e)
|
|||
|
{
|
|||
|
try
|
|||
|
{
|
|||
|
|
|||
|
|
|||
|
}
|
|||
|
catch (Exception ex)
|
|||
|
{
|
|||
|
ShowError(ex);
|
|||
|
}
|
|||
|
}
|
|||
|
|
|||
|
private void 修改选中项ToolStripMenuItem_Click(object sender, EventArgs e)
|
|||
|
{
|
|||
|
try
|
|||
|
{
|
|||
|
|
|||
|
|
|||
|
}
|
|||
|
catch (Exception ex)
|
|||
|
{
|
|||
|
ShowError(ex);
|
|||
|
}
|
|||
|
}
|
|||
|
|
|||
|
private void 删除选中项ToolStripMenuItem_Click(object sender, EventArgs e)
|
|||
|
{
|
|||
|
try
|
|||
|
{
|
|||
|
|
|||
|
|
|||
|
}
|
|||
|
catch (Exception ex)
|
|||
|
{
|
|||
|
ShowError(ex);
|
|||
|
}
|
|||
|
}
|
|||
|
#endregion
|
|||
|
|
|||
|
|
|||
|
private List<trophy_info> trophyList = new List<trophy_info>();
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// 关闭前保存数据
|
|||
|
/// </summary>
|
|||
|
/// <param name="sender"></param>
|
|||
|
/// <param name="e"></param>
|
|||
|
private void EditActivityForm_FormClosing(object sender, FormClosingEventArgs e)
|
|||
|
{
|
|||
|
try
|
|||
|
{
|
|||
|
fl_plugin_activity_info activity = new fl_plugin_activity_info()
|
|||
|
{
|
|||
|
activity_name = tbx_ActivityName.Text.Trim(),
|
|||
|
time_begin = DateTime.Parse(dtp_Begin.Text),
|
|||
|
time_end = DateTime.Parse(dtp_End.Text),
|
|||
|
opening_time = DateTime.Parse(dtp_OpeningTime.Text),
|
|||
|
amount = cbx_Amount.Checked,
|
|||
|
order_amount = (double)nud_Amount.Value,
|
|||
|
grade = cbx_Grade.Checked,
|
|||
|
grade_id = -1,//TODO
|
|||
|
order_state = cbx_OrderState.Checked,
|
|||
|
account_paid = cbx_AccountPaid.Checked,
|
|||
|
freezing = cbx_Freezing.Checked,
|
|||
|
settled = cbx_Settled.Checked,
|
|||
|
trophyjson = "",//TODO
|
|||
|
activity_state = Api.Framework.Enums.SwitchType.关闭//TODO
|
|||
|
|
|||
|
};
|
|||
|
}
|
|||
|
catch (Exception ex)
|
|||
|
{
|
|||
|
ShowError(ex);
|
|||
|
}
|
|||
|
}
|
|||
|
}
|
|||
|
}
|