feat: implement idempotency key for critical API endpoints
This commit is contained in:
@@ -28,18 +28,20 @@ class OrderVoidConfirmDialog extends StatelessWidget {
|
||||
children: [
|
||||
Expanded(
|
||||
child: AppElevatedButton.outlined(
|
||||
onPressed: () => context.maybePop(),
|
||||
onPressed: state.isSubmitting ? null : () => context.maybePop(),
|
||||
label: 'Batal',
|
||||
),
|
||||
),
|
||||
const SpaceWidth(16),
|
||||
Expanded(
|
||||
child: AppElevatedButton.filled(
|
||||
onPressed: () {
|
||||
context.read<VoidFormBloc>().add(
|
||||
const VoidFormEvent.submitted(),
|
||||
);
|
||||
},
|
||||
onPressed: state.isSubmitting
|
||||
? null
|
||||
: () {
|
||||
context.read<VoidFormBloc>().add(
|
||||
const VoidFormEvent.submitted(),
|
||||
);
|
||||
},
|
||||
label: state.voidType.isAll ? 'Void Pesanan' : 'Void Item',
|
||||
isLoading: state.isSubmitting,
|
||||
),
|
||||
|
||||
Reference in New Issue
Block a user