aggiunta visualizzazione
- doc allegato OC/DC - alelgati squadre su scheda dett intgervento
This commit is contained in:
Binary file not shown.
@@ -36,6 +36,8 @@
|
||||
<add key="urlGestUtenti" value="UserAdmin" />
|
||||
<add key="adminEmail" value="samuele@steamware.net" />
|
||||
<add key="PageNoIndex" value="UserAdmin#Test" />
|
||||
<!--file allegati documenti-->
|
||||
<add key="fileUploadFolder" value="~/DocUploader"/>
|
||||
<!--gestione sw uploader locale-->
|
||||
<add key="localUplURL" value="http://IIS02" />
|
||||
<!--stringhe connessione-->
|
||||
|
||||
@@ -383,6 +383,7 @@
|
||||
<Content Include="WebUserControls\mod_enrollByAuthKey.ascx" />
|
||||
<Content Include="WebUserControls\mod_enrollByEmail.ascx" />
|
||||
<Content Include="WebUserControls\mod_enrollByJumperAuthKey.ascx" />
|
||||
<Content Include="WebUserControls\mod_fileImpegno.ascx" />
|
||||
<Content Include="WebUserControls\mod_fileUpload.ascx" />
|
||||
<Content Include="WebUserControls\mod_filtroPeriodo.ascx" />
|
||||
<Content Include="WebUserControls\mod_filtroZona.ascx" />
|
||||
@@ -624,6 +625,13 @@
|
||||
<Compile Include="WebUserControls\mod_enrollByJumperAuthKey.ascx.designer.cs">
|
||||
<DependentUpon>mod_enrollByJumperAuthKey.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_fileImpegno.ascx.cs">
|
||||
<DependentUpon>mod_fileImpegno.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_fileImpegno.ascx.designer.cs">
|
||||
<DependentUpon>mod_fileImpegno.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_fileUpload.ascx.cs">
|
||||
<DependentUpon>mod_fileUpload.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
|
||||
@@ -0,0 +1,5 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_fileImpegno.ascx.cs" Inherits="WebSCR.WebUserControls.mod_fileImpegno" %>
|
||||
|
||||
<div style="font-size: 2em; text-align: center; margin: auto; font-weight: bold;">
|
||||
<i class="fa fa-file-pdf-o"></i> <asp:HyperLink runat="server" ID="hlDoc" Target="_blank" />
|
||||
</div>
|
||||
@@ -0,0 +1,67 @@
|
||||
using SteamWare;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using WebSCR_data;
|
||||
|
||||
namespace WebSCR.WebUserControls
|
||||
{
|
||||
public partial class mod_fileImpegno : System.Web.UI.UserControl
|
||||
{
|
||||
/// <summary>
|
||||
/// caricamento modulo
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
// leggo impegno
|
||||
int IdxImpegno = 0;
|
||||
try
|
||||
{
|
||||
IdxImpegno = Convert.ToInt32(qsVal("IdxImpegno"));
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
hlDoc.Text = "-";
|
||||
// recupero documento...
|
||||
if (IdxImpegno > 0)
|
||||
{
|
||||
// cerco DOC...
|
||||
DS_Applicazione.ImpegniRow riga =DtProxy.man.taImp.getByKey(IdxImpegno)[0];
|
||||
// se c'è documento...
|
||||
if (riga.RifOC != "")
|
||||
{
|
||||
string tipoDoc = "";
|
||||
int numDoc = 0;
|
||||
try
|
||||
{
|
||||
tipoDoc = riga.RifOC.Substring(0, 2);
|
||||
numDoc = Convert.ToInt32(riga.RifOC.Replace(tipoDoc, ""));
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
if (numDoc > 0)
|
||||
{
|
||||
// imposto link del doc richiesto x download...
|
||||
hlDoc.NavigateUrl = string.Format("{0}/{1:0000000}_{2}_{3:yyyy}.pdf", memLayer.ML.CRS("fileUploadFolder"), numDoc, tipoDoc, DateTime.Now);
|
||||
hlDoc.Text = string.Format("{1}{0:0000000} ({2:yyyy})", numDoc, tipoDoc, DateTime.Now);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// recupera valore querystring
|
||||
/// </summary>
|
||||
/// <param name="nome"></param>
|
||||
/// <returns></returns>
|
||||
protected string qsVal(string nome)
|
||||
{
|
||||
return memLayer.ML.QSS(nome);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,24 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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_fileImpegno {
|
||||
|
||||
/// <summary>
|
||||
/// hlDoc 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.HyperLink hlDoc;
|
||||
}
|
||||
}
|
||||
@@ -1,7 +1,7 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_fileUpload.ascx.cs" Inherits="WebSCR.WebUserControls.mod_fileUpload" %>
|
||||
|
||||
<div id="divNewEdit" runat="server">
|
||||
<asp:Button ID="btnAdd" runat="server" Text="Nuovo Allegato" OnClick="btnAdd_Click" />
|
||||
<asp:Button ID="btnAdd" runat="server" Text="Nuovo Allegato" OnClick="btnAdd_Click" Enabled='<%# enableMod %>' />
|
||||
<asp:Button ID="btnCancel" runat="server" Text="Annulla" OnClick="btnCancel_Click" />
|
||||
</div>
|
||||
|
||||
@@ -35,9 +35,7 @@
|
||||
<asp:LinkButton ID="lnkDownload" runat="server" OnClick="DownloadFile"
|
||||
CommandArgument='<%# Eval("idxFile") %>'>
|
||||
<asp:Label ID="Label1" runat="server" Text='<%# Eval("FileName") %>' />
|
||||
</asp:LinkButton>
|
||||
</div>
|
||||
<div>
|
||||
</asp:LinkButton></div><div>
|
||||
<asp:Label CssClass="flLeft" ID="lblDataMod" runat="server" Text='<%# Eval("DataMod","{0:yyyy-MM-dd HH:mm}") %>' Font-Size="0.7em" />
|
||||
<asp:Label CssClass="flRight" ID="lblSize" runat="server" Text='<%# Eval("Size","{0:N0} kb") %>' Font-Size="0.8em" />
|
||||
</div>
|
||||
@@ -47,8 +45,8 @@
|
||||
<asp:TemplateField ItemStyle-HorizontalAlign="right">
|
||||
<ItemTemplate>
|
||||
<div id="Div1" runat="server" visible='<%# isWriteEnabled %>'>
|
||||
<asp:LinkButton ID="lnkSelect" runat="server" CausesValidation="False" CommandName="Select" Text="Select" CssClass="ui-btn ui-shadow ui-corner-all ui-icon-edit ui-btn-icon-notext ui-btn-inline" ToolTip="Modifica" />
|
||||
<asp:LinkButton ID="lnkDelete" runat="server" CausesValidation="False" CommandName="Delete" Text="Delete" CssClass="ui-btn ui-shadow ui-corner-all ui-icon-delete ui-btn-icon-notext ui-btn-inline" ToolTip="Elimina" OnClientClick="return confirm('Sei sicuro di voler eliminare il file?')" />
|
||||
<asp:LinkButton ID="lnkSelect" runat="server" CausesValidation="False" CommandName="Select" Text="Select" CssClass="ui-btn ui-shadow ui-corner-all ui-icon-edit ui-btn-icon-notext ui-btn-inline" ToolTip="Modifica" Visible='<%# enableMod %>' />
|
||||
<asp:LinkButton ID="lnkDelete" runat="server" CausesValidation="False" CommandName="Delete" Text="Delete" CssClass="ui-btn ui-shadow ui-corner-all ui-icon-delete ui-btn-icon-notext ui-btn-inline" ToolTip="Elimina" OnClientClick="return confirm('Sei sicuro di voler eliminare il file?')" Visible='<%# enableMod %>' />
|
||||
</div>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Center"></ItemStyle>
|
||||
|
||||
@@ -16,6 +16,15 @@ namespace WebSCR.WebUserControls
|
||||
{
|
||||
public partial class mod_fileUpload : SteamWare.UserControl
|
||||
{
|
||||
/// <summary>
|
||||
/// abilita modifica/cancellazione allegati
|
||||
/// </summary>
|
||||
public bool enableMod { get; set; }
|
||||
/// <summary>
|
||||
/// caricamento pagina
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
if (!IsPostBack)
|
||||
@@ -24,6 +33,7 @@ namespace WebSCR.WebUserControls
|
||||
grView.DataBind();
|
||||
}
|
||||
divNewEdit.Visible = isWriteEnabled;
|
||||
btnAdd.DataBind();
|
||||
}
|
||||
protected void Upload(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
@@ -7,6 +7,10 @@
|
||||
<%@ Register Src="~/WebUserControls/mod_impegno.ascx" TagPrefix="uc1" TagName="mod_impegno" %>
|
||||
<%@ Register Src="~/WebUserControls/mod_dettInt.ascx" TagPrefix="uc1" TagName="mod_dettInt" %>
|
||||
<%@ Register Src="~/WebUserControls/mod_selSquadre.ascx" TagPrefix="uc1" TagName="mod_selSquadre" %>
|
||||
<%@ Register Src="~/WebUserControls/mod_fileImpegno.ascx" TagPrefix="uc1" TagName="mod_fileImpegno" %>
|
||||
<%@ Register Src="~/WebUserControls/mod_fileUpload.ascx" TagPrefix="uc1" TagName="mod_fileUpload" %>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -24,17 +28,31 @@
|
||||
<uc1:mod_selSquadre runat="server" ID="mod_selSquadre" />
|
||||
</div>
|
||||
<div class="ui-mini" style="width: 100%;">
|
||||
<div style="min-width: 85px;width: 20%; float: left;">
|
||||
<div style="min-width: 85px; width: 20%; float: left;">
|
||||
<uc1:mod_dispPeriodo runat="server" ID="mod_dispPeriodo" />
|
||||
</div>
|
||||
<div style="width: 80%; float:right;">
|
||||
<div style="width: 80%; float: right;">
|
||||
<uc1:mod_giornata runat="server" ID="mod_giornata" />
|
||||
<div data-role="listview" data-inset="true">
|
||||
<div class="ui-field-contain">
|
||||
<uc1:mod_impegno runat="server" ID="mod_impegno" />
|
||||
<div style="width: 100%;">
|
||||
<div style="width: 75%; float: left;">
|
||||
<div data-role="listview" data-inset="true">
|
||||
<div class="ui-field-contain">
|
||||
<uc1:mod_impegno runat="server" ID="mod_impegno" />
|
||||
</div>
|
||||
<div class="ui-body">
|
||||
<uc1:mod_dettInt runat="server" ID="mod_dettInt" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="ui-body">
|
||||
<uc1:mod_dettInt runat="server" ID="mod_dettInt" />
|
||||
<div style="width: 25%; float: right;">
|
||||
<div data-role="listview" data-inset="true">
|
||||
<div class="ui-field-contain">
|
||||
<uc1:mod_fileImpegno runat="server" ID="mod_fileImpegno" />
|
||||
</div>
|
||||
<div class="ui-body">
|
||||
<uc1:mod_fileUpload runat="server" ID="mod_fileUpload" enableMod="false" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -23,8 +23,6 @@ namespace WebSCR.WebUserControls
|
||||
mod_filtroZona.Zona = memLayer.ML.confReadString("zonaDef");
|
||||
mod_filtroPeriodo.numGG = memLayer.ML.confReadInt("numGgDef");
|
||||
// reimposto selezione squadre...
|
||||
// !!!FARE!!! verifica
|
||||
//mod_selSquadre.selezionaAttive();
|
||||
mod_selSquadre.selezionaDaSession();
|
||||
refreshDetail();
|
||||
}
|
||||
|
||||
@@ -74,5 +74,23 @@ namespace WebSCR.WebUserControls {
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::WebSCR.WebUserControls.mod_dettInt mod_dettInt;
|
||||
|
||||
/// <summary>
|
||||
/// mod_fileImpegno control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::WebSCR.WebUserControls.mod_fileImpegno mod_fileImpegno;
|
||||
|
||||
/// <summary>
|
||||
/// mod_fileUpload control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::WebSCR.WebUserControls.mod_fileUpload mod_fileUpload;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -40,12 +40,12 @@ namespace WebSCR.WebUserControls
|
||||
/// </summary>
|
||||
public void selezionaDaSession()
|
||||
{
|
||||
// !!!FARE!!! NON FUNZIONA!!!
|
||||
cblSquadre.DataBind();
|
||||
if (memLayer.ML.isInSessionObject("elencoSquadre"))
|
||||
{
|
||||
foreach (ListItem item in cblSquadre.Items)
|
||||
{
|
||||
if (memLayer.ML.isInSessionObject("elencoSquadre").ToString().IndexOf(item.Value) > 0)
|
||||
if (memLayer.ML.StringSessionObj("elencoSquadre").ToString().IndexOf(item.Value) >= 0)
|
||||
item.Selected = true;
|
||||
}
|
||||
}
|
||||
|
||||
Binary file not shown.
Binary file not shown.
@@ -36,6 +36,8 @@
|
||||
<add key="urlGestUtenti" value="UserAdmin" />
|
||||
<add key="adminEmail" value="samuele@steamware.net" />
|
||||
<add key="PageNoIndex" value="UserAdmin#Test" />
|
||||
<!--file allegati documenti-->
|
||||
<add key="fileUploadFolder" value="~/DocUploader"/>
|
||||
<!--gestione sw uploader locale-->
|
||||
<add key="localUplURL" value="http://IIS02" />
|
||||
<!--stringhe connessione-->
|
||||
|
||||
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