Пример #1
0
        private void loadFirstTime()
        {
            VSOrdTbj = new Orden_trabajo();
            string folio = string.Empty;

            if (Request.QueryString["folio"] != null)
            {
                folio          = Request.QueryString["folio"].ToString();
                txt_folio.Text = folio;
                txt_folio_changed(txt_folio, null);
            }
        }
Пример #2
0
        protected void guardar_ot(object sender, EventArgs args)
        {
            string msg;

            try
            {
                Orden_trabajo oT = MaquilaCtrl.OrdenTrabajoAdd(getFormValues());
                msg = "La orden de trabajo se guardó correctamente, folio asignado: " + oT.Folio;
                ClientScript.RegisterStartupScript(this.GetType(), "alertSave", "<script type=\"text/javascript\">alert('" + msg + "');window.location.href='frmOrdenTrabajo.aspx';</script>");
            }
            catch (Exception e)
            {
                ((MstCasc)this.Master).setError = e.Message;
            }
        }
Пример #3
0
        private Orden_trabajo getFormValues()
        {
            Orden_trabajo o = new Orden_trabajo();

            try
            {
                if (VSLstOTS.Count == 0)
                {
                    throw new Exception("Es necesario agregar por lo menos un servicio a la orden de trabajo");
                }

                o.Referencia         = txt_trafico.Text.Trim();
                o.Referencia_entrada = txt_referencia.Text.Trim();
                //EntradaCtrl.EntradaLiverpoolGetRefEntByRef(o.Referencia);
                o.Supervisor = txt_supervisor.Text.Trim().ToUpper();
                o.PLstOTSer  = VSLstOTS;
            }
            catch
            {
                throw;
            }

            return(o);
        }