D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
home
/
forge
/
re-viewers.com
/
app
/
Http
/
Resources
/
Filename :
SettingResource.php
back
Copy
<?php namespace App\Http\Resources; use Illuminate\Http\Request; use Illuminate\Http\Resources\Json\JsonResource; class SettingResource extends JsonResource { public function toArray($request): array { return [ 'app_name' => $this->app_name, 'app_logo' => $this->app_logo ? asset('storage/images/' . $this->app_logo) : null, 'app_description' => $this->app_description, 'app_version' => $this->app_version, 'app_author' => $this->app_author, 'app_contact' => $this->app_contact, 'app_email' => $this->app_email, 'app_website' => $this->app_website, // ✅ الإعلانات 'ads' => [ 'interstitial' => [ 'enabled' => (bool) $this->interstital_ad, 'id' => $this->interstital_ad_id, 'facebook_id' => $this->interstital_facebook_id, 'clicks' => $this->interstital_ad_click, 'applovin_id' => $this->interstitial_applovin_id, 'wortise_id' => $this->interstitial_wortise_id, ], 'banner' => [ 'enabled' => (bool) $this->banner_ad, 'id' => $this->banner_ad_id, 'facebook_id' => $this->banner_facebook_id, 'applovin_id' => $this->banner_applovin_id, 'wortise_id' => $this->banner_wortise_id, ], 'native' => [ 'enabled' => (bool) $this->nativ_ad, 'id' => $this->nativ_ad_id, 'facebook_id' => $this->nativ_facebook_id, 'clicks' => $this->nativ_ad_click, 'applovin_id' => $this->nativ_applovin_id, 'wortise_id' => $this->native_wortise_id, ], 'start_ads_id' => $this->start_ads_id, 'ad_network' => $this->android_ad_network, 'wortise_app_id'=> $this->wortise_app_id, ], // ✅ إعدادات الـ API 'api' => [ 'page_limit' => $this->api_page_limit, 'cat_order_by' => $this->api_cat_order_by, 'cat_post_order_by' => $this->api_cat_post_order_by, ], // ✅ سياسة الاستخدام 'privacy_policy' => $this->app_privacy_policy, 'terms_conditions' => $this->app_terms_conditions, 'faq' => $this->app_faq, 'about_us' => $this->about_us_description, // ✅ التحديثات 'update' => [ 'status' => (bool) $this->app_update_status, 'new_version' => $this->app_new_version, 'description' => $this->app_update_desc, 'redirect_url' => $this->app_redirect_url, 'cancel_status' => (bool) $this->cancel_update_status, ], // ✅ إدارة الحساب 'account_delete_intruction' => $this->account_delete_intruction, // ✅ إشعارات 'onesignal' => [ 'app_id' => $this->onesignal_app_id, 'rest_key' => $this->onesignal_rest_key, ], 'publisher_id' => $this->publisher_id, ]; } }