Coder Social home page Coder Social logo

aspjson's People

Contributors

gerritvankuipers avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

aspjson's Issues

decimal read problem

1.18 versinon -> iyziCommissionRateAmount=0.40000000 write 40000000 (not show comma)
1.19 version -> not read

i want to read iyziCommissionRateAmount

JSON DATA
{"status":"success","locale":"tr","systemTime":1653066614838,"conversationId":"ETH1000","price":1.0,"paidPrice":10.0,"installment":1,"paymentId":"17604670","fraudStatus":1,"merchantCommissionRate":900.00000000,"merchantCommissionRateAmount":9.0,"iyziCommissionRateAmount":0.40000000,"iyziCommissionFee":0.25000000,"cardType":"DEBIT_CARD","cardAssociation":"MASTER_CARD","cardFamily":"Neo","binNumber":"589004","lastFourDigits":"0016","basketId":"ETH1000","currency":"TRY","itemTransactions":[{"itemId":"ETH1000","paymentTransactionId":"18814235","transactionStatus":2,"price":1.0,"paidPrice":10.00000000,"merchantCommissionRate":900.00000000,"merchantCommissionRateAmount":9.00000000,"iyziCommissionRateAmount":0.40000000,"iyziCommissionFee":0.25000000,"blockageRate":0E-8,"blockageRateAmountMerchant":0E-8,"blockageRateAmountSubMerchant":0,"blockageResolvedDate":"2022-05-28 00:00:00","subMerchantPrice":0,"subMerchantPayoutRate":0E-8,"subMerchantPayoutAmount":0,"merchantPayoutAmount":9.35000000,"convertedPayout":{"paidPrice":10.00000000,"iyziCommissionRateAmount":0.40000000,"iyziCommissionFee":0.25000000,"blockageRateAmountMerchant":0E-8,"blockageRateAmountSubMerchant":0E-8,"subMerchantPayoutAmount":0E-8,"merchantPayoutAmount":9.35000000,"iyziConversionRate":0,"iyziConversionRateAmount":0,"currency":"TRY"}}],"authCode":"222905","phase":"AUTH","hostReference":"mock00027iyzihostrfn"}

Overflow: 'Clng Line 240

Line 240 reads:
val = Clng(Replace(val, ".", ""))

when val = 50.16093600000001

Apparently 14 decimal places wasn't expected in your code, but sometimes it is necessary (Latitudes and Longitudes may need extreme precision and that is what I am working with).

I noticed you are using CLNG. The maximum allowed value is 2,147,483,647 (10 digits). I understand that while coding sometimes I tend to go with the quick and dirty just to get the job done. I'm actually going through my code I built using your library but now I need my Latitudes and Longitudes to be a bit more accurate than 10 digits so I'll be changing the function aj_ReadNumericValue to read as:

Private Function aj_ReadNumericValue(ByVal val)
If Instr(val, ".") > 0 Then ''< duh
val = trim(val)
if len(val) > 15 Then val = left(val,15) 'Limiter required in order to avoid breaking the DOUBLE data type
numdecimals = Len(val) - Instr(val, ".")
val = CDBL(Replace(val, ".", ""))
val = val / (10 ^ numdecimals)
aj_ReadNumericValue = val
Else
aj_ReadNumericValue = CDBL(val)
End If
End Function

Just an FYI. Thanks for the code! Works really well (once I trim my 14 decimal places down).

empty primary key

I have a json string:

[{"file":"78jsyhpg9mtf.jpg"},{"file":"imqk2680ra4p.jpg"}]

that doesn't have primary object name. It is accessible via data(0)...

But how do I iterate with for next loop over all elements in collection?

Using

Set oJSON = New aspJSON for each file in oJSON.data() ... next

obviously doesn't work. And I can not use oJSON.data("name") as the collection does not have primary data object.

How can I iterate or at least find the number of records, so I could use for next with x=0 to number of records?

Loop collection inside another collection

Please can you help me to read a collection inside another collection? Here it is my JSON:

