Proyectos de Subversion LeadersLinked - Services

Rev

Rev 121 | Rev 124 | Ir a la última revisión | | Comparar con el anterior | Ultima modificación | Ver Log |

Rev Autor Línea Nro. Línea
1 efrain 1
<?php
2
 
3
declare(strict_types=1);
4
 
5
namespace LeadersLinked\Controller;
6
 
7
use Laminas\Db\Adapter\AdapterInterface;
8
 
9
use Laminas\Mvc\Controller\AbstractActionController;
10
use Laminas\Log\LoggerInterface;
11
use Laminas\View\Model\ViewModel;
12
use Laminas\View\Model\JsonModel;
13
use LeadersLinked\Mapper\UserMapper;
14
use LeadersLinked\Mapper\CalendarEventMapper;
15
use LeadersLinked\Mapper\ZoomMeetingMapper;
16
use LeadersLinked\Model\CalendarEvent;
17
use LeadersLinked\Library\Functions;
18
use LeadersLinked\Mapper\PerformanceEvaluationTestMapper;
19
use LeadersLinked\Mapper\PerformanceEvaluationFormMapper;
20
use LeadersLinked\Model\PerformanceEvaluationTest;
21
use LeadersLinked\Mapper\JobDescriptionMapper;
22
use LeadersLinked\Mapper\CompanyUserMapper;
23
use LeadersLinked\Model\CompanyUser;
24
use LeadersLinked\Mapper\CompanyMapper;
25
use LeadersLinked\Mapper\RecruitmentSelectionInterviewMapper;
26
use LeadersLinked\Mapper\RecruitmentSelectionCandidateMapper;
27
use LeadersLinked\Mapper\RecruitmentSelectionVacancyMapper;
28
use LeadersLinked\Model\RecruitmentSelectionInterview;
29
use Laminas\Mvc\I18n\Translator;
30
use LeadersLinked\Cache\CacheInterface;
31
use LeadersLinked\Mapper\SurveyTestMapper;
32
use LeadersLinked\Mapper\SurveyCampaignMapper;
33
 
34
 
