@ -957,7 +957,7 @@ exports.createstaff = async (request, reply) => {
exports.editStaff = async (request, reply) => {
try {
const { customerId, phone } = request.params;
const { name, password } = request.body;
const { name, password,all_motor_access } = request.body;
const user = await User.findOne({ customerId, "staff.staff.phone": phone });
if (!user) {
@ -890,7 +890,8 @@ fastify.route({
type: "object",
properties: {
name: { type: "string" },
password: { type: "string" }
password: { type: "string" },
all_motor_access:{type:"string"}
},
required: ["name", "password"]
}