{
    "versao": "3.3.12",
    "quantidade": 1,
    "**objetos**": [
        {
            "codObjeto": "OV827287026BR",
            "tipoPostal": {
                "sigla": "OV",
                "descricao": "ETIQUETA FISICA SEDEX OV",
                "categoria": "SEDEX"
            },
            "dtPrevista": "2024-03-08T23:59:59",
            "contrato": "9912295023",
            "largura": 10,
            "comprimento": 15,
            "altura": 1,
            "peso": 1.5,
            "formato": "Pacote",
            "modalidade": "F",
            "**eventos**": [
                {
                    "codigo": "BDE",
                    "tipo": "01",
                    "**dtHrCriado**": "2024-03-08T11:24:47",
                    "**descricao**": "Objeto entregue ao destinatário",
                    "unidade": {
                        "codSro": "15900970",
                        "tipo": "Agência dos Correios",
                        "endereco": {
                            "cidade": "TAQUARITINGA",
                            "uf": "SP"
                        }
                    }
                },
                {
                    "codigo": "OEC",
                    "tipo": "01",
                    "**dtHrCriado**": "2024-03-08T09:39:43",
                    "**descricao**": "Objeto saiu para entrega ao destinatário",
                    "unidade": {
                        "tipo": "Agência dos Correios",
                        "endereco": {
                            "cep": "15900970",
                            "logradouro": "PRACA DOUTOR HORACIO RAMALHO",
                            "numero": "12",
                            "bairro": "CENTRO",
                            "cidade": "TAQUARITINGA",
                            "uf": "SP"
                        }
                    }
                },
                {
                    "codigo": "RO",
                    "tipo": "01",
                    "**dtHrCriado**": "2024-03-08T05:59:16",
                    "**descricao**": "Objeto em transferência - por favor aguarde",
                    "unidade": {
                        "codSro": "14095970",
                        "tipo": "Unidade de Tratamento",
                        "endereco": {
                            "cidade": "RIBEIRAO PRETO",
                            "uf": "SP"
                        }
                    },
                    "unidadeDestino": {
                        "tipo": "Agência dos Correios",
                        "endereco": {
                            "cidade": "TAQUARITINGA",
                            "uf": "SP"
                        }
                    }
                },
                {
                    "codigo": "DO",
                    "tipo": "01",
                    "**dtHrCriado**": "2024-03-07T22:44:10",
                    "**descricao**": "Objeto em transferência - por favor aguarde",
                    "unidade": {
                        "codSro": "05314979",
                        "tipo": "Unidade de Tratamento",
                        "endereco": {
                            "cidade": "SAO PAULO",
                            "uf": "SP"
                        }
                    },
                    "unidadeDestino": {
                        "tipo": "Unidade de Tratamento",
                        "endereco": {
                            "cidade": "RIBEIRAO PRETO",
                            "uf": "SP"
                        }
                    }
                },
                {
                    "codigo": "RO",
                    "tipo": "01",
                    "**dtHrCriado**": "2024-03-07T16:56:12",
                    "**descricao**": "Objeto em transferência - por favor aguarde",
                    "unidade": {
                        "codSro": "05379972",
                        "tipo": "Agência dos Correios",
                        "endereco": {
                            "cidade": "SAO PAULO",
                            "uf": "SP"
                        }
                    },
                    "unidadeDestino": {
                        "tipo": "Unidade de Tratamento",
                        "endereco": {
                            "cidade": "SAO PAULO",
                            "uf": "SP"
                        }
                    }
                },
                {
                    "codigo": "PO",
                    "tipo": "01",
                    "**dtHrCriado**": "2024-03-07T16:46:17",
                    "**descricao**": "Objeto postado",
                    "unidade": {
                        "codSro": "05379972",
                        "tipo": "Agência dos Correios",
                        "endereco": {
                            "cidade": "SAO PAULO",
                            "uf": "SP"
                        }
                    }
                }
            ]
        }
    ],
    "tipoResultado": "Todos os Eventos"
}

A need to make a loop to read all "dtHrCriado" and "descricao".

I tried:

