Fix cancellazioen cascata (tags) x matricole

This commit is contained in:
Samuele E. Locatelli
2015-10-19 12:33:33 +02:00
parent 43ec2ef312
commit b1b7d0d24b
9 changed files with 27 additions and 1 deletions
Binary file not shown.
Binary file not shown.
Binary file not shown.
+11
View File
@@ -21,6 +21,17 @@ namespace CMS_SC
}
mod_righePag.eh_newNum += mod_righePag_eh_newNum;
mod_anagMatricole.eh_selezioneValore += mod_anagMatricole_eh_selezioneValore;
mod_anagMatricole.eh_deleteValore += Mod_anagMatricole_eh_deleteValore;
}
/// <summary>
/// fix post cancellazione
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void Mod_anagMatricole_eh_deleteValore(object sender, EventArgs e)
{
divTags.Visible = false;
}
void mod_anagMatricole_eh_selezioneValore(object sender, EventArgs e)
@@ -1,5 +1,5 @@
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_anagMatricole.ascx.cs" Inherits="CMS_SC.WebUserControls.mod_anagMatricole" %>
<asp:GridView ID="grView" runat="server" AutoGenerateColumns="False" DataKeyNames="Matricola" DataSourceID="ods" CssClass="table table-striped" AllowPaging="True" AllowSorting="True" OnSelectedIndexChanged="grView_SelectedIndexChanged" OnRowDataBound="grView_RowDataBound">
<asp:GridView ID="grView" runat="server" AutoGenerateColumns="False" DataKeyNames="Matricola" DataSourceID="ods" CssClass="table table-striped" AllowPaging="True" AllowSorting="True" OnSelectedIndexChanged="grView_SelectedIndexChanged" OnRowDataBound="grView_RowDataBound" OnRowDeleted="grView_RowDeleted">
<PagerStyle CssClass="active GridPager" />
<PagerSettings Mode="NumericFirstLast" />
<SelectedRowStyle CssClass="info" />
@@ -16,6 +16,10 @@ namespace CMS_SC.WebUserControls
/// </summary>
public event EventHandler eh_selezioneValore;
/// <summary>
/// selezione valore in DettScheda
/// </summary>
public event EventHandler eh_deleteValore;
/// <summary>
/// sollevo evento selezione
/// </summary>
protected void raiseEvent()
@@ -102,5 +106,16 @@ namespace CMS_SC.WebUserControls
{
raiseEvent();
}
protected void grView_RowDeleted(object sender, GridViewDeletedEventArgs e)
{
grView.SelectedIndex = -1;
grView.DataBind();
if (eh_deleteValore != null)
{
eh_deleteValore(this, new EventArgs());
}
}
}
}
Binary file not shown.
Binary file not shown.
Binary file not shown.