feat: add customer creation modal

This commit is contained in:
Sérgio Salgado 2021-09-15 14:42:46 +01:00
parent cfb360ab4e
commit 94eed283cb
8 changed files with 153 additions and 9 deletions

View file

@ -49,7 +49,8 @@ const resolvers = {
},
deleteCustomerNote: (...[, { noteId }]) => {
return customerNotes.deleteCustomerNote(noteId)
}
},
createCustomer: (...[, { phoneNumber }]) => customers.add({ phone: phoneNumber })
}
}

View file

@ -103,6 +103,7 @@ const typeDef = gql`
createCustomerNote(customerId: ID!, title: String!, content: String!): Boolean @auth
editCustomerNote(noteId: ID!, newContent: String!): Boolean @auth
deleteCustomerNote(noteId: ID!): Boolean @auth
createCustomer(phoneNumber: String): Customer @auth
}
`