diff --git a/components/SellReportForm.vue b/components/SellReportForm.vue index 9b82218..7e6fffc 100644 --- a/components/SellReportForm.vue +++ b/components/SellReportForm.vue @@ -28,6 +28,15 @@ const { form, onSubmit } = useReportForm({ name: props.product.name, targetCity: props.target.name }); + +const changePricePercent = (type: 'add' | 'reduce') => { + const percent = form.values.percent?.[0] ?? 100; + if (type === 'add') { + form.setFieldValue('percent', [percent + 1]); + } else { + form.setFieldValue('percent', [percent - 1]); + } +}