Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

V5.0.x #1789

Merged
merged 36 commits into from
Feb 27, 2024
Merged

V5.0.x #1789

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
b66b558
Update
Blair2004 Jan 26, 2024
0ff5a32
Update
Blair2004 Feb 1, 2024
c18f466
Merge branch 'master' into v5.0.x
Blair2004 Feb 1, 2024
ebcb4e2
Refactor manage-products.vue and ns-products-preview.vue
Blair2004 Feb 1, 2024
f986f78
Update
Blair2004 Feb 2, 2024
b32dc95
Update
Blair2004 Feb 2, 2024
308b9ad
WIP
Blair2004 Feb 2, 2024
86423e6
WIP
Blair2004 Feb 11, 2024
ae19353
Merge branch 'master' of https://github.com/blair2004/NexoPOS into v5…
Blair2004 Feb 13, 2024
b60a98f
WIP
Blair2004 Feb 13, 2024
6a5e99b
Update NexoPOS version to 5.1.0
Blair2004 Feb 13, 2024
fe70e67
Update
Blair2004 Feb 13, 2024
516f747
Fix label translation in ProductCategoryCrud.php #1764
Blair2004 Feb 14, 2024
39b0ffc
Update:
Blair2004 Feb 23, 2024
121c310
WIP
Blair2004 Feb 23, 2024
795c81f
Update:
Blair2004 Feb 25, 2024
fc27bfb
Add isSubmitting flag to prevent multiple form submissions
Blair2004 Feb 25, 2024
b60412f
Update
Blair2004 Feb 25, 2024
b51991d
Build Project
Blair2004 Feb 25, 2024
d8d7027
Ensuring theme are supported by the new dragzone
Blair2004 Feb 25, 2024
3498d8c
Pinting
Blair2004 Feb 25, 2024
1995b89
WIP
Blair2004 Feb 26, 2024
3aa3127
Add a way to control popup priority while pressing ESC.
Blair2004 Feb 27, 2024
5de8403
Update
Blair2004 Feb 27, 2024
076a9e6
WIP
Blair2004 Feb 27, 2024
dae6f1c
Update Translations
Blair2004 Feb 27, 2024
5a4b8d1
Update French translation for "Biling" key
Blair2004 Feb 27, 2024
ca7afaf
Building
Blair2004 Feb 27, 2024
242140c
WIP
Blair2004 Feb 27, 2024
5c6139f
Merge branch 'master' of https://github.com/blair2004/NexoPOS into v5…
Blair2004 Feb 27, 2024
47394d5
WIP
Blair2004 Feb 27, 2024
7396134
Update user authentication logic
Blair2004 Feb 27, 2024
d93f032
Fix typo in Arabic translation
Blair2004 Feb 27, 2024
9d92c26
Add generateUsername function to AuthenticationTest.php
Blair2004 Feb 27, 2024
381b580
Refactor generateUsername method in AuthenticationTest
Blair2004 Feb 27, 2024
21e4d8d
Update:
Blair2004 Feb 27, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion app/Broadcasting/PrivateChannel.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public function __construct()
*
* @return array|bool
*/
public function join(User $user)
public function join( User $user )
{
return true;
}
Expand Down
14 changes: 7 additions & 7 deletions app/Casts/CurrencyCast.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,23 +9,23 @@ class CurrencyCast implements CastsAttributes
/**
* Cast the given value.
*
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @return mixed
*/
public function get($model, string $key, $value, array $attributes)
public function get( $model, string $key, $value, array $attributes )
{
return (string) ns()->currency->define($value);
return (string) ns()->currency->define( $value );
}

