Questions tagged as 'json'

3
answers

Encapsulate values returned by JSON within a single object

I have a question, I have this code below in controller : [Authorize] public JsonResult Teste() { var licencas = new List<Object>(); licencas.Add(new { Responsavel = "José",...
asked by 18.03.2014 / 19:28
1
answer

Algorithm - How to get the days in a week JS

I have the following situation: I need to set the days of each week within a month, creating an array of JSON objects. Each position would correspond to a week, for example if there were 5 weeks I would have an array of 5 positions, where eac...
asked by 12.05.2016 / 16:16
1
answer

I can not insert data into the array

I linked two drives to this product, but when I select it I have no way of linking to another new drive, since% is done at all, not being distinguished a new record that I try to link to As below, I am trying to register the drive code P1, af...
asked by 31.10.2017 / 20:46
2
answers

How to save files to a server via Java?

I need to save a file to a server using Java . In my case, I need to save a json file. Can I save a file normally on my computer, but how do I save directly to a remote server? Here is an example that saves a file to my computer. My...
asked by 02.12.2015 / 16:45
1
answer

How do I convert formdata to json?

I have the following code: var form = new FormData(); form.append('user',$("#user").val()); form.append('password',$("#password").val()); var data = JSON.stringify($(form).serialize()); but the var 'date' is getting null, look at the exampl...
asked by 16.05.2017 / 15:56
1
answer

Deserialization of Object JSON morMot

I am trying to deserialize a JSON object with an objectlist, following the examples from the mormot forum does not work, can anyone help me: Memo.Text := '{"CODIGO":"01","NOME":"CIDO","TELEFONES":[{"DDD":"18","NUMERO":"996237140"},{"DDD":"18",...
asked by 29.11.2016 / 14:05
1
answer

I can not return another field other than the primary key using $ project

I'm starting in MongoDB and would like to do a query on my bank like: Which animals got sick in the year 2016? Using $ group and $ project: db.animais.aggregate([ {$unwind : "$doencas" }, {$project : { year : {$year : "$doencas.data_di...
asked by 10.12.2016 / 17:09
1
answer

How to deserialize a list with items of type {"key": "value"}?

I need to deserialize a JSON, but I can not map the enumerated object. Follow JSON: { "list": [ { "1": "Bola" }, { "2": "Quadrado" }, { "3": "Retangulo" } ], "code": 0, "success": true }...
asked by 11.08.2016 / 01:08
1
answer

Laravel and Json Web Token

I am having difficulty authenticating through the Json Web Token token (JWT) in the Laravel framework, I have been using the framework recently and have come across the following error. Whoops, looks like something went wrong. 1/1 ErrorEx...
asked by 01.12.2015 / 17:23
2
answers

How to organize the return of data in a ListT?

I have a wcf that returns me some information, I would like to bring them organized, how could I do this? I would like to return data like this: Atthemomentitislikethis: I'm doing this: public List<V_PRODUTOS> GetProdutos(string c...
asked by 08.06.2015 / 05:11