Compare commits

...

31 Commits
4.0.0 ... 4.0.1

Author SHA1 Message Date
034c7e385c fix translation issues & formatting 2020-12-09 11:36:14 +05:30
c9086747a3 remove delete_files validation on update 2020-12-08 20:32:41 +05:30
ab1ed269fd fix update-app description style 2020-12-08 20:27:05 +05:30
f7a823e9bc fix reset pass validation message and add 401 migration 2020-12-08 19:52:32 +05:30
b6301b08f8 new build 4.0.1 2020-12-08 19:00:49 +05:30
265c219fdc Merge branch 'localhost-img-issue' into 'master'
fix localhost img display issue

See merge request mohit.panjvani/crater-web!638
2020-12-08 12:15:57 +00:00
729db694a3 Merge branch 'timezone' into 'master'
Fix Timezone issue

See merge request mohit.panjvani/crater-web!642
2020-12-08 12:03:36 +00:00
e2e6415cb6 fix timezone issue 2020-12-08 16:31:44 +05:30
419104a4ec check system using file disk type 2020-12-08 15:07:57 +05:30
f18eac2001 replace env with config 2020-12-08 14:43:21 +05:30
7bffbe59ed Merge branch 'change-datatype' into 'master'
change notes & description column type

See merge request mohit.panjvani/crater-web!639
2020-12-08 09:07:59 +00:00
bf53b4f5eb Merge branch 'fix-toastr' into 'master'
remove multiple toastr call

See merge request mohit.panjvani/crater-web!640
2020-12-08 09:07:12 +00:00
21440230f3 Merge branch 'pdf-ext' into 'master'
fix pdf extenstion issue

See merge request mohit.panjvani/crater-web!641
2020-12-08 09:06:43 +00:00
99c27ba8ef fix pdf extenstion issue 2020-12-08 14:14:52 +05:30
cb7a925cd0 remove multiple toastr call 2020-12-08 13:19:06 +05:30
d2e11bd7df change notes & description column type 2020-12-08 12:55:28 +05:30
1b74a3720e fix localhost img display issue 2020-12-08 11:39:47 +05:30
e222af335e Merge branch 'date-range' into 'master'
fix date range issue in reports

See merge request mohit.panjvani/crater-web!635
2020-12-07 12:52:58 +00:00
599e6270e8 fix date range issue in reports 2020-12-07 12:34:12 +05:30
da7ddcd4f1 Merge branch 'fix-reset-pass-layout' into 'master'
fix layout issue

See merge request mohit.panjvani/crater-web!632
2020-12-07 06:43:07 +00:00
bd01039fb8 Merge branch 'reset-password' into 'master'
Fix reset password

See merge request mohit.panjvani/crater-web!634
2020-12-07 06:42:32 +00:00
718f01ccd4 Merge branch 'unique-hash' into 'master'
Unique hash

See merge request mohit.panjvani/crater-web!633
2020-12-07 06:42:26 +00:00
fd3742b926 fix reset password issue 2020-12-07 10:34:22 +05:30
e8b954d1bd generate unique hash ids 2020-12-05 17:06:22 +05:30
58042decd5 fix layout issue 2020-12-05 15:43:35 +05:30
fa500b3865 add cmd for app key generate 2020-12-05 13:35:46 +05:30
e03924fe9d Merge branch 'master' of https://github.com/bytefury/crater 2020-12-04 11:46:49 +05:30
3f308a2d3b update composer file 2020-12-04 11:46:32 +05:30
6cdd93bab0 Merge pull request #288 from MakerLab-Dev/master
Password reset update
2020-12-04 11:43:02 +05:30
69c6c883c2 Password reset update 2020-12-03 19:04:50 +01:00
69dcf1299b More descriptive errors 2020-12-03 18:00:09 +01:00
43 changed files with 3421 additions and 1301 deletions

View File

@ -1,25 +0,0 @@
<?php
namespace Crater\Http\Controllers\V1\Auth;
use Crater\Http\Controllers\Controller;
use Crater\Models\User;
use Illuminate\Http\Request;
class IsRegisteredController extends Controller
{
/**
* Handle the incoming request.
*
* @param \Illuminate\Http\Request $request
* @return \Illuminate\Http\Response
*/
public function __invoke(Request $request)
{
if (User::whereEmail($request->email)->first()) {
return 'true';
} else {
return 'false';
}
}
}

View File

