Skip to content

Commit

Permalink
feedback updated
Browse files Browse the repository at this point in the history
  • Loading branch information
abhinavv245 committed Dec 29, 2023
1 parent 3207c0c commit c6dd73b
Show file tree
Hide file tree
Showing 7 changed files with 56 additions and 107 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ package-lock.json
*.env
.vscode
/public/logs/*
/public/server/*
verification-logs
/utils/*.json
/utils/*.txt
Expand Down

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -235,9 +235,10 @@ module.exports = {
type: "string",
enum: [
"Pending",
"Packed",
"Agent-assigned",
"Out-for-pickup",
"Order-picked-up",
"In-transit",
"At-destination-hub",
"Out-for-delivery",
"Order-delivered",
],
Expand Down Expand Up @@ -327,21 +328,27 @@ module.exports = {
properties: {
start: {
type: "string",
pattern: "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{3}Z$",
errorMessage:"should be in RFC 3339 (YYYY-MM-DDTHH:MN:SS.MSSZ) Format"
pattern:
"^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{3}Z$",
errorMessage:
"should be in RFC 3339 (YYYY-MM-DDTHH:MN:SS.MSSZ) Format",
},
end: {
type: "string",
pattern: "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{3}Z$",
errorMessage:"should be in RFC 3339 (YYYY-MM-DDTHH:MN:SS.MSSZ) Format"
pattern:
"^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{3}Z$",
errorMessage:
"should be in RFC 3339 (YYYY-MM-DDTHH:MN:SS.MSSZ) Format",
},
},
required: ["start", "end"],
},
timestamp: {
type: "string",
pattern: "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{3}Z$",
errorMessage:"should be in RFC 3339 (YYYY-MM-DDTHH:MN:SS.MSSZ) Format"
pattern:
"^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{3}Z$",
errorMessage:
"should be in RFC 3339 (YYYY-MM-DDTHH:MN:SS.MSSZ) Format",
},
},
required: ["range"],
Expand Down Expand Up @@ -568,7 +575,7 @@ module.exports = {
},
},
isQuoteMatching: true,

required: ["price", "breakup", "ttl"],
},
payments: {
Expand Down Expand Up @@ -753,6 +760,6 @@ module.exports = {
required: ["order"],
},
},

required: ["context", "message"],
};
Original file line number Diff line number Diff line change
Expand Up @@ -56,18 +56,18 @@ module.exports = {
},
transaction_id: {
type: "string",
const: { $data: "/select/0/context/transaction_id" },
const: { $data: "/select/0/context/transaction_id" },
},
message_id: {
type: "string",
const: { $data: "/update/0/context/message_id" },
const: { $data: "/update/0/context/message_id" },
},
timestamp: {
type: "string",
format: "date-time",
},
ttl: {
type: "string"
type: "string",
},
},
required: [
Expand All @@ -93,22 +93,18 @@ module.exports = {
properties: {
id: {
type: "string",
const: { $data: "/confirm/0/message/order/id" },
const: { $data: "/confirm/0/message/order/id" },
},
state: {
type: "string",
enum: [
"Created",
"Accepted",
"In-progress"
],
enum: ["Created", "Accepted", "In-progress"],
},
provider: {
type: "object",
properties: {
id: {
type: "string",
const: { $data: "/select/0/message/order/provider/id" },
const: { $data: "/init/0/message/order/provider/id" },
},
},
required: ["id"],
Expand Down Expand Up @@ -178,7 +174,7 @@ module.exports = {
},
collected_by: {
type: "string",
enum:["BAP","BPP"]
enum: ["BAP", "BPP"],
},
"@ondc/org/buyer_app_finder_fee_type": {
type: "string",
Expand Down Expand Up @@ -255,13 +251,13 @@ module.exports = {
},
},
if: { properties: { type: { const: "ON-FULFILLMENT" } } },
then: {
properties: {
collected_by: {
const: "BPP",
},
then: {
properties: {
collected_by: {
const: "BPP",
},
},
},
required: [
"params",
"status",
Expand Down Expand Up @@ -290,7 +286,15 @@ module.exports = {
properties: {
code: {
type: "string",
enum:["Pending","Agent-assigned","Order-picked-up","Out-for-delivery","Delivered"]
enum: [
"Pending",
"Out-for-pickup",
"Order-picked-up",
"In-transit",
"At-destination-hub",
"Out-for-delivery",
"Order-delivered",
],
},
},
required: ["code"],
Expand Down Expand Up @@ -374,13 +378,17 @@ module.exports = {
properties: {
start: {
type: "string",
pattern: "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{3}Z$",
errorMessage:"should be in RFC 3339 (YYYY-MM-DDTHH:MN:SS.MSSZ) Format"
pattern:
"^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{3}Z$",
errorMessage:
"should be in RFC 3339 (YYYY-MM-DDTHH:MN:SS.MSSZ) Format",
},
end: {
type: "string",
pattern: "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{3}Z$",
errorMessage:"should be in RFC 3339 (YYYY-MM-DDTHH:MN:SS.MSSZ) Format"
pattern:
"^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{3}Z$",
errorMessage:
"should be in RFC 3339 (YYYY-MM-DDTHH:MN:SS.MSSZ) Format",
},
},
required: ["start", "end"],
Expand Down Expand Up @@ -435,7 +443,7 @@ module.exports = {
properties: {
code: {
type: "string",
enum:["ITEM_DETAILS"]
enum: ["ITEM_DETAILS"],
},
},
required: ["code"],
Expand All @@ -450,7 +458,12 @@ module.exports = {
properties: {
code: {
type: "string",
enum:["ITEM_ID","COUNT","MEASURE_UNIT","MEASURE_VALUE"]
enum: [
"ITEM_ID",
"COUNT",
"MEASURE_UNIT",
"MEASURE_VALUE",
],
},
},
required: ["code"],
Expand All @@ -472,12 +485,12 @@ module.exports = {
"@ondc/org/provider_name",
"state",
"type",
"stops"
"stops",
],
},
},
},

required: ["id", "state", "provider", "items"],
},
},
Expand Down

0 comments on commit c6dd73b

Please sign in to comment.