COmpletata gestione multilingua x NOME scheda

This commit is contained in:
Samuele E. Locatelli
2018-02-23 16:24:18 +01:00
parent 6442964ecb
commit 4c6f26b213
25 changed files with 711 additions and 158 deletions
+1
View File
@@ -42,6 +42,7 @@
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Web" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="Microsoft.CSharp" />
+2 -2
View File
@@ -2036,7 +2036,7 @@ namespace CMS_SC_Data {
this.columnCodScheda.MaxLength = 50;
this.columnVers.AllowDBNull = false;
this.columnDescrizione.AllowDBNull = false;
this.columnDescrizione.MaxLength = 250;
this.columnDescrizione.MaxLength = 2147483647;
this.columnPath.AllowDBNull = false;
this.columnPath.MaxLength = 2147483647;
this.columnFasiEnab.AllowDBNull = false;
@@ -11325,7 +11325,7 @@ SELECT CodScheda, Vers, Descrizione, Path, FasiEnab, CodVisib FROM AnagSchede WH
this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@RETURN_VALUE", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.ReturnValue, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodScheda", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Vers", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Descrizione", global::System.Data.SqlDbType.NVarChar, 250, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Descrizione", global::System.Data.SqlDbType.NVarChar, 2147483647, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Path", global::System.Data.SqlDbType.NVarChar, 2147483647, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@FasiEnab", global::System.Data.SqlDbType.NVarChar, 2147483647, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodVisib", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+2 -2
View File
@@ -341,7 +341,7 @@ SELECT CodScheda, Vers, Descrizione, Path, FasiEnab, CodVisib FROM AnagSchede WH
<Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DataTypeServer="int" DbType="Int32" Direction="ReturnValue" ParameterName="@RETURN_VALUE" Precision="10" ProviderType="Int" Scale="0" Size="4" SourceColumnNullMapping="false" SourceVersion="Current" />
<Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DataTypeServer="nvarchar" DbType="String" Direction="Input" ParameterName="@CodScheda" Precision="0" ProviderType="NVarChar" Scale="0" Size="50" SourceColumnNullMapping="false" SourceVersion="Current" />
<Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DataTypeServer="int" DbType="Int32" Direction="Input" ParameterName="@Vers" Precision="10" ProviderType="Int" Scale="0" Size="4" SourceColumnNullMapping="false" SourceVersion="Current" />
<Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DataTypeServer="nvarchar" DbType="String" Direction="Input" ParameterName="@Descrizione" Precision="0" ProviderType="NVarChar" Scale="0" Size="250" SourceColumnNullMapping="false" SourceVersion="Current" />
<Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DataTypeServer="nvarchar" DbType="String" Direction="Input" ParameterName="@Descrizione" Precision="0" ProviderType="NVarChar" Scale="0" Size="2147483647" SourceColumnNullMapping="false" SourceVersion="Current" />
<Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DataTypeServer="nvarchar" DbType="String" Direction="Input" ParameterName="@Path" Precision="0" ProviderType="NVarChar" Scale="0" Size="2147483647" SourceColumnNullMapping="false" SourceVersion="Current" />
<Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DataTypeServer="nvarchar" DbType="String" Direction="Input" ParameterName="@FasiEnab" Precision="0" ProviderType="NVarChar" Scale="0" Size="2147483647" SourceColumnNullMapping="false" SourceVersion="Current" />
<Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DataTypeServer="nvarchar" DbType="String" Direction="Input" ParameterName="@CodVisib" Precision="0" ProviderType="NVarChar" Scale="0" Size="50" SourceColumnNullMapping="false" SourceVersion="Current" />
@@ -1636,7 +1636,7 @@ SELECT Email, ParName, ParValue FROM UserParam WHERE (Email = @Email) AND (ParNa
<xs:element name="Descrizione" msprop:Generator_ColumnVarNameInTable="columnDescrizione" msprop:Generator_ColumnPropNameInRow="Descrizione" msprop:Generator_ColumnPropNameInTable="DescrizioneColumn" msprop:Generator_UserColumnName="Descrizione">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:maxLength value="250" />
<xs:maxLength value="2147483647" />
</xs:restriction>
</xs:simpleType>
</xs:element>
+37 -37
View File
@@ -4,35 +4,35 @@
Changes to this file may cause incorrect behavior and will be lost if
the code is regenerated.
</autogenerated>-->
<DiagramLayout xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" ex:showrelationlabel="False" ViewPortX="-10" ViewPortY="-47" xmlns:ex="urn:schemas-microsoft-com:xml-msdatasource-layout-extended" xmlns="urn:schemas-microsoft-com:xml-msdatasource-layout">
<DiagramLayout xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" ex:showrelationlabel="False" ViewPortX="-10" ViewPortY="-46" xmlns:ex="urn:schemas-microsoft-com:xml-msdatasource-layout-extended" xmlns="urn:schemas-microsoft-com:xml-msdatasource-layout">
<Shapes>
<Shape ID="DesignTable:ElencoFamMacc" ZOrder="26" X="598" Y="-22" Height="227" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="99" />
<Shape ID="DesignTable:ElencoMacchineCN" ZOrder="8" X="1029" Y="-32" Height="365" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="214" />
<Shape ID="DesignTable:AnagFasi" ZOrder="5" X="1097" Y="812" Height="204" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="76" />
<Shape ID="DesignTable:AnagSchede" ZOrder="10" X="67" Y="363" Height="319" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="168" />
<Shape ID="DesignTable:DettScheda" ZOrder="18" X="414" Y="421" Height="342" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="191" />
<Shape ID="DesignTable:ValidVal" ZOrder="13" X="74" Y="683" Height="342" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="191" />
<Shape ID="DesignTable:SchemaCollFamMacc" ZOrder="9" X="67" Y="-36" Height="411" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="260" />
<Shape ID="DesignTable:ElencoDossier" ZOrder="4" X="1070" Y="325" Height="434" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="283" />
<Shape ID="DesignTable:SchemaCollMacc" ZOrder="11" X="738" Y="184" Height="365" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="214" />
<Shape ID="DesignTable:Misure" ZOrder="1" X="735" Y="583" Height="457" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="306" />
<Shape ID="DesignTable:ElencoMacchineCN" ZOrder="12" X="1029" Y="-32" Height="365" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="214" />
<Shape ID="DesignTable:AnagFasi" ZOrder="9" X="1097" Y="812" Height="204" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="76" />
<Shape ID="DesignTable:AnagSchede" ZOrder="1" X="53" Y="398" Height="319" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="168" />
<Shape ID="DesignTable:DettScheda" ZOrder="2" X="421" Y="465" Height="342" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="191" />
<Shape ID="DesignTable:ValidVal" ZOrder="14" X="68" Y="739" Height="342" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="191" />
<Shape ID="DesignTable:SchemaCollFamMacc" ZOrder="5" X="67" Y="-36" Height="411" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="260" />
<Shape ID="DesignTable:ElencoDossier" ZOrder="8" X="1070" Y="325" Height="434" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="283" />
<Shape ID="DesignTable:SchemaCollMacc" ZOrder="4" X="738" Y="184" Height="365" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="214" />
<Shape ID="DesignTable:Misure" ZOrder="6" X="735" Y="583" Height="457" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="306" />
<Shape ID="DesignTable:ReportData" ZOrder="19" X="418" Y="847" Height="365" Width="253" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="306" />
<Shape ID="DesignTable:Tags2Macchine" ZOrder="17" X="1366" Y="-8" Height="158" Width="277" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="76" />
<Shape ID="DesignTable:AnagTags" ZOrder="14" X="1376" Y="245" Height="227" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="76" />
<Shape ID="DesignTable:UserParam" ZOrder="6" X="0" Y="0" Height="204" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="99" />
<Shape ID="DesignTable:StatoCollaudi" ZOrder="2" X="92" Y="1056" Height="388" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="306" />
<Shape ID="DesignTable:DFR" ZOrder="3" X="738" Y="1126" Height="204" Width="232" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="99" />
<Shape ID="DesignTable:Tags2Macchine" ZOrder="18" X="1366" Y="-8" Height="158" Width="277" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="76" />
<Shape ID="DesignTable:AnagTags" ZOrder="15" X="1376" Y="245" Height="227" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="76" />
<Shape ID="DesignTable:UserParam" ZOrder="10" X="0" Y="0" Height="204" Width="294" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="99" />
<Shape ID="DesignTable:StatoCollaudi" ZOrder="3" X="63" Y="1186" Height="388" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="306" />
<Shape ID="DesignTable:DFR" ZOrder="7" X="738" Y="1126" Height="204" Width="232" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="99" />
</Shapes>
<Connectors>
<Connector ID="DesignRelation:FK_DettScheda_AnagSchede1" ZOrder="28" LineWidth="11">
<RoutePoints>
<Point>
<X>367</X>
<Y>573</Y>
<X>353</X>
<Y>695</Y>
</Point>
<Point>
<X>414</X>
<Y>573</Y>
<X>421</X>
<Y>695</Y>
</Point>
</RoutePoints>
</Connector>
@@ -51,32 +51,32 @@
<Connector ID="DesignRelation:FK_ValidVal_DettScheda" ZOrder="25" LineWidth="11">
<RoutePoints>
<Point>
<X>414</X>
<Y>732</Y>
<X>421</X>
<Y>795</Y>
</Point>
<Point>
<X>374</X>
<Y>732</Y>
<X>368</X>
<Y>795</Y>
</Point>
</RoutePoints>
</Connector>
<Connector ID="DesignRelation:FK_SchemaCollFamMacc_AnagSchede1" ZOrder="23" LineWidth="11">
<RoutePoints>
<Point>
<X>367</X>
<Y>371</Y>
<X>353</X>
<Y>406</Y>
</Point>
<Point>
<X>397</X>
<Y>371</Y>
<X>554</X>
<Y>406</Y>
</Point>
<Point>
<X>397</X>
<Y>367</Y>
<X>554</X>
<Y>236</Y>
</Point>
<Point>
<X>367</X>
<Y>367</Y>
<Y>236</Y>
</Point>
</RoutePoints>
</Connector>
@@ -92,7 +92,7 @@
</Point>
</RoutePoints>
</Connector>
<Connector ID="DesignRelation:FK_ElencoDossier_ElencoMacchineCN" ZOrder="7" LineWidth="11">
<Connector ID="DesignRelation:FK_ElencoDossier_ElencoMacchineCN" ZOrder="11" LineWidth="11">
<RoutePoints>
<Point>
<X>1053</X>
@@ -108,15 +108,15 @@
</Point>
</RoutePoints>
</Connector>
<Connector ID="DesignRelation:FK_SchemaCollMacc_AnagSchede" ZOrder="12" LineWidth="11">
<Connector ID="DesignRelation:FK_SchemaCollMacc_AnagSchede" ZOrder="13" LineWidth="11">
<RoutePoints>
<Point>
<X>367</X>
<Y>402</Y>
<X>353</X>
<Y>437</Y>
</Point>
<Point>
<X>738</X>
<Y>402</Y>
<Y>437</Y>
</Point>
</RoutePoints>
</Connector>
@@ -156,7 +156,7 @@
</Point>
</RoutePoints>
</Connector>
<Connector ID="DesignRelation:FK_Tags2Macchine_ElencoMacchineCN" ZOrder="16" LineWidth="11">
<Connector ID="DesignRelation:FK_Tags2Macchine_ElencoMacchineCN" ZOrder="17" LineWidth="11">
<RoutePoints>
<Point>
<X>1329</X>
@@ -168,7 +168,7 @@
</Point>
</RoutePoints>
</Connector>
<Connector ID="DesignRelation:FK_Tags2Macchine_AnagTags" ZOrder="15" LineWidth="11">
<Connector ID="DesignRelation:FK_Tags2Macchine_AnagTags" ZOrder="16" LineWidth="11">
<RoutePoints>
<Point>
<X>1476</X>
+100
View File
@@ -1,4 +1,9 @@
using SteamWare;
using System;
using System.Collections.Generic;
using System.Data;
using System.IO;
using System.Web;
namespace CMS_SC_Data
{
@@ -134,4 +139,99 @@ namespace CMS_SC_Data
#endregion
}
/// <summary>
/// Classe per split testo in modalità multilanguage
/// </summary>
public class LangSplitter
{
public LangSplitter()
{
flagList = getDictFromFile("FlagList.map");
}
protected Dictionary<string, string> flagList;
/// <summary>
/// Restituisce tabella con tante righe quante le lingue comprese
/// </summary>
/// <param name="fullData">Testo multilingua...</param>
/// <param name="tagOpen">Tag di apertura nel formato di esempio italiano, es: [IT]</param>
/// <param name="tagClose">Tag di chiusura nel formato di esempio italiano, es: [/IT]</param>
/// <returns></returns>
public DataTable getSplitData(string fullData, string tagOpen, string tagClose)
{
DataTable dt = new DataTable
{
TableName = "LocalizedSet"
};
dt.Columns.AddRange(new DataColumn[4] { new DataColumn("Idx", typeof(int)),
new DataColumn("Lang", typeof(string)),
new DataColumn("Flag", typeof(string)),
new DataColumn("Translation",typeof(string)) });
int idx = 1;
int endPos = 0;
int strLenght = fullData.Length;
string Lang = "";
string Translation = "";
string currOpen, currClose;
// proseguo estraendo a blocchi...
while (strLenght > 0)
{
// verifico formato inizia per iniziale del TAG
if (fullData[0] == tagOpen[0])
{
Lang = fullData.Substring(1, 2);
}
// compongo i 2 tag di apertura/chiusura...
currOpen = tagOpen.Replace("IT", Lang);
currClose = tagClose.Replace("IT", Lang);
// calcolo fine tag...
endPos = fullData.IndexOf(currClose);
// recupero la stringa effettiva
Translation = fullData.Substring(0, endPos).Replace(currOpen, "").Replace(currClose, "");
// tolgo tag+stringa da full e calcolo lunghezza, poi procedo
fullData = fullData.Substring(endPos).Replace(currClose, "");
strLenght = fullData.Length;
dt.Rows.Add(idx, Lang, flagList[Lang], Translation);
idx++;
}
return dt;
}
/// <summary>
/// Lettura file di conf e ritorna dictionary
/// </summary>
/// <param name="filePath">File con le conf key-val tipo file.map</param>
/// <returns></returns>
protected Dictionary<string, string> getDictFromFile(string filePath)
{
// leggo file...
string[] contenuto = File.ReadAllLines(resDir + filePath);
System.Collections.Generic.Dictionary<string, string> answ = new Dictionary<string, string>();
foreach (var line in contenuto)
{
// se la linea non è commento e non è vuota...
if (line.Length > 0 && line[0] != '#')
{
string[] tokens = line.Split(':');
answ.Add(tokens[0], tokens[1]);
}
}
// ritorno valori...
return answ;
}
/// <summary>
/// folder Risorse x configurazione (Resources)
/// </summary>
public static string resDir
{
get
{
return string.Format(@"{0}\App_Data\", HttpContext.Current.Server.MapPath("~"));
}
}
}
}
@@ -1 +1 @@
2fb95a3993cb82f9761f08fd519bb0550ffc5978
73bbb3de17cae454ab54595b2c5a3ff7389a549e
+3
View File
@@ -0,0 +1,3 @@
#Elenco delel associazioni lingua - flag
IT:flag-it
EN:flag-us
+1
View File
@@ -7,6 +7,7 @@
<include path="~/Content/font-awesome.min.css" />
<include path="~/Content/font.min.css" />
<include path="~/Content/Style.min.css" />
<include path="~/Content/flags.min.css" />
</styleBundle>
<styleBundle path="~/Content/themes/base/css">
<!--<include path="~/Content/themes/base/jquery.ui.all.css" />-->
+17 -1
View File
@@ -187,6 +187,11 @@
<Content Include="Content\bootswatch.min.css">
<DependentUpon>bootswatch.css</DependentUpon>
</Content>
<Content Include="Content\flags.css" />
<Content Include="Content\flags.min.css">
<DependentUpon>flags.css</DependentUpon>
</Content>
<Content Include="Content\flags.png" />
<Content Include="Content\font-awesome.css" />
<Content Include="Content\font-awesome.min.css" />
<Content Include="Content\font.css">
@@ -275,6 +280,7 @@
<Content Include="fonts\fontawesome-webfont.svg" />
<Content Include="Home.aspx" />
<Content Include="Images\accent.png" />
<Content Include="Images\blank.gif" />
<Content Include="Images\bullet.png" />
<Content Include="Images\heroAccent.png" />
<Content Include="Images\loader.gif" />
@@ -363,6 +369,9 @@
<Content Include="Scripts\bootstrap.js.map" />
<Content Include="Scripts\bootstrap.bundle.min.js.map" />
<Content Include="Scripts\bootstrap.bundle.js.map" />
<Content Include="App_Data\FlagList.map">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>
<None Include="Scripts\jquery-3.3.1.intellisense.js" />
<Content Include="Scripts\jquery-3.3.1.js" />
<Content Include="Scripts\jquery-3.3.1.min.js" />
@@ -444,6 +453,7 @@
<Content Include="fonts\OpenSans_600.woff" />
<Content Include="fonts\OpenSans_italic_400.woff" />
<Content Include="fonts\OpenSans_italic_600.woff" />
<Content Include="WebUserControls\mod_textTrans.ascx" />
<Content Include="WebUserControls\mod_validVal.ascx" />
<Content Include="WebUserControls\mod_vocabolario.ascx" />
<Content Include="fonts\Raleway_400.woff" />
@@ -923,6 +933,13 @@
<Compile Include="WebUserControls\mod_testata.ascx.designer.cs">
<DependentUpon>mod_testata.ascx</DependentUpon>
</Compile>
<Compile Include="WebUserControls\mod_textTrans.ascx.cs">
<DependentUpon>mod_textTrans.ascx</DependentUpon>
<SubType>ASPXCodeBehind</SubType>
</Compile>
<Compile Include="WebUserControls\mod_textTrans.ascx.designer.cs">
<DependentUpon>mod_textTrans.ascx</DependentUpon>
</Compile>
<Compile Include="WebUserControls\mod_validVal.ascx.cs">
<DependentUpon>mod_validVal.ascx</DependentUpon>
<SubType>ASPXCodeBehind</SubType>
@@ -939,7 +956,6 @@
</Compile>
</ItemGroup>
<ItemGroup>
<Folder Include="App_Data\" />
<Folder Include="imagecache\" />
</ItemGroup>
<ItemGroup>
+251
View File
@@ -0,0 +1,251 @@
.flag {
width: 16px;
height: 11px;
background:url(flags.png) no-repeat
}
.flag.flag-ad {background-position: -16px 0}
.flag.flag-ae {background-position: -32px 0}
.flag.flag-af {background-position: -48px 0}
.flag.flag-ag {background-position: -64px 0}
.flag.flag-ai {background-position: -80px 0}
.flag.flag-al {background-position: -96px 0}
.flag.flag-am {background-position: -112px 0}
.flag.flag-an {background-position: -128px 0}
.flag.flag-ao {background-position: -144px 0}
.flag.flag-ar {background-position: -160px 0}
.flag.flag-as {background-position: -176px 0}
.flag.flag-at {background-position: -192px 0}
.flag.flag-au {background-position: -208px 0}
.flag.flag-aw {background-position: -224px 0}
.flag.flag-az {background-position: -240px 0}
.flag.flag-ba {background-position: 0 -11px}
.flag.flag-bb {background-position: -16px -11px}
.flag.flag-bd {background-position: -32px -11px}
.flag.flag-be {background-position: -48px -11px}
.flag.flag-bf {background-position: -64px -11px}
.flag.flag-bg {background-position: -80px -11px}
.flag.flag-bh {background-position: -96px -11px}
.flag.flag-bi {background-position: -112px -11px}
.flag.flag-bj {background-position: -128px -11px}
.flag.flag-bm {background-position: -144px -11px}
.flag.flag-bn {background-position: -160px -11px}
.flag.flag-bo {background-position: -176px -11px}
.flag.flag-br {background-position: -192px -11px}
.flag.flag-bs {background-position: -208px -11px}
.flag.flag-bt {background-position: -224px -11px}
.flag.flag-bv {background-position: -240px -11px}
.flag.flag-bw {background-position: 0 -22px}
.flag.flag-by {background-position: -16px -22px}
.flag.flag-bz {background-position: -32px -22px}
.flag.flag-ca {background-position: -48px -22px}
.flag.flag-catalonia {background-position: -64px -22px}
.flag.flag-cd {background-position: -80px -22px}
.flag.flag-cf {background-position: -96px -22px}
.flag.flag-cg {background-position: -112px -22px}
.flag.flag-ch {background-position: -128px -22px}
.flag.flag-ci {background-position: -144px -22px}
.flag.flag-ck {background-position: -160px -22px}
.flag.flag-cl {background-position: -176px -22px}
.flag.flag-cm {background-position: -192px -22px}
.flag.flag-cn {background-position: -208px -22px}
.flag.flag-co {background-position: -224px -22px}
.flag.flag-cr {background-position: -240px -22px}
.flag.flag-cu {background-position: 0 -33px}
.flag.flag-cv {background-position: -16px -33px}
.flag.flag-cy {background-position: -32px -33px}
.flag.flag-cz {background-position: -48px -33px}
.flag.flag-de {background-position: -64px -33px}
.flag.flag-dj {background-position: -80px -33px}
.flag.flag-dk {background-position: -96px -33px}
.flag.flag-dm {background-position: -112px -33px}
.flag.flag-do {background-position: -128px -33px}
.flag.flag-dz {background-position: -144px -33px}
.flag.flag-ec {background-position: -160px -33px}
.flag.flag-ee {background-position: -176px -33px}
.flag.flag-eg {background-position: -192px -33px}
.flag.flag-eh {background-position: -208px -33px}
.flag.flag-england {background-position: -224px -33px}
.flag.flag-er {background-position: -240px -33px}
.flag.flag-es {background-position: 0 -44px}
.flag.flag-et {background-position: -16px -44px}
.flag.flag-eu {background-position: -32px -44px}
.flag.flag-fi {background-position: -48px -44px}
.flag.flag-fj {background-position: -64px -44px}
.flag.flag-fk {background-position: -80px -44px}
.flag.flag-fm {background-position: -96px -44px}
.flag.flag-fo {background-position: -112px -44px}
.flag.flag-fr {background-position: -128px -44px}
.flag.flag-ga {background-position: -144px -44px}
.flag.flag-gb {background-position: -160px -44px}
.flag.flag-gd {background-position: -176px -44px}
.flag.flag-ge {background-position: -192px -44px}
.flag.flag-gf {background-position: -208px -44px}
.flag.flag-gg {background-position: -224px -44px}
.flag.flag-gh {background-position: -240px -44px}
.flag.flag-gi {background-position: 0 -55px}
.flag.flag-gl {background-position: -16px -55px}
.flag.flag-gm {background-position: -32px -55px}
.flag.flag-gn {background-position: -48px -55px}
.flag.flag-gp {background-position: -64px -55px}
.flag.flag-gq {background-position: -80px -55px}
.flag.flag-gr {background-position: -96px -55px}
.flag.flag-gs {background-position: -112px -55px}
.flag.flag-gt {background-position: -128px -55px}
.flag.flag-gu {background-position: -144px -55px}
.flag.flag-gw {background-position: -160px -55px}
.flag.flag-gy {background-position: -176px -55px}
.flag.flag-hk {background-position: -192px -55px}
.flag.flag-hm {background-position: -208px -55px}
.flag.flag-hn {background-position: -224px -55px}
.flag.flag-hr {background-position: -240px -55px}
.flag.flag-ht {background-position: 0 -66px}
.flag.flag-hu {background-position: -16px -66px}
.flag.flag-id {background-position: -32px -66px}
.flag.flag-ie {background-position: -48px -66px}
.flag.flag-il {background-position: -64px -66px}
.flag.flag-im {background-position: -80px -66px}
.flag.flag-in {background-position: -96px -66px}
.flag.flag-io {background-position: -112px -66px}
.flag.flag-iq {background-position: -128px -66px}
.flag.flag-ir {background-position: -144px -66px}
.flag.flag-is {background-position: -160px -66px}
.flag.flag-it {background-position: -176px -66px}
.flag.flag-je {background-position: -192px -66px}
.flag.flag-jm {background-position: -208px -66px}
.flag.flag-jo {background-position: -224px -66px}
.flag.flag-jp {background-position: -240px -66px}
.flag.flag-ke {background-position: 0 -77px}
.flag.flag-kg {background-position: -16px -77px}
.flag.flag-kh {background-position: -32px -77px}
.flag.flag-ki {background-position: -48px -77px}
.flag.flag-km {background-position: -64px -77px}
.flag.flag-kn {background-position: -80px -77px}
.flag.flag-kp {background-position: -96px -77px}
.flag.flag-kr {background-position: -112px -77px}
.flag.flag-kw {background-position: -128px -77px}
.flag.flag-ky {background-position: -144px -77px}
.flag.flag-kz {background-position: -160px -77px}
.flag.flag-la {background-position: -176px -77px}
.flag.flag-lb {background-position: -192px -77px}
.flag.flag-lc {background-position: -208px -77px}
.flag.flag-li {background-position: -224px -77px}
.flag.flag-lk {background-position: -240px -77px}
.flag.flag-lr {background-position: 0 -88px}
.flag.flag-ls {background-position: -16px -88px}
.flag.flag-lt {background-position: -32px -88px}
.flag.flag-lu {background-position: -48px -88px}
.flag.flag-lv {background-position: -64px -88px}
.flag.flag-ly {background-position: -80px -88px}
.flag.flag-ma {background-position: -96px -88px}
.flag.flag-mc {background-position: -112px -88px}
.flag.flag-md {background-position: -128px -88px}
.flag.flag-me {background-position: -144px -88px}
.flag.flag-mg {background-position: -160px -88px}
.flag.flag-mh {background-position: -176px -88px}
.flag.flag-mk {background-position: -192px -88px}
.flag.flag-ml {background-position: -208px -88px}
.flag.flag-mm {background-position: -224px -88px}
.flag.flag-mn {background-position: -240px -88px}
.flag.flag-mo {background-position: 0 -99px}
.flag.flag-mp {background-position: -16px -99px}
.flag.flag-mq {background-position: -32px -99px}
.flag.flag-mr {background-position: -48px -99px}
.flag.flag-ms {background-position: -64px -99px}
.flag.flag-mt {background-position: -80px -99px}
.flag.flag-mu {background-position: -96px -99px}
.flag.flag-mv {background-position: -112px -99px}
.flag.flag-mw {background-position: -128px -99px}
.flag.flag-mx {background-position: -144px -99px}
.flag.flag-my {background-position: -160px -99px}
.flag.flag-mz {background-position: -176px -99px}
.flag.flag-na {background-position: -192px -99px}
.flag.flag-nc {background-position: -208px -99px}
.flag.flag-ne {background-position: -224px -99px}
.flag.flag-nf {background-position: -240px -99px}
.flag.flag-ng {background-position: 0 -110px}
.flag.flag-ni {background-position: -16px -110px}
.flag.flag-nl {background-position: -32px -110px}
.flag.flag-no {background-position: -48px -110px}
.flag.flag-np {background-position: -64px -110px}
.flag.flag-nr {background-position: -80px -110px}
.flag.flag-nu {background-position: -96px -110px}
.flag.flag-nz {background-position: -112px -110px}
.flag.flag-om {background-position: -128px -110px}
.flag.flag-pa {background-position: -144px -110px}
.flag.flag-pe {background-position: -160px -110px}
.flag.flag-pf {background-position: -176px -110px}
.flag.flag-pg {background-position: -192px -110px}
.flag.flag-ph {background-position: -208px -110px}
.flag.flag-pk {background-position: -224px -110px}
.flag.flag-pl {background-position: -240px -110px}
.flag.flag-pm {background-position: 0 -121px}
.flag.flag-pn {background-position: -16px -121px}
.flag.flag-pr {background-position: -32px -121px}
.flag.flag-ps {background-position: -48px -121px}
.flag.flag-pt {background-position: -64px -121px}
.flag.flag-pw {background-position: -80px -121px}
.flag.flag-py {background-position: -96px -121px}
.flag.flag-qa {background-position: -112px -121px}
.flag.flag-re {background-position: -128px -121px}
.flag.flag-ro {background-position: -144px -121px}
.flag.flag-rs {background-position: -160px -121px}
.flag.flag-ru {background-position: -176px -121px}
.flag.flag-rw {background-position: -192px -121px}
.flag.flag-sa {background-position: -208px -121px}
.flag.flag-sb {background-position: -224px -121px}
.flag.flag-sc {background-position: -240px -121px}
.flag.flag-scotland {background-position: 0 -132px}
.flag.flag-sd {background-position: -16px -132px}
.flag.flag-se {background-position: -32px -132px}
.flag.flag-sg {background-position: -48px -132px}
.flag.flag-sh {background-position: -64px -132px}
.flag.flag-si {background-position: -80px -132px}
.flag.flag-sk {background-position: -96px -132px}
.flag.flag-sl {background-position: -112px -132px}
.flag.flag-sm {background-position: -128px -132px}
.flag.flag-sn {background-position: -144px -132px}
.flag.flag-so {background-position: -160px -132px}
.flag.flag-sr {background-position: -176px -132px}
.flag.flag-ss {background-position: -192px -132px}
.flag.flag-st {background-position: -208px -132px}
.flag.flag-sv {background-position: -224px -132px}
.flag.flag-sy {background-position: -240px -132px}
.flag.flag-sz {background-position: 0 -143px}
.flag.flag-tc {background-position: -16px -143px}
.flag.flag-td {background-position: -32px -143px}
.flag.flag-tf {background-position: -48px -143px}
.flag.flag-tg {background-position: -64px -143px}
.flag.flag-th {background-position: -80px -143px}
.flag.flag-tj {background-position: -96px -143px}
.flag.flag-tk {background-position: -112px -143px}
.flag.flag-tl {background-position: -128px -143px}
.flag.flag-tm {background-position: -144px -143px}
.flag.flag-tn {background-position: -160px -143px}
.flag.flag-to {background-position: -176px -143px}
.flag.flag-tr {background-position: -192px -143px}
.flag.flag-tt {background-position: -208px -143px}
.flag.flag-tv {background-position: -224px -143px}
.flag.flag-tw {background-position: -240px -143px}
.flag.flag-tz {background-position: 0 -154px}
.flag.flag-ua {background-position: -16px -154px}
.flag.flag-ug {background-position: -32px -154px}
.flag.flag-um {background-position: -48px -154px}
.flag.flag-us {background-position: -64px -154px}
.flag.flag-uy {background-position: -80px -154px}
.flag.flag-uz {background-position: -96px -154px}
.flag.flag-va {background-position: -112px -154px}
.flag.flag-vc {background-position: -128px -154px}
.flag.flag-ve {background-position: -144px -154px}
.flag.flag-vg {background-position: -160px -154px}
.flag.flag-vi {background-position: -176px -154px}
.flag.flag-vn {background-position: -192px -154px}
.flag.flag-vu {background-position: -208px -154px}
.flag.flag-wales {background-position: -224px -154px}
.flag.flag-wf {background-position: -240px -154px}
.flag.flag-ws {background-position: 0 -165px}
.flag.flag-ye {background-position: -16px -165px}
.flag.flag-yt {background-position: -32px -165px}
.flag.flag-za {background-position: -48px -165px}
.flag.flag-zm {background-position: -64px -165px}
.flag.flag-zw {background-position: -80px -165px}
+1
View File
File diff suppressed because one or more lines are too long
Binary file not shown.

After

Width:  |  Height:  |  Size: 76 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 46 B

+74 -70
View File
@@ -1,76 +1,80 @@
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_anagSchedeColl.ascx.cs" Inherits="CMS_SC.WebUserControls.mod_anagSchedeColl" %>
<%@ Register Src="~/WebUserControls/mod_textTrans.ascx" TagPrefix="uc1" TagName="mod_textTrans" %>
<asp:GridView ID="grView" runat="server" AutoGenerateColumns="False" DataKeyNames="CodScheda,Vers" DataSourceID="ods" CssClass="table table-condensed table-sm table-striped m-0" AllowPaging="True" AllowSorting="True" OnSelectedIndexChanged="grView_SelectedIndexChanged" OnRowDataBound="grView_RowDataBound">
<PagerStyle CssClass="active GridPager" />
<PagerSettings Mode="NumericFirstLast" />
<SelectedRowStyle CssClass="info" />
<Columns>
<asp:TemplateField ShowHeader="False" ItemStyle-Wrap="false">
<EditItemTemplate>
<asp:LinkButton ID="lbUpdate" runat="server" CausesValidation="True" CommandName="Update" ToolTip="Update" CssClass="fa fa-check fa-2x" />
&nbsp;<asp:LinkButton ID="lbCancel" runat="server" CausesValidation="False" CommandName="Cancel" ToolTip="Cancel" CssClass="fa fa-undo fa-2x" />
</EditItemTemplate>
<ItemTemplate>
<asp:LinkButton ID="lbSelect" runat="server" CausesValidation="False" CommandName="Select" ToolTip="Select" CssClass="fa fa-search text-info fa-2x" />
&nbsp;
<PagerStyle CssClass="active GridPager" />
<PagerSettings Mode="NumericFirstLast" />
<SelectedRowStyle CssClass="info" />
<Columns>
<asp:TemplateField ShowHeader="False" ItemStyle-Wrap="false">
<EditItemTemplate>
<asp:LinkButton ID="lbUpdate" runat="server" CausesValidation="True" CommandName="Update" ToolTip="Update" CssClass="fa fa-check fa-2x" />
&nbsp;<asp:LinkButton ID="lbCancel" runat="server" CausesValidation="False" CommandName="Cancel" ToolTip="Cancel" CssClass="fa fa-undo fa-2x" />
</EditItemTemplate>
<ItemTemplate>
<asp:LinkButton ID="lbSelect" runat="server" CausesValidation="False" CommandName="Select" ToolTip="Select" CssClass="fa fa-search text-info fa-2x" />
&nbsp;
<asp:LinkButton ID="lbEdit" runat="server" CausesValidation="False" CommandName="Edit" ToolTip="Edit" CssClass="fa fa-edit text-info fa-2x" />
</ItemTemplate>
</asp:TemplateField>
<asp:BoundField DataField="CodScheda" HeaderText="CodScheda" ReadOnly="false" SortExpression="CodScheda" />
<asp:BoundField DataField="Vers" HeaderText="Vers" SortExpression="Vers" ReadOnly="false" />
<asp:TemplateField HeaderText="Descrizione" SortExpression="Descrizione">
<EditItemTemplate>
<asp:TextBox ID="TextBox2" runat="server" Text='<%# Bind("Descrizione") %>' Width="100%" />
</EditItemTemplate>
<ItemTemplate>
<asp:Label ID="Label1" runat="server" Text='<%# Eval("Descrizione") %>' />
</ItemTemplate>
</asp:TemplateField>
<asp:BoundField DataField="FasiEnab" HeaderText="FasiEnab" SortExpression="FasiEnab" ReadOnly="false" ControlStyle-Width="8em" />
<asp:BoundField DataField="CodVisib" HeaderText="Visib." SortExpression="CodVisib" ControlStyle-Width="4em" />
<asp:TemplateField HeaderText="Doc" SortExpression="Path">
<EditItemTemplate>
<asp:TextBox ID="TextBox1" runat="server" Text='<%# Bind("Path") %>' Width="100%" />
</EditItemTemplate>
<ItemTemplate>
<asp:HyperLink runat="server" ID="hlDoc" Target="_blank" ToolTip='<%# Eval("Path") %>' Visible='<%# CMS_SC_Data.DtProxy.notNullDocPath(Eval("Path")) %>' NavigateUrl='<%# CMS_SC_Data.DtProxy.getDocPath(Eval("Path")) %>'><i class="fa fa-file-pdf-o fa-2x"></i></asp:HyperLink>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField ShowHeader="False" ItemStyle-Wrap="false">
<HeaderTemplate>
<asp:LinkButton ID="lbAddNew" runat="server" CausesValidation="false" ToolTip="InsNew" CssClass="fa fa-plus text-success fa-2x" OnClick="lbAddNew_Click" />
</HeaderTemplate>
<EditItemTemplate>
<asp:LinkButton ID="lbUpdate2" runat="server" CausesValidation="True" CommandName="Update" ToolTip="Update" CssClass="fa fa-check fa-2x" />
&nbsp;<asp:LinkButton ID="lbCancel2" runat="server" CausesValidation="False" CommandName="Cancel" ToolTip="Cancel" CssClass="fa fa-undo fa-2x" />
</EditItemTemplate>
<ItemTemplate>
<asp:LinkButton ID="lbDelete" runat="server" CausesValidation="False" CommandName="Delete" ToolTip="Delete" OnClientClick='<%# SteamWare.jsUtils.getCBE("confermaDel") %>' CssClass="fa fa-trash text-danger fa-2x" />
</ItemTemplate>
</asp:TemplateField>
</Columns>
</ItemTemplate>
</asp:TemplateField>
<asp:BoundField DataField="CodScheda" HeaderText="CodScheda" ReadOnly="false" SortExpression="CodScheda" />
<asp:BoundField DataField="Vers" HeaderText="Vers" SortExpression="Vers" ReadOnly="false" />
<asp:TemplateField HeaderText="Descrizione" SortExpression="Descrizione">
<EditItemTemplate>
<asp:TextBox ID="TextBox2" runat="server" Text='<%# Bind("Descrizione") %>' CssClass="form-control form-control-sm small" TextMode="MultiLine" Height="8em" Font-Size="0.9em" />
<p><b>[IT]</b>Versione testo in Italiano<b>[/IT]</b><br />
<b>[EN]</b>English version text<b>[/EN]</b></p>
</EditItemTemplate>
<ItemTemplate>
<uc1:mod_textTrans runat="server" ID="mod_textTrans" fullText='<%# Eval("Descrizione") %>' tagOpen="[IT]" tagClose="[/IT]" />
</ItemTemplate>
</asp:TemplateField>
<asp:BoundField DataField="FasiEnab" HeaderText="FasiEnab" SortExpression="FasiEnab" ReadOnly="false" ControlStyle-Width="8em" />
<asp:BoundField DataField="CodVisib" HeaderText="Visib." SortExpression="CodVisib" ControlStyle-Width="4em" />
<asp:TemplateField HeaderText="Doc" SortExpression="Path">
<EditItemTemplate>
<asp:TextBox ID="TextBox1" runat="server" Text='<%# Bind("Path") %>' Width="100%" />
</EditItemTemplate>
<ItemTemplate>
<asp:HyperLink runat="server" ID="hlDoc" Target="_blank" ToolTip='<%# Eval("Path") %>' Visible='<%# CMS_SC_Data.DtProxy.notNullDocPath(Eval("Path")) %>' NavigateUrl='<%# CMS_SC_Data.DtProxy.getDocPath(Eval("Path")) %>'><i class="fa fa-file-pdf-o fa-2x"></i></asp:HyperLink>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField ShowHeader="False" ItemStyle-Wrap="false">
<HeaderTemplate>
<asp:LinkButton ID="lbAddNew" runat="server" CausesValidation="false" ToolTip="InsNew" CssClass="fa fa-plus text-success fa-2x" OnClick="lbAddNew_Click" />
</HeaderTemplate>
<EditItemTemplate>
<asp:LinkButton ID="lbUpdate2" runat="server" CausesValidation="True" CommandName="Update" ToolTip="Update" CssClass="fa fa-check fa-2x" />
&nbsp;<asp:LinkButton ID="lbCancel2" runat="server" CausesValidation="False" CommandName="Cancel" ToolTip="Cancel" CssClass="fa fa-undo fa-2x" />
</EditItemTemplate>
<ItemTemplate>
<asp:LinkButton ID="lbDelete" runat="server" CausesValidation="False" CommandName="Delete" ToolTip="Delete" OnClientClick='<%# SteamWare.jsUtils.getCBE("confermaDel") %>' CssClass="fa fa-trash text-danger fa-2x" />
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
<asp:ObjectDataSource ID="ods" runat="server" OldValuesParameterFormatString="original_{0}" SelectMethod="GetData" TypeName="CMS_SC_Data.DS_ApplicazioneTableAdapters.AnagSchedeTableAdapter" FilterExpression=" CodScheda LIKE '%{0}%' OR Descrizione LIKE '%{0}%'" DeleteMethod="deleteQuery" InsertMethod="insertQuery" UpdateMethod="updateQuery" OnUpdating="ods_Updating">
<DeleteParameters>
<asp:Parameter Name="Original_CodScheda" Type="String" />
<asp:Parameter Name="Original_Vers" Type="Int32" />
</DeleteParameters>
<FilterParameters>
<asp:SessionParameter DefaultValue="*" Name="ricerca" SessionField="searchVal" />
</FilterParameters>
<InsertParameters>
<asp:Parameter Name="CodScheda" Type="String" />
<asp:Parameter Name="Vers" Type="Int32" />
<asp:Parameter Name="Descrizione" Type="String" />
<asp:Parameter Name="Path" Type="String" />
</InsertParameters>
<UpdateParameters>
<asp:Parameter Name="CodScheda" Type="String" />
<asp:Parameter Name="Vers" Type="Int32" />
<asp:Parameter Name="Descrizione" Type="String" />
<asp:Parameter Name="Path" Type="String" />
<asp:Parameter Name="FasiEnab" Type="String" />
<asp:Parameter Name="CodVisib" Type="String" />
<asp:Parameter Name="Original_CodScheda" Type="String" />
<asp:Parameter Name="Original_Vers" Type="Int32" />
</UpdateParameters>
<DeleteParameters>
<asp:Parameter Name="Original_CodScheda" Type="String" />
<asp:Parameter Name="Original_Vers" Type="Int32" />
</DeleteParameters>
<FilterParameters>
<asp:SessionParameter DefaultValue="*" Name="ricerca" SessionField="searchVal" />
</FilterParameters>
<InsertParameters>
<asp:Parameter Name="CodScheda" Type="String" />
<asp:Parameter Name="Vers" Type="Int32" />
<asp:Parameter Name="Descrizione" Type="String" />
<asp:Parameter Name="Path" Type="String" />
</InsertParameters>
<UpdateParameters>
<asp:Parameter Name="CodScheda" Type="String" />
<asp:Parameter Name="Vers" Type="Int32" />
<asp:Parameter Name="Descrizione" Type="String" />
<asp:Parameter Name="Path" Type="String" />
<asp:Parameter Name="FasiEnab" Type="String" />
<asp:Parameter Name="CodVisib" Type="String" />
<asp:Parameter Name="Original_CodScheda" Type="String" />
<asp:Parameter Name="Original_Vers" Type="Int32" />
</UpdateParameters>
</asp:ObjectDataSource>
@@ -5,50 +5,55 @@ using System.Web.UI.WebControls;
namespace CMS_SC.WebUserControls
{
public partial class mod_anagSchedeColl : SteamWare.UserControl
public partial class mod_anagSchedeColl : SteamWare.UserControl
{
protected void Page_Load(object sender, EventArgs e)
{
protected void Page_Load(object sender, EventArgs e)
{
}
/// <summary>
/// dimensione pagina grid view
/// </summary>
public int pageSize
{
get
{
return grView.PageSize;
}
set
{
grView.PageSize = value;
}
}
/// <summary>
/// richiesta di aggiunta record, tutto a zero!
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
protected void lbAddNew_Click(object sender, EventArgs e)
{
// inserisco nuovo record
DtProxy.man.taASC.insertQuery(memLayer.ML.CRS("defASC01"), 0, memLayer.ML.CRS("defASC02"), "", memLayer.ML.CRS("defFasiEnab"));
// update!
grView.DataBind();
}
protected void grView_SelectedIndexChanged(object sender, EventArgs e)
{
// mando a dettaglio scheda...
string codScheda = string.Format("{0}.{1}", grView.SelectedDataKey["CodScheda"], grView.SelectedDataKey["Vers"]);
Response.Redirect(string.Format("~/DettScheda?CodSchedaVers={0}", codScheda));
}
protected void ods_Updating(object sender, ObjectDataSourceMethodEventArgs e)
{
if (e.InputParameters["Path"] == null) e.InputParameters["Path"] = "";
if (e.InputParameters["FasiEnab"] == null) e.InputParameters["FasiEnab"] = "";
}
}
/// <summary>
/// dimensione pagina grid view
/// </summary>
public int pageSize
{
get
{
return grView.PageSize;
}
set
{
grView.PageSize = value;
}
}
/// <summary>
/// richiesta di aggiunta record, tutto a zero!
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
protected void lbAddNew_Click(object sender, EventArgs e)
{
// inserisco nuovo record
DtProxy.man.taASC.insertQuery(memLayer.ML.CRS("defASC01"), 0, memLayer.ML.CRS("defASC02"), "", memLayer.ML.CRS("defFasiEnab"));
// update!
grView.DataBind();
}
protected void grView_SelectedIndexChanged(object sender, EventArgs e)
{
// mando a dettaglio scheda...
string codScheda = string.Format("{0}.{1}", grView.SelectedDataKey["CodScheda"], grView.SelectedDataKey["Vers"]);
Response.Redirect(string.Format("~/DettScheda?CodSchedaVers={0}", codScheda));
}
protected void ods_Updating(object sender, ObjectDataSourceMethodEventArgs e)
{
if (e.InputParameters["Path"] == null) e.InputParameters["Path"] = "";
if (e.InputParameters["FasiEnab"] == null) e.InputParameters["FasiEnab"] = "";
// metto a capo tra i vari tag SE non ci fosse...
if (e.InputParameters["Descrizione"].ToString().IndexOf("][") >= 0)
{
e.InputParameters["Descrizione"] = e.InputParameters["Descrizione"].ToString().Replace("][", "]\n[");
}
}
}
}
@@ -0,0 +1,4 @@
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_textTrans.ascx.cs" Inherits="CMS_SC.WebUserControls.mod_textTrans" %>
<asp:HiddenField runat="server" ID="hfFullText" />
<asp:Label runat="server" ID="lblItem" Text='<%# tradTesto(hfFullText.Value) %>'></asp:Label>
@@ -0,0 +1,118 @@
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using SteamWare;
namespace CMS_SC.WebUserControls
{
public partial class mod_textTrans : SteamWare.UserControl
{
protected Dictionary<string, string> flagList;
protected void Page_Load(object sender, EventArgs e)
{
flagList = getDictFromFile("FlagList.map");
}
/// <summary>
/// Lettura file di conf e ritorna dictionary
/// </summary>
/// <param name="filePath">File con le conf key-val tipo file.map</param>
/// <returns></returns>
protected Dictionary<string, string> getDictFromFile(string filePath)
{
// leggo file...
string[] contenuto = File.ReadAllLines(resDir + filePath);
Dictionary<string, string> answ = new Dictionary<string, string>();
foreach (var line in contenuto)
{
// se la linea non è commento e non è vuota...
if (line.Length > 0 && line[0] != '#')
{
string[] tokens = line.Split(':');
answ.Add(tokens[0], tokens[1]);
}
}
// ritorno valori...
return answ;
}
/// <summary>
/// folder Risorse x configurazione (Resources)
/// </summary>
public static string resDir
{
get
{
return string.Format(@"{0}\App_Data\", HttpContext.Current.Server.MapPath("~"));
}
}
/// <summary>
/// Versione compelta del testo
/// </summary>
public string fullText
{
get
{
return hfFullText.Value;
}
set
{
hfFullText.Value = value;
}
}
public string tagOpen { get; set; }
public string tagClose { get; set; }
/// <summary>
/// Effettua una traduzione del testo da originale a test con FLAG + a capo ove necessario
/// </summary>
/// <param name="fullData"></param>
/// <returns></returns>
public string tradTesto(string fullData)
{
fullData = fullData.Replace("\n", "");
int idx = 1;
int endPos = 0;
int strLenght = fullData.Length;
string Lang = "";
string Translation = "";
string currOpen, currClose;
string outStr = "";
// proseguo estraendo a blocchi...
while (strLenght > 0)
{
// verifico formato inizia per iniziale del TAG
if (fullData[0] == tagOpen[0])
{
Lang = fullData.Substring(1, 2);
}
// compongo i 2 tag di apertura/chiusura...
currOpen = tagOpen.Replace("IT", Lang);
currClose = tagClose.Replace("IT", Lang);
// calcolo fine tag...
endPos = fullData.IndexOf(currClose);
try
{
// recupero la stringa effettiva
Translation = fullData.Substring(0, endPos).Replace(currOpen, "").Replace(currClose, "");
// tolgo tag+stringa da full e calcolo lunghezza, poi procedo
fullData = fullData.Substring(endPos).Replace(currClose, "");
strLenght = fullData.Length;
// accodo stringa...
outStr += string.Format(@"<img src='Images/blank.gif' class='flag {0}'/> {1}</br>", flagList[Lang], Translation);
idx++;
}
catch
{
strLenght = 0;
}
}
return outStr;
}
}
}
+33
View File
@@ -0,0 +1,33 @@
//------------------------------------------------------------------------------
// <generato automaticamente>
// Codice generato da uno strumento.
//
// Le modifiche a questo file possono causare un comportamento non corretto e verranno perse se
// il codice viene rigenerato.
// </generato automaticamente>
//------------------------------------------------------------------------------
namespace CMS_SC.WebUserControls {
public partial class mod_textTrans {
/// <summary>
/// Controllo hfFullText.
/// </summary>
/// <remarks>
/// Campo generato automaticamente.
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
/// </remarks>
protected global::System.Web.UI.WebControls.HiddenField hfFullText;
/// <summary>
/// Controllo lblItem.
/// </summary>
/// <remarks>
/// Campo generato automaticamente.
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
/// </remarks>
protected global::System.Web.UI.WebControls.Label lblItem;
}
}
Binary file not shown.
+7 -1
View File
@@ -58,5 +58,11 @@
"inputFiles": [
"Content/bootstrap-theme.css"
]
},
{
"outputFileName": "Content/flags.min.css",
"inputFiles": [
"Content/flags.css"
]
}
]
]
+1
View File
@@ -7,6 +7,7 @@
<package id="bootstrap" version="4.0.0" targetFramework="net462" />
<package id="elmah" version="1.2.2" targetFramework="net45" />
<package id="elmah.corelibrary" version="1.2.2" targetFramework="net45" />
<package id="FlagSprites" version="1.0" targetFramework="net462" />
<package id="FontAwesome" version="4.7.0" targetFramework="net452" />
<package id="Glimpse" version="1.8.6" targetFramework="net45" />
<package id="Glimpse.Ado" version="1.7.3" targetFramework="net45" />
+9
View File
@@ -28,3 +28,12 @@ INSERT INTO [dbo].[DettScheda]
VALUES ('FN0001',0,'M0001','Note libere collaudo','TEXTAREA','','FCS','')
INSERT INTO [dbo].[DettScheda]
VALUES ('FN0001',0,'M0002','File Allegati','FILE','','FCS','')
-- modifica colonna descrizione NVARCHAR(MAX)
ALTER TABLE AnagSchede DROP CONSTRAINT [DF_AnagSchede_Descrizione]
ALTER TABLE AnagSchede ALTER COLUMN Descrizione NVARCHAR(MAX) NOT NULL
ALTER TABLE AnagSchede ADD CONSTRAINT [DF_AnagSchede_Descrizione] DEFAULT ('') FOR [Descrizione]
-- traduzione nome schede collaudo compreso a capo - CHAR(10)
UPDATE AnagSchede SET Descrizione = '[IT]' + Descrizione + '[/IT]' + CHAR(10) + '[EN]' + Descrizione + '[/EN]'
Vendored
+1 -1
View File
@@ -11,7 +11,7 @@ pipeline {
/* calcolo numero versione... diverso x branch MASTER/DEVELOP */
script {
withEnv(['NEXT_BUILD_NUMBER=4180']) {
withEnv(['NEXT_BUILD_NUMBER=4185']) {
// env.versionNumber = VersionNumber(versionNumberString : '${BUILD_DATE_FORMATTED, "yyMM"}.${BUILDS_ALL_TIME}', projectStartDate : '2006-01-01', skipFailedBuilds: true)
env.versionNumber = VersionNumber(versionNumberString : '${BUILD_DATE_FORMATTED, "yyMM"}.${BUILDS_ALL_TIME}', projectStartDate : '2006-01-01', skipFailedBuilds: true, overrideBuildsAllTime: '${NEXT_BUILD_NUMBER}')
env.APP_NAME = 'CMS-SC'