added capacity in bores and pipelines

master
varun 3 years ago
parent 8dd793c117
commit b096ddce3a

@ -180,6 +180,7 @@ exports.addBores = async (req, reply) => {
boresData = {
customerId:customerId,
boreName: req.body.boreName,
capacity: req.body.capacity,
typeofwater: req.body.typeofwater,
description: req.body.description,
};
@ -200,6 +201,7 @@ exports.addBores = async (req, reply) => {
console.log("thsi true url string");
bores.customerId = usertobeInserted.customerId
bores.boreName = usertobeInserted.boreName;
bores.capacity = usertobeInserted.capacity;
bores.typeofwater = usertobeInserted.typeofwater;
bores.description = usertobeInserted.description;
}
@ -278,6 +280,7 @@ exports.addGovtPIpeline = async (req, reply) => {
pipelineData = {
customerId:customerId,
Name: req.body.Name,
capacity: req.body.capacity,
typeofwater: req.body.typeofwater,
description: req.body.description,
};
@ -298,6 +301,7 @@ exports.addGovtPIpeline = async (req, reply) => {
console.log("thsi true url string");
pipe_line.customerId = usertobeInserted.customerId
pipe_line.Name = usertobeInserted.Name;
pipe_line.capacity = usertobeInserted.capacity;
pipe_line.typeofwater = usertobeInserted.typeofwater;
pipe_line.description = usertobeInserted.description;
}

@ -38,7 +38,9 @@ const tankersbookingSchema = new mongoose.Schema({
const boreSchema = new mongoose.Schema({
customerId: { type: String, default: null },
boreName: { type: String, default: null },
capacity: { type: String, default: null },
typeofwater: { type: String, default: null },
description: { type: String, default: null },
@ -48,6 +50,7 @@ const boreSchema = new mongoose.Schema({
const GovtPipeLineSchema = new mongoose.Schema({
customerId: { type: String, default: null },
Name: { type: String, default: null },
capacity: { type: String, default: null },
typeofwater: { type: String, default: null },
description: { type: String, default: null },

@ -227,6 +227,7 @@ module.exports = function (fastify, opts, next) {
type: "object",
properties: {
boreName: { type: "string" },
capacity: { type: "string" },
typeofwater: { type: "string" },
description: { type: "string" },
},
@ -321,6 +322,7 @@ module.exports = function (fastify, opts, next) {
properties: {
boreName: { type: "string" },
capacity: { type: "string" },
typeofwater: { type: "string" },
description: { type: "string" },
},
@ -363,6 +365,7 @@ module.exports = function (fastify, opts, next) {
type: "object",
properties: {
Name: { type: "string" },
capacity: { type: "string" },
typeofwater: { type: "string" },
description: { type: "string" },
},
@ -457,6 +460,7 @@ module.exports = function (fastify, opts, next) {
properties: {
Name: { type: "string" },
capacity: { type: "string" },
typeofwater: { type: "string" },
description: { type: "string" },
},
@ -478,13 +482,6 @@ module.exports = function (fastify, opts, next) {
next();
}

Loading…
Cancel
Save