fix visibilità inizio/fine intervento...
This commit is contained in:
Binary file not shown.
@@ -3,12 +3,15 @@
|
||||
<%@ Register Src="~/WebUserControls/mod_consegne.ascx" TagPrefix="uc1" TagName="mod_consegne" %>
|
||||
<%@ Register Src="~/WebUserControls/mod_dettInt.ascx" TagPrefix="uc1" TagName="mod_dettInt" %>
|
||||
<%@ Register Src="~/WebUserControls/mod_ImpegnoSmall.ascx" TagPrefix="uc1" TagName="mod_ImpegnoSmall" %>
|
||||
<%@ Register Src="~/WebUserControls/mod_gestIntSquadra.ascx" TagPrefix="uc1" TagName="mod_gestIntSquadra" %>
|
||||
|
||||
|
||||
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
|
||||
<div class="ui-mini" style="margin: 1px; padding: 0px;">
|
||||
<uc1:mod_consegne runat="server" ID="mod_consegne" />
|
||||
<uc1:mod_gestIntSquadra runat="server" id="mod_gestIntSquadra" />
|
||||
<uc1:mod_ImpegnoSmall runat="server" id="mod_ImpegnoSmall" />
|
||||
<uc1:mod_dettInt runat="server" ID="mod_dettInt" disableEdit="true" />
|
||||
</div>
|
||||
|
||||
@@ -31,10 +31,12 @@ namespace WebSCR
|
||||
mod_consegne.Visible = true;
|
||||
mod_dettInt.Visible = false;
|
||||
mod_ImpegnoSmall.Visible = false;
|
||||
mod_gestIntSquadra.Visible = false;
|
||||
if (qsVal("Data") != "")
|
||||
{
|
||||
if (qsVal("IdxImpegno") != "")
|
||||
{
|
||||
mod_gestIntSquadra.Visible = true;
|
||||
mod_ImpegnoSmall.Visible = true;
|
||||
mod_dettInt.Visible = true;
|
||||
mod_consegne.Visible = false;
|
||||
|
||||
Generated
+9
@@ -21,6 +21,15 @@ namespace WebSCR {
|
||||
/// </remarks>
|
||||
protected global::WebSCR.WebUserControls.mod_consegne mod_consegne;
|
||||
|
||||
/// <summary>
|
||||
/// mod_gestIntSquadra control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::WebSCR.WebUserControls.mod_gestIntSquadra mod_gestIntSquadra;
|
||||
|
||||
/// <summary>
|
||||
/// mod_ImpegnoSmall control.
|
||||
/// </summary>
|
||||
|
||||
@@ -364,6 +364,7 @@
|
||||
<Content Include="WebUserControls\mod_filtroPeriodo.ascx" />
|
||||
<Content Include="WebUserControls\mod_filtroZona.ascx" />
|
||||
<Content Include="WebUserControls\mod_footer.ascx" />
|
||||
<Content Include="WebUserControls\mod_gestIntSquadra.ascx" />
|
||||
<Content Include="WebUserControls\mod_giornata.ascx" />
|
||||
<Content Include="WebUserControls\mod_header.ascx" />
|
||||
<Content Include="WebUserControls\mod_impegno.ascx" />
|
||||
@@ -600,6 +601,13 @@
|
||||
<Compile Include="WebUserControls\mod_footer.ascx.designer.cs">
|
||||
<DependentUpon>mod_footer.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_gestIntSquadra.ascx.cs">
|
||||
<DependentUpon>mod_gestIntSquadra.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_gestIntSquadra.ascx.designer.cs">
|
||||
<DependentUpon>mod_gestIntSquadra.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_giornata.ascx.cs">
|
||||
<DependentUpon>mod_giornata.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
|
||||
@@ -1,8 +1,5 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_consegne.ascx.cs" Inherits="WebSCR.WebUserControls.mod_consegne" %>
|
||||
|
||||
<p>
|
||||
3) possibilità di cliccare "inizio", "fine", mostra Allegati, carica foto (allegati) ad ogni TASK
|
||||
</p>
|
||||
<div class="ui-mini">
|
||||
<asp:GridView ID="grView" runat="server" DataSourceID="ods" AutoGenerateColumns="False" DataKeyNames="IdxImpegno" CellPadding="4" ForeColor="#333333" GridLines="None" Width="100%" AllowPaging="True" OnRowCommand="grView_RowCommand" OnSelectedIndexChanged="grView_SelectedIndexChanged">
|
||||
<EditRowStyle BackColor="#2461BF" />
|
||||
@@ -68,10 +65,6 @@
|
||||
</Columns>
|
||||
</asp:GridView>
|
||||
<asp:ObjectDataSource ID="ods" runat="server" SelectMethod="getBySearch" TypeName="WebSCR_data.DS_ApplicazioneTableAdapters.ImpegniTableAdapter" OldValuesParameterFormatString="original_{0}">
|
||||
<%--FilterExpression="CodSquadra LIKE '%{0}%' OR DescrSquadra LIKE '%{0}%' OR CodCliente LIKE '%{0}%' OR RagSoc LIKE '%{0}%' OR RifOC LIKE '%{0}%' "
|
||||
<FilterParameters>
|
||||
<asp:ControlParameter ControlID="txtSearch" DefaultValue="*" Type="string" />
|
||||
</FilterParameters>--%>
|
||||
<SelectParameters>
|
||||
<asp:Parameter DefaultValue="*" Name="Stato" Type="String" />
|
||||
<asp:CookieParameter CookieName="DataRif" Name="DataRif" Type="DateTime" />
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
<SortedDescendingHeaderStyle BackColor="#4870BE" />
|
||||
<AlternatingRowStyle BackColor="White" />
|
||||
<EmptyDataTemplate>
|
||||
Nessun Task
|
||||
Nessuna Attivià
|
||||
</EmptyDataTemplate>
|
||||
<Columns>
|
||||
<asp:TemplateField ShowHeader="False" ItemStyle-HorizontalAlign="Center" HeaderStyle-HorizontalAlign="Center">
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_gestIntSquadra.ascx.cs" Inherits="WebSCR.WebUserControls.mod_gestIntSquadra" %>
|
||||
|
||||
<div class="ui-mini">
|
||||
<div style="text-align: center; margin: auto;">
|
||||
<asp:LinkButton ID="lbInizioInt" CssClass="ui-btn ui-shadow ui-corner-all ui-icon-clock ui-btn-icon-right ui-btn-inline" runat="server" CausesValidation="False" Text="Inizio Intervento" Width="75%" />
|
||||
<asp:LinkButton ID="lbFineInt" CssClass="ui-btn ui-shadow ui-corner-all ui-icon-clock ui-btn-icon-right ui-btn-inline" runat="server" CausesValidation="False" Text="Fine Intervento" Width="75%" />
|
||||
<asp:LinkButton ID="lbNoteInt" CssClass="ui-btn ui-shadow ui-corner-all ui-icon-edit ui-btn-icon-right ui-btn-inline" runat="server" CausesValidation="False" Text="Note Intervento" Width="75%" />
|
||||
<asp:LinkButton ID="lbFileInt" CssClass="ui-btn ui-shadow ui-corner-all ui-icon-camera ui-btn-icon-right ui-btn-inline" runat="server" CausesValidation="False" Text="Allega File" Width="75%" />
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,59 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using SteamWare;
|
||||
using WebSCR_data;
|
||||
|
||||
namespace WebSCR.WebUserControls
|
||||
{
|
||||
public partial class mod_gestIntSquadra : System.Web.UI.UserControl
|
||||
{
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
fixVisibility();
|
||||
}
|
||||
/// <summary>
|
||||
/// sistemo visibilità buttons
|
||||
/// </summary>
|
||||
private void fixVisibility()
|
||||
{
|
||||
// verifico se impegno è iniziato o meno e di conseguenza mostro inizio/fine
|
||||
int idxImpergno = 0;
|
||||
try
|
||||
{
|
||||
idxImpergno = memLayer.ML.QSI("IdxImpegno");
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
if (idxImpergno > 0)
|
||||
{
|
||||
DS_Applicazione.ImpegniRow riga = DtProxy.man.taImp.getByKey(idxImpergno)[0];
|
||||
bool iniziato = false;
|
||||
bool finito = false;
|
||||
try
|
||||
{
|
||||
if (riga.InizioInt != null)
|
||||
{
|
||||
iniziato = true;
|
||||
}
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
try
|
||||
{
|
||||
if (riga.FineInt != null)
|
||||
{
|
||||
finito = true;
|
||||
}
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
lbInizioInt.Visible = !iniziato;
|
||||
lbFineInt.Visible = iniziato && !finito;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,51 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace WebSCR.WebUserControls {
|
||||
|
||||
|
||||
public partial class mod_gestIntSquadra {
|
||||
|
||||
/// <summary>
|
||||
/// lbInizioInt control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton lbInizioInt;
|
||||
|
||||
/// <summary>
|
||||
/// lbFineInt control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton lbFineInt;
|
||||
|
||||
/// <summary>
|
||||
/// lbNoteInt control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton lbNoteInt;
|
||||
|
||||
/// <summary>
|
||||
/// lbFileInt control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton lbFileInt;
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using SteamWare;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
@@ -50,14 +51,7 @@ namespace WebSCR.WebUserControls
|
||||
/// <returns></returns>
|
||||
protected string qsVal(string nome)
|
||||
{
|
||||
string answ = "";
|
||||
try
|
||||
{
|
||||
answ = Request.QueryString[nome].ToString();
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
return answ;
|
||||
return memLayer.ML.QSS(nome);
|
||||
}
|
||||
/// <summary>
|
||||
/// recupero valori mancanti
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Reference in New Issue
Block a user