|
|
|
|
@ -336,12 +336,12 @@ const motorSwitchSensorInSchema = new mongoose.Schema({
|
|
|
|
|
|
|
|
|
|
const insensorsSchema = new mongoose.Schema({
|
|
|
|
|
storeId: { type: String },
|
|
|
|
|
hardwareId: { type: String ,default:null},
|
|
|
|
|
hardwareId: { type: String, default: null },
|
|
|
|
|
masterId: { type: String, default: null },
|
|
|
|
|
type: { type: String },
|
|
|
|
|
model: { type: String },
|
|
|
|
|
indate: { type: String },
|
|
|
|
|
hardwareId_company: { type: String,default: null },
|
|
|
|
|
hardwareId_company: { type: String, default: null },
|
|
|
|
|
qccheck: { type: String, default: null },
|
|
|
|
|
qccheckdate: { type: String, default: null },
|
|
|
|
|
qcby: { type: String, default: null },
|
|
|
|
|
@ -355,11 +355,34 @@ const insensorsSchema = new mongoose.Schema({
|
|
|
|
|
comments: { type: String, default: "0" },
|
|
|
|
|
quantity: { type: Number, default: 0 },
|
|
|
|
|
batchno: { type: String, default: null },
|
|
|
|
|
sensor_type: { type: String, enum: ['slaves', 'motorswitch', 'master'] }, // adding sensor_type field
|
|
|
|
|
sensor_type: { type: String }, // adding sensor_type field
|
|
|
|
|
status: { type: String, default: "pending" },
|
|
|
|
|
quality_check_details: [{
|
|
|
|
|
damage_check: { result: String },
|
|
|
|
|
stickering_check: { result: String },
|
|
|
|
|
power_check: { result: String },
|
|
|
|
|
master_connecting_gsm: { result: String },
|
|
|
|
|
slave_connecting: { result: String },
|
|
|
|
|
motor_starting: {
|
|
|
|
|
result: String,
|
|
|
|
|
steps: [
|
|
|
|
|
{ step: Number, result: String }
|
|
|
|
|
]
|
|
|
|
|
},
|
|
|
|
|
connecting_to_sensor: { result: String },
|
|
|
|
|
connecting_to_slave: { result: String },
|
|
|
|
|
data_sending: { result: String },
|
|
|
|
|
distance_check: {
|
|
|
|
|
result: String,
|
|
|
|
|
steps: [
|
|
|
|
|
{ step: Number, result: String }
|
|
|
|
|
]
|
|
|
|
|
}
|
|
|
|
|
}]
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const iotpriceSchema = new mongoose.Schema({
|
|
|
|
|
name: { type: String },
|
|
|
|
|
type: { type: String ,default:null},
|
|
|
|
|
|