made changes in tanker.js,tankercontrollers,tanker routes

master
varun 3 years ago
parent 33a6689dad
commit b06f001dbc

@ -12,6 +12,7 @@ const fastify = require("fastify")({
exports.addTankers = async (req, reply) => { exports.addTankers = async (req, reply) => {
try { try {

@ -16,14 +16,11 @@ const tankersSchema = new mongoose.Schema({
phoneNumber: { type: String, default: null }, phoneNumber: { type: String, default: null },
alternative_phoneNumber: { type: String, default: null }, alternative_phoneNumber: { type: String, default: null },
typeofwater: [{ typeofwater: String}], typeofwater: [{ typeofwater: String}],
price:[{ typeofwater: String}], price:[{ price: String}],
capacity: { capacity: String}, capacity: { type: String},
supplier_address: { type: String, default: null }, supplier_address: { type: String, default: null },
supplier_name : { type: String, default: null }, supplier_name : { type: String, default: null },
price: {
type: [String],
default: []
},
status: { type: String} status: { type: String}
}); });

@ -41,7 +41,6 @@ module.exports = function (fastify, opts, next) {
}, },
}, },
}, },
price: { price: {
type: "array", type: "array",
maxItems: 2500, maxItems: 2500,

Loading…
Cancel
Save