Merge branch 'develop'
This commit is contained in:
@@ -0,0 +1,36 @@
|
||||
<%@ Page Title="" Language="C#" MasterPageFile="~/FullPage.master" AutoEventWireup="true" CodeBehind="AgentsMan.aspx.cs" Inherits="C2P.AgentsMan" %>
|
||||
|
||||
<%@ Register Src="~/WebUserControls/mod_ricercaGenerica.ascx" TagPrefix="uc1" TagName="mod_ricercaGenerica" %>
|
||||
<%@ Register Src="~/WebUserControls/mod_righePag.ascx" TagName="mod_righePag" TagPrefix="uc1" %>
|
||||
<%@ Register Src="~/WebUserControls/mod_AgentsMan.ascx" TagPrefix="uc1" TagName="mod_AgentsMan" %>
|
||||
|
||||
|
||||
|
||||
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="HeadContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content3" ContentPlaceHolderID="FeaturedContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content4" ContentPlaceHolderID="MainContent" runat="server">
|
||||
<div class="container-fluid" style="background-color: #cdcdcd; padding-top: 2px; padding-bottom: 2px;">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-sm-8 col-sm-offset-2 text-center">
|
||||
<uc1:mod_ricercaGenerica runat="server" ID="mod_ricercaGenerica" />
|
||||
</div>
|
||||
<div class="col-sm-2 text-right">
|
||||
<uc1:mod_righePag ID="mod_righePag" runat="server" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="container-fluid" style="padding-top: 2px; padding-bottom: 2px;">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-sm-12">
|
||||
<uc1:mod_AgentsMan runat="server" id="mod_AgentsMan" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</asp:Content>
|
||||
@@ -0,0 +1,31 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
|
||||
namespace C2P
|
||||
{
|
||||
public partial class AgentsMan : System.Web.UI.Page
|
||||
{
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
if (!Page.IsPostBack)
|
||||
{
|
||||
mod_righePag.numRowPag = 20;
|
||||
mod_AgentsMan.pageSize = mod_righePag.numRowPag;
|
||||
}
|
||||
mod_righePag.eh_newNum += mod_righePag_eh_newNum;
|
||||
}
|
||||
/// <summary>
|
||||
/// aggiornato numero righe datagrid... aggiorno visualizzazione
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
void mod_righePag_eh_newNum(object sender, EventArgs e)
|
||||
{
|
||||
mod_AgentsMan.pageSize = mod_righePag.numRowPag;
|
||||
}
|
||||
}
|
||||
}
|
||||
Generated
+42
@@ -0,0 +1,42 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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 C2P {
|
||||
|
||||
|
||||
public partial class AgentsMan {
|
||||
|
||||
/// <summary>
|
||||
/// mod_ricercaGenerica control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::mod_ricercaGenerica mod_ricercaGenerica;
|
||||
|
||||
/// <summary>
|
||||
/// mod_righePag control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::mod_righePag mod_righePag;
|
||||
|
||||
/// <summary>
|
||||
/// mod_AgentsMan control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::C2P.WebUserControls.mod_AgentsMan mod_AgentsMan;
|
||||
}
|
||||
}
|
||||
@@ -78,7 +78,7 @@
|
||||
<!-- /.container -->
|
||||
<asp:UpdatePanel ID="uppFooter" runat="server">
|
||||
<ContentTemplate>
|
||||
<asp:Timer ID="Timer1" runat="server" Interval="10000" OnTick="Timer1_Tick">
|
||||
<asp:Timer ID="Timer1" runat="server" Interval="120000" OnTick="Timer1_Tick">
|
||||
</asp:Timer>
|
||||
<footer>
|
||||
<div class="navbar navbar-inverse navbar-fixed-bottom" role="navigation">
|
||||
|
||||
+119
-3
@@ -122,6 +122,7 @@
|
||||
</Reference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Content Include="AgentsMan.aspx" />
|
||||
<Content Include="App_Readme\Elmah.txt" />
|
||||
<Content Include="Content\bootstrap-theme.css" />
|
||||
<Content Include="Content\bootstrap-theme.min.css" />
|
||||
@@ -204,7 +205,9 @@
|
||||
<Content Include="Content\themes\base\minified\jquery.ui.tabs.min.css" />
|
||||
<Content Include="Content\themes\base\minified\jquery.ui.theme.min.css" />
|
||||
<Content Include="Content\themes\base\minified\jquery.ui.tooltip.min.css" />
|
||||
<Content Include="CsvExcelExporter.aspx" />
|
||||
<Content Include="DbSync.aspx" />
|
||||
<Content Include="DiesGroupMan.aspx" />
|
||||
<Content Include="Drawings\1AN00002.png" />
|
||||
<Content Include="Drawings\1AN00003.png" />
|
||||
<Content Include="Drawings\1AN00004.png" />
|
||||
@@ -300,11 +303,13 @@
|
||||
<Content Include="NewProductOffer.aspx" />
|
||||
<Content Include="OfferReport.aspx" />
|
||||
<Content Include="OffersArchive.aspx" />
|
||||
<Content Include="PackageMan.aspx" />
|
||||
<Content Include="packages.config" />
|
||||
<Content Include="NLog.config">
|
||||
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
||||
</Content>
|
||||
<Content Include="Content\Style.less" />
|
||||
<Content Include="PlantsMan.aspx" />
|
||||
<Content Include="Quote.aspx" />
|
||||
<Content Include="Bootstrap.Master" />
|
||||
<Content Include="logs\PlaceHolder.file" />
|
||||
@@ -313,17 +318,17 @@
|
||||
<Content Include="fonts\OpenSans_600.woff" />
|
||||
<Content Include="fonts\OpenSans_italic_400.woff" />
|
||||
<Content Include="fonts\OpenSans_italic_600.woff" />
|
||||
<Content Include="RawMatMan.aspx" />
|
||||
<Content Include="RepOffers.aspx" />
|
||||
<Content Include="RevisionHistory.aspx" />
|
||||
<Content Include="Scripts\bootstrap.js" />
|
||||
<Content Include="Scripts\bootstrap.min.js" />
|
||||
<Content Include="Reports\0MarginReport123456789.xlsx" />
|
||||
<Content Include="Reports\MarginReport.xlsx" />
|
||||
<Content Include="Reports\MarginReport_Real.xlsx" />
|
||||
<Content Include="fonts\fontawesome-webfont.woff" />
|
||||
<Content Include="fonts\fontawesome-webfont.ttf" />
|
||||
<Content Include="fonts\fontawesome-webfont.eot" />
|
||||
<Content Include="fonts\FontAwesome.otf" />
|
||||
<Content Include="PDF\PlaceHolder.file" />
|
||||
<None Include="Properties\PublishProfiles\demo.pubxml" />
|
||||
<Content Include="Reports\OfferReport.xlsx" />
|
||||
<None Include="Scripts\jquery-2.1.1.intellisense.js" />
|
||||
@@ -360,10 +365,14 @@
|
||||
<Content Include="Settings.aspx" />
|
||||
<Content Include="StdCostList.aspx" />
|
||||
<Content Include="test.aspx" />
|
||||
<Content Include="TranspCostMan.aspx" />
|
||||
<Content Include="UpdateVoc.aspx" />
|
||||
<Content Include="UserAdmin.aspx" />
|
||||
<Content Include="Vocabolario.aspx" />
|
||||
<Content Include="WebUserControls\mod_AgentsMan.ascx" />
|
||||
<Content Include="WebUserControls\mod_autocompleteShort.ascx" />
|
||||
<Content Include="WebUserControls\mod_createNewStdCost.ascx" />
|
||||
<Content Include="WebUserControls\mod_DiesGroupMan.ascx" />
|
||||
<Content Include="WebUserControls\mod_display.ascx" />
|
||||
<Content Include="WebUserControls\mod_displayHor.ascx" />
|
||||
<Content Include="WebUserControls\mod_elencoRichResetUtenti.ascx" />
|
||||
@@ -381,12 +390,15 @@
|
||||
<Content Include="WebUserControls\mod_newProduct.ascx" />
|
||||
<Content Include="WebUserControls\mod_OfferReport.ascx" />
|
||||
<Content Include="WebUserControls\mod_OffersArchive.ascx" />
|
||||
<Content Include="WebUserControls\mod_PackageMan.ascx" />
|
||||
<Content Include="WebUserControls\mod_PlantsMan.ascx" />
|
||||
<Content Include="WebUserControls\mod_Q_Costs.ascx" />
|
||||
<Content Include="WebUserControls\mod_Q_ExtrPar.ascx" />
|
||||
<Content Include="WebUserControls\mod_Q_Header.ascx" />
|
||||
<Content Include="WebUserControls\mod_Q_PackPar.ascx" />
|
||||
<Content Include="WebUserControls\mod_Q_Quot.ascx" />
|
||||
<Content Include="WebUserControls\mod_range.ascx" />
|
||||
<Content Include="WebUserControls\mod_RawMatMan.ascx" />
|
||||
<Content Include="WebUserControls\mod_ricercaGenerica.ascx" />
|
||||
<Content Include="WebUserControls\mod_righePag.ascx" />
|
||||
<Content Include="WebUserControls\mod_selPeriodo.ascx" />
|
||||
@@ -401,6 +413,7 @@
|
||||
<Content Include="WebUserControls\mod_testata.ascx" />
|
||||
<Content Include="JumboPage.master" />
|
||||
<Content Include="FullPage.master" />
|
||||
<Content Include="WebUserControls\mod_TranspCostMan.ascx" />
|
||||
<Content Include="WebUserControls\mod_vocabolario.ascx" />
|
||||
<Content Include="WhatIf.aspx" />
|
||||
<Content Include="fonts\glyphicons-halflings-regular.woff" />
|
||||
@@ -410,7 +423,6 @@
|
||||
<Content Include="Content\bootstrap.css.map" />
|
||||
<None Include="Properties\PublishProfiles\IIS02.pubxml" />
|
||||
<None Include="Properties\PublishProfiles\localhost.pubxml" />
|
||||
<None Include="Properties\PublishProfiles\RemoteZip.pubxml" />
|
||||
<None Include="Properties\PublishProfiles\WinLab.pubxml" />
|
||||
<Content Include="Scripts\jquery-ui-1.10.4.js" />
|
||||
<Content Include="Scripts\jquery-ui-1.10.4.min.js" />
|
||||
@@ -466,6 +478,10 @@
|
||||
<DependentUpon>Web.config</DependentUpon>
|
||||
<SubType>Designer</SubType>
|
||||
</None>
|
||||
<None Include="Web.IIS02.config">
|
||||
<DependentUpon>Web.config</DependentUpon>
|
||||
<SubType>Designer</SubType>
|
||||
</None>
|
||||
<None Include="Web.WinLab.config">
|
||||
<DependentUpon>Web.config</DependentUpon>
|
||||
<SubType>Designer</SubType>
|
||||
@@ -483,6 +499,13 @@
|
||||
<Compile Include="..\VersGen\C2P.cs">
|
||||
<Link>C2P.cs</Link>
|
||||
</Compile>
|
||||
<Compile Include="AgentsMan.aspx.cs">
|
||||
<DependentUpon>AgentsMan.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="AgentsMan.aspx.designer.cs">
|
||||
<DependentUpon>AgentsMan.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="App_Start\BundleConfig.cs" />
|
||||
<Compile Include="App_Start\RouteConfig.cs" />
|
||||
<Compile Include="Bootstrap.Master.cs">
|
||||
@@ -492,6 +515,13 @@
|
||||
<Compile Include="Bootstrap.Master.designer.cs">
|
||||
<DependentUpon>Bootstrap.Master</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="CsvExcelExporter.aspx.cs">
|
||||
<DependentUpon>CsvExcelExporter.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="CsvExcelExporter.aspx.designer.cs">
|
||||
<DependentUpon>CsvExcelExporter.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="DbSync.aspx.cs">
|
||||
<DependentUpon>DbSync.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
@@ -506,6 +536,13 @@
|
||||
<Compile Include="Default.aspx.designer.cs">
|
||||
<DependentUpon>Default.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="DiesGroupMan.aspx.cs">
|
||||
<DependentUpon>DiesGroupMan.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="DiesGroupMan.aspx.designer.cs">
|
||||
<DependentUpon>DiesGroupMan.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="ExistingProductOffer.aspx.cs">
|
||||
<DependentUpon>ExistingProductOffer.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
@@ -600,6 +637,20 @@
|
||||
<Compile Include="OffersArchive.aspx.designer.cs">
|
||||
<DependentUpon>OffersArchive.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="PackageMan.aspx.cs">
|
||||
<DependentUpon>PackageMan.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="PackageMan.aspx.designer.cs">
|
||||
<DependentUpon>PackageMan.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="PlantsMan.aspx.cs">
|
||||
<DependentUpon>PlantsMan.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="PlantsMan.aspx.designer.cs">
|
||||
<DependentUpon>PlantsMan.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<Compile Include="Quote.aspx.cs">
|
||||
<DependentUpon>Quote.aspx</DependentUpon>
|
||||
@@ -615,6 +666,13 @@
|
||||
<Compile Include="QuoteDet.aspx.designer.cs">
|
||||
<DependentUpon>QuoteDet.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="RawMatMan.aspx.cs">
|
||||
<DependentUpon>RawMatMan.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="RawMatMan.aspx.designer.cs">
|
||||
<DependentUpon>RawMatMan.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="RepOffers.aspx.cs">
|
||||
<DependentUpon>RepOffers.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
@@ -673,6 +731,13 @@
|
||||
<Compile Include="test.aspx.designer.cs">
|
||||
<DependentUpon>test.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="TranspCostMan.aspx.cs">
|
||||
<DependentUpon>TranspCostMan.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="TranspCostMan.aspx.designer.cs">
|
||||
<DependentUpon>TranspCostMan.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="UpdateVoc.aspx.cs">
|
||||
<DependentUpon>UpdateVoc.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
@@ -701,6 +766,13 @@
|
||||
<Compile Include="Vocabolario.aspx.designer.cs">
|
||||
<DependentUpon>Vocabolario.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_AgentsMan.ascx.cs">
|
||||
<DependentUpon>mod_AgentsMan.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_AgentsMan.ascx.designer.cs">
|
||||
<DependentUpon>mod_AgentsMan.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_autocomplete.ascx.cs">
|
||||
<DependentUpon>mod_autocomplete.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
@@ -708,6 +780,13 @@
|
||||
<Compile Include="WebUserControls\mod_autocomplete.ascx.designer.cs">
|
||||
<DependentUpon>mod_autocomplete.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_autocompleteShort.ascx.cs">
|
||||
<DependentUpon>mod_autocompleteShort.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_autocompleteShort.ascx.designer.cs">
|
||||
<DependentUpon>mod_autocompleteShort.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_createNewStdCost.ascx.cs">
|
||||
<DependentUpon>mod_createNewStdCost.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
@@ -715,6 +794,13 @@
|
||||
<Compile Include="WebUserControls\mod_createNewStdCost.ascx.designer.cs">
|
||||
<DependentUpon>mod_createNewStdCost.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_DiesGroupMan.ascx.cs">
|
||||
<DependentUpon>mod_DiesGroupMan.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_DiesGroupMan.ascx.designer.cs">
|
||||
<DependentUpon>mod_DiesGroupMan.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_display.ascx.cs">
|
||||
<DependentUpon>mod_display.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
@@ -841,6 +927,20 @@
|
||||
<Compile Include="WebUserControls\mod_OffersArchive.ascx.designer.cs">
|
||||
<DependentUpon>mod_OffersArchive.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_PackageMan.ascx.cs">
|
||||
<DependentUpon>mod_PackageMan.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_PackageMan.ascx.designer.cs">
|
||||
<DependentUpon>mod_PackageMan.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_PlantsMan.ascx.cs">
|
||||
<DependentUpon>mod_PlantsMan.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_PlantsMan.ascx.designer.cs">
|
||||
<DependentUpon>mod_PlantsMan.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_QuoteDet.ascx.cs">
|
||||
<DependentUpon>mod_QuoteDet.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
@@ -897,6 +997,13 @@
|
||||
<Compile Include="WebUserControls\mod_range.ascx.designer.cs">
|
||||
<DependentUpon>mod_range.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_RawMatMan.ascx.cs">
|
||||
<DependentUpon>mod_RawMatMan.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_RawMatMan.ascx.designer.cs">
|
||||
<DependentUpon>mod_RawMatMan.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_ricercaGenerica.ascx.cs">
|
||||
<DependentUpon>mod_ricercaGenerica.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
@@ -981,6 +1088,13 @@
|
||||
<Compile Include="WebUserControls\mod_testata.ascx.designer.cs">
|
||||
<DependentUpon>mod_testata.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_TranspCostMan.ascx.cs">
|
||||
<DependentUpon>mod_TranspCostMan.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_TranspCostMan.ascx.designer.cs">
|
||||
<DependentUpon>mod_TranspCostMan.ascx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="WebUserControls\mod_vocabolario.ascx.cs">
|
||||
<DependentUpon>mod_vocabolario.ascx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
@@ -1049,6 +1163,7 @@
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
|
||||
<ExcludeGeneratedDebugSymbol>true</ExcludeGeneratedDebugSymbol>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'IIS02|AnyCPU'">
|
||||
<OutputPath>bin\</OutputPath>
|
||||
@@ -1057,6 +1172,7 @@
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
|
||||
<ExcludeGeneratedDebugSymbol>true</ExcludeGeneratedDebugSymbol>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
|
||||
<Import Project="$(VSToolsPath)\WebApplications\Microsoft.WebApplication.targets" Condition="'$(VSToolsPath)' != ''" />
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<ProjectView>ShowAllFiles</ProjectView>
|
||||
<NameOfLastUsedPublishProfile>WinLab</NameOfLastUsedPublishProfile>
|
||||
<NameOfLastUsedPublishProfile>costimateZip</NameOfLastUsedPublishProfile>
|
||||
</PropertyGroup>
|
||||
<ProjectExtensions>
|
||||
<VisualStudio>
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="CsvExcelExporter.aspx.cs" Inherits="C2P.CsvExcelExporter" EnableEventValidation="false" %>
|
||||
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head runat="server">
|
||||
<title>Excel Export in CSV format</title>
|
||||
</head>
|
||||
<body>
|
||||
<form id="form1" runat="server">
|
||||
<div>
|
||||
</div>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,114 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using SteamWare;
|
||||
using C2P_Data;
|
||||
using System.Text;
|
||||
using System.Data;
|
||||
|
||||
|
||||
namespace C2P
|
||||
{
|
||||
public partial class CsvExcelExporter : System.Web.UI.Page
|
||||
{
|
||||
/// <summary>
|
||||
/// tabella per export CSV richiesta da QueryString
|
||||
/// </summary>
|
||||
public string tableReq
|
||||
{
|
||||
get
|
||||
{
|
||||
return memLayer.ML.QSS("table");
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// caricamento pagina
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
if (!Page.IsPostBack)
|
||||
{
|
||||
doExportCsv();
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// wrapper traduzione
|
||||
/// </summary>
|
||||
/// <param name="lemma"></param>
|
||||
/// <returns></returns>
|
||||
public string traduci(object lemma)
|
||||
{
|
||||
return user_std.UtSn.Traduci(lemma.ToString());
|
||||
}
|
||||
/// <summary>
|
||||
/// fix rendering tabelle standard in webform
|
||||
/// </summary>
|
||||
/// <param name="control"></param>
|
||||
public override void VerifyRenderingInServerForm(Control control)
|
||||
{
|
||||
// Confirms that an HtmlForm control is rendered for the specified ASP.NET server control at run time.
|
||||
}
|
||||
/// <summary>
|
||||
/// Si occupa di rendere l'out HTML come excel file (mimetype)
|
||||
/// </summary>
|
||||
private void doExportCsv()
|
||||
{
|
||||
var dataTable = new DataTable();
|
||||
// in base alla tabella recupero i dati richiesti...
|
||||
switch (tableReq)
|
||||
{
|
||||
case "DiesGroup":
|
||||
dataTable = DtProxy.man.taDGD.GetData();
|
||||
break;
|
||||
case "TranspCost":
|
||||
dataTable = DtProxy.man.taTCD.GetData();
|
||||
break;
|
||||
default:
|
||||
dataTable = DtProxy.man.taTCD.GetData();
|
||||
break;
|
||||
}
|
||||
|
||||
StringBuilder builder = new StringBuilder();
|
||||
List<string> columnNames = new List<string>();
|
||||
List<string> rows = new List<string>();
|
||||
|
||||
foreach (DataColumn column in dataTable.Columns)
|
||||
{
|
||||
columnNames.Add(column.ColumnName);
|
||||
}
|
||||
|
||||
builder.Append(string.Join(memLayer.ML.confReadString("FIELDTERMINATOR"), columnNames.ToArray())).Append("\n");
|
||||
|
||||
foreach (DataRow row in dataTable.Rows)
|
||||
{
|
||||
List<string> currentRow = new List<string>();
|
||||
|
||||
foreach (DataColumn column in dataTable.Columns)
|
||||
{
|
||||
object item = row[column];
|
||||
|
||||
currentRow.Add(item.ToString().Replace("\n", " ").Replace("\r", ""));
|
||||
}
|
||||
|
||||
rows.Add(string.Join(memLayer.ML.confReadString("FIELDTERMINATOR"), currentRow.ToArray()));
|
||||
}
|
||||
|
||||
builder.Append(string.Join("\n", rows.ToArray()));
|
||||
|
||||
Response.Clear();
|
||||
Response.AddHeader("content-disposition", string.Format("attachment; filename={0}.csv", tableReq));
|
||||
Response.ContentType = "text/csv";
|
||||
Response.Charset = "";
|
||||
Response.Cache.SetCacheability(HttpCacheability.NoCache);
|
||||
Response.Write(builder.ToString());
|
||||
Response.End();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
Generated
+26
@@ -0,0 +1,26 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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 C2P
|
||||
{
|
||||
|
||||
|
||||
public partial class CsvExcelExporter
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// form1 control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.HtmlControls.HtmlForm form1;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
<%@ Page Title="" Language="C#" MasterPageFile="~/FullPage.Master" AutoEventWireup="true" CodeBehind="DiesGroupMan.aspx.cs" Inherits="C2P.DiesGroupMan" %>
|
||||
|
||||
<%@ Register Src="~/WebUserControls/mod_DiesGroupMan.ascx" TagPrefix="uc1" TagName="mod_DiesGroupMan" %>
|
||||
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="HeadContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content3" ContentPlaceHolderID="FeaturedContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content4" ContentPlaceHolderID="MainContent" runat="server">
|
||||
<div class="container-fluid" style="background-color: #cdcdcd; padding-top: 2px; padding-bottom: 2px;">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<uc1:mod_DiesGroupMan runat="server" ID="mod_DiesGroupMan" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</asp:Content>
|
||||
@@ -0,0 +1,14 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
|
||||
namespace C2P
|
||||
{
|
||||
public partial class DiesGroupMan : System.Web.UI.Page
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
Generated
+24
@@ -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 C2P {
|
||||
|
||||
|
||||
public partial class DiesGroupMan {
|
||||
|
||||
/// <summary>
|
||||
/// mod_DiesGroupMan control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::C2P.WebUserControls.mod_DiesGroupMan mod_DiesGroupMan;
|
||||
}
|
||||
}
|
||||
@@ -19,7 +19,7 @@
|
||||
<div class="col-xs-12">
|
||||
<asp:UpdatePanel ID="upSelettore" runat="server" ViewStateMode="Disabled">
|
||||
<ContentTemplate>
|
||||
<uc1:mod_autocomplete runat="server" ID="acArticolo" contextKey="a" minCharAutocomplete="3" showKey="false" ServicePath="Services/WS_data.asmx/Items" placeholder="Type to Search" />
|
||||
<uc1:mod_autocomplete runat="server" ID="acArticolo" contextKey="a" minCharAutocomplete="3" showKey="false" ServicePath='<%# serviceUrl("Items") %>' placeholder="Type to Search" />
|
||||
<%--<asp:DropDownList ID="ddlProduct" runat="server" DataSourceID="odsProducts" DataValueField="value" DataTextField="value" AutoPostBack="true" Font-Size="1.4em" />
|
||||
<asp:ObjectDataSource ID="odsProducts" runat="server" OldValuesParameterFormatString="original_{0}" SelectMethod="GetData" TypeName="C2P_Data.DS_UtilityTableAdapters.v_selItemsTableAdapter"></asp:ObjectDataSource>--%>
|
||||
</ContentTemplate>
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using SteamWare;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
@@ -9,11 +10,19 @@ namespace C2P
|
||||
{
|
||||
public partial class ExistingProductOffer : SteamWare.UserPage
|
||||
{
|
||||
/// <summary>
|
||||
/// url base area services
|
||||
/// </summary>
|
||||
public string serviceUrl(string method)
|
||||
{
|
||||
return string.Format("/{0}/WS_data.asmx/{1}", memLayer.ML.confReadString("serviceUrl"), method);
|
||||
}
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
fixDetailVisibility();
|
||||
acArticolo.eh_reset += acArticolo_eh_reset;
|
||||
acArticolo.eh_valSelezionato += acArticolo_eh_valSelezionato;
|
||||
acArticolo.DataBind();
|
||||
}
|
||||
/// <summary>
|
||||
/// selezionato articolo
|
||||
|
||||
+14
-2
@@ -12,9 +12,21 @@
|
||||
<h3 class="panel-title"><%: traduci("ImportData") %></h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div class="row" style="min-height: 3.3em;" runat="server" id="divNoteImport">
|
||||
<div class="col-sm-12">
|
||||
<a class="btn btn-primary" data-toggle="collapse" href="#collapseExample" aria-expanded="false" aria-controls="collapseExample"><%: traduci("NoteImportToggle") %>
|
||||
</a>
|
||||
<div class="collapse" id="collapseExample">
|
||||
<div class="well">
|
||||
<h3><%: traduci("NoteImportTitle") %></h3>
|
||||
<%: traduci("NoteImportBody") %>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row" style="min-height: 3.3em;" runat="server" id="divAllSteps">
|
||||
<div class="col-sm-12">
|
||||
<asp:LinkButton runat="server" ID="lbtAllSteps" CssClass="btn btn-success" Width="100%" OnClick="lbtAllSteps_Click"><%: traduci("tmp.stp_All_Process") %></asp:LinkButton>
|
||||
<asp:LinkButton runat="server" ID="lbtAllSteps" CssClass="btn btn-success" Width="100%" OnClick="lbtAllSteps_Click" OnClientClick='<%# SteamWare.jsUtils.getCBE("confermaImportAll") %>'><%: traduci("tmp.stp_All_Process") %></asp:LinkButton>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row" style="min-height: 3.3em;" runat="server" id="divThreeSteps">
|
||||
@@ -25,7 +37,7 @@
|
||||
<asp:LinkButton runat="server" ID="lbtConvert" CssClass="btn btn-info" Width="100%" OnClick="lbtConvert_Click">Step 2 - <%: traduci("tmp.stp_All_ConvertFile_Process") %></asp:LinkButton>
|
||||
</div>
|
||||
<div class="col-sm-4">
|
||||
<asp:LinkButton runat="server" ID="lbtMerge" CssClass="btn btn-warning" Width="100%" OnClick="lbtMerge_Click">Step 3 - <%: traduci("ext.stp_All_MergeFile_Process") %></asp:LinkButton>
|
||||
<asp:LinkButton runat="server" ID="lbtMerge" CssClass="btn btn-warning" Width="100%" OnClick="lbtMerge_Click" OnClientClick='<%# SteamWare.jsUtils.getCBE("confermaMergeData") %>'>Step 3 - <%: traduci("ext.stp_All_MergeFile_Process") %></asp:LinkButton>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row" style="min-height: 3.3em;">
|
||||
|
||||
+37
-8
@@ -17,6 +17,8 @@ namespace C2P
|
||||
{
|
||||
grViewLog.Visible = false;
|
||||
divThreeSteps.Visible = userIsSuperAdmin;
|
||||
lbtAllSteps.DataBind();
|
||||
lbtMerge.DataBind();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -117,7 +119,32 @@ namespace C2P
|
||||
/// <param name="e"></param>
|
||||
protected void lbtImport_Click(object sender, EventArgs e)
|
||||
{
|
||||
insertStepTicket("step01", 0, DateTime.Now);
|
||||
DateTime adesso = DateTime.Now;
|
||||
addStep01(adesso);
|
||||
}
|
||||
/// <summary>
|
||||
/// aggiungo step 01...
|
||||
/// </summary>
|
||||
/// <param name="adesso"></param>
|
||||
private int addStep01(DateTime adesso)
|
||||
{
|
||||
int answ = 0;
|
||||
// effettuo spostamento file A PRIORI...
|
||||
string importDataFolder = memLayer.ML.confReadString("importDataFolder");
|
||||
string archiveDataFolder = memLayer.ML.confReadString("archiveDataFolder");
|
||||
string uplDir = memLayer.ML.confReadString("uplDir");
|
||||
string archDir = memLayer.ML.confReadString("archDir");
|
||||
// calcolo nuova cartella archivio (anno/mese/gg_ora)
|
||||
archiveDataFolder = string.Format(@"{0}{1:yyyy}\{1:MM}\{1:dd}\{1:HHmmss}\", archiveDataFolder, adesso);
|
||||
archDir = string.Format(@"{0}{1:yyyy}\{1:MM}\{1:dd}\{1:HHmmss}\", archDir, adesso);
|
||||
// sposto i files da TEMP a cartella archive
|
||||
string[] file2move = memLayer.ML.confReadString("elencoFileImportAll").Split(memLayer.ML.confReadString("strSep").ToCharArray()[0]);
|
||||
foreach (string fileName in file2move)
|
||||
{
|
||||
fileMover.obj.muoviFile(importDataFolder, archiveDataFolder, fileName);
|
||||
}
|
||||
answ = insertStepTicket("step01", 0, DateTime.Now, archDir);
|
||||
return answ;
|
||||
}
|
||||
/// <summary>
|
||||
/// fa la chiamata di inserimento step richeisto e aggiorna
|
||||
@@ -126,13 +153,13 @@ namespace C2P
|
||||
/// <param name="prevNumTicket"></param>
|
||||
/// <param name="dataRich"></param>
|
||||
/// <returns>NumTicket generato</returns>
|
||||
private int insertStepTicket(string stepCode, int prevNumTicket, DateTime dataRich)
|
||||
private int insertStepTicket(string stepCode, int prevNumTicket, DateTime dataRich, string filePath)
|
||||
{
|
||||
int answ = 0;
|
||||
DS_Utility.Import_TicketListRow riga;
|
||||
try
|
||||
{
|
||||
string param = string.Format(memLayer.ML.confReadString(stepCode + "_par"), prevNumTicket);
|
||||
string param = string.Format(memLayer.ML.confReadString(stepCode + "_par"), prevNumTicket, filePath);
|
||||
riga = (DS_Utility.Import_TicketListRow)DtProxy.man.taImpTL.InsertQuery(memLayer.ML.confReadString(stepCode + "_stp"), param, dataRich)[0];
|
||||
answ = riga.NumTicket;
|
||||
}
|
||||
@@ -149,7 +176,8 @@ namespace C2P
|
||||
/// <param name="e"></param>
|
||||
protected void lbtConvert_Click(object sender, EventArgs e)
|
||||
{
|
||||
insertStepTicket("step02", 0, DateTime.Now);
|
||||
int NumTicket = 0;
|
||||
insertStepTicket("step02", NumTicket, DateTime.Now, "");
|
||||
}
|
||||
/// <summary>
|
||||
/// chiamata procedura di merge dati
|
||||
@@ -158,7 +186,8 @@ namespace C2P
|
||||
/// <param name="e"></param>
|
||||
protected void lbtMerge_Click(object sender, EventArgs e)
|
||||
{
|
||||
insertStepTicket("step03", 0, DateTime.Now);
|
||||
int NumTicket = 0;
|
||||
insertStepTicket("step03", NumTicket, DateTime.Now, "");
|
||||
}
|
||||
/// <summary>
|
||||
/// chiamata a TUTTE LE procedure x import dati
|
||||
@@ -169,9 +198,9 @@ namespace C2P
|
||||
{
|
||||
int NumTicket = 0;
|
||||
DateTime adesso = DateTime.Now;
|
||||
NumTicket = insertStepTicket("step01", NumTicket, adesso);
|
||||
NumTicket = insertStepTicket("step02", NumTicket, adesso.AddMinutes(1));
|
||||
NumTicket = insertStepTicket("step03", NumTicket, adesso.AddMinutes(2));
|
||||
NumTicket = addStep01(adesso);
|
||||
NumTicket = insertStepTicket("step02", NumTicket, adesso.AddMinutes(1),"");
|
||||
NumTicket = insertStepTicket("step03", NumTicket, adesso.AddMinutes(2),"");
|
||||
}
|
||||
|
||||
|
||||
|
||||
Generated
+9
@@ -12,6 +12,15 @@ namespace C2P {
|
||||
|
||||
public partial class Import {
|
||||
|
||||
/// <summary>
|
||||
/// divNoteImport control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.HtmlControls.HtmlGenericControl divNoteImport;
|
||||
|
||||
/// <summary>
|
||||
/// divAllSteps control.
|
||||
/// </summary>
|
||||
|
||||
+1
-1
@@ -61,7 +61,7 @@ namespace C2P
|
||||
long CodQuote = 0;
|
||||
try
|
||||
{
|
||||
DS_Quotes.QuoteFull_QDataTable tabQuote = DtProxy.man.taQFQ.insertNew("Q", ddlCodCustomer.SelectedValue, CodItem, ddlRawMat.SelectedValue, RawMatCost, 0, batchQty, "EXW", "EXT", user_std.UtSn.utente);
|
||||
DS_Quotes.QuoteFull_QDataTable tabQuote = DtProxy.man.taQFQ.insertNew("Q", ddlCodCustomer.SelectedValue, CodItem, "", ddlRawMat.SelectedValue, RawMatCost, 0, batchQty, "EXW", "EXT", user_std.UtSn.utente);
|
||||
CodQuote = tabQuote[0].CodQuote;
|
||||
if (memLayer.ML.confReadInt("_logLevel") > 5) logger.lg.scriviLog("MakeSim: Step 03", tipoLog.INFO);
|
||||
}
|
||||
|
||||
@@ -1,9 +1,14 @@
|
||||
<%@ Page Title="" Language="C#" MasterPageFile="~/FullPage.master" AutoEventWireup="true" CodeBehind="NewProductOffer.aspx.cs" Inherits="C2P.NewProductOffer" %>
|
||||
<%@ Register src="~/WebUserControls/mod_newProduct.ascx" tagname="mod_newProduct" tagprefix="uc1" %>
|
||||
|
||||
<%@ Register Src="~/WebUserControls/mod_newProduct.ascx" TagName="mod_newProduct" TagPrefix="uc1" %>
|
||||
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="FeaturedContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content3" ContentPlaceHolderID="MainContent" runat="server">
|
||||
<uc1:mod_newProduct ID="mod_newProduct1" runat="server" />
|
||||
<br />
|
||||
<br />
|
||||
<br />
|
||||
<br />
|
||||
</asp:Content>
|
||||
|
||||
@@ -0,0 +1,36 @@
|
||||
<%@ Page Title="" Language="C#" MasterPageFile="~/FullPage.master" AutoEventWireup="true" CodeBehind="PackageMan.aspx.cs" Inherits="C2P.PackageMan" %>
|
||||
|
||||
<%@ Register Src="~/WebUserControls/mod_ricercaGenerica.ascx" TagPrefix="uc1" TagName="mod_ricercaGenerica" %>
|
||||
<%@ Register Src="~/WebUserControls/mod_righePag.ascx" TagName="mod_righePag" TagPrefix="uc1" %>
|
||||
<%@ Register Src="~/WebUserControls/mod_PackageMan.ascx" TagPrefix="uc1" TagName="mod_PackageMan" %>
|
||||
|
||||
|
||||
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="HeadContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content3" ContentPlaceHolderID="FeaturedContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content4" ContentPlaceHolderID="MainContent" runat="server">
|
||||
<div class="container-fluid" style="background-color: #cdcdcd; padding-top: 2px; padding-bottom: 2px;">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-sm-8 col-sm-offset-2 text-center">
|
||||
<uc1:mod_ricercaGenerica runat="server" ID="mod_ricercaGenerica" />
|
||||
</div>
|
||||
<div class="col-sm-2 text-right">
|
||||
<uc1:mod_righePag ID="mod_righePag" runat="server" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="container-fluid" style="padding-top: 2px; padding-bottom: 2px;">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-sm-12">
|
||||
<uc1:mod_PackageMan runat="server" id="mod_PackageMan" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</asp:Content>
|
||||
@@ -0,0 +1,31 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
|
||||
namespace C2P
|
||||
{
|
||||
public partial class PackageMan : System.Web.UI.Page
|
||||
{
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
if (!Page.IsPostBack)
|
||||
{
|
||||
mod_righePag.numRowPag = 20;
|
||||
mod_PackageMan.pageSize = mod_righePag.numRowPag;
|
||||
}
|
||||
mod_righePag.eh_newNum += mod_righePag_eh_newNum;
|
||||
}
|
||||
/// <summary>
|
||||
/// aggiornato numero righe datagrid... aggiorno visualizzazione
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
void mod_righePag_eh_newNum(object sender, EventArgs e)
|
||||
{
|
||||
mod_PackageMan.pageSize = mod_righePag.numRowPag;
|
||||
}
|
||||
}
|
||||
}
|
||||
Generated
+42
@@ -0,0 +1,42 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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 C2P {
|
||||
|
||||
|
||||
public partial class PackageMan {
|
||||
|
||||
/// <summary>
|
||||
/// mod_ricercaGenerica control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::mod_ricercaGenerica mod_ricercaGenerica;
|
||||
|
||||
/// <summary>
|
||||
/// mod_righePag control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::mod_righePag mod_righePag;
|
||||
|
||||
/// <summary>
|
||||
/// mod_PackageMan control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::C2P.WebUserControls.mod_PackageMan mod_PackageMan;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,37 @@
|
||||
<%@ Page Title="" Language="C#" MasterPageFile="~/FullPage.master" AutoEventWireup="true" CodeBehind="PlantsMan.aspx.cs" Inherits="C2P.PlantsMan" %>
|
||||
|
||||
<%@ Register Src="~/WebUserControls/mod_ricercaGenerica.ascx" TagPrefix="uc1" TagName="mod_ricercaGenerica" %>
|
||||
<%@ Register Src="~/WebUserControls/mod_righePag.ascx" TagName="mod_righePag" TagPrefix="uc1" %>
|
||||
<%@ Register Src="~/WebUserControls/mod_PlantsMan.ascx" TagPrefix="uc1" TagName="mod_PlantsMan" %>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="HeadContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content3" ContentPlaceHolderID="FeaturedContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content4" ContentPlaceHolderID="MainContent" runat="server">
|
||||
<div class="container-fluid" style="background-color: #cdcdcd; padding-top: 2px; padding-bottom: 2px;">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-sm-8 col-sm-offset-2 text-center">
|
||||
<uc1:mod_ricercaGenerica runat="server" ID="mod_ricercaGenerica" />
|
||||
</div>
|
||||
<div class="col-sm-2 text-right">
|
||||
<uc1:mod_righePag ID="mod_righePag" runat="server" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="container-fluid" style="padding-top: 2px; padding-bottom: 2px;">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-sm-12">
|
||||
<uc1:mod_PlantsMan runat="server" id="mod_PlantsMan" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</asp:Content>
|
||||
@@ -0,0 +1,31 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
|
||||
namespace C2P
|
||||
{
|
||||
public partial class PlantsMan : System.Web.UI.Page
|
||||
{
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
if (!Page.IsPostBack)
|
||||
{
|
||||
mod_righePag.numRowPag = 20;
|
||||
mod_PlantsMan.pageSize = mod_righePag.numRowPag;
|
||||
}
|
||||
mod_righePag.eh_newNum += mod_righePag_eh_newNum;
|
||||
}
|
||||
/// <summary>
|
||||
/// aggiornato numero righe datagrid... aggiorno visualizzazione
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
void mod_righePag_eh_newNum(object sender, EventArgs e)
|
||||
{
|
||||
mod_PlantsMan.pageSize = mod_righePag.numRowPag;
|
||||
}
|
||||
}
|
||||
}
|
||||
Generated
+42
@@ -0,0 +1,42 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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 C2P {
|
||||
|
||||
|
||||
public partial class PlantsMan {
|
||||
|
||||
/// <summary>
|
||||
/// mod_ricercaGenerica control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::mod_ricercaGenerica mod_ricercaGenerica;
|
||||
|
||||
/// <summary>
|
||||
/// mod_righePag control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::mod_righePag mod_righePag;
|
||||
|
||||
/// <summary>
|
||||
/// mod_PlantsMan control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::C2P.WebUserControls.mod_PlantsMan mod_PlantsMan;
|
||||
}
|
||||
}
|
||||
@@ -1,43 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
This file is used by the publish/package process of your Web project. You can customize the behavior of this process
|
||||
by editing this MSBuild file. In order to learn more about this please visit http://go.microsoft.com/fwlink/?LinkID=208121.
|
||||
-->
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<EnableMSDeployAppOffline>true</EnableMSDeployAppOffline>
|
||||
<WebPublishMethod>Package</WebPublishMethod>
|
||||
<LastUsedBuildConfiguration>Release</LastUsedBuildConfiguration>
|
||||
<LastUsedPlatform>Any CPU</LastUsedPlatform>
|
||||
<SiteUrlToLaunchAfterPublish />
|
||||
<LaunchSiteAfterPublish>True</LaunchSiteAfterPublish>
|
||||
<PrecompileBeforePublish>True</PrecompileBeforePublish>
|
||||
<EnableUpdateable>True</EnableUpdateable>
|
||||
<DebugSymbols>False</DebugSymbols>
|
||||
<WDPMergeOption>DonotMerge</WDPMergeOption>
|
||||
<ExcludeApp_Data>True</ExcludeApp_Data>
|
||||
<DesktopBuildPackageLocation>C:\Users\samuele\Documents\Visual Studio 2012\Projects\C2P\ReleaseClienti\C2P.zip</DesktopBuildPackageLocation>
|
||||
<PackageAsSingleFile>true</PackageAsSingleFile>
|
||||
<DeployIisAppPath>C2P</DeployIisAppPath>
|
||||
<PublishDatabaseSettings>
|
||||
<Objects xmlns="">
|
||||
<ObjectGroup Name="C2P_Data.Properties.Settings.C2PConnectionString" Order="1" Enabled="True">
|
||||
<Destination Path="Data Source=10.74.82.217\SQL2008R2;Initial Catalog=C2P;Persist Security Info=True;User ID=sa;Password=keyhammer" />
|
||||
<Object Type="DbDacFx">
|
||||
<PreSource Path="Data Source=10.74.82.217\SQL2008R2;Initial Catalog=C2P;Persist Security Info=True;User ID=sa;Password=keyhammer" includeData="False" />
|
||||
<Source Path="$(IntermediateOutputPath)AutoScripts\C2P_Data.Properties.Settings.C2PConnectionString_IncrementalSchemaOnly.dacpac" dacpacAction="Deploy" />
|
||||
</Object>
|
||||
<UpdateFrom Type="Web.Config">
|
||||
<Source MatchValue="Data Source=10.74.82.217\SQL2008R2;Initial Catalog=C2P;Persist Security Info=True;User ID=sa;Password=keyhammer;" MatchAttributes="$(UpdateFromConnectionStringAttributes)" />
|
||||
</UpdateFrom>
|
||||
</ObjectGroup>
|
||||
</Objects>
|
||||
</PublishDatabaseSettings>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<MSDeployParameterValue Include="$(DeployParameterPrefix)C2P_Data.Properties.Settings.C2PConnectionString-Web.config Connection String">
|
||||
<ParameterValue>Data Source=10.74.82.217\SQL2008R2;Initial Catalog=C2P;Persist Security Info=True;User ID=sa;Password=keyhammer</ParameterValue>
|
||||
<UpdateDestWebConfig>False</UpdateDestWebConfig>
|
||||
</MSDeployParameterValue>
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
@@ -13,7 +13,7 @@ by editing this MSBuild file. In order to learn more about this please visit htt
|
||||
<ExcludeApp_Data>True</ExcludeApp_Data>
|
||||
<DesktopBuildPackageLocation>C:\Users\samuele\Documents\Visual Studio 2012\Projects\C2P\ReleaseClienti\C2P.zip</DesktopBuildPackageLocation>
|
||||
<PackageAsSingleFile>true</PackageAsSingleFile>
|
||||
<DeployIisAppPath>Default Web Site/C2P</DeployIisAppPath>
|
||||
<DeployIisAppPath>Default Web Site</DeployIisAppPath>
|
||||
<PublishDatabaseSettings>
|
||||
<Objects xmlns="">
|
||||
<ObjectGroup Name="SteamWare.Properties.Settings.DS_AuthConnectionString" Order="2" Enabled="False">
|
||||
|
||||
@@ -7,4 +7,8 @@
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content3" ContentPlaceHolderID="MainContent" runat="server">
|
||||
<uc1:mod_QuoteDet ID="mod_QuoteDet1" runat="server" />
|
||||
<br />
|
||||
<br />
|
||||
<br />
|
||||
<br />
|
||||
</asp:Content>
|
||||
|
||||
@@ -21,38 +21,7 @@ namespace C2P
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
#if false
|
||||
mod_newQuote1.eh_newSearchData += mod_newQuote1_eh_newSearchData;
|
||||
mod_newQuote1.eh_newQuote += mod_newQuote1_eh_newQuote;
|
||||
mod_newQuote1.eh_reset += mod_newQuote1_eh_reset;
|
||||
mod_QuoteList1.eh_loadReq += mod_QuoteList1_eh_loadReq;
|
||||
#endif
|
||||
}
|
||||
|
||||
#if false
|
||||
void mod_newQuote1_eh_reset(object sender, EventArgs e)
|
||||
{
|
||||
mod_QuoteList1.reset();
|
||||
}
|
||||
/// <summary>
|
||||
/// richeista load dati dell'offerta...
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
void mod_QuoteList1_eh_loadReq(object sender, EventArgs e)
|
||||
{
|
||||
mod_newQuote1.loadSelData();
|
||||
}
|
||||
|
||||
void mod_newQuote1_eh_newQuote(object sender, EventArgs e)
|
||||
{
|
||||
mod_QuoteList1.doUpdate();
|
||||
}
|
||||
|
||||
void mod_newQuote1_eh_newSearchData(object sender, EventArgs e)
|
||||
{
|
||||
mod_QuoteList1.doUpdate();
|
||||
}
|
||||
#endif
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
<%@ Page Title="Alloy Man" Language="C#" MasterPageFile="~/FullPage.master" AutoEventWireup="true" CodeBehind="RawMatMan.aspx.cs" Inherits="C2P.RawMatMan" %>
|
||||
|
||||
<%@ Register Src="~/WebUserControls/mod_ricercaGenerica.ascx" TagPrefix="uc1" TagName="mod_ricercaGenerica" %>
|
||||
<%@ Register Src="~/WebUserControls/mod_righePag.ascx" TagName="mod_righePag" TagPrefix="uc1" %>
|
||||
<%@ Register Src="~/WebUserControls/mod_RawMatMan.ascx" TagPrefix="uc1" TagName="mod_RawMatMan" %>
|
||||
|
||||
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="HeadContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content3" ContentPlaceHolderID="FeaturedContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content4" ContentPlaceHolderID="MainContent" runat="server">
|
||||
<div class="container-fluid" style="background-color: #cdcdcd; padding-top: 2px; padding-bottom: 2px;">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-sm-8 col-sm-offset-2 text-center">
|
||||
<uc1:mod_ricercaGenerica runat="server" ID="mod_ricercaGenerica" />
|
||||
</div>
|
||||
<div class="col-sm-2 text-right">
|
||||
<uc1:mod_righePag ID="mod_righePag" runat="server" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="container-fluid" style="padding-top: 2px; padding-bottom: 2px;">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-sm-12">
|
||||
<uc1:mod_RawMatMan runat="server" id="mod_RawMatMan" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</asp:Content>
|
||||
@@ -0,0 +1,31 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
|
||||
namespace C2P
|
||||
{
|
||||
public partial class RawMatMan : System.Web.UI.Page
|
||||
{
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
if (!Page.IsPostBack)
|
||||
{
|
||||
mod_righePag.numRowPag = 20;
|
||||
mod_RawMatMan.pageSize = mod_righePag.numRowPag;
|
||||
}
|
||||
mod_righePag.eh_newNum += mod_righePag_eh_newNum;
|
||||
}
|
||||
/// <summary>
|
||||
/// aggiornato numero righe datagrid... aggiorno visualizzazione
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
void mod_righePag_eh_newNum(object sender, EventArgs e)
|
||||
{
|
||||
mod_RawMatMan.pageSize = mod_righePag.numRowPag;
|
||||
}
|
||||
}
|
||||
}
|
||||
Generated
+42
@@ -0,0 +1,42 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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 C2P {
|
||||
|
||||
|
||||
public partial class RawMatMan {
|
||||
|
||||
/// <summary>
|
||||
/// mod_ricercaGenerica control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::mod_ricercaGenerica mod_ricercaGenerica;
|
||||
|
||||
/// <summary>
|
||||
/// mod_righePag control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::mod_righePag mod_righePag;
|
||||
|
||||
/// <summary>
|
||||
/// mod_RawMatMan control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::C2P.WebUserControls.mod_RawMatMan mod_RawMatMan;
|
||||
}
|
||||
}
|
||||
+12
-1
@@ -17,8 +17,19 @@ namespace C2P
|
||||
{
|
||||
if (!Page.IsPostBack)
|
||||
{
|
||||
// calcolo livello di auth utente...
|
||||
string livAuth = "1";
|
||||
if (devicesAuthProxy.stObj.userHasRight("SuperAdmin") || devicesAuthProxy.stObj.userHasRight("Admin"))
|
||||
{
|
||||
livAuth = "3";
|
||||
}
|
||||
else if (devicesAuthProxy.stObj.userHasRight("SuperUser"))
|
||||
{
|
||||
livAuth = "2";
|
||||
}
|
||||
|
||||
// imposto iframe! con tutti i possibili valori di URL
|
||||
repView.Src = string.Format(@"{0}/ReportViewer.aspx?ticket={1}&lingua={2}&QuoteType={3}&CodQuote={4}&QuoteRev={5}&TypeDoc={6}", memLayer.ML.confReadString("reportsUrl"), Request.QueryString["ticket"], user_std.UtSn.lingua, Request.QueryString["QuoteType"], Request.QueryString["CodQuote"], Request.QueryString["QuoteRev"], Request.QueryString["TypeDoc"]);
|
||||
repView.Src = string.Format(@"{0}/ReportViewer.aspx?ticket={1}&lingua={2}&QuoteType={3}&CodQuote={4}&QuoteRev={5}&TypeDoc={6}&livAuth={7}", memLayer.ML.confReadString("reportsUrl"), Request.QueryString["ticket"], user_std.UtSn.lingua, Request.QueryString["QuoteType"], Request.QueryString["CodQuote"], Request.QueryString["QuoteRev"], Request.QueryString["TypeDoc"], livAuth);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
Before Width: | Height: | Size: 16 KiB |
@@ -13,18 +13,28 @@
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div class="row" style="min-height: 3.1em;">
|
||||
<div class="col-sm-3">
|
||||
<div class="col-sm-2 col-sm-offset-1">
|
||||
<asp:LinkButton runat="server" Width="100%" ID="lbOpen" CssClass="btn btn-success" OnClick="lbOpen_Click"><i class="fa fa-search"></i> <%:traduci("Open") %></asp:LinkButton>
|
||||
</div>
|
||||
<div class="col-sm-3">
|
||||
<asp:LinkButton runat="server" Width="100%" ID="lbDuplicate" CssClass="btn btn-warning" OnClick="lbDuplicate_Click"><i class="fa fa-code-fork"></i> <%:traduci("Duplicate") %></asp:LinkButton>
|
||||
<div class="col-sm-2">
|
||||
<asp:LinkButton runat="server" Width="100%" ID="lbDuplicate" CssClass="btn btn-warning" OnClick="lbDuplicate_Click" Visible="false"><i class="fa fa-code-fork"></i> <%:traduci("Duplicate") %></asp:LinkButton>
|
||||
</div>
|
||||
<div class="col-sm-3">
|
||||
<asp:LinkButton runat="server" Width="100%" ID="lbSimulate" CssClass="btn btn-danger" OnClick="lbSimulate_Click"><i class="fa fa-flask"></i> <%:traduci("Simulate") %></asp:LinkButton>
|
||||
<div class="col-sm-2">
|
||||
<asp:LinkButton runat="server" Width="100%" ID="lbSimulate" CssClass="btn btn-danger" OnClick="lbSimulate_Click" Visible="false"><i class="fa fa-flask"></i> <%:traduci("Simulate") %></asp:LinkButton>
|
||||
</div>
|
||||
<div class="col-sm-3">
|
||||
<div class="col-sm-2">
|
||||
<asp:LinkButton runat="server" Width="100%" ID="lbPrint" CssClass="btn btn-info" OnClick="lbPrint_Click"><i class="fa fa-print"></i> <%:traduci("Print") %></asp:LinkButton>
|
||||
</div>
|
||||
<div class="col-sm-2" style="padding: 0px 4px;">
|
||||
<asp:DropDownList runat="server" ID="ddlTypeDoc" CssClass="btn btn-default dropdown-toggle" Font-Size="X-Small" DataSourceID="odsTipoDoc" DataTextField="label" datal="value" DataValueField="value" Enabled="false">
|
||||
</asp:DropDownList>
|
||||
<asp:ObjectDataSource ID="odsTipoDoc" runat="server" OldValuesParameterFormatString="original_{0}" SelectMethod="getByTableField" TypeName="C2P_Data.DS_UtilityTableAdapters.v_selListValTableAdapter">
|
||||
<SelectParameters>
|
||||
<asp:Parameter DefaultValue="*" Name="TableName" Type="String" />
|
||||
<asp:Parameter DefaultValue="TipoDoc" Name="FieldName" Type="String" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-sm-12">
|
||||
|
||||
+23
-10
@@ -25,15 +25,15 @@ namespace C2P
|
||||
{
|
||||
baseCss = "btn disabled btn-";
|
||||
lbOpen.CssClass = baseCss + "success";
|
||||
lbDuplicate.CssClass = baseCss + "warning";
|
||||
lbSimulate.CssClass = baseCss + "danger";
|
||||
lbDuplicate.CssClass = baseCss + "primary";
|
||||
lbSimulate.CssClass = baseCss + "warning";
|
||||
lbPrint.CssClass = baseCss + "info";
|
||||
}
|
||||
else if (numSel == 1)
|
||||
{
|
||||
lbOpen.CssClass = baseCss + "success";
|
||||
lbDuplicate.CssClass = baseCss + "warning";
|
||||
lbSimulate.CssClass = baseCss + "danger";
|
||||
lbDuplicate.CssClass = baseCss + "primary";
|
||||
lbSimulate.CssClass = baseCss + "warning";
|
||||
lbPrint.CssClass = baseCss + "info";
|
||||
|
||||
// cerco riga selezionata...
|
||||
@@ -41,7 +41,7 @@ namespace C2P
|
||||
for (int i = 0; i < grView.Rows.Count; i++)
|
||||
{
|
||||
grView.SelectedIndex = i;
|
||||
chkBox = ((CheckBox)grView.SelectedRow.FindControl("chkSelect"));
|
||||
chkBox = ((CheckBox)grView.SelectedRow .FindControl("chkSelect"));
|
||||
if (chkBox.Checked)
|
||||
{
|
||||
QuoteType = grView.SelectedDataKey["QuoteType"].ToString();
|
||||
@@ -55,8 +55,8 @@ namespace C2P
|
||||
lbPrint.CssClass = baseCss + "info";
|
||||
baseCss = "btn disabled btn-";
|
||||
lbOpen.CssClass = baseCss + "success";
|
||||
lbDuplicate.CssClass = baseCss + "warning";
|
||||
lbSimulate.CssClass = baseCss + "danger";
|
||||
lbDuplicate.CssClass = baseCss + "primary";
|
||||
lbSimulate.CssClass = baseCss + "warning";
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
@@ -117,7 +117,11 @@ namespace C2P
|
||||
}
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
if (!Page.IsPostBack)
|
||||
{
|
||||
numSel = 0;
|
||||
}
|
||||
setBtnVisib();
|
||||
}
|
||||
/// <summary>
|
||||
/// stringa formattata del numero di record mostrati
|
||||
@@ -207,7 +211,15 @@ namespace C2P
|
||||
/// <param name="e"></param>
|
||||
protected void lbSimulate_Click(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
// duplica offerta!
|
||||
DS_Quotes.QuoteListDataTable tab = DtProxy.man.taQL.clone(QuoteType, user_std.UtSn.utente, QuoteType, Convert.ToInt32(CodQuote), Convert.ToInt32(QuoteRev));
|
||||
if (tab.Rows.Count > 0)
|
||||
{
|
||||
// rendo simulazione!
|
||||
tab = DtProxy.man.taQL.makeSim(tab[0].CodQuote, tab[0].QuoteRev, user_std.UtSn.utente);
|
||||
// seleziona l'offerta duplicata!
|
||||
Response.Redirect(string.Format("Quote?QuoteType={0}&CodQuote={1}&QuoteRev={2}", tab[0].QuoteType, tab[0].CodQuote, tab[0].QuoteRev));
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// stampa offerta(e) selezionata(e)
|
||||
@@ -242,7 +254,8 @@ namespace C2P
|
||||
}
|
||||
}
|
||||
// rimando a pagina di stampa reports...
|
||||
Response.Redirect(string.Format("RepOffers?ticket={0}", ticket));
|
||||
//Response.Redirect(string.Format("RepOffers?ticket={0}", ticket));
|
||||
Response.Redirect(string.Format("RepOffers?ticket={0}&QuoteType={1}&CodQuote=0&QuoteRev=0&TypeDoc={2}", ticket, QuoteType, ddlTypeDoc.SelectedValue));
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
|
||||
Generated
+18
@@ -48,6 +48,24 @@ namespace C2P {
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton lbPrint;
|
||||
|
||||
/// <summary>
|
||||
/// ddlTypeDoc 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.DropDownList ddlTypeDoc;
|
||||
|
||||
/// <summary>
|
||||
/// odsTipoDoc 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.ObjectDataSource odsTipoDoc;
|
||||
|
||||
/// <summary>
|
||||
/// grView control.
|
||||
/// </summary>
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
<%@ Page Title="" Language="C#" MasterPageFile="~/FullPage.Master" AutoEventWireup="true" CodeBehind="TranspCostMan.aspx.cs" Inherits="C2P.TranspCostMan" %>
|
||||
|
||||
<%@ Register Src="~/WebUserControls/mod_TranspCostMan.ascx" TagPrefix="uc1" TagName="mod_TranspCostMan" %>
|
||||
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="HeadContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content3" ContentPlaceHolderID="FeaturedContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content4" ContentPlaceHolderID="MainContent" runat="server">
|
||||
<div class="container-fluid" style="background-color: #cdcdcd; padding-top: 2px; padding-bottom: 2px;">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<uc1:mod_TranspCostMan runat="server" id="mod_TranspCostMan" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</asp:Content>
|
||||
@@ -0,0 +1,17 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
|
||||
namespace C2P
|
||||
{
|
||||
public partial class TranspCostMan : System.Web.UI.Page
|
||||
{
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
Generated
+24
@@ -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 C2P {
|
||||
|
||||
|
||||
public partial class TranspCostMan {
|
||||
|
||||
/// <summary>
|
||||
/// mod_TranspCostMan control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::C2P.WebUserControls.mod_TranspCostMan mod_TranspCostMan;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,36 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
|
||||
<!-- For more information on using web.config transformation visit http://go.microsoft.com/fwlink/?LinkId=125889 -->
|
||||
|
||||
<configuration xmlns:xdt="http://schemas.microsoft.com/XML-Document-Transform">
|
||||
<!--
|
||||
In the example below, the "SetAttributes" transform will change the value of
|
||||
"connectionString" to use "ReleaseSQLServer" only when the "Match" locator
|
||||
finds an attribute "name" that has a value of "MyDB".
|
||||
|
||||
<connectionStrings>
|
||||
<add name="MyDB"
|
||||
connectionString="Data Source=ReleaseSQLServer;Initial Catalog=MyReleaseDB;Integrated Security=True"
|
||||
xdt:Transform="SetAttributes" xdt:Locator="Match(name)"/>
|
||||
</connectionStrings>
|
||||
-->
|
||||
<appSettings>
|
||||
<add key="_logLevel" value="6" xdt:Transform="SetAttributes" xdt:Locator="Match(key)"/>
|
||||
<add key="enablePlain" value="true" xdt:Transform="SetAttributes" xdt:Locator="Match(key)"/>
|
||||
<add key="serviceUrl" value="C2P/Services" xdt:Transform="SetAttributes" xdt:Locator="Match(key)"/>
|
||||
</appSettings>
|
||||
<system.web>
|
||||
<compilation xdt:Transform="RemoveAttributes(debug)" />
|
||||
<!--
|
||||
In the example below, the "Replace" transform will replace the entire
|
||||
<customErrors> section of your web.config file.
|
||||
Note that because there is only one customErrors section under the
|
||||
<system.web> node, there is no need to use the "xdt:Locator" attribute.
|
||||
|
||||
<customErrors defaultRedirect="GenericError.htm"
|
||||
mode="RemoteOnly" xdt:Transform="Replace">
|
||||
<error statusCode="500" redirect="InternalError.htm"/>
|
||||
</customErrors>
|
||||
-->
|
||||
</system.web>
|
||||
</configuration>
|
||||
+29
-17
@@ -28,21 +28,32 @@
|
||||
<add key="defaultUser" value="#proxima#" />
|
||||
<add key="defaultDomain" value="#WINLAB#" />
|
||||
<!--gestione auth dispositivi-->
|
||||
<add key="AuthCookieName" value="AuthDeviceC2P"/>
|
||||
<add key="AuthCookieName" value="AuthDeviceC2P" />
|
||||
<add key="defaultDomain" value="steamwarewin" />
|
||||
<add key="enablePlain" value="false" />
|
||||
<add key="urlGestUtenti" value="UserAdmin"/>
|
||||
<add key="adminEmail" value="samuele@steamware.net"/>
|
||||
<add key="enablePlain" value="true" />
|
||||
<add key="urlGestUtenti" value="UserAdmin" />
|
||||
<add key="adminEmail" value="samuele@steamware.net" />
|
||||
<add key="PageNoIndex" value="UserAdmin#Test" />
|
||||
<!--gestione timeout "esteso" x chiamate SQL critiche, in secondi -->
|
||||
<add key="sqlLongCommandTimeout" value="600" />
|
||||
<!--area import dati-->
|
||||
<add key="step01_stp" value="[tmp].[stp_All_ImportFile_Process]"/>
|
||||
<add key="step01_par" value="@filePath='e:\test\',@ProcDiesGroup=1,@precNumTicket={0}"/>
|
||||
<add key="step02_stp" value="[tmp].[stp_All_ConvertFile_Process]"/>
|
||||
<add key="step02_par" value="@ProcDiesGroup=1,@precNumTicket={0}"/>
|
||||
<add key="step03_stp" value="[ext].[stp_All_MergeFile_Process]"/>
|
||||
<add key="step03_par" value="@flgUpdate=0,@precNumTicket={0}"/>
|
||||
<add key="step01_stp" value="[tmp].[stp_All_ImportFile_Process]" />
|
||||
<add key="step01_par" value="@filePath='{1}',@ProcDiesGroup=1,@precNumTicket={0}" />
|
||||
<add key="step02_stp" value="[tmp].[stp_All_ConvertFile_Process]" />
|
||||
<add key="step02_par" value="@ProcDiesGroup=1,@precNumTicket={0}" />
|
||||
<add key="step03_stp" value="[ext].[stp_All_MergeFile_Process]" />
|
||||
<add key="step03_par" value="@flgUpdate=0,@precNumTicket={0}" />
|
||||
<add key="strSep" value="#" />
|
||||
<add key="elencoFileImportAll" value="ProductRaw.csv#ClientsRaw.csv#TranspCostRaw.csv#ItemsRaw.csv#PackagRaw.csv#DiesRaw.csv#DiesGroupRaw.csv" />
|
||||
<add key="importDataFolder" value="\\10.74.82.217\ImportData\" />
|
||||
<add key="archiveDataFolder" value="\\10.74.82.217\Archive\" />
|
||||
<add key="uplDir" value="\\10.74.82.217\ImportData\" />
|
||||
<add key="archDir" value="\\10.74.82.217\Archive\" />
|
||||
<add key="FIELDTERMINATOR" value=";" />
|
||||
<add key="ROWTERMINATOR" value="\n" />
|
||||
<add key="FIRSTROW" value="2" />
|
||||
<add key="CODEPAGE" value="ACP" />
|
||||
<add key="flgUpdate" value="true" />
|
||||
<!--area suggerimenti-->
|
||||
<add key="maxNumSuggest" value="50" />
|
||||
<!--area logger-->
|
||||
@@ -51,15 +62,18 @@
|
||||
<add key="_logLevel" value="6" />
|
||||
<add key="_logMaxMb" value="30" />
|
||||
<add key="defDayFrom" value="-365" />
|
||||
<add key="intUpdatePagina_ms" value="60000" />
|
||||
<!--area import dati-->
|
||||
<add key="importDataFolder" value="\\10.74.82.217\e$\test" />
|
||||
<add key="intUpdatePagina_ms" value="120000" />
|
||||
<!--area default creazione valori -->
|
||||
<add key="defaultCodClient" value="00000000000" />
|
||||
<add key="defaultCodItem" value="00000000" />
|
||||
<!--area reports-->
|
||||
<add key="ReportRemoteRender" value="true" />
|
||||
<add key="enableQueue" value="false" />
|
||||
<add key="PdfFolder" value="PDF" />
|
||||
<add key="doPdfCopy" value="false" />
|
||||
<add key="reportsUrl" value="http://IIS02/C2P_Report" />
|
||||
<!--area url x webservices-->
|
||||
<add key="serviceUrl" value="Services" />
|
||||
<!--numero record max x processing lunghi-->
|
||||
<add key="rec2procQLR" value="500" />
|
||||
<add key="rec2procQLC" value="500" />
|
||||
@@ -78,7 +92,7 @@
|
||||
<add key="baseUrl" value="http://IIS02/C2P" />
|
||||
<add key="wfApprTo" value="samuele@steamware.net" />
|
||||
<!--link esterni-->
|
||||
<add key="linkSwProfili" value="http://sambha.soltea.it/SambhaWeb"/>
|
||||
<add key="linkSwProfili" value="http://sambha.soltea.it/SambhaWeb" />
|
||||
<!--stringhe connessione-->
|
||||
<add key="C2PConnectionString" value="Data Source=10.74.82.217\SQL2008R2;Initial Catalog=C2P;Persist Security Info=True;User ID=sa;Password=keyhammer" />
|
||||
<add key="PermessiConnectionString" value="Data Source=10.74.82.217\sql2008r2;Initial Catalog=C2P;Persist Security Info=True;User ID=sa;Password=keyhammer" />
|
||||
@@ -201,9 +215,7 @@
|
||||
</basicHttpBinding>
|
||||
</bindings>
|
||||
<client>
|
||||
<endpoint address="http://c2p.steamware.net/Services/WS_data.asmx"
|
||||
binding="basicHttpBinding" bindingConfiguration="WS_dataSoap"
|
||||
contract="RemoteWS.WS_dataSoap" name="WS_dataSoap" />
|
||||
<endpoint address="http://c2p.steamware.net/Services/WS_data.asmx" binding="basicHttpBinding" bindingConfiguration="WS_dataSoap" contract="RemoteWS.WS_dataSoap" name="WS_dataSoap" />
|
||||
<!--<endpoint address="http://iis02/C2P/Services/WS_data.asmx" binding="basicHttpBinding"
|
||||
bindingConfiguration="WS_dataSoap1" contract="RemoteWS.WS_dataSoap"
|
||||
name="WS_dataSoap1" />-->
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
<add key="_emailPwd" value="drmfsls16" xdt:Transform="SetAttributes" xdt:Locator="Match(key)" />
|
||||
<add key="_enableSSL" value="true" xdt:Transform="SetAttributes" xdt:Locator="Match(key)" />
|
||||
|
||||
<add key="baseUrl" value="http://costimate/C2P" xdt:Transform="SetAttributes" xdt:Locator="Match(key)" />
|
||||
<add key="baseUrl" value="http://costimate" xdt:Transform="SetAttributes" xdt:Locator="Match(key)" />
|
||||
<add key="wfApprTo" value="samuele@steamware.net" xdt:Transform="SetAttributes" xdt:Locator="Match(key)" />
|
||||
|
||||
<add key="C2PConnectionString" value="Data Source=localhost;Initial Catalog=C2P;Persist Security Info=True;User ID=connC2P;Password=C2P_pwd" xdt:Transform="SetAttributes" xdt:Locator="Match(key)"/>
|
||||
|
||||
@@ -0,0 +1,60 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_AgentsMan.ascx.cs" Inherits="C2P.WebUserControls.mod_AgentsMan" %>
|
||||
<div class="row" style="font-size: 8pt;">
|
||||
<div class="col-sm-12">
|
||||
<asp:LinkButton ID="lbtNew" runat="server" OnClick="lbtNew_Click" CssClass="btn btn-success"><%: traduci("btnNewAgent") %></asp:LinkButton>
|
||||
<asp:TextBox ID="txtNewVal" runat="server" />
|
||||
</div>
|
||||
<div class="col-sm-12">
|
||||
<asp:GridView ID="grView" runat="server" AllowPaging="True" AllowSorting="True" AutoGenerateColumns="False" DataKeyNames="CodAg" DataSourceID="ods" OnDataBound="grView_DataBound" CssClass="table table-striped table-bordered" OnRowEditing="grView_RowEditing">
|
||||
<Columns>
|
||||
<asp:TemplateField ShowHeader="False" ItemStyle-HorizontalAlign="Center" ItemStyle-Wrap="false">
|
||||
<EditItemTemplate>
|
||||
<asp:LinkButton runat="server" ID="lbUpdate" CausesValidation="true" CommandName="Update"><i class="fa fa-check fa-2x"></i></asp:LinkButton>
|
||||
<asp:LinkButton runat="server" ID="lbCancel" CausesValidation="false" CommandName="Cancel"><i class="fa fa-undo fa-2x"></i></asp:LinkButton>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton runat="server" ID="lbEdit" CausesValidation="false" CommandName="Edit" Visible='<%# !checkValEq(Eval("CodAg"), "TBD") %>'><i class="fa fa-edit fa-2x"></i></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="CodAg" HeaderText="CodAg" SortExpression="CodAg" />
|
||||
<asp:BoundField DataField="Lastname" HeaderText="Lastname" SortExpression="Lastname" />
|
||||
<asp:BoundField DataField="Firstname" HeaderText="Firstname" SortExpression="Firstname" />
|
||||
<asp:BoundField DataField="QuotaProvvAg" HeaderText="QuotaProvvAg" SortExpression="QuotaProvvAg" DataFormatString="{0:C4}" />
|
||||
<asp:TemplateField ShowHeader="False" ItemStyle-HorizontalAlign="Center" ItemStyle-Wrap="false">
|
||||
<EditItemTemplate>
|
||||
<asp:LinkButton runat="server" ID="lbUpdate2" CausesValidation="true" CommandName="Update"><i class="fa fa-check fa-2x"></i></asp:LinkButton>
|
||||
<asp:LinkButton runat="server" ID="lbCancel2" CausesValidation="false" CommandName="Cancel"><i class="fa fa-undo fa-2x"></i></asp:LinkButton>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton runat="server" ID="lbDelete" CausesValidation="false" CommandName="Delete" OnClientClick='<%# SteamWare.jsUtils.getCBE("confermaDel") %>' Visible='<%# !checkValEq(Eval("CodAg"), "TBD") %>'><i class="fa fa-trash-o fa-2x"></i></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
<EmptyDataTemplate>
|
||||
<asp:Label runat="server" ID="lblNoRecord" Text='<%# traduci("noRecord") %>' />
|
||||
</EmptyDataTemplate>
|
||||
</asp:GridView>
|
||||
<asp:Label ID="lblNumRec" runat="server" CssClass="didascalia" />
|
||||
<asp:ObjectDataSource ID="ods" runat="server" SelectMethod="GetData" TypeName="C2P_Data.DS_QuotesTableAdapters.AgentsDetTableAdapter" UpdateMethod="updateQuery" DeleteMethod="deleteQuery" OldValuesParameterFormatString="original_{0}" FilterExpression="CodAg LIKE '%{0}%' OR Lastname LIKE '%{0}%' OR Firstname LIKE '%{0}%' " InsertMethod="insertQuery">
|
||||
<DeleteParameters>
|
||||
<asp:Parameter Name="Original_CodAg" Type="String" />
|
||||
</DeleteParameters>
|
||||
<FilterParameters>
|
||||
<asp:SessionParameter DefaultValue="*" Name="ricerca" SessionField="valoreCercato" />
|
||||
</FilterParameters>
|
||||
<InsertParameters>
|
||||
<asp:Parameter Name="CodAg" Type="String" />
|
||||
<asp:Parameter Name="Lastname" Type="String" />
|
||||
<asp:Parameter Name="Firstname" Type="String" />
|
||||
<asp:Parameter Name="QuotaProvvAg" Type="Decimal" />
|
||||
</InsertParameters>
|
||||
<UpdateParameters>
|
||||
<asp:Parameter Name="CodAg" Type="String" />
|
||||
<asp:Parameter Name="Lastname" Type="String" />
|
||||
<asp:Parameter Name="Firstname" Type="String" />
|
||||
<asp:Parameter Name="QuotaProvvAg" Type="Decimal" />
|
||||
<asp:Parameter Name="Original_CodAg" Type="String" />
|
||||
</UpdateParameters>
|
||||
</asp:ObjectDataSource>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,131 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using SteamWare;
|
||||
using C2P_Data;
|
||||
|
||||
namespace C2P.WebUserControls
|
||||
{
|
||||
public partial class mod_AgentsMan : SteamWare.UserControl
|
||||
{
|
||||
/// <summary>
|
||||
/// caricamento pagina
|
||||
/// </summary>
|
||||
protected void Page_Load()
|
||||
{
|
||||
if (!Page.IsPostBack)
|
||||
{
|
||||
txtNewVal.Text = "";
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// inserisco nel db il nuovo lemma...
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void lbtNew_Click(object sender, EventArgs e)
|
||||
{
|
||||
creaNuovo();
|
||||
}
|
||||
/// <summary>
|
||||
/// dimensione pagina grid view
|
||||
/// </summary>
|
||||
public int pageSize
|
||||
{
|
||||
get
|
||||
{
|
||||
return grView.PageSize;
|
||||
}
|
||||
set
|
||||
{
|
||||
grView.PageSize = value;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// post bind grView
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void grView_DataBound(object sender, EventArgs e)
|
||||
{
|
||||
if (grView.Rows.Count > 0)
|
||||
{
|
||||
LinkButton lb;
|
||||
// aggiorno gli headers
|
||||
foreach (TableCell cella in grView.HeaderRow.Cells)
|
||||
{
|
||||
try
|
||||
{
|
||||
lb = (LinkButton)cella.Controls[0];
|
||||
lb.Text = traduci(lb.Text);
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
}
|
||||
int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1);
|
||||
lblNumRec.Text = string.Format("{0} ({1})", grView.Rows.Count, totRecord);
|
||||
}
|
||||
else
|
||||
{
|
||||
lblNumRec.Text = "";
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// editing riga
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void grView_RowEditing(object sender, GridViewEditEventArgs e)
|
||||
{
|
||||
// seleziono la riga corrente...
|
||||
grView.SelectedIndex = e.NewEditIndex;
|
||||
}
|
||||
/// <summary>
|
||||
/// resetta la selezione dei valori in caso di modifiche su altri controlli
|
||||
/// </summary>
|
||||
public void resetSelezione()
|
||||
{
|
||||
grView.SelectedIndex = -1;
|
||||
grView.DataBind();
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// creazione nuovo lemma
|
||||
/// </summary>
|
||||
private void creaNuovo()
|
||||
{
|
||||
if (txtNewVal.Text != "")
|
||||
{
|
||||
// inserisco
|
||||
DtProxy.man.taAgent.insertQuery(txtNewVal.Text.Trim(), "-", "-", 0);
|
||||
// metto in campo ricerca...
|
||||
memLayer.ML.setSessionVal("valoreCercato", txtNewVal.Text.Trim());
|
||||
// svuoto campo text
|
||||
txtNewVal.Text = "";
|
||||
// riparto...
|
||||
Response.Redirect(user_std.pagCorrente);
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// verifica se i 2 vallori inseriti corrispondano
|
||||
/// </summary>
|
||||
/// <param name="val1"></param>
|
||||
/// <param name="val2"></param>
|
||||
/// <returns></returns>
|
||||
public bool checkValEq(object val1, object val2)
|
||||
{
|
||||
bool answ = false;
|
||||
try
|
||||
{
|
||||
if (val1.ToString() == val2.ToString()) answ = true;
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
return answ;
|
||||
}
|
||||
}
|
||||
}
|
||||
+60
@@ -0,0 +1,60 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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 C2P.WebUserControls {
|
||||
|
||||
|
||||
public partial class mod_AgentsMan {
|
||||
|
||||
/// <summary>
|
||||
/// lbtNew 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 lbtNew;
|
||||
|
||||
/// <summary>
|
||||
/// txtNewVal 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.TextBox txtNewVal;
|
||||
|
||||
/// <summary>
|
||||
/// grView 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.GridView grView;
|
||||
|
||||
/// <summary>
|
||||
/// lblNumRec 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.Label lblNumRec;
|
||||
|
||||
/// <summary>
|
||||
/// ods 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.ObjectDataSource ods;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,64 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_DiesGroupMan.ascx.cs" Inherits="C2P.WebUserControls.mod_DiesGroupMan" %>
|
||||
|
||||
<%@ Register Src="~/WebUserControls/mod_fileUploader.ascx" TagName="mod_fileUploader" TagPrefix="uc1" %>
|
||||
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-body">
|
||||
<div class="row">
|
||||
<div class="col-xs-8 col-xs-offset-2">
|
||||
<div runat="server" id="divHelp">
|
||||
<h3 style="text-align: center; margin: auto;"><%: traduci("HDiesGroupManTitle") %></h3>
|
||||
<div style="font-size: 1.2em; text-align: center; margin: auto;">
|
||||
<%: traduci("HDiesGroupManRepBody") %>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel-body" style="min-height: 213px;">
|
||||
<div class="row">
|
||||
<div class="col-xs-6">
|
||||
<div runat="server" id="divAnalisys">
|
||||
<h3><%: traduci("StepA") %></h3>
|
||||
<div class="panel panel-info" style="min-height: 180px;">
|
||||
<div class="panel-heading">
|
||||
<h4 style="margin-top: -4px; margin-bottom: -4px;"><%: traduci("HDiesGroupManStepA") %></h4>
|
||||
</div>
|
||||
<div class="panel-body bg-info" style="padding-top: 20px; padding-bottom: 20px;">
|
||||
<div class="col-xs-12 text-center">
|
||||
<asp:HyperLink runat="server" ID="HyperLink2" class="btn btn-success btn-lg" NavigateUrl="~/CsvExcelExporter?table=DiesGroup">
|
||||
|
||||
<i class="fa fa-file-excel-o fa-3x"></i>
|
||||
<div style="margin-top:0.5em;">
|
||||
<%: traduci("DiesGroupFile") %>
|
||||
</div>
|
||||
</asp:HyperLink>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-xs-6">
|
||||
<div runat="server" id="div1">
|
||||
<h3><%: traduci("StepB") %></h3>
|
||||
<div class="panel panel-success" style="min-height: 180px;">
|
||||
<div class="panel-heading">
|
||||
<h4 style="margin-top: -4px; margin-bottom: -4px;"><%: traduci("HDiesGroupManStepB") %></h4>
|
||||
</div>
|
||||
<div class="panel-body bg-success" style="padding-top: 20px; padding-bottom: 20px; height: 148px;">
|
||||
<div class="col-xs-12 text-center">
|
||||
<uc1:mod_fileuploader id="mod_fileUploader1" runat="server" contTypeFilt="application/vnd.ms-excel" checkFileType="false" filename="DiesGroupRaw.csv" />
|
||||
<asp:Label runat="server" ID="lblOut"><%: traduci("WaitingForFile") %></asp:Label>
|
||||
<div class="row">
|
||||
<div class="col-xs-9">
|
||||
<asp:Label runat="server" ID="lblUploadDone" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,78 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using SteamWare;
|
||||
using C2P_Data;
|
||||
|
||||
namespace C2P.WebUserControls
|
||||
{
|
||||
public partial class mod_DiesGroupMan : System.Web.UI.UserControl
|
||||
{
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
mod_fileUploader1.eh_uploadDone += mod_fileUploader1_eh_uploadDone;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// file caricato
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
void mod_fileUploader1_eh_uploadDone(object sender, EventArgs e)
|
||||
{
|
||||
// caricato file su server, PROVA ad eseguire import tabella
|
||||
string fileName = "DiesGroupRaw";
|
||||
string importDataFolder = memLayer.ML.confReadString("importDataFolder");
|
||||
string archiveDataFolder = memLayer.ML.confReadString("archiveDataFolder");
|
||||
string uplDir = memLayer.ML.confReadString("uplDir");
|
||||
string archDir = memLayer.ML.confReadString("archDir");
|
||||
string FIELDTERMINATOR = memLayer.ML.confReadString("FIELDTERMINATOR");
|
||||
string ROWTERMINATOR = memLayer.ML.confReadString("ROWTERMINATOR");
|
||||
string FIRSTROW = memLayer.ML.confReadString("FIRSTROW");
|
||||
string CODEPAGE = memLayer.ML.confReadString("CODEPAGE");
|
||||
bool flgUpdate = memLayer.ML.confReadBool("flgUpdate");
|
||||
int numTicket = 0; // Convert.ToInt32(DateTime.Now.ToString("yyMMddHHmm"));
|
||||
|
||||
// calcolo nuova cartella archivio (anno/mese/gg_ora)
|
||||
DateTime adesso = DateTime.Now;
|
||||
archiveDataFolder = string.Format(@"{0}{1:yyyy}\{1:MM}\{1:dd}\{1:HHmmss}\", archiveDataFolder, adesso);
|
||||
archDir = string.Format(@"{0}{1:yyyy}\{1:MM}\{1:dd}\{1:HHmmss}\", archDir, adesso);
|
||||
// sposto i files da TEMP a cartella archive REMOTE
|
||||
fileMover.obj.muoviFile(importDataFolder, archiveDataFolder, "DiesGroupRaw.csv");
|
||||
// parto con la catena di esecuzione con cartella "relativa" al server...
|
||||
try
|
||||
{
|
||||
DtProxy.man.taDGD.import(fileName, archDir, "DiesGroupRaw.csv", FIELDTERMINATOR, ROWTERMINATOR, FIRSTROW, CODEPAGE, "errorDiesGroup.log", numTicket);
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
try
|
||||
{
|
||||
DtProxy.man.taDGD.convert(fileName, numTicket);
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
try
|
||||
{
|
||||
DtProxy.man.taDGD.merge(fileName, numTicket, flgUpdate);
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
lblUploadDone.Text = string.Format("Upload and Import done for {0}", fileName);
|
||||
logger.lg.scriviLog(lblUploadDone.Text, tipoLog.INFO);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// wrapper traduzione
|
||||
/// </summary>
|
||||
/// <param name="lemma"></param>
|
||||
/// <returns></returns>
|
||||
public string traduci(string lemma)
|
||||
{
|
||||
return user_std.UtSn.Traduci(lemma);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,78 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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 C2P.WebUserControls {
|
||||
|
||||
|
||||
public partial class mod_DiesGroupMan {
|
||||
|
||||
/// <summary>
|
||||
/// divHelp control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.HtmlControls.HtmlGenericControl divHelp;
|
||||
|
||||
/// <summary>
|
||||
/// divAnalisys control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.HtmlControls.HtmlGenericControl divAnalisys;
|
||||
|
||||
/// <summary>
|
||||
/// HyperLink2 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 HyperLink2;
|
||||
|
||||
/// <summary>
|
||||
/// div1 control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.HtmlControls.HtmlGenericControl div1;
|
||||
|
||||
/// <summary>
|
||||
/// mod_fileUploader1 control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::C2P.WebUserControls.mod_fileUploader mod_fileUploader1;
|
||||
|
||||
/// <summary>
|
||||
/// lblOut 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.Label lblOut;
|
||||
|
||||
/// <summary>
|
||||
/// lblUploadDone 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.Label lblUploadDone;
|
||||
}
|
||||
}
|
||||
@@ -51,17 +51,17 @@
|
||||
</div>
|
||||
<div class="row" style="min-height: 3.3em;">
|
||||
<div class="col-sm-12">
|
||||
<uc1:mod_autocomplete runat="server" ID="acClient" contextKey="c" minCharAutocomplete="2" showKey="false" ServicePath="../Services/WS_data.asmx/Clients" placeholder="Type to Search - Clients" labelRicercaTrad="acCliente" labelWidth="85px" />
|
||||
<uc1:mod_autocomplete runat="server" ID="acClient" contextKey="c" minCharAutocomplete="2" showKey="false" ServicePath='<%# serviceUrl("Clients") %>' placeholder="Type to Search - Clients" labelRicercaTrad="acCliente" labelWidth="85px" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row" style="min-height: 3.3em;">
|
||||
<div class="col-sm-12">
|
||||
<uc1:mod_autocomplete runat="server" ID="acMaterial" contextKey="l" minCharAutocomplete="2" showKey="false" ServicePath="../Services/WS_data.asmx/RawMat" placeholder="Type to Search - Alloy" labelRicercaTrad="acLega" labelWidth="85px" />
|
||||
<uc1:mod_autocomplete runat="server" ID="acMaterial" contextKey="l" minCharAutocomplete="2" showKey="false" ServicePath='<%# serviceUrl("RawMat") %>' placeholder="Type to Search - Alloy" labelRicercaTrad="acLega" labelWidth="85px" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row" style="min-height: 3.3em;">
|
||||
<div class="col-sm-12">
|
||||
<uc1:mod_autocomplete runat="server" ID="acItem" contextKey="a" minCharAutocomplete="2" showKey="false" ServicePath="../Services/WS_data.asmx/Items" placeholder="Type to Search - Items" labelRicercaTrad="acArticolo" labelWidth="85px" />
|
||||
<uc1:mod_autocomplete runat="server" ID="acItem" contextKey="a" minCharAutocomplete="2" showKey="false" ServicePath='<%# serviceUrl("Items") %>' placeholder="Type to Search - Items" labelRicercaTrad="acArticolo" labelWidth="85px" />
|
||||
</div>
|
||||
</div>
|
||||
<%--<div class="row" style="min-height: 3.3em;">
|
||||
@@ -137,7 +137,7 @@
|
||||
<asp:Label ID="Label8" runat="server" Text='<%# Bind("QuoteType") %>' />|</b><asp:Label ID="Label6" runat="server" Text='<%# Bind("CodQuote") %>' />.<span style="font-size: 0.8em;"><asp:Label ID="Label7" runat="server" Text='<%# Bind("QuoteRev") %>' /></span>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="QS" SortExpression="idxQState">
|
||||
<asp:TemplateField HeaderText="QS" SortExpression="idxQState" ItemStyle-Wrap="false">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label5" runat="server" Text='<%# traduci("ST" + Eval("idxQState")) %>'></asp:Label>
|
||||
/
|
||||
@@ -150,45 +150,26 @@
|
||||
<asp:BoundField DataField="BatchQty" HeaderText="Qty" SortExpression="BatchQty" ReadOnly="true" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N0}" HtmlEncode="false">
|
||||
<ItemStyle HorizontalAlign="Right"></ItemStyle>
|
||||
</asp:BoundField>
|
||||
<asp:TemplateField HeaderText="AlloyCost" SortExpression="RawMatFullCost" ItemStyle-HorizontalAlign="Right">
|
||||
<%--<HeaderTemplate>
|
||||
<asp:Label runat="server" ID="lblHeadRMFC" Text="RMFC" ToolTip="Raw Material Full Cost" />
|
||||
</HeaderTemplate>--%>
|
||||
<asp:TemplateField HeaderText="AlloyCost" SortExpression="RawMatFullCost" ItemStyle-HorizontalAlign="Right" ItemStyle-Wrap="false">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label1" runat="server" Text='<%# Eval("RawMatFullCost", "{0:C3}") %>' />
|
||||
</ItemTemplate>
|
||||
|
||||
<ItemStyle HorizontalAlign="Right"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
<%--<asp:TemplateField HeaderText="FullCost" SortExpression="FullCost" ItemStyle-HorizontalAlign="Right">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label2" runat="server" Text='<%# Eval("FullCost", "{0:C3}") %>' />
|
||||
</ItemTemplate>
|
||||
|
||||
<ItemStyle HorizontalAlign="Right"></ItemStyle>
|
||||
</asp:TemplateField>--%>
|
||||
<asp:TemplateField HeaderText="RockBott" SortExpression="MinPrice" ItemStyle-HorizontalAlign="Right">
|
||||
<%--<HeaderTemplate>
|
||||
<asp:Label runat="server" ID="lblHeadMP" Text="MP" ToolTip="Minimum Price" />
|
||||
</HeaderTemplate>--%>
|
||||
<asp:TemplateField HeaderText="RockBott" SortExpression="MinPrice" ItemStyle-HorizontalAlign="Right" ItemStyle-Wrap="false">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label3" runat="server" Text='<%# Eval("MinPrice", "{0:C3}") %>' Visible='<%# (Eval("QuoteType").ToString() == "Q") %>' />
|
||||
<asp:Label ID="Label9" runat="server" Text='<%# Eval("MinPrice_sim", "{0:C3}") %>' Visible='<%# (Eval("QuoteType").ToString() != "Q") %>' />
|
||||
</ItemTemplate>
|
||||
|
||||
<ItemStyle HorizontalAlign="Right"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Price" SortExpression="PriceOff" ItemStyle-HorizontalAlign="Right">
|
||||
<%--<HeaderTemplate>
|
||||
<asp:Label runat="server" ID="lblHeadPO" Text="PO" ToolTip="Price Offeres" />
|
||||
</HeaderTemplate>--%>
|
||||
<asp:TemplateField HeaderText="Price" SortExpression="PriceOff" ItemStyle-HorizontalAlign="Right" ItemStyle-Wrap="false">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label4" runat="server" Text='<%# Eval("PriceOff", "{0:C3}") %>' CssClass='<%# C2P_Data.utils.priceVsCost(Eval("QuoteType"),Eval("FullCost"),Eval("MinPrice"),Eval("MinPrice_sim"),Eval("PriceOff")) %>' />
|
||||
</ItemTemplate>
|
||||
<EditItemTemplate>
|
||||
<asp:TextBox ID="txtPriceOff" runat="server" Text='<%# Bind("PriceOff") %>' Width="5em" />
|
||||
</EditItemTemplate>
|
||||
|
||||
<ItemStyle HorizontalAlign="Right"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField ItemStyle-HorizontalAlign="Center">
|
||||
|
||||
@@ -12,6 +12,13 @@ namespace C2P.WebUserControls
|
||||
{
|
||||
public partial class mod_OffersArchive : System.Web.UI.UserControl
|
||||
{
|
||||
/// <summary>
|
||||
/// url base area services
|
||||
/// </summary>
|
||||
public string serviceUrl(string method)
|
||||
{
|
||||
return string.Format("/{0}/WS_data.asmx/{1}", memLayer.ML.confReadString("serviceUrl"), method);
|
||||
}
|
||||
/// <summary>
|
||||
/// richeista caricamento tabella (da filtro configurato)
|
||||
/// </summary>
|
||||
@@ -41,6 +48,9 @@ namespace C2P.WebUserControls
|
||||
}
|
||||
setBtnVisib();
|
||||
mod_selPeriodo1.eh_doUpdate += mod_selPeriodo1_eh_doUpdate;
|
||||
acClient.DataBind();
|
||||
acMaterial.DataBind();
|
||||
acItem.DataBind();
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1,71 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_PackageMan.ascx.cs" Inherits="C2P.WebUserControls.mod_PackageMan" %>
|
||||
<div class="row" style="font-size: 8pt;">
|
||||
<div class="col-sm-12">
|
||||
<asp:LinkButton ID="lbtNew" runat="server" OnClick="lbtNew_Click" CssClass="btn btn-success"><%: traduci("btnNewPackage") %></asp:LinkButton>
|
||||
<asp:TextBox ID="txtNewVal" runat="server" />
|
||||
</div>
|
||||
<div class="col-sm-12">
|
||||
<asp:GridView ID="grView" runat="server" AllowPaging="True" AllowSorting="True" AutoGenerateColumns="False" DataKeyNames="CodPackag" DataSourceID="ods" OnDataBound="grView_DataBound" CssClass="table table-striped table-bordered" OnRowEditing="grView_RowEditing">
|
||||
<Columns>
|
||||
<asp:TemplateField ShowHeader="False" ItemStyle-HorizontalAlign="Center" ItemStyle-Wrap="false">
|
||||
<EditItemTemplate>
|
||||
<asp:LinkButton runat="server" ID="lbUpdate" CausesValidation="true" CommandName="Update"><i class="fa fa-check fa-2x"></i></asp:LinkButton>
|
||||
<asp:LinkButton runat="server" ID="lbCancel" CausesValidation="false" CommandName="Cancel"><i class="fa fa-undo fa-2x"></i></asp:LinkButton>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton runat="server" ID="lbEdit" CausesValidation="false" CommandName="Edit" Visible='<%# Eval("CodPackag")!="" %>'><i class="fa fa-edit fa-2x"></i></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
|
||||
<ItemStyle HorizontalAlign="Center" Wrap="False"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="CodPackag" HeaderText="CodPackag" SortExpression="CodPackag" />
|
||||
<asp:TemplateField HeaderText="PackagDesc" SortExpression="PackagDesc">
|
||||
<EditItemTemplate>
|
||||
<asp:TextBox ID="txtPackagDesc" runat="server" Text='<%# Bind("PackagDesc") %>' Width="50em"></asp:TextBox>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lblPackagDesc" runat="server" Text='<%# Bind("PackagDesc") %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="RMCost" HeaderText="RMCost" SortExpression="RMCost" DataFormatString="{0:C4}" />
|
||||
<asp:BoundField DataField="RMWeight" HeaderText="RMWeight" SortExpression="RMWeight" DataFormatString="kg {0:N3}" />
|
||||
<asp:TemplateField ShowHeader="False" ItemStyle-HorizontalAlign="Center" ItemStyle-Wrap="false">
|
||||
<EditItemTemplate>
|
||||
<asp:LinkButton runat="server" ID="lbUpdate2" CausesValidation="true" CommandName="Update"><i class="fa fa-check fa-2x"></i></asp:LinkButton>
|
||||
<asp:LinkButton runat="server" ID="lbCancel2" CausesValidation="false" CommandName="Cancel"><i class="fa fa-undo fa-2x"></i></asp:LinkButton>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton runat="server" ID="lbDelete" CausesValidation="false" CommandName="Delete" OnClientClick='<%# SteamWare.jsUtils.getCBE("confermaDel") %>' Visible='<%# Eval("CodPackag")!="" %>'><i class="fa fa-trash-o fa-2x"></i></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
|
||||
<ItemStyle HorizontalAlign="Center" Wrap="False"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
<EmptyDataTemplate>
|
||||
<asp:Label runat="server" ID="lblNoRecord" Text='<%# traduci("noRecord") %>' />
|
||||
</EmptyDataTemplate>
|
||||
</asp:GridView>
|
||||
<asp:Label ID="lblNumRec" runat="server" CssClass="didascalia" />
|
||||
<asp:ObjectDataSource ID="ods" runat="server" SelectMethod="GetData" TypeName="C2P_Data.DS_QuotesTableAdapters.PackagDetTableAdapter" UpdateMethod="updateQuery" DeleteMethod="deleteQuery" OldValuesParameterFormatString="Original_{0}" FilterExpression="CodPackag LIKE '%{0}%' OR PackagDesc LIKE '%{0}%' " InsertMethod="insertQuery">
|
||||
<DeleteParameters>
|
||||
<asp:Parameter Name="Original_CodPackag" Type="String" />
|
||||
</DeleteParameters>
|
||||
<FilterParameters>
|
||||
<asp:SessionParameter DefaultValue="*" Name="ricerca" SessionField="valoreCercato" />
|
||||
</FilterParameters>
|
||||
<InsertParameters>
|
||||
<asp:Parameter Name="CodPackag" Type="String" />
|
||||
<asp:Parameter Name="PackagDesc" Type="String" />
|
||||
<asp:Parameter Name="RMCost" Type="Decimal" />
|
||||
<asp:Parameter Name="RMWeight" Type="Decimal" />
|
||||
</InsertParameters>
|
||||
<UpdateParameters>
|
||||
<asp:Parameter Name="CodPackag" Type="String" />
|
||||
<asp:Parameter Name="PackagDesc" Type="String" />
|
||||
<asp:Parameter Name="RMCost" Type="Decimal" />
|
||||
<asp:Parameter Name="RMWeight" Type="Decimal" />
|
||||
<asp:Parameter Name="Original_CodPackag" Type="String" />
|
||||
</UpdateParameters>
|
||||
</asp:ObjectDataSource>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,114 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using SteamWare;
|
||||
using C2P_Data;
|
||||
|
||||
namespace C2P.WebUserControls
|
||||
{
|
||||
public partial class mod_PackageMan : SteamWare.UserControl
|
||||
{
|
||||
/// <summary>
|
||||
/// caricamento pagina
|
||||
/// </summary>
|
||||
protected void Page_Load()
|
||||
{
|
||||
if (!Page.IsPostBack)
|
||||
{
|
||||
txtNewVal.Text = "";
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// inserisco nel db il nuovo lemma...
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void lbtNew_Click(object sender, EventArgs e)
|
||||
{
|
||||
creaNuovo();
|
||||
}
|
||||
/// <summary>
|
||||
/// dimensione pagina grid view
|
||||
/// </summary>
|
||||
public int pageSize
|
||||
{
|
||||
get
|
||||
{
|
||||
return grView.PageSize;
|
||||
}
|
||||
set
|
||||
{
|
||||
grView.PageSize = value;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// post bind grView
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void grView_DataBound(object sender, EventArgs e)
|
||||
{
|
||||
if (grView.Rows.Count > 0)
|
||||
{
|
||||
LinkButton lb;
|
||||
// aggiorno gli headers
|
||||
foreach (TableCell cella in grView.HeaderRow.Cells)
|
||||
{
|
||||
try
|
||||
{
|
||||
lb = (LinkButton)cella.Controls[0];
|
||||
lb.Text = traduci(lb.Text);
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
}
|
||||
int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1);
|
||||
lblNumRec.Text = string.Format("{0} ({1})", grView.Rows.Count, totRecord);
|
||||
}
|
||||
else
|
||||
{
|
||||
lblNumRec.Text = "";
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// editing riga
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void grView_RowEditing(object sender, GridViewEditEventArgs e)
|
||||
{
|
||||
// seleziono la riga corrente...
|
||||
grView.SelectedIndex = e.NewEditIndex;
|
||||
}
|
||||
/// <summary>
|
||||
/// resetta la selezione dei valori in caso di modifiche su altri controlli
|
||||
/// </summary>
|
||||
public void resetSelezione()
|
||||
{
|
||||
grView.SelectedIndex = -1;
|
||||
grView.DataBind();
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// creazione nuovo lemma
|
||||
/// </summary>
|
||||
private void creaNuovo()
|
||||
{
|
||||
if (txtNewVal.Text != "")
|
||||
{
|
||||
// inserisco
|
||||
DtProxy.man.taPD.insertQuery(txtNewVal.Text.Trim(), txtNewVal.Text.Trim(), 0, 1);
|
||||
// metto in campo ricerca...
|
||||
memLayer.ML.setSessionVal("valoreCercato", txtNewVal.Text.Trim());
|
||||
// svuoto campo text
|
||||
txtNewVal.Text = "";
|
||||
// riparto...
|
||||
Response.Redirect(user_std.pagCorrente);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
+60
@@ -0,0 +1,60 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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 C2P.WebUserControls {
|
||||
|
||||
|
||||
public partial class mod_PackageMan {
|
||||
|
||||
/// <summary>
|
||||
/// lbtNew 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 lbtNew;
|
||||
|
||||
/// <summary>
|
||||
/// txtNewVal 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.TextBox txtNewVal;
|
||||
|
||||
/// <summary>
|
||||
/// grView 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.GridView grView;
|
||||
|
||||
/// <summary>
|
||||
/// lblNumRec 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.Label lblNumRec;
|
||||
|
||||
/// <summary>
|
||||
/// ods 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.ObjectDataSource ods;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,68 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_PlantsMan.ascx.cs" Inherits="C2P.WebUserControls.mod_PlantsMan" %>
|
||||
<div class="row" style="font-size: 8pt;">
|
||||
<div class="col-sm-12">
|
||||
<asp:LinkButton ID="lbtNew" runat="server" OnClick="lbtNew_Click" CssClass="btn btn-success"><%: traduci("btnNewPlant") %></asp:LinkButton>
|
||||
<asp:TextBox ID="txtNewVal" runat="server" />
|
||||
</div>
|
||||
<div class="col-sm-12">
|
||||
<asp:GridView ID="grView" runat="server" AllowPaging="True" AllowSorting="True" AutoGenerateColumns="False" DataKeyNames="CodPlant" DataSourceID="ods" OnDataBound="grView_DataBound" CssClass="table table-striped table-bordered" OnRowEditing="grView_RowEditing">
|
||||
<Columns>
|
||||
<asp:TemplateField ShowHeader="False" ItemStyle-HorizontalAlign="Center" ItemStyle-Wrap="false">
|
||||
<EditItemTemplate>
|
||||
<asp:LinkButton runat="server" ID="lbUpdate" CausesValidation="true" CommandName="Update"><i class="fa fa-check fa-2x"></i></asp:LinkButton>
|
||||
<asp:LinkButton runat="server" ID="lbCancel" CausesValidation="false" CommandName="Cancel"><i class="fa fa-undo fa-2x"></i></asp:LinkButton>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton runat="server" ID="lbEdit" CausesValidation="false" CommandName="Edit" Visible='<%# Eval("CodPlant")!="" %>'><i class="fa fa-edit fa-2x"></i></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
|
||||
<ItemStyle HorizontalAlign="Center" Wrap="False"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="CodPlant" HeaderText="CodPlant" SortExpression="CodPlant" />
|
||||
<asp:BoundField DataField="Descript" HeaderText="Descript" SortExpression="Descript" />
|
||||
<asp:TemplateField HeaderText="Charge" SortExpression="Charge">
|
||||
<EditItemTemplate>
|
||||
<asp:TextBox ID="txtCharge" runat="server" Text='<%# Bind("Charge") %>'></asp:TextBox>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lblCharge" runat="server" Text='<%# Bind("Charge", "{0:P2}") %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField ShowHeader="False" ItemStyle-HorizontalAlign="Center" ItemStyle-Wrap="false">
|
||||
<EditItemTemplate>
|
||||
<asp:LinkButton runat="server" ID="lbUpdate2" CausesValidation="true" CommandName="Update"><i class="fa fa-check fa-2x"></i></asp:LinkButton>
|
||||
<asp:LinkButton runat="server" ID="lbCancel2" CausesValidation="false" CommandName="Cancel"><i class="fa fa-undo fa-2x"></i></asp:LinkButton>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton runat="server" ID="lbDelete" CausesValidation="false" CommandName="Delete" OnClientClick='<%# SteamWare.jsUtils.getCBE("confermaDel") %>' Visible='<%# Eval("CodPlant")!="" %>'><i class="fa fa-trash-o fa-2x"></i></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
|
||||
<ItemStyle HorizontalAlign="Center" Wrap="False"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
<EmptyDataTemplate>
|
||||
<asp:Label runat="server" ID="lblNoRecord" Text='<%# traduci("noRecord") %>' />
|
||||
</EmptyDataTemplate>
|
||||
</asp:GridView>
|
||||
<asp:Label ID="lblNumRec" runat="server" CssClass="didascalia" />
|
||||
<asp:ObjectDataSource ID="ods" runat="server" SelectMethod="GetData" TypeName="C2P_Data.DS_QuotesTableAdapters.PlantsDetTableAdapter" UpdateMethod="updateQuery" DeleteMethod="deleteQuery" OldValuesParameterFormatString="original_{0}" FilterExpression="CodPlant LIKE '%{0}%' OR Descript LIKE '%{0}%' " InsertMethod="insertQuery" OnUpdating="ods_Updating">
|
||||
<DeleteParameters>
|
||||
<asp:Parameter Name="Original_CodPlant" Type="String" />
|
||||
</DeleteParameters>
|
||||
<FilterParameters>
|
||||
<asp:SessionParameter DefaultValue="*" Name="ricerca" SessionField="valoreCercato" />
|
||||
</FilterParameters>
|
||||
<InsertParameters>
|
||||
<asp:Parameter Name="CodPlant" Type="String" />
|
||||
<asp:Parameter Name="Descript" Type="String" />
|
||||
<asp:Parameter Name="Charge" Type="Decimal" />
|
||||
</InsertParameters>
|
||||
<UpdateParameters>
|
||||
<asp:Parameter Name="CodPlant" Type="String" />
|
||||
<asp:Parameter Name="Descript" Type="String" />
|
||||
<asp:Parameter Name="Charge" Type="Decimal" />
|
||||
<asp:Parameter Name="Original_CodPlant" Type="String" />
|
||||
</UpdateParameters>
|
||||
</asp:ObjectDataSource>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,136 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using SteamWare;
|
||||
using C2P_Data;
|
||||
|
||||
namespace C2P.WebUserControls
|
||||
{
|
||||
public partial class mod_PlantsMan : SteamWare.UserControl
|
||||
{
|
||||
/// <summary>
|
||||
/// caricamento pagina
|
||||
/// </summary>
|
||||
protected void Page_Load()
|
||||
{
|
||||
if (!Page.IsPostBack)
|
||||
{
|
||||
txtNewVal.Text = "";
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// inserisco nel db il nuovo lemma...
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void lbtNew_Click(object sender, EventArgs e)
|
||||
{
|
||||
creaNuovo();
|
||||
}
|
||||
/// <summary>
|
||||
/// dimensione pagina grid view
|
||||
/// </summary>
|
||||
public int pageSize
|
||||
{
|
||||
get
|
||||
{
|
||||
return grView.PageSize;
|
||||
}
|
||||
set
|
||||
{
|
||||
grView.PageSize = value;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// post bind grView
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void grView_DataBound(object sender, EventArgs e)
|
||||
{
|
||||
if (grView.Rows.Count > 0)
|
||||
{
|
||||
LinkButton lb;
|
||||
// aggiorno gli headers
|
||||
foreach (TableCell cella in grView.HeaderRow.Cells)
|
||||
{
|
||||
try
|
||||
{
|
||||
lb = (LinkButton)cella.Controls[0];
|
||||
lb.Text = traduci(lb.Text);
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
}
|
||||
int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1);
|
||||
lblNumRec.Text = string.Format("{0} ({1})", grView.Rows.Count, totRecord);
|
||||
if (grView.EditIndex >= 0)
|
||||
{
|
||||
// imposto i valori "%" corretti
|
||||
try
|
||||
{
|
||||
// cerco i textBox...
|
||||
TextBox txtCharge = ((TextBox)((GridViewRow)grView.Rows[grView.EditIndex]).FindControl("txtCharge"));
|
||||
decimal Charge = percentuali.num2perc(txtCharge.Text);
|
||||
// ora modifico moltiplicando x 100...
|
||||
txtCharge.Text = string.Format("{0:N2}", Charge);
|
||||
}
|
||||
catch (Exception exc)
|
||||
{
|
||||
SteamWare.logger.lg.scriviLog(string.Format("{0}", exc), SteamWare.tipoLog.EXCEPTION);
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
lblNumRec.Text = "";
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// editing riga
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void grView_RowEditing(object sender, GridViewEditEventArgs e)
|
||||
{
|
||||
// seleziono la riga corrente...
|
||||
grView.SelectedIndex = e.NewEditIndex;
|
||||
|
||||
}
|
||||
/// <summary>
|
||||
/// resetta la selezione dei valori in caso di modifiche su altri controlli
|
||||
/// </summary>
|
||||
public void resetSelezione()
|
||||
{
|
||||
grView.SelectedIndex = -1;
|
||||
grView.DataBind();
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// creazione nuovo lemma
|
||||
/// </summary>
|
||||
private void creaNuovo()
|
||||
{
|
||||
if (txtNewVal.Text != "")
|
||||
{
|
||||
// inserisco
|
||||
DtProxy.man.taPlant.insertQuery(txtNewVal.Text.Trim(), txtNewVal.Text.Trim(), 0);
|
||||
// metto in campo ricerca...
|
||||
memLayer.ML.setSessionVal("valoreCercato", txtNewVal.Text.Trim());
|
||||
// svuoto campo text
|
||||
txtNewVal.Text = "";
|
||||
// riparto...
|
||||
Response.Redirect(user_std.pagCorrente);
|
||||
}
|
||||
}
|
||||
|
||||
protected void ods_Updating(object sender, ObjectDataSourceMethodEventArgs e)
|
||||
{
|
||||
e.InputParameters["Charge"] = percentuali.perc2num(e.InputParameters["Charge"].ToString());
|
||||
}
|
||||
}
|
||||
}
|
||||
+60
@@ -0,0 +1,60 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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 C2P.WebUserControls {
|
||||
|
||||
|
||||
public partial class mod_PlantsMan {
|
||||
|
||||
/// <summary>
|
||||
/// lbtNew 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 lbtNew;
|
||||
|
||||
/// <summary>
|
||||
/// txtNewVal 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.TextBox txtNewVal;
|
||||
|
||||
/// <summary>
|
||||
/// grView 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.GridView grView;
|
||||
|
||||
/// <summary>
|
||||
/// lblNumRec 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.Label lblNumRec;
|
||||
|
||||
/// <summary>
|
||||
/// ods 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.ObjectDataSource ods;
|
||||
}
|
||||
}
|
||||
@@ -155,6 +155,6 @@
|
||||
<asp:QueryStringParameter Name="QuoteType" QueryStringField="QuoteType" Type="String" />
|
||||
<asp:QueryStringParameter Name="CodQuote" QueryStringField="CodQuote" Type="Int64" />
|
||||
<asp:QueryStringParameter Name="QuoteRev" QueryStringField="QuoteRev" Type="Int32" />
|
||||
<asp:Parameter DefaultValue="Y" Name="DoUpdate" Type="String" />
|
||||
<asp:Parameter DefaultValue="N" Name="DoUpdate" Type="String" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using SteamWare;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
@@ -83,6 +84,11 @@ namespace C2P.WebUserControls
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void odsQuotes_Updated(object sender, ObjectDataSourceStatusEventArgs e)
|
||||
{
|
||||
raiseEvent();
|
||||
}
|
||||
|
||||
private void raiseEvent()
|
||||
{
|
||||
if (eh_update != null)
|
||||
{
|
||||
@@ -96,9 +102,10 @@ namespace C2P.WebUserControls
|
||||
{
|
||||
get
|
||||
{
|
||||
bool answ = SteamWare.user_std.UtSn.userHasRight("SuperUser");
|
||||
bool answ = devicesAuthProxy.stObj.userHasRight("SuperUser");
|
||||
return answ;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -74,6 +74,6 @@
|
||||
<asp:QueryStringParameter Name="QuoteType" QueryStringField="QuoteType" Type="String" />
|
||||
<asp:QueryStringParameter Name="CodQuote" QueryStringField="CodQuote" Type="Int64" />
|
||||
<asp:QueryStringParameter Name="QuoteRev" QueryStringField="QuoteRev" Type="Int32" />
|
||||
<asp:Parameter DefaultValue="Y" Name="DoUpdate" Type="String" />
|
||||
<asp:Parameter DefaultValue="N" Name="DoUpdate" Type="String" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
|
||||
@@ -44,5 +44,12 @@ namespace C2P.WebUserControls
|
||||
{ }
|
||||
return answ;
|
||||
}
|
||||
/// <summary>
|
||||
/// effettua update
|
||||
/// </summary>
|
||||
public void doUpdate()
|
||||
{
|
||||
frmView.DataBind();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -5,66 +5,66 @@
|
||||
<webopt:BundleReference ID="BundleReference2" runat="server" Path="~/Content/themes/base/css" />
|
||||
<%} %>
|
||||
<%@ Register Src="~/WebUserControls/mod_display.ascx" TagName="mod_display" TagPrefix="uc1" %>
|
||||
<%@ Register Src="mod_autocompleteShort.ascx" TagPrefix="uc1" TagName="mod_autocompleteShort" %>
|
||||
|
||||
<asp:FormView ID="frmView" runat="server" DataKeyNames="QuoteType,CodQuote,QuoteRev" DataSourceID="odsQuotes" Width="100%" OnModeChanged="frmView_ModeChanged">
|
||||
<ItemTemplate>
|
||||
<div class="row bottomLine">
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display1" runat="server" etichetta='<%# traduci("ProductCode") %>' valore='<%# Bind("CodItem") %>' />
|
||||
<div class="col-xs-3 text-left">
|
||||
<uc1:mod_display ID="mod_display1" runat="server" etichetta='<%# traduci("ProductCode") %>' valore='<%# Eval("CodItem") %>' />
|
||||
</div>
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display10" runat="server" etichetta='<%# traduci("CodItemGroup") %>' valore='<%# Bind("CodItemGroup") %>' />
|
||||
<uc1:mod_display ID="mod_display10" runat="server" etichetta='<%# traduci("CodItemGroup") %>' valore='<%# Eval("CodItemGroup") %>' />
|
||||
</div>
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display11" runat="server" etichetta='<%# traduci("UnitWeight") %>' valore='<%# Bind("UnitWeight","{0:N0}") %>' />
|
||||
<uc1:mod_display ID="mod_display11" runat="server" etichetta='<%# traduci("UnitWeight") %>' valore='<%# Eval("UnitWeight","{0:N0}") %>' />
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
<uc1:mod_display ID="mod_display2" runat="server" etichetta='<%# traduci("Customer") %>' toolTipVal='<%# Bind("CodClient") %>' valore='<%# Bind("ClientName") %>' />
|
||||
<div class="col-xs-5 text-right">
|
||||
<uc1:mod_display ID="mod_display2" runat="server" etichetta='<%# traduci("Customer") %>' toolTipVal='<%# Eval("CodClient") %>' valore='<%# Eval("ClientName") %>' />
|
||||
<uc1:mod_autocompleteShort runat="server" ID="acCliente" contextKey="c" minCharAutocomplete="2" showKey="false" ServicePath='<%# serviceUrl("Clients") %>' placeholder="Ricerca Cliente" valore='<%# Bind("CodClient") %>' selezione='<%# Eval("ClientName") %>' show="false" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row bottomLine">
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display3" runat="server" etichetta='<%# traduci("Alloy") %>' valore='<%# Bind("RawMat") %>' />
|
||||
<div class="col-xs-3 text-left">
|
||||
<uc1:mod_display ID="mod_display3" runat="server" etichetta='<%# traduci("Alloy") %>' valore='<%# Eval("RawMat") %>' />
|
||||
</div>
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display5" runat="server" etichetta='<%# traduci("Base6060") %>' valore='<%# Bind("RawMatCost","{0:C3}") %>' />
|
||||
<uc1:mod_display ID="mod_display5" runat="server" etichetta='<%# traduci("Base6060") %>' valore='<%# Eval("RawMatCost","{0:C3}") %>' />
|
||||
</div>
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display7" runat="server" etichetta='<%# traduci("ExtraAlloy") %>' valore='<%# Bind("RawMatExtraCost","{0:C3}") %>' />
|
||||
<uc1:mod_display ID="mod_display7" runat="server" etichetta='<%# traduci("ExtraAlloy") %>' valore='<%# Eval("RawMatExtraCost","{0:C3}") %>' />
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
<uc1:mod_display ID="mod_display4" runat="server" etichetta='<%# traduci("OrderBatch") %>' valore='<%# Bind("BatchQty") %>' />
|
||||
<div class="col-xs-5 text-right">
|
||||
<uc1:mod_display ID="mod_display4" runat="server" etichetta='<%# traduci("OrderBatch") %>' valore='<%# Eval("BatchQty") %>' />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row bottomLine">
|
||||
<div class="col-xs-6 text-left">
|
||||
<uc1:mod_display ID="mod_display6" runat="server" etichetta='<%# traduci("Incoterms") %>' valore='<%# Bind("CodInco") %>' />
|
||||
<uc1:mod_display ID="mod_display6" runat="server" etichetta='<%# traduci("Incoterms") %>' valore='<%# Eval("CodInco") %>' />
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
<uc1:mod_display ID="mod_display8" runat="server" etichetta='<%# traduci("Agency") %>' valore='<%# Bind("ProvvCost","{0:C3}") %>' />
|
||||
<uc1:mod_display ID="mod_display8" runat="server" etichetta='<%# traduci("Agency") %>' valore='<%# Eval("ProvvCost","{0:C4}") %>' />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-xs-9">
|
||||
<uc1:mod_display ID="mod_display9" runat="server" etichetta='<%# traduci("Note") %>' valore='<%# Bind("Note") %>' />
|
||||
<uc1:mod_display ID="mod_display9" runat="server" etichetta='<%# traduci("Note") %>' valore='<%# Eval("Note") %>' />
|
||||
</div>
|
||||
<div class="col-xs-1">
|
||||
<uc1:mod_display ID="mod_display13" runat="server" etichetta='<%# traduci("OfferResult") %>' valore='<%# Bind("OfferResult") %>' />
|
||||
<uc1:mod_display ID="mod_display13" runat="server" etichetta='<%# traduci("OfferResult") %>' valore='<%# Eval("OfferResult") %>' />
|
||||
</div>
|
||||
<div class="col-xs-1">
|
||||
<uc1:mod_display ID="mod_display14" runat="server" etichetta='<%# traduci("KoReason") %>' valore='<%# Bind("KoReason") %>' />
|
||||
<uc1:mod_display ID="mod_display14" runat="server" etichetta='<%# traduci("KoReason") %>' valore='<%# Eval("KoReason") %>' />
|
||||
</div>
|
||||
<div class="col-xs-1">
|
||||
<uc1:mod_display ID="mod_display15" runat="server" etichetta='<%# traduci("Agente") %>' valore='<%# Bind("Agente") %>' />
|
||||
<uc1:mod_display ID="mod_display15" runat="server" etichetta='<%# traduci("Agente") %>' valore='<%# Eval("Agente") %>' />
|
||||
</div>
|
||||
</div>
|
||||
</ItemTemplate>
|
||||
<EditItemTemplate>
|
||||
<div class="row bottomLine">
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display1" runat="server" etichetta='<%# traduci("ProductCode") %>' />
|
||||
<asp:DropDownList ID="DropDownList2" runat="server" DataSourceID="odsProducts" DataValueField="value" DataTextField="value" SelectedValue='<%# Bind("CodItem") %>' />
|
||||
<%--<asp:TextBox Font-Bold="true" ID="TextBox1" runat="server" Text='<%# Bind("CodItem") %>' />--%>
|
||||
<div class="col-xs-3 text-left">
|
||||
<uc1:mod_display ID="mod_display12" runat="server" etichetta='<%# traduci("ProductCode") %>' valore='<%# Bind("CodItem") %>' />
|
||||
</div>
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display10" runat="server" etichetta='<%# traduci("CodItemGroup") %>' valore='<%# Eval("CodItemGroup") %>' />
|
||||
@@ -72,46 +72,42 @@
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display11" runat="server" etichetta='<%# traduci("UnitWeight") %>' valore='<%# Eval("UnitWeight") %>' />
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
<div class="col-xs-5 text-right">
|
||||
<uc1:mod_display ID="mod_display2" runat="server" etichetta='<%# traduci("Customer") %>' />
|
||||
<asp:DropDownList ID="DropDownList3" runat="server" DataSourceID="odsCustomers" DataValueField="value" DataTextField="label" SelectedValue='<%# Bind("CodClient") %>' CssClass="text-right" />
|
||||
<%--<asp:TextBox Font-Bold="true" ID="TextBox2" runat="server" Text='<%# Bind("CodClient") %>' CssClass="text-right" />--%>
|
||||
<uc1:mod_autocompleteShort runat="server" ID="acCliente" contextKey="c" minCharAutocomplete="2" showKey="false" ServicePath='<%# serviceUrl("Clients") %>' placeholder="Ricerca Cliente" valore='<%# Bind("CodClient") %>' selezione='<%# Eval("ClientName") %>' show='<%# editEnabled %>' />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row bottomLine">
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display3" runat="server" etichetta='<%# traduci("Alloy") %>' />
|
||||
<asp:DropDownList ID="ddlRawMat" runat="server" DataSourceID="odsRawMat" DataValueField="value" DataTextField="label" SelectedValue='<%# Bind("RawMat") %>' OnSelectedIndexChanged="ddlRawMat_SelectedIndexChanged" AutoPostBack="true" />
|
||||
<%--<asp:TextBox Font-Bold="true" ID="TextBox3" runat="server" Text='<%# Bind("RawMat") %>' />--%>
|
||||
<div class="col-xs-3 text-left">
|
||||
<uc1:mod_display ID="mod_display16" runat="server" etichetta='<%# traduci("Alloy") %>' valore='<%# Bind("RawMat") %>' />
|
||||
</div>
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display5" runat="server" etichetta='<%# traduci("Base6060") %>' />
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox5" runat="server" Text='<%# Bind("RawMatCost","{0:N3}") %>' Width="10em" />
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox5" runat="server" Text='<%# Bind("RawMatCost","{0:N3}") %>' Width="10em" Enabled='<%# editEnabled %>' />
|
||||
</div>
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display7" runat="server" etichetta='<%# traduci("ExtraAlloy") %>' />
|
||||
<asp:TextBox Font-Bold="true" ID="txtRawMatExtraCost" runat="server" Text='<%# Bind("RawMatExtraCost","{0:N3}") %>' Width="10em" />
|
||||
<asp:TextBox Font-Bold="true" ID="txtRawMatExtraCost" runat="server" Text='<%# Bind("RawMatExtraCost","{0:N3}") %>' Width="10em" Enabled='<%# editEnabled %>' />
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
<div class="col-xs-5 text-right">
|
||||
<uc1:mod_display ID="mod_display4" runat="server" etichetta='<%# traduci("OrderBatch") %>' />
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox4" runat="server" Text='<%# Bind("BatchQty") %>' CssClass="text-right" Width="10em" />
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox4" runat="server" Text='<%# Bind("BatchQty") %>' CssClass="text-right" Width="10em" Enabled='<%# editEnabled %>' />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row bottomLine">
|
||||
<div class="col-xs-6 text-left">
|
||||
<uc1:mod_display ID="mod_display6" runat="server" etichetta='<%# traduci("Incoterms") %>' />
|
||||
<asp:DropDownList ID="DropDownList1" runat="server" DataSourceID="odsIncoterms" DataValueField="value" DataTextField="label" SelectedValue='<%# Bind("CodInco") %>' CssClass="text-right" Width="97.5%" />
|
||||
<%--<asp:TextBox Font-Bold="true" ID="TextBox6" runat="server" Text='<%# Bind("CodInco") %>' CssClass="text-right" />--%>
|
||||
<asp:DropDownList ID="DropDownList1" runat="server" DataSourceID="odsIncoterms" DataValueField="value" DataTextField="label" SelectedValue='<%# Bind("CodInco") %>' CssClass="text-right" Width="97.5%" Enabled='<%# editEnabled %>' />
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
<uc1:mod_display ID="mod_display8" runat="server" etichetta='<%# traduci("Agency") %>' />
|
||||
<asp:Label Font-Bold="true" ID="TextBox8" runat="server" Text='<%# Eval("ProvvCost","{0:N3}") %>' CssClass="text-right" />
|
||||
<asp:Label Font-Bold="true" ID="TextBox8" runat="server" Text='<%# Eval("ProvvCost","{0:N4}") %>' CssClass="text-right" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-xs-9">
|
||||
<uc1:mod_display ID="mod_display9" runat="server" etichetta='<%# traduci("Note") %>' />
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox1" runat="server" Text='<%# Bind("Note") %>' TextMode="MultiLine" Width="100%" Height="4em" />
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox1" runat="server" Text='<%# Bind("Note") %>' TextMode="MultiLine" Width="100%" Height="4em" Enabled='<%# editEnabled %>' />
|
||||
</div>
|
||||
<div class="col-xs-1">
|
||||
<uc1:mod_display ID="mod_display13" runat="server" etichetta='<%# traduci("OfferResult") %>' />
|
||||
@@ -123,7 +119,7 @@
|
||||
</div>
|
||||
<div class="col-xs-1">
|
||||
<uc1:mod_display ID="mod_display15" runat="server" etichetta='<%# traduci("Agente") %>' />
|
||||
<asp:DropDownList ID="DropDownList6" runat="server" DataSourceID="odsAgente" DataValueField="value" DataTextField="label" SelectedValue='<%# Bind("Agente") %>' CssClass="text-right" Width="97.5%" Font-Size="0.8em" />
|
||||
<asp:DropDownList ID="DropDownList6" runat="server" DataSourceID="odsAgente" DataValueField="value" DataTextField="label" Enabled='<%# editEnabled %>' SelectedValue='<%# Bind("Agente") %>' CssClass="text-right" Width="97.5%" Font-Size="0.8em" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
@@ -145,21 +141,16 @@
|
||||
<InsertItemTemplate>
|
||||
<div class="row bottomLine">
|
||||
<div class="col-xs-6 text-left">
|
||||
<uc1:mod_display ID="mod_display1" runat="server" etichetta='<%# traduci("ProductCode") %>' />
|
||||
<asp:DropDownList ID="ddlProducts" runat="server" DataSourceID="odsProducts" DataValueField="value" DataTextField="value" SelectedValue='<%# Bind("CodItem") %>' OnDataBound="ddlProducts_DataBound" />
|
||||
<%--<asp:TextBox Font-Bold="true" ID="TextBox1" runat="server" Text='<%# Bind("CodItem") %>' />--%>
|
||||
<uc1:mod_display ID="mod_display1" runat="server" etichetta='<%# traduci("ProductCode") %>' valore='<%# Request.QueryString["CodItem"] %>' />
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
<uc1:mod_display ID="mod_display2" runat="server" etichetta='<%# traduci("Customer") %>' />
|
||||
<asp:DropDownList ID="DropDownList3" runat="server" DataSourceID="odsCustomers" DataValueField="value" DataTextField="label" SelectedValue='<%# Bind("CodClient") %>' CssClass="text-right" />
|
||||
<%--<asp:TextBox Font-Bold="true" ID="TextBox2" runat="server" Text='<%# Bind("CodClient") %>' CssClass="text-right" />--%>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row bottomLine">
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display3" runat="server" etichetta='<%# traduci("Alloy") %>' />
|
||||
<asp:DropDownList ID="ddlRawMat" runat="server" DataSourceID="odsRawMat" DataValueField="value" DataTextField="label" SelectedValue='<%# Bind("RawMat") %>' OnDataBound="ddlRawMat_DataBound" OnSelectedIndexChanged="ddlRawMat_SelectedIndexChanged" AutoPostBack="true" />
|
||||
<%--<asp:TextBox Font-Bold="true" ID="TextBox3" runat="server" Text='<%# Bind("RawMat") %>' />--%>
|
||||
<div class="col-xs-3 text-left">
|
||||
<uc1:mod_display ID="mod_display3" runat="server" etichetta='<%# traduci("Alloy") %>' valore='<%# Request.QueryString["RawMat"] %>' />
|
||||
</div>
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display5" runat="server" etichetta='<%# traduci("Base6060") %>' />
|
||||
@@ -172,7 +163,7 @@
|
||||
<asp:TextBox Font-Bold="true" ID="txtRawMatExtraCost" runat="server" Text='<%# Bind("RawMatExtraCost","{0:N3}") %>' OnDataBinding="txtRawMatExtraCost_DataBinding" />
|
||||
<asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ErrorMessage='<%# traduci("ErrExtraAlloy") %>' CssClass="text-danger" ControlToValidate="txtRawMatExtraCost" Display="Dynamic" />
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
<div class="col-xs-5 text-right">
|
||||
<uc1:mod_display ID="mod_display4" runat="server" etichetta='<%# traduci("OrderBatch") %>' />
|
||||
<asp:TextBox Font-Bold="true" ID="txtBatchQty" runat="server" Text='<%# Bind("BatchQty") %>' CssClass="text-right" />
|
||||
<asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ErrorMessage='<%# traduci("ErrBatchQty") %>' CssClass="text-danger" ControlToValidate="txtBatchQty" Display="Dynamic" />
|
||||
@@ -186,7 +177,7 @@
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
<uc1:mod_display ID="mod_display8" runat="server" etichetta='<%# traduci("Agency") %>' />
|
||||
<asp:Label Font-Bold="true" ID="TextBox8" runat="server" Text='<%# Eval("ProvvCost","{0:N3}") %>' CssClass="text-right" />
|
||||
<asp:Label Font-Bold="true" ID="TextBox8" runat="server" Text='<%# Eval("ProvvCost","{0:N4}") %>' CssClass="text-right" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
@@ -217,6 +208,7 @@
|
||||
<asp:Parameter Name="QuoteType" Type="String" DefaultValue="Q" />
|
||||
<asp:Parameter Name="CodClient" Type="String" />
|
||||
<asp:Parameter Name="CodItem" Type="String" />
|
||||
<asp:Parameter Name="CodItemGroup" Type="String" DefaultValue="" />
|
||||
<asp:Parameter Name="RawMat" Type="String" />
|
||||
<asp:Parameter Name="RawMatCost" Type="Decimal" />
|
||||
<asp:Parameter Name="RawMatExtraCost" Type="Decimal" />
|
||||
@@ -228,7 +220,7 @@
|
||||
<asp:QueryStringParameter Name="QuoteType" QueryStringField="QuoteType" Type="String" />
|
||||
<asp:QueryStringParameter Name="CodQuote" QueryStringField="CodQuote" Type="Int64" />
|
||||
<asp:QueryStringParameter Name="QuoteRev" QueryStringField="QuoteRev" Type="Int32" />
|
||||
<asp:Parameter DefaultValue="Y" Name="DoUpdate" Type="String" />
|
||||
<asp:Parameter DefaultValue="N" Name="DoUpdate" Type="String" />
|
||||
</SelectParameters>
|
||||
<UpdateParameters>
|
||||
<asp:Parameter Name="Original_QuoteType" Type="String" />
|
||||
@@ -264,11 +256,7 @@
|
||||
<asp:Parameter DefaultValue="KoReason" Name="FieldName" Type="String" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<asp:ObjectDataSource ID="odsAgente" runat="server" OldValuesParameterFormatString="original_{0}" SelectMethod="getByTableField" TypeName="C2P_Data.DS_UtilityTableAdapters.v_selListValTableAdapter">
|
||||
<SelectParameters>
|
||||
<asp:Parameter DefaultValue="QuoteList" Name="TableName" Type="String" />
|
||||
<asp:Parameter DefaultValue="Agente" Name="FieldName" Type="String" />
|
||||
</SelectParameters>
|
||||
<asp:ObjectDataSource ID="odsAgente" runat="server" OldValuesParameterFormatString="original_{0}" SelectMethod="GetData" TypeName="C2P_Data.DS_UtilityTableAdapters.v_selAgentsTableAdapter">
|
||||
</asp:ObjectDataSource>
|
||||
<asp:Label runat="server" ID="Label1" CssClass="text-danger" Visible="false" />
|
||||
|
||||
|
||||
@@ -12,6 +12,13 @@ namespace C2P.WebUserControls
|
||||
{
|
||||
public partial class mod_Q_Header : SteamWare.UserControl
|
||||
{
|
||||
/// <summary>
|
||||
/// url base area services
|
||||
/// </summary>
|
||||
public string serviceUrl(string method)
|
||||
{
|
||||
return string.Format("/{0}/WS_data.asmx/{1}", memLayer.ML.confReadString("serviceUrl"), method);
|
||||
}
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
@@ -75,8 +82,8 @@ namespace C2P.WebUserControls
|
||||
//...leggo i valori!
|
||||
string QuoteType = e.InputParameters["QuoteType"].ToString();
|
||||
string CodClient = e.InputParameters["CodClient"].ToString();
|
||||
string CodItem = e.InputParameters["CodItem"].ToString();
|
||||
string RawMat = e.InputParameters["RawMat"].ToString();
|
||||
//string CodItem = e.InputParameters["CodItem"].ToString();
|
||||
//string RawMat = e.InputParameters["RawMat"].ToString();
|
||||
decimal RawMatCost = Convert.ToDecimal(e.InputParameters["RawMatCost"], cultura);
|
||||
decimal RawMatExtraCost = Convert.ToDecimal(e.InputParameters["RawMatExtraCost"], cultura);
|
||||
int BatchQty = Convert.ToInt32(e.InputParameters["BatchQty"], cultura);
|
||||
@@ -97,7 +104,7 @@ namespace C2P.WebUserControls
|
||||
try
|
||||
{
|
||||
// chiamo update e vedo risultati (se ultimo record è cambiato rispetto a prima...)
|
||||
rigaPost = DtProxy.man.taQFQ.insertNew(QuoteType, CodClient, CodItem, RawMat, RawMatCost, RawMatExtraCost, BatchQty, CodInco, Note, user_std.UtSn.utente)[0];
|
||||
rigaPost = DtProxy.man.taQFQ.insertNew(QuoteType, CodClient, CodItem, "", RawMat, RawMatCost, RawMatExtraCost, BatchQty, CodInco, Note, user_std.UtSn.utente)[0];
|
||||
if (rigaPost != null)
|
||||
{
|
||||
// verifico SE E' CAMBIATO mando a pagina edit...
|
||||
@@ -162,24 +169,6 @@ namespace C2P.WebUserControls
|
||||
return answ;
|
||||
}
|
||||
}
|
||||
|
||||
protected void ddlProducts_DataBound(object sender, EventArgs e)
|
||||
{
|
||||
DropDownList lista = ((DropDownList)sender);
|
||||
if (lista.Items.FindByValue(CodItem) != null)
|
||||
{
|
||||
lista.SelectedIndex = lista.Items.IndexOf(lista.Items.FindByValue(CodItem));
|
||||
}
|
||||
}
|
||||
|
||||
protected void ddlRawMat_DataBound(object sender, EventArgs e)
|
||||
{
|
||||
DropDownList lista = ((DropDownList)sender);
|
||||
if (lista.Items.FindByValue(RawMat) != null)
|
||||
{
|
||||
lista.SelectedIndex = lista.Items.IndexOf(lista.Items.FindByValue(RawMat));
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// controllo se inviare evento refresh al cambio di modo della formview
|
||||
/// </summary>
|
||||
@@ -203,11 +192,6 @@ namespace C2P.WebUserControls
|
||||
txtRMEC.Text = DtProxy.man.taRMD.getByKey(RawMat)[0].ExtraMatCost.ToString();
|
||||
}
|
||||
|
||||
protected void ddlRawMat_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
TextBox txtRMEC = (TextBox)frmView.FindControl("txtRawMatExtraCost");
|
||||
txtRMEC.Text = DtProxy.man.taRMD.getByKey(((DropDownList)sender).SelectedValue)[0].ExtraMatCost.ToString();
|
||||
}
|
||||
|
||||
protected void odsQuotes_Updating(object sender, ObjectDataSourceMethodEventArgs e)
|
||||
{
|
||||
@@ -216,6 +200,32 @@ namespace C2P.WebUserControls
|
||||
{
|
||||
e.InputParameters["KoReason"] = "NA";
|
||||
}
|
||||
// 2015.05.26 check note NON empty...
|
||||
// se note vuoto metto "-"
|
||||
if (e.InputParameters["Note"] == null || e.InputParameters["Note"].ToString()=="")
|
||||
{
|
||||
e.InputParameters["Note"] = "-";
|
||||
}
|
||||
// 2015.05.29 agente a '' se null
|
||||
if (e.InputParameters["Agente"] == null)
|
||||
{
|
||||
e.InputParameters["Agente"] = "";
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// stato offerta...
|
||||
/// </summary>
|
||||
public int IdxQS { get; set; }
|
||||
/// <summary>
|
||||
/// determina editabilità da stato offerto (es esito offerta modificabile sempre il resto solo se NON approvata: < 2)
|
||||
/// </summary>
|
||||
public bool editEnabled
|
||||
{
|
||||
get
|
||||
{
|
||||
return IdxQS < 2;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -54,6 +54,6 @@
|
||||
<asp:QueryStringParameter Name="QuoteType" QueryStringField="QuoteType" Type="String" />
|
||||
<asp:QueryStringParameter Name="CodQuote" QueryStringField="CodQuote" Type="Int64" />
|
||||
<asp:QueryStringParameter Name="QuoteRev" QueryStringField="QuoteRev" Type="Int32" />
|
||||
<asp:Parameter DefaultValue="Y" Name="DoUpdate" Type="String" />
|
||||
<asp:Parameter DefaultValue="N" Name="DoUpdate" Type="String" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
|
||||
@@ -29,5 +29,12 @@ namespace C2P.WebUserControls
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// effettua update
|
||||
/// </summary>
|
||||
public void doUpdate()
|
||||
{
|
||||
frmView.DataBind();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -71,13 +71,9 @@
|
||||
</div>
|
||||
<div class="row bottomLine bg-info" style="font-size: 1.2em; line-height: 1.4em;">
|
||||
<div class="col-xs-6">
|
||||
<div class="row">
|
||||
<div class="col-xs-6 text-left">
|
||||
<uc1:mod_displayHor ID="mod_displayHor8" runat="server" etichetta='<%# traduci("PriceOff") %>' />
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox5" runat="server" Text='<%# Bind("PriceOff","{0:N3}") %>' Width="5em" />
|
||||
</div>
|
||||
<uc1:mod_displayHor ID="mod_displayHor8" runat="server" etichetta='<%# traduci("PriceOff") %>' />
|
||||
<div class="text-right" style="padding-right: 30px;">
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox5" runat="server" Text='<%# Bind("PriceOff","{0:N3}") %>' Width="5em" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
@@ -122,7 +118,7 @@
|
||||
<asp:QueryStringParameter Name="QuoteType" QueryStringField="QuoteType" Type="String" />
|
||||
<asp:QueryStringParameter Name="CodQuote" QueryStringField="CodQuote" Type="Int64" />
|
||||
<asp:QueryStringParameter Name="QuoteRev" QueryStringField="QuoteRev" Type="Int32" />
|
||||
<asp:Parameter DefaultValue="Y" Name="DoUpdate" Type="String" />
|
||||
<asp:Parameter DefaultValue="N" Name="DoUpdate" Type="String" />
|
||||
</SelectParameters>
|
||||
<UpdateParameters>
|
||||
<asp:Parameter Name="Original_QuoteType" Type="String" />
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using SteamWare;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
@@ -39,6 +40,11 @@ namespace C2P.WebUserControls
|
||||
}
|
||||
}
|
||||
protected void odsQuotes_Updated(object sender, ObjectDataSourceStatusEventArgs e)
|
||||
{
|
||||
raiseEvent();
|
||||
}
|
||||
|
||||
private void raiseEvent()
|
||||
{
|
||||
if (eh_update != null)
|
||||
{
|
||||
@@ -54,10 +60,7 @@ namespace C2P.WebUserControls
|
||||
{
|
||||
if (frmView.CurrentMode == FormViewMode.ReadOnly)
|
||||
{
|
||||
if (eh_update != null)
|
||||
{
|
||||
eh_update(this, new EventArgs());
|
||||
}
|
||||
raiseEvent();
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
@@ -74,7 +77,18 @@ namespace C2P.WebUserControls
|
||||
{
|
||||
get
|
||||
{
|
||||
bool answ = SteamWare.user_std.UtSn.userHasRight("SuperUser");
|
||||
bool answ = devicesAuthProxy.stObj.userHasRight("SuperAdmin") || devicesAuthProxy.stObj.userHasRight("Admin");
|
||||
return answ;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// verifica se utente sia admin altrimenti non vede dati...
|
||||
/// </summary>
|
||||
public bool userIsSuper
|
||||
{
|
||||
get
|
||||
{
|
||||
bool answ = devicesAuthProxy.stObj.userHasRight("SuperUser");
|
||||
return answ;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -37,22 +37,21 @@
|
||||
<!--style="min-height: 282px;">-->
|
||||
<div class="col-xs-10">
|
||||
<div class="panel panel-default">
|
||||
<%--<div class="panel-heading">--%>
|
||||
<div class="btn-group btn-group-justified">
|
||||
<div class="btn-group">
|
||||
<asp:LinkButton runat="server" ID="lbHeader" class="btn btn-default" OnClick="lbt_Click" CommandArgument="Header"><i class="fa fa-tasks"></i> <%: traduci("HEADER") %></asp:LinkButton>
|
||||
</div>
|
||||
<div class="btn-group">
|
||||
<asp:LinkButton runat="server" ID="lbCosts" class="btn btn-default" OnClick="lbt_Click" CommandArgument="Costs"><i class="fa fa-tasks"></i> <%: traduci("COSTS") %></asp:LinkButton>
|
||||
</div>
|
||||
<div class="btn-group">
|
||||
<asp:LinkButton runat="server" ID="lbExtrPar" class="btn btn-default" OnClick="lbt_Click" CommandArgument="ExtrPar"><i class="fa fa-tasks"></i> <%: traduci("EXTRUS-PARAM") %></asp:LinkButton>
|
||||
</div>
|
||||
<div class="btn-group">
|
||||
<asp:LinkButton runat="server" ID="lbPackPar" class="btn btn-default" OnClick="lbt_Click" CommandArgument="PackPar"><i class="fa fa-tasks"></i> <%: traduci("PACK-PARAM") %></asp:LinkButton>
|
||||
</div>
|
||||
<div class="btn-group">
|
||||
<asp:LinkButton runat="server" ID="lbCosts" class="btn btn-default" OnClick="lbt_Click" CommandArgument="Costs"><i class="fa fa-tasks"></i> <%: traduci("COSTS") %></asp:LinkButton>
|
||||
</div>
|
||||
</div>
|
||||
<%--</div>--%><div class="panel-body">
|
||||
<div class="panel-body">
|
||||
<uc1:mod_Q_Costs ID="mod_Q_Costs1" runat="server" />
|
||||
<uc2:mod_Q_ExtrPar ID="mod_Q_ExtrPar1" runat="server" />
|
||||
<uc3:mod_Q_Header ID="mod_Q_Header1" runat="server" />
|
||||
|
||||
@@ -151,10 +151,27 @@ namespace C2P.WebUserControls
|
||||
prevReq = "";
|
||||
editActive = false;
|
||||
setModVisibility("Header");
|
||||
setBtnVisibility();
|
||||
}
|
||||
mod_Q_Header1.eh_update += mod_Q_Header1_eh_update;
|
||||
mod_Q_Quot1.eh_update += mod_Q_Quot1_eh_update;
|
||||
mod_Q_Costs1.eh_update += mod_Q_Costs1_eh_update;
|
||||
// fix visibilità costi x user base...
|
||||
lbCosts.Visible = userIsSuper;
|
||||
}
|
||||
/// <summary>
|
||||
/// stato scheda attuale
|
||||
/// </summary>
|
||||
protected int IdxQS
|
||||
{
|
||||
get
|
||||
{
|
||||
return memLayer.ML.IntSessionObj(string.Format("idxQS_{0}", uid));
|
||||
}
|
||||
set
|
||||
{
|
||||
memLayer.ML.setSessionVal(string.Format("idxQS_{0}", uid), value);
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// update costo offerto
|
||||
@@ -177,7 +194,7 @@ namespace C2P.WebUserControls
|
||||
CodQuote = Request.QueryString["CodQuote"];
|
||||
QuoteRev = Request.QueryString["QuoteRev"];
|
||||
// carico stato offerta...
|
||||
int IdxQS = 0;
|
||||
IdxQS = 0;
|
||||
string CodItem = "";
|
||||
try
|
||||
{
|
||||
@@ -191,6 +208,10 @@ namespace C2P.WebUserControls
|
||||
Status = traduci(string.Format("IdxQState-{0:D2}", IdxQS));
|
||||
setBtnVisibility();
|
||||
mod_Q_Quot1.doUpdate();
|
||||
//2015.05.26 update altri moduli!
|
||||
mod_Q_Costs1.doUpdate();
|
||||
mod_Q_ExtrPar1.doUpdate();
|
||||
mod_Q_PackPar1.doUpdate();
|
||||
// fix articolo x visualizzazione...
|
||||
mod_imgPreview.CodItem = CodItem;
|
||||
}
|
||||
@@ -203,6 +224,7 @@ namespace C2P.WebUserControls
|
||||
{
|
||||
updateBaseData();
|
||||
setModVisibility("");
|
||||
setBtnVisibility();
|
||||
}
|
||||
/// <summary>
|
||||
/// richiesto update x cambiamento valori costs
|
||||
@@ -213,6 +235,7 @@ namespace C2P.WebUserControls
|
||||
{
|
||||
updateBaseData();
|
||||
setModVisibility("");
|
||||
setBtnVisibility();
|
||||
}
|
||||
/// <summary>
|
||||
/// premuto uno dei buttons dell'header
|
||||
@@ -263,7 +286,9 @@ namespace C2P.WebUserControls
|
||||
mod_Q_PackPar1.Visible = false;
|
||||
break;
|
||||
case "Header":
|
||||
// 2015.05.27 sempre editabile ma passo QS x determinare COSA (se stato >2 solo esito...)
|
||||
if (prevReq == req) mod_Q_Header1.toggleMode();
|
||||
mod_Q_Header1.IdxQS = IdxQS;
|
||||
mod_Q_Costs1.Visible = false;
|
||||
mod_Q_ExtrPar1.Visible = false;
|
||||
mod_Q_Header1.Visible = true;
|
||||
@@ -276,7 +301,13 @@ namespace C2P.WebUserControls
|
||||
mod_Q_PackPar1.Visible = true;
|
||||
break;
|
||||
case "Quote":
|
||||
if (prevReq == req) mod_Q_Quot1.toggleMode();
|
||||
// SOLO se stato <= approvato(2)...
|
||||
if (IdxQS < 2)
|
||||
{
|
||||
// 2015.06.11 sempre attivo il toggle NON faccio check che sia già stato richiesto...
|
||||
//if (prevReq == req) mod_Q_Quot1.toggleMode();
|
||||
mod_Q_Quot1.toggleMode();
|
||||
}
|
||||
break;
|
||||
default:
|
||||
mod_Q_Costs1.Visible = false;
|
||||
@@ -363,8 +394,23 @@ namespace C2P.WebUserControls
|
||||
divStato1.Visible = false;
|
||||
divStato2.Visible = false;
|
||||
// 2015.02.26 SOLO SE è in result = TBD
|
||||
bool condTbd = false;
|
||||
try
|
||||
{
|
||||
condTbd = OfferResult == "TBD"; // hard coded !!!
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
// 2015.05.26 SOLO SE è l'ULTIMA revisione...
|
||||
bool condIsLast = false;
|
||||
try
|
||||
{
|
||||
condIsLast = DtProxy.man.taCLQ.GetData(QuoteType, Convert.ToInt64(CodQuote))[0].lastRev == Convert.ToInt32(QuoteRev);
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
//divStato3.Visible = true;
|
||||
divStato3.Visible = OfferResult == "TBD"; // hard coded !!!
|
||||
divStato3.Visible = condTbd && condIsLast;
|
||||
btnGetPdf.Visible = true;
|
||||
break;
|
||||
default:
|
||||
@@ -501,5 +547,28 @@ namespace C2P.WebUserControls
|
||||
Response.Redirect(string.Format("Quote?QuoteType={0}&CodQuote={1}&QuoteRev={2}", tab[0].QuoteType, tab[0].CodQuote, tab[0].QuoteRev));
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// verifica se utente sia admin altrimenti non vede dati...
|
||||
/// </summary>
|
||||
public bool userIsAdmin
|
||||
{
|
||||
get
|
||||
{
|
||||
bool answ = devicesAuthProxy.stObj.userHasRight("SuperAdmin") || devicesAuthProxy.stObj.userHasRight("Admin");
|
||||
return answ;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// verifica se utente sia admin altrimenti non vede dati...
|
||||
/// </summary>
|
||||
public bool userIsSuper
|
||||
{
|
||||
get
|
||||
{
|
||||
bool answ = devicesAuthProxy.stObj.userHasRight("SuperUser");
|
||||
return answ;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
+9
-9
@@ -120,15 +120,6 @@ namespace C2P.WebUserControls {
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton lbHeader;
|
||||
|
||||
/// <summary>
|
||||
/// lbCosts 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 lbCosts;
|
||||
|
||||
/// <summary>
|
||||
/// lbExtrPar control.
|
||||
/// </summary>
|
||||
@@ -147,6 +138,15 @@ namespace C2P.WebUserControls {
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton lbPackPar;
|
||||
|
||||
/// <summary>
|
||||
/// lbCosts 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 lbCosts;
|
||||
|
||||
/// <summary>
|
||||
/// mod_Q_Costs1 control.
|
||||
/// </summary>
|
||||
|
||||
@@ -0,0 +1,105 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_RawMatMan.ascx.cs" Inherits="C2P.WebUserControls.mod_RawMatMan" %>
|
||||
<div class="row" style="font-size: 8pt;">
|
||||
<div class="col-sm-12">
|
||||
<asp:LinkButton ID="lbtNew" runat="server" OnClick="lbtNew_Click" CssClass="btn btn-success"><%: traduci("btnNewRawMat") %></asp:LinkButton>
|
||||
<asp:TextBox ID="txtNewVal" runat="server" />
|
||||
</div>
|
||||
<div class="col-sm-12">
|
||||
<asp:GridView ID="grView" runat="server" AllowPaging="True" AllowSorting="True" AutoGenerateColumns="False" DataKeyNames="RawMat" DataSourceID="ods" OnDataBound="grView_DataBound" CssClass="table table-striped table-bordered" OnRowEditing="grView_RowEditing">
|
||||
<Columns>
|
||||
<asp:TemplateField ShowHeader="False" ItemStyle-HorizontalAlign="Center" ItemStyle-Wrap="false">
|
||||
<EditItemTemplate>
|
||||
<asp:LinkButton runat="server" ID="lbUpdate" CausesValidation="true" CommandName="Update"><i class="fa fa-check fa-2x"></i></asp:LinkButton>
|
||||
<asp:LinkButton runat="server" ID="lbCancel" CausesValidation="false" CommandName="Cancel"><i class="fa fa-undo fa-2x"></i></asp:LinkButton>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton runat="server" ID="lbEdit" CausesValidation="false" CommandName="Edit" Visible='<%# Eval("RawMat")!="" %>'><i class="fa fa-edit fa-2x"></i></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
|
||||
<ItemStyle HorizontalAlign="Center" Wrap="False"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="RawMat" HeaderText="RawMat" ReadOnly="True" SortExpression="RawMat" />
|
||||
<asp:BoundField DataField="ProcCost" HeaderText="ProcCost" SortExpression="ProcCost" DataFormatString="{0:C4}" />
|
||||
<asp:TemplateField HeaderText="ProcYield" SortExpression="ProcYield">
|
||||
<EditItemTemplate>
|
||||
<asp:TextBox ID="txtProcYield" runat="server" Text='<%# Bind("ProcYield") %>'></asp:TextBox>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lblProcYield" runat="server" Text='<%# Bind("ProcYield", "{0:P2}") %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="CSR" SortExpression="CSR">
|
||||
<EditItemTemplate>
|
||||
<asp:TextBox ID="txtCSR" runat="server" Text='<%# Bind("CSR") %>'></asp:TextBox>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lblCSR" runat="server" Text='<%# Bind("CSR", "{0:P2}") %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="SSR" SortExpression="SSR">
|
||||
<EditItemTemplate>
|
||||
<asp:TextBox ID="txtSSR" runat="server" Text='<%# Bind("SSR") %>'></asp:TextBox>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lblSSR" runat="server" Text='<%# Bind("SSR", "{0:P2}") %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="SSVA" SortExpression="SSVA">
|
||||
<EditItemTemplate>
|
||||
<asp:TextBox ID="txtSSVA" runat="server" Text='<%# Bind("SSVA") %>'></asp:TextBox>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lblSSVA" runat="server" Text='<%# Bind("SSVA", "{0:C4}") %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="SSVR" SortExpression="SSVR">
|
||||
<EditItemTemplate>
|
||||
<asp:TextBox ID="txtSSVR" runat="server" Text='<%# Bind("SSVR") %>'></asp:TextBox>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lblSSVR" runat="server" Text='<%# Bind("SSVR", "{0:P2}") %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="ExtraMatCost" HeaderText="ExtraMatCost" SortExpression="ExtraMatCost" DataFormatString="{0:C4}" />
|
||||
<asp:BoundField DataField="ExtraServCost" HeaderText="ExtraServCost" SortExpression="ExtraServCost" DataFormatString="{0:C4}" />
|
||||
<asp:TemplateField ShowHeader="False" ItemStyle-HorizontalAlign="Center" ItemStyle-Wrap="false">
|
||||
<EditItemTemplate>
|
||||
<asp:LinkButton runat="server" ID="lbUpdate2" CausesValidation="true" CommandName="Update"><i class="fa fa-check fa-2x"></i></asp:LinkButton>
|
||||
<asp:LinkButton runat="server" ID="lbCancel2" CausesValidation="false" CommandName="Cancel"><i class="fa fa-undo fa-2x"></i></asp:LinkButton>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton runat="server" ID="lbDelete" CausesValidation="false" CommandName="Delete" OnClientClick='<%# SteamWare.jsUtils.getCBE("confermaDel") %>' Visible='<%# Eval("RawMat")!="" %>'><i class="fa fa-trash-o fa-2x"></i></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
|
||||
<ItemStyle HorizontalAlign="Center" Wrap="False"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
<EmptyDataTemplate>
|
||||
<asp:Label runat="server" ID="lblNoRecord" Text='<%# traduci("noRecord") %>' />
|
||||
</EmptyDataTemplate>
|
||||
</asp:GridView>
|
||||
<asp:Label ID="lblNumRec" runat="server" CssClass="didascalia" />
|
||||
<asp:ObjectDataSource ID="ods" runat="server" SelectMethod="GetData" TypeName="C2P_Data.DS_QuotesTableAdapters.RawMatDetTableAdapter" UpdateMethod="updateQuery" DeleteMethod="deleteQuery" OldValuesParameterFormatString="Original_{0}" FilterExpression="RawMat LIKE '%{0}%' " InsertMethod="insertQuery" OnUpdating="ods_Updating">
|
||||
<DeleteParameters>
|
||||
<asp:Parameter Name="Original_RawMat" Type="String" />
|
||||
</DeleteParameters>
|
||||
<FilterParameters>
|
||||
<asp:SessionParameter DefaultValue="*" Name="ricerca" SessionField="valoreCercato" />
|
||||
</FilterParameters>
|
||||
<InsertParameters>
|
||||
<asp:Parameter Name="RawMat" Type="String" />
|
||||
</InsertParameters>
|
||||
<UpdateParameters>
|
||||
<asp:Parameter Name="Original_RawMat" Type="String" />
|
||||
<asp:Parameter Name="ProcCost" Type="Decimal" />
|
||||
<asp:Parameter Name="ProcYield" Type="Decimal" />
|
||||
<asp:Parameter Name="CSR" Type="Decimal" />
|
||||
<asp:Parameter Name="SSR" Type="Decimal" />
|
||||
<asp:Parameter Name="SSVA" Type="Decimal" />
|
||||
<asp:Parameter Name="SSVR" Type="Decimal" />
|
||||
<asp:Parameter Name="ExtraMatCost" Type="Decimal" />
|
||||
<asp:Parameter Name="ExtraServCost" Type="Decimal" />
|
||||
</UpdateParameters>
|
||||
</asp:ObjectDataSource>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,147 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using SteamWare;
|
||||
using C2P_Data;
|
||||
|
||||
namespace C2P.WebUserControls
|
||||
{
|
||||
public partial class mod_RawMatMan : SteamWare.UserControl
|
||||
{
|
||||
/// <summary>
|
||||
/// caricamento pagina
|
||||
/// </summary>
|
||||
protected void Page_Load()
|
||||
{
|
||||
if (!Page.IsPostBack)
|
||||
{
|
||||
txtNewVal.Text = "";
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// inserisco nel db il nuovo lemma...
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void lbtNew_Click(object sender, EventArgs e)
|
||||
{
|
||||
creaNuovo();
|
||||
}
|
||||
/// <summary>
|
||||
/// dimensione pagina grid view
|
||||
/// </summary>
|
||||
public int pageSize
|
||||
{
|
||||
get
|
||||
{
|
||||
return grView.PageSize;
|
||||
}
|
||||
set
|
||||
{
|
||||
grView.PageSize = value;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// post bind grView
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void grView_DataBound(object sender, EventArgs e)
|
||||
{
|
||||
if (grView.Rows.Count > 0)
|
||||
{
|
||||
LinkButton lb;
|
||||
// aggiorno gli headers
|
||||
foreach (TableCell cella in grView.HeaderRow.Cells)
|
||||
{
|
||||
try
|
||||
{
|
||||
lb = (LinkButton)cella.Controls[0];
|
||||
lb.Text = traduci(lb.Text);
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
}
|
||||
int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1);
|
||||
lblNumRec.Text = string.Format("{0} ({1})", grView.Rows.Count, totRecord);
|
||||
if (grView.EditIndex >= 0)
|
||||
{
|
||||
// imposto i valori "%" corretti
|
||||
try
|
||||
{
|
||||
// cerco i textBox...
|
||||
TextBox txtProcYield = ((TextBox)((GridViewRow)grView.Rows[grView.EditIndex]).FindControl("txtProcYield"));
|
||||
TextBox txtCSR = ((TextBox)((GridViewRow)grView.Rows[grView.EditIndex]).FindControl("txtCSR"));
|
||||
TextBox txtSSR = ((TextBox)((GridViewRow)grView.Rows[grView.EditIndex]).FindControl("txtSSR"));
|
||||
TextBox txtSSVR = ((TextBox)((GridViewRow)grView.Rows[grView.EditIndex]).FindControl("txtSSVR"));
|
||||
// valori decimali
|
||||
decimal ProcYield = percentuali.num2perc(txtProcYield.Text);
|
||||
decimal CSR = percentuali.num2perc(txtCSR.Text);
|
||||
decimal SSR = percentuali.num2perc(txtSSR.Text);
|
||||
decimal SSVR = percentuali.num2perc(txtSSVR.Text);
|
||||
// ora modifico moltiplicando x 100...
|
||||
txtProcYield.Text = string.Format("{0:N2}", ProcYield);
|
||||
txtCSR.Text = string.Format("{0:N2}", CSR);
|
||||
txtSSR.Text = string.Format("{0:N2}", SSR);
|
||||
txtSSVR.Text = string.Format("{0:N2}", SSVR);
|
||||
}
|
||||
catch (Exception exc)
|
||||
{
|
||||
SteamWare.logger.lg.scriviLog(string.Format("{0}", exc), SteamWare.tipoLog.EXCEPTION);
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
lblNumRec.Text = "";
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// editing riga
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void grView_RowEditing(object sender, GridViewEditEventArgs e)
|
||||
{
|
||||
// seleziono la riga corrente...
|
||||
grView.SelectedIndex = e.NewEditIndex;
|
||||
}
|
||||
/// <summary>
|
||||
/// resetta la selezione dei valori in caso di modifiche su altri controlli
|
||||
/// </summary>
|
||||
public void resetSelezione()
|
||||
{
|
||||
grView.SelectedIndex = -1;
|
||||
grView.DataBind();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// creazione nuovo lemma
|
||||
/// </summary>
|
||||
private void creaNuovo()
|
||||
{
|
||||
if (txtNewVal.Text != "")
|
||||
{
|
||||
// inserisco
|
||||
DtProxy.man.taRMD.insertQuery(txtNewVal.Text.Trim());
|
||||
// metto in campo ricerca...
|
||||
memLayer.ML.setSessionVal("valoreCercato", txtNewVal.Text.Trim());
|
||||
// svuoto campo text
|
||||
txtNewVal.Text = "";
|
||||
// riparto...
|
||||
Response.Redirect(user_std.pagCorrente);
|
||||
}
|
||||
}
|
||||
|
||||
protected void ods_Updating(object sender, ObjectDataSourceMethodEventArgs e)
|
||||
{
|
||||
e.InputParameters["ProcYield"] = percentuali.perc2num(e.InputParameters["ProcYield"].ToString());
|
||||
e.InputParameters["CSR"] = percentuali.perc2num(e.InputParameters["CSR"].ToString());
|
||||
e.InputParameters["SSR"] = percentuali.perc2num(e.InputParameters["SSR"].ToString());
|
||||
e.InputParameters["SSVR"] = percentuali.perc2num(e.InputParameters["SSVR"].ToString());
|
||||
}
|
||||
}
|
||||
}
|
||||
+60
@@ -0,0 +1,60 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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 C2P.WebUserControls {
|
||||
|
||||
|
||||
public partial class mod_RawMatMan {
|
||||
|
||||
/// <summary>
|
||||
/// lbtNew 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 lbtNew;
|
||||
|
||||
/// <summary>
|
||||
/// txtNewVal 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.TextBox txtNewVal;
|
||||
|
||||
/// <summary>
|
||||
/// grView 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.GridView grView;
|
||||
|
||||
/// <summary>
|
||||
/// lblNumRec 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.Label lblNumRec;
|
||||
|
||||
/// <summary>
|
||||
/// ods 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.ObjectDataSource ods;
|
||||
}
|
||||
}
|
||||
@@ -113,7 +113,7 @@
|
||||
<asp:QueryStringParameter Name="QuoteType" QueryStringField="QuoteType" Type="String" />
|
||||
<asp:QueryStringParameter Name="CodQuote" QueryStringField="CodQuote" Type="Int64" />
|
||||
<asp:QueryStringParameter Name="QuoteRev" QueryStringField="QuoteRev" Type="Int32" />
|
||||
<asp:Parameter DefaultValue="Y" Name="DoUpdate" Type="String" />
|
||||
<asp:Parameter DefaultValue="N" Name="DoUpdate" Type="String" />
|
||||
</SelectParameters>
|
||||
<UpdateParameters>
|
||||
<asp:Parameter Name="Original_QuoteType" Type="String" />
|
||||
|
||||
@@ -61,5 +61,13 @@ namespace C2P.WebUserControls
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// effettua update
|
||||
/// </summary>
|
||||
public void doUpdate()
|
||||
{
|
||||
frmView.DataBind();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -6,7 +6,7 @@
|
||||
<%} %>
|
||||
<%@ Register Src="~/WebUserControls/mod_display.ascx" TagName="mod_display" TagPrefix="uc1" %>
|
||||
|
||||
<asp:FormView ID="frmView" runat="server" DataKeyNames="QuoteType,CodQuote,QuoteRev" DataSourceID="odsQuotes" Width="100%" OnModeChanged="frmView_ModeChanged">
|
||||
<asp:FormView ID="frmView" runat="server" DataKeyNames="QuoteType,CodQuote,QuoteRev" DataSourceID="odsQuotes" Width="100%" OnModeChanged="frmView_ModeChanged" OnDataBound="frmView_DataBound">
|
||||
<ItemTemplate>
|
||||
<div class="row bottomLine">
|
||||
<div class="col-xs-2 text-left">
|
||||
@@ -160,11 +160,11 @@
|
||||
<div class="row">
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display19" runat="server" etichetta='<%# traduci("WSR01_sim") %>' />
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox3" runat="server" Text='<%# Bind("WSR01_sim", "{0:N3}") %>' Width="10em" />
|
||||
<asp:TextBox Font-Bold="true" ID="txtWSR01_sim" runat="server" Text='<%# Bind("WSR01_sim", "{0:N4}") %>' Width="10em" />
|
||||
</div>
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display20" runat="server" etichetta='<%# traduci("MSR01_sim") %>' />
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox4" runat="server" Text='<%# Bind("MSR01_sim", "{0:N3}") %>' Width="10em" />
|
||||
<asp:TextBox Font-Bold="true" ID="txtMSR01_sim" runat="server" Text='<%# Bind("MSR01_sim", "{0:N4}") %>' Width="10em" />
|
||||
</div>
|
||||
<div class="col-xs-8 text-right">
|
||||
<uc1:mod_display ID="mod_display21" runat="server" etichetta='<%# traduci("NetProd01_sim") %>' />
|
||||
@@ -188,7 +188,7 @@
|
||||
<asp:QueryStringParameter Name="QuoteType" QueryStringField="QuoteType" Type="String" />
|
||||
<asp:QueryStringParameter Name="CodQuote" QueryStringField="CodQuote" Type="Int64" />
|
||||
<asp:QueryStringParameter Name="QuoteRev" QueryStringField="QuoteRev" Type="Int32" />
|
||||
<asp:Parameter DefaultValue="Y" Name="DoUpdate" Type="String" />
|
||||
<asp:Parameter DefaultValue="N" Name="DoUpdate" Type="String" />
|
||||
</SelectParameters>
|
||||
<UpdateParameters>
|
||||
<asp:Parameter Name="Original_QuoteType" Type="String" />
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using SteamWare;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
@@ -70,36 +71,11 @@ namespace C2P.WebUserControls
|
||||
protected void odsQuotes_Updating(object sender, ObjectDataSourceMethodEventArgs e)
|
||||
{
|
||||
// verifico i campi che possono contenere "%" e percentuali x sistemare come decimal...
|
||||
e.InputParameters["WSR01_sim"] = fixPerc(e.InputParameters["WSR01_sim"].ToString());
|
||||
e.InputParameters["MSR01_sim"] = fixPerc(e.InputParameters["MSR01_sim"].ToString());
|
||||
e.InputParameters["WSR01_sim"] = percentuali.perc2num(e.InputParameters["WSR01_sim"].ToString());
|
||||
e.InputParameters["MSR01_sim"] = percentuali.perc2num(e.InputParameters["MSR01_sim"].ToString());
|
||||
|
||||
}
|
||||
/// <summary>
|
||||
/// sistema un valore stringa ad un decimal per valori "%" corretti, secondo regola
|
||||
/// - se > 1 è da dividere per 100
|
||||
/// - se contiene % è da dividere per 100
|
||||
/// - altrimenti è già da convertire decimal
|
||||
/// </summary>
|
||||
/// <param name="originalVal"></param>
|
||||
/// <returns></returns>
|
||||
protected decimal fixPerc(string originalVal)
|
||||
{
|
||||
decimal answ = 0;
|
||||
try
|
||||
{
|
||||
// inizio convertendo ..
|
||||
answ = Convert.ToDecimal(originalVal);
|
||||
// se > 1 divido per 100...
|
||||
if (answ > 1)
|
||||
{
|
||||
answ = answ / 100;
|
||||
}
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
return answ;
|
||||
}
|
||||
/// <summary>
|
||||
/// verifica se il valore sia zero (x nascondere...)
|
||||
/// </summary>
|
||||
/// <param name="valore"></param>
|
||||
@@ -115,5 +91,35 @@ namespace C2P.WebUserControls
|
||||
{ }
|
||||
return answ;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// effettua update
|
||||
/// </summary>
|
||||
public void doUpdate()
|
||||
{
|
||||
frmView.DataBind();
|
||||
}
|
||||
|
||||
protected void frmView_DataBound(object sender, EventArgs e)
|
||||
{
|
||||
if (frmView.CurrentMode == FormViewMode.Edit)
|
||||
{
|
||||
try
|
||||
{
|
||||
// cerco i textBox...
|
||||
TextBox txtWSR01_sim = ((TextBox)((FormView)sender).FindControl("txtWSR01_sim"));
|
||||
TextBox txtMSR01_sim = ((TextBox)((FormView)sender).FindControl("txtMSR01_sim"));
|
||||
decimal WSR01_sim = percentuali.num2perc(txtWSR01_sim.Text);
|
||||
decimal MSR01_sim = percentuali.num2perc(txtMSR01_sim.Text);
|
||||
// ora modifico moltiplicando x 100...
|
||||
txtWSR01_sim.Text = string.Format("{0:N2}", WSR01_sim);
|
||||
txtMSR01_sim.Text = string.Format("{0:N2}", MSR01_sim);
|
||||
}
|
||||
catch(Exception exc)
|
||||
{
|
||||
SteamWare.logger.lg.scriviLog(string.Format("{0}", exc), SteamWare.tipoLog.EXCEPTION);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -5,114 +5,115 @@
|
||||
<webopt:BundleReference ID="BundleReference2" runat="server" Path="~/Content/themes/base/css" />
|
||||
<%} %>
|
||||
<%@ Register Src="~/WebUserControls/mod_display.ascx" TagName="mod_display" TagPrefix="uc1" %>
|
||||
<%@ Register Src="mod_autocompleteShort.ascx" TagPrefix="uc1" TagName="mod_autocompleteShort" %>
|
||||
|
||||
<asp:FormView ID="frmView" runat="server" DataKeyNames="QuoteType,CodQuote,QuoteRev" DataSourceID="odsQuotes" Width="100%" OnModeChanged="frmView_ModeChanged">
|
||||
<ItemTemplate>
|
||||
<div class="row bottomLine">
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display1" runat="server" etichetta='<%# traduci("ProductCode") %>' valore='<%# Bind("CodItem") %>' />
|
||||
<div class="col-xs-3 text-left">
|
||||
<uc1:mod_display ID="mod_display1" runat="server" etichetta='<%# traduci("ProductCode") %>' valore='<%# Eval("CodItem") %>' />
|
||||
<uc1:mod_autocompleteShort runat="server" ID="acItem" contextKey="a" minCharAutocomplete="2" showKey="false" ServicePath='<%# serviceUrl("Items") %>' placeholder="Search Items" valore='<%# Bind("CodItem") %>' selezione='<%# Eval("CodItem") %>' show="false" />
|
||||
</div>
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display10" runat="server" etichetta='<%# traduci("CodItemGroup") %>' valore='<%# Bind("CodItemGroup") %>' />
|
||||
<uc1:mod_display ID="mod_display10" runat="server" etichetta='<%# traduci("CodItemGroup") %>' valore='<%# Eval("CodItemGroup") %>' />
|
||||
</div>
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display11" runat="server" etichetta='<%# traduci("UnitWeight") %>' valore='<%# Bind("UnitWeight","{0:N0}") %>' />
|
||||
<uc1:mod_display ID="mod_display11" runat="server" etichetta='<%# traduci("UnitWeight") %>' valore='<%# Eval("UnitWeight","{0:N0}") %>' />
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
<uc1:mod_display ID="mod_display2" runat="server" etichetta='<%# traduci("Customer") %>' toolTipVal='<%# Bind("CodClient") %>' valore='<%# Bind("ClientName") %>' />
|
||||
<div class="col-xs-5 text-right">
|
||||
<uc1:mod_display ID="mod_display2" runat="server" etichetta='<%# traduci("Customer") %>' toolTipVal='<%# Eval("CodClient") %>' valore='<%# Eval("ClientName") %>' />
|
||||
<uc1:mod_autocompleteShort runat="server" ID="acCliente" contextKey="c" minCharAutocomplete="2" showKey="false" ServicePath='<%# serviceUrl("Clients") %>' placeholder="Search Customer" valore='<%# Bind("CodClient") %>' selezione='<%# Eval("ClientName") %>' show="false" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row bottomLine">
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display3" runat="server" etichetta='<%# traduci("Alloy") %>' valore='<%# Bind("RawMat") %>' />
|
||||
<div class="col-xs-3 text-left">
|
||||
<uc1:mod_display ID="mod_display3" runat="server" etichetta='<%# traduci("Alloy") %>' valore='<%# Eval("RawMat") %>' />
|
||||
</div>
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display5" runat="server" etichetta='<%# traduci("Base6060") %>' valore='<%# Bind("RawMatCost","{0:C3}") %>' />
|
||||
<uc1:mod_display ID="mod_display5" runat="server" etichetta='<%# traduci("Base6060") %>' valore='<%# Eval("RawMatCost","{0:C3}") %>' />
|
||||
</div>
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display7" runat="server" etichetta='<%# traduci("ExtraAlloy") %>' valore='<%# Bind("RawMatExtraCost","{0:C3}") %>' />
|
||||
<uc1:mod_display ID="mod_display7" runat="server" etichetta='<%# traduci("ExtraAlloy") %>' valore='<%# Eval("RawMatExtraCost","{0:C3}") %>' />
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
<uc1:mod_display ID="mod_display4" runat="server" etichetta='<%# traduci("OrderBatch") %>' valore='<%# Bind("BatchQty") %>' />
|
||||
<div class="col-xs-5 text-right">
|
||||
<uc1:mod_display ID="mod_display4" runat="server" etichetta='<%# traduci("OrderBatch") %>' valore='<%# Eval("BatchQty") %>' />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row bottomLine">
|
||||
<div class="col-xs-6 text-left">
|
||||
<uc1:mod_display ID="mod_display6" runat="server" etichetta='<%# traduci("Incoterms") %>' valore='<%# Bind("CodInco") %>' />
|
||||
<uc1:mod_display ID="mod_display6" runat="server" etichetta='<%# traduci("Incoterms") %>' valore='<%# Eval("CodInco") %>' />
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
<uc1:mod_display ID="mod_display8" runat="server" etichetta='<%# traduci("Agency") %>' valore='<%# Bind("ProvvCost","{0:C3}") %>' />
|
||||
<uc1:mod_display ID="mod_display8" runat="server" etichetta='<%# traduci("Agency") %>' valore='<%# Eval("ProvvCost","{0:C4}") %>' />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-xs-9">
|
||||
<uc1:mod_display ID="mod_display9" runat="server" etichetta='<%# traduci("Note") %>' valore='<%# Bind("Note") %>' />
|
||||
<uc1:mod_display ID="mod_display9" runat="server" etichetta='<%# traduci("Note") %>' valore='<%# Eval("Note") %>' />
|
||||
</div>
|
||||
<div class="col-xs-1">
|
||||
<uc1:mod_display ID="mod_display13" runat="server" etichetta='<%# traduci("OfferResult") %>' valore='<%# Bind("OfferResult") %>' />
|
||||
<uc1:mod_display ID="mod_display13" runat="server" etichetta='<%# traduci("OfferResult") %>' valore='<%# Eval("OfferResult") %>' />
|
||||
</div>
|
||||
<div class="col-xs-1">
|
||||
<uc1:mod_display ID="mod_display14" runat="server" etichetta='<%# traduci("KoReason") %>' valore='<%# Bind("KoReason") %>' />
|
||||
<uc1:mod_display ID="mod_display14" runat="server" etichetta='<%# traduci("KoReason") %>' valore='<%# Eval("KoReason") %>' />
|
||||
</div>
|
||||
<div class="col-xs-1">
|
||||
<uc1:mod_display ID="mod_display15" runat="server" etichetta='<%# traduci("Agente") %>' valore='<%# Bind("Agente") %>' />
|
||||
<uc1:mod_display ID="mod_display15" runat="server" etichetta='<%# traduci("Agente") %>' valore='<%# Eval("Agente") %>' />
|
||||
</div>
|
||||
</div>
|
||||
</ItemTemplate>
|
||||
<EditItemTemplate>
|
||||
<div class="row bottomLine">
|
||||
<div class="col-xs-2 text-left">
|
||||
<div class="col-xs-3 text-left">
|
||||
<uc1:mod_display ID="mod_display12" runat="server" etichetta='<%# traduci("ProductCode") %>' />
|
||||
<asp:DropDownList ID="ddlCodItem" runat="server" DataSourceID="odsProducts" DataValueField="value" DataTextField="value" SelectedValue='<%# Bind("CodItem") %>' />
|
||||
<uc1:mod_autocompleteShort runat="server" ID="acItem" contextKey="a" minCharAutocomplete="2" showKey="false" ServicePath='<%# serviceUrl("Items") %>' placeholder="Search Items" valore='<%# Bind("CodItem") %>' selezione='<%# Eval("CodItem") %>' show='<%# editEnabled %>' />
|
||||
</div>
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display10" runat="server" etichetta='<%# traduci("CodItemGroup") %>' />
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox2" runat="server" Text='<%# Bind("CodItemGroup") %>' Width="10em" />
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox2" runat="server" Text='<%# Bind("CodItemGroup") %>' Width="10em" Enabled='<%# editEnabled %>' />
|
||||
</div>
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display11" runat="server" etichetta='<%# traduci("UnitWeight") %>' />
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox3" runat="server" Text='<%# Bind("UnitWeight","{0:N3}") %>' Width="10em" />
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox3" runat="server" Text='<%# Bind("UnitWeight","{0:N3}") %>' Width="10em" Enabled='<%# editEnabled %>' />
|
||||
</div>
|
||||
|
||||
<div class="col-xs-6 text-right">
|
||||
<div class="col-xs-5 text-right">
|
||||
<uc1:mod_display ID="mod_display2" runat="server" etichetta='<%# traduci("Customer") %>' />
|
||||
<asp:DropDownList ID="DropDownList3" runat="server" DataSourceID="odsCustomers" DataValueField="value" DataTextField="label" SelectedValue='<%# Bind("CodClient") %>' CssClass="text-right" />
|
||||
<uc1:mod_autocompleteShort runat="server" ID="acCliente" contextKey="c" minCharAutocomplete="2" showKey="false" ServicePath='<%# serviceUrl("Clients") %>' placeholder="Search Customer" valore='<%# Bind("CodClient") %>' selezione='<%# Eval("ClientName") %>' show='<%# editEnabled %>' />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row bottomLine">
|
||||
<div class="col-xs-2 text-left">
|
||||
<div class="col-xs-3 text-left">
|
||||
<uc1:mod_display ID="mod_display3" runat="server" etichetta='<%# traduci("Alloy") %>' />
|
||||
<asp:DropDownList ID="ddlRawMat" runat="server" DataSourceID="odsRawMat" DataValueField="value" DataTextField="label" SelectedValue='<%# Bind("RawMat") %>' OnSelectedIndexChanged="ddlRawMat_SelectedIndexChanged" AutoPostBack="true" />
|
||||
<%--<asp:TextBox Font-Bold="true" ID="TextBox3" runat="server" Text='<%# Bind("RawMat") %>' />--%>
|
||||
<asp:DropDownList ID="ddlRawMat" runat="server" DataSourceID="odsRawMat" DataValueField="value" DataTextField="label" SelectedValue='<%# Bind("RawMat") %>' OnSelectedIndexChanged="ddlRawMat_SelectedIndexChanged" AutoPostBack="true" Enabled='<%# editEnabled %>' />
|
||||
</div>
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display5" runat="server" etichetta='<%# traduci("Base6060") %>' />
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox5" runat="server" Text='<%# Bind("RawMatCost","{0:N3}") %>' Width="10em" />
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox5" runat="server" Text='<%# Bind("RawMatCost","{0:N3}") %>' Width="10em" Enabled='<%# editEnabled %>' />
|
||||
</div>
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display7" runat="server" etichetta='<%# traduci("ExtraAlloy") %>' />
|
||||
<asp:TextBox Font-Bold="true" ID="txtRawMatExtraCost" runat="server" Text='<%# Bind("RawMatExtraCost","{0:N3}") %>' Width="10em" />
|
||||
<asp:TextBox Font-Bold="true" ID="txtRawMatExtraCost" runat="server" Text='<%# Bind("RawMatExtraCost","{0:N3}") %>' Width="10em" Enabled='<%# editEnabled %>' />
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
<div class="col-xs-5 text-right">
|
||||
<uc1:mod_display ID="mod_display4" runat="server" etichetta='<%# traduci("OrderBatch") %>' />
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox4" runat="server" Text='<%# Bind("BatchQty") %>' CssClass="text-right" Width="10em" />
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox4" runat="server" Text='<%# Bind("BatchQty") %>' CssClass="text-right" Width="10em" Enabled='<%# editEnabled %>' />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row bottomLine">
|
||||
<div class="col-xs-6 text-left">
|
||||
<uc1:mod_display ID="mod_display6" runat="server" etichetta='<%# traduci("Incoterms") %>' />
|
||||
<asp:DropDownList ID="DropDownList1" runat="server" DataSourceID="odsIncoterms" DataValueField="value" DataTextField="label" SelectedValue='<%# Bind("CodInco") %>' CssClass="text-right" Width="97.5%" />
|
||||
<%--<asp:TextBox Font-Bold="true" ID="TextBox6" runat="server" Text='<%# Bind("CodInco") %>' CssClass="text-right" />--%>
|
||||
<asp:DropDownList ID="DropDownList1" runat="server" DataSourceID="odsIncoterms" DataValueField="value" DataTextField="label" SelectedValue='<%# Bind("CodInco") %>' CssClass="text-right" Width="97.5%" Enabled='<%# editEnabled %>' />
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
<uc1:mod_display ID="mod_display8" runat="server" etichetta='<%# traduci("Agency") %>' />
|
||||
<asp:TextBox Font-Bold="true" ID="txtProvvCost" runat="server" Text='<%# Bind("ProvvCost","{0:N3}") %>' CssClass="text-right" />
|
||||
<asp:TextBox Font-Bold="true" ID="txtProvvCost" runat="server" Text='<%# Bind("ProvvCost","{0:N4}") %>' CssClass="text-right" Enabled='<%# editEnabled %>' />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-xs-9">
|
||||
<uc1:mod_display ID="mod_display9" runat="server" etichetta='<%# traduci("Note") %>' />
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox1" runat="server" Text='<%# Bind("Note") %>' TextMode="MultiLine" Width="100%" Height="4em" />
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox1" runat="server" Text='<%# Bind("Note") %>' TextMode="MultiLine" Width="100%" Height="4em" Enabled='<%# editEnabled %>' />
|
||||
</div>
|
||||
<div class="col-xs-1">
|
||||
<uc1:mod_display ID="mod_display13" runat="server" etichetta='<%# traduci("OfferResult") %>' />
|
||||
@@ -124,7 +125,7 @@
|
||||
</div>
|
||||
<div class="col-xs-1">
|
||||
<uc1:mod_display ID="mod_display15" runat="server" etichetta='<%# traduci("Agente") %>' />
|
||||
<asp:DropDownList ID="DropDownList5" runat="server" DataSourceID="odsAgente" DataValueField="value" DataTextField="label" SelectedValue='<%# Bind("Agente") %>' CssClass="text-right" Width="97.5%" Font-Size="0.8em" />
|
||||
<asp:DropDownList ID="DropDownList5" runat="server" DataSourceID="odsAgente" DataValueField="value" DataTextField="label" Enabled='<%# editEnabled %>' SelectedValue='<%# Bind("Agente") %>' CssClass="text-right" Width="97.5%" Font-Size="0.8em" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
@@ -140,22 +141,19 @@
|
||||
</EditItemTemplate>
|
||||
<InsertItemTemplate>
|
||||
<div class="row bottomLine">
|
||||
<div class="col-xs-6 text-left">
|
||||
<%--<div class="col-xs-6 text-left">
|
||||
<uc1:mod_display ID="mod_display1" runat="server" etichetta='<%# traduci("ProductCode") %>' />
|
||||
<asp:DropDownList ID="ddlProducts" runat="server" DataSourceID="odsProducts" DataValueField="value" DataTextField="value" SelectedValue='<%# Bind("CodItem") %>' OnDataBound="ddlProducts_DataBound" />
|
||||
<%--<asp:TextBox Font-Bold="true" ID="TextBox1" runat="server" Text='<%# Bind("CodItem") %>' />--%>
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
<uc1:mod_display ID="mod_display2" runat="server" etichetta='<%# traduci("Customer") %>' />
|
||||
<asp:DropDownList ID="DropDownList3" runat="server" DataSourceID="odsCustomers" DataValueField="value" DataTextField="label" SelectedValue='<%# Bind("CodClient") %>' CssClass="text-right" />
|
||||
<%--<asp:TextBox Font-Bold="true" ID="TextBox2" runat="server" Text='<%# Bind("CodClient") %>' CssClass="text-right" />--%>
|
||||
</div>
|
||||
</div>--%>
|
||||
</div>
|
||||
<div class="row bottomLine">
|
||||
<div class="col-xs-2 text-left">
|
||||
<div class="col-xs-3 text-left">
|
||||
<uc1:mod_display ID="mod_display3" runat="server" etichetta='<%# traduci("Alloy") %>' />
|
||||
<asp:DropDownList ID="ddlRawMat" runat="server" DataSourceID="odsRawMat" DataValueField="value" DataTextField="label" SelectedValue='<%# Bind("RawMat") %>' OnDataBound="ddlRawMat_DataBound" OnSelectedIndexChanged="ddlRawMat_SelectedIndexChanged" AutoPostBack="true" />
|
||||
<%--<asp:TextBox Font-Bold="true" ID="TextBox3" runat="server" Text='<%# Bind("RawMat") %>' />--%>
|
||||
</div>
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display5" runat="server" etichetta='<%# traduci("Base6060") %>' />
|
||||
@@ -167,7 +165,11 @@
|
||||
<asp:TextBox Font-Bold="true" ID="txtRawMatExtraCost" runat="server" Text='<%# Bind("RawMatExtraCost","{0:N3}") %>' OnDataBinding="txtRawMatExtraCost_DataBinding" Width="10em" />
|
||||
<asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ErrorMessage='<%# traduci("ErrExtraAlloy") %>' CssClass="text-danger" ControlToValidate="txtRawMatExtraCost" Display="Dynamic" />
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display10" runat="server" etichetta='<%# traduci("CodItemGroup") %>' />
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox2" runat="server" Text='<%# Bind("CodItemGroup") %>' Width="10em" />
|
||||
</div>
|
||||
<div class="col-xs-3 text-right">
|
||||
<uc1:mod_display ID="mod_display4" runat="server" etichetta='<%# traduci("OrderBatch") %>' Width="10em" />
|
||||
<asp:TextBox Font-Bold="true" ID="txtBatchQty" runat="server" Text='<%# Bind("BatchQty") %>' CssClass="text-right" />
|
||||
<asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ErrorMessage='<%# traduci("ErrBatchQty") %>' CssClass="text-danger" ControlToValidate="txtBatchQty" Display="Dynamic" />
|
||||
@@ -181,7 +183,7 @@
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
<uc1:mod_display ID="mod_display8" runat="server" etichetta='<%# traduci("Agency") %>' />
|
||||
<asp:Label Font-Bold="true" ID="lblProvvCost" runat="server" Text='<%# Bind("ProvvCost","{0:N3}") %>' CssClass="text-right" />
|
||||
<asp:Label Font-Bold="true" ID="lblProvvCost" runat="server" Text='<%# Bind("ProvvCost","{0:N4}") %>' CssClass="text-right" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
@@ -202,11 +204,12 @@
|
||||
</div>
|
||||
</InsertItemTemplate>
|
||||
</asp:FormView>
|
||||
<asp:ObjectDataSource ID="odsQuotes" runat="server" OldValuesParameterFormatString="Original_{0}" SelectMethod="getByKey" TypeName="C2P_Data.DS_QuotesTableAdapters.QuoteFull_QTableAdapter" UpdateMethod="updateHeadSim" OnUpdated="odsQuotes_Updated" InsertMethod="insertNew" OnInserting="odsQuotes_Inserting">
|
||||
<asp:ObjectDataSource ID="odsQuotes" runat="server" OldValuesParameterFormatString="Original_{0}" SelectMethod="getByKey" TypeName="C2P_Data.DS_QuotesTableAdapters.QuoteFull_QTableAdapter" UpdateMethod="updateHeadSim" OnUpdated="odsQuotes_Updated" InsertMethod="insertNew" OnInserting="odsQuotes_Inserting" OnUpdating="odsQuotes_Updating">
|
||||
<InsertParameters>
|
||||
<asp:Parameter Name="QuoteType" Type="String" DefaultValue="S" />
|
||||
<asp:Parameter Name="CodClient" Type="String" />
|
||||
<asp:Parameter Name="CodItem" Type="String" />
|
||||
<asp:Parameter Name="CodItemGroup" Type="String" />
|
||||
<asp:Parameter Name="RawMat" Type="String" />
|
||||
<asp:Parameter Name="RawMatCost" Type="Decimal" />
|
||||
<asp:Parameter Name="RawMatExtraCost" Type="Decimal" />
|
||||
@@ -218,7 +221,7 @@
|
||||
<asp:QueryStringParameter Name="QuoteType" QueryStringField="QuoteType" Type="String" />
|
||||
<asp:QueryStringParameter Name="CodQuote" QueryStringField="CodQuote" Type="Int64" />
|
||||
<asp:QueryStringParameter Name="QuoteRev" QueryStringField="QuoteRev" Type="Int32" />
|
||||
<asp:Parameter DefaultValue="Y" Name="DoUpdate" Type="String" />
|
||||
<asp:Parameter DefaultValue="N" Name="DoUpdate" Type="String" />
|
||||
</SelectParameters>
|
||||
<UpdateParameters>
|
||||
<asp:Parameter Name="Original_QuoteType" Type="String" />
|
||||
@@ -256,11 +259,7 @@
|
||||
<asp:Parameter DefaultValue="KoReason" Name="FieldName" Type="String" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<asp:ObjectDataSource ID="odsAgente" runat="server" OldValuesParameterFormatString="original_{0}" SelectMethod="getByTableField" TypeName="C2P_Data.DS_UtilityTableAdapters.v_selListValTableAdapter">
|
||||
<SelectParameters>
|
||||
<asp:Parameter DefaultValue="QuoteList" Name="TableName" Type="String" />
|
||||
<asp:Parameter DefaultValue="Agente" Name="FieldName" Type="String" />
|
||||
</SelectParameters>
|
||||
<asp:ObjectDataSource ID="odsAgente" runat="server" OldValuesParameterFormatString="original_{0}" SelectMethod="GetData" TypeName="C2P_Data.DS_UtilityTableAdapters.v_selAgentsTableAdapter">
|
||||
</asp:ObjectDataSource>
|
||||
<asp:Label runat="server" ID="lblError" CssClass="text-danger" Visible="false" />
|
||||
|
||||
|
||||
@@ -12,9 +12,15 @@ namespace C2P.WebUserControls
|
||||
{
|
||||
public partial class mod_S_Header : SteamWare.UserControl
|
||||
{
|
||||
/// <summary>
|
||||
/// url base area services
|
||||
/// </summary>
|
||||
public string serviceUrl(string method)
|
||||
{
|
||||
return string.Format("/{0}/WS_data.asmx/{1}", memLayer.ML.confReadString("serviceUrl"), method);
|
||||
}
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
}
|
||||
public event EventHandler eh_update;
|
||||
/// <summary>
|
||||
@@ -74,8 +80,9 @@ namespace C2P.WebUserControls
|
||||
|
||||
//...leggo i valori!
|
||||
string QuoteType = e.InputParameters["QuoteType"].ToString();
|
||||
string CodClient = e.InputParameters["CodClient"].ToString();
|
||||
string CodItem = e.InputParameters["CodItem"].ToString();
|
||||
string CodClient = memLayer.ML.confReadString("defaultCodClient");
|
||||
string CodItem = memLayer.ML.confReadString("defaultCodItem");
|
||||
string CodItemGroup = e.InputParameters["CodItemGroup"].ToString();
|
||||
string RawMat = e.InputParameters["RawMat"].ToString();
|
||||
decimal RawMatCost = Convert.ToDecimal(e.InputParameters["RawMatCost"]);
|
||||
decimal RawMatExtraCost = Convert.ToDecimal(e.InputParameters["RawMatExtraCost"]);
|
||||
@@ -94,13 +101,12 @@ namespace C2P.WebUserControls
|
||||
{
|
||||
Note = e.InputParameters["Note"].ToString();
|
||||
}
|
||||
|
||||
// chiamo update e vedo risultati (se ultimo record è cambiato rispetto a prima...)
|
||||
DS_Quotes.QuoteFull_QRow rigaPost;
|
||||
try
|
||||
{
|
||||
// chiamo update e vedo risultati (se ultimo record è cambiato rispetto a prima...)
|
||||
rigaPost = DtProxy.man.taQFQ.insertNew(QuoteType, CodClient, CodItem, RawMat, RawMatCost, RawMatExtraCost, BatchQty, CodInco, Note, user_std.UtSn.utente)[0];
|
||||
rigaPost = DtProxy.man.taQFQ.insertNew(QuoteType, CodClient, CodItem, CodItemGroup, RawMat, RawMatCost, RawMatExtraCost, BatchQty, CodInco, Note, user_std.UtSn.utente)[0];
|
||||
if (rigaPost != null)
|
||||
{
|
||||
// verifico SE E' CAMBIATO mando a pagina edit...
|
||||
@@ -212,11 +218,44 @@ namespace C2P.WebUserControls
|
||||
|
||||
protected void odsQuotes_Updating(object sender, ObjectDataSourceMethodEventArgs e)
|
||||
{
|
||||
// intercetto: se esito offerta è OK allora fausa KO è NA...
|
||||
// intercetto: se esito offerta è OK allora causa KO è NA...
|
||||
if (e.InputParameters["OfferResult"].ToString() == "OK")
|
||||
{
|
||||
e.InputParameters["KoReason"] = "NA";
|
||||
}
|
||||
// 2015.05.26 check note NON empty...
|
||||
// se note vuoto metto "-"
|
||||
if (e.InputParameters["Note"] == null || e.InputParameters["Note"].ToString() == "")
|
||||
{
|
||||
e.InputParameters["Note"] = "-";
|
||||
}
|
||||
// 2015.05.29 agente a '' se null
|
||||
if (e.InputParameters["Agente"] == null)
|
||||
{
|
||||
e.InputParameters["Agente"] = "";
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// effettua update
|
||||
/// </summary>
|
||||
public void doUpdate()
|
||||
{
|
||||
frmView.DataBind();
|
||||
}
|
||||
/// <summary>
|
||||
/// stato offerta...
|
||||
/// </summary>
|
||||
public int IdxQS { get; set; }
|
||||
/// <summary>
|
||||
/// determina editabilità da stato offerto (es esito offerta modificabile sempre il resto solo se NON approvata: < 2)
|
||||
/// </summary>
|
||||
public bool editEnabled
|
||||
{
|
||||
get
|
||||
{
|
||||
return IdxQS < 2;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -6,7 +6,7 @@
|
||||
<%} %>
|
||||
<%@ Register Src="~/WebUserControls/mod_display.ascx" TagName="mod_display" TagPrefix="uc1" %>
|
||||
|
||||
<asp:FormView ID="frmView" runat="server" DataKeyNames="QuoteType,CodQuote,QuoteRev" DataSourceID="odsQuotes" Width="100%" OnModeChanged="frmView_ModeChanged">
|
||||
<asp:FormView ID="frmView" runat="server" DataKeyNames="QuoteType,CodQuote,QuoteRev" DataSourceID="odsQuotes" Width="100%" OnModeChanged="frmView_ModeChanged" OnDataBound="frmView_DataBound">
|
||||
<ItemTemplate>
|
||||
<div class="row bottomLine">
|
||||
<div class="col-xs-2 text-left">
|
||||
@@ -100,7 +100,7 @@
|
||||
<div class="row">
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display1" runat="server" etichetta='<%# traduci("DSR_sim") %>' />
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox1" runat="server" Text='<%# Bind("DSR_sim", "{0:N3}") %>' Width="10em" />
|
||||
<asp:TextBox Font-Bold="true" ID="txtDSR_sim" runat="server" Text='<%# Bind("DSR_sim", "{0:N4}") %>' Width="10em" />
|
||||
</div>
|
||||
<div class="col-xs-2 text-left">
|
||||
<uc1:mod_display ID="mod_display15" runat="server" etichetta='<%# traduci("FSR") %>' valore='<%# Eval("FSR", "{0:P2}") %>' />
|
||||
@@ -127,7 +127,7 @@
|
||||
<asp:QueryStringParameter Name="QuoteType" QueryStringField="QuoteType" Type="String" />
|
||||
<asp:QueryStringParameter Name="CodQuote" QueryStringField="CodQuote" Type="Int64" />
|
||||
<asp:QueryStringParameter Name="QuoteRev" QueryStringField="QuoteRev" Type="Int32" />
|
||||
<asp:Parameter DefaultValue="Y" Name="DoUpdate" Type="String" />
|
||||
<asp:Parameter DefaultValue="N" Name="DoUpdate" Type="String" />
|
||||
</SelectParameters>
|
||||
<UpdateParameters>
|
||||
<asp:Parameter Name="Original_QuoteType" Type="String" />
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using SteamWare;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
@@ -70,34 +71,35 @@ namespace C2P.WebUserControls
|
||||
protected void odsQuotes_Updating(object sender, ObjectDataSourceMethodEventArgs e)
|
||||
{
|
||||
// verifico i campi che possono contenere "%" e percentuali x sistemare come decimal...
|
||||
e.InputParameters["DSR_sim"] = fixPerc(e.InputParameters["DSR_sim"].ToString());
|
||||
e.InputParameters["DSR_sim"] = percentuali.perc2num(e.InputParameters["DSR_sim"].ToString());
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// sistema un valore stringa ad un decimal per valori "%" corretti, secondo regola
|
||||
/// - se > 1 è da dividere per 100
|
||||
/// - se contiene % è da dividere per 100
|
||||
/// - altrimenti è già da convertire decimal
|
||||
/// effettua update
|
||||
/// </summary>
|
||||
/// <param name="originalVal"></param>
|
||||
/// <returns></returns>
|
||||
protected decimal fixPerc(string originalVal)
|
||||
public void doUpdate()
|
||||
{
|
||||
decimal answ = 0;
|
||||
try
|
||||
frmView.DataBind();
|
||||
}
|
||||
|
||||
protected void frmView_DataBound(object sender, EventArgs e)
|
||||
{
|
||||
if (frmView.CurrentMode == FormViewMode.Edit)
|
||||
{
|
||||
// inizio convertendo ..
|
||||
answ = Convert.ToDecimal(originalVal);
|
||||
// se > 1 divido per 100...
|
||||
if (answ > 1)
|
||||
try
|
||||
{
|
||||
answ = answ / 100;
|
||||
// cerco i textBox...
|
||||
TextBox txtDSR_sim = ((TextBox)((FormView)sender).FindControl("txtDSR_sim"));
|
||||
decimal DSR_sim = percentuali.num2perc(txtDSR_sim.Text);
|
||||
// ora modifico moltiplicando x 100...
|
||||
txtDSR_sim.Text = string.Format("{0:N2}", DSR_sim);
|
||||
}
|
||||
catch (Exception exc)
|
||||
{
|
||||
SteamWare.logger.lg.scriviLog(string.Format("{0}", exc), SteamWare.tipoLog.EXCEPTION);
|
||||
}
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
return answ;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -44,14 +44,14 @@
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row bottomLine">
|
||||
<div class="col-xs-6 text-left">
|
||||
<uc1:mod_displayHor ID="mod_displayHor14" runat="server" etichetta='<%# traduci("PckSur") %>' valore='<%# Eval("PckSur", "{0:C3}") %>' Visible='<%# userIsAdmin %>' />
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row bottomLine bg-warning" style="font-size: 1.2em; line-height: 1.4em;">
|
||||
<div class="col-xs-6 text-left">
|
||||
<uc1:mod_displayHor ID="mod_displayHor1" runat="server" etichetta='<%# traduci("NetMar_sim") %>' valore='<%# Eval("NetMar_sim", "{0:C3}") %>' />
|
||||
@@ -93,13 +93,9 @@
|
||||
</div>
|
||||
<div class="row bottomLine bg-info" style="font-size: 1.2em; line-height: 1.4em;">
|
||||
<div class="col-xs-6">
|
||||
<div class="row">
|
||||
<div class="col-xs-6 text-left">
|
||||
<uc1:mod_displayHor ID="mod_displayHor8" runat="server" etichetta='<%# traduci("PriceOff") %>' />
|
||||
</div>
|
||||
<div class="col-xs-5 text-right">
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox5" runat="server" Text='<%# Bind("PriceOff","{0:N3}") %>' Width="5em" />
|
||||
</div>
|
||||
<uc1:mod_displayHor ID="mod_displayHor8" runat="server" etichetta='<%# traduci("PriceOff") %>' />
|
||||
<div class="text-right" style="padding-right: 30px;">
|
||||
<asp:TextBox Font-Bold="true" ID="TextBox5" runat="server" Text='<%# Bind("PriceOff","{0:N3}") %>' Width="5em" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
@@ -126,7 +122,7 @@
|
||||
</div>
|
||||
<div class="col-xs-6 text-right">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row bottomLine bg-warning" style="font-size: 1.2em; line-height: 1.4em;">
|
||||
<div class="col-xs-6 text-left">
|
||||
<uc1:mod_displayHor ID="mod_displayHor1" runat="server" etichetta='<%# traduci("NetMar_sim") %>' valore='<%# Eval("NetMar_sim", "{0:C3}") %>' />
|
||||
@@ -166,7 +162,7 @@
|
||||
<asp:QueryStringParameter Name="QuoteType" QueryStringField="QuoteType" Type="String" />
|
||||
<asp:QueryStringParameter Name="CodQuote" QueryStringField="CodQuote" Type="Int64" />
|
||||
<asp:QueryStringParameter Name="QuoteRev" QueryStringField="QuoteRev" Type="Int32" />
|
||||
<asp:Parameter DefaultValue="Y" Name="DoUpdate" Type="String" />
|
||||
<asp:Parameter DefaultValue="N" Name="DoUpdate" Type="String" />
|
||||
</SelectParameters>
|
||||
<UpdateParameters>
|
||||
<asp:Parameter Name="Original_QuoteType" Type="String" />
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using SteamWare;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
@@ -75,7 +76,18 @@ namespace C2P.WebUserControls
|
||||
{
|
||||
get
|
||||
{
|
||||
bool answ = SteamWare.user_std.UtSn.userHasRight("SuperUser");
|
||||
bool answ = devicesAuthProxy.stObj.userHasRight("SuperAdmin") || devicesAuthProxy.stObj.userHasRight("Admin");
|
||||
return answ;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// verifica se utente sia admin altrimenti non vede dati...
|
||||
/// </summary>
|
||||
public bool userIsSuper
|
||||
{
|
||||
get
|
||||
{
|
||||
bool answ = devicesAuthProxy.stObj.userHasRight("SuperUser");
|
||||
return answ;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -58,15 +58,31 @@ namespace C2P.WebUserControls
|
||||
try
|
||||
{
|
||||
termine = risultato.Split('#');
|
||||
// verifico se il termine sia cambiato...
|
||||
if (DataWrap.DW.dictVocabolario[termine[0] + "#" + termine[1]] != termine[2] || DataWrap.DW.dictVocabolario[termine[0] + "#" + termine[1]] == null)
|
||||
// in primis cerco SE ESISTA la chiave in locale...
|
||||
if (DataWrap.DW.dictVocabolario.ContainsKey(termine[0] + "#" + termine[1]))
|
||||
{
|
||||
// verifico se il termine sia cambiato...
|
||||
if (DataWrap.DW.dictVocabolario[termine[0] + "#" + termine[1]] != termine[2] || DataWrap.DW.dictVocabolario[termine[0] + "#" + termine[1]] == null)
|
||||
{
|
||||
// faccio upsert
|
||||
selDataVoc.mgr.upsertLemma(termine[0], termine[1], termine[2]);
|
||||
updLoc++;
|
||||
}
|
||||
}
|
||||
else // non c'è faccio upsert ed inserisco comunque!
|
||||
{
|
||||
// faccio upsert
|
||||
selDataVoc.mgr.upsertLemma(termine[0], termine[1], termine[2]);
|
||||
updLoc++;
|
||||
}
|
||||
}
|
||||
catch { }
|
||||
catch (Exception exc)
|
||||
{
|
||||
if (memLayer.ML.confReadInt("_logLevel") > 6)
|
||||
{
|
||||
logger.lg.scriviLog(string.Format("Errore merge vocabolario:{0}{1}", Environment.NewLine, exc));
|
||||
}
|
||||
}
|
||||
}
|
||||
// step 2: caricamento termini NUOVI locali in db remoto...
|
||||
string trovato = "";
|
||||
|
||||
@@ -0,0 +1,64 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_TranspCostMan.ascx.cs" Inherits="C2P.WebUserControls.mod_TranspCostMan" %>
|
||||
|
||||
<%@ Register Src="~/WebUserControls/mod_fileUploader.ascx" TagName="mod_fileUploader" TagPrefix="uc1" %>
|
||||
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-body">
|
||||
<div class="row">
|
||||
<div class="col-xs-8 col-xs-offset-2">
|
||||
<div runat="server" id="divHelp">
|
||||
<h3 style="text-align: center; margin: auto;"><%: traduci("HTranspCostManTitle") %></h3>
|
||||
<div style="font-size: 1.2em; text-align: center; margin: auto;">
|
||||
<%: traduci("HTranspCostManRepBody") %>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel-body" style="min-height: 213px;">
|
||||
<div class="row">
|
||||
<div class="col-xs-6">
|
||||
<div runat="server" id="divAnalisys">
|
||||
<h3><%: traduci("StepA") %></h3>
|
||||
<div class="panel panel-info" style="min-height: 180px;">
|
||||
<div class="panel-heading">
|
||||
<h4 style="margin-top: -4px; margin-bottom: -4px;"><%: traduci("HTranspCostManStepA") %></h4>
|
||||
</div>
|
||||
<div class="panel-body bg-info" style="padding-top: 20px; padding-bottom: 20px;">
|
||||
<div class="col-xs-12 text-center">
|
||||
<asp:HyperLink runat="server" ID="HyperLink2" class="btn btn-success btn-lg" NavigateUrl="~/CsvExcelExporter?table=TranspCost">
|
||||
|
||||
<i class="fa fa-file-excel-o fa-3x"></i>
|
||||
<div style="margin-top:0.5em;">
|
||||
<%: traduci("TranspCostFile") %>
|
||||
</div>
|
||||
</asp:HyperLink>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-xs-6">
|
||||
<div runat="server" id="div1">
|
||||
<h3><%: traduci("StepB") %></h3>
|
||||
<div class="panel panel-success" style="min-height: 180px;">
|
||||
<div class="panel-heading">
|
||||
<h4 style="margin-top: -4px; margin-bottom: -4px;"><%: traduci("HTranspCostManStepB") %></h4>
|
||||
</div>
|
||||
<div class="panel-body bg-success" style="padding-top: 20px; padding-bottom: 20px; height: 148px;">
|
||||
<div class="col-xs-12 text-center">
|
||||
<uc1:mod_fileUploader ID="mod_fileUploader1" runat="server" contTypeFilt="application/vnd.ms-excel" checkFileType="false" fileName="TranspCostRaw.csv" />
|
||||
<asp:Label runat="server" ID="lblOut"><%: traduci("WaitingForFile") %></asp:Label>
|
||||
<div class="row">
|
||||
<div class="col-xs-9">
|
||||
<asp:Label runat="server" ID="lblUploadDone" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,78 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using SteamWare;
|
||||
using C2P_Data;
|
||||
|
||||
namespace C2P.WebUserControls
|
||||
{
|
||||
public partial class mod_TranspCostMan : System.Web.UI.UserControl
|
||||
{
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
mod_fileUploader1.eh_uploadDone += mod_fileUploader1_eh_uploadDone;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// file caricato
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
void mod_fileUploader1_eh_uploadDone(object sender, EventArgs e)
|
||||
{
|
||||
// caricato file su server, PROVA ad eseguire import tabella
|
||||
string fileName = "TranspCostRaw";
|
||||
string importDataFolder = memLayer.ML.confReadString("importDataFolder");
|
||||
string archiveDataFolder = memLayer.ML.confReadString("archiveDataFolder");
|
||||
string uplDir = memLayer.ML.confReadString("uplDir");
|
||||
string archDir = memLayer.ML.confReadString("archDir");
|
||||
string FIELDTERMINATOR = memLayer.ML.confReadString("FIELDTERMINATOR");
|
||||
string ROWTERMINATOR = memLayer.ML.confReadString("ROWTERMINATOR");
|
||||
string FIRSTROW = memLayer.ML.confReadString("FIRSTROW");
|
||||
string CODEPAGE = memLayer.ML.confReadString("CODEPAGE");
|
||||
bool flgUpdate = memLayer.ML.confReadBool("flgUpdate");
|
||||
int numTicket = 0; // Convert.ToInt32(DateTime.Now.ToString("yyMMddHHmm"));
|
||||
|
||||
// calcolo nuova cartella archivio (anno/mese/gg_ora)
|
||||
DateTime adesso = DateTime.Now;
|
||||
archiveDataFolder = string.Format(@"{0}{1:yyyy}\{1:MM}\{1:dd}\{1:HHmmss}\", archiveDataFolder, adesso);
|
||||
archDir = string.Format(@"{0}{1:yyyy}\{1:MM}\{1:dd}\{1:HHmmss}\", archDir, adesso);
|
||||
// sposto i files da TEMP a cartella archive
|
||||
fileMover.obj.muoviFile(importDataFolder, archiveDataFolder, "TranspCostRaw.csv");
|
||||
// parto con la catena di esecuzione
|
||||
try
|
||||
{
|
||||
DtProxy.man.taTCD.import(fileName, archDir, "TranspCostRaw.csv", FIELDTERMINATOR, ROWTERMINATOR, FIRSTROW, CODEPAGE, "errorTranspCost.log", numTicket);
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
try
|
||||
{
|
||||
DtProxy.man.taTCD.convert(fileName, numTicket);
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
try
|
||||
{
|
||||
DtProxy.man.taTCD.merge(fileName, numTicket, flgUpdate);
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
lblUploadDone.Text = string.Format("Upload and Import done for {0}", fileName);
|
||||
logger.lg.scriviLog(lblUploadDone.Text, tipoLog.INFO);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// wrapper traduzione
|
||||
/// </summary>
|
||||
/// <param name="lemma"></param>
|
||||
/// <returns></returns>
|
||||
public string traduci(string lemma)
|
||||
{
|
||||
return user_std.UtSn.Traduci(lemma);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,78 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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 C2P.WebUserControls {
|
||||
|
||||
|
||||
public partial class mod_TranspCostMan {
|
||||
|
||||
/// <summary>
|
||||
/// divHelp control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.HtmlControls.HtmlGenericControl divHelp;
|
||||
|
||||
/// <summary>
|
||||
/// divAnalisys control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.HtmlControls.HtmlGenericControl divAnalisys;
|
||||
|
||||
/// <summary>
|
||||
/// HyperLink2 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 HyperLink2;
|
||||
|
||||
/// <summary>
|
||||
/// div1 control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.HtmlControls.HtmlGenericControl div1;
|
||||
|
||||
/// <summary>
|
||||
/// mod_fileUploader1 control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::C2P.WebUserControls.mod_fileUploader mod_fileUploader1;
|
||||
|
||||
/// <summary>
|
||||
/// lblOut 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.Label lblOut;
|
||||
|
||||
/// <summary>
|
||||
/// lblUploadDone 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.Label lblUploadDone;
|
||||
}
|
||||
}
|
||||
@@ -33,7 +33,6 @@
|
||||
dataType: "json",
|
||||
async: true,
|
||||
success: function (data) {
|
||||
//response(data.d);
|
||||
response($.map(data.d, function (item) {
|
||||
return {
|
||||
label: item.split('#')[0],
|
||||
|
||||
@@ -139,6 +139,7 @@ namespace C2P.WebUserControls
|
||||
set
|
||||
{
|
||||
hiddenFieldID.Text = value;
|
||||
selezione = value;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
|
||||
+21
-22
@@ -1,4 +1,4 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_autocomplete.ascx.cs" Inherits="C2P.WebUserControls.mod_autocomplete" %>
|
||||
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_autocompleteShort.ascx.cs" Inherits="C2P.WebUserControls.mod_autocompleteShort" %>
|
||||
<%if (false)
|
||||
{ %>
|
||||
<webopt:BundleReference ID="BundleReference1" runat="server" Path="~/Content/css" />
|
||||
@@ -23,6 +23,7 @@
|
||||
// funzione autocomplete
|
||||
function set<%=txtSel.ClientID %>()
|
||||
{
|
||||
//$("input").autocomplete({
|
||||
$("#<%=txtSel.ClientID %>").autocomplete({
|
||||
source: function (request, response) {
|
||||
$.ajax({
|
||||
@@ -33,7 +34,6 @@
|
||||
dataType: "json",
|
||||
async: true,
|
||||
success: function (data) {
|
||||
//response(data.d);
|
||||
response($.map(data.d, function (item) {
|
||||
return {
|
||||
label: item.split('#')[0],
|
||||
@@ -50,7 +50,6 @@
|
||||
$("#<%=hiddenFieldID.ClientID %>").val(i.item.val);
|
||||
$("#<%=txtSel.ClientID %>").val(i.item.label);
|
||||
document.getElementById('<%=btnSearch.ClientID%>').click();
|
||||
//$("#<%=btnSearch.ClientID %>").click();
|
||||
},
|
||||
minLength: <%=txtMinCharAutoCom.Text %>
|
||||
});
|
||||
@@ -67,8 +66,6 @@
|
||||
}
|
||||
// chiamo search...
|
||||
document.getElementById('<%=btnSearch.ClientID%>').click();
|
||||
// alert...
|
||||
//alert('Valore hidden: ' +$("#<%=hiddenFieldID.ClientID %>").val());
|
||||
});
|
||||
}
|
||||
// aggancio evento doc pronto con jQuery...
|
||||
@@ -88,23 +85,25 @@
|
||||
});
|
||||
</script>
|
||||
<%--controlli "principali"--%>
|
||||
<div class="input-group input-group-sm">
|
||||
<span class="input-group-btn" style="text-align: left;">
|
||||
<asp:LinkButton runat="server" ID="btnSearch" CssClass="btn btn-primary btn-sm" OnClick="btnSearch_Click">
|
||||
<i class="fa fa-search"></i>
|
||||
<asp:Label runat="server" ID="lblField"><%: traduci("Search") %></asp:Label>
|
||||
</asp:LinkButton>
|
||||
</span>
|
||||
<asp:TextBox runat="server" ID="txtSel" CssClass="searchinput form-control" OnTextChanged="txtSel_TextChanged" AutoPostBack="True" TextMode="SingleLine" AutoCompleteType="Search" />
|
||||
<%--controlli "accessori"--%>
|
||||
<asp:TextBox runat="server" ID="txtMinCharAutoCom" Text="2" Visible="false" Width="1em" />
|
||||
<asp:TextBox runat="server" ID="txtServiceUrl" Text="Services/WS_data.asmx/Test" Visible="false" Width="1em" />
|
||||
<span class="input-group-btn">
|
||||
<asp:LinkButton runat="server" ID="lnkReset" class="btn btn-primary btn-sm" OnClick="lnkReset_Click"><i class="fa fa-undo"></i></asp:LinkButton>
|
||||
</span>
|
||||
</div>
|
||||
<asp:TextBox runat="server" ID="hiddenFieldID" AutoPostBack="true" OnTextChanged="hiddenFieldID_TextChanged" ViewStateMode="Enabled" Width="0px" Font-Size="6pt" BackColor="Transparent" BorderStyle="None" Height="0px" />
|
||||
|
||||
<asp:Panel runat="server" ID="pnlAC">
|
||||
<div class="input-group input-group-sm">
|
||||
<span class="input-group-btn" style="text-align: left;">
|
||||
<asp:LinkButton runat="server" ID="btnSearch" CssClass="btn btn-primary btn-sm" OnClick="btnSearch_Click">
|
||||
<i class="fa fa-search"></i>
|
||||
<asp:Label runat="server" ID="lblField" />
|
||||
</asp:LinkButton>
|
||||
</span>
|
||||
<%--searchinput form-control artworkcopylookup--%>
|
||||
<asp:TextBox runat="server" ID="txtSel" CssClass="searchinput form-control" OnTextChanged="txtSel_TextChanged" AutoPostBack="True" TextMode="SingleLine" AutoCompleteType="Search" />
|
||||
<%--controlli "accessori"--%>
|
||||
<asp:TextBox runat="server" ID="txtMinCharAutoCom" Text="2" Visible="false" Width="1em" />
|
||||
<asp:TextBox runat="server" ID="txtServiceUrl" Text="Services/WS_data.asmx/Test" Visible="false" Width="1em" />
|
||||
<span class="input-group-btn">
|
||||
<asp:LinkButton runat="server" ID="lnkReset" class="btn btn-primary btn-sm" OnClick="lnkReset_Click"><i class="fa fa-undo"></i></asp:LinkButton>
|
||||
</span>
|
||||
</div>
|
||||
<asp:TextBox runat="server" ID="hiddenFieldID" AutoPostBack="true" OnTextChanged="hiddenFieldID_TextChanged" ViewStateMode="Enabled" Width="0px" Font-Size="6pt" BackColor="Transparent" BorderStyle="None" Height="0px" />
|
||||
</asp:Panel>
|
||||
<style>
|
||||
.ui-autocomplete-category {
|
||||
font-weight: bold;
|
||||
@@ -0,0 +1,339 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using SteamWare;
|
||||
using C2P_Data;
|
||||
|
||||
namespace C2P.WebUserControls
|
||||
{
|
||||
public partial class mod_autocompleteShort : System.Web.UI.UserControl
|
||||
{
|
||||
/// <summary>
|
||||
/// evento valore selezionato
|
||||
/// </summary>
|
||||
public event EventHandler eh_valSelezionato;
|
||||
/// <summary>
|
||||
/// evento valore selezionato
|
||||
/// </summary>
|
||||
public event EventHandler eh_reset;
|
||||
/// <summary>
|
||||
/// segnaposto x casella testuale autocomplete
|
||||
/// </summary>
|
||||
public string placeholder { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// UID formattato con "_"
|
||||
/// </summary>
|
||||
public string uid
|
||||
{
|
||||
get
|
||||
{
|
||||
// fix brutale: nelle pagine master c'è un ctl00_ iniziale di troppo...
|
||||
return this.UniqueID.Replace("$", "_").Replace("ctl00_", "").Replace("ctl01_", "");
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// caricamento pagina
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
if (!Page.IsPostBack)
|
||||
{
|
||||
defaultVal = "";
|
||||
txtSel.Attributes["placeholder"] = placeholder;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// definisce stato hide del controllo
|
||||
/// </summary>
|
||||
public bool show
|
||||
{
|
||||
set
|
||||
{
|
||||
pnlAC.Visible = value;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// wrapper traduzione
|
||||
/// </summary>
|
||||
/// <param name="lemma"></param>
|
||||
/// <returns></returns>
|
||||
public string traduci(object lemma)
|
||||
{
|
||||
return user_std.UtSn.Traduci(lemma.ToString());
|
||||
}
|
||||
|
||||
protected void txtSel_TextChanged(object sender, EventArgs e)
|
||||
{
|
||||
if (txtSel.Text.Trim() == "")
|
||||
{
|
||||
hiddenFieldID.Text = defaultVal;
|
||||
_valore = defaultVal;
|
||||
}
|
||||
if (eh_valSelezionato != null)
|
||||
{
|
||||
eh_valSelezionato(this, new EventArgs());
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// salvo valore selezionato!
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void hiddenFieldID_TextChanged(object sender, EventArgs e)
|
||||
{
|
||||
salvaSelezione();
|
||||
}
|
||||
/// <summary>
|
||||
/// valore selezionato dal controllo (RW local)
|
||||
/// </summary>
|
||||
protected string _valore
|
||||
{
|
||||
get
|
||||
{
|
||||
return memLayer.ML.StringSessionObj(uid + "_sel");
|
||||
}
|
||||
set
|
||||
{
|
||||
memLayer.ML.setSessionVal(uid + "_sel", value);
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// salva evento selezione
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void btnPost_Click(object sender, EventArgs e)
|
||||
{
|
||||
salvaSelezione();
|
||||
}
|
||||
|
||||
private void salvaSelezione()
|
||||
{
|
||||
_valore = hiddenFieldID.Text;
|
||||
if (eh_valSelezionato != null)
|
||||
{
|
||||
eh_valSelezionato(this, new EventArgs());
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// valore (chiave) selezionato dal controllo (R public)
|
||||
/// </summary>
|
||||
public string valore
|
||||
{
|
||||
get
|
||||
{
|
||||
string answ = "";
|
||||
try
|
||||
{
|
||||
answ = hiddenFieldID.Text;
|
||||
}
|
||||
catch
|
||||
{
|
||||
answ = txtSel.Text.Trim();
|
||||
}
|
||||
if (answ == "")
|
||||
{
|
||||
answ = txtSel.Text.Trim();
|
||||
}
|
||||
return answ;
|
||||
}
|
||||
set
|
||||
{
|
||||
hiddenFieldID.Text = value;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// label selezionato dal controllo (R public)
|
||||
/// </summary>
|
||||
public string selezione
|
||||
{
|
||||
get
|
||||
{
|
||||
return txtSel.Text;
|
||||
}
|
||||
set
|
||||
{
|
||||
txtSel.Text = value;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// label dell'etichetta di ricerca
|
||||
/// </summary>
|
||||
public string labelRicerca
|
||||
{
|
||||
set
|
||||
{
|
||||
lblField.Text = value;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// label dell'etichetta di ricerca CON TRADUZIONE
|
||||
/// </summary>
|
||||
public string labelRicercaTrad
|
||||
{
|
||||
set
|
||||
{
|
||||
lblField.Text = traduci(value);
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// num minimo caratteri x autocomplete
|
||||
/// </summary>
|
||||
public Int32 minCharAutocomplete
|
||||
{
|
||||
get
|
||||
{
|
||||
return Convert.ToInt32(txtMinCharAutoCom.Text);
|
||||
}
|
||||
set
|
||||
{
|
||||
txtMinCharAutoCom.Text = value.ToString();
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// path del webservice (compreso metodo)
|
||||
/// nb: DI NORMA fornisce risultati nel formato label#valore
|
||||
/// </summary>
|
||||
public string ServicePath
|
||||
{
|
||||
get
|
||||
{
|
||||
return txtServiceUrl.Text;
|
||||
}
|
||||
set
|
||||
{
|
||||
txtServiceUrl.Text = value;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// imposta visibilità della textBox delle chiavi
|
||||
/// </summary>
|
||||
public bool showKey
|
||||
{
|
||||
set
|
||||
{
|
||||
if (!value)
|
||||
{
|
||||
hiddenFieldID.Width = Unit.Pixel(0);
|
||||
}
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// imposta la stringa tooltip
|
||||
/// </summary>
|
||||
public string toolTip
|
||||
{
|
||||
set
|
||||
{
|
||||
txtSel.ToolTip = value;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// larghezza textbox in unità EM
|
||||
/// </summary>
|
||||
public int textEmWidht
|
||||
{
|
||||
set
|
||||
{
|
||||
txtSel.Width = Unit.Parse(string.Format("{0}em", value));
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// larghezza textbox in unità %
|
||||
/// </summary>
|
||||
public int textEmPerc
|
||||
{
|
||||
set
|
||||
{
|
||||
txtSel.Width = Unit.Parse(string.Format("{0}%", value));
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// imposta il focus sulla textBox
|
||||
/// </summary>
|
||||
public void setFocus()
|
||||
{
|
||||
txtSel.Focus();
|
||||
}
|
||||
/// <summary>
|
||||
/// permette di passare altri parametri di contesto al metodo invocato x autocomplete
|
||||
/// </summary>
|
||||
public string contextKey
|
||||
{
|
||||
get
|
||||
{
|
||||
return txtSel.AccessKey;
|
||||
}
|
||||
set
|
||||
{
|
||||
txtSel.AccessKey = value;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// tabIndex del controllo
|
||||
/// </summary>
|
||||
public short TabIndex
|
||||
{
|
||||
set
|
||||
{
|
||||
txtSel.TabIndex = value;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// valore di default (x reset)
|
||||
/// </summary>
|
||||
public string defaultVal { get; set; }
|
||||
/// <summary>
|
||||
/// resetta controllo
|
||||
/// </summary>
|
||||
public void doReset()
|
||||
{
|
||||
// resetto selezione e ricerca!
|
||||
txtSel.Text = "";
|
||||
hiddenFieldID.Text = defaultVal;
|
||||
_valore = defaultVal;
|
||||
}
|
||||
/// <summary>
|
||||
/// effettuato reset
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void lnkReset_Click(object sender, EventArgs e)
|
||||
{
|
||||
doReset();
|
||||
if (eh_reset != null)
|
||||
{
|
||||
eh_reset(this, new EventArgs());
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// stile x la label
|
||||
/// </summary>
|
||||
public Unit labelWidth
|
||||
{
|
||||
set
|
||||
{
|
||||
lblField.Width = value;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// dummy call x indicare selezione...
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void btnSearch_Click(object sender, EventArgs e)
|
||||
{
|
||||
salvaSelezione();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,105 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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 C2P.WebUserControls {
|
||||
|
||||
|
||||
public partial class mod_autocompleteShort {
|
||||
|
||||
/// <summary>
|
||||
/// BundleReference1 control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::Microsoft.AspNet.Web.Optimization.WebForms.BundleReference BundleReference1;
|
||||
|
||||
/// <summary>
|
||||
/// BundleReference2 control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::Microsoft.AspNet.Web.Optimization.WebForms.BundleReference BundleReference2;
|
||||
|
||||
/// <summary>
|
||||
/// pnlAC 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.Panel pnlAC;
|
||||
|
||||
/// <summary>
|
||||
/// btnSearch 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 btnSearch;
|
||||
|
||||
/// <summary>
|
||||
/// lblField 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.Label lblField;
|
||||
|
||||
/// <summary>
|
||||
/// txtSel 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.TextBox txtSel;
|
||||
|
||||
/// <summary>
|
||||
/// txtMinCharAutoCom 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.TextBox txtMinCharAutoCom;
|
||||
|
||||
/// <summary>
|
||||
/// txtServiceUrl 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.TextBox txtServiceUrl;
|
||||
|
||||
/// <summary>
|
||||
/// lnkReset 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 lnkReset;
|
||||
|
||||
/// <summary>
|
||||
/// hiddenFieldID 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.TextBox hiddenFieldID;
|
||||
}
|
||||
}
|
||||
@@ -55,5 +55,19 @@ namespace C2P.WebUserControls
|
||||
lblVal.ToolTip = value;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// determina visibilità valore
|
||||
/// </summary>
|
||||
public bool showVav
|
||||
{
|
||||
get
|
||||
{
|
||||
return lblVal.Visible;
|
||||
}
|
||||
set
|
||||
{
|
||||
lblVal.Visible = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,9 +1,9 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_displayHor.ascx.cs" Inherits="C2P.WebUserControls.mod_displayHor" %>
|
||||
<div class="row">
|
||||
<%--<div class="row">--%>
|
||||
<div class="col-xs-6 col-xs-offset-1 text-left" style="white-space: normal;">
|
||||
<asp:Label runat="server" ID="lblLab" CssClass="didascalia" Font-Size="1.1em" />
|
||||
</div>
|
||||
<div class="col-xs-4 text-right">
|
||||
<asp:Label runat="server" ID="lblVal" Font-Bold="true" Font-Size="1.2em" />
|
||||
</div>
|
||||
</div>
|
||||
<%--</div>--%>
|
||||
|
||||
@@ -91,7 +91,7 @@ namespace C2P.WebUserControls
|
||||
if (USER_NAME != "" && AuthKey != "")
|
||||
{
|
||||
// invio email!
|
||||
devicesAuthProxy.stObj.sendEmailAuthKey(USER_NAME, AuthKey);
|
||||
devicesAuthProxy.stObj.sendEmailAuthKey(USER_NAME, AuthKey, "New AuthKey COSTIMATE");
|
||||
}
|
||||
break;
|
||||
case "Edit":
|
||||
|
||||
@@ -41,7 +41,7 @@ namespace C2P.WebUserControls
|
||||
{
|
||||
try
|
||||
{
|
||||
if (FileUploadControl.PostedFile.ContentType == contTypeFilt && contTypeFilt != "")
|
||||
if ((FileUploadControl.PostedFile.ContentType == contTypeFilt && contTypeFilt != "") || !checkFileType)
|
||||
{
|
||||
//if (FileUploadControl.PostedFile.ContentLength < 102400000)
|
||||
//{
|
||||
@@ -66,7 +66,7 @@ namespace C2P.WebUserControls
|
||||
}
|
||||
else
|
||||
{
|
||||
StatusLabel.Text = string.Format("{0} - {1}", traduci("ERR-FU-002"), contTypeFilt);
|
||||
StatusLabel.Text = string.Format("{0}{1}PostedFile.ContentType: {2}{1}contTypeFilt: {3}", traduci("ERR-FU-002"), Environment.NewLine, FileUploadControl.PostedFile.ContentType, contTypeFilt);
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
@@ -81,6 +81,10 @@ namespace C2P.WebUserControls
|
||||
/// </summary>
|
||||
public string contTypeFilt { get; set; }
|
||||
/// <summary>
|
||||
/// content type permesso
|
||||
/// </summary>
|
||||
public bool checkFileType{ get; set; }
|
||||
/// <summary>
|
||||
/// nome file con cui salvare
|
||||
/// </summary>
|
||||
public string fileName { get; set; }
|
||||
|
||||
@@ -49,7 +49,7 @@
|
||||
<h4 style="margin-top: -4px; margin-bottom: -4px;"><%: traduci("HMaRepLoadData") %></h4>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<uc2:mod_fileUploader ID="mod_fileUploader1" runat="server" contTypeFilt="application/vnd.ms-excel" fileName="MarginRep_Import.csv" />
|
||||
<uc2:mod_fileUploader ID="mod_fileUploader1" runat="server" contTypeFilt="application/vnd.ms-excel" checkFileType="false" fileName="MarginRep_Import.csv" />
|
||||
<div class="row">
|
||||
<div class="col-xs-9">
|
||||
<asp:Label runat="server" ID="lblUploadDone" />
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user