我有一個 laravel 項目,您只能使用電子郵件和密碼進入該項目創建客戶發票,有時管理員想使用 wtsapp 和電子郵件共享發票我們如何創建無需電子郵件和密碼即可公開的鏈接?這是刀片代碼示例<thead> <tr class="header" id="myHeader"> <th style="width: 20px">#</th> <th>Customer</th> <th>Units</th> <th>Total</th> <th>Sub Total</th> <th>Recieved</th> <th>Balance</th> <th>Advance</th> @if(Auth::user()->role < 3) <th>A Benefit</th> <th>Actual Ben</th> @endif <th>C Benefit</th> <th>S Price</th> <th>Date</th> <th>Action</th> </tr></thead>@if ( $invoice->received_amount < $invoice->subtotal ) <td style="color: red" data-changein="subtotal">{{ $invoice->amount }}</td>@elseif ( $invoice->received_amount > $invoice->subtotal && $invoice->amount_left > 0 ) <td style="color: #CC9A2E" data-changein="subtotal">{{ $invoice->amount }}</td>@endif
1 回答

HUWWW
TA貢獻1874條經驗 獲得超12個贊
auth
只需從具有中間件并且應該可以工作的路由組中刪除 invoice 路由。
你的路線可能是這樣的yourapp.com/invoice/{invoice_id}
。唯一的問題是,如果知道發票 ID,任何人都可以閱讀發票的內容。如果您使用增量 ID,情況可能會變得更糟。您可能需要考慮使用hashed_id
列來防止這種情況發生。
- 1 回答
- 0 關注
- 147 瀏覽
添加回答
舉報
0/150
提交
取消