added Translation to setting

master
A1Gard 1 month ago
parent 3abd1b6d38
commit f936feb684

@ -79,6 +79,11 @@ class SettingController extends Controller
if ($set != null && !$request->hasFile($key)) {
$set->value = validateSettingRequest($set,$val);
// need to test
if (config('app.xlang.active') && config('app.xlang.main') != 'en' && (
$set->type != 'TEXT' && $set->type != 'EDITOR' && $set->type != 'LONGTEXT')){
$set->setTranslation('value','en' , $val);
}
$set->save();
}
}

@ -57,6 +57,7 @@
"Added items view depends on theme part": "موارد اضافه شده بسته به نوع نمای انتخاب شده متفاوت خواهد بود",
"Additional data": "اطلاعات تکمیلی",
"Address": "نشانی",
"Address added successfully": "",
"Address added to :CUSTOMER": "نشانی به :CUSTOMER اضافه شد",
"Address editor": "ویرایشگر نشانی",
"Addresses": "نشانی‌ها",
@ -83,6 +84,7 @@
"Auth code": "کد احراز هویت",
"Auth code is invalid": "کد احراز هویت اشتباه اسات",
"Auth code send successfully": "کد احراز هویت ارسال شد",
"Back to profile": "",
"Background image": "تصویر زمینه",
"Base price": "مبلغ پایه",
"Basic data": "اطلاعات پایه",
@ -341,7 +343,9 @@
"Send Answer": "ارسال پاسخ",
"Send Answer and close": "ارسال پاسخ و بستن",
"Send Password Reset Link": "ارسال پیوند بازنشانی گذرواژه",
"Send answer": "",
"Send authenticate code": "ارسال کد احراز هویت",
"Send ticket": "",
"Sent to": "ارسال به",
"Set": "تغییر به",
"Setting": "تنظیمات",
@ -381,6 +385,8 @@
"There is nothing added to card!": "چیزی در سبد خرید وجود ندارد",
"There is nothing to show!": "اینجا چیزی برای نمایش وجود ندارد",
"There is noting file to show!": "هیچ پرونده ای برای نمایش وجود ندارد",
"Ticket added successfully": "",
"Ticket answered successfully": "",
"Tickets": "تیکت‌های پشتیبانی",
"Tickets list": "فهرست تیکت‌های پشتیبانی",
"Tips": "نکات",
@ -417,12 +423,14 @@
"Video clip": "کلیپ",
"Video clips": "کلیپ‌ها",
"Video clips list": "فهرست کلیپ‌ها",
"View": "",
"Visitors": "بازدیدکنندگان",
"Visits": "بازدید‌ها",
"We recommending add title each images": "به شما پیشنهاد می‌کنیم که برای هر تصویر یک عنوان اضافه کنید",
"Website attachments list": "فهرست پیوست‌های سایت",
"Welcome back": "خوش آمدید",
"Width": "عرض",
"You": "",
"You are logged in successfully": "شما با موفقیت وارد شدید",
"You can add images after create gallery": "شما می‌توانید بعد از ساختن گالری به آن تصویر اضافه کنید",
"You can add item after create menu": "شما می‌توانید پس از ساختن فهرست به آن آیتم اضافه کنید",
@ -431,6 +439,7 @@
"You can create \/ edit clip as draft, publish it when you want": "شما میتوانید کلیپ را ایجاد و ویرایش کنید، هر زمان که خواستید آن را منتشر کنید",
"You can leave the slug empty; it will be generated automatically.": "شما می‌توانید نامک را خالی بگذارید به صورت خودکار ساخته شود",
"You don't have access this action": "شما دسترسی لازم برای این بخش را ندارید",
"You don't have any comments, We are so pleased to hear your look-out": "",
"You have some products in your shopping card.": "در سبد خرید شما محصول وجود دارد",
"You need at least one address to order, Please add address": "شما برای ادامه فرآیند خرید به حداقل یک نشانی نیاز دارید",
"You need complete your information": "شما می‌بایستی اطلاعات خود را تکمیل کنید",
@ -439,8 +448,10 @@
"You try attempts, Try it a few minutes": "تلاش شما از حداکثر درخواستی بیشتر است",
"You try more than :COUNT attempts, Try it later": "شما بیش از :COUNT تلاش کردید لطفاً بعداً تلاش کنید",
"Your Email sent": "ایمیل شما ارسال شد",
"Your answer ...": "",
"Your comment has been submitted": "دیدگاه شما ارسال شد",
"Your information is insufficient, Please complete your information": "اطلاعات شما ناقص است، لطفا اطلاعات خود را تکمیل کنید",
"Your message ...": "",
"Your message for this order...": "پیام شما ویژه این سفارش ...",
"a minute ago": "یک دقیقه پیش",
"address updated": "نشانی به روز شد",

@ -58,11 +58,11 @@
<div class="row">
<div class="col-md-10">
@if( $tr == 'body' || $tr == 'desc' || $tr == 'description' || $tr == 'excerpt' || $tr == 'table')
@if( $tr == 'body' || $tr == 'desc' || $tr == 'description' || $tr == 'excerpt' || $tr == 'table' || request()->has('editor'))
<textarea
@if(langIsRTL($lang->tag)) dir="rtl" @else dir="ltr" @endif
class="form-control @if($tr == 'body' || $tr == 'desc' || $tr == 'description' || $tr == 'table' ) ckeditorx @endif"
class="form-control @if($tr == 'body' || $tr == 'desc' || $tr == 'description' || $tr == 'table' || request()->has('editor')) ckeditorx @endif"
rows="4" id="{{$lang->tag}}{{$tr}}"
name="data[{{$lang->tag}}][{{$tr}}]">{{gettype($model->getTranslation($tr,$lang->tag)) == 'string' ? $model->getTranslation($tr,$lang->tag):'' }}</textarea>
@else

@ -1,6 +1,12 @@
<div class="setting-field col-md-{{$setting->size}}">
<label for="{{$setting->key}}">
{{$setting->title}}
@if(config('app.xlang.active') && isset($setting->translatable) &&
($setting['type'] == 'LONGTEXT' || $setting['type'] == 'TEXT' || $setting['type'] == 'EDITOR'))
<a href="{{route('admin.lang.model',[$setting->id, get_class($setting)])}}{{$setting['type'] == 'EDITOR'?'?editor=1':''}}">
<i class="ri-translate"></i>
</a>
@endif
{{-- // WIP translate--}}
</label>

Loading…
Cancel
Save