【发布时间】:2021-02-08 20:17:46
【问题描述】:
在尝试将以下 JSON 内容反序列化为对象时遇到问题,尤其是 eInv 部分中的内容
{
"requestType": "SaveDocuments",
"status": "P",
"version": "v0.1",
"validationReport": null,
"dataReport": [
{
"locationGstin": "DSAJJ0AAGCR31",
"locationName": "ABC MARKET",
"documentNumber": "2947",
"documentDate": "23-10-2020",
"billFromGstin": "DDLDF07AAGCL",
"supplyType": "S",
"documentType": "LST",
"portCode": null,
"custom1": null,
"custom2": null,
"custom3": null,
"custom4": null,
"custom5": null,
"custom6": null,
"custom7": null,
"custom8": null,
"custom9": null,
"custom10": null,
"eInv": {
"ackNumber": "1721101",
"ackDate": "01-02-2021 18:54:00",
"irn": "2d9a39998157b984276e6f1d3b8f74597d7850f0b7ba88c251556e4436b2bb0e",
"signedInvoice": "CJWeJKYynrWOw2k-GLO-vDipfOohtqW1xh5bg",
"signedQRCode": "eyJhbGciOiJSUzI1NiIsImtpZCI6IjQe5VoYONjADbEYzGABzAz8cCyLXDfNENkZ_TXHw",
"qrCode": "iVBORw0KGgoAAAANSUhEUgAAAG0AAABtCAYAAACrXCIc",
"qrCodeData": "{\"SellerGstin\":\"abc\",\"BuyerGstin\":\"def\",\"DocNo\":\"234\",\"DocTyp\":\"ghi\",\"DocDt\":\"23/10/2020\",\"TotInvVal\":4005.00,\"ItemCnt\":4,\"MainHsnCode\":\"abc\",\"Irn\":\"321absd432\",\"IrnDt\":\"2021-02-01 18:54:00\"}",
"errors": null
},
"propertyErrors": null
}
],
"referenceId": "abcdesf="
}
【问题讨论】:
-
嗨,Paapu,谢谢您的提问。有几种方法可以改善您的问题:我们可以从您的标签中推断出来(它看起来像 C#),列出您正在使用的技术仍然很有帮助;请提供您尝试过的代码。
标签: c# json json-deserialization