Subversion Repositories SmartDukaan

Rev

Blame | Last modification | View Log | RSS feed

<section class="px-3">
    <div class="row" style="width: 350px">
        <div class="col-md-12">
            <div class="minimal-table  border  " style="border-width: 6px !important; border-radius: 5px ">
                <table class="table" id="lmiCreditedIncome">
                    <thead>
                    <tr class="text-white">
                        <th class=" fs-5 bg-danger text-white pe-4" style="padding-right: 30px !important;">Brand</th>
                        <th class="fs-5
                        text-start bg-danger text-white">Credited Income
                        </th>
                        <th class="fs-5
                        text-start bg-danger text-white">Pending Income
                        </th>
                        <th class="fs-5
                        text-start pe-3 bg-danger text-white">Total Income
                        </th>
                    </tr>
                    </thead>
                    <tbody>
                        #foreach($brand in $brandSet)
                        <tr class="brand-wise-income" data-brand="$brand" data-month="$month" data-status="$status">
                            <td class="text-start ps-4 d-flex align-items-center fs-5">
                                ##                                <img src="$brandLogos.getOrDefault($brand, 'default-logo.png')"
                                ##                                     class="brand-logo rounded-circle me-3"
                                ##                                     style="width:32px; height:32px; object-fit: contain;">
                                <span class="gradient-text fw-bold ">$brand</span>
                            </td>

                            <!-- Credited Income -->
                            <td class="fs-5">
                                #set($totalAmount = 0)
                            #set($pendingAmount = 0)

                            #if($totalAmountMap.get($brand))
                                #set($totalAmount = $totalAmountMap.get($brand))
                            #end

                            #if($lastMonthPendingIncomeMap.get($brand) && $lastMonthPendingIncomeMap.get($brand).getAmount())
                                #set($pendingAmount = $lastMonthPendingIncomeMap.get($brand).getAmount())
                            #end

                            #set($creditedAmount = $totalAmount - $pendingAmount)
                            $creditedAmount
                            </td>

                            <!-- Pending Income -->
                            <td class="fs-5">
                                #if($lastMonthPendingIncomeMap.get($brand) && $lastMonthPendingIncomeMap.get($brand).getAmount())
                                    $lastMonthPendingIncomeMap.get($brand).getAmount()
                                #else
                                    0
                                #end
                            </td>
                            <!-- Total -->
                            <td class="fs-5">
                                #if($totalAmountMap.get($brand))
                                    $totalAmountMap.get($brand)
                                #else
                                    0
                                #end
                            </td>
                        </tr>
                        #end
                    </tbody>
                </table>
            </div>
        </div>
    </div>

</section>