This commit is contained in:
JORGE LUIS CAUDILLO ESPARZA
2020-04-23 15:39:00 -07:00
parent fbef754e34
commit 73476f82fb
35 changed files with 6190 additions and 59 deletions

View File

@@ -51,6 +51,7 @@ Public Class BundleConfig
"~/Metronic/assets/admin/layout/scripts/demo.js",
"~/Metronic/assets/admin/pages/scripts/table-advanced.js",
"~/Metronic/assets/admin/pages/scripts/ui-alert-dialog-api.js",
"~/Metronic/assets/global/plugins/icheck/icheck.min.js",
"~/Metronic/assets/global/plugins/dropzone/dropzone.js",
"~/Metronic/assets/layouts/layout3/scripts/jquery.datetimepicker.full.js",
"~/Scripts/custom.js"
@@ -76,6 +77,7 @@ Public Class BundleConfig
"~/Metronic/assets/layouts/global/scripts/quick-nav.min.js",
"~/Metronic/assets/admin/pages/scripts/table-advanced.js",
"~/Metronic/assets/admin/pages/scripts/ui-alert-dialog-api.js",
"~/Metronic/assets/global/plugins/icheck/icheck.min.js",
"~/Metronic/assets/global/plugins/dropzone/dropzone.js",
"~/Metronic/assets/layouts/layout3/scripts/jquery.datetimepicker.full.js",
"~/Scripts/custom.js"
@@ -198,6 +200,7 @@ Public Class BundleConfig
"~/Metronic/assets/global/plugins/datatables/extensions/Scroller/css/dataTables.scroller.min.css",
"~/Metronic/assets/global/plugins/datatables/extensions/ColReorder/css/dataTables.colReorder.min.css",
"~/Metronic/assets/global/plugins/datatables/plugins/bootstrap/dataTables.bootstrap.css",
"~/Metronic/assets/global/plugins/icheck/skins/all.css",
"~/Styles/thickbox.css",
"~/Metronic/assets/global/css/components.css",
"~/Metronic/assets/global/css/plugins.css",
@@ -221,6 +224,7 @@ Public Class BundleConfig
"~/Metronic/assets/global/plugins/datatables2/extensions/KeyTable/css/keyTable.dataTables.min.css",
"~/Metronic/assets/global/plugins/datatables/extensions/ColReorder/css/dataTables.colReorder.min.css",
"~/Metronic/assets/global/plugins/datatables/plugins/bootstrap/dataTables.bootstrap.css",
"~/Metronic/assets/global/plugins/icheck/skins/all.css",
"~/Styles/thickbox.css",
"~/Metronic/assets/global/css/components.css",
"~/Metronic/assets/global/css/plugins.css",

View File

