When generating TypeScript code with the dateTimeType set to "OffsetMomentJS" it only adjusts the offset for parameters that are in the body of a HTTP action.
this.plannedStartDate.toISOString(true)
But for parameters that are passed via the querystring the following is still used:
url_ += "start=" + encodeURIComponent(start ? "" + start.toJSON() : "") + "&";
Is it possible to change the toJSON() here to toISOString(true), keeping the offset?
We need to use the logic from here also for parameters:
https://github.com/RSuter/NJsonSchema/blob/8e5bc578ee740384c0b468dcb787f4c802a51e3e/src/NJsonSchema.CodeGeneration.TypeScript/DataConversionGenerator.cs#L88
Tasks:
I recently encountered the same issue, but then with moment.Duration and the conversion to TimeSpan.
Will this be fixed with the same case?
Most helpful comment
We need to use the logic from here also for parameters:
https://github.com/RSuter/NJsonSchema/blob/8e5bc578ee740384c0b468dcb787f4c802a51e3e/src/NJsonSchema.CodeGeneration.TypeScript/DataConversionGenerator.cs#L88
Tasks: