In test QUALCOSA funziona...
This commit is contained in:
@@ -31,6 +31,59 @@ textarea {
|
||||
max-width: 100%;
|
||||
}
|
||||
}
|
||||
/* FIX modali sx */
|
||||
.modal.left .modal-dialog {
|
||||
position: fixed;
|
||||
margin: auto;
|
||||
width: 320px;
|
||||
height: 100%;
|
||||
-webkit-transform: translate3d(0%, 0, 0);
|
||||
-ms-transform: translate3d(0%, 0, 0);
|
||||
-o-transform: translate3d(0%, 0, 0);
|
||||
transform: translate3d(0%, 0, 0);
|
||||
}
|
||||
.modal.left .modal-content {
|
||||
height: 100%;
|
||||
overflow-y: auto;
|
||||
}
|
||||
.modal.left .modal-body {
|
||||
padding: 15px 15px 80px;
|
||||
}
|
||||
.modal.left.fade .modal-dialog {
|
||||
left: -320px;
|
||||
-webkit-transition: opacity 0.3s linear, left 0.3s ease-out;
|
||||
-moz-transition: opacity 0.3s linear, left 0.3s ease-out;
|
||||
-o-transition: opacity 0.3s linear, left 0.3s ease-out;
|
||||
transition: opacity 0.3s linear, left 0.3s ease-out;
|
||||
}
|
||||
.modal.left.fade.show .modal-dialog {
|
||||
left: 0;
|
||||
}
|
||||
/* ----- MODAL STYLE ----- */
|
||||
.modal-content {
|
||||
border-radius: 0;
|
||||
border: none;
|
||||
}
|
||||
.modal-header {
|
||||
border-bottom-color: #eeeeee;
|
||||
background-color: #fafafa;
|
||||
}
|
||||
/*.demo {
|
||||
padding-top: 60px;
|
||||
padding-bottom: 110px;
|
||||
}
|
||||
|
||||
.btn-demo {
|
||||
margin: 15px;
|
||||
padding: 10px 15px;
|
||||
border-radius: 0;
|
||||
font-size: 16px;
|
||||
background-color: #ffffff;
|
||||
}
|
||||
|
||||
.btn-demo:focus {
|
||||
outline: 0;
|
||||
}*/
|
||||
.elTimbSmart {
|
||||
padding: 0.2em;
|
||||
font-size: 1.1em;
|
||||
|
||||
@@ -38,6 +38,69 @@ textarea {
|
||||
}
|
||||
}
|
||||
|
||||
/* FIX modali sx */
|
||||
.modal.left .modal-dialog {
|
||||
position: fixed;
|
||||
margin: auto;
|
||||
width: 320px;
|
||||
height: 100%;
|
||||
-webkit-transform: translate3d(0%, 0, 0);
|
||||
-ms-transform: translate3d(0%, 0, 0);
|
||||
-o-transform: translate3d(0%, 0, 0);
|
||||
transform: translate3d(0%, 0, 0);
|
||||
}
|
||||
|
||||
.modal.left .modal-content {
|
||||
height: 100%;
|
||||
overflow-y: auto;
|
||||
}
|
||||
|
||||
.modal.left .modal-body {
|
||||
padding: 15px 15px 80px;
|
||||
}
|
||||
|
||||
.modal.left.fade .modal-dialog {
|
||||
left: -320px;
|
||||
-webkit-transition: opacity 0.3s linear, left 0.3s ease-out;
|
||||
-moz-transition: opacity 0.3s linear, left 0.3s ease-out;
|
||||
-o-transition: opacity 0.3s linear, left 0.3s ease-out;
|
||||
transition: opacity 0.3s linear, left 0.3s ease-out;
|
||||
}
|
||||
|
||||
.modal.left.fade.show .modal-dialog {
|
||||
left: 0;
|
||||
}
|
||||
|
||||
/* ----- MODAL STYLE ----- */
|
||||
.modal-content {
|
||||
border-radius: 0;
|
||||
border: none;
|
||||
}
|
||||
|
||||
.modal-header {
|
||||
border-bottom-color: #eeeeee;
|
||||
background-color: #fafafa;
|
||||
}
|
||||
|
||||
/*.demo {
|
||||
padding-top: 60px;
|
||||
padding-bottom: 110px;
|
||||
}
|
||||
|
||||
.btn-demo {
|
||||
margin: 15px;
|
||||
padding: 10px 15px;
|
||||
border-radius: 0;
|
||||
font-size: 16px;
|
||||
background-color: #ffffff;
|
||||
}
|
||||
|
||||
.btn-demo:focus {
|
||||
outline: 0;
|
||||
}*/
|
||||
|
||||
|
||||
|
||||
|
||||
.elTimbSmart {
|
||||
padding: 0.2em;
|
||||
|
||||
Vendored
+1
-1
@@ -1 +1 @@
|
||||
body{font-family:'Roboto Condensed',sans-serif;padding-top:50px;padding-bottom:20px;}.body-content{padding-left:15px;padding-right:15px;}input,select,textarea{max-width:280px;}@media screen and (min-width:768px){.jumbotron{margin-top:20px;}.body-content{padding:0;}input,select,textarea{max-width:100%;}}.elTimbSmart{padding:.2em;font-size:1.1em;line-height:1.3em;}.ui-input-btn input{opacity:.5;}.ui-controlgroup-label legend,.legend{line-height:1.3em;border-bottom:none;}input[type=checkbox],input[type=radio]{margin:-11px 0 0 0;}*{-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;}*:before,*:after{-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;}
|
||||
body{font-family:'Roboto Condensed',sans-serif;padding-top:50px;padding-bottom:20px;}.body-content{padding-left:15px;padding-right:15px;}input,select,textarea{max-width:280px;}@media screen and (min-width:768px){.jumbotron{margin-top:20px;}.body-content{padding:0;}input,select,textarea{max-width:100%;}}.modal.left .modal-dialog{position:fixed;margin:auto;width:320px;height:100%;-webkit-transform:translate3d(0%,0,0);-ms-transform:translate3d(0%,0,0);-o-transform:translate3d(0%,0,0);transform:translate3d(0%,0,0);}.modal.left .modal-content{height:100%;overflow-y:auto;}.modal.left .modal-body{padding:15px 15px 80px;}.modal.left.fade .modal-dialog{left:-320px;-webkit-transition:opacity .3s linear,left .3s ease-out;-moz-transition:opacity .3s linear,left .3s ease-out;-o-transition:opacity .3s linear,left .3s ease-out;transition:opacity .3s linear,left .3s ease-out;}.modal.left.fade.show .modal-dialog{left:0;}.modal-content{border-radius:0;border:none;}.modal-header{border-bottom-color:#eee;background-color:#fafafa;}.elTimbSmart{padding:.2em;font-size:1.1em;line-height:1.3em;}.ui-input-btn input{opacity:.5;}.ui-controlgroup-label legend,.legend{line-height:1.3em;border-bottom:none;}input[type=checkbox],input[type=radio]{margin:-11px 0 0 0;}*{-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;}*:before,*:after{-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;}
|
||||
@@ -5,12 +5,12 @@
|
||||
@import url('JQClock.css');
|
||||
.logo {
|
||||
background-image: url(../images/logo_sw.png);
|
||||
-khtml-opacity: .50;
|
||||
-moz-opacity: .50;
|
||||
-khtml-opacity: 0.5;
|
||||
-moz-opacity: 0.5;
|
||||
-ms-filter: "alpha(opacity=50)";
|
||||
filter: alpha(opacity=50);
|
||||
filter: progid:DXImageTransform.Microsoft.Alpha(opacity=0.5);
|
||||
opacity: .50;
|
||||
opacity: 0.5;
|
||||
width: 800px;
|
||||
height: 300px;
|
||||
margin: 50px auto 50px auto;
|
||||
@@ -19,12 +19,12 @@
|
||||
}
|
||||
.logo:hover {
|
||||
background-image: url(../images/logo_sw.png);
|
||||
-khtml-opacity: 1.0;
|
||||
-moz-opacity: 1.0;
|
||||
-khtml-opacity: 1;
|
||||
-moz-opacity: 1;
|
||||
-ms-filter: "alpha(opacity=100)";
|
||||
filter: alpha(opacity=100);
|
||||
filter: progid:DXImageTransform.Microsoft.Alpha(opacity=1);
|
||||
opacity: 1.0;
|
||||
opacity: 1;
|
||||
width: 800px;
|
||||
height: 300px;
|
||||
margin: 50px auto 50px auto;
|
||||
|
||||
@@ -87,7 +87,7 @@
|
||||
cursor: pointer;
|
||||
position: relative;
|
||||
margin: 2px 0 0 0;
|
||||
padding: .5em .5em .5em .7em;
|
||||
padding: 0.5em 0.5em 0.5em 0.7em;
|
||||
font-size: 100%;
|
||||
}
|
||||
.ui-accordion .ui-accordion-content {
|
||||
@@ -119,7 +119,7 @@
|
||||
}
|
||||
.ui-menu .ui-menu-item-wrapper {
|
||||
position: relative;
|
||||
padding: 3px 1em 3px .4em;
|
||||
padding: 3px 1em 3px 0.4em;
|
||||
}
|
||||
.ui-menu .ui-menu-divider {
|
||||
margin: 5px 0;
|
||||
@@ -144,7 +144,7 @@
|
||||
position: absolute;
|
||||
top: 0;
|
||||
bottom: 0;
|
||||
left: .2em;
|
||||
left: 0.2em;
|
||||
margin: auto 0;
|
||||
}
|
||||
/* right-aligned */
|
||||
@@ -153,11 +153,11 @@
|
||||
right: 0;
|
||||
}
|
||||
.ui-button {
|
||||
padding: .4em 1em;
|
||||
padding: 0.4em 1em;
|
||||
display: inline-block;
|
||||
position: relative;
|
||||
line-height: normal;
|
||||
margin-right: .1em;
|
||||
margin-right: 0.1em;
|
||||
cursor: pointer;
|
||||
vertical-align: middle;
|
||||
text-align: center;
|
||||
@@ -206,7 +206,7 @@ input.ui-button.ui-icon-notext .ui-icon {
|
||||
height: auto;
|
||||
text-indent: 0;
|
||||
white-space: normal;
|
||||
padding: .4em 1em;
|
||||
padding: 0.4em 1em;
|
||||
}
|
||||
/* workarounds */
|
||||
/* Support: Firefox 5 - 40 */
|
||||
@@ -240,7 +240,7 @@ button.ui-button::-moz-focus-inner {
|
||||
box-sizing: border-box;
|
||||
}
|
||||
.ui-controlgroup .ui-controlgroup-label {
|
||||
padding: .4em 1em;
|
||||
padding: 0.4em 1em;
|
||||
}
|
||||
.ui-controlgroup .ui-controlgroup-label span {
|
||||
font-size: 80%;
|
||||
@@ -261,14 +261,14 @@ button.ui-button::-moz-focus-inner {
|
||||
.ui-controlgroup-vertical .ui-spinner-input {
|
||||
/* Support: IE8 only, Android < 4.4 only */
|
||||
width: 75%;
|
||||
width: calc(97.6%);
|
||||
width: calc(100% - 2.4em);
|
||||
}
|
||||
.ui-controlgroup-vertical .ui-spinner .ui-spinner-up {
|
||||
border-top-style: solid;
|
||||
}
|
||||
.ui-checkboxradio-label .ui-icon-background {
|
||||
box-shadow: inset 1px 1px 1px #ccc;
|
||||
border-radius: .12em;
|
||||
border-radius: 0.12em;
|
||||
border: none;
|
||||
}
|
||||
.ui-checkboxradio-radio-label .ui-icon-background {
|
||||
@@ -291,12 +291,12 @@ button.ui-button::-moz-focus-inner {
|
||||
}
|
||||
.ui-datepicker {
|
||||
width: 17em;
|
||||
padding: .2em .2em 0;
|
||||
padding: 0.2em 0.2em 0;
|
||||
display: none;
|
||||
}
|
||||
.ui-datepicker .ui-datepicker-header {
|
||||
position: relative;
|
||||
padding: .2em 0;
|
||||
padding: 0.2em 0;
|
||||
}
|
||||
.ui-datepicker .ui-datepicker-prev,
|
||||
.ui-datepicker .ui-datepicker-next {
|
||||
@@ -345,12 +345,12 @@ button.ui-button::-moz-focus-inner {
|
||||
}
|
||||
.ui-datepicker table {
|
||||
width: 100%;
|
||||
font-size: .9em;
|
||||
font-size: 0.9em;
|
||||
border-collapse: collapse;
|
||||
margin: 0 0 .4em;
|
||||
margin: 0 0 0.4em;
|
||||
}
|
||||
.ui-datepicker th {
|
||||
padding: .7em .3em;
|
||||
padding: 0.7em 0.3em;
|
||||
text-align: center;
|
||||
font-weight: bold;
|
||||
border: 0;
|
||||
@@ -362,23 +362,23 @@ button.ui-button::-moz-focus-inner {
|
||||
.ui-datepicker td span,
|
||||
.ui-datepicker td a {
|
||||
display: block;
|
||||
padding: .2em;
|
||||
padding: 0.2em;
|
||||
text-align: right;
|
||||
text-decoration: none;
|
||||
}
|
||||
.ui-datepicker .ui-datepicker-buttonpane {
|
||||
background-image: none;
|
||||
margin: .7em 0 0 0;
|
||||
padding: 0 .2em;
|
||||
margin: 0.7em 0 0 0;
|
||||
padding: 0 0.2em;
|
||||
border-left: 0;
|
||||
border-right: 0;
|
||||
border-bottom: 0;
|
||||
}
|
||||
.ui-datepicker .ui-datepicker-buttonpane button {
|
||||
float: right;
|
||||
margin: .5em .2em .4em;
|
||||
margin: 0.5em 0.2em 0.4em;
|
||||
cursor: pointer;
|
||||
padding: .2em .6em .3em .6em;
|
||||
padding: 0.2em 0.6em 0.3em 0.6em;
|
||||
width: auto;
|
||||
overflow: visible;
|
||||
}
|
||||
@@ -394,7 +394,7 @@ button.ui-button::-moz-focus-inner {
|
||||
}
|
||||
.ui-datepicker-multi .ui-datepicker-group table {
|
||||
width: 95%;
|
||||
margin: 0 auto .4em;
|
||||
margin: 0 auto 0.4em;
|
||||
}
|
||||
.ui-datepicker-multi-2 .ui-datepicker-group {
|
||||
width: 50%;
|
||||
@@ -458,23 +458,23 @@ button.ui-button::-moz-focus-inner {
|
||||
text-indent: -99999px;
|
||||
overflow: hidden;
|
||||
background-repeat: no-repeat;
|
||||
left: .5em;
|
||||
top: .3em;
|
||||
left: 0.5em;
|
||||
top: 0.3em;
|
||||
}
|
||||
.ui-dialog {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
padding: .2em;
|
||||
padding: 0.2em;
|
||||
outline: 0;
|
||||
}
|
||||
.ui-dialog .ui-dialog-titlebar {
|
||||
padding: .4em 1em;
|
||||
padding: 0.4em 1em;
|
||||
position: relative;
|
||||
}
|
||||
.ui-dialog .ui-dialog-title {
|
||||
float: left;
|
||||
margin: .1em 0;
|
||||
margin: 0.1em 0;
|
||||
white-space: nowrap;
|
||||
width: 90%;
|
||||
overflow: hidden;
|
||||
@@ -482,7 +482,7 @@ button.ui-button::-moz-focus-inner {
|
||||
}
|
||||
.ui-dialog .ui-dialog-titlebar-close {
|
||||
position: absolute;
|
||||
right: .3em;
|
||||
right: 0.3em;
|
||||
top: 50%;
|
||||
width: 20px;
|
||||
margin: -10px 0 0 0;
|
||||
@@ -492,7 +492,7 @@ button.ui-button::-moz-focus-inner {
|
||||
.ui-dialog .ui-dialog-content {
|
||||
position: relative;
|
||||
border: 0;
|
||||
padding: .5em 1em;
|
||||
padding: 0.5em 1em;
|
||||
background: none;
|
||||
overflow: auto;
|
||||
}
|
||||
@@ -500,14 +500,14 @@ button.ui-button::-moz-focus-inner {
|
||||
text-align: left;
|
||||
border-width: 1px 0 0 0;
|
||||
background-image: none;
|
||||
margin-top: .5em;
|
||||
padding: .3em 1em .5em .4em;
|
||||
margin-top: 0.5em;
|
||||
padding: 0.3em 1em 0.5em 0.4em;
|
||||
}
|
||||
.ui-dialog .ui-dialog-buttonpane .ui-dialog-buttonset {
|
||||
float: right;
|
||||
}
|
||||
.ui-dialog .ui-dialog-buttonpane button {
|
||||
margin: .5em .4em .5em 0;
|
||||
margin: 0.5em 0.4em 0.5em 0;
|
||||
cursor: pointer;
|
||||
}
|
||||
.ui-dialog .ui-resizable-n {
|
||||
@@ -710,7 +710,7 @@ button.ui-button::-moz-focus-inner {
|
||||
.ui-slider .ui-slider-range {
|
||||
position: absolute;
|
||||
z-index: 1;
|
||||
font-size: .7em;
|
||||
font-size: 0.7em;
|
||||
display: block;
|
||||
border: 0;
|
||||
background-position: 0 0;
|
||||
@@ -721,7 +721,7 @@ button.ui-button::-moz-focus-inner {
|
||||
filter: inherit;
|
||||
}
|
||||
.ui-slider-horizontal {
|
||||
height: .8em;
|
||||
height: 0.8em;
|
||||
}
|
||||
.ui-slider-horizontal .ui-slider-handle {
|
||||
top: -0.3em;
|
||||
@@ -738,7 +738,7 @@ button.ui-button::-moz-focus-inner {
|
||||
right: 0;
|
||||
}
|
||||
.ui-slider-vertical {
|
||||
width: .8em;
|
||||
width: 0.8em;
|
||||
height: 100px;
|
||||
}
|
||||
.ui-slider-vertical .ui-slider-handle {
|
||||
@@ -771,16 +771,16 @@ button.ui-button::-moz-focus-inner {
|
||||
border: none;
|
||||
background: none;
|
||||
color: inherit;
|
||||
padding: .222em 0;
|
||||
margin: .2em 0;
|
||||
padding: 0.222em 0;
|
||||
margin: 0.2em 0;
|
||||
vertical-align: middle;
|
||||
margin-left: .4em;
|
||||
margin-left: 0.4em;
|
||||
margin-right: 2em;
|
||||
}
|
||||
.ui-spinner-button {
|
||||
width: 1.6em;
|
||||
height: 50%;
|
||||
font-size: .5em;
|
||||
font-size: 0.5em;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
text-align: center;
|
||||
@@ -805,25 +805,25 @@ button.ui-button::-moz-focus-inner {
|
||||
.ui-tabs {
|
||||
position: relative;
|
||||
/* position: relative prevents IE scroll bug (element with position: relative inside container with overflow: auto appear as "fixed") */
|
||||
padding: .2em;
|
||||
padding: 0.2em;
|
||||
}
|
||||
.ui-tabs .ui-tabs-nav {
|
||||
margin: 0;
|
||||
padding: .2em .2em 0;
|
||||
padding: 0.2em 0.2em 0;
|
||||
}
|
||||
.ui-tabs .ui-tabs-nav li {
|
||||
list-style: none;
|
||||
float: left;
|
||||
position: relative;
|
||||
top: 0;
|
||||
margin: 1px .2em 0 0;
|
||||
margin: 1px 0.2em 0 0;
|
||||
border-bottom-width: 0;
|
||||
padding: 0;
|
||||
white-space: nowrap;
|
||||
}
|
||||
.ui-tabs .ui-tabs-nav .ui-tabs-anchor {
|
||||
float: left;
|
||||
padding: .5em 1em;
|
||||
padding: 0.5em 1em;
|
||||
text-decoration: none;
|
||||
}
|
||||
.ui-tabs .ui-tabs-nav li.ui-tabs-active {
|
||||
@@ -1006,7 +1006,7 @@ a.ui-button:active,
|
||||
.ui-priority-secondary,
|
||||
.ui-widget-content .ui-priority-secondary,
|
||||
.ui-widget-header .ui-priority-secondary {
|
||||
opacity: .7;
|
||||
opacity: 0.7;
|
||||
filter: alpha(opacity=70);
|
||||
/* support: IE8 */
|
||||
font-weight: normal;
|
||||
@@ -1014,7 +1014,7 @@ a.ui-button:active,
|
||||
.ui-state-disabled,
|
||||
.ui-widget-content .ui-state-disabled,
|
||||
.ui-widget-header .ui-state-disabled {
|
||||
opacity: .35;
|
||||
opacity: 0.35;
|
||||
filter: alpha(opacity=35);
|
||||
/* support: IE8 */
|
||||
background-image: none;
|
||||
@@ -1615,7 +1615,7 @@ a.ui-button:active,
|
||||
/* Overlays */
|
||||
.ui-widget-overlay {
|
||||
background: #aaaaaa;
|
||||
opacity: .3;
|
||||
opacity: 0.3;
|
||||
filter: alpha(opacity=30);
|
||||
/* support: IE8 */
|
||||
}
|
||||
|
||||
+1
-1
File diff suppressed because one or more lines are too long
@@ -477,6 +477,7 @@
|
||||
<Content Include="Content\fonts\Material-Design-Iconic-Font.eot" />
|
||||
<Content Include="Content\fonts\Material-Design-Iconic-Font.ttf" />
|
||||
<Content Include="Content\fonts\Material-Design-Iconic-Font.woff" />
|
||||
<Content Include="fonts\fontawesome-webfont.svg" />
|
||||
<Content Include="images\AbstractDownload.jpg" />
|
||||
<Content Include="images\favicon.png" />
|
||||
<Content Include="logs\PlaceHolder.file" />
|
||||
@@ -496,6 +497,11 @@
|
||||
<Content Include="Content\bootstrap-reboot.css.map" />
|
||||
<Content Include="Content\bootstrap-grid.min.css.map" />
|
||||
<Content Include="Content\bootstrap-grid.css.map" />
|
||||
<Content Include="fonts\FontAwesome.otf" />
|
||||
<Content Include="fonts\fontawesome-webfont.woff2" />
|
||||
<Content Include="fonts\fontawesome-webfont.woff" />
|
||||
<Content Include="fonts\fontawesome-webfont.ttf" />
|
||||
<Content Include="fonts\fontawesome-webfont.eot" />
|
||||
<None Include="Properties\PublishProfiles\ETS.pubxml" />
|
||||
<None Include="Properties\PublishProfiles\IIS01.pubxml" />
|
||||
<None Include="Properties\PublishProfiles\IIS02-ETS.pubxml" />
|
||||
|
||||
+13
-1
@@ -50,7 +50,19 @@
|
||||
<div class="container-flow body-content">
|
||||
<asp:ContentPlaceHolder ID="MainContent" runat="server">
|
||||
</asp:ContentPlaceHolder>
|
||||
<uc1:cmp_footer runat="server" ID="cmp_footer" />
|
||||
<div data-role="panel" id="bottomsheet" data-animate="false" data-position='bottom' data-display="overlay" style="padding: -1em;">
|
||||
<asp:ContentPlaceHolder ID="btOptContent" runat="server">
|
||||
opzioni bottom
|
||||
</asp:ContentPlaceHolder>
|
||||
</div>
|
||||
<div data-role="footer" data-position="fixed" data-theme="a">
|
||||
<uc1:cmp_footer runat="server" ID="cmp_footer" />
|
||||
</div>
|
||||
<div data-role="panel" id="leftpanel" data-display="overlay" data-position-fixed="true">
|
||||
<asp:ContentPlaceHolder ID="sxOptContent" runat="server">
|
||||
opzioni SX
|
||||
</asp:ContentPlaceHolder>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
|
||||
@@ -28,5 +28,27 @@ namespace GPW_Smart
|
||||
cmp_menuTop.showSearch = value;
|
||||
}
|
||||
}
|
||||
|
||||
public bool showSettings { get; set; }
|
||||
public bool showLeftPnl { get; set; }
|
||||
|
||||
public string hideSettings
|
||||
{
|
||||
get
|
||||
{
|
||||
string answ = "";
|
||||
if (!showSettings) answ = "hidden";
|
||||
return answ;
|
||||
}
|
||||
}
|
||||
public string hideLeftPnl
|
||||
{
|
||||
get
|
||||
{
|
||||
string answ = "";
|
||||
if (!showLeftPnl) answ = "hidden";
|
||||
return answ;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Generated
+18
@@ -30,6 +30,15 @@ namespace GPW_Smart {
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ContentPlaceHolder MainContent;
|
||||
|
||||
/// <summary>
|
||||
/// Controllo btOptContent.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Campo generato automaticamente.
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ContentPlaceHolder btOptContent;
|
||||
|
||||
/// <summary>
|
||||
/// Controllo cmp_footer.
|
||||
/// </summary>
|
||||
@@ -38,5 +47,14 @@ namespace GPW_Smart {
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::GPW_Smart.WebUserControls.cmp_footer cmp_footer;
|
||||
|
||||
/// <summary>
|
||||
/// Controllo sxOptContent.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Campo generato automaticamente.
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ContentPlaceHolder sxOptContent;
|
||||
}
|
||||
}
|
||||
|
||||
+52
-1
@@ -1,4 +1,55 @@
|
||||
<%@ Page Title="" Language="C#" MasterPageFile="~/Site.master" AutoEventWireup="true" CodeBehind="TestMe.aspx.cs" Inherits="GPW_Smart.TestMe" %>
|
||||
|
||||
<%@ Register Src="~/WebUserControls/mod_timbrature.ascx" TagPrefix="uc1" TagName="mod_timbrature" %>
|
||||
<%@ Register Src="~/WebUserControls/mod_mancTimb.ascx" TagPrefix="uc1" TagName="mod_mancTimb" %>
|
||||
<%@ Register Src="~/WebUserControls/mod_opzioniSx.ascx" TagPrefix="uc1" TagName="mod_opzioniSx" %>
|
||||
|
||||
|
||||
<asp:Content ID="Content1" ContentPlaceHolderID="MainContent" runat="server">
|
||||
Test con master page...
|
||||
<asp:UpdatePanel runat="server" ID="pnlTimbrature">
|
||||
<ContentTemplate>
|
||||
<uc1:mod_timbrature runat="server" ID="mod_timbrature" />
|
||||
|
||||
<div class="row">
|
||||
<div class="col">
|
||||
<button type="button" class="btn btn-block btn-warning" data-toggle="modal" data-target="#panelSxModal">
|
||||
Left Sidebar Modal
|
||||
</button>
|
||||
</div>
|
||||
<div class="col">
|
||||
<button type="button" class="btn btn-block btn-warning" data-toggle="modal" data-target="#bottomModal">
|
||||
Other Modal
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="modal left fade" id="panelSxModal" tabindex="-1" role="dialog" aria-labelledby="exampleModalLabel" aria-hidden="true">
|
||||
<div class="modal-dialog" role="document">
|
||||
<div class="modal-content">
|
||||
<div class="modal-body">
|
||||
<uc1:mod_opzioniSx runat="server" ID="mod_opzioniSx" />
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-secondary" data-dismiss="modal">Close</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="modal fade" id="bottomModal" tabindex="-1" role="dialog" aria-labelledby="exampleModalLabel" aria-hidden="true">
|
||||
<div class="modal-dialog" role="document">
|
||||
<div class="modal-content">
|
||||
<div class="modal-body">
|
||||
<uc1:mod_mancTimb runat="server" ID="mod_mancTimb" />
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-secondary" data-dismiss="modal">Close</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
</asp:Content>
|
||||
|
||||
|
||||
@@ -1,9 +1,6 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using GPW_data;
|
||||
using System;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
|
||||
namespace GPW_Smart
|
||||
{
|
||||
@@ -11,7 +8,35 @@ namespace GPW_Smart
|
||||
{
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
if (!Page.IsPostBack)
|
||||
{
|
||||
utils.mng.dailyDuties();
|
||||
}
|
||||
((Site)Master).showSettings = true;
|
||||
((Site)Master).showLeftPnl = true;
|
||||
mod_opzioniSx.ev_reqAbilitaAll += Mod_opzioniSx_ev_reqAbilitaAll;
|
||||
mod_opzioniSx.ev_reqUpdate += Mod_opzioniSx_ev_reqUpdate;
|
||||
mod_mancTimb.ev_reqUpdate += Mod_mancTimb_ev_reqUpdate;
|
||||
}
|
||||
private void Mod_mancTimb_ev_reqUpdate(object sender, EventArgs e)
|
||||
{
|
||||
mod_timbrature.doUpdate();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// update visualizzazione timbrature
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
private void Mod_opzioniSx_ev_reqUpdate(object sender, EventArgs e)
|
||||
{
|
||||
mod_timbrature.doUpdate();
|
||||
}
|
||||
|
||||
private void Mod_opzioniSx_ev_reqAbilitaAll(object sender, EventArgs e)
|
||||
{
|
||||
mod_timbrature.abilitaAll();
|
||||
mod_timbrature.doUpdate();
|
||||
}
|
||||
}
|
||||
}
|
||||
Generated
+36
@@ -11,5 +11,41 @@ namespace GPW_Smart {
|
||||
|
||||
|
||||
public partial class TestMe {
|
||||
|
||||
/// <summary>
|
||||
/// Controllo pnlTimbrature.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Campo generato automaticamente.
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.UpdatePanel pnlTimbrature;
|
||||
|
||||
/// <summary>
|
||||
/// Controllo mod_timbrature.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Campo generato automaticamente.
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::GPW.WebUserControls.mod_timbrature mod_timbrature;
|
||||
|
||||
/// <summary>
|
||||
/// Controllo mod_opzioniSx.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Campo generato automaticamente.
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::GPW_Smart.WebUserControls.mod_opzioniSx mod_opzioniSx;
|
||||
|
||||
/// <summary>
|
||||
/// Controllo mod_mancTimb.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Campo generato automaticamente.
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::GPW.WebUserControls.mod_mancTimb mod_mancTimb;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="cmp_menuTop.ascx.cs" Inherits="GPW_Smart.WebUserControls.cmp_menuTop" %>
|
||||
|
||||
<nav class="navbar navbar-expand-lg navbar-dark bg-dark text-light">
|
||||
<a class="navbar-brand" href="#">Sauder NKC <i class="fa fa-object-group" aria-hidden="true"></i></a>
|
||||
<a class="navbar-brand" href="#"><asp:Label runat="server" ID="lblSwData" /> <i class="fa fa-clock-o" aria-hidden="true"></i></a>
|
||||
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
|
||||
<span class="navbar-toggler-icon"></span>
|
||||
</button>
|
||||
|
||||
@@ -1,11 +1,24 @@
|
||||
using SteamWare;
|
||||
using GPW_data;
|
||||
using SteamWare;
|
||||
using System;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
|
||||
namespace GPW_Smart.WebUserControls
|
||||
{
|
||||
public partial class cmp_menuTop : System.Web.UI.UserControl
|
||||
{
|
||||
/// <summary>
|
||||
/// user agent corrente
|
||||
/// </summary>
|
||||
protected string userAgent = "";
|
||||
/// <summary>
|
||||
/// IP corrente
|
||||
/// </summary>
|
||||
protected string postazione_IP = "";
|
||||
/// <summary>
|
||||
/// gestione evento refresh
|
||||
/// </summary>
|
||||
public event EventHandler eh_doRefresh;
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
@@ -13,6 +26,99 @@ namespace GPW_Smart.WebUserControls
|
||||
{
|
||||
searchVal = "";
|
||||
}
|
||||
// controllo se c'è utente in sessione..
|
||||
checkUser();
|
||||
// sistemo visualizzazione
|
||||
postazione_IP = Request.UserHostName;
|
||||
try
|
||||
{
|
||||
lblSwData.Text = memLayer.ML.StringSessionObj("cognomeNome");
|
||||
}
|
||||
catch
|
||||
{
|
||||
lblSwData.Text = "GPW";
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// verifica presenza utente autorizzato in sessione
|
||||
/// </summary>
|
||||
private void checkUser()
|
||||
{
|
||||
if (!memLayer.ML.isInSessionObject("idxDipendente"))
|
||||
{
|
||||
// controllo cookie device...
|
||||
checkAuthCookieGPW();
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// verifica al presenza di un cookie VALIDO per autorizzare il device
|
||||
/// </summary>
|
||||
private void checkAuthCookieGPW()
|
||||
{
|
||||
try
|
||||
{
|
||||
HttpCookie cookie = Request.Cookies["AuthGPW"];
|
||||
if (cookie == null || cookie.Value == "")
|
||||
{
|
||||
// rimando pagina x registrazione devices
|
||||
Response.Redirect("~/regNewDevice.aspx");
|
||||
}
|
||||
else
|
||||
{
|
||||
// ricavo utente da cookie...
|
||||
string devSecret = cookie.Value;
|
||||
DS_Applicazione.AnagDevicesRow device = null;
|
||||
// cerco il device...ogni dipendente può averne + di 1 registrato a suo nome...
|
||||
int idxDipendente = 0;
|
||||
try
|
||||
{
|
||||
device = DataProxy.DP.taAnagDev.getByDeviceSecret(devSecret)[0];
|
||||
idxDipendente = device.idxDipendente;
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
if (idxDipendente > 0)
|
||||
{
|
||||
// aggiorno descrizione (user agent) ed IP...
|
||||
userAgent = Request.UserAgent;
|
||||
postazione_IP = Request.UserHostName;
|
||||
// controllo IP e DeviceDescription x eventuale update
|
||||
if ((device.lastIPv4 != postazione_IP) || (device.Description != userAgent))
|
||||
{
|
||||
// salvo ultimo "contatto" del device aggiornando descrizione ed IP
|
||||
DataProxy.DP.taAnagDev.updateIP(device.IdxDevice, DateTime.Now, postazione_IP, userAgent);
|
||||
}
|
||||
// salvo in sessione utente
|
||||
memLayer.ML.setSessionVal("idxDipendente", idxDipendente);
|
||||
string CognomeNome = "";
|
||||
string email = "";
|
||||
string hashEmail = "";
|
||||
try
|
||||
{
|
||||
DS_Applicazione.DipendentiRow rigaDip = DataProxy.DP.taDipendenti.getByIdx(idxDipendente)[0];
|
||||
CognomeNome = string.Format("{0} {1}", rigaDip.Cognome, rigaDip.Nome);
|
||||
email = rigaDip.email;
|
||||
hashEmail = SteamCrypto.getHashStringMD5(email);
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
memLayer.ML.setSessionVal("cognomeNome", CognomeNome);
|
||||
memLayer.ML.setSessionVal("email", email);
|
||||
memLayer.ML.setSessionVal("hashEmail", hashEmail);
|
||||
}
|
||||
else
|
||||
{
|
||||
// svuoto cookie...
|
||||
memLayer.ML.emptyCookieVal("AuthGPW");
|
||||
// rimando pagina x registrazione devices
|
||||
Response.Redirect("~/regNewDevice.aspx");
|
||||
}
|
||||
}
|
||||
}
|
||||
catch (Exception exc)
|
||||
{
|
||||
logger.lg.scriviLog(string.Format("Errore in checkAuthCookie:{0}{1}", Environment.NewLine, exc), tipoLog.EXCEPTION);
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// imposta visibilità search globale
|
||||
|
||||
@@ -12,6 +12,15 @@ namespace GPW_Smart.WebUserControls {
|
||||
|
||||
public partial class cmp_menuTop {
|
||||
|
||||
/// <summary>
|
||||
/// Controllo lblSwData.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Campo generato automaticamente.
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lblSwData;
|
||||
|
||||
/// <summary>
|
||||
/// Controllo divSearch.
|
||||
/// </summary>
|
||||
|
||||
@@ -1,16 +1,16 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_timbrature.ascx.cs" Inherits="GPW.WebUserControls.mod_timbrature" %>
|
||||
<div class="ui-grid-a">
|
||||
<div class="ui-block-a ui-content">
|
||||
<asp:Button runat="server" CssClass="ui-btn ui-btn-icon-left ui-shadow ui-corner-all clr-btn-blue" data-icon="check" ID="btnEntrata" Text="Entrata" OnClick="btnEntrata_Click" Width="100%" />
|
||||
</div>
|
||||
<div class="ui-block-b">
|
||||
<asp:Button runat="server" CssClass="ui-btn ui-btn-icon-left ui-shadow ui-corner-all clr-btn-green" data-icon="check" ID="btnUscita" Text="Uscita" OnClick="btnUscita_Click" Width="100%" />
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col">
|
||||
<asp:LinkButton runat="server" CssClass="btn btn-primary btn-block" ID="lbtEntrata" OnClick="lbtEntrata_Click"><i class="fa fa-sign-in" aria-hidden="true"></i> Entrata</asp:LinkButton>
|
||||
</div>
|
||||
<div class="col">
|
||||
<asp:LinkButton runat="server" CssClass="btn btn-success btn-block" ID="lbtUscita" OnClick="lbtUscita_Click">Uscita <i class="fa fa-sign-out" aria-hidden="true"></i></asp:LinkButton>
|
||||
</div>
|
||||
</div>
|
||||
<asp:Label runat="server" ID="lblWarning" Visible="false" />
|
||||
<div class="elTimbSmart">
|
||||
<asp:GridView ID="grView" runat="server" AllowPaging="false" DataSourceID="ods" AutoGenerateColumns="False" DataKeyNames="dataLav,idxDipendente" CellPadding="4" ForeColor="#333333" GridLines="None" Width="100%" OnRowCreated="grView_RowCreated" OnSelectedIndexChanged="grView_SelectedIndexChanged">
|
||||
<AlternatingRowStyle BackColor="White" />
|
||||
<asp:GridView ID="grView" runat="server" AllowPaging="false" DataSourceID="ods" AutoGenerateColumns="False" DataKeyNames="dataLav,idxDipendente" CellPadding="4" ForeColor="#333333" GridLines="None" Width="100%" OnRowCreated="grView_RowCreated" OnSelectedIndexChanged="grView_SelectedIndexChanged" CssClass="table table-striped table-sm">
|
||||
<%--<AlternatingRowStyle BackColor="White" />
|
||||
<EditRowStyle BackColor="#2461BF" />
|
||||
<FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
|
||||
<HeaderStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
|
||||
@@ -20,68 +20,67 @@
|
||||
<SortedAscendingCellStyle BackColor="#F5F7FB" />
|
||||
<SortedAscendingHeaderStyle BackColor="#6D95E1" />
|
||||
<SortedDescendingCellStyle BackColor="#E9EBEF" />
|
||||
<SortedDescendingHeaderStyle BackColor="#4870BE" />
|
||||
<Columns>
|
||||
<asp:TemplateField HeaderText="data" SortExpression="dataLav" ItemStyle-Wrap="false" ItemStyle-HorizontalAlign="Left">
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton runat="server" ID="lbShowOre" CommandArgument="showProj" CommandName="Select" data-inline="true"><%# Eval("dataLav", "{0:MM.dd} <sup>{0:ddd}</sup>") %></asp:LinkButton>
|
||||
<%--<asp:Label ID="Label1" runat="server" Text='<%# Eval("dataLav", "{0:MM-dd ddd}") %>' />--%>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Ent" SortExpression="entrata_1" ItemStyle-HorizontalAlign="Center">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label3" runat="server" Text='<%# Eval("entrata_1","{0:HH:mm}") %>' ForeColor="#226622" Font-Size="Smaller" />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Usc" SortExpression="uscita_1" ItemStyle-HorizontalAlign="Center">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label4" runat="server" Text='<%# Eval("uscita_1","{0:HH:mm}") %>' ForeColor="#222266" Font-Size="Smaller" />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Ent" SortExpression="entrata_2" ItemStyle-HorizontalAlign="Center">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label5" runat="server" Text='<%# Eval("entrata_2","{0:HH:mm}") %>' ForeColor="#226622" Font-Size="Smaller" />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Usc" SortExpression="uscita_2" ItemStyle-HorizontalAlign="Center">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label6" runat="server" Text='<%# Eval("uscita_2","{0:HH:mm}") %>' ForeColor="#222266" Font-Size="Smaller" />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Ent" SortExpression="entrata_3" ItemStyle-HorizontalAlign="Center">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label7" runat="server" Text='<%# Eval("entrata_3","{0:HH:mm}") %>' ForeColor="#226622" Font-Size="Smaller" />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Usc" SortExpression="uscita_3" ItemStyle-HorizontalAlign="Center">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label8" runat="server" Text='<%# Eval("uscita_3","{0:HH:mm}") %>' ForeColor="#222266" Font-Size="Smaller" />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="H lav" SortExpression="h_lav" ItemStyle-HorizontalAlign="Right" HeaderStyle-HorizontalAlign="Right">
|
||||
<ItemTemplate>
|
||||
<b>
|
||||
<asp:Label ID="Label11" runat="server" Text='<%# Eval("h_lav","{0:0.00}") %>' />
|
||||
</b>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="" ItemStyle-HorizontalAlign="Right" HeaderStyle-HorizontalAlign="Right">
|
||||
<ItemTemplate>
|
||||
<b>
|
||||
<asp:Label ID="lblIsOk" runat="server" Text="*" ForeColor="Red" Visible='<%# invBool(Eval("isOk")) %>' />
|
||||
</b>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
</asp:GridView>
|
||||
<asp:ObjectDataSource ID="ods" runat="server" DeleteMethod="Delete" InsertMethod="Insert" OldValuesParameterFormatString="Original_{0}" SelectMethod="getLastByUser" TypeName="GPW_data.DS_ApplicazioneTableAdapters.TimbratureExplTableAdapter" UpdateMethod="Update" FilterExpression="idxDipendente = {0} AND (NOT (entrata_1 IS NULL) )">
|
||||
<FilterParameters>
|
||||
<asp:SessionParameter SessionField="idxDipendente" Name="idxDipendente" Type="Int32" />
|
||||
</FilterParameters>
|
||||
<SelectParameters>
|
||||
<asp:SessionParameter SessionField="idxDipendente" Name="idxDipendente" Type="Int32" />
|
||||
<asp:SessionParameter SessionField="numRowTimb" Name="num2show" Type="Int32" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<SortedDescendingHeaderStyle BackColor="#4870BE" />--%>
|
||||
<Columns>
|
||||
<asp:TemplateField HeaderText="data" SortExpression="dataLav" ItemStyle-Wrap="false" ItemStyle-HorizontalAlign="Left">
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton runat="server" ID="lbShowOre" CommandArgument="showProj" CommandName="Select" CssClass="btn btn-dark btn-sm px-1 py-0"><%# Eval("dataLav", "{0:MM.dd} <sup>{0:ddd}</sup>") %></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Ent" SortExpression="entrata_1" ItemStyle-HorizontalAlign="Center">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label3" runat="server" Text='<%# Eval("entrata_1","{0:HH:mm}") %>' ForeColor="#226622" Font-Size="Smaller" />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Usc" SortExpression="uscita_1" ItemStyle-HorizontalAlign="Center">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label4" runat="server" Text='<%# Eval("uscita_1","{0:HH:mm}") %>' ForeColor="#222266" Font-Size="Smaller" />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Ent" SortExpression="entrata_2" ItemStyle-HorizontalAlign="Center">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label5" runat="server" Text='<%# Eval("entrata_2","{0:HH:mm}") %>' ForeColor="#226622" Font-Size="Smaller" />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Usc" SortExpression="uscita_2" ItemStyle-HorizontalAlign="Center">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label6" runat="server" Text='<%# Eval("uscita_2","{0:HH:mm}") %>' ForeColor="#222266" Font-Size="Smaller" />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Ent" SortExpression="entrata_3" ItemStyle-HorizontalAlign="Center">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label7" runat="server" Text='<%# Eval("entrata_3","{0:HH:mm}") %>' ForeColor="#226622" Font-Size="Smaller" />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Usc" SortExpression="uscita_3" ItemStyle-HorizontalAlign="Center">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label8" runat="server" Text='<%# Eval("uscita_3","{0:HH:mm}") %>' ForeColor="#222266" Font-Size="Smaller" />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="H lav" SortExpression="h_lav" ItemStyle-HorizontalAlign="Right" HeaderStyle-HorizontalAlign="Right">
|
||||
<ItemTemplate>
|
||||
<b>
|
||||
<asp:Label ID="Label11" runat="server" Text='<%# Eval("h_lav","{0:0.00}") %>' />
|
||||
</b>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="" ItemStyle-HorizontalAlign="Right" HeaderStyle-HorizontalAlign="Right">
|
||||
<ItemTemplate>
|
||||
<b>
|
||||
<asp:Label ID="lblIsOk" runat="server" Text="*" ForeColor="Red" Visible='<%# invBool(Eval("isOk")) %>' />
|
||||
</b>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
</asp:GridView>
|
||||
<asp:ObjectDataSource ID="ods" runat="server" DeleteMethod="Delete" InsertMethod="Insert" OldValuesParameterFormatString="Original_{0}" SelectMethod="getLastByUser" TypeName="GPW_data.DS_ApplicazioneTableAdapters.TimbratureExplTableAdapter" UpdateMethod="Update" FilterExpression="idxDipendente = {0} AND (NOT (entrata_1 IS NULL) )">
|
||||
<FilterParameters>
|
||||
<asp:SessionParameter SessionField="idxDipendente" Name="idxDipendente" Type="Int32" />
|
||||
</FilterParameters>
|
||||
<SelectParameters>
|
||||
<asp:SessionParameter SessionField="idxDipendente" Name="idxDipendente" Type="Int32" />
|
||||
<asp:SessionParameter SessionField="numRowTimb" Name="num2show" Type="Int32" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
|
||||
</div>
|
||||
|
||||
@@ -1,230 +1,232 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using GPW_data;
|
||||
using SteamWare;
|
||||
using System;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using SteamWare;
|
||||
using GPW_data;
|
||||
|
||||
namespace GPW.WebUserControls
|
||||
{
|
||||
public partial class mod_timbrature : System.Web.UI.UserControl
|
||||
public partial class mod_timbrature : System.Web.UI.UserControl
|
||||
{
|
||||
protected bool forceButtons = true;
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
protected bool forceButtons = true;
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
if (!Page.IsPostBack)
|
||||
{
|
||||
// verifico se ci sia un numero di righe selezionate altrimenti lo imposto...
|
||||
if (!memLayer.ML.isInSessionObject("numColEU")) numColEU = 2;
|
||||
if (!memLayer.ML.isInSessionObject("numRowTimb")) numRowTimb = 10;
|
||||
memLayer.ML.setSessionVal("dataRif", DateTime.Today);
|
||||
}
|
||||
setButtons();
|
||||
}
|
||||
|
||||
public int numColEU
|
||||
{
|
||||
get
|
||||
{
|
||||
int answ = 2;
|
||||
try
|
||||
{
|
||||
answ = memLayer.ML.IntSessionObj("numColEU");
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
if (answ <= 0) answ = 2;
|
||||
return answ;
|
||||
}
|
||||
set
|
||||
{
|
||||
memLayer.ML.setSessionVal("numColEU", value);
|
||||
}
|
||||
}
|
||||
public int numRowTimb
|
||||
{
|
||||
get
|
||||
{
|
||||
return memLayer.ML.IntSessionObj("numRowTimb");
|
||||
}
|
||||
set
|
||||
{
|
||||
memLayer.ML.setSessionVal("numRowTimb", value);
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// imposto highlight di un area intorno al button
|
||||
/// </summary>
|
||||
private void setButtons()
|
||||
{
|
||||
// controllo SE voglio inibire i buttons...
|
||||
if (forceButtons)
|
||||
{
|
||||
// controllo se il prox comando DOVREBBE essere entrata o uscita
|
||||
bool nextIsEntrata = true;
|
||||
// controllo dipendente
|
||||
if (IdxDipendente > 0)
|
||||
{
|
||||
// ricavo ultima timbratura..
|
||||
nextIsEntrata = timbratrice.nextIsEntrata(IdxDipendente);
|
||||
// di conseguenza cambio abilitazione ad un buttons
|
||||
if (nextIsEntrata)
|
||||
{
|
||||
btnEntrata.Enabled = true;
|
||||
btnUscita.Enabled = false;
|
||||
}
|
||||
else
|
||||
{
|
||||
btnEntrata.Enabled = false;
|
||||
btnUscita.Enabled = true;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
btnEntrata.Enabled = false;
|
||||
btnUscita.Enabled = false;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
btnEntrata.Enabled = true;
|
||||
btnUscita.Enabled = true;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// timbro entrata...
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void btnEntrata_Click(object sender, EventArgs e)
|
||||
{
|
||||
bool isEntrata = true;
|
||||
registraTimbratura(isEntrata);
|
||||
}
|
||||
/// <summary>
|
||||
/// uscita...
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void btnUscita_Click(object sender, EventArgs e)
|
||||
{
|
||||
bool isEntrata = false;
|
||||
registraTimbratura(isEntrata);
|
||||
}
|
||||
/// <summary>
|
||||
/// Abilita tutti i buttons
|
||||
/// </summary>
|
||||
public void abilitaAll()
|
||||
{
|
||||
forceButtons = false;
|
||||
}
|
||||
/// <summary>
|
||||
/// Aggiorno visualizzazione
|
||||
/// </summary>
|
||||
public void doUpdate()
|
||||
{
|
||||
setButtons();
|
||||
grView.DataBind();
|
||||
}
|
||||
/// <summary>
|
||||
/// update elenco ultime timbrature
|
||||
/// </summary>
|
||||
private void updateTimbrature()
|
||||
{
|
||||
// aggiorno datagrid
|
||||
}
|
||||
/// <summary>
|
||||
/// registro timbratura
|
||||
/// </summary>
|
||||
/// <param name="isEntrata"></param>
|
||||
/// <returns></returns>
|
||||
private int registraTimbratura(bool isEntrata)
|
||||
{
|
||||
// salvo evento entrata...
|
||||
string IPv4 = "";
|
||||
bool approvata = false;
|
||||
if (IdxDipendente > 0)
|
||||
{
|
||||
// recupero IP
|
||||
IPv4 = Request.UserHostName;
|
||||
// controllo se IP locale = approvata...
|
||||
if (IPv4.Contains(memLayer.ML.confReadString("localNet")))
|
||||
{
|
||||
approvata = true;
|
||||
}
|
||||
timbratrice.registraTimbratura(IdxDipendente, DateTime.Now, isEntrata, IPv4, "Web", approvata);
|
||||
lblWarning.Visible = false;
|
||||
//aggiorno timbrature visualizzate
|
||||
setButtons();
|
||||
updateTimbrature();
|
||||
grView.DataBind();
|
||||
}
|
||||
else
|
||||
{
|
||||
lblWarning.Text = "IdxDipendente non trovato! timbratura impossibile";
|
||||
lblWarning.Visible = true;
|
||||
}
|
||||
return IdxDipendente;
|
||||
}
|
||||
/// <summary>
|
||||
/// idx dipendente loggato
|
||||
/// </summary>
|
||||
protected int IdxDipendente
|
||||
{
|
||||
get
|
||||
{
|
||||
int idx = 0;
|
||||
try
|
||||
{
|
||||
idx = memLayer.ML.IntSessionObj("IdxDipendente");
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
return idx;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// inverte valore booleano
|
||||
/// </summary>
|
||||
/// <param name="isEnt"></param>
|
||||
/// <returns></returns>
|
||||
public bool invBool(object valore)
|
||||
{
|
||||
bool answ = true;
|
||||
try
|
||||
{
|
||||
answ = !Convert.ToBoolean(valore);
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
return answ;
|
||||
}
|
||||
|
||||
protected void grView_RowCreated(object sender, GridViewRowEventArgs e)
|
||||
{
|
||||
int maxNum = e.Row.Cells.Count - 2;
|
||||
for (int i = numColEU * 2 + 1; i < maxNum; i++)
|
||||
{
|
||||
e.Row.Cells[i].Visible = false;
|
||||
}
|
||||
}
|
||||
|
||||
protected void grView_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
// rimando ai progetti sulla data indicata...
|
||||
DateTime dataRif = DateTime.Today;
|
||||
try
|
||||
{
|
||||
dataRif = Convert.ToDateTime(grView.SelectedDataKey["dataLav"]);
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
// salvo in sessione...
|
||||
memLayer.ML.setSessionVal("dataRif", dataRif);
|
||||
// reinvio
|
||||
Response.Redirect(string.Format("Progetti?dataRif={0:yyyy-MM-dd}", dataRif));
|
||||
}
|
||||
if (!Page.IsPostBack)
|
||||
{
|
||||
// verifico se ci sia un numero di righe selezionate altrimenti lo imposto...
|
||||
if (!memLayer.ML.isInSessionObject("numColEU")) numColEU = 2;
|
||||
if (!memLayer.ML.isInSessionObject("numRowTimb")) numRowTimb = 10;
|
||||
memLayer.ML.setSessionVal("dataRif", DateTime.Today);
|
||||
}
|
||||
setButtons();
|
||||
}
|
||||
|
||||
public int numColEU
|
||||
{
|
||||
get
|
||||
{
|
||||
int answ = 2;
|
||||
try
|
||||
{
|
||||
answ = memLayer.ML.IntSessionObj("numColEU");
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
if (answ <= 0) answ = 2;
|
||||
return answ;
|
||||
}
|
||||
set
|
||||
{
|
||||
memLayer.ML.setSessionVal("numColEU", value);
|
||||
}
|
||||
}
|
||||
public int numRowTimb
|
||||
{
|
||||
get
|
||||
{
|
||||
return memLayer.ML.IntSessionObj("numRowTimb");
|
||||
}
|
||||
set
|
||||
{
|
||||
memLayer.ML.setSessionVal("numRowTimb", value);
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// imposto highlight di un area intorno al button
|
||||
/// </summary>
|
||||
private void setButtons()
|
||||
{
|
||||
// controllo SE voglio inibire i buttons...
|
||||
if (forceButtons)
|
||||
{
|
||||
// controllo se il prox comando DOVREBBE essere entrata o uscita
|
||||
bool nextIsEntrata = true;
|
||||
// controllo dipendente
|
||||
if (IdxDipendente > 0)
|
||||
{
|
||||
// ricavo ultima timbratura..
|
||||
nextIsEntrata = timbratrice.nextIsEntrata(IdxDipendente);
|
||||
// di conseguenza cambio abilitazione ad un buttons
|
||||
if (nextIsEntrata)
|
||||
{
|
||||
fixBtnInOut(true, false);
|
||||
}
|
||||
else
|
||||
{
|
||||
fixBtnInOut(false, true);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
fixBtnInOut(false, false);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
fixBtnInOut(true, true);
|
||||
}
|
||||
}
|
||||
|
||||
private void fixBtnInOut(bool showIn, bool showOut)
|
||||
{
|
||||
lbtEntrata.Enabled = showIn;
|
||||
lbtUscita.Enabled = showOut;
|
||||
lbtEntrata.CssClass = showIn ? "btn btn-primary btn-block" : "btn btn-outline-primary disabled btn-block";
|
||||
lbtUscita.CssClass = showOut ? "btn btn-success btn-block" : "btn btn-outline-success disabled btn-block";
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// timbro entrata...
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void lbtEntrata_Click(object sender, EventArgs e)
|
||||
{
|
||||
bool isEntrata = true;
|
||||
registraTimbratura(isEntrata);
|
||||
}
|
||||
/// <summary>
|
||||
/// uscita...
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void lbtUscita_Click(object sender, EventArgs e)
|
||||
{
|
||||
bool isEntrata = false;
|
||||
registraTimbratura(isEntrata);
|
||||
}
|
||||
/// <summary>
|
||||
/// Abilita tutti i buttons
|
||||
/// </summary>
|
||||
public void abilitaAll()
|
||||
{
|
||||
forceButtons = false;
|
||||
}
|
||||
/// <summary>
|
||||
/// Aggiorno visualizzazione
|
||||
/// </summary>
|
||||
public void doUpdate()
|
||||
{
|
||||
setButtons();
|
||||
grView.DataBind();
|
||||
}
|
||||
/// <summary>
|
||||
/// update elenco ultime timbrature
|
||||
/// </summary>
|
||||
private void updateTimbrature()
|
||||
{
|
||||
// aggiorno datagrid
|
||||
}
|
||||
/// <summary>
|
||||
/// registro timbratura
|
||||
/// </summary>
|
||||
/// <param name="isEntrata"></param>
|
||||
/// <returns></returns>
|
||||
private int registraTimbratura(bool isEntrata)
|
||||
{
|
||||
// salvo evento entrata...
|
||||
string IPv4 = "";
|
||||
bool approvata = false;
|
||||
if (IdxDipendente > 0)
|
||||
{
|
||||
// recupero IP
|
||||
IPv4 = Request.UserHostName;
|
||||
// controllo se IP locale = approvata...
|
||||
if (IPv4.Contains(memLayer.ML.confReadString("localNet")))
|
||||
{
|
||||
approvata = true;
|
||||
}
|
||||
timbratrice.registraTimbratura(IdxDipendente, DateTime.Now, isEntrata, IPv4, "Web", approvata);
|
||||
lblWarning.Visible = false;
|
||||
//aggiorno timbrature visualizzate
|
||||
setButtons();
|
||||
updateTimbrature();
|
||||
grView.DataBind();
|
||||
}
|
||||
else
|
||||
{
|
||||
lblWarning.Text = "IdxDipendente non trovato! timbratura impossibile";
|
||||
lblWarning.Visible = true;
|
||||
}
|
||||
return IdxDipendente;
|
||||
}
|
||||
/// <summary>
|
||||
/// idx dipendente loggato
|
||||
/// </summary>
|
||||
protected int IdxDipendente
|
||||
{
|
||||
get
|
||||
{
|
||||
int idx = 0;
|
||||
try
|
||||
{
|
||||
idx = memLayer.ML.IntSessionObj("IdxDipendente");
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
return idx;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// inverte valore booleano
|
||||
/// </summary>
|
||||
/// <param name="isEnt"></param>
|
||||
/// <returns></returns>
|
||||
public bool invBool(object valore)
|
||||
{
|
||||
bool answ = true;
|
||||
try
|
||||
{
|
||||
answ = !Convert.ToBoolean(valore);
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
return answ;
|
||||
}
|
||||
|
||||
protected void grView_RowCreated(object sender, GridViewRowEventArgs e)
|
||||
{
|
||||
int maxNum = e.Row.Cells.Count - 2;
|
||||
for (int i = numColEU * 2 + 1; i < maxNum; i++)
|
||||
{
|
||||
e.Row.Cells[i].Visible = false;
|
||||
}
|
||||
}
|
||||
|
||||
protected void grView_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
// rimando ai progetti sulla data indicata...
|
||||
DateTime dataRif = DateTime.Today;
|
||||
try
|
||||
{
|
||||
dataRif = Convert.ToDateTime(grView.SelectedDataKey["dataLav"]);
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
// salvo in sessione...
|
||||
memLayer.ML.setSessionVal("dataRif", dataRif);
|
||||
// reinvio
|
||||
Response.Redirect(string.Format("Progetti?dataRif={0:yyyy-MM-dd}", dataRif));
|
||||
}
|
||||
}
|
||||
}
|
||||
+22
-22
@@ -1,10 +1,10 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
// <generato automaticamente>
|
||||
// Codice generato da uno strumento.
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
// Le modifiche a questo file possono causare un comportamento non corretto e verranno perse se
|
||||
// il codice viene rigenerato.
|
||||
// </generato automaticamente>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace GPW.WebUserControls {
|
||||
@@ -13,47 +13,47 @@ namespace GPW.WebUserControls {
|
||||
public partial class mod_timbrature {
|
||||
|
||||
/// <summary>
|
||||
/// btnEntrata control.
|
||||
/// Controllo lbtEntrata.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// Campo generato automaticamente.
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Button btnEntrata;
|
||||
protected global::System.Web.UI.WebControls.LinkButton lbtEntrata;
|
||||
|
||||
/// <summary>
|
||||
/// btnUscita control.
|
||||
/// Controllo lbtUscita.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// Campo generato automaticamente.
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Button btnUscita;
|
||||
protected global::System.Web.UI.WebControls.LinkButton lbtUscita;
|
||||
|
||||
/// <summary>
|
||||
/// lblWarning control.
|
||||
/// Controllo lblWarning.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// Campo generato automaticamente.
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lblWarning;
|
||||
|
||||
/// <summary>
|
||||
/// grView control.
|
||||
/// Controllo grView.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// Campo generato automaticamente.
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.GridView grView;
|
||||
|
||||
/// <summary>
|
||||
/// ods control.
|
||||
/// Controllo ods.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// Campo generato automaticamente.
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource ods;
|
||||
}
|
||||
|
||||
@@ -1,121 +1,117 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using GPW_data;
|
||||
using SteamWare;
|
||||
using GPW_data;
|
||||
using System;
|
||||
using System.Web;
|
||||
|
||||
namespace GPW.WebUserControls
|
||||
{
|
||||
public partial class mod_title : System.Web.UI.UserControl
|
||||
{
|
||||
/// <summary>
|
||||
/// user agent corrente
|
||||
/// </summary>
|
||||
protected string userAgent = "";
|
||||
/// <summary>
|
||||
/// IP corrente
|
||||
/// </summary>
|
||||
protected string postazione_IP = "";
|
||||
public partial class mod_title : System.Web.UI.UserControl
|
||||
{
|
||||
/// <summary>
|
||||
/// user agent corrente
|
||||
/// </summary>
|
||||
protected string userAgent = "";
|
||||
/// <summary>
|
||||
/// IP corrente
|
||||
/// </summary>
|
||||
protected string postazione_IP = "";
|
||||
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
// controllo se c'è utente in sessione..
|
||||
checkUser();
|
||||
// sistemo visualizzazione
|
||||
postazione_IP = Request.UserHostName;
|
||||
try
|
||||
{
|
||||
lblSwData.Text = memLayer.ML.StringSessionObj("cognomeNome");
|
||||
}
|
||||
catch
|
||||
{
|
||||
lblSwData.Text = "GPW";
|
||||
}
|
||||
//lblIpData.Text = memLayer.ML.StringSessionObj("cognomeNome");
|
||||
}
|
||||
/// <summary>
|
||||
/// verifica presenza utente autorizzato in sessione
|
||||
/// </summary>
|
||||
private void checkUser()
|
||||
{
|
||||
if (!memLayer.ML.isInSessionObject("idxDipendente"))
|
||||
{
|
||||
// controllo cookie device...
|
||||
checkAuthCookieGPW();
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// verifica al presenza di un cookie VALIDO per autorizzare il device
|
||||
/// </summary>
|
||||
private void checkAuthCookieGPW()
|
||||
{
|
||||
try
|
||||
{
|
||||
HttpCookie cookie = Request.Cookies["AuthGPW"];
|
||||
if (cookie == null || cookie.Value == "")
|
||||
{
|
||||
// controllo se c'è utente in sessione..
|
||||
checkUser();
|
||||
// sistemo visualizzazione
|
||||
// rimando pagina x registrazione devices
|
||||
Response.Redirect("~/regNewDevice.aspx");
|
||||
}
|
||||
else
|
||||
{
|
||||
// ricavo utente da cookie...
|
||||
string devSecret = cookie.Value;
|
||||
DS_Applicazione.AnagDevicesRow device = null;
|
||||
// cerco il device...ogni dipendente può averne + di 1 registrato a suo nome...
|
||||
int idxDipendente = 0;
|
||||
try
|
||||
{
|
||||
device = DataProxy.DP.taAnagDev.getByDeviceSecret(devSecret)[0];
|
||||
idxDipendente = device.idxDipendente;
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
if (idxDipendente > 0)
|
||||
{
|
||||
// aggiorno descrizione (user agent) ed IP...
|
||||
userAgent = Request.UserAgent;
|
||||
postazione_IP = Request.UserHostName;
|
||||
// controllo IP e DeviceDescription x eventuale update
|
||||
if ((device.lastIPv4 != postazione_IP) || (device.Description != userAgent))
|
||||
{
|
||||
// salvo ultimo "contatto" del device aggiornando descrizione ed IP
|
||||
DataProxy.DP.taAnagDev.updateIP(device.IdxDevice, DateTime.Now, postazione_IP, userAgent);
|
||||
}
|
||||
// salvo in sessione utente
|
||||
memLayer.ML.setSessionVal("idxDipendente", idxDipendente);
|
||||
string CognomeNome = "";
|
||||
string email = "";
|
||||
string hashEmail = "";
|
||||
try
|
||||
{
|
||||
lblSwData.Text = memLayer.ML.StringSessionObj("cognomeNome");
|
||||
DS_Applicazione.DipendentiRow rigaDip = DataProxy.DP.taDipendenti.getByIdx(idxDipendente)[0];
|
||||
CognomeNome = string.Format("{0} {1}", rigaDip.Cognome, rigaDip.Nome);
|
||||
email = rigaDip.email;
|
||||
hashEmail = SteamCrypto.getHashStringMD5(email);
|
||||
}
|
||||
catch
|
||||
{
|
||||
lblSwData.Text = "GPW";
|
||||
}
|
||||
//lblIpData.Text = memLayer.ML.StringSessionObj("cognomeNome");
|
||||
}
|
||||
/// <summary>
|
||||
/// verifica presenza utente autorizzato in sessione
|
||||
/// </summary>
|
||||
private void checkUser()
|
||||
{
|
||||
if (!memLayer.ML.isInSessionObject("idxDipendente"))
|
||||
{
|
||||
// controllo cookie device...
|
||||
checkAuthCookieGPW();
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// verifica al presenza di un cookie VALIDO per autorizzare il device
|
||||
/// </summary>
|
||||
private void checkAuthCookieGPW()
|
||||
{
|
||||
try
|
||||
{
|
||||
HttpCookie cookie = Request.Cookies["AuthGPW"];
|
||||
if (cookie == null || cookie.Value=="")
|
||||
{
|
||||
// rimando pagina x registrazione devices
|
||||
Response.Redirect("~/regNewDevice.aspx");
|
||||
}
|
||||
else
|
||||
{
|
||||
// ricavo utente da cookie...
|
||||
string devSecret = cookie.Value;
|
||||
DS_Applicazione.AnagDevicesRow device = null;
|
||||
// cerco il device...ogni dipendente può averne + di 1 registrato a suo nome...
|
||||
int idxDipendente = 0;
|
||||
try
|
||||
{
|
||||
device = DataProxy.DP.taAnagDev.getByDeviceSecret(devSecret)[0];
|
||||
idxDipendente = device.idxDipendente;
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
if (idxDipendente > 0)
|
||||
{
|
||||
// aggiorno descrizione (user agent) ed IP...
|
||||
userAgent = Request.UserAgent;
|
||||
postazione_IP = Request.UserHostName;
|
||||
// controllo IP e DeviceDescription x eventuale update
|
||||
if ((device.lastIPv4 != postazione_IP) || (device.Description != userAgent))
|
||||
{
|
||||
// salvo ultimo "contatto" del device aggiornando descrizione ed IP
|
||||
DataProxy.DP.taAnagDev.updateIP(device.IdxDevice, DateTime.Now, postazione_IP, userAgent);
|
||||
}
|
||||
// salvo in sessione utente
|
||||
memLayer.ML.setSessionVal("idxDipendente", idxDipendente);
|
||||
string CognomeNome = "";
|
||||
string email = "";
|
||||
string hashEmail = "";
|
||||
try
|
||||
{
|
||||
DS_Applicazione.DipendentiRow rigaDip = DataProxy.DP.taDipendenti.getByIdx(idxDipendente)[0];
|
||||
CognomeNome = string.Format("{0} {1}", rigaDip.Cognome, rigaDip.Nome);
|
||||
email = rigaDip.email;
|
||||
hashEmail = SteamCrypto.getHashStringMD5(email);
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
memLayer.ML.setSessionVal("cognomeNome", CognomeNome);
|
||||
memLayer.ML.setSessionVal("email", email);
|
||||
memLayer.ML.setSessionVal("hashEmail", hashEmail);
|
||||
}
|
||||
else
|
||||
{
|
||||
// svuoto cookie...
|
||||
memLayer.ML.emptyCookieVal("AuthGPW");
|
||||
// rimando pagina x registrazione devices
|
||||
Response.Redirect("~/regNewDevice.aspx");
|
||||
}
|
||||
}
|
||||
}
|
||||
catch(Exception exc)
|
||||
{
|
||||
logger.lg.scriviLog(string.Format("Errore in checkAuthCookie:{0}{1}", Environment.NewLine, exc), tipoLog.EXCEPTION);
|
||||
}
|
||||
{ }
|
||||
memLayer.ML.setSessionVal("cognomeNome", CognomeNome);
|
||||
memLayer.ML.setSessionVal("email", email);
|
||||
memLayer.ML.setSessionVal("hashEmail", hashEmail);
|
||||
}
|
||||
else
|
||||
{
|
||||
// svuoto cookie...
|
||||
memLayer.ML.emptyCookieVal("AuthGPW");
|
||||
// rimando pagina x registrazione devices
|
||||
Response.Redirect("~/regNewDevice.aspx");
|
||||
}
|
||||
}
|
||||
}
|
||||
catch (Exception exc)
|
||||
{
|
||||
logger.lg.scriviLog(string.Format("Errore in checkAuthCookie:{0}{1}", Environment.NewLine, exc), tipoLog.EXCEPTION);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Binary file not shown.
Binary file not shown.
File diff suppressed because it is too large
Load Diff
|
After Width: | Height: | Size: 434 KiB |
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -2,9 +2,12 @@
|
||||
<packages>
|
||||
<package id="Antlr" version="3.5.0.2" targetFramework="net462" />
|
||||
<package id="AspNet.ScriptManager.bootstrap" version="4.3.1" targetFramework="net462" />
|
||||
<package id="AspNet.ScriptManager.jQuery" version="3.4.1" targetFramework="net462" />
|
||||
<package id="bootstrap" version="4.3.1" targetFramework="net462" />
|
||||
<package id="elmah" version="1.2.2" targetFramework="net462" />
|
||||
<package id="elmah.corelibrary" version="1.2.2" targetFramework="net462" />
|
||||
<package id="FontAwesome" version="4.7.0" targetFramework="net462" />
|
||||
<package id="jQuery" version="3.4.1" targetFramework="net462" />
|
||||
<package id="jquery.mobile" version="1.4.5" targetFramework="net462" />
|
||||
<package id="jQuery.UI.Combined" version="1.12.1" targetFramework="net462" />
|
||||
<package id="Microsoft.AspNet.FriendlyUrls" version="1.0.2" targetFramework="net462" />
|
||||
@@ -19,6 +22,7 @@
|
||||
<package id="Modernizr" version="2.8.3" targetFramework="net462" />
|
||||
<package id="Newtonsoft.Json" version="12.0.2" targetFramework="net462" />
|
||||
<package id="Pipelines.Sockets.Unofficial" version="2.0.25" targetFramework="net462" />
|
||||
<package id="popper.js" version="1.14.3" targetFramework="net462" />
|
||||
<package id="Respond" version="1.4.2" targetFramework="net462" />
|
||||
<package id="StackExchange.Redis" version="2.0.601" targetFramework="net462" />
|
||||
<package id="StackExchange.Redis.StrongName" version="1.2.6" targetFramework="net462" />
|
||||
|
||||
Vendored
+2
-2
@@ -2,7 +2,7 @@ pipeline {
|
||||
agent none
|
||||
environment {
|
||||
enableIIS01 = 'Y'
|
||||
enableIIS02 = 'Y'
|
||||
enableIIS02 = 'N'
|
||||
}
|
||||
stages {
|
||||
stage('Checkout') {
|
||||
@@ -15,7 +15,7 @@ pipeline {
|
||||
|
||||
/* calcolo numero versione... diverso x branch MASTER/DEVELOP */
|
||||
script {
|
||||
withEnv(['NEXT_BUILD_NUMBER=4063']) {
|
||||
withEnv(['NEXT_BUILD_NUMBER=4065']) {
|
||||
// env.versionNumber = VersionNumber(versionNumberString : '${BUILD_DATE_FORMATTED, "yyMM"}.${BUILDS_ALL_TIME}', projectStartDate : '2006-01-01', skipFailedBuilds: true)
|
||||
env.versionNumber = VersionNumber(versionNumberString : '${BUILD_DATE_FORMATTED, "yyMM"}.${BUILDS_ALL_TIME}', projectStartDate : '2006-01-01', skipFailedBuilds: true, overrideBuildsAllTime: '${NEXT_BUILD_NUMBER}')
|
||||
env.APP_NAME = 'GPW'
|
||||
|
||||
Reference in New Issue
Block a user