@@ -4,7 +4,18 @@ Option Explicit On
Imports System.Data
Imports System.Data.SqlClient
Imports Extensiones
Public Enum OITipoEventos
Tarea = 1
Agenda = 2
Proyecto = 3
Control_de_Versiones_de_Doctos = 4
Minuta = 5
Bitacora = 6
Scrum = 7
ISO = 8
Soporte = 9
Gastos_Mes = 10
End Enum
Public Class ClsOIEventos
Implements IDisposable
@@ -171,7 +182,192 @@ Public Class ClsOIEventos
End Sub
#Region "oieventos2.0"
Public Function GetOI_Eventos2(cveEvento As Int32, CveEmpresa As Integer) As Boolean
Dim retorno As Boolean = False
DataAdapter("PA_GetOI_Eventos2", CommandType.StoredProcedure)
With SqlAdapter.SelectCommand.Parameters
.Add("@CveEvento", SqlDbType.Int).Value = cveEvento
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
End With
Try
SqlAdapter.Fill(Data)
retorno = True
Catch ex As Exception
OnError("Ocurrió un error al obtener el Catálogo de Eventos.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
End Try
Return retorno
End Function
Public Function AddOI_Eventos2(cveTipoEvento As OITipoEventos, asunto As String, descripcion As String, prioridad As Int32, cveUsuarioDe As Int32, cveUsuarioPara As Int32,
fechaInicio As String, fechaFin As String, cveRevision As Int32, archivo As String, cveUsuarioIng As Int32, cveEmpresa As Int32) As Boolean
Dim retorno As Boolean = False
DataAdapter("PA_AddOI_Eventos2", CommandType.StoredProcedure)
With SqlAdapter.SelectCommand.Parameters
.Add("@CveEvento", SqlDbType.Int).Direction = ParameterDirection.Output
.Add("@Folio", SqlDbType.Int).Direction = ParameterDirection.Output
.Add("@cveTipoEvento", SqlDbType.Int).Value = cveTipoEvento
.Add("@asunto", SqlDbType.VarChar).Value = asunto
.Add("@descripcion", SqlDbType.VarChar).Value = descripcion
.Add("@prioridad", SqlDbType.Int).Value = prioridad
.Add("@cveUsuarioDe", SqlDbType.Int).Value = cveUsuarioDe
.Add("@cveUsuarioPara", SqlDbType.Int).Value = cveUsuarioPara
.Add("@fechaInicio", SqlDbType.VarChar).Value = fechaInicio
.Add("@fechaFin", SqlDbType.VarChar).Value = fechaFin
.Add("@cveRevision", SqlDbType.Int).Value = cveRevision
.Add("@archivo", SqlDbType.VarChar).Value = archivo
.Add("@cveUsuarioIng", SqlDbType.Int).Value = cveUsuarioIng
.Add("@cveEmpresa", SqlDbType.Int).Value = cveEmpresa
End With
Try
SqlAdapter.Fill(Data)
CveEvento = SqlAdapter.SelectCommand.Parameters("@CveEvento").Value.ToString().ToEntero()
Folio = SqlAdapter.SelectCommand.Parameters("@Folio").Value.ToString().ToEntero()
retorno = True
Catch ex As Exception
OnError("Ocurrió un error al obtener el Catálogo de Eventos.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
End Try
Return retorno
End Function
Public Function UpdateEstatusEvento2(CveEventoEstatus As Integer, CveComentario As Integer, CveEvento As Integer, CveUsuario As Integer) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_OI_EventosEstatusUpdate2")
With SqlAdapter.SelectCommand.Parameters
.Add("@pCveEventoEstatus", SqlDbType.Int).Value = CveEventoEstatus
.Add("@pCveComentario", SqlDbType.Int).Value = CveComentario
.Add("@pCveEvento", SqlDbType.Int).Value = CveEvento
.Add("@pCveUsuario", SqlDbType.Int).Value = CveUsuario
End With
Try
SqlAdapter.Fill(Data)
Retorno = True
Catch ex As Exception
OnError("Ocurrió un error al actualizar el estatus en el Evento.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
End Try
Return Retorno
End Function
#Region "CRUD_cheklist"
Public Function Getcheklist(cveEvento As Int32) As Boolean
Dim retorno As Boolean = False
DataAdapter("PA_OI_cheklistGet", CommandType.StoredProcedure)
With SqlAdapter.SelectCommand.Parameters
.Add("@cveEvento", SqlDbType.Int).Value = cveEvento
End With
Try
SqlAdapter.Fill(Data)
retorno = True
Catch ex As Exception
OnError("Ocurrió un error al obtener el checklist.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
End Try
Return retorno
End Function
Public Function Addcheklist(cveEvento As Int32, eventoComentario As String, cveUsuario As Int32) As Boolean
Dim retorno As Boolean = False
DataAdapter("PA_OI_cheklistAdd", CommandType.StoredProcedure)
With SqlAdapter.SelectCommand.Parameters
.Add("@cveEvento", SqlDbType.Int).Value = cveEvento
.Add("@eventoComentario", SqlDbType.VarChar).Value = eventoComentario
.Add("@cveUsuario", SqlDbType.Int).Value = cveUsuario
End With
Try
SqlAdapter.Fill(Data)
retorno = True
Catch ex As Exception
OnError("Ocurrió un error al agregar el checklist.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
End Try
Return retorno
End Function
Public Function Upcheklist(cveEventoCheckList As Int32, cveEvento As Int32, eventoComentario As String, estatus As Boolean, cveUsuario As Int32) As Boolean
Dim retorno As Boolean = False
DataAdapter("PA_OI_cheklistUp", CommandType.StoredProcedure)
With SqlAdapter.SelectCommand.Parameters
.Add("@cveEventoCheckList", SqlDbType.Int).Value = cveEventoCheckList
.Add("@cveEvento", SqlDbType.Int).Value = cveEvento
.Add("@eventoComentario", SqlDbType.VarChar).Value = eventoComentario
.Add("@estatus", SqlDbType.Bit).Value = estatus
.Add("@cveUsuario", SqlDbType.Int).Value = cveUsuario
End With
Try
SqlAdapter.Fill(Data)
retorno = True
Catch ex As Exception
OnError("Ocurrió un error al actualizar el checklist.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
End Try
Return retorno
End Function
Public Function Removecheklist(cveEventoCheckList As Int32, cveEvento As Int32, cveUsuario As Int32) As Boolean
Dim retorno As Boolean = False
DataAdapter("PA_OI_cheklistRemove", CommandType.StoredProcedure)
With SqlAdapter.SelectCommand.Parameters
.Add("@cveEventoCheckList", SqlDbType.Int).Value = cveEventoCheckList
.Add("@cveEvento", SqlDbType.Int).Value = cveEvento
.Add("@cveUsuario", SqlDbType.Int).Value = cveUsuario
End With
Try
SqlAdapter.Fill(Data)
retorno = True
Catch ex As Exception
OnError("Ocurrió un error al eliminar el checklist.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
End Try
Return retorno
End Function
#End Region
Public Function AddUPEventoArchivo(CveEvento As Integer, Archivo As String, CveUsuario As Integer) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_OI_EventosArchivoAddUP")
With SqlAdapter.SelectCommand.Parameters
.Add("@CveEvento", SqlDbType.Int).Value = CveEvento
.Add("@Archivo", SqlDbType.VarChar).Value = Archivo
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
End With
Try
SqlAdapter.Fill(Data)
Retorno = True
Catch Ex1 As SqlException
Retorno = False
Me.OnError("Ocurrió un error al Guardar el comentario del evento.", Ex1, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
Catch ex As Exception
Retorno = False
OnError("Ocurrió un error al Guardar el Evento Comentario", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
End Try
Return Retorno
End Function
Public Function UPEventoAAvance(CveEvento As Integer, Avance As Decimal, CveUsuario As Integer) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_OI_EventosAvanceUP")
With SqlAdapter.SelectCommand.Parameters
.Add("@CveEvento", SqlDbType.Int).Value = CveEvento
.Add("@Avance", SqlDbType.Decimal).Value = Avance
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
End With
Try
SqlAdapter.Fill(Data)
Retorno = True
Catch Ex1 As SqlException
Retorno = False
Me.OnError("Ocurrió un error al Guardar el comentario del evento.", Ex1, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
Catch ex As Exception
Retorno = False
OnError("Ocurrió un error al Guardar el Evento Comentario", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
End Try
Return Retorno
End Function
#End Region

View File

@@ -4405,6 +4405,7 @@ Public Class ClsPaginas
'OI
#Region "OI"
PaginaDict.Add("/OI/EventoDetalle.aspx".ToUpper(), -1)
PaginaDict.Add("/OI/TareaDetalle.aspx".ToUpper(), -1)
PaginaDict.Add("/OI/Normatividad.aspx".ToUpper(), 669)
PaginaDict.Add("/OI/RepNormatividad.aspx".ToUpper(), 669)
PaginaDict.Add("/OI/Minutas.aspx".ToUpper(), -1)
@@ -5165,7 +5166,7 @@ Public Class ClsPaginas
For Each rpds As ReportDataSource In DataSource
Dim dt As DataTable = DirectCast(rpds.Value, Data.DataTable)
If dt Is Nothing Then
dt = New DataTable
dt = New DataTable()
Else
dt = dt.Copy()
End If

View File

@@ -569,6 +569,14 @@ Namespace Extensiones
Else
Return Nothing
End If
End Function
<Runtime.CompilerServices.Extension()>
Public Function ToDateTimeExcat(Str As String, Optional format As String = "dd/MM/yyyy HH:mm") As DateTime
Dim fecha As DateTime = New DateTime()
DateTime.TryParseExact(Str, format, System.Globalization.CultureInfo.InvariantCulture, System.Globalization.DateTimeStyles.None, fecha)
Return fecha
End Function
<Runtime.CompilerServices.Extension()>

View File

@@ -1,5 +1,5 @@
/* Ion.RangeSlider
// css version 1.9.2
// css version 2.0.3
// © 2013-2014 Denis Ineshin | IonDen.com
// ===================================================================================================================*/
@@ -8,62 +8,61 @@
.irs {
position: relative; display: block;
-webkit-touch-callout: none;
-webkit-user-select: none;
-khtml-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
}
.irs-line {
position: relative; display: block;
overflow: hidden;
outline: none !important;
}
.irs-line-left, .irs-line-mid, .irs-line-right {
position: absolute; display: block;
top: 0;
}
.irs-line-left {
left: 0; width: 10%;
left: 0; width: 11%;
}
.irs-line-mid {
left: 9%; width: 82%;
}
.irs-line-right {
right: 0; width: 10%;
right: 0; width: 11%;
}
.irs-diapason {
.irs-bar {
position: absolute; display: block;
left: 0; width: 100%;
left: 0; width: 0;
}
.irs-bar-edge {
position: absolute; display: block;
top: 0; left: 0;
}
.irs-shadow {
position: absolute; display: none;
left: 0; width: 0;
}
.irs-slider {
position: absolute; display: block;
cursor: default;
z-index: 1;
}
.irs-slider.single {
left: 10px;
}
.irs-slider.single:before {
position: absolute; display: block; content: "";
top: -30%; left: -30%;
width: 160%; height: 160%;
background: rgba(0,0,0,0.0);
}
.irs-slider.from {
left: 100px;
}
.irs-slider.from:before {
position: absolute; display: block; content: "";
top: -30%; left: -30%;
width: 130%; height: 160%;
background: rgba(0,0,0,0.0);
}
.irs-slider.to {
left: 300px;
}
.irs-slider.to:before {
position: absolute; display: block; content: "";
top: -30%; left: 0;
width: 130%; height: 160%;
background: rgba(0,0,0,0.0);
}
.irs-slider.last {
.irs-slider.type_last {
z-index: 2;
}
@@ -85,7 +84,6 @@
white-space: nowrap;
}
.irs-grid {
position: absolute; display: none;
bottom: 0; left: 0;
@@ -106,17 +104,17 @@
.irs-grid-text {
position: absolute;
bottom: 0; left: 0;
width: 100px;
white-space: nowrap;
text-align: center;
font-size: 9px; line-height: 9px;
padding: 0 3px;
color: #000;
}
.irs-disable-mask {
position: absolute; display: block;
top: 0; left: 0;
width: 100%; height: 100%;
top: 0; left: -1%;
width: 102%; height: 100%;
cursor: default;
background: rgba(0,0,0,0.0);
z-index: 2;
@@ -124,3 +122,25 @@
.irs-disabled {
opacity: 0.4;
}
.lt-ie9 .irs-disabled {
filter: alpha(opacity=40);
}
.irs-hidden-input {
position: absolute !important;
display: block !important;
top: 0 !important;
left: 0 !important;
width: 0 !important;
height: 0 !important;
font-size: 0 !important;
line-height: 0 !important;
padding: 0 !important;
margin: 0 !important;
outline: none !important;
z-index: -9999 !important;
background: none !important;
border-style: solid !important;
border-color: transparent !important;
}

View File

@@ -1,6 +1,6 @@
/* Ion.RangeSlider, Flat UI Skin
// css version 1.9.2
// © 2013-2014 Denis Ineshin | IonDen.com
// css version 2.0.3
// © Denis Ineshin, 2014 https://github.com/IonDen
// ===================================================================================================================*/
/* =====================================================================================================================
@@ -9,7 +9,8 @@
.irs-line-mid,
.irs-line-left,
.irs-line-right,
.irs-diapason,
.irs-bar,
.irs-bar-edge,
.irs-slider {
background: url(../img/sprite-skin-flat.png) repeat-x;
}
@@ -36,19 +37,33 @@
background-position: 100% -30px;
}
.irs-diapason {
.irs-bar {
height: 12px; top: 25px;
background-position: 0 -60px;
}
.irs-bar-edge {
top: 25px;
height: 12px; width: 9px;
background-position: 0 -90px;
}
.irs-shadow {
height: 3px; top: 34px;
background: #000;
opacity: 0.25;
}
.lt-ie9 .irs-shadow {
filter: alpha(opacity=25);
}
.irs-slider {
width: 16px; height: 18px;
top: 22px;
background-position: 0 -90px;
}
#irs-active-slider, .irs-slider:hover {
background-position: 0 -120px;
}
.irs-slider.state_hover, .irs-slider:hover {
background-position: 0 -150px;
}
.irs-min, .irs-max {
color: #999;
@@ -56,6 +71,7 @@
text-shadow: none;
top: 0; padding: 1px 3px;
background: #e1e4e9;
-moz-border-radius: 4px;
border-radius: 4px;
}
@@ -65,6 +81,7 @@
text-shadow: none;
padding: 1px 5px;
background: #ed5565;
-moz-border-radius: 4px;
border-radius: 4px;
}
.irs-from:after, .irs-to:after, .irs-single:after {

View File

@@ -0,0 +1,124 @@
/* Ion.RangeSlider, Simple Skin
// css version 2.0.3
// © Denis Ineshin, 2014 https://github.com/IonDen
// © guybowden, 2014 https://github.com/guybowden
// ===================================================================================================================*/
/* =====================================================================================================================
// Skin details */
.irs {
height: 55px;
}
.irs-with-grid {
height: 75px;
}
.irs-line {
height: 10px; top: 33px;
background: #EEE;
background: linear-gradient(to bottom, #DDD -50%, #FFF 150%); /* W3C */
border: 1px solid #CCC;
border-radius: 16px;
-moz-border-radius: 16px;
}
.irs-line-left {
height: 8px;
}
.irs-line-mid {
height: 8px;
}
.irs-line-right {
height: 8px;
}
.irs-bar {
height: 10px; top: 33px;
border-top: 1px solid #428bca;
border-bottom: 1px solid #428bca;
background: #428bca;
background: linear-gradient(to top, rgba(66,139,202,1) 0%,rgba(127,195,232,1) 100%); /* W3C */
}
.irs-bar-edge {
height: 10px; top: 33px;
width: 14px;
border: 1px solid #428bca;
border-right: 0;
background: #428bca;
background: linear-gradient(to top, rgba(66,139,202,1) 0%,rgba(127,195,232,1) 100%); /* W3C */
border-radius: 16px 0 0 16px;
-moz-border-radius: 16px 0 0 16px;
}
.irs-shadow {
height: 2px; top: 38px;
background: #000;
opacity: 0.3;
border-radius: 5px;
-moz-border-radius: 5px;
}
.lt-ie9 .irs-shadow {
filter: alpha(opacity=30);
}
.irs-slider {
top: 25px;
width: 27px; height: 27px;
border: 1px solid #AAA;
background: #DDD;
background: linear-gradient(to bottom, rgba(255,255,255,1) 0%,rgba(220,220,220,1) 20%,rgba(255,255,255,1) 100%); /* W3C */
border-radius: 27px;
-moz-border-radius: 27px;
box-shadow: 1px 1px 3px rgba(0,0,0,0.3);
cursor: pointer;
}
.irs-slider.state_hover, .irs-slider:hover {
background: #FFF;
}
.irs-min, .irs-max {
color: #333;
font-size: 12px; line-height: 1.333;
text-shadow: none;
top: 0;
padding: 1px 5px;
background: rgba(0,0,0,0.1);
border-radius: 3px;
-moz-border-radius: 3px;
}
.lt-ie9 .irs-min, .lt-ie9 .irs-max {
background: #ccc;
}
.irs-from, .irs-to, .irs-single {
color: #fff;
font-size: 14px; line-height: 1.333;
text-shadow: none;
padding: 1px 5px;
background: #428bca;
border-radius: 3px;
-moz-border-radius: 3px;
}
.lt-ie9 .irs-from, .lt-ie9 .irs-to, .lt-ie9 .irs-single {
background: #999;
}
.irs-grid {
height: 27px;
}
.irs-grid-pol {
opacity: 0.5;
background: #428bca;
}
.irs-grid-pol.small {
background: #999;
}
.irs-grid-text {
bottom: 5px;
color: #99a4ac;
}
.irs-disabled {
}

View File

@@ -0,0 +1,116 @@
/* Ion.RangeSlider, Modern Skin
// css version 2.0.3
// © Denis Ineshin, 2014 https://github.com/IonDen
// ===================================================================================================================*/
/* =====================================================================================================================
// Skin details */
.irs-line-mid,
.irs-line-left,
.irs-line-right,
.irs-bar,
.irs-bar-edge,
.irs-slider {
background: url(../img/sprite-skin-modern.png) repeat-x;
}
.irs {
height: 50px;
}
.irs-with-grid {
height: 70px;
}
.irs-line {
height: 6px; top: 25px;
}
.irs-line-left {
height: 6px;
background-position: 0 -30px;
}
.irs-line-mid {
height: 6px;
background-position: 0 0;
}
.irs-line-right {
height: 6px;
background-position: 100% -30px;
}
.irs-bar {
height: 6px; top: 25px;
background-position: 0 -60px;
}
.irs-bar-edge {
top: 25px;
height: 6px; width: 6px;
background-position: 0 -90px;
}
.irs-shadow {
height: 5px; top: 25px;
background: #000;
opacity: 0.25;
}
.lt-ie9 .irs-shadow {
filter: alpha(opacity=25);
}
.irs-slider {
width: 11px; height: 18px;
top: 31px;
background-position: 0 -120px;
}
.irs-slider.state_hover, .irs-slider:hover {
background-position: 0 -150px;
}
.irs-min, .irs-max {
color: #999;
font-size: 10px; line-height: 1.333;
text-shadow: none;
top: 0; padding: 1px 3px;
background: #e1e4e9;
-moz-border-radius: 4px;
border-radius: 4px;
}
.irs-from, .irs-to, .irs-single {
color: #fff;
font-size: 10px; line-height: 1.333;
text-shadow: none;
padding: 1px 5px;
background: #20b426;
-moz-border-radius: 4px;
border-radius: 4px;
}
.irs-from:after, .irs-to:after, .irs-single:after {
position: absolute; display: block; content: "";
bottom: -6px; left: 50%;
width: 0; height: 0;
margin-left: -3px;
overflow: hidden;
border: 3px solid transparent;
border-top-color: #20b426;
}
.irs-grid {
height: 34px;
}
.irs-grid-pol {
background: #c0c0c0;
}
.irs-grid-text {
bottom: 12px;
color: #c0c0c0;
}
.irs-disable-mask {
}
.irs-disabled {
}
.lt-ie9 .irs-disabled {
}

View File

@@ -1,6 +1,6 @@
/* Ion.RangeSlider, Nice Skin
// css version 1.9.2
// © 2013-2014 Denis Ineshin | IonDen.com
// css version 2.0.3
// © Denis Ineshin, 2014 https://github.com/IonDen
// ===================================================================================================================*/
/* =====================================================================================================================
@@ -9,7 +9,8 @@
.irs-line-mid,
.irs-line-left,
.irs-line-right,
.irs-diapason,
.irs-bar,
.irs-bar-edge,
.irs-slider {
background: url(../img/sprite-skin-nice.png) repeat-x;
}
@@ -36,19 +37,33 @@
background-position: 100% -30px;
}
.irs-diapason {
.irs-bar {
height: 8px; top: 25px;
background-position: 0 -60px;
}
.irs-bar-edge {
top: 25px;
height: 8px; width: 11px;
background-position: 0 -90px;
}
.irs-shadow {
height: 1px; top: 34px;
background: #000;
opacity: 0.15;
}
.lt-ie9 .irs-shadow {
filter: alpha(opacity=15);
}
.irs-slider {
width: 22px; height: 22px;
top: 17px;
background-position: 0 -90px;
}
#irs-active-slider, .irs-slider:hover {
background-position: 0 -120px;
}
.irs-slider.state_hover, .irs-slider:hover {
background-position: 0 -150px;
}
.irs-min, .irs-max {
color: #999;
@@ -56,6 +71,7 @@
text-shadow: none;
top: 0; padding: 1px 3px;
background: rgba(0,0,0,0.1);
-moz-border-radius: 3px;
border-radius: 3px;
}
.lt-ie9 .irs-min, .lt-ie9 .irs-max {
@@ -68,6 +84,7 @@
text-shadow: none;
padding: 1px 5px;
background: rgba(0,0,0,0.3);
-moz-border-radius: 3px;
border-radius: 3px;
}
.lt-ie9 .irs-from, .lt-ie9 .irs-to, .lt-ie9 .irs-single {

View File

@@ -1,6 +1,6 @@
/* Ion.RangeSlider, Simple Skin
// css version 1.9.2
// © 2013-2014 Denis Ineshin | IonDen.com
// css version 2.0.3
// © Denis Ineshin, 2014 https://github.com/IonDen
// ===================================================================================================================*/
/* =====================================================================================================================
@@ -9,7 +9,8 @@
.irs-line-mid,
.irs-line-left,
.irs-line-right,
.irs-diapason,
.irs-bar,
.irs-bar-edge,
.irs-slider {
background: url(../img/sprite-skin-simple.png) repeat-x;
}
@@ -36,19 +37,33 @@
background-position: 100% -30px;
}
.irs-diapason {
.irs-bar {
height: 6px; top: 25px;
background-position: 0 -60px;
}
.irs-bar-edge {
top: 25px;
height: 6px; width: 7px;
background-position: 0 -90px;
}
.irs-shadow {
height: 1px; top: 34px;
background: #000;
opacity: 0.75;
}
.lt-ie9 .irs-shadow {
filter: alpha(opacity=75);
}
.irs-slider {
width: 8px; height: 15px;
top: 21px;
background-position: 0 -90px;
}
#irs-active-slider, .irs-slider:hover {
background-position: 0 -120px;
}
.irs-slider.state_hover, .irs-slider:hover {
background-position: 0 -150px;
}
.irs-min, .irs-max {
color: #c0c0c0;
@@ -56,6 +71,7 @@
text-shadow: none;
top: 0; padding: 1px 3px;
background: rgba(0,0,0,0.1);
-moz-border-radius: 3px;
border-radius: 3px;
}
.lt-ie9 .irs-min, .lt-ie9 .irs-max {
@@ -68,6 +84,7 @@
text-shadow: none;
padding: 1px 5px;
background: rgba(255,255,255,0.8);
-moz-border-radius: 3px;
border-radius: 3px;
}
.lt-ie9 .irs-from, .lt-ie9 .irs-to, .lt-ie9 .irs-single {

View File

@@ -0,0 +1,427 @@
/*! normalize.css v3.0.2 | MIT License | git.io/normalize */
/**
* 1. Set default font family to sans-serif.
* 2. Prevent iOS text size adjust after orientation change, without disabling
* user zoom.
*/
html {
font-family: sans-serif; /* 1 */
-ms-text-size-adjust: 100%; /* 2 */
-webkit-text-size-adjust: 100%; /* 2 */
}
/**
* Remove default margin.
*/
body {
margin: 0;
}
/* HTML5 display definitions
========================================================================== */
/**
* Correct `block` display not defined for any HTML5 element in IE 8/9.
* Correct `block` display not defined for `details` or `summary` in IE 10/11
* and Firefox.
* Correct `block` display not defined for `main` in IE 11.
*/
article,
aside,
details,
figcaption,
figure,
footer,
header,
hgroup,
main,
menu,
nav,
section,
summary {
display: block;
}
/**
* 1. Correct `inline-block` display not defined in IE 8/9.
* 2. Normalize vertical alignment of `progress` in Chrome, Firefox, and Opera.
*/
audio,
canvas,
progress,
video {
display: inline-block; /* 1 */
vertical-align: baseline; /* 2 */
}
/**
* Prevent modern browsers from displaying `audio` without controls.
* Remove excess height in iOS 5 devices.
*/
audio:not([controls]) {
display: none;
height: 0;
}
/**
* Address `[hidden]` styling not present in IE 8/9/10.
* Hide the `template` element in IE 8/9/11, Safari, and Firefox < 22.
*/
[hidden],
template {
display: none;
}
/* Links
========================================================================== */
/**
* Remove the gray background color from active links in IE 10.
*/
a {
background-color: transparent;
}
/**
* Improve readability when focused and also mouse hovered in all browsers.
*/
a:active,
a:hover {
outline: 0;
}
/* Text-level semantics
========================================================================== */
/**
* Address styling not present in IE 8/9/10/11, Safari, and Chrome.
*/
abbr[title] {
border-bottom: 1px dotted;
}
/**
* Address style set to `bolder` in Firefox 4+, Safari, and Chrome.
*/
b,
strong {
font-weight: bold;
}
/**
* Address styling not present in Safari and Chrome.
*/
dfn {
font-style: italic;
}
/**
* Address variable `h1` font-size and margin within `section` and `article`
* contexts in Firefox 4+, Safari, and Chrome.
*/
h1 {
font-size: 2em;
margin: 0.67em 0;
}
/**
* Address styling not present in IE 8/9.
*/
mark {
background: #ff0;
color: #000;
}
/**
* Address inconsistent and variable font size in all browsers.
*/
small {
font-size: 80%;
}
/**
* Prevent `sub` and `sup` affecting `line-height` in all browsers.
*/
sub,
sup {
font-size: 75%;
line-height: 0;
position: relative;
vertical-align: baseline;
}
sup {
top: -0.5em;
}
sub {
bottom: -0.25em;
}
/* Embedded content
========================================================================== */
/**
* Remove border when inside `a` element in IE 8/9/10.
*/
img {
border: 0;
}
/**
* Correct overflow not hidden in IE 9/10/11.
*/
svg:not(:root) {
overflow: hidden;
}
/* Grouping content
========================================================================== */
/**
* Address margin not present in IE 8/9 and Safari.
*/
figure {
margin: 1em 40px;
}
/**
* Address differences between Firefox and other browsers.
*/
hr {
-moz-box-sizing: content-box;
box-sizing: content-box;
height: 0;
}
/**
* Contain overflow in all browsers.
*/
pre {
overflow: auto;
}
/**
* Address odd `em`-unit font size rendering in all browsers.
*/
code,
kbd,
pre,
samp {
font-family: monospace, monospace;
font-size: 1em;
}
/* Forms
========================================================================== */
/**
* Known limitation: by default, Chrome and Safari on OS X allow very limited
* styling of `select`, unless a `border` property is set.
*/
/**
* 1. Correct color not being inherited.
* Known issue: affects color of disabled elements.
* 2. Correct font properties not being inherited.
* 3. Address margins set differently in Firefox 4+, Safari, and Chrome.
*/
button,
input,
optgroup,
select,
textarea {
color: inherit; /* 1 */
font: inherit; /* 2 */
margin: 0; /* 3 */
}
/**
* Address `overflow` set to `hidden` in IE 8/9/10/11.
*/
button {
overflow: visible;
}
/**
* Address inconsistent `text-transform` inheritance for `button` and `select`.
* All other form control elements do not inherit `text-transform` values.
* Correct `button` style inheritance in Firefox, IE 8/9/10/11, and Opera.
* Correct `select` style inheritance in Firefox.
*/
button,
select {
text-transform: none;
}
/**
* 1. Avoid the WebKit bug in Android 4.0.* where (2) destroys native `audio`
* and `video` controls.
* 2. Correct inability to style clickable `input` types in iOS.
* 3. Improve usability and consistency of cursor style between image-type
* `input` and others.
*/
button,
html input[type="button"], /* 1 */
input[type="reset"],
input[type="submit"] {
-webkit-appearance: button; /* 2 */
cursor: pointer; /* 3 */
}
/**
* Re-set default cursor for disabled elements.
*/
button[disabled],
html input[disabled] {
cursor: default;
}
/**
* Remove inner padding and border in Firefox 4+.
*/
button::-moz-focus-inner,
input::-moz-focus-inner {
border: 0;
padding: 0;
}
/**
* Address Firefox 4+ setting `line-height` on `input` using `!important` in
* the UA stylesheet.
*/
input {
line-height: normal;
}
/**
* It's recommended that you don't attempt to style these elements.
* Firefox's implementation doesn't respect box-sizing, padding, or width.
*
* 1. Address box sizing set to `content-box` in IE 8/9/10.
* 2. Remove excess padding in IE 8/9/10.
*/
input[type="checkbox"],
input[type="radio"] {
box-sizing: border-box; /* 1 */
padding: 0; /* 2 */
}
/**
* Fix the cursor style for Chrome's increment/decrement buttons. For certain
* `font-size` values of the `input`, it causes the cursor style of the
* decrement button to change from `default` to `text`.
*/
input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button {
height: auto;
}
/**
* 1. Address `appearance` set to `searchfield` in Safari and Chrome.
* 2. Address `box-sizing` set to `border-box` in Safari and Chrome
* (include `-moz` to future-proof).
*/
input[type="search"] {
-webkit-appearance: textfield; /* 1 */
-moz-box-sizing: content-box;
-webkit-box-sizing: content-box; /* 2 */
box-sizing: content-box;
}
/**
* Remove inner padding and search cancel button in Safari and Chrome on OS X.
* Safari (but not Chrome) clips the cancel button when the search input has
* padding (and `textfield` appearance).
*/
input[type="search"]::-webkit-search-cancel-button,
input[type="search"]::-webkit-search-decoration {
-webkit-appearance: none;
}
/**
* Define consistent border, margin, and padding.
*/
fieldset {
border: 1px solid #c0c0c0;
margin: 0 2px;
padding: 0.35em 0.625em 0.75em;
}
/**
* 1. Correct `color` not being inherited in IE 8/9/10/11.
* 2. Remove padding so people aren't caught out if they zero out fieldsets.
*/
legend {
border: 0; /* 1 */
padding: 0; /* 2 */
}
/**
* Remove default vertical scrollbar in IE 8/9/10/11.
*/
textarea {
overflow: auto;
}
/**
* Don't inherit the `font-weight` (applied by a rule above).
* NOTE: the default cannot safely be changed in Chrome and Safari on OS X.
*/
optgroup {
font-weight: bold;
}
/* Tables
========================================================================== */
/**
* Remove most spacing between table cells.
*/
table {
border-collapse: collapse;
border-spacing: 0;
}
td,
th {
padding: 0;
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 352 B

After

Width:  |  Height:  |  Size: 304 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 505 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1022 B

After

Width:  |  Height:  |  Size: 694 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 385 B

After

Width:  |  Height:  |  Size: 358 B

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,71 @@
// Ion.RangeSlider | version 2.0.13 | https://github.com/IonDen/ion.rangeSlider
;(function(e,r,h,t,v){var u=0,p=function(){var a=t.userAgent,b=/msie\s\d+/i;return 0<a.search(b)&&(a=b.exec(a).toString(),a=a.split(" ")[1],9>a)?(e("html").addClass("lt-ie9"),!0):!1}();Function.prototype.bind||(Function.prototype.bind=function(a){var b=this,c=[].slice;if("function"!=typeof b)throw new TypeError;var d=c.call(arguments,1),f=function(){if(this instanceof f){var g=function(){};g.prototype=b.prototype;var g=new g,l=b.apply(g,d.concat(c.call(arguments)));return Object(l)===l?l:g}return b.apply(a,
d.concat(c.call(arguments)))};return f});Array.prototype.indexOf||(Array.prototype.indexOf=function(a,b){var c;if(null==this)throw new TypeError('"this" is null or not defined');var d=Object(this),f=d.length>>>0;if(0===f)return-1;c=+b||0;Infinity===Math.abs(c)&&(c=0);if(c>=f)return-1;for(c=Math.max(0<=c?c:f-Math.abs(c),0);c<f;){if(c in d&&d[c]===a)return c;c++}return-1});var q=function(a,b,c){this.VERSION="2.0.13";this.input=a;this.plugin_count=c;this.old_to=this.old_from=this.update_tm=this.calc_count=
this.current_plugin=0;this.raf_id=null;this.is_update=this.is_key=this.force_redraw=this.dragging=!1;this.is_start=!0;this.is_click=this.is_resize=this.is_active=this.is_finish=!1;this.$cache={win:e(h),body:e(r.body),input:e(a),cont:null,rs:null,min:null,max:null,from:null,to:null,single:null,bar:null,line:null,s_single:null,s_from:null,s_to:null,shad_single:null,shad_from:null,shad_to:null,edge:null,grid:null,grid_labels:[]};c=this.$cache.input;a={type:c.data("type"),min:c.data("min"),max:c.data("max"),
from:c.data("from"),to:c.data("to"),step:c.data("step"),min_interval:c.data("minInterval"),max_interval:c.data("maxInterval"),drag_interval:c.data("dragInterval"),values:c.data("values"),from_fixed:c.data("fromFixed"),from_min:c.data("fromMin"),from_max:c.data("fromMax"),from_shadow:c.data("fromShadow"),to_fixed:c.data("toFixed"),to_min:c.data("toMin"),to_max:c.data("toMax"),to_shadow:c.data("toShadow"),prettify_enabled:c.data("prettifyEnabled"),prettify_separator:c.data("prettifySeparator"),force_edges:c.data("forceEdges"),
keyboard:c.data("keyboard"),keyboard_step:c.data("keyboardStep"),grid:c.data("grid"),grid_margin:c.data("gridMargin"),grid_num:c.data("gridNum"),grid_snap:c.data("gridSnap"),hide_min_max:c.data("hideMinMax"),hide_from_to:c.data("hideFromTo"),prefix:c.data("prefix"),postfix:c.data("postfix"),max_postfix:c.data("maxPostfix"),decorate_both:c.data("decorateBoth"),values_separator:c.data("valuesSeparator"),disable:c.data("disable")};a.values=a.values&&a.values.split(",");if(c=c.prop("value"))c=c.split(";"),
c[0]&&c[0]==+c[0]&&(c[0]=+c[0]),c[1]&&c[1]==+c[1]&&(c[1]=+c[1]),b&&b.values&&b.values.length?(a.from=c[0]&&b.values.indexOf(c[0]),a.to=c[1]&&b.values.indexOf(c[1])):(a.from=c[0]&&+c[0],a.to=c[1]&&+c[1]);b=e.extend(a,b);this.options=e.extend({type:"single",min:10,max:100,from:null,to:null,step:1,min_interval:0,max_interval:0,drag_interval:!1,values:[],p_values:[],from_fixed:!1,from_min:null,from_max:null,from_shadow:!1,to_fixed:!1,to_min:null,to_max:null,to_shadow:!1,prettify_enabled:!0,prettify_separator:" ",
prettify:null,force_edges:!1,keyboard:!1,keyboard_step:5,grid:!1,grid_margin:!0,grid_num:4,grid_snap:!1,hide_min_max:!1,hide_from_to:!1,prefix:"",postfix:"",max_postfix:"",decorate_both:!0,values_separator:" \u2014 ",disable:!1,onStart:null,onChange:null,onFinish:null,onUpdate:null},b);this.validate();this.result={input:this.$cache.input,slider:null,min:this.options.min,max:this.options.max,from:this.options.from,from_percent:0,from_value:null,to:this.options.to,to_percent:0,to_value:null};this.coords=
{x_gap:0,x_pointer:0,w_rs:0,w_rs_old:0,w_handle:0,p_gap:0,p_gap_left:0,p_gap_right:0,p_step:0,p_pointer:0,p_handle:0,p_single:0,p_single_real:0,p_from:0,p_from_real:0,p_to:0,p_to_real:0,p_bar_x:0,p_bar_w:0,grid_gap:0,big_num:0,big:[],big_w:[],big_p:[],big_x:[]};this.labels={w_min:0,w_max:0,w_from:0,w_to:0,w_single:0,p_min:0,p_max:0,p_from:0,p_from_left:0,p_to:0,p_to_left:0,p_single:0,p_single_left:0};this.init()};q.prototype={init:function(a){this.coords.p_step=this.options.step/((this.options.max-
this.options.min)/100);this.target="base";this.toggleInput();this.append();this.setMinMax();a?(this.force_redraw=!0,this.calc(!0),this.callOnUpdate()):(this.force_redraw=!0,this.calc(!0),this.callOnStart());this.updateScene()},append:function(){this.$cache.input.before('<span class="irs js-irs-'+this.plugin_count+'"></span>');this.$cache.input.prop("readonly",!0);this.$cache.cont=this.$cache.input.prev();this.result.slider=this.$cache.cont;this.$cache.cont.html('<span class="irs"><span class="irs-line" tabindex="-1"><span class="irs-line-left"></span><span class="irs-line-mid"></span><span class="irs-line-right"></span></span><span class="irs-min">0</span><span class="irs-max">1</span><span class="irs-from">0</span><span class="irs-to">0</span><span class="irs-single">0</span></span><span class="irs-grid"></span><span class="irs-bar"></span>');
this.$cache.rs=this.$cache.cont.find(".irs");this.$cache.min=this.$cache.cont.find(".irs-min");this.$cache.max=this.$cache.cont.find(".irs-max");this.$cache.from=this.$cache.cont.find(".irs-from");this.$cache.to=this.$cache.cont.find(".irs-to");this.$cache.single=this.$cache.cont.find(".irs-single");this.$cache.bar=this.$cache.cont.find(".irs-bar");this.$cache.line=this.$cache.cont.find(".irs-line");this.$cache.grid=this.$cache.cont.find(".irs-grid");"single"===this.options.type?(this.$cache.cont.append('<span class="irs-bar-edge"></span><span class="irs-shadow shadow-single"></span><span class="irs-slider single"></span>'),
this.$cache.edge=this.$cache.cont.find(".irs-bar-edge"),this.$cache.s_single=this.$cache.cont.find(".single"),this.$cache.from[0].style.visibility="hidden",this.$cache.to[0].style.visibility="hidden",this.$cache.shad_single=this.$cache.cont.find(".shadow-single")):(this.$cache.cont.append('<span class="irs-shadow shadow-from"></span><span class="irs-shadow shadow-to"></span><span class="irs-slider from"></span><span class="irs-slider to"></span>'),this.$cache.s_from=this.$cache.cont.find(".from"),
this.$cache.s_to=this.$cache.cont.find(".to"),this.$cache.shad_from=this.$cache.cont.find(".shadow-from"),this.$cache.shad_to=this.$cache.cont.find(".shadow-to"),this.setTopHandler());this.options.hide_from_to&&(this.$cache.from[0].style.display="none",this.$cache.to[0].style.display="none",this.$cache.single[0].style.display="none");this.appendGrid();this.options.disable?(this.appendDisableMask(),this.$cache.input[0].disabled=!0):(this.$cache.cont.removeClass("irs-disabled"),this.$cache.input[0].disabled=
!1,this.bindEvents())},setTopHandler:function(){var a=this.options.max,b=this.options.to;this.options.from>this.options.min&&b===a?this.$cache.s_from.addClass("type_last"):b<a&&this.$cache.s_to.addClass("type_last")},appendDisableMask:function(){this.$cache.cont.append('<span class="irs-disable-mask"></span>');this.$cache.cont.addClass("irs-disabled")},remove:function(){this.$cache.cont.remove();this.$cache.cont=null;this.$cache.line.off("keydown.irs_"+this.plugin_count);this.$cache.body.off("touchmove.irs_"+
this.plugin_count);this.$cache.body.off("mousemove.irs_"+this.plugin_count);this.$cache.win.off("touchend.irs_"+this.plugin_count);this.$cache.win.off("mouseup.irs_"+this.plugin_count);p&&(this.$cache.body.off("mouseup.irs_"+this.plugin_count),this.$cache.body.off("mouseleave.irs_"+this.plugin_count));this.$cache.grid_labels=[];this.coords.big=[];this.coords.big_w=[];this.coords.big_p=[];this.coords.big_x=[];cancelAnimationFrame(this.raf_id)},bindEvents:function(){this.$cache.body.on("touchmove.irs_"+
this.plugin_count,this.pointerMove.bind(this));this.$cache.body.on("mousemove.irs_"+this.plugin_count,this.pointerMove.bind(this));this.$cache.win.on("touchend.irs_"+this.plugin_count,this.pointerUp.bind(this));this.$cache.win.on("mouseup.irs_"+this.plugin_count,this.pointerUp.bind(this));this.$cache.line.on("touchstart.irs_"+this.plugin_count,this.pointerClick.bind(this,"click"));this.$cache.line.on("mousedown.irs_"+this.plugin_count,this.pointerClick.bind(this,"click"));this.options.drag_interval&&
"double"===this.options.type?(this.$cache.bar.on("touchstart.irs_"+this.plugin_count,this.pointerDown.bind(this,"both")),this.$cache.bar.on("mousedown.irs_"+this.plugin_count,this.pointerDown.bind(this,"both"))):(this.$cache.bar.on("touchstart.irs_"+this.plugin_count,this.pointerClick.bind(this,"click")),this.$cache.bar.on("mousedown.irs_"+this.plugin_count,this.pointerClick.bind(this,"click")));"single"===this.options.type?(this.$cache.single.on("touchstart.irs_"+this.plugin_count,this.pointerDown.bind(this,
"single")),this.$cache.s_single.on("touchstart.irs_"+this.plugin_count,this.pointerDown.bind(this,"single")),this.$cache.shad_single.on("touchstart.irs_"+this.plugin_count,this.pointerClick.bind(this,"click")),this.$cache.single.on("mousedown.irs_"+this.plugin_count,this.pointerDown.bind(this,"single")),this.$cache.s_single.on("mousedown.irs_"+this.plugin_count,this.pointerDown.bind(this,"single")),this.$cache.edge.on("mousedown.irs_"+this.plugin_count,this.pointerClick.bind(this,"click")),this.$cache.shad_single.on("mousedown.irs_"+
this.plugin_count,this.pointerClick.bind(this,"click"))):(this.$cache.single.on("touchstart.irs_"+this.plugin_count,this.pointerDown.bind(this,"from")),this.$cache.single.on("mousedown.irs_"+this.plugin_count,this.pointerDown.bind(this,"from")),this.$cache.from.on("touchstart.irs_"+this.plugin_count,this.pointerDown.bind(this,"from")),this.$cache.s_from.on("touchstart.irs_"+this.plugin_count,this.pointerDown.bind(this,"from")),this.$cache.to.on("touchstart.irs_"+this.plugin_count,this.pointerDown.bind(this,
"to")),this.$cache.s_to.on("touchstart.irs_"+this.plugin_count,this.pointerDown.bind(this,"to")),this.$cache.shad_from.on("touchstart.irs_"+this.plugin_count,this.pointerClick.bind(this,"click")),this.$cache.shad_to.on("touchstart.irs_"+this.plugin_count,this.pointerClick.bind(this,"click")),this.$cache.from.on("mousedown.irs_"+this.plugin_count,this.pointerDown.bind(this,"from")),this.$cache.s_from.on("mousedown.irs_"+this.plugin_count,this.pointerDown.bind(this,"from")),this.$cache.to.on("mousedown.irs_"+
this.plugin_count,this.pointerDown.bind(this,"to")),this.$cache.s_to.on("mousedown.irs_"+this.plugin_count,this.pointerDown.bind(this,"to")),this.$cache.shad_from.on("mousedown.irs_"+this.plugin_count,this.pointerClick.bind(this,"click")),this.$cache.shad_to.on("mousedown.irs_"+this.plugin_count,this.pointerClick.bind(this,"click")));if(this.options.keyboard)this.$cache.line.on("keydown.irs_"+this.plugin_count,this.key.bind(this,"keyboard"));p&&(this.$cache.body.on("mouseup.irs_"+this.plugin_count,
this.pointerUp.bind(this)),this.$cache.body.on("mouseleave.irs_"+this.plugin_count,this.pointerUp.bind(this)))},pointerMove:function(a){this.dragging&&(this.coords.x_pointer=(a.pageX||a.originalEvent.touches&&a.originalEvent.touches[0].pageX)-this.coords.x_gap,this.calc())},pointerUp:function(a){if(this.current_plugin===this.plugin_count&&this.is_active){this.is_active=!1;if(e.contains(this.$cache.cont[0],a.target)||this.dragging)this.is_finish=!0,this.callOnFinish();this.$cache.cont.find(".state_hover").removeClass("state_hover");
this.force_redraw=!0;this.dragging=!1;p&&e("*").prop("unselectable",!1);this.updateScene()}},changeLevel:function(a){switch(a){case "single":this.coords.p_gap=this.toFixed(this.coords.p_pointer-this.coords.p_single);break;case "from":this.coords.p_gap=this.toFixed(this.coords.p_pointer-this.coords.p_from);this.$cache.s_from.addClass("state_hover");this.$cache.s_from.addClass("type_last");this.$cache.s_to.removeClass("type_last");break;case "to":this.coords.p_gap=this.toFixed(this.coords.p_pointer-
this.coords.p_to);this.$cache.s_to.addClass("state_hover");this.$cache.s_to.addClass("type_last");this.$cache.s_from.removeClass("type_last");break;case "both":this.coords.p_gap_left=this.toFixed(this.coords.p_pointer-this.coords.p_from),this.coords.p_gap_right=this.toFixed(this.coords.p_to-this.coords.p_pointer),this.$cache.s_to.removeClass("type_last"),this.$cache.s_from.removeClass("type_last")}},pointerDown:function(a,b){b.preventDefault();var c=b.pageX||b.originalEvent.touches&&b.originalEvent.touches[0].pageX;
2!==b.button&&(this.current_plugin=this.plugin_count,this.target=a,this.dragging=this.is_active=!0,this.coords.x_gap=this.$cache.rs.offset().left,this.coords.x_pointer=c-this.coords.x_gap,this.calcPointer(),this.changeLevel(a),p&&e("*").prop("unselectable",!0),this.$cache.line.trigger("focus"),this.updateScene())},pointerClick:function(a,b){b.preventDefault();var c=b.pageX||b.originalEvent.touches&&b.originalEvent.touches[0].pageX;2!==b.button&&(this.current_plugin=this.plugin_count,this.target=a,
this.is_click=!0,this.coords.x_gap=this.$cache.rs.offset().left,this.coords.x_pointer=+(c-this.coords.x_gap).toFixed(),this.force_redraw=!0,this.calc(),this.$cache.line.trigger("focus"))},key:function(a,b){if(!(this.current_plugin!==this.plugin_count||b.altKey||b.ctrlKey||b.shiftKey||b.metaKey)){switch(b.which){case 83:case 65:case 40:case 37:b.preventDefault();this.moveByKey(!1);break;case 87:case 68:case 38:case 39:b.preventDefault(),this.moveByKey(!0)}return!0}},moveByKey:function(a){var b=this.coords.p_pointer,
b=a?b+this.options.keyboard_step:b-this.options.keyboard_step;this.coords.x_pointer=this.toFixed(this.coords.w_rs/100*b);this.is_key=!0;this.calc()},setMinMax:function(){this.options&&(this.options.hide_min_max?(this.$cache.min[0].style.display="none",this.$cache.max[0].style.display="none"):(this.options.values.length?(this.$cache.min.html(this.decorate(this.options.p_values[this.options.min])),this.$cache.max.html(this.decorate(this.options.p_values[this.options.max]))):(this.$cache.min.html(this.decorate(this._prettify(this.options.min),
this.options.min)),this.$cache.max.html(this.decorate(this._prettify(this.options.max),this.options.max))),this.labels.w_min=this.$cache.min.outerWidth(!1),this.labels.w_max=this.$cache.max.outerWidth(!1)))},calc:function(a){if(this.options){this.calc_count++;if(10===this.calc_count||a)this.calc_count=0,this.coords.w_rs=this.$cache.rs.outerWidth(!1),this.coords.w_handle="single"===this.options.type?this.$cache.s_single.outerWidth(!1):this.$cache.s_from.outerWidth(!1);if(this.coords.w_rs){this.calcPointer();
this.coords.p_handle=this.toFixed(this.coords.w_handle/this.coords.w_rs*100);a=100-this.coords.p_handle;var b=this.toFixed(this.coords.p_pointer-this.coords.p_gap);"click"===this.target&&(this.coords.p_gap=this.coords.p_handle/2,b=this.toFixed(this.coords.p_pointer-this.coords.p_gap),this.target=this.chooseHandle(b));0>b?b=0:b>a&&(b=a);switch(this.target){case "base":b=(this.options.max-this.options.min)/100;a=(this.result.from-this.options.min)/b;b=(this.result.to-this.options.min)/b;this.coords.p_single_real=
this.toFixed(a);this.coords.p_from_real=this.toFixed(a);this.coords.p_to_real=this.toFixed(b);this.coords.p_single_real=this.checkDiapason(this.coords.p_single_real,this.options.from_min,this.options.from_max);this.coords.p_from_real=this.checkDiapason(this.coords.p_from_real,this.options.from_min,this.options.from_max);this.coords.p_to_real=this.checkDiapason(this.coords.p_to_real,this.options.to_min,this.options.to_max);this.coords.p_single=this.toFixed(a-this.coords.p_handle/100*a);this.coords.p_from=
this.toFixed(a-this.coords.p_handle/100*a);this.coords.p_to=this.toFixed(b-this.coords.p_handle/100*b);this.target=null;break;case "single":if(this.options.from_fixed)break;this.coords.p_single_real=this.calcWithStep(b/a*100);this.coords.p_single_real=this.checkDiapason(this.coords.p_single_real,this.options.from_min,this.options.from_max);this.coords.p_single=this.toFixed(this.coords.p_single_real/100*a);break;case "from":if(this.options.from_fixed)break;this.coords.p_from_real=this.calcWithStep(b/
a*100);this.coords.p_from_real>this.coords.p_to_real&&(this.coords.p_from_real=this.coords.p_to_real);this.coords.p_from_real=this.checkDiapason(this.coords.p_from_real,this.options.from_min,this.options.from_max);this.coords.p_from_real=this.checkMinInterval(this.coords.p_from_real,this.coords.p_to_real,"from");this.coords.p_from_real=this.checkMaxInterval(this.coords.p_from_real,this.coords.p_to_real,"from");this.coords.p_from=this.toFixed(this.coords.p_from_real/100*a);break;case "to":if(this.options.to_fixed)break;
this.coords.p_to_real=this.calcWithStep(b/a*100);this.coords.p_to_real<this.coords.p_from_real&&(this.coords.p_to_real=this.coords.p_from_real);this.coords.p_to_real=this.checkDiapason(this.coords.p_to_real,this.options.to_min,this.options.to_max);this.coords.p_to_real=this.checkMinInterval(this.coords.p_to_real,this.coords.p_from_real,"to");this.coords.p_to_real=this.checkMaxInterval(this.coords.p_to_real,this.coords.p_from_real,"to");this.coords.p_to=this.toFixed(this.coords.p_to_real/100*a);break;
case "both":if(this.options.from_fixed||this.options.to_fixed)break;b=this.toFixed(b+.1*this.coords.p_handle);this.coords.p_from_real=this.calcWithStep((b-this.coords.p_gap_left)/a*100);this.coords.p_from_real=this.checkDiapason(this.coords.p_from_real,this.options.from_min,this.options.from_max);this.coords.p_from_real=this.checkMinInterval(this.coords.p_from_real,this.coords.p_to_real,"from");this.coords.p_from=this.toFixed(this.coords.p_from_real/100*a);this.coords.p_to_real=this.calcWithStep((b+
this.coords.p_gap_right)/a*100);this.coords.p_to_real=this.checkDiapason(this.coords.p_to_real,this.options.to_min,this.options.to_max);this.coords.p_to_real=this.checkMinInterval(this.coords.p_to_real,this.coords.p_from_real,"to");this.coords.p_to=this.toFixed(this.coords.p_to_real/100*a)}"single"===this.options.type?(this.coords.p_bar_x=this.coords.p_handle/2,this.coords.p_bar_w=this.coords.p_single,this.result.from_percent=this.coords.p_single_real,this.result.from=this.calcReal(this.coords.p_single_real),
this.options.values.length&&(this.result.from_value=this.options.values[this.result.from])):(this.coords.p_bar_x=this.toFixed(this.coords.p_from+this.coords.p_handle/2),this.coords.p_bar_w=this.toFixed(this.coords.p_to-this.coords.p_from),this.result.from_percent=this.coords.p_from_real,this.result.from=this.calcReal(this.coords.p_from_real),this.result.to_percent=this.coords.p_to_real,this.result.to=this.calcReal(this.coords.p_to_real),this.options.values.length&&(this.result.from_value=this.options.values[this.result.from],
this.result.to_value=this.options.values[this.result.to]));this.calcMinMax();this.calcLabels()}}},calcPointer:function(){this.coords.w_rs?(0>this.coords.x_pointer||isNaN(this.coords.x_pointer)?this.coords.x_pointer=0:this.coords.x_pointer>this.coords.w_rs&&(this.coords.x_pointer=this.coords.w_rs),this.coords.p_pointer=this.toFixed(this.coords.x_pointer/this.coords.w_rs*100)):this.coords.p_pointer=0},chooseHandle:function(a){return"single"===this.options.type?"single":a>=this.coords.p_from_real+(this.coords.p_to_real-
this.coords.p_from_real)/2?this.options.to_fixed?"from":"to":this.options.from_fixed?"to":"from"},calcMinMax:function(){this.coords.w_rs&&(this.labels.p_min=this.labels.w_min/this.coords.w_rs*100,this.labels.p_max=this.labels.w_max/this.coords.w_rs*100)},calcLabels:function(){this.coords.w_rs&&!this.options.hide_from_to&&("single"===this.options.type?(this.labels.w_single=this.$cache.single.outerWidth(!1),this.labels.p_single=this.labels.w_single/this.coords.w_rs*100,this.labels.p_single_left=this.coords.p_single+
this.coords.p_handle/2-this.labels.p_single/2):(this.labels.w_from=this.$cache.from.outerWidth(!1),this.labels.p_from=this.labels.w_from/this.coords.w_rs*100,this.labels.p_from_left=this.coords.p_from+this.coords.p_handle/2-this.labels.p_from/2,this.labels.p_from_left=this.toFixed(this.labels.p_from_left),this.labels.p_from_left=this.checkEdges(this.labels.p_from_left,this.labels.p_from),this.labels.w_to=this.$cache.to.outerWidth(!1),this.labels.p_to=this.labels.w_to/this.coords.w_rs*100,this.labels.p_to_left=
this.coords.p_to+this.coords.p_handle/2-this.labels.p_to/2,this.labels.p_to_left=this.toFixed(this.labels.p_to_left),this.labels.p_to_left=this.checkEdges(this.labels.p_to_left,this.labels.p_to),this.labels.w_single=this.$cache.single.outerWidth(!1),this.labels.p_single=this.labels.w_single/this.coords.w_rs*100,this.labels.p_single_left=(this.labels.p_from_left+this.labels.p_to_left+this.labels.p_to)/2-this.labels.p_single/2,this.labels.p_single_left=this.toFixed(this.labels.p_single_left)),this.labels.p_single_left=
this.checkEdges(this.labels.p_single_left,this.labels.p_single))},updateScene:function(){this.raf_id&&(cancelAnimationFrame(this.raf_id),this.raf_id=null);clearTimeout(this.update_tm);this.update_tm=null;this.options&&(this.drawHandles(),this.is_active?this.raf_id=requestAnimationFrame(this.updateScene.bind(this)):this.update_tm=setTimeout(this.updateScene.bind(this),300))},drawHandles:function(){this.coords.w_rs=this.$cache.rs.outerWidth(!1);if(this.coords.w_rs){this.coords.w_rs!==this.coords.w_rs_old&&
(this.target="base",this.is_resize=!0);if(this.coords.w_rs!==this.coords.w_rs_old||this.force_redraw)this.setMinMax(),this.calc(!0),this.drawLabels(),this.options.grid&&(this.calcGridMargin(),this.calcGridLabels()),this.force_redraw=!0,this.coords.w_rs_old=this.coords.w_rs,this.drawShadow();if(this.coords.w_rs&&(this.dragging||this.force_redraw||this.is_key)){if(this.old_from!==this.result.from||this.old_to!==this.result.to||this.force_redraw||this.is_key){this.drawLabels();this.$cache.bar[0].style.left=
this.coords.p_bar_x+"%";this.$cache.bar[0].style.width=this.coords.p_bar_w+"%";if("single"===this.options.type)this.$cache.s_single[0].style.left=this.coords.p_single+"%",this.$cache.single[0].style.left=this.labels.p_single_left+"%",this.options.values.length?(this.$cache.input.prop("value",this.result.from_value),this.$cache.input.data("from",this.result.from_value)):(this.$cache.input.prop("value",this.result.from),this.$cache.input.data("from",this.result.from));else{this.$cache.s_from[0].style.left=
this.coords.p_from+"%";this.$cache.s_to[0].style.left=this.coords.p_to+"%";if(this.old_from!==this.result.from||this.force_redraw)this.$cache.from[0].style.left=this.labels.p_from_left+"%";if(this.old_to!==this.result.to||this.force_redraw)this.$cache.to[0].style.left=this.labels.p_to_left+"%";this.$cache.single[0].style.left=this.labels.p_single_left+"%";this.options.values.length?(this.$cache.input.prop("value",this.result.from_value+";"+this.result.to_value),this.$cache.input.data("from",this.result.from_value),
this.$cache.input.data("to",this.result.to_value)):(this.$cache.input.prop("value",this.result.from+";"+this.result.to),this.$cache.input.data("from",this.result.from),this.$cache.input.data("to",this.result.to))}this.old_from===this.result.from&&this.old_to===this.result.to||this.is_start||this.$cache.input.trigger("change");this.old_from=this.result.from;this.old_to=this.result.to;this.is_resize||this.is_update||this.is_start||this.is_finish||this.callOnChange();(this.is_key||this.is_click)&&this.callOnFinish();
this.is_finish=this.is_resize=this.is_update=!1}this.force_redraw=this.is_click=this.is_key=this.is_start=!1}}},callOnStart:function(){if(this.options.onStart&&"function"===typeof this.options.onStart)this.options.onStart(this.result)},callOnChange:function(){if(this.options.onChange&&"function"===typeof this.options.onChange)this.options.onChange(this.result)},callOnFinish:function(){if(this.options.onFinish&&"function"===typeof this.options.onFinish)this.options.onFinish(this.result)},callOnUpdate:function(){if(this.options.onUpdate&&
"function"===typeof this.options.onUpdate)this.options.onUpdate(this.result)},drawLabels:function(){if(this.options){var a=this.options.values.length,b=this.options.p_values,c;if(!this.options.hide_from_to)if("single"===this.options.type)a=a?this.decorate(b[this.result.from]):this.decorate(this._prettify(this.result.from),this.result.from),this.$cache.single.html(a),this.calcLabels(),this.$cache.min[0].style.visibility=this.labels.p_single_left<this.labels.p_min+1?"hidden":"visible",this.$cache.max[0].style.visibility=
this.labels.p_single_left+this.labels.p_single>100-this.labels.p_max-1?"hidden":"visible";else{a?(this.options.decorate_both?(a=this.decorate(b[this.result.from]),a+=this.options.values_separator,a+=this.decorate(b[this.result.to])):a=this.decorate(b[this.result.from]+this.options.values_separator+b[this.result.to]),c=this.decorate(b[this.result.from]),b=this.decorate(b[this.result.to])):(this.options.decorate_both?(a=this.decorate(this._prettify(this.result.from),this.result.from),a+=this.options.values_separator,
a+=this.decorate(this._prettify(this.result.to),this.result.to)):a=this.decorate(this._prettify(this.result.from)+this.options.values_separator+this._prettify(this.result.to),this.result.to),c=this.decorate(this._prettify(this.result.from),this.result.from),b=this.decorate(this._prettify(this.result.to),this.result.to));this.$cache.single.html(a);this.$cache.from.html(c);this.$cache.to.html(b);this.calcLabels();b=Math.min(this.labels.p_single_left,this.labels.p_from_left);a=this.labels.p_single_left+
this.labels.p_single;c=this.labels.p_to_left+this.labels.p_to;var d=Math.max(a,c);this.labels.p_from_left+this.labels.p_from>=this.labels.p_to_left?(this.$cache.from[0].style.visibility="hidden",this.$cache.to[0].style.visibility="hidden",this.$cache.single[0].style.visibility="visible",this.result.from===this.result.to?(this.$cache.from[0].style.visibility="visible",this.$cache.single[0].style.visibility="hidden",d=c):(this.$cache.from[0].style.visibility="hidden",this.$cache.single[0].style.visibility=
"visible",d=Math.max(a,c))):(this.$cache.from[0].style.visibility="visible",this.$cache.to[0].style.visibility="visible",this.$cache.single[0].style.visibility="hidden");this.$cache.min[0].style.visibility=b<this.labels.p_min+1?"hidden":"visible";this.$cache.max[0].style.visibility=d>100-this.labels.p_max-1?"hidden":"visible"}}},drawShadow:function(){var a=this.options,b=this.$cache,c="number"===typeof a.from_min&&!isNaN(a.from_min),d="number"===typeof a.from_max&&!isNaN(a.from_max),f="number"===
typeof a.to_min&&!isNaN(a.to_min),g="number"===typeof a.to_max&&!isNaN(a.to_max);"single"===a.type?a.from_shadow&&(c||d)?(c=this.calcPercent(c?a.from_min:a.min),d=this.calcPercent(d?a.from_max:a.max)-c,c=this.toFixed(c-this.coords.p_handle/100*c),d=this.toFixed(d-this.coords.p_handle/100*d),c+=this.coords.p_handle/2,b.shad_single[0].style.display="block",b.shad_single[0].style.left=c+"%",b.shad_single[0].style.width=d+"%"):b.shad_single[0].style.display="none":(a.from_shadow&&(c||d)?(c=this.calcPercent(c?
a.from_min:a.min),d=this.calcPercent(d?a.from_max:a.max)-c,c=this.toFixed(c-this.coords.p_handle/100*c),d=this.toFixed(d-this.coords.p_handle/100*d),c+=this.coords.p_handle/2,b.shad_from[0].style.display="block",b.shad_from[0].style.left=c+"%",b.shad_from[0].style.width=d+"%"):b.shad_from[0].style.display="none",a.to_shadow&&(f||g)?(f=this.calcPercent(f?a.to_min:a.min),a=this.calcPercent(g?a.to_max:a.max)-f,f=this.toFixed(f-this.coords.p_handle/100*f),a=this.toFixed(a-this.coords.p_handle/100*a),
f+=this.coords.p_handle/2,b.shad_to[0].style.display="block",b.shad_to[0].style.left=f+"%",b.shad_to[0].style.width=a+"%"):b.shad_to[0].style.display="none")},toggleInput:function(){this.$cache.input.toggleClass("irs-hidden-input")},calcPercent:function(a){return this.toFixed((a-this.options.min)/((this.options.max-this.options.min)/100))},calcReal:function(a){var b=this.options.min,c=this.options.max,d=b.toString().split(".")[1],f=c.toString().split(".")[1],g,l,k=0,e=0;if(0===a)return this.options.min;
if(100===a)return this.options.max;d&&(k=g=d.length);f&&(k=l=f.length);g&&l&&(k=g>=l?g:l);0>b&&(e=Math.abs(b),b=+(b+e).toFixed(k),c=+(c+e).toFixed(k));a=(c-b)/100*a+b;(b=this.options.step.toString().split(".")[1])?a=+a.toFixed(b.length):(a/=this.options.step,a*=this.options.step,a=+a.toFixed(0));e&&(a-=e);e=b?+a.toFixed(b.length):this.toFixed(a);e<this.options.min?e=this.options.min:e>this.options.max&&(e=this.options.max);return e},calcWithStep:function(a){var b=Math.round(a/this.coords.p_step)*
this.coords.p_step;100<b&&(b=100);100===a&&(b=100);return this.toFixed(b)},checkMinInterval:function(a,b,c){var d=this.options;if(!d.min_interval)return a;a=this.calcReal(a);b=this.calcReal(b);"from"===c?b-a<d.min_interval&&(a=b-d.min_interval):a-b<d.min_interval&&(a=b+d.min_interval);return this.calcPercent(a)},checkMaxInterval:function(a,b,c){var d=this.options;if(!d.max_interval)return a;a=this.calcReal(a);b=this.calcReal(b);"from"===c?b-a>d.max_interval&&(a=b-d.max_interval):a-b>d.max_interval&&
(a=b+d.max_interval);return this.calcPercent(a)},checkDiapason:function(a,b,c){a=this.calcReal(a);var d=this.options;"number"!==typeof b&&(b=d.min);"number"!==typeof c&&(c=d.max);a<b&&(a=b);a>c&&(a=c);return this.calcPercent(a)},toFixed:function(a){a=a.toFixed(9);return+a},_prettify:function(a){return this.options.prettify_enabled?this.options.prettify&&"function"===typeof this.options.prettify?this.options.prettify(a):this.prettify(a):a},prettify:function(a){return a.toString().replace(/(\d{1,3}(?=(?:\d\d\d)+(?!\d)))/g,
"$1"+this.options.prettify_separator)},checkEdges:function(a,b){if(!this.options.force_edges)return this.toFixed(a);0>a?a=0:a>100-b&&(a=100-b);return this.toFixed(a)},validate:function(){var a=this.options,b=this.result,c=a.values,d=c.length,f,g;"string"===typeof a.min&&(a.min=+a.min);"string"===typeof a.max&&(a.max=+a.max);"string"===typeof a.from&&(a.from=+a.from);"string"===typeof a.to&&(a.to=+a.to);"string"===typeof a.step&&(a.step=+a.step);"string"===typeof a.from_min&&(a.from_min=+a.from_min);
"string"===typeof a.from_max&&(a.from_max=+a.from_max);"string"===typeof a.to_min&&(a.to_min=+a.to_min);"string"===typeof a.to_max&&(a.to_max=+a.to_max);"string"===typeof a.keyboard_step&&(a.keyboard_step=+a.keyboard_step);"string"===typeof a.grid_num&&(a.grid_num=+a.grid_num);a.max<=a.min&&(a.max=a.min?2*a.min:a.min+1,a.step=1);if(d)for(a.p_values=[],a.min=0,a.max=d-1,a.step=1,a.grid_num=a.max,a.grid_snap=!0,g=0;g<d;g++)f=+c[g],isNaN(f)?f=c[g]:(c[g]=f,f=this._prettify(f)),a.p_values.push(f);if("number"!==
typeof a.from||isNaN(a.from))a.from=a.min;if("number"!==typeof a.to||isNaN(a.from))a.to=a.max;if("single"===a.type)a.from<a.min&&(a.from=a.min),a.from>a.max&&(a.from=a.max);else{if(a.from<a.min||a.from>a.max)a.from=a.min;if(a.to>a.max||a.to<a.min)a.to=a.max;a.from>a.to&&(a.from=a.to)}if("number"!==typeof a.step||isNaN(a.step)||!a.step||0>a.step)a.step=1;if("number"!==typeof a.keyboard_step||isNaN(a.keyboard_step)||!a.keyboard_step||0>a.keyboard_step)a.keyboard_step=5;"number"===typeof a.from_min&&
a.from<a.from_min&&(a.from=a.from_min);"number"===typeof a.from_max&&a.from>a.from_max&&(a.from=a.from_max);"number"===typeof a.to_min&&a.to<a.to_min&&(a.to=a.to_min);"number"===typeof a.to_max&&a.from>a.to_max&&(a.to=a.to_max);if(b){b.min!==a.min&&(b.min=a.min);b.max!==a.max&&(b.max=a.max);if(b.from<b.min||b.from>b.max)b.from=a.from;if(b.to<b.min||b.to>b.max)b.to=a.to}if("number"!==typeof a.min_interval||isNaN(a.min_interval)||!a.min_interval||0>a.min_interval)a.min_interval=0;if("number"!==typeof a.max_interval||
isNaN(a.max_interval)||!a.max_interval||0>a.max_interval)a.max_interval=0;a.min_interval&&a.min_interval>a.max-a.min&&(a.min_interval=a.max-a.min);a.max_interval&&a.max_interval>a.max-a.min&&(a.max_interval=a.max-a.min)},decorate:function(a,b){var c="",d=this.options;d.prefix&&(c+=d.prefix);c+=a;d.max_postfix&&(d.values.length&&a===d.p_values[d.max]?(c+=d.max_postfix,d.postfix&&(c+=" ")):b===d.max&&(c+=d.max_postfix,d.postfix&&(c+=" ")));d.postfix&&(c+=d.postfix);return c},updateFrom:function(){this.result.from=
this.options.from;this.result.from_percent=this.calcPercent(this.result.from);this.options.values&&(this.result.from_value=this.options.values[this.result.from])},updateTo:function(){this.result.to=this.options.to;this.result.to_percent=this.calcPercent(this.result.to);this.options.values&&(this.result.to_value=this.options.values[this.result.to])},updateResult:function(){this.result.min=this.options.min;this.result.max=this.options.max;this.updateFrom();this.updateTo()},appendGrid:function(){if(this.options.grid){var a=
this.options,b,c;b=a.max-a.min;var d=a.grid_num,f=0,g=0,e=4,k,h,m=0,n="";this.calcGridMargin();a.grid_snap?(d=b/a.step,f=this.toFixed(a.step/(b/100))):f=this.toFixed(100/d);4<d&&(e=3);7<d&&(e=2);14<d&&(e=1);28<d&&(e=0);for(b=0;b<d+1;b++){k=e;g=this.toFixed(f*b);100<g&&(g=100,k-=2,0>k&&(k=0));this.coords.big[b]=g;h=(g-f*(b-1))/(k+1);for(c=1;c<=k&&0!==g;c++)m=this.toFixed(g-h*c),n+='<span class="irs-grid-pol small" style="left: '+m+'%"></span>';n+='<span class="irs-grid-pol" style="left: '+g+'%"></span>';
m=this.calcReal(g);m=a.values.length?a.p_values[m]:this._prettify(m);n+='<span class="irs-grid-text js-grid-text-'+b+'" style="left: '+g+'%">'+m+"</span>"}this.coords.big_num=Math.ceil(d+1);this.$cache.cont.addClass("irs-with-grid");this.$cache.grid.html(n);this.cacheGridLabels()}},cacheGridLabels:function(){var a,b,c=this.coords.big_num;for(b=0;b<c;b++)a=this.$cache.grid.find(".js-grid-text-"+b),this.$cache.grid_labels.push(a);this.calcGridLabels()},calcGridLabels:function(){var a,b;b=[];var c=[],
d=this.coords.big_num;for(a=0;a<d;a++)this.coords.big_w[a]=this.$cache.grid_labels[a].outerWidth(!1),this.coords.big_p[a]=this.toFixed(this.coords.big_w[a]/this.coords.w_rs*100),this.coords.big_x[a]=this.toFixed(this.coords.big_p[a]/2),b[a]=this.toFixed(this.coords.big[a]-this.coords.big_x[a]),c[a]=this.toFixed(b[a]+this.coords.big_p[a]);this.options.force_edges&&(b[0]<-this.coords.grid_gap&&(b[0]=-this.coords.grid_gap,c[0]=this.toFixed(b[0]+this.coords.big_p[0]),this.coords.big_x[0]=this.coords.grid_gap),
c[d-1]>100+this.coords.grid_gap&&(c[d-1]=100+this.coords.grid_gap,b[d-1]=this.toFixed(c[d-1]-this.coords.big_p[d-1]),this.coords.big_x[d-1]=this.toFixed(this.coords.big_p[d-1]-this.coords.grid_gap)));this.calcGridCollision(2,b,c);this.calcGridCollision(4,b,c);for(a=0;a<d;a++)b=this.$cache.grid_labels[a][0],b.style.marginLeft=-this.coords.big_x[a]+"%"},calcGridCollision:function(a,b,c){var d,f,g,e=this.coords.big_num;for(d=0;d<e;d+=a){f=d+a/2;if(f>=e)break;g=this.$cache.grid_labels[f][0];g.style.visibility=
c[d]<=b[f]?"visible":"hidden"}},calcGridMargin:function(){this.options.grid_margin&&(this.coords.w_rs=this.$cache.rs.outerWidth(!1),this.coords.w_rs&&(this.coords.w_handle="single"===this.options.type?this.$cache.s_single.outerWidth(!1):this.$cache.s_from.outerWidth(!1),this.coords.p_handle=this.toFixed(this.coords.w_handle/this.coords.w_rs*100),this.coords.grid_gap=this.toFixed(this.coords.p_handle/2-.1),this.$cache.grid[0].style.width=this.toFixed(100-this.coords.p_handle)+"%",this.$cache.grid[0].style.left=
this.coords.grid_gap+"%"))},update:function(a){this.input&&(this.is_update=!0,this.options.from=this.result.from,this.options.to=this.result.to,this.options=e.extend(this.options,a),this.validate(),this.updateResult(a),this.toggleInput(),this.remove(),this.init(!0))},reset:function(){this.input&&(this.updateResult(),this.update())},destroy:function(){this.input&&(this.toggleInput(),this.$cache.input.prop("readonly",!1),e.data(this.input,"ionRangeSlider",null),this.remove(),this.options=this.input=
null)}};e.fn.ionRangeSlider=function(a){return this.each(function(){e.data(this,"ionRangeSlider")||e.data(this,"ionRangeSlider",new q(this,a,u++))})};(function(){for(var a=0,b=["ms","moz","webkit","o"],c=0;c<b.length&&!h.requestAnimationFrame;++c)h.requestAnimationFrame=h[b[c]+"RequestAnimationFrame"],h.cancelAnimationFrame=h[b[c]+"CancelAnimationFrame"]||h[b[c]+"CancelRequestAnimationFrame"];h.requestAnimationFrame||(h.requestAnimationFrame=function(b,c){var g=(new Date).getTime(),e=Math.max(0,16-
(g-a)),k=h.setTimeout(function(){b(g+e)},e);a=g+e;return k});h.cancelAnimationFrame||(h.cancelAnimationFrame=function(a){clearTimeout(a)})})()})(jQuery,document,window,navigator);

View File

@@ -0,0 +1,87 @@
/* Ion.RangeSlider, Nice Skin
// css version 1.5.11
// by Denis Ineshin | ionden.com
// ===================================================================================================================*/
/* =====================================================================================================================
// Skin details */
.irs-line-mid,
.irs-line-left,
.irs-line-right,
.irs-diapason,
.irs-slider {
background:#E5E5E5;
}
.irs-diapason {
background: #ffb848;
}
.irs {
height: 40px;
}
.irs-with-grid {
height: 60px;
}
.irs-line {
height: 8px; top: 25px;
}
.irs-line-left {
height: 8px;
}
.irs-line-mid {
height: 8px;
}
.irs-line-right {
height: 8px;
}
.irs-diapason {
height: 8px; top: 25px;
}
.irs-slider {
width: 13px;
height: 24px;
top: 17px;
border:1px solid #fefefe;
background:#777;
border-radius: 3px;
}
#irs-active-slider, .irs-slider:hover {
}
.irs-min, .irs-max {
color: #999;
font-size: 10px;
line-height: 1.333;
text-shadow: none;
top: 0; padding: 1px 3px;
background: rgba(0,0,0,0.1);
border-radius: 3px;
}
.lt-ie9 .irs-min, .lt-ie9 .irs-max {
background: #ccc;
}
.irs-from, .irs-to, .irs-single {
color: #fff;
font-size: 10px; line-height: 1.333;
text-shadow: none;
padding: 1px 5px;
background: rgba(0,0,0,0.3);
border-radius: 3px;
}
.lt-ie9 .irs-from, .lt-ie9 .irs-to, .lt-ie9 .irs-single {
background: #999;
}
.irs-grid-pol {
background: #99a4ac;
}
.irs-grid-text {
color: #99a4ac;
}

View File

@@ -0,0 +1,126 @@
/* Ion.RangeSlider
// css version 1.9.2
// © 2013-2014 Denis Ineshin | IonDen.com
// ===================================================================================================================*/
/* =====================================================================================================================
// RangeSlider */
.irs {
position: relative; display: block;
}
.irs-line {
position: relative; display: block;
overflow: hidden;
}
.irs-line-left, .irs-line-mid, .irs-line-right {
position: absolute; display: block;
top: 0;
}
.irs-line-left {
left: 0; width: 10%;
}
.irs-line-mid {
left: 9%; width: 82%;
}
.irs-line-right {
right: 0; width: 10%;
}
.irs-diapason {
position: absolute; display: block;
left: 0; width: 100%;
}
.irs-slider {
position: absolute; display: block;
cursor: default;
z-index: 1;
}
.irs-slider.single {
left: 10px;
}
.irs-slider.single:before {
position: absolute; display: block; content: "";
top: -30%; left: -30%;
width: 160%; height: 160%;
background: rgba(0,0,0,0.0);
}
.irs-slider.from {
left: 100px;
}
.irs-slider.from:before {
position: absolute; display: block; content: "";
top: -30%; left: -30%;
width: 130%; height: 160%;
background: rgba(0,0,0,0.0);
}
.irs-slider.to {
left: 300px;
}
.irs-slider.to:before {
position: absolute; display: block; content: "";
top: -30%; left: 0;
width: 130%; height: 160%;
background: rgba(0,0,0,0.0);
}
.irs-slider.last {
z-index: 2;
}
.irs-min {
position: absolute; display: block;
left: 0;
cursor: default;
}
.irs-max {
position: absolute; display: block;
right: 0;
cursor: default;
}
.irs-from, .irs-to, .irs-single {
position: absolute; display: block;
top: 0; left: 0;
cursor: default;
white-space: nowrap;
}
.irs-grid {
position: absolute; display: none;
bottom: 0; left: 0;
width: 100%; height: 20px;
}
.irs-with-grid .irs-grid {
display: block;
}
.irs-grid-pol {
position: absolute;
top: 0; left: 0;
width: 1px; height: 8px;
background: #000;
}
.irs-grid-pol.small {
height: 4px;
}
.irs-grid-text {
position: absolute;
bottom: 0; left: 0;
width: 100px;
white-space: nowrap;
text-align: center;
font-size: 9px; line-height: 9px;
color: #000;
}
.irs-disable-mask {
position: absolute; display: block;
top: 0; left: 0;
width: 100%; height: 100%;
cursor: default;
background: rgba(0,0,0,0.0);
z-index: 2;
}
.irs-disabled {
opacity: 0.4;
}

View File

@@ -0,0 +1,89 @@
/* Ion.RangeSlider, Flat UI Skin
// css version 1.9.2
// © 2013-2014 Denis Ineshin | IonDen.com
// ===================================================================================================================*/
/* =====================================================================================================================
// Skin details */
.irs-line-mid,
.irs-line-left,
.irs-line-right,
.irs-diapason,
.irs-slider {
background: url(../img/sprite-skin-flat.png) repeat-x;
}
.irs {
height: 40px;
}
.irs-with-grid {
height: 60px;
}
.irs-line {
height: 12px; top: 25px;
}
.irs-line-left {
height: 12px;
background-position: 0 -30px;
}
.irs-line-mid {
height: 12px;
background-position: 0 0;
}
.irs-line-right {
height: 12px;
background-position: 100% -30px;
}
.irs-diapason {
height: 12px; top: 25px;
background-position: 0 -60px;
}
.irs-slider {
width: 16px; height: 18px;
top: 22px;
background-position: 0 -90px;
}
#irs-active-slider, .irs-slider:hover {
background-position: 0 -120px;
}
.irs-min, .irs-max {
color: #999;
font-size: 10px; line-height: 1.333;
text-shadow: none;
top: 0; padding: 1px 3px;
background: #e1e4e9;
border-radius: 4px;
}
.irs-from, .irs-to, .irs-single {
color: #fff;
font-size: 10px; line-height: 1.333;
text-shadow: none;
padding: 1px 5px;
background: #ed5565;
border-radius: 4px;
}
.irs-from:after, .irs-to:after, .irs-single:after {
position: absolute; display: block; content: "";
bottom: -6px; left: 50%;
width: 0; height: 0;
margin-left: -3px;
overflow: hidden;
border: 3px solid transparent;
border-top-color: #ed5565;
}
.irs-grid-pol {
background: #e1e4e9;
}
.irs-grid-text {
color: #999;
}
.irs-disabled {
}

View File

@@ -0,0 +1,85 @@
/* Ion.RangeSlider, Nice Skin
// css version 1.9.2
// © 2013-2014 Denis Ineshin | IonDen.com
// ===================================================================================================================*/
/* =====================================================================================================================
// Skin details */
.irs-line-mid,
.irs-line-left,
.irs-line-right,
.irs-diapason,
.irs-slider {
background: url(../img/sprite-skin-nice.png) repeat-x;
}
.irs {
height: 40px;
}
.irs-with-grid {
height: 60px;
}
.irs-line {
height: 8px; top: 25px;
}
.irs-line-left {
height: 8px;
background-position: 0 -30px;
}
.irs-line-mid {
height: 8px;
background-position: 0 0;
}
.irs-line-right {
height: 8px;
background-position: 100% -30px;
}
.irs-diapason {
height: 8px; top: 25px;
background-position: 0 -60px;
}
.irs-slider {
width: 22px; height: 22px;
top: 17px;
background-position: 0 -90px;
}
#irs-active-slider, .irs-slider:hover {
background-position: 0 -120px;
}
.irs-min, .irs-max {
color: #999;
font-size: 10px; line-height: 1.333;
text-shadow: none;
top: 0; padding: 1px 3px;
background: rgba(0,0,0,0.1);
border-radius: 3px;
}
.lt-ie9 .irs-min, .lt-ie9 .irs-max {
background: #ccc;
}
.irs-from, .irs-to, .irs-single {
color: #fff;
font-size: 10px; line-height: 1.333;
text-shadow: none;
padding: 1px 5px;
background: rgba(0,0,0,0.3);
border-radius: 3px;
}
.lt-ie9 .irs-from, .lt-ie9 .irs-to, .lt-ie9 .irs-single {
background: #999;
}
.irs-grid-pol {
background: #99a4ac;
}
.irs-grid-text {
color: #99a4ac;
}
.irs-disabled {
}

View File

@@ -0,0 +1,85 @@
/* Ion.RangeSlider, Simple Skin
// css version 1.9.2
// © 2013-2014 Denis Ineshin | IonDen.com
// ===================================================================================================================*/
/* =====================================================================================================================
// Skin details */
.irs-line-mid,
.irs-line-left,
.irs-line-right,
.irs-diapason,
.irs-slider {
background: url(../img/sprite-skin-simple.png) repeat-x;
}
.irs {
height: 40px;
}
.irs-with-grid {
height: 60px;
}
.irs-line {
height: 6px; top: 25px;
}
.irs-line-left {
height: 6px;
background-position: 0 -30px;
}
.irs-line-mid {
height: 6px;
background-position: 0 0;
}
.irs-line-right {
height: 6px;
background-position: 100% -30px;
}
.irs-diapason {
height: 6px; top: 25px;
background-position: 0 -60px;
}
.irs-slider {
width: 8px; height: 15px;
top: 21px;
background-position: 0 -90px;
}
#irs-active-slider, .irs-slider:hover {
background-position: 0 -120px;
}
.irs-min, .irs-max {
color: #c0c0c0;
font-size: 10px; line-height: 1.333;
text-shadow: none;
top: 0; padding: 1px 3px;
background: rgba(0,0,0,0.1);
border-radius: 3px;
}
.lt-ie9 .irs-min, .lt-ie9 .irs-max {
background: #3654b0;
}
.irs-from, .irs-to, .irs-single {
color: #000;
font-size: 10px; line-height: 1.333;
text-shadow: none;
padding: 1px 5px;
background: rgba(255,255,255,0.8);
border-radius: 3px;
}
.lt-ie9 .irs-from, .lt-ie9 .irs-to, .lt-ie9 .irs-single {
background: #d8dff3;
}
.irs-grid-pol {
background: #777;
}
.irs-grid-text {
color: #e0e0e0;
}
.irs-disabled {
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 352 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1022 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 385 B

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,27 @@
// Ion.RangeSlider | version 1.9.3 | https://github.com/IonDen/ion.rangeSlider
(function(c,ea,aa,M){var ba=0,r,N=function(){var c=M.userAgent,a=/msie\s\d+/i;return 0<c.search(a)&&(c=a.exec(c).toString(),c=c.split(" ")[1],9>c)?!0:!1}(),X="ontouchstart"in aa||0<M.msMaxTouchPoints,O=function(c){"number"!==typeof c&&(c=parseFloat(c));return isNaN(c)?null:c},H={init:function(fa){return this.each(function(){var a=c.extend({min:null,max:null,from:null,to:null,type:"single",step:null,prefix:"",postfix:"",maxPostfix:"",hasGrid:!1,gridMargin:0,hideMinMax:!1,hideFromTo:!1,prettify:!0,
disable:!1,values:null,onLoad:null,onChange:null,onFinish:null},fa),e=c(this),l=this,I=!1,g=null;if(!e.data("isActive")){e.data("isActive",!0);this.plugin_count=ba+=1;e.prop("value")&&(g=e.prop("value").split(";"));"single"===a.type?g&&1<g.length?("number"!==typeof a.min?a.min=parseFloat(g[0]):"number"!==typeof a.from&&(a.from=parseFloat(g[0])),"number"!==typeof a.max&&(a.max=parseFloat(g[1]))):g&&1===g.length&&"number"!==typeof a.from&&(a.from=parseFloat(g[0])):"double"===a.type&&(g&&1<g.length?
("number"!==typeof a.min?a.min=parseFloat(g[0]):"number"!==typeof a.from&&(a.from=parseFloat(g[0])),"number"!==typeof a.max?a.max=parseFloat(g[1]):"number"!==typeof a.to&&(a.to=parseFloat(g[1]))):g&&1===g.length&&("number"!==typeof a.min?a.min=parseFloat(g[0]):"number"!==typeof a.from&&(a.from=parseFloat(g[0]))));"number"===typeof e.data("min")&&(a.min=parseFloat(e.data("min")));"number"===typeof e.data("max")&&(a.max=parseFloat(e.data("max")));"number"===typeof e.data("from")&&(a.from=parseFloat(e.data("from")));
"number"===typeof e.data("to")&&(a.to=parseFloat(e.data("to")));e.data("step")&&(a.step=parseFloat(e.data("step")));e.data("type")&&(a.type=e.data("type"));e.data("prefix")&&(a.prefix=e.data("prefix"));e.data("postfix")&&(a.postfix=e.data("postfix"));e.data("maxpostfix")&&(a.maxPostfix=e.data("maxpostfix"));e.data("hasgrid")&&(a.hasGrid=e.data("hasgrid"));e.data("gridmargin")&&(a.gridMargin=+e.data("gridmargin"));e.data("hideminmax")&&(a.hideMinMax=e.data("hideminmax"));e.data("hidefromto")&&(a.hideFromTo=
e.data("hidefromto"));e.data("prettify")&&(a.prettify=e.data("prettify"));e.data("disable")&&(a.disable=e.data("disable"));e.data("values")&&(a.values=e.data("values").split(","));a.min=O(a.min);a.min||0===a.min||(a.min=10);a.max=O(a.max);a.max||0===a.max||(a.max=100);"[object Array]"!==Object.prototype.toString.call(a.values)&&(a.values=null);a.values&&0<a.values.length&&(a.min=0,a.max=a.values.length-1,a.step=1,I=!0);a.from=O(a.from);a.from||0===a.from||(a.from=a.min);a.to=O(a.to);a.to||0===a.to||
(a.to=a.max);a.step=O(a.step);a.step||(a.step=1);a.from<a.min&&(a.from=a.min);a.from>a.max&&(a.from=a.min);a.to<a.min&&(a.to=a.max);a.to>a.max&&(a.to=a.max);"double"===a.type&&(a.from>a.to&&(a.from=a.to),a.to<a.from&&(a.to=a.from));var z=function(b){b=b.toString();a.prettify&&(b=b.replace(/(\d{1,3}(?=(?:\d\d\d)+(?!\d)))/g,"$1 "));return b},g='<span class="irs" id="irs-'+this.plugin_count+'"></span>';e[0].style.display="none";e.before(g);var n=e.prev(),C=c(ea.body),P=c(aa),p,D,E,A,B,w,x,m,s,q,H,Y,
v=!1,y=!1,J=!0,f={},U=0,Q=0,R=0,t=0,F=0,G=0,V=0,S=0,T=0,Z=0,u=0;parseInt(a.step,10)!==parseFloat(a.step)&&(u=a.step.toString().split(".")[1],u=Math.pow(10,u.length));this.updateData=function(b){c.extend(a,b);n.find("*").off();P.off("mouseup.irs"+l.plugin_count);C.off("mouseup.irs"+l.plugin_count);C.off("mouseleave.irs"+l.plugin_count);C.off("mousemove.irs"+l.plugin_count);n.html("");M()};this.removeSlider=function(){n.find("*").off();P.off("mouseup.irs"+l.plugin_count);C.off("mouseup.irs"+l.plugin_count);
C.off("mouseleave.irs"+l.plugin_count);C.off("mousemove.irs"+l.plugin_count);n.html("").remove();e.data("isActive",!1);e.show()};var M=function(){n.html('<span class="irs"><span class="irs-line"><span class="irs-line-left"></span><span class="irs-line-mid"></span><span class="irs-line-right"></span></span><span class="irs-min">0</span><span class="irs-max">1</span><span class="irs-from">0</span><span class="irs-to">0</span><span class="irs-single">0</span></span><span class="irs-grid"></span>');p=
n.find(".irs");D=p.find(".irs-min");E=p.find(".irs-max");A=p.find(".irs-from");B=p.find(".irs-to");w=p.find(".irs-single");Y=n.find(".irs-grid");a.hideFromTo&&(A[0].style.visibility="hidden",B[0].style.visibility="hidden",w[0].style.visibility="hidden");a.hideFromTo||(A[0].style.visibility="visible",B[0].style.visibility="visible",w[0].style.visibility="visible");a.hideMinMax&&(D[0].style.visibility="hidden",E[0].style.visibility="hidden",R=Q=0);a.hideMinMax||(D[0].style.visibility="visible",E[0].style.visibility=
"visible",a.values?(D.html(a.prefix+a.values[0]+a.postfix),E.html(a.prefix+a.values[a.values.length-1]+a.maxPostfix+a.postfix)):(D.html(a.prefix+z(a.min)+a.postfix),E.html(a.prefix+z(a.max)+a.maxPostfix+a.postfix)),Q=D.outerWidth(!1),R=E.outerWidth(!1));ga()},ga=function(){if("single"===a.type){if(p.append('<span class="irs-slider single"></span>'),x=p.find(".single"),x.on("mousedown",function(a){a.preventDefault();a.stopPropagation();K(a,c(this),null);y=v=!0;r=l.plugin_count;N&&c("*").prop("unselectable",
!0)}),X)x.on("touchstart",function(a){a.preventDefault();a.stopPropagation();K(a.originalEvent.touches[0],c(this),null);y=v=!0;r=l.plugin_count})}else"double"===a.type&&(p.append('<span class="irs-diapason"></span><span class="irs-slider from"></span><span class="irs-slider to"></span>'),m=p.find(".from"),s=p.find(".to"),H=p.find(".irs-diapason"),L(),m.on("mousedown",function(a){a.preventDefault();a.stopPropagation();c(this).addClass("last");s.removeClass("last");K(a,c(this),"from");y=v=!0;r=l.plugin_count;
N&&c("*").prop("unselectable",!0)}),s.on("mousedown",function(a){a.preventDefault();a.stopPropagation();c(this).addClass("last");m.removeClass("last");K(a,c(this),"to");y=v=!0;r=l.plugin_count;N&&c("*").prop("unselectable",!0)}),X&&(m.on("touchstart",function(a){a.preventDefault();a.stopPropagation();c(this).addClass("last");s.removeClass("last");K(a.originalEvent.touches[0],c(this),"from");y=v=!0;r=l.plugin_count}),s.on("touchstart",function(a){a.preventDefault();a.stopPropagation();c(this).addClass("last");
m.removeClass("last");K(a.originalEvent.touches[0],c(this),"to");y=v=!0;r=l.plugin_count})),a.to===a.max&&m.addClass("last"));var b=function(){r===l.plugin_count&&v&&(v=y=!1,q.removeAttr("id"),q=null,"double"===a.type&&L(),$(),N&&c("*").prop("unselectable",!1))};P.on("mouseup.irs"+l.plugin_count,function(){b()});if(N)C.on("mouseleave.irs"+l.plugin_count,function(){b()});C.on("mousemove.irs"+l.plugin_count,function(a){v&&(U=a.pageX,W())});n.on("mousedown",function(){r=l.plugin_count});n.on("mouseup",
function(b){if(r===l.plugin_count&&!v&&!a.disable){b=b.pageX;J=!1;b-=n.offset().left;var h=f.fromX+(f.toX-f.fromX)/2;S=0;V=p.width()-G;T=p.width()-G;"single"===a.type?(q=x,q.prop("id","irs-active-slider"),W(b)):"double"===a.type&&(q=b<=h?m:s,q.prop("id","irs-active-slider"),W(b),L());q.removeAttr("id");q=null}});X&&(P.on("touchend",function(){v&&(v=y=!1,q.removeAttr("id"),q=null,"double"===a.type&&L(),$())}),P.on("touchmove",function(a){v&&(U=a.originalEvent.touches[0].pageX,W())}));ca();ha();a.hasGrid&&
ia();a.disable?(n.addClass("irs-disabled"),n.append('<span class="irs-disable-mask"></span>')):(n.removeClass("irs-disabled"),n.find(".irs-disable-mask").remove())},ca=function(){t=p.width();G=x?x.width():m.width();F=t-G},K=function(b,d,h){ca();J=!1;q=d;q.prop("id","irs-active-slider");d=q.offset().left;Z=d+(b.pageX-d)-q.position().left;"single"===a.type?V=p.width()-G:"double"===a.type&&("from"===h?(S=0,T=parseInt(s.css("left"),10)):(S=parseInt(m.css("left"),10),T=p.width()-G))},L=function(){var a=
m.width(),d=c.data(m[0],"x")||parseInt(m[0].style.left,10)||m.position().left,h=(c.data(s[0],"x")||parseInt(s[0].style.left,10)||s.position().left)-d;H[0].style.left=d+a/2+"px";H[0].style.width=h+"px"},W=function(b){var d=U-Z,d=b?b:U-Z;"single"===a.type?(0>d&&(d=0),d>V&&(d=V)):"double"===a.type&&(d<S&&(d=S),d>T&&(d=T),L());c.data(q[0],"x",d);$();b=Math.round(d);q[0].style.left=b+"px"},$=function(){var b={input:e,slider:n,min:a.min,max:a.max,fromNumber:0,toNumber:0,fromPers:0,toPers:0,fromX:0,fromX_pure:0,
toX:0,toX_pure:0},d=a.max-a.min,h;"single"===a.type?(b.fromX=c.data(x[0],"x")||parseInt(x[0].style.left,10)||x.position().left,b.fromPers=b.fromX/F*100,h=d/100*b.fromPers+a.min,b.fromNumber=Math.round(h/a.step)*a.step,b.fromNumber<a.min&&(b.fromNumber=a.min),b.fromNumber>a.max&&(b.fromNumber=a.max),u&&(b.fromNumber=parseInt(b.fromNumber*u,10)/u),I&&(b.fromValue=a.values[b.fromNumber])):"double"===a.type&&(b.fromX=c.data(m[0],"x")||parseInt(m[0].style.left,10)||m.position().left,b.fromPers=b.fromX/
F*100,h=d/100*b.fromPers+a.min,b.fromNumber=Math.round(h/a.step)*a.step,b.fromNumber<a.min&&(b.fromNumber=a.min),b.toX=c.data(s[0],"x")||parseInt(s[0].style.left,10)||s.position().left,b.toPers=b.toX/F*100,d=d/100*b.toPers+a.min,b.toNumber=Math.round(d/a.step)*a.step,b.toNumber>a.max&&(b.toNumber=a.max),u&&(b.fromNumber=parseInt(b.fromNumber*u,10)/u,b.toNumber=parseInt(b.toNumber*u,10)/u),I&&(b.fromValue=a.values[b.fromNumber],b.toValue=a.values[b.toNumber]));f=b;da()},ha=function(){var b={input:e,
slider:n,min:a.min,max:a.max,fromNumber:a.from,toNumber:a.to,fromPers:0,toPers:0,fromX:0,fromX_pure:0,toX:0,toX_pure:0},d=a.max-a.min;"single"===a.type?(b.fromPers=0!==d?(b.fromNumber-a.min)/d*100:0,b.fromX_pure=F/100*b.fromPers,b.fromX=Math.round(b.fromX_pure),x[0].style.left=b.fromX+"px",c.data(x[0],"x",b.fromX_pure)):"double"===a.type&&(b.fromPers=0!==d?(b.fromNumber-a.min)/d*100:0,b.fromX_pure=F/100*b.fromPers,b.fromX=Math.round(b.fromX_pure),m[0].style.left=b.fromX+"px",c.data(m[0],"x",b.fromX_pure),
b.toPers=0!==d?(b.toNumber-a.min)/d*100:1,b.toX_pure=F/100*b.toPers,b.toX=Math.round(b.toX_pure),s[0].style.left=b.toX+"px",c.data(s[0],"x",b.toX_pure),L());f=b;da()},da=function(){var b,d,h,c,g,k;k=G/2;h="";"single"===a.type?(h=f.fromNumber===a.max?a.maxPostfix:"",A[0].style.display="none",B[0].style.display="none",h=I?a.prefix+a.values[f.fromNumber]+h+a.postfix:a.prefix+z(f.fromNumber)+h+a.postfix,w.html(h),g=w.outerWidth(!1),k=f.fromX-g/2+k,0>k&&(k=0),k>t-g&&(k=t-g),w[0].style.left=k+"px",a.hideMinMax||
a.hideFromTo||(D[0].style.display=k<Q?"none":"block",E[0].style.display=k+g>t-R?"none":"block"),e.prop("value",parseFloat(f.fromNumber))):"double"===a.type&&(h=f.toNumber===a.max?a.maxPostfix:"",I?(b=a.prefix+a.values[f.fromNumber]+a.postfix,d=a.prefix+a.values[f.toNumber]+h+a.postfix,h=f.fromNumber!==f.toNumber?a.prefix+a.values[f.fromNumber]+" \u2014 "+a.prefix+a.values[f.toNumber]+h+a.postfix:a.prefix+a.values[f.fromNumber]+h+a.postfix):(b=a.prefix+z(f.fromNumber)+a.postfix,d=a.prefix+z(f.toNumber)+
h+a.postfix,h=f.fromNumber!==f.toNumber?a.prefix+z(f.fromNumber)+" \u2014 "+a.prefix+z(f.toNumber)+h+a.postfix:a.prefix+z(f.fromNumber)+h+a.postfix),A.html(b),B.html(d),w.html(h),b=A.outerWidth(!1),d=f.fromX-b/2+k,0>d&&(d=0),d>t-b&&(d=t-b),A[0].style.left=d+"px",h=B.outerWidth(!1),c=f.toX-h/2+k,0>c&&(c=0),c>t-h&&(c=t-h),B[0].style.left=c+"px",g=w.outerWidth(!1),k=f.fromX+(f.toX-f.fromX)/2-g/2+k,0>k&&(k=0),k>t-g&&(k=t-g),w[0].style.left=k+"px",d+b<c?(w[0].style.display="none",A[0].style.display="block",
B[0].style.display="block"):(w[0].style.display="block",A[0].style.display="none",B[0].style.display="none"),a.hideMinMax||a.hideFromTo||(D[0].style.display=k<Q||d<Q?"none":"block",E[0].style.display=k+g>t-R||c+h>t-R?"none":"block"),e.prop("value",parseFloat(f.fromNumber)+";"+parseFloat(f.toNumber)));a.from=f.fromNumber;a.to=f.toNumber;ja()},ja=function(){"function"!==typeof a.onFinish||y||J||a.onFinish.call(this,f);"function"!==typeof a.onChange||J||a.onChange.call(this,f);"function"===typeof a.onLoad&&
!y&&J&&(a.onLoad.call(this,f),J=!1)},ia=function(){n.addClass("irs-with-grid");var b,d="",c=0,c=0,e="",f=t-2*a.gridMargin;for(b=0;20>=b;b+=1)c=Math.floor(f/20*b),c>=f&&(c=f-1),e+='<span class="irs-grid-pol small" style="left: '+c+'px;"></span>';for(b=0;4>=b;b+=1)c=Math.floor(f/4*b),c>=f&&(c=f-1),e+='<span class="irs-grid-pol" style="left: '+c+'px;"></span>',u?(d=a.min+(a.max-a.min)/4*b,d=d/a.step*a.step,d=parseInt(d*u,10)/u):(d=Math.round(a.min+(a.max-a.min)/4*b),d=Math.round(d/a.step)*a.step,d=z(d)),
I&&(a.hideMinMax?(d=Math.round(a.min+(a.max-a.min)/4*b),d=Math.round(d/a.step)*a.step,d=0===b||4===b?a.values[d]:""):d=""),0===b?e+='<span class="irs-grid-text" style="left: '+c+'px; text-align: left;">'+d+"</span>":4===b?(c-=100,e+='<span class="irs-grid-text" style="left: '+c+'px; text-align: right;">'+d+"</span>"):(c-=50,e+='<span class="irs-grid-text" style="left: '+c+'px;">'+d+"</span>");Y.html(e);Y[0].style.left=a.gridMargin+"px"};M()}})},update:function(c){return this.each(function(){this.updateData(c)})},
remove:function(){return this.each(function(){this.removeSlider()})}};c.fn.ionRangeSlider=function(r){if(H[r])return H[r].apply(this,Array.prototype.slice.call(arguments,1));if("object"!==typeof r&&r)c.error("Method "+r+" does not exist for jQuery.ionRangeSlider");else return H.init.apply(this,arguments)}})(jQuery,document,window,navigator);

722
OI/TareaDetalle.aspx Normal file
View File

@@ -0,0 +1,722 @@
<%@ Page Title="" Language="C#" MasterPageFile="~/Site.master" AutoEventWireup="true" CodeFile="TareaDetalle.aspx.cs" Inherits="OI_TareaDetalle" %>
<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="Css" runat="Server">
<style>
.btn.btnCalendar {
padding: 5px 10px;
}
.btn.btn-circle.btn-icon-only.btnsmalli {
padding: 5px 7px 5px;
height: 27px;
width: 27px;
line-height: 1;
}
.btn.btnsmalli > i {
font-size: 10px;
}
.titletable {
background-color: #e1e5ec;
}
#Gvmiembros tr > td:nth-child(2) {
width: 30px;
text-align: right;
}
.mypaste:before {
content: "Pegar aquí";
}
.filediv .addropzone.dz-clickable:before {
margin-top: 20px;
}
.filediv .addropzone {
min-height: 100px;
}
.divArchivo {
padding: 15px;
text-align: center;
}
.divArchivo a {
color: #659be0;
font-size: 18px;
}
.divArchivo a i {
font-size: 32px;
line-height: 32px;
}
.itembaja {
color: #00CC00;
}
.itemmedia {
color: #000000;
}
.itemalta {
color: #FF0000;
}
.GVcheklist pre {
background-color: transparent;
border: none;
}
.GVcheklist .finished .pre {
text-decoration: line-through;
}
.GvActividades tr > td:nth-child(1) {
white-space: nowrap;
}
.labelitem {
margin-bottom: 0;
font-size: 13px;
color: #888888;
opacity: 1;
}
</style>
<link href="/Metronic/assets/global/plugins/ion.rangeslider/css/ion.rangeSlider.css" rel="stylesheet" type="text/css" />
<link href="/Metronic/assets/global/plugins/ion.rangeslider/css/ion.rangeSlider.skinFlat.css" rel="stylesheet" type="text/css" />
<link href="/Metronic/assets/global/plugins/bootstrap-markdown/css/bootstrap-markdown.min.css" rel="stylesheet" type="text/css" />
<link href="/Metronic/assets/global/plugins/bootstrap-summernote/summernote.css" rel="stylesheet" type="text/css" />
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="E" runat="Server">
<asp:UpdatePanel ID="UpTitulo" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<asp:Label ID="LtlTitulo" runat="server"></asp:Label>
</ContentTemplate>
</asp:UpdatePanel>
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="HB" runat="Server">
</asp:Content>
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
<asp:UpdatePanel ID="UpAcciones" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<li>
<asp:LinkButton ID="LnkAgregarCheckList" OnClick="LnkAgregarCheckList_Click" runat="server"><i class="fa fa-plus"></i> Agregar CheckList</asp:LinkButton></li>
<li>
<asp:LinkButton ID="LnkcambiarEstatus" OnClick="LnkcambiarEstatus_Click" runat="server"><i class="fa fa-exchange"></i>Cambiar Estatus</asp:LinkButton></li>
<li>
<asp:LinkButton ID="LnkAgregarActividad" OnClick="LnkAgregarActividad_Click" runat="server"><i class="fa fa-plus"></i> Agregar Comentario</asp:LinkButton></li>
<li>
<asp:LinkButton ID="LnkAgregarTema" OnClick="LnkAgregarTema_Click" runat="server"><i class="fa fa-plus"></i> Agregar Tema</asp:LinkButton></li>
<li>
<asp:LinkButton ID="LnkUpFile" OnClick="LnkUpFile_Click" Visible="false" runat="server"><i class="fa fa-plus"></i> Agregar Archivo</asp:LinkButton></li>
</ContentTemplate>
</asp:UpdatePanel>
</asp:Content>
<asp:Content ID="Content6" ContentPlaceHolderID="HA" runat="Server">
</asp:Content>
<asp:Content ID="Content7" ContentPlaceHolderID="C" runat="Server">
<asp:UpdatePanel ID="UpContenido" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<div class="row">
<div class="col-md-8">
<asp:Panel runat="server" ID="portletTarea" class="portlet light smmallpadding bordered">
<div class="portlet-title">
<div class="caption font-green">
<i class="icon-pin font-green"></i>
<span class="caption-subject bold uppercase">Tarea</span>
</div>
<div class="tools">
<a href="javascript:;" class="collapse" data-original-title="" title=""></a>
</div>
</div>
<div class="portlet-body rowpadding">
<div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtAsunto" runat="server" CssClass="form-control" CausesValidation="true"></asp:TextBox>
<asp:RequiredFieldValidator ID="RFVAsunto" runat="server" CssClass="help-block errorimput" ControlToValidate="TxtAsunto" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Asunto''</b> es necesario, por favor ingréselo." ValidationGroup="GrpTarea"></asp:RequiredFieldValidator>
<asp:Label runat="server" Text="Asunto:" AssociatedControlID="TxtAsunto"></asp:Label>
</div>
<div class="form-group form-md-line-input">
<asp:TextBox ID="TxtDescripcion" runat="server" CssClass="form-control" CausesValidation="true" TextMode="MultiLine" Rows="2"></asp:TextBox>
<asp:RequiredFieldValidator ID="RfvDescripcion" runat="server" CssClass="help-block errorimput" ControlToValidate="TxtDescripcion" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Descripción''</b> es necesario, por favor ingréselo." ValidationGroup="GrpTarea"></asp:RequiredFieldValidator>
<asp:Label runat="server" Text="Descripción" AssociatedControlID="TxtDescripcion"></asp:Label>
</div>
<asp:Panel runat="server" ID="PnlUsuarios" Visible="false">
<div class="panel panel-default" style="margin-bottom: 5px;">
<div class="panel-heading" style="display: inline-block; width: 19%; border-bottom-width: 0px; margin: 0px;">
<h3 class="panel-title">Para</h3>
</div>
<div class="panel-body" style="display: inline-block; width: 79%;">
<asp:Literal ID="LtlPara" runat="server"></asp:Literal>
</div>
</div>
<div class="panel panel-default" style="margin-bottom: 5px;">
<div class="panel-heading" style="display: inline-block; width: 19%; border-bottom-width: 0px; margin: 0px;">
<h3 class="panel-title">C. C. Para</h3>
</div>
<div class="panel-body" style="display: inline-block; width: 79%;">
<asp:Literal ID="LtlCCPara" runat="server"></asp:Literal>
</div>
</div>
</asp:Panel>
<div class="row">
<div class="col-sm-6">
<div class="input-group form-group form-md-line-input date date-picker " data-date-format="dd/mm/yyyy hh:mm" style="display: inline-block;">
<asp:TextBox ID="txtFechaI" runat="server" autocomplete="false" CssClass="form-control input-sm ADDateTimePicker" CausesValidation="true" MaxLength="18" Width="132px "></asp:TextBox>
<asp:RequiredFieldValidator ID="RFVtxtFechaI" runat="server" ControlToValidate="txtFechaI" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha Inicio''</b> es necesario, por favor seleccione uno." ValidationGroup="GrpTarea"></asp:RequiredFieldValidator>
<asp:Label AssociatedControlID="txtFechaI" runat="server" Text="Fecha Inicio"></asp:Label>
<%--<ajax:MaskedEditExtender ID="MEEFechaI" runat="server" TargetControlID="txtFechaI" Mask="99/99/9999 99:99" MaskType="DateTime" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>--%>
<ajax:ValidatorCalloutExtender ID="VcoFechaI" runat="server" HighlightCssClass="vco" TargetControlID="RFVtxtFechaI" Width="350px"></ajax:ValidatorCalloutExtender>
</div>
</div>
<div class="col-sm-6">
<div class="input-group form-group form-md-line-input date date-picker " data-date-format="dd/mm/yyyy hh:mm" style="display: inline-block;">
<asp:TextBox ID="txtFechaF" runat="server" autocomplete="false" CssClass="form-control input-sm ADDateTimePicker" CausesValidation="true" MaxLength="18" Width="132px " placeholder=""></asp:TextBox>
<asp:RequiredFieldValidator ID="RFVtxtFechaF" runat="server" ControlToValidate="txtFechaF" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha Fin''</b> es necesario, por favor seleccione uno." ValidationGroup="GrpTarea"></asp:RequiredFieldValidator>
<asp:Label AssociatedControlID="txtFechaF" runat="server" Text="Fecha Fin"></asp:Label>
<%--<ajax:MaskedEditExtender ID="MEEFechaI" runat="server" TargetControlID="txtFechaI" Mask="99/99/9999 99:99" MaskType="DateTime" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>--%>
<ajax:ValidatorCalloutExtender ID="VcoFechaF" runat="server" HighlightCssClass="vco" TargetControlID="RFVtxtFechaF" Width="350px"></ajax:ValidatorCalloutExtender>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-6">
<div class="form-group form-md-line-input">
<asp:DropDownList ID="DdlPrioridad" runat="server" CssClass="form-control select2me input-sm" Width="100%">
<asp:ListItem Selected="True" Text="Seleccione" Value="-1"></asp:ListItem>
<asp:ListItem Text="Baja" Value="1" class="itembaja"></asp:ListItem>
<asp:ListItem Text="Media" Value="2" class="itemmedia"></asp:ListItem>
<asp:ListItem Text="Alta" Value="3" class="itemalta"></asp:ListItem>
</asp:DropDownList>
<asp:RequiredFieldValidator ID="RFVPrioridad" runat="server" ControlToValidate="DdlPrioridad" Display="None" ErrorMessage="El campo <b>''Prioridad''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpTarea"></asp:RequiredFieldValidator>
<asp:Label runat="server" AssociatedControlID="DdlPrioridad">Prioridad:</asp:Label>
<ajax:ValidatorCalloutExtender ID="VCOPrio" runat="server" TargetControlID="RFVPrioridad" HighlightCssClass="vco" Width="300px"></ajax:ValidatorCalloutExtender>
</div>
</div>
<div class="col-sm-6">
<div class="form-group form-md-line-input">
<asp:DropDownList ID="DdlTema" runat="server" CssClass="form-control select2me input-sm" DataValueField="CveRevision" DataTextField="Revision" Width="100%">
<asp:ListItem Selected="True" Text="Seleccione" Value="-1"></asp:ListItem>
</asp:DropDownList>
<asp:Label runat="server" AssociatedControlID="DdlTema">Tema:</asp:Label>
</div>
</div>
</div>
</div>
</asp:Panel>
</div>
<div class="col-md-4">
<asp:Panel runat="server" ID="portletEstatus" class="portlet light smmallpadding bordered" Style="margin-bottom: 15px;">
<div class="portlet-title">
<div class="caption font-green">
<i class="icon-pin font-green"></i>
<span class="caption-subject bold uppercase">Estatus</span>
</div>
<div class="tools">
<a href="javascript:;" class="collapse" data-original-title="" title=""></a>
</div>
</div>
<div class="portlet-body rowpadding">
<asp:UpdatePanel ID="UpEstatus" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<div class="form-group form-md-line-input">
<asp:DropDownList ID="DdlEventoEstatus" Visible="true" runat="server" DataValueField="CveEventoEstatus" CssClass="form-control select2me input-sm" Width="100%" DataTextField="EventoEstatus">
</asp:DropDownList>
<asp:Label runat="server" AssociatedControlID="DdlEventoEstatus">Estatus:</asp:Label>
</div>
<div class="">
<asp:Label runat="server" CssClass="labelitem" AssociatedControlID="TxtAvance">Avance:</asp:Label>
<asp:TextBox ID="TxtAvance" runat="server" CssClass="form-control TxtAvance" CausesValidation="true"></asp:TextBox>
</div>
<asp:Button ID="BtnUpAvance" OnClick="BtnUpAvance_Click" CssClass="hidden BtnUpAvance" runat="server" Text="ActualizarAvance" />
</ContentTemplate>
</asp:UpdatePanel>
</div>
</asp:Panel>
<asp:Panel runat="server" ID="portletArchivo" class="portlet light smmallpadding bordered">
<div class="portlet-title">
<div class="caption font-green">
<i class="fa fa-file-archive-o font-green"></i>
<span class="caption-subject bold uppercase">Archivo</span>
</div>
<div class="actions">
<div class="btn-group">
</div>
</div>
<div class="tools">
<a href="javascript:;" class="collapse" data-original-title="" title=""></a>
</div>
</div>
<div class="portlet-body rowpadding filediv">
<asp:TextBox ID="TxtArchivo" CssClass="ADSdropzone hidden" runat="server"></asp:TextBox>
<div class="divArchivo">
<asp:HyperLink ID="HypArchivo" runat="server" Target="_blank">
<asp:Literal ID="LtlArchivo" runat="server"></asp:Literal><br />
<i class="fa fa-download"></i>
</asp:HyperLink>
</div>
</div>
</asp:Panel>
</div>
</div>
<div class="row">
<asp:UpdatePanel ID="UpChkList" runat="server" class="col-md-8" UpdateMode="Conditional">
<ContentTemplate>
<asp:Panel runat="server" ID="portletChekList" Visible="false" class="portlet light smmallpadding bordered" DefaultButton="LnkAgregarchklistitem">
<div class="portlet-title">
<div class="caption font-green">
<i class="fa fa-check-square-o font-green"></i>
<span class="caption-subject bold uppercase">CheckList <span id="Contador"></span></span>
</div>
<div class="tools">
<a href="javascript:;" class="collapse" data-original-title="" title=""></a>
</div>
</div>
<div class="portlet-body rowpadding">
<div class="row">
<div class="col-md-8">
<div class="form-group form-md-line-input">
<asp:TextBox ID="TxtActividad" runat="server" CssClass="form-control" CausesValidation="true"></asp:TextBox>
<asp:Label runat="server" Text="Actividad" AssociatedControlID="TxtActividad"></asp:Label>
</div>
</div>
<div class="col-md-4">
<asp:Button ID="LnkSinfuncion" OnClick="LnkSinfuncion_Click" UseSubmitBehavior="false" CssClass="btn btn-default LnkSinfuncion hidden" runat="server"></asp:Button>
<asp:LinkButton ID="LnkAgregarchklistitem" OnClick="LnkAgregarchklistitem_Click" CssClass="btn btn-default" runat="server">Agregar</asp:LinkButton>
<%--<a class="btn btn-default">Agregar</a>--%>
</div>
</div>
<asp:GridView ID="GVcheklist" runat="server" GridLines="None" CssClass="table table-hover table-striped ScrollAD Widthall GVcheklist" AutoGenerateColumns="False"
DataKeyNames="CveEventoCheckList,CveEvento,CveTipoEvento,EventoComentario,Estatus,CveUsuario,Usuario,FechaIng">
<Columns>
<asp:TemplateField HeaderText="" ItemStyle-Width="30">
<ItemTemplate>
<asp:CheckBox ID="ChkEstatus" Text=" " OnCheckedChanged="ChkEstatus_CheckedChanged" runat="server" data-valor='<%# Extensiones.ModExtensiones.Encripta(Eval("CveEventoCheckList").ToString())%>' Checked='<%# Eval("Estatus")%>' />
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Actividad">
<ItemTemplate>
<%--<pre>--%>
<span class="pre">
<asp:Literal ID="lbleventoComentario" runat="server" Text='<%# Eval("EventoComentario")%>'> </asp:Literal>
</span>
<%--</pre>--%>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField ItemStyle-Width="30" Visible="false">
<ItemTemplate>
<asp:LinkButton data-toggle="tooltip" title="Editar" ID="LnkEditar" OnClick="LnkEditarCheck_Click" CssClass="btn btn-circle btn-sm green" runat="server" Text="<i class='fa fa-pencil'></i>"></asp:LinkButton>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField ItemStyle-Width="30">
<ItemTemplate>
<asp:LinkButton ID="LnkD" runat="server" OnClick="LnkEliminarchek_Click" CssClass="btn btn-circle btn-sm red" Text="<i class='icon-trash'></i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea eliminar el cheklist?" data-btn-ok-label="si" />
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</div>
</asp:Panel>
</ContentTemplate>
</asp:UpdatePanel>
<div class="col-md-4 ">
<asp:Panel runat="server" ID="portletMiembros" class="portlet light smmallpadding bordered">
<div class="portlet-title">
<div class="caption font-green">
<i class="fa fa-user-plus font-green"></i>
<span class="caption-subject bold uppercase">Miembros</span>
</div>
<div class="tools">
<a href="javascript:;" class="collapse" data-original-title="" title=""></a>
</div>
</div>
<div class="portlet-body rowpadding">
<%--<div class="row">
<div class="col-md-10">
<div class="form-group form-md-line-input">
<asp:DropDownList ID="DdlUsuario" Visible="true" runat="server" CssClass="form-control select2me input-sm" Width="100%" DataValueField="CveUsuario" DataTextField="Usuario">
</asp:DropDownList>
<asp:Label runat="server" AssociatedControlID="DdlUsuario">Usuario:</asp:Label>
</div>
</div>
<div class="col-md-2" style="direction: rtl; padding-top: 15px;">
<a class="btn btn-default"><i class="fa fa-plus"></i></a>
</div>
</div>
<table id="Gvmiembros" class="Widthall">
<tr class="titletable">
<td colspan="2">Para</td>
</tr>
<tr>
<td>jorge caudillo</td>
<td><a class="btn btn-circle btn-icon-only red btnsmalli"><i class='icon-trash'></i></a></td>
</tr>
<tr class="titletable">
<td colspan="2">Con copia para</td>
</tr>
<tr>
<td>Julian Moreno</td>
<td><a class="btn btn-circle btn-icon-only red btnsmalli"><i class='icon-trash'></i></a></td>
</tr>
</table>--%>
<asp:GridView ID="GVUsuarios" runat="server" AutoGenerateColumns="false" DataKeyNames="CveUsuario,Nombre,Correo,Empresa"
CssClass="table table-striped table-advance table-hover Widthall ScrollAD GVUsuarios" GridLines="None" data-height="200">
<Columns>
<asp:TemplateField>
<ItemStyle HorizontalAlign="Center" Width="50px" />
<HeaderTemplate>Para</HeaderTemplate>
<ItemTemplate>
<asp:CheckBox ID="ChkPara" Text=" " runat="server" />
<%--<asp:CheckBox ID="ChkPara" CssClass="icheck " data-checkbox="icheckbox_flat-red" runat="server" />--%>
<ajax:MutuallyExclusiveCheckBoxExtender ID="MECBE" runat="server" TargetControlID="ChkPara" Key="Para"></ajax:MutuallyExclusiveCheckBoxExtender>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<ItemStyle HorizontalAlign="Center" Width="50px" />
<HeaderTemplate>C. C. Para</HeaderTemplate>
<ItemTemplate>
<asp:CheckBox ID="ChkCCP" Checked="false" runat="server" />
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>Usuario</HeaderTemplate>
<ItemTemplate>
<asp:Literal ID="LtlNombre" runat="server" Text='<%# Eval("Nombre") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>Rol</HeaderTemplate>
<ItemTemplate>
<asp:Literal ID="LtlRol" runat="server" Text='<%# Eval("Rol") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</div>
</asp:Panel>
</div>
</div>
<div class="text-center">
<asp:LinkButton ID="LnkGuardar" OnClick="LnkGuardar_Click" CssClass="btn btn-primary" ValidationGroup="GrpTarea" runat="server">Guardar</asp:LinkButton>
</div>
<br />
<asp:Panel runat="server" ID="portletActividades" class="portlet light smmallpadding bordered">
<div class="portlet-title">
<div class="caption font-green">
<i class="fa fa-bars font-green"></i>
<span class="caption-subject bold uppercase">Registro de actividades</span>
</div>
<div class="tools">
<a href="javascript:;" class="expand" data-original-title="" title=""></a>
</div>
</div>
<div class="portlet-body rowpadding" style="display: none;">
<%--<table class="Widthall table ">
<tbody>
<tr>
<td>19/04/2020 </td>
<td>comentario con archivo</td>
<td><a><i class="fa fa-download"></i></a></td>
</tr>
<tr>
<td>19/04/2020 </td>
<td>comentario</td>
</tr>
<tr>
<td>19/04/2020 </td>
<td>Se termino la activada y del checklist</td>
</tr>
<tr>
<td>19/04/2020 </td>
<td>Se termino la activada x del checklist</td>
</tr>
<tr>
<td>19/04/2020 </td>
<td>Se agrego la activada p al checklist</td>
</tr>
<tr>
<td>19/04/2020 </td>
<td>Se agrego la activada w al checklist</td>
</tr>
<tr>
<td>19/04/2020 </td>
<td>Se agrego la activada z al checklist</td>
</tr>
<tr>
<td>19/04/2020 </td>
<td>Se agrego la activada y al checklist</td>
</tr>
<tr>
<td>19/04/2020 </td>
<td>Se agrego la activada x al checklist</td>
</tr>
<tr>
<td>19/04/2020 </td>
<td>Se registro la tarea oi</td>
</tr>
</tbody>
</table>--%>
<asp:UpdatePanel ID="UpActividades" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<asp:GridView ID="GvActividades" runat="server" AutoGenerateColumns="False" CssClass="table table-striped table-advance table-hover Widthall ScrollAD GvActividades"
OnRowDataBound="GvActividades_RowDataBound"
GridLines="None">
<Columns>
<asp:BoundField DataField="FechaIng" DataFormatString="{0:dd/MM/yyyy HH:mm}" HeaderText="Fecha">
<ItemStyle Width="90px" HorizontalAlign="Center" />
</asp:BoundField>
<asp:BoundField DataField="NombreUsuario" DataFormatString="&nbsp;{0}" HeaderText="Usuario">
<ItemStyle Width="200px" />
</asp:BoundField>
<%--<asp:BoundField DataField="EventoComentario" DataFormatString="&nbsp;{0}" HeaderText="Observación"></asp:BoundField>--%>
<asp:TemplateField HeaderText="Observación">
<ItemTemplate>
<asp:Literal runat="server" Text='<%# Eval("EventoComentario").ToString().Replace("\n","<br/>") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="">
<ItemTemplate>
<asp:HyperLink Target="_blank" ID="HplA" runat="server"><i class="fa fa-download"></i></asp:HyperLink>
<%--<asp:ImageButton ID="ImBtnPub" ToolTip="Publicar Documento" Visible="False" ImageUrl="/Imagenes/PublicarDoc.jpg" Height="18px" runat="server" />--%>
</ItemTemplate>
<ItemStyle HorizontalAlign="Center" Width="40px" />
</asp:TemplateField>
</Columns>
<RowStyle CssClass="Texto" />
<AlternatingRowStyle CssClass="TextoAlterno" />
<HeaderStyle CssClass="Titulos" />
</asp:GridView>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</asp:Panel>
</ContentTemplate>
</asp:UpdatePanel>
<div id='<%= iddivAgregarTema %>' class="modal ADS fade" role="dialog">
<div class="modal-dialog">
<asp:UpdatePanel ID="UpdatePanel1" class="modal-content " tabindex="-1" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span> </button>
<h4 class="modal-title" style="text-align: left">
<asp:Literal ID="Literal2" runat="server">Agregar Actividad</asp:Literal></h4>
</div>
<div class="modal-body">
<div class="form-group form-md-line-input">
<asp:TextBox ID="TxtTema" runat="server" CssClass="form-control" CausesValidation="true" TextMode="MultiLine" Rows="1"></asp:TextBox>
<asp:Label runat="server" Text="Tema" AssociatedControlID="TxtTema"></asp:Label>
</div>
</div>
<div class="modal-footer">
<asp:LinkButton ID="BtnAgregarTema" OnClick="BtnAgregarTema_Click" CssClass="btn btn-default" runat="server">Agregar</asp:LinkButton>
<button data-dismiss="modal" class="btn btn-default">Cancelar</button>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</div>
<div id='<%= iddivAgregar %>' class="modal ADS fade" role="dialog">
<div class="modal-dialog ">
<asp:UpdatePanel ID="UpModalActividad" class="modal-content " tabindex="-1" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span> </button>
<h4 class="modal-title" style="text-align: left">
<asp:Literal ID="LtleventoTitle" runat="server">Agregar Actividad</asp:Literal></h4>
</div>
<div class="modal-body">
<div class="form-group form-md-line-input">
<asp:TextBox ID="TxtComentario" runat="server" CssClass="form-control" CausesValidation="true" TextMode="MultiLine" Rows="1"></asp:TextBox>
<asp:Label runat="server" Text="Agregar Comentario" AssociatedControlID="TxtComentario"></asp:Label>
</div>
<asp:TextBox ID="Txtfilecomentario" CssClass="ADSdropzone hidden" runat="server"></asp:TextBox>
</div>
<div class="modal-footer">
<asp:LinkButton ID="BtnAgregarComentario" OnClick="BtnAgregarComentario_Click" CssClass="btn btn-default" runat="server">Agregar</asp:LinkButton>
<button data-dismiss="modal" class="btn btn-default">Cancelar</button>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</div>
<div id='<%= iddivCambiarEstatus %>' class="modal ADS fade" role="dialog">
<div class="modal-dialog">
<asp:UpdatePanel ID="UpModalCambiarEstatus" class="modal-content " tabindex="-1" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span> </button>
<h4 class="modal-title" style="text-align: left">
<asp:Literal ID="Literal1" runat="server">Cambiar Estatus</asp:Literal></h4>
</div>
<div class="modal-body">
<div class="form-group form-md-line-input">
<asp:DropDownList ID="DDlEstatus" Visible="true" runat="server" DataValueField="CveEventoEstatus" CssClass="form-control select2me input-sm" Width="100%" DataTextField="EventoEstatus">
</asp:DropDownList>
<asp:Label runat="server" AssociatedControlID="DdlEventoEstatus">Estatus:</asp:Label>
</div>
</div>
<div class="modal-footer">
<asp:LinkButton ID="BtnCambiarEstatus" OnClick="BtnCambiarEstatus_Click" CssClass="btn btn-default" ValidationGroup="GrpTarea" runat="server">Guardar</asp:LinkButton>
<button data-dismiss="modal" class="btn btn-default">Cancelar</button>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</div>
<div id='<%= iddivAgregarArchivo %>' class="modal ADS fade" role="dialog">
<div class="modal-dialog ">
<asp:UpdatePanel ID="UpdatePanel2" class="modal-content " tabindex="-1" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span> </button>
<h4 class="modal-title" style="text-align: left">
<asp:Literal ID="Literal3" runat="server">Actualizar Archivo</asp:Literal></h4>
</div>
<div class="modal-body">
<asp:TextBox ID="txtActualizarArchivo" CssClass="ADSdropzone hidden" runat="server"></asp:TextBox>
</div>
<div class="modal-footer">
<asp:LinkButton ID="BtnActualizarArchivo" OnClick="BtnActualizarArchivo_Click" CssClass="btn btn-default" runat="server">Agregar</asp:LinkButton>
<button data-dismiss="modal" class="btn btn-default">Cancelar</button>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</div>
</asp:Content>
<asp:Content ID="Content8" ContentPlaceHolderID="JS" runat="Server">
<script src="/Metronic/assets/global/plugins/ion.rangeslider/js/ion.rangeSlider.min.js" type="text/javascript"></script>
<script src="/Metronic/assets/global/plugins/bootstrap-markdown/lib/markdown.js" type="text/javascript"></script>
<script src="/Metronic/assets/global/plugins/bootstrap-markdown/js/bootstrap-markdown.js" type="text/javascript"></script>
<script src="/Metronic/assets/global/plugins/bootstrap-summernote/summernote.min.js" type="text/javascript"></script>
<script>
function CargaPickers() {
$.datetimepicker.setLocale('es');
$('input.ADDateTimePicker').each(function () {
var TThis = $(this);
TThis.datetimepicker({
dayOfWeekStart: 1,
lang: 'es',
format: 'd/m/Y H:i',
formatDate: 'd/m/Y H:i',
step: 30
});
var Div = TThis.parent()
var boton = document.createElement('span');
boton.className = "input-group-btn"
var subboton = document.createElement('a')
subboton.className = "btn default btnCalendar"
subboton.innerHTML = "<i class='fa fa-calendar'></i>"
subboton.addEventListener('click', function () {
TThis.datetimepicker('show')
});
boton.appendChild(subboton)
var agregar = true;
for (var i = 0; i < Div[0].children.length; i++) {
if (Div[0].children[i].isEqualNode(boton)) {
agregar = false;
}
}
if (agregar) {
Div[0].appendChild(boton);
}
//Div[0].appendChild(boton)
});
}
//CssClass="icheck"
loaderinited = loaderinit;
function setchecklistitulo() {
let Total = $('.GVcheklist input[type="checkbox"]').length;
let Terminados = $('.GVcheklist input[type="checkbox"]:checked').length;
$('#Contador').text('(' + Terminados + '/' + Total + ')');
$('.GVcheklist input[type="checkbox"]:checked').closest('tr').addClass('finished');
CambiarTitulo('' + Terminados + '/' + Total);
let checks = $('.GVcheklist input[type="checkbox"]:not(.chadd)');
checks.addClass('chadd');
checks.change(function () {
loaderinit = (function () { });
let ischeked = $(this).is(':checked');
$(this).closest('tr').toggleClass('finished');
$(".LnkSinfuncion").click();
});
}
function CambiarTitulo(cadena) {
let TTitulo = $('#E_LtlTitulo')
let texto = TTitulo.text();
let splited = texto.split(" ");
let size = splited[splited.length - 1].length;
texto = texto.substring(0, texto.length - size) + cadena;
TTitulo.text(texto);
}
var avancecambio=0;
function barraavance() {
let item = $(".TxtAvance:not(.ionRangeSlider)")
let Valorxyz = $(".TxtAvance").val();
if (item.length > 0) {
item.toggleClass('ionRangeSlider');
item.ionRangeSlider({
min: 0,
max: 100,
onChange: (function () {
setTimeout(function () { if ($(".TxtAvance").val() != Valorxyz) { avancecambio = 1 } }, 50);
})
});
}
}
var prm = Sys.WebForms.PageRequestManager.getInstance();
prm.add_endRequest(function (s, e) { loaderinit = loaderinited; });
Sys.Application.add_load(function (s, e) {
CargaPickers();
setchecklistitulo();
barraavance();
//$('.GVcheklist input[type="checkbox"]:checked').addClass('icheck setclass');
});
$(document).ready(function () {
$(document).mouseup(function () {
setTimeout( function () { if (avancecambio == 1) { loaderinit = (function () { });$('.BtnUpAvance').click(); avancecambio = 0; } }, 100);
});
CargaPickers();
setchecklistitulo();
barraavance();
//$('.GVUsuarios input[type="checkbox"]:not(.setclass)').addClass('icheck setclass');
});
</script>
</asp:Content>

691
OI/TareaDetalle.aspx.cs Normal file
View File

@@ -0,0 +1,691 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Extensiones;
public partial class OI_TareaDetalle : ClsPaginas
{
#region Propiedades
public const string iddivAgregar = "divModalAgregarActividad";
public const string iddivAgregarArchivo = "divModalAgregarArchivo";
public const string iddivAgregarTema = "divModalAgregartema";
public const string iddivCambiarEstatus = "divModalCambiarEstatus";
public int RCveEvento { get { return ViewState["RCveEvento"] != null ? ViewState["RCveEvento"].ToString().ToEntero() : 0; } set { ViewState["RCveEvento"] = value; } }
public int Folio { get { return ViewState["Folio"] != null ? ViewState["Folio"].ToString().ToEntero() : 0; } set { ViewState["Folio"] = value; } }
public decimal Avance { get { return ViewState["Avance"] != null ? ViewState["Avance"].ToString().ToEntero() : 0; } set { ViewState["Avance"] = value; } }
public int CveUsuarioPara { get { return ViewState["CveUsuarioPara"].ToString().ToEntero(); } set { ViewState["CveUsuarioPara"] = value; } }
public int CveUsuarioCCPara { get { return ViewState["CveUsuarioCCPara"].ToString().ToEntero(); } set { ViewState["CveUsuarioCCPara"] = value; } }
public bool EsNuevo { get { return Convert.ToBoolean(ViewState["EsNuevo"]); } set { ViewState["EsNuevo"] = value; } }
public System.Data.DataTable CheckListNew { get { return ViewState["CheckListNew"] != null ? (System.Data.DataTable)ViewState["CheckListNew"] : null; } set { ViewState["CheckListNew"] = value; } }
public int chklistitemindex { get { return ViewState["chklistitemindex"] != null ? ViewState["chklistitemindex"].ToString().ToEntero() : 0; } set { ViewState["chklistitemindex"] = value; } }
#endregion
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
EsNuevo = true;
CveUsuarioPara = 0;
CveUsuarioCCPara = 0;
if (Request["Archivo"] != null)
{
string strArchivo = string.Format("{0}{1}", UsuarioActual.Empresa.Ruta, ModExtensiones.Decripta(Request["Archivo"].ToString()));
if (System.IO.File.Exists(strArchivo))
{
try
{
string filename = ModExtensiones.Decripta(Request["filename"].ToString());
System.IO.FileInfo file = new System.IO.FileInfo(strArchivo);
string mimeType = "text/plain";
try { mimeType = MimeMapping.GetMimeMapping(strArchivo); }
catch (Exception) { }
// Response.Write(path)
Response.Clear();
Response.ClearHeaders();
Response.ClearContent();
Response.AddHeader("Content-Disposition", $"attachment; filename= {Uri.EscapeDataString(filename)}");
Response.AddHeader("Content-Length", file.Length.ToString());
Response.ContentType = mimeType;
Response.Flush();
Response.TransmitFile(file.FullName);
Response.End();
}
catch (Exception)
{
this.RegistraScript("window.close();");
}
}
else
{
this.RegistraScript("window.close();");
}
}
else
{
CargaTemas();
CargaEstatus();
cargaUsuarios();
if (Request["CveEvento"] != null)
{
RCveEvento = Request["CveEvento"].ToString().ToEntero();
}
if (RCveEvento > 0)
{
EsNuevo = false;
LoadTarea();
}
else
{
LtlTitulo.Text = "Tarea Nueva";
TxtArchivo.Visible = true;
CveUsuarioCCPara = UsuarioActual.CveUsuario;
}
SetUsuarios();
HypArchivo.Visible = !TxtArchivo.Visible;
}
}
}
private void CargaTemas()
{
DdlTema.DataSource = get_GlobalDTOIRevision(UsuarioActual.CveEmpresa).FiltraParametros(string.Format("CveUsuario = {0}", UsuarioActual.CveUsuario));
DdlTema.DataBind();
DdlTema.Items.Insert(0, new ListItem("Seleccione", "-1"));
}
private void CargaEstatus()
{
DdlEventoEstatus.DataSource = GlobalDTOIEstatusEventos;//get_GlobalDTOIRevision(UsuarioActual.CveEmpresa).FiltraParametros(string.Format("CveUsuario = {0}", UsuarioActual.CveUsuario));
DDlEstatus.DataSource = DdlEventoEstatus.DataSource;
DdlEventoEstatus.DataBind();
DDlEstatus.DataBind();
DdlEventoEstatus.Enabled = false;
//DdlEventoEstatus.Items.Insert(0, new ListItem("Seleccione", "-1"));
}
private void cargaUsuarios()
{
string FiltroAD = "";
GVUsuarios.DataSource = get_GlobalDTUsuarios().FiltraParametros(String.Format("CveEmpresa = {0} AND Estatus =1 {1}", UsuarioActual.CveEmpresa, FiltroAD), "Rol ASC");
GVUsuarios.DataBind();
}
private void cargaActividades(ClsOIEventos ObjOI)
{
GvActividades.DataSource = null;
if (ObjOI.GetEventosComentarios(RCveEvento))
{
GvActividades.DataSource = ObjOI.DtResultados;
}
GvActividades.DataBind();
UpActividades.Update();
}
private void SetUsuarios()
{
StringBuilder para = new StringBuilder();
StringBuilder CCpara = new StringBuilder();
foreach (GridViewRow gvRow in GVUsuarios.Rows)
{
if (gvRow.RowType == DataControlRowType.DataRow)
{
int CveUsuario = gvRow.DataKey("CveUsuario").ToString().ToEntero();
CheckBox chkpara = gvRow.FCCheckBox("ChkPara");
CheckBox chkCCpara = gvRow.FCCheckBox("ChkCCP");
chkpara.Checked = false;
chkCCpara.Checked = false;
if (EsNuevo)
{
chkpara.Enabled = true;
chkCCpara.Enabled = true;
//if (CveUsuario == CveUsuarioCCPara)
//{
// chkCCpara.Enabled = false;
//}
}
else
{
chkpara.Enabled = false;
chkCCpara.Enabled = false;
}
if (CveUsuario == CveUsuarioPara)
{
chkpara.Checked = true;
para.AppendFormat("\"{0}\"",gvRow.DataKey("Nombre").ToString());
}
if (CveUsuario == CveUsuarioCCPara)
{
chkCCpara.Checked = true;
CCpara.AppendFormat("\"{0}\"", gvRow.DataKey("Nombre").ToString());
}
}
LtlPara.Text = para.ToString();
LtlCCPara.Text = CCpara.ToString();
}
}
public void LoadTarea()
{
GVcheklist.DataSource = new System.Data.DataTable();
using (ClsOIEventos ObjOI_E = new ClsOIEventos())
{
if (ObjOI_E.GetOI_Eventos2(RCveEvento, UsuarioActual.CveEmpresa) && ObjOI_E.DtResultados.Rows.Count > 0)
{
PnlUsuarios.Visible = true;
portletMiembros.Visible = false;
LnkUpFile.Visible = true;
System.Data.DataRow drow = ObjOI_E.DtResultados.Rows[0];
Folio = drow["Folio"].ToString().ToEntero();
Avance = drow["Avance"].ToString().ToDecimal();
TxtAsunto.Text = drow["Asunto"].ToString();
TxtDescripcion.Text = drow["Descripcion"].ToString();
DdlPrioridad.SelectedValueExist(drow["Prioridad"].ToString());
txtFechaI.Text = string.Format("{0:dd/MM/yyyy HH:mm}", drow["FechaInicio"]);
txtFechaF.Text = string.Format("{0:dd/MM/yyyy HH:mm}", drow["FechaFin"]);
DdlTema.SelectedValueExist(drow["CveRevision"].ToString());
DdlEventoEstatus.SelectedValueExist(drow["CveEventoEstatus"].ToString());
DDlEstatus.SelectedValueExist(drow["CveEventoEstatus"].ToString());
HypArchivo.Text = string.Format("{0}<br /><i class=\"fa fa-download\"></i>", drow["Archivo"].ToString());
HypArchivo.NavigateUrl = string.Format("~/OI/TareaDetalle.aspx?Archivo={0}&filename={1}", ModExtensiones.Encripta(string.Format("OIFiles\\{0}\\{1}", Folio, drow["Archivo"])), ModExtensiones.Encripta(drow["Archivo"].ToString()));
TxtArchivo.Visible = (drow["Archivo"].ToString().Length == 0);
portletArchivo.Visible = !TxtArchivo.Visible;
LnkUpFile.Text = (portletArchivo.Visible ? "Actualizar archivo" : "Agregar archivo");
CveUsuarioCCPara = drow["CveUsuarioDe"].ToString().ToEntero();
CveUsuarioPara = drow["CveUsuarioPara"].ToString().ToEntero();
TxtAvance.Text = string.Format("{0:##0}", drow["Avance"]);
//OIE.[CveEvento], OIE.[CveTipoEvento], OIE.[Folio], OIE.[Asunto], OIE.[Descripcion], OIE.[Prioridad], OIE.[CveUsuarioDe], OIE.[CveUsuarioPara],
//OIE.[CveEventoEstatus], OIE.[FechaInicio], OIE.[FechaFin], OIE.[FechaRealTermino], OIE.[CveRevision], OIE.[Archivo], OIE.[FechaIng],
//OIE.[CveUsuarioIng], OIE.[CveEmpresa], OIE.[CveUsuarioModifico], OIE.[Avance]
LtlTitulo.Text = drow["Titulo"].ToString();
if (ObjOI_E.Getcheklist(RCveEvento))
{
GVcheklist.DataSource = ObjOI_E.DtResultados;
if (ObjOI_E.DtResultados.Rows.Count > 0)
{
portletChekList.Visible = true;
LnkAgregarCheckList.Visible = false;
}
}
cargaActividades(ObjOI_E);
}
}
GVcheklist.DataBind();
}
protected void LnkGuardar_Click(object sender, EventArgs e)
{
if (EsNuevo)
{
string errorMessage = "";
int cveUsuarioDe = -1;
int cveUsuarioPara = -1;
foreach (GridViewRow gvRow in GVUsuarios.Rows)
{
if (gvRow.RowType == DataControlRowType.DataRow)
{
int CveUsuario = gvRow.DataKey("CveUsuario").ToString().ToEntero();
CheckBox chkpara = gvRow.FCCheckBox("ChkPara");
CheckBox chkCCpara = gvRow.FCCheckBox("ChkCCP");
if (chkpara.Checked)
{
cveUsuarioPara = CveUsuario;
}
if (chkCCpara.Checked)
{
cveUsuarioDe = CveUsuario;
}
}
}
OITipoEventos cveTipoEvento = OITipoEventos.Tarea;
string asunto = TxtAsunto.Text;
string descripcion = TxtDescripcion.Text;
int prioridad = DdlPrioridad.SelectedValue.ToEntero();
string fechaInicio = "";
if (txtFechaI.Text.ToDateTimeExcat().Year <= 1999)
{
if (txtFechaI.Text.ToDateTimeExcat("dd/MM/yyyy").Year <= 1999)
{
errorMessage = "no se ingreso una fecha de inicio valida";
}
else
{
fechaInicio = txtFechaI.Text.ToDateTimeExcat("dd/MM/yyyy").ToString("yyyy/MM/dd HH:mm");
}
}
else
{
fechaInicio = txtFechaI.Text.ToDateTimeExcat().ToString("yyyy/MM/dd HH:mm");
}
string fechaFin = "";
if (txtFechaF.Text.ToDateTimeExcat().Year <= 1999)
{
if (txtFechaF.Text.ToDateTimeExcat("dd/MM/yyyy").Year <= 1999)
{
errorMessage = "no se ingreso una fecha fin valida";
}
else
{
fechaFin = string.Format("{0:yyyy/MM/dd} 23:59", txtFechaF.Text.ToDateTimeExcat("dd/MM/yyyy"));
}
}
else
{
fechaFin = txtFechaF.Text.ToDateTimeExcat().ToString("yyyy/MM/dd HH:mm");
}
int cveRevision = DdlTema.SelectedValue.ToEntero();
string archivoname = "";
string rutaarchivoOri = "";
string ArchivoExtencion = "";
foreach (Archivo item in TxtArchivo.getfiles().Archivos)
{
archivoname = item.filenameO;
ArchivoExtencion = string.Format("{0}{1}", (item.Extencion.Length > 0 ? "." : ""), item.Extencion);
rutaarchivoOri = string.Format("{0}{1}{2}", AppDomain.CurrentDomain.BaseDirectory, item.patch, item.filename);
}
int cveUsuarioIng = UsuarioActual.CveUsuario;
int cveEmpresa = UsuarioActual.CveEmpresa;
bool Continuar = false;
int Folio = -1;
int CveEvento = -1;
if (cveUsuarioDe <= 0)
{
errorMessage = "no se selecciono el miembro 'C C Para'";
}
if (cveUsuarioPara <= 0)
{
errorMessage = "no se selecciono el miembro 'Para'";
}
if (errorMessage.Length == 0)
{
using (ClsOIEventos objOI = new ClsOIEventos())
{
objOI.IniciaTransacSQL();
Continuar = objOI.AddOI_Eventos2(cveTipoEvento, asunto, descripcion, prioridad, cveUsuarioDe, cveUsuarioPara, fechaInicio, fechaFin, cveRevision, archivoname, cveUsuarioIng, cveEmpresa);
CveEvento = objOI.CveEvento;
Folio = objOI.Folio;
if (Continuar)
{
foreach (System.Data.DataRow item in CheckListNew.Rows)
{
if (Continuar)
{
Continuar = objOI.Addcheklist(CveEvento, item["EventoComentario"].ToString(), UsuarioActual.CveUsuario);
}
}
}
if (Continuar && CveEvento > 0)
{
objOI.Commit();
}
else
{
objOI.RollBack();
Continuar = false;
}
}
if (Continuar && CveEvento > 0)
{
if (rutaarchivoOri.Length > 0)
{
string ruta = string.Format("{0}OIFiles\\", UsuarioActual.Empresa.Ruta);
if (!System.IO.Directory.Exists(ruta))
{
System.IO.Directory.CreateDirectory(ruta);
}
ruta = string.Format("{0}{1}\\", ruta, Folio);
if (!System.IO.Directory.Exists(ruta))
{
System.IO.Directory.CreateDirectory(ruta);
}
ruta = string.Format("{0}{1}", ruta, archivoname);//, ArchivoExtencion);
System.IO.File.Move(rutaarchivoOri, ruta);
}
this.Alert("Se ha agregado la nueva tarea", ModExtensiones.TipoMensaje.MsgInformacion, string.Format("location.replace(\"/OI/TareaDetalle.aspx?CveEvento={0}\");", CveEvento));
}
}
else
{
this.Alert(errorMessage, ModExtensiones.TipoMensaje.MsgAdvertencia);
}
}
}
protected void LnkEliminarchek_Click(object sender, EventArgs e)
{
GridViewRow gvrow = (GridViewRow)((LinkButton)sender).NamingContainer;
if (EsNuevo)
{
CheckListNew = CheckListNew.FiltraParametros(string.Format("CveEventoCheckList <> {0}", gvrow.DataKey("CveEventoCheckList")));
GVcheklist.DataSource = CheckListNew;
GVcheklist.DataBind();
}
else
{
using (ClsOIEventos objOI = new ClsOIEventos())
{
if (objOI.Removecheklist(gvrow.DataKey("CveEventoCheckList").ToEntero(), gvrow.DataKey("CveEvento").ToEntero(), UsuarioActual.CveUsuario))
{
Alert("Se ha eliminado la actividad", ModExtensiones.TipoMensaje.ToastInformacion);
if (objOI.Getcheklist(RCveEvento))
{
GVcheklist.DataSource = objOI.DtResultados;
GVcheklist.DataBind();
cargaActividades(objOI);
}
}
}
}
}
protected void LnkAgregarCheckList_Click(object sender, EventArgs e)
{
portletChekList.Visible = true;
LnkAgregarCheckList.Visible = false;
if (RCveEvento > 0)
{
}
else
{
GVcheklist.Columns[0].Visible = false;
CheckListNew = new System.Data.DataTable();
//CveEventoCheckList,CveEvento,CveTipoEvento,EventoComentario,Estatus,CveUsuario,Usuario,FechaIng
CheckListNew.Columns.Add("CveEventoCheckList", typeof(int));
CheckListNew.Columns.Add("CveEvento", typeof(int));
CheckListNew.Columns.Add("CveTipoEvento", typeof(int));
CheckListNew.Columns.Add("EventoComentario", typeof(String));
CheckListNew.Columns.Add("Estatus", typeof(bool));
CheckListNew.Columns.Add("CveUsuario", typeof(int));
CheckListNew.Columns.Add("Usuario", typeof(string));
CheckListNew.Columns.Add("FechaIng", typeof(DateTime));
}
UpChkList.Update();
}
protected void LnkAgregarchklistitem_Click(object sender, EventArgs e)
{
if (RCveEvento > 0)
{
using (ClsOIEventos objOI = new ClsOIEventos())
{
if (objOI.Addcheklist(RCveEvento, TxtActividad.Text, UsuarioActual.CveUsuario))
{
Alert("Se ha agregó la actividad", ModExtensiones.TipoMensaje.ToastInformacion);
if (objOI.Getcheklist(RCveEvento))
{
GVcheklist.DataSource = objOI.DtResultados;
GVcheklist.DataBind();
cargaActividades(objOI);
}
}
}
}
else
{
System.Data.DataRow drow = CheckListNew.NewRow();
drow["CveEventoCheckList"] = chklistitemindex++;
drow["EventoComentario"] = TxtActividad.Text;
drow["Estatus"] = false;
//CveEventoCheckList,CveEvento,CveTipoEvento,EventoComentario,Estatus,CveUsuario,Usuario,FechaIng
CheckListNew.Rows.Add(drow);
GVcheklist.DataSource = CheckListNew;
GVcheklist.DataBind();
}
TxtActividad.Text = "";
}
protected void ChkEstatus_CheckedChanged(object sender, EventArgs e)
{
CheckBox chk = (CheckBox)sender;
GridViewRow gvrow = (GridViewRow)chk.NamingContainer;
using (ClsOIEventos objOI = new ClsOIEventos())
{
if (objOI.Upcheklist(gvrow.DataKey("CveEventoCheckList").ToEntero(), gvrow.DataKey("CveEvento").ToEntero(), gvrow.DataKey("EventoComentario"), chk.Checked, UsuarioActual.CveUsuario))
{
Alert("Se actualizo el estatus de la actividad", ModExtensiones.TipoMensaje.ToastInformacion);
if (objOI.Getcheklist(RCveEvento))
{
GVcheklist.DataSource = objOI.DtResultados;
GVcheklist.DataBind();
cargaActividades(objOI);
}
}
}
}
protected void LnkEditarCheck_Click(object sender, EventArgs e)
{
}
protected void BtnCambiarEstatus_Click(object sender, EventArgs e)
{
using (ClsOIEventos objOI = new ClsOIEventos())
{
if (objOI.UpdateEstatusEvento2(DDlEstatus.SelectedValue.ToEntero(), -1, RCveEvento, UsuarioActual.CveUsuario))
{
//CargaEstatusEventos(DdlEventoEstatus.SelectedValue.ToEntero);
//if (DdlEventoEstatus.SelectedValue.ToEntero == 3 | DdlEventoEstatus.SelectedValue.ToEntero == 1)
// EnviarCorreoCambioEstatus(false);
//CargaDatos();
string mensaje = string.Format("Se cambio el Estatus de \"{0}\" a \"{1}\"", DdlEventoEstatus.SelectedItem.Text, DDlEstatus.SelectedItem.Text);
DdlEventoEstatus.SelectedValueExist(DDlEstatus.SelectedValue);
UpEstatus.Update();
this.RegistraScript(string.Format("$('#{0}').modal('hide')", iddivCambiarEstatus));
Alert(mensaje, ModExtensiones.TipoMensaje.ToastInformacion);
cargaActividades(objOI);
}
}
}
protected void LnkcambiarEstatus_Click(object sender, EventArgs e)
{
this.RegistraScript(string.Format("$('#{0}').modal()", iddivCambiarEstatus));
}
protected void LnkSinfuncion_Click(object sender, EventArgs e)
{
}
protected void LnkAgregarTema_Click(object sender, EventArgs e)
{
this.RegistraScript(string.Format("$('#{0}').modal()", iddivAgregarTema));
}
protected void BtnAgregarTema_Click(object sender, EventArgs e)
{
using (ClsOIEventos objoi = new ClsOIEventos())
{
if (objoi.AddRevisionesEventos(TxtTema.Text.Trim(), UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa))
{
Alert("Tema agregada con éxito.", ModExtensiones.TipoMensaje.MsgInformacion);
this.RegistraScript(string.Format("$('#{0}').modal('hide')", iddivAgregarTema));
TxtTema.Text = "";
set_GlobalDTOIRevision(-1, objoi.DtResultados);
CargaTemas();
UpContenido.Update();
}
else { Alert("Ocurrió un error al agregar la revisión. Por favor vuelva a intentar.", ModExtensiones.TipoMensaje.MsgError); }
}
}
protected void LnkAgregarActividad_Click(object sender, EventArgs e)
{
this.RegistraScript(string.Format("$('#{0}').modal()", iddivAgregar));
}
protected void BtnAgregarComentario_Click(object sender, EventArgs e)
{
string Comentario = TxtComentario.Text;
int CveComentario = 0;
string archivoname = "";
string rutaarchivoOri = "";
string ArchivoExtencion = "";
foreach (Archivo item in Txtfilecomentario.getfiles().Archivos)
{
archivoname = item.filenameO;
ArchivoExtencion = string.Format("{0}{1}", (item.Extencion.Length > 0 ? "." : ""), item.Extencion);
rutaarchivoOri = string.Format("{0}{1}{2}", AppDomain.CurrentDomain.BaseDirectory, item.patch, item.filename);
}
using (ClsOIEventos objoi = new ClsOIEventos())
{
CveComentario = objoi.AddEventoComentario(RCveEvento, Comentario, archivoname, UsuarioActual.CveUsuario);
if (CveComentario > 0) { cargaActividades(objoi); }
}
Txtfilecomentario.Text = "";
if (CveComentario > 0)
{
if (rutaarchivoOri.Length > 0)
{
string ruta = string.Format("{0}OIFiles\\", UsuarioActual.Empresa.Ruta);
if (!System.IO.Directory.Exists(ruta))
{
System.IO.Directory.CreateDirectory(ruta);
}
ruta = string.Format("{0}{1}\\", ruta, Folio);
if (!System.IO.Directory.Exists(ruta))
{
System.IO.Directory.CreateDirectory(ruta);
}
ruta = string.Format("{0}{1}{2}", ruta, CveComentario, archivoname);//, ArchivoExtencion);
System.IO.File.Move(rutaarchivoOri, ruta);
}
this.RegistraScript(string.Format("$('#{0}').modal('hide')", iddivAgregar));
this.Alert("comentario agregado", ModExtensiones.TipoMensaje.ToastInformacion);
//this.Alert("Se ha agregado la nueva tarea", ModExtensiones.TipoMensaje.MsgInformacion, string.Format("location.replace(\"/OI/TareaDetalle.aspx?CveEvento={0}\");", CveEvento));
}
}
protected void GvActividades_RowDataBound(object sender, GridViewRowEventArgs e)
{
if (e.Row.RowType == DataControlRowType.DataRow)
{
HyperLink HplA = e.Row.FCHyperLink("HplA");
string archivoname = e.Row.DBCampo("Archivo");
string CveComentario = e.Row.DBCampo("CveEventoComentario");
HplA.Visible = archivoname != "";
if (HplA.Visible)
{
HplA.NavigateUrl = string.Format("~/OI/TareaDetalle.aspx?Archivo={0}&filename={1}", ModExtensiones.Encripta(string.Format("OIFiles\\{0}\\{1}", Folio, archivoname)), ModExtensiones.Encripta(archivoname));
}
}
//Visible='<%# Eval("Archivo").ToString() != "" %>' data-archivo ='<%# string.Format("",Eval("CveEventoComentario").ToString()) %>'
//string.Format("~/OI/TareaDetalle.aspx?Archivo={0}&filename={1}", ModExtensiones.Encripta(string.Format("OIFiles\\{0}\\{1}", Folio, drow["Archivo"])), ModExtensiones.Encripta(drow["Archivo"].ToString()))
}
protected void LnkUpFile_Click(object sender, EventArgs e)
{
this.RegistraScript(string.Format("$('#{0}').modal()", iddivAgregarArchivo));
}
protected void BtnActualizarArchivo_Click(object sender, EventArgs e)
{
string archivoname = "";
string rutaarchivoOri = "";
string ArchivoExtencion = "";
foreach (Archivo item in txtActualizarArchivo.getfiles().Archivos)
{
archivoname = item.filenameO;
ArchivoExtencion = string.Format("{0}{1}", (item.Extencion.Length > 0 ? "." : ""), item.Extencion);
rutaarchivoOri = string.Format("{0}{1}{2}", AppDomain.CurrentDomain.BaseDirectory, item.patch, item.filename);
}
string ruta = string.Format("{0}OIFiles\\", UsuarioActual.Empresa.Ruta);
if (!System.IO.Directory.Exists(ruta))
{
System.IO.Directory.CreateDirectory(ruta);
}
ruta = string.Format("{0}{1}\\", ruta, Folio);
if (!System.IO.Directory.Exists(ruta))
{
System.IO.Directory.CreateDirectory(ruta);
}
string rutafin = string.Format("{0}{1}", ruta, archivoname);//, ArchivoExtencion);
int index = 0;
while (System.IO.File.Exists(rutafin))
{
archivoname = string.Format("{0}{1}", index++, archivoname);
rutafin = string.Format("{0}{1}", ruta, archivoname);
}
System.IO.File.Move(rutaarchivoOri, rutafin);
bool continuar = false;
using (ClsOIEventos objoi = new ClsOIEventos())
{
continuar = objoi.AddUPEventoArchivo(RCveEvento, archivoname, UsuarioActual.CveUsuario);
}
if (continuar)
{
LoadTarea();
this.RegistraScript(string.Format("$('#{0}').modal('hide')", iddivAgregarArchivo));
this.Alert("Archivo Actualizado", ModExtensiones.TipoMensaje.ToastInformacion);
}
UpContenido.Update();
}
protected void BtnUpAvance_Click(object sender, EventArgs e)
{
bool continuar = false;
using (ClsOIEventos objoi = new ClsOIEventos())
{
continuar = objoi.UPEventoAAvance(RCveEvento, TxtAvance.Text.ToDecimal(), UsuarioActual.CveUsuario);
if (continuar){
if (objoi.DtResultados.Rows.Count > 0)
{
LtlTitulo.Text = objoi.DtResultados.Rows[0]["Titulo"].ToString();
}
cargaActividades(objoi);
}
}
if (continuar)
{
this.Alert("Avance Actualizado", ModExtensiones.TipoMensaje.ToastInformacion);
}
UpTitulo.Update();
}
}

View File

@@ -1993,7 +1993,7 @@ function AddFunctionPS(inputProducto, inputAlmace, datos) {
});
}
textoOld = texto
textoOld = texto;
};
let GETPSALMACEN = function () {
@@ -2016,10 +2016,10 @@ function AddFunctionPS(inputProducto, inputAlmace, datos) {
};
lupa.bind("click", function () {
buscaPS(Minput.val());
})
});
Minput.bind("copy paste cut", function () {
buscaPS(Minput.val());
})
});
Minput.bind("keyup ", function (e) {
if (e.keyCode == 13) {
buscaPS(Minput.val());
@@ -2027,7 +2027,7 @@ function AddFunctionPS(inputProducto, inputAlmace, datos) {
} else {
buscaPSTimer(Minput.val());
}
})
});
PSModal.on('click', '.list-group-item ', function (e) {
let $this = $(this).hasClass('list-group-item') ? $(this) : $(this).closest('.list-group-item');
@@ -2054,7 +2054,7 @@ function AddFunctionPS(inputProducto, inputAlmace, datos) {
});
PSModal.on('shown.bs.modal', function () {
Minput.focus();
})
});
PSModal.on('click', '.item-almacen', function (e) {
let $this = $(this).hasClass('item-almacen') ? $(this) : $(this).closest('.item-almacen');
let cveps = $(PSModal.find('.active')).data('cve');