This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Web; | |
namespace MvcTemplates_I.Models | |
{ | |
/// <summary> | |
/// Model usado como exemplo | |
/// </summary> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@model DateTime? | |
@{ | |
//Salva o valor como uma string validando a nulidade do objeto passado | |
string dateValue = Model.HasValue ? Model.Value.ToString("dd/MM/yyyy") : string.Empty; | |
} | |
@Html.TextBox("", dateValue, new { @class = "datepicker", maxlength = 10, @readonly = true }) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="editor-label"> | |
@Html.LabelFor(model => model.TestDate1) | |
</div> | |
<div class="editor-field"> | |
@Html.EditorFor(model => model.TestDate1) | |
@Html.ValidationMessageFor(model => model.TestDate1) | |
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="editor-label"> | |
<label for="TestDate1">TestDate1</label> | |
</div> | |
<div class="editor-field"> | |
<input class="datepicker" data-val="true" data-val-required="The TestDate1 field is required." id="TestDate1" maxlength="10" name="TestDate1" readonly="True" type="text" value="" /> | |
<span class="field-validation-valid" data-valmsg-for="TestDate1" data-valmsg-replace="true"></span> | |
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<link href="@Url.Content("~/Content/themes/base/jquery.ui.all.css")" rel="stylesheet" type="text/css" /> | |
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js" type="text/javascript"></script> | |
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/jquery-ui.min.js" | |
type="text/javascript"></script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script type="text/javascript"> | |
$(function(){ | |
$(".datepicker").datepicker(); | |
}); | |
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Portuguese initialisation for the jQuery UI date picker plugin. */ | |
jQuery(function ($) { | |
$.datepicker.regional['pt'] = { | |
closeText: 'Fechar', | |
prevText: '<Anterior', | |
nextText: 'Seguinte', | |
currentText: 'Hoje', | |
monthNames: ['Janeiro', 'Fevereiro', 'Março', 'Abril', 'Maio', 'Junho', | |
'Julho', 'Agosto', 'Setembro', 'Outubro', 'Novembro', 'Dezembro'], | |
monthNamesShort: ['Jan', 'Fev', 'Mar', 'Abr', 'Mai', 'Jun', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script src="@Url.Content("~/scripts/jquery.maskedinput.js")" type="text/javascript"></script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script type="text/javascript"> | |
$(function(){ | |
$(".datepicker").datepicker(); | |
$(".number").setMask("decimal"); | |
}); | |
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Copyright (C) Microsoft Corporation. All rights reserved. | |
using System; | |
using System.Collections.Generic; | |
using System.Text; | |
using System.Linq; | |
using System.Linq.Expressions; | |
using System.Reflection; | |
using System.Reflection.Emit; | |
using System.Threading; |
OlderNewer