mirror of
https://github.com/valitydev/openapi-generator.git
synced 2024-11-07 10:58:55 +00:00
rebuilt samples
This commit is contained in:
parent
728544cc03
commit
62caf7dac5
@ -74,9 +74,9 @@ SWGOrder::fromJson(QString &json) {
|
||||
void
|
||||
SWGOrder::fromJsonObject(QJsonObject &pJson) {
|
||||
::Swagger::setValue(&id, pJson["id"], "qint64", "");
|
||||
::Swagger::setValue(&pet_id, pJson["pet_id"], "qint64", "");
|
||||
::Swagger::setValue(&pet_id, pJson["petId"], "qint64", "");
|
||||
::Swagger::setValue(&quantity, pJson["quantity"], "qint32", "");
|
||||
::Swagger::setValue(&ship_date, pJson["ship_date"], "QDateTime", "QDateTime");
|
||||
::Swagger::setValue(&ship_date, pJson["shipDate"], "QDateTime", "QDateTime");
|
||||
::Swagger::setValue(&status, pJson["status"], "QString", "QString");
|
||||
::Swagger::setValue(&complete, pJson["complete"], "bool", "");
|
||||
}
|
||||
@ -97,11 +97,11 @@ SWGOrder::asJsonObject() {
|
||||
|
||||
obj->insert("id", QJsonValue(id));
|
||||
|
||||
obj->insert("pet_id", QJsonValue(pet_id));
|
||||
obj->insert("petId", QJsonValue(pet_id));
|
||||
|
||||
obj->insert("quantity", QJsonValue(quantity));
|
||||
|
||||
toJsonValue(QString("ship_date"), ship_date, obj, QString("QDateTime"));
|
||||
toJsonValue(QString("shipDate"), ship_date, obj, QString("QDateTime"));
|
||||
|
||||
toJsonValue(QString("status"), status, obj, QString("QString"));
|
||||
|
||||
|
@ -94,7 +94,7 @@ SWGPet::fromJsonObject(QJsonObject &pJson) {
|
||||
::Swagger::setValue(&category, pJson["category"], "SWGCategory", "SWGCategory");
|
||||
::Swagger::setValue(&name, pJson["name"], "QString", "QString");
|
||||
|
||||
::Swagger::setValue(&photo_urls, pJson["photo_urls"], "QList", "QString");
|
||||
::Swagger::setValue(&photo_urls, pJson["photoUrls"], "QList", "QString");
|
||||
|
||||
|
||||
::Swagger::setValue(&tags, pJson["tags"], "QList", "SWGTag");
|
||||
@ -124,7 +124,7 @@ SWGPet::asJsonObject() {
|
||||
|
||||
QJsonArray photo_urlsJsonArray;
|
||||
toJsonArray((QList<void*>*)photo_urls, &photo_urlsJsonArray, "photo_urls", "QString");
|
||||
obj->insert("photo_urls", photo_urlsJsonArray);
|
||||
obj->insert("photoUrls", photo_urlsJsonArray);
|
||||
|
||||
QJsonArray tagsJsonArray;
|
||||
toJsonArray((QList<void*>*)tags, &tagsJsonArray, "tags", "SWGTag");
|
||||
|
@ -91,12 +91,12 @@ void
|
||||
SWGUser::fromJsonObject(QJsonObject &pJson) {
|
||||
::Swagger::setValue(&id, pJson["id"], "qint64", "");
|
||||
::Swagger::setValue(&username, pJson["username"], "QString", "QString");
|
||||
::Swagger::setValue(&first_name, pJson["first_name"], "QString", "QString");
|
||||
::Swagger::setValue(&last_name, pJson["last_name"], "QString", "QString");
|
||||
::Swagger::setValue(&first_name, pJson["firstName"], "QString", "QString");
|
||||
::Swagger::setValue(&last_name, pJson["lastName"], "QString", "QString");
|
||||
::Swagger::setValue(&email, pJson["email"], "QString", "QString");
|
||||
::Swagger::setValue(&password, pJson["password"], "QString", "QString");
|
||||
::Swagger::setValue(&phone, pJson["phone"], "QString", "QString");
|
||||
::Swagger::setValue(&user_status, pJson["user_status"], "qint32", "");
|
||||
::Swagger::setValue(&user_status, pJson["userStatus"], "qint32", "");
|
||||
}
|
||||
|
||||
QString
|
||||
@ -117,9 +117,9 @@ SWGUser::asJsonObject() {
|
||||
|
||||
toJsonValue(QString("username"), username, obj, QString("QString"));
|
||||
|
||||
toJsonValue(QString("first_name"), first_name, obj, QString("QString"));
|
||||
toJsonValue(QString("firstName"), first_name, obj, QString("QString"));
|
||||
|
||||
toJsonValue(QString("last_name"), last_name, obj, QString("QString"));
|
||||
toJsonValue(QString("lastName"), last_name, obj, QString("QString"));
|
||||
|
||||
toJsonValue(QString("email"), email, obj, QString("QString"));
|
||||
|
||||
@ -127,7 +127,7 @@ SWGUser::asJsonObject() {
|
||||
|
||||
toJsonValue(QString("phone"), phone, obj, QString("QString"));
|
||||
|
||||
obj->insert("user_status", QJsonValue(user_status));
|
||||
obj->insert("userStatus", QJsonValue(user_status));
|
||||
|
||||
return obj;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user