Posts by victor • 306 points
9 posts
-
1
votes1
answer987
viewsA: Modal with Countdown
From what I understand, Oce wants to start a countdown as soon as the modal is open. You can do this using the callbacks shown.bs.modal and hidden.bs.modal of the modal of the bootstrap, firing the…
-
2
votes3
answers512
viewsA: Add option inside optgroup
You can use the following jQuery to add a new option: $("select[name=testSelect]").children("optgroup[label=opt2]").append("<option value=4>Bananas</option>"); First we select the type…
javascriptanswered victor 306 -
2
votes1
answer966
viewsA: Capture Scroll by Scroll Bar
You only need to add one event handler at the onscroll of the element. var readAll = false; $elToBeRead.on("scroll", function() { if (readAll) return; readAll = this.scrollHeight - this.scrollTop…
-
1
votes1
answer113
viewsA: Xamarin Forms await is not respected
In fact, what’s happening is that you’re not expecting the function InsertAsync, then program follows the normal flow and prints End Save, as expected. The output you want requires the call to…
-
3
votes2
answers147
viewsA: How do I migrate Code First without deleting data from the table attribute?
You will need to manually edit the generated Migration by replacing Add and Drop for Rename: public override void Up() { //AddColumn("dbo.Produto", "PesoProduto", c => c.Decimal(precision: 18,…
-
0
votes1
answer488
viewsA: Format date with jQuery
You can change use D: {pattern: /[^3][0-9]|3[0-1]/}, or put a single digit in the mask and make a simpler expression: mask('d/mM/yYYY') and use d: {pattern: /[0-2][0-9]|3[0-1]/}.…
-
2
votes2
answers111
viewsA: Is it right to use string when the value is integer?
Although you don’t use Ids for mathematical operations, you certainly do make comparisons, especially when searching for data in your database. With performance in mind, the best practice is still…
-
3
votes2
answers1906
viewsA: await Task.Whenall how to run multiple processes?
To make an asynchronous function, Voce uses the Task, as you’ve already discovered. The right way to do something like this is like this: public static Task MakeRequest(int i) { return Task.Run(()…
-
2
votes1
answer220
viewsA: Concurrent Use in Asp.net Applications
Your question is not very specific, I will try to answer taking into account what you most quoted (DDD and DAL). There is competition control at the level of request, that is, requests Simultaneos…