支付宝记账本
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 lines
456 B

5 months ago
5 months ago
  1. <?php
  2. namespace App\Models;
  3. use Dcat\Admin\Traits\HasDateTimeFormatter;
  4. use Illuminate\Database\Eloquent\Model;
  5. class Merchant extends Model
  6. {
  7. use HasDateTimeFormatter;
  8. public static function getAllMerchant(): array
  9. {
  10. $merchants = self::all();
  11. $list = [];
  12. foreach ($merchants as $merchant) {
  13. $list[$merchant->mch_no] = "[$merchant->mch_no]$merchant->mch_name";
  14. }
  15. return $list;
  16. }
  17. }