/**
* Prepare the given value for storage.
*
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @return mixed
*/
public function set($model, string $key, $value, array $attributes)
public function set( $model, string $key, $value, array $attributes )
{
return $value;
}
Expand Down
24 changes: 12 additions & 12 deletions app/Casts/DateCast.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,16 @@ class DateCast implements CastsAttributes
/**
* Cast the given value.
*
* @param \Illuminate\Database\Eloquent\Model $model
* @param string $key
* @param mixed $value
* @param array $attributes
* @param \Illuminate\Database\Eloquent\Model $model
* @param string $key
* @param mixed $value
* @param array $attributes
* @return mixed
*/
public function get($model, $key, $value, $attributes)
public function get( $model, $key, $value, $attributes )
{
if ($value !== null) {
return ns()->date->getFormatted($value);
if ( $value !== null ) {
return ns()->date->getFormatted( $value );
}

return $value;
Expand All @@ -27,13 +27,13 @@ public function get($model, $key, $value, $attributes)
/**
* Prepare the given value for storage.
*
* @param \Illuminate\Database\Eloquent\Model $model
* @param string $key
* @param array $value
* @param array $attributes
* @param \Illuminate\Database\Eloquent\Model $model
* @param string $key
* @param array $value
* @param array $attributes
* @return mixed
*/
public function set($model, $key, $value, $attributes)
public function set( $model, $key, $value, $attributes )
{
return $value;
}
Expand Down
20 changes: 10 additions & 10 deletions app/Casts/DiscountTypeCast.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,27 +9,27 @@ class DiscountTypeCast implements CastsAttributes
/**
* Cast the given value.
*
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @return mixed
*/
public function get($model, string $key, $value, array $attributes)
public function get( $model, string $key, $value, array $attributes )
{
return match ($value) {
'percentage_discount' => __('Percentage'),
'flat_discount' => __('Flat'),
default => __('Unknown Type'),
return match ( $value ) {
'percentage_discount' => __( 'Percentage' ),
'flat_discount' => __( 'Flat' ),
default => __( 'Unknown Type' ),
};
}

/**
* Prepare the given value for storage.
*
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @return mixed
*/
public function set($model, string $key, $value, array $attributes)
public function set( $model, string $key, $value, array $attributes )
{
return $value;
}
Expand Down
14 changes: 7 additions & 7 deletions app/Casts/FloatConvertCasting.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,23 +9,23 @@ class FloatConvertCasting implements CastsAttributes
/**
* Cast the given value.
*
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @return mixed
*/
public function get($model, string $key, $value, array $attributes)
public function get( $model, string $key, $value, array $attributes )
{
return ns()->math->set($value ?: 0)->toFloat();
return ns()->math->set( $value ?: 0 )->toFloat();
}

/**
* Prepare the given value for storage.
*
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @return mixed
*/
public function set($model, string $key, $value, array $attributes)
public function set( $model, string $key, $value, array $attributes )
{
return $value;
}
Expand Down
20 changes: 10 additions & 10 deletions app/Casts/GenderCast.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,27 +9,27 @@ class GenderCast implements CastsAttributes
/**
* Cast the given value.
*
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @return mixed
*/
public function get($model, string $key, $value, array $attributes)
public function get( $model, string $key, $value, array $attributes )
{
return match ($value) {
'male' => __('Male'),
'female' => __('Female'),
default => __('Not Defined'),
return match ( $value ) {
'male' => __( 'Male' ),
'female' => __( 'Female' ),
default => __( 'Not Defined' ),
};
}

/**
* Prepare the given value for storage.
*
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @return mixed
*/
public function set($model, string $key, $value, array $attributes)
public function set( $model, string $key, $value, array $attributes )
{
return $value;
}
Expand Down
14 changes: 7 additions & 7 deletions app/Casts/NotDefinedCast.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,23 +9,23 @@ class NotDefinedCast implements CastsAttributes
/**
* Cast the given value.
*
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @return mixed
*/
public function get($model, string $key, $value, array $attributes)
public function get( $model, string $key, $value, array $attributes )
{
return empty($value) ? __('Not Defined') : $value;
return empty( $value ) ? __( 'Not Defined' ) : $value;
}

/**
* Prepare the given value for storage.
*
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @return mixed
*/
public function set($model, string $key, $value, array $attributes)
public function set( $model, string $key, $value, array $attributes )
{
return $value;
}
Expand Down
16 changes: 8 additions & 8 deletions app/Casts/OrderDeliveryCast.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,28 +10,28 @@ class OrderDeliveryCast implements CastsAttributes
/**
* Cast the given value.
*
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @return mixed
*/
public function get($model, string $key, $value, array $attributes)
public function get( $model, string $key, $value, array $attributes )
{
/**
* @var OrdersService $orderService
*/
$orderService = app()->make(OrdersService::class);
$orderService = app()->make( OrdersService::class );

return $orderService->getDeliveryStatus($value);
return $orderService->getDeliveryStatus( $value );
}

/**
* Prepare the given value for storage.
*
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @return mixed
*/
public function set($model, string $key, $value, array $attributes)
public function set( $model, string $key, $value, array $attributes )
{
return $value;
}
Expand Down
14 changes: 7 additions & 7 deletions app/Casts/OrderPaymentCast.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,23 +9,23 @@ class OrderPaymentCast implements CastsAttributes
/**
* Cast the given value.
*
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @return mixed
*/
public function get($model, string $key, $value, array $attributes)
public function get( $model, string $key, $value, array $attributes )
{
return ns()->order->getPaymentLabel($value);
return ns()->order->getPaymentLabel( $value );
}

/**
* Prepare the given value for storage.
*
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @return mixed
*/
public function set($model, string $key, $value, array $attributes)
public function set( $model, string $key, $value, array $attributes )
{
return $value;
}
Expand Down
16 changes: 8 additions & 8 deletions app/Casts/OrderProcessCast.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,28 +10,28 @@ class OrderProcessCast implements CastsAttributes
/**
* Cast the given value.
*
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @return mixed
*/
public function get($model, string $key, $value, array $attributes)
public function get( $model, string $key, $value, array $attributes )
{
/**
* @var OrdersService $orderService
*/
$orderService = app()->make(OrdersService::class);
$orderService = app()->make( OrdersService::class );

return $orderService->getProcessStatus($value);
return $orderService->getProcessStatus( $value );
}

/**
* Prepare the given value for storage.
*
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @return mixed
*/
public function set($model, string $key, $value, array $attributes)
public function set( $model, string $key, $value, array $attributes )
{
return $value;
}
Expand Down
16 changes: 8 additions & 8 deletions app/Casts/OrderTypeCast.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,28 +10,28 @@ class OrderTypeCast implements CastsAttributes
/**
* Cast the given value.
*
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @return mixed
*/
public function get($model, string $key, $value, array $attributes)
public function get( $model, string $key, $value, array $attributes )
{
/**
* @var OrdersService $orderService
*/
$orderService = app()->make(OrdersService::class);
$orderService = app()->make( OrdersService::class );

return $orderService->getTypeLabel($value);
return $orderService->getTypeLabel( $value );
}

/**
* Prepare the given value for storage.
*
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @param \Illuminate\Database\Eloquent\Model $model
* @param mixed $value
* @return mixed
*/
public function set($model, string $key, $value, array $attributes)
public function set( $model, string $key, $value, array $attributes )
{
return $value;
}
Expand Down
Loading
Loading