public DetalleDiagramacion(Deporte deporte, int item, string dia_semana, Sector sector, Horario hora_desde, Horario hora_hasta, Personal profesor) { Deporte = deporte; Item = item; Dia_semana = dia_semana; Sector = sector; Hora_desde = hora_desde; Hora_hasta = hora_hasta; Profesor = profesor; }
protected void Button1_Click(object sender, EventArgs e) { if (IsValid) { if (int.Parse(cmbPersonal.SelectedValue) > 0 ) { persona = Personal.FindOne(Expression.Eq("IdEmpleados", int.Parse(cmbPersonal.SelectedValue))); FillGrid(); } } }
public DetalleDiagramacion(Diagramacion diagramacion, int item, Dia dia_semana, Sector sector, Horario hora_desde, Horario hora_hasta, Personal profesor, bool lugar_confirmado, bool horario_confirmado, bool profesor_confirmado) { Diagramacion = diagramacion; Item = item; Dia_semana = dia_semana; Sector = sector; Hora_desde = hora_desde; Hora_hasta = hora_hasta; Profesor = profesor; Lugar_confirmado = lugar_confirmado; Horario_confirmado = horario_confirmado; Profesor_confirmado = profesor_confirmado; }
protected void cvPersona_ServerValidate(object source, ServerValidateEventArgs args) { args.IsValid = false; persona = Personal.GetById(cmbPersonal.SelectedValue); if (persona.email != null) { args.IsValid = true; } else { args.IsValid = false; cvPersona.ErrorMessage = persona.Apellido + "," + persona.Nombres + " no tiene un email valido "; } }
/// <summary>Takes the remaining content of the stream and deserialze it into the instance.</summary> public static Personal.Person Deserialize(Stream stream, Personal.Person instance) { if (instance.Phone == null) instance.Phone = new List<Personal.Person.PhoneNumber>(); while (true) { int keyByte = stream.ReadByte(); if (keyByte == -1) break; // Optimized reading of known fields with field ID < 16 switch (keyByte) { // Field 1 LengthDelimited case 10: instance.Name = global::SilentOrbit.ProtocolBuffers.ProtocolParser.ReadString(stream); continue; // Field 2 Varint case 16: instance.Id = (int)global::SilentOrbit.ProtocolBuffers.ProtocolParser.ReadUInt64(stream); continue; // Field 3 LengthDelimited case 26: instance.Email = global::SilentOrbit.ProtocolBuffers.ProtocolParser.ReadString(stream); continue; // Field 4 LengthDelimited case 34: // repeated instance.Phone.Add(Personal.Person.PhoneNumber.DeserializeLengthDelimited(stream)); continue; } var key = global::SilentOrbit.ProtocolBuffers.ProtocolParser.ReadKey((byte)keyByte, stream); // Reading field ID > 16 and unknown field ID/wire type combinations switch (key.Field) { case 0: throw new global::SilentOrbit.ProtocolBuffers.ProtocolBufferException("Invalid field id: 0, something went wrong in the stream"); default: global::SilentOrbit.ProtocolBuffers.ProtocolParser.SkipKey(stream, key); break; } } return instance; }
private void butGuardar_Click(object sender, EventArgs e) { string sex =""+comboSexo.SelectedItem; Personal p = new Personal(); p.Cedula = textCedula.Text; p.Nombre = textNombres.Text; p.Apellido = textApellidos.Text; p.Cargo = textCargo.Text; p.Titulo = textTitulo.Text; p.Correo = textCorreo.Text; p.Sexo = sex[0]; p.Ciudad = textCiudad.Text; p.Direccion = textDireccion.Text; p.Telefono = textTelefono.Text; p.Tipo = Convert.ToString(comboTipo.SelectedItem); p.DataFoto = ImageToByte(picture); PersonalCd.Create(p); frmap.dataGridView1.Update(); }
public static List <Personal> obtenerTuplasPersonal() { return(Personal.listaDatos()); }
#pragma warning disable 1998 public async override global::System.Threading.Tasks.Task ExecuteAsync() { BeginContext(50, 2, true); WriteLiteral("\r\n"); EndContext(); #line 3 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" ViewData["Title"] = "Index"; #line default #line hidden BeginContext(93, 745, true); WriteLiteral(@" <style> .mdl-button--file input { cursor: pointer; height: 100%; right: 0; opacity: 0; position: absolute; top: 0; width: 300px; z-index: 4; } .mdl-textfield--file .mdl-textfield__input { box-sizing: border-box; width: calc(100% - 32px); } .mdl-textfield--file .mdl-button--file { right: 0; } </style> <div id=""demo-snackbar-example"" class=""mdl-js-snackbar mdl-snackbar""> <div class=""mdl-snackbar__text""></div> <button class=""mdl-snackbar__action"" type=""button""></button> </div> <script> r(function () { var notification = document.querySelector('.mdl-js-snackbar'); if ("); EndContext(); BeginContext(839, 19, false); #line 36 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" Write(TempData["Changed"]); #line default #line hidden EndContext(); BeginContext(858, 187, true); WriteLiteral(" == 1) {\r\n notification.MaterialSnackbar.showSnackbar(\r\n {\r\n message: \'Personal Information has been changed\'\r\n }\r\n "); EndContext(); BeginContext(1046, 19, false); #line 41 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" Write(TempData["Changed"]); #line default #line hidden EndContext(); BeginContext(1065, 272, true); WriteLiteral(@" = 0; ); } }); function r(f) { /in/.test(document.readyState) ? setTimeout('r(' + f + ')', 9) : f() } </script> <div class=""mdl-grid""> <div class=""mdl-cell mdl-cell--3-col""></div> <div class=""mdl-cell mdl-cell--6-col""> "); EndContext(); #line 54 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" if (Model.Count() != 0) { #line default #line hidden BeginContext(1384, 41, true); WriteLiteral(" <h3>Change my profile</h3> \r\n"); EndContext(); #line 58 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" Personal pers = Model.Single() as Personal; #line default #line hidden BeginContext(1484, 12, true); WriteLiteral(" "); EndContext(); BeginContext(1496, 4421, false); __tagHelperExecutionContext = __tagHelperScopeManager.Begin("form", global::Microsoft.AspNetCore.Razor.TagHelpers.TagMode.StartTagAndEndTag, "184bb9e699a743cb84b515cb8d45711d", async() => { BeginContext(1588, 186, true); WriteLiteral("\r\n <div class=\"mdl-textfield mdl-js-textfield mdl-textfield--floating-label\">\r\n <input class=\"mdl-textfield__input\" name=\"name\" type=\"text\" id=\"sample3\""); EndContext(); BeginWriteAttribute("value", " value=\"", 1774, "\"", 1792, 1); #line 62 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" WriteAttributeValue("", 1782, pers.name, 1782, 10, false); #line default #line hidden EndWriteAttribute(); BeginContext(1793, 235, true); WriteLiteral(">\r\n <label class=\"mdl-textfield__label\" for=\"sample3\">Name...</label>\r\n </div>\r\n <div class=\"mdl-textfield mdl-js-textfield mdl-textfield--file\">\r\n <input name=\"image\""); EndContext(); BeginWriteAttribute("value", " value=\"", 2028, "\"", 2047, 1); #line 66 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" WriteAttributeValue("", 2036, pers.image, 2036, 11, false); #line default #line hidden EndWriteAttribute(); BeginContext(2048, 639, true); WriteLiteral(@" type=""hidden"" /> <input class=""mdl-textfield__input"" placeholder=""Change my photo..."" type=""text"" id=""TEXT_ID"" readonly /> <div class=""mdl-button mdl-button--icon mdl-button--file""> <i class=""material-icons"">attach_file</i> <input type=""file"" name=""imgFile"" id=""imgFile"" onchange=""document.getElementById('TEXT_ID').value=this.files[0].name;"" /> </div> </div> <div class=""mdl-textfield mdl-js-textfield mdl-textfield--floating-label""> <input class=""mdl-textfield__input"""); EndContext(); BeginWriteAttribute("value", " value=\"", 2687, "\"", 2711, 1); #line 74 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" WriteAttributeValue("", 2695, pers.image_desc, 2695, 16, false); #line default #line hidden EndWriteAttribute(); BeginContext(2712, 351, true); WriteLiteral(@" name=""image_desc"" type=""text"" id=""sample3""> <label class=""mdl-textfield__label"" for=""sample3"">Image Description</label> </div> <div class=""mdl-textfield mdl-js-textfield mdl-textfield--floating-label""> <input class=""mdl-textfield__input"" name=""desc"" type=""text"" id=""sample3"""); EndContext(); BeginWriteAttribute("value", " value=\"", 3063, "\"", 3081, 1); #line 78 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" WriteAttributeValue("", 3071, pers.desc, 3071, 10, false); #line default #line hidden EndWriteAttribute(); BeginContext(3082, 773, true); WriteLiteral(@"> <label class=""mdl-textfield__label"" for=""sample3"">Description</label> </div> <div class=""mdl-textfield mdl-js-textfield mdl-textfield--file""> <input class=""mdl-textfield__input"" name=""skilsList"" placeholder=""add a skill"" type=""text"" id=""skill"" /> <div class=""mdl-button mdl-button--icon mdl-button--file"" id=""addSkill""> <i class=""material-icons"">add</i> </div> <input type=""hidden"" value="""" name=""skills"" /> </div> <div class=""mdl-textfield mdl-js-textfield mdl-textfield--floating-label""> <input class=""mdl-textfield__input"" type=""text"" name=""phone"""); EndContext(); BeginWriteAttribute("value", " value=\"", 3855, "\"", 3874, 1); #line 90 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" WriteAttributeValue("", 3863, pers.phone, 3863, 11, false); #line default #line hidden EndWriteAttribute(); BeginContext(3875, 437, true); WriteLiteral(@" pattern=""-?[0-9]*(\.[0-9]+)?"" id=""sample4""> <label class=""mdl-textfield__label"" for=""sample4"">Phone Number...</label> <span class=""mdl-textfield__error"">Input is not a number!</span> </div> <div class=""mdl-textfield mdl-js-textfield mdl-textfield--floating-label""> <input class=""mdl-textfield__input"" name=""email"" type=""email"" id=""sample3"""); EndContext(); BeginWriteAttribute("value", " value=\"", 4312, "\"", 4331, 1); #line 95 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" WriteAttributeValue("", 4320, pers.email, 4320, 11, false); #line default #line hidden EndWriteAttribute(); BeginContext(4332, 298, true); WriteLiteral(@"> <label class=""mdl-textfield__label"" for=""sample3"">E-Mail</label> </div> <div class=""mdl-textfield mdl-js-textfield mdl-textfield--floating-label""> <input class=""mdl-textfield__input"" name=""place"" type=""text"" id=""sample3"""); EndContext(); BeginWriteAttribute("value", " value=\"", 4630, "\"", 4649, 1); #line 99 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" WriteAttributeValue("", 4638, pers.place, 4638, 11, false); #line default #line hidden EndWriteAttribute(); BeginContext(4650, 295, true); WriteLiteral(@"> <label class=""mdl-textfield__label"" for=""sample3"">Place</label> </div> <div class=""mdl-textfield mdl-js-textfield mdl-textfield--floating-label""> <input class=""mdl-textfield__input"" name=""map"" type=""text"" id=""sample3"""); EndContext(); BeginWriteAttribute("value", " value=\"", 4945, "\"", 4962, 1); #line 103 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" WriteAttributeValue("", 4953, pers.map, 4953, 9, false); #line default #line hidden EndWriteAttribute(); BeginContext(4963, 344, true); WriteLiteral(@"> <label class=""mdl-textfield__label"" for=""sample3"">Map...</label> </div> <button class=""mdl-button mdl-js-button mdl-button--raised mdl-button--colored""> SEND </button> <div id=""skillList""> <h5>Skills List</h5> "); EndContext(); #line 111 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" if (pers.skills != null) { #line default #line hidden #line 115 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" foreach (string skill in pers.skills.Split(",")) { #line default #line hidden BeginContext(5483, 159, true); WriteLiteral(" <span class=\"mdl-chip mdl-chip--deletable\" id=\"item\">\r\n <span class=\"mdl-chip__text\" id=\"skillName\">"); EndContext(); BeginContext(5643, 5, false); #line 118 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" Write(skill); #line default #line hidden EndContext(); BeginContext(5648, 172, true); WriteLiteral("</span>\r\n <button type=\"button\" class=\"mdl-chip__action\"><i class=\"material-icons\">cancel</i></button>\r\n </span>\r\n"); EndContext(); #line 121 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" } #line default #line hidden #line 121 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" } #line default #line hidden BeginContext(5874, 36, true); WriteLiteral(" </div>\r\n "); EndContext(); } ); __Microsoft_AspNetCore_Mvc_TagHelpers_FormTagHelper = CreateTagHelper <global::Microsoft.AspNetCore.Mvc.TagHelpers.FormTagHelper>(); __tagHelperExecutionContext.Add(__Microsoft_AspNetCore_Mvc_TagHelpers_FormTagHelper); __Microsoft_AspNetCore_Mvc_TagHelpers_RenderAtEndOfFormTagHelper = CreateTagHelper <global::Microsoft.AspNetCore.Mvc.TagHelpers.RenderAtEndOfFormTagHelper>(); __tagHelperExecutionContext.Add(__Microsoft_AspNetCore_Mvc_TagHelpers_RenderAtEndOfFormTagHelper); __Microsoft_AspNetCore_Mvc_TagHelpers_FormTagHelper.Action = (string)__tagHelperAttribute_0.Value; __tagHelperExecutionContext.AddTagHelperAttribute(__tagHelperAttribute_0); if (__Microsoft_AspNetCore_Mvc_TagHelpers_FormTagHelper.RouteValues == null) { throw new InvalidOperationException(InvalidTagHelperIndexerAssignment("asp-route-id", "Microsoft.AspNetCore.Mvc.TagHelpers.FormTagHelper", "RouteValues")); } BeginWriteTagHelperAttribute(); #line 60 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" WriteLiteral(pers.ID); #line default #line hidden __tagHelperStringValueBuffer = EndWriteTagHelperAttribute(); __Microsoft_AspNetCore_Mvc_TagHelpers_FormTagHelper.RouteValues["id"] = __tagHelperStringValueBuffer; __tagHelperExecutionContext.AddTagHelperAttribute("asp-route-id", __Microsoft_AspNetCore_Mvc_TagHelpers_FormTagHelper.RouteValues["id"], global::Microsoft.AspNetCore.Razor.TagHelpers.HtmlAttributeValueStyle.DoubleQuotes); __tagHelperExecutionContext.AddHtmlAttribute(__tagHelperAttribute_1); __tagHelperExecutionContext.AddHtmlAttribute(__tagHelperAttribute_2); await __tagHelperRunner.RunAsync(__tagHelperExecutionContext); if (!__tagHelperExecutionContext.Output.IsContentModified) { await __tagHelperExecutionContext.SetOutputContentAsync(); } Write(__tagHelperExecutionContext.Output); __tagHelperExecutionContext = __tagHelperScopeManager.End(); EndContext(); BeginContext(5917, 2, true); WriteLiteral("\r\n"); EndContext(); #line 127 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" } else if (Model.Count() == 0) { #line default #line hidden BeginContext(5983, 50, true); WriteLiteral(" <h3>First setup... </h3>\r\n "); EndContext(); BeginContext(6033, 3586, false); __tagHelperExecutionContext = __tagHelperScopeManager.Begin("form", global::Microsoft.AspNetCore.Razor.TagHelpers.TagMode.StartTagAndEndTag, "2f938b7e3cef432084db85f9827c0206", async() => { BeginContext(6059, 3553, true); WriteLiteral(@" <div class=""mdl-textfield mdl-js-textfield mdl-textfield--floating-label""> <input class=""mdl-textfield__input"" name=""name"" type=""text"" id=""sample3""> <label class=""mdl-textfield__label"" for=""sample3"">Name...</label> </div> <div class=""mdl-textfield mdl-js-textfield mdl-textfield--file""> <input class=""mdl-textfield__input"" name=""image"" placeholder=""Add a photo"" type=""text"" id=""TEXT_ID"" readonly /> <div class=""mdl-button mdl-button--icon mdl-button--file""> <i class=""material-icons"">attach_file</i> <input type=""file"" name=""NAME"" id=""ID"" onchange=""document.getElementById('TEXT_ID').value=this.files[0].name;"" /> </div> </div> <div class=""mdl-textfield mdl-js-textfield mdl-textfield--floating-label""> <input class=""mdl-textfield__input"" name=""image_desc"" type="); WriteLiteral(@"""text"" id=""sample3""> <label class=""mdl-textfield__label"" for=""sample3"">Image Description</label> </div> <div class=""mdl-textfield mdl-js-textfield mdl-textfield--floating-label""> <input class=""mdl-textfield__input"" name=""desc"" type=""text"" id=""sample3""> <label class=""mdl-textfield__label"" for=""sample3"">Description</label> </div> <div class=""mdl-textfield mdl-js-textfield mdl-textfield--file""> <input class=""mdl-textfield__input"" name=""skilsList"" placeholder=""add a skill"" type=""text"" id=""skill"" /> <div class=""mdl-button mdl-button--icon mdl-button--file"" id=""addSkill""> <i class=""material-icons"">add</i> </div> <input type=""hidden"" value="""" name=""skills"" /> </div> <div class=""mdl-textfield mdl-js-textfield mdl-textfield--float"); WriteLiteral(@"ing-label""> <input class=""mdl-textfield__input"" type=""text"" name=""phone"" pattern=""-?[0-9]*(\.[0-9]+)?"" id=""sample4""> <label class=""mdl-textfield__label"" for=""sample4"">Phone Number...</label> <span class=""mdl-textfield__error"">Input is not a number!</span> </div> <div class=""mdl-textfield mdl-js-textfield mdl-textfield--floating-label""> <input class=""mdl-textfield__input"" name=""email"" type=""email"" id=""sample3""> <label class=""mdl-textfield__label"" for=""sample3"">E-Mail</label> </div> <div class=""mdl-textfield mdl-js-textfield mdl-textfield--floating-label""> <input class=""mdl-textfield__input"" name=""place"" type=""text"" id=""sample3""> <label class=""mdl-textfield__label"" for=""sample3"">Place</label> </div> <div class=""mdl-textfield mdl-js-textfield mdl-textfield--floating-l"); WriteLiteral(@"abel""> <input class=""mdl-textfield__input"" name=""map"" type=""text"" id=""sample3""> <label class=""mdl-textfield__label"" for=""sample3"">Map...</label> </div> <button class=""mdl-button mdl-js-button mdl-button--raised mdl-button--colored""> SEND </button> <div id=""skillList""> <h5>Skills List</h5> </div> "); EndContext(); } ); __Microsoft_AspNetCore_Mvc_TagHelpers_FormTagHelper = CreateTagHelper <global::Microsoft.AspNetCore.Mvc.TagHelpers.FormTagHelper>(); __tagHelperExecutionContext.Add(__Microsoft_AspNetCore_Mvc_TagHelpers_FormTagHelper); __Microsoft_AspNetCore_Mvc_TagHelpers_RenderAtEndOfFormTagHelper = CreateTagHelper <global::Microsoft.AspNetCore.Mvc.TagHelpers.RenderAtEndOfFormTagHelper>(); __tagHelperExecutionContext.Add(__Microsoft_AspNetCore_Mvc_TagHelpers_RenderAtEndOfFormTagHelper); __Microsoft_AspNetCore_Mvc_TagHelpers_FormTagHelper.Action = (string)__tagHelperAttribute_3.Value; __tagHelperExecutionContext.AddTagHelperAttribute(__tagHelperAttribute_3); await __tagHelperRunner.RunAsync(__tagHelperExecutionContext); if (!__tagHelperExecutionContext.Output.IsContentModified) { await __tagHelperExecutionContext.SetOutputContentAsync(); } Write(__tagHelperExecutionContext.Output); __tagHelperExecutionContext = __tagHelperScopeManager.End(); EndContext(); BeginContext(9619, 2, true); WriteLiteral("\r\n"); EndContext(); DefineSection("Scripts", async() => { BeginContext(9655, 2, true); WriteLiteral("\r\n"); EndContext(); #line 190 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" await Html.RenderPartialAsync("_ValidationScriptsPartial"); #line default #line hidden BeginContext(9737, 12, true); WriteLiteral(" "); EndContext(); } ); #line 191 "C:\Users\tekno\source\repos\PersonalSite\PersonalSite\Views\Personal\Index.cshtml" } #line default #line hidden BeginContext(9765, 1441, true); WriteLiteral(@" </div> <div class=""mdl-cell mdl-cell--3-col""></div> </div> <script> $('#addSkill').click(function (event) { addSkill(); }); $(""#item button"").click(function () { $(this).closest(""#item"").remove(); refreshList(); }); function refreshList() { var skillsArray = []; $(""#skillList #item"").each(function (index) { skillsArray.push($(this).find(""#skillName"").text()); }); $('input[name=""skills""]').val(skillsArray.toString()); } function addSkill() { if ($('#skill').val() != """") { $(""#skillList"").append( '<span class=""mdl-chip mdl-chip--deletable"" id=""item"">' + '<span class=""mdl-chip__text"" id=""skillName"">' + $('#skill').val() + '</span>' + ' <button type=""button"" class=""mdl-chip__action""><i class=""material-icons"">cancel</i></button>' + '</span>').on('click', '#item', function () { "); WriteLiteral(@" $(this).remove(); refreshList(); });; $('#skill').val(""""); refreshList(); } } $(document).ready(function () { refreshList(); }); $(window).keydown(function (event) { if (event.keyCode == 13) { addSkill(); event.preventDefault(); return false; } }); </script>"); EndContext(); }
public static void Delete(Personal obj) { Delete <Personal>(obj); }
private async void ExecuteLoginAsync() { /// validacion de los campos if (string.IsNullOrEmpty(this.UserName)) { await Application.Current.MainPage.DisplayAlert("Alerta", "Ingrese el nombre de usuario :(", "Aceptar"); return; } if (string.IsNullOrEmpty(this.Password)) { await Application.Current.MainPage.DisplayAlert("Alerta", "Ingrese la contraseña :(", "Aceptar"); Password = ""; return; } /// Actualizando los estados this.IsRunning = true; this.IsEnabled = false; /// Verificar conecion a internet Response connection = await this.webService.CheckConnection(); if (!connection.IsSuccess) { this.IsRunning = false; this.IsEnabled = true; await Application.Current.MainPage.DisplayAlert("Alerta", connection.Message, "Aceptar"); return; } try { /// Logueando El Usuario Personal personal = new Personal(); personal.usuario = this.UserName; personal.password = this.Password; // Login del personal List <Personal> user = await webService.POST <Personal, List <Personal> >("personal", "buscar", personal); if (user.Count == 0) // Contraseña y usuario incorrecta { await Application.Current.MainPage.DisplayAlert("Error", "El nombre de usuario o contraseña es incorrecta!!", "Aceptar"); return; } App.personal = user[0]; // Lamacenando en una base de datos local si el usuario indico recordar contraseña if (IsRemembered) { App.personal.IsRemembered = this.IsRemembered; App.personal.password = this.Password; dataService.InsertPersonal(App.personal); } // cargar componentes desde el webservice await cargarComponente(); // esperar a que cargen todo los web service await Task.Run(() => { while (true) { Thread.Sleep(50); if (nLoads >= 10) // IMPORTANTE IMPORTANTE el numero tiene que ser igual al numero de web service que se este llamando { break; } } }); // Compronbando la asignacion if (App.almacenes.Count > 1 || App.puntosDeVenta.Count > 1) { App.Current.MainPage = new AdmeliApp.Pages.Root.ConfigInitialPage(); } else { // asignando los id principales de almacen y id punto de venta App.currentIdAlmacen = (App.almacenes.Count > 0) ? App.almacenes[0].idAlmacen : 0; App.currentIdPuntoVenta = (App.puntosDeVenta.Count > 0) ? App.puntosDeVenta[0].idAsignarPuntoVenta : 0; // Mostrando la pagina principal App.Current.MainPage = new AdmeliApp.Pages.Root.RootPage(); } } catch (Exception ex) { await Application.Current.MainPage.DisplayAlert("Error", ex.Message, "Aceptar"); } finally { this.IsRunning = false; this.IsEnabled = true; } }
public void CardInserted(Personal personal) { if (personal == null) return; lbl_cid.BeginInvoke(new MethodInvoker(delegate { lbl_cid.Text = personal.Citizenid; })); lbl_birthday.BeginInvoke(new MethodInvoker(delegate { lbl_birthday.Text = personal.Birthday.ToString("dd/MM/yyyy"); })); lbl_sex.BeginInvoke(new MethodInvoker(delegate { lbl_sex.Text = personal.Sex; })); lbl_th_prefix.BeginInvoke(new MethodInvoker(delegate { lbl_th_prefix.Text = personal.Th_Prefix; })); lbl_th_firstname.BeginInvoke(new MethodInvoker(delegate { lbl_th_firstname.Text = personal.Th_Firstname; })); lbl_th_lastname.BeginInvoke(new MethodInvoker(delegate { lbl_th_lastname.Text = personal.Th_Lastname; })); lbl_en_prefix.BeginInvoke(new MethodInvoker(delegate { lbl_en_prefix.Text = personal.En_Prefix; })); lbl_en_firstname.BeginInvoke(new MethodInvoker(delegate { lbl_en_firstname.Text = personal.En_Firstname; })); lbl_en_lastname.BeginInvoke(new MethodInvoker(delegate { lbl_en_lastname.Text = personal.En_Lastname; })); lbl_issue.BeginInvoke(new MethodInvoker(delegate { lbl_issue.Text = personal.Issue.ToString("dd/MM/yyyy"); })); lbl_expire.BeginInvoke(new MethodInvoker(delegate { lbl_expire.Text = personal.Expire.ToString("dd/MM/yyyy"); })); pictureBox1.BeginInvoke(new MethodInvoker(delegate { pictureBox1.Image = personal.PhotoBitmap; })); lbl_alarmMessage.BeginInvoke(new MethodInvoker(delegate { lbl_alarmMessage.Text = "กรุณาตรวจสอบข้อมูล"; })); lbl_alarmMessage.BeginInvoke(new MethodInvoker(delegate { lbl_alarmMessage.ForeColor = System.Drawing.Color.Green; })); lbl_alarmMessage.BeginInvoke(new MethodInvoker(delegate { lbl_alarmMessage.Visible = true; })); }
/// <summary> /// 实现ESB用户到授权用户的装换 /// </summary> /// <param name="person"></param> /// <returns></returns> public static AuthenUser GetAuthenUser(Personal person) { AuthenUser authenUser = new AuthenUser(); authenUser.IsSystemAdmin = (person.permission == 0); authenUser.UserID = person.PersonalID; authenUser.UserName = person.PersonalName; authenUser.LoginName = person.PersonalAccount; authenUser.IsVisitor = false; return authenUser; }
public void UpdatePerson(Personal entity) { entity.Update(); }
public void Actualitza(object sender, EventArgs e) { if (!grid.IsSelected()) { return; } int id = int.Parse((string)grid.GetRowCell(grid.GetSelectedRowIndex(), "id").Value); Personal personal = propietaris_manager.GetPersonalPerId(id.ToString()); for (int i = 0; i < personal_per_afegir.Count; i++) { if (personal_per_afegir[i].GetTbl().id == id.ToString()) { personal = personal_per_afegir[i]; break; } } if (personal == null) { return; } if (!FormulariComplert()) { return; } personal_per_eliminar.Add(personal); tblPersonal p = new tblPersonal(); Propietari propietari = propietari_combo.GetSelected() as Propietari; p.nom = nom_text_input.GetText(); p.nif = nif_text_input.GetText(); p.numCarnet = num_carnet_text_input.GetText(); p.nivell = qualificacio_text_input.GetText(); p.id = personal.GetTbl().id; p.CodigoEmpresa = propietari.GetTbl().CodigoEmpresa; p.idProveedor = int.Parse(propietari.GetTbl().idProveedor); var checkedButton = tipus_panel.GetElement().Controls.OfType <RadioButton>().FirstOrDefault(r => r.Checked); if (checkedButton == propi_radiobutton.GetElement()) { p.personal = true; } else if (checkedButton == contractat_radiobutton.GetElement()) { p.contractat = true; } else if (checkedButton == serveis_radiobutton.GetElement()) { p.empresa = true; } Personal nou_personal = new Personal(p); personal_per_afegir.Add(nou_personal); ActualitzaLlistaPersonal(); }
public IActionResult Delete(int id) { Personal personal = _repo.Get(id); return(View(personal)); }
public IActionResult Delete(Personal personal) { _repo.Delete(personal); return(RedirectToAction("Index")); }
public IActionResult Edit(int id, Personal personal) { _repo.Update(id, personal); return(RedirectToAction("Index")); }
public IActionResult Create(Personal personal) { _repo.Add(personal); return(RedirectToAction("Index")); }
public ActionResult Registrar_Personal(int id_area, string nombre, string cargo, string t_documento, string n_documento, int edad, string sexo, string est_civil, string celular, string direccion, string correo) { Personal per = new Personal(); Modelo_Personal mp = new Modelo_Personal(); string message; SortedList <string, string> error = new SortedList <string, string>(); if (id_area == 0) { error.Add("sp_id_area", "Seleccione el area"); } if (String.IsNullOrEmpty(nombre)) { error.Add("sp_nombre", "Ingrese el nombre del Usuario"); } if (String.IsNullOrEmpty(cargo)) { error.Add("sp_cargo", "Ingrese el Cargo"); } if (String.IsNullOrEmpty(t_documento)) { error.Add("sp_t_documento", "Ingrese el tipo de documento"); } if (String.IsNullOrEmpty(n_documento)) { error.Add("sp_n_documento", "Ingrese el N° del documento"); } if (edad == 0) { error.Add("sp_edad", "Ingrese la edad del personal"); } if (String.IsNullOrEmpty(sexo)) { error.Add("sp_sexo", "Seleccione el Sexo"); } if (String.IsNullOrEmpty(est_civil)) { error.Add("sp_est_civil", "Seleccione su estado civil"); } if (String.IsNullOrEmpty(correo)) { error.Add("sp_correo", "Ingrese el correo del personal"); } if (String.IsNullOrEmpty(celular)) { error.Add("sp_correo", "Ingrese el correo del personal"); } if (String.IsNullOrEmpty(direccion)) { error.Add("sp_direccion", "Ingrese la direccion del personal"); } if (String.IsNullOrEmpty(cargo)) { error.Add("sp_celular", "Ingrese el Cargo"); } if (error.Count == 0) { per.Id_area = id_area == 0 ? 0 : id_area;; per.Nombre = nombre == null ? "" : nombre; per.Cargo = cargo == null ? "" : cargo; per.T_documento = t_documento == null ? "" : t_documento; per.N_documento = n_documento == null ? "" : n_documento; per.Edad = edad == 0 ? 0 : edad; per.Sexo = sexo == null ? "" : sexo; per.Est_civil = est_civil == null ? "" : est_civil; per.Correo = correo == null ? "" : correo; per.Celular = celular == null ? "" : celular; per.Direccion = direccion == null ? "" : direccion; per.Cargo = cargo == null ? "" : cargo; if (mp.guardar(per)) { message = "Se guardaron los datos correctamente"; } else { message = "No se Guardaron lo datos"; } return(Json(new { message = message, success = true })); } else { message = "Ingrese los datos necesarios"; return(Json(new { message = message, success = false, datos = error })); } }
public void LäggTillPersonal(Personal personal) { uiw.PersonalRepository.Add(personal); }
public AddHotel(Personal per) { personal_seleccionado = per; InitializeComponent(); }
// Register the type on the generic ThingToFhir partial class public static Patient ToFhir(this Personal personal, Patient patient) { return(PersonalToFhir.ToFhirInternal(personal, patient)); }
public override void Visit(Personal personal) { if (!personal.SalitaID.HasValue) { this.AddError(MessageError.PERSONAL_TURNO); } if (!personal.FechaAsignacion.HasValue) { this.AddError(MessageError.PERSONAL_FECHA); } if (!personal.IdCargo.HasValue) { this.AddError(MessageError.PERSONAL_CARGO); } foreach (var requisito in personal.requisitos) { if (requisito.Estado == true && !requisito.fechaPresentacion.HasValue) { this.AddError(MessageError.PERSONAL_FECHA_PRESENTACION); break; } if (requisito.fechaPresentacion.HasValue && requisito.fechaPresentacion > fechaHoy) { this.AddError(MessageError.PERSONAL_FECHA_MAYOR_ACTUAL); break; } } if (personal.PersonaSeleccionada != null) { //if (!puedeRegistrar(personal)) //{ // this.AddError(MessageError.PERSONAL_SAVE_ERROR_DOS_TURNOS); //} if (personal.SalitaID.HasValue) { string resultadoTurno = puedeRegistrar(personal); if (resultadoTurno != "S") { this.AddError(resultadoTurno); } if (personal.FechaAsignacion < FechaCreacion(personal)) { this.AddError(MessageError.PERSONAL_SAVE_ERROR_FECHA_ASIG); } } if (personal.PersonaSeleccionada.SexoId == null || personal.PersonaSeleccionada.SexoId == "") { this.AddError(MessageError.PERSONAL_SAVE_ERROR_SEXOID_NULL); } if (personal.PersonaSeleccionada.NumeroId == -1) { if (string.IsNullOrEmpty(personal.PersonaSeleccionada.Nombre)) { this.AddError(MessageError.PERSONAL_SAVE_ERROR_NOMBRE_NULL); } if (string.IsNullOrEmpty(personal.PersonaSeleccionada.Apellido)) { this.AddError(MessageError.PERSONAL_SAVE_ERROR_APELLIDO_NULL); } if (personal.PersonaSeleccionada.FechaNacimiento == null) { this.AddError(MessageError.PERSONAL_SAVE_ERROR_FECHA_NACIMIENTO_NULL); } if (personal.PersonaSeleccionada.FechaNacimiento.HasValue && personal.PersonaSeleccionada.FechaNacimiento > DateTime.Today) { this.AddError(MessageError.PERSONAL_SAVE_ERROR_FECHA_NACIMIENTO_MAX); } if (!personal.PersonaSeleccionada.Indocumentado) { if (string.IsNullOrEmpty(personal.PersonaSeleccionada.TipoDocumentoId)) { this.AddError(MessageError.PERSONAL_SAVE_ERROR_TIPO_DOCUMENTO_ID_NULL); } } if (string.IsNullOrEmpty(personal.NacionalidadId)) { this.AddError(MessageError.PERSONAL_SAVE_ERROR_NACIONALIDAD_ID_NULL); } if (string.IsNullOrEmpty(personal.PersonaSeleccionada.CodigoPais)) { this.AddError(MessageError.PERSONAL_SAVE_ERROR_PAIS_ID_NULL); } if (string.IsNullOrEmpty(personal.PersonaSeleccionada.EstadoCivilId)) { this.AddError(MessageError.PERSONAL_SAVE_ERROR_ESTADO_CIVIL_ID_NULL); } } else { if (personal.PersonaSeleccionada.NumeroId == null || string.IsNullOrEmpty(personal.PersonaSeleccionada.CodigoPais) || string.IsNullOrEmpty(personal.PersonaSeleccionada.NumeroDocumento)) { this.AddError(MessageError.PERSONAL_PERSONA_SELECCIONADA_NULL); } } } else { this.AddError(MessageError.PERSONAL_PERSONA_SELECCIONADA_NULL); } }
public void CardInserted(Personal personal) { if (personal == null) return; lbl_cid.BeginInvoke(new MethodInvoker(delegate { lbl_cid.Text = personal.Citizenid; })); lbl_birthday.BeginInvoke(new MethodInvoker(delegate { lbl_birthday.Text = personal.Birthday.ToString("dd/MM/yyyy"); })); lbl_sex.BeginInvoke(new MethodInvoker(delegate { lbl_sex.Text = personal.Sex; })); lbl_th_prefix.BeginInvoke(new MethodInvoker(delegate { lbl_th_prefix.Text = personal.Th_Prefix; })); lbl_th_firstname.BeginInvoke(new MethodInvoker(delegate { lbl_th_firstname.Text = personal.Th_Firstname; })); lbl_th_lastname.BeginInvoke(new MethodInvoker(delegate { lbl_th_lastname.Text = personal.Th_Lastname; })); lbl_en_prefix.BeginInvoke(new MethodInvoker(delegate { lbl_en_prefix.Text = personal.En_Prefix; })); lbl_en_firstname.BeginInvoke(new MethodInvoker(delegate { lbl_en_firstname.Text = personal.En_Firstname; })); lbl_en_lastname.BeginInvoke(new MethodInvoker(delegate { lbl_en_lastname.Text = personal.En_Lastname; })); lbl_issue.BeginInvoke(new MethodInvoker(delegate { lbl_issue.Text = personal.Issue.ToString("dd/MM/yyyy"); })); lbl_expire.BeginInvoke(new MethodInvoker(delegate { lbl_expire.Text = personal.Expire.ToString("dd/MM/yyyy"); })); pictureBox1.BeginInvoke(new MethodInvoker(delegate { pictureBox1.Image = personal.PhotoBitmap; })); }
// GET: Informes public async Task <IActionResult> Informes(int?pacienteId, string sortOrder, string currentFilter, string searchString, int?page) { //Mostrar todos los informes del usuario que esta logeado o el paciente seleccionado. if (HttpContext.Session.GetInt32("userLogged") == null) { return(RedirectToAction("Login", "Manage")); } string token = HttpContext.Session.GetString("token"); if (token == null) { TempData["Mensaje"] = "Sesion expirada,vuelva a hacer el log in por favor."; return(RedirectToAction("Login", "Manage")); } int userLogged = int.Parse(HttpContext.Session.GetInt32("userLogged").ToString()); Personal personal = await repo.FindPersonal(userLogged, token); if (personal != null) { ViewBag.MedicoId = personal.PersonalId; } List <Informe> informes; if (pacienteId == null) { Paciente paciente = await repo.FindPaciente(userLogged, token); if (paciente == null) { return(RedirectToAction("VerPerfil", "Manage", new { userLogged = userLogged })); } informes = await repo.GetInformes(paciente.PacienteId, token); } else { informes = await repo.GetInformes(pacienteId.GetValueOrDefault(), token); ViewBag.PacienteId = pacienteId.GetValueOrDefault(); } ViewBag.FechaSortParm = String.IsNullOrEmpty(sortOrder) ? "fecha_desc" : ""; ViewBag.DescripcionSortParm = sortOrder == "Descripcion" ? "descripcion_desc" : "Descripcion"; ViewBag.MedicoSortParm = sortOrder == "Medico" ? "medico_desc" : "Medico"; if (searchString != null) { page = 1; } else { searchString = currentFilter; } ViewBag.CurrentFilter = searchString; if (!String.IsNullOrEmpty(searchString)) { informes = informes.Where(i => i.Descripcion.ToLower().Contains(searchString.ToLower()) || i.Personal.Nombre.ToLower().Contains(searchString.ToLower()) || i.Personal.Apellidos.ToLower().Contains(searchString.ToLower())).ToList(); } switch (sortOrder) { case "fecha_desc": informes = informes.OrderByDescending(i => i.Fecha).ToList(); break; case "Descripcion": informes = informes.OrderBy(i => i.Descripcion).ToList(); break; case "descripcion_desc": informes = informes.OrderByDescending(i => i.Descripcion).ToList(); break; case "Medico": informes = informes.OrderBy(i => i.Personal.Nombre).ToList(); break; case "medico_desc": informes = informes.OrderByDescending(i => i.Personal.Nombre).ToList(); break; default: informes = informes.OrderBy(i => i.Fecha).ToList(); break; } int pageSize = 3; int pageNumber = (page ?? 1); return(View(informes.ToPagedList(pageNumber, pageSize))); }
public Recepcionista ContratarPersonal(Recepcionista empleado) { Personal.Add(empleado); return(empleado); }
public async Task <JsonResult> ProfileUpdate(string Name, string Surname, string Contact, string Email, string Password) { var user = web.Session.SessionUser.User; ImageProcess Ip = new ImageProcess(); try { var image = System.Web.HttpContext.Current.Request.Files[0]; string filename = null; if (image != null && (image.ContentType == "image/jpeg" || image.ContentType == "image/jpg" || image.ContentType == "image/png")) { filename = Ip.Resolution(image, new int[] { 128, 256, 512 }, user.User.UserName.Split('@')[0], "UserPicture"); } else { filename = user.User.Image; } using (business.Management.UserManagement.UserFunctions userM = new business.Management.UserManagement.UserFunctions()) { PasswordRules pw = new PasswordRules(); string hashedPW = Password; if (pw.GeneratePasswordScore(Password) >= 60) { if (Password != user.User.EncryptedPassword) { hashedPW = business.SessionSettings.Crypting.En_De_crypt._Encrypt(Password); } bool verify = true; if (Email != user.User.UserName) { if (user.User.Role == "ClientManager") { if (userM.isManagerExist(Email)) { return(Json(new { result = false, message = "Girdiğiniz bilgiler sistemde kayıtlı..." }, JsonRequestBehavior.AllowGet)); } } else { if (userM.isPersonalExist(Email)) { return(Json(new { result = false, message = "Girdiğiniz bilgiler sistemde kayıtlı..." }, JsonRequestBehavior.AllowGet)); } } BuildEmailTemplate(user.User.UserId); verify = false; } User updateuser = new User { UserName = Email, EncryptedPassword = hashedPW, Image = filename, EmailVeryfied = verify }; if (userM.updateUser(updateuser, user.User.UserId)) { if (user.User.Role.Contains("ClientManager")) { ClientManager updateManager = new ClientManager { Name = Name, Surname = Surname, Email = Email, Password = hashedPW, Contact = Contact, }; if (userM.updateClientManager(updateManager, user.ClientManager_Id)) { return(Json(new { result = true, message = "Bilgileriniz güncellendi." }, JsonRequestBehavior.AllowGet)); } else { return(Json(new { result = false, message = "Bilgileriniz güncellenemedi." }, JsonRequestBehavior.AllowGet)); } } else { Personal updatePersonal = new Personal { Name = Name, Surname = Surname, Contact = Contact, Mail = Email, Password = hashedPW }; if (userM.updatePersonal(updatePersonal, user.Personal_Id)) { return(Json(new { result = true, message = "Bilgileriniz güncellendi." }, JsonRequestBehavior.AllowGet)); } else { return(Json(new { result = false, message = "Bilgileriniz güncellenemedi." }, JsonRequestBehavior.AllowGet)); } } } else { return(Json(new { result = false, message = "Bilgileriniz güncellenemedi." }, JsonRequestBehavior.AllowGet)); } } else { return(Json(new { result = false, message = "Şifreniz zayıf daha güçlü bir şifre giriniz." }, JsonRequestBehavior.AllowGet)); } } } catch (Exception e) { return(Json(new { result = false, message = "Hata oluştu" }, JsonRequestBehavior.AllowGet)); } }
protected void btnComenzarCarga_Click(object sender, EventArgs e) { if (IsValid) { Solicitud Sol = Solicitud.GetById(BiFactory.Sol.Id_Solicitud); SolicitudTareasGenerales sol_Tg = SolicitudTareasGenerales.FindFirst(Expression.Eq("IdSolicitud", BiFactory.Sol.Id_Solicitud)); if (sol_Tg == null) { sol_Tg = new SolicitudTareasGenerales(); sol_Tg.IdSolicitud = Sol.Id_Solicitud; sol_Tg.Descripcion = Sol.Descripcion; } sol_Tg.FechaInicio = AntaresHelper.FechaNula(); sol_Tg.FechaFin = AntaresHelper.FechaNula(); sol_Tg.Duracion = 0; sol_Tg.IdTipotarea = int.Parse(cmbTipoTarea.SelectedValue); sol_Tg.IdEmpleado = BiFactory.Empleado.IdEmpleados; sol_Tg.SaveAndFlush(); txtHorasPersonalDia.Text = string.Empty; ddlHorasPersonalHoras.SelectedIndex = 0; DateTime fechaInicio = Sol.FechaCreacion; DateTime fechaFin = DateTime.MinValue; this.Persona = Personal.GetById(sol_Tg.IdEmpleado.ToString()); litHorasPersonalPersona.Text = Persona.Apellido + "," + Persona.Nombres; cmpVFecha.ValueToCompare = DateTime.Today.ToString("dd/MM/yyyy"); FillHorasPersonalGrid(0); } }
public static IPersonal GetPersonalFactory() { Personal personal = new Personal(); return((IPersonal)personal); }
public static void Update(Personal obj) { Update <Personal>(obj); }
public static void Populate(DatabaseContext dbContext) { if (dbContext.Alumner.Count() == 0) { //Alumn Alumn alumn1 = new Alumn() { Användarnamn = "*****@*****.**", Lösenord = "123", Förnamn = "Vissla", Efternamn = "Kvist", }; dbContext.Alumner.Add(alumn1); Alumn alumn2 = new Alumn() { Användarnamn = "*****@*****.**", Lösenord = "123", Förnamn = "Palle", Efternamn = "Kuling", }; dbContext.Alumner.Add(alumn2); Alumn alumn3 = new Alumn() { Användarnamn = "*****@*****.**", Lösenord = "123", Förnamn = "Jan", Efternamn = "Banan", }; dbContext.Alumner.Add(alumn3); Alumn alumn4 = new Alumn() { Användarnamn = "*****@*****.**", Lösenord = "123", Förnamn = "Tony", Efternamn = "Stark", }; dbContext.Alumner.Add(alumn4); //Program Program program0 = new Program() { Namn = "Alla" }; dbContext.Program.Add(program0); Program program1 = new Program() { Namn = "Systemarkitekt" }; dbContext.Program.Add(program1); Program program2 = new Program() { Namn = "Systemvetare" }; dbContext.Program.Add(program2); Program program3 = new Program() { Namn = "Dataekonom" }; dbContext.Program.Add(program3); dbContext.AlumnProgram.Add(new AlumnProgram() { Alumn = alumn1, Program = program1 }); dbContext.AlumnProgram.Add(new AlumnProgram() { Alumn = alumn2, Program = program2 }); dbContext.AlumnProgram.Add(new AlumnProgram() { Alumn = alumn3, Program = program3 }); dbContext.AlumnProgram.Add(new AlumnProgram() { Alumn = alumn4, Program = program2 }); //Kompetens Kompetens kompetens1 = new Kompetens() { Beskrivning = "Har 3 års erfarenhet som utvecklare i C#" }; dbContext.AlumnKompetens.Add(new AlumnKompetens() { Alumn = alumn1, Kompetens = kompetens1 }); //Personal Personal personal = new Personal() { Användarnamn = "SuperAdmin", Lösenord = "123", Förnamn = "Super", Efternamn = "Admin", }; dbContext.Personal.Add(personal); Personal personal1 = new Personal() { Användarnamn = "P5500", Lösenord = "pers", Förnamn = "Jan", Efternamn = "Andersson", }; dbContext.Personal.Add(personal1); //Aktivitet Aktivitet aktivitet1 = new Aktivitet() { Titel = "Företagsmässa för nyexaminerade", Ansvarig = "Milla Trop", Kontaktperson = "Loki Foi", Plats = "Högskolan i Borås", Startdatum = new DateTime(2020, 08, 01), Slutdatum = new DateTime(2020, 08, 02), Beskrivning = "Träffa företag som är i behov av just dig! Knyt kontakter och maxa dina möjligheter", InformationsutskickAktivitet = new List <InformationsutskickAktivitet>(), AlumnAktivitet = new List <AlumnAktivitetBokning>() }; dbContext.Aktiviteter.Add(aktivitet1); Aktivitet aktivitet2 = new Aktivitet() { Titel = "Föreläsning av Elon Musk", Ansvarig = "Henry Jons", Kontaktperson = "Jocke Boi", Plats = "Högskolan i Borås, Sparbankssalen", Startdatum = new DateTime(2020, 09, 01), Slutdatum = new DateTime(2020, 09, 02), Beskrivning = "Elon Musk kommer och berättar om sin spännande resa från ung entreprenör i Sydafrika till en av världens mest kända företagsledare.", InformationsutskickAktivitet = new List <InformationsutskickAktivitet>(), AlumnAktivitet = new List <AlumnAktivitetBokning>() }; dbContext.Aktiviteter.Add(aktivitet2); dbContext.SaveChanges(); } }
public static void Add(Personal obj) { Add <Personal>(obj); }
public ActionResult Profil(int id) { Personal prs = _personalService.Get(id); return(View(prs)); }
public static List <Personal> obtenerTuplasPersonalUsuariio() { return(Personal.listaDatos2()); }
public ActionResult SendMessage(int id) { Personal personal = _personalService.Get(id); return(View(personal)); }
public static List <Personal> obtenerTuplasPersonalParaFases(string idFase, int tipo) { return(Personal.listaDatosDispFases(idFase, tipo)); }
public Personal ObeterDatosParaActualizar() { Personal persona = new Personal(); persona.Id = Convert.ToInt32(lblIdPerson.Text); persona.Nombre = txtNombre.Text; persona.Cédula = txtCédula.Text; persona.Formacion = dropFormacion.Text; persona.Caducidad_licencia = dtFechaCaduc.Value; persona.Certificacion = null; persona.Observaciones = txtObservacion.Text; if (hoja.buffer != null) { persona.hoja_de_vida = hoja.buffer; } else if (hoja.buffer == null) { persona.hoja_de_vida = hojaV; } if (doc.buffer != null) { persona.doc_personales = doc.buffer; } else if (doc.buffer == null) { persona.doc_personales = docsb; } if (titulo.buffer != null) { persona.doc_Titulo = titulo.buffer; } else if (titulo.buffer == null) { persona.doc_Titulo = titulob; } if (hoja.nombHoja != null) { persona.nombre_hojaV = hoja.nombHoja; } else if (hoja.nombHoja == null) { persona.nombre_hojaV = lblNomHo.Text; } if (titulo.nombTitulo != null) { persona.nombre_titulo = titulo.nombTitulo; } else if (titulo.nombTitulo == null) { persona.nombre_titulo = lblNomTitu.Text; } if (doc.nombDocs != null) { persona.nombre_docP = doc.nombDocs; } else if (doc.nombDocs == null) { persona.nombre_docP = lblnomDocs.Text; } if (certif.buffer != null) { persona.doc_Certificacion = certif.buffer; } else if (certif.buffer == null) { persona.doc_Certificacion = experi; } if (licencia.buffer != null) { persona.Licencia_Riesgos = licencia.buffer; } else if (licencia.buffer == null) { persona.Licencia_Riesgos = licen; } if (certif.nombCertif != null) { persona.nom_docCertif = certif.nombCertif; } else if (certif.nombCertif == null) { persona.nom_docCertif = lblNomExper.Text; } if (licencia.nombLicen != null) { persona.nom_Licencia = licencia.nombLicen; } else if (licencia.nombLicen == null) { persona.nom_Licencia = lblNomLice.Text; } persona.anio = Convert.ToInt32(dropAnio.Text); persona.Tipo_Bachillerato = txtTipoBachiller.Text; return(persona); }
// Register the type on the generic ThingToFhir partial class public static Patient ToFhir(this Personal personal) { return(PersonalToFhir.ToFhirInternal(personal, ThingBaseToFhir.ToFhirInternal <Patient>(personal))); }
private static void Usage () { Console.WriteLine ("brief"); Console.WriteLine (""); { #pragma warning disable 219 Reset Dummy = new Reset (); #pragma warning restore 219 Console.Write ("{0}reset ", UsageFlag); Console.WriteLine (); Console.WriteLine (" Delete all test profiles"); } { #pragma warning disable 219 Device Dummy = new Device (); #pragma warning restore 219 Console.Write ("{0}device ", UsageFlag); Console.Write ("[{0}] ", Dummy.DeviceID.Usage (null, "id", UsageFlag)); Console.Write ("[{0}] ", Dummy.DeviceDescription.Usage (null, "dd", UsageFlag)); Console.Write ("[{0}] ", Dummy.Default.Usage ("default", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Create new device profile"); } { #pragma warning disable 219 Personal Dummy = new Personal (); #pragma warning restore 219 Console.Write ("{0}personal ", UsageFlag); Console.Write ("[{0}] ", Dummy.Portal.Usage (null, "portal", UsageFlag)); Console.Write ("[{0}] ", Dummy.Description.Usage (null, "pd", UsageFlag)); Console.Write ("[{0}] ", Dummy.Next.Usage ("next", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Verbose.Usage ("verbose", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Report.Usage ("report", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.DeviceNew.Usage ("new", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.DeviceUDF.Usage ("dudf", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.DeviceID.Usage ("did", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.DeviceDescription.Usage ("dd", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Create new personal profile"); } { #pragma warning disable 219 Register Dummy = new Register (); #pragma warning restore 219 Console.Write ("{0}register ", UsageFlag); Console.Write ("[{0}] ", Dummy.UDF.Usage (null, "udf", UsageFlag)); Console.Write ("[{0}] ", Dummy.Portal.Usage (null, "portal", UsageFlag)); Console.Write ("[{0}] ", Dummy.Verbose.Usage ("verbose", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Report.Usage ("report", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Register the specified profile at a new portal"); } { #pragma warning disable 219 Sync Dummy = new Sync (); #pragma warning restore 219 Console.Write ("{0}sync ", UsageFlag); Console.Write ("[{0}] ", Dummy.Portal.Usage ("portal", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.UDF.Usage ("udf", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Verbose.Usage ("verbose", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Report.Usage ("report", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Synchronize local copies of Mesh profiles with the server"); } { #pragma warning disable 219 Escrow Dummy = new Escrow (); #pragma warning restore 219 Console.Write ("{0}escrow ", UsageFlag); Console.Write ("[{0}] ", Dummy.Quorum.Usage ("quorum", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Shares.Usage ("shares", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Portal.Usage ("portal", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.UDF.Usage ("udf", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Verbose.Usage ("verbose", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Report.Usage ("report", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Create a set of key escrow shares"); } { #pragma warning disable 219 Export Dummy = new Export (); #pragma warning restore 219 Console.Write ("{0}export ", UsageFlag); Console.Write ("[{0}] ", Dummy.File.Usage (null, "file", UsageFlag)); Console.Write ("[{0}] ", Dummy.Portal.Usage ("portal", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.UDF.Usage ("udf", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Verbose.Usage ("verbose", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Report.Usage ("report", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Export the specified profile data to the specified file"); } { #pragma warning disable 219 Import Dummy = new Import (); #pragma warning restore 219 Console.Write ("{0}import ", UsageFlag); Console.Write ("[{0}] ", Dummy.File.Usage (null, "file", UsageFlag)); Console.Write ("[{0}] ", Dummy.Portal.Usage ("portal", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.UDF.Usage ("udf", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Verbose.Usage ("verbose", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Report.Usage ("report", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Import the specified profile data to the specified file"); } { #pragma warning disable 219 List Dummy = new List (); #pragma warning restore 219 Console.Write ("{0}list ", UsageFlag); Console.Write ("[{0}] ", Dummy.Verbose.Usage ("verbose", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Report.Usage ("report", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" List all profiles on the local machine"); } { #pragma warning disable 219 Dump Dummy = new Dump (); #pragma warning restore 219 Console.Write ("{0}dump ", UsageFlag); Console.Write ("[{0}] ", Dummy.Portal.Usage ("portal", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.UDF.Usage ("udf", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Verbose.Usage ("verbose", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Report.Usage ("report", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Describe the specified profile"); } { #pragma warning disable 219 Pending Dummy = new Pending (); #pragma warning restore 219 Console.Write ("{0}pending ", UsageFlag); Console.Write ("[{0}] ", Dummy.Portal.Usage ("portal", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.UDF.Usage ("udf", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Verbose.Usage ("verbose", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Report.Usage ("report", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Get list of pending connection requests"); } { #pragma warning disable 219 Connect Dummy = new Connect (); #pragma warning restore 219 Console.Write ("{0}connect ", UsageFlag); Console.Write ("[{0}] ", Dummy.Portal.Usage (null, "portal", UsageFlag)); Console.Write ("[{0}] ", Dummy.PIN.Usage ("pin", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Verbose.Usage ("verbose", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Report.Usage ("report", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.DeviceNew.Usage ("new", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.DeviceUDF.Usage ("dudf", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.DeviceID.Usage ("did", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.DeviceDescription.Usage ("dd", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Connect to an existing profile registered at a portal"); } { #pragma warning disable 219 Accept Dummy = new Accept (); #pragma warning restore 219 Console.Write ("{0}accept ", UsageFlag); Console.Write ("[{0}] ", Dummy.DeviceUDF.Usage (null, "udf", UsageFlag)); Console.Write ("[{0}] ", Dummy.Verbose.Usage ("verbose", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Report.Usage ("report", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Portal.Usage ("portal", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.UDF.Usage ("udf", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Accept a pending connection"); } { #pragma warning disable 219 Complete Dummy = new Complete (); #pragma warning restore 219 Console.Write ("{0}complete ", UsageFlag); Console.Write ("[{0}] ", Dummy.Verbose.Usage ("verbose", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Report.Usage ("report", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Portal.Usage ("portal", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.UDF.Usage ("udf", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Complete a pending connection request"); } { #pragma warning disable 219 Password Dummy = new Password (); #pragma warning restore 219 Console.Write ("{0}password ", UsageFlag); Console.Write ("[{0}] ", Dummy.Portal.Usage ("portal", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.UDF.Usage ("udf", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Verbose.Usage ("verbose", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Report.Usage ("report", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Add a web application profile to a personal profile"); } { #pragma warning disable 219 AddPassword Dummy = new AddPassword (); #pragma warning restore 219 Console.Write ("{0}pwadd ", UsageFlag); Console.Write ("[{0}] ", Dummy.Site.Usage (null, "site", UsageFlag)); Console.Write ("[{0}] ", Dummy.Username.Usage (null, "user", UsageFlag)); Console.Write ("[{0}] ", Dummy.Password.Usage (null, "password", UsageFlag)); Console.Write ("[{0}] ", Dummy.Portal.Usage ("portal", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.UDF.Usage ("udf", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Verbose.Usage ("verbose", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Report.Usage ("report", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Add password entry"); } { #pragma warning disable 219 GetPassword Dummy = new GetPassword (); #pragma warning restore 219 Console.Write ("{0}pwget ", UsageFlag); Console.Write ("[{0}] ", Dummy.Site.Usage (null, "site", UsageFlag)); Console.Write ("[{0}] ", Dummy.Portal.Usage ("portal", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.UDF.Usage ("udf", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Verbose.Usage ("verbose", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Report.Usage ("report", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Lookup password entry"); } { #pragma warning disable 219 DeletePassword Dummy = new DeletePassword (); #pragma warning restore 219 Console.Write ("{0}pwdelete ", UsageFlag); Console.Write ("[{0}] ", Dummy.Site.Usage (null, "site", UsageFlag)); Console.Write ("[{0}] ", Dummy.Portal.Usage ("portal", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.UDF.Usage ("udf", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Verbose.Usage ("verbose", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Report.Usage ("report", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Delete password entry"); } { #pragma warning disable 219 DumpPassword Dummy = new DumpPassword (); #pragma warning restore 219 Console.Write ("{0}pwdump ", UsageFlag); Console.Write ("[{0}] ", Dummy.JSON.Usage (null, "json", UsageFlag)); Console.Write ("[{0}] ", Dummy.Portal.Usage ("portal", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.UDF.Usage ("udf", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Verbose.Usage ("verbose", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Report.Usage ("report", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Describe password entry"); } { #pragma warning disable 219 Mail Dummy = new Mail (); #pragma warning restore 219 Console.Write ("{0}mail ", UsageFlag); Console.Write ("[{0}] ", Dummy.address.Usage (null, "address", UsageFlag)); Console.Write ("[{0}] ", Dummy.Portal.Usage ("portal", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.UDF.Usage ("udf", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Verbose.Usage ("verbose", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Report.Usage ("report", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Add a mail application profile to a personal profile"); } { #pragma warning disable 219 SSH Dummy = new SSH (); #pragma warning restore 219 Console.Write ("{0}ssh ", UsageFlag); Console.Write ("[{0}] ", Dummy.Host.Usage (null, "host", UsageFlag)); Console.Write ("[{0}] ", Dummy.Client.Usage (null, "client", UsageFlag)); Console.Write ("[{0}] ", Dummy.Portal.Usage ("portal", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.UDF.Usage ("udf", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Verbose.Usage ("verbose", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Report.Usage ("report", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Add a ssh application profile to a personal profile"); } } // Usage
public void InsertPerson(Personal entity) { if (String.IsNullOrEmpty(entity.PersonalID)) entity.PersonalID = Guid.NewGuid().ToString(); entity.Insert(); }
protected void Page_Load(object sender, EventArgs e) { if (!Page.IsPostBack) { if ((Request.QueryString["Id"] != null)) { IdSolicitudRecurso = int.Parse(Request.QueryString["Id"].ToString()); SolicitudRecursosEmpleados s = SolicitudRecursosEmpleados.FindFirst(Expression.Eq("Id", IdSolicitudRecurso)); //SolicitudRendicionPersonalHoras ph = SolicitudRendicionPersonalHoras.fin IdSolicitud = s.IdSolicitud; IdPersona = s.IdEmpleado; FechaRango r = Solicitud.PeriodoDesdeHasta(s.IdSolicitud); makeCboFecha(r); p = Personal.GetById(s.IdEmpleado.ToString()); txtPersona.Text = p.Apellido + "," + p.Nombres; } } fillGrid(); }
public void DeletePerson(Personal entity) { entity.Delete(); }
/// <summary>Helper: put the buffer into a MemoryStream before deserializing</summary> public static Personal.AddressBook Deserialize(byte[] buffer, Personal.AddressBook instance) { using (var ms = new MemoryStream(buffer)) Deserialize(ms, instance); return instance; }
/// <summary> /// Create a new personal profile /// </summary> /// <param name="Options">Command line parameters</param> public override void Personal(Personal Options) { SetReporting(Options.Report, Options.Verbose); var Address = Options.Portal.Value; Utils.Assert((Address != null & Address != ""), "Must specify account"); // See if the portal exists and will accept the specified account name. GetMeshClient(Address); var AccountAvailable = MeshClient.Validate(AccountID); if (!AccountAvailable.Valid) { if (Options.Next.Value) { GetNextAccount(); } else { Utils.Error("Portal refused account {0} because {1}", Address, AccountAvailable.Reason); } } // Get / create the device profile if required RegistrationDevice RegistrationDevice = null; bool Generate = false; if (Options.DeviceNew.Value) { Generate = true; } else if (Options.DeviceUDF.Value != null) { // use the profile with the specified fingerprint var Found = Machine.GetUDF(Options.DeviceUDF.Value, out RegistrationDevice); Utils.Assert(Found, "Could not find profile " + Options.DeviceUDF.Value); } else if (Options.DeviceID.Value != null) { // use the profile with the specified ID var Found = Machine.GetID(Options.DeviceID.Value, out RegistrationDevice); Utils.Assert(Found, "Could not find profile " + Options.DeviceID.Value); } else if (Machine.Device != null) { RegistrationDevice = Machine.Device; } else { Generate = true; } // Generate a new device profile if (Generate) { var DeviceID = Utils.Default(Options.DeviceID.Value, "Default"); var DeviceDescription = Utils.Default(Options.DeviceDescription.Value, "Unknown"); var NewProfileDevice = new SignedDeviceProfile(DeviceID, DeviceDescription); RegistrationDevice = Machine.Add(NewProfileDevice); } var ProfileDevice = RegistrationDevice.Device; var PersonalProfile = new PersonalProfile(ProfileDevice); var SignedPersonalProfile = PersonalProfile.Signed; // add to the machine registry Machine.Add(SignedPersonalProfile, PortalID); // Register with the Mesh portal var PublishResult = MeshClient.Publish(SignedPersonalProfile); Utils.Assert(PublishResult.Status.StatusSuccess(), "Portal refused profile publication request"); Report("Created new personal profile {0}", SignedPersonalProfile.UDF); Report("Device profile is {0}", ProfileDevice.UDF); Report("Profile registered to {0}", PortalID); }
/// <summary>Helper: put the buffer into a MemoryStream before deserializing</summary> public static Personal.Person.PhoneNumber Deserialize(byte[] buffer, Personal.Person.PhoneNumber instance) { using (var ms = new MemoryStream(buffer)) Deserialize(ms, instance); return instance; }
private void FillSol() { if (Request.QueryString["Id"] != null) { IdSol = int.Parse(Request.QueryString["Id"].ToString()); BiFactory.Sol = Solicitud.GetById(IdSol); } sol_Cap = SolicitudCapacitacion.FindFirst(Expression.Eq("IdSolicitud", BiFactory.Sol.Id_Solicitud)); if (sol_Cap != null) { cmbNivelCapacitacion.SelectedValue = sol_Cap.Nivel; txtAreaEstudios.Text = sol_Cap.AreaEstudio; txtEntidad.Text = sol_Cap.EntidadEducativa; txtInstructor.Text = sol_Cap.Instructor; txtPuntuacionExamen.Text = sol_Cap.PuntuacionExamen; Persona = Personal.GetById(sol_Cap.IdEmpleado.ToString()); FillHorasPersonalGrid(0); MostrarSolicitud(); } else { Persona = Personal.GetById(BiFactory.Empleado.IdEmpleados.ToString()); } litHorasPersonalPersona.Text = Persona.Apellido + "," + Persona.Nombres; //CargarCombos(); }
internal static Patient ToFhirInternal(Personal personal, Patient patient) { if (personal.BirthDate?.Date != null) { patient.BirthDateElement = new Date(personal.BirthDate.Date.Year, personal.BirthDate.Date.Month, personal.BirthDate.Date.Day); if (personal.BirthDate?.Time != null) { patient.BirthDateElement.AddExtension(HealthVaultExtensions.PatientBirthTime, personal.BirthDate.Time.ToFhir()); } } if (personal.DateOfDeath != null) { patient.Deceased = personal.DateOfDeath.ToFhir(); } else { patient.Deceased = new FhirBoolean(personal.IsDeceased); } patient.Extension.Add(PopulatePersonalExtension(personal)); if (personal.Name != null) { var humanName = new HumanName { Family = personal.Name.Last, Text = personal.Name.Full, }; var givenNames = new List <string>(); if (!string.IsNullOrEmpty(personal.Name.First)) { givenNames.Add(personal.Name.First); } if (!string.IsNullOrEmpty(personal.Name.Middle)) { givenNames.Add(personal.Name.Middle); } humanName.Given = givenNames; if (personal.Name.Title != null) { humanName.Prefix = new List <string> { personal.Name.Title.Text }; } if (personal.Name.Suffix != null) { humanName.Suffix = new List <string> { personal.Name.Suffix.Text }; } patient.Name.Add(humanName); } if (!string.IsNullOrEmpty(personal.SocialSecurityNumber)) { patient.Identifier.Add(new Identifier { Value = personal.SocialSecurityNumber, System = Constants.FhirExtensions.SSN, } ); } return(patient); }
protected void CargarCombos(int IdEmpleado) { persona = Personal.FindOne(Expression.Eq("IdEmpleados", IdEmpleado)); cmbPersonal.Items.Clear(); cmbPersonal.Items.Add(new ListItem(persona.Apellido + "," + persona.Nombres, persona.IdEmpleados.ToString())); }
public LoVSolicita(String SolicitaCod) { InitializeComponent(); this.Text = "Solicitante"; this.StartPosition = FormStartPosition.Manual; this.Location = new Point(50, 20); emisionForm = Caja.EmisionVoucher.formEmision; reportevoucher = Reporte.ReporteVoucher.formReporteCheques; codigoSolicita = SolicitaCod; objLoVDao = new LoVDAO(); objPersonal = new Personal(); objProveedor = new Proveedor(); objBanco = new CuentaBanco(); objCliente = new Cliente(); this.ActiveControl = txt_Busqueda; objListPersonal = objLoVDao.getLovPersonal(); objListPersonalTotal = objListPersonal; objListProveedor = objLoVDao.getLovProveedor(Ventas.UNIDADNEGOCIO); objListProveedorTotal = objListProveedor; objListaCliente = objLoVDao.getLovCliente(Ventas.UNIDADNEGOCIO); objListaClienteTotal = objListaCliente; objListaBanco = objLoVDao.getLovBancoSolicita(Ventas.UNIDADNEGOCIO); objListaBancoTotal = objListaBanco; txt_Busqueda.TextChanged += Txt_Busqueda_TextChanged; grdSolicita.DoubleClick += GrdSolicita_DoubleClick; switch (SolicitaCod) { case "02": lbl_Solicita.Text = "Razón Social o Ruc"; gridParamsProveedor(); grdSolicita.DataSource = objListProveedor; grdSolicita.Refresh(); break; case "03": lbl_Solicita.Text = "Nombre o Documento"; gridParamsPersonal(); grdSolicita.DataSource = objListPersonal; grdSolicita.Refresh(); break; case "04": lbl_Solicita.Text = "Nombre del Banco"; gridParamsBanco(); grdSolicita.DataSource = objListaBanco; grdSolicita.Refresh(); break; case "05": lbl_Solicita.Text = "Razón Social o Ruc"; gridParamsCliente(); grdSolicita.DataSource = objListaCliente; grdSolicita.Refresh(); break; case "06": lbl_Solicita.Text = "Nombre del Banco"; gridParamsBanco(); grdSolicita.DataSource = objListaBanco; grdSolicita.Refresh(); break; } }
private static void Handle_Personal ( Shell Dispatch, string[] args, int index) { Personal Options = new Personal (); var Registry = new Goedel.Registry.Registry (); Options.Portal.Register ("portal", Registry, (int) TagType_Personal.Portal); Options.Description.Register ("pd", Registry, (int) TagType_Personal.Description); Options.Verbose.Register ("verbose", Registry, (int) TagType_Personal.Verbose); Options.Report.Register ("report", Registry, (int) TagType_Personal.Report); Options.DeviceNew.Register ("new", Registry, (int) TagType_Personal.DeviceNew); Options.DeviceUDF.Register ("dudf", Registry, (int) TagType_Personal.DeviceUDF); Options.DeviceID.Register ("did", Registry, (int) TagType_Personal.DeviceID); Options.DeviceDescription.Register ("dd", Registry, (int) TagType_Personal.DeviceDescription); // looking for parameter Param.Name} if (index < args.Length && !IsFlag (args [index][0] )) { // Have got the parameter, call the parameter value method Options.Portal.Parameter (args [index]); index++; } // looking for parameter Param.Name} if (index < args.Length && !IsFlag (args [index][0] )) { // Have got the parameter, call the parameter value method Options.Description.Parameter (args [index]); index++; } #pragma warning disable 162 for (int i = index; i< args.Length; i++) { if (!IsFlag (args [i][0] )) { throw new System.Exception ("Unexpected parameter: " + args[i]);} string Rest = args [i].Substring (1); TagType_Personal TagType = (TagType_Personal) Registry.Find (Rest); // here have the cases for what to do with it. switch (TagType) { case TagType_Personal.Verbose : { int OptionParams = Options.Verbose.Tag (Rest); if (OptionParams>0 && ((i+1) < args.Length)) { if (!IsFlag (args [i+1][0] )) { i++; Options.Verbose.Parameter (args[i]); } } break; } case TagType_Personal.Report : { int OptionParams = Options.Report.Tag (Rest); if (OptionParams>0 && ((i+1) < args.Length)) { if (!IsFlag (args [i+1][0] )) { i++; Options.Report.Parameter (args[i]); } } break; } case TagType_Personal.DeviceNew : { int OptionParams = Options.DeviceNew.Tag (Rest); if (OptionParams>0 && ((i+1) < args.Length)) { if (!IsFlag (args [i+1][0] )) { i++; Options.DeviceNew.Parameter (args[i]); } } break; } case TagType_Personal.DeviceUDF : { int OptionParams = Options.DeviceUDF.Tag (Rest); if (OptionParams>0 && ((i+1) < args.Length)) { if (!IsFlag (args [i+1][0] )) { i++; Options.DeviceUDF.Parameter (args[i]); } } break; } case TagType_Personal.DeviceID : { int OptionParams = Options.DeviceID.Tag (Rest); if (OptionParams>0 && ((i+1) < args.Length)) { if (!IsFlag (args [i+1][0] )) { i++; Options.DeviceID.Parameter (args[i]); } } break; } case TagType_Personal.DeviceDescription : { int OptionParams = Options.DeviceDescription.Tag (Rest); if (OptionParams>0 && ((i+1) < args.Length)) { if (!IsFlag (args [i+1][0] )) { i++; Options.DeviceDescription.Parameter (args[i]); } } break; } default : throw new System.Exception ("Internal error"); } } #pragma warning restore 162 Dispatch.Personal (Options); }
private static void Usage () { Console.WriteLine ("brief"); Console.WriteLine (""); { #pragma warning disable 219 Reset Dummy = new Reset (); #pragma warning restore 219 Console.Write ("{0}reset ", UsageFlag); Console.WriteLine (); Console.WriteLine (" Delete all test profiles"); } { #pragma warning disable 219 Device Dummy = new Device (); #pragma warning restore 219 Console.Write ("{0}device ", UsageFlag); Console.Write ("[{0}] ", Dummy.DeviceID.Usage (null, "id", UsageFlag)); Console.Write ("[{0}] ", Dummy.DeviceDescription.Usage (null, "dd", UsageFlag)); Console.Write ("[{0}] ", Dummy.Default.Usage ("default", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Create new device profile"); } { #pragma warning disable 219 Personal Dummy = new Personal (); #pragma warning restore 219 Console.Write ("{0}personal ", UsageFlag); Console.Write ("[{0}] ", Dummy.Portal.Usage (null, "portal", UsageFlag)); Console.Write ("[{0}] ", Dummy.Description.Usage (null, "pd", UsageFlag)); Console.Write ("[{0}] ", Dummy.Verbose.Usage ("verbose", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Report.Usage ("report", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.DeviceNew.Usage ("new", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.DeviceUDF.Usage ("dudf", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.DeviceID.Usage ("did", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.DeviceDescription.Usage ("dd", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Create new personal profile"); } { #pragma warning disable 219 Label Dummy = new Label (); #pragma warning restore 219 Console.Write ("{0}label ", UsageFlag); Console.Write ("[{0}] ", Dummy.Portal.Usage ("portal", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.UDF.Usage ("udf", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Create new security label"); } { #pragma warning disable 219 Add Dummy = new Add (); #pragma warning restore 219 Console.Write ("{0}add ", UsageFlag); Console.WriteLine (); Console.WriteLine (" Add user to a label"); } { #pragma warning disable 219 Remove Dummy = new Remove (); #pragma warning restore 219 Console.Write ("{0}remove ", UsageFlag); Console.WriteLine (); Console.WriteLine (" Remove user from a label"); } { #pragma warning disable 219 Rekey Dummy = new Rekey (); #pragma warning restore 219 Console.Write ("{0}rekey ", UsageFlag); Console.WriteLine (); Console.WriteLine (" Create a new label key and recryption keys"); } { #pragma warning disable 219 Encrypt Dummy = new Encrypt (); #pragma warning restore 219 Console.Write ("{0}encrypt ", UsageFlag); Console.WriteLine (); Console.WriteLine (" Encrypt a data file to a label"); } { #pragma warning disable 219 Decrypt Dummy = new Decrypt (); #pragma warning restore 219 Console.Write ("{0}decrypt ", UsageFlag); Console.WriteLine (); Console.WriteLine (" Decrypt a data file"); } } // Usage
/// <summary>Read the given number of bytes from the stream and deserialze it into the instance.</summary> public static Personal.AddressBook DeserializeLength(Stream stream, int length, Personal.AddressBook instance) { if (instance.List == null) instance.List = new List<Personal.Person>(); long limit = stream.Position + length; while (true) { if (stream.Position >= limit) { if (stream.Position == limit) break; else throw new InvalidOperationException("Read past max limit"); } int keyByte = stream.ReadByte(); if (keyByte == -1) throw new System.IO.EndOfStreamException(); // Optimized reading of known fields with field ID < 16 switch (keyByte) { // Field 1 LengthDelimited case 10: // repeated instance.List.Add(Personal.Person.DeserializeLengthDelimited(stream)); continue; } var key = global::SilentOrbit.ProtocolBuffers.ProtocolParser.ReadKey((byte)keyByte, stream); // Reading field ID > 16 and unknown field ID/wire type combinations switch (key.Field) { case 0: throw new InvalidDataException("Invalid field id: 0, something went wrong in the stream"); default: global::SilentOrbit.ProtocolBuffers.ProtocolParser.SkipKey(stream, key); break; } } return instance; }
public virtual void Personal ( Personal Options ) { char UsageFlag = '-'; { #pragma warning disable 219 Personal Dummy = new Personal (); #pragma warning restore 219 Console.Write ("{0}personal ", UsageFlag); Console.Write ("[{0}] ", Dummy.Portal.Usage (null, "portal", UsageFlag)); Console.Write ("[{0}] ", Dummy.Description.Usage (null, "pd", UsageFlag)); Console.Write ("[{0}] ", Dummy.Verbose.Usage ("verbose", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.Report.Usage ("report", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.DeviceNew.Usage ("new", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.DeviceUDF.Usage ("dudf", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.DeviceID.Usage ("did", "value", UsageFlag)); Console.Write ("[{0}] ", Dummy.DeviceDescription.Usage ("dd", "value", UsageFlag)); Console.WriteLine (); Console.WriteLine (" Create new personal profile"); } Console.WriteLine (" {0}\t{1} = [{2}]", "String", "Portal", Options.Portal); Console.WriteLine (" {0}\t{1} = [{2}]", "String", "Description", Options.Description); Console.WriteLine (" {0}\t{1} = [{2}]", "Flag", "Verbose", Options.Verbose); Console.WriteLine (" {0}\t{1} = [{2}]", "Flag", "Report", Options.Report); Console.WriteLine (" {0}\t{1} = [{2}]", "Flag", "DeviceNew", Options.DeviceNew); Console.WriteLine (" {0}\t{1} = [{2}]", "String", "DeviceUDF", Options.DeviceUDF); Console.WriteLine (" {0}\t{1} = [{2}]", "String", "DeviceID", Options.DeviceID); Console.WriteLine (" {0}\t{1} = [{2}]", "String", "DeviceDescription", Options.DeviceDescription); Console.WriteLine ("Not Yet Implemented"); }
/// <summary>Read the VarInt length prefix and the given number of bytes from the stream and deserialze it into the instance.</summary> public static Personal.Person.PhoneNumber DeserializeLengthDelimited(Stream stream, Personal.Person.PhoneNumber instance) { instance.Type = Personal.Person.PhoneType.HOME; long limit = global::SilentOrbit.ProtocolBuffers.ProtocolParser.ReadUInt32(stream); limit += stream.Position; while (true) { if (stream.Position >= limit) { if (stream.Position == limit) break; else throw new InvalidOperationException("Read past max limit"); } int keyByte = stream.ReadByte(); if (keyByte == -1) throw new System.IO.EndOfStreamException(); // Optimized reading of known fields with field ID < 16 switch (keyByte) { // Field 1 LengthDelimited case 10: instance.Number = global::SilentOrbit.ProtocolBuffers.ProtocolParser.ReadString(stream); continue; // Field 2 Varint case 16: instance.Type = (Personal.Person.PhoneType)global::SilentOrbit.ProtocolBuffers.ProtocolParser.ReadUInt64(stream); continue; } var key = global::SilentOrbit.ProtocolBuffers.ProtocolParser.ReadKey((byte)keyByte, stream); // Reading field ID > 16 and unknown field ID/wire type combinations switch (key.Field) { case 0: throw new InvalidDataException("Invalid field id: 0, something went wrong in the stream"); default: global::SilentOrbit.ProtocolBuffers.ProtocolParser.SkipKey(stream, key); break; } } return instance; }
public void Accepta(object sender, EventArgs e) { this.Enabled = false; if (!propietaris_combobox.IsSelected()) { return; } Propietari propi = propietaris_combobox.GetSelected() as Propietari; DataSources.ReportDataQuadernPag1 pag1 = new DataSources.ReportDataQuadernPag1(); List <DataSources.ReportDataQuadernPag2t1> pag2t1 = new List <DataSources.ReportDataQuadernPag2t1>(); List <DataSources.ReportDataQuadernPag2t2> pag2t2 = new List <DataSources.ReportDataQuadernPag2t2>(); List <DataSources.ReportDataQuadernPag2t3> pag2t3 = new List <DataSources.ReportDataQuadernPag2t3>(); List <DataSources.ReportDataQuadernPag2t4> pag2t4 = new List <DataSources.ReportDataQuadernPag2t4>(); List <DataSources.ReportDataQuadernPag2t5> pag2t5 = new List <DataSources.ReportDataQuadernPag2t5>(); List <DataSources.ReportDataQuadernPag3> pag3 = new List <DataSources.ReportDataQuadernPag3>(); List <DataSources.ReportDataQuadernPag4> pag4 = new List <DataSources.ReportDataQuadernPag4>(); List <DataSources.ReportDataQuadernPag5> pag5 = new List <DataSources.ReportDataQuadernPag5>(); List <DataSources.ReportDataQuadernPag6> pag6 = new List <DataSources.ReportDataQuadernPag6>(); // Pag 1 pag1.titular_explotacio = propi.GetTbl().Nombre; pag1.titular_explotacio_nif = propi.GetTbl().Cif; pag1.titular_explotacio_ccpae = propi.GetTbl().idCAE; pag1.assessor_explotacio = propi.GetTbl().Nombre; pag1.assessor_explotacio_nif = propi.GetTbl().Cif; pag1.assessor_explotacio_registre = propi.GetTbl().idCAE; // Pag2 List <Personal> personal = propietaris_manager.GetPersonal(); List <Maquina> maquines = propietaris_manager.GetMaquinaria(); // Pag2t1 // Pag2t2 // Pag2t3 for (int i = 0; i < personal.Count; i++) { Personal personal_act = personal[i]; if (personal_act.GetTbl().idProveedor.ToString() != propi.GetTbl().idProveedor.ToLower().Replace(" ", "")) { continue; } if (personal_act.GetTbl().personal != null && (bool)personal_act.GetTbl().personal) { DataSources.ReportDataQuadernPag2t1 p = new DataSources.ReportDataQuadernPag2t1(); p.nom_cognom = personal_act.GetTbl().nom; p.nif = personal_act.GetTbl().nif; p.num_carnet = personal_act.GetTbl().numCarnet; p.num_quali = personal_act.GetTbl().nivell; p.num_ordre = personal_act.GetTbl().id; pag2t1.Add(p); } else if (personal_act.GetTbl().contractat != null && (bool)personal_act.GetTbl().contractat) { DataSources.ReportDataQuadernPag2t2 p = new DataSources.ReportDataQuadernPag2t2(); p.nom_cognom_2t2 = personal_act.GetTbl().nom; p.nif_2t2 = personal_act.GetTbl().nif; p.num_carnet_2t2 = personal_act.GetTbl().numCarnet; p.num_quali_2t2 = personal_act.GetTbl().nivell; p.numero_ordre_2t2 = personal_act.GetTbl().id; pag2t2.Add(p); } else if (personal_act.GetTbl().empresa != null && (bool)personal_act.GetTbl().empresa) { DataSources.ReportDataQuadernPag2t3 p = new DataSources.ReportDataQuadernPag2t3(); p.nom_cognom = personal_act.GetTbl().nom; p.nif = personal_act.GetTbl().nif; p.num_registre = personal_act.GetTbl().numCarnet; p.num_ordre = personal_act.GetTbl().id; pag2t3.Add(p); } } // Pag2t4 // Pag2t5 for (int i = 0; i < maquines.Count; i++) { Maquina maquina_act = maquines[i]; if (maquina_act.GetTbl().idProveedor.ToString() != propi.GetTbl().idProveedor.ToLower().Replace(" ", "")) { continue; } if (maquina_act.GetTbl().enPropietat != null && (bool)maquina_act.GetTbl().enPropietat) { DataSources.ReportDataQuadernPag2t4 p = new DataSources.ReportDataQuadernPag2t4(); p.tipo_maquina = maquina_act.GetTbl().nomMaquina; if (maquina_act.GetTbl().dataCompra != null) { DateTime d = (DateTime)maquina_act.GetTbl().dataCompra; p.data_compra = d.ToShortDateString(); } p.num_roma = maquina_act.GetTbl().numRoma; if (maquina_act.GetTbl().darreraInspeccio != null) { DateTime da = (DateTime)maquina_act.GetTbl().darreraInspeccio; p.data_ins = da.ToShortDateString(); } p.num_ordre = maquina_act.GetTbl().id; pag2t4.Add(p); } else if (maquina_act.GetTbl().llogada != null && (bool)maquina_act.GetTbl().llogada) { DataSources.ReportDataQuadernPag2t5 p = new DataSources.ReportDataQuadernPag2t5(); p.tipo_maquina_2t5 = maquina_act.GetTbl().nomMaquina; if (maquina_act.GetTbl().dataCompra != null) { DateTime d = (DateTime)maquina_act.GetTbl().dataCompra; p.data_compra_2t5 = d.ToShortDateString(); } p.num_roma_2t5 = maquina_act.GetTbl().numRoma; if (maquina_act.GetTbl().darreraInspeccio != null) { DateTime da = (DateTime)maquina_act.GetTbl().darreraInspeccio; p.data_ins_2t5 = da.ToShortDateString(); } p.num_ordre_2t5 = maquina_act.GetTbl().id; pag2t5.Add(p); } } // Pag3 List <Parcela> parceles = propietaris_manager.GetParcelesPerPropietari(propi); for (int i = 0; i < parceles.Count; i++) { Parcela parcela_act = parceles[i]; Finca finca_act = propietaris_manager.GetFincaPerParcela(parcela_act); Varietat varietat = propietaris_manager.GetVarietatPerParcela(parcela_act); DataSources.ReportDataQuadernPag3 p = new DataSources.ReportDataQuadernPag3(); p.num_finca_p3 = finca_act.GetTbl().idFinca.ToString(); p.nom_finca_p3 = finca_act.GetTbl().Nom1; p.municipi_p3 = finca_act.GetTbl().CodiMunicipi; p.poligon_p3 = parcela_act.GetTbl().Poligon; p.parcela_p3 = parcela_act.GetTbl().Parcela; p.recinte_p3 = ""; p.us_p3 = "Vi"; if (varietat != null) { p.cultiu_p3 = varietat.GetTbl().Nombre; } p.superficie_p3 = parcela_act.GetTbl().Ha.ToString(); p.sistema_conreu_p3 = "S / L"; p.num_rcv_p3 = parcela_act.GetTbl().idParcelaVinicola; pag3.Add(p); } // Pag4 // Pag5 List <tblLineasPartesFinca> linies = propietaris_manager.GetLineasPartePerPropietari(propi); for (int i = 0; i < linies.Count; i++) { tblLineasPartesFinca linea_act = linies[i]; tblPartesFinca parte_act = propietaris_manager.GetPartePerParteId(linea_act.idParte); Parcela parcela_act = propietaris_manager.GetParcelaPerParcelaID(linea_act.idParcela.ToString()); Finca finca_act = propietaris_manager.GetFincaPerParcela(parcela_act); Varietat varietat_act = propietaris_manager.GetVarietatPerParcela(parcela_act); Treball treball_act = propietaris_manager.GetTreballPerTreballId(linea_act.idFamiliaCoste); Adob adob_act = propietaris_manager.GetAdobPerId(linea_act.idProduteFito.ToString()); UnitatMetrica unitat_act = propietaris_manager.GetUnitatMetricaPerId(linea_act.idUnitatMetrica != null ? (int)linea_act.idUnitatMetrica : -1); if (linea_act.idProduteFito == null) { DataSources.ReportDataQuadernPag4 p = new DataSources.ReportDataQuadernPag4(); if (parte_act.Fecha != null) { DateTime d = (DateTime)parte_act.Fecha; p.data = d.ToShortDateString(); } p.num_finca = finca_act.GetTbl().idFinca.ToString(); p.cultiu = varietat_act.GetTbl().Nombre; p.superficie = parcela_act.GetTbl().Ha.ToString(); p.treballs = treball_act.GetTbl().Descripcio; pag4.Add(p); } else { DataSources.ReportDataQuadernPag5 p = new DataSources.ReportDataQuadernPag5(); if (parte_act.Fecha != null) { DateTime d = (DateTime)parte_act.Fecha; p.data = d.ToShortDateString(); } p.num_finca = finca_act.GetTbl().idFinca.ToString(); p.cultiu = varietat_act.GetTbl().Nombre; p.plaga = linea_act.Descripcion; p.superficie = parcela_act.GetTbl().Ha.ToString(); p.num_aplicador = linea_act.idAplicador.ToString(); p.num_maquinaria = linea_act.idMaquinaria.ToString(); p.kg_brou = linea_act.Unidades.ToString(); if (unitat_act != null) { p.kg_brou += unitat_act.GetTbl().Unitat; } if (adob_act != null) { p.productes_nom = adob_act.GetTbl().NomComercial; p.productes_num_registre = adob_act.GetTbl().NumRegistre.ToString(); } p.productes_dosi = linea_act.Unidades.ToString(); p.eficacia = linea_act.EficaciaTractament.ToString(); pag5.Add(p); } } quadern_form.SetInfo(pag1, pag2t1, pag2t2, pag2t3, pag2t4, pag2t5, pag3, pag4, pag5, pag6); this.Hide(); this.Enabled = true; quadern_form.ShowDialog(); }
internal Personal GetPersonal(int species) { Personal data = new Personal(); byte[] MonData = new byte[EntryLength]; data.BaseStats = new byte[6]; data.Abilities = new byte[3]; Array.Copy(file, species * EntryLength, MonData, 0, EntryLength); Array.Copy(MonData, data.BaseStats, 6); Array.Copy(MonData, 6, data.Abilities, 0, 3); data.BaseFriendship = MonData[0x9]; data.GenderRatio = MonData[0xA]; data.EXPGrowth = MonData[0xB]; data.AltFormCount = MonData[0xC]; data.FormPointer = MonData[0xD]; return data; }
private void FillSol() { if (Request.QueryString["Id"] != null) { IdSol = int.Parse(Request.QueryString["Id"].ToString()); BiFactory.Sol = Solicitud.GetById(IdSol); } SolicitudTareasGenerales sol_Tg = SolicitudTareasGenerales.FindFirst(Expression.Eq("IdSolicitud", BiFactory.Sol.Id_Solicitud)); if (sol_Tg != null) { cmbTipoTarea.SelectedValue = sol_Tg.IdTipotarea.ToString(); txtDescripcion.Text = sol_Tg.Descripcion; Persona = Personal.GetById(sol_Tg.IdEmpleado.ToString()); FillHorasPersonalGrid(0); MostrarSolicitud(); } else { Persona = Personal.GetById(BiFactory.Empleado.IdEmpleados.ToString()); } litHorasPersonalPersona.Text = Persona.Apellido + "," + Persona.Nombres; }