mirror of
				https://github.com/mokuappio/serverless-invoices.git
				synced 2025-10-31 09:51:08 -04:00 
			
		
		
		
	Fix persisting client changes. Fix persisting team changes. Fix validating vat of 0.
This commit is contained in:
		| @ -50,11 +50,9 @@ export default { | ||||
|       await dispatch('clientProps', props); | ||||
|       return ClientService.updateClient(getters.client); | ||||
|     }, | ||||
|     async updateClientById(payload) { | ||||
|       const client = await Client.update({ | ||||
|         where: payload.clientId, | ||||
|         data: payload.props, | ||||
|       }); | ||||
|     async updateClientById(store, payload) { | ||||
|       const client = Client.find(payload.clientId); | ||||
|       client.$update(payload.props); | ||||
|       return ClientService.updateClient(client); | ||||
|     }, | ||||
|     async openNewClientModal({ commit }) { | ||||
|  | ||||
| @ -27,11 +27,8 @@ export default { | ||||
|       await Team.create({ data: team }); | ||||
|       return team; | ||||
|     }, | ||||
|     async teamProps({ state }, props) { | ||||
|       return Team.update({ | ||||
|         where: state.teamId, | ||||
|         data: props, | ||||
|       }); | ||||
|     async teamProps({ getters }, props) { | ||||
|       return getters.team.$update(props); | ||||
|     }, | ||||
|     async updateTeam({ getters, dispatch }, props) { | ||||
|       if (props) { | ||||
|  | ||||
		Reference in New Issue
	
	Block a user