Set objJSONData = objJSONrastreio.data
Set objObjects = objJSONData.item("objetos")
Set objEvents = objObjects.item("eventos")

and got this error:

Microsoft VBScript runtime error '800a01a8'
Object required: 'objObjects.Item(...)'

Thank you!

Problem parsing a json input

Hi there,

Been trying to retrieve the message & code values in the following json data:

{
"exception_count" : "2",
"exceptions" : [
{
"exception" : [
{
"message" : "Not a valid routing number",
"code" : 15
}
],
"line" : 2
},
{
"exception" : [
{
"message" : "Not a valid routing number",
"code" : 15
}
],
"line" : 3
}
],
"payment_total" : 0,
"collection_count" : "2",
"transaction_count" : "2",
"error_code" : "001",
"collection_total" : 811,
"requested_date" : "08 06 21",
"payment_count" : "0",
"error_string" : "Success with exceptions",
"trx_id" : "DirectNetDebit-080621"
}

Any help would be much appreciated.

Thank You

Variable is undefined: 'numdecimals' Line: 264

Error al recibir un int con decimales

Variable is undefined: 'numdecimals', se declara variable dentro de método privado, Dim numdecimals

Ejemplo de json que generaba error:

"commitmentsList": [ { "taxCode": "10", "tax": "IGPJ/ 10", "concept": "", "description": "XXXXXX", "formCode": "XXXXX", "commitmentId": 000000, "payroll": "00000", **"amount": 261.0** } ]

Big Data Script Timeout Problem

Hi.

when I load a data to parse, I get a 'Script timed out' error. I think the csv data under products is bloating the server. Do you have a quick solution to this?

tryed aspjson Version 1.18 & 1.19
Sample JSON attached:
test.txt

Help wanted

Hello,
Thank you for this very helpfull library.

I have some problems to use it.

My ajax send :

$.ajax({
    url: 'data-delta.asp',
    type: 'POST',
    contentType: "application/json; charset=utf-8",
    data: JSON.stringify({
        "firstName": "John",
        "lastName": "Smith",
        "age": 25,
        "address": {
            "streetAddress": "21 2nd Street",
            "city": "New York",
            "state": "NY",
            "postalCode": "10021"
        },
        "phoneNumbers": [{
                "type": "home",
                "number": "212 555-1234"
            },
            {
                "type": "fax",
                "number": "646 555-4567"
            }
        ]
    }),
    dataType: "json",
    cache: false,
    async: false,

    success: function(response) {

    }
});

And the file is getting data :

<!--#include file="aspJSON1.19.asp" -->
<%

Set oJSON = New aspJSON

' 'Load JSON string
oJSON.loadJSON(Request.form())

' Get single value
Response.Write oJSON.data("firstName")
%>

I've this error :
loadJSON Error erreur '800a0001'
No data to load.
aspJSON1.19.asp, ligne 25

Thank you

Why string values are always trimmed? My workaround:

Hi all. When we load data from a string with loadJson() or we are displaying data with JSONoutput(), all processed strings are always trimmed. Is this a wanted behavior?
In my case, no. This was an issue, because my app wants to receive the complete value, even if it begins/ends with spaces.
So I found that aj_JSONEncode() and aj_JSONDecode() always trim strings.
Solution: I made a copy of these 2 functions - dropping the trim() - and I replaced them in getJSONValue() and WriteValue(). Now string values are added/readed without trimming.

help iam new to json

can somebody tell me how to create this please
{
  "SubscriptionId": "7620A519",
  "MainData": [
    {
      "TransactionAgreement": {
        "TransactionSource": {
          "Institution": "Test Bank",
          "AccountHolder": "John Doe",
        },
        "Reference": "EXT-AAA-0000001"
      },
      "TransactionsToSchedule": [
        {
          "ScheduledDate": "2021-03-11T00:00:00+10:00",
          "Reference": "AAAAA-BBB-CCCCC-DDD-EEEEE"
        }
      ]
    }
  ]
}

Decimals issue

