Replies: 2 comments
-
|
Please provide full repository to help us debug your exact use case. |
Beta Was this translation helpful? Give feedback.
0 replies
-
|
Below the part of code in the (new Panel('Payment', $this->paymentFields()))->limit(2),
//
//Some code
//
protected function paymentFields()
if ($this->price_tf - $this->paid_amount >0)
return [
Badge::make('Payment', function () {
return 'Not paid';
})->map([
'Not paid' => 'danger',
]),
];
else
return [
Badge::make('Status', function () {
return 'Paid';
})->map([
'Paid' => 'success',
])->hideFromIndex(),
} |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Description:
Hello,

I have placed a
Badge Fieldfor payments status with condition to show onIndexonly when it is not paid. I get the below index display.Figure 1: when first row meets the condition to display the
badge fieldonindex.Figure 2: when the first row doesn't meet the condition to display the

badge fieldonindex.Detailed steps to reproduce the issue on a fresh Nova installation:
Place a
Badge Fieldwith condition to display onIndex.Beta Was this translation helpful? Give feedback.
All reactions