Permalink
Browse files

巡检计划

  • Loading branch information...
1 parent 0b0a89b commit 1f41761f63f41e953c4a1a2b139355d47c380e42 qicb committed Oct 30, 2012
View
@@ -14,7 +14,7 @@ static void Main()
{
Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
- Application.Run(new frmain());
+ Application.Run(new frMain());
}
}
}
@@ -111,11 +111,11 @@
<Compile Include="frmAddTask.Designer.cs">
<DependentUpon>frmAddTask.cs</DependentUpon>
</Compile>
- <Compile Include="frmain.cs">
+ <Compile Include="frMain.cs">
<SubType>Form</SubType>
</Compile>
- <Compile Include="frmain.Designer.cs">
- <DependentUpon>frmain.cs</DependentUpon>
+ <Compile Include="frMain.Designer.cs">
+ <DependentUpon>frMain.cs</DependentUpon>
</Compile>
<Compile Include="frmAddItem.cs">
<SubType>Form</SubType>
@@ -191,8 +191,8 @@
<EmbeddedResource Include="frmAddTask.resx">
<DependentUpon>frmAddTask.cs</DependentUpon>
</EmbeddedResource>
- <EmbeddedResource Include="frmain.resx">
- <DependentUpon>frmain.cs</DependentUpon>
+ <EmbeddedResource Include="frMain.resx">
+ <DependentUpon>frMain.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="frmAddItem.resx">
<DependentUpon>frmAddItem.cs</DependentUpon>

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
@@ -17,24 +17,6 @@ public frmAddPlanToTask()
InitializeComponent();
}
-
- private void dgvPlan_CellContentClick(object sender, DataGridViewCellEventArgs e)
- {
- if (e.RowIndex < 0) return;
- getDgvTask(dgvPlan.Rows[e.RowIndex].Cells[1].Value.ToString());
- if (e.ColumnIndex == 0)
- {
- if ((bool)dgvPlan.Rows[e.RowIndex].Cells[0].EditedFormattedValue == false)
- {
- dgvPlan.Rows[e.RowIndex].Cells[0].Value = true;
- }
- else
- {
- dgvPlan.Rows[e.RowIndex].Cells[0].Value = false;
- }
- }
- }
-
private void btnDown_Click(object sender, EventArgs e)
{
string strIDs = "";
@@ -142,5 +124,22 @@ private void cboState_SelectedIndexChanged(object sender, EventArgs e)
}
getDgvPlan();
}
+
+ private void dgvPlan_CellClick(object sender, DataGridViewCellEventArgs e)
+ {
+ if (e.RowIndex < 0) return;
+ getDgvTask(dgvPlan.Rows[e.RowIndex].Cells[1].Value.ToString());
+ if (e.ColumnIndex == 0)
+ {
+ if ((bool)dgvPlan.Rows[e.RowIndex].Cells[0].EditedFormattedValue == false)
+ {
+ dgvPlan.Rows[e.RowIndex].Cells[0].Value = true;
+ }
+ else
+ {
+ dgvPlan.Rows[e.RowIndex].Cells[0].Value = false;
+ }
+ }
+ }
}
}

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
@@ -49,6 +49,11 @@ private void btnSave_Click(object sender, EventArgs e)
MessageBox.Show("请确保没有空值");
return;
}
+ if (dtpStart.Value <= dtpEffect.Value || dtpStart.Value >= dtpIneffect.Value || dtpEnd.Value <= dtpEffect.Value || dtpEnd.Value >= dtpIneffect.Value || dtpStart.Value >= dtpEnd.Value || dtpEffect.Value >= dtpIneffect.Value)
+ {
+ MessageBox.Show("请确保第一次开始结束时间在事物生效时间之内。");
+ return;
+ }
if (isEdit==false&&SqlHelper.ExecuteScalar("Select count(1) From CheckPlan Where Name='" + this.txtName.Text.Trim() + "'").ToString() != "0")
{
MessageBox.Show("请确保计划名称的唯一性");

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
View
@@ -9,9 +9,9 @@
namespace WorkStation
{
- public partial class frmain : Form
+ public partial class frMain : Form
{
- public frmain()
+ public frMain()
{
InitializeComponent();
}

0 comments on commit 1f41761

Please sign in to comment.