добавляю файлы dll с таблицами БД magic 2.0, а также наполнение этих таблиц данными
This commit is contained in:
@@ -1,18 +0,0 @@
|
|||||||
root = true
|
|
||||||
|
|
||||||
[*]
|
|
||||||
charset = utf-8
|
|
||||||
end_of_line = lf
|
|
||||||
indent_size = 4
|
|
||||||
indent_style = space
|
|
||||||
insert_final_newline = true
|
|
||||||
trim_trailing_whitespace = true
|
|
||||||
|
|
||||||
[*.md]
|
|
||||||
trim_trailing_whitespace = false
|
|
||||||
|
|
||||||
[*.{yml,yaml}]
|
|
||||||
indent_size = 2
|
|
||||||
|
|
||||||
[docker-compose.yml]
|
|
||||||
indent_size = 4
|
|
||||||
@@ -1,59 +0,0 @@
|
|||||||
APP_NAME=Laravel
|
|
||||||
APP_ENV=local
|
|
||||||
APP_KEY=
|
|
||||||
APP_DEBUG=true
|
|
||||||
APP_URL=http://localhost
|
|
||||||
|
|
||||||
LOG_CHANNEL=stack
|
|
||||||
LOG_DEPRECATIONS_CHANNEL=null
|
|
||||||
LOG_LEVEL=debug
|
|
||||||
|
|
||||||
DB_CONNECTION=mysql
|
|
||||||
DB_HOST=127.0.0.1
|
|
||||||
DB_PORT=3306
|
|
||||||
DB_DATABASE=laravel
|
|
||||||
DB_USERNAME=root
|
|
||||||
DB_PASSWORD=
|
|
||||||
|
|
||||||
BROADCAST_DRIVER=log
|
|
||||||
CACHE_DRIVER=file
|
|
||||||
FILESYSTEM_DISK=local
|
|
||||||
QUEUE_CONNECTION=sync
|
|
||||||
SESSION_DRIVER=file
|
|
||||||
SESSION_LIFETIME=120
|
|
||||||
|
|
||||||
MEMCACHED_HOST=127.0.0.1
|
|
||||||
|
|
||||||
REDIS_HOST=127.0.0.1
|
|
||||||
REDIS_PASSWORD=null
|
|
||||||
REDIS_PORT=6379
|
|
||||||
|
|
||||||
MAIL_MAILER=smtp
|
|
||||||
MAIL_HOST=mailpit
|
|
||||||
MAIL_PORT=1025
|
|
||||||
MAIL_USERNAME=null
|
|
||||||
MAIL_PASSWORD=null
|
|
||||||
MAIL_ENCRYPTION=null
|
|
||||||
MAIL_FROM_ADDRESS="hello@example.com"
|
|
||||||
MAIL_FROM_NAME="${APP_NAME}"
|
|
||||||
|
|
||||||
AWS_ACCESS_KEY_ID=
|
|
||||||
AWS_SECRET_ACCESS_KEY=
|
|
||||||
AWS_DEFAULT_REGION=us-east-1
|
|
||||||
AWS_BUCKET=
|
|
||||||
AWS_USE_PATH_STYLE_ENDPOINT=false
|
|
||||||
|
|
||||||
PUSHER_APP_ID=
|
|
||||||
PUSHER_APP_KEY=
|
|
||||||
PUSHER_APP_SECRET=
|
|
||||||
PUSHER_HOST=
|
|
||||||
PUSHER_PORT=443
|
|
||||||
PUSHER_SCHEME=https
|
|
||||||
PUSHER_APP_CLUSTER=mt1
|
|
||||||
|
|
||||||
VITE_APP_NAME="${APP_NAME}"
|
|
||||||
VITE_PUSHER_APP_KEY="${PUSHER_APP_KEY}"
|
|
||||||
VITE_PUSHER_HOST="${PUSHER_HOST}"
|
|
||||||
VITE_PUSHER_PORT="${PUSHER_PORT}"
|
|
||||||
VITE_PUSHER_SCHEME="${PUSHER_SCHEME}"
|
|
||||||
VITE_PUSHER_APP_CLUSTER="${PUSHER_APP_CLUSTER}"
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
* text=auto eol=lf
|
|
||||||
|
|
||||||
*.blade.php diff=html
|
|
||||||
*.css diff=css
|
|
||||||
*.html diff=html
|
|
||||||
*.md diff=markdown
|
|
||||||
*.php diff=php
|
|
||||||
|
|
||||||
/.github export-ignore
|
|
||||||
CHANGELOG.md export-ignore
|
|
||||||
.styleci.yml export-ignore
|
|
||||||
-19
@@ -1,19 +0,0 @@
|
|||||||
/.phpunit.cache
|
|
||||||
/node_modules
|
|
||||||
/public/build
|
|
||||||
/public/hot
|
|
||||||
/public/storage
|
|
||||||
/storage/*.key
|
|
||||||
/vendor
|
|
||||||
.env
|
|
||||||
.env.backup
|
|
||||||
.env.production
|
|
||||||
.phpunit.result.cache
|
|
||||||
Homestead.json
|
|
||||||
Homestead.yaml
|
|
||||||
auth.json
|
|
||||||
npm-debug.log
|
|
||||||
yarn-error.log
|
|
||||||
/.fleet
|
|
||||||
/.idea
|
|
||||||
/.vscode
|
|
||||||
@@ -1,90 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Taxi\App\Console;
|
|
||||||
|
|
||||||
use Error;
|
|
||||||
use Symfony\Component\Console\Input\InputOption;
|
|
||||||
use Symfony\Component\Console\Input\InputArgument;
|
|
||||||
use App\Console\Commands\BaseScheduleCommand;
|
|
||||||
use App\Mail\BaseMailerObj;
|
|
||||||
use Illuminate\Support\Facades\Mail;
|
|
||||||
use App\Mail\Mailer;
|
|
||||||
use Modules\Taxi\App\Models\TaxiMain;
|
|
||||||
use DateTime;
|
|
||||||
|
|
||||||
class SendOrdersToTaxiCommand extends BaseScheduleCommand
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* The name and signature of the console command.
|
|
||||||
*/
|
|
||||||
public $signature = 'taxi:send';
|
|
||||||
|
|
||||||
/**
|
|
||||||
* The console command description.
|
|
||||||
*/
|
|
||||||
public $description = 'Отправка заказов такси на сегодня агрегаторам';
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Create a new command instance.
|
|
||||||
*/
|
|
||||||
public function __construct()
|
|
||||||
{
|
|
||||||
parent::__construct();
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Execute the console command.
|
|
||||||
*/
|
|
||||||
public function handle()
|
|
||||||
{
|
|
||||||
$this->executeCommand(function () {
|
|
||||||
$todayOrders = TaxiMain::where('cancel_rqst', 0)
|
|
||||||
->where('taxi_date', (new DateTime())->format('Y-m-d'))
|
|
||||||
->get()
|
|
||||||
->toArray();
|
|
||||||
|
|
||||||
if (!$todayOrders) {
|
|
||||||
Mail::send(new Mailer(
|
|
||||||
new BaseMailerObj(
|
|
||||||
|
|
||||||
)
|
|
||||||
));
|
|
||||||
echo '<pre>'; var_dump('da'); echo'</pre>';
|
|
||||||
} else {
|
|
||||||
echo '<pre>'; var_dump('net'); echo'</pre>';
|
|
||||||
}
|
|
||||||
|
|
||||||
throw new Error('Ошипка!');
|
|
||||||
}, 'еще инва');
|
|
||||||
|
|
||||||
// try {
|
|
||||||
// throw new Error('Ошипка!');
|
|
||||||
// } catch (\Throwable $th) {
|
|
||||||
// \Log::channel('schedule_err')->error($th->getFile() . ": " . $th->getMessage() . " Line: " . $th->getLine());
|
|
||||||
// }
|
|
||||||
|
|
||||||
//$this->info('Daily report generated at ' . now());
|
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Get the console command arguments.
|
|
||||||
*/
|
|
||||||
protected function getArguments(): array
|
|
||||||
{
|
|
||||||
return [
|
|
||||||
['example', InputArgument::REQUIRED, 'An example argument.'],
|
|
||||||
];
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Get the console command options.
|
|
||||||
*/
|
|
||||||
protected function getOptions(): array
|
|
||||||
{
|
|
||||||
return [
|
|
||||||
['example', null, InputOption::VALUE_OPTIONAL, 'An example option.', null],
|
|
||||||
];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,65 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Taxi\App\DTO;
|
|
||||||
|
|
||||||
use Modules\Taxi\App\Http\Requests\TaxiOrderRequest;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Класс для формирования DTO с данными по заказу на такси
|
|
||||||
*/
|
|
||||||
class TaxiOrderDTO
|
|
||||||
{
|
|
||||||
public function __construct(
|
|
||||||
public readonly int | null $id,
|
|
||||||
public readonly string | null $emp_login,
|
|
||||||
public readonly string $emp_phone,
|
|
||||||
public readonly string $taxi_date,
|
|
||||||
public readonly string $taxi_time,
|
|
||||||
public readonly string $taxi_address_from,
|
|
||||||
public readonly string $taxi_address_to,
|
|
||||||
public readonly int $cancel_rqst = 0,
|
|
||||||
) {}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Метод формирования DTO с данными по заказу такси
|
|
||||||
*
|
|
||||||
* По сути, простой сеттер, позволяющий создать для обрабатываемого объекта данных экземпляр класса для более удобного взаимодействия с ним, более стандартизированного и более надежного (так как все параметры прописаны в одном месте)
|
|
||||||
* Использование self позволяет нам не зависеть от названия текущего класса, если мы захотим его переименовать
|
|
||||||
*
|
|
||||||
* @param TaxiOrderRequest $rqst запрос с валидными данными по заказу, пришедшими с фронта
|
|
||||||
* @param string $rqstMethod метод обрабатываемого запроса. Обновление или создание, например
|
|
||||||
* @return self
|
|
||||||
*/
|
|
||||||
public static function setTaxiOrderDTO(TaxiOrderRequest $rqst, string $rqstMethod): self
|
|
||||||
{
|
|
||||||
$validated = $rqst->validated();
|
|
||||||
|
|
||||||
switch ($rqstMethod) {
|
|
||||||
case 'PATCH':
|
|
||||||
return new self(
|
|
||||||
id: $validated['id'],
|
|
||||||
//При обновлении запроса логин пользователя должен оставаться неизменным
|
|
||||||
emp_login: $rqst->emp_login,
|
|
||||||
emp_phone: $validated['emp_phone'],
|
|
||||||
taxi_date: $validated['taxi_date'],
|
|
||||||
taxi_time: $validated['taxi_time'],
|
|
||||||
taxi_address_from: $validated['taxi_address_from'],
|
|
||||||
taxi_address_to: $validated['taxi_address_to'],
|
|
||||||
cancel_rqst: $validated['cancel_rqst'] ?? null,
|
|
||||||
);
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
return new self(
|
|
||||||
id: $validated['id'] ?? null,
|
|
||||||
emp_login: $validated['emp_login'],
|
|
||||||
emp_phone: $validated['emp_phone'],
|
|
||||||
taxi_date: $validated['taxi_date'],
|
|
||||||
taxi_time: $validated['taxi_time'],
|
|
||||||
taxi_address_from: $validated['taxi_address_from'],
|
|
||||||
taxi_address_to: $validated['taxi_address_to'],
|
|
||||||
cancel_rqst: $validated['cancel_rqst'] ?? null,
|
|
||||||
);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,350 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Taxi\App\Http\Controllers;
|
|
||||||
|
|
||||||
use App\Http\Controllers\Controller;
|
|
||||||
use Illuminate\Http\RedirectResponse;
|
|
||||||
use Illuminate\Http\Request;
|
|
||||||
use Illuminate\Http\Response;
|
|
||||||
use Modules\Taxi\App\Models as TaxiModels;
|
|
||||||
use App\Models\OldMagicModels;
|
|
||||||
#Гаврилов
|
|
||||||
//Rule и Validatir НЕ НУЖЕН? ЕСЛИ МЫ ВАЛИДИРУЕМ В ОТДЕЛЬОМ FORM_REQUEST
|
|
||||||
use Illuminate\Validation\Rule;
|
|
||||||
use Illuminate\Support\Facades\Validator;
|
|
||||||
use Modules\Taxi\App\Http\Requests\TaxiOrderRequest;
|
|
||||||
#Гаврилов
|
|
||||||
//КЛАСС НИЖЕ НЕ НУЖЕН, ТАК КАК ИСПОЛЬЗУЕМ СЕРВИС?
|
|
||||||
use Illuminate\Support\Facades\Mail;
|
|
||||||
use Modules\Taxi\App\Services\TaxiOrderService;
|
|
||||||
use Modules\Taxi\App\Services\TaxiMailerService;
|
|
||||||
use Modules\Taxi\App\DTO\TaxiOrderDTO;
|
|
||||||
use Modules\Taxi\App\Jobs\SendMailNewOrder;
|
|
||||||
//use Illuminate\Support\Facades\Config;
|
|
||||||
use App\Mail\Mailer;
|
|
||||||
use DateTime;
|
|
||||||
use Error;
|
|
||||||
use Exception;
|
|
||||||
use Illuminate\Support\Facades\DB;
|
|
||||||
use Modules\Taxi\App\Mail\NewOrderMail;
|
|
||||||
use Illuminate\Support\Facades\Redis;
|
|
||||||
use App\Facades\RedisNotifications;
|
|
||||||
|
|
||||||
|
|
||||||
class TaxiController extends Controller
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Конструктор
|
|
||||||
*
|
|
||||||
* @param TaxiMailerService $sendMailService сервис отправки писем
|
|
||||||
* @param TaxiOrderService $orderService сервис работы с заказами
|
|
||||||
*/
|
|
||||||
public function __construct(protected TaxiMailerService $sendMailService, protected TaxiOrderService $orderService) {
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Получаем информацию по существующему заказу
|
|
||||||
*
|
|
||||||
* @param integer $orderId идентификатор заказа
|
|
||||||
*/
|
|
||||||
public function getOrderById(int $orderId)
|
|
||||||
{
|
|
||||||
$taxiOrder = TaxiModels\TaxiMain::where('id', $orderId)->first();
|
|
||||||
|
|
||||||
return $taxiOrder;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Получение адресов офисов для подстановки в запросы такси
|
|
||||||
*
|
|
||||||
* @return array
|
|
||||||
*/
|
|
||||||
public function getOfficeAddress()
|
|
||||||
{
|
|
||||||
$taxiAddress = TaxiModels\OfficeAddress::all();
|
|
||||||
|
|
||||||
return $taxiAddress;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Получение всех активных заказов
|
|
||||||
*
|
|
||||||
* @return array
|
|
||||||
*/
|
|
||||||
public function getActiveOrders()
|
|
||||||
{
|
|
||||||
$todaydate = new DateTime();
|
|
||||||
$todaydate->setTime(00, 00, 00);
|
|
||||||
$todaydate = $todaydate->format('Y-m-d');
|
|
||||||
$orders = TaxiModels\TaxiMain::where('taxi_date', '>=', $todaydate)
|
|
||||||
->get();
|
|
||||||
|
|
||||||
return $orders;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Метод получения заказов по условиям фильтра
|
|
||||||
*
|
|
||||||
* @param Request $rqst запрос с параметрами поиска
|
|
||||||
* @return string
|
|
||||||
*/
|
|
||||||
public function getFilterOrders(Request $rqst)
|
|
||||||
{
|
|
||||||
$rqstCond = [];
|
|
||||||
foreach ($rqst->all() as $fieldName => $fieldVal) {
|
|
||||||
if (!$fieldVal) continue;
|
|
||||||
$rqstCond[] = [$fieldName, '=', $fieldVal];
|
|
||||||
}
|
|
||||||
$filterRqst = TaxiModels\TaxiMain::where($rqstCond)->get();
|
|
||||||
|
|
||||||
return json_encode($filterRqst->toArray());
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
//ГАВРИЛОВ используй транзакцию, а то создается запрос, не отправляется письмо и сообщение об ошибке
|
|
||||||
/**
|
|
||||||
* Show the form for creating a new resource.
|
|
||||||
*/
|
|
||||||
public function createTaxiOrder(TaxiOrderRequest $rqst)
|
|
||||||
{
|
|
||||||
$validateData = TaxiOrderDTO::setTaxiOrderDTO($rqst, $rqst->method());
|
|
||||||
//Пытаемся найти уже существующий запрос на этот же логин и эту же дату. Если запрос найден, возвращаем ошибку.
|
|
||||||
$searchExistsOrder = TaxiModels\TaxiMain::where([
|
|
||||||
['emp_login', '=', $validateData->emp_login],
|
|
||||||
['taxi_date', '=', $validateData->taxi_date]
|
|
||||||
])->take(1)->get();
|
|
||||||
if (count($searchExistsOrder)) {
|
|
||||||
return response()->json(['message' => "Ошибка! Заявка для сотрудника $validateData->emp_login на дату $validateData->taxi_date уже существует"], 400);
|
|
||||||
}
|
|
||||||
// $createRqstMsg;
|
|
||||||
try {
|
|
||||||
$newOrderId = (new TaxiModels\TaxiMain())->createOrder($validateData);
|
|
||||||
//$newOrderId = $this->orderService->createOrder($validateData);
|
|
||||||
$createRqstMsg = "Заявка успешно создана. Номер $newOrderId";
|
|
||||||
#Гаврилов
|
|
||||||
//ПРОВЕРЬ, ЧТОБЫ ПИСЬМО НЕ ОТПРАВЛЯЛОСЬ, ЕСЛИ ВОЗНИКАЕТ ОШИБКА НА ЭТАПЕ СОЗДАНИЯ ЗАЯВКИ
|
|
||||||
//Один метод отправки письма для всех методов работы с заказом: создание, редактирование, отмена
|
|
||||||
$this->sendMailService->sendMail(new NewOrderMail($validateData, $newOrderId));
|
|
||||||
// SendMailNewOrder::dispatch(json_decode(json_encode($validateData), true), $newOrderId)->onQueue('emails')->delay(10);
|
|
||||||
// Mail::send(new Mailer(
|
|
||||||
// [$validateData->emp_login],
|
|
||||||
// 'Создание заказа на такси',
|
|
||||||
// "Для вас создана заявка на заказ такси на дату <b>{$validateData->taxi_date}</b> и время <b>{$validateData->taxi_time}</b>. Номер заказа <b>{$newOrderId}</b>",
|
|
||||||
// #Гаврилов
|
|
||||||
// //ЗДЕСЬ НЕПОНЯТНО ОТКУДА ВЗЯТЬ ЗНАЧЕНИЕ. ОБРАТИТЬСЯ К ЛОКАЛЬНО МОДУЛЬНОМУ ENV?
|
|
||||||
// config('taxi.name_ru'),
|
|
||||||
// ));
|
|
||||||
return response()->json( ['message' => "Заявка успешно создана. Номер заявки $newOrderId"] );
|
|
||||||
} catch (\Throwable $t) {
|
|
||||||
#Гаврилов
|
|
||||||
//ОТПРАВКА СООБЩЕНИЯ С ОШИБКОЙ. ЗАТЕСТИ и отправляй response
|
|
||||||
//ОШИБКИ $T->GETmESSAGE НУЖНО ЛОГИРОВАТЬ, НО ПОЛЬЗОВАТЕЛЯМ ВЫВОДИТЬ ПРОСТО СООБЩЕНИЕ оШИБКА, ИНАЧЕ ОНИ ВИДЯТ ТЕХН ЧЕСКИЙ ТЕКСТ
|
|
||||||
//СНАЧАЛА ПЕРЕХВАТЫЙ EXCEPTION, ПОТОМ УЖЕ THOWBLE. EXCEPTION ВЫВОДИ ПОЛЬЗОВАТЕЛЮ, THORWBLE ЛОГИРУЙ ОТДЕЛЬНО
|
|
||||||
echo '<pre>'; var_dump($t->getMessage()); echo'</pre>';
|
|
||||||
echo '<pre>'; var_dump($t->getTrace()); echo'</pre>';
|
|
||||||
$createRqstMsg = "Ошибка!" . $t->getMessage() . ". Заявка не создана";
|
|
||||||
return response()->json(['message' => $createRqstMsg], 400);
|
|
||||||
}
|
|
||||||
|
|
||||||
//ГАВРИЛОВ
|
|
||||||
//ДОБАВЬ ФОРМИРОВАНИЕ ОТВЕТА ЧЕРЕЗ ГЕНЕРАЦИЮ РЕСУРСА, а не через response()
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
#Гаврилов
|
|
||||||
//ИСПОЛЬЗУЙ TaxiOrderRequest ПРИ ОБРАБОТКЕ ЗАЯВОК НА ТАКСИ
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Метод отмены запроса
|
|
||||||
*
|
|
||||||
* @param integer $rqstId идентификатор запроса
|
|
||||||
* @return string
|
|
||||||
*/
|
|
||||||
public function cancelRqst(int $rqstId): string
|
|
||||||
{
|
|
||||||
#Гаврилов
|
|
||||||
//ПОПРОБУЙ ОТПРАВИТЬ ЗАПРОС К API ЕНДПОИНТУ (ОТМЕНА ЗАПРОСА НА ТАКСИ) ЧЕРЕЗ POSTMAN С ПЕРЕДАЧЕЙ ЗАГОЛОВКА АУТЕНТИФИКАЦИИ С SANCTUM ТОКЕНОМ. ДОЛЖЕН ПРОПУСТИТЬ, А БЕЗ ЗАГОЛОВКА НЕ ДОЛЖЕН
|
|
||||||
$rqstData = $this->getOrderById($rqstId);
|
|
||||||
try {
|
|
||||||
#Гаврилов
|
|
||||||
//ПЕРЕНЕСИ ЭТУ ПРОВЕРКУ В РОУТИНГ? FINDORFAIL С РЕДИРЕКТОМ И ОШИБКОЙ
|
|
||||||
if (!$rqstData) {
|
|
||||||
throw new \Exception("Запрос $rqstId не существует");
|
|
||||||
}
|
|
||||||
if (!$this->checkRqstDate($rqstData->taxi_date)) {
|
|
||||||
throw new \Exception("Дата запроса $rqstId уже прошла");
|
|
||||||
}
|
|
||||||
} catch (\Throwable $t) {
|
|
||||||
return response()->json([
|
|
||||||
'errorMsg' => "Ошибка: $t->getMessage(). Заявка не отменена",
|
|
||||||
], 400);
|
|
||||||
}
|
|
||||||
|
|
||||||
$rqstData['cancel_rqst'] = 1;
|
|
||||||
$rqstData->save();
|
|
||||||
|
|
||||||
$this->sendMailService->sendCancelOrderMail($validateData, $newOrderId);
|
|
||||||
|
|
||||||
// Mail::send(new Mailer(
|
|
||||||
// [$rqstData->emp_login],
|
|
||||||
// 'Отмена заказа на такси',
|
|
||||||
// "Заказ номер $rqstId на дату $rqstData->taxi_date и время $rqstData->taxi_time отменен",
|
|
||||||
// $this->appName));
|
|
||||||
|
|
||||||
return redirect('/taxi/home')->with([
|
|
||||||
'notification' => "Запрос $rqstId отменен",
|
|
||||||
'notification_err' => false
|
|
||||||
]);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Проверяем находится ли дата запроса на такси в диапазоне сегодняшнего или завтрашнего дня.
|
|
||||||
*
|
|
||||||
* @param string $rqstDate дата запроса на такси
|
|
||||||
* @return boolean
|
|
||||||
*/
|
|
||||||
private function checkRqstDate($rqstDate): bool
|
|
||||||
{
|
|
||||||
$todaydate = new DateTime();
|
|
||||||
$todaydate->setTime(00, 00, 00);
|
|
||||||
|
|
||||||
return new DateTime($rqstDate) >= $todaydate;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Получаем временные промежутки
|
|
||||||
*
|
|
||||||
* @return array
|
|
||||||
*/
|
|
||||||
public function getTimePeriods()
|
|
||||||
{
|
|
||||||
$empAllData = TaxiModels\TaxiTimePeriod::select('time_period', 'is_morning_time')
|
|
||||||
->where('archive', 0)
|
|
||||||
->get();
|
|
||||||
|
|
||||||
return $empAllData;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Метод получает информацию по всем активным пользователям
|
|
||||||
*
|
|
||||||
* @return array
|
|
||||||
*/
|
|
||||||
public function getActiveUsersInfo()
|
|
||||||
{
|
|
||||||
$empAllData = OldMagicModels\CcEmp::whereIn('emp_area', ['Курск', 'Пенза'])
|
|
||||||
->whereNotIn('emp_state', ['Уволен', 'Декрет', 'Перевод на позицию', 'Перевод в ГРАН'])
|
|
||||||
->get();
|
|
||||||
foreach ($empAllData as &$empData) {
|
|
||||||
$empData['full_name'] = $empData['emp_surname'] . " " . $empData['emp_name'] . " " . $empData['emp_surname'];
|
|
||||||
$empData['extension_number'] = $empData['emp_phone'];
|
|
||||||
$empData['emp_phone'] = $empData['emp_mob_phone'];
|
|
||||||
}
|
|
||||||
|
|
||||||
return $empAllData;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Метод получает информацию по конкретному пользователю
|
|
||||||
*
|
|
||||||
* @return array
|
|
||||||
*/
|
|
||||||
public function getUserInfoByLogin(string $userLogin)
|
|
||||||
{
|
|
||||||
$empLoginData = OldMagicModels\CcEmp::where('emp_login', $userLogin)
|
|
||||||
->get();
|
|
||||||
|
|
||||||
// dd($empLoginData);
|
|
||||||
$empLoginData[0]['full_name'] = $empLoginData[0]['emp_surname'] . " " . $empLoginData[0]['emp_name'] . " " . $empLoginData[0]['emp_surname'];
|
|
||||||
$empLoginData[0]['extension_number'] = $empLoginData[0]['emp_phone'];
|
|
||||||
$empLoginData[0]['emp_phone'] = $empLoginData[0]['emp_mob_phone'];
|
|
||||||
|
|
||||||
return $empLoginData;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
#Гаврилов
|
|
||||||
//НЕ ЗАБУДЬ УДАЛИТЬ
|
|
||||||
public function testRedisMethod()
|
|
||||||
{
|
|
||||||
RedisNotifications::module('taxi')
|
|
||||||
->notifications(['текст1', 'tеуые2'])
|
|
||||||
->types(['error', 'success'])
|
|
||||||
->put();
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Обновление заявки на такси
|
|
||||||
*
|
|
||||||
* @param TaxiOrderRequest $rqst информация по измененному запросу
|
|
||||||
* @return response
|
|
||||||
*/
|
|
||||||
public function updateTaxiOrder(TaxiOrderRequest $rqst)
|
|
||||||
{
|
|
||||||
try {
|
|
||||||
DB::beginTransaction();
|
|
||||||
#Гаврилов
|
|
||||||
//ЕЩЕ РАЗ, ЧТО ЗА LOCKFORUPDATE
|
|
||||||
$orderData = TaxiModels\TaxiMain::lockForUpdate()->find($rqst->id);
|
|
||||||
$oldOrderData = TaxiModels\TaxiMain::find($rqst->id);
|
|
||||||
|
|
||||||
if (!$orderData) {
|
|
||||||
throw new Exception("Заказ номер " . $rqst->id . " не найден");
|
|
||||||
//return response()->json(['message' => 'Заказ номер ' . $rqst->id . ' не найден'], 400);
|
|
||||||
}
|
|
||||||
$editOrderData = TaxiOrderDTO::setTaxiOrderDTO($rqst, $rqst->method());
|
|
||||||
#Гаврилов
|
|
||||||
//НА ДОМАШНЕЙ СТРАНИЦЕ ПОКАЗЫВАТЬ ТОЛЬКО ТЕ ЗАПРОСЫ, ДАТА КОТОРЫХ СЕГОДНЯ ИЛИ ЗАВТРА
|
|
||||||
$dateInterval = (new DateTime())->diff(new DateTime($orderData->taxi_date));
|
|
||||||
if ($dateInterval->format('%R') == '-' && $dateInterval->format('%a') >= 1) {
|
|
||||||
throw new Exception("Нельзя менять заявки, дата которых уже прошла");
|
|
||||||
// return response()->json(['message' => 'Нельзя менять заявки, дата которых уже прошла'], 400);
|
|
||||||
}
|
|
||||||
foreach($editOrderData as $fieldName => $fieldVal) {
|
|
||||||
if (isset($orderData->$fieldName)) {
|
|
||||||
$orderData[$fieldName] = $fieldVal;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
$orderDataDiff = $orderData->getDirty();
|
|
||||||
if (empty($orderDataDiff)) {
|
|
||||||
throw new Exception("Вы не внесли никаких изменений");
|
|
||||||
//return response()->json(['message' => 'Вы не внесли никаких изменений'], 400);
|
|
||||||
}
|
|
||||||
$orderData->save();
|
|
||||||
$this->sendMailService->sendEditOrderMail($oldOrderData->toArray(), $orderDataDiff, $orderData['id']);
|
|
||||||
|
|
||||||
DB::commit();
|
|
||||||
|
|
||||||
return response()->json(['message' => 'Заявка успешно изменена'], 200);
|
|
||||||
} catch (\Exception $e) {
|
|
||||||
DB::rollBack();
|
|
||||||
|
|
||||||
return response()->json(['message' => "Ошибка." . $e->getMessage() . ". Не удалось обновить заявку"], 400);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//ГАВРИЛОВ. ДОБАВЬ БЛОКИРОВКУ В МОМЕНТ ПОЛУЧЕНИЯ ДАННЫХ ПО РЕДАКТИРУЕМОМУ ЗАПРОСУ И ДО МОМЕНТА ЕГО ОБНОВЛЕНИЯ. ЛИБО ЧЕРЕЗ УСТАНОВКУ УРОВНЯ ИЗОЛЯЦИИ
|
|
||||||
|
|
||||||
//ГАВРИЛОВ. ДОБАВЬ В DTO НЕ ОБНУЛЕНИЕ НЕНУЖНЫХД ДАННЫХ, А ПРИНУДИТЕЬНАЯ ИХ УСТАНОВКА. НАПРИМЕР ПРИ ОБНОВЛЕНИИ ЗАПРОСА НА ТАКСИ, УСТАНАВЛИВАТЬ EMP_LOGIN = ПЕРЕДАННОМУ ЗНАЧЕНИЮ, ВЗЯТОМУ ИЗ СУЩЕСТВУЮЩЕГО ЗАПРОСА.
|
|
||||||
|
|
||||||
//Обновляем текущую модель, добавляя туда измененные значения, затем проверяем есть ли измененные значения через getDirty()
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//ГАВРИЛОВ. убрать поле Запрос актуален? и при отмене заявки убирать ее из таблицы Активные заявки
|
|
||||||
|
|
||||||
//гаврилов. СДЕЛАТЬ ВОЗМОЖНОСТЬ ВЫГРУЗИТЬ В ОТЧЕТНОСТЬ ВСЕ ИМЕЮЩИЕСЯ ЗАЯВКИ В CSV ФАЙЛ.
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,52 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Taxi\App\Http\Middleware;
|
|
||||||
|
|
||||||
use Closure;
|
|
||||||
use Illuminate\Http\Request;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Блокировщик работы с заявками на такси в случае слишком ранееЙ, слишком поздней работы с ресурсом
|
|
||||||
*
|
|
||||||
* Решил блочить рабоут приложения в части работы с заявками в очень ранее или очень позднее время. Это связано с нежеланием валидировать при создании или редактировании заявки передаваемый временной промежуток. Например, если текущее время 22:15, а заявка созается на 22:00.
|
|
||||||
*/
|
|
||||||
class CheckTimeRqstAvailability
|
|
||||||
{
|
|
||||||
public function handle(Request $request, Closure $next)
|
|
||||||
{
|
|
||||||
#Гаврилов
|
|
||||||
//ПОМЕНЯЙ НА 21 НА РЕЛИЗЕ
|
|
||||||
$maxRqstTime = 23;
|
|
||||||
$minRqstTime = 7;
|
|
||||||
$timezone = new \DateTimeZone('Europe/Moscow');
|
|
||||||
$timeNow = (new \DateTime())->setTimezone($timezone);
|
|
||||||
$timeMax = (new \DateTime())->setTimezone($timezone);
|
|
||||||
$timeMin = (new \DateTime())->setTimezone($timezone);
|
|
||||||
$timeMax->setTime($maxRqstTime, 00, 00);
|
|
||||||
$timeMin->setTime($minRqstTime, 00, 00);
|
|
||||||
|
|
||||||
#Гаврилов
|
|
||||||
//ПОМЕНЯЙ
|
|
||||||
if (!($timeNow > $timeMin && $timeNow < $timeMax)) {
|
|
||||||
//if (!($timeNow > $timeMin && $timeNow > $timeMax)) {
|
|
||||||
$errMsg = "Работа с заявками на такси заблокирована с $maxRqstTime:00 по 0$minRqstTime:00";
|
|
||||||
#Гаврилов
|
|
||||||
//ПОДУМАТЬ КАКОЙ КОД ЛУЧШЕ ВЕРНУТЬ
|
|
||||||
//Метод expectsJson позволяет определить вызывается ли api роут через ajax/fetch, либо web route.
|
|
||||||
if ($request->expectsJson()) {
|
|
||||||
return response()->json([
|
|
||||||
'errorMsg' => $errMsg
|
|
||||||
], 400);
|
|
||||||
} else {
|
|
||||||
#Гаврилов
|
|
||||||
//ПРОВЕРЬ КОГДА РЕАЛИЗУЕШЬ ОПОВЕЩЕНИЯ
|
|
||||||
return redirect('/taxi/home')->with([
|
|
||||||
'notification' => $errMsg,
|
|
||||||
'notification_err' => true
|
|
||||||
]);
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
return $next($request);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,109 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Taxi\App\Http\Requests;
|
|
||||||
|
|
||||||
use Illuminate\Foundation\Http\FormRequest;
|
|
||||||
use App\Models\OldMagicModels;
|
|
||||||
use Illuminate\Validation\Rule;
|
|
||||||
use DateTime;
|
|
||||||
|
|
||||||
class TaxiOrderRequest extends FormRequest
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Действия перед валидацией.
|
|
||||||
*
|
|
||||||
* @return void
|
|
||||||
*/
|
|
||||||
protected function prepareForValidation()
|
|
||||||
{
|
|
||||||
//echo '<pre>'; var_dump($this->all()); echo'</pre>';
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Get the validation rules that apply to the request.
|
|
||||||
*/
|
|
||||||
public function rules(): array
|
|
||||||
{
|
|
||||||
//Получаем список активных пользователей
|
|
||||||
$empActiveLogins = OldMagicModels\CcEmp::select('emp_login')
|
|
||||||
->whereNotIn('emp_state', ['Уволен', 'Декрет'])
|
|
||||||
->get()
|
|
||||||
->toArray();
|
|
||||||
//Правила валидации
|
|
||||||
$validationRules = [
|
|
||||||
'id' => [
|
|
||||||
'int'
|
|
||||||
],
|
|
||||||
'taxi_date' => [
|
|
||||||
'date_format:Y-m-d',
|
|
||||||
//Заказ можно создать только на сегодняшний или завтрашний день
|
|
||||||
Rule::in([
|
|
||||||
(new DateTime())->format('Y-m-d'),
|
|
||||||
(new DateTime())->modify('+1 day')->format('Y-m-d')
|
|
||||||
]),
|
|
||||||
],
|
|
||||||
'taxi_time' => [
|
|
||||||
'required',
|
|
||||||
'string',
|
|
||||||
'regex:/^[0-9]{2}:[0-9]{2}$/', //время в формате 00:00
|
|
||||||
],
|
|
||||||
'cancel_rqst' => 'boolean',
|
|
||||||
'emp_phone' => [
|
|
||||||
'required',
|
|
||||||
'int',
|
|
||||||
'regex:/^(7|8)?[0-9]{10}$/'
|
|
||||||
],
|
|
||||||
'emp_login' => [
|
|
||||||
$validationRules['emp_login'] = [
|
|
||||||
'required',
|
|
||||||
'string',
|
|
||||||
'regex:/^[a-z\-]+[0-9]*$/',
|
|
||||||
//Логины ищем среди активных логинов на текущий момент
|
|
||||||
Rule::in(
|
|
||||||
array_map(fn($el) => $el['emp_login'], $empActiveLogins)
|
|
||||||
)
|
|
||||||
],
|
|
||||||
],
|
|
||||||
'taxi_address_from' => [
|
|
||||||
'required',
|
|
||||||
'string',
|
|
||||||
'max: 500'
|
|
||||||
],
|
|
||||||
'taxi_address_to' => [
|
|
||||||
'required',
|
|
||||||
'string',
|
|
||||||
'max: 500'
|
|
||||||
]
|
|
||||||
];
|
|
||||||
|
|
||||||
//Во время создания запроса поле ID не валидируется
|
|
||||||
if ($this->isMethod('POST')){
|
|
||||||
$validationRules['id'] = [
|
|
||||||
'prohibited'
|
|
||||||
];
|
|
||||||
}
|
|
||||||
|
|
||||||
return $validationRules;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Determine if the user is authorized to make this request.
|
|
||||||
*/
|
|
||||||
public function authorize(): bool
|
|
||||||
{
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Переопределение сообщений об ошибках валидации
|
|
||||||
*
|
|
||||||
* @return array
|
|
||||||
*/
|
|
||||||
public function messages(): array
|
|
||||||
{
|
|
||||||
return [
|
|
||||||
'taxi_date.in' => 'Заявку на такси можно завести только на сегодняшний или завтрашний день'
|
|
||||||
];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,40 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Taxi\App\Jobs;
|
|
||||||
|
|
||||||
use Illuminate\Bus\Queueable;
|
|
||||||
use Illuminate\Queue\SerializesModels;
|
|
||||||
use Illuminate\Queue\InteractsWithQueue;
|
|
||||||
use Illuminate\Contracts\Queue\ShouldQueue;
|
|
||||||
use Illuminate\Foundation\Bus\Dispatchable;
|
|
||||||
use Illuminate\Support\Facades\Mail;
|
|
||||||
use App\Mail\Mailer;
|
|
||||||
use App\Mail\BaseMailerObj;
|
|
||||||
use App\Job\BaseJob;
|
|
||||||
use Error;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Джоба размещения задачи на отправку писем по такси
|
|
||||||
*/
|
|
||||||
class TaxiMailJob extends BaseJob
|
|
||||||
{
|
|
||||||
use Dispatchable, InteractsWithQueue, Queueable, SerializesModels;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Create a new job instance.
|
|
||||||
*/
|
|
||||||
public function __construct(public BaseMailerObj $jobData)
|
|
||||||
{
|
|
||||||
//
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Execute the job.
|
|
||||||
*/
|
|
||||||
public function handle(): void
|
|
||||||
{
|
|
||||||
Mail::send(new Mailer(
|
|
||||||
$this->jobData
|
|
||||||
));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,32 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Taxi\App\Mail;
|
|
||||||
use App\Mail\BaseMailerObj;
|
|
||||||
use Modules\Taxi\App\DTO\TaxiOrderDTO;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Базовый класс отправки письма по заказу такси. Объявляет обязательный к реализации метод формирования данных для отправки.
|
|
||||||
*/
|
|
||||||
abstract class BaseTaxiMail
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Undocumented function
|
|
||||||
*
|
|
||||||
* @param TaxiOrderDTO $orderData
|
|
||||||
* @param integer|null $orderId идентификатор заказа такси
|
|
||||||
*/
|
|
||||||
public function __construct(
|
|
||||||
public TaxiOrderDTO $orderData,
|
|
||||||
public ?int $orderId
|
|
||||||
){
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Метод формирует объект с данными письма для передачи в джобу
|
|
||||||
*
|
|
||||||
* @return BaseMailerObj базовый класс объекта параметров письма для мейлера
|
|
||||||
*/
|
|
||||||
abstract public function prepareDataForMail(): BaseMailerObj;
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -1,39 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Taxi\App\Mail;
|
|
||||||
|
|
||||||
use Modules\Taxi\App\DTO\TaxiOrderDTO;
|
|
||||||
use App\Mail\BaseMailerObj;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Класс формирования объекта с данными для передачи в джобу отправки письма. Наследует базовый класс отправки письма по такси, где объвляется обязательный метод
|
|
||||||
*/
|
|
||||||
class NewOrderMail extends BaseTaxiMail
|
|
||||||
{
|
|
||||||
public function __construct(
|
|
||||||
public TaxiOrderDTO $orderData,
|
|
||||||
public ?int $orderId)
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Метод подготавливает данные письма для передачи в джобу
|
|
||||||
*
|
|
||||||
* @return BaseMailerObj
|
|
||||||
*/
|
|
||||||
public function prepareDataForMail(): BaseMailerObj
|
|
||||||
{
|
|
||||||
return new BaseMailerObj(
|
|
||||||
[$this->orderData->emp_login],
|
|
||||||
"Создана заявка на такси",
|
|
||||||
"Для вас создана заявка на такси № {$this->orderId}:
|
|
||||||
<ul>
|
|
||||||
<li><b>Дата:</b> {$this->orderData->taxi_date}</li>
|
|
||||||
<li><b>Время:</b> {$this->orderData->taxi_time}</li>
|
|
||||||
<li><b>Откуда:</b> {$this->orderData->taxi_address_from}</li>
|
|
||||||
<li><b>Куда:</b> {$this->orderData->taxi_address_to}</li>
|
|
||||||
</ul>",
|
|
||||||
config('taxi.name_ru'),
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,13 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Taxi\App\Models;
|
|
||||||
|
|
||||||
use Illuminate\Database\Eloquent\Model;
|
|
||||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
|
||||||
use Modules\Taxi\Database\factories\OfficeAddressFactory;
|
|
||||||
|
|
||||||
class OfficeAddress extends Model
|
|
||||||
{
|
|
||||||
protected $table = 'office_address';
|
|
||||||
protected $guarded = [];
|
|
||||||
}
|
|
||||||
@@ -1,104 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Taxi\App\Models;
|
|
||||||
|
|
||||||
use Illuminate\Database\Eloquent\Model;
|
|
||||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
|
||||||
use Modules\Taxi\Database\factories\TaxiMainFactory;
|
|
||||||
//use Spatie\Activitylog\Traits\LogsActivity;
|
|
||||||
// use Spatie\Activitylog\LogOptions;
|
|
||||||
use App\Traits\LogsActivity_custom;
|
|
||||||
use Modules\Taxi\App\DTO\TaxiOrderDTO;
|
|
||||||
use App\Enums\LogBusinessEvents;
|
|
||||||
|
|
||||||
class TaxiMain extends Model
|
|
||||||
{
|
|
||||||
//use LogsActivity;
|
|
||||||
use LogsActivity_custom;
|
|
||||||
|
|
||||||
protected $table = 'taxi_main';
|
|
||||||
protected $guarded = [];
|
|
||||||
|
|
||||||
// protected $activityCustomProperties = [
|
|
||||||
// 'emp_login' => 'dgavrilov',
|
|
||||||
// ];
|
|
||||||
|
|
||||||
// public function getActivitylogOptions(): LogOptions
|
|
||||||
// {
|
|
||||||
// return LogOptions::defaults()
|
|
||||||
// ->logAll()
|
|
||||||
// ->logOnlyDirty()
|
|
||||||
// ->useLogName('Taxi')
|
|
||||||
// ->logExcept(['created_at', 'updated_at']);
|
|
||||||
|
|
||||||
// }
|
|
||||||
|
|
||||||
public function __construct()
|
|
||||||
{
|
|
||||||
parent::__construct();
|
|
||||||
//В трейте LogsActivity_custom это свойство отвечает за название приложения, события в котором логируются. Оно записывается в поле activity_log.log_name
|
|
||||||
$this->logActivity_custom__name = 'Taxi';
|
|
||||||
$this->addCustomLogProperties(['custom__test' => 'test']);
|
|
||||||
}
|
|
||||||
|
|
||||||
//ГАВРИЛОВ. сделай метод не статическим
|
|
||||||
public static function getFieldsTitle()
|
|
||||||
{
|
|
||||||
return [
|
|
||||||
'id' => 'Номер запроса',
|
|
||||||
'emp_login' => 'Логин сотрудника',
|
|
||||||
'emp_phone' => 'Телефон сотрудника',
|
|
||||||
'taxi_date' => 'Дата заказа',
|
|
||||||
'taxi_time' => 'Время заказа',
|
|
||||||
'taxi_address_from' => 'Адрес откуда',
|
|
||||||
'taxi_address_to' => 'Адрес куда',
|
|
||||||
'cancel_rqst' => 'Запрос отменен',
|
|
||||||
];
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
public function createOrder(TaxiOrderDTO $orderData): string
|
|
||||||
{
|
|
||||||
//ГАВРИЛОВ. проверь будет ли возвращаться ошибка без try catch
|
|
||||||
// try {
|
|
||||||
|
|
||||||
$this->logBusinessEvent(LogBusinessEvents::Create);
|
|
||||||
$newOrder = $this->create(
|
|
||||||
[
|
|
||||||
'emp_login' => $orderData->emp_login,
|
|
||||||
'taxi_date' => $orderData->taxi_date,
|
|
||||||
'emp_phone' => $orderData->emp_phone,
|
|
||||||
'taxi_time' => $orderData->taxi_time,
|
|
||||||
'taxi_address_from' => $orderData->taxi_address_from,
|
|
||||||
'taxi_address_to' => $orderData->taxi_address_to
|
|
||||||
]
|
|
||||||
);
|
|
||||||
return $newOrder->id;
|
|
||||||
// } catch (\Exception $e) {
|
|
||||||
// return $e->getMessage();
|
|
||||||
// }
|
|
||||||
}
|
|
||||||
|
|
||||||
// /**
|
|
||||||
// * @return string Метод нужен для переопределения параметра трейта. Простое переопределение вызывает конфликт
|
|
||||||
// */
|
|
||||||
//protected $logActivity_custom__name = 'Taxi';
|
|
||||||
// public function getLogName(): string
|
|
||||||
// {
|
|
||||||
// return 'Taxi';
|
|
||||||
// }
|
|
||||||
|
|
||||||
//protected $logActivity_custom__name;
|
|
||||||
|
|
||||||
// public function getActivitylogOptions(): LogOptions
|
|
||||||
// {
|
|
||||||
// //Через метод default() получаем параметры класса логирования по умолчанию. Ниже можем их переопределять в зависимости от специфики работы с моделью
|
|
||||||
// $logOptions = LogOptions::defaults()
|
|
||||||
// ->logOnly(['*']); //Устанавиваем список логируемых данных (полей модели), либо, как в этом случае, логируем все поля
|
|
||||||
// //->logExcept(['created_at', 'updated_at']) //Не логируем поля изменения и создания записи в ЛЮБОМ случае
|
|
||||||
// //->logOnlyDirty(); //Логируем только те поля, которые были изменены
|
|
||||||
// $logOptions->logName = 'Taxi'; //Устанавливаем значение для имени приложения
|
|
||||||
|
|
||||||
// return $logOptions;
|
|
||||||
// }
|
|
||||||
}
|
|
||||||
@@ -1,14 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Taxi\App\Models;
|
|
||||||
|
|
||||||
use Illuminate\Database\Eloquent\Model;
|
|
||||||
|
|
||||||
class TaxiTimePeriod extends Model
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* The attributes that are mass assignable.
|
|
||||||
*/
|
|
||||||
protected $guarded = [];
|
|
||||||
|
|
||||||
}
|
|
||||||
@@ -1,68 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Taxi\App\Providers;
|
|
||||||
|
|
||||||
use Illuminate\Support\Facades\Route;
|
|
||||||
use Illuminate\Foundation\Support\Providers\RouteServiceProvider as ServiceProvider;
|
|
||||||
|
|
||||||
class RouteServiceProvider extends ServiceProvider
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* The module namespace to assume when generating URLs to actions.
|
|
||||||
*/
|
|
||||||
protected string $moduleNamespace = 'Modules\Taxi\App\Http\Controllers';
|
|
||||||
protected $middleware_checkTimeRqstAvailable = [Modules\Taxi\Http\Middleware\CheckTimeRqstAvailability::class];
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Called before routes are registered.
|
|
||||||
*
|
|
||||||
* Register any model bindings or pattern based filters.
|
|
||||||
*/
|
|
||||||
public function boot(): void
|
|
||||||
{
|
|
||||||
parent::boot();
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Define the routes for the application.
|
|
||||||
*/
|
|
||||||
public function map(): void
|
|
||||||
{
|
|
||||||
$this->mapApiRoutes();
|
|
||||||
|
|
||||||
$this->mapWebRoutes();
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Define the "web" routes for the application.
|
|
||||||
*
|
|
||||||
* These routes all receive session state, CSRF protection, etc.
|
|
||||||
*/
|
|
||||||
protected function mapWebRoutes(): void
|
|
||||||
{
|
|
||||||
Route::middleware('web')
|
|
||||||
->namespace($this->moduleNamespace)
|
|
||||||
->group(module_path('Taxi', '/routes/web.php'));
|
|
||||||
|
|
||||||
Route::prefix('taxi')
|
|
||||||
->middleware('web')
|
|
||||||
->group(base_path('Modules/Taxi/routes/web.php'));
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Define the "api" routes for the application.
|
|
||||||
*
|
|
||||||
* These routes are typically stateless.
|
|
||||||
*/
|
|
||||||
protected function mapApiRoutes(): void
|
|
||||||
{
|
|
||||||
Route::prefix('api')
|
|
||||||
->middleware('api')
|
|
||||||
->namespace($this->moduleNamespace)
|
|
||||||
->group(module_path('Taxi', '/routes/api.php'));
|
|
||||||
|
|
||||||
Route::prefix('taxi')
|
|
||||||
->middleware('api')
|
|
||||||
->group(base_path('Modules/Taxi/routes/api.php'));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,29 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Taxi\App\Providers;
|
|
||||||
|
|
||||||
use Illuminate\Support\ServiceProvider;
|
|
||||||
use Modules\Taxi\App\Services\TaxiMailerService;
|
|
||||||
|
|
||||||
class TaxiMailerProvider extends ServiceProvider
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Register the service provider.
|
|
||||||
*/
|
|
||||||
public function register(): void
|
|
||||||
{
|
|
||||||
#Гаврилов
|
|
||||||
//ЗАЧЕМ В КАЧЕСТВЕ АРГУМЕНТА ПЕРЕЛАЕТСЯ $app?
|
|
||||||
$this->app->bind(TaxiMailerService::class, function($app) {
|
|
||||||
return new TaxiMailerService();
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Get the services provided by the provider.
|
|
||||||
*/
|
|
||||||
public function provides(): array
|
|
||||||
{
|
|
||||||
return [];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,27 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Taxi\App\Providers;
|
|
||||||
|
|
||||||
use Illuminate\Support\ServiceProvider;
|
|
||||||
use Modules\Taxi\App\Services\TaxiOrderService;
|
|
||||||
|
|
||||||
class TaxiOrderProvider extends ServiceProvider
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Register the service provider.
|
|
||||||
*/
|
|
||||||
public function register(): void
|
|
||||||
{
|
|
||||||
$this->app->bind(TaxiOrderService::class, function($app) {
|
|
||||||
return new TaxiOrderService();
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Get the services provided by the provider.
|
|
||||||
*/
|
|
||||||
public function provides(): array
|
|
||||||
{
|
|
||||||
return [];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,30 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Taxi\App\Providers;
|
|
||||||
|
|
||||||
use Illuminate\Support\ServiceProvider;
|
|
||||||
use Modules\Taxi\App\Console\SendOrdersToTaxiCommand;
|
|
||||||
|
|
||||||
class TaxiScheduleProvider extends ServiceProvider
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Register the service provider.
|
|
||||||
*/
|
|
||||||
public function register(): void
|
|
||||||
{
|
|
||||||
// Регистрируем команду в системе
|
|
||||||
if ($this->app->runningInConsole()) {
|
|
||||||
$this->commands([
|
|
||||||
SendOrdersToTaxiCommand::class, // ✅ Теперь Laravel знает о команде
|
|
||||||
]);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Get the services provided by the provider.
|
|
||||||
*/
|
|
||||||
public function provides(): array
|
|
||||||
{
|
|
||||||
return [];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,114 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Taxi\App\Providers;
|
|
||||||
|
|
||||||
use Illuminate\Support\Facades\Blade;
|
|
||||||
use Illuminate\Support\ServiceProvider;
|
|
||||||
|
|
||||||
class TaxiServiceProvider extends ServiceProvider
|
|
||||||
{
|
|
||||||
protected string $moduleName = 'Taxi';
|
|
||||||
|
|
||||||
protected string $moduleNameLower = 'taxi';
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Boot the application events.
|
|
||||||
*/
|
|
||||||
public function boot(): void
|
|
||||||
{
|
|
||||||
$this->registerCommands();
|
|
||||||
$this->registerCommandSchedules();
|
|
||||||
$this->registerTranslations();
|
|
||||||
$this->registerConfig();
|
|
||||||
$this->registerViews();
|
|
||||||
$this->loadMigrationsFrom(module_path($this->moduleName, 'Database/migrations'));
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Register the service provider.
|
|
||||||
*/
|
|
||||||
public function register(): void
|
|
||||||
{
|
|
||||||
$this->app->register(RouteServiceProvider::class);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Register commands in the format of Command::class
|
|
||||||
*/
|
|
||||||
protected function registerCommands(): void
|
|
||||||
{
|
|
||||||
// $this->commands([]);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Register command Schedules.
|
|
||||||
*/
|
|
||||||
protected function registerCommandSchedules(): void
|
|
||||||
{
|
|
||||||
// $this->app->booted(function () {
|
|
||||||
// $schedule = $this->app->make(Schedule::class);
|
|
||||||
// $schedule->command('inspire')->hourly();
|
|
||||||
// });
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Register translations.
|
|
||||||
*/
|
|
||||||
public function registerTranslations(): void
|
|
||||||
{
|
|
||||||
$langPath = resource_path('lang/modules/'.$this->moduleNameLower);
|
|
||||||
|
|
||||||
if (is_dir($langPath)) {
|
|
||||||
$this->loadTranslationsFrom($langPath, $this->moduleNameLower);
|
|
||||||
$this->loadJsonTranslationsFrom($langPath);
|
|
||||||
} else {
|
|
||||||
$this->loadTranslationsFrom(module_path($this->moduleName, 'lang'), $this->moduleNameLower);
|
|
||||||
$this->loadJsonTranslationsFrom(module_path($this->moduleName, 'lang'));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Register config.
|
|
||||||
*/
|
|
||||||
protected function registerConfig(): void
|
|
||||||
{
|
|
||||||
$this->publishes([module_path($this->moduleName, 'config/config.php') => config_path($this->moduleNameLower.'.php')], 'config');
|
|
||||||
$this->mergeConfigFrom(module_path($this->moduleName, 'config/config.php'), $this->moduleNameLower);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Register views.
|
|
||||||
*/
|
|
||||||
public function registerViews(): void
|
|
||||||
{
|
|
||||||
$viewPath = resource_path('views/modules/'.$this->moduleNameLower);
|
|
||||||
$sourcePath = module_path($this->moduleName, 'resources/views');
|
|
||||||
|
|
||||||
$this->publishes([$sourcePath => $viewPath], ['views', $this->moduleNameLower.'-module-views']);
|
|
||||||
|
|
||||||
$this->loadViewsFrom(array_merge($this->getPublishableViewPaths(), [$sourcePath]), $this->moduleNameLower);
|
|
||||||
|
|
||||||
$componentNamespace = str_replace('/', '\\', config('modules.namespace').'\\'.$this->moduleName.'\\'.config('modules.paths.generator.component-class.path'));
|
|
||||||
Blade::componentNamespace($componentNamespace, $this->moduleNameLower);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Get the services provided by the provider.
|
|
||||||
*/
|
|
||||||
public function provides(): array
|
|
||||||
{
|
|
||||||
return [];
|
|
||||||
}
|
|
||||||
|
|
||||||
private function getPublishableViewPaths(): array
|
|
||||||
{
|
|
||||||
$paths = [];
|
|
||||||
foreach (config('view.paths') as $path) {
|
|
||||||
if (is_dir($path.'/modules/'.$this->moduleNameLower)) {
|
|
||||||
$paths[] = $path.'/modules/'.$this->moduleNameLower;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return $paths;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,27 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Taxi\App\Services;
|
|
||||||
|
|
||||||
use Modules\Taxi\App\Mail\BaseTaxiMail;
|
|
||||||
use Modules\Taxi\App\Jobs\TaxiMailJob;
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Сервис отправки письма. Отвечает за формирование всех писем приложения Такси
|
|
||||||
*/
|
|
||||||
class TaxiMailerService
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Единый метод отправки всех писем по такси
|
|
||||||
*
|
|
||||||
* @param BaseTaxiMail $taxiMailClass
|
|
||||||
* @return void
|
|
||||||
*/
|
|
||||||
public function sendMail(BaseTaxiMail $taxiMailClass)
|
|
||||||
{
|
|
||||||
#Гаврилов
|
|
||||||
//delay наверное не нужен?
|
|
||||||
//Вызов джобы для отправки письма
|
|
||||||
TaxiMailJob::dispatch($taxiMailClass->prepareDataForMail())->onQueue('emails')->delay(5);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,42 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Taxi\App\Services;
|
|
||||||
|
|
||||||
use Modules\Taxi\App\Models as TaxiModels;
|
|
||||||
use Modules\Taxi\App\DTO\TaxiOrderDTO;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Сервис работы с заказами такси
|
|
||||||
*/
|
|
||||||
class TaxiOrderService
|
|
||||||
{
|
|
||||||
public function __construct()
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Метод создания заказа на такси
|
|
||||||
*
|
|
||||||
* @param TaxiOrderDTO $orderData объект с данными по заказу
|
|
||||||
* @return int идентификатор созданного заказа
|
|
||||||
*/
|
|
||||||
public function createOrder(TaxiOrderDTO $orderData): string
|
|
||||||
{
|
|
||||||
//ГАВРИЛОВ. проверь будет ли возвращаться ошибка без try catch
|
|
||||||
// try {
|
|
||||||
$newOrder = TaxiModels\TaxiMain::create(
|
|
||||||
[
|
|
||||||
'emp_login' => $orderData->emp_login,
|
|
||||||
'taxi_date' => $orderData->taxi_date,
|
|
||||||
'emp_phone' => $orderData->emp_phone,
|
|
||||||
'taxi_time' => $orderData->taxi_time,
|
|
||||||
'taxi_address_from' => $orderData->taxi_address_from,
|
|
||||||
'taxi_address_to' => $orderData->taxi_address_to
|
|
||||||
]
|
|
||||||
);
|
|
||||||
return $newOrder->id;
|
|
||||||
// } catch (\Exception $e) {
|
|
||||||
// return $e->getMessage();
|
|
||||||
// }
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,16 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Taxi\Database\Seeders;
|
|
||||||
|
|
||||||
use Illuminate\Database\Seeder;
|
|
||||||
|
|
||||||
class TaxiDatabaseSeeder extends Seeder
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Run the database seeds.
|
|
||||||
*/
|
|
||||||
public function run(): void
|
|
||||||
{
|
|
||||||
// $this->call([]);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,33 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
use Illuminate\Database\Migrations\Migration;
|
|
||||||
use Illuminate\Database\Schema\Blueprint;
|
|
||||||
use Illuminate\Support\Facades\Schema;
|
|
||||||
|
|
||||||
return new class extends Migration
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Run the migrations.
|
|
||||||
*/
|
|
||||||
public function up(): void
|
|
||||||
{
|
|
||||||
Schema::create('taxi_main', function (Blueprint $table) {
|
|
||||||
$table->id();
|
|
||||||
$table->string('emp_login', 30)->comment('логин сотрудника кто поедет');
|
|
||||||
$table->string('emp_phone', 15)->comment('телефон сотрудника');
|
|
||||||
$table->date('taxi_date')->comment('дата заказа такси');
|
|
||||||
$table->time('taxi_time')->comment('время заказа такси');
|
|
||||||
$table->string('taxi_address', 500)->comment('адрес заказа такси');
|
|
||||||
$table->boolean('archive')->default(0);
|
|
||||||
$table->timestamps();
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Reverse the migrations.
|
|
||||||
*/
|
|
||||||
public function down(): void
|
|
||||||
{
|
|
||||||
Schema::dropIfExists('taxi_main');
|
|
||||||
}
|
|
||||||
};
|
|
||||||
@@ -1,34 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
use Illuminate\Database\Migrations\Migration;
|
|
||||||
use Illuminate\Database\Schema\Blueprint;
|
|
||||||
use Illuminate\Support\Facades\Schema;
|
|
||||||
|
|
||||||
return new class extends Migration
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Run the migrations.
|
|
||||||
*/
|
|
||||||
public function up(): void
|
|
||||||
{
|
|
||||||
Schema::create('taxi_hist', function (Blueprint $table) {
|
|
||||||
$table->id('hist_id');
|
|
||||||
$table->integer('id_change_row')->default(NULL)->comment('id изменяемой строки');
|
|
||||||
$table->string('table_name', 50)->default(NULL)->comment('имя изменямой таблицы');
|
|
||||||
$table->string('field_name', 50)->default(NULL)->comment('имя изменяемого поля');
|
|
||||||
$table->string('emp_login', 50)->default(NULL)->comment('логин сотрудника, внесшего изменение');
|
|
||||||
$table->string('value_before', 500)->default(NULL)->comment('значение ДО');
|
|
||||||
$table->string('value_after', 500)->default(NULL)->comment('значение ПОСЛЕ');
|
|
||||||
$table->timestamps();
|
|
||||||
$table->comment('Таблица с историей изменений по процессу Заказ такси');
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Reverse the migrations.
|
|
||||||
*/
|
|
||||||
public function down(): void
|
|
||||||
{
|
|
||||||
Schema::dropIfExists('taxi_hist');
|
|
||||||
}
|
|
||||||
};
|
|
||||||
@@ -1,30 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
use Illuminate\Database\Migrations\Migration;
|
|
||||||
use Illuminate\Database\Schema\Blueprint;
|
|
||||||
use Illuminate\Support\Facades\Schema;
|
|
||||||
|
|
||||||
return new class extends Migration
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Run the migrations.
|
|
||||||
*/
|
|
||||||
public function up(): void
|
|
||||||
{
|
|
||||||
Schema::create('taxi_time_period', function (Blueprint $table) {
|
|
||||||
$table->id();
|
|
||||||
$table->string('time_period', 5)->comment('Временнoй промежуток');
|
|
||||||
$table->boolean('archive')->default(0)->comment('Актуальность');
|
|
||||||
$table->timestamps();
|
|
||||||
$table->comment('Временные промежутки для заказа такси');
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Reverse the migrations.
|
|
||||||
*/
|
|
||||||
public function down(): void
|
|
||||||
{
|
|
||||||
Schema::dropIfExists('taxi_time_period');
|
|
||||||
}
|
|
||||||
};
|
|
||||||
@@ -1,24 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
use Illuminate\Database\Migrations\Migration;
|
|
||||||
use Illuminate\Database\Schema\Blueprint;
|
|
||||||
use Illuminate\Support\Facades\Schema;
|
|
||||||
|
|
||||||
return new class extends Migration
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Run the migrations.
|
|
||||||
*/
|
|
||||||
public function up(): void
|
|
||||||
{
|
|
||||||
Schema::rename('taxi_time_period', 'taxi_time_periods');
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Reverse the migrations.
|
|
||||||
*/
|
|
||||||
public function down(): void
|
|
||||||
{
|
|
||||||
//
|
|
||||||
}
|
|
||||||
};
|
|
||||||
@@ -1,26 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
use Illuminate\Database\Migrations\Migration;
|
|
||||||
use Illuminate\Database\Schema\Blueprint;
|
|
||||||
use Illuminate\Support\Facades\Schema;
|
|
||||||
|
|
||||||
return new class extends Migration
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Run the migrations.
|
|
||||||
*/
|
|
||||||
public function up(): void
|
|
||||||
{
|
|
||||||
Schema::table('taxi_main', function (Blueprint $table){
|
|
||||||
$table->string('taxi_time', 8)->change();
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Reverse the migrations.
|
|
||||||
*/
|
|
||||||
public function down(): void
|
|
||||||
{
|
|
||||||
//
|
|
||||||
}
|
|
||||||
};
|
|
||||||
@@ -1,28 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
use Illuminate\Database\Migrations\Migration;
|
|
||||||
use Illuminate\Database\Schema\Blueprint;
|
|
||||||
use Illuminate\Support\Facades\Schema;
|
|
||||||
|
|
||||||
return new class extends Migration
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Run the migrations.
|
|
||||||
*/
|
|
||||||
public function up(): void
|
|
||||||
{
|
|
||||||
Schema::table('taxi_main', function (Blueprint $table) {
|
|
||||||
//$table->renameColumn('archive', 'cancel_rqst');
|
|
||||||
$table->string('taxi_time', 6)->change();
|
|
||||||
});
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Reverse the migrations.
|
|
||||||
*/
|
|
||||||
public function down(): void
|
|
||||||
{
|
|
||||||
//
|
|
||||||
}
|
|
||||||
};
|
|
||||||
@@ -1,27 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
use Illuminate\Database\Migrations\Migration;
|
|
||||||
use Illuminate\Database\Schema\Blueprint;
|
|
||||||
use Illuminate\Support\Facades\Schema;
|
|
||||||
|
|
||||||
return new class extends Migration
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Run the migrations.
|
|
||||||
*/
|
|
||||||
public function up(): void
|
|
||||||
{
|
|
||||||
Schema::table('taxi_main', function (Blueprint $table) {
|
|
||||||
$table->boolean('cancel_rqst')->default(0)->after('archive');
|
|
||||||
$table->dropColumn('archive');
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Reverse the migrations.
|
|
||||||
*/
|
|
||||||
public function down(): void
|
|
||||||
{
|
|
||||||
//
|
|
||||||
}
|
|
||||||
};
|
|
||||||
@@ -1,39 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
use Illuminate\Database\Migrations\Migration;
|
|
||||||
use Illuminate\Database\Schema\Blueprint;
|
|
||||||
use Illuminate\Support\Facades\Schema;
|
|
||||||
|
|
||||||
return new class extends Migration
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Run the migrations.
|
|
||||||
*/
|
|
||||||
public function up(): void
|
|
||||||
{
|
|
||||||
// Schema::table('taxi_main', function(Blueprint $table) {
|
|
||||||
// $table->renameColumn('taxi_address', 'order_addr_to');
|
|
||||||
// });
|
|
||||||
DB::statement('ALTER TABLE taxi_main CHANGE COLUMN taxi_address taxi_address_to Varchar(500)');
|
|
||||||
// Schema::table('taxi_main', function (Blueprint $table) {
|
|
||||||
// $table->renameColumn('taxi_address', 'taxi_address_to')->change();
|
|
||||||
// //$table->string('taxi_time', 8)->change();
|
|
||||||
// });
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Reverse the migrations.
|
|
||||||
*/
|
|
||||||
public function down(): void
|
|
||||||
{
|
|
||||||
// Schema::table('taxi_main', function(Blueprint $table) {
|
|
||||||
// $table->renameColumn('order_addr_to', 'taxi_address');
|
|
||||||
// });
|
|
||||||
DB::statement('ALTER TABLE taxi_main CHANGE COLUMN taxi_address_to taxi_address Varchar(500)');
|
|
||||||
// Schema::table('taxi_main', function (Blueprint $table) {
|
|
||||||
// //$table->renameColumn('archive', 'cancel_rqst');
|
|
||||||
// $table->renameColumn('taxi_address_to', 'taxi_address')->change();
|
|
||||||
// // $table->string('taxi_time', 6)->change();
|
|
||||||
// });
|
|
||||||
}
|
|
||||||
};
|
|
||||||
@@ -1,28 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
use Illuminate\Database\Migrations\Migration;
|
|
||||||
use Illuminate\Database\Schema\Blueprint;
|
|
||||||
use Illuminate\Support\Facades\Schema;
|
|
||||||
|
|
||||||
return new class extends Migration
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Run the migrations.
|
|
||||||
*/
|
|
||||||
public function up(): void
|
|
||||||
{
|
|
||||||
Schema::table('taxi_main', function(Blueprint $table){
|
|
||||||
$table->string('taxi_address_from', 500)->after('taxi_time')->comment('Адрес откуда ехать');
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Reverse the migrations.
|
|
||||||
*/
|
|
||||||
public function down(): void
|
|
||||||
{
|
|
||||||
Schema::table('taxi_main', function(Blueprint $table){
|
|
||||||
$table->dropColumn('taxi_address_from');
|
|
||||||
});
|
|
||||||
}
|
|
||||||
};
|
|
||||||
@@ -1,28 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
use Illuminate\Database\Migrations\Migration;
|
|
||||||
use Illuminate\Database\Schema\Blueprint;
|
|
||||||
use Illuminate\Support\Facades\Schema;
|
|
||||||
|
|
||||||
return new class extends Migration
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Run the migrations.
|
|
||||||
*/
|
|
||||||
public function up(): void
|
|
||||||
{
|
|
||||||
Schema::table('taxi_main', function(Blueprint $table){
|
|
||||||
$table->string('taxi_address_from', 500)->nullable(false)->change();
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Reverse the migrations.
|
|
||||||
*/
|
|
||||||
public function down(): void
|
|
||||||
{
|
|
||||||
Schema::table('taxi_main', function(Blueprint $table){
|
|
||||||
$table->string('taxi_address_from', 500)->nullable(true)->change();
|
|
||||||
});
|
|
||||||
}
|
|
||||||
};
|
|
||||||
@@ -1,28 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
use Illuminate\Database\Migrations\Migration;
|
|
||||||
use Illuminate\Database\Schema\Blueprint;
|
|
||||||
use Illuminate\Support\Facades\Schema;
|
|
||||||
|
|
||||||
return new class extends Migration
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Run the migrations.
|
|
||||||
*/
|
|
||||||
public function up(): void
|
|
||||||
{
|
|
||||||
Schema::table('taxi_main', function(Blueprint $table){
|
|
||||||
$table->string('taxi_address_to', 500)->nullable(false)->change();
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Reverse the migrations.
|
|
||||||
*/
|
|
||||||
public function down(): void
|
|
||||||
{
|
|
||||||
Schema::table('taxi_main', function(Blueprint $table){
|
|
||||||
$table->string('taxi_address_to', 500)->nullable(true)->change();
|
|
||||||
});
|
|
||||||
}
|
|
||||||
};
|
|
||||||
@@ -1,28 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
use Illuminate\Database\Migrations\Migration;
|
|
||||||
use Illuminate\Database\Schema\Blueprint;
|
|
||||||
use Illuminate\Support\Facades\Schema;
|
|
||||||
|
|
||||||
return new class extends Migration
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Run the migrations.
|
|
||||||
*/
|
|
||||||
public function up(): void
|
|
||||||
{
|
|
||||||
Schema::table('taxi_time_periods', function(Blueprint $table){
|
|
||||||
$table->boolean('morning_time')->after('time_period')->nullable(false)->default(true)->comment('Утренний промежуток времени');
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Reverse the migrations.
|
|
||||||
*/
|
|
||||||
public function down(): void
|
|
||||||
{
|
|
||||||
Schema::table('taxi_time_periods', function(Blueprint $table){
|
|
||||||
$table->dropColumn('morning_time');
|
|
||||||
});
|
|
||||||
}
|
|
||||||
};
|
|
||||||
@@ -1,24 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
use Illuminate\Database\Migrations\Migration;
|
|
||||||
use Illuminate\Database\Schema\Blueprint;
|
|
||||||
use Illuminate\Support\Facades\Schema;
|
|
||||||
|
|
||||||
return new class extends Migration
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Run the migrations.
|
|
||||||
*/
|
|
||||||
public function up(): void
|
|
||||||
{
|
|
||||||
DB::statement('ALTER TABLE taxi_time_periods CHANGE COLUMN morning_time is_morning_time Boolean');
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Reverse the migrations.
|
|
||||||
*/
|
|
||||||
public function down(): void
|
|
||||||
{
|
|
||||||
DB::statement('ALTER TABLE taxi_time_periods CHANGE COLUMN is_morning_time morning_time Boolean');
|
|
||||||
}
|
|
||||||
};
|
|
||||||
@@ -1,29 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
use Illuminate\Database\Migrations\Migration;
|
|
||||||
use Illuminate\Database\Schema\Blueprint;
|
|
||||||
use Illuminate\Support\Facades\Schema;
|
|
||||||
|
|
||||||
return new class extends Migration
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Run the migrations.
|
|
||||||
*/
|
|
||||||
public function up(): void
|
|
||||||
{
|
|
||||||
Schema::create('office_address', function(Blueprint $table){
|
|
||||||
$table->id();
|
|
||||||
$table->string('place', 20)->nullable(false)->comment('Площадка');
|
|
||||||
$table->string('address', 100)->nullable(false)->comment('Адрес');
|
|
||||||
$table->comment('Адреса офисов для подстановки в заказы такси');
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Reverse the migrations.
|
|
||||||
*/
|
|
||||||
public function down(): void
|
|
||||||
{
|
|
||||||
Schema::drop('office_address');
|
|
||||||
}
|
|
||||||
};
|
|
||||||
@@ -1,31 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "nwidart/taxi",
|
|
||||||
"description": "",
|
|
||||||
"authors": [
|
|
||||||
{
|
|
||||||
"name": "Nicolas Widart",
|
|
||||||
"email": "n.widart@gmail.com"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"extra": {
|
|
||||||
"laravel": {
|
|
||||||
"providers": [],
|
|
||||||
"aliases": {
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"autoload": {
|
|
||||||
"psr-4": {
|
|
||||||
"Modules\\Taxi\\": "",
|
|
||||||
"Modules\\Taxi\\App\\": "app/",
|
|
||||||
"Modules\\Taxi\\Database\\Factories\\": "database/factories/",
|
|
||||||
"Modules\\Taxi\\Database\\Seeders\\": "database/seeders/"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"autoload-dev": {
|
|
||||||
"psr-4": {
|
|
||||||
"Modules\\Taxi\\Tests\\": "tests/"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,8 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
return [
|
|
||||||
'name' => 'Taxi',
|
|
||||||
#Гаврилов
|
|
||||||
//КАК ЗАСТАВИТЬ ПРИ СОЗДАНИИ МОДУЛЯ ЭТОТ ПАРАМЕТР ПРОПИСЫВАТЬ АВТОМАТИЧЕСКИ?
|
|
||||||
'name_ru' => 'Реестр заказа такси', //Добавляем вручную в каждый конфиг
|
|
||||||
];
|
|
||||||
@@ -1,14 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "Taxi",
|
|
||||||
"alias": "taxi",
|
|
||||||
"description": "",
|
|
||||||
"keywords": [],
|
|
||||||
"priority": 0,
|
|
||||||
"providers": [
|
|
||||||
"Modules\\Taxi\\App\\Providers\\TaxiServiceProvider",
|
|
||||||
"Modules\\Taxi\\App\\Providers\\TaxiOrderProvider",
|
|
||||||
"Modules\\Taxi\\App\\Providers\\TaxiMailerProvider",
|
|
||||||
"Modules\\Taxi\\App\\Providers\\TaxiScheduleProvider"
|
|
||||||
],
|
|
||||||
"files": []
|
|
||||||
}
|
|
||||||
@@ -1,15 +0,0 @@
|
|||||||
{
|
|
||||||
"private": true,
|
|
||||||
"type": "module",
|
|
||||||
"scripts": {
|
|
||||||
"dev": "vite",
|
|
||||||
"build": "vite build"
|
|
||||||
},
|
|
||||||
"devDependencies": {
|
|
||||||
"axios": "^1.1.2",
|
|
||||||
"laravel-vite-plugin": "^0.7.5",
|
|
||||||
"sass": "^1.69.5",
|
|
||||||
"postcss": "^8.3.7",
|
|
||||||
"vite": "^4.0.0"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,6 +0,0 @@
|
|||||||
import { createRoot } from 'react-dom/client';
|
|
||||||
import MenuApp from './components/MenuApp.jsx'; // Создайте этот файл, если используете React
|
|
||||||
|
|
||||||
const container = document.getElementById('root');
|
|
||||||
const root = createRoot(container);
|
|
||||||
root.render(<MenuApp />);
|
|
||||||
@@ -1,44 +0,0 @@
|
|||||||
table {
|
|
||||||
|
|
||||||
& td {
|
|
||||||
padding: 5px;
|
|
||||||
}
|
|
||||||
& tr:nth-child(odd) {
|
|
||||||
background-color: #eeeeee;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
#taxi__order-create{
|
|
||||||
padding: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
#taxi__home__filter-form{
|
|
||||||
width: 20%;
|
|
||||||
}
|
|
||||||
|
|
||||||
.taxi-btn{
|
|
||||||
margin: 25px 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.elem--title.el-title--big{
|
|
||||||
padding: 7px;
|
|
||||||
margin: 50px 0 25px 0;
|
|
||||||
border-left: 5px solid #7864eb;
|
|
||||||
font-size: 1.3rem;
|
|
||||||
background: linear-gradient(90deg, rgb(237 234 255) 0%, rgb(255 255 255) 75%);
|
|
||||||
border-top-left-radius: 5px;
|
|
||||||
border-bottom-left-radius: 5px;
|
|
||||||
display: inline-block;
|
|
||||||
min-width: 400px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.form-field-block{
|
|
||||||
display: flex;
|
|
||||||
}
|
|
||||||
|
|
||||||
.taxi-orders__order-options{
|
|
||||||
|
|
||||||
& button {
|
|
||||||
margin: 10px 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
.order-create__btn-block{
|
|
||||||
margin: 20px 0;
|
|
||||||
}
|
|
||||||
@@ -1,387 +0,0 @@
|
|||||||
import { tr } from "date-fns/locale";
|
|
||||||
import React, { useEffect, useState, useMemo, useContext } from "react";
|
|
||||||
import { TaxiOrder_type, TaxiOrder_initial, TaxiOrder_fieldName, TaxiOrder_tableData } from '../types/taxiOrderType';
|
|
||||||
import { differenceInDays } from 'date-fns';
|
|
||||||
import { getCsrfToken } from "../../../../../resources/js/services/getCsrfService";
|
|
||||||
import { Button, TextInput, Select, Option } from '@SharePoint/rencredit_uikit';
|
|
||||||
import { EntityHistoryProps } from "../../../../../resources/js/components/entityHistory/EntityHistory";
|
|
||||||
import { HistoryProvider, HistoryContext } from "../../../../../resources/js/contexts/HistoryContext";
|
|
||||||
import { PopupContext } from "../../../../../resources/js/contexts/PopupContext";
|
|
||||||
import { PreloaderContext } from "../../../../../resources/js/contexts/PreloaderContext";
|
|
||||||
import api from "../../../../../resources/js/api";
|
|
||||||
|
|
||||||
type EmpSupervisorsData = {
|
|
||||||
emp_login: string,
|
|
||||||
emp_supervisor: string
|
|
||||||
}
|
|
||||||
|
|
||||||
export default function TaxiHome ()
|
|
||||||
{
|
|
||||||
//Массив полей для отображения в таблицах с заяками. Учитывается, в том числе, порядок
|
|
||||||
const rqstTableFields = ['id', 'emp_login', 'emp_supervisor', 'emp_phone', 'taxi_date', 'taxi_time', 'taxi_address_from', 'taxi_address_to', 'cancel_rqst'];
|
|
||||||
//Формируем объект с полями для таблицы
|
|
||||||
const rqstTableHeaderFields: Record<keyof TaxiOrder_tableData, string> = Object.assign({}, ...rqstTableFields.map( field => {return {[field]: TaxiOrder_fieldName[field]}}));
|
|
||||||
const rqstTableHeader:string[] = Object.keys(TaxiOrder_fieldName).map(rqstFieldName => TaxiOrder_fieldName[rqstFieldName]);
|
|
||||||
const [ccEmp, setCcEmp] = useState<string[]>([]);
|
|
||||||
//Стейт для руководителей сотрудников
|
|
||||||
const [empSupervisors, setEmpSupervisors] = useState<EmpSupervisorsData[]>([]);
|
|
||||||
const [allOrders, setAllOrders] = useState<TaxiOrder_type[]>([]);
|
|
||||||
const [filterOrders, setFilterOrders] = useState<TaxiOrder_type[]>([]);
|
|
||||||
const [startSearch, setStartSearch] = useState<boolean>(false);
|
|
||||||
const [rqstNumber, setRqstNumber] = useState<string>('');
|
|
||||||
const [rqstTime, setRqstTime] = useState<string>('');
|
|
||||||
const [rqstLogin, setRqstLogin] = useState<string>('');
|
|
||||||
const [orderTimePeriods, setOrderTimePeriods] = useState<[{time_period: string}]>([{time_period: ''}]);
|
|
||||||
|
|
||||||
const popupContext = useContext(PopupContext);
|
|
||||||
const preloaderContext = useContext(PreloaderContext);
|
|
||||||
|
|
||||||
useEffect ( () => {
|
|
||||||
api.get('/taxi/getTimePeriods',
|
|
||||||
).then(timePeriods_json => setOrderTimePeriods(timePeriods_json.data));
|
|
||||||
|
|
||||||
// fetch('/public/api/taxi/getTimePeriods', {
|
|
||||||
// method: 'GET',
|
|
||||||
// credentials: 'include',
|
|
||||||
// }).then(timePeriods_resp => timePeriods_resp.json().then( timePeriods_json => {
|
|
||||||
// setOrderTimePeriods(timePeriods_json);
|
|
||||||
// }));
|
|
||||||
|
|
||||||
setTimeout(() => {
|
|
||||||
popupContext.addPopupArrTest([
|
|
||||||
{message: 'для информации', timeOut: true, type: 'attention'}
|
|
||||||
])
|
|
||||||
popupContext.addPopupArrTest([
|
|
||||||
{message: 'ошибка', timeOut: true, type: 'error'}
|
|
||||||
])
|
|
||||||
}, 1000);
|
|
||||||
console.log(Object.keys(TaxiOrder_fieldName))
|
|
||||||
}, [])
|
|
||||||
|
|
||||||
//ГАВРИЛОВ
|
|
||||||
//ЕСЛИ ОБЪЕКТ СО ЗНАЧЕНИЯМИ ДЛЯ ПОИСКА ПУСТОЙ - НЕ ВЫПОЛНЯЕМ ПОИСК, ВОЗВРАЩАЕМ ОПОВЕЩЕНИЕ О ПУСТЫХ УСЛОВИЯХ
|
|
||||||
const getFilterOrders = () => {
|
|
||||||
console.log(rqstTime)
|
|
||||||
console.log(rqstNumber)
|
|
||||||
console.log(rqstLogin)
|
|
||||||
setStartSearch(true);
|
|
||||||
// ГАВРИЛОВ. проверь
|
|
||||||
api.post('/taxi/getFilterOrders', {
|
|
||||||
id: rqstNumber,
|
|
||||||
taxi_time: rqstTime,
|
|
||||||
emp_login: rqstLogin
|
|
||||||
}).then(filterOrdersJson => {
|
|
||||||
setFilterOrders(filterOrdersJson.data);
|
|
||||||
})
|
|
||||||
// fetch('/public/api/taxi/getFilterOrders', {
|
|
||||||
// credentials: 'include',
|
|
||||||
// method: 'POST',
|
|
||||||
// body: JSON.stringify({
|
|
||||||
// id: rqstNumber,
|
|
||||||
// taxi_time: rqstTime,
|
|
||||||
// emp_login: rqstLogin
|
|
||||||
// }),
|
|
||||||
// headers: {
|
|
||||||
// 'content-type': 'application/json'
|
|
||||||
// }
|
|
||||||
// }).then(filterOrdersRqst => filterOrdersRqst.json())
|
|
||||||
// .then(filterOrdersJson => {
|
|
||||||
// setFilterOrders(filterOrdersJson);
|
|
||||||
// })
|
|
||||||
}
|
|
||||||
|
|
||||||
const timePeriodOptions: Option<string>[] = useMemo(() => {
|
|
||||||
return orderTimePeriods.map((time: {time_period: string}) => {
|
|
||||||
return {
|
|
||||||
caption: time.time_period,
|
|
||||||
value: time.time_period,
|
|
||||||
id: time.time_period
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}, [orderTimePeriods])
|
|
||||||
|
|
||||||
const empLoginOptions: Option<string>[] = useMemo(() => {
|
|
||||||
return ccEmp.map((empLogin: string) => {
|
|
||||||
return {
|
|
||||||
caption: empLogin,
|
|
||||||
value: empLogin,
|
|
||||||
id: empLogin
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}, [ccEmp])
|
|
||||||
|
|
||||||
useEffect ( () => {
|
|
||||||
Promise.all(
|
|
||||||
[
|
|
||||||
// fetch('/public/api/taxi/getEmpInfo', {
|
|
||||||
// credentials: 'include',
|
|
||||||
// method: 'GET',
|
|
||||||
// }).then( empInfo_resp => empInfo_resp.json() ),
|
|
||||||
api.get('taxi/getEmpInfo'),
|
|
||||||
api.get('taxi/getActiveOrders'),
|
|
||||||
// fetch('/public/api/taxi/getActiveOrders', {
|
|
||||||
// credentials: 'include',
|
|
||||||
// method: 'GET',
|
|
||||||
// }).then( allOrders_resp => allOrders_resp.json() )
|
|
||||||
]
|
|
||||||
).then(
|
|
||||||
([
|
|
||||||
{data: empInfo_json},
|
|
||||||
{data: allOrders_json}
|
|
||||||
]) => {
|
|
||||||
setCcEmp(empInfo_json.map( (empInfoEl: {emp_login: String}) => empInfoEl.emp_login ));
|
|
||||||
setAllOrders(allOrders_json);
|
|
||||||
setEmpSupervisors(empInfo_json.map( (empInfoEl: {emp_login: String, emp_group: String}) => ({emp_login: empInfoEl.emp_login, emp_supervisor: empInfoEl.emp_group}) ));
|
|
||||||
}
|
|
||||||
)
|
|
||||||
|
|
||||||
}, [])
|
|
||||||
|
|
||||||
const isReady = ccEmp.length > 0 && orderTimePeriods.length > 0;
|
|
||||||
|
|
||||||
useEffect ( () => {
|
|
||||||
console.log(!isReady)
|
|
||||||
preloaderContext.setPreloaderVisible(!isReady)
|
|
||||||
// setPreloaderProp(!isReady);
|
|
||||||
// console.log(empSupervisors)
|
|
||||||
}, [isReady])
|
|
||||||
|
|
||||||
if (!ccEmp.length || !orderTimePeriods.length) {
|
|
||||||
//setIsReady(true);
|
|
||||||
return;
|
|
||||||
} else {
|
|
||||||
//setIsReady(false);
|
|
||||||
// console.log(allOrders);
|
|
||||||
console.log(ccEmp);
|
|
||||||
console.log(orderTimePeriods);
|
|
||||||
}
|
|
||||||
|
|
||||||
// ГАВРИЛОВ. ОФОРМИ РЕЗУЛЬТАТЫ ПОИСКА. ПОСЛЕ ПОИСКА ПЛАВНО ОПУСКАЙ ДО ТАБЛИЦЫ РЕЗУЛЬТАТЫ ПОИСКА, ТАКЖЕ ВЫВЕДИ ЗОТЯ БЫ ТЕКСТ "РЕЗУЛЬТАТЫ ПОИСКА, СЕЙЧАС ЭТО ПРОСТО ТАБЛИЦА"
|
|
||||||
|
|
||||||
//Гаврилов
|
|
||||||
//Реализовать подтягивание информации
|
|
||||||
//Реализовать переключение между БД (new and old Magic)
|
|
||||||
|
|
||||||
//console.log(sanctumToken())
|
|
||||||
|
|
||||||
let newDate = new Date('2024-06-05');
|
|
||||||
newDate.setHours(0, 0, 0);
|
|
||||||
|
|
||||||
// function callHistory(entityId) {
|
|
||||||
// console.log(entityId)
|
|
||||||
|
|
||||||
// return fakeObjArr;
|
|
||||||
// }
|
|
||||||
|
|
||||||
|
|
||||||
// let resultObj = {
|
|
||||||
// entityId: 1,
|
|
||||||
// entityProps: fakeObjArr
|
|
||||||
// }
|
|
||||||
|
|
||||||
return (
|
|
||||||
<div id='taxi-container'>
|
|
||||||
<Button
|
|
||||||
type = 'button'
|
|
||||||
text = 'Новая заявка'
|
|
||||||
onClick = {
|
|
||||||
() => document.location.href = 'createRqst'
|
|
||||||
}
|
|
||||||
className = "taxi-btn"
|
|
||||||
/>
|
|
||||||
<div className = "elem--title el-title--big">Активные заявки</div>
|
|
||||||
<div className='container__table-block' id='taxi__rqst--active'>
|
|
||||||
<HistoryProvider>
|
|
||||||
<RqstTable
|
|
||||||
allOrders={allOrders}
|
|
||||||
rqstTableHeader={rqstTableHeaderFields}
|
|
||||||
empSupervisors={empSupervisors}
|
|
||||||
/>
|
|
||||||
</HistoryProvider>
|
|
||||||
</div>
|
|
||||||
<div id="taxi__home__filter-form">
|
|
||||||
<div className = "elem--title el-title--big">Поиск заявки</div>
|
|
||||||
<form>
|
|
||||||
<input
|
|
||||||
type="hidden"
|
|
||||||
name="_token"
|
|
||||||
value={getCsrfToken()}
|
|
||||||
/>
|
|
||||||
<div>
|
|
||||||
<TextInput
|
|
||||||
labelText = 'Номер заявки'
|
|
||||||
value = {rqstNumber}
|
|
||||||
onChange = {(e: string) => setRqstNumber(e)}
|
|
||||||
/>
|
|
||||||
{/* <label htmlFor="">Номер заявки</label>
|
|
||||||
<input type="number" onChange={ e => {
|
|
||||||
setRqstNumber(e.target.value)
|
|
||||||
}}></input> */}
|
|
||||||
</div>
|
|
||||||
{/* <div>
|
|
||||||
<label htmlFor="">Дата с</label>
|
|
||||||
<input type="date" />
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
<label htmlFor="">Дата по</label>
|
|
||||||
<input type="date" />
|
|
||||||
</div> */}
|
|
||||||
<div>
|
|
||||||
<Select
|
|
||||||
labelText = "Время"
|
|
||||||
options = {timePeriodOptions}
|
|
||||||
size = '1'
|
|
||||||
onChange = { (e: string) => {
|
|
||||||
setRqstTime(e)
|
|
||||||
}}
|
|
||||||
/>
|
|
||||||
{/* <label htmlFor="">Время</label>
|
|
||||||
<select name="taxi_time" id="" onChange={ e => {
|
|
||||||
setRqstTime(e.target.value)
|
|
||||||
}}>
|
|
||||||
<option key='0' value=''></option>
|
|
||||||
{
|
|
||||||
orderTimePeriods.map( (timePeriodEl, timePeriodIndex ) =>
|
|
||||||
<option key={timePeriodIndex++} value={timePeriodEl.time_period}>{timePeriodEl.time_period}</option>
|
|
||||||
)
|
|
||||||
}
|
|
||||||
</select> */}
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
<Select
|
|
||||||
labelText = "Сотрудник"
|
|
||||||
options = {empLoginOptions}
|
|
||||||
size = '1'
|
|
||||||
onChange = { (e, selectedOption: {value: string}) => {
|
|
||||||
setRqstLogin(selectedOption.value)
|
|
||||||
}}
|
|
||||||
/>
|
|
||||||
{/* <label htmlFor="">Логин</label>
|
|
||||||
<select onChange={ e => setRqstLogin(e.target.value) }>
|
|
||||||
<option key="0" value=""></option>
|
|
||||||
{
|
|
||||||
ccEmp.map( (empDataEl: string, empDataIndex: number) =>
|
|
||||||
<option key={empDataIndex++} value={empDataEl}>{empDataEl}</option>
|
|
||||||
)
|
|
||||||
}
|
|
||||||
</select> */}
|
|
||||||
</div>
|
|
||||||
<Button
|
|
||||||
className = "taxi-btn"
|
|
||||||
type = 'button'
|
|
||||||
text = 'Искать'
|
|
||||||
onClick = { getFilterOrders }
|
|
||||||
size = 's'
|
|
||||||
ui = 'secondary'
|
|
||||||
/>
|
|
||||||
{/* <button type="button" onClick={getFilterOrders}>Искать</button> */}
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
<div id = "container__filter-rqst-table">
|
|
||||||
{
|
|
||||||
startSearch ?
|
|
||||||
<table>
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
{
|
|
||||||
rqstTableHeader.map( (headEl, headElIndex) =>
|
|
||||||
<th key={headElIndex} className = "table-header">
|
|
||||||
{headEl}
|
|
||||||
</th>)
|
|
||||||
}
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
{
|
|
||||||
filterOrders.length ?
|
|
||||||
filterOrders.map( (rqstData: TaxiOrder_type, rqstIndex: number) =>
|
|
||||||
<tr key={rqstIndex}>
|
|
||||||
{
|
|
||||||
Object.keys(TaxiOrder_initial).map(initField =>
|
|
||||||
<td>
|
|
||||||
{initField == 'cancel_rqst' ? (rqstData[initField] ? 'Нет' : 'Да') : rqstData[initField]}
|
|
||||||
</td>)
|
|
||||||
}
|
|
||||||
</tr>)
|
|
||||||
: <tr>
|
|
||||||
<td>Запросов не найдено</td>
|
|
||||||
</tr>
|
|
||||||
}
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
: ''
|
|
||||||
}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
function RqstTable(props: {allOrders: TaxiOrder_type[], rqstTableHeader: Record<keyof TaxiOrder_tableData, string>, empSupervisors: EmpSupervisorsData[]}){
|
|
||||||
const historyContext = useContext(HistoryContext);
|
|
||||||
if (!historyContext) {
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
let newDate = new Date('2024-06-05');
|
|
||||||
newDate.setHours(0, 0, 0);
|
|
||||||
return (
|
|
||||||
props.allOrders.length ?
|
|
||||||
<table className="taxi-orders">
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
{
|
|
||||||
Object.entries(props.rqstTableHeader).map((el, index) =>
|
|
||||||
<th key={index} className="table-header">{el[1]}</th>
|
|
||||||
)
|
|
||||||
}
|
|
||||||
<th className = "table-header">Управление</th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
{
|
|
||||||
props.allOrders.map( (rqstData: TaxiOrder_type, rqstIndex: number) =>
|
|
||||||
<tr key = {rqstIndex}>
|
|
||||||
{
|
|
||||||
Object.entries(props.rqstTableHeader).map( el => {
|
|
||||||
return (
|
|
||||||
// Если поле - руководитель сотрудника - вычисляем значение, ориентируясь на список props.empSupervisors
|
|
||||||
el[0] === 'emp_supervisor' ?
|
|
||||||
<td key={el[0]}>{ props.empSupervisors.find(empData => empData.emp_login == rqstData.emp_login)?.emp_supervisor }</td>
|
|
||||||
: <td key={el[0]}>{ rqstData[el[0]] }</td>
|
|
||||||
)
|
|
||||||
})
|
|
||||||
}
|
|
||||||
<td className="taxi-orders__order-options">
|
|
||||||
{/* Можно взаимодействовать только с заявками на такси на сегодняшнюю, либо завтрашнюю дату */}
|
|
||||||
{differenceInDays(new Date(rqstData.taxi_date), new Date()) >= 0 && !rqstData.cancel_rqst ?
|
|
||||||
<>
|
|
||||||
<Button
|
|
||||||
type = 'button'
|
|
||||||
onClick = { () => { document.location.href = `editOrder/${rqstData.id}` } }
|
|
||||||
text = {'Редактировать'}
|
|
||||||
ui = 'secondaryPurple'
|
|
||||||
/>
|
|
||||||
<Button
|
|
||||||
type = 'button'
|
|
||||||
onClick = { () => { document.location.href = `cancelRqst/${rqstData.id}` } }
|
|
||||||
text = {'Отменить'}
|
|
||||||
ui = 'secondaryPurple'
|
|
||||||
/>
|
|
||||||
<Button
|
|
||||||
type = 'button'
|
|
||||||
onClick = { () => { historyContext.getHistoryFromMagic('taxi', rqstData.id, TaxiOrder_fieldName) } }
|
|
||||||
text = {'История'}
|
|
||||||
ui = 'secondaryPurple'
|
|
||||||
/>
|
|
||||||
</>
|
|
||||||
: ""
|
|
||||||
}
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
)
|
|
||||||
}
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
: <div>Нет активных заявок</div>
|
|
||||||
)
|
|
||||||
}
|
|
||||||
@@ -1,635 +0,0 @@
|
|||||||
import React, { useEffect, useContext, useState, useMemo } from "react";
|
|
||||||
import { TaxiOrder_type, TaxiOrder_initial } from '../types/taxiOrderType';
|
|
||||||
import { addDays, format } from 'date-fns';
|
|
||||||
import { getCsrfToken } from "../../../../../resources/js/services/getCsrfService";
|
|
||||||
import { Button, TextInput, Select, Option } from '@SharePoint/rencredit_uikit';
|
|
||||||
import FormValidErr, { FormValidErrObject } from "../../../../../resources/js/components/formValidErr/FormValidErr";
|
|
||||||
import { PopupContext } from "../../../../../resources/js/contexts/PopupContext";
|
|
||||||
import { EntityHistoryProps } from "../../../../../resources/js/components/entityHistory/EntityHistory";
|
|
||||||
import { PreloaderContext } from "../../../../../resources/js/contexts/PreloaderContext";
|
|
||||||
|
|
||||||
//Гаврилов типы для пропсов?
|
|
||||||
// export default function TaxiOrder( {rqstId, setPreloaderProp}: {rqstId: number | undefined, setPreloaderProp: CallableFunction} )
|
|
||||||
export default function TaxiOrder( {rqstId}: {rqstId: number | undefined} )
|
|
||||||
{
|
|
||||||
let newDate = new Date('2024-06-05');
|
|
||||||
newDate.setHours(0, 0, 0);
|
|
||||||
let fakeObjArr: EntityHistoryProps[] = [
|
|
||||||
{
|
|
||||||
changeAction: 'insert',
|
|
||||||
changeAuthor: 'login',
|
|
||||||
changeDate: newDate,
|
|
||||||
changeDetails: [
|
|
||||||
{
|
|
||||||
propName: 'поле',
|
|
||||||
propValue: 'значение'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
propName: 'поле',
|
|
||||||
propValue: 'значение'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
propName: 'поле',
|
|
||||||
propValue: 'значение'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
propName: 'поле2',
|
|
||||||
propValue: 'значение2'
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
|
||||||
changeAction: 'insert',
|
|
||||||
changeAuthor: 'login',
|
|
||||||
changeDate: new Date('2024-06-05'),
|
|
||||||
changeDetails: [
|
|
||||||
{
|
|
||||||
propName: 'поле',
|
|
||||||
propValue: 'значение'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
propName: 'поле',
|
|
||||||
propValue: 'значение'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
propName: 'поле',
|
|
||||||
propValue: 'значение'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
propName: 'поле2',
|
|
||||||
propValue: 'значение2'
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
|
||||||
changeAction: 'insert',
|
|
||||||
changeAuthor: 'login',
|
|
||||||
changeDate: new Date('2024-06-05'),
|
|
||||||
changeDetails: [
|
|
||||||
{
|
|
||||||
propName: 'поле',
|
|
||||||
propValue: 'значение'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
propName: 'поле',
|
|
||||||
propValue: 'значение'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
propName: 'поле',
|
|
||||||
propValue: 'значение'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
propName: 'поле2',
|
|
||||||
propValue: 'значение2'
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
|
||||||
changeAction: 'update',
|
|
||||||
changeAuthor: 'login2',
|
|
||||||
changeDate: new Date('2025-06-05'),
|
|
||||||
changeDetails: [
|
|
||||||
{
|
|
||||||
propName: 'поле3',
|
|
||||||
propValue: 'значение4'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
propName: 'поле3',
|
|
||||||
propValue: 'значение4'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
propName: 'поле3',
|
|
||||||
propValue: 'значение4'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
propName: 'поле3',
|
|
||||||
propValue: 'значение4'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
propName: 'поле5',
|
|
||||||
propValue: 'значение6'
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
|
||||||
changeAction: 'update',
|
|
||||||
changeAuthor: 'login2',
|
|
||||||
changeDate: new Date('2025-06-05'),
|
|
||||||
changeDetails: [
|
|
||||||
{
|
|
||||||
propName: 'поле3',
|
|
||||||
propValue: 'значение4'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
propName: 'поле3',
|
|
||||||
propValue: 'значение4'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
propName: 'поле3',
|
|
||||||
propValue: 'значение4'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
propName: 'поле3',
|
|
||||||
propValue: 'значение4'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
propName: 'поле5',
|
|
||||||
propValue: 'значение6'
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
];
|
|
||||||
|
|
||||||
const preloaderContext = useContext(PreloaderContext);
|
|
||||||
|
|
||||||
//ГАВРИЛОВ ПОСТОЯННЫЙ ПЕРЕРЕНДЕРИНГ СПРОСИТЬ У САШИ. ЭЛЕМЕНТ НЕ МИГАЕТ В КОНСОЛИ, НО ПИШЕТ ПОСТОЯННО ПЕРЕРЕНДЕР
|
|
||||||
console.log('🔁 TaxiForm перерендерился!');
|
|
||||||
interface UserData {
|
|
||||||
emp_id: number,
|
|
||||||
emp_address: string,
|
|
||||||
emp_lastname: string,
|
|
||||||
emp_name: string,
|
|
||||||
emp_surname: string,
|
|
||||||
emp_login: string | null
|
|
||||||
emp_phone: string,
|
|
||||||
//Все остальные поля объекта могут быть пустыми
|
|
||||||
[key: string]: unknown,
|
|
||||||
full_name: string,
|
|
||||||
};
|
|
||||||
const UserData_initial: UserData = {
|
|
||||||
emp_id: 0,
|
|
||||||
emp_address: '',
|
|
||||||
emp_lastname: '',
|
|
||||||
emp_name: '',
|
|
||||||
emp_surname: '',
|
|
||||||
emp_login: '',
|
|
||||||
emp_phone: '',
|
|
||||||
full_name: '',
|
|
||||||
// _token: getCsrfToken()
|
|
||||||
};
|
|
||||||
//Проверка загрузки необходимых для начала работ данных. После успешного получения всех данных происходит рендеринг
|
|
||||||
const [checkLoad, setCheckLoad] = useState(
|
|
||||||
{
|
|
||||||
ccEmp: false,
|
|
||||||
orderData: false,
|
|
||||||
checkEditOrderUserData: false,
|
|
||||||
getTimePeriods: false,
|
|
||||||
checkOfficeAddress: false,
|
|
||||||
}
|
|
||||||
);
|
|
||||||
const todayDate = new Date();
|
|
||||||
//Данные по всем пользователям
|
|
||||||
const [ccEmp, setCcEmp] = useState<UserData[]>( [UserData_initial] );
|
|
||||||
//Данные по редактируемому запросу (если вызвано редактирование)
|
|
||||||
const [orderData, setOrderData] = useState<TaxiOrder_type>(TaxiOrder_initial);
|
|
||||||
//Данные по пользователю, чей запрос редактируется (если вызвано редактирование запроса)
|
|
||||||
const [editOrderUserData, setEditOrderUserData] = useState<UserData>(UserData_initial);
|
|
||||||
//Данные по временным промежуткам
|
|
||||||
const [orderTimePeriods, setOrderTimePeriods] = useState< {time_period: string, is_morning_time: number}[] >(
|
|
||||||
[ {time_period: '', is_morning_time: 0} ]
|
|
||||||
);
|
|
||||||
//Массив доступных для заказа такси дат для их дальнейшего преобразования в теги option селекта
|
|
||||||
const [dateOrderArr, setDateOrderArr] = useState<string[]>(
|
|
||||||
[
|
|
||||||
format(todayDate, "yyyy-MM-dd"),
|
|
||||||
format(addDays(todayDate, 1), "yyyy-MM-dd")
|
|
||||||
]
|
|
||||||
);
|
|
||||||
const popupContext = useContext(PopupContext);
|
|
||||||
useEffect ( () => {
|
|
||||||
setFormCreateVisible(true);
|
|
||||||
setFormCreateValidObj([{fieldName: 'testField', fieldErrors: ['errOne']}]);
|
|
||||||
console.log(popupContext)
|
|
||||||
// console.log()
|
|
||||||
// setTimeout(() => {
|
|
||||||
// popupContext.addPopupArrTest([
|
|
||||||
// {message: 'для информации', timeOut: true, type: 'attention'}
|
|
||||||
// ])
|
|
||||||
// }, 1000);
|
|
||||||
// setTimeout(() => {
|
|
||||||
// setPopupArrProp([
|
|
||||||
// {message: 'для информации', timeOut: true, type: 'attention'},
|
|
||||||
// ])
|
|
||||||
// }, 1000);
|
|
||||||
// setTimeout(() => {
|
|
||||||
// setPopupArrProp([
|
|
||||||
// {message: 'для информации', timeOut: false, type: 'info'},
|
|
||||||
// ])
|
|
||||||
// }, 2000);
|
|
||||||
// setTimeout(() => {
|
|
||||||
// setPopupArrProp([
|
|
||||||
// {message: 'для информации', timeOut: false, type: 'info'},
|
|
||||||
// ])
|
|
||||||
// }, 3000);
|
|
||||||
// setPopupArrProp([
|
|
||||||
// {message: 'для информации', timeOut: false, type: 'info'},
|
|
||||||
// {message: 'успешно', timeOut: true, type: 'success'},
|
|
||||||
// {message: 'ошибка', timeOut: true, type: 'error'},
|
|
||||||
// {message: 'обратить внимание', timeOut: true, type: 'attention'}
|
|
||||||
// ])
|
|
||||||
}, [])
|
|
||||||
|
|
||||||
const [formCreateVisible, setFormCreateVisible] = useState<boolean>(false);
|
|
||||||
const [formCreateValidErrObj, setFormCreateValidObj] = useState<FormValidErrObject[]>([{fieldName: null, fieldErrors: []}])
|
|
||||||
|
|
||||||
//ГАВРИЛОВ ДОБАВИТЬ ВСПЛЫВАЮЩЕЕ ОКНО ЕСЛИ ПРОИСХОДИТ НЕСООТВЕТСТВИЕ ВРЕМЕНИ И ДАТЫ ЗАКАЗА ТАКСИ? А НЕ ПРОСТО УДАЛЯТЬ ЗНАЧЕНИЕ ИЗ СОСЕДНЕГО ПОЛЯ?
|
|
||||||
|
|
||||||
//Адреса офисов
|
|
||||||
const [officeAddressInfo, setOfficeAddressInfo] = useState< {place: string, address: string}[] >(
|
|
||||||
[ {place: '', address: ''} ]
|
|
||||||
);
|
|
||||||
//Адрес офиса, где работает сотрудник. Определяется на этапе выбора логина
|
|
||||||
const [empOfficeAddress, setEmpOfficeAddress] = useState<string | null>(null);
|
|
||||||
//const [orderTime, setOrderTime] = useState<string|null>(null);
|
|
||||||
//const [orderDate, setOrderDate] = useState<string|null>(null);
|
|
||||||
// const [orderAddressFrom, setOrderAddressFrom] = useState<string|null>(null);
|
|
||||||
// const [orderAddressTo, setOrderAddressTo] = useState<string|null>(null);
|
|
||||||
|
|
||||||
function gotoHome()
|
|
||||||
{
|
|
||||||
document.location.href = '/public/taxi/home';
|
|
||||||
}
|
|
||||||
|
|
||||||
//Гаврилов. Не передаешь CSRF токен
|
|
||||||
//Отправка заказа на такси
|
|
||||||
function sendTaxiOrder ()
|
|
||||||
{
|
|
||||||
console.log(orderData)
|
|
||||||
console.log(editOrderUserData)
|
|
||||||
//return
|
|
||||||
// setPreloaderProp(true, 'создаем заявку')
|
|
||||||
preloaderContext.setPreloaderVisible(true);
|
|
||||||
preloaderContext.setPreloaderText('создаем заявку');
|
|
||||||
let popupType;
|
|
||||||
fetch('/public/api/taxi/' + (rqstId ? `editOrder/${rqstId}` : 'createRqst'), {
|
|
||||||
credentials: 'include',
|
|
||||||
method: (rqstId ? "PATCH" : "POST"),
|
|
||||||
body: JSON.stringify(orderData),
|
|
||||||
headers: {
|
|
||||||
'content-type': 'application/json',
|
|
||||||
'Accept': 'application/json'
|
|
||||||
}
|
|
||||||
}).then(result => {
|
|
||||||
preloaderContext.setPreloaderVisible(false);
|
|
||||||
// setPreloaderProp(false)
|
|
||||||
result.json().then(jsonResult => {
|
|
||||||
console.log(jsonResult)
|
|
||||||
if (!result.ok) {
|
|
||||||
//ГАВРИЛОВ здесь обработка ошибок валидации формы
|
|
||||||
if (result.status == 422) {
|
|
||||||
// setPopupArrProp(
|
|
||||||
// [
|
|
||||||
// //ГАВРИЛОВ обработка ошибки
|
|
||||||
// {message: 'Произошла ошибка! Заявка не создана', type: 'error'},
|
|
||||||
// ]
|
|
||||||
// )
|
|
||||||
} else {
|
|
||||||
// setPopupArrProp(
|
|
||||||
// [
|
|
||||||
// //ГАВРИЛОВ обработка ошибки
|
|
||||||
// {message: jsonResult.result_msg, type: 'error'},
|
|
||||||
// ]
|
|
||||||
// )
|
|
||||||
}
|
|
||||||
popupType = 'error'
|
|
||||||
} else {
|
|
||||||
popupType = 'success'
|
|
||||||
}
|
|
||||||
popupContext.addPopupArrTest(
|
|
||||||
[
|
|
||||||
{message: jsonResult.message, type: popupType},
|
|
||||||
]
|
|
||||||
)
|
|
||||||
})
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
//Функция, собирающая нужный массив для формирования из него списка option для select
|
|
||||||
function transformToOptionsFunc <T,>(
|
|
||||||
dataArr: T[],
|
|
||||||
dataKey?: keyof T
|
|
||||||
): Option<string>[] {
|
|
||||||
let optionArr = dataArr.map(item => {
|
|
||||||
//Без проверки ниже, Typescript ругается на условный атрибут dataKey, который может отсутствовать, но при этом укаан как относящийся к Дженерику
|
|
||||||
const value = dataKey !== undefined
|
|
||||||
? item[dataKey]
|
|
||||||
: item;
|
|
||||||
|
|
||||||
return {
|
|
||||||
caption: String(value),
|
|
||||||
value: String(value),
|
|
||||||
id: String(value)
|
|
||||||
};
|
|
||||||
});
|
|
||||||
return optionArr;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Метод проверки соответствует ли дата и время заказа логике. Наприме, если дата заказа сегодняшняя - нельзя выбрать утренний промежуток времени
|
|
||||||
* @param orderTime время заказа такси
|
|
||||||
* @param orderDate дата заказа такси
|
|
||||||
* @returns результат проверки соответствия даты и времени заказа
|
|
||||||
*/
|
|
||||||
function checkTimeAndDate (orderTime: string|null, orderDate: string|null): boolean
|
|
||||||
{
|
|
||||||
// console.log(orderTime)
|
|
||||||
// console.log(!orderTime)
|
|
||||||
// console.log(orderDate)
|
|
||||||
// console.log(!orderDate)
|
|
||||||
if (!orderTime || !orderDate) {
|
|
||||||
//console.log(1)
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
let isMorningTimeCheck = orderTimePeriods.filter( e => e.time_period == orderTime )[0].is_morning_time;
|
|
||||||
// console.log(isMorningTimeCheck)
|
|
||||||
//Если выбранная дата заказа больше текущей - заказ на завтра, можно выбирать любую дату
|
|
||||||
if (!(new Date(orderDate) > todayDate)) {
|
|
||||||
//console.log(2)
|
|
||||||
return !isMorningTimeCheck;
|
|
||||||
}
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
// const ccEmpList: Option<string>[] = useMemo(() => {
|
|
||||||
// return ccEmp.map(empData => {
|
|
||||||
// return {
|
|
||||||
// caption: empData.emp_login,
|
|
||||||
// value: empData.emp_login,
|
|
||||||
// id: empData.emp_login
|
|
||||||
// }
|
|
||||||
// })
|
|
||||||
// }, [ccEmp]);
|
|
||||||
|
|
||||||
// console.log(ccEmpList)
|
|
||||||
|
|
||||||
|
|
||||||
const ccEmpList = useMemo( () => {
|
|
||||||
return transformToOptionsFunc(ccEmp, 'emp_login');
|
|
||||||
}, [ccEmp]);
|
|
||||||
|
|
||||||
const orderDateList = useMemo( () => {
|
|
||||||
return transformToOptionsFunc(dateOrderArr);
|
|
||||||
}, [dateOrderArr]);
|
|
||||||
|
|
||||||
const orderTimeList = useMemo( () => {
|
|
||||||
return transformToOptionsFunc(orderTimePeriods, 'time_period')
|
|
||||||
}, [orderTimePeriods]);
|
|
||||||
|
|
||||||
//Загрузка данных для старта работ
|
|
||||||
useEffect ( () => {
|
|
||||||
//Получаем информацию по сотруднику при загрузке страницы
|
|
||||||
fetch('/public/api/taxi/getEmpInfo', {
|
|
||||||
credentials: 'include',
|
|
||||||
method: 'GET',
|
|
||||||
// headers: new Headers({
|
|
||||||
// 'Authorization': `Bearer ${sanctumToken()}`
|
|
||||||
// })
|
|
||||||
}).then(empInfo_resp => empInfo_resp.json().then(empInfo_json => {
|
|
||||||
console.log(empInfo_json)
|
|
||||||
console.log(editOrderUserData)
|
|
||||||
setCcEmp(empInfo_json);
|
|
||||||
setCheckLoad(loadObj => ( {...loadObj, ccEmp: true} ));
|
|
||||||
}));
|
|
||||||
//Получаем доступные временные промежутки для заказа такси
|
|
||||||
fetch('/public/api/taxi/getTimePeriods', {
|
|
||||||
method: 'GET',
|
|
||||||
credentials: 'include',
|
|
||||||
// headers: new Headers({
|
|
||||||
// 'Authorization': `Bearer ${sanctumToken()}`
|
|
||||||
// })
|
|
||||||
}).then(timePeriods_resp => timePeriods_resp.json().then(timePeriods_json => {
|
|
||||||
setOrderTimePeriods(timePeriods_json);
|
|
||||||
setCheckLoad(loadObj => ( {...loadObj, getTimePeriods: true} ));
|
|
||||||
}));
|
|
||||||
//ГАВРИЛОВ. ВЕЗДЕ В FETCH ЗАПРОСАХ ПЕРЕХВАТЫВАЙ ОШИБКИ И ВЫВОДИ СООБЩЕНИЯ ОБ ОШИБКЕ. НАПРИМЕМР С 401. В ЭТОМ СЛУЧАЕ НУЖНО ПЕРЕБРАСЫВАТЬ ПОЛЬЗОВАТЕЛЯ НА СТРАНИЦУ АУТЕНТИФИКАЦИИ
|
|
||||||
//Получае адреса всех офисов, куда могут заказываться такси?
|
|
||||||
fetch('/public/api/taxi/getOfficeAddress', {
|
|
||||||
method: 'GET',
|
|
||||||
credentials: 'include',
|
|
||||||
}).then(officeAddress_resp => {officeAddress_resp.json().then(officeAddress_json => {
|
|
||||||
setOfficeAddressInfo(officeAddress_json);
|
|
||||||
setCheckLoad(loadObj => ( {...loadObj, checkOfficeAddress: true} ));
|
|
||||||
})});
|
|
||||||
//Если в пропсах передается rqstId, происходит редактирование заявки, а не создание новой - получаем данные по редактируемой заявке на такси
|
|
||||||
if (rqstId) {
|
|
||||||
fetch(`/public/api/taxi/getOrderById/${rqstId}`, {
|
|
||||||
method: 'GET',
|
|
||||||
credentials: 'include',
|
|
||||||
// headers: new Headers({
|
|
||||||
// 'Authorization': `Bearer ${sanctumToken()}`
|
|
||||||
// })
|
|
||||||
}).then(orderData_resp => orderData_resp.json().then( orderData_json => {
|
|
||||||
console.log(orderData_json)
|
|
||||||
setOrderData(orderData_json);
|
|
||||||
setCheckLoad(loadObj => ({...loadObj, orderData: true}));
|
|
||||||
}));
|
|
||||||
}
|
|
||||||
}, [])
|
|
||||||
|
|
||||||
//гаврилов. Нужно ввести объект с данными по запросу и туда класть только нужные данные , а не все параметры пользователя. и тогда не нужно нигде проверять rqstId. Внизу в методе класть в этот объект все нужные параметры
|
|
||||||
|
|
||||||
useEffect ( () => {
|
|
||||||
//Гаврилов. Причем тут проверка логина? Зачем она?
|
|
||||||
if (rqstId && orderData.emp_login) {
|
|
||||||
//Если передан id запроса на редактирование, устанавливаем значение с данными пользователя редактируемого запроса
|
|
||||||
fetch(`/public/api/taxi/getEmpInfo/${orderData.emp_login}`).then(userData_resp => userData_resp.json().then(userData_json => {
|
|
||||||
//гаврилов. Вот здесь нужно класть данные в orderData, а также заполнять адрес из и адрес куда
|
|
||||||
setEditOrderUserData(userData_json[0]);
|
|
||||||
//setOrderData(prevData => ({...prevData, userData_json[0]}));
|
|
||||||
//setEmpAddress(editOrderUserData['emp_address']);
|
|
||||||
setCheckLoad(loadObj => ( {...loadObj, checkEditOrderUserData: true} ));
|
|
||||||
//ГАВРИЛОВ. вынеси в отедльную функцию определение адреса офиса?
|
|
||||||
setEmpOfficeAddress(officeAddressInfo.filter(addressInfo => addressInfo.place == userData_json[0].emp_area)[0].address);
|
|
||||||
}));
|
|
||||||
}
|
|
||||||
}, [orderData.emp_login])
|
|
||||||
|
|
||||||
//Итоговая проверка все ли необходимые данные для рендеринга получены
|
|
||||||
const isReady = rqstId ?
|
|
||||||
checkLoad.ccEmp && checkLoad.checkEditOrderUserData && checkLoad.orderData && checkLoad.checkOfficeAddress && checkLoad.getTimePeriods
|
|
||||||
: checkLoad.ccEmp;
|
|
||||||
|
|
||||||
//Регулировка видимости прелоадера в зависимости от того все ли данные для рендеринга получены или нет
|
|
||||||
useEffect ( () => {
|
|
||||||
//isReady ? setPreloaderProp(false) : setPreloaderProp(true);
|
|
||||||
isReady ? preloaderContext.setPreloaderVisible(false) : preloaderContext.setPreloaderVisible(true);
|
|
||||||
}, [isReady])
|
|
||||||
|
|
||||||
if (!isReady) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
return (
|
|
||||||
<div id = "taxi__order-create">
|
|
||||||
{/* <EntityHistory
|
|
||||||
entityId={1}
|
|
||||||
entityProps= {fakeObjArr}
|
|
||||||
/> */}
|
|
||||||
<div className = "order-create__btn-block">
|
|
||||||
<Button
|
|
||||||
type = 'button'
|
|
||||||
onClick = {gotoHome}
|
|
||||||
text = 'Домой'
|
|
||||||
ui = 'secondary'
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
<h2>{rqstId ? 'Редактирование' : 'Создание'} заявки на такси</h2>
|
|
||||||
<div className="form-container form-container--medium-size form-containter--left-pos">
|
|
||||||
{/* <FormValidErr
|
|
||||||
visible = {formCreateVisible}
|
|
||||||
validErrorsObj = {formCreateValidErrObj}
|
|
||||||
/> */}
|
|
||||||
<form>
|
|
||||||
{/* ГАВРИЛОВ как защищаешься от csrf если комментируешь поле ниже? */}
|
|
||||||
{/* <input
|
|
||||||
type="hidden"
|
|
||||||
name="_token"
|
|
||||||
value={getCsrfToken()}
|
|
||||||
/> */}
|
|
||||||
<div className="form__field-block">
|
|
||||||
<Select
|
|
||||||
//ГАВРИЛОВ. ПЕРЕПИШИ НА ОПРЕДЕЛЕНИЕ НАЗВАНИЯ ПОЛЯ, СОГЛАСНО TaxiOrder_fieldName ИЗ TAXIORDERTYPE
|
|
||||||
labelText = 'Дата заказа'
|
|
||||||
options = {orderDateList}
|
|
||||||
//Гаврилов. Может где-то сверху нужно класть в объект с данными формы данные из orderData (если она есть) .тогда не нужно проверять props.rqstId ?
|
|
||||||
value = {orderData.taxi_date ? orderDateList.find(dateData => dateData.value === orderData.taxi_date) : null}
|
|
||||||
size = 'm'
|
|
||||||
onChange = {
|
|
||||||
(_, sel:{caption:string, id:string, value:string} ) => {
|
|
||||||
let selOrderDate: string|null = (sel ? sel.value : null);
|
|
||||||
//setEditOrderUserData(prevData => ({...prevData, taxi_date: selOrderDate}));
|
|
||||||
setOrderData(prevData => ( {...prevData, taxi_date: selOrderDate} ));
|
|
||||||
//Если проверка соответствия времени и даты заказа не выполняется, сбрасываем время.
|
|
||||||
// if (!checkTimeAndDate(orderData.taxi_time, selOrderDate)) {
|
|
||||||
popupContext.addPopupArrTest( [{message: 'Несоответствие времени и даты', type: 'error'}] )
|
|
||||||
// setOrderData(prevData => ( {...prevData, taxi_time: null} ));
|
|
||||||
// }
|
|
||||||
}}
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
<div className="form__field-block">
|
|
||||||
<Select
|
|
||||||
labelText = "Время заказа"
|
|
||||||
options = {orderTimeList}
|
|
||||||
value = {orderData.taxi_time ? orderTimeList.find(dateData => dateData.value === orderData.taxi_time) : null}
|
|
||||||
size = 'm'
|
|
||||||
onChange = {(_, sel:{caption:string, id:string, value:string}) => {
|
|
||||||
let selOrderTime = (sel ? sel.value : null);
|
|
||||||
setOrderData(prevData => ( {...prevData, taxi_time: selOrderTime} ));
|
|
||||||
//Проверяем относится ли выбранный промежуток времени заказа к утру или нет. Если выбран утренний промежуток, дата откуда - адрес сотрудника, адрес куда - офис, если выбран вечерний промежуток - наоборот
|
|
||||||
if (orderTimePeriods.filter( e => selOrderTime == e.time_period )[0].is_morning_time == 1) {
|
|
||||||
console.log(1)
|
|
||||||
setOrderData(prevData => ( {...prevData, taxi_address_from: editOrderUserData.emp_address, taxi_address_to: empOfficeAddress} ));
|
|
||||||
} else {
|
|
||||||
console.log(2)
|
|
||||||
console.log(empOfficeAddress)
|
|
||||||
setOrderData(prevData => ( {...prevData, taxi_address_from: empOfficeAddress, taxi_address_to: editOrderUserData.emp_address} ));
|
|
||||||
}
|
|
||||||
//Если проверка соответствия и времени заказа не выполняется, сбрасываем дату
|
|
||||||
if (!checkTimeAndDate(selOrderTime, orderData.taxi_date)) {
|
|
||||||
popupContext.addPopupArrTest(
|
|
||||||
[{message: 'Несоответствие времени и даты', type: 'error'}]
|
|
||||||
)
|
|
||||||
setOrderData(prevData => ({...prevData, taxi_date: null}));
|
|
||||||
}
|
|
||||||
}}
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
<div className="form__field-block">
|
|
||||||
<Select
|
|
||||||
labelText = 'Логин сотрудника'
|
|
||||||
options = {ccEmpList}
|
|
||||||
value = {orderData.emp_login}
|
|
||||||
size = 'm'
|
|
||||||
//В компоненте Select значение "выбранного" option помещается во второй аргумент onChange
|
|
||||||
onChange = { (_, sel:{caption:string, id:string, value:string}) => {
|
|
||||||
if (sel) {
|
|
||||||
let empData = ccEmp.filter(empData => {return empData.emp_login == sel.value})[0];
|
|
||||||
//При создании нового запроса, на этом действии время и дата могут быть уже записаны в объект editOrderUserData, но при выборе нового логина, если передать в сеттер setEditOrderUserData только объект empData, он перезапишет значения времени и даты, поэтому конкатенируем объект, отдавая приоритет при замене дублирующих значений empData (правый объект перезапишет левый)
|
|
||||||
setEditOrderUserData( {...editOrderUserData, ...empData} );
|
|
||||||
setOrderData(prevData => ({...prevData, emp_login: sel.value, emp_phone: empData.emp_phone}));
|
|
||||||
//Гаврилов. Если площадка РКЦ - выводить ошибку? Так как у этой площадки нет адреса офиса
|
|
||||||
//ГАВРИЛОВ. ВЫНЕСИ ОПРЕДЕЛЕНИЕ АДРЕСА В ОТДЕЛЬНУЮ ФУНКЦИЮ?
|
|
||||||
let officeAddress: string | null = empData.emp_area == 'РКЦ' ? null : officeAddressInfo.filter(addressInfo => addressInfo.place == empData.emp_area)[0].address;
|
|
||||||
setEmpOfficeAddress(officeAddress);
|
|
||||||
setOrderData(prevData => {
|
|
||||||
let setAddressTo: string|null, setAddressFrom: string|null;
|
|
||||||
//Если время выставлено в форме
|
|
||||||
if (orderData.taxi_time) {
|
|
||||||
//Проверяем относится ли выбранный промежуток времени заказа к утру или нет. Если выбран утренний промежуток, дата откуда - адрес сотрудника, адрес куда - офис, если выбран вечерний промежуток - наоборот
|
|
||||||
if (orderTimePeriods.filter( e => orderData.taxi_time == e.time_period )[0].is_morning_time == 1) {
|
|
||||||
setAddressTo = officeAddress;
|
|
||||||
setAddressFrom = empData.emp_address;
|
|
||||||
} else {
|
|
||||||
setAddressTo = empData.emp_address;
|
|
||||||
setAddressFrom = officeAddress;
|
|
||||||
}
|
|
||||||
//Если время заказа не выбрано, сбрасываем дату откуда и дату куда
|
|
||||||
} else {
|
|
||||||
setAddressTo = null;
|
|
||||||
setAddressFrom = null;
|
|
||||||
}
|
|
||||||
return {...prevData, taxi_address_from: setAddressFrom, taxi_address_to: setAddressTo};
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
setOrderData(prevData => ({...prevData, emp_login: null, emp_phone: null}));
|
|
||||||
setEditOrderUserData(UserData_initial);
|
|
||||||
setEmpOfficeAddress(null);
|
|
||||||
setOrderData(prevData => ({...prevData, taxi_address_from: null, taxi_address_to: null}));
|
|
||||||
}
|
|
||||||
} }
|
|
||||||
//При редактировании существующего запроса нельзя менять выбранный логин сотрудника для заказа
|
|
||||||
disabled = {rqstId ? true : false}
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
<div className="form__field-block">
|
|
||||||
<TextInput
|
|
||||||
labelText = 'ФИО'
|
|
||||||
value = {editOrderUserData.full_name}
|
|
||||||
disabled = {true}
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
<div className="form__field-block">
|
|
||||||
<TextInput
|
|
||||||
labelText = 'Мобильный номер телефона'
|
|
||||||
value = {orderData.emp_phone}
|
|
||||||
onChange = {(e: string) => {
|
|
||||||
setOrderData(prevData => ({...prevData, emp_phone: e}));
|
|
||||||
}}
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
<div className="form__field-block">
|
|
||||||
<TextInput
|
|
||||||
labelText = 'Адрес (откуда)'
|
|
||||||
value = {
|
|
||||||
//Если в пропсы передается id запроса, проставляем значение из параметров имеющегося запроса. В противном случае определяем является ли выбранный временной промежуток утренним. Если да - прописываем, что едем из адреса сотрудника, в противном случае - из офиса
|
|
||||||
//Гаврилов. Будет ли при редактировании уже созданного запроса, работать смена адресов при изменении времени запроса? Или всегда будет искаться props.rqstId и логика будет исходить из этого?
|
|
||||||
orderData.taxi_address_from
|
|
||||||
}
|
|
||||||
onChange = { (e: string) => {
|
|
||||||
setOrderData(prevData => ({...prevData, taxi_address_from: e}));
|
|
||||||
}}
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
<div className = "form__field-block">
|
|
||||||
<TextInput
|
|
||||||
labelText = 'Адрес (куда)'
|
|
||||||
value = {orderData.taxi_address_to}
|
|
||||||
onChange = {(e: string) => {
|
|
||||||
setOrderData(prevData => ({...prevData, taxi_address_to: e}));
|
|
||||||
}}
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
<div className = "order-create__btn-block">
|
|
||||||
<Button
|
|
||||||
type = 'button'
|
|
||||||
onClick = {sendTaxiOrder}
|
|
||||||
text = 'Отправить'
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
)
|
|
||||||
}
|
|
||||||
@@ -1,13 +0,0 @@
|
|||||||
import React from 'react';
|
|
||||||
import { createRoot } from 'react-dom/client';
|
|
||||||
import { AppProvider } from '../../../../../resources/js/providers/AppProvider.tsx';
|
|
||||||
import TaxiHome from '../components/TaxiHome.tsx';
|
|
||||||
|
|
||||||
const container:HTMLElement = document.getElementById('root')!;
|
|
||||||
const root = createRoot(container);
|
|
||||||
|
|
||||||
root.render(
|
|
||||||
<AppProvider>
|
|
||||||
<TaxiHome/>
|
|
||||||
</AppProvider>
|
|
||||||
);
|
|
||||||
@@ -1,37 +0,0 @@
|
|||||||
import { createRoot } from 'react-dom/client';
|
|
||||||
import React from 'react';
|
|
||||||
import '@SharePoint/rencredit_uikit/dist/static/fonts/mont/Mont.css';
|
|
||||||
import { AppProvider } from '../../../../../resources/js/providers/AppProvider.tsx';
|
|
||||||
import TaxiOrder from '../components/TaxiOrder.tsx';
|
|
||||||
|
|
||||||
const container:HTMLElement = document.getElementById('root')!;
|
|
||||||
const root = createRoot(container);
|
|
||||||
|
|
||||||
//ГАВРИЛОВ
|
|
||||||
//не забудь обернуть рендер editOrder так же в PopupProvider. И вообще это дубирование выглядит костыльно
|
|
||||||
|
|
||||||
//Гаврилов
|
|
||||||
//Спроси у дипсика насколько корректно таким образом получать аргументы из URLA
|
|
||||||
if (document.location.pathname.split('/').find(el => el === 'editOrder')) {
|
|
||||||
let rqstIdUrl = parseInt(document.location.pathname.split('/').pop());
|
|
||||||
root.render(
|
|
||||||
<AppProvider>
|
|
||||||
<TaxiOrder
|
|
||||||
rqstId = {rqstIdUrl}
|
|
||||||
/>
|
|
||||||
</AppProvider>
|
|
||||||
);
|
|
||||||
} else {
|
|
||||||
root.render(
|
|
||||||
<AppProvider>
|
|
||||||
{/* Не получится передавать контейнер попапов на этом этапе, так как компоненты приложения (формы Такси) должны иметь общего родителя с компонентом контейнеров попапов, иначе они не смогут знать через общий стейт какое состояние у набора попапов */}
|
|
||||||
{/* ГАВРИЛОВ ругается на указание параметра rqstId в TaxiPage? */}
|
|
||||||
{/* <TaxiOrderPage rqstId = {undefined}/> */}
|
|
||||||
<TaxiOrder
|
|
||||||
rqstId = {undefined}
|
|
||||||
/>
|
|
||||||
</AppProvider>
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
@@ -1,50 +0,0 @@
|
|||||||
/**
|
|
||||||
* Объект заказа такси
|
|
||||||
*/
|
|
||||||
export interface TaxiOrder_type{
|
|
||||||
id: number | null,
|
|
||||||
emp_login: string | null,
|
|
||||||
emp_phone: string | null,
|
|
||||||
taxi_date: string | null,
|
|
||||||
taxi_time: string | null,
|
|
||||||
taxi_address_from: string | null,
|
|
||||||
taxi_address_to: string | null,
|
|
||||||
cancel_rqst: boolean
|
|
||||||
};
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Тип для отображения данных по заявке на такси в таблице (есть дополнительные поля чисто для отображения)
|
|
||||||
*/
|
|
||||||
export type TaxiOrder_tableData = TaxiOrder_type & {
|
|
||||||
emp_supervisor: string | null;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Начальное состояние типа заказа такси
|
|
||||||
*/
|
|
||||||
export const TaxiOrder_initial: TaxiOrder_type = {
|
|
||||||
id: null,
|
|
||||||
emp_login: null,
|
|
||||||
emp_phone: null,
|
|
||||||
taxi_date: null,
|
|
||||||
taxi_time: null,
|
|
||||||
taxi_address_from: null,
|
|
||||||
taxi_address_to: null,
|
|
||||||
cancel_rqst: false
|
|
||||||
};
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Справочник названий полей запроса такси
|
|
||||||
* гаврилов. пересекается со свойством TaxiMain с названием полей. ПОПРАВИТЬ, РЕАЛИЗОВАВ ОБМЕН ТИПАМИ ЧЕРЕЗ СТОРОННИЙ ПАКЕТ
|
|
||||||
*/
|
|
||||||
export const TaxiOrder_fieldName = {
|
|
||||||
id: 'Номер запроса',
|
|
||||||
emp_login: 'Логин сотрудника',
|
|
||||||
emp_supervisor: 'Руководитель',
|
|
||||||
emp_phone: 'Телефон сотрудника',
|
|
||||||
taxi_date: 'Дата заказа',
|
|
||||||
taxi_time: 'Время заказа',
|
|
||||||
taxi_address_from: 'Адрес (откуда)',
|
|
||||||
taxi_address_to: 'Адрес (куда)',
|
|
||||||
cancel_rqst: 'Запрос актуален'
|
|
||||||
};
|
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
@extends('taxi::layouts.master')
|
|
||||||
|
|
||||||
@section('content')
|
|
||||||
<h1>Hello World</h1>
|
|
||||||
|
|
||||||
<p>Module: {!! config('taxi.name') !!}</p>
|
|
||||||
@endsection
|
|
||||||
@@ -1,31 +0,0 @@
|
|||||||
<!DOCTYPE html>
|
|
||||||
<html lang="{{ str_replace('_', '-', app()->getLocale()) }}">
|
|
||||||
|
|
||||||
<!-- ГАВРИЛОВ. НЕ УВЕРЕН, ЧТО ЭТО НУЖНО -->
|
|
||||||
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8">
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
||||||
<meta name="csrf-token" content="{{ csrf_token() }}">
|
|
||||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
|
||||||
|
|
||||||
<title>Taxi Module - {{ config('app.name', 'Laravel') }}</title>
|
|
||||||
|
|
||||||
<meta name="description" content="{{ $description ?? '' }}">
|
|
||||||
<meta name="keywords" content="{{ $keywords ?? '' }}">
|
|
||||||
<meta name="author" content="{{ $author ?? '' }}">
|
|
||||||
|
|
||||||
<!-- Fonts -->
|
|
||||||
<link rel="preconnect" href="https://fonts.bunny.net">
|
|
||||||
<link href="https://fonts.bunny.net/css?family=figtree:400,500,600&display=swap" rel="stylesheet" />
|
|
||||||
|
|
||||||
{{-- Vite CSS --}}
|
|
||||||
{{-- {{ module_vite('build-taxi', 'resources/assets/sass/app.scss') }} --}}
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body>
|
|
||||||
@yield('content')
|
|
||||||
|
|
||||||
{{-- Vite JS --}}
|
|
||||||
{{-- {{ module_vite('build-taxi', 'resources/assets/js/app.js') }} --}}
|
|
||||||
</body>
|
|
||||||
@@ -1,13 +0,0 @@
|
|||||||
@extends('layouts.app_main')
|
|
||||||
|
|
||||||
@section('app_styles')
|
|
||||||
@vite(['Modules/Taxi/resources/css/taxiHome.css'])
|
|
||||||
@endsection
|
|
||||||
|
|
||||||
@section('app_content')
|
|
||||||
<div id="root"></div>
|
|
||||||
@endsection
|
|
||||||
|
|
||||||
@section('app_scripts')
|
|
||||||
@vite(['Modules/Taxi/resources/js/page/taxiHomePage.tsx'])
|
|
||||||
@endsection
|
|
||||||
@@ -1,13 +0,0 @@
|
|||||||
@extends('layouts.app_main')
|
|
||||||
|
|
||||||
@section('app_styles')
|
|
||||||
@vite(['Modules/Taxi/resources/css/taxiOrder.css'])
|
|
||||||
@endsection
|
|
||||||
|
|
||||||
@section('app_content')
|
|
||||||
<div id="root"></div>
|
|
||||||
@endsection
|
|
||||||
|
|
||||||
@section('app_scripts')
|
|
||||||
@vite(['Modules/Taxi/resources/js/page/taxiOrderPage.tsx'])
|
|
||||||
@endsection
|
|
||||||
@@ -1,50 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
use App\Http\Controllers\Controller;
|
|
||||||
use Illuminate\Http\Request;
|
|
||||||
use Illuminate\Support\Facades\Route;
|
|
||||||
use Modules\Taxi\App\Http\Controllers as TaxiControllers;
|
|
||||||
|
|
||||||
/*
|
|
||||||
|--------------------------------------------------------------------------
|
|
||||||
| API Routes
|
|
||||||
|--------------------------------------------------------------------------
|
|
||||||
|
|
|
||||||
| Here is where you can register API routes for your application. These
|
|
||||||
| routes are loaded by the RouteServiceProvider within a group which
|
|
||||||
| is assigned the "api" middleware group. Enjoy building your API!
|
|
||||||
|
|
|
||||||
*/
|
|
||||||
|
|
||||||
// Route::middleware(['auth:sanctum'])->prefix('v1')->name('api.')->group(function () {
|
|
||||||
// Route::get('taxi', fn (Request $request) => $request->user())->name('taxi');
|
|
||||||
// });
|
|
||||||
|
|
||||||
Route::group([
|
|
||||||
'prefix' => 'taxi',
|
|
||||||
'middleware' => 'checkAppAccess'
|
|
||||||
],
|
|
||||||
function() {
|
|
||||||
Route::group(
|
|
||||||
['middleware' => \Modules\Taxi\App\Http\Middleware\CheckTimeRqstAvailability::class],
|
|
||||||
function() {
|
|
||||||
//Route::post('/createOrder', [TaxiControllers\TaxiController::class, 'createTaxiOrder']);
|
|
||||||
//TODO. Какая будет ошибка, если регулярка не сможет проверить переданные параметр? Можно ли ввести какую-то проверку на уровне роутинга с возвратом конкретной ошибки?
|
|
||||||
// Route::post('/editOrder/{orderId}', [TaxiControllers\TaxiController::class, 'updateTaxiOrder'])->where('orderId', '^[0-9]+$');
|
|
||||||
Route::get('/cancelRqst/{rqstId}', [TaxiControllers\TaxiController::class, 'cancelRqst'])->where('rqstId', '^[0-9]+$');
|
|
||||||
Route::post('/createRqst', [TaxiControllers\TaxiController::class, 'createTaxiOrder']);
|
|
||||||
Route::patch('/editOrder/{orderId}', [TaxiControllers\TaxiController::class, 'updateTaxiOrder'])->where('orderId', '^[0-9]+$');
|
|
||||||
});
|
|
||||||
Route::get('/getActiveOrders', [TaxiControllers\TaxiController::class, 'getActiveOrders']);
|
|
||||||
Route::post('/getFilterOrders', [TaxiControllers\TaxiController::class, 'getFilterOrders']);
|
|
||||||
Route::get('/getEmpInfo/{userLogin}', [TaxiControllers\TaxiController::class, 'getUserInfoByLogin'])->where('userLogin', '^[a-zA-Z_]+[0-9]*$');
|
|
||||||
Route::get('/getOfficeAddress/', [TaxiControllers\TaxiController::class, 'getOfficeAddress']);
|
|
||||||
#Гаврилов
|
|
||||||
//ВЫНЕСТИ ЭТОТ ЕНДПОИНТ ИЗ ГРУППЫ ТАКСИ И ВЫНЕСТИ МЕТОД ПОЛУЧЕНИЯ ВСЕХ ПОЛЬЗОВАТЕЛЕЙ ИЗ СТАРОГО МЭДЖИКА КАКИМ-ТО ОБЩИМ КОНТРОЛЛЕРОМ, СЕРВИСОМ?
|
|
||||||
Route::get('/getEmpInfo/', [TaxiControllers\TaxiController::class, 'getActiveUsersInfo']);
|
|
||||||
//Получаем временные промежутки для заказа такси
|
|
||||||
Route::get('/getTimePeriods/', [TaxiControllers\TaxiController::class, 'getTimePeriods']);
|
|
||||||
//Получаем данные по существующему заказу такси
|
|
||||||
Route::get('/getOrderById/{orderId}', [TaxiControllers\TaxiController::class, 'getOrderById'])->where('orderId', '^[0-9]+$');
|
|
||||||
}
|
|
||||||
);
|
|
||||||
@@ -1,44 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
use Illuminate\Support\Facades\Route;
|
|
||||||
use Modules\Taxi\App\Http\Controllers as TaxiControllers;
|
|
||||||
use Modules\Taxi\App\Http\Controllers\TaxiController;
|
|
||||||
|
|
||||||
/*
|
|
||||||
|--------------------------------------------------------------------------
|
|
||||||
| Web Routes
|
|
||||||
|--------------------------------------------------------------------------
|
|
||||||
|
|
|
||||||
| Here is where you can register web routes for your application. These
|
|
||||||
| routes are loaded by the RouteServiceProvider within a group which
|
|
||||||
| contains the "web" middleware group. Now create something great!
|
|
||||||
|
|
|
||||||
*/
|
|
||||||
|
|
||||||
|
|
||||||
Route::group([
|
|
||||||
'prefix' => 'taxi',
|
|
||||||
'middleware' => 'checkAppAccess'
|
|
||||||
],
|
|
||||||
function() {
|
|
||||||
Route::get('/home', function() {
|
|
||||||
return view('taxi::taxi_home');
|
|
||||||
})->name('taxi_home');
|
|
||||||
#Гаврилов
|
|
||||||
//УБЕРИ ЕНДПОИНТ
|
|
||||||
Route::get('/checkredis', [TaxiControllers\TaxiController::class, 'testRedisMethod']);
|
|
||||||
#Гаврилов
|
|
||||||
//ПОСРЕДНИК АУТЕНТИФИКАЦИИ ЗДЕСЬ БУДЕТ СРАБАТЫВАТЬ?
|
|
||||||
//внедри внутри роута проверку существует ли запрос и можно ли его редачить (заказ на сегодня + время отправки еще не подошло, либо заказ на завтра)
|
|
||||||
Route::group(['middleware' => \Modules\Taxi\App\Http\Middleware\CheckTimeRqstAvailability::class], function() {
|
|
||||||
Route::get('/editOrder/{orderId}', function() {
|
|
||||||
return view('taxi::taxi_order');
|
|
||||||
})->where('orderId', '^[0-9]+$');
|
|
||||||
Route::post('/createRqst', [TaxiControllers\TaxiController::class, 'createTaxiOrder']);
|
|
||||||
Route::post('/editOrder/{orderId}', [TaxiControllers\TaxiController::class, 'updateTaxiOrder'])->where('orderId', '^[0-9]+$');
|
|
||||||
Route::get('/createRqst', function() {
|
|
||||||
return view('taxi::taxi_order');
|
|
||||||
})->middleware('checkPermission:admin'); //ГАВРИЛОВ. НЕ ЗАБУДЬ УБРАТЬ ДОСТУП К ЭТОМУ РОУТУ ДЛЯ АДМИНОВ, ОН ДОСТУПЕН ДЛЯ ВСЕХ
|
|
||||||
});
|
|
||||||
}
|
|
||||||
);
|
|
||||||
@@ -1,26 +0,0 @@
|
|||||||
import { defineConfig } from 'vite';
|
|
||||||
import laravel from 'laravel-vite-plugin';
|
|
||||||
|
|
||||||
export default defineConfig({
|
|
||||||
build: {
|
|
||||||
outDir: '../../public/build-taxi',
|
|
||||||
emptyOutDir: true,
|
|
||||||
manifest: true,
|
|
||||||
},
|
|
||||||
plugins: [
|
|
||||||
laravel({
|
|
||||||
publicDirectory: '../../public',
|
|
||||||
buildDirectory: 'build-taxi',
|
|
||||||
input: [
|
|
||||||
__dirname + '/resources/assets/sass/app.scss',
|
|
||||||
__dirname + '/resources/assets/js/app.js'
|
|
||||||
],
|
|
||||||
refresh: true,
|
|
||||||
}),
|
|
||||||
],
|
|
||||||
});
|
|
||||||
|
|
||||||
//export const paths = [
|
|
||||||
// 'Modules/$STUDLY_NAME$/resources/assets/sass/app.scss',
|
|
||||||
// 'Modules/$STUDLY_NAME$/resources/assets/js/app.js',
|
|
||||||
//];
|
|
||||||
@@ -1,67 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Test\App\Http\Controllers;
|
|
||||||
|
|
||||||
use App\Http\Controllers\Controller;
|
|
||||||
use Illuminate\Http\RedirectResponse;
|
|
||||||
use Illuminate\Http\Request;
|
|
||||||
use Illuminate\Http\Response;
|
|
||||||
|
|
||||||
class TestController extends Controller
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Display a listing of the resource.
|
|
||||||
*/
|
|
||||||
public function index()
|
|
||||||
{
|
|
||||||
return view('test::index');
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Show the form for creating a new resource.
|
|
||||||
*/
|
|
||||||
public function create()
|
|
||||||
{
|
|
||||||
return view('test::create');
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Store a newly created resource in storage.
|
|
||||||
*/
|
|
||||||
public function store(Request $request): RedirectResponse
|
|
||||||
{
|
|
||||||
//
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Show the specified resource.
|
|
||||||
*/
|
|
||||||
public function show($id)
|
|
||||||
{
|
|
||||||
return view('test::show');
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Show the form for editing the specified resource.
|
|
||||||
*/
|
|
||||||
public function edit($id)
|
|
||||||
{
|
|
||||||
return view('test::edit');
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Update the specified resource in storage.
|
|
||||||
*/
|
|
||||||
public function update(Request $request, $id): RedirectResponse
|
|
||||||
{
|
|
||||||
//
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Remove the specified resource from storage.
|
|
||||||
*/
|
|
||||||
public function destroy($id)
|
|
||||||
{
|
|
||||||
//
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,59 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Test\App\Providers;
|
|
||||||
|
|
||||||
use Illuminate\Support\Facades\Route;
|
|
||||||
use Illuminate\Foundation\Support\Providers\RouteServiceProvider as ServiceProvider;
|
|
||||||
|
|
||||||
class RouteServiceProvider extends ServiceProvider
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* The module namespace to assume when generating URLs to actions.
|
|
||||||
*/
|
|
||||||
protected string $moduleNamespace = 'Modules\Test\App\Http\Controllers';
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Called before routes are registered.
|
|
||||||
*
|
|
||||||
* Register any model bindings or pattern based filters.
|
|
||||||
*/
|
|
||||||
public function boot(): void
|
|
||||||
{
|
|
||||||
parent::boot();
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Define the routes for the application.
|
|
||||||
*/
|
|
||||||
public function map(): void
|
|
||||||
{
|
|
||||||
$this->mapApiRoutes();
|
|
||||||
|
|
||||||
$this->mapWebRoutes();
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Define the "web" routes for the application.
|
|
||||||
*
|
|
||||||
* These routes all receive session state, CSRF protection, etc.
|
|
||||||
*/
|
|
||||||
protected function mapWebRoutes(): void
|
|
||||||
{
|
|
||||||
Route::middleware('web')
|
|
||||||
->namespace($this->moduleNamespace)
|
|
||||||
->group(module_path('Test', '/routes/web.php'));
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Define the "api" routes for the application.
|
|
||||||
*
|
|
||||||
* These routes are typically stateless.
|
|
||||||
*/
|
|
||||||
protected function mapApiRoutes(): void
|
|
||||||
{
|
|
||||||
Route::prefix('api')
|
|
||||||
->middleware('api')
|
|
||||||
->namespace($this->moduleNamespace)
|
|
||||||
->group(module_path('Test', '/routes/api.php'));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,114 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Test\App\Providers;
|
|
||||||
|
|
||||||
use Illuminate\Support\Facades\Blade;
|
|
||||||
use Illuminate\Support\ServiceProvider;
|
|
||||||
|
|
||||||
class TestServiceProvider extends ServiceProvider
|
|
||||||
{
|
|
||||||
protected string $moduleName = 'Test';
|
|
||||||
|
|
||||||
protected string $moduleNameLower = 'test';
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Boot the application events.
|
|
||||||
*/
|
|
||||||
public function boot(): void
|
|
||||||
{
|
|
||||||
$this->registerCommands();
|
|
||||||
$this->registerCommandSchedules();
|
|
||||||
$this->registerTranslations();
|
|
||||||
$this->registerConfig();
|
|
||||||
$this->registerViews();
|
|
||||||
$this->loadMigrationsFrom(module_path($this->moduleName, 'Database/migrations'));
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Register the service provider.
|
|
||||||
*/
|
|
||||||
public function register(): void
|
|
||||||
{
|
|
||||||
$this->app->register(RouteServiceProvider::class);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Register commands in the format of Command::class
|
|
||||||
*/
|
|
||||||
protected function registerCommands(): void
|
|
||||||
{
|
|
||||||
// $this->commands([]);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Register command Schedules.
|
|
||||||
*/
|
|
||||||
protected function registerCommandSchedules(): void
|
|
||||||
{
|
|
||||||
// $this->app->booted(function () {
|
|
||||||
// $schedule = $this->app->make(Schedule::class);
|
|
||||||
// $schedule->command('inspire')->hourly();
|
|
||||||
// });
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Register translations.
|
|
||||||
*/
|
|
||||||
public function registerTranslations(): void
|
|
||||||
{
|
|
||||||
$langPath = resource_path('lang/modules/'.$this->moduleNameLower);
|
|
||||||
|
|
||||||
if (is_dir($langPath)) {
|
|
||||||
$this->loadTranslationsFrom($langPath, $this->moduleNameLower);
|
|
||||||
$this->loadJsonTranslationsFrom($langPath);
|
|
||||||
} else {
|
|
||||||
$this->loadTranslationsFrom(module_path($this->moduleName, 'lang'), $this->moduleNameLower);
|
|
||||||
$this->loadJsonTranslationsFrom(module_path($this->moduleName, 'lang'));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Register config.
|
|
||||||
*/
|
|
||||||
protected function registerConfig(): void
|
|
||||||
{
|
|
||||||
$this->publishes([module_path($this->moduleName, 'config/config.php') => config_path($this->moduleNameLower.'.php')], 'config');
|
|
||||||
$this->mergeConfigFrom(module_path($this->moduleName, 'config/config.php'), $this->moduleNameLower);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Register views.
|
|
||||||
*/
|
|
||||||
public function registerViews(): void
|
|
||||||
{
|
|
||||||
$viewPath = resource_path('views/modules/'.$this->moduleNameLower);
|
|
||||||
$sourcePath = module_path($this->moduleName, 'resources/views');
|
|
||||||
|
|
||||||
$this->publishes([$sourcePath => $viewPath], ['views', $this->moduleNameLower.'-module-views']);
|
|
||||||
|
|
||||||
$this->loadViewsFrom(array_merge($this->getPublishableViewPaths(), [$sourcePath]), $this->moduleNameLower);
|
|
||||||
|
|
||||||
$componentNamespace = str_replace('/', '\\', config('modules.namespace').'\\'.$this->moduleName.'\\'.config('modules.paths.generator.component-class.path'));
|
|
||||||
Blade::componentNamespace($componentNamespace, $this->moduleNameLower);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Get the services provided by the provider.
|
|
||||||
*/
|
|
||||||
public function provides(): array
|
|
||||||
{
|
|
||||||
return [];
|
|
||||||
}
|
|
||||||
|
|
||||||
private function getPublishableViewPaths(): array
|
|
||||||
{
|
|
||||||
$paths = [];
|
|
||||||
foreach (config('view.paths') as $path) {
|
|
||||||
if (is_dir($path.'/modules/'.$this->moduleNameLower)) {
|
|
||||||
$paths[] = $path.'/modules/'.$this->moduleNameLower;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return $paths;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,16 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace Modules\Test\Database\Seeders;
|
|
||||||
|
|
||||||
use Illuminate\Database\Seeder;
|
|
||||||
|
|
||||||
class TestDatabaseSeeder extends Seeder
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Run the database seeds.
|
|
||||||
*/
|
|
||||||
public function run(): void
|
|
||||||
{
|
|
||||||
// $this->call([]);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,31 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "nwidart/test",
|
|
||||||
"description": "",
|
|
||||||
"authors": [
|
|
||||||
{
|
|
||||||
"name": "Nicolas Widart",
|
|
||||||
"email": "n.widart@gmail.com"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"extra": {
|
|
||||||
"laravel": {
|
|
||||||
"providers": [],
|
|
||||||
"aliases": {
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"autoload": {
|
|
||||||
"psr-4": {
|
|
||||||
"Modules\\Test\\": "",
|
|
||||||
"Modules\\Test\\App\\": "app/",
|
|
||||||
"Modules\\Test\\Database\\Factories\\": "database/factories/",
|
|
||||||
"Modules\\Test\\Database\\Seeders\\": "database/seeders/"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"autoload-dev": {
|
|
||||||
"psr-4": {
|
|
||||||
"Modules\\Test\\Tests\\": "tests/"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
return [
|
|
||||||
'name' => 'Test',
|
|
||||||
];
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "Test",
|
|
||||||
"alias": "test",
|
|
||||||
"description": "",
|
|
||||||
"keywords": [],
|
|
||||||
"priority": 0,
|
|
||||||
"providers": [
|
|
||||||
"Modules\\Test\\App\\Providers\\TestServiceProvider"
|
|
||||||
],
|
|
||||||
"files": []
|
|
||||||
}
|
|
||||||
@@ -1,15 +0,0 @@
|
|||||||
{
|
|
||||||
"private": true,
|
|
||||||
"type": "module",
|
|
||||||
"scripts": {
|
|
||||||
"dev": "vite",
|
|
||||||
"build": "vite build"
|
|
||||||
},
|
|
||||||
"devDependencies": {
|
|
||||||
"axios": "^1.1.2",
|
|
||||||
"laravel-vite-plugin": "^0.7.5",
|
|
||||||
"sass": "^1.69.5",
|
|
||||||
"postcss": "^8.3.7",
|
|
||||||
"vite": "^4.0.0"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
@extends('test::layouts.master')
|
|
||||||
|
|
||||||
@section('content')
|
|
||||||
<h1>Hello World</h1>
|
|
||||||
|
|
||||||
<p>Module: {!! config('test.name') !!}</p>
|
|
||||||
@endsection
|
|
||||||
@@ -1,29 +0,0 @@
|
|||||||
<!DOCTYPE html>
|
|
||||||
<html lang="{{ str_replace('_', '-', app()->getLocale()) }}">
|
|
||||||
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8">
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
||||||
<meta name="csrf-token" content="{{ csrf_token() }}">
|
|
||||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
|
||||||
|
|
||||||
<title>Test Module - {{ config('app.name', 'Laravel') }}</title>
|
|
||||||
|
|
||||||
<meta name="description" content="{{ $description ?? '' }}">
|
|
||||||
<meta name="keywords" content="{{ $keywords ?? '' }}">
|
|
||||||
<meta name="author" content="{{ $author ?? '' }}">
|
|
||||||
|
|
||||||
<!-- Fonts -->
|
|
||||||
<link rel="preconnect" href="https://fonts.bunny.net">
|
|
||||||
<link href="https://fonts.bunny.net/css?family=figtree:400,500,600&display=swap" rel="stylesheet" />
|
|
||||||
|
|
||||||
{{-- Vite CSS --}}
|
|
||||||
{{-- {{ module_vite('build-test', 'resources/assets/sass/app.scss') }} --}}
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body>
|
|
||||||
@yield('content')
|
|
||||||
|
|
||||||
{{-- Vite JS --}}
|
|
||||||
{{-- {{ module_vite('build-test', 'resources/assets/js/app.js') }} --}}
|
|
||||||
</body>
|
|
||||||
@@ -1,19 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
use Illuminate\Http\Request;
|
|
||||||
use Illuminate\Support\Facades\Route;
|
|
||||||
|
|
||||||
/*
|
|
||||||
|--------------------------------------------------------------------------
|
|
||||||
| API Routes
|
|
||||||
|--------------------------------------------------------------------------
|
|
||||||
|
|
|
||||||
| Here is where you can register API routes for your application. These
|
|
||||||
| routes are loaded by the RouteServiceProvider within a group which
|
|
||||||
| is assigned the "api" middleware group. Enjoy building your API!
|
|
||||||
|
|
|
||||||
*/
|
|
||||||
|
|
||||||
Route::middleware(['auth:sanctum'])->prefix('v1')->name('api.')->group(function () {
|
|
||||||
Route::get('test', fn (Request $request) => $request->user())->name('test');
|
|
||||||
});
|
|
||||||
@@ -1,19 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
use Illuminate\Support\Facades\Route;
|
|
||||||
use Modules\Test\App\Http\Controllers\TestController;
|
|
||||||
|
|
||||||
/*
|
|
||||||
|--------------------------------------------------------------------------
|
|
||||||
| Web Routes
|
|
||||||
|--------------------------------------------------------------------------
|
|
||||||
|
|
|
||||||
| Here is where you can register web routes for your application. These
|
|
||||||
| routes are loaded by the RouteServiceProvider within a group which
|
|
||||||
| contains the "web" middleware group. Now create something great!
|
|
||||||
|
|
|
||||||
*/
|
|
||||||
|
|
||||||
Route::group([], function () {
|
|
||||||
Route::resource('test', TestController::class)->names('test');
|
|
||||||
});
|
|
||||||
@@ -1,26 +0,0 @@
|
|||||||
import { defineConfig } from 'vite';
|
|
||||||
import laravel from 'laravel-vite-plugin';
|
|
||||||
|
|
||||||
export default defineConfig({
|
|
||||||
build: {
|
|
||||||
outDir: '../../public/build-test',
|
|
||||||
emptyOutDir: true,
|
|
||||||
manifest: true,
|
|
||||||
},
|
|
||||||
plugins: [
|
|
||||||
laravel({
|
|
||||||
publicDirectory: '../../public',
|
|
||||||
buildDirectory: 'build-test',
|
|
||||||
input: [
|
|
||||||
__dirname + '/resources/assets/sass/app.scss',
|
|
||||||
__dirname + '/resources/assets/js/app.js'
|
|
||||||
],
|
|
||||||
refresh: true,
|
|
||||||
}),
|
|
||||||
],
|
|
||||||
});
|
|
||||||
|
|
||||||
//export const paths = [
|
|
||||||
// 'Modules/$STUDLY_NAME$/resources/assets/sass/app.scss',
|
|
||||||
// 'Modules/$STUDLY_NAME$/resources/assets/js/app.js',
|
|
||||||
//];
|
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
-- custom.activity_log definition
|
||||||
|
|
||||||
|
CREATE TABLE `activity_log` (
|
||||||
|
`id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
|
||||||
|
`log_name` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||||
|
`description` text COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||||
|
`subject_type` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||||
|
`event` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||||
|
`business_event` varchar(50) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'кастомное событие',
|
||||||
|
`subject_id` bigint(20) unsigned DEFAULT NULL,
|
||||||
|
`properties` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL CHECK (json_valid(`properties`)),
|
||||||
|
`batch_uuid` char(36) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||||
|
`created_at` timestamp NULL DEFAULT NULL,
|
||||||
|
`updated_at` timestamp NULL DEFAULT NULL,
|
||||||
|
`causer_type` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||||
|
`causer_id` bigint(20) DEFAULT NULL,
|
||||||
|
PRIMARY KEY (`id`),
|
||||||
|
KEY `subject` (`subject_type`,`subject_id`),
|
||||||
|
KEY `activity_log_log_name_index` (`log_name`)
|
||||||
|
) ENGINE=InnoDB AUTO_INCREMENT=207 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||||
@@ -0,0 +1,211 @@
|
|||||||
|
INSERT INTO custom.activity_log (log_name,description,subject_type,event,business_event,subject_id,properties,batch_uuid,created_at,updated_at,causer_type,causer_id) VALUES
|
||||||
|
('default','Look mum, I logged something',NULL,NULL,'',NULL,'[]',NULL,'2025-06-19 12:42:40','2025-06-19 12:42:40',NULL,NULL),
|
||||||
|
('default','Look mum, I logged something',NULL,NULL,'',NULL,'{"key":"value"}',NULL,'2025-06-19 13:57:46','2025-06-19 13:57:46',NULL,NULL),
|
||||||
|
('module1','Look mum, I logged something',NULL,NULL,'',NULL,'[]',NULL,'2025-06-19 14:07:08','2025-06-19 14:07:08',NULL,NULL),
|
||||||
|
('default','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',5,'{"attributes":{"id":5,"emp_login":"dgavrilov","emp_phone":"9512348876","taxi_date":"2025-06-19","taxi_time":"15:15:00","taxi_address":"15:15","archive":0,"created_at":"2025-06-19T14:44:50.000000Z","updated_at":"2025-06-19T14:44:50.000000Z"}}',NULL,'2025-06-19 14:44:50','2025-06-19 14:44:50',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',9,'[]',NULL,'2025-06-19 15:03:15','2025-06-19 15:03:15',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',1,'[]',NULL,'2025-06-20 08:41:31','2025-06-20 08:41:31',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',1,'{"attributes":{"id":1,"emp_login":"dgavrilov","emp_phone":"89374370448","taxi_date":"2025-06-20","taxi_time":"15:15:00","taxi_address":"15:15","archive":0,"created_at":"2025-05-15T10:11:49.000000Z","updated_at":"2025-06-20T08:45:36.000000Z"},"old":{"id":1,"emp_login":"dgavrilov","emp_phone":"89374370448","taxi_date":"2025-06-21","taxi_time":"15:15:00","taxi_address":"15:15","archive":0,"created_at":"2025-05-15T10:11:49.000000Z","updated_at":"2025-06-20T08:41:31.000000Z"}}',NULL,'2025-06-20 08:45:36','2025-06-20 08:45:36',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',1,'{"attributes":{"taxi_date":"2025-06-21","updated_at":"2025-06-20T08:49:01.000000Z"},"old":{"taxi_date":"2025-06-20","updated_at":"2025-06-20T08:45:36.000000Z"}}',NULL,'2025-06-20 08:49:01','2025-06-20 08:49:01',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',1,'{"attributes":{"id":1,"emp_login":"dgavrilov","emp_phone":"89374370448","taxi_date":"2025-06-20","taxi_time":"15:15:00","taxi_address":"15:15","archive":0,"created_at":"2025-05-15T10:11:49.000000Z","updated_at":"2025-06-20T08:49:35.000000Z"},"old":{"id":1,"emp_login":"dgavrilov","emp_phone":"89374370448","taxi_date":"2025-06-21","taxi_time":"15:15:00","taxi_address":"15:15","archive":0,"created_at":"2025-05-15T10:11:49.000000Z","updated_at":"2025-06-20T08:49:01.000000Z"}}',NULL,'2025-06-20 08:49:35','2025-06-20 08:49:35',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',1,'{"attributes":{"taxi_date":"2025-06-21","updated_at":"2025-06-20T08:50:14.000000Z"},"old":{"taxi_date":"2025-06-20","updated_at":"2025-06-20T08:49:35.000000Z"}}',NULL,'2025-06-20 08:50:14','2025-06-20 08:50:14',NULL,NULL);
|
||||||
|
INSERT INTO custom.activity_log (log_name,description,subject_type,event,business_event,subject_id,properties,batch_uuid,created_at,updated_at,causer_type,causer_id) VALUES
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',1,'{"attributes":{"taxi_date":"2025-06-20"},"old":{"taxi_date":"2025-06-21"}}',NULL,'2025-06-20 08:54:05','2025-06-20 08:54:05',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',1,'{"attributes":{"id":1,"emp_login":"dgavrilov","emp_phone":"89374370448","taxi_date":"2025-06-21","taxi_time":"15:15:00","taxi_address":"15:15","archive":0,"created_at":"2025-05-15T10:11:49.000000Z","updated_at":"2025-06-20T09:01:24.000000Z"},"old":{"id":1,"emp_login":"dgavrilov","emp_phone":"89374370448","taxi_date":"2025-06-20","taxi_time":"15:15:00","taxi_address":"15:15","archive":0,"created_at":"2025-05-15T10:11:49.000000Z","updated_at":"2025-06-20T08:54:05.000000Z"}}',NULL,'2025-06-20 09:01:24','2025-06-20 09:01:24',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',1,'{"attributes":{"taxi_date":"2025-06-21"},"old":{"taxi_date":"2025-06-20"}}',NULL,'2025-06-20 11:08:48','2025-06-20 11:08:48',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',1,'{"attributes":{"taxi_date":"2025-06-20"},"old":{"taxi_date":"2025-06-21"}}',NULL,'2025-06-20 14:06:57','2025-06-20 14:06:57',NULL,NULL),
|
||||||
|
('default','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',1,'{"attributes":{"taxi_date":"2025-06-21"},"old":{"taxi_date":"2025-06-20"}}',NULL,'2025-06-20 14:23:37','2025-06-20 14:23:37',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',12,'{"attributes":{"id":12,"emp_login":"ymezentseva2","emp_phone":"9512348876","taxi_date":"2025-08-01","taxi_time":"15:15","taxi_address":"\\u0430\\u0434\\u0440\\u0435\\u0441","cancel_rqst":0}}',NULL,'2025-07-31 18:46:03','2025-07-31 18:46:03',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',1,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0}}',NULL,'2025-07-31 18:46:29','2025-07-31 18:46:29',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',12,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0}}',NULL,'2025-08-01 11:06:48','2025-08-01 11:06:48',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',20,'{"attributes":{"id":20,"emp_login":"ymezentseva2","emp_phone":"9512348876","taxi_date":"2025-08-02","taxi_time":"15:15","taxi_address":"\\u0430\\u0434\\u0440\\u0435\\u0441","cancel_rqst":0}}',NULL,'2025-08-01 12:12:57','2025-08-01 12:12:57',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',14,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0}}',NULL,'2025-08-01 12:49:44','2025-08-01 12:49:44',NULL,NULL);
|
||||||
|
INSERT INTO custom.activity_log (log_name,description,subject_type,event,business_event,subject_id,properties,batch_uuid,created_at,updated_at,causer_type,causer_id) VALUES
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',29,'{"attributes":{"id":29,"emp_login":"ymezentseva2","emp_phone":"9512348876","taxi_date":"2025-08-02","taxi_time":"15:15","taxi_address":"\\u0430\\u0434\\u0440\\u0435\\u0441","cancel_rqst":0}}',NULL,'2025-08-01 12:51:39','2025-08-01 12:51:39',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',33,'{"attributes":{"id":33,"emp_login":"ymezentseva2","emp_phone":"9512348876","taxi_date":"2025-08-02","taxi_time":"15:15","taxi_address":"\\u0430\\u0434\\u0440\\u0435\\u0441","cancel_rqst":0}}',NULL,'2025-08-01 15:57:11','2025-08-01 15:57:11',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',35,'{"attributes":{"id":35,"emp_login":"ymezentseva2","emp_phone":"9512348876","taxi_date":"2025-08-02","taxi_time":"15:15","taxi_address":"\\u0430\\u0434\\u0440\\u0435\\u0441","cancel_rqst":0},"user_login":"dgavrilov"}',NULL,'2025-08-01 16:47:54','2025-08-01 16:47:54',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',45,'{"attributes":{"id":45,"emp_login":"ymezentseva2","emp_phone":"9512348876","taxi_date":"2025-08-02","taxi_time":"15:15","taxi_address":"\\u0430\\u0434\\u0440\\u0435\\u0441","cancel_rqst":0}}',NULL,'2025-08-01 17:44:19','2025-08-01 17:44:19',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',55,'{"attributes":{"id":55,"emp_login":"ymezentseva2","emp_phone":"9512348876","taxi_date":"2025-08-02","taxi_time":"15:15","taxi_address":"\\u0430\\u0434\\u0440\\u0435\\u0441","cancel_rqst":0}}',NULL,'2025-08-01 19:13:22','2025-08-01 19:13:22',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',71,'{"attributes":{"id":71,"emp_login":"nrzhevskaya","emp_phone":"9611973699","taxi_date":"2025-08-01","taxi_time":"05:20","taxi_address":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u043f\\u0440-\\u0442 \\u041a\\u043b\\u044b\\u043a\\u043e\\u0432\\u0430 52, 3 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434","cancel_rqst":0}}',NULL,'2025-08-01 19:47:32','2025-08-01 19:47:32',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',72,'{"attributes":{"id":72,"emp_login":"nbabkina2","emp_phone":"9513144152","taxi_date":"2025-08-02","taxi_time":"05:20","taxi_address":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a,\\u00a0 \\u043f\\u0440-\\u0442 \\u0410. \\u0414\\u0435\\u0440\\u0438\\u0433\\u043b\\u0430\\u0437\\u043e\\u0432\\u0430, \\u0434. 93,\\u00a0 \\u043a\\u0432\\u00a0 185","cancel_rqst":0}}',NULL,'2025-08-01 20:06:14','2025-08-01 20:06:14',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',73,'{"attributes":{"id":73,"emp_login":"abarysheva","emp_phone":"9202677745","taxi_date":"2025-08-01","taxi_time":"05:20","taxi_address":"\\u041a\\u0443\\u0440\\u0441\\u043a\\u0430\\u044f \\u043e\\u0431\\u043b\\u0430\\u0441\\u0442\\u044c, \\u041a\\u0443\\u0440\\u0441\\u043a\\u0438\\u0439 \\u0440\\u0430\\u0439\\u043e\\u043d, \\u0441. \\u041e\\u0442\\u0440\\u0435\\u0448\\u043a\\u043e\\u0432\\u043e, \\u0434\\u043e\\u043c 69","cancel_rqst":0}}',NULL,'2025-08-01 20:07:49','2025-08-01 20:07:49',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',84,'{"attributes":{"id":84,"emp_login":"kelagina","emp_phone":"9207138479","taxi_date":"2025-08-01","taxi_time":"06:00","taxi_address":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a., \\u0443\\u043b. 2-\\u0430\\u044f \\u0424\\u0430\\u0442\\u0435\\u0436\\u0441\\u043a\\u0430\\u044f, \\u0434. 35","cancel_rqst":0}}',NULL,'2025-08-01 20:44:36','2025-08-01 20:44:36',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',85,'{"attributes":{"id":85,"emp_login":"tzakharova","emp_phone":"9045238279","taxi_date":"2025-08-02","taxi_time":"06:00","taxi_address":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u0412\\u0430\\u0442\\u0443\\u0442\\u0438\\u043d\\u0430 \\u0434.23, \\u043a\\u0432. 32","cancel_rqst":0}}',NULL,'2025-08-02 17:31:25','2025-08-02 17:31:25',NULL,NULL);
|
||||||
|
INSERT INTO custom.activity_log (log_name,description,subject_type,event,business_event,subject_id,properties,batch_uuid,created_at,updated_at,causer_type,causer_id) VALUES
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',86,'{"attributes":{"id":86,"emp_login":"abychkova3","emp_phone":"9023460641","taxi_date":"2025-08-02","taxi_time":"06:00","taxi_address":"test","cancel_rqst":0}}',NULL,'2025-08-02 17:33:16','2025-08-02 17:33:16',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',87,'{"attributes":{"id":87,"emp_login":"amedvedeva10","emp_phone":"79508736255","taxi_date":"2025-08-02","taxi_time":"06:00","taxi_address":"test","cancel_rqst":0}}',NULL,'2025-08-02 17:34:06','2025-08-02 17:34:06',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',88,'{"attributes":{"id":88,"emp_login":"asamokhin","emp_phone":"79950858268","taxi_date":"2025-08-02","taxi_time":"06:00","taxi_address":"test","cancel_rqst":0}}',NULL,'2025-08-02 17:35:17','2025-08-02 17:35:17',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',94,'{"attributes":{"id":94,"emp_login":"abarysheva","emp_phone":"9202677745","taxi_date":"2025-08-02","taxi_time":"06:00","taxi_address":"\\u041a\\u0443\\u0440\\u0441\\u043a\\u0430\\u044f \\u043e\\u0431\\u043b\\u0430\\u0441\\u0442\\u044c, \\u041a\\u0443\\u0440\\u0441\\u043a\\u0438\\u0439 \\u0440\\u0430\\u0439\\u043e\\u043d, \\u0441. \\u041e\\u0442\\u0440\\u0435\\u0448\\u043a\\u043e\\u0432\\u043e, \\u0434\\u043e\\u043c 69","cancel_rqst":0}}',NULL,'2025-08-02 17:47:11','2025-08-02 17:47:11',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',95,'{"attributes":{"id":95,"emp_login":"ybukreeva","emp_phone":"9207032112","taxi_date":"2025-08-02","taxi_time":"06:00","taxi_address":"\\u041a\\u0443\\u0440\\u0441\\u043a\\u0430\\u044f \\u043e\\u0431\\u043b., \\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0421\\u0443\\u043c\\u0441\\u043a\\u0430\\u044f, \\u0434. 46, \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 3, \\u043a\\u0432. 50","cancel_rqst":0}}',NULL,'2025-08-02 17:50:29','2025-08-02 17:50:29',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',85,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0}}',NULL,'2025-08-02 17:50:50','2025-08-02 17:50:50',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',96,'{"attributes":{"id":96,"emp_login":"tvavilova","emp_phone":"89624737723","taxi_date":"2025-08-02","taxi_time":"06:00","taxi_address":"\\u0423\\u043b. \\u041a\\u0443\\u043b\\u0438\\u0431\\u0438\\u043d\\u0430 \\u0434. 11 \\u043f. 2","cancel_rqst":0}}',NULL,'2025-08-02 17:55:28','2025-08-02 17:55:28',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',98,'{"attributes":{"id":98,"emp_login":"tvlasova","emp_phone":"9508720817","taxi_date":"2025-08-02","taxi_time":"06:00","taxi_address":"\\u041a\\u0443\\u0440\\u0441\\u043a\\u0430\\u044f \\u043e\\u0431\\u043b\\u0430\\u0441\\u0442\\u044c , \\u0433 \\u041a\\u0443\\u0440\\u0441\\u043a , \\u0443\\u043b \\u041c\\u0430\\u044f\\u043a\\u043e\\u0432\\u0441\\u043a\\u043e\\u0433\\u043e \\u0434 109 \\u043a\\u0432 4","cancel_rqst":0}}',NULL,'2025-08-02 17:57:49','2025-08-02 17:57:49',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',86,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0}}',NULL,'2025-08-02 17:59:21','2025-08-02 17:59:21',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',99,'{"attributes":{"id":99,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-08-02","taxi_time":"06:00","taxi_address":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"user_login":"dgavrilov"}',NULL,'2025-08-02 18:02:14','2025-08-02 18:02:14',NULL,NULL);
|
||||||
|
INSERT INTO custom.activity_log (log_name,description,subject_type,event,business_event,subject_id,properties,batch_uuid,created_at,updated_at,causer_type,causer_id) VALUES
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',100,'{"attributes":{"id":100,"emp_login":"nrzhevskaya","emp_phone":"9611973699","taxi_date":"2025-08-02","taxi_time":"06:00","taxi_address":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u043f\\u0440-\\u0442 \\u041a\\u043b\\u044b\\u043a\\u043e\\u0432\\u0430 52, 3 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434","cancel_rqst":0},"activity_log__user_login":"dgavrilov"}',NULL,'2025-08-02 18:19:56','2025-08-02 18:19:56',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',95,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0},"Custom__user_login":"dgavrilov"}',NULL,'2025-08-02 18:20:36','2025-08-02 18:20:36',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',98,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0},"Custom__user_login":"dgavrilov","Custom__test":"test"}',NULL,'2025-08-02 18:21:42','2025-08-02 18:21:42',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',99,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0},"custom_prop":{"Custom__user_login":"dgavrilov"}}',NULL,'2025-08-02 18:24:30','2025-08-02 18:24:30',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',101,'{"attributes":{"id":101,"emp_login":"tgrudkina","emp_phone":"9374230056","taxi_date":"2025-08-03","taxi_time":"06:00","taxi_address":"\\u041b\\u0430\\u0434\\u043e\\u0436\\u0441\\u043a\\u0430\\u044f, 53,\\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 2","cancel_rqst":0},"custom_props":{"custom__user_login":"dgavrilov"}}',NULL,'2025-08-03 16:04:15','2025-08-03 16:04:15',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',101,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":null}}',NULL,'2025-08-03 16:05:45','2025-08-03 16:05:45',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',101,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":null}}',NULL,'2025-08-10 17:30:01','2025-08-10 17:30:01',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',101,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-10 17:38:08','2025-08-10 17:38:08',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',101,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-10 17:40:07','2025-08-10 17:40:07',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',101,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-10 17:45:35','2025-08-10 17:45:35',NULL,NULL);
|
||||||
|
INSERT INTO custom.activity_log (log_name,description,subject_type,event,business_event,subject_id,properties,batch_uuid,created_at,updated_at,causer_type,causer_id) VALUES
|
||||||
|
('default','Look mum, I logged something',NULL,NULL,'',NULL,'[]',NULL,'2025-08-10 17:47:54','2025-08-10 17:47:54',NULL,NULL),
|
||||||
|
('default','Look mum, I logged something',NULL,NULL,'',NULL,'[]',NULL,'2025-08-10 18:12:19','2025-08-10 18:12:19',NULL,NULL),
|
||||||
|
('Shedule','Look mum, I logged something',NULL,'clear_old_Sanctum_tokens','',NULL,'[]',NULL,'2025-08-10 18:12:40','2025-08-10 18:12:40',NULL,NULL),
|
||||||
|
('Shedule','Look mum, I logged something',NULL,'clear_old_Sanctum_tokens','',NULL,'[]',NULL,'2025-08-10 18:27:55','2025-08-10 18:27:55',NULL,NULL),
|
||||||
|
('Shedule','Look mum, I logged something',NULL,'clear_old_Sanctum_tokens','',NULL,'[]',NULL,'2025-08-10 18:35:39','2025-08-10 18:35:39',NULL,NULL),
|
||||||
|
('Shedule','Look mum, I logged something',NULL,'clear_old_Sanctum_tokens','',NULL,'[]',NULL,'2025-08-10 18:36:27','2025-08-10 18:36:27',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',101,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-10 18:42:33','2025-08-10 18:42:33',NULL,NULL),
|
||||||
|
('Shedule','Look mum, I logged something',NULL,'clear_old_Sanctum_tokens','',NULL,'[]',NULL,'2025-08-11 09:42:50','2025-08-11 09:42:50',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',105,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-11 09:43:52','2025-08-11 09:43:52',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',102,'{"attributes":{"emp_phone":"9102113631"},"old":{"emp_phone":"9102113630"},"custom_props":{"custom__test":"test","custom__user_login":null}}',NULL,'2025-08-11 16:07:19','2025-08-11 16:07:19',NULL,NULL);
|
||||||
|
INSERT INTO custom.activity_log (log_name,description,subject_type,event,business_event,subject_id,properties,batch_uuid,created_at,updated_at,causer_type,causer_id) VALUES
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',102,'{"attributes":{"emp_phone":"9102113632"},"old":{"emp_phone":"9102113631"},"custom_props":{"custom__test":"test","custom__user_login":null}}',NULL,'2025-08-11 16:08:03','2025-08-11 16:08:03',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',102,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-11 16:08:32','2025-08-11 16:08:32',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',103,'{"attributes":{"emp_phone":"9045238278"},"old":{"emp_phone":"9045238279"},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilo"}}',NULL,'2025-08-11 16:39:52','2025-08-11 16:39:52',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',103,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-11 16:40:44','2025-08-11 16:40:44',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',103,'{"attributes":{"emp_phone":"9045238277"},"old":{"emp_phone":"9045238278"},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilo"}}',NULL,'2025-08-11 16:41:13','2025-08-11 16:41:13',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',103,'{"attributes":{"emp_phone":"9045238277"},"old":{"emp_phone":"9045238278"},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-11 17:02:54','2025-08-11 17:02:54',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',103,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-11 17:03:30','2025-08-11 17:03:30',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',104,'{"attributes":{"emp_phone":"9191705200"},"old":{"emp_phone":"9191705201"},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-11 17:08:34','2025-08-11 17:08:34',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',104,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-13 17:56:54','2025-08-13 17:56:54',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',104,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-17 15:45:23','2025-08-17 15:45:23',NULL,NULL);
|
||||||
|
INSERT INTO custom.activity_log (log_name,description,subject_type,event,business_event,subject_id,properties,batch_uuid,created_at,updated_at,causer_type,causer_id) VALUES
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',104,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-17 15:46:50','2025-08-17 15:46:50',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',104,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-17 15:48:44','2025-08-17 15:48:44',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',106,'{"attributes":{"id":106,"emp_login":"tgrudkina","emp_phone":"9374230056","taxi_date":"2025-08-18","taxi_time":"05:20","taxi_address":"\\u041b\\u0430\\u0434\\u043e\\u0436\\u0441\\u043a\\u0430\\u044f, 53,\\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 2","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-17 16:04:33','2025-08-17 16:04:33',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',107,'{"attributes":{"id":107,"emp_login":"lshchetinina","emp_phone":"89875140821","taxi_date":"2025-08-17","taxi_time":"05:20","taxi_address":"testodsq \\u0430\\u0434\\u0440\\u0435\\u0441","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-17 16:05:07','2025-08-17 16:05:07',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',106,'{"attributes":{"emp_phone":"9374230057"},"old":{"emp_phone":"9374230056"},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-17 16:39:13','2025-08-17 16:39:13',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',106,'{"attributes":{"emp_phone":"9374230058"},"old":{"emp_phone":"9374230057"},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-17 16:45:59','2025-08-17 16:45:59',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',106,'{"attributes":{"emp_phone":"9374230055"},"old":{"emp_phone":"9374230058"},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-17 16:53:18','2025-08-17 16:53:18',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',106,'{"attributes":{"emp_phone":"9374230054"},"old":{"emp_phone":"9374230055"},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-17 16:57:47','2025-08-17 16:57:47',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',106,'{"attributes":{"emp_phone":"9374230053"},"old":{"emp_phone":"9374230054"},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-17 16:58:04','2025-08-17 16:58:04',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',106,'{"attributes":{"emp_phone":"9374230052"},"old":{"emp_phone":"9374230053"},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-17 17:06:15','2025-08-17 17:06:15',NULL,NULL);
|
||||||
|
INSERT INTO custom.activity_log (log_name,description,subject_type,event,business_event,subject_id,properties,batch_uuid,created_at,updated_at,causer_type,causer_id) VALUES
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',108,'{"attributes":{"id":108,"emp_login":"nsubbotina2","emp_phone":"9513112628","taxi_date":"2025-08-17","taxi_time":"05:10","taxi_address":"test","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-17 17:35:38','2025-08-17 17:35:38',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',109,'{"attributes":{"id":109,"emp_login":"ogalushka","emp_phone":"9611968330","taxi_date":"2025-08-26","taxi_time":"01:15","taxi_address":"\\u041a\\u0443\\u0440\\u0441\\u043a\\u0430\\u044f \\u043e\\u0431\\u043b\\u0430\\u0441\\u0442\\u044c, \\u041a\\u0443\\u0440\\u0441\\u043a\\u0438\\u0439 \\u0440\\u0430\\u0439\\u043e\\u043d, \\u0434\\u0435\\u0440\\u0435\\u0432\\u043d\\u044f \\u0412\\u0435\\u0440\\u0445\\u043d\\u044f\\u044f \\u041c\\u0435\\u0434\\u0432\\u0435\\u0434\\u0438\\u0446\\u0430 \\u0443\\u043b. \\u0421\\u043e\\u0432\\u0435\\u0442\\u0441\\u043a\\u0430\\u044f, \\u0434\\u043e\\u043c 151","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-26 11:04:47','2025-08-26 11:04:47',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',109,'{"attributes":{"emp_phone":"9611968331"},"old":{"emp_phone":"9611968330"},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-26 11:05:30','2025-08-26 11:05:30',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',110,'{"attributes":{"id":110,"emp_login":"lalferova","emp_phone":"9308549910","taxi_date":"2025-08-26","taxi_time":"23:15","taxi_address":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 23 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-08-26 12:55:54','2025-08-26 12:55:54',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',111,'{"attributes":{"id":111,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-09-22","taxi_time":"23:15","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-09-22 10:10:18','2025-09-22 10:10:18',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',112,'{"attributes":{"id":112,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-09-24","taxi_time":"23:15","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-09-24 15:11:26','2025-09-24 15:11:26',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',113,'{"attributes":{"id":113,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-09-25","taxi_time":"23:15","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-09-25 13:08:55','2025-09-25 13:08:55',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',114,'{"attributes":{"id":114,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-09-25","taxi_time":"23:15","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-09-25 13:10:28','2025-09-25 13:10:28',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',115,'{"attributes":{"id":115,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-09-25","taxi_time":"23:15","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-09-25 13:11:56','2025-09-25 13:11:56',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',116,'{"attributes":{"id":116,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-09-25","taxi_time":"23:15","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-09-25 14:17:24','2025-09-25 14:17:24',NULL,NULL);
|
||||||
|
INSERT INTO custom.activity_log (log_name,description,subject_type,event,business_event,subject_id,properties,batch_uuid,created_at,updated_at,causer_type,causer_id) VALUES
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',117,'{"attributes":{"id":117,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-09-25","taxi_time":"23:15","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-09-25 14:41:26','2025-09-25 14:41:26',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',118,'{"attributes":{"id":118,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-09-25","taxi_time":"23:15","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-09-25 14:42:28','2025-09-25 14:42:28',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',119,'{"attributes":{"id":119,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-09-25","taxi_time":"23:15","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-09-25 14:54:44','2025-09-25 14:54:44',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',120,'{"attributes":{"id":120,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-09-25","taxi_time":"23:15","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-09-25 14:59:54','2025-09-25 14:59:54',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',121,'{"attributes":{"id":121,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-09-25","taxi_time":"23:15","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-09-25 15:30:25','2025-09-25 15:30:25',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',122,'{"attributes":{"id":122,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-09-25","taxi_time":"23:15","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-09-25 15:31:32','2025-09-25 15:31:32',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',123,'{"attributes":{"id":123,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-09-25","taxi_time":"23:15","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-09-25 15:33:40','2025-09-25 15:33:40',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',124,'{"attributes":{"id":124,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-10-21","taxi_time":"05:10","taxi_address_from":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-10-20 11:59:21','2025-10-20 11:59:21',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',124,'{"attributes":{"taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 166"},"old":{"taxi_address_from":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430"},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-10-21 17:30:19','2025-10-21 17:30:19',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',125,'{"attributes":{"id":125,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-10-23","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-10-23 16:22:49','2025-10-23 16:22:49',NULL,NULL);
|
||||||
|
INSERT INTO custom.activity_log (log_name,description,subject_type,event,business_event,subject_id,properties,batch_uuid,created_at,updated_at,causer_type,causer_id) VALUES
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',126,'{"attributes":{"id":126,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-10-24","taxi_time":"05:10","taxi_address_from":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-10-23 16:49:07','2025-10-23 16:49:07',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',126,'{"attributes":{"taxi_time":"23:15","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164"},"old":{"taxi_time":"05:10","taxi_address_from":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430"},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-10-23 17:00:18','2025-10-23 17:00:18',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',126,'{"attributes":{"taxi_time":"05:10","taxi_address_from":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430"},"old":{"taxi_time":"23:15","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164"},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-10-23 17:00:46','2025-10-23 17:00:46',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',127,'{"attributes":{"id":127,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-10-25","taxi_time":"23:15","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-10-24 08:25:06','2025-10-24 08:25:06',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',127,'{"attributes":{"emp_phone":"9308549910","taxi_time":"04:20","taxi_address_from":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430"},"old":{"emp_phone":"9308549909","taxi_time":"23:15","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164"},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-10-24 08:35:56','2025-10-24 08:35:56',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',126,'{"attributes":{"cancel_rqst":1},"old":{"cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-10-24 08:48:25','2025-10-24 08:48:25',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',128,'{"attributes":{"id":128,"emp_login":"nrzhevskaya","emp_phone":"9611973699","taxi_date":"2025-10-25","taxi_time":"23:15","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u043f\\u0440-\\u0442 \\u041a\\u043b\\u044b\\u043a\\u043e\\u0432\\u0430 52, 3 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-10-24 09:13:47','2025-10-24 09:13:47',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',129,'{"attributes":{"id":129,"emp_login":"nbabkina2","emp_phone":"9513144152","taxi_date":"2025-10-25","taxi_time":"06:00","taxi_address_from":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a,\\u00a0 \\u043f\\u0440-\\u0442 \\u0410. \\u0414\\u0435\\u0440\\u0438\\u0433\\u043b\\u0430\\u0437\\u043e\\u0432\\u0430, \\u0434. 93,\\u00a0 \\u043a\\u0432\\u00a0 185","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-10-24 10:12:26','2025-10-24 10:12:26',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',124,'{"attributes":{"taxi_date":"2025-10-24"},"old":{"taxi_date":"2025-10-25"},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-10-24 12:34:42','2025-10-24 12:34:42',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',124,'{"attributes":{"taxi_date":"2025-10-25"},"old":{"taxi_date":"2025-10-24"},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-10-24 12:35:25','2025-10-24 12:35:25',NULL,NULL);
|
||||||
|
INSERT INTO custom.activity_log (log_name,description,subject_type,event,business_event,subject_id,properties,batch_uuid,created_at,updated_at,causer_type,causer_id) VALUES
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',129,'{"attributes":{"emp_phone":"9513144153"},"old":{"emp_phone":"9513144152"},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-10-24 15:38:09','2025-10-24 15:38:09',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',124,'{"attributes":{"taxi_date":"2025-10-24"},"old":{"taxi_date":"2025-10-25"},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-10-24 15:57:37','2025-10-24 15:57:37',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',124,'{"attributes":{"taxi_date":"2025-10-25"},"old":{"taxi_date":"2025-10-24"},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-10-24 17:02:24','2025-10-24 17:02:24',NULL,NULL),
|
||||||
|
('Taxi','updated','Modules\\Taxi\\App\\Models\\TaxiMain','updated','',124,'{"attributes":{"taxi_date":"2025-10-24"},"old":{"taxi_date":"2025-10-25"},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-10-24 17:04:30','2025-10-24 17:04:30',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',130,'{"attributes":{"id":130,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-10-31","taxi_time":"00:15","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-10-31 11:34:19','2025-10-31 11:34:19',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',131,'{"attributes":{"id":131,"emp_login":"nrzhevskaya","emp_phone":"9611973699","taxi_date":"2025-11-09","taxi_time":"05:20","taxi_address_from":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u043f\\u0440-\\u0442 \\u041a\\u043b\\u044b\\u043a\\u043e\\u0432\\u0430 52, 3 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 18:24:43','2025-11-08 18:24:43',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',132,'{"attributes":{"id":132,"emp_login":"abarysheva","emp_phone":"9202677745","taxi_date":"2025-11-09","taxi_time":"05:20","taxi_address_from":"\\u041a\\u0443\\u0440\\u0441\\u043a\\u0430\\u044f \\u043e\\u0431\\u043b\\u0430\\u0441\\u0442\\u044c, \\u041a\\u0443\\u0440\\u0441\\u043a\\u0438\\u0439 \\u0440\\u0430\\u0439\\u043e\\u043d, \\u0441. \\u041e\\u0442\\u0440\\u0435\\u0448\\u043a\\u043e\\u0432\\u043e, \\u0434\\u043e\\u043c 69","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 18:33:45','2025-11-08 18:33:45',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',133,'{"attributes":{"id":133,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-09","taxi_time":"06:00","taxi_address_from":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 18:34:44','2025-11-08 18:34:44',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',134,'{"attributes":{"id":134,"emp_login":"nbabkina2","emp_phone":"9513144152","taxi_date":"2025-11-09","taxi_time":"06:00","taxi_address_from":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a,\\u00a0 \\u043f\\u0440-\\u0442 \\u0410. \\u0414\\u0435\\u0440\\u0438\\u0433\\u043b\\u0430\\u0437\\u043e\\u0432\\u0430, \\u0434. 93,\\u00a0 \\u043a\\u0432\\u00a0 185","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 18:35:28','2025-11-08 18:35:28',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',135,'{"attributes":{"id":135,"emp_login":"ybukreeva","emp_phone":"9207032112","taxi_date":"2025-11-09","taxi_time":"06:00","taxi_address_from":"\\u041a\\u0443\\u0440\\u0441\\u043a\\u0430\\u044f \\u043e\\u0431\\u043b., \\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0421\\u0443\\u043c\\u0441\\u043a\\u0430\\u044f, \\u0434. 46, \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 3, \\u043a\\u0432. 50","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 18:38:32','2025-11-08 18:38:32',NULL,NULL);
|
||||||
|
INSERT INTO custom.activity_log (log_name,description,subject_type,event,business_event,subject_id,properties,batch_uuid,created_at,updated_at,causer_type,causer_id) VALUES
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',136,'{"attributes":{"id":136,"emp_login":"elukina","emp_phone":"79051588139","taxi_date":"2025-11-09","taxi_time":"06:00","taxi_address_from":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u0425\\u0443\\u0442\\u043e\\u0440\\u0441\\u043a\\u0430\\u044f, \\u0434. 12 \\u0410, \\u043a\\u0432. 82","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 18:40:30','2025-11-08 18:40:30',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',137,'{"attributes":{"id":137,"emp_login":"lshchetinina","emp_phone":"89875140821","taxi_date":"2025-11-09","taxi_time":"06:00","taxi_address_from":"test","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041f\\u0435\\u043d\\u0437\\u044b","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 18:43:54','2025-11-08 18:43:54',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',138,'{"attributes":{"id":138,"emp_login":"lshchetinina","emp_phone":"89875140821","taxi_date":"2025-11-09","taxi_time":"06:00","taxi_address_from":"test","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041f\\u0435\\u043d\\u0437\\u044b","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 18:45:19','2025-11-08 18:45:19',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',139,'{"attributes":{"id":139,"emp_login":"lshchetinina","emp_phone":"89875140821","taxi_date":"2025-11-09","taxi_time":"06:00","taxi_address_from":"test","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041f\\u0435\\u043d\\u0437\\u044b","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 18:47:19','2025-11-08 18:47:19',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',140,'{"attributes":{"id":140,"emp_login":"gshchankina","emp_phone":"9648654220","taxi_date":"2025-11-09","taxi_time":"06:00","taxi_address_from":"gf","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041f\\u0435\\u043d\\u0437\\u044b","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 18:49:05','2025-11-08 18:49:05',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',141,'{"attributes":{"id":141,"emp_login":"gshchankina","emp_phone":"9648654220","taxi_date":"2025-11-09","taxi_time":"06:00","taxi_address_from":"gf","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041f\\u0435\\u043d\\u0437\\u044b","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 18:53:30','2025-11-08 18:53:30',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',142,'{"attributes":{"id":142,"emp_login":"gshchankina","emp_phone":"9648654220","taxi_date":"2025-11-09","taxi_time":"06:00","taxi_address_from":"gf","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041f\\u0435\\u043d\\u0437\\u044b","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 18:54:43','2025-11-08 18:54:43',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',143,'{"attributes":{"id":143,"emp_login":"lanokhina","emp_phone":"9191793910","taxi_date":"2025-11-09","taxi_time":"05:00","taxi_address_from":"\\u041a\\u0443\\u0440\\u0447\\u0430\\u0442\\u043e\\u0432\\u0441\\u043a\\u0438\\u0439 \\u0440-\\u043d \\u0441.\\u0423\\u0441\\u043f\\u0435\\u043d\\u043a\\u0430 \\u0434.2,\\u043a\\u0432.1 (\\u0447\\u0430\\u0441\\u0442\\u043d\\u044b\\u0439 \\u0434\\u043e\\u043c)","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 18:56:17','2025-11-08 18:56:17',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',144,'{"attributes":{"id":144,"emp_login":"lanokhina","emp_phone":"9191793910","taxi_date":"2025-11-09","taxi_time":"05:00","taxi_address_from":"\\u041a\\u0443\\u0440\\u0447\\u0430\\u0442\\u043e\\u0432\\u0441\\u043a\\u0438\\u0439 \\u0440-\\u043d \\u0441.\\u0423\\u0441\\u043f\\u0435\\u043d\\u043a\\u0430 \\u0434.2,\\u043a\\u0432.1 (\\u0447\\u0430\\u0441\\u0442\\u043d\\u044b\\u0439 \\u0434\\u043e\\u043c)","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 19:20:50','2025-11-08 19:20:50',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',145,'{"attributes":{"id":145,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-08","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 19:23:50','2025-11-08 19:23:50',NULL,NULL);
|
||||||
|
INSERT INTO custom.activity_log (log_name,description,subject_type,event,business_event,subject_id,properties,batch_uuid,created_at,updated_at,causer_type,causer_id) VALUES
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',146,'{"attributes":{"id":146,"emp_login":"osoldatenkova","emp_phone":"89023459514","taxi_date":"2025-11-09","taxi_time":"05:20","taxi_address_from":"test","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041f\\u0435\\u043d\\u0437\\u044b","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 19:27:26','2025-11-08 19:27:26',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',147,'{"attributes":{"id":147,"emp_login":"osoldatenkova","emp_phone":"89023459514","taxi_date":"2025-11-09","taxi_time":"05:20","taxi_address_from":"test","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041f\\u0435\\u043d\\u0437\\u044b","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 19:28:55','2025-11-08 19:28:55',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',148,'{"attributes":{"id":148,"emp_login":"tromakina","emp_phone":"9603165907","taxi_date":"2025-11-09","taxi_time":"05:10","taxi_address_from":"\\u0443\\u043b.\\u0413\\u0435\\u043d\\u0435\\u0440\\u0430\\u043b\\u0430 \\u0413\\u043b\\u0430\\u0437\\u0443\\u043d\\u043e\\u0432\\u0430, \\u0434. 5","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041f\\u0435\\u043d\\u0437\\u044b","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 19:32:38','2025-11-08 19:32:38',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',149,'{"attributes":{"id":149,"emp_login":"tromakina","emp_phone":"9603165907","taxi_date":"2025-11-09","taxi_time":"05:10","taxi_address_from":"\\u0443\\u043b.\\u0413\\u0435\\u043d\\u0435\\u0440\\u0430\\u043b\\u0430 \\u0413\\u043b\\u0430\\u0437\\u0443\\u043d\\u043e\\u0432\\u0430, \\u0434. 5","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041f\\u0435\\u043d\\u0437\\u044b","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 19:36:22','2025-11-08 19:36:22',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',150,'{"attributes":{"id":150,"emp_login":"aarkhipova6","emp_phone":"9374299849","taxi_date":"2025-11-09","taxi_time":"04:20","taxi_address_from":"\\u0443\\u043b. \\u0414\\u0437\\u0435\\u0440\\u0436\\u0438\\u043d\\u0441\\u043a\\u043e\\u0433\\u043e, \\u0434\\u043e\\u043c 21, 4 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041f\\u0435\\u043d\\u0437\\u044b","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 19:37:09','2025-11-08 19:37:09',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',151,'{"attributes":{"id":151,"emp_login":"abarysheva","emp_phone":"9202677745","taxi_date":"2025-11-09","taxi_time":"05:20","taxi_address_from":"\\u041a\\u0443\\u0440\\u0441\\u043a\\u0430\\u044f \\u043e\\u0431\\u043b\\u0430\\u0441\\u0442\\u044c, \\u041a\\u0443\\u0440\\u0441\\u043a\\u0438\\u0439 \\u0440\\u0430\\u0439\\u043e\\u043d, \\u0441. \\u041e\\u0442\\u0440\\u0435\\u0448\\u043a\\u043e\\u0432\\u043e, \\u0434\\u043e\\u043c 69","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 19:39:12','2025-11-08 19:39:12',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',152,'{"attributes":{"id":152,"emp_login":"abarysheva","emp_phone":"9202677745","taxi_date":"2025-11-09","taxi_time":"05:20","taxi_address_from":"\\u041a\\u0443\\u0440\\u0441\\u043a\\u0430\\u044f \\u043e\\u0431\\u043b\\u0430\\u0441\\u0442\\u044c, \\u041a\\u0443\\u0440\\u0441\\u043a\\u0438\\u0439 \\u0440\\u0430\\u0439\\u043e\\u043d, \\u0441. \\u041e\\u0442\\u0440\\u0435\\u0448\\u043a\\u043e\\u0432\\u043e, \\u0434\\u043e\\u043c 69","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-08 19:41:38','2025-11-08 19:41:38',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',153,'{"attributes":{"id":153,"emp_login":"ybukreeva","emp_phone":"9207032112","taxi_date":"2025-11-10","taxi_time":"05:00","taxi_address_from":"\\u041a\\u0443\\u0440\\u0441\\u043a\\u0430\\u044f \\u043e\\u0431\\u043b., \\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0421\\u0443\\u043c\\u0441\\u043a\\u0430\\u044f, \\u0434. 46, \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 3, \\u043a\\u0432. 50","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-09 11:21:23','2025-11-09 11:21:23',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',154,'{"attributes":{"id":154,"emp_login":"ybukreeva","emp_phone":"9207032112","taxi_date":"2025-11-10","taxi_time":"05:00","taxi_address_from":"\\u041a\\u0443\\u0440\\u0441\\u043a\\u0430\\u044f \\u043e\\u0431\\u043b., \\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0421\\u0443\\u043c\\u0441\\u043a\\u0430\\u044f, \\u0434. 46, \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 3, \\u043a\\u0432. 50","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-09 11:24:46','2025-11-09 11:24:46',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',155,'{"attributes":{"id":155,"emp_login":"ybukreeva","emp_phone":"9207032112","taxi_date":"2025-11-10","taxi_time":"05:20","taxi_address_from":"\\u041a\\u0443\\u0440\\u0441\\u043a\\u0430\\u044f \\u043e\\u0431\\u043b., \\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0421\\u0443\\u043c\\u0441\\u043a\\u0430\\u044f, \\u0434. 46, \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 3, \\u043a\\u0432. 50","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-09 11:26:36','2025-11-09 11:26:36',NULL,NULL);
|
||||||
|
INSERT INTO custom.activity_log (log_name,description,subject_type,event,business_event,subject_id,properties,batch_uuid,created_at,updated_at,causer_type,causer_id) VALUES
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',156,'{"attributes":{"id":156,"emp_login":"ybukreeva","emp_phone":"9207032112","taxi_date":"2025-11-10","taxi_time":"05:20","taxi_address_from":"\\u041a\\u0443\\u0440\\u0441\\u043a\\u0430\\u044f \\u043e\\u0431\\u043b., \\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0421\\u0443\\u043c\\u0441\\u043a\\u0430\\u044f, \\u0434. 46, \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 3, \\u043a\\u0432. 50","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-09 11:27:52','2025-11-09 11:27:52',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',157,'{"attributes":{"id":157,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-09","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-09 11:32:00','2025-11-09 11:32:00',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',158,'{"attributes":{"id":158,"emp_login":"ybukreeva","emp_phone":"9207032112","taxi_date":"2025-11-10","taxi_time":"05:20","taxi_address_from":"\\u041a\\u0443\\u0440\\u0441\\u043a\\u0430\\u044f \\u043e\\u0431\\u043b., \\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0421\\u0443\\u043c\\u0441\\u043a\\u0430\\u044f, \\u0434. 46, \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 3, \\u043a\\u0432. 50","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-09 11:48:23','2025-11-09 11:48:23',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',159,'{"attributes":{"id":159,"emp_login":"ybukreeva","emp_phone":"9207032112","taxi_date":"2025-11-10","taxi_time":"05:20","taxi_address_from":"\\u041a\\u0443\\u0440\\u0441\\u043a\\u0430\\u044f \\u043e\\u0431\\u043b., \\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0421\\u0443\\u043c\\u0441\\u043a\\u0430\\u044f, \\u0434. 46, \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 3, \\u043a\\u0432. 50","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-09 11:49:01','2025-11-09 11:49:01',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',160,'{"attributes":{"id":160,"emp_login":"ybukreeva","emp_phone":"9207032112","taxi_date":"2025-11-10","taxi_time":"05:20","taxi_address_from":"\\u041a\\u0443\\u0440\\u0441\\u043a\\u0430\\u044f \\u043e\\u0431\\u043b., \\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0421\\u0443\\u043c\\u0441\\u043a\\u0430\\u044f, \\u0434. 46, \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 3, \\u043a\\u0432. 50","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-09 11:49:40','2025-11-09 11:49:40',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',161,'{"attributes":{"id":161,"emp_login":"ybukreeva","emp_phone":"9207032112","taxi_date":"2025-11-10","taxi_time":"05:20","taxi_address_from":"\\u041a\\u0443\\u0440\\u0441\\u043a\\u0430\\u044f \\u043e\\u0431\\u043b., \\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0421\\u0443\\u043c\\u0441\\u043a\\u0430\\u044f, \\u0434. 46, \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 3, \\u043a\\u0432. 50","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-09 11:50:28','2025-11-09 11:50:28',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',162,'{"attributes":{"id":162,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-09","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-09 11:51:37','2025-11-09 11:51:37',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',163,'{"attributes":{"id":163,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-09","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-09 11:52:54','2025-11-09 11:52:54',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',164,'{"attributes":{"id":164,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-09","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-09 11:53:16','2025-11-09 11:53:16',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',165,'{"attributes":{"id":165,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-09","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-09 11:53:58','2025-11-09 11:53:58',NULL,NULL);
|
||||||
|
INSERT INTO custom.activity_log (log_name,description,subject_type,event,business_event,subject_id,properties,batch_uuid,created_at,updated_at,causer_type,causer_id) VALUES
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',166,'{"attributes":{"id":166,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-09","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-09 11:55:59','2025-11-09 11:55:59',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',167,'{"attributes":{"id":167,"emp_login":"ybukreeva","emp_phone":"9207032112","taxi_date":"2025-11-10","taxi_time":"05:20","taxi_address_from":"\\u041a\\u0443\\u0440\\u0441\\u043a\\u0430\\u044f \\u043e\\u0431\\u043b., \\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0421\\u0443\\u043c\\u0441\\u043a\\u0430\\u044f, \\u0434. 46, \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 3, \\u043a\\u0432. 50","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-09 11:57:03','2025-11-09 11:57:03',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',168,'{"attributes":{"id":168,"emp_login":"ybukreeva","emp_phone":"9207032112","taxi_date":"2025-11-10","taxi_time":"05:20","taxi_address_from":"\\u041a\\u0443\\u0440\\u0441\\u043a\\u0430\\u044f \\u043e\\u0431\\u043b., \\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0421\\u0443\\u043c\\u0441\\u043a\\u0430\\u044f, \\u0434. 46, \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 3, \\u043a\\u0432. 50","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-09 11:57:51','2025-11-09 11:57:51',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',169,'{"attributes":{"id":169,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-09","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-09 12:20:14','2025-11-09 12:20:14',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',170,'{"attributes":{"id":170,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-09","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-09 12:21:30','2025-11-09 12:21:30',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',171,'{"attributes":{"id":171,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-09","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-09 13:40:08','2025-11-09 13:40:08',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',172,'{"attributes":{"id":172,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-09","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-09 13:40:32','2025-11-09 13:40:32',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',173,'{"attributes":{"id":173,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-10","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-10 18:14:46','2025-11-10 18:14:46',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',174,'{"attributes":{"id":174,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-10","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-10 18:17:05','2025-11-10 18:17:05',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',175,'{"attributes":{"id":175,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-10","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-10 18:20:45','2025-11-10 18:20:45',NULL,NULL);
|
||||||
|
INSERT INTO custom.activity_log (log_name,description,subject_type,event,business_event,subject_id,properties,batch_uuid,created_at,updated_at,causer_type,causer_id) VALUES
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',176,'{"attributes":{"id":176,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-10","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-10 18:27:54','2025-11-10 18:27:54',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',177,'{"attributes":{"id":177,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-10","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-10 18:29:12','2025-11-10 18:29:12',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',178,'{"attributes":{"id":178,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-10","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-10 18:31:04','2025-11-10 18:31:04',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',179,'{"attributes":{"id":179,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-11","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-11 09:48:14','2025-11-11 09:48:14',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',180,'{"attributes":{"id":180,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-11","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-11 09:49:13','2025-11-11 09:49:13',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',181,'{"attributes":{"id":181,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-11","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-11 09:49:35','2025-11-11 09:49:35',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',182,'{"attributes":{"id":182,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-11","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-11 09:52:01','2025-11-11 09:52:01',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',183,'{"attributes":{"id":183,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-11","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-11 09:53:05','2025-11-11 09:53:05',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',184,'{"attributes":{"id":184,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-11","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-11 09:54:13','2025-11-11 09:54:13',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',185,'{"attributes":{"id":185,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-11","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-11 09:56:17','2025-11-11 09:56:17',NULL,NULL);
|
||||||
|
INSERT INTO custom.activity_log (log_name,description,subject_type,event,business_event,subject_id,properties,batch_uuid,created_at,updated_at,causer_type,causer_id) VALUES
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',186,'{"attributes":{"id":186,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-11","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-11 09:58:00','2025-11-11 09:58:00',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',187,'{"attributes":{"id":187,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-11","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-11 10:00:04','2025-11-11 10:00:04',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',188,'{"attributes":{"id":188,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-11","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-11 10:00:25','2025-11-11 10:00:25',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',189,'{"attributes":{"id":189,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-11","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-11 11:29:37','2025-11-11 11:29:37',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',190,'{"attributes":{"id":190,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-11","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-11 14:23:21','2025-11-11 14:23:21',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',191,'{"attributes":{"id":191,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-11","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-11 14:48:04','2025-11-11 14:48:04',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',192,'{"attributes":{"id":192,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-11","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-11 14:48:42','2025-11-11 14:48:42',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',193,'{"attributes":{"id":193,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-12","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-12 21:14:08','2025-11-12 21:14:08',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',194,'{"attributes":{"id":194,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-13","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-13 11:48:37','2025-11-13 11:48:37',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',195,'{"attributes":{"id":195,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-13","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-13 11:55:13','2025-11-13 11:55:13',NULL,NULL);
|
||||||
|
INSERT INTO custom.activity_log (log_name,description,subject_type,event,business_event,subject_id,properties,batch_uuid,created_at,updated_at,causer_type,causer_id) VALUES
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',196,'{"attributes":{"id":196,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-13","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-13 11:58:23','2025-11-13 11:58:23',NULL,NULL),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','',197,'{"attributes":{"id":197,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2025-11-13","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"dgavrilov"}}',NULL,'2025-11-13 11:59:40','2025-11-13 11:59:40',NULL,NULL),
|
||||||
|
('Taxi','{"action":"edit"}','Modules\\Taxi\\App\\Models\\TaxiMain','created','',213,'{"attributes":{"id":213,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2026-01-10","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"developer"}}',NULL,'2026-01-09 20:17:31','2026-01-09 20:17:31',NULL,NULL),
|
||||||
|
('Taxi','{"action":"create"}','Modules\\Taxi\\App\\Models\\TaxiMain','created','',214,'{"attributes":{"id":214,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2026-01-10","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"developer"}}',NULL,'2026-01-09 20:20:55','2026-01-09 20:20:55',NULL,NULL),
|
||||||
|
('Taxi','{"action":"create"}','Modules\\Taxi\\App\\Models\\TaxiMain','created','',215,'{"attributes":{"id":215,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2026-01-10","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"developer"}}',NULL,'2026-01-09 20:56:25','2026-01-09 20:56:25',NULL,NULL),
|
||||||
|
('Taxi','{"action":"create"}','Modules\\Taxi\\App\\Models\\TaxiMain','created','',217,'{"attributes":{"id":217,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2026-01-10","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"developer"}}',NULL,'2026-01-09 21:08:41','2026-01-09 21:08:41',NULL,NULL),
|
||||||
|
('Taxi','{"action":"create"}','Modules\\Taxi\\App\\Models\\TaxiMain','created','',218,'{"attributes":{"id":218,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2026-01-12","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"developer"}}',NULL,'2026-01-11 14:04:43','2026-01-11 14:04:43','App\\Models\\User',3),
|
||||||
|
('Taxi','{"action":"create"}','Modules\\Taxi\\App\\Models\\TaxiMain','created','create_order',221,'{"attributes":{"id":221,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2026-01-12","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test","custom__user_login":"developer"}}',NULL,'2026-01-11 14:33:32','2026-01-11 14:33:32','App\\Models\\User',3),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','create',223,'{"attributes":{"id":222,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2026-01-12","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test"}}',NULL,'2026-01-11 14:53:51','2026-01-11 14:53:51','App\\Models\\User',3),
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','create',223,'{"attributes":{"id":223,"emp_login":"lalferova","emp_phone":"9308549909","taxi_date":"2026-01-12","taxi_time":"05:10","taxi_address_from":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","taxi_address_to":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u0443\\u043b. \\u041c\\u0435\\u043d\\u0434\\u0435\\u043b\\u0435\\u0435\\u0432\\u0430, \\u0434. 24 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434 5, \\u043a\\u0432 164","cancel_rqst":0},"custom_props":{"custom__test":"test"}}',NULL,'2026-01-11 15:10:45','2026-01-11 15:10:45','App\\Models\\User',2);
|
||||||
|
INSERT INTO custom.activity_log (log_name,description,subject_type,event,business_event,subject_id,properties,batch_uuid,created_at,updated_at,causer_type,causer_id) VALUES
|
||||||
|
('Taxi','created','Modules\\Taxi\\App\\Models\\TaxiMain','created','create',224,'{"attributes":{"id":224,"emp_login":"nrzhevskaya","emp_phone":"9611973699","taxi_date":"2026-01-17","taxi_time":"05:10","taxi_address_from":"\\u0433. \\u041a\\u0443\\u0440\\u0441\\u043a, \\u043f\\u0440-\\u0442 \\u041a\\u043b\\u044b\\u043a\\u043e\\u0432\\u0430 52, 3 \\u043f\\u043e\\u0434\\u044a\\u0435\\u0437\\u0434","taxi_address_to":"\\u0430\\u0434\\u0440\\u0435\\u0441 \\u041a\\u0443\\u0440\\u0441\\u043a\\u0430","cancel_rqst":0},"custom_props":{"custom__test":"test"}}',NULL,'2026-01-16 11:51:51','2026-01-16 11:51:51','App\\Models\\User',2);
|
||||||
@@ -1,48 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace App\Console\Commands;
|
|
||||||
|
|
||||||
use Illuminate\Console\Command;
|
|
||||||
use Illuminate\Support\Facades\Log;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Базовый класс для описания команд по расписанию
|
|
||||||
* Создан, в частности, чтобы предоставить универсальный функционал для всех команд, запускаемых по расписанию
|
|
||||||
*/
|
|
||||||
abstract class BaseScheduleCommand extends Command
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Метод выполнения команды
|
|
||||||
*
|
|
||||||
* @param callable $execFunc функция с логикой выполнения команды
|
|
||||||
* @return void
|
|
||||||
*/
|
|
||||||
protected function executeCommand(callable $execFunc): void
|
|
||||||
{
|
|
||||||
try {
|
|
||||||
$execFunc();
|
|
||||||
|
|
||||||
} catch (\Throwable $th) {
|
|
||||||
$this->logExecErr($th);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Метод логирования ошибки выполнения скриптов по расписанию
|
|
||||||
*
|
|
||||||
* @param \Throwable $th
|
|
||||||
* @return void
|
|
||||||
*/
|
|
||||||
private function logExecErr(\Throwable $th): void
|
|
||||||
{
|
|
||||||
$context = [
|
|
||||||
//Скрипт откуда запустилась задача
|
|
||||||
'command' => static::class,
|
|
||||||
//Скрипт, в котором произошла ошибка
|
|
||||||
'file' => $th->getFile(),
|
|
||||||
'line' => $th->getLine(),
|
|
||||||
];
|
|
||||||
\Log::channel('schedule_err')->error($th->getMessage(), $context);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,34 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace App\Console\Commands;
|
|
||||||
|
|
||||||
use Illuminate\Console\Command;
|
|
||||||
use App\Models\TestData;
|
|
||||||
|
|
||||||
class testDataCommand extends Command
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* The name and signature of the console command.
|
|
||||||
*
|
|
||||||
* @var string
|
|
||||||
*/
|
|
||||||
protected $signature = 'data_base:test-data-command';
|
|
||||||
|
|
||||||
/**
|
|
||||||
* The console command description.
|
|
||||||
*
|
|
||||||
* @var string
|
|
||||||
*/
|
|
||||||
protected $description = 'Тестовая команда';
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Execute the console command.
|
|
||||||
*/
|
|
||||||
public function handle()
|
|
||||||
{
|
|
||||||
$testDataModel = new TestData;
|
|
||||||
$test = TestData::where('test_char', 'hellos')->get();
|
|
||||||
var_dump($test);
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,38 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace App\Console;
|
|
||||||
|
|
||||||
use Illuminate\Console\Scheduling\Schedule;
|
|
||||||
use Illuminate\Foundation\Console\Kernel as ConsoleKernel;
|
|
||||||
|
|
||||||
class Kernel extends ConsoleKernel
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Define the application's command schedule.
|
|
||||||
*/
|
|
||||||
protected function schedule(Schedule $schedule): void
|
|
||||||
{
|
|
||||||
// $schedule->command('inspire')->hourly();
|
|
||||||
//activity()->log('Look mum, I logged something');
|
|
||||||
#Гаврилов
|
|
||||||
//ПРОВЕРИТЬ, РАБОТАЕТ?
|
|
||||||
// $schedule->command('sanctum:prune-expired --hours=24')
|
|
||||||
// ->daily();
|
|
||||||
//->dailyAt('21:03');
|
|
||||||
// activity()
|
|
||||||
// ->byAnonymous()
|
|
||||||
// ->inLog('Shedule')
|
|
||||||
// ->event('clear_old_Sanctum_tokens');
|
|
||||||
$schedule->command('taxi:send-today-orders-mail')->dailyAt('08:00');
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Register the commands for the application.
|
|
||||||
*/
|
|
||||||
protected function commands(): void
|
|
||||||
{
|
|
||||||
$this->load(__DIR__.'/Commands');
|
|
||||||
|
|
||||||
require base_path('routes/console.php');
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,27 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace App\Dto;
|
|
||||||
|
|
||||||
class ApiResponseDto
|
|
||||||
{
|
|
||||||
public function __construct(
|
|
||||||
public readonly ?string $message = null,
|
|
||||||
// public readonly ?int $statusCode = 200,
|
|
||||||
public readonly mixed $data = null,
|
|
||||||
public readonly mixed $meta = null,
|
|
||||||
)
|
|
||||||
{
|
|
||||||
// return new self($this->message, $this->statusCode, $this->data, $this->meta);
|
|
||||||
}
|
|
||||||
|
|
||||||
// public static function success()
|
|
||||||
// {
|
|
||||||
// return new self($message, $data, $statusCode = 200);
|
|
||||||
// }
|
|
||||||
|
|
||||||
// public static function error()
|
|
||||||
// {
|
|
||||||
// return new self($message, $data, $statusCode = 400);
|
|
||||||
// }
|
|
||||||
|
|
||||||
}
|
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace App\Enums;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Бизнес действия, доступные для логирования через activity_log
|
|
||||||
* @author dgavrilov
|
|
||||||
*/
|
|
||||||
|
|
||||||
|
|
||||||
#Гаврилов
|
|
||||||
//ПОЛУЧИТСЯ ЛИ ПЕРЕДАТЬ НА ФРОНТ ЭТОТ ENUM
|
|
||||||
//ГАВРИЛОВ
|
|
||||||
//ИДЕНТИЧНЫЙ СПРАВОЧНИК УКАЗАН НА СТОРОНЕ react в компоненте ENTITYHISTORY. ЕСТЬ ВОЗМОЖНОСТЬ ОБЪЕДИНИТЬ ИХ?
|
|
||||||
enum LogBusinessEvents: string
|
|
||||||
{
|
|
||||||
case Create = 'create';
|
|
||||||
case Edit = 'edit';
|
|
||||||
case Archive = 'archive';
|
|
||||||
case Restore = 'restore';
|
|
||||||
case Delete = 'delete';
|
|
||||||
case Cancel = 'cancel';
|
|
||||||
|
|
||||||
public function title(): string
|
|
||||||
{
|
|
||||||
return match($this)
|
|
||||||
{
|
|
||||||
self::Create => 'создание',
|
|
||||||
self::Edit => 'редактирование',
|
|
||||||
self::Archive => 'архивация',
|
|
||||||
self::Restore => 'восстановление',
|
|
||||||
self::Delete => 'удаление',
|
|
||||||
self::Cancel => 'отмена',
|
|
||||||
};
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,30 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace App\Exceptions;
|
|
||||||
|
|
||||||
use Illuminate\Foundation\Exceptions\Handler as ExceptionHandler;
|
|
||||||
use Throwable;
|
|
||||||
|
|
||||||
class Handler extends ExceptionHandler
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* The list of the inputs that are never flashed to the session on validation exceptions.
|
|
||||||
*
|
|
||||||
* @var array<int, string>
|
|
||||||
*/
|
|
||||||
protected $dontFlash = [
|
|
||||||
'current_password',
|
|
||||||
'password',
|
|
||||||
'password_confirmation',
|
|
||||||
];
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Register the exception handling callbacks for the application.
|
|
||||||
*/
|
|
||||||
public function register(): void
|
|
||||||
{
|
|
||||||
$this->reportable(function (Throwable $e) {
|
|
||||||
//
|
|
||||||
});
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,15 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace App\Facades;
|
|
||||||
|
|
||||||
use Illuminate\Support\Facades\Facade;
|
|
||||||
use App\Services\RedisNotificationService;
|
|
||||||
|
|
||||||
class RedisNotifications extends Facade
|
|
||||||
{
|
|
||||||
protected static function getFacadeAccessor()
|
|
||||||
{
|
|
||||||
return \App\Services\RedisNotificationService::class;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -1,18 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace App\Facades;
|
|
||||||
|
|
||||||
use Illuminate\Support\Facades\Facade;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Фасад для доступа к user сервису без инъекции зависимостей
|
|
||||||
*
|
|
||||||
* @see \App\Services\UserService
|
|
||||||
*/
|
|
||||||
class UserContext extends Facade
|
|
||||||
{
|
|
||||||
protected static function getFacadeAccessor()
|
|
||||||
{
|
|
||||||
return \App\Services\UserService::class;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace App\Http\Controllers;
|
|
||||||
|
|
||||||
use Illuminate\Http\Request;
|
|
||||||
use App\Models\AccessModel;
|
|
||||||
|
|
||||||
class AccessListController extends Controller
|
|
||||||
{
|
|
||||||
public function getAccess($id = null)
|
|
||||||
{
|
|
||||||
$accessListModel = new AccessModel();
|
|
||||||
$accessListData = $accessListModel::where(['access_id' => $id])->select('access_id')->get();
|
|
||||||
if ($id) {
|
|
||||||
echo '<pre>'; var_dump($accessListData->toArray()); echo'</pre>';
|
|
||||||
} else {
|
|
||||||
var_dump($accessListModel::all());
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
public function postAccess(Request $rqst)
|
|
||||||
{
|
|
||||||
$accessListModel = new AccessModel();
|
|
||||||
$accessListModel->role = $rqst['role'];
|
|
||||||
$accessListModel->title = $rqst['title'];
|
|
||||||
$accessListModel->save();
|
|
||||||
}
|
|
||||||
|
|
||||||
public function delAccess($id)
|
|
||||||
{
|
|
||||||
$accessListModel = new AccessModel();
|
|
||||||
//$accessListModel::where(['access_id' => $id])->delete();
|
|
||||||
$accessListModel::destroy($id);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,103 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace App\Http\Controllers;
|
|
||||||
|
|
||||||
use Illuminate\Http\Request;
|
|
||||||
use Spatie\Activitylog\Models\Activity;
|
|
||||||
// use App\Services\ModuleService;
|
|
||||||
use App\Services\UserService;
|
|
||||||
use App\Facades\UserContext;
|
|
||||||
use App\Services\ApiResponder;
|
|
||||||
use App\Dto\ApiResponseDto;
|
|
||||||
use App\Enums\LogBusinessAction;
|
|
||||||
use App\Models\User;
|
|
||||||
use Illuminate\Http\JsonResponse;
|
|
||||||
|
|
||||||
class AppHistoryController extends Controller
|
|
||||||
{
|
|
||||||
public function __construct(protected ApiResponder $apiResponder)
|
|
||||||
{}
|
|
||||||
|
|
||||||
public function getAppHistory($appName, $subjectId): JsonResponse
|
|
||||||
{
|
|
||||||
#Гаврилов
|
|
||||||
//ПОКА НЕ РЕАЛИЗОВЫВАЮ ОГРАНИЧЕНИЕ ДОСТУПА К ИСТОРИИ ПО РОЛЯМ (РОЛЬ ИСТОЧНИКА ЗАПРОСА НЕ ЗАПРАШИВАЕТСЯ И НЕ ВАЛИДИРУЕТСЯ, ТОЛЬКО НАЛИЧИЕ ДОСТУПА К ПРИЛОЖЕНИЮ)
|
|
||||||
if (array_key_exists($appName, UserContext::getUserAppPermissions()) === false) {
|
|
||||||
$this->apiResponder->setDto(new ApiResponseDto('Отсутствует доступ к ресурсу'));
|
|
||||||
return response()->json($this->apiResponder->error(), 403);
|
|
||||||
}
|
|
||||||
$entityHistory = Activity::where('log_name', $appName)
|
|
||||||
->where('subject_id', $subjectId)
|
|
||||||
->get()
|
|
||||||
->toArray();
|
|
||||||
|
|
||||||
$this->apiResponder->setDto(new ApiResponseDto(null, $this->formatHistory($entityHistory)));
|
|
||||||
//echo '<pre>'; var_dump($this->apiResponder->success()); echo'</pre>';
|
|
||||||
//return $this->apiResponder->success();
|
|
||||||
// return response()->json();
|
|
||||||
return $this->apiResponder->success();
|
|
||||||
|
|
||||||
// die();
|
|
||||||
|
|
||||||
// if (empty($entityHistory)) {
|
|
||||||
// $this->apiResponder->setDto(new ApiResponseDto());
|
|
||||||
// return response()->json($this->apiResponder->error());
|
|
||||||
// }
|
|
||||||
|
|
||||||
// $this->apiResponder->setDto(new ApiResponseDto('', ));
|
|
||||||
// return response()->json($this->apiResponder->error());
|
|
||||||
|
|
||||||
// die();
|
|
||||||
// //$appName = $moduleName ?? (new ModuleService())->getModuleName();
|
|
||||||
|
|
||||||
// //echo '<pre>'; var_dump(UserService->getUserAppPermissions()); echo'</pre>';
|
|
||||||
|
|
||||||
// echo '<pre>'; var_dump($rqst->subject_id); echo'</pre>';
|
|
||||||
// echo '<pre>'; var_dump($appName); echo'</pre>';
|
|
||||||
|
|
||||||
// if (!$appName) {
|
|
||||||
// #Гаврилов
|
|
||||||
// //ВОЗВРАЩАЕМ ОШИБКУ, ЕСЛИ ИСТОРИЯ НЕ НАЙДЕНА. ИЛИ НА УРОВНЕ ФРОНТА ПРОВЕРЯЕМ ПУСТАЯ ЛИ ИСТОРИЯ И ВЫВОДИМ ВСПЛЫВАЮЩЕЕ ОКНО что "ИСТОРИЯ ОТСУТСТВУЕТ"
|
|
||||||
// return '';
|
|
||||||
// }
|
|
||||||
|
|
||||||
|
|
||||||
// return '';
|
|
||||||
// // $entityHistory = Activity::where('log_name', 'Taxi')
|
|
||||||
// // ->where('subject_id', $entityId)
|
|
||||||
// // ->get();
|
|
||||||
|
|
||||||
// // return $entityHistory;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
private function formatHistory($historyData)
|
|
||||||
{
|
|
||||||
$formattedHistory = [];
|
|
||||||
foreach ($historyData as $historyAction) {
|
|
||||||
$historyChange = [];
|
|
||||||
#Гаврилов
|
|
||||||
//ДОЛЖНО ЛОГИРОВАТЬСЯ ID АУТЕНТИФИЦИРОВАННОГО ПОЛЬЗОВАТЕЛЯ. сЕЙЧАС ЗАПИСЫВАЕМ КОЛХОЗНО В PROPERTIES.
|
|
||||||
//ПРОВЕРЬ ЧТО ДЕЛАТЬ, ЕСЛИ ПОЛЬЗОВАТЕЛЬ - API?
|
|
||||||
$historyChange['changeAction'] = $historyAction['business_event'];
|
|
||||||
$user = User::find($historyAction['causer_id']);
|
|
||||||
$login = $user->login;
|
|
||||||
$historyChange['changeAuthor'] = $login;
|
|
||||||
$actionDate = new \DateTime($historyAction['created_at']);
|
|
||||||
$historyChange['changeDate'] = $actionDate->format('d.m.Y');
|
|
||||||
$historyChange['changeTime'] = $actionDate->format('H:i:s');
|
|
||||||
$historyChange['changeDetails'] = json_encode($historyAction['properties']['attributes'], JSON_UNESCAPED_UNICODE);
|
|
||||||
$formattedHistory[] = $historyChange;
|
|
||||||
}
|
|
||||||
|
|
||||||
//ГАВРИЛОВ. СОЗДАЙ СЕРВИС. В НЕМ РЕАЛ3ИЗУЙ МЕТОДЫ НАЗНАЧЕНИЯ ЗНАЧЕНИЙ КАЖДОМУ СВОЙСТВУ ОБЪЕКТА ИСТОРИИ . ИЗ КОНТРОЛЛЕРА СОЗДАВАЙ ЭКЗЕМПЛЯР КЛАССА СЕРВИСА. В КОНТРОЛЛЕРЕ СЕРВИСА ПО ОЧЕРЕДИ ВЫЗЫВАЙ ВСЕ МЕТОДЫ НАЗНАЧЕНИЯ СВОЙСТВ ИСТОРИИ.
|
|
||||||
|
|
||||||
|
|
||||||
return $formattedHistory;
|
|
||||||
//changeAction: string, //Совершенное действие: создание, удаление, редактирование, архивирование и т.д.
|
|
||||||
// changeAuthor: string, //Автор изменения: логин, сервисная УЗ
|
|
||||||
// changeDate: Date //Объект даты изменения. В объекте будет либо время (тогда показываем), либо время будет отсутствовать (тогда не показываем) //что будем передавать? объект new Date или библиотечный объект для работы с датами?
|
|
||||||
// changeTime?: string //Время изменений. Передавать не нужно, на этабе сборки компонента будет формироваться на основе пропса changeDate
|
|
||||||
// changeDetails?: HistoryEntityElDetails[]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,28 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace App\Http\Controllers;
|
|
||||||
|
|
||||||
use Illuminate\Http\Request;
|
|
||||||
use App\Services\AuthorizationService;
|
|
||||||
use App\Facades\UserContext;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Контроллер авторизации
|
|
||||||
*/
|
|
||||||
class AuthorizationController extends Controller
|
|
||||||
{
|
|
||||||
public function __construct(AuthorizationService $authorizationService)
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
public function getUserRole($moduleName)
|
|
||||||
{
|
|
||||||
$userPermissions = UserContext::getUserAppPermissions();
|
|
||||||
//Проверяем есть ли у пользователя в принципе доступ к приложению
|
|
||||||
if (array_key_exists($moduleName, $userPermissions) !== false) {
|
|
||||||
return response()->json(['userRole' => $userPermissions[$moduleName]], 403);
|
|
||||||
} else {
|
|
||||||
return response()->json(['message' => 'Приложение недоступно'], 403);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,12 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace App\Http\Controllers;
|
|
||||||
|
|
||||||
use Illuminate\Foundation\Auth\Access\AuthorizesRequests;
|
|
||||||
use Illuminate\Foundation\Validation\ValidatesRequests;
|
|
||||||
use Illuminate\Routing\Controller as BaseController;
|
|
||||||
|
|
||||||
class Controller extends BaseController
|
|
||||||
{
|
|
||||||
use AuthorizesRequests, ValidatesRequests;
|
|
||||||
}
|
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user