821 lines
39 KiB
Plaintext
821 lines
39 KiB
Plaintext
<%@ Import Namespace="Extensiones" %>
|
||
|
||
<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="OP.aspx.vb" Inherits="OP_OP" %>
|
||
|
||
<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
|
||
</asp:Content>
|
||
<asp:Content ID="Content2" ContentPlaceHolderID="Css" runat="Server">
|
||
|
||
<style>
|
||
.v-center {
|
||
display: flex;
|
||
align-items: center;
|
||
}
|
||
|
||
.ajax__calendar_container {
|
||
position: fixed !important;
|
||
}
|
||
|
||
.one {
|
||
margin: 10px;
|
||
padding: 10px;
|
||
}
|
||
|
||
.btn-verde {
|
||
color: #32c5d2;
|
||
background-color: #fff;
|
||
border-color: #32c5d2;
|
||
}
|
||
|
||
.btn-verde .fa-plus {
|
||
color: #32c5d2 !important;
|
||
}
|
||
|
||
.btn-verde:hover {
|
||
color: #fff;
|
||
background-color: #32c5d2;
|
||
border-color: #32c5d2;
|
||
}
|
||
|
||
.btn-verde:hover .fa-plus {
|
||
color: white !important;
|
||
}
|
||
|
||
|
||
.table-scrollable {
|
||
margin-top: 0px !important;
|
||
margin-bottom: 0px !important;
|
||
}
|
||
|
||
.Widthall {
|
||
width: 100% !important;
|
||
}
|
||
|
||
.dataTables_scrollHeadInner {
|
||
width: 100% !important;
|
||
background-color: #dddddd;
|
||
padding-left: 0px !important;
|
||
}
|
||
|
||
.dataTables_scrollFoot {
|
||
display: none;
|
||
position: static;
|
||
}
|
||
|
||
.table-scrollable {
|
||
margin: 0px !important;
|
||
}
|
||
|
||
.dataTables_scroll {
|
||
margin-bottom: 0px;
|
||
}
|
||
|
||
.table.dataTable {
|
||
margin-top: 0px !important;
|
||
}
|
||
|
||
.dataTables_scrollBody table th {
|
||
padding: 0px !important;
|
||
padding-right: 4px !important;
|
||
padding-left: 4px !important;
|
||
}
|
||
|
||
.sinlink td a {
|
||
pointer-events: none;
|
||
cursor: default;
|
||
color: black;
|
||
font-size: small;
|
||
}
|
||
|
||
.white a {
|
||
color: white !important;
|
||
}
|
||
|
||
.Derecha {
|
||
text-align: right;
|
||
}
|
||
|
||
.Izquierda {
|
||
text-align: left;
|
||
}
|
||
|
||
.SinColor th {
|
||
background-color: white;
|
||
}
|
||
|
||
.Excede {
|
||
overflow: hidden;
|
||
text-overflow: ellipsis;
|
||
}
|
||
|
||
.truncate {
|
||
width: 300px;
|
||
white-space: nowrap;
|
||
overflow: hidden;
|
||
text-overflow: ellipsis;
|
||
}
|
||
|
||
.select2 .select2-selection__rendered {
|
||
line-height: 1;
|
||
color: #111;
|
||
}
|
||
|
||
.select2 .select2-selection--multiple {
|
||
box-sizing: border-box;
|
||
cursor: pointer;
|
||
display: block;
|
||
min-height: 20px;
|
||
user-select: none;
|
||
-webkit-user-select: none;
|
||
}
|
||
|
||
.select2-container--default .select2-selection--multiple .select2-selection__choice {
|
||
margin-top: 10px;
|
||
}
|
||
|
||
.select2-selection__rendered {
|
||
margin-top: 0px;
|
||
height: 25px;
|
||
}
|
||
|
||
.select2-selection {
|
||
margin-top: 0px;
|
||
height: 31px;
|
||
}
|
||
|
||
.select2-container--default.select2-container--focus .select2-selection--multiple {
|
||
border: none;
|
||
outline: 0;
|
||
}
|
||
|
||
#chartdiv {
|
||
width: 100%;
|
||
height: 250px;
|
||
}
|
||
|
||
#chartdiv2 {
|
||
width: 100%;
|
||
height: 250px;
|
||
}
|
||
|
||
#chartdiv3 {
|
||
width: 100%;
|
||
height: 250px;
|
||
}
|
||
|
||
#chartdiv4 {
|
||
width: 100%;
|
||
height: 250px;
|
||
}
|
||
|
||
|
||
.orange {
|
||
color: orange;
|
||
background-color: orange;
|
||
}
|
||
|
||
.tooltip-inner {
|
||
max-width: 750px !important;
|
||
font-size: 14px;
|
||
}
|
||
|
||
.arrow {
|
||
left: 20%;
|
||
}
|
||
|
||
.popover {
|
||
width: 500px !important;
|
||
max-width: 500px !important;
|
||
}
|
||
|
||
.modalBackground {
|
||
background-color: Black;
|
||
filter: alpha(opacity=90);
|
||
opacity: 0.8;
|
||
}
|
||
|
||
|
||
.select2anothertable {
|
||
position: absolute;
|
||
left: 100%;
|
||
background-color: white;
|
||
/*top: 50px;*/ top: 21px;
|
||
/*max-height: 200px;*/ max-height: 229px;
|
||
/*background-color: #dcdcdc;*/
|
||
overflow: hidden;
|
||
}
|
||
|
||
.select2anothertable > table > tbody > tr > td:nth-of-type(odd) {
|
||
background-color: rgba(220, 220, 220, 0.45);
|
||
}
|
||
|
||
.select2anothertable > table > tbody > tr > td {
|
||
line-height: 21px;
|
||
white-space: nowrap;
|
||
}
|
||
|
||
.select2anothertable > table > tbody > tr.active {
|
||
background-color: #5897fb;
|
||
}
|
||
|
||
#C_TrDescuentoProntoPago > td:nth-child(3) > span:nth-child(1) > label:nth-child(2) {
|
||
white-space: nowrap;
|
||
}
|
||
|
||
.op-container {
|
||
max-width: 1400px;
|
||
margin: 20px auto;
|
||
padding: 20px;
|
||
}
|
||
|
||
.op-header {
|
||
text-align: left;
|
||
border-bottom: 2px solid #e0e0e0;
|
||
padding-bottom: 15px;
|
||
margin-bottom: 25px;
|
||
}
|
||
|
||
.op-title {
|
||
font-size: 24px;
|
||
color: #2c3e50;
|
||
margin: 0;
|
||
}
|
||
|
||
.op-section {
|
||
margin-bottom: 25px;
|
||
text-align: left;
|
||
}
|
||
|
||
.op-field {
|
||
margin-bottom: 15px;
|
||
}
|
||
|
||
.op-label {
|
||
font-weight: bold;
|
||
color: #7f8c8d;
|
||
margin-bottom: 5px;
|
||
display: block;
|
||
}
|
||
|
||
.op-input {
|
||
width: 100%;
|
||
max-width: 400px;
|
||
}
|
||
|
||
.op-date-section {
|
||
margin-top: 30px;
|
||
padding-top: 15px;
|
||
border-top: 1px solid #eee;
|
||
}
|
||
|
||
.op-status {
|
||
font-size: 16px;
|
||
font-weight: bold;
|
||
}
|
||
|
||
.section-title {
|
||
font-weight: bold;
|
||
background-color: #CCC;
|
||
padding: 5px;
|
||
margin-top: 10px;
|
||
}
|
||
</style>
|
||
|
||
</asp:Content>
|
||
<asp:Content ID="Content3" ContentPlaceHolderID="E" runat="Server">
|
||
Orden de Producción
|
||
</asp:Content>
|
||
<asp:Content ID="Content4" ContentPlaceHolderID="HB" runat="Server">
|
||
</asp:Content>
|
||
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
|
||
</asp:Content>
|
||
<asp:Content ID="Content6" ContentPlaceHolderID="HA" runat="Server">
|
||
</asp:Content>
|
||
<asp:Content ID="Content7" ContentPlaceHolderID="C" runat="Server">
|
||
<!-- Aquí se muestra la información de la OP -->
|
||
|
||
<div class="row">
|
||
<asp:UpdatePanel ID="UpOP" runat="server" UpdateMode="Conditional">
|
||
<ContentTemplate>
|
||
<div class="col-md-6">
|
||
<div class="portlet light xspadding bordered">
|
||
<div class="portlet-title">
|
||
<div class="caption font-green">
|
||
<span class="caption-subject bold uppercase">Orden de producción #<asp:Label ID="LblFolio" runat="server"></asp:Label></span>
|
||
</div>
|
||
</div>
|
||
<div class="portlet-body form">
|
||
<div class="labeltruncate labeltext labelbold">
|
||
<div class="row">
|
||
<div class="col-md-6">
|
||
<div class="form-group form-md-line-input input-iconright">
|
||
<label for="<%= DdlClientes.ClientID.ToString()%>">Cliente</label>
|
||
<ADS:Dropdownlost ID="DdlClientes" runat="server"
|
||
CssClassDdl="form-control" DataTextField="NombreComercial"
|
||
data-metodo="getcliente"
|
||
DataValueField="CveCliente" Enabled="false" />
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
<!-- Centro de Costo -->
|
||
<div class="portlet-body form">
|
||
<div class="labeltruncate labeltext labelbold">
|
||
<div class="row">
|
||
<div class="col-md-16">
|
||
<div class="form-group form-md-line-input input-iconright">
|
||
<asp:Label ID="LblProyecto" runat="server">
|
||
<label>Proyecto:</label>
|
||
</asp:Label>
|
||
<div runat="server" id="DivProyecto">
|
||
<asp:DropDownList ID="DdlProyecto" runat="server" AutoPostBack="true" AppendDataBoundItems="true" DataTextField="Proyecto" DataValueField="CveProyecto" Class="form-control select2me" Style="width: 100%;"></asp:DropDownList>
|
||
</div>
|
||
<asp:Label ID="LblSubProyecto" runat="server" class="col-md-2">
|
||
<label>Subproyecto:</label>
|
||
</asp:Label>
|
||
<div runat="server" id="DivSubProyecto" class="col-md-4">
|
||
<asp:DropDownList ID="DdlSubProyecto" runat="server" AppendDataBoundItems="true" DataTextField="SubProyecto" DataValueField="CveSubProyecto" Class="form-control select2me" Style="width: 100%;"></asp:DropDownList>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
|
||
<!-- Descripción -->
|
||
|
||
<div class="row">
|
||
<div class="col-md-10">
|
||
<div class="form-group form-md-line-input input-iconright">
|
||
<asp:TextBox ID="TxtDescripcion" runat="server"
|
||
CssClass="form-control"
|
||
Style="width: 95%; height: 40px;"
|
||
ValidationGroup="GrpGuardar"
|
||
TextMode="MultiLine"
|
||
Rows="2"
|
||
MaxLength="1000" />
|
||
<asp:RequiredFieldValidator ID="RFVDescripcion" runat="server"
|
||
ControlToValidate="TxtDescripcion"
|
||
ErrorMessage="Descripción requerida"
|
||
Display="None"
|
||
CssClass="text-danger"
|
||
ValidationGroup="GrpGuardar" />
|
||
<label for="<%= TxtDescripcion.ClientID.ToString()%>">Descripcion</label>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
|
||
|
||
|
||
<!-- Fecha -->
|
||
<div class="form-section">
|
||
<div class="row">
|
||
<div class="form-group">
|
||
<div class="col-md-1">
|
||
<label class="mb-0">Fecha</label>
|
||
</div>
|
||
<div class="col-md-2">
|
||
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 100px !important; padding: 0px;">
|
||
<asp:TextBox Width="80px" ID="Txtfecha" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10"></asp:TextBox>
|
||
<span class="input-group-btn ">
|
||
<asp:LinkButton ID="imgCalendarioF" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
||
</span>
|
||
</div>
|
||
<ajax:MaskedEditExtender ID="MEEFechaF" runat="server" TargetControlID="Txtfecha" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||
<ajax:CalendarExtender runat="server" ID="Calendario2" TargetControlID="Txtfecha" PopupButtonID="imgCalendarioF" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
||
<asp:RequiredFieldValidator ID="rfvFechaF" runat="server" ControlToValidate="Txtfecha" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="Valida"></asp:RequiredFieldValidator>
|
||
<asp:CompareValidator ID="cvFechaF" runat="server" ControlToValidate="Txtfecha" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="Valida"></asp:CompareValidator>
|
||
<ajax:ValidatorCalloutExtender ID="vcoRfvFF" runat="server" HighlightCssClass="vco" TargetControlID="rfvFechaF" Width="350px"></ajax:ValidatorCalloutExtender>
|
||
<ajax:ValidatorCalloutExtender ID="vcoCvFF" runat="server" HighlightCssClass="vco" TargetControlID="cvFechaF" Width="350px"></ajax:ValidatorCalloutExtender>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="col-md-3">
|
||
<div class="portlet light xspadding bordered">
|
||
<div class="portlet-title">
|
||
<div class="caption font-green">
|
||
<span class="caption-subject bold uppercase">Estatus</span>
|
||
</div>
|
||
|
||
</div>
|
||
<div class="portlet-body form">
|
||
<asp:TextBox ID="TxtEstatus" runat="server" CssClass="form-control" Width="150px"></asp:TextBox>
|
||
<asp:RequiredFieldValidator ID="RFVEstatus" runat="server"
|
||
ControlToValidate="TxtEstatus"
|
||
Display="Dynamic"
|
||
ErrorMessage="Estatus requerido"
|
||
CssClass="text-danger"
|
||
ValidationGroup="GrpGuardar" />
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
</ContentTemplate>
|
||
</asp:UpdatePanel>
|
||
</div>
|
||
|
||
<!-- GridViews -->
|
||
<asp:UpdatePanel ID="UpGvDatosOP" runat="server" UpdateMode="Conditional">
|
||
<ContentTemplate>
|
||
|
||
<div class="row">
|
||
<div class="col-md-12">
|
||
<div class="portlet light xspadding bordered">
|
||
<div class="portlet-title">
|
||
<div class="caption font-green">
|
||
<span class="caption-subject bold uppercase">Productos</span>
|
||
</div>
|
||
</div>
|
||
<div class="portlet-body">
|
||
<div class="row">
|
||
<label class="col-md-1" style="max-width: 70px;">Producto</label>
|
||
<div class="col-md-3">
|
||
<ADS:Dropdownlost ID="DdlPS" runat="server" Width="100%" CssStyle="width: 100%;"
|
||
CssClass="select2me"
|
||
CssClassDdl="form-control" DataTextField="PSCodigo"
|
||
DataValueField="CvePS" Enabled="false" />
|
||
</div>
|
||
<div class="col-md-4 d-flex align-items-center" style="gap: 10px;">
|
||
<asp:LinkButton ID="BtnAgregarProducto" runat="server"
|
||
CssClass="btn btn-primary"
|
||
Style="padding: 4px 10px; border-radius: 50%;"
|
||
ValidationGroup="GrpAgregarProducto">
|
||
<i class="fa fa-plus"></i>
|
||
</asp:LinkButton>
|
||
|
||
<!-- Botón de Simulación -->
|
||
|
||
<asp:LinkButton ID="BtnSimularMP" runat="server" Text="Simular MP"
|
||
CssClass="btn btn-primary" OnClick="BtnSimularMP_Click" Visible="false"
|
||
Style="padding: 4px 10px; border-radius: 50%;">
|
||
<i class="fa fa-cogs"></i>
|
||
</asp:LinkButton>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="row">
|
||
<div class="col-md-12">
|
||
<div class="section-title">Productos</div>
|
||
<asp:GridView ID="GvProductos" runat="server" AutoGenerateColumns="False"
|
||
CssClass="table table-striped table-hover" GridLines="None" Width="100%">
|
||
<Columns>
|
||
<asp:BoundField DataField="PSCodigo" HeaderText="Producto" />
|
||
<asp:BoundField DataField="UnidadMedida" HeaderText="UM" />
|
||
<asp:BoundField DataField="Cantidad" HeaderText="Cantidad" />
|
||
<asp:TemplateField>
|
||
<ItemTemplate>
|
||
<asp:LinkButton ID="BtnEliminar" runat="server"
|
||
CommandArgument='<%# Eval("Clave") %>'
|
||
OnClick="BtnEliminarProducto_Click"
|
||
CssClass="btn btn-circle btn-xs red"
|
||
Text="<i class='icon-trash'></i>" />
|
||
</ItemTemplate>
|
||
</asp:TemplateField>
|
||
</Columns>
|
||
</asp:GridView>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
|
||
<div class="row">
|
||
<div class="col-md-6">
|
||
<div class="portlet light xspadding bordered">
|
||
<div class="portlet-title">
|
||
<div class="caption font-green">
|
||
<span class="caption-subject bold uppercase">Materia Prima</span>
|
||
</div>
|
||
<div class="col-md-4 d-flex align-items-center" style="gap: 10px;">
|
||
<asp:LinkButton ID="LnkSolicitarMP" runat="server"
|
||
CssClass="btn btn-success"
|
||
OnClick="LnkSolicitarMP_Click"
|
||
Style="padding: 4px 10px; border-radius: 50%;"
|
||
Visible="false">
|
||
Solicitar MP
|
||
</asp:LinkButton>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="portlet-body">
|
||
|
||
<div class="section-title">Materia prima</div>
|
||
<asp:GridView ID="GvMateriaPrima" runat="server" AutoGenerateColumns="False"
|
||
CssClass="table table-striped table-hover" GridLines="None" Width="100%">
|
||
<Columns>
|
||
<asp:BoundField DataField="PSCodigo" HeaderText="Producto" />
|
||
<asp:BoundField DataField="UnidadMedida" HeaderText="UM" />
|
||
<asp:BoundField DataField="Cantidad" HeaderText="Cantidad" DataFormatString="{0:#,##0.####}" ItemStyle-HorizontalAlign="Right" />
|
||
<asp:BoundField DataField="Surtido" HeaderText="Surtido" DataFormatString="{0:#,##0.####}" ItemStyle-HorizontalAlign="Right" />
|
||
</Columns>
|
||
</asp:GridView>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
|
||
<div class="row">
|
||
<div class="col-md-6">
|
||
<div class="portlet light xspadding bordered">
|
||
<div class="portlet-title">
|
||
<div class="caption font-green">
|
||
<span class="caption-subject bold uppercase">Mano de Obra</span>
|
||
</div>
|
||
</div>
|
||
|
||
|
||
<div class="portlet-body">
|
||
<div class="section-title">Mano de obra</div>
|
||
<asp:GridView ID="GvManoObra" runat="server" AutoGenerateColumns="False"
|
||
CssClass="table table-striped table-hover" GridLines="None" Width="100%">
|
||
<Columns>
|
||
<asp:BoundField DataField="Puesto" HeaderText="Puesto" />
|
||
<asp:BoundField DataField="Cantidad" HeaderText="Cantidad" DataFormatString="{0:#,##0.####}" ItemStyle-HorizontalAlign="Right" />
|
||
</Columns>
|
||
</asp:GridView>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div class="col-md-6">
|
||
<div class="portlet light xspadding bordered">
|
||
<div class="portlet-title">
|
||
<div class="caption font-green">
|
||
<span class="caption-subject bold uppercase">Costo Indirecto</span>
|
||
</div>
|
||
</div>
|
||
<div class="portlet-body">
|
||
<div class="section-title">Costo indirecto</div>
|
||
<asp:GridView ID="GvCostosIndirectos" runat="server" AutoGenerateColumns="False"
|
||
CssClass="table table-striped table-hover" GridLines="None" Width="100%">
|
||
<Columns>
|
||
<asp:BoundField DataField="productoMateriaPrima" HeaderText="Producto" />
|
||
<asp:BoundField DataField="Cantidad" HeaderText="Costo" DataFormatString="{0:#,##0.####}" ItemStyle-HorizontalAlign="Right" />
|
||
</Columns>
|
||
</asp:GridView>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</ContentTemplate>
|
||
</asp:UpdatePanel>
|
||
|
||
<div id="DVModalSolicitarMP" class="modal ADS fade" role="dialog" data-backdrop="static">
|
||
<div class="modal-dialog" style="width: 750px;">
|
||
<asp:UpdatePanel runat="server" class="modal-content" ID="UpModalMP" UpdateMode="Conditional">
|
||
<ContentTemplate>
|
||
<div class="modal-header">
|
||
<button type="button" class="close" data-dismiss="modal">×</button>
|
||
<h4 class="modal-title">Solicitar Materia Prima - OP #<%= LblFolio.Text %></h4>
|
||
</div>
|
||
<div class="modal-body">
|
||
<!-- Almacenes -->
|
||
<div class="row">
|
||
<div class="col-md-6 form-group">
|
||
<label>Almacén Origen:</label>
|
||
<asp:DropDownList ID="DdlAlmacenOrigenMP" runat="server"
|
||
DataTextField="Almacen" DataValueField="CveAlmacen"
|
||
CssClass="form-control select2me" AutoPostBack="true"
|
||
OnSelectedIndexChanged="DdlAlmacenOrigenMP_SelectedIndexChanged" />
|
||
</div>
|
||
<div class="col-md-6 form-group">
|
||
<label>Almacén Destino:</label>
|
||
<asp:DropDownList ID="DdlAlmacenDestinoMP" runat="server"
|
||
DataTextField="Almacen" DataValueField="CveAlmacen"
|
||
CssClass="form-control select2me" />
|
||
</div>
|
||
</div>
|
||
|
||
<div class="row marginRowLeft">
|
||
<div class="col-md-12 form-group">
|
||
<label>Observaciones:</label>
|
||
<asp:TextBox ID="TxtObservacionesMP" runat="server"
|
||
CssClass="form-control" TextMode="MultiLine" Rows="3"
|
||
MaxLength="500" placeholder="Ingrese observaciones..." />
|
||
</div>
|
||
</div>
|
||
|
||
<!-- Grid de productos agregados -->
|
||
<asp:GridView ID="GvMPAgregados" runat="server" AutoGenerateColumns="False"
|
||
CssClass="table table-striped table-hover" GridLines="None" Width="100%"
|
||
DataKeyNames="CvePSMateriaPrima,CveUMMateriaPrima, Cantidad" EmptyDataText="No se encontraron Productos registrados" ToolTip="Listado de Productos">
|
||
<Columns>
|
||
<asp:BoundField DataField="PSCodigo" HeaderText="Producto" />
|
||
<asp:BoundField DataField="UnidadMedida" HeaderText="UM" />
|
||
<asp:BoundField DataField="Cantidad" HeaderText="Cantidad" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
|
||
</Columns>
|
||
</asp:GridView>
|
||
</div>
|
||
|
||
|
||
|
||
<div class="modal-footer">
|
||
<asp:Button ID="BtnGuardarSolicitudMP" runat="server"
|
||
Text="Guardar Solicitud" CssClass="btn btn-primary"
|
||
OnClick="BtnGuardarSolicitudMP_Click" />
|
||
</div>
|
||
</ContentTemplate>
|
||
</asp:UpdatePanel>
|
||
</div>
|
||
</div>
|
||
|
||
<div id="DVModalSimularMP" class="modal fade" role="dialog" data-backdrop="static">
|
||
<div class="modal-dialog" style="width: 750px;">
|
||
<asp:UpdatePanel ID="UpModalSimular" runat="server" UpdateMode="Conditional">
|
||
<ContentTemplate>
|
||
<div class="modal-content">
|
||
<div class="modal-header">
|
||
|
||
<h4 class="modal-title">Simulación de Materia Prima -
|
||
<span id="SpanNombreProducto" runat="server"></span>
|
||
</h4>
|
||
|
||
</div>
|
||
|
||
|
||
<div class="modal-body">
|
||
<div class="row">
|
||
<div class="col-md-12">
|
||
<div class="portlet light xspadding bordered">
|
||
<div class="portlet-title">
|
||
<div class="caption font-green">
|
||
<span class="caption-subject bold uppercase">Simulación</span>
|
||
</div>
|
||
<div class="row">
|
||
<div class="col-md-12">
|
||
<asp:RadioButtonList ID="RblModoSimulacion" runat="server" AutoPostBack="true"
|
||
OnSelectedIndexChanged="RblModoSimulacion_SelectedIndexChanged" RepeatDirection="Horizontal">
|
||
<asp:ListItem Text="Por Cantidad" Value="1" Selected="True"></asp:ListItem>
|
||
<asp:ListItem Text="Por Existencias" Value="2"></asp:ListItem>
|
||
</asp:RadioButtonList>
|
||
</div>
|
||
</div>
|
||
<div class="row">
|
||
<div class="col-md-6">
|
||
<label>Almacén:</label>
|
||
<asp:DropDownList ID="DdlAlmacenSimular" runat="server"
|
||
DataTextField="Almacen" DataValueField="CveAlmacen"
|
||
CssClass="form-control" AutoPostBack="true"
|
||
OnSelectedIndexChanged="DdlAlmacenSimular_SelectedIndexChanged"
|
||
AppendDataBoundItems="True">
|
||
<asp:ListItem Text="Selecciona el almacén" Value="-1" Selected="True"></asp:ListItem>
|
||
</asp:DropDownList>
|
||
|
||
|
||
|
||
</div>
|
||
</div>
|
||
<div class="row">
|
||
<asp:Panel ID="PnlCantidad" runat="server" class="col-md-2">
|
||
<label>Cantidad:</label>
|
||
<asp:TextBox ID="TxtCantidadSimular" runat="server"
|
||
CssClass="form-control" TextMode="Number" Min="1" Value="1" AutoPostBack="true" OnTextChanged="TxtCantidadSimular_TextChanged" />
|
||
</asp:Panel>
|
||
</div>
|
||
<div class="row">
|
||
<asp:Label ID="LblCantidadPosibleGlobal" runat="server" Class="col-md-2"
|
||
Visible="false">
|
||
<strong>Cantidad:</strong> <span id="SpanCantidad">0</span>
|
||
</asp:Label>
|
||
</div>
|
||
|
||
|
||
<div class="section-title">Materia prima</div>
|
||
<asp:GridView ID="GvSimulacionMP" runat="server" AutoGenerateColumns="False"
|
||
CssClass="table table-striped table-hover"
|
||
GridLines="None" Width="100%" DataKeyNames="CvePS,CveUM">
|
||
<Columns>
|
||
|
||
<asp:BoundField DataField="productoMateriaPrima" HeaderText="Producto" />
|
||
<asp:BoundField DataField="CantidadUnitaria" HeaderText="Cantidad Unitaria"
|
||
DataFormatString="{0:#,##0.####}" ItemStyle-HorizontalAlign="Right" />
|
||
|
||
<asp:BoundField DataField="Disponible" HeaderText="Disponible"
|
||
DataFormatString="{0:#,##0.####}" ItemStyle-HorizontalAlign="Right" />
|
||
|
||
<asp:BoundField DataField="TotalRequerido" HeaderText="Total Requerido"
|
||
DataFormatString="{0:#,##0.####}" ItemStyle-HorizontalAlign="Right"
|
||
Visible="false" />
|
||
<asp:BoundField DataField="Faltante" HeaderText="Faltante"
|
||
DataFormatString="{0:#,##0.####}" ItemStyle-HorizontalAlign="Right"
|
||
Visible="false" />
|
||
<asp:BoundField DataField="CantidadPosible" HeaderText="Cantidad Producible"
|
||
DataFormatString="{0:#,##0.####}" ItemStyle-HorizontalAlign="Right"
|
||
Visible="false" />
|
||
</Columns>
|
||
</asp:GridView>
|
||
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div class="modal-footer">
|
||
<button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</ContentTemplate>
|
||
</asp:UpdatePanel>
|
||
</div>
|
||
</div>
|
||
|
||
|
||
<!-- Botón para Guardar la OP -->
|
||
<div class="form-group" style="margin-top: 20px;">
|
||
<asp:Button ID="BtnGuardarOP" runat="server" Text="Guardar Orden de Producción"
|
||
CssClass="btn btn-success" OnClick="BtnGuardarOP_Click"
|
||
ValidationGroup="GrpGuardar" />
|
||
</div>
|
||
|
||
<div class="row mt-4">
|
||
<div class="col-md-12 d-flex justify-content-end">
|
||
<asp:Button ID="BtnFinalizarOP" runat="server" Text="Terminar"
|
||
CssClass="btn btn-success mr-2" OnClick="BtnFinalizarOP_Click"
|
||
Visible="false" />
|
||
</div>
|
||
</div>
|
||
|
||
<div id="DVModalFinalizarOP" class="modal ADS fade" role="dialog" data-backdrop="static">
|
||
<div class="modal-dialog" style="width: 750px;">
|
||
<asp:UpdatePanel runat="server" class="modal-content" ID="UpModalFinalizar" UpdateMode="Conditional">
|
||
<ContentTemplate>
|
||
<div class="modal-header">
|
||
<button type="button" class="close" data-dismiss="modal">×</button>
|
||
<h4 class="modal-title">Finalizar Orden de Producción #<%= LblFolio.Text %></h4>
|
||
</div>
|
||
<div class="modal-body">
|
||
<!-- Almacén de Materia Prima (Fijo) -->
|
||
<div class="row">
|
||
<div class="col-md-6 form-group">
|
||
<label>Almacén de Salida (Materia Prima):</label>
|
||
<asp:DropDownList ID="DdlAlmacenOrigenSalidaMP" runat="server"
|
||
DataTextField="Almacen" DataValueField="CveAlmacen"
|
||
CssClass="form-control select2me" />
|
||
</div>
|
||
<!-- Almacén de Producto Terminado (Dropdown) -->
|
||
<div class="col-md-6 form-group">
|
||
<label>Almacén de Entrada (Producto Terminado):</label>
|
||
<asp:DropDownList ID="DdlAlmacenTerminado" runat="server"
|
||
DataTextField="Almacen" DataValueField="CveAlmacen"
|
||
CssClass="form-control select2me" />
|
||
</div>
|
||
</div>
|
||
|
||
<!-- GridViews -->
|
||
<div class="row">
|
||
<div class="col-md-12">
|
||
<div class="section-title">Producto Terminado</div>
|
||
<asp:GridView ID="GvProductoTerminado" runat="server" AutoGenerateColumns="False"
|
||
CssClass="table table-striped table-hover" GridLines="None" Width="100%">
|
||
<Columns>
|
||
<asp:BoundField DataField="PSCodigo" HeaderText="Producto" />
|
||
<asp:BoundField DataField="UnidadMedida" HeaderText="UM" />
|
||
<asp:BoundField DataField="Cantidad" HeaderText="Cantidad" DataFormatString="{0:N2}" />
|
||
</Columns>
|
||
</asp:GridView>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="row">
|
||
<div class="col-md-12">
|
||
<div class="section-title">Materia Prima</div>
|
||
<asp:GridView ID="GvMPUtilizada" runat="server" AutoGenerateColumns="False"
|
||
CssClass="table table-striped table-hover" GridLines="None" Width="100%">
|
||
<Columns>
|
||
<asp:BoundField DataField="PSCodigo" HeaderText="Producto" />
|
||
<asp:BoundField DataField="Cantidad" HeaderText="Cantidad" DataFormatString="{0:N2}" />
|
||
</Columns>
|
||
</asp:GridView>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div class="modal-footer">
|
||
<%-- Botón Guardar --%>
|
||
<asp:Button ID="BtnGuardarFinalizarOP" runat="server" Text="Guardar"
|
||
CssClass="btn btn-primary" OnClick="BtnGuardarFinalizarOP_Click" />
|
||
<%-- Botón Cerrar --%>
|
||
<button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
|
||
</div>
|
||
</ContentTemplate>
|
||
</asp:UpdatePanel>
|
||
</div>
|
||
</div>
|
||
|
||
|
||
</asp:Content>
|
||
|
||
|
||
<asp:Content ID="Content8" ContentPlaceHolderID="JS" runat="Server">
|
||
</asp:Content>
|
||
|