inputconnection ismotor issue

master
bhaskar 2 years ago
parent df3b1af3b7
commit e02d669fe0

@ -27,7 +27,7 @@ exports.createConnections = async (req, body) => {
inputConnections: connection.inputConnections,
input_type: connection.input_type,
motor_status: connection.motor_status || "0",
inputismotor: connection.inputismotor || false // default to false if not specified
inputismotor: connection.inputismotor // default to false if not specified
};
});
}
@ -38,7 +38,7 @@ exports.createConnections = async (req, body) => {
return {
outputConnections: connection.outputConnections,
output_type: connection.output_type,
outputismotor: connection.outputismotor || false // default to false if not specified
outputismotor: connection.outputismotor // default to false if not specified
};
});
}

@ -48,7 +48,7 @@ const tanksSchema = new mongoose.Schema({
{
inputConnections: { type: String },
input_type: { type: String },
inputismotor: { type: Boolean, default: false },
inputismotor: { type: Boolean },
motor_status: { type: String, default: "0" }
}
],
@ -56,7 +56,7 @@ const tanksSchema = new mongoose.Schema({
{
outputConnections: { type: String },
output_type: { type: String },
outputismotor: { type: Boolean, default: false },
outputismotor: { type: Boolean },
motor_status: { type: String, default: "0" }
}
]

@ -182,7 +182,7 @@ module.exports = function (fastify, opts, next) {
properties: {
inputConnections: { type: "string", default: null },
type: { type: "string", default: null },
inputismotor: { type: "boolean", default: false },
inputismotor: { type: "boolean"},
},
},
},
@ -194,7 +194,7 @@ module.exports = function (fastify, opts, next) {
properties: {
outputConnections: { type: "string", default: null },
type: { type: "string", default: null },
outputismotor: { type: "boolean", default: false },
outputismotor: { type: "boolean" },
},
},
},

Loading…
Cancel
Save