@ -55,7 +55,7 @@ class ResetPasswordController extends Controller
*/ */
protected function resetPassword($user, $password) protected function resetPassword($user, $password)
{ {
$user->password = \Hash::make($password); $user->password = $password;
$user->setRememberToken(Str::random(60)); $user->setRememberToken(Str::random(60));

View File

@ -35,6 +35,7 @@ class DatabaseConfigurationController extends Controller
$results = $this->environmentManager->saveDatabaseVariables($request); $results = $this->environmentManager->saveDatabaseVariables($request);
if (array_key_exists("success", $results)) { if (array_key_exists("success", $results)) {
Artisan::call('key:generate --force');
Artisan::call('config:clear'); Artisan::call('config:clear');
Artisan::call('cache:clear'); Artisan::call('cache:clear');
Artisan::call('storage:link'); Artisan::call('storage:link');

View File

@ -16,9 +16,6 @@ class DeleteFilesController extends Controller
*/ */
public function __invoke(Request $request) public function __invoke(Request $request)
{ {
$request->validate([
'deleted_files' => 'required',
]);
if(isset($request->deleted_files) && !empty($request->deleted_files)) { if(isset($request->deleted_files) && !empty($request->deleted_files)) {
Updater::deleteFiles($request->deleted_files); Updater::deleteFiles($request->deleted_files);

View File

@ -23,6 +23,7 @@ class ConfigMiddleware
if ($setting && $setting != null && $setting != $timezone) { if ($setting && $setting != null && $setting != $timezone) {
config(['app.timezone' => $setting]); config(['app.timezone' => $setting]);
date_default_timezone_set($setting);
} }
if($request->has('file_disk_id')) { if($request->has('file_disk_id')) {

View File

@ -430,7 +430,12 @@ class Estimate extends Model implements HasMedia
$company = Company::find($this->company_id); $company = Company::find($this->company_id);
$logo = $company->getMedia('logo')->first(); $logo = $company->getMedia('logo')->first();
if ($logo) { $isSystem = FileDisk::whereSetAsDefault(true)->first()->isSystem();
$isLocalhost = config('session.domain') === 'localhost';
if ($logo && $isLocalhost && $isSystem) {
$logo = $logo->getPath();
} else if($logo) {
$logo = $logo->getFullUrl(); $logo = $logo->getFullUrl();
} }

View File

@ -8,6 +8,9 @@ use Illuminate\Database\Eloquent\Factories\HasFactory;
class FileDisk extends Model class FileDisk extends Model
{ {
CONST DISK_TYPE_SYSTEM = 'SYSTEM';
CONST DISK_TYPE_REMOTE = 'REMOTE';
use HasFactory; use HasFactory;
protected $guarded = [ protected $guarded = [
@ -184,4 +187,14 @@ class FileDisk extends Model
return $this; return $this;
} }
public function isSystem()
{
return $this->type === self::DISK_TYPE_SYSTEM;
}
public function isRemote()
{
return $this->type === self::DISK_TYPE_REMOTE;
}
} }

View File

@ -514,7 +514,12 @@ class Invoice extends Model implements HasMedia
$logo = $company->getMedia('logo')->first(); $logo = $company->getMedia('logo')->first();
if ($logo) { $isSystem = FileDisk::whereSetAsDefault(true)->first()->isSystem();
$isLocalhost = config('session.domain') === 'localhost';
if ($logo && $isLocalhost && $isSystem) {
$logo = $logo->getPath();
} else if($logo) {
$logo = $logo->getFullUrl(); $logo = $logo->getFullUrl();
} }

View File

@ -375,7 +375,12 @@ class Payment extends Model implements HasMedia
$logo = $company->getMedia('logo')->first(); $logo = $company->getMedia('logo')->first();
if ($logo) { $isSystem = FileDisk::whereSetAsDefault(true)->first()->isSystem();
$isLocalhost = config('session.domain') === 'localhost';
if ($logo && $isLocalhost && $isSystem) {
$logo = $logo->getPath();
} else if($logo) {
$logo = $logo->getFullUrl(); $logo = $logo->getFullUrl();
} }

View File

@ -14,11 +14,10 @@ trait GeneratesPdfTrait
public function getGeneratedPDFOrStream($collection_name) public function getGeneratedPDFOrStream($collection_name)
{ {
$pdf = $this->getGeneratedPDF($collection_name); $pdf = $this->getGeneratedPDF($collection_name);
if($pdf && file_exists($pdf['path'])) { if($pdf && file_exists($pdf['path'])) {
return response()->make(file_get_contents($pdf['path']), 200, [ return response()->make(file_get_contents($pdf['path']), 200, [
'Content-Type' => 'application/pdf', 'Content-Type' => 'application/pdf',
'Content-Disposition' => 'inline; filename="'.$pdf['file_name'].'"' 'Content-Disposition' => 'inline; filename="'.$pdf['file_name'].'.pdf"'
]); ]);
} }
@ -30,7 +29,7 @@ trait GeneratesPdfTrait
return response()->make($pdf->stream(), 200, [ return response()->make($pdf->stream(), 200, [
'Content-Type' => 'application/pdf', 'Content-Type' => 'application/pdf',
'Content-Disposition' => 'inline; filename="'.$this[$collection_name.'_number'].'"' 'Content-Disposition' => 'inline; filename="'.$this[$collection_name.'_number'].'.pdf"'
]); ]);
} }

2950
composer.lock generated

File diff suppressed because it is too large Load Diff

View File

@ -17,8 +17,10 @@ return [
["code"=>"fr", "name" => "French"], ["code"=>"fr", "name" => "French"],
["code"=>"de", "name" => "German"], ["code"=>"de", "name" => "German"],
["code"=>"it", "name" => "Italian"], ["code"=>"it", "name" => "Italian"],
["code"=>"pt-br", "name" => "Portuguese (Brazilian)"], ["code"=>"pt_BR", "name" => "Portuguese (Brazilian)"],
["code"=>"es", "name" => "Spanish"], ["code"=>"es", "name" => "Spanish"],
["code"=>"lv", "name" => "Latvian"],
["code"=>"sr_LA", "name" => "Serbian Latin"],
], ],
/* /*

View File

@ -41,19 +41,19 @@ return [
'connections' => [ 'connections' => [
Invoice::class => [ Invoice::class => [
'salt' => Invoice::class.'7623e9b0009feff8e024a689d6ef59ce', 'salt' => Invoice::class.config('app.key'),
'length' => '20', 'length' => '20',
'alphabet' => 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890' 'alphabet' => 'XKyIAR7mgt8jD2vbqPrOSVenNGpiYLx4M61T'
], ],
Estimate::class => [ Estimate::class => [
'salt' => Estimate::class.'7623e9b0009feff8e024a689d6ef59ce', 'salt' => Estimate::class.config('app.key'),
'length' => '20', 'length' => '20',
'alphabet' => 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890' 'alphabet' => 'yLJWP79M8rYVqbn1NXjulO6IUDdvekRQGo40'
], ],
Payment::class => [ Payment::class => [
'salt' => Payment::class.'7623e9b0009feff8e024a689d6ef59ce', 'salt' => Payment::class.config('app.key'),
'length' => '20', 'length' => '20',
'alphabet' => 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890' 'alphabet' => 'asqtW3eDRIxB65GYl7UVLS1dybn9XrKTZ4zO'
], ],
], ],

View File

@ -0,0 +1,46 @@
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class ChangeDescriptionAndNotesColumnType extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::table('estimates', function (Blueprint $table) {
$table->text('notes')->nullable()->change();
});
Schema::table('expenses', function (Blueprint $table) {
$table->text('notes')->nullable()->change();
});
Schema::table('estimate_items', function (Blueprint $table) {
$table->text('description')->nullable()->change();
});
Schema::table('invoice_items', function (Blueprint $table) {
$table->text('description')->nullable()->change();
});
Schema::table('items', function (Blueprint $table) {
$table->text('description')->nullable()->change();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
//
}
}

View File

@ -0,0 +1,29 @@
<?php
use Crater\Models\Setting;
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class UpdateCraterVersion401 extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Setting::setSetting('version', '4.0.1');
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
//
}
}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1,4 +1,4 @@
{ {
"/assets/js/app.js": "/assets/js/app.js?id=f8c1167e861af23971a2", "/assets/js/app.js": "/assets/js/app.js?id=bb2c4150e0caffb9f475",
"/assets/css/crater.css": "/assets/css/crater.css?id=262352bd0c724bad8f2f" "/assets/css/crater.css": "/assets/css/crater.css?id=180193a313e33aed1712"
} }

View File

@ -97,7 +97,7 @@ global.axios.interceptors.response.use(undefined, function (err) {
} }
if (!err.response) { if (!err.response) {
window.toastr['error']( window.toastr['error'](
'Network error: Please check your internet connection or wait until servers are back online' 'Please check your internet connection or wait until servers are back online', 'Network Error'
) )
} else { } else {
if ( if (
@ -121,7 +121,7 @@ global.axios.interceptors.response.use(undefined, function (err) {
window.toastr['error']( window.toastr['error'](
err.response.data.message err.response.data.message
? err.response.data.message ? err.response.data.message
: 'Unknown error occurred' : err.response.data || 'Unknown error occurred', 'Error'
) )
} }
} }

View File

@ -122,12 +122,7 @@ export default {
} }
window.toastr['error'](response.data.error) window.toastr['error'](response.data.error)
} catch (err) { } catch (err) {
if (err.response.data.errors.name) { this.isLoading = false
this.isLoading = false
window.toastr['error'](
this.$t('validation.payment_mode_already_taken')
)
}
} }
} }
}, },

View File

@ -75,7 +75,7 @@
"you_got_lost": "عفواً! يبدو أنك قد تهت!", "you_got_lost": "عفواً! يبدو أنك قد تهت!",
"go_home": "عودة إلى الرئيسية", "go_home": "عودة إلى الرئيسية",
"test_mail_conf": "اختبار تكوين البريد", "test_mail_conf": "اختبار تكوين البريد",
"send_mail_successfully": "Mail sent successfully", "send_mail_successfully": "تم إرسال البريد بنجاح",
"setting_updated": "تم تحديث الإعدادات بنجاح", "setting_updated": "تم تحديث الإعدادات بنجاح",
"select_state": "اختر الولاية/المنطقة", "select_state": "اختر الولاية/المنطقة",
"select_country": "اختر الدولة", "select_country": "اختر الدولة",
@ -84,8 +84,8 @@
"street_2": "عنوان الشارع 2", "street_2": "عنوان الشارع 2",
"action_failed": "فشلت العملية", "action_failed": "فشلت العملية",
"retry": "أعد المحاولة", "retry": "أعد المحاولة",
"choose_note": "Choose Note", "choose_note": "اختر ملاحظة",
"no_note_found": "No Note Found", "no_note_found": "لم يتم العثور على الملاحظة",
"insert_note": "أدخل ملاحظة" "insert_note": "أدخل ملاحظة"
}, },
"dashboard": { "dashboard": {
@ -143,8 +143,8 @@
"add_customer": "إضافة عميل", "add_customer": "إضافة عميل",
"contacts_list": "قائمة العملاء", "contacts_list": "قائمة العملاء",
"name": "الاسم", "name": "الاسم",
"mail": "Mail | Mails", "mail": "البريد",
"statement": "Statement", "statement": "البيان",
"display_name": "اسم العرض", "display_name": "اسم العرض",
"primary_contact_name": "اسم التواصل الرئيسي", "primary_contact_name": "اسم التواصل الرئيسي",
"contact_name": "اسم تواصل آخر", "contact_name": "اسم تواصل آخر",
@ -153,7 +153,7 @@
"address": "العنوان", "address": "العنوان",
"phone": "الهاتف", "phone": "الهاتف",
"website": "موقع الإنترنت", "website": "موقع الإنترنت",
"overview": "Overview", "overview": "استعراض",
"enable_portal": "Enable Portal", "enable_portal": "Enable Portal",
"country": "الدولة", "country": "الدولة",
"state": "الولاية/المنطقة", "state": "الولاية/المنطقة",
@ -980,7 +980,6 @@
"default_driver": "برنامج التشغيل الافتراضي", "default_driver": "برنامج التشغيل الافتراضي",
"is_default": "أمر افتراضي", "is_default": "أمر افتراضي",
"set_default_disk": "تعيين القرص الافتراضي", "set_default_disk": "تعيين القرص الافتراضي",
"set_default_disk_confirm": "This disk will be set as default and all the new PDFs will be saved on this disk",
"success_set_default_disk": "Disk set as default successfully", "success_set_default_disk": "Disk set as default successfully",
"save_pdf_to_disk": "حفظ ملفات PDF على القرص", "save_pdf_to_disk": "حفظ ملفات PDF على القرص",
"disk_setting_description": "قم بتمكين هذا ، إذا كنت ترغب في حفظ نسخة من كل فاتورة ، تقدير وإيصال دفع PDF على القرص الافتراضي الخاص بك تلقائيًا. سيؤدي تشغيل هذا الخيار إلى تقليل وقت التحميل عند عرض ملفات PDF.", "disk_setting_description": "قم بتمكين هذا ، إذا كنت ترغب في حفظ نسخة من كل فاتورة ، تقدير وإيصال دفع PDF على القرص الافتراضي الخاص بك تلقائيًا. سيؤدي تشغيل هذا الخيار إلى تقليل وقت التحميل عند عرض ملفات PDF.",

View File

@ -980,7 +980,6 @@
"default_driver": "Default Driver", "default_driver": "Default Driver",
"is_default": "IS DEFAULT", "is_default": "IS DEFAULT",
"set_default_disk": "Set Default Disk", "set_default_disk": "Set Default Disk",
"set_default_disk_confirm": "This disk will be set as default and all the new PDFs will be saved on this disk",
"success_set_default_disk": "Disk set as default successfully", "success_set_default_disk": "Disk set as default successfully",
"save_pdf_to_disk": "Save PDFs to Disk", "save_pdf_to_disk": "Save PDFs to Disk",
"disk_setting_description": " Enable this, if you wish to save a copy of each Invoice, Estimate & Payment Receipt PDF on your default disk automatically. Turning this option will decrease the load-time when viewing the PDFs.", "disk_setting_description": " Enable this, if you wish to save a copy of each Invoice, Estimate & Payment Receipt PDF on your default disk automatically. Turning this option will decrease the load-time when viewing the PDFs.",
@ -1130,7 +1129,7 @@
"address_maxlength": "Die Adresse sollte nicht länger als 255 Zeichen sein.", "address_maxlength": "Die Adresse sollte nicht länger als 255 Zeichen sein.",
"ref_number_maxlength": "Ref Number sollte nicht länger als 255 Zeichen sein.", "ref_number_maxlength": "Ref Number sollte nicht länger als 255 Zeichen sein.",
"prefix_maxlength": "Das Präfix sollte nicht länger als 5 Zeichen sein.", "prefix_maxlength": "Das Präfix sollte nicht länger als 5 Zeichen sein.",
"something_went_wrong": "Etwas ist falsch gelaufen" "something_went_wrong": "Da ist etwas schief gelaufen"
}, },
"pdf_estimate_label": "Kostenvoranschlag", "pdf_estimate_label": "Kostenvoranschlag",
"pdf_estimate_number": "Kostenvoran. Nummer", "pdf_estimate_number": "Kostenvoran. Nummer",
@ -1166,6 +1165,6 @@
"pdf_tax_types_label": "Steuersätze", "pdf_tax_types_label": "Steuersätze",
"pdf_expenses_label": "Gesamtausgaben", "pdf_expenses_label": "Gesamtausgaben",
"pdf_bill_to": "Rechnungsempfänger,", "pdf_bill_to": "Rechnungsempfänger,",
"pdf_ship_to": "Versand ein,", "pdf_ship_to": "Versand an,",
"pdf_received_from": "Received from:" "pdf_received_from": "Received from:"
} }

View File

@ -912,6 +912,7 @@
"download_zip_file": "Download ZIP file", "download_zip_file": "Download ZIP file",
"unzipping_package": "Unzipping Package", "unzipping_package": "Unzipping Package",
"copying_files": "Copying Files", "copying_files": "Copying Files",
"deleting_files": "Deleting Unused files",
"running_migrations": "Running Migrations", "running_migrations": "Running Migrations",
"finishing_update": "Finishing Update", "finishing_update": "Finishing Update",
"update_failed": "Update Failed", "update_failed": "Update Failed",
@ -1123,11 +1124,11 @@
"price_minvalue": "Price should be greater than 0.", "price_minvalue": "Price should be greater than 0.",
"amount_maxlength": "Amount should not be greater than 20 digits.", "amount_maxlength": "Amount should not be greater than 20 digits.",
"amount_minvalue": "Amount should be greater than 0.", "amount_minvalue": "Amount should be greater than 0.",
"description_maxlength": "Description should not be greater than 255 characters.", "description_maxlength": "Description should not be greater than 65,000 characters.",
"subject_maxlength": "Subject should not be greater than 100 characters.", "subject_maxlength": "Subject should not be greater than 100 characters.",
"message_maxlength": "Message should not be greater than 255 characters.", "message_maxlength": "Message should not be greater than 255 characters.",
"maximum_options_error": "Maximum of {max} options selected. First remove a selected option to select another.", "maximum_options_error": "Maximum of {max} options selected. First remove a selected option to select another.",
"notes_maxlength": "Notes should not be greater than 255 characters.", "notes_maxlength": "Notes should not be greater than 65,000 characters.",
"address_maxlength": "Address should not be greater than 255 characters.", "address_maxlength": "Address should not be greater than 255 characters.",
"ref_number_maxlength": "Ref Number should not be greater than 255 characters.", "ref_number_maxlength": "Ref Number should not be greater than 255 characters.",
"prefix_maxlength": "Prefix should not be greater than 5 characters.", "prefix_maxlength": "Prefix should not be greater than 5 characters.",

View File

@ -15,7 +15,7 @@
"general": { "general": {
"add_company": "Add Company", "add_company": "Add Company",
"view_pdf": "Ver PDF", "view_pdf": "Ver PDF",
"copy_pdf_url": "Copiar URL del PDF", "copy_pdf_url": "Copy PDF Url",
"download_pdf": "Descargar PDF", "download_pdf": "Descargar PDF",
"save": "Guardar", "save": "Guardar",
"create": "Create", "create": "Create",
@ -339,7 +339,7 @@
"notes": "Notas", "notes": "Notas",
"view": "Ver", "view": "Ver",
"send_invoice": "Enviar la factura", "send_invoice": "Enviar la factura",
"resend_invoice": "Reenviar la factura", "resend_invoice": "Resend Invoice",
"invoice_template": "Plantilla de factura", "invoice_template": "Plantilla de factura",
"template": "Modelo", "template": "Modelo",
"mark_as_sent": "Marcar como enviada", "mark_as_sent": "Marcar como enviada",
@ -980,7 +980,6 @@
"default_driver": "Default Driver", "default_driver": "Default Driver",
"is_default": "IS DEFAULT", "is_default": "IS DEFAULT",
"set_default_disk": "Set Default Disk", "set_default_disk": "Set Default Disk",
"set_default_disk_confirm": "This disk will be set as default and all the new PDFs will be saved on this disk",
"success_set_default_disk": "Disk set as default successfully", "success_set_default_disk": "Disk set as default successfully",
"save_pdf_to_disk": "Save PDFs to Disk", "save_pdf_to_disk": "Save PDFs to Disk",
"disk_setting_description": " Enable this, if you wish to save a copy of each Invoice, Estimate & Payment Receipt PDF on your default disk automatically. Turning this option will decrease the load-time when viewing the PDFs.", "disk_setting_description": " Enable this, if you wish to save a copy of each Invoice, Estimate & Payment Receipt PDF on your default disk automatically. Turning this option will decrease the load-time when viewing the PDFs.",

View File

@ -154,7 +154,7 @@
"phone": "Téléphone", "phone": "Téléphone",
"website": "Site Internet", "website": "Site Internet",
"overview": "Overview", "overview": "Overview",
"enable_portal": "Enable Portal", "enable_portal": "Activer le portail",
"country": "Pays", "country": "Pays",
"state": "Etat", "state": "Etat",
"city": "Ville", "city": "Ville",
@ -253,7 +253,7 @@
"convert_to_invoice": "Convertir en facture", "convert_to_invoice": "Convertir en facture",
"mark_as_sent": "Marquer comme envoyé", "mark_as_sent": "Marquer comme envoyé",
"send_estimate": "Envoyer un devis", "send_estimate": "Envoyer un devis",
"resend_estimate": "Resend Estimate", "resend_estimate": "Renvoyer le devis",
"record_payment": "Enregistrer un paiement", "record_payment": "Enregistrer un paiement",
"add_estimate": "Ajouter un devis", "add_estimate": "Ajouter un devis",
"save_estimate": "Sauvegarder le devis", "save_estimate": "Sauvegarder le devis",
@ -339,7 +339,7 @@
"notes": "Remarques", "notes": "Remarques",
"view": "Voir", "view": "Voir",
"send_invoice": "Envoyer une facture", "send_invoice": "Envoyer une facture",
"resend_invoice": "Resend Invoice", "resend_invoice": "Renvoyer la facture",
"invoice_template": "Modèle de facture", "invoice_template": "Modèle de facture",
"template": "Modèle", "template": "Modèle",
"mark_as_sent": "Marquer comme envoyé", "mark_as_sent": "Marquer comme envoyé",
@ -679,7 +679,7 @@
"edit_custom_field": "Modifier un champ personnalisé", "edit_custom_field": "Modifier un champ personnalisé",
"field_name": "Nom de domaine", "field_name": "Nom de domaine",
"label": "Étiquette", "label": "Étiquette",
"type": "Type", "type": "Type ",
"name": "Nom", "name": "Nom",
"required": "Obligatoire", "required": "Obligatoire",
"placeholder": "Espace réservé", "placeholder": "Espace réservé",
@ -713,7 +713,7 @@
"save": "Sauvegarder", "save": "Sauvegarder",
"addresses": { "addresses": {
"title": "Adresses", "title": "Adresses",
"section_description": "You can set Customer Billing Address and Customer Shipping Address Format (Displayed in PDF only). ", "section_description": "Vous pouvez définir le format de l'adresse de facturation et de livraison du client (affiché en PDF uniquement). ",
"customer_billing_address": "Adresse de paiement", "customer_billing_address": "Adresse de paiement",
"customer_shipping_address": "Adresse de livraison", "customer_shipping_address": "Adresse de livraison",
"company_address": "Adresse de l'entreprise", "company_address": "Adresse de l'entreprise",
@ -722,7 +722,7 @@
"address": "Addresse", "address": "Addresse",
"display_name": "Nom", "display_name": "Nom",
"primary_contact_name": "Nom du contact principal", "primary_contact_name": "Nom du contact principal",
"email": "Email", "email": "Adresse email",
"website": "Site Internet", "website": "Site Internet",
"name": "Nom", "name": "Nom",
"country": "Pays", "country": "Pays",
@ -758,7 +758,7 @@
"estimate_settings": "Paramètre", "estimate_settings": "Paramètre",
"autogenerate_estimate_number": "Générer automatiquement le numéro de devis", "autogenerate_estimate_number": "Générer automatiquement le numéro de devis",
"estimate_setting_description": "Désactivez cette option si vous ne souhaitez pas générer automatiquement les numéros de devis à chaque fois que vous en créez un nouveau.", "estimate_setting_description": "Désactivez cette option si vous ne souhaitez pas générer automatiquement les numéros de devis à chaque fois que vous en créez un nouveau.",
"enter_estimate_prefix": "Enter estmiate prefix", "enter_estimate_prefix": "Entrez le préfixe d'estimation",
"estimate_setting_updated": "Paramètres de devis mis à jour", "estimate_setting_updated": "Paramètres de devis mis à jour",
"company_address_format": "Format d'adresse de l'entreprise", "company_address_format": "Format d'adresse de l'entreprise",
"billing_address_format": "Format d'adresse de facturation", "billing_address_format": "Format d'adresse de facturation",
@ -802,7 +802,7 @@
"title": "Remarques", "title": "Remarques",
"description": "Gagnez du temps en créant des notes et en les réutilisant sur vos factures, devis et paiements.", "description": "Gagnez du temps en créant des notes et en les réutilisant sur vos factures, devis et paiements.",
"notes": "Remarques", "notes": "Remarques",
"type": "Type", "type": "Type ",
"add_note": "Ajouter une note", "add_note": "Ajouter une note",
"add_new_note": "Ajouter une nouvelle note", "add_new_note": "Ajouter une nouvelle note",
"name": "Nom", "name": "Nom",
@ -817,7 +817,7 @@
"account_settings": { "account_settings": {
"profile_picture": "Image de profil", "profile_picture": "Image de profil",
"name": "Nom", "name": "Nom",
"email": "Email", "email": "Adresse email",
"password": "Mot de passe", "password": "Mot de passe",
"confirm_password": "Confirmez le mot de passe", "confirm_password": "Confirmez le mot de passe",
"account_settings": "Paramètres du compte", "account_settings": "Paramètres du compte",
@ -827,7 +827,7 @@
}, },
"user_profile": { "user_profile": {
"name": "Nom", "name": "Nom",
"email": "Email", "email": "Adresse email",
"password": "Mot de passe", "password": "Mot de passe",
"confirm_password": "Confirmez le mot de passe" "confirm_password": "Confirmez le mot de passe"
}, },
@ -892,7 +892,7 @@
"updated_message": "Préférences mises à jour avec succès", "updated_message": "Préférences mises à jour avec succès",
"select_language": "Choisir la langue", "select_language": "Choisir la langue",
"select_time_zone": "sélectionnez le fuseau horaire", "select_time_zone": "sélectionnez le fuseau horaire",
"select_date_format": "Select Date Format", "select_date_format": "Sélectionnez le format de date",
"select_financial_year": "sélectionner lexercice" "select_financial_year": "sélectionner lexercice"
}, },
"update_app": { "update_app": {
@ -901,7 +901,7 @@
"check_update": "Vérifier les mises à jour", "check_update": "Vérifier les mises à jour",
"avail_update": "Nouvelle mise à jour disponible", "avail_update": "Nouvelle mise à jour disponible",
"next_version": "Version suivante", "next_version": "Version suivante",
"requirements": "Requirements", "requirements": "Exigences",
"update": "Mettre à jour maintenant", "update": "Mettre à jour maintenant",
"update_progress": "Mise à jour en cours...", "update_progress": "Mise à jour en cours...",
"progress_text": "Cela ne prendra que quelques minutes. S'il vous plaît ne pas actualiser l'écran ou fermer la fenêtre avant la fin de la mise à jour", "progress_text": "Cela ne prendra que quelques minutes. S'il vous plaît ne pas actualiser l'écran ou fermer la fenêtre avant la fin de la mise à jour",
@ -980,7 +980,6 @@
"default_driver": "Pilote par défaut", "default_driver": "Pilote par défaut",
"is_default": "EST PAR DÉFAUT", "is_default": "EST PAR DÉFAUT",
"set_default_disk": "Définir le disque par défaut", "set_default_disk": "Définir le disque par défaut",
"set_default_disk_confirm": "This disk will be set as default and all the new PDFs will be saved on this disk",
"success_set_default_disk": "Disk set as default successfully", "success_set_default_disk": "Disk set as default successfully",
"save_pdf_to_disk": "Enregistrer les PDF sur le disque", "save_pdf_to_disk": "Enregistrer les PDF sur le disque",
"disk_setting_description": "Activez cette option si vous souhaitez enregistrer automatiquement une copie de chaque facture, devis et reçu de paiement PDF sur votre disque par défaut. L'activation de cette option réduira le temps de chargement lors de l'affichage des PDF.", "disk_setting_description": "Activez cette option si vous souhaitez enregistrer automatiquement une copie de chaque facture, devis et reçu de paiement PDF sur votre disque par défaut. L'activation de cette option réduira le temps de chargement lors de l'affichage des PDF.",

View File

@ -9,6 +9,7 @@ import pt_BR from './pt-br.json'
import it from './it.json' import it from './it.json'
import sr_LA from './sr-latn.json' import sr_LA from './sr-latn.json'
import nl from './nl.json' import nl from './nl.json'
import lv from './lv.json'
Vue.use(VueI18n) Vue.use(VueI18n)
@ -24,6 +25,7 @@ const i18n = new VueI18n({
it, it,
sr_LA, sr_LA,
nl, nl,
lv,
}, },
}) })

View File

@ -980,7 +980,6 @@
"default_driver": "Default Driver", "default_driver": "Default Driver",
"is_default": "IS DEFAULT", "is_default": "IS DEFAULT",
"set_default_disk": "Set Default Disk", "set_default_disk": "Set Default Disk",
"set_default_disk_confirm": "This disk will be set as default and all the new PDFs will be saved on this disk",
"success_set_default_disk": "Disk set as default successfully", "success_set_default_disk": "Disk set as default successfully",
"save_pdf_to_disk": "Save PDFs to Disk", "save_pdf_to_disk": "Save PDFs to Disk",
"disk_setting_description": " Enable this, if you wish to save a copy of each Invoice, Estimate & Payment Receipt PDF on your default disk automatically. Turning this option will decrease the load-time when viewing the PDFs.", "disk_setting_description": " Enable this, if you wish to save a copy of each Invoice, Estimate & Payment Receipt PDF on your default disk automatically. Turning this option will decrease the load-time when viewing the PDFs.",

File diff suppressed because it is too large Load Diff

View File

@ -1,6 +1,6 @@
{ {
"navigation": { "navigation": {
"dashboard": "Dashboard", "dashboard": "Overzicht",
"customers": "Klanten", "customers": "Klanten",
"items": "Artikelen", "items": "Artikelen",
"invoices": "Facturen", "invoices": "Facturen",
@ -10,15 +10,15 @@
"reports": "Rapporten", "reports": "Rapporten",
"settings": "Instellingen", "settings": "Instellingen",
"logout": "Uitloggen", "logout": "Uitloggen",
"users": "Users" "users": "Gebruikers"
}, },
"general": { "general": {
"add_company": "Add Company", "add_company": "Bedrijf toevoegen",
"view_pdf": "Bekijk PDF", "view_pdf": "Bekijk PDF",
"copy_pdf_url": "Kopieer PDF-URL", "copy_pdf_url": "Kopieer PDF-URL",
"download_pdf": "Download PDF", "download_pdf": "Download PDF",
"save": "Opslaan", "save": "Opslaan",
"create": "Create", "create": "Maak",
"cancel": "annuleren", "cancel": "annuleren",
"update": "Bijwerken", "update": "Bijwerken",
"deselect": "Maak de selectie ongedaan", "deselect": "Maak de selectie ongedaan",
@ -31,9 +31,9 @@
"ascending": "Oplopend", "ascending": "Oplopend",
"descending": "Aflopend", "descending": "Aflopend",
"subject": "Onderwerpen", "subject": "Onderwerpen",
"body": "Body", "body": "Inhoud",
"message": "Bericht", "message": "Bericht",
"send": "Send", "send": "Verstuur",
"go_back": "Ga terug", "go_back": "Ga terug",
"back_to_login": "Terug naar Inloggen?", "back_to_login": "Terug naar Inloggen?",
"home": "Home", "home": "Home",
@ -84,9 +84,9 @@
"street_2": "Straat # 2", "street_2": "Straat # 2",
"action_failed": "Actie: mislukt", "action_failed": "Actie: mislukt",
"retry": "Retr", "retry": "Retr",
"choose_note": "Choose Note", "choose_note": "Kies notitie",
"no_note_found": "No Note Found", "no_note_found": "Geen notitie gevonden",
"insert_note": "Insert Note" "insert_note": "Notitie invoegen"
}, },
"dashboard": { "dashboard": {
"select_year": "Selecteer jaar", "select_year": "Selecteer jaar",
@ -133,10 +133,10 @@
"compound_tax": "Verbinding Ta" "compound_tax": "Verbinding Ta"
}, },
"global_search": { "global_search": {
"search": "Search...", "search": "Zoeken...",
"customers": "Klanten", "customers": "Klanten",
"users": "Users", "users": "Gebruikers",
"no_results_found": "No Results Found" "no_results_found": "Geen zoekresultaten"
}, },
"customers": { "customers": {
"title": "Klanten", "title": "Klanten",
@ -144,7 +144,7 @@
"contacts_list": "Klantenlijst", "contacts_list": "Klantenlijst",
"name": "Naam", "name": "Naam",
"mail": "Mail | Mails", "mail": "Mail | Mails",
"statement": "Statement", "statement": "Verklaring",
"display_name": "Weergavenaam", "display_name": "Weergavenaam",
"primary_contact_name": "Naam primaire contactpersoon", "primary_contact_name": "Naam primaire contactpersoon",
"contact_name": "Contactnaam", "contact_name": "Contactnaam",
@ -153,8 +153,8 @@
"address": "Adres", "address": "Adres",
"phone": "Telefoon", "phone": "Telefoon",
"website": "Website", "website": "Website",
"overview": "Overview", "overview": "Overzicht",
"enable_portal": "Enable Portal", "enable_portal": "Activeer Portaal",
"country": "Land", "country": "Land",
"state": "Provincie", "state": "Provincie",
"city": "Stad", "city": "Stad",
@ -182,10 +182,10 @@
"select_currency": "Selecteer valuta", "select_currency": "Selecteer valuta",
"select_a_customer": "Selecteer een klant", "select_a_customer": "Selecteer een klant",
"type_or_click": "Typ of klik om te selecteren", "type_or_click": "Typ of klik om te selecteren",
"new_transaction": "New Transaction", "new_transaction": "Nieuwe transactie",
"no_matching_customers": "There are no matching customers!", "no_matching_customers": "Er zijn geen overeenkomende klanten!",
"phone_number": "Phone Number", "phone_number": "Telefoonnummer",
"create_date": "Create Date", "create_date": "Aangemaakt op",
"confirm_delete": "U kunt deze klant en alle gerelateerde facturen, offertes en betalingen niet terugkrijgen. | U zult deze klanten en alle gerelateerde facturen, offertes en betalingen niet kunnen terugkrijgen.", "confirm_delete": "U kunt deze klant en alle gerelateerde facturen, offertes en betalingen niet terugkrijgen. | U zult deze klanten en alle gerelateerde facturen, offertes en betalingen niet kunnen terugkrijgen.",
"created_message": "Klant succesvol aangemaakt", "created_message": "Klant succesvol aangemaakt",
"updated_message": "Klant succesvol geüpdatet", "updated_message": "Klant succesvol geüpdatet",
@ -429,7 +429,7 @@
"view_payment": "Bekijk betaling", "view_payment": "Bekijk betaling",
"add_new_payment": "Nieuwe betaling toevoegen", "add_new_payment": "Nieuwe betaling toevoegen",
"send_payment_receipt": "Betaalbewijs verzenden", "send_payment_receipt": "Betaalbewijs verzenden",
"send_payment": "Send Payment", "send_payment": "Verstuur betaling",
"save_payment": "Betaling opslaan", "save_payment": "Betaling opslaan",
"update_payment": "Betaling bijwerken", "update_payment": "Betaling bijwerken",
"payment": "Betaling | Betalingen", "payment": "Betaling | Betalingen",
@ -508,30 +508,30 @@
"login_placeholder": "mail@voorbeeld.co" "login_placeholder": "mail@voorbeeld.co"
}, },
"users": { "users": {
"title": "Users", "title": "Gebruikers",
"users_list": "Users List", "users_list": "Gebruikerslijst",
"name": "Naam", "name": "Naam",
"description": "Omschrijving", "description": "Omschrijving",
"added_on": "Toegevoegd", "added_on": "Toegevoegd",
"date_of_creation": "Datum van creatie", "date_of_creation": "Datum van creatie",
"action": "Actie", "action": "Actie",
"add_user": "Add User", "add_user": "Gebruiker toevoegen",
"save_user": "Save User", "save_user": "Gebruiker opslaan",
"update_user": "Update User", "update_user": "Gebruiker bijwerken",
"user": "User | Users", "user": "Gebruiker | Gebruikers",
"add_new_user": "Add New User", "add_new_user": "Nieuwe gebruiker toevoegen",
"new_user": "New User", "new_user": "Nieuwe gebruiker",
"edit_user": "Edit User", "edit_user": "Gebruiker bewerken",
"no_users": "No users yet!", "no_users": "Nog geen gebruikers!",
"list_of_users": "This section will contain the list of users.", "list_of_users": "Deze sectie zal de lijst met gebruikers bevatten.",
"email": "E-mail", "email": "E-mail",
"phone": "Telefoon", "phone": "Telefoon",
"password": "Wachtwoord", "password": "Wachtwoord",
"user_attached_message": "Kan een item dat al in gebruik is niet verwijderen", "user_attached_message": "Kan een item dat al in gebruik is niet verwijderen",
"confirm_delete": "You will not be able to recover this User | You will not be able to recover these Users", "confirm_delete": "Je kunt deze gebruiker later niet herstellen | Je kunt deze gebruikers later niet herstellen",
"created_message": "User created successfully", "created_message": "Gebruiker succesvol aangemaakt",
"updated_message": "User updated successfully", "updated_message": "Gebruiker met succes bijgewerkt",
"deleted_message": "User deleted successfully | User deleted successfully" "deleted_message": "Gebruiker succesvol verwijderd | Gebruikers succesvol verwijderd"
}, },
"reports": { "reports": {
"title": "Verslag doen van", "title": "Verslag doen van",
@ -604,8 +604,8 @@
"tax_types": "Belastingtypen", "tax_types": "Belastingtypen",
"expense_category": "Onkostencategorieën", "expense_category": "Onkostencategorieën",
"update_app": "App bijwerken", "update_app": "App bijwerken",
"backup": "Backup", "backup": "Back-up",
"file_disk": "File Disk", "file_disk": "Bestandsopslag",
"custom_fields": "Custom Fields", "custom_fields": "Custom Fields",
"payment_modes": "Payment Modes", "payment_modes": "Payment Modes",
"notes": "Opmerkingen" "notes": "Opmerkingen"
@ -980,7 +980,6 @@
"default_driver": "Default Driver", "default_driver": "Default Driver",
"is_default": "IS DEFAULT", "is_default": "IS DEFAULT",
"set_default_disk": "Set Default Disk", "set_default_disk": "Set Default Disk",
"set_default_disk_confirm": "This disk will be set as default and all the new PDFs will be saved on this disk",
"success_set_default_disk": "Disk set as default successfully", "success_set_default_disk": "Disk set as default successfully",
"save_pdf_to_disk": "Save PDFs to Disk", "save_pdf_to_disk": "Save PDFs to Disk",
"disk_setting_description": " Enable this, if you wish to save a copy of each Invoice, Estimate & Payment Receipt PDF on your default disk automatically. Turning this option will decrease the load-time when viewing the PDFs.", "disk_setting_description": " Enable this, if you wish to save a copy of each Invoice, Estimate & Payment Receipt PDF on your default disk automatically. Turning this option will decrease the load-time when viewing the PDFs.",

View File

@ -923,15 +923,15 @@
"create_backup": "Create Backup", "create_backup": "Create Backup",
"select_backup_type": "Select Backup Type", "select_backup_type": "Select Backup Type",
"backup_confirm_delete": "You will not be able to recover this Backup", "backup_confirm_delete": "You will not be able to recover this Backup",
"path": "path", "path": "Caminho",
"new_disk": "New Disk", "new_disk": "Novo disco",
"created_at": "created at", "created_at": "Criado em",
"size": "size", "size": "Tamanho",
"dropbox": "dropbox", "dropbox": "DropBox",
"local": "local", "local": "local",
"healthy": "healthy", "healthy": "healthy",
"amount_of_backups": "amount of backups", "amount_of_backups": "Quantidade de backups",
"newest_backups": "newest backups", "newest_backups": "Backups mais recentes",
"used_storage": "used storage", "used_storage": "used storage",
"select_disk": "Select Disk", "select_disk": "Select Disk",
"action": "Ação", "action": "Ação",
@ -942,13 +942,13 @@
"disk": { "disk": {
"title": "File Disk | File Disks", "title": "File Disk | File Disks",
"description": "By default, Crater will use your local disk for saving backups, avatar and other image files. You can configure more than one disk drivers like DigitalOcean, S3 and Dropbox according to your preference.", "description": "By default, Crater will use your local disk for saving backups, avatar and other image files. You can configure more than one disk drivers like DigitalOcean, S3 and Dropbox according to your preference.",
"created_at": "created at", "created_at": "Criado em",
"dropbox": "dropbox", "dropbox": "DropBox",
"name": "Nome", "name": "Nome",
"driver": "Driver", "driver": "Driver",
"disk_type": "Tipo", "disk_type": "Tipo",
"disk_name": "Disk Name", "disk_name": "Nome do disco",
"new_disk": "Add New Disk", "new_disk": "Adicionar novo disco",
"filesystem_driver": "Filesystem Driver", "filesystem_driver": "Filesystem Driver",
"local_driver": "local Driver", "local_driver": "local Driver",
"local_root": "local Root", "local_root": "local Root",
@ -958,10 +958,10 @@
"public_visibility": "Public Visibility", "public_visibility": "Public Visibility",
"media_driver": "Media Driver", "media_driver": "Media Driver",
"media_root": "Media Root", "media_root": "Media Root",
"aws_driver": "AWS Driver", "aws_driver": "Driver AWS",
"aws_key": "AWS Key", "aws_key": "Chave AWS",
"aws_secret": "AWS Secret", "aws_secret": "Segredo AWS",
"aws_region": "AWS Region", "aws_region": "Região AWS",
"aws_bucket": "AWS Bucket", "aws_bucket": "AWS Bucket",
"aws_root": "AWS Root", "aws_root": "AWS Root",
"do_spaces_type": "Do Spaces type", "do_spaces_type": "Do Spaces type",
@ -980,7 +980,6 @@
"default_driver": "Default Driver", "default_driver": "Default Driver",
"is_default": "IS DEFAULT", "is_default": "IS DEFAULT",
"set_default_disk": "Set Default Disk", "set_default_disk": "Set Default Disk",
"set_default_disk_confirm": "This disk will be set as default and all the new PDFs will be saved on this disk",
"success_set_default_disk": "Disk set as default successfully", "success_set_default_disk": "Disk set as default successfully",
"save_pdf_to_disk": "Save PDFs to Disk", "save_pdf_to_disk": "Save PDFs to Disk",
"disk_setting_description": " Enable this, if you wish to save a copy of each Invoice, Estimate & Payment Receipt PDF on your default disk automatically. Turning this option will decrease the load-time when viewing the PDFs.", "disk_setting_description": " Enable this, if you wish to save a copy of each Invoice, Estimate & Payment Receipt PDF on your default disk automatically. Turning this option will decrease the load-time when viewing the PDFs.",

View File

@ -48,16 +48,3 @@ export const logout = ({ state, commit }) => {
}) })
}) })
} }
export const checkMail = ({ commit }, data) => {
return new Promise((resolve, reject) => {
window.axios
.post('/api/v1/is-registered', data)
.then((response) => {
resolve(response)
})
.catch((err) => {
reject(err)
})
})
}

View File

@ -20,19 +20,24 @@
</div> </div>
</div> </div>
<sw-button <sw-button
v-if="!isSent" :loading="isLoading"
:disabled="isLoading" :disabled="isLoading"
type="submit" type="submit"
variant="primary" variant="primary"
> >
{{ $t('validation.send_reset_link') }} <div v-if="!isSent">
</sw-button> {{ $t('validation.send_reset_link') }}
<sw-button v-else :disabled="isLoading" variant="primary" type="submit"> </div>
{{ $t('validation.not_yet') }} <div v-else>
{{ $t('validation.not_yet') }}
</div>
</sw-button> </sw-button>
<div class="mt-4 mb-4 text-sm"> <div class="mt-4 mb-4 text-sm">
<router-link to="/login"> <router-link
to="/login"
class="text-sm text-primary-400 hover:text-gray-700"
>
{{ $t('general.back_to_login') }} {{ $t('general.back_to_login') }}
</router-link> </router-link>
</div> </div>
@ -52,7 +57,6 @@ export default {
}, },
isSent: false, isSent: false,
isLoading: false, isLoading: false,
isRegisteredUser: false,
} }
}, },
validations: { validations: {
@ -64,14 +68,9 @@ export default {
}, },
}, },
methods: { methods: {
...mapActions('auth', ['checkMail']), ...mapActions('auth'),
async validateBeforeSubmit(e) { async validateBeforeSubmit(e) {
this.$v.formData.$touch() this.$v.formData.$touch()
let { data } = await this.checkMail()
if (data === false) {
toastr['error'](this.$t('validation.email_does_not_exist'))
return
}
if (!this.$v.formData.$invalid) { if (!this.$v.formData.$invalid) {
try { try {
this.isLoading = true this.isLoading = true
@ -87,19 +86,10 @@ export default {
this.isSent = true this.isSent = true
this.isLoading = false this.isLoading = false
} catch (err) { } catch (err) {
if (err.response && err.response.status === 403) { this.isLoading = false
toastr['error'](err.response.data, 'Error')
}
} }
} }
}, },
// async checkMail() {
// let response = await window.axios.post(
// '/api/v1/is-registered',
// this.formData
// )
// return response.data
// },
}, },
} }
</script> </script>

View File

@ -1,43 +1,53 @@
<template> <template>
<form id="loginForm" @submit.prevent="validateBeforeSubmit"> <form id="loginForm" @submit.prevent="validateBeforeSubmit">
<div class="form-group"> <div class="mb-4 form-group">
<sw-input <sw-input-group :label="$t('login.email')" required>
v-model.trim="formData.email" <sw-input
:invalid="$v.formData.email.$error" v-model.trim="formData.email"
:placeholder="$t('login.enter_email')" :invalid="$v.formData.email.$error"
type="email" :placeholder="$t('login.enter_email')"
name="email" type="email"
@input="$v.formData.email.$touch()" name="email"
/> @input="$v.formData.email.$touch()"
/>
</sw-input-group>
<div v-if="$v.formData.email.$error"> <div v-if="$v.formData.email.$error">
<span v-if="!$v.formData.email.required" class="help-block text-danger"> <span
v-if="!$v.formData.email.required"
class="text-sm help-block text-danger"
>
{{ $t('validation.required') }} {{ $t('validation.required') }}
</span> </span>
<span v-if="!$v.formData.email.email" class="help-block text-danger"> <span
v-if="!$v.formData.email.email"
class="text-sm help-block text-danger"
>
{{ $t('validation.email_incorrect') }} {{ $t('validation.email_incorrect') }}
</span> </span>
</div> </div>
</div> </div>
<div class="form-group"> <div class="mb-4 form-group">
<sw-input <sw-input-group :label="$t('login.password')" required>
id="password" <sw-input
v-model.trim="formData.password" id="password"
:invalid="$v.formData.password.$error" v-model.trim="formData.password"
:placeholder="$t('login.enter_password')" :invalid="$v.formData.password.$error"
type="password" :placeholder="$t('login.enter_password')"
name="password" type="password"
@input="$v.formData.password.$touch()" name="password"
/> @input="$v.formData.password.$touch()"
/>
</sw-input-group>
<div v-if="$v.formData.password.$error"> <div v-if="$v.formData.password.$error">
<span <span
v-if="!$v.formData.password.required" v-if="!$v.formData.password.required"
class="help-block text-danger" class="text-sm help-block text-danger"
> >
{{ $t('validation.required') }} {{ $t('validation.required') }}
</span> </span>
<span <span
v-if="!$v.formData.password.minLength" v-if="!$v.formData.password.minLength"
class="help-block text-danger" class="text-sm help-block text-danger"
> >
{{ {{
$tc( $tc(
@ -49,19 +59,21 @@
</span> </span>
</div> </div>
</div> </div>
<div class="form-group"> <div class="mb-8 form-group">
<sw-input <sw-input-group :label="$t('login.retype_password')" required>
v-model.trim="formData.password_confirmation" <sw-input
:invalid="$v.formData.password_confirmation.$error" v-model.trim="formData.password_confirmation"
:placeholder="$t('login.retype_password')" :invalid="$v.formData.password_confirmation.$error"
type="password" :placeholder="$t('login.retype_password')"
name="password_confirmation" type="password"
@input="$v.formData.password_confirmation.$touch()" name="password_confirmation"
/> @input="$v.formData.password_confirmation.$touch()"
/>
</sw-input-group>
<div v-if="$v.formData.password_confirmation.$error"> <div v-if="$v.formData.password_confirmation.$error">
<span <span
v-if="!$v.formData.password_confirmation.sameAsPassword" v-if="!$v.formData.password_confirmation.sameAsPassword"
class="help-block text-danger" class="text-sm help-block text-danger"
> >
{{ $t('validation.password_incorrect') }} {{ $t('validation.password_incorrect') }}
</span> </span>

View File

@ -340,7 +340,7 @@ export default {
between: between(0, this.maxDiscount), between: between(0, this.maxDiscount),
}, },
description: { description: {
maxLength: maxLength(255), maxLength: maxLength(65000),
}, },
}, },
} }

View File

@ -302,7 +302,7 @@ export default {
}, },
notes: { notes: {
maxLength: maxLength(255), maxLength: maxLength(65000),
}, },
}, },
}, },

View File

@ -340,7 +340,7 @@ export default {
between: between(0, this.maxDiscount), between: between(0, this.maxDiscount),
}, },
description: { description: {
maxLength: maxLength(255), maxLength: maxLength(65000),
}, },
}, },
} }

View File

@ -118,7 +118,7 @@
:loading="isLoading" :loading="isLoading"
variant="primary" variant="primary"
size="lg" size="lg"
class="flex w-full justify-center md:w-auto" class="flex justify-center w-full md:w-auto"
> >
<save-icon v-if="!isLoading" class="mr-2 -ml-1" /> <save-icon v-if="!isLoading" class="mr-2 -ml-1" />
{{ isEdit ? $t('items.update_item') : $t('items.save_item') }} {{ isEdit ? $t('items.update_item') : $t('items.save_item') }}
@ -293,7 +293,7 @@ export default {
}, },
description: { description: {
maxLength: maxLength(255), maxLength: maxLength(65000),
}, },
}, },
}, },

View File

@ -163,6 +163,14 @@ export default {
return this.$t('validation.required') return this.$t('validation.required')
} }
}, },
dateRangeUrl () {
return `${this.siteURL}?from_date=${moment(
this.formData.from_date
).format('YYYY-MM-DD')}&to_date=${moment(this.formData.to_date).format(
'YYYY-MM-DD'
)}`
}
}, },
watch: { watch: {
@ -174,11 +182,7 @@ export default {
mounted() { mounted() {
this.siteURL = `/reports/expenses/${this.getSelectedCompany.unique_hash}` this.siteURL = `/reports/expenses/${this.getSelectedCompany.unique_hash}`
this.url = `${this.siteURL}?from_date=${moment( this.url = this.dateRangeUrl
this.formData.from_date
).format('YYYY-MM-DD')}&to_date=${moment(this.formData.to_date).format(
'YYYY-MM-DD'
)}`
}, },
methods: { methods: {
@ -243,6 +247,7 @@ export default {
setRangeToCustom() { setRangeToCustom() {
this.selectedRange = 'Custom' this.selectedRange = 'Custom'
}, },
async viewReportsPDF() { async viewReportsPDF() {
let data = await this.getReports() let data = await this.getReports()
window.open(this.getReportUrl, '_blank') window.open(this.getReportUrl, '_blank')
@ -257,7 +262,7 @@ export default {
return true return true
} }
this.url = `${this.siteURL}?from_date=${this.formData.from_date}&to_date=${this.formData.to_date}` this.url = this.dateRangeUrl
return true return true
}, },
@ -269,7 +274,7 @@ export default {
window.open(this.getReportUrl + '&download=true') window.open(this.getReportUrl + '&download=true')
setTimeout(() => { setTimeout(() => {
this.url = `${this.siteURL}?from_date=${this.formData.from_date}&to_date=${this.formData.to_date}` this.url = this.dateRangeUrl
}, 200) }, 200)
}, },
}, },

View File

@ -162,6 +162,14 @@ export default {
return this.$t('validation.required') return this.$t('validation.required')
} }
}, },
dateRangeUrl () {
return `${this.siteURL}?from_date=${moment(
this.formData.from_date
).format('YYYY-MM-DD')}&to_date=${moment(this.formData.to_date).format(
'YYYY-MM-DD'
)}`
}
}, },
watch: { watch: {
@ -173,17 +181,14 @@ export default {
mounted() { mounted() {
this.siteURL = `/reports/profit-loss/${this.getSelectedCompany.unique_hash}` this.siteURL = `/reports/profit-loss/${this.getSelectedCompany.unique_hash}`
this.url = `${this.siteURL}?from_date=${moment( this.url = this.dateRangeUrl
this.formData.from_date
).format('YYYY-MM-DD')}&to_date=${moment(this.formData.to_date).format(
'YYYY-MM-DD'
)}`
}, },
methods: { methods: {
getThisDate(type, time) { getThisDate(type, time) {
return moment()[type](time).toString() return moment()[type](time).toString()
}, },
getPreDate(type, time) { getPreDate(type, time) {
return moment().subtract(1, time)[type](time).toString() return moment().subtract(1, time)[type](time).toString()
}, },
@ -257,7 +262,7 @@ export default {
return true return true
} }
this.url = `${this.siteURL}?from_date=${this.formData.from_date}&to_date=${this.formData.to_date}` this.url = this.dateRangeUrl
return true return true
}, },
@ -268,7 +273,7 @@ export default {
window.open(this.getReportUrl + '&download=true') window.open(this.getReportUrl + '&download=true')
setTimeout(() => { setTimeout(() => {
this.url = `${this.siteURL}?from_date=${this.formData.from_date}&to_date=${this.formData.to_date}` this.url = this.dateRangeUrl
}, 200) }, 200)
}, },
}, },

View File

@ -147,6 +147,7 @@ export default {
computed: { computed: {
...mapGetters('company', ['getSelectedCompany']), ...mapGetters('company', ['getSelectedCompany']),
getReportUrl() { getReportUrl() {
return this.url return this.url
}, },
@ -180,6 +181,22 @@ export default {
return this.$t('validation.required') return this.$t('validation.required')
} }
}, },
customerDateRangeUrl () {
return `${this.customerSiteURL}?from_date=${moment(
this.formData.from_date
).format('YYYY-MM-DD')}&to_date=${moment(this.formData.to_date).format(
'YYYY-MM-DD'
)}`
},
itemDateRangeUrl () {
return `${this.itemsSiteURL}?from_date=${moment(
this.formData.from_date
).format('YYYY-MM-DD')}&to_date=${moment(this.formData.to_date).format(
'YYYY-MM-DD'
)}`
}
}, },
watch: { watch: {
@ -197,6 +214,7 @@ export default {
methods: { methods: {
...mapActions('salesReport', ['loadLinkByCustomer', 'loadLinkByItems']), ...mapActions('salesReport', ['loadLinkByCustomer', 'loadLinkByItems']),
getThisDate(type, time) { getThisDate(type, time) {
return moment()[type](time).toString() return moment()[type](time).toString()
}, },
@ -263,18 +281,10 @@ export default {
async getInitialReport() { async getInitialReport() {
if (this.selectedType === 'By Customer') { if (this.selectedType === 'By Customer') {
this.url = `${this.customerSiteURL}?from_date=${moment( this.url = this.customerDateRangeUrl
this.formData.from_date
).format('YYYY-MM-DD')}&to_date=${moment(this.formData.to_date).format(
'YYYY-MM-DD'
)}`
return true return true
} }
this.url = `${this.itemsSiteURL}?from_date=${moment( this.url = this.itemDateRangeUrl
this.formData.from_date
).format('YYYY-MM-DD')}&to_date=${moment(this.formData.to_date).format(
'YYYY-MM-DD'
)}`
return true return true
}, },
@ -291,10 +301,10 @@ export default {
return true return true
} }
if (this.selectedType === 'By Customer') { if (this.selectedType === 'By Customer') {
this.url = `${this.customerSiteURL}?from_date=${this.formData.from_date}&to_date=${this.formData.to_date}` this.url = this.customerDateRangeUrl
return true return true
} }
this.url = `${this.itemsSiteURL}?from_date=${this.formData.from_date}&to_date=${this.formData.to_date}` this.url = this.itemDateRangeUrl
return true return true
}, },
@ -306,10 +316,10 @@ export default {
window.open(this.getReportUrl + '&download=true') window.open(this.getReportUrl + '&download=true')
setTimeout(() => { setTimeout(() => {
if (this.selectedType === 'By Customer') { if (this.selectedType === 'By Customer') {
this.url = `${this.customerSiteURL}?from_date=${this.formData.from_date}&to_date=${this.formData.to_date}` this.url = this.customerDateRangeUrl
return true return true
} }
this.url = `${this.itemsSiteURL}?from_date=${this.formData.from_date}&to_date=${this.formData.to_date}` this.url = this.itemDateRangeUrl
return true return true
}, 200) }, 200)
}, },

View File

@ -151,21 +151,28 @@ export default {
return this.$t('validation.required') return this.$t('validation.required')
} }
}, },
dateRangeUrl () {
return `${this.siteURL}?from_date=${moment(
this.formData.from_date
).format('YYYY-MM-DD')}&to_date=${moment(this.formData.to_date).format(
'YYYY-MM-DD'
)}`
}
}, },
watch: { watch: {
range(newRange) { range(newRange) {
this.formData.from_date = moment(newRange).startOf('year').toString() this.formData.from_date = moment(newRange).startOf('year').toString()
this.formData.to_date = moment(newRange).endOf('year').toString() this.formData.to_date = moment(newRange).endOf('year').toString()
}, },
}, },
mounted() { mounted() {
this.siteURL = `/reports/tax-summary/${this.getSelectedCompany.unique_hash}` this.siteURL = `/reports/tax-summary/${this.getSelectedCompany.unique_hash}`
this.url = `${this.siteURL}?from_date=${moment( this.url = this.dateRangeUrl
this.formData.from_date
).format('YYYY-MM-DD')}&to_date=${moment(this.formData.to_date).format(
'YYYY-MM-DD'
)}`
}, },
methods: { methods: {
getThisDate(type, time) { getThisDate(type, time) {
return moment()[type](time).toString() return moment()[type](time).toString()
@ -240,7 +247,7 @@ export default {
return false return false
} }
this.url = `${this.siteURL}?from_date=${this.formData.from_date}&to_date=${this.formData.to_date}` this.url = this.dateRangeUrl
return true return true
}, },
downloadReport() { downloadReport() {
@ -251,7 +258,7 @@ export default {
window.open(this.url + '&download=true') window.open(this.url + '&download=true')
setTimeout(() => { setTimeout(() => {
this.url = `${this.siteURL}?from_date=${this.formData.from_date}&to_date=${this.formData.to_date}` this.url = this.dateRangeUrl
}, 200) }, 200)
}, },
}, },

View File

@ -47,12 +47,12 @@
> >
{{ updateData.version }} {{ updateData.version }}
</label> </label>
<p <div
class="mb-8 text-sm leading-snug text-gray-500" class="pl-5 mt-4 mb-8 text-sm leading-snug text-gray-500 update-description"
style="white-space: pre-wrap; max-width: 480px" style="white-space: pre-wrap; max-width: 480px"
v-html="description" v-html="description"
> ></div>
</p>
<label class="text-sm not-italic font-medium input-label"> <label class="text-sm not-italic font-medium input-label">
{{ $t('settings.update_app.requirements') }} {{ $t('settings.update_app.requirements') }}
</label> </label>
@ -211,7 +211,7 @@ export default {
}, },
hasUiUpdate() { hasUiUpdate() {
return this.updateData.version != '4.0.0' return this.updateData.version != '4.0.0'
} },
}, },
created() { created() {
window.addEventListener('beforeunload', (event) => { window.addEventListener('beforeunload', (event) => {
@ -358,3 +358,10 @@ export default {
}, },
} }
</script> </script>
<style>
.update-description ul li {
list-style: disc !important;
margin-bottom: 4px;
}
</style>

View File

@ -96,12 +96,6 @@ Route::prefix('/v1')->group(function () {
Route::get('/app/version', AppVersionController::class); Route::get('/app/version', AppVersionController::class);
// Email is registered
// ----------------------------------
Route::get('/is/registered', IsRegisteredController::class);
// Authentication & Password Reset // Authentication & Password Reset
//---------------------------------- //----------------------------------
@ -112,7 +106,7 @@ Route::prefix('/v1')->group(function () {
Route::post('logout', [AuthController::class, 'logout'])->middleware('auth:sanctum'); Route::post('logout', [AuthController::class, 'logout'])->middleware('auth:sanctum');
// Send reset password mail // Send reset password mail
Route::post('password/email', [ForgotPasswordController::class, 'sendResetLinkEmail']); Route::post('password/email', [ForgotPasswordController::class, 'sendResetLinkEmail'])->middleware("throttle:10,2");;
// handle reset password form process // handle reset password form process
Route::post('reset/password', [ResetPasswordController::class, 'reset']); Route::post('reset/password', [ResetPasswordController::class, 'reset']);