2
0
mirror of https://github.com/frappe/books.git synced 2025-01-03 07:12:21 +00:00

Merge pull request #973 from AbleKSaju/fix-pos-datas

fix: refresh item quantities & clear previous customer after POS purchase
This commit is contained in:
Akshay 2024-10-09 16:26:53 +05:30 committed by GitHub
commit d2c307d8a3
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -788,16 +788,21 @@ export default defineComponent({
async afterTransaction() {
await this.setItemQtyMap();
this.clearValues();
await this.clearValues();
this.setSinvDoc();
this.toggleModal('Payment', false);
},
clearValues() {
async clearValues() {
this.setSinvDoc();
this.itemSerialNumbers = {};
this.cashAmount = fyo.pesa(0);
this.transferAmount = fyo.pesa(0);
await this.setItems();
if (!this.defaultCustomer) {
this.sinvDoc.party = '';
}
},
toggleModal(modal: ModalName, value?: boolean) {
if (value) {