35
class CalendarController extends AbstractActionController
36
{
37
    /**
38
     *
39
     * @var \Laminas\Db\Adapter\AdapterInterface
40
     */
41
    private $adapter;
42
 
43
    /**
44
     *
45
     * @var \LeadersLinked\Cache\CacheInterface
46
     */
47
    private $cache;
48
 
49
 
50
    /**
51
     *
52
     * @var \Laminas\Log\LoggerInterface
53
     */
54
    private $logger;
55
 
56
    /**
57
     *
58
     * @var array
59
     */
60
    private $config;
61
 
62
 
63
    /**
64
     *
65
     * @var \Laminas\Mvc\I18n\Translator
66
     */
67
    private $translator;
68
 
69
 
70
    /**
71
     *
72
     * @param \Laminas\Db\Adapter\AdapterInterface $adapter
73
     * @param \LeadersLinked\Cache\CacheInterface $cache
74
     * @param \Laminas\Log\LoggerInterface LoggerInterface $logger
75
     * @param array $config
76
     * @param \Laminas\Mvc\I18n\Translator $translator
77
     */
78
    public function __construct($adapter, $cache, $logger, $config, $translator)
79
    {
80
        $this->adapter      = $adapter;
81
        $this->cache        = $cache;
82
        $this->logger       = $logger;
83
        $this->config       = $config;
84
        $this->translator   = $translator;
85
    }
86
 
87
 
88
 
89
    public function indexAction()
90
    {
91
        return new JsonModel([
92
            'success' => false,
93
            'data' => 'ERROR_METHOD_NOT_ALLOWED'
94
        ]);
95
    }
96
 
97
 
98
 
99
 
100
    public function eventsAction()
101
    {
102
 
103
        $request = $this->getRequest();
104
        if($request->isGet()) {
105
 
106
            $currentUserPlugin = $this->plugin('currentUserPlugin');
107
            $currentUser = $currentUserPlugin->getUser();
108
 
109
            $currentNetworkPlugin = $this->plugin('currentNetworkPlugin');
110
            $currentNetwork = $currentNetworkPlugin->getNetwork();
111
 
112
 
113
 
114
            $start  = $this->params()->fromQuery('start');
115
            $end    = $this->params()->fromQuery('end');
116
 
117
            if(!empty($start) && !empty($end)) {
118
 
119
                $dtStart = \DateTime::createFromFormat('Y-m-d', $start);
120
                $dtEnd = \DateTime::createFromFormat('Y-m-d', $end);
121
            } else {
122
                $dtStart = null;
123
                $dtEnd = null;
124
            }
125
 
126
            if(!$dtStart || !$dtEnd) {
127
              $t = time();
128
              $year = intval(date('Y', $t), 10);
129
              $month = intval(date('m', $t), 10);
130
              $last_day = intval(date('t', $t), 10);
131
 
132
              $start = mktime(0, 0, 0, $month, 1, $year);
133
              $start = date('Y-m-d H:i:s');
134
 
135
              $end = mktime(23, 56, 59, $month, $last_day, $year);
136
              $end = date('Y-m-d H:i:s');
137
 
138
            } else {
139
                $dtStart->setTime(0, 0, 0);
140
                $start = $dtStart->format('Y-m-d H:i:s');
141
 
142
                $dtEnd->setTime(23, 59, 59);
143
                $end  = $dtEnd->format('Y-m-d H:i:s');
144
            }
145
 
146
 
147
            $events = [];
148
 
149
 
150
 
151
            //3 días
152
            $expirePeriod = 86400 * 3;
153
            $t1 = time();
154
 
155
 
156
            $companies = [];
157
            $companyMapper = CompanyMapper::getInstance($this->adapter);
158
 
159
            $companyUsers = [];
160
            $companyUserMapper = CompanyUserMapper::getInstance($this->adapter);
161
            $records = $companyUserMapper->fetchAllByUserId($currentUser->id);
162
 
163
            foreach($records as $record) {
164
                $companyUsers[$record->company_id] = $record->backend == CompanyUser::BACKEND_YES;
165
             }
166
 
167
 
168
 
169
 
170
 
171
 
172
            $zoomMeetingMapper = ZoomMeetingMapper::getInstance($this->adapter);
173
            $recruitmentSelectionCandidateMapper = RecruitmentSelectionCandidateMapper::getInstance($this->adapter);
174
            $recruitmentSelectionVacancyMapper = RecruitmentSelectionVacancyMapper::getInstance($this->adapter);
175
            $recruitmentSelectionInterviewMapper = RecruitmentSelectionInterviewMapper::getInstance($this->adapter);
176
            $performanceEvaluationTestMapper = PerformanceEvaluationTestMapper::getInstance($this->adapter);
177
            $performanceEvaluationFormMapper = PerformanceEvaluationFormMapper::getInstance($this->adapter);
178
            $jobDescriptionMapper = JobDescriptionMapper::getInstance($this->adapter);
179
            $userMapper = UserMapper::getInstance($this->adapter);
180
 
181
            $calendarEventMapper = CalendarEventMapper::getInstance($this->adapter);
182
            $records = $calendarEventMapper->fetchAllByUserIdAndStartTimeAndEndTime($currentUser->id, $start, $end);
183
 
123 efrain 184
 
185
            print_r($records); exit;
186
 
1 efrain 187
            foreach($records as $record)
188
            {
189
                switch($record->type)
190
                {
191
                    case CalendarEvent::TYPE_SURVEY_NORMAL:
192
                        $backgroundColor = $currentNetwork->css_calendar_survey_bg_color;
193
                        $textColor = $currentNetwork->css_calendar_survey_text_color;
194
 
195
                        $surveyTestMapper = SurveyTestMapper::getInstance($this->adapter);
196
                        $surveyTest = $surveyTestMapper->fetchOne($record->relational_id);
197
 
198
                        if($surveyTest && $surveyTest->user_id == $currentUser->id) {
199
 
200
                            $surveyCampaingMapper = SurveyCampaignMapper::getInstance($this->adapter);
201
                            $surveyCampaing = $surveyCampaingMapper->fetchOne($surveyTest->campaign_id);
202
 
203
                            $url = '';
204
                            $hasLink = !empty($companyUsers[$surveyTest->company_id]);
205
 
206
                            if ($hasLink) {
207
 
208
                                if (!isset($companies[$surveyTest->company_id])) {
209
                                    $company  = $companyMapper->fetchOne($surveyTest->company_id);
210
 
211
                                    $companies[$company->id]  = $company;
212
                                } else {
213
                                    $company = $companies[$surveyTest->company_id];
214
                                }
215
 
216
 
217
                                $url = $this->url()->fromRoute('backend/signin-company', [
218
                                    'id' => $company->uuid,
219
                                    'relational' => $surveyTest->uuid,
220
                                    'type' => CalendarEvent::TYPE_SURVEY_ORGANIZATIONAL_CLIMATE,
221
                                ]);
222
                            }
223
 
224
                            $dtStart = \DateTime::createFromFormat('Y-m-d', $surveyCampaing->end_date);
225
 
226
 
227
                            array_push($events, [
228
                                'id'                => $surveyTest->uuid,
229
                                'title'             => $surveyCampaing->name,
230
                                'start'             => $dtStart->format('d/m/Y'),
231
                                'url'               => $url,
232
                                'backgroundColor'   => $backgroundColor,
233
                                'textColor'         => $textColor,
234
                                'allDay'            => true,
235
                                'type'              => 'task',
236
                            ]);
237
                        }
238
 
239
                        break;
240
 
241
                    case CalendarEvent::TYPE_SURVEY_ORGANIZATIONAL_CLIMATE:
242
                        $backgroundColor = $currentNetwork->css_calendar_organizational_climate_bg_color;
243
                        $textColor = $currentNetwork->css_calendar_organizational_climate_text_color;
244
 
245
                        $surveyTestMapper = SurveyTestMapper::getInstance($this->adapter);
246
                        $surveyTest = $surveyTestMapper->fetchOne($record->relational_id);
247
 
248
                        if($surveyTest && $surveyTest->user_id == $currentUser->id) {
249
 
250
                            $surveyCampaingMapper = SurveyCampaignMapper::getInstance($this->adapter);
251
                            $surveyCampaing = $surveyCampaingMapper->fetchOne($surveyTest->campaign_id);
252
 
253
                            $url = '';
254
                            $hasLink = !empty($companyUsers[$surveyTest->company_id]);
255
 
256
                            if ($hasLink) {
257
 
258
                                if (!isset($companies[$surveyTest->company_id])) {
259
                                    $company  = $companyMapper->fetchOne($surveyTest->company_id);
260
 
261
                                    $companies[$company->id]  = $company;
262
                                } else {
263
                                    $company = $companies[$surveyTest->company_id];
264
                                }
265
 
266
 
267
                                $url = $this->url()->fromRoute('backend/signin-company', [
268
                                    'id' => $company->uuid,
269
                                    'relational' => $surveyTest->uuid,
270
                                    'type' => CalendarEvent::TYPE_SURVEY_ORGANIZATIONAL_CLIMATE,
271
                                ]);
272
                            }
273
 
274
                            $dtStart = \DateTime::createFromFormat('Y-m-d', $surveyCampaing->end_date);
275
 
276
 
277
                            array_push($events, [
278
                                'id'                => $surveyTest->uuid,
279
                                'title'             => $surveyCampaing->name,
280
                                'start'             => $dtStart->format('d/m/Y'),
281
                                'url'               => $url,
282
                                'backgroundColor'   => $backgroundColor,
283
                                'textColor'         => $textColor,
284
                                'allDay'            => true,
285
                                'type'              => 'task',
286
                            ]);
287
                        }
288
 
289
                        break;
290
 
291
 
292
 
293
 
294
 
295
                    case CalendarEvent::TYPE_RECRUITMENT_SELECTION_INTERVIEW  :
296
                        $backgroundColor = $currentNetwork->css_calendar_recruitment_and_selection_bg_color ;
297
                        $textColor = $currentNetwork->css_calendar_recruitment_and_selection_text_color;
298
 
299
 
300
                        $recruitmentSelectionInterview = $recruitmentSelectionInterviewMapper->fetchOne($record->relational_id);
301
                        if($recruitmentSelectionInterview) {
302
 
303
                            $recruitmentSelectionVacancy = $recruitmentSelectionVacancyMapper->fetchOne($recruitmentSelectionInterview->vacancy_id);
304
 
305
 
306
 
307
                            $recruitmentSelectionCandidate = $recruitmentSelectionCandidateMapper->fetchOne($recruitmentSelectionInterview->candidate_id);
308
                            if($recruitmentSelectionVacancy && $recruitmentSelectionCandidate) {
309
                                $jobDescription = $jobDescriptionMapper->fetchOne($recruitmentSelectionVacancy->job_description_id);
310
                                if($jobDescription) {
311
                                    $url = '';
312
                                    $hasLink = !empty($companyUsers[$recruitmentSelectionInterview->company_id]);
313
 
314
 
315
 
316
                                    if($hasLink) {
317
 
318
                                        if(!isset($companies[$recruitmentSelectionInterview->company_id])) {
319
                                            $company  = $companyMapper->fetchOne($recruitmentSelectionInterview->company_id);
320
 
321
                                            $companies[ $company->id ]  = $company;
322
                                        } else {
323
                                            $company = $companies[ $recruitmentSelectionInterview->company_id ];
324
                                        }
325
 
326
 
327
                                        $url = $this->url()->fromRoute('backend/signin-company', [
328
                                            'id' => $company->uuid,
329
                                            'relational' => $recruitmentSelectionInterview->uuid,
330
                                            'type' => CalendarEvent::TYPE_RECRUITMENT_SELECTION_INTERVIEW
331
                                        ]);
332
                                    }
333
 
334
                                    $agenda = " LABEL_RECRUITMENT_SELECTION_JOB_DESCRIPTION : " . $jobDescription->name . "<br>";
335
                                    switch($recruitmentSelectionInterview->type)
336
                                    {
337
                                        case RecruitmentSelectionInterview::TYPE_BOSS :
338
                                            $agenda .= " LABEL_RECRUITMENT_SELECTION_TYPE : LABEL_RECRUITMENT_SELECTION_TYPE_BOSS_INTERVIEW <br>";
339
                                            break;
340
 
341
                                        case RecruitmentSelectionInterview::TYPE_HUMAN_RESOURCE :
342
                                            $agenda .= " LABEL_RECRUITMENT_SELECTION_TYPE : LABEL_RECRUITMENT_SELECTION_TYPE_HUMAN_RESOURCE <br>";
343
                                            break;
344
                                    }
345
 
346
                                    $agenda .= " LABEL_RECRUITMENT_SELECTION_CANDIDATE : " . trim($recruitmentSelectionCandidate->first_name . ' ' . $recruitmentSelectionCandidate->last_name) . " <br>";
347
 
348
 
349
 
350
                                    $dtStart = \DateTime::createFromFormat('Y-m-d', $recruitmentSelectionInterview->last_date);
351
                                    $agenda .= " LABEL_PERFORMANCE_EVALUATION_LAST_DATE : " . $dtStart->format('Y-m-d') . "<br>" ;
352
 
353
 
354
                                    array_push($events, [
355
                                        'id'                => $recruitmentSelectionInterview->uuid,
356
                                        'title'             => $recruitmentSelectionVacancy->name,
357
                                        'agenda'            => $agenda,
358
                                        'url'               => $url,
359
                                        'start'             => $dtStart->format('Y-m-d'),
360
                                        'url'               => '',
361
                                        'backgroundColor'   => $backgroundColor,
362
                                        'textColor'         => $textColor,
363
                                        'allDay'            => true,
364
                                        'type'              => 'task',
365
                                    ]);
366
                                }
367
                            }
368
                        }
369
 
370
 
371
                        break;
372
 
373
                    case CalendarEvent::TYPE_PERFORMANCE_EVALUATION :
374
 
375
 
376
                        $backgroundColor = $currentNetwork->css_calendar_performance_evaluation_bg_color ;
377
                        $textColor = $currentNetwork->css_calendar_performance_evaluation_text_color;
378
 
379
 
380
                        $performanceEvaluationTest = $performanceEvaluationTestMapper->fetchOne($record->relational_id);
381
                        if($performanceEvaluationTest) {
382
 
383
 
384
 
385
                            $performanceEvaluationForm = $performanceEvaluationFormMapper->fetchOne($performanceEvaluationTest->form_id);
386
                            if($performanceEvaluationForm) {
387
                                $jobDescription = $jobDescriptionMapper->fetchOne($performanceEvaluationForm->job_description_id);
388
                                if($jobDescription) {
389
                                    $url = '';
390
                                    if($performanceEvaluationTest->supervisor_id) {
391
                                        $supervisor = $userMapper->fetchOne($performanceEvaluationTest->supervisor_id);
392
                                    } else {
393
                                        $supervisor = '';
394
                                    }
395
 
396
                                    if($performanceEvaluationTest->employee_id) {
397
                                        $employee = $userMapper->fetchOne($performanceEvaluationTest->employee_id);
398
                                    } else {
399
                                        $employee = '';
400
                                    }
401
 
402
 
403
                                    $hasLink = !empty($companyUsers[$performanceEvaluationTest->company_id]);
404
 
405
                                    switch ($performanceEvaluationTest->type)
406
                                    {
407
                                        case PerformanceEvaluationTest::TYPE_SUPERVISOR :
408
                                        case PerformanceEvaluationTest::TYPE_BOTH  :
409
                                            if($performanceEvaluationTest->supervisor_id != $currentUser->id) {
410
                                                $hasLink = false;
411
                                            }
412
                                            break;
413
 
414
                                        case  PerformanceEvaluationTest::TYPE_EMPLOYEE  :
415
                                            if($performanceEvaluationTest->employee_id != $currentUser->id) {
416
                                                $hasLink = false;
417
                                            }
418
                                            break;
419
 
420
                                        default :
421
                                            $hasLink = false;
422
                                            break;
423
                                    }
424
 
425
 
426
 
427
                                    if($hasLink) {
428
 
429
                                        if(!isset($companies[$performanceEvaluationTest->company_id])) {
430
                                            $company  = $companyMapper->fetchOne($performanceEvaluationTest->company_id);
431
 
432
                                            $companies[ $company->id ]  = $company;
433
                                        } else {
434
                                            $company = $companies[ $performanceEvaluationTest->company_id ];
435
                                        }
436
 
437
 
438
                                        $url = $this->url()->fromRoute('backend/signin-company', [
439
                                            'id' => $company->uuid,
440
                                            'relational' => $performanceEvaluationTest->uuid,
441
                                            'type' => CalendarEvent::TYPE_PERFORMANCE_EVALUATION
442
                                        ]);
443
 
444
 
445
 
446
                                    }
447
 
448
                                    $agenda = " LABEL_PERFORMANCE_EVALUATION_FORM_NAME : " . $performanceEvaluationForm->name . "<br>";
449
                                    $agenda .= " LABEL_PERFORMANCE_EVALUATION_JOB_DESCRIPTION : " . $jobDescription->name . "<br>";
450
 
451
                                    switch($performanceEvaluationTest->type)
452
                                    {
453
                                        case PerformanceEvaluationTest::TYPE_BOTH :
454
                                            $agenda .= " LABEL_PERFORMANCE_EVALUATION_TYPE : LABEL_PERFORMANCE_EVALUATION_TYPE_BOTH <br>";
455
                                            break;
456
 
457
                                        case PerformanceEvaluationTest::TYPE_SUPERVISOR :
458
                                            $agenda .= " LABEL_PERFORMANCE_EVALUATION_TYPE : LABEL_PERFORMANCE_EVALUATION_TYPE_SUPERVISOR <br>";
459
                                            break;
460
 
461
                                        case PerformanceEvaluationTest::TYPE_EMPLOYEE :
462
                                            $agenda .= " LABEL_PERFORMANCE_EVALUATION_TYPE : LABEL_PERFORMANCE_EVALUATION_TYPE_EMPLOYEE <br>";
463
                                            break;
464
 
465
 
466
                                    }
467
 
468
                                    if($supervisor) {
469
                                        $agenda .= " LABEL_PERFORMANCE_EVALUATION_SUPERVISOR : " . trim($supervisor->first_name . ' ' . $supervisor->last_name) . " <br>";
470
 
471
                                    }
472
                                    if($employee) {
473
                                        $agenda .= " LABEL_PERFORMANCE_EVALUATION_EMPLOYEE : " . trim($employee->first_name . ' ' . $employee->last_name) . " <br>";
474
 
475
                                    }
476
 
477
                                    $dtStart = \DateTime::createFromFormat('Y-m-d', $performanceEvaluationTest->last_date);
478
                                    $agenda .= " LABEL_PERFORMANCE_EVALUATION_LAST_DATE : " . $dtStart->format('Y-m-d') . "<br>" ;
479
 
480
 
481
 
482
                                    array_push($events, [
483
                                        'id'                => $performanceEvaluationTest->uuid,
484
                                        'title'             =>  $performanceEvaluationForm->name,
485
                                        'agenda'            => $agenda,
486
                                        'start'             => $dtStart->format('Y-m-d'),
487
                                        'url'               => $url,
488
                                        'backgroundColor'   => $backgroundColor,
489
                                        'textColor'         => $textColor,
490
                                        'allDay'            => true,
491
                                        'type'              => 'task',
492
                                    ]);
493
                                }
494
                            }
495
 
496
                        }
497
 
498
 
499
 
500
 
501
 
502
                        break;
503
 
504
                    case CalendarEvent::TYPE_ZOOM :
505
                        $zoomMeeting = $zoomMeetingMapper->fetchOne($record->relational_id);
506
                        if($zoomMeeting) {
507
 
508
                            $backgroundColor = $currentNetwork->css_calendar_zoom_bg_color ;
509
                            $textColor = $currentNetwork->css_calendar_zoom_text_color;
510
 
511
                            $dtStart = \DateTime::createFromFormat('Y-m-d H:i:s', $zoomMeeting->start_time);
512
                            $t2 = $dtStart->getTimestamp();
513
 
514
                            if($t2 > $t1) {
515
 
516
                                $t3 = $t1 + $expirePeriod;
517
                                if($t3 > $t2) {
518
                                    $backgroundColor = $currentNetwork->css_calendar_expire_bg_color;
519
                                    $textColor = $currentNetwork->css_calendar_expire_text_color;
520
                                }
521
 
522
                            }
523
 
524
 
525
 
526
                            if($currentUser->timezone && $currentUser->timezone != $zoomMeeting->timezone) {
527
 
528
                                $start =  str_replace(' ', 'T', Functions::convertDateTimeBetweenTimeZones($zoomMeeting->start_time, $zoomMeeting->timezone, $currentUser->timezone));
529
                                $end =  str_replace(' ', 'T', Functions::convertDateTimeBetweenTimeZones($zoomMeeting->end_time, $zoomMeeting->timezone, $currentUser->timezone));
530
 
531
 
532
 
533
 
534
 
535
                            } else {
536
                                $start = str_replace(' ', 'T', $zoomMeeting->start_time);
537
                                $end = str_replace(' ', 'T', $zoomMeeting->end_time);
538
                            }
539
 
540
 
541
 
542
 
543
 
544
 
545
                            $agenda = "<a href=\"{$zoomMeeting->join_url}\" target=\"_blank\">" .  $zoomMeeting->agenda . "<br>" .
546
                                " LABEL_ZOOM_MEETING_START_DATE : " . $dtStart->format('Y-m-d') . "<br>" .
547
                                " LABEL_ZOOM_MEETING_START_TIME : " . $dtStart->format('H:i a') . "<br>" .
548
                                " LABEL_ZOOM_MEETING_TIMEZONE : " . $zoomMeeting->timezone . "<br>" .
549
                                " LABEL_ZOOM_MEETING_TITLE :  " . $zoomMeeting->topic  . "<br>" .
550
                                " LABEL_ZOOM_MEETING_URL : " . $zoomMeeting->join_url . "<br>" .
551
                                " LABEL_ZOOM_MEETING_PASSWORD : " . $zoomMeeting->password . "<br>" .
552
                                "</a>";
553
 
554
                            array_push($events, [
555
                                'id'                => $zoomMeeting->id,
556
                                'title'             => $zoomMeeting->topic,
557
                                'agenda'            => $agenda,
558
                                'start'             => $start,
559
                                'end'               => $end,
560
                                'url'               => $zoomMeeting->join_url,
561
                                'backgroundColor'   => $backgroundColor,
562
                                'textColor'         => $textColor,
563
                                'type'              => 'event',
564
                            ]);
565
                        }
566
                        break;
567
 
568
 
569
                }
570
 
571
 
572
 
573
            }
574
 
575
 
576
 
577
 
121 efrain 578
            return new JsonModel([
579
                'success' => true,
580
                'data' => $events
581
            ]);
1 efrain 582
 
583
        } else {
584
            $response = [
585
                'success' => false,
586
                'data' => 'ERROR_METHOD_NOT_ALLOWED'
587
            ];
588
        }
589
 
590
        return new JsonModel($response);
591
    }
592
 
593
 
594
 
595
 
596
}