Using 1.18 when reading decimal values, the local settings can mess things up.
Example:
{
"Field1":"",
"Field2":"",
"Field3":20.239994,
"Field4":"",
"Field5":null,
"Field6":"",
"Field7":"",
"Field8":1,
"Field9":"",
"Field10":"Sample 3",
"Field11":"AAAAAAAA"
}

Response.Write oJSON.data("Field3")
Can result in:
20239994

Reading sub item / array

Hi there.

Thanks for setting up this git.

I have some sample code i am getting from paypal.

I would like to get the 'custom_id' variable (in: purchase_units)
I tried custom_id = oJSON.data("purchase_units").item("custom_id") but it was empty.
How would i access it? Is it different being within an array?

I also tried this, which works partially - i get an error on what seems to be the 2nd loop of the for loop. But the first loop does seem to access the tag i want. Maybe its throwing an error as this isnt a true array with multiple objects?

   For Each custom_id In oJSON.data("purchase_units")
        Set this = oJSON.data("purchase_units").item(custom_id)
        Response.Write _
        this.item("custom_id")  
    Next

Thanks

JSON BELOW:

{
  "id": "94151283KB577953A",
  "intent": "CAPTURE",
  "status": "COMPLETED",
  "payment_source": {
    "paypal": {
      "email_address": "[email protected]",
      "account_id": "A95TCZ88AZQMU",
      "account_status": "UNVERIFIED",
      "name": {
        "given_name": "mo",
        "surname": "Test"
      },
      "address": {
        "country_code": "IL"
      }
    }
  },
  "purchase_units": [{
    "reference_id": "default",
    "amount": {
      "currency_code": "USD",
      "value": "7.50",
      "breakdown": {
        "item_total": {
          "currency_code": "USD",
          "value": "7.50"
        }
      }
    },
    "payee": {
      "email_address": "[email protected]",
      "merchant_id": "C832PPP4ECVRN"
    },
    "description": "Demo Product",
    "custom_id": "DP12345",
    "soft_descriptor": "PAYPAL *TEST STORE",
    "items": [{
      "name": "Demo Product",
      "unit_amount": {
        "currency_code": "USD",
        "value": "7.50"
      },
      "quantity": "1",
      "description": "Demo Product",
      "category": "DIGITAL_GOODS"
    }],
    "shipping": {
      "name": {
        "full_name": "mo Test"
      },
      "address": {
        "address_line_1": "Arba St",
        "admin_area_2": "Tel Aviv",
        "country_code": "IL"
      }
    },
    "payments": {
      "captures": [{
        "id": "8KS14127A2501944D",
        "status": "COMPLETED",
        "amount": {
          "currency_code": "USD",
          "value": "7.50"
        },
        "final_capture": true,
        "seller_protection": {
          "status": "ELIGIBLE",
          "dispute_categories": ["ITEM_NOT_RECEIVED", "UNAUTHORIZED_TRANSACTION"]
        },
        "seller_receivable_breakdown": {
          "gross_amount": {
            "currency_code": "USD",
            "value": "7.50"
          },
          "paypal_fee": {
            "currency_code": "USD",
            "value": "0.43"
          },
          "net_amount": {
            "currency_code": "USD",
            "value": "7.07"
          },
          "receivable_amount": {
            "currency_code": "ILS",
            "value": "25.09"
          },
          "exchange_rate": {
            "source_currency": "USD",
            "target_currency": "ILS",
            "value": "3.5487075"
          }
        },
        "custom_id": "DP12345",
        "links": [{
          "href": "https://api.sandbox.paypal.com/v2/payments/captures/8KS14127A2501944D",
          "rel": "self",
          "method": "GET"
        }, {
          "href": "https://api.sandbox.paypal.com/v2/payments/captures/8KS14127A2501944D/refund",
          "rel": "refund",
          "method": "POST"
        }, {
          "href": "https://api.sandbox.paypal.com/v2/checkout/orders/94151283KB577953A",
          "rel": "up",
          "method": "GET"
        }],
        "create_time": "2023-11-27T21:30:56Z",
        "update_time": "2023-11-27T21:30:56Z"
      }]
    }
  }],
  "payer": {
    "name": {
      "given_name": "mo",
      "surname": "Test"
    },
    "email_address": "[email protected]",
    "payer_id": "A95TCZ88AZQMU",
    "address": {
      "country_code": "IL"
    }
  },
  "create_time": "2023-11-27T21:30:42Z",
  "update_time": "2023-11-27T21:30:56Z",
  "links": [{
    "href": "https://api.sandbox.paypal.com/v2/checkout/orders/94151283KB577953A",
    "rel": "self",
    "method": "GET"
  }]
}

Error in the example file?

In the example write.asp shouldn't line 10 be changed from
With oJSON.data("familyMembers")
to
With .item("familyMembers")

Cannot work out syntax for multilevel JSON file

In your basic example you have

oJSON.data("firstName")

How would you get the data in say city which is part of address

The JSON file I am working with has many more levels but if I can see the correct syntax for your example then I should be able to work it out

Thanks

Nested JSON File Issue

The httpResponse text looks like...

  {"returnObj":{"LaborHed": 
    [{"Company":"MYCOMPANY","EmployeeNum":"A","LaborHedSeq":106,"PayrollDate":"2022-10- 
    06T00:00:00","Shift":11,"ClockInDate":"2022-10-05T00:00:00",

According to other posts on this topic it looks as though the issue I am getting is because the response is nested in "returnObj": though i can't see how to resolve. Please can I have an example of parsing the above response.

ASPJson doesn't work with Windows 2019 IIS

Hi there

I was using ASPJson with WIndows 2012 and 2016, but using Windows 2019, it stopped working.

I get error: Description: Object not a collection

When I issue

For Each answer In oJson.data("response")

Any ideas why is this happening?

PS - Problem seems to be related to Msxml2.ServerXMLHTTP.6.0.

Help for retrieve node

Immagine 2022-10-14 115654

I need help because I can't get the elements inside "captures",

For Each purchase_units In oJSON.data("purchase_units")
Set purchase_units = oJSON.data("purchase_units").item(purchase_units)
Next

I can get the values ​​inside "purchase_units" but I don't know how to read inside "captures", I have made many attempts but I don't understand how to do it.

Would anyone know how to give me a hand?

no working in another class

I am loading the file
and into another class in am trying to using it but its not working when its without class its working why?

validate result

missing feature: result of loadJSON

  • valid input
  • position of parsing error

Variable uses an Automation type not supported in VBScript: 'TypeName'

Just came across your Git and tried to create a short JSON file with it from a database query.

But when I try to run it I get the following error:

<p>Microsoft VBScript runtime </font> <font face="Arial" size=2>error '800a01ca'</font>
<p>
<font face="Arial" size=2>Variable uses an Automation type not supported in VBScript: 'TypeName'</font>
<p>
<font face="Arial" size=2>/includes/aspJSON1.18.asp</font><font face="Arial" size=2>, line 175</font> 

The script that I'm using is the following:

response.ContentType = "application/json"
Dim GetArray, vJSON
Set ConnObj=Server.CreateObject("ADODB.Connection")
ConnObj.Open myDSN
set rs = ConnObj.execute(strSQLA) 
If rs.BOF or rs.EOF Then
Else
   GetArray = rs.GetRows()
End If
rs.Close
ConnObj.Close
Set rs = Nothing
Set ConnObj = Nothing

'Write JSON

Set vJSON = New aspJSON

With vJSON.data
    For i = 0 to UBound(GetArray,2)
        .Add i, vJSON.Collection()
        With .item(i)
            .Add "Date", GetArray(0,i)
            .Add "Temperature", GetArray(1,i)
            .Add "Humidity", GetArray(2,i)
        End With
    Next
End With

Response.Write vJSON.JSONoutput()

And there is no "strange" data in the Query. This is the result I get from the database:

Date	Temperature	Humidity
2020-12-31 12:25:00.000	-22.380000	0.000000
2020-12-31 12:30:00.000	-25.880000	0.000000
2020-12-31 12:35:00.000	-24.740000	0.000000
2020-12-31 12:40:00.000	-12.160000	0.000000
2020-12-31 12:45:00.000	20.640000	0.000000
2020-12-31 12:50:00.000	26.660000	0.000000

Thank you!

Not really an issue, but I just wanted to thank you for making this library. I found it very useful when connecting an old ASP app to a new API.

Some Suggestion's

Hey, A big thanks for this lovely project as its a big help in keeping asp classic communicating with modern APIs. I would like to suggest the following:

Loading JSON from URL

Line 31:
Should be GET rather than POST to work with most APIs like this one
Line 32:
Content-Type should be application/json; charset=UTF-8
Line 33:
I have never seen Charset in a header and Accept-Charset should no longer be used.

Load values based on a condition

Hello Gerrit,
thank you for your incredible and useful work. I'm asking if it's possible to load JSON values based on a condition of a field (ie: a date)
Thank you in advance
Best regards

Seemd slow

This seems very slow - is there anything I can do to speed it up as there are an awful lot of records to process The page speed is ok until this bit - thanks

Set oJSON = New aspJSON

With oJSON.data
     For i=0 To Ubound(ShiftsId)		
        .Add i, oJSON.Collection()               
        With .item(i)
            .Add "start", ShiftsDate(i) + "T" + ShiftsStartHours(i)
            .Add "end", ShiftsDate(i) + "T" + ShiftsEndHours(i)
			.Add "title", ShiftsTitle(i)
			.Add "resource", ShiftsId(i)
			.Add "slot", ShiftsSlot(i)
			.Add "shifttype", ShiftsType(i)
			.Add "shiftsdatefrom", ShiftsDateFrom(i)
			.Add "shiftsdateto", ShiftsDateTo(i)
			.Add "shiftsdbid", ShiftsDbID(i)
        End With
	Next
End With

Overflow: 'Clng'

I am trying to loop through some basic JSON and for some reason, I am getting a a Overflow: 'Clng' error when loading the JSON and cannot figure out why.

Here is my code, I am using the EXACT version 1.19 code from here: https://github.com/gerritvankuipers/aspjson

	Set oJSON = New aspJSON
	strJSON = strSJON 'SEE BELOW

	'Wrap with events to turn it into a collection so we can loop below (i commented this out, i get the same error regardless though)
	'strJSON = "{""events"":" & strJSON & "}"

	'Load JSON string
	oJSON.loadJSON(strJSON)

I cannot even get past this point since the error happens above this:

	'Loop through collection
	For Each oEvent In oJSON.data("events")
		Set this = oJSON.data("events").item(oEvent)
		Response.Write this.item("id") & ": " & this.item("title") & "<br>"

		'Get single value
		'Response.Write oJSON.data("firstName") & "<br>"

		'Loop through collection
		For Each link In oJSON.data("links")
			 Set this = oJSON.data("links").item(link)
			 Response.Write this.item("website") & "<br>"
		Next
	Next

Here is the JSON:

[{"id":29599,"title":"Lucky Voice","category_id":45,"sub_category_ids":[],"timestamp":"2015-07-01T13:06:31.851013Z","start_time":"2015-07-01T17:00:00+01:00","end_time":"2021-07-01T03:00:00+01:00","door_time":null,"last_entry_time":null,"summary":"Lucky Voice is the most liberating, heart-racing, life-affirming private karaoke experience on Earth. But don't just take our word for it...","description":"Lucky Voice - simply the best! Hire out one of our karaoke rooms for you and your friends and experience some of the best fun around. Whether you are 12 or 92 and love singing, then this is the place for you! Plus, you wont be disturbed by anyone, unless of course, you press the \"thirsty\" button for a drink...\r\n\r\nOpening Hours:\r\nMon - Wed 5:30pm - 1:00am\r\nThurs - Sat 5:30pm - 3:00am\r\nSun 3:00pm - 10:30pm","organiser_name":"Lucky Voice","hashtag":"luckyvoice","image_url":"https://s3-eu-west-1.amazonaws.com/evvnt.staging/uploads/event_image/event_image/4626090b-9c8d-484d-92e6-c0331d4af9cd/soho3.jpg","image_urls":["https://s3-eu-west-1.amazonaws.com/evvnt.staging/uploads/event_image/event_image/4626090b-9c8d-484d-92e6-c0331d4af9cd/soho3.jpg","https://s3-eu-west-1.amazonaws.com/evvnt.staging/uploads/event_image/event_image/7199c9d4-cfe2-44e9-9523-a1d9e9a78e0d/Brighton%20Pod2.jpg"],"links":{"Website":"http://go-staging.evvnt.com/29599-0","Booking":"http://go-staging.evvnt.com/29599-1","Facebook":"http://go-staging.evvnt.com/29599-2","Twitter":"http://go-staging.evvnt.com/29599-3","YouTube":"http://go-staging.evvnt.com/29599-4"},"artists":"","keywords":"karaoke, lucky voice, soho","prices":{"Average pp":"GBP 22"},"workflow_state":"report_complete","capacity":null,"venue":{"id":16838,"name":"Lucky Voice","address_1":"52 Poland Street","address_2":"","town":"London","country":"GB","postcode":"W1F 7NQ","latitude":51.5146901,"longitude":-0.136974},"contact":{"name":"Contact Name 26421","email":"[email protected]","tel":"123456789"}},{"id":46658,"title":"Base SAS Online Training at VirtualNuggets.com","category_id":124,"sub_category_ids":[],"timestamp":"2016-02-10T05:19:39.666806Z","start_time":"2016-02-12T01:00:00+00:00","end_time":"2024-08-17T23:00:00+01:00","door_time":null,"last_entry_time":null,"summary":"VirtualNuggets is the one of Best organization providing Online and Corporate Training worldwide.","description":"Base SAS provides a scalable, included software environment specially designed for data access, alteration and reporting. It includes a fourth-generation programming language; ready-to-use programs for data handling, information storage and recovery, evocative statistics and report writing; and an influential macro facility that reduces programming time and preservation headaches.\r\n\r\nVirtualNuggets is the one of Best organization providing Online and Corporate Training worldwide. We offer Real-time practical Oriented Training on Base SAS, New batch starts on every week.\r\n\r\nFor more information on Base SAS Online Training\r\n\r\nEmail\t        :  info@virtualnuggets com\r\nContact       :  +1-707 666 8949(USA)\t  +91-888 556 0202(India)\r\nWeb URL    :  http://www.virtualnuggets.com/base-sas.html\r\nBlogger       : http://basesasonlinetraining.blogspot.com\r\n","organiser_name":"vasubuddi","hashtag":"basesas","image_url":"https://s3-eu-west-1.amazonaws.com/evvnt.staging/uploads/event_image/event_image/a49c513e-f8ce-4095-b51d-989e7d8e3d75/VirtualNuggets.png","image_urls":["https://s3-eu-west-1.amazonaws.com/evvnt.staging/uploads/event_image/event_image/a49c513e-f8ce-4095-b51d-989e7d8e3d75/VirtualNuggets.png"],"links":{"Website":"http://go-staging.evvnt.com/46658-0","Inquiries":"http://go-staging.evvnt.com/46658-1"},"artists":"","keywords":"base sas, sas, online training, virtualnuggets","prices":{"Training":"USD 0"},"workflow_state":"reported_on","capacity":null,"venue":{"id":26319,"name":"station road","address_1":"station road","address_2":"","town":"Sandwell","country":"GB","postcode":"B71 4HJ","latitude":52.5273431,"longitude":-1.9883300652359},"contact":{"name":"Contact Name 43585","email":"[email protected]","tel":"123456789"}}]

Trying to use loadJSON function on collection.

I need to insert some json objects into an existing json list.

So let's say I have a json list inside my main object named Tasks looking like this.
{ "Groups": [ { "id":22, "Status": 1, "Tasks": [] } ] }
And then just want to add the tasks afterwards,
{ "name":"task-1", "id":1 }, { "name":"task-2", "id":2 }

I have tried the appending it into the object from another json object but couldn't get it to work that way.
Also tried to use .item("Tasks").loadJSON right on the task list, but that didn't seem to work either.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.