66 lines
2.1 KiB
C#
66 lines
2.1 KiB
C#
using AIMSBLL;
|
|
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 AIMS.OperationFront.UI
|
|
{
|
|
public partial class frmExeOperationPlan : Form
|
|
{
|
|
public frmExeOperationPlan()
|
|
{
|
|
InitializeComponent();
|
|
}
|
|
private void frmExeOperationPlan_Load(object sender, EventArgs e)
|
|
{
|
|
dgv1.BackgroundColor = System.Drawing.Color.Snow;
|
|
|
|
dtpBegInDate.Value = DateTime.Parse(dtpBegInDate.Value.ToString("yyyy-MM-dd"));
|
|
dtpEndDate.Value = DateTime.Parse(dtpEndDate.Value.ToString("yyyy-MM-dd")).AddDays(4);
|
|
btnFind_Click(null, null);
|
|
|
|
}
|
|
private void tsbExe_Click(object sender, EventArgs e)
|
|
{
|
|
for (int i = 0; i < dgv1.Rows.Count; i++)
|
|
{
|
|
if (bool.Parse(this.dgv1.Rows[i].Cells["CheckBoxColumn"].EditedFormattedValue.ToString()))
|
|
{
|
|
int ApplyId = int.Parse(dgv1.Rows[i].Cells["ApplyIdColumn1"].Value.ToString());
|
|
|
|
BOperationApply.UpdateApplyState(ApplyId, 4);
|
|
}
|
|
}
|
|
MessageBox.Show("执行成功!", "系统提示");
|
|
Close();
|
|
}
|
|
|
|
private void tsbExit_Click(object sender, EventArgs e)
|
|
{
|
|
Close();
|
|
}
|
|
|
|
private void tsbSet_Click(object sender, EventArgs e)
|
|
{
|
|
}
|
|
|
|
private void btnFind_Click(object sender, EventArgs e)
|
|
{
|
|
DataTable dt = BOperationApply.GetOperationFrontDataTable(dtpBegInDate.Value.ToString("yyyy-MM-dd"), dtpEndDate.Value.ToString("yyyy-MM-dd"));
|
|
DataTable Newdt = AIMSExtension.PublicMethod.GetNewDataTable(dt, "OperationType <>'特急' and State IN ('预排程')", "");
|
|
dgv1.DataSource = Newdt;
|
|
for (int i = 0; i < dgv1.Rows.Count; i++)
|
|
{
|
|
dgv1.Rows[i].Cells["CheckBoxColumn"].Value = true;
|
|
}
|
|
}
|
|
|
|
|
|
}
|
|
}
|