|
10273
|
NULL
|
0
|
2026-04-14T08:27:24.608427+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776155244608_m1.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
iTerm2ShellEditViewSessionScriptsProfilesWindowHel iTerm2ShellEditViewSessionScriptsProfilesWindowHelp• 0DOCKER• 881DEV (-zsh)882"frame_status":"ok","audio_status": "disabled","last_frame": "2026-04-14T09:44:01+03:00","uptime": 1243.255541917,"fps": 0.254975738544637,"frames": 317APP (-zsh)ec2-user@ip-10-30-...X4}{lukas@Lukas-Kovaliks-MacBook-Pro-Jiminny ~/.screenpipe $ sp-status"status": "healthy""frame_status": "ok""audio_status": "disabled""last_frame": "2026-04-14T10:12:37+03:00","uptime": 2959.307842208,"fps": 0.[CREDIT_CARD],"frames": 929}lukas@Lukas-Kovaliks-MacBook-Pro-Jiminny ~/.screenpipe $du -sh ~/.screenpipe887M/Users/lukas/.screenpipelukas@Lukas-Kovaliks-MacBook-Pro-Jiminny ~/.screenpipe $du -sh ~/.screenpipe/*4.0K/Users/Lukas/.screenpipe/config.json308M/Users/lukas/.screenpipe/data561M/Users/lukas/.screenpipe/db.sqlite64K/Users/lukas/.screenpipe/db.sqlite-shm18M/Users/lukas/.screenpipe/db.sqlite-wal24K/Users/lukas/.screenpipe/pipes132K/Users/lukas/.screenpipe/screenpipe.2026-04-09.0.log96K72K/Users/lukas/.screenpipe/screenpipe.2026-04-11.0.1og/Users/lukas/.screenpipe/screenpipe.2026-04-12.0.log72K/Users/lukas/.screenpipe/screenpipe.2026-04-13.0.1og32K/Users/lukas/.screenpipe/screenpipe.2026-04-14.0.loglukas@Lukas-Kovaliks-MacBook-Pro-Jiminny ~/.screenpipe $du -sh ~/.screenpipe/*4.0K/Users/lukas/.screenpipe/config.json392M/Users/lukas/.screenpipe/data660M64K/Users/lukas/.screenpipe/db.sqlite/Users/lukas/.screenpipe/db.sqlite-shm15M/Users/lukas/.screenpipe/db.sqlite-wal24K/Users/lukas/.screenpipe/pipes132K/Users/lukas/.screenpipe/screenpipe.2026-04-09.0.1og96K/Users/lukas/.screenpipe/screenpipe.2026-04-11.0.log72K/Users/lukas/.screenpipe/screenpipe.2026-04-12.0.log72K/Users/lukas/.screenpipe/screenpipe.2026-04-13.0.log44K/Users/lukas/.screenpipe/screenpipe.2026-04-14.0.loglukas@Lukas-Kovaliks-MacBook-Pro-Jiminny ~/.screenpipe $ nano screenpipe.2026-04-13.0.10glukas@Lukas-Kovaliks-MacBook-Pro-Jiminny ~/.screenpipe $ I(ablSupport Daily • in 3 h 33 m-zsh-zsh-zsh86-zsh100% <47Tue 14 Apr 11:27:24181O 87* Unable to acce...O x8...
|
NULL
|
2886665110413202797
|
NULL
|
click
|
ocr
|
NULL
|
iTerm2ShellEditViewSessionScriptsProfilesWindowHel iTerm2ShellEditViewSessionScriptsProfilesWindowHelp• 0DOCKER• 881DEV (-zsh)882"frame_status":"ok","audio_status": "disabled","last_frame": "2026-04-14T09:44:01+03:00","uptime": 1243.255541917,"fps": 0.254975738544637,"frames": 317APP (-zsh)ec2-user@ip-10-30-...X4}{lukas@Lukas-Kovaliks-MacBook-Pro-Jiminny ~/.screenpipe $ sp-status"status": "healthy""frame_status": "ok""audio_status": "disabled""last_frame": "2026-04-14T10:12:37+03:00","uptime": 2959.307842208,"fps": 0.[CREDIT_CARD],"frames": 929}lukas@Lukas-Kovaliks-MacBook-Pro-Jiminny ~/.screenpipe $du -sh ~/.screenpipe887M/Users/lukas/.screenpipelukas@Lukas-Kovaliks-MacBook-Pro-Jiminny ~/.screenpipe $du -sh ~/.screenpipe/*4.0K/Users/Lukas/.screenpipe/config.json308M/Users/lukas/.screenpipe/data561M/Users/lukas/.screenpipe/db.sqlite64K/Users/lukas/.screenpipe/db.sqlite-shm18M/Users/lukas/.screenpipe/db.sqlite-wal24K/Users/lukas/.screenpipe/pipes132K/Users/lukas/.screenpipe/screenpipe.2026-04-09.0.log96K72K/Users/lukas/.screenpipe/screenpipe.2026-04-11.0.1og/Users/lukas/.screenpipe/screenpipe.2026-04-12.0.log72K/Users/lukas/.screenpipe/screenpipe.2026-04-13.0.1og32K/Users/lukas/.screenpipe/screenpipe.2026-04-14.0.loglukas@Lukas-Kovaliks-MacBook-Pro-Jiminny ~/.screenpipe $du -sh ~/.screenpipe/*4.0K/Users/lukas/.screenpipe/config.json392M/Users/lukas/.screenpipe/data660M64K/Users/lukas/.screenpipe/db.sqlite/Users/lukas/.screenpipe/db.sqlite-shm15M/Users/lukas/.screenpipe/db.sqlite-wal24K/Users/lukas/.screenpipe/pipes132K/Users/lukas/.screenpipe/screenpipe.2026-04-09.0.1og96K/Users/lukas/.screenpipe/screenpipe.2026-04-11.0.log72K/Users/lukas/.screenpipe/screenpipe.2026-04-12.0.log72K/Users/lukas/.screenpipe/screenpipe.2026-04-13.0.log44K/Users/lukas/.screenpipe/screenpipe.2026-04-14.0.loglukas@Lukas-Kovaliks-MacBook-Pro-Jiminny ~/.screenpipe $ nano screenpipe.2026-04-13.0.10glukas@Lukas-Kovaliks-MacBook-Pro-Jiminny ~/.screenpipe $ I(ablSupport Daily • in 3 h 33 m-zsh-zsh-zsh86-zsh100% <47Tue 14 Apr 11:27:24181O 87* Unable to acce...O x8...
|
10270
|
|
10274
|
NULL
|
0
|
2026-04-14T08:27:29.909199+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776155249909_m2.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
PhpStormFileEditViewNavigateCodeLaravelRefactorFV PhpStormFileEditViewNavigateCodeLaravelRefactorFV faVsco.js v#11894 on JY-18909-automated-reports-ask-iminny K vProject vToolsWindowHelpProphetAiv D Reports© AutomatedReportsCl© AutomatedReportsRe© AutomatedReportsSt© CreateMockAskJimir© DeleteReportComma© GenerateMarketingR© Team.php© Usage.phpD Slack• TeamsD TracksO TranscriptionO TwilioD UsersVocabulary@Zoom© CoachingFeedbacksUpr© Command.phpcreateDatabaseusers.pc Daraoase oecountoi© DeleteOldAiCrmNotesC:© DeleteS3LeftoversComiDevPostmanCommand./© DiarizeViaAiParticipantk© EncryptTokensComman© EngagementStatsRegen©FeatureFlagsHelper.php© FixCrossTenantlssues.p© FlushRolesPermissionsC(e) Generatelnterna wepho• GroupSetDefaultLangua© HelperTruncateCoachin© HubspotJournalPollingC© HubspotWebhookServic©ImportRecording.php© ImportUsersFromCsvFil© IterateUsersCommand.p© JiminnyCacheClearCom© JiminnyDebugCommanc© JiminnySetEncryptedTo(c) Jiminny okenintocomm© MakeSlackLiveCoaching(c Manacescimror eam.o© MarkBranchForEnvironn© MuteOrganizerChannel.© PhpApm.php© PropagateCoachingFeer© PurgeConferences.php© PurgeSoftDeletedOppor© PurgeSyncBatchesCom(e RecalculatebealkiskscoC) RemoveDeleteMarkersd(e) Remove-xoiredNudoes© RemoveUnusedParticip:© ResetElasticSearch.php© RestoreActivityCrmProv© RestoreActivityTypeCor© ReportController.phpJiminnybebuecommana.ongAutomaleakeporssenacommana.ongC AutomatedReportsCommand.php xAulomaleakeporskeposilory.onoAulomaleakeporisservice.onp= custom.log= laravel.logA SF [jiminny@localhost]Hs local liminnyalocalnostconsole PRODA console [EU]TrackProviderInstalledEvent.phpActivilyLoggeo.ongCreateActivityLoggedEvent.php© RequestGenerateAskJiminnyReportJob.php© UserPilotActivityListener.phpA console [STAGING]© AskJiminnyReportActivityService.phpC) RequestGenerateAskJiminnyReportJobTest.php© RequestGenerateReportJob.phpC AutomatedReportResult.phpAutomaleakeportoneTx: AutoyHlaygroundGajiminny vclass AutomatedReportsCommand extends CommandE WHEN U.1d = T.OWNEr_1d THEN(owner) ' El ti016 A 13 X13 A Vououc runccion nanolelur aint517if ($isFirstDay0fMonth && $isQuarterlyMonth) €$this->processReports( frequency: AutomatedReportsService::FREQUENCY_QUARTERLY);9910110210310410510610710810911011111311411511611711811912012112212312412512612712812913013113211551154135136137138139140$this->logger→>info(self::LOG_PREFIX' Completed');521522523524525526socal accounts= sa.sociable idon t.id = u.team_idand sa.provider = 'salesforce';where id = 1;return 0;g JOIN playbooks p 1..n<->1: on g.playbook_id = p.id where g.team_iwhere id = 565;oks where team_id = 1;1 usageprivate function processSingleReport(string $reportId): intACceptKeTect528529550oks where id = 175;ok_categories where playbook_id = 175;$this->logger->info(self::LOG_PREFIX|•||'| Manual single-report mode'. ['reportid'l => $reportid]):Wnere teal_1d = 1,where id = 7160;532oTiles where User 10 = 1100.$report = is_numeric($reportId)? AutomatedReport: :withTrashed()->find((int) $reportId)533:AutomatedReport: :withTrashed()->where( column: 'uvid'.AutomatedReport: :toOptimized($reportId))-534535if ($report === null) €536ovider, playbook_category_id, user_id, lead_id, contact_id, account$this->logger->error(self::L0G_PREFIX|'| Report not found', ['reportid' => $reportid]);537id, crm_provider_id, transcription_id, status$this-›error( string: |"Report not found: ($reportid}"):538e crm_configuration_id = 1 and type = 'conference'539a IS NUI NULLreturn A;540oader' and actual_start_time IS NOT NULL541542ties where id = 54747783; # 00U0400000pCZojMAC543$this->warnIfNotApplicableForSchedule($report);544$this->logger->info(self::LOG_PREFIXDispatching Generate Report job for report', [545ity_type, pc.id, pc.name1546'reportUvid' => $report->getUvid(),'teamId' => $report->getTeamId(),547ries pc1<->1..n: on p.id = pc.playbook_idand p.activity_type = 'event';'frequency'=> $report->getFrequencxD,548ID:'type' => $report->getTyReO,|549elds WHERE crm_configuration_id = 1 and object_type = 'event';550eld_values WHERE crm_field_id = 4;551$job = $report->isAskJiminnyReport()552youts cl Join playbook_layouts pu->Ian: on cl.1d = pL. Layout_10553ion id = 1 and pl.plavbook id = 1751? new RequestGenerateAskJiminnyReportJob($report->getUuid()): new RequestGenerateReportJob($report->getUuid(D):594555556mated_reports r$this->dispatcher->dispatchSync($job);557auid = t.id$this->logger->info(self::LOG_PREFIX•'| Completed');558'daily'559return 0;560ve'561now() OR r.expires.at IS NULL);5621 usage564ted_report_results where repont.id IN (18, 33);private function warnIfNotApplicableForSchedule(AutomatedReport $report): void565ted_reports;566 vted_report_results where ceRontaid IN (34);($report->trashed(0) €$this->warn( string:'Report is soft-deleted (deleted_at:+ 1 of 5 edits +v Accept File *-X Reject File 0*8Sreport->getDeletedAt(P->toDateTihe: 567Windsurf changelog 2.12.21: A new version is available. // View Changelog (54 minutes ago), 0lablSupport Daily • in 3h 33mARequestGenerateAskJiminnyReportJobTestv100% [2Tue 14 Apr 11:27:29CascadeFixing ReportControlleAutomated Report Fai+D ...un onucolld Leuneyot tscomlallus oheadd additional parameter report id and if provider then instead ofexoris by wrecuenell lakes wle levort vy le or uule.Add checks for status, team activity andoiel stull useu lor curymg. uns Iwi ve usee only mllanudlly sou mele shote ve mio l not duptlcadle baseu onlstandara searenLet me read the command and related files first.reao Auloma lecreoorscommanc,ono anopAuloalecreoorsredosilorv.ono ›Now let me check the AutonatedReoort model tor relevanttielas:сxоютeй nuLоїus|getTeam|expires_at|getFrequency|getType|STATUS_lis›Now.nave everytnine.neeo. Lerme imolement tne changes.• AutomatedReportsCommand.php+78 -2Also need to check if findByUuid handles soft-deleted — it doesn't, so for UUID lookup we need withTrashed too.Let me tix thatAutomatedReportsCommand.phpDone. Here's what was added:+1 -1Changes SummaryNew option: —report-id= — accepts either a numeric ID or a UUID.processsing lekeportl, — oypasses treouency logie entirely.• Looks up by ID (AutomatedReport: :withTrashed()->find() ) or UUID (also withTrashed so even deletedreports can be triggered manually)• Calls warnIfNotApplicableForSchedule() for informational outputDispatches the job the same way as the scheduled pathwarnIfNotApplicableForSchedule() - mirrors every condition from getActiveReportsByFrequency() and thejob's validateReport(), printing a warn() (vellow terminal output) for each condition that would cause the reportto oe skiooed in a normal scheculed run:CheckReport is soft-deletedstatus s inactiveTeam not STATUS_ACTIVEexpires_at is pastFrequency wouldn't run todayUsage:bash# By IDSourcewathi rashed - nouln normal scopegetActiveReportsByFrequencygetActivereportsbyFrequencygetActiveReportsByFrequencyscheduling logic in handle()php artisan automated-reports —report-id=68#BY UULDphp artisan automated-reports --report-1d=some-uuid-hereC1l -1 file +78 -2 >Reject allAccept allit seems to be a log of duplication. Lets jusst use the same method we have+ <> CodeClaude Sonnet 4.6winasun leams203:6 1229 chars, 26 line breaksuir-o( 4 spaces...
|
NULL
|
8508095350697127596
|
NULL
|
visual_change
|
ocr
|
NULL
|
PhpStormFileEditViewNavigateCodeLaravelRefactorFV PhpStormFileEditViewNavigateCodeLaravelRefactorFV faVsco.js v#11894 on JY-18909-automated-reports-ask-iminny K vProject vToolsWindowHelpProphetAiv D Reports© AutomatedReportsCl© AutomatedReportsRe© AutomatedReportsSt© CreateMockAskJimir© DeleteReportComma© GenerateMarketingR© Team.php© Usage.phpD Slack• TeamsD TracksO TranscriptionO TwilioD UsersVocabulary@Zoom© CoachingFeedbacksUpr© Command.phpcreateDatabaseusers.pc Daraoase oecountoi© DeleteOldAiCrmNotesC:© DeleteS3LeftoversComiDevPostmanCommand./© DiarizeViaAiParticipantk© EncryptTokensComman© EngagementStatsRegen©FeatureFlagsHelper.php© FixCrossTenantlssues.p© FlushRolesPermissionsC(e) Generatelnterna wepho• GroupSetDefaultLangua© HelperTruncateCoachin© HubspotJournalPollingC© HubspotWebhookServic©ImportRecording.php© ImportUsersFromCsvFil© IterateUsersCommand.p© JiminnyCacheClearCom© JiminnyDebugCommanc© JiminnySetEncryptedTo(c) Jiminny okenintocomm© MakeSlackLiveCoaching(c Manacescimror eam.o© MarkBranchForEnvironn© MuteOrganizerChannel.© PhpApm.php© PropagateCoachingFeer© PurgeConferences.php© PurgeSoftDeletedOppor© PurgeSyncBatchesCom(e RecalculatebealkiskscoC) RemoveDeleteMarkersd(e) Remove-xoiredNudoes© RemoveUnusedParticip:© ResetElasticSearch.php© RestoreActivityCrmProv© RestoreActivityTypeCor© ReportController.phpJiminnybebuecommana.ongAutomaleakeporssenacommana.ongC AutomatedReportsCommand.php xAulomaleakeporskeposilory.onoAulomaleakeporisservice.onp= custom.log= laravel.logA SF [jiminny@localhost]Hs local liminnyalocalnostconsole PRODA console [EU]TrackProviderInstalledEvent.phpActivilyLoggeo.ongCreateActivityLoggedEvent.php© RequestGenerateAskJiminnyReportJob.php© UserPilotActivityListener.phpA console [STAGING]© AskJiminnyReportActivityService.phpC) RequestGenerateAskJiminnyReportJobTest.php© RequestGenerateReportJob.phpC AutomatedReportResult.phpAutomaleakeportoneTx: AutoyHlaygroundGajiminny vclass AutomatedReportsCommand extends CommandE WHEN U.1d = T.OWNEr_1d THEN(owner) ' El ti016 A 13 X13 A Vououc runccion nanolelur aint517if ($isFirstDay0fMonth && $isQuarterlyMonth) €$this->processReports( frequency: AutomatedReportsService::FREQUENCY_QUARTERLY);9910110210310410510610710810911011111311411511611711811912012112212312412512612712812913013113211551154135136137138139140$this->logger→>info(self::LOG_PREFIX' Completed');521522523524525526socal accounts= sa.sociable idon t.id = u.team_idand sa.provider = 'salesforce';where id = 1;return 0;g JOIN playbooks p 1..n<->1: on g.playbook_id = p.id where g.team_iwhere id = 565;oks where team_id = 1;1 usageprivate function processSingleReport(string $reportId): intACceptKeTect528529550oks where id = 175;ok_categories where playbook_id = 175;$this->logger->info(self::LOG_PREFIX|•||'| Manual single-report mode'. ['reportid'l => $reportid]):Wnere teal_1d = 1,where id = 7160;532oTiles where User 10 = 1100.$report = is_numeric($reportId)? AutomatedReport: :withTrashed()->find((int) $reportId)533:AutomatedReport: :withTrashed()->where( column: 'uvid'.AutomatedReport: :toOptimized($reportId))-534535if ($report === null) €536ovider, playbook_category_id, user_id, lead_id, contact_id, account$this->logger->error(self::L0G_PREFIX|'| Report not found', ['reportid' => $reportid]);537id, crm_provider_id, transcription_id, status$this-›error( string: |"Report not found: ($reportid}"):538e crm_configuration_id = 1 and type = 'conference'539a IS NUI NULLreturn A;540oader' and actual_start_time IS NOT NULL541542ties where id = 54747783; # 00U0400000pCZojMAC543$this->warnIfNotApplicableForSchedule($report);544$this->logger->info(self::LOG_PREFIXDispatching Generate Report job for report', [545ity_type, pc.id, pc.name1546'reportUvid' => $report->getUvid(),'teamId' => $report->getTeamId(),547ries pc1<->1..n: on p.id = pc.playbook_idand p.activity_type = 'event';'frequency'=> $report->getFrequencxD,548ID:'type' => $report->getTyReO,|549elds WHERE crm_configuration_id = 1 and object_type = 'event';550eld_values WHERE crm_field_id = 4;551$job = $report->isAskJiminnyReport()552youts cl Join playbook_layouts pu->Ian: on cl.1d = pL. Layout_10553ion id = 1 and pl.plavbook id = 1751? new RequestGenerateAskJiminnyReportJob($report->getUuid()): new RequestGenerateReportJob($report->getUuid(D):594555556mated_reports r$this->dispatcher->dispatchSync($job);557auid = t.id$this->logger->info(self::LOG_PREFIX•'| Completed');558'daily'559return 0;560ve'561now() OR r.expires.at IS NULL);5621 usage564ted_report_results where repont.id IN (18, 33);private function warnIfNotApplicableForSchedule(AutomatedReport $report): void565ted_reports;566 vted_report_results where ceRontaid IN (34);($report->trashed(0) €$this->warn( string:'Report is soft-deleted (deleted_at:+ 1 of 5 edits +v Accept File *-X Reject File 0*8Sreport->getDeletedAt(P->toDateTihe: 567Windsurf changelog 2.12.21: A new version is available. // View Changelog (54 minutes ago), 0lablSupport Daily • in 3h 33mARequestGenerateAskJiminnyReportJobTestv100% [2Tue 14 Apr 11:27:29CascadeFixing ReportControlleAutomated Report Fai+D ...un onucolld Leuneyot tscomlallus oheadd additional parameter report id and if provider then instead ofexoris by wrecuenell lakes wle levort vy le or uule.Add checks for status, team activity andoiel stull useu lor curymg. uns Iwi ve usee only mllanudlly sou mele shote ve mio l not duptlcadle baseu onlstandara searenLet me read the command and related files first.reao Auloma lecreoorscommanc,ono anopAuloalecreoorsredosilorv.ono ›Now let me check the AutonatedReoort model tor relevanttielas:сxоютeй nuLоїus|getTeam|expires_at|getFrequency|getType|STATUS_lis›Now.nave everytnine.neeo. Lerme imolement tne changes.• AutomatedReportsCommand.php+78 -2Also need to check if findByUuid handles soft-deleted — it doesn't, so for UUID lookup we need withTrashed too.Let me tix thatAutomatedReportsCommand.phpDone. Here's what was added:+1 -1Changes SummaryNew option: —report-id= — accepts either a numeric ID or a UUID.processsing lekeportl, — oypasses treouency logie entirely.• Looks up by ID (AutomatedReport: :withTrashed()->find() ) or UUID (also withTrashed so even deletedreports can be triggered manually)• Calls warnIfNotApplicableForSchedule() for informational outputDispatches the job the same way as the scheduled pathwarnIfNotApplicableForSchedule() - mirrors every condition from getActiveReportsByFrequency() and thejob's validateReport(), printing a warn() (vellow terminal output) for each condition that would cause the reportto oe skiooed in a normal scheculed run:CheckReport is soft-deletedstatus s inactiveTeam not STATUS_ACTIVEexpires_at is pastFrequency wouldn't run todayUsage:bash# By IDSourcewathi rashed - nouln normal scopegetActiveReportsByFrequencygetActivereportsbyFrequencygetActiveReportsByFrequencyscheduling logic in handle()php artisan automated-reports —report-id=68#BY UULDphp artisan automated-reports --report-1d=some-uuid-hereC1l -1 file +78 -2 >Reject allAccept allit seems to be a log of duplication. Lets jusst use the same method we have+ <> CodeClaude Sonnet 4.6winasun leams203:6 1229 chars, 26 line breaksuir-o( 4 spaces...
|
NULL
|
|
10275
|
202
|
0
|
2026-04-14T08:27:31.070073+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776155251070_m1.jpg...
|
PhpStorm
|
faVsco.js – AutomatedReportsCommand.php
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
<?php
declare(strict_types=1);
namespace Jiminny\Console\Commands\Reports;
use Carbon\Carbon;
use Illuminate\Console\Command;
use Illuminate\Contracts\Bus\Dispatcher as BusDispatcher;
use Jiminny\Jobs\AutomatedReports\RequestGenerateAskJiminnyReportJob;
use Jiminny\Jobs\AutomatedReports\RequestGenerateReportJob;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\Team;
use Jiminny\Repositories\AutomatedReportsRepository;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Psr\Log\LoggerInterface;
class AutomatedReportsCommand extends Command
{
/**
* Log prefix for all log messages
*/
private const string LOG_PREFIX = '[automated-reports]';
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'automated-reports {--report-id= : Process a specific report by ID or UUID (bypasses frequency scheduling)}';
/**
* The console command description.
*
* @var string
*/
protected $description = 'Process automated reports based on their frequency (weekly, monthly, quarterly). Use --report-id to manually trigger a specific report by ID or UUID.';
public function __construct(
private readonly LoggerInterface $logger,
private readonly BusDispatcher $dispatcher,
private readonly AutomatedReportsRepository $reportRepository
) {
parent::__construct();
}
/**
* Execute the console command.
*
* @return int
*/
public function handle(): int
{
$this->logger->info(self::LOG_PREFIX . ' Started');
$reportId = $this->option('report-id');
if ($reportId !== null) {
return $this->processSingleReport((string) $reportId);
}
$now = Carbon::now();
$isMonday = $now->isMonday();
$isFirstDayOfMonth = $now->day === 1;
$currentMonth = $now->month;
// Check if the current month is a quarterly month (January, April, July, October)
$isQuarterlyMonth = in_array($currentMonth, [1, 4, 7, 10], true);
$this->logger->info(self::LOG_PREFIX . ' Checking conditions', [
'isMonday' => $isMonday,
'isFirstDayOfMonth' => $isFirstDayOfMonth,
'currentMonth' => $currentMonth,
'isQuarterlyMonth' => $isQuarterlyMonth,
]);
// Process daily reports
$this->processReports(AutomatedReportsService::FREQUENCY_DAILY);
// Process weekly reports on Mondays
if ($isMonday) {
$this->processReports(AutomatedReportsService::FREQUENCY_WEEKLY);
}
// Process monthly reports on the first day of the month
if ($isFirstDayOfMonth) {
$this->processReports(AutomatedReportsService::FREQUENCY_MONTHLY);
}
// Process quarterly reports on the first day of January, April, July, and October
if ($isFirstDayOfMonth && $isQuarterlyMonth) {
$this->processReports(AutomatedReportsService::FREQUENCY_QUARTERLY);
}
$this->logger->info(self::LOG_PREFIX . ' Completed');
return 0;
}
private function processSingleReport(string $reportId): int
{
$this->logger->info(self::LOG_PREFIX . ' Manual single-report mode', ['reportId' => $reportId]);
$report = is_numeric($reportId)
? AutomatedReport::withTrashed()->find((int) $reportId)
: AutomatedReport::withTrashed()->where('uuid', AutomatedReport::toOptimized($reportId))->first();
if ($report === null) {
$this->logger->error(self::LOG_PREFIX . ' Report not found', ['reportId' => $reportId]);
$this->error("Report not found: {$reportId}");
return 1;
}
$this->warnIfNotApplicableForSchedule($report);
$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [
'reportUuid' => $report->getUuid(),
'teamId' => $report->getTeamId(),
'frequency' => $report->getFrequency(),
'type' => $report->getType(),
]);
$job = $report->isAskJiminnyReport()
? new RequestGenerateAskJiminnyReportJob($report->getUuid())
: new RequestGenerateReportJob($report->getUuid());
$this->dispatcher->dispatchSync($job);
$this->logger->info(self::LOG_PREFIX . ' Completed');
return 0;
}
private function warnIfNotApplicableForSchedule(AutomatedReport $report): void
{
if ($report->trashed()) {
$this->warn('Report is soft-deleted (deleted_at: ' . $report->getDeletedAt()?->toDateTimeString() . ').');
}
if (! $report->getStatus()) {
$this->warn('Report status is inactive — would be skipped in scheduled run.');
}
$team = $report->getTeam();
if ($team->getStatus() !== Team::STATUS_ACTIVE) {
$this->warn("Team #{$report->getTeamId()} is not active (status: {$team->getStatus()}) — would be skipped in scheduled run.");
}
if ($report->isExpired()) {
$this->warn('Report is expired (expires_at: ' . $report->getExpiresAt()?->toDateString() . ') — would be skipped in scheduled run.');
}
$now = Carbon::now();
$frequency = $report->getFrequency();
$wouldRunToday = match ($frequency) {
AutomatedReportsService::FREQUENCY_DAILY => true,
AutomatedReportsService::FREQUENCY_WEEKLY => $now->isMonday(),
AutomatedReportsService::FREQUENCY_MONTHLY => $now->day === 1,
AutomatedReportsService::FREQUENCY_QUARTERLY => $now->day === 1 && in_array($now->month, [1, 4, 7, 10], true),
default => false,
};
if (! $wouldRunToday) {
$this->warn("Report frequency is '{$frequency}' — would NOT be scheduled to run today.");
}
}
/**
* Process reports for a specific frequency.
*
* @param string $frequency
*
* @return void
*/
private function processReports(string $frequency): void
{
$this->logger->info(self::LOG_PREFIX . " Processing $frequency reports");
// Get all enabled, not deleted reports with active teams for the specified frequency
$reports = $this->reportRepository->getActiveReportsByFrequency($frequency);
// $reports = collect([AutomatedReport::find(68)]);
$this->logger->info(self::LOG_PREFIX . " Found {$reports->count()} $frequency reports to process");
/** @var AutomatedReport $report */
foreach ($reports as $report) {
$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [
'reportUuid' => $report->getUuid(),
'teamId' => $report->getTeamId(),
'frequency' => $report->getFrequency(),
'type' => $report->getType(),
]);
$job = $report->isAskJiminnyReport()
? new RequestGenerateAskJiminnyReportJob($report->getUuid())
: new RequestGenerateReportJob($report->getUuid());
// $this->dispatcher->dispatch($job);
$this->dispatcher->dispatchSync($job);
}
}
}
Execute
Explain Plan
Browse Query History
View Parameters
Open Query Execution Settings…
In-Editor Results
Tx: Auto
Cancel Running Statements
Playground
jiminny
Sync Changes
Hide This Notification
Code changed:
Hide
16
13
13
Previous Highlighted Error
Next Highlighted Error
SELECT * FROM teams WHERE id = 1;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;
SELECT * FROM crm_fields WHERE id = 2234;
SELECT * FROM crm_field_values WHERE crm_field_id = 2234;
select * from crm_profiles where user_id = 143;
select * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO
select * from business_processes where crm_configuration_id = 39;
# 01941000000H669AAC, 01941000000H66JAAS
select * from record_type_field_values
where record_type_id IN (24);
select * from crm_field_values where id IN (2730);
select * from crm_configurations where id = 39;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce'; #1035
select * from users where team_id = 1; # 222 group 3
SELECT * FROM activities WHERE user_id = 222 order by id desc;
select * from sidekick_settings where team_id = 1;
select * from teams where id = 1;
select * from team_features where team_id = 1;
select * from activities where crm_configuration_id = 2
and provider = 'ms-teams' and id = 608765;
SELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';
select * from sidekick_settings where team_id = 2;
SELECT * FROM activities WHERE id = 608660;
select * from activity_summary_logs where activity_id = 608660;
select * from ai_prompts where transcription_id = 11214;
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;
# id: 608818, crm: 59628809737
SELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;
# id: 608821, crm: 59632069252
SELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,
playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,
scheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at
FROM activities a
join calendar_events ce on a.calendar_event_id = ce.id
WHERE a.id IN (608818, 608821);
select * from users where team_id = 1;
select * from team_settings where team_id = 1;
select * from crm_profiles where crm_configuration_id = 39 order by user_id;
select * from team_features where team_id = 1;
select * from users where team_id = 2;
SELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639
# Preslava N. Ivanova, grou id 3
SELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;
select * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';
select
a.id,
a.type,
a.scheduled_start_time,
a.actual_start_time,
a.created_at,
a.opportunity_id,
a.status
FROM activities a
WHERE opportunity_id = 344
and status IN ('completed', 'received', 'delivered')
and (
(a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))
;
SELECT * FROM users WHERE id = 222;
SELECT * FROM crm_profiles WHERE user_id = 222;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;
select * from group_deal_risk_types;
select * from opportunities where team_id = 1;
SELECT * FROM opportunities WHERE id = 315;
SELECT * FROM crm_field_data WHERE object_id = 315;
select * from crm_field_data where object_id = 260;
select * from generic_ai_prompts where subject_id = 315;
select * from teams; # 36, 21, 121, [EMAIL]
SELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';
# [PASSWORD_DOTS]
select * from teams where id = 1;
select * from crm_configurations where id = 39;
select * from users where team_id = 1;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 1;
# 1 - 00541000004281rAAA
# 204 - 0052g000003freeAAA
# 429 - 0052g000003qGOiAAM
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
select * from activities where type = 'softphone'
and created_at > '2024-12-11 15:24:36' order by id desc;
select * from activity_providers where team_id = 1;
select * from activity_provider_users where activity_provider_id = 328;
select * from opportunities where crm_configuration_id = 39
AND account_id = 178 AND is_closed = false
order by created_at DESC;
select * from contacts where id = 3952;
select * from accounts where id = 178;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations where id = 21;
select * from users where team_id = 36;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 36
and sa.provider = 'bullhorn';
select * from social_accounts where id = 348;
UPDATE social_accounts SET
provider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',
provider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',
expires = 1733998131,
state = 'connected'
WHERE id = 348;
# [PASSWORD_DOTS]
select * from teams where id = 31;
select * from crm_configurations where id = 18;
select * from users where team_id = 31; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 31;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 31
and sa.provider = 'close';
select * from contacts where crm_configuration_id = 18;
# [PASSWORD_DOTS] NEPTUNE [PASSWORD_DOTS]
select * from teams;
select * from users where id IN (1030, 1035, 1052);
select * from crm_configurations;
select * from users where team_id = 65; # 257
select * from team_settings where team_id = 65; # 257
select * from invitations where team_id = 65; # 257
select * from users where email = '[EMAIL]'; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 65;
select * from crm_configurations where id = 53;
select * from accounts where crm_configuration_id = 53 order by id desc;
select * from leads where crm_configuration_id = 53 order by id desc;
select * from contacts where crm_configuration_id = 53 order by id desc;
select * from opportunities where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 53 order by id desc;
select * from crm_fields where crm_configuration_id = 53 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 53 order by id desc;
select * from stages where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 13;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
and sa.provider = 'integration-app';
select * from contacts where crm_configuration_id = 13;
select * from social_accounts where sociable_id = 283;
SELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';
select * from activity_providers where team_id = 65;
SELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
;
# [PASSWORD_DOTS] STAGING [PASSWORD_DOTS]
SELECT * FROM teams;
SELECT * FROM teams WHERE id = 88;
SELECT * FROM teams WHERE id = 89;
select * from team_settings where team_id = 89;
SELECT * FROM users WHERE team_id = 89;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 89;
select * from users;
SELECT * FROM social_accounts WHERE sociable_id = 1761;
SELECT * FROM crm_configurations WHERE id = 70;
select * from accounts where crm_configuration_id = 70 order by id desc;
select * from leads where crm_configuration_id = 70 order by id desc;
select * from contacts where crm_configuration_id = 70 order by id desc;
select * from opportunities where crm_configuration_id = 70 order by id desc;
select * from crm_profiles where crm_configuration_id = 70 order by id desc;
select * from crm_fields where crm_configuration_id = 70 order by id desc;
select * from crm_field_values where crm_field_id = 3536 order by id desc;
select * from crm_layouts where crm_configuration_id = 70 order by id desc;
select * from stages where crm_configuration_id = 70 order by id desc;
select * from business_processes where crm_configuration_id = 70 order by id desc;
select * from business_process_stages where business_process_id = 34;
select * from contacts where id = 10468;
select * from crm_layouts where crm_configuration_id = 70;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;
SELECT * FROM crm_fields WHERE id IN (3533,3534,3535);
select * from activities where crm_configuration_id = 70
and (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;
SELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;
SELECT * FROM activities where crm_configuration_id = 69 ;
SELECT * FROM users WHERE email LIKE '%[EMAIL]%';
SELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;
SELECT * FROM opportunities WHERE id = 385;
select * from participants p
join activities a on p.activity_id = a.id
where a.crm_configuration_id = 70
and (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);
SELECT * FROM participants WHERE id = 1013638;
select * from teams where id = 90;
select * from users where team_id = 90;
select * from social_accounts where social_accounts.sociable_id IN (1960,1760);
SELECT * FROM crm_profiles WHERE crm_configuration_id = 71;
select * from invitations where team_id = 90;
select * from crm_configurations where id = 71;
select * from accounts where crm_configuration_id = 71 order by id desc;
select * from leads where crm_configuration_id = 71 order by id desc;
select * from contacts where crm_configuration_id = 71 order by id desc;
select * from opportunities where crm_configuration_id = 71 order by id desc;
select * from crm_profiles where crm_configuration_id = 71 order by id desc;
select * from crm_fields where crm_configuration_id = 71 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 71 order by id desc;
select * from stages where crm_configuration_id = 71 order by id desc;
select * from users order by secondary_email desc;
select u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa
join users u on sa.sociable_id = u.id
where sa.provider = 'google' and u.email LIKE 'aneliya%';
select * from failed_jobs order by id desc;
select * from users where email = '[EMAIL]' or secondary_email = '[EMAIL]';
select * from teams;
SELECT * FROM crm_profiles WHERE crm_configuration_id = 39;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;
SELECT * FROM crm_configurations WHERE id = 70;
select * from teams where id = 1;
select * from groups where team_id = 1;
select * from users where team_id = 1;
select o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o
join users u on o.user_id = u.id
join groups g on u.group_id = g.id
join role_user ru on u.id = ru.user_id
join roles r on ru.role_id = r.id
where o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';
select * from role_user where user_id = 143;
select * from roles;
select * from role_user;
select * from groups where id = 9;
select * from scope_groups where group_id = 9;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations;
SELECT * FROM social_accounts WHERE sociable_id = 121;
https://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105
https://crmsandbox.zoho.com/crm/
https://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080
https://crm.zoho.com/crm/
org3469620
SELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;
select * from users where email LIKE "%mobile_automation_%";
select * from social_accounts where sociable_id IN (2228);
select * from crm_profiles where user_id IN (2222,2223,2226,2227);
select * from teams order by id desc;
SELECT * FROM users WHERE id = 2229;
SELECT * FROM crm_profiles WHERE user_id = 2229;
select * from opportunities where crm_configuration_id = 88;
select * from crm_fields where crm_configuration_id = 88;
select * from crm_profiles where crm_configuration_id = 88;
SELECT * FROM teams WHERE id = 1;
SELECT * FROM users WHERE id = 143;
SELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;
https://app.staging.jiminny.com/ondemand?
min_duration=1
&
only_recorded=1
&
user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e
&
sequence_number=2
select * from users where team_id = 1 and email like '%stoyan%'
select * from coaching_feedbacks;
select * from teams;
SELECT * FROM users WHERE team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from users where id = 143;
SELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
select * from users where team_id = 2;
select * from activities where crm_configuration_id = 39
and activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'
AND user_id = 143
order by id desc;
# [PASSWORD_DOTS]
select * from teams where id = 142; # 2312, 126
select * from team_settings;
select * from users where team_id = 142; # 21642
SELECT * FROM social_accounts WHERE sociable_id = 21642;
SELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;
select * from crm_profiles where id IN (93);
select * from invitations;
select * from team_features where team_id = 1;
SELECT * FROM crm_configurations WHERE id = 126;
select * from accounts where crm_configuration_id = 126 order by id desc;
select * from leads where crm_configuration_id = 126 order by id desc;
select * from contacts where crm_configuration_id = 126 order by id desc;
select * from opportunities where crm_configuration_id = 126 order by id desc;
select * from crm_profiles where crm_configuration_id = 126 order by id desc;
select * from crm_fields where crm_configuration_id = 126 # 11060
# and type IN ('picklist', 'status')
# and object_type = 'task'
order by id desc;
# 5731,5732,5733
select DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;
select * from crm_layouts where crm_configuration_id = 126 order by id desc;
SELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);
select * from stages where crm_configuration_id = 126 order by id desc;
select * from business_processes where crm_configuration_id = 126 order by id desc;
select * from business_process_stages where business_process_id IN (76,75,74,73);
select * from playbooks where team_id = 142;
select * from playbook_layouts where playbook_id IN (108);
SELECT * FROM playbook_categories WHERE playbook_id IN (108);
select * from teams where id = 130;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 2
and sa.provider = 'hubspot';
SELECT * FROM activities
WHERE crm_configuration_id = 110;
select * from teams;
select * from crm_configurations;
SELECT * FROM activities WHERE id = 628773;
SELECT * FROM crm_profiles WHERE user_id = 1460;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from teams;
select ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id
join permission_role pr on pr.role_id = ru.role_id
join permissions p on p.id = pr.permission_id
where team_id = 495 and p.name IN ('dial');
select * from teams where id = 145;
select * from crm_configurations where id = 129;
select * from social_accounts where sociable_id = 2317;
SELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;
select * from teams where id = 1;
SELECT * FROM crm_layouts WHERE crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;
SELECT * FROM crm_layout_entities WHERE id = 5507;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');
select * from teams;
select * from activities where crm_configuration_id = 14;
SELECT * FROM social_accounts where provider = 'copper';
select * from activities where id = 628467;
select * from participants where activity_id = 628467;
SELECT * FROM contacts WHERE id = 3969;
SELECT * FROM accounts WHERE id = 177;
SELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;
# [PASSWORD_DOTS] BH
select * from teams where id = 36;
SELECT * FROM crm_configurations WHERE id = 21;
select * from activities where crm_configuration_id = 21 and id = 607901;
select * from activities where crm_configuration_id = 21;
select * roles;
select * from permissions;
select * from permission_role where permission_id = 226;
select * from migrations order by id desc;
# mercury
# neptune
# earth
select * from teams;
select * from teams where id = 19;
select * from teams where id = 27;
select * from users where team_id = 27;
SELECT * FROM crm_configurations WHERE id = 42;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from activities where id = 631461;
SELECT * FROM crm_field_values WHERE crm_field_id = 180;
select * from teams where id = 2;
SELECT * FROM social_accounts WHERE sociable_id = 89;
SELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273
select * from activity_summary_logs where activity_id = 634273;
select * from sidekick_settings where team_id = 2;
select * from teams; # 2, 2
SELECT * FROM crm_configurations WHERE team_id = 2; # 2
select * from team_features where team_id = 2;
select * from features;
SELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';
SELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;
select * from automated_reports order by id desc;
select * from automated_report_results order by id desc;
select * from users where team_id = 1 and id IN (7160, 3248);
select * from migrations order by id desc;
SELECT
CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,
u.email,
sa.*,
t.owner_id FROM social_accounts sa
JOIN users u on u.id = sa.sociable_id
JOIN teams t on t.id = u.team_id
WHERE u.team_id = 1 and sa.provider = 'salesforce';
select * from teams where id = 1;
select * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;
select * from groups where id = 565;
select * from playbooks where team_id = 1;
select * from playbooks where id = 175;
select * from playbook_categories where playbook_id = 175;
select * from users where team_id = 1;
select * from users where id = 7160;
select * from crm_profiles where user_id = 7160;
select * from features;
select
*
# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,
# crm_configuration_id, crm_provider_id, transcription_id, status
from activities where crm_configuration_id = 1 and type = 'conference'
# and crm_provider_id IS NOT NULL
and provider != 'uploader' and actual_start_time IS NOT NULL
ORDER by id desc;
select * from activities where id = 54747783; # 00UO400000pCzojMAC
select p.id, p.activity_type, pc.id, pc.name
FROM playbooks p
join playbook_categories pc on p.id = pc.playbook_id
where p.team_id = 1 and p.activity_type = 'event';
SELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';
SELECT * FROM crm_field_values WHERE crm_field_id = 4;
select * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id
where crm_configuration_id = 1 and pl.playbook_id = 175;
select * from teams;
SELECT r.* FROM automated_reports r
join teams t on r.team_id = t.id
WHERE r.frequency = 'daily'
and r.status = 1
AND t.status = 'active'
AND (r.expires_at >= now() OR r.expires_at IS NULL);
select * from automated_report_results where report_id IN (18, 33);
select * from automated_reports;
select * from automated_report_results where report_id IN (34);
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
[{"role":"AXButton","text" [{"role":"AXButton","text":"Project: faVsco.js, menu","depth":5,"help_text":"~/jiminny/app","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"#11894 on JY-18909-automated-reports-ask-jiminny, menu","depth":5,"help_text":"Pull request #11894 exists for current branch JY-18909-automated-reports-ask-jiminny, but local branch is out of sync with remote","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Start Listening for PHP Debug Connections","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"RequestGenerateAskJiminnyReportJobTest","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Run 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Debug 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"More Actions","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"JetBrains AI","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Search Everywhere","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"IDE and Project Settings","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.088194445,"height":0.027777778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Console\\Commands\\Reports;\n\nuse Carbon\\Carbon;\nuse Illuminate\\Console\\Command;\nuse Illuminate\\Contracts\\Bus\\Dispatcher as BusDispatcher;\nuse Jiminny\\Jobs\\AutomatedReports\\RequestGenerateAskJiminnyReportJob;\nuse Jiminny\\Jobs\\AutomatedReports\\RequestGenerateReportJob;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Repositories\\AutomatedReportsRepository;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Psr\\Log\\LoggerInterface;\n\nclass AutomatedReportsCommand extends Command\n{\n /**\n * Log prefix for all log messages\n */\n private const string LOG_PREFIX = '[automated-reports]';\n\n /**\n * The name and signature of the console command.\n *\n * @var string\n */\n protected $signature = 'automated-reports {--report-id= : Process a specific report by ID or UUID (bypasses frequency scheduling)}';\n\n /**\n * The console command description.\n *\n * @var string\n */\n protected $description = 'Process automated reports based on their frequency (weekly, monthly, quarterly). Use --report-id to manually trigger a specific report by ID or UUID.';\n\n\n public function __construct(\n private readonly LoggerInterface $logger,\n private readonly BusDispatcher $dispatcher,\n private readonly AutomatedReportsRepository $reportRepository\n ) {\n parent::__construct();\n }\n\n /**\n * Execute the console command.\n *\n * @return int\n */\n public function handle(): int\n {\n $this->logger->info(self::LOG_PREFIX . ' Started');\n\n $reportId = $this->option('report-id');\n\n if ($reportId !== null) {\n return $this->processSingleReport((string) $reportId);\n }\n\n $now = Carbon::now();\n $isMonday = $now->isMonday();\n $isFirstDayOfMonth = $now->day === 1;\n $currentMonth = $now->month;\n\n // Check if the current month is a quarterly month (January, April, July, October)\n $isQuarterlyMonth = in_array($currentMonth, [1, 4, 7, 10], true);\n\n $this->logger->info(self::LOG_PREFIX . ' Checking conditions', [\n 'isMonday' => $isMonday,\n 'isFirstDayOfMonth' => $isFirstDayOfMonth,\n 'currentMonth' => $currentMonth,\n 'isQuarterlyMonth' => $isQuarterlyMonth,\n ]);\n\n // Process daily reports\n $this->processReports(AutomatedReportsService::FREQUENCY_DAILY);\n\n // Process weekly reports on Mondays\n if ($isMonday) {\n $this->processReports(AutomatedReportsService::FREQUENCY_WEEKLY);\n }\n\n // Process monthly reports on the first day of the month\n if ($isFirstDayOfMonth) {\n $this->processReports(AutomatedReportsService::FREQUENCY_MONTHLY);\n }\n\n // Process quarterly reports on the first day of January, April, July, and October\n if ($isFirstDayOfMonth && $isQuarterlyMonth) {\n $this->processReports(AutomatedReportsService::FREQUENCY_QUARTERLY);\n }\n\n $this->logger->info(self::LOG_PREFIX . ' Completed');\n\n return 0;\n }\n\n private function processSingleReport(string $reportId): int\n {\n $this->logger->info(self::LOG_PREFIX . ' Manual single-report mode', ['reportId' => $reportId]);\n\n $report = is_numeric($reportId)\n ? AutomatedReport::withTrashed()->find((int) $reportId)\n : AutomatedReport::withTrashed()->where('uuid', AutomatedReport::toOptimized($reportId))->first();\n\n if ($report === null) {\n $this->logger->error(self::LOG_PREFIX . ' Report not found', ['reportId' => $reportId]);\n $this->error(\"Report not found: {$reportId}\");\n\n return 1;\n }\n\n $this->warnIfNotApplicableForSchedule($report);\n\n $this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [\n 'reportUuid' => $report->getUuid(),\n 'teamId' => $report->getTeamId(),\n 'frequency' => $report->getFrequency(),\n 'type' => $report->getType(),\n ]);\n\n $job = $report->isAskJiminnyReport()\n ? new RequestGenerateAskJiminnyReportJob($report->getUuid())\n : new RequestGenerateReportJob($report->getUuid());\n\n $this->dispatcher->dispatchSync($job);\n\n $this->logger->info(self::LOG_PREFIX . ' Completed');\n\n return 0;\n }\n\n private function warnIfNotApplicableForSchedule(AutomatedReport $report): void\n {\n if ($report->trashed()) {\n $this->warn('Report is soft-deleted (deleted_at: ' . $report->getDeletedAt()?->toDateTimeString() . ').');\n }\n\n if (! $report->getStatus()) {\n $this->warn('Report status is inactive — would be skipped in scheduled run.');\n }\n\n $team = $report->getTeam();\n if ($team->getStatus() !== Team::STATUS_ACTIVE) {\n $this->warn(\"Team #{$report->getTeamId()} is not active (status: {$team->getStatus()}) — would be skipped in scheduled run.\");\n }\n\n if ($report->isExpired()) {\n $this->warn('Report is expired (expires_at: ' . $report->getExpiresAt()?->toDateString() . ') — would be skipped in scheduled run.');\n }\n\n $now = Carbon::now();\n $frequency = $report->getFrequency();\n $wouldRunToday = match ($frequency) {\n AutomatedReportsService::FREQUENCY_DAILY => true,\n AutomatedReportsService::FREQUENCY_WEEKLY => $now->isMonday(),\n AutomatedReportsService::FREQUENCY_MONTHLY => $now->day === 1,\n AutomatedReportsService::FREQUENCY_QUARTERLY => $now->day === 1 && in_array($now->month, [1, 4, 7, 10], true),\n default => false,\n };\n\n if (! $wouldRunToday) {\n $this->warn(\"Report frequency is '{$frequency}' — would NOT be scheduled to run today.\");\n }\n }\n\n /**\n * Process reports for a specific frequency.\n *\n * @param string $frequency\n *\n * @return void\n */\n private function processReports(string $frequency): void\n {\n $this->logger->info(self::LOG_PREFIX . \" Processing $frequency reports\");\n\n // Get all enabled, not deleted reports with active teams for the specified frequency\n $reports = $this->reportRepository->getActiveReportsByFrequency($frequency);\n // $reports = collect([AutomatedReport::find(68)]);\n\n $this->logger->info(self::LOG_PREFIX . \" Found {$reports->count()} $frequency reports to process\");\n\n /** @var AutomatedReport $report */\n foreach ($reports as $report) {\n $this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [\n 'reportUuid' => $report->getUuid(),\n 'teamId' => $report->getTeamId(),\n 'frequency' => $report->getFrequency(),\n 'type' => $report->getType(),\n ]);\n\n $job = $report->isAskJiminnyReport()\n ? new RequestGenerateAskJiminnyReportJob($report->getUuid())\n : new RequestGenerateReportJob($report->getUuid());\n\n // $this->dispatcher->dispatch($job);\n $this->dispatcher->dispatchSync($job);\n }\n }\n}","depth":4,"value":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Console\\Commands\\Reports;\n\nuse Carbon\\Carbon;\nuse Illuminate\\Console\\Command;\nuse Illuminate\\Contracts\\Bus\\Dispatcher as BusDispatcher;\nuse Jiminny\\Jobs\\AutomatedReports\\RequestGenerateAskJiminnyReportJob;\nuse Jiminny\\Jobs\\AutomatedReports\\RequestGenerateReportJob;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Repositories\\AutomatedReportsRepository;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Psr\\Log\\LoggerInterface;\n\nclass AutomatedReportsCommand extends Command\n{\n /**\n * Log prefix for all log messages\n */\n private const string LOG_PREFIX = '[automated-reports]';\n\n /**\n * The name and signature of the console command.\n *\n * @var string\n */\n protected $signature = 'automated-reports {--report-id= : Process a specific report by ID or UUID (bypasses frequency scheduling)}';\n\n /**\n * The console command description.\n *\n * @var string\n */\n protected $description = 'Process automated reports based on their frequency (weekly, monthly, quarterly). Use --report-id to manually trigger a specific report by ID or UUID.';\n\n\n public function __construct(\n private readonly LoggerInterface $logger,\n private readonly BusDispatcher $dispatcher,\n private readonly AutomatedReportsRepository $reportRepository\n ) {\n parent::__construct();\n }\n\n /**\n * Execute the console command.\n *\n * @return int\n */\n public function handle(): int\n {\n $this->logger->info(self::LOG_PREFIX . ' Started');\n\n $reportId = $this->option('report-id');\n\n if ($reportId !== null) {\n return $this->processSingleReport((string) $reportId);\n }\n\n $now = Carbon::now();\n $isMonday = $now->isMonday();\n $isFirstDayOfMonth = $now->day === 1;\n $currentMonth = $now->month;\n\n // Check if the current month is a quarterly month (January, April, July, October)\n $isQuarterlyMonth = in_array($currentMonth, [1, 4, 7, 10], true);\n\n $this->logger->info(self::LOG_PREFIX . ' Checking conditions', [\n 'isMonday' => $isMonday,\n 'isFirstDayOfMonth' => $isFirstDayOfMonth,\n 'currentMonth' => $currentMonth,\n 'isQuarterlyMonth' => $isQuarterlyMonth,\n ]);\n\n // Process daily reports\n $this->processReports(AutomatedReportsService::FREQUENCY_DAILY);\n\n // Process weekly reports on Mondays\n if ($isMonday) {\n $this->processReports(AutomatedReportsService::FREQUENCY_WEEKLY);\n }\n\n // Process monthly reports on the first day of the month\n if ($isFirstDayOfMonth) {\n $this->processReports(AutomatedReportsService::FREQUENCY_MONTHLY);\n }\n\n // Process quarterly reports on the first day of January, April, July, and October\n if ($isFirstDayOfMonth && $isQuarterlyMonth) {\n $this->processReports(AutomatedReportsService::FREQUENCY_QUARTERLY);\n }\n\n $this->logger->info(self::LOG_PREFIX . ' Completed');\n\n return 0;\n }\n\n private function processSingleReport(string $reportId): int\n {\n $this->logger->info(self::LOG_PREFIX . ' Manual single-report mode', ['reportId' => $reportId]);\n\n $report = is_numeric($reportId)\n ? AutomatedReport::withTrashed()->find((int) $reportId)\n : AutomatedReport::withTrashed()->where('uuid', AutomatedReport::toOptimized($reportId))->first();\n\n if ($report === null) {\n $this->logger->error(self::LOG_PREFIX . ' Report not found', ['reportId' => $reportId]);\n $this->error(\"Report not found: {$reportId}\");\n\n return 1;\n }\n\n $this->warnIfNotApplicableForSchedule($report);\n\n $this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [\n 'reportUuid' => $report->getUuid(),\n 'teamId' => $report->getTeamId(),\n 'frequency' => $report->getFrequency(),\n 'type' => $report->getType(),\n ]);\n\n $job = $report->isAskJiminnyReport()\n ? new RequestGenerateAskJiminnyReportJob($report->getUuid())\n : new RequestGenerateReportJob($report->getUuid());\n\n $this->dispatcher->dispatchSync($job);\n\n $this->logger->info(self::LOG_PREFIX . ' Completed');\n\n return 0;\n }\n\n private function warnIfNotApplicableForSchedule(AutomatedReport $report): void\n {\n if ($report->trashed()) {\n $this->warn('Report is soft-deleted (deleted_at: ' . $report->getDeletedAt()?->toDateTimeString() . ').');\n }\n\n if (! $report->getStatus()) {\n $this->warn('Report status is inactive — would be skipped in scheduled run.');\n }\n\n $team = $report->getTeam();\n if ($team->getStatus() !== Team::STATUS_ACTIVE) {\n $this->warn(\"Team #{$report->getTeamId()} is not active (status: {$team->getStatus()}) — would be skipped in scheduled run.\");\n }\n\n if ($report->isExpired()) {\n $this->warn('Report is expired (expires_at: ' . $report->getExpiresAt()?->toDateString() . ') — would be skipped in scheduled run.');\n }\n\n $now = Carbon::now();\n $frequency = $report->getFrequency();\n $wouldRunToday = match ($frequency) {\n AutomatedReportsService::FREQUENCY_DAILY => true,\n AutomatedReportsService::FREQUENCY_WEEKLY => $now->isMonday(),\n AutomatedReportsService::FREQUENCY_MONTHLY => $now->day === 1,\n AutomatedReportsService::FREQUENCY_QUARTERLY => $now->day === 1 && in_array($now->month, [1, 4, 7, 10], true),\n default => false,\n };\n\n if (! $wouldRunToday) {\n $this->warn(\"Report frequency is '{$frequency}' — would NOT be scheduled to run today.\");\n }\n }\n\n /**\n * Process reports for a specific frequency.\n *\n * @param string $frequency\n *\n * @return void\n */\n private function processReports(string $frequency): void\n {\n $this->logger->info(self::LOG_PREFIX . \" Processing $frequency reports\");\n\n // Get all enabled, not deleted reports with active teams for the specified frequency\n $reports = $this->reportRepository->getActiveReportsByFrequency($frequency);\n // $reports = collect([AutomatedReport::find(68)]);\n\n $this->logger->info(self::LOG_PREFIX . \" Found {$reports->count()} $frequency reports to process\");\n\n /** @var AutomatedReport $report */\n foreach ($reports as $report) {\n $this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [\n 'reportUuid' => $report->getUuid(),\n 'teamId' => $report->getTeamId(),\n 'frequency' => $report->getFrequency(),\n 'type' => $report->getType(),\n ]);\n\n $job = $report->isAskJiminnyReport()\n ? new RequestGenerateAskJiminnyReportJob($report->getUuid())\n : new RequestGenerateReportJob($report->getUuid());\n\n // $this->dispatcher->dispatch($job);\n $this->dispatcher->dispatchSync($job);\n }\n }\n}","role_description":"text entry area","is_enabled":true,"is_focused":true,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Execute","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Explain Plan","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Browse Query History","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"View Parameters","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Open Query Execution Settings…","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"In-Editor Results","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Tx: Auto","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Cancel Running Statements","depth":4,"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Playground","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"jiminny","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.088194445,"height":0.027777778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"16","depth":4,"role_description":"text"},{"role":"AXStaticText","text":"13","depth":4,"role_description":"text"},{"role":"AXStaticText","text":"13","depth":4,"role_description":"text"},{"role":"AXButton","text":"Previous Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Next Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"SELECT * FROM teams WHERE id = 1;\n\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;\nSELECT * FROM crm_fields WHERE id = 2234;\nSELECT * FROM crm_field_values WHERE crm_field_id = 2234;\n\nselect * from crm_profiles where user_id = 143;\n\nselect * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO\nselect * from business_processes where crm_configuration_id = 39;\n# 01941000000H669AAC, 01941000000H66JAAS\n\nselect * from record_type_field_values\n where record_type_id IN (24);\n\nselect * from crm_field_values where id IN (2730);\n\nselect * from crm_configurations where id = 39;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce'; #1035\n\n\nselect * from users where team_id = 1; # 222 group 3\nSELECT * FROM activities WHERE user_id = 222 order by id desc;\nselect * from sidekick_settings where team_id = 1;\nselect * from teams where id = 1;\nselect * from team_features where team_id = 1;\n\nselect * from activities where crm_configuration_id = 2\nand provider = 'ms-teams' and id = 608765;\n\nSELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';\n\nselect * from sidekick_settings where team_id = 2;\n\nSELECT * FROM activities WHERE id = 608660;\nselect * from activity_summary_logs where activity_id = 608660;\nselect * from ai_prompts where transcription_id = 11214;\n\n# ********************************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;\n# id: 608818, crm: 59628809737\nSELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;\n# id: 608821, crm: 59632069252\nSELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,\nplaybook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,\nscheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at\nFROM activities a\njoin calendar_events ce on a.calendar_event_id = ce.id\nWHERE a.id IN (608818, 608821);\n\nselect * from users where team_id = 1;\nselect * from team_settings where team_id = 1;\nselect * from crm_profiles where crm_configuration_id = 39 order by user_id;\n\nselect * from team_features where team_id = 1;\n\nselect * from users where team_id = 2;\n\nSELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639\n# Preslava N. Ivanova, grou id 3\n\nSELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;\n\nselect * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';\n\nselect\n a.id,\n a.type,\n a.scheduled_start_time,\n a.actual_start_time,\n a.created_at,\n a.opportunity_id,\n a.status\nFROM activities a\nWHERE opportunity_id = 344\nand status IN ('completed', 'received', 'delivered')\nand (\n (a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))\n;\n\nSELECT * FROM users WHERE id = 222;\n\nSELECT * FROM crm_profiles WHERE user_id = 222;\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;\n\nselect * from group_deal_risk_types;\n\nselect * from opportunities where team_id = 1;\n\nSELECT * FROM opportunities WHERE id = 315;\nSELECT * FROM crm_field_data WHERE object_id = 315;\nselect * from crm_field_data where object_id = 260;\n\nselect * from generic_ai_prompts where subject_id = 315;\n\nselect * from teams; # 36, 21, 121, james.graham@bullhorn.jiminny.com\nSELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';\n\n# ************************************************************************************\nselect * from teams where id = 1;\nselect * from crm_configurations where id = 39;\nselect * from users where team_id = 1;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 1;\n# 1 - 00541000004281rAAA\n# 204 - 0052g000003freeAAA\n# 429 - 0052g000003qGOiAAM\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\nselect * from activities where type = 'softphone'\nand created_at > '2024-12-11 15:24:36' order by id desc;\n\nselect * from activity_providers where team_id = 1;\nselect * from activity_provider_users where activity_provider_id = 328;\n\nselect * from opportunities where crm_configuration_id = 39\nAND account_id = 178 AND is_closed = false\norder by created_at DESC;\n\nselect * from contacts where id = 3952;\nselect * from accounts where id = 178;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations where id = 21;\nselect * from users where team_id = 36;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 36;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 36\nand sa.provider = 'bullhorn';\n\nselect * from social_accounts where id = 348;\nUPDATE social_accounts SET\nprovider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',\nprovider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',\nexpires = 1733998131,\nstate = 'connected'\nWHERE id = 348;\n\n# ************************************************************************************\nselect * from teams where id = 31;\nselect * from crm_configurations where id = 18;\n\nselect * from users where team_id = 31; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 31;\n\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 31\nand sa.provider = 'close';\n\nselect * from contacts where crm_configuration_id = 18;\n\n# ********************** NEPTUNE **************************************************************\nselect * from teams;\nselect * from users where id IN (1030, 1035, 1052);\nselect * from crm_configurations;\n\nselect * from users where team_id = 65; # 257\nselect * from team_settings where team_id = 65; # 257\nselect * from invitations where team_id = 65; # 257\nselect * from users where email = 'integration-account@jiminny.com'; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 65;\n\nselect * from crm_configurations where id = 53;\nselect * from accounts where crm_configuration_id = 53 order by id desc;\nselect * from leads where crm_configuration_id = 53 order by id desc;\nselect * from contacts where crm_configuration_id = 53 order by id desc;\nselect * from opportunities where crm_configuration_id = 53 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 53 order by id desc;\nselect * from crm_fields where crm_configuration_id = 53 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 53 order by id desc;\nselect * from stages where crm_configuration_id = 53 order by id desc;\n\n\nselect * from crm_profiles where crm_configuration_id = 13;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\nand sa.provider = 'integration-app';\n\nselect * from contacts where crm_configuration_id = 13;\n\nselect * from social_accounts where sociable_id = 283;\n\nSELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';\n\nselect * from activity_providers where team_id = 65;\nSELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\n;\n\n# ***************************** STAGING ********************************************\nSELECT * FROM teams;\nSELECT * FROM teams WHERE id = 88;\nSELECT * FROM teams WHERE id = 89;\nselect * from team_settings where team_id = 89;\nSELECT * FROM users WHERE team_id = 89;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 89;\n\nselect * from users;\nSELECT * FROM social_accounts WHERE sociable_id = 1761;\nSELECT * FROM crm_configurations WHERE id = 70;\nselect * from accounts where crm_configuration_id = 70 order by id desc;\nselect * from leads where crm_configuration_id = 70 order by id desc;\nselect * from contacts where crm_configuration_id = 70 order by id desc;\nselect * from opportunities where crm_configuration_id = 70 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 70 order by id desc;\nselect * from crm_fields where crm_configuration_id = 70 order by id desc;\nselect * from crm_field_values where crm_field_id = 3536 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 70 order by id desc;\nselect * from stages where crm_configuration_id = 70 order by id desc;\nselect * from business_processes where crm_configuration_id = 70 order by id desc;\nselect * from business_process_stages where business_process_id = 34;\n\nselect * from contacts where id = 10468;\n\nselect * from crm_layouts where crm_configuration_id = 70;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;\nSELECT * FROM crm_fields WHERE id IN (3533,3534,3535);\n\nselect * from activities where crm_configuration_id = 70\nand (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;\n\nSELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;\nSELECT * FROM activities where crm_configuration_id = 69 ;\n\nSELECT * FROM users WHERE email LIKE '%jiminny_web_sa2@jiminny.com%';\nSELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;\nSELECT * FROM opportunities WHERE id = 385;\n\nselect * from participants p\njoin activities a on p.activity_id = a.id\nwhere a.crm_configuration_id = 70\nand (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);\nSELECT * FROM participants WHERE id = 1013638;\n\nselect * from teams where id = 90;\nselect * from users where team_id = 90;\nselect * from social_accounts where social_accounts.sociable_id IN (1960,1760);\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 71;\nselect * from invitations where team_id = 90;\n\nselect * from crm_configurations where id = 71;\nselect * from accounts where crm_configuration_id = 71 order by id desc;\nselect * from leads where crm_configuration_id = 71 order by id desc;\nselect * from contacts where crm_configuration_id = 71 order by id desc;\nselect * from opportunities where crm_configuration_id = 71 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 71 order by id desc;\nselect * from crm_fields where crm_configuration_id = 71 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 71 order by id desc;\nselect * from stages where crm_configuration_id = 71 order by id desc;\n\nselect * from users order by secondary_email desc;\nselect u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa\n join users u on sa.sociable_id = u.id\nwhere sa.provider = 'google' and u.email LIKE 'aneliya%';\n\nselect * from failed_jobs order by id desc;\n\nselect * from users where email = 'ben.allwright@learningpeople.co.uk' or secondary_email = 'ben.allwright@learningpeople.co.uk';\n\nselect * from teams;\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 39;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\n# ************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;\nSELECT * FROM crm_configurations WHERE id = 70;\n\nselect * from teams where id = 1;\nselect * from groups where team_id = 1;\nselect * from users where team_id = 1;\n\nselect o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o\njoin users u on o.user_id = u.id\njoin groups g on u.group_id = g.id\njoin role_user ru on u.id = ru.user_id\njoin roles r on ru.role_id = r.id\nwhere o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';\n\nselect * from role_user where user_id = 143;\nselect * from roles;\n\nselect * from role_user;\nselect * from groups where id = 9;\nselect * from scope_groups where group_id = 9;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations;\nSELECT * FROM social_accounts WHERE sociable_id = 121;\n\nhttps://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105\nhttps://crmsandbox.zoho.com/crm/\n\nhttps://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080\n https://crm.zoho.com/crm/\n org3469620\n\nSELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;\n\nselect * from users where email LIKE \"%mobile_automation_%\";\nselect * from social_accounts where sociable_id IN (2228);\nselect * from crm_profiles where user_id IN (2222,2223,2226,2227);\n\nselect * from teams order by id desc;\nSELECT * FROM users WHERE id = 2229;\nSELECT * FROM crm_profiles WHERE user_id = 2229;\nselect * from opportunities where crm_configuration_id = 88;\nselect * from crm_fields where crm_configuration_id = 88;\nselect * from crm_profiles where crm_configuration_id = 88;\n\nSELECT * FROM teams WHERE id = 1;\n\nSELECT * FROM users WHERE id = 143;\nSELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;\n\nhttps://app.staging.jiminny.com/ondemand?\n min_duration=1\n &\n only_recorded=1\n &\n user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e\n &\n sequence_number=2\n\n select * from users where team_id = 1 and email like '%stoyan%'\n\nselect * from coaching_feedbacks;\n\nselect * from teams;\nSELECT * FROM users WHERE team_id = 36;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from users where id = 143;\n\nSELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\n\nselect * from users where team_id = 2;\nselect * from activities where crm_configuration_id = 39\nand activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'\nAND user_id = 143\norder by id desc;\n\n# ************************************************************************************\nselect * from teams where id = 142; # 2312, 126\nselect * from team_settings;\nselect * from users where team_id = 142; # 21642\nSELECT * FROM social_accounts WHERE sociable_id = 21642;\nSELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;\nselect * from crm_profiles where id IN (93);\nselect * from invitations;\nselect * from team_features where team_id = 1;\n\nSELECT * FROM crm_configurations WHERE id = 126;\nselect * from accounts where crm_configuration_id = 126 order by id desc;\nselect * from leads where crm_configuration_id = 126 order by id desc;\nselect * from contacts where crm_configuration_id = 126 order by id desc;\nselect * from opportunities where crm_configuration_id = 126 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 126 order by id desc;\nselect * from crm_fields where crm_configuration_id = 126 # 11060\n# and type IN ('picklist', 'status')\n# and object_type = 'task'\norder by id desc;\n# 5731,5732,5733\nselect DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;\nselect * from crm_layouts where crm_configuration_id = 126 order by id desc;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);\nselect * from stages where crm_configuration_id = 126 order by id desc;\nselect * from business_processes where crm_configuration_id = 126 order by id desc;\nselect * from business_process_stages where business_process_id IN (76,75,74,73);\nselect * from playbooks where team_id = 142;\nselect * from playbook_layouts where playbook_id IN (108);\nSELECT * FROM playbook_categories WHERE playbook_id IN (108);\n\nselect * from teams where id = 130;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 2\nand sa.provider = 'hubspot';\n\nSELECT * FROM activities\n WHERE crm_configuration_id = 110;\n\nselect * from teams;\nselect * from crm_configurations;\n\nSELECT * FROM activities WHERE id = 628773;\nSELECT * FROM crm_profiles WHERE user_id = 1460;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from teams;\nselect ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id\njoin permission_role pr on pr.role_id = ru.role_id\n join permissions p on p.id = pr.permission_id\nwhere team_id = 495 and p.name IN ('dial');\n\nselect * from teams where id = 145;\nselect * from crm_configurations where id = 129;\nselect * from social_accounts where sociable_id = 2317;\nSELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;\n\nselect * from teams where id = 1;\nSELECT * FROM crm_layouts WHERE crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;\nSELECT * FROM crm_layout_entities WHERE id = 5507;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');\n\nselect * from teams;\nselect * from activities where crm_configuration_id = 14;\n\nSELECT * FROM social_accounts where provider = 'copper';\n\nselect * from activities where id = 628467;\nselect * from participants where activity_id = 628467;\n\nSELECT * FROM contacts WHERE id = 3969;\nSELECT * FROM accounts WHERE id = 177;\n\nSELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;\n\n# ********************* BH\nselect * from teams where id = 36;\nSELECT * FROM crm_configurations WHERE id = 21;\nselect * from activities where crm_configuration_id = 21 and id = 607901;\nselect * from activities where crm_configuration_id = 21;\n\nselect * roles;\nselect * from permissions;\nselect * from permission_role where permission_id = 226;\n\nselect * from migrations order by id desc;\n\n# mercury\n# neptune\n# earth\n\nselect * from teams;\nselect * from teams where id = 19;\nselect * from teams where id = 27;\nselect * from users where team_id = 27;\nSELECT * FROM crm_configurations WHERE id = 42;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from activities where id = 631461;\nSELECT * FROM crm_field_values WHERE crm_field_id = 180;\n\nselect * from teams where id = 2;\nSELECT * FROM social_accounts WHERE sociable_id = 89;\n\nSELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273\nselect * from activity_summary_logs where activity_id = 634273;\n\nselect * from sidekick_settings where team_id = 2;\n\nselect * from teams; # 2, 2\nSELECT * FROM crm_configurations WHERE team_id = 2; # 2\nselect * from team_features where team_id = 2;\nselect * from features;\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;\n\nselect * from automated_reports order by id desc;\nselect * from automated_report_results order by id desc;\nselect * from users where team_id = 1 and id IN (7160, 3248);\nselect * from migrations order by id desc;\n\nSELECT\n CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,\n u.email,\n sa.*,\n t.owner_id FROM social_accounts sa\nJOIN users u on u.id = sa.sociable_id\nJOIN teams t on t.id = u.team_id\nWHERE u.team_id = 1 and sa.provider = 'salesforce';\n\nselect * from teams where id = 1;\nselect * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;\nselect * from groups where id = 565;\nselect * from playbooks where team_id = 1;\nselect * from playbooks where id = 175;\nselect * from playbook_categories where playbook_id = 175;\nselect * from users where team_id = 1;\nselect * from users where id = 7160;\nselect * from crm_profiles where user_id = 7160;\nselect * from features;\nselect\n *\n# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,\n# crm_configuration_id, crm_provider_id, transcription_id, status\nfrom activities where crm_configuration_id = 1 and type = 'conference'\n# and crm_provider_id IS NOT NULL\nand provider != 'uploader' and actual_start_time IS NOT NULL\nORDER by id desc;\nselect * from activities where id = 54747783; # 00UO400000pCzojMAC\n\nselect p.id, p.activity_type, pc.id, pc.name\nFROM playbooks p\njoin playbook_categories pc on p.id = pc.playbook_id\nwhere p.team_id = 1 and p.activity_type = 'event';\n\nSELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';\nSELECT * FROM crm_field_values WHERE crm_field_id = 4;\n\nselect * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id\nwhere crm_configuration_id = 1 and pl.playbook_id = 175;\n\nselect * from teams;\nSELECT r.* FROM automated_reports r\njoin teams t on r.team_id = t.id\nWHERE r.frequency = 'daily'\n and r.status = 1\nAND t.status = 'active'\nAND (r.expires_at >= now() OR r.expires_at IS NULL);\n\nselect * from automated_report_results where report_id IN (18, 33);\n\nselect * from automated_reports;\nselect * from automated_report_results where report_id IN (34);","depth":4,"value":"SELECT * FROM teams WHERE id = 1;\n\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;\nSELECT * FROM crm_fields WHERE id = 2234;\nSELECT * FROM crm_field_values WHERE crm_field_id = 2234;\n\nselect * from crm_profiles where user_id = 143;\n\nselect * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO\nselect * from business_processes where crm_configuration_id = 39;\n# 01941000000H669AAC, 01941000000H66JAAS\n\nselect * from record_type_field_values\n where record_type_id IN (24);\n\nselect * from crm_field_values where id IN (2730);\n\nselect * from crm_configurations where id = 39;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce'; #1035\n\n\nselect * from users where team_id = 1; # 222 group 3\nSELECT * FROM activities WHERE user_id = 222 order by id desc;\nselect * from sidekick_settings where team_id = 1;\nselect * from teams where id = 1;\nselect * from team_features where team_id = 1;\n\nselect * from activities where crm_configuration_id = 2\nand provider = 'ms-teams' and id = 608765;\n\nSELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';\n\nselect * from sidekick_settings where team_id = 2;\n\nSELECT * FROM activities WHERE id = 608660;\nselect * from activity_summary_logs where activity_id = 608660;\nselect * from ai_prompts where transcription_id = 11214;\n\n# ********************************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;\n# id: 608818, crm: 59628809737\nSELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;\n# id: 608821, crm: 59632069252\nSELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,\nplaybook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,\nscheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at\nFROM activities a\njoin calendar_events ce on a.calendar_event_id = ce.id\nWHERE a.id IN (608818, 608821);\n\nselect * from users where team_id = 1;\nselect * from team_settings where team_id = 1;\nselect * from crm_profiles where crm_configuration_id = 39 order by user_id;\n\nselect * from team_features where team_id = 1;\n\nselect * from users where team_id = 2;\n\nSELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639\n# Preslava N. Ivanova, grou id 3\n\nSELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;\n\nselect * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';\n\nselect\n a.id,\n a.type,\n a.scheduled_start_time,\n a.actual_start_time,\n a.created_at,\n a.opportunity_id,\n a.status\nFROM activities a\nWHERE opportunity_id = 344\nand status IN ('completed', 'received', 'delivered')\nand (\n (a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))\n;\n\nSELECT * FROM users WHERE id = 222;\n\nSELECT * FROM crm_profiles WHERE user_id = 222;\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;\n\nselect * from group_deal_risk_types;\n\nselect * from opportunities where team_id = 1;\n\nSELECT * FROM opportunities WHERE id = 315;\nSELECT * FROM crm_field_data WHERE object_id = 315;\nselect * from crm_field_data where object_id = 260;\n\nselect * from generic_ai_prompts where subject_id = 315;\n\nselect * from teams; # 36, 21, 121, james.graham@bullhorn.jiminny.com\nSELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';\n\n# ************************************************************************************\nselect * from teams where id = 1;\nselect * from crm_configurations where id = 39;\nselect * from users where team_id = 1;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 1;\n# 1 - 00541000004281rAAA\n# 204 - 0052g000003freeAAA\n# 429 - 0052g000003qGOiAAM\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\nselect * from activities where type = 'softphone'\nand created_at > '2024-12-11 15:24:36' order by id desc;\n\nselect * from activity_providers where team_id = 1;\nselect * from activity_provider_users where activity_provider_id = 328;\n\nselect * from opportunities where crm_configuration_id = 39\nAND account_id = 178 AND is_closed = false\norder by created_at DESC;\n\nselect * from contacts where id = 3952;\nselect * from accounts where id = 178;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations where id = 21;\nselect * from users where team_id = 36;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 36;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 36\nand sa.provider = 'bullhorn';\n\nselect * from social_accounts where id = 348;\nUPDATE social_accounts SET\nprovider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',\nprovider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',\nexpires = 1733998131,\nstate = 'connected'\nWHERE id = 348;\n\n# ************************************************************************************\nselect * from teams where id = 31;\nselect * from crm_configurations where id = 18;\n\nselect * from users where team_id = 31; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 31;\n\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 31\nand sa.provider = 'close';\n\nselect * from contacts where crm_configuration_id = 18;\n\n# ********************** NEPTUNE **************************************************************\nselect * from teams;\nselect * from users where id IN (1030, 1035, 1052);\nselect * from crm_configurations;\n\nselect * from users where team_id = 65; # 257\nselect * from team_settings where team_id = 65; # 257\nselect * from invitations where team_id = 65; # 257\nselect * from users where email = 'integration-account@jiminny.com'; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 65;\n\nselect * from crm_configurations where id = 53;\nselect * from accounts where crm_configuration_id = 53 order by id desc;\nselect * from leads where crm_configuration_id = 53 order by id desc;\nselect * from contacts where crm_configuration_id = 53 order by id desc;\nselect * from opportunities where crm_configuration_id = 53 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 53 order by id desc;\nselect * from crm_fields where crm_configuration_id = 53 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 53 order by id desc;\nselect * from stages where crm_configuration_id = 53 order by id desc;\n\n\nselect * from crm_profiles where crm_configuration_id = 13;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\nand sa.provider = 'integration-app';\n\nselect * from contacts where crm_configuration_id = 13;\n\nselect * from social_accounts where sociable_id = 283;\n\nSELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';\n\nselect * from activity_providers where team_id = 65;\nSELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\n;\n\n# ***************************** STAGING ********************************************\nSELECT * FROM teams;\nSELECT * FROM teams WHERE id = 88;\nSELECT * FROM teams WHERE id = 89;\nselect * from team_settings where team_id = 89;\nSELECT * FROM users WHERE team_id = 89;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 89;\n\nselect * from users;\nSELECT * FROM social_accounts WHERE sociable_id = 1761;\nSELECT * FROM crm_configurations WHERE id = 70;\nselect * from accounts where crm_configuration_id = 70 order by id desc;\nselect * from leads where crm_configuration_id = 70 order by id desc;\nselect * from contacts where crm_configuration_id = 70 order by id desc;\nselect * from opportunities where crm_configuration_id = 70 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 70 order by id desc;\nselect * from crm_fields where crm_configuration_id = 70 order by id desc;\nselect * from crm_field_values where crm_field_id = 3536 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 70 order by id desc;\nselect * from stages where crm_configuration_id = 70 order by id desc;\nselect * from business_processes where crm_configuration_id = 70 order by id desc;\nselect * from business_process_stages where business_process_id = 34;\n\nselect * from contacts where id = 10468;\n\nselect * from crm_layouts where crm_configuration_id = 70;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;\nSELECT * FROM crm_fields WHERE id IN (3533,3534,3535);\n\nselect * from activities where crm_configuration_id = 70\nand (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;\n\nSELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;\nSELECT * FROM activities where crm_configuration_id = 69 ;\n\nSELECT * FROM users WHERE email LIKE '%jiminny_web_sa2@jiminny.com%';\nSELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;\nSELECT * FROM opportunities WHERE id = 385;\n\nselect * from participants p\njoin activities a on p.activity_id = a.id\nwhere a.crm_configuration_id = 70\nand (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);\nSELECT * FROM participants WHERE id = 1013638;\n\nselect * from teams where id = 90;\nselect * from users where team_id = 90;\nselect * from social_accounts where social_accounts.sociable_id IN (1960,1760);\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 71;\nselect * from invitations where team_id = 90;\n\nselect * from crm_configurations where id = 71;\nselect * from accounts where crm_configuration_id = 71 order by id desc;\nselect * from leads where crm_configuration_id = 71 order by id desc;\nselect * from contacts where crm_configuration_id = 71 order by id desc;\nselect * from opportunities where crm_configuration_id = 71 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 71 order by id desc;\nselect * from crm_fields where crm_configuration_id = 71 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 71 order by id desc;\nselect * from stages where crm_configuration_id = 71 order by id desc;\n\nselect * from users order by secondary_email desc;\nselect u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa\n join users u on sa.sociable_id = u.id\nwhere sa.provider = 'google' and u.email LIKE 'aneliya%';\n\nselect * from failed_jobs order by id desc;\n\nselect * from users where email = 'ben.allwright@learningpeople.co.uk' or secondary_email = 'ben.allwright@learningpeople.co.uk';\n\nselect * from teams;\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 39;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\n# ************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;\nSELECT * FROM crm_configurations WHERE id = 70;\n\nselect * from teams where id = 1;\nselect * from groups where team_id = 1;\nselect * from users where team_id = 1;\n\nselect o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o\njoin users u on o.user_id = u.id\njoin groups g on u.group_id = g.id\njoin role_user ru on u.id = ru.user_id\njoin roles r on ru.role_id = r.id\nwhere o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';\n\nselect * from role_user where user_id = 143;\nselect * from roles;\n\nselect * from role_user;\nselect * from groups where id = 9;\nselect * from scope_groups where group_id = 9;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations;\nSELECT * FROM social_accounts WHERE sociable_id = 121;\n\nhttps://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105\nhttps://crmsandbox.zoho.com/crm/\n\nhttps://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080\n https://crm.zoho.com/crm/\n org3469620\n\nSELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;\n\nselect * from users where email LIKE \"%mobile_automation_%\";\nselect * from social_accounts where sociable_id IN (2228);\nselect * from crm_profiles where user_id IN (2222,2223,2226,2227);\n\nselect * from teams order by id desc;\nSELECT * FROM users WHERE id = 2229;\nSELECT * FROM crm_profiles WHERE user_id = 2229;\nselect * from opportunities where crm_configuration_id = 88;\nselect * from crm_fields where crm_configuration_id = 88;\nselect * from crm_profiles where crm_configuration_id = 88;\n\nSELECT * FROM teams WHERE id = 1;\n\nSELECT * FROM users WHERE id = 143;\nSELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;\n\nhttps://app.staging.jiminny.com/ondemand?\n min_duration=1\n &\n only_recorded=1\n &\n user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e\n &\n sequence_number=2\n\n select * from users where team_id = 1 and email like '%stoyan%'\n\nselect * from coaching_feedbacks;\n\nselect * from teams;\nSELECT * FROM users WHERE team_id = 36;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from users where id = 143;\n\nSELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\n\nselect * from users where team_id = 2;\nselect * from activities where crm_configuration_id = 39\nand activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'\nAND user_id = 143\norder by id desc;\n\n# ************************************************************************************\nselect * from teams where id = 142; # 2312, 126\nselect * from team_settings;\nselect * from users where team_id = 142; # 21642\nSELECT * FROM social_accounts WHERE sociable_id = 21642;\nSELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;\nselect * from crm_profiles where id IN (93);\nselect * from invitations;\nselect * from team_features where team_id = 1;\n\nSELECT * FROM crm_configurations WHERE id = 126;\nselect * from accounts where crm_configuration_id = 126 order by id desc;\nselect * from leads where crm_configuration_id = 126 order by id desc;\nselect * from contacts where crm_configuration_id = 126 order by id desc;\nselect * from opportunities where crm_configuration_id = 126 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 126 order by id desc;\nselect * from crm_fields where crm_configuration_id = 126 # 11060\n# and type IN ('picklist', 'status')\n# and object_type = 'task'\norder by id desc;\n# 5731,5732,5733\nselect DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;\nselect * from crm_layouts where crm_configuration_id = 126 order by id desc;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);\nselect * from stages where crm_configuration_id = 126 order by id desc;\nselect * from business_processes where crm_configuration_id = 126 order by id desc;\nselect * from business_process_stages where business_process_id IN (76,75,74,73);\nselect * from playbooks where team_id = 142;\nselect * from playbook_layouts where playbook_id IN (108);\nSELECT * FROM playbook_categories WHERE playbook_id IN (108);\n\nselect * from teams where id = 130;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 2\nand sa.provider = 'hubspot';\n\nSELECT * FROM activities\n WHERE crm_configuration_id = 110;\n\nselect * from teams;\nselect * from crm_configurations;\n\nSELECT * FROM activities WHERE id = 628773;\nSELECT * FROM crm_profiles WHERE user_id = 1460;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from teams;\nselect ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id\njoin permission_role pr on pr.role_id = ru.role_id\n join permissions p on p.id = pr.permission_id\nwhere team_id = 495 and p.name IN ('dial');\n\nselect * from teams where id = 145;\nselect * from crm_configurations where id = 129;\nselect * from social_accounts where sociable_id = 2317;\nSELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;\n\nselect * from teams where id = 1;\nSELECT * FROM crm_layouts WHERE crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;\nSELECT * FROM crm_layout_entities WHERE id = 5507;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');\n\nselect * from teams;\nselect * from activities where crm_configuration_id = 14;\n\nSELECT * FROM social_accounts where provider = 'copper';\n\nselect * from activities where id = 628467;\nselect * from participants where activity_id = 628467;\n\nSELECT * FROM contacts WHERE id = 3969;\nSELECT * FROM accounts WHERE id = 177;\n\nSELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;\n\n# ********************* BH\nselect * from teams where id = 36;\nSELECT * FROM crm_configurations WHERE id = 21;\nselect * from activities where crm_configuration_id = 21 and id = 607901;\nselect * from activities where crm_configuration_id = 21;\n\nselect * roles;\nselect * from permissions;\nselect * from permission_role where permission_id = 226;\n\nselect * from migrations order by id desc;\n\n# mercury\n# neptune\n# earth\n\nselect * from teams;\nselect * from teams where id = 19;\nselect * from teams where id = 27;\nselect * from users where team_id = 27;\nSELECT * FROM crm_configurations WHERE id = 42;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from activities where id = 631461;\nSELECT * FROM crm_field_values WHERE crm_field_id = 180;\n\nselect * from teams where id = 2;\nSELECT * FROM social_accounts WHERE sociable_id = 89;\n\nSELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273\nselect * from activity_summary_logs where activity_id = 634273;\n\nselect * from sidekick_settings where team_id = 2;\n\nselect * from teams; # 2, 2\nSELECT * FROM crm_configurations WHERE team_id = 2; # 2\nselect * from team_features where team_id = 2;\nselect * from features;\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;\n\nselect * from automated_reports order by id desc;\nselect * from automated_report_results order by id desc;\nselect * from users where team_id = 1 and id IN (7160, 3248);\nselect * from migrations order by id desc;\n\nSELECT\n CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,\n u.email,\n sa.*,\n t.owner_id FROM social_accounts sa\nJOIN users u on u.id = sa.sociable_id\nJOIN teams t on t.id = u.team_id\nWHERE u.team_id = 1 and sa.provider = 'salesforce';\n\nselect * from teams where id = 1;\nselect * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;\nselect * from groups where id = 565;\nselect * from playbooks where team_id = 1;\nselect * from playbooks where id = 175;\nselect * from playbook_categories where playbook_id = 175;\nselect * from users where team_id = 1;\nselect * from users where id = 7160;\nselect * from crm_profiles where user_id = 7160;\nselect * from features;\nselect\n *\n# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,\n# crm_configuration_id, crm_provider_id, transcription_id, status\nfrom activities where crm_configuration_id = 1 and type = 'conference'\n# and crm_provider_id IS NOT NULL\nand provider != 'uploader' and actual_start_time IS NOT NULL\nORDER by id desc;\nselect * from activities where id = 54747783; # 00UO400000pCzojMAC\n\nselect p.id, p.activity_type, pc.id, pc.name\nFROM playbooks p\njoin playbook_categories pc on p.id = pc.playbook_id\nwhere p.team_id = 1 and p.activity_type = 'event';\n\nSELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';\nSELECT * FROM crm_field_values WHERE crm_field_id = 4;\n\nselect * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id\nwhere crm_configuration_id = 1 and pl.playbook_id = 175;\n\nselect * from teams;\nSELECT r.* FROM automated_reports r\njoin teams t on r.team_id = t.id\nWHERE r.frequency = 'daily'\n and r.status = 1\nAND t.status = 'active'\nAND (r.expires_at >= now() OR r.expires_at IS NULL);\n\nselect * from automated_report_results where report_id IN (18, 33);\n\nselect * from automated_reports;\nselect * from automated_report_results where report_id IN (34);","role_description":"text entry area","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Project","depth":3,"role_description":"text"},{"role":"AXButton","text":"Project","depth":3,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"New File or Directory…","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Expand Selected","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Collapse All","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Options","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false}]...
|
-4325362117536949503
|
6686649039917036621
|
click
|
accessibility
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
<?php
declare(strict_types=1);
namespace Jiminny\Console\Commands\Reports;
use Carbon\Carbon;
use Illuminate\Console\Command;
use Illuminate\Contracts\Bus\Dispatcher as BusDispatcher;
use Jiminny\Jobs\AutomatedReports\RequestGenerateAskJiminnyReportJob;
use Jiminny\Jobs\AutomatedReports\RequestGenerateReportJob;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\Team;
use Jiminny\Repositories\AutomatedReportsRepository;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Psr\Log\LoggerInterface;
class AutomatedReportsCommand extends Command
{
/**
* Log prefix for all log messages
*/
private const string LOG_PREFIX = '[automated-reports]';
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'automated-reports {--report-id= : Process a specific report by ID or UUID (bypasses frequency scheduling)}';
/**
* The console command description.
*
* @var string
*/
protected $description = 'Process automated reports based on their frequency (weekly, monthly, quarterly). Use --report-id to manually trigger a specific report by ID or UUID.';
public function __construct(
private readonly LoggerInterface $logger,
private readonly BusDispatcher $dispatcher,
private readonly AutomatedReportsRepository $reportRepository
) {
parent::__construct();
}
/**
* Execute the console command.
*
* @return int
*/
public function handle(): int
{
$this->logger->info(self::LOG_PREFIX . ' Started');
$reportId = $this->option('report-id');
if ($reportId !== null) {
return $this->processSingleReport((string) $reportId);
}
$now = Carbon::now();
$isMonday = $now->isMonday();
$isFirstDayOfMonth = $now->day === 1;
$currentMonth = $now->month;
// Check if the current month is a quarterly month (January, April, July, October)
$isQuarterlyMonth = in_array($currentMonth, [1, 4, 7, 10], true);
$this->logger->info(self::LOG_PREFIX . ' Checking conditions', [
'isMonday' => $isMonday,
'isFirstDayOfMonth' => $isFirstDayOfMonth,
'currentMonth' => $currentMonth,
'isQuarterlyMonth' => $isQuarterlyMonth,
]);
// Process daily reports
$this->processReports(AutomatedReportsService::FREQUENCY_DAILY);
// Process weekly reports on Mondays
if ($isMonday) {
$this->processReports(AutomatedReportsService::FREQUENCY_WEEKLY);
}
// Process monthly reports on the first day of the month
if ($isFirstDayOfMonth) {
$this->processReports(AutomatedReportsService::FREQUENCY_MONTHLY);
}
// Process quarterly reports on the first day of January, April, July, and October
if ($isFirstDayOfMonth && $isQuarterlyMonth) {
$this->processReports(AutomatedReportsService::FREQUENCY_QUARTERLY);
}
$this->logger->info(self::LOG_PREFIX . ' Completed');
return 0;
}
private function processSingleReport(string $reportId): int
{
$this->logger->info(self::LOG_PREFIX . ' Manual single-report mode', ['reportId' => $reportId]);
$report = is_numeric($reportId)
? AutomatedReport::withTrashed()->find((int) $reportId)
: AutomatedReport::withTrashed()->where('uuid', AutomatedReport::toOptimized($reportId))->first();
if ($report === null) {
$this->logger->error(self::LOG_PREFIX . ' Report not found', ['reportId' => $reportId]);
$this->error("Report not found: {$reportId}");
return 1;
}
$this->warnIfNotApplicableForSchedule($report);
$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [
'reportUuid' => $report->getUuid(),
'teamId' => $report->getTeamId(),
'frequency' => $report->getFrequency(),
'type' => $report->getType(),
]);
$job = $report->isAskJiminnyReport()
? new RequestGenerateAskJiminnyReportJob($report->getUuid())
: new RequestGenerateReportJob($report->getUuid());
$this->dispatcher->dispatchSync($job);
$this->logger->info(self::LOG_PREFIX . ' Completed');
return 0;
}
private function warnIfNotApplicableForSchedule(AutomatedReport $report): void
{
if ($report->trashed()) {
$this->warn('Report is soft-deleted (deleted_at: ' . $report->getDeletedAt()?->toDateTimeString() . ').');
}
if (! $report->getStatus()) {
$this->warn('Report status is inactive — would be skipped in scheduled run.');
}
$team = $report->getTeam();
if ($team->getStatus() !== Team::STATUS_ACTIVE) {
$this->warn("Team #{$report->getTeamId()} is not active (status: {$team->getStatus()}) — would be skipped in scheduled run.");
}
if ($report->isExpired()) {
$this->warn('Report is expired (expires_at: ' . $report->getExpiresAt()?->toDateString() . ') — would be skipped in scheduled run.');
}
$now = Carbon::now();
$frequency = $report->getFrequency();
$wouldRunToday = match ($frequency) {
AutomatedReportsService::FREQUENCY_DAILY => true,
AutomatedReportsService::FREQUENCY_WEEKLY => $now->isMonday(),
AutomatedReportsService::FREQUENCY_MONTHLY => $now->day === 1,
AutomatedReportsService::FREQUENCY_QUARTERLY => $now->day === 1 && in_array($now->month, [1, 4, 7, 10], true),
default => false,
};
if (! $wouldRunToday) {
$this->warn("Report frequency is '{$frequency}' — would NOT be scheduled to run today.");
}
}
/**
* Process reports for a specific frequency.
*
* @param string $frequency
*
* @return void
*/
private function processReports(string $frequency): void
{
$this->logger->info(self::LOG_PREFIX . " Processing $frequency reports");
// Get all enabled, not deleted reports with active teams for the specified frequency
$reports = $this->reportRepository->getActiveReportsByFrequency($frequency);
// $reports = collect([AutomatedReport::find(68)]);
$this->logger->info(self::LOG_PREFIX . " Found {$reports->count()} $frequency reports to process");
/** @var AutomatedReport $report */
foreach ($reports as $report) {
$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [
'reportUuid' => $report->getUuid(),
'teamId' => $report->getTeamId(),
'frequency' => $report->getFrequency(),
'type' => $report->getType(),
]);
$job = $report->isAskJiminnyReport()
? new RequestGenerateAskJiminnyReportJob($report->getUuid())
: new RequestGenerateReportJob($report->getUuid());
// $this->dispatcher->dispatch($job);
$this->dispatcher->dispatchSync($job);
}
}
}
Execute
Explain Plan
Browse Query History
View Parameters
Open Query Execution Settings…
In-Editor Results
Tx: Auto
Cancel Running Statements
Playground
jiminny
Sync Changes
Hide This Notification
Code changed:
Hide
16
13
13
Previous Highlighted Error
Next Highlighted Error
SELECT * FROM teams WHERE id = 1;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;
SELECT * FROM crm_fields WHERE id = 2234;
SELECT * FROM crm_field_values WHERE crm_field_id = 2234;
select * from crm_profiles where user_id = 143;
select * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO
select * from business_processes where crm_configuration_id = 39;
# 01941000000H669AAC, 01941000000H66JAAS
select * from record_type_field_values
where record_type_id IN (24);
select * from crm_field_values where id IN (2730);
select * from crm_configurations where id = 39;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce'; #1035
select * from users where team_id = 1; # 222 group 3
SELECT * FROM activities WHERE user_id = 222 order by id desc;
select * from sidekick_settings where team_id = 1;
select * from teams where id = 1;
select * from team_features where team_id = 1;
select * from activities where crm_configuration_id = 2
and provider = 'ms-teams' and id = 608765;
SELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';
select * from sidekick_settings where team_id = 2;
SELECT * FROM activities WHERE id = 608660;
select * from activity_summary_logs where activity_id = 608660;
select * from ai_prompts where transcription_id = 11214;
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;
# id: 608818, crm: 59628809737
SELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;
# id: 608821, crm: 59632069252
SELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,
playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,
scheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at
FROM activities a
join calendar_events ce on a.calendar_event_id = ce.id
WHERE a.id IN (608818, 608821);
select * from users where team_id = 1;
select * from team_settings where team_id = 1;
select * from crm_profiles where crm_configuration_id = 39 order by user_id;
select * from team_features where team_id = 1;
select * from users where team_id = 2;
SELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639
# Preslava N. Ivanova, grou id 3
SELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;
select * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';
select
a.id,
a.type,
a.scheduled_start_time,
a.actual_start_time,
a.created_at,
a.opportunity_id,
a.status
FROM activities a
WHERE opportunity_id = 344
and status IN ('completed', 'received', 'delivered')
and (
(a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))
;
SELECT * FROM users WHERE id = 222;
SELECT * FROM crm_profiles WHERE user_id = 222;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;
select * from group_deal_risk_types;
select * from opportunities where team_id = 1;
SELECT * FROM opportunities WHERE id = 315;
SELECT * FROM crm_field_data WHERE object_id = 315;
select * from crm_field_data where object_id = 260;
select * from generic_ai_prompts where subject_id = 315;
select * from teams; # 36, 21, 121, [EMAIL]
SELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';
# [PASSWORD_DOTS]
select * from teams where id = 1;
select * from crm_configurations where id = 39;
select * from users where team_id = 1;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 1;
# 1 - 00541000004281rAAA
# 204 - 0052g000003freeAAA
# 429 - 0052g000003qGOiAAM
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
select * from activities where type = 'softphone'
and created_at > '2024-12-11 15:24:36' order by id desc;
select * from activity_providers where team_id = 1;
select * from activity_provider_users where activity_provider_id = 328;
select * from opportunities where crm_configuration_id = 39
AND account_id = 178 AND is_closed = false
order by created_at DESC;
select * from contacts where id = 3952;
select * from accounts where id = 178;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations where id = 21;
select * from users where team_id = 36;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 36
and sa.provider = 'bullhorn';
select * from social_accounts where id = 348;
UPDATE social_accounts SET
provider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',
provider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',
expires = 1733998131,
state = 'connected'
WHERE id = 348;
# [PASSWORD_DOTS]
select * from teams where id = 31;
select * from crm_configurations where id = 18;
select * from users where team_id = 31; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 31;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 31
and sa.provider = 'close';
select * from contacts where crm_configuration_id = 18;
# [PASSWORD_DOTS] NEPTUNE [PASSWORD_DOTS]
select * from teams;
select * from users where id IN (1030, 1035, 1052);
select * from crm_configurations;
select * from users where team_id = 65; # 257
select * from team_settings where team_id = 65; # 257
select * from invitations where team_id = 65; # 257
select * from users where email = '[EMAIL]'; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 65;
select * from crm_configurations where id = 53;
select * from accounts where crm_configuration_id = 53 order by id desc;
select * from leads where crm_configuration_id = 53 order by id desc;
select * from contacts where crm_configuration_id = 53 order by id desc;
select * from opportunities where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 53 order by id desc;
select * from crm_fields where crm_configuration_id = 53 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 53 order by id desc;
select * from stages where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 13;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
and sa.provider = 'integration-app';
select * from contacts where crm_configuration_id = 13;
select * from social_accounts where sociable_id = 283;
SELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';
select * from activity_providers where team_id = 65;
SELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
;
# [PASSWORD_DOTS] STAGING [PASSWORD_DOTS]
SELECT * FROM teams;
SELECT * FROM teams WHERE id = 88;
SELECT * FROM teams WHERE id = 89;
select * from team_settings where team_id = 89;
SELECT * FROM users WHERE team_id = 89;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 89;
select * from users;
SELECT * FROM social_accounts WHERE sociable_id = 1761;
SELECT * FROM crm_configurations WHERE id = 70;
select * from accounts where crm_configuration_id = 70 order by id desc;
select * from leads where crm_configuration_id = 70 order by id desc;
select * from contacts where crm_configuration_id = 70 order by id desc;
select * from opportunities where crm_configuration_id = 70 order by id desc;
select * from crm_profiles where crm_configuration_id = 70 order by id desc;
select * from crm_fields where crm_configuration_id = 70 order by id desc;
select * from crm_field_values where crm_field_id = 3536 order by id desc;
select * from crm_layouts where crm_configuration_id = 70 order by id desc;
select * from stages where crm_configuration_id = 70 order by id desc;
select * from business_processes where crm_configuration_id = 70 order by id desc;
select * from business_process_stages where business_process_id = 34;
select * from contacts where id = 10468;
select * from crm_layouts where crm_configuration_id = 70;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;
SELECT * FROM crm_fields WHERE id IN (3533,3534,3535);
select * from activities where crm_configuration_id = 70
and (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;
SELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;
SELECT * FROM activities where crm_configuration_id = 69 ;
SELECT * FROM users WHERE email LIKE '%[EMAIL]%';
SELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;
SELECT * FROM opportunities WHERE id = 385;
select * from participants p
join activities a on p.activity_id = a.id
where a.crm_configuration_id = 70
and (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);
SELECT * FROM participants WHERE id = 1013638;
select * from teams where id = 90;
select * from users where team_id = 90;
select * from social_accounts where social_accounts.sociable_id IN (1960,1760);
SELECT * FROM crm_profiles WHERE crm_configuration_id = 71;
select * from invitations where team_id = 90;
select * from crm_configurations where id = 71;
select * from accounts where crm_configuration_id = 71 order by id desc;
select * from leads where crm_configuration_id = 71 order by id desc;
select * from contacts where crm_configuration_id = 71 order by id desc;
select * from opportunities where crm_configuration_id = 71 order by id desc;
select * from crm_profiles where crm_configuration_id = 71 order by id desc;
select * from crm_fields where crm_configuration_id = 71 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 71 order by id desc;
select * from stages where crm_configuration_id = 71 order by id desc;
select * from users order by secondary_email desc;
select u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa
join users u on sa.sociable_id = u.id
where sa.provider = 'google' and u.email LIKE 'aneliya%';
select * from failed_jobs order by id desc;
select * from users where email = '[EMAIL]' or secondary_email = '[EMAIL]';
select * from teams;
SELECT * FROM crm_profiles WHERE crm_configuration_id = 39;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;
SELECT * FROM crm_configurations WHERE id = 70;
select * from teams where id = 1;
select * from groups where team_id = 1;
select * from users where team_id = 1;
select o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o
join users u on o.user_id = u.id
join groups g on u.group_id = g.id
join role_user ru on u.id = ru.user_id
join roles r on ru.role_id = r.id
where o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';
select * from role_user where user_id = 143;
select * from roles;
select * from role_user;
select * from groups where id = 9;
select * from scope_groups where group_id = 9;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations;
SELECT * FROM social_accounts WHERE sociable_id = 121;
https://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105
https://crmsandbox.zoho.com/crm/
https://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080
https://crm.zoho.com/crm/
org3469620
SELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;
select * from users where email LIKE "%mobile_automation_%";
select * from social_accounts where sociable_id IN (2228);
select * from crm_profiles where user_id IN (2222,2223,2226,2227);
select * from teams order by id desc;
SELECT * FROM users WHERE id = 2229;
SELECT * FROM crm_profiles WHERE user_id = 2229;
select * from opportunities where crm_configuration_id = 88;
select * from crm_fields where crm_configuration_id = 88;
select * from crm_profiles where crm_configuration_id = 88;
SELECT * FROM teams WHERE id = 1;
SELECT * FROM users WHERE id = 143;
SELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;
https://app.staging.jiminny.com/ondemand?
min_duration=1
&
only_recorded=1
&
user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e
&
sequence_number=2
select * from users where team_id = 1 and email like '%stoyan%'
select * from coaching_feedbacks;
select * from teams;
SELECT * FROM users WHERE team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from users where id = 143;
SELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
select * from users where team_id = 2;
select * from activities where crm_configuration_id = 39
and activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'
AND user_id = 143
order by id desc;
# [PASSWORD_DOTS]
select * from teams where id = 142; # 2312, 126
select * from team_settings;
select * from users where team_id = 142; # 21642
SELECT * FROM social_accounts WHERE sociable_id = 21642;
SELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;
select * from crm_profiles where id IN (93);
select * from invitations;
select * from team_features where team_id = 1;
SELECT * FROM crm_configurations WHERE id = 126;
select * from accounts where crm_configuration_id = 126 order by id desc;
select * from leads where crm_configuration_id = 126 order by id desc;
select * from contacts where crm_configuration_id = 126 order by id desc;
select * from opportunities where crm_configuration_id = 126 order by id desc;
select * from crm_profiles where crm_configuration_id = 126 order by id desc;
select * from crm_fields where crm_configuration_id = 126 # 11060
# and type IN ('picklist', 'status')
# and object_type = 'task'
order by id desc;
# 5731,5732,5733
select DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;
select * from crm_layouts where crm_configuration_id = 126 order by id desc;
SELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);
select * from stages where crm_configuration_id = 126 order by id desc;
select * from business_processes where crm_configuration_id = 126 order by id desc;
select * from business_process_stages where business_process_id IN (76,75,74,73);
select * from playbooks where team_id = 142;
select * from playbook_layouts where playbook_id IN (108);
SELECT * FROM playbook_categories WHERE playbook_id IN (108);
select * from teams where id = 130;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 2
and sa.provider = 'hubspot';
SELECT * FROM activities
WHERE crm_configuration_id = 110;
select * from teams;
select * from crm_configurations;
SELECT * FROM activities WHERE id = 628773;
SELECT * FROM crm_profiles WHERE user_id = 1460;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from teams;
select ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id
join permission_role pr on pr.role_id = ru.role_id
join permissions p on p.id = pr.permission_id
where team_id = 495 and p.name IN ('dial');
select * from teams where id = 145;
select * from crm_configurations where id = 129;
select * from social_accounts where sociable_id = 2317;
SELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;
select * from teams where id = 1;
SELECT * FROM crm_layouts WHERE crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;
SELECT * FROM crm_layout_entities WHERE id = 5507;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');
select * from teams;
select * from activities where crm_configuration_id = 14;
SELECT * FROM social_accounts where provider = 'copper';
select * from activities where id = 628467;
select * from participants where activity_id = 628467;
SELECT * FROM contacts WHERE id = 3969;
SELECT * FROM accounts WHERE id = 177;
SELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;
# [PASSWORD_DOTS] BH
select * from teams where id = 36;
SELECT * FROM crm_configurations WHERE id = 21;
select * from activities where crm_configuration_id = 21 and id = 607901;
select * from activities where crm_configuration_id = 21;
select * roles;
select * from permissions;
select * from permission_role where permission_id = 226;
select * from migrations order by id desc;
# mercury
# neptune
# earth
select * from teams;
select * from teams where id = 19;
select * from teams where id = 27;
select * from users where team_id = 27;
SELECT * FROM crm_configurations WHERE id = 42;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from activities where id = 631461;
SELECT * FROM crm_field_values WHERE crm_field_id = 180;
select * from teams where id = 2;
SELECT * FROM social_accounts WHERE sociable_id = 89;
SELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273
select * from activity_summary_logs where activity_id = 634273;
select * from sidekick_settings where team_id = 2;
select * from teams; # 2, 2
SELECT * FROM crm_configurations WHERE team_id = 2; # 2
select * from team_features where team_id = 2;
select * from features;
SELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';
SELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;
select * from automated_reports order by id desc;
select * from automated_report_results order by id desc;
select * from users where team_id = 1 and id IN (7160, 3248);
select * from migrations order by id desc;
SELECT
CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,
u.email,
sa.*,
t.owner_id FROM social_accounts sa
JOIN users u on u.id = sa.sociable_id
JOIN teams t on t.id = u.team_id
WHERE u.team_id = 1 and sa.provider = 'salesforce';
select * from teams where id = 1;
select * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;
select * from groups where id = 565;
select * from playbooks where team_id = 1;
select * from playbooks where id = 175;
select * from playbook_categories where playbook_id = 175;
select * from users where team_id = 1;
select * from users where id = 7160;
select * from crm_profiles where user_id = 7160;
select * from features;
select
*
# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,
# crm_configuration_id, crm_provider_id, transcription_id, status
from activities where crm_configuration_id = 1 and type = 'conference'
# and crm_provider_id IS NOT NULL
and provider != 'uploader' and actual_start_time IS NOT NULL
ORDER by id desc;
select * from activities where id = 54747783; # 00UO400000pCzojMAC
select p.id, p.activity_type, pc.id, pc.name
FROM playbooks p
join playbook_categories pc on p.id = pc.playbook_id
where p.team_id = 1 and p.activity_type = 'event';
SELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';
SELECT * FROM crm_field_values WHERE crm_field_id = 4;
select * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id
where crm_configuration_id = 1 and pl.playbook_id = 175;
select * from teams;
SELECT r.* FROM automated_reports r
join teams t on r.team_id = t.id
WHERE r.frequency = 'daily'
and r.status = 1
AND t.status = 'active'
AND (r.expires_at >= now() OR r.expires_at IS NULL);
select * from automated_report_results where report_id IN (18, 33);
select * from automated_reports;
select * from automated_report_results where report_id IN (34);
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
NULL
|
|
10276
|
203
|
0
|
2026-04-14T08:27:31.101853+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776155251101_m2.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
PhpStormFileEditFV faVsco.js vViewNavigateCodeLara PhpStormFileEditFV faVsco.js vViewNavigateCodeLaravelRefactor#11894 on JY-18909-automated-reports-ask-iminny K vToolsWindowHelpProject vProphetAiv D Reports© AutomatedReportsCl© AutomatedReportsRe© AutomatedReportsSt© CreateMockAskJimir© DeleteReportComma© GenerateMarketingR© Team.php© Usage.phpD Slack• TeamsD TracksO TranscriptionO TwilioD UsersVocabularyDZoom© CoachingFeedbacksUpr© Command.phpo Cearevaroaseusers.oc Daraoase oecountoi© DeleteOldAiCrmNotesC:© DeleteS3LeftoversComiDevPostmanCommand./© DiarizeViaAiParticipantk© EncryptTokensComman© EngagementStatsRegen© FeatureFlagsHelper.php© FixCrossTenantlssues.p(c) -ushro espermissionsa(e) Generatelnterna wepho• GroupSetDefaultLangua© HelperTruncateCoachin© HubspotJournalPollingC© HubspotWebhookServic©ImportRecording.php© ImportUsersFromCsvFil© IterateUsersCommand.p© JiminnyCacheClearCom© JiminnyDebugCommanc© JiminnySetEncryptedTo© JiminnyTokenInfoCommMakeslackLvecoaching(c Manacescimror eam.oc мarkbranchrorenvironh© MuteOrganizerChannel.© PhpApm.php© PropagateCoachingFeer© PurgeConferences.php© PurgeSoftDeletedOppor© PurgeSyncBatchesCom(e Recalculatebealkisksco(c) Removede eremarkersc(e) Remove-xoiredNudoesc removeunusecrarcloC ResetElasticSearch.php© RestoreActivityCrmProv© RestoreActivityTypeCor© ReportController.phpJiminnyDeouecommana.ongAutomaleakeporssenacommana.ongC AutomatedReportsCommand.php xAulomaleakeporskeposilory.onoAulomaleakeporisservice.onpTrackProviderInstalledEvent.phpActivilyLoggeo.ongCreateActivityLoggedEvent.php© RequestGenerateAskJiminnyReportJob.phpC AutomatedReport.php© UserPilotActivityListener.php© RequestGenerateReportJob.phpC AutomatedReportResult.phpclass AutomatedReportsCommand extends Commandououc runccion nanolelur aint$isMonday = $now->isMonday():$isFirstDay0fMonth = $now->day === 1;$currentMonth = $now->month;909192100101102103104105106107108109110111112113// Check if the current month is a quarterly month (January, April, July, October)SisOuarterlvMonth = in array(ScurrentMonth.[1, 4, 7, 10],suiel aruen$this->Logger->info(self::LOG_PREFIX•Checking conditions','isMonday' => $isMonday,'isFirstDay0fMonth' => $isFirstDay0fMonth,'currentMonth' => $currentMonth,'isQuarterLyMonth' => $isQuarterlyMonth,521522523524525526527528529550ID:// Process daily reportsSthis->processReports( frequency: AutomatedReportsService::FREQUENCY_DAILY);// Process weekly reports on Mondaysif ($isMonday) €$this->processReports( frequency: AutomatedReportsService: :FREQUENCY_WEEKLY);// Process monthly reports on the first day of the monthif ($isFirstDay0fMonth) €$this->processReports( frequency: AutomatedReportsService::FREQUENCY_MONTHLY):// Process quarterly reports on the first day of January, April, July, and Octoberif ($isFirstDay0fMonth && $isQuarterlyMonth) €$this->processReports( frequency: AutomatedReportsService::FREQUENCY_QUARTERLY);$this->logger->info(self::LOG_PREFIX' Completed');return 0;532533534535536537538539540541542543544545546E5475485495505515521 usageprivate function processSingleReport(string $reportId): intpchus->logger->uhrolselt..Loo_PKErIX' Manual single-report mode'. ['reportId' => $reportId]);594555556557558559560$report = is_numeric($reportId)? AutomatedReport: :withTrashed()->find((int) $reportId): AutomatedReport::withTrashed()->where( column: 'uvid'.AutomatedReport::toOptimized($reportId)).562563if ($report === null) ($this->Logger->error(self::LOG_PREFIX.' Report not found". ['reportId' => $reportId]);$this->error( string: "Report not found: [SreportId}"):564565566 v567return 1;T 1 of 5 edits JX Reject File t*@Windsurf changelog 2.12.21: A new version is available. // View Changelog (54 minutes ago)= custom.log= laravel.logA SF [jiminny@localhost]Hs local liminnyalocalnostconsole PRODA console [EU]A console [STAGING]© AskJiminnyReportActivityService.phpC) RequestGenerateAskJiminnyReportJobTest.phpTx: AutoyE WHEN U.1d = T.OWNEr_1d THENrlayground(owner) ' El tiGajiminny v016 A 13 X13 A Vsocal accounts= sa.sociable idon t.id = u.team_idand sa.provider = 'salesforce';where id = 1;g JOIN playbooks p 1..n<->1: on g.playbook_id = p.id where g.team_iwhere id = 565;oks where team_id = 1;oks where id = 175;ok_categories where playbook_id = 175;Wnere teal_1d = 1,where id = 7160;oTiles where User 10 = 1100.es;ovider, playbook_category_id, user_id, lead_id, contact_id, accountid, crm_provider_id, transcription_id, statuse crm_configuration_id = 1 and type = 'conference'a IS NUI NULLoader' and actual_start_time IS NOT NULLties where id = 54747783; # 00U0400000pCZojMACity_type, pc.id, pc.nameries pc1<->1..n: on p.id = pc.playbook_idand p.activity_type = 'event';elds WHERE crm_configuration_id = 1 and object_type = 'event';eld_values WHERE crm_field_id = 4;youts cl Join playbook_layouts puion id = 1 and pl.plavbook id = 1751->Ian: on cl.1d = pL. Layout_10mated_reports rauid = t.id'daily've'now() OR r.expires.at IS NULL);ted_report_results where repont.id IN (18, 33);ted_report_results where ceRontaid IN (34);, 0lablSupport Daily • in 3h 33mARequestGenerateAskJiminnyReportJobTestv100% [2Tue 14 Apr 11:27:31CascadeFixing ReportControlleAutomated Report Fai+D ...in onucolld Leuneyot tscomlanlus oheadd additional parameter report id and if provider then instead ofexoris by wrecuenell lakes wle levort vy le or uule.Add checks for status, team activity andoiel stull useu lor curymg. uns Iwi ve usee only mllanudlly sou mele shote ve mio l not duptlcadle baseu onlstandara searenLet me read the command and related files first.reao Auloma lecreoorscommanc,ono anopAuloalecreoorsredosilorv.ono ›Now let me check the AutonatedReoort model tor relevanttielas:сxоютeй nuLоїus|getTeam|expires_at|getFrequency|getType|STATUS_lis..>Now.nave everytnine.neeo. Lerme imolement tne changes.• AutomatedReportsCommand.php+78 -2Also need to check if findByUuid handles soft-deleted — it doesn't, so for UUID lookup we need withTrashed too.Let me tix thatAutomatedReportsCommand.phpDone. Here's what was added:+1 -1Changes SummaryNew option: —report-id= — accepts either a numeric ID or a UUID.processsing lekeportl, — oypasses treouency logie entirely.• Looks up by ID (AutomatedReport: :withTrashed()->find() ) or UUID (also withTrashed so even deletedreports can be triggered manually)• Calls warnIfNotApplicableForSchedule() for informational outputDispatches the job the same way as the scheduled pathwarnIfNotApplicableForSchedule() - mirrors every condition from getActiveReportsByFrequency() and thejob's validateReport(), printing a warn() (vellow terminal output) for each condition that would cause the reportto oe skiooed in a normal scheculed run:CheckReport is soft-deletedstatus s inactiveTeam not STATUS_ACTIVEexpires_at is pastFrequency wouldn't run todayUsage:bash# By IDSourcewathi rashed - nouln normal scopegetActiveReportsByFrequencygetActivereportsbyFrequencygetActiveReportsByFrequencyscheduling logic in handle()php artisan automated-reports —report-id=68#BY UULDphp artisan automated-reports --report-1d=some-uuid-hereC1l -1 file +78 -2 >Reject allAccept allit seems to be a log of duplication. Lets jusst use the same method we havel+ <> CodeClaude Sonnet 4.6winasun leams203:6 1229 chars, 26 line breaksuir-o( 4 spaces...
|
NULL
|
2984712721042032268
|
NULL
|
click
|
ocr
|
NULL
|
PhpStormFileEditFV faVsco.js vViewNavigateCodeLara PhpStormFileEditFV faVsco.js vViewNavigateCodeLaravelRefactor#11894 on JY-18909-automated-reports-ask-iminny K vToolsWindowHelpProject vProphetAiv D Reports© AutomatedReportsCl© AutomatedReportsRe© AutomatedReportsSt© CreateMockAskJimir© DeleteReportComma© GenerateMarketingR© Team.php© Usage.phpD Slack• TeamsD TracksO TranscriptionO TwilioD UsersVocabularyDZoom© CoachingFeedbacksUpr© Command.phpo Cearevaroaseusers.oc Daraoase oecountoi© DeleteOldAiCrmNotesC:© DeleteS3LeftoversComiDevPostmanCommand./© DiarizeViaAiParticipantk© EncryptTokensComman© EngagementStatsRegen© FeatureFlagsHelper.php© FixCrossTenantlssues.p(c) -ushro espermissionsa(e) Generatelnterna wepho• GroupSetDefaultLangua© HelperTruncateCoachin© HubspotJournalPollingC© HubspotWebhookServic©ImportRecording.php© ImportUsersFromCsvFil© IterateUsersCommand.p© JiminnyCacheClearCom© JiminnyDebugCommanc© JiminnySetEncryptedTo© JiminnyTokenInfoCommMakeslackLvecoaching(c Manacescimror eam.oc мarkbranchrorenvironh© MuteOrganizerChannel.© PhpApm.php© PropagateCoachingFeer© PurgeConferences.php© PurgeSoftDeletedOppor© PurgeSyncBatchesCom(e Recalculatebealkisksco(c) Removede eremarkersc(e) Remove-xoiredNudoesc removeunusecrarcloC ResetElasticSearch.php© RestoreActivityCrmProv© RestoreActivityTypeCor© ReportController.phpJiminnyDeouecommana.ongAutomaleakeporssenacommana.ongC AutomatedReportsCommand.php xAulomaleakeporskeposilory.onoAulomaleakeporisservice.onpTrackProviderInstalledEvent.phpActivilyLoggeo.ongCreateActivityLoggedEvent.php© RequestGenerateAskJiminnyReportJob.phpC AutomatedReport.php© UserPilotActivityListener.php© RequestGenerateReportJob.phpC AutomatedReportResult.phpclass AutomatedReportsCommand extends Commandououc runccion nanolelur aint$isMonday = $now->isMonday():$isFirstDay0fMonth = $now->day === 1;$currentMonth = $now->month;909192100101102103104105106107108109110111112113// Check if the current month is a quarterly month (January, April, July, October)SisOuarterlvMonth = in array(ScurrentMonth.[1, 4, 7, 10],suiel aruen$this->Logger->info(self::LOG_PREFIX•Checking conditions','isMonday' => $isMonday,'isFirstDay0fMonth' => $isFirstDay0fMonth,'currentMonth' => $currentMonth,'isQuarterLyMonth' => $isQuarterlyMonth,521522523524525526527528529550ID:// Process daily reportsSthis->processReports( frequency: AutomatedReportsService::FREQUENCY_DAILY);// Process weekly reports on Mondaysif ($isMonday) €$this->processReports( frequency: AutomatedReportsService: :FREQUENCY_WEEKLY);// Process monthly reports on the first day of the monthif ($isFirstDay0fMonth) €$this->processReports( frequency: AutomatedReportsService::FREQUENCY_MONTHLY):// Process quarterly reports on the first day of January, April, July, and Octoberif ($isFirstDay0fMonth && $isQuarterlyMonth) €$this->processReports( frequency: AutomatedReportsService::FREQUENCY_QUARTERLY);$this->logger->info(self::LOG_PREFIX' Completed');return 0;532533534535536537538539540541542543544545546E5475485495505515521 usageprivate function processSingleReport(string $reportId): intpchus->logger->uhrolselt..Loo_PKErIX' Manual single-report mode'. ['reportId' => $reportId]);594555556557558559560$report = is_numeric($reportId)? AutomatedReport: :withTrashed()->find((int) $reportId): AutomatedReport::withTrashed()->where( column: 'uvid'.AutomatedReport::toOptimized($reportId)).562563if ($report === null) ($this->Logger->error(self::LOG_PREFIX.' Report not found". ['reportId' => $reportId]);$this->error( string: "Report not found: [SreportId}"):564565566 v567return 1;T 1 of 5 edits JX Reject File t*@Windsurf changelog 2.12.21: A new version is available. // View Changelog (54 minutes ago)= custom.log= laravel.logA SF [jiminny@localhost]Hs local liminnyalocalnostconsole PRODA console [EU]A console [STAGING]© AskJiminnyReportActivityService.phpC) RequestGenerateAskJiminnyReportJobTest.phpTx: AutoyE WHEN U.1d = T.OWNEr_1d THENrlayground(owner) ' El tiGajiminny v016 A 13 X13 A Vsocal accounts= sa.sociable idon t.id = u.team_idand sa.provider = 'salesforce';where id = 1;g JOIN playbooks p 1..n<->1: on g.playbook_id = p.id where g.team_iwhere id = 565;oks where team_id = 1;oks where id = 175;ok_categories where playbook_id = 175;Wnere teal_1d = 1,where id = 7160;oTiles where User 10 = 1100.es;ovider, playbook_category_id, user_id, lead_id, contact_id, accountid, crm_provider_id, transcription_id, statuse crm_configuration_id = 1 and type = 'conference'a IS NUI NULLoader' and actual_start_time IS NOT NULLties where id = 54747783; # 00U0400000pCZojMACity_type, pc.id, pc.nameries pc1<->1..n: on p.id = pc.playbook_idand p.activity_type = 'event';elds WHERE crm_configuration_id = 1 and object_type = 'event';eld_values WHERE crm_field_id = 4;youts cl Join playbook_layouts puion id = 1 and pl.plavbook id = 1751->Ian: on cl.1d = pL. Layout_10mated_reports rauid = t.id'daily've'now() OR r.expires.at IS NULL);ted_report_results where repont.id IN (18, 33);ted_report_results where ceRontaid IN (34);, 0lablSupport Daily • in 3h 33mARequestGenerateAskJiminnyReportJobTestv100% [2Tue 14 Apr 11:27:31CascadeFixing ReportControlleAutomated Report Fai+D ...in onucolld Leuneyot tscomlanlus oheadd additional parameter report id and if provider then instead ofexoris by wrecuenell lakes wle levort vy le or uule.Add checks for status, team activity andoiel stull useu lor curymg. uns Iwi ve usee only mllanudlly sou mele shote ve mio l not duptlcadle baseu onlstandara searenLet me read the command and related files first.reao Auloma lecreoorscommanc,ono anopAuloalecreoorsredosilorv.ono ›Now let me check the AutonatedReoort model tor relevanttielas:сxоютeй nuLоїus|getTeam|expires_at|getFrequency|getType|STATUS_lis..>Now.nave everytnine.neeo. Lerme imolement tne changes.• AutomatedReportsCommand.php+78 -2Also need to check if findByUuid handles soft-deleted — it doesn't, so for UUID lookup we need withTrashed too.Let me tix thatAutomatedReportsCommand.phpDone. Here's what was added:+1 -1Changes SummaryNew option: —report-id= — accepts either a numeric ID or a UUID.processsing lekeportl, — oypasses treouency logie entirely.• Looks up by ID (AutomatedReport: :withTrashed()->find() ) or UUID (also withTrashed so even deletedreports can be triggered manually)• Calls warnIfNotApplicableForSchedule() for informational outputDispatches the job the same way as the scheduled pathwarnIfNotApplicableForSchedule() - mirrors every condition from getActiveReportsByFrequency() and thejob's validateReport(), printing a warn() (vellow terminal output) for each condition that would cause the reportto oe skiooed in a normal scheculed run:CheckReport is soft-deletedstatus s inactiveTeam not STATUS_ACTIVEexpires_at is pastFrequency wouldn't run todayUsage:bash# By IDSourcewathi rashed - nouln normal scopegetActiveReportsByFrequencygetActivereportsbyFrequencygetActiveReportsByFrequencyscheduling logic in handle()php artisan automated-reports —report-id=68#BY UULDphp artisan automated-reports --report-1d=some-uuid-hereC1l -1 file +78 -2 >Reject allAccept allit seems to be a log of duplication. Lets jusst use the same method we havel+ <> CodeClaude Sonnet 4.6winasun leams203:6 1229 chars, 26 line breaksuir-o( 4 spaces...
|
10274
|
|
10329
|
NULL
|
0
|
2026-04-14T08:32:06.247968+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776155526247_m1.jpg...
|
PhpStorm
|
faVsco.js – AutomatedReportsCommand.php
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
<?php
declare(strict_types=1);
namespace Jiminny\Console\Commands\Reports;
use Carbon\Carbon;
use Illuminate\Console\Command;
use Illuminate\Contracts\Bus\Dispatcher as BusDispatcher;
use Jiminny\Jobs\AutomatedReports\RequestGenerateAskJiminnyReportJob;
use Jiminny\Jobs\AutomatedReports\RequestGenerateReportJob;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\Team;
use Jiminny\Repositories\AutomatedReportsRepository;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Psr\Log\LoggerInterface;
class AutomatedReportsCommand extends Command
{
/**
* Log prefix for all log messages
*/
private const string LOG_PREFIX = '[automated-reports]';
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'automated-reports {--report-id= : Process a specific report by ID or UUID (bypasses frequency scheduling)}';
/**
* The console command description.
*
* @var string
*/
protected $description = 'Process automated reports based on their frequency (weekly, monthly, quarterly). Use --report-id to manually trigger a specific report by ID or UUID.';
public function __construct(
private readonly LoggerInterface $logger,
private readonly BusDispatcher $dispatcher,
private readonly AutomatedReportsRepository $reportRepository
) {
parent::__construct();
}
/**
* Execute the console command.
*
* @return int
*/
public function handle(): int
{
$this->logger->info(self::LOG_PREFIX . ' Started');
$reportId = $this->option('report-id');
if ($reportId !== null) {
return $this->processSingleReport((string) $reportId);
}
$now = Carbon::now();
$isMonday = $now->isMonday();
$isFirstDayOfMonth = $now->day === 1;
$currentMonth = $now->month;
// Check if the current month is a quarterly month (January, April, July, October)
$isQuarterlyMonth = in_array($currentMonth, [1, 4, 7, 10], true);
$this->logger->info(self::LOG_PREFIX . ' Checking conditions', [
'isMonday' => $isMonday,
'isFirstDayOfMonth' => $isFirstDayOfMonth,
'currentMonth' => $currentMonth,
'isQuarterlyMonth' => $isQuarterlyMonth,
]);
// Process daily reports
$this->processReports(AutomatedReportsService::FREQUENCY_DAILY);
// Process weekly reports on Mondays
if ($isMonday) {
$this->processReports(AutomatedReportsService::FREQUENCY_WEEKLY);
}
// Process monthly reports on the first day of the month
if ($isFirstDayOfMonth) {
$this->processReports(AutomatedReportsService::FREQUENCY_MONTHLY);
}
// Process quarterly reports on the first day of January, April, July, and October
if ($isFirstDayOfMonth && $isQuarterlyMonth) {
$this->processReports(AutomatedReportsService::FREQUENCY_QUARTERLY);
}
$this->logger->info(self::LOG_PREFIX . ' Completed');
return 0;
}
private function processSingleReport(string $reportId): int
{
$this->logger->info(self::LOG_PREFIX . ' Manual single-report mode', ['reportId' => $reportId]);
$report = is_numeric($reportId)
? AutomatedReport::withTrashed()->find((int) $reportId)
: AutomatedReport::withTrashed()->where('uuid', AutomatedReport::toOptimized($reportId))->first();
if ($report === null) {
$this->logger->error(self::LOG_PREFIX . ' Report not found', ['reportId' => $reportId]);
$this->error("Report not found: {$reportId}");
return 1;
}
$this->warnIfNotApplicableForSchedule($report);
$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [
'reportUuid' => $report->getUuid(),
'teamId' => $report->getTeamId(),
'frequency' => $report->getFrequency(),
'type' => $report->getType(),
]);
$job = $report->isAskJiminnyReport()
? new RequestGenerateAskJiminnyReportJob($report->getUuid())
: new RequestGenerateReportJob($report->getUuid());
$this->dispatcher->dispatchSync($job);
$this->logger->info(self::LOG_PREFIX . ' Completed');
return 0;
}
private function warnIfNotApplicableForSchedule(AutomatedReport $report): void
{
if ($report->trashed()) {
$this->warn('Report is soft-deleted (deleted_at: ' . $report->getDeletedAt()?->toDateTimeString() . ').');
}
if (! $report->getStatus()) {
$this->warn('Report status is inactive — would be skipped in scheduled run.');
}
$team = $report->getTeam();
if ($team->getStatus() !== Team::STATUS_ACTIVE) {
$this->warn("Team #{$report->getTeamId()} is not active (status: {$team->getStatus()}) — would be skipped in scheduled run.");
}
if ($report->isExpired()) {
$this->warn('Report is expired (expires_at: ' . $report->getExpiresAt()?->toDateString() . ') — would be skipped in scheduled run.');
}
$now = Carbon::now();
$frequency = $report->getFrequency();
$wouldRunToday = match ($frequency) {
AutomatedReportsService::FREQUENCY_DAILY => true,
AutomatedReportsService::FREQUENCY_WEEKLY => $now->isMonday(),
AutomatedReportsService::FREQUENCY_MONTHLY => $now->day === 1,
AutomatedReportsService::FREQUENCY_QUARTERLY => $now->day === 1 && in_array($now->month, [1, 4, 7, 10], true),
default => false,
};
if (! $wouldRunToday) {
$this->warn("Report frequency is '{$frequency}' — would NOT be scheduled to run today.");
}
}
/**
* Process reports for a specific frequency.
*
* @param string $frequency
*
* @return void
*/
private function processReports(string $frequency): void
{
$this->logger->info(self::LOG_PREFIX . " Processing $frequency reports");
$reportId = $this->option('report-id');
if ($reportId !== null) {
$reports = $this->getReportById($reportId);
} else {
// Get all enabled, not deleted reports with active teams for the specified frequency
$reports = $this->reportRepository->getActiveReportsByFrequency($frequency);
}
$this->logger->info(self::LOG_PREFIX . " Found {$reports->count()} $frequency reports to process");
/** @var AutomatedReport $report */
foreach ($reports as $report) {
$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [
'reportUuid' => $report->getUuid(),
'teamId' => $report->getTeamId(),
'frequency' => $report->getFrequency(),
'type' => $report->getType(),
]);
$job = $report->isAskJiminnyReport()
? new RequestGenerateAskJiminnyReportJob($report->getUuid())
: new RequestGenerateReportJob($report->getUuid());
// $this->dispatcher->dispatch($job);
$this->dispatcher->dispatchSync($job);
}
}
}
Execute
Explain Plan
Browse Query History
View Parameters
Open Query Execution Settings…
In-Editor Results
Tx: Auto
Cancel Running Statements
Playground
jiminny
Sync Changes
Hide This Notification
Code changed:
Hide
16
13
13
Previous Highlighted Error
Next Highlighted Error
SELECT * FROM teams WHERE id = 1;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;
SELECT * FROM crm_fields WHERE id = 2234;
SELECT * FROM crm_field_values WHERE crm_field_id = 2234;
select * from crm_profiles where user_id = 143;
select * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO
select * from business_processes where crm_configuration_id = 39;
# 01941000000H669AAC, 01941000000H66JAAS
select * from record_type_field_values
where record_type_id IN (24);
select * from crm_field_values where id IN (2730);
select * from crm_configurations where id = 39;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce'; #1035
select * from users where team_id = 1; # 222 group 3
SELECT * FROM activities WHERE user_id = 222 order by id desc;
select * from sidekick_settings where team_id = 1;
select * from teams where id = 1;
select * from team_features where team_id = 1;
select * from activities where crm_configuration_id = 2
and provider = 'ms-teams' and id = 608765;
SELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';
select * from sidekick_settings where team_id = 2;
SELECT * FROM activities WHERE id = 608660;
select * from activity_summary_logs where activity_id = 608660;
select * from ai_prompts where transcription_id = 11214;
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;
# id: 608818, crm: 59628809737
SELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;
# id: 608821, crm: 59632069252
SELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,
playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,
scheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at
FROM activities a
join calendar_events ce on a.calendar_event_id = ce.id
WHERE a.id IN (608818, 608821);
select * from users where team_id = 1;
select * from team_settings where team_id = 1;
select * from crm_profiles where crm_configuration_id = 39 order by user_id;
select * from team_features where team_id = 1;
select * from users where team_id = 2;
SELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639
# Preslava N. Ivanova, grou id 3
SELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;
select * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';
select
a.id,
a.type,
a.scheduled_start_time,
a.actual_start_time,
a.created_at,
a.opportunity_id,
a.status
FROM activities a
WHERE opportunity_id = 344
and status IN ('completed', 'received', 'delivered')
and (
(a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))
;
SELECT * FROM users WHERE id = 222;
SELECT * FROM crm_profiles WHERE user_id = 222;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;
select * from group_deal_risk_types;
select * from opportunities where team_id = 1;
SELECT * FROM opportunities WHERE id = 315;
SELECT * FROM crm_field_data WHERE object_id = 315;
select * from crm_field_data where object_id = 260;
select * from generic_ai_prompts where subject_id = 315;
select * from teams; # 36, 21, 121, [EMAIL]
SELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';
# [PASSWORD_DOTS]
select * from teams where id = 1;
select * from crm_configurations where id = 39;
select * from users where team_id = 1;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 1;
# 1 - 00541000004281rAAA
# 204 - 0052g000003freeAAA
# 429 - 0052g000003qGOiAAM
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
select * from activities where type = 'softphone'
and created_at > '2024-12-11 15:24:36' order by id desc;
select * from activity_providers where team_id = 1;
select * from activity_provider_users where activity_provider_id = 328;
select * from opportunities where crm_configuration_id = 39
AND account_id = 178 AND is_closed = false
order by created_at DESC;
select * from contacts where id = 3952;
select * from accounts where id = 178;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations where id = 21;
select * from users where team_id = 36;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 36
and sa.provider = 'bullhorn';
select * from social_accounts where id = 348;
UPDATE social_accounts SET
provider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',
provider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',
expires = 1733998131,
state = 'connected'
WHERE id = 348;
# [PASSWORD_DOTS]
select * from teams where id = 31;
select * from crm_configurations where id = 18;
select * from users where team_id = 31; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 31;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 31
and sa.provider = 'close';
select * from contacts where crm_configuration_id = 18;
# [PASSWORD_DOTS] NEPTUNE [PASSWORD_DOTS]
select * from teams;
select * from users where id IN (1030, 1035, 1052);
select * from crm_configurations;
select * from users where team_id = 65; # 257
select * from team_settings where team_id = 65; # 257
select * from invitations where team_id = 65; # 257
select * from users where email = '[EMAIL]'; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 65;
select * from crm_configurations where id = 53;
select * from accounts where crm_configuration_id = 53 order by id desc;
select * from leads where crm_configuration_id = 53 order by id desc;
select * from contacts where crm_configuration_id = 53 order by id desc;
select * from opportunities where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 53 order by id desc;
select * from crm_fields where crm_configuration_id = 53 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 53 order by id desc;
select * from stages where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 13;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
and sa.provider = 'integration-app';
select * from contacts where crm_configuration_id = 13;
select * from social_accounts where sociable_id = 283;
SELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';
select * from activity_providers where team_id = 65;
SELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
;
# [PASSWORD_DOTS] STAGING [PASSWORD_DOTS]
SELECT * FROM teams;
SELECT * FROM teams WHERE id = 88;
SELECT * FROM teams WHERE id = 89;
select * from team_settings where team_id = 89;
SELECT * FROM users WHERE team_id = 89;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 89;
select * from users;
SELECT * FROM social_accounts WHERE sociable_id = 1761;
SELECT * FROM crm_configurations WHERE id = 70;
select * from accounts where crm_configuration_id = 70 order by id desc;
select * from leads where crm_configuration_id = 70 order by id desc;
select * from contacts where crm_configuration_id = 70 order by id desc;
select * from opportunities where crm_configuration_id = 70 order by id desc;
select * from crm_profiles where crm_configuration_id = 70 order by id desc;
select * from crm_fields where crm_configuration_id = 70 order by id desc;
select * from crm_field_values where crm_field_id = 3536 order by id desc;
select * from crm_layouts where crm_configuration_id = 70 order by id desc;
select * from stages where crm_configuration_id = 70 order by id desc;
select * from business_processes where crm_configuration_id = 70 order by id desc;
select * from business_process_stages where business_process_id = 34;
select * from contacts where id = 10468;
select * from crm_layouts where crm_configuration_id = 70;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;
SELECT * FROM crm_fields WHERE id IN (3533,3534,3535);
select * from activities where crm_configuration_id = 70
and (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;
SELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;
SELECT * FROM activities where crm_configuration_id = 69 ;
SELECT * FROM users WHERE email LIKE '%[EMAIL]%';
SELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;
SELECT * FROM opportunities WHERE id = 385;
select * from participants p
join activities a on p.activity_id = a.id
where a.crm_configuration_id = 70
and (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);
SELECT * FROM participants WHERE id = 1013638;
select * from teams where id = 90;
select * from users where team_id = 90;
select * from social_accounts where social_accounts.sociable_id IN (1960,1760);
SELECT * FROM crm_profiles WHERE crm_configuration_id = 71;
select * from invitations where team_id = 90;
select * from crm_configurations where id = 71;
select * from accounts where crm_configuration_id = 71 order by id desc;
select * from leads where crm_configuration_id = 71 order by id desc;
select * from contacts where crm_configuration_id = 71 order by id desc;
select * from opportunities where crm_configuration_id = 71 order by id desc;
select * from crm_profiles where crm_configuration_id = 71 order by id desc;
select * from crm_fields where crm_configuration_id = 71 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 71 order by id desc;
select * from stages where crm_configuration_id = 71 order by id desc;
select * from users order by secondary_email desc;
select u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa
join users u on sa.sociable_id = u.id
where sa.provider = 'google' and u.email LIKE 'aneliya%';
select * from failed_jobs order by id desc;
select * from users where email = '[EMAIL]' or secondary_email = '[EMAIL]';
select * from teams;
SELECT * FROM crm_profiles WHERE crm_configuration_id = 39;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;
SELECT * FROM crm_configurations WHERE id = 70;
select * from teams where id = 1;
select * from groups where team_id = 1;
select * from users where team_id = 1;
select o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o
join users u on o.user_id = u.id
join groups g on u.group_id = g.id
join role_user ru on u.id = ru.user_id
join roles r on ru.role_id = r.id
where o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';
select * from role_user where user_id = 143;
select * from roles;
select * from role_user;
select * from groups where id = 9;
select * from scope_groups where group_id = 9;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations;
SELECT * FROM social_accounts WHERE sociable_id = 121;
https://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105
https://crmsandbox.zoho.com/crm/
https://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080
https://crm.zoho.com/crm/
org3469620
SELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;
select * from users where email LIKE "%mobile_automation_%";
select * from social_accounts where sociable_id IN (2228);
select * from crm_profiles where user_id IN (2222,2223,2226,2227);
select * from teams order by id desc;
SELECT * FROM users WHERE id = 2229;
SELECT * FROM crm_profiles WHERE user_id = 2229;
select * from opportunities where crm_configuration_id = 88;
select * from crm_fields where crm_configuration_id = 88;
select * from crm_profiles where crm_configuration_id = 88;
SELECT * FROM teams WHERE id = 1;
SELECT * FROM users WHERE id = 143;
SELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;
https://app.staging.jiminny.com/ondemand?
min_duration=1
&
only_recorded=1
&
user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e
&
sequence_number=2
select * from users where team_id = 1 and email like '%stoyan%'
select * from coaching_feedbacks;
select * from teams;
SELECT * FROM users WHERE team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from users where id = 143;
SELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
select * from users where team_id = 2;
select * from activities where crm_configuration_id = 39
and activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'
AND user_id = 143
order by id desc;
# [PASSWORD_DOTS]
select * from teams where id = 142; # 2312, 126
select * from team_settings;
select * from users where team_id = 142; # 21642
SELECT * FROM social_accounts WHERE sociable_id = 21642;
SELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;
select * from crm_profiles where id IN (93);
select * from invitations;
select * from team_features where team_id = 1;
SELECT * FROM crm_configurations WHERE id = 126;
select * from accounts where crm_configuration_id = 126 order by id desc;
select * from leads where crm_configuration_id = 126 order by id desc;
select * from contacts where crm_configuration_id = 126 order by id desc;
select * from opportunities where crm_configuration_id = 126 order by id desc;
select * from crm_profiles where crm_configuration_id = 126 order by id desc;
select * from crm_fields where crm_configuration_id = 126 # 11060
# and type IN ('picklist', 'status')
# and object_type = 'task'
order by id desc;
# 5731,5732,5733
select DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;
select * from crm_layouts where crm_configuration_id = 126 order by id desc;
SELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);
select * from stages where crm_configuration_id = 126 order by id desc;
select * from business_processes where crm_configuration_id = 126 order by id desc;
select * from business_process_stages where business_process_id IN (76,75,74,73);
select * from playbooks where team_id = 142;
select * from playbook_layouts where playbook_id IN (108);
SELECT * FROM playbook_categories WHERE playbook_id IN (108);
select * from teams where id = 130;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 2
and sa.provider = 'hubspot';
SELECT * FROM activities
WHERE crm_configuration_id = 110;
select * from teams;
select * from crm_configurations;
SELECT * FROM activities WHERE id = 628773;
SELECT * FROM crm_profiles WHERE user_id = 1460;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from teams;
select ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id
join permission_role pr on pr.role_id = ru.role_id
join permissions p on p.id = pr.permission_id
where team_id = 495 and p.name IN ('dial');
select * from teams where id = 145;
select * from crm_configurations where id = 129;
select * from social_accounts where sociable_id = 2317;
SELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;
select * from teams where id = 1;
SELECT * FROM crm_layouts WHERE crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;
SELECT * FROM crm_layout_entities WHERE id = 5507;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');
select * from teams;
select * from activities where crm_configuration_id = 14;
SELECT * FROM social_accounts where provider = 'copper';
select * from activities where id = 628467;
select * from participants where activity_id = 628467;
SELECT * FROM contacts WHERE id = 3969;
SELECT * FROM accounts WHERE id = 177;
SELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;
# [PASSWORD_DOTS] BH
select * from teams where id = 36;
SELECT * FROM crm_configurations WHERE id = 21;
select * from activities where crm_configuration_id = 21 and id = 607901;
select * from activities where crm_configuration_id = 21;
select * roles;
select * from permissions;
select * from permission_role where permission_id = 226;
select * from migrations order by id desc;
# mercury
# neptune
# earth
select * from teams;
select * from teams where id = 19;
select * from teams where id = 27;
select * from users where team_id = 27;
SELECT * FROM crm_configurations WHERE id = 42;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from activities where id = 631461;
SELECT * FROM crm_field_values WHERE crm_field_id = 180;
select * from teams where id = 2;
SELECT * FROM social_accounts WHERE sociable_id = 89;
SELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273
select * from activity_summary_logs where activity_id = 634273;
select * from sidekick_settings where team_id = 2;
select * from teams; # 2, 2
SELECT * FROM crm_configurations WHERE team_id = 2; # 2
select * from team_features where team_id = 2;
select * from features;
SELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';
SELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;
select * from automated_reports order by id desc;
select * from automated_report_results order by id desc;
select * from users where team_id = 1 and id IN (7160, 3248);
select * from migrations order by id desc;
SELECT
CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,
u.email,
sa.*,
t.owner_id FROM social_accounts sa
JOIN users u on u.id = sa.sociable_id
JOIN teams t on t.id = u.team_id
WHERE u.team_id = 1 and sa.provider = 'salesforce';
select * from teams where id = 1;
select * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;
select * from groups where id = 565;
select * from playbooks where team_id = 1;
select * from playbooks where id = 175;
select * from playbook_categories where playbook_id = 175;
select * from users where team_id = 1;
select * from users where id = 7160;
select * from crm_profiles where user_id = 7160;
select * from features;
select
*
# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,
# crm_configuration_id, crm_provider_id, transcription_id, status
from activities where crm_configuration_id = 1 and type = 'conference'
# and crm_provider_id IS NOT NULL
and provider != 'uploader' and actual_start_time IS NOT NULL
ORDER by id desc;
select * from activities where id = 54747783; # 00UO400000pCzojMAC
select p.id, p.activity_type, pc.id, pc.name
FROM playbooks p
join playbook_categories pc on p.id = pc.playbook_id
where p.team_id = 1 and p.activity_type = 'event';
SELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';
SELECT * FROM crm_field_values WHERE crm_field_id = 4;
select * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id
where crm_configuration_id = 1 and pl.playbook_id = 175;
select * from teams;
SELECT r.* FROM automated_reports r
join teams t on r.team_id = t.id
WHERE r.frequency = 'daily'
and r.status = 1
AND t.status = 'active'
AND (r.expires_at >= now() OR r.expires_at IS NULL);
select * from automated_report_results where report_id IN (18, 33);
select * from automated_reports;
select * from automated_report_results where report_id IN (34);
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
[{"role":"AXButton","text" [{"role":"AXButton","text":"Project: faVsco.js, menu","depth":5,"help_text":"~/jiminny/app","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"#11894 on JY-18909-automated-reports-ask-jiminny, menu","depth":5,"help_text":"Pull request #11894 exists for current branch JY-18909-automated-reports-ask-jiminny, but local branch is out of sync with remote","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Start Listening for PHP Debug Connections","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"RequestGenerateAskJiminnyReportJobTest","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Run 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Debug 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"More Actions","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"JetBrains AI","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Search Everywhere","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"IDE and Project Settings","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.088194445,"height":0.027777778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Console\\Commands\\Reports;\n\nuse Carbon\\Carbon;\nuse Illuminate\\Console\\Command;\nuse Illuminate\\Contracts\\Bus\\Dispatcher as BusDispatcher;\nuse Jiminny\\Jobs\\AutomatedReports\\RequestGenerateAskJiminnyReportJob;\nuse Jiminny\\Jobs\\AutomatedReports\\RequestGenerateReportJob;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Repositories\\AutomatedReportsRepository;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Psr\\Log\\LoggerInterface;\n\nclass AutomatedReportsCommand extends Command\n{\n /**\n * Log prefix for all log messages\n */\n private const string LOG_PREFIX = '[automated-reports]';\n\n /**\n * The name and signature of the console command.\n *\n * @var string\n */\n protected $signature = 'automated-reports {--report-id= : Process a specific report by ID or UUID (bypasses frequency scheduling)}';\n\n /**\n * The console command description.\n *\n * @var string\n */\n protected $description = 'Process automated reports based on their frequency (weekly, monthly, quarterly). Use --report-id to manually trigger a specific report by ID or UUID.';\n\n\n public function __construct(\n private readonly LoggerInterface $logger,\n private readonly BusDispatcher $dispatcher,\n private readonly AutomatedReportsRepository $reportRepository\n ) {\n parent::__construct();\n }\n\n /**\n * Execute the console command.\n *\n * @return int\n */\n public function handle(): int\n {\n $this->logger->info(self::LOG_PREFIX . ' Started');\n\n $reportId = $this->option('report-id');\n\n if ($reportId !== null) {\n return $this->processSingleReport((string) $reportId);\n }\n\n $now = Carbon::now();\n $isMonday = $now->isMonday();\n $isFirstDayOfMonth = $now->day === 1;\n $currentMonth = $now->month;\n\n // Check if the current month is a quarterly month (January, April, July, October)\n $isQuarterlyMonth = in_array($currentMonth, [1, 4, 7, 10], true);\n\n $this->logger->info(self::LOG_PREFIX . ' Checking conditions', [\n 'isMonday' => $isMonday,\n 'isFirstDayOfMonth' => $isFirstDayOfMonth,\n 'currentMonth' => $currentMonth,\n 'isQuarterlyMonth' => $isQuarterlyMonth,\n ]);\n\n // Process daily reports\n $this->processReports(AutomatedReportsService::FREQUENCY_DAILY);\n\n // Process weekly reports on Mondays\n if ($isMonday) {\n $this->processReports(AutomatedReportsService::FREQUENCY_WEEKLY);\n }\n\n // Process monthly reports on the first day of the month\n if ($isFirstDayOfMonth) {\n $this->processReports(AutomatedReportsService::FREQUENCY_MONTHLY);\n }\n\n // Process quarterly reports on the first day of January, April, July, and October\n if ($isFirstDayOfMonth && $isQuarterlyMonth) {\n $this->processReports(AutomatedReportsService::FREQUENCY_QUARTERLY);\n }\n\n $this->logger->info(self::LOG_PREFIX . ' Completed');\n\n return 0;\n }\n\n private function processSingleReport(string $reportId): int\n {\n $this->logger->info(self::LOG_PREFIX . ' Manual single-report mode', ['reportId' => $reportId]);\n\n $report = is_numeric($reportId)\n ? AutomatedReport::withTrashed()->find((int) $reportId)\n : AutomatedReport::withTrashed()->where('uuid', AutomatedReport::toOptimized($reportId))->first();\n\n if ($report === null) {\n $this->logger->error(self::LOG_PREFIX . ' Report not found', ['reportId' => $reportId]);\n $this->error(\"Report not found: {$reportId}\");\n\n return 1;\n }\n\n $this->warnIfNotApplicableForSchedule($report);\n\n $this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [\n 'reportUuid' => $report->getUuid(),\n 'teamId' => $report->getTeamId(),\n 'frequency' => $report->getFrequency(),\n 'type' => $report->getType(),\n ]);\n\n $job = $report->isAskJiminnyReport()\n ? new RequestGenerateAskJiminnyReportJob($report->getUuid())\n : new RequestGenerateReportJob($report->getUuid());\n\n $this->dispatcher->dispatchSync($job);\n\n $this->logger->info(self::LOG_PREFIX . ' Completed');\n\n return 0;\n }\n\n private function warnIfNotApplicableForSchedule(AutomatedReport $report): void\n {\n if ($report->trashed()) {\n $this->warn('Report is soft-deleted (deleted_at: ' . $report->getDeletedAt()?->toDateTimeString() . ').');\n }\n\n if (! $report->getStatus()) {\n $this->warn('Report status is inactive — would be skipped in scheduled run.');\n }\n\n $team = $report->getTeam();\n if ($team->getStatus() !== Team::STATUS_ACTIVE) {\n $this->warn(\"Team #{$report->getTeamId()} is not active (status: {$team->getStatus()}) — would be skipped in scheduled run.\");\n }\n\n if ($report->isExpired()) {\n $this->warn('Report is expired (expires_at: ' . $report->getExpiresAt()?->toDateString() . ') — would be skipped in scheduled run.');\n }\n\n $now = Carbon::now();\n $frequency = $report->getFrequency();\n $wouldRunToday = match ($frequency) {\n AutomatedReportsService::FREQUENCY_DAILY => true,\n AutomatedReportsService::FREQUENCY_WEEKLY => $now->isMonday(),\n AutomatedReportsService::FREQUENCY_MONTHLY => $now->day === 1,\n AutomatedReportsService::FREQUENCY_QUARTERLY => $now->day === 1 && in_array($now->month, [1, 4, 7, 10], true),\n default => false,\n };\n\n if (! $wouldRunToday) {\n $this->warn(\"Report frequency is '{$frequency}' — would NOT be scheduled to run today.\");\n }\n }\n\n /**\n * Process reports for a specific frequency.\n *\n * @param string $frequency\n *\n * @return void\n */\n private function processReports(string $frequency): void\n {\n $this->logger->info(self::LOG_PREFIX . \" Processing $frequency reports\");\n \n $reportId = $this->option('report-id');\n\n if ($reportId !== null) {\n $reports = $this->getReportById($reportId);\n } else {\n // Get all enabled, not deleted reports with active teams for the specified frequency\n $reports = $this->reportRepository->getActiveReportsByFrequency($frequency);\n \n }\n\n $this->logger->info(self::LOG_PREFIX . \" Found {$reports->count()} $frequency reports to process\");\n\n /** @var AutomatedReport $report */\n foreach ($reports as $report) {\n $this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [\n 'reportUuid' => $report->getUuid(),\n 'teamId' => $report->getTeamId(),\n 'frequency' => $report->getFrequency(),\n 'type' => $report->getType(),\n ]);\n\n $job = $report->isAskJiminnyReport()\n ? new RequestGenerateAskJiminnyReportJob($report->getUuid())\n : new RequestGenerateReportJob($report->getUuid());\n\n // $this->dispatcher->dispatch($job);\n $this->dispatcher->dispatchSync($job);\n }\n }\n}","depth":4,"value":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Console\\Commands\\Reports;\n\nuse Carbon\\Carbon;\nuse Illuminate\\Console\\Command;\nuse Illuminate\\Contracts\\Bus\\Dispatcher as BusDispatcher;\nuse Jiminny\\Jobs\\AutomatedReports\\RequestGenerateAskJiminnyReportJob;\nuse Jiminny\\Jobs\\AutomatedReports\\RequestGenerateReportJob;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Repositories\\AutomatedReportsRepository;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Psr\\Log\\LoggerInterface;\n\nclass AutomatedReportsCommand extends Command\n{\n /**\n * Log prefix for all log messages\n */\n private const string LOG_PREFIX = '[automated-reports]';\n\n /**\n * The name and signature of the console command.\n *\n * @var string\n */\n protected $signature = 'automated-reports {--report-id= : Process a specific report by ID or UUID (bypasses frequency scheduling)}';\n\n /**\n * The console command description.\n *\n * @var string\n */\n protected $description = 'Process automated reports based on their frequency (weekly, monthly, quarterly). Use --report-id to manually trigger a specific report by ID or UUID.';\n\n\n public function __construct(\n private readonly LoggerInterface $logger,\n private readonly BusDispatcher $dispatcher,\n private readonly AutomatedReportsRepository $reportRepository\n ) {\n parent::__construct();\n }\n\n /**\n * Execute the console command.\n *\n * @return int\n */\n public function handle(): int\n {\n $this->logger->info(self::LOG_PREFIX . ' Started');\n\n $reportId = $this->option('report-id');\n\n if ($reportId !== null) {\n return $this->processSingleReport((string) $reportId);\n }\n\n $now = Carbon::now();\n $isMonday = $now->isMonday();\n $isFirstDayOfMonth = $now->day === 1;\n $currentMonth = $now->month;\n\n // Check if the current month is a quarterly month (January, April, July, October)\n $isQuarterlyMonth = in_array($currentMonth, [1, 4, 7, 10], true);\n\n $this->logger->info(self::LOG_PREFIX . ' Checking conditions', [\n 'isMonday' => $isMonday,\n 'isFirstDayOfMonth' => $isFirstDayOfMonth,\n 'currentMonth' => $currentMonth,\n 'isQuarterlyMonth' => $isQuarterlyMonth,\n ]);\n\n // Process daily reports\n $this->processReports(AutomatedReportsService::FREQUENCY_DAILY);\n\n // Process weekly reports on Mondays\n if ($isMonday) {\n $this->processReports(AutomatedReportsService::FREQUENCY_WEEKLY);\n }\n\n // Process monthly reports on the first day of the month\n if ($isFirstDayOfMonth) {\n $this->processReports(AutomatedReportsService::FREQUENCY_MONTHLY);\n }\n\n // Process quarterly reports on the first day of January, April, July, and October\n if ($isFirstDayOfMonth && $isQuarterlyMonth) {\n $this->processReports(AutomatedReportsService::FREQUENCY_QUARTERLY);\n }\n\n $this->logger->info(self::LOG_PREFIX . ' Completed');\n\n return 0;\n }\n\n private function processSingleReport(string $reportId): int\n {\n $this->logger->info(self::LOG_PREFIX . ' Manual single-report mode', ['reportId' => $reportId]);\n\n $report = is_numeric($reportId)\n ? AutomatedReport::withTrashed()->find((int) $reportId)\n : AutomatedReport::withTrashed()->where('uuid', AutomatedReport::toOptimized($reportId))->first();\n\n if ($report === null) {\n $this->logger->error(self::LOG_PREFIX . ' Report not found', ['reportId' => $reportId]);\n $this->error(\"Report not found: {$reportId}\");\n\n return 1;\n }\n\n $this->warnIfNotApplicableForSchedule($report);\n\n $this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [\n 'reportUuid' => $report->getUuid(),\n 'teamId' => $report->getTeamId(),\n 'frequency' => $report->getFrequency(),\n 'type' => $report->getType(),\n ]);\n\n $job = $report->isAskJiminnyReport()\n ? new RequestGenerateAskJiminnyReportJob($report->getUuid())\n : new RequestGenerateReportJob($report->getUuid());\n\n $this->dispatcher->dispatchSync($job);\n\n $this->logger->info(self::LOG_PREFIX . ' Completed');\n\n return 0;\n }\n\n private function warnIfNotApplicableForSchedule(AutomatedReport $report): void\n {\n if ($report->trashed()) {\n $this->warn('Report is soft-deleted (deleted_at: ' . $report->getDeletedAt()?->toDateTimeString() . ').');\n }\n\n if (! $report->getStatus()) {\n $this->warn('Report status is inactive — would be skipped in scheduled run.');\n }\n\n $team = $report->getTeam();\n if ($team->getStatus() !== Team::STATUS_ACTIVE) {\n $this->warn(\"Team #{$report->getTeamId()} is not active (status: {$team->getStatus()}) — would be skipped in scheduled run.\");\n }\n\n if ($report->isExpired()) {\n $this->warn('Report is expired (expires_at: ' . $report->getExpiresAt()?->toDateString() . ') — would be skipped in scheduled run.');\n }\n\n $now = Carbon::now();\n $frequency = $report->getFrequency();\n $wouldRunToday = match ($frequency) {\n AutomatedReportsService::FREQUENCY_DAILY => true,\n AutomatedReportsService::FREQUENCY_WEEKLY => $now->isMonday(),\n AutomatedReportsService::FREQUENCY_MONTHLY => $now->day === 1,\n AutomatedReportsService::FREQUENCY_QUARTERLY => $now->day === 1 && in_array($now->month, [1, 4, 7, 10], true),\n default => false,\n };\n\n if (! $wouldRunToday) {\n $this->warn(\"Report frequency is '{$frequency}' — would NOT be scheduled to run today.\");\n }\n }\n\n /**\n * Process reports for a specific frequency.\n *\n * @param string $frequency\n *\n * @return void\n */\n private function processReports(string $frequency): void\n {\n $this->logger->info(self::LOG_PREFIX . \" Processing $frequency reports\");\n \n $reportId = $this->option('report-id');\n\n if ($reportId !== null) {\n $reports = $this->getReportById($reportId);\n } else {\n // Get all enabled, not deleted reports with active teams for the specified frequency\n $reports = $this->reportRepository->getActiveReportsByFrequency($frequency);\n \n }\n\n $this->logger->info(self::LOG_PREFIX . \" Found {$reports->count()} $frequency reports to process\");\n\n /** @var AutomatedReport $report */\n foreach ($reports as $report) {\n $this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [\n 'reportUuid' => $report->getUuid(),\n 'teamId' => $report->getTeamId(),\n 'frequency' => $report->getFrequency(),\n 'type' => $report->getType(),\n ]);\n\n $job = $report->isAskJiminnyReport()\n ? new RequestGenerateAskJiminnyReportJob($report->getUuid())\n : new RequestGenerateReportJob($report->getUuid());\n\n // $this->dispatcher->dispatch($job);\n $this->dispatcher->dispatchSync($job);\n }\n }\n}","role_description":"text entry area","is_enabled":true,"is_focused":true,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Execute","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Explain Plan","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Browse Query History","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"View Parameters","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Open Query Execution Settings…","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"In-Editor Results","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Tx: Auto","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Cancel Running Statements","depth":4,"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Playground","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"jiminny","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.088194445,"height":0.027777778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"16","depth":4,"role_description":"text"},{"role":"AXStaticText","text":"13","depth":4,"role_description":"text"},{"role":"AXStaticText","text":"13","depth":4,"role_description":"text"},{"role":"AXButton","text":"Previous Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Next Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"SELECT * FROM teams WHERE id = 1;\n\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;\nSELECT * FROM crm_fields WHERE id = 2234;\nSELECT * FROM crm_field_values WHERE crm_field_id = 2234;\n\nselect * from crm_profiles where user_id = 143;\n\nselect * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO\nselect * from business_processes where crm_configuration_id = 39;\n# 01941000000H669AAC, 01941000000H66JAAS\n\nselect * from record_type_field_values\n where record_type_id IN (24);\n\nselect * from crm_field_values where id IN (2730);\n\nselect * from crm_configurations where id = 39;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce'; #1035\n\n\nselect * from users where team_id = 1; # 222 group 3\nSELECT * FROM activities WHERE user_id = 222 order by id desc;\nselect * from sidekick_settings where team_id = 1;\nselect * from teams where id = 1;\nselect * from team_features where team_id = 1;\n\nselect * from activities where crm_configuration_id = 2\nand provider = 'ms-teams' and id = 608765;\n\nSELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';\n\nselect * from sidekick_settings where team_id = 2;\n\nSELECT * FROM activities WHERE id = 608660;\nselect * from activity_summary_logs where activity_id = 608660;\nselect * from ai_prompts where transcription_id = 11214;\n\n# ********************************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;\n# id: 608818, crm: 59628809737\nSELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;\n# id: 608821, crm: 59632069252\nSELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,\nplaybook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,\nscheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at\nFROM activities a\njoin calendar_events ce on a.calendar_event_id = ce.id\nWHERE a.id IN (608818, 608821);\n\nselect * from users where team_id = 1;\nselect * from team_settings where team_id = 1;\nselect * from crm_profiles where crm_configuration_id = 39 order by user_id;\n\nselect * from team_features where team_id = 1;\n\nselect * from users where team_id = 2;\n\nSELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639\n# Preslava N. Ivanova, grou id 3\n\nSELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;\n\nselect * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';\n\nselect\n a.id,\n a.type,\n a.scheduled_start_time,\n a.actual_start_time,\n a.created_at,\n a.opportunity_id,\n a.status\nFROM activities a\nWHERE opportunity_id = 344\nand status IN ('completed', 'received', 'delivered')\nand (\n (a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))\n;\n\nSELECT * FROM users WHERE id = 222;\n\nSELECT * FROM crm_profiles WHERE user_id = 222;\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;\n\nselect * from group_deal_risk_types;\n\nselect * from opportunities where team_id = 1;\n\nSELECT * FROM opportunities WHERE id = 315;\nSELECT * FROM crm_field_data WHERE object_id = 315;\nselect * from crm_field_data where object_id = 260;\n\nselect * from generic_ai_prompts where subject_id = 315;\n\nselect * from teams; # 36, 21, 121, james.graham@bullhorn.jiminny.com\nSELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';\n\n# ************************************************************************************\nselect * from teams where id = 1;\nselect * from crm_configurations where id = 39;\nselect * from users where team_id = 1;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 1;\n# 1 - 00541000004281rAAA\n# 204 - 0052g000003freeAAA\n# 429 - 0052g000003qGOiAAM\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\nselect * from activities where type = 'softphone'\nand created_at > '2024-12-11 15:24:36' order by id desc;\n\nselect * from activity_providers where team_id = 1;\nselect * from activity_provider_users where activity_provider_id = 328;\n\nselect * from opportunities where crm_configuration_id = 39\nAND account_id = 178 AND is_closed = false\norder by created_at DESC;\n\nselect * from contacts where id = 3952;\nselect * from accounts where id = 178;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations where id = 21;\nselect * from users where team_id = 36;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 36;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 36\nand sa.provider = 'bullhorn';\n\nselect * from social_accounts where id = 348;\nUPDATE social_accounts SET\nprovider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',\nprovider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',\nexpires = 1733998131,\nstate = 'connected'\nWHERE id = 348;\n\n# ************************************************************************************\nselect * from teams where id = 31;\nselect * from crm_configurations where id = 18;\n\nselect * from users where team_id = 31; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 31;\n\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 31\nand sa.provider = 'close';\n\nselect * from contacts where crm_configuration_id = 18;\n\n# ********************** NEPTUNE **************************************************************\nselect * from teams;\nselect * from users where id IN (1030, 1035, 1052);\nselect * from crm_configurations;\n\nselect * from users where team_id = 65; # 257\nselect * from team_settings where team_id = 65; # 257\nselect * from invitations where team_id = 65; # 257\nselect * from users where email = 'integration-account@jiminny.com'; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 65;\n\nselect * from crm_configurations where id = 53;\nselect * from accounts where crm_configuration_id = 53 order by id desc;\nselect * from leads where crm_configuration_id = 53 order by id desc;\nselect * from contacts where crm_configuration_id = 53 order by id desc;\nselect * from opportunities where crm_configuration_id = 53 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 53 order by id desc;\nselect * from crm_fields where crm_configuration_id = 53 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 53 order by id desc;\nselect * from stages where crm_configuration_id = 53 order by id desc;\n\n\nselect * from crm_profiles where crm_configuration_id = 13;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\nand sa.provider = 'integration-app';\n\nselect * from contacts where crm_configuration_id = 13;\n\nselect * from social_accounts where sociable_id = 283;\n\nSELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';\n\nselect * from activity_providers where team_id = 65;\nSELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\n;\n\n# ***************************** STAGING ********************************************\nSELECT * FROM teams;\nSELECT * FROM teams WHERE id = 88;\nSELECT * FROM teams WHERE id = 89;\nselect * from team_settings where team_id = 89;\nSELECT * FROM users WHERE team_id = 89;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 89;\n\nselect * from users;\nSELECT * FROM social_accounts WHERE sociable_id = 1761;\nSELECT * FROM crm_configurations WHERE id = 70;\nselect * from accounts where crm_configuration_id = 70 order by id desc;\nselect * from leads where crm_configuration_id = 70 order by id desc;\nselect * from contacts where crm_configuration_id = 70 order by id desc;\nselect * from opportunities where crm_configuration_id = 70 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 70 order by id desc;\nselect * from crm_fields where crm_configuration_id = 70 order by id desc;\nselect * from crm_field_values where crm_field_id = 3536 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 70 order by id desc;\nselect * from stages where crm_configuration_id = 70 order by id desc;\nselect * from business_processes where crm_configuration_id = 70 order by id desc;\nselect * from business_process_stages where business_process_id = 34;\n\nselect * from contacts where id = 10468;\n\nselect * from crm_layouts where crm_configuration_id = 70;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;\nSELECT * FROM crm_fields WHERE id IN (3533,3534,3535);\n\nselect * from activities where crm_configuration_id = 70\nand (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;\n\nSELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;\nSELECT * FROM activities where crm_configuration_id = 69 ;\n\nSELECT * FROM users WHERE email LIKE '%jiminny_web_sa2@jiminny.com%';\nSELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;\nSELECT * FROM opportunities WHERE id = 385;\n\nselect * from participants p\njoin activities a on p.activity_id = a.id\nwhere a.crm_configuration_id = 70\nand (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);\nSELECT * FROM participants WHERE id = 1013638;\n\nselect * from teams where id = 90;\nselect * from users where team_id = 90;\nselect * from social_accounts where social_accounts.sociable_id IN (1960,1760);\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 71;\nselect * from invitations where team_id = 90;\n\nselect * from crm_configurations where id = 71;\nselect * from accounts where crm_configuration_id = 71 order by id desc;\nselect * from leads where crm_configuration_id = 71 order by id desc;\nselect * from contacts where crm_configuration_id = 71 order by id desc;\nselect * from opportunities where crm_configuration_id = 71 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 71 order by id desc;\nselect * from crm_fields where crm_configuration_id = 71 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 71 order by id desc;\nselect * from stages where crm_configuration_id = 71 order by id desc;\n\nselect * from users order by secondary_email desc;\nselect u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa\n join users u on sa.sociable_id = u.id\nwhere sa.provider = 'google' and u.email LIKE 'aneliya%';\n\nselect * from failed_jobs order by id desc;\n\nselect * from users where email = 'ben.allwright@learningpeople.co.uk' or secondary_email = 'ben.allwright@learningpeople.co.uk';\n\nselect * from teams;\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 39;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\n# ************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;\nSELECT * FROM crm_configurations WHERE id = 70;\n\nselect * from teams where id = 1;\nselect * from groups where team_id = 1;\nselect * from users where team_id = 1;\n\nselect o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o\njoin users u on o.user_id = u.id\njoin groups g on u.group_id = g.id\njoin role_user ru on u.id = ru.user_id\njoin roles r on ru.role_id = r.id\nwhere o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';\n\nselect * from role_user where user_id = 143;\nselect * from roles;\n\nselect * from role_user;\nselect * from groups where id = 9;\nselect * from scope_groups where group_id = 9;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations;\nSELECT * FROM social_accounts WHERE sociable_id = 121;\n\nhttps://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105\nhttps://crmsandbox.zoho.com/crm/\n\nhttps://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080\n https://crm.zoho.com/crm/\n org3469620\n\nSELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;\n\nselect * from users where email LIKE \"%mobile_automation_%\";\nselect * from social_accounts where sociable_id IN (2228);\nselect * from crm_profiles where user_id IN (2222,2223,2226,2227);\n\nselect * from teams order by id desc;\nSELECT * FROM users WHERE id = 2229;\nSELECT * FROM crm_profiles WHERE user_id = 2229;\nselect * from opportunities where crm_configuration_id = 88;\nselect * from crm_fields where crm_configuration_id = 88;\nselect * from crm_profiles where crm_configuration_id = 88;\n\nSELECT * FROM teams WHERE id = 1;\n\nSELECT * FROM users WHERE id = 143;\nSELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;\n\nhttps://app.staging.jiminny.com/ondemand?\n min_duration=1\n &\n only_recorded=1\n &\n user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e\n &\n sequence_number=2\n\n select * from users where team_id = 1 and email like '%stoyan%'\n\nselect * from coaching_feedbacks;\n\nselect * from teams;\nSELECT * FROM users WHERE team_id = 36;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from users where id = 143;\n\nSELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\n\nselect * from users where team_id = 2;\nselect * from activities where crm_configuration_id = 39\nand activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'\nAND user_id = 143\norder by id desc;\n\n# ************************************************************************************\nselect * from teams where id = 142; # 2312, 126\nselect * from team_settings;\nselect * from users where team_id = 142; # 21642\nSELECT * FROM social_accounts WHERE sociable_id = 21642;\nSELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;\nselect * from crm_profiles where id IN (93);\nselect * from invitations;\nselect * from team_features where team_id = 1;\n\nSELECT * FROM crm_configurations WHERE id = 126;\nselect * from accounts where crm_configuration_id = 126 order by id desc;\nselect * from leads where crm_configuration_id = 126 order by id desc;\nselect * from contacts where crm_configuration_id = 126 order by id desc;\nselect * from opportunities where crm_configuration_id = 126 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 126 order by id desc;\nselect * from crm_fields where crm_configuration_id = 126 # 11060\n# and type IN ('picklist', 'status')\n# and object_type = 'task'\norder by id desc;\n# 5731,5732,5733\nselect DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;\nselect * from crm_layouts where crm_configuration_id = 126 order by id desc;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);\nselect * from stages where crm_configuration_id = 126 order by id desc;\nselect * from business_processes where crm_configuration_id = 126 order by id desc;\nselect * from business_process_stages where business_process_id IN (76,75,74,73);\nselect * from playbooks where team_id = 142;\nselect * from playbook_layouts where playbook_id IN (108);\nSELECT * FROM playbook_categories WHERE playbook_id IN (108);\n\nselect * from teams where id = 130;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 2\nand sa.provider = 'hubspot';\n\nSELECT * FROM activities\n WHERE crm_configuration_id = 110;\n\nselect * from teams;\nselect * from crm_configurations;\n\nSELECT * FROM activities WHERE id = 628773;\nSELECT * FROM crm_profiles WHERE user_id = 1460;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from teams;\nselect ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id\njoin permission_role pr on pr.role_id = ru.role_id\n join permissions p on p.id = pr.permission_id\nwhere team_id = 495 and p.name IN ('dial');\n\nselect * from teams where id = 145;\nselect * from crm_configurations where id = 129;\nselect * from social_accounts where sociable_id = 2317;\nSELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;\n\nselect * from teams where id = 1;\nSELECT * FROM crm_layouts WHERE crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;\nSELECT * FROM crm_layout_entities WHERE id = 5507;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');\n\nselect * from teams;\nselect * from activities where crm_configuration_id = 14;\n\nSELECT * FROM social_accounts where provider = 'copper';\n\nselect * from activities where id = 628467;\nselect * from participants where activity_id = 628467;\n\nSELECT * FROM contacts WHERE id = 3969;\nSELECT * FROM accounts WHERE id = 177;\n\nSELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;\n\n# ********************* BH\nselect * from teams where id = 36;\nSELECT * FROM crm_configurations WHERE id = 21;\nselect * from activities where crm_configuration_id = 21 and id = 607901;\nselect * from activities where crm_configuration_id = 21;\n\nselect * roles;\nselect * from permissions;\nselect * from permission_role where permission_id = 226;\n\nselect * from migrations order by id desc;\n\n# mercury\n# neptune\n# earth\n\nselect * from teams;\nselect * from teams where id = 19;\nselect * from teams where id = 27;\nselect * from users where team_id = 27;\nSELECT * FROM crm_configurations WHERE id = 42;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from activities where id = 631461;\nSELECT * FROM crm_field_values WHERE crm_field_id = 180;\n\nselect * from teams where id = 2;\nSELECT * FROM social_accounts WHERE sociable_id = 89;\n\nSELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273\nselect * from activity_summary_logs where activity_id = 634273;\n\nselect * from sidekick_settings where team_id = 2;\n\nselect * from teams; # 2, 2\nSELECT * FROM crm_configurations WHERE team_id = 2; # 2\nselect * from team_features where team_id = 2;\nselect * from features;\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;\n\nselect * from automated_reports order by id desc;\nselect * from automated_report_results order by id desc;\nselect * from users where team_id = 1 and id IN (7160, 3248);\nselect * from migrations order by id desc;\n\nSELECT\n CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,\n u.email,\n sa.*,\n t.owner_id FROM social_accounts sa\nJOIN users u on u.id = sa.sociable_id\nJOIN teams t on t.id = u.team_id\nWHERE u.team_id = 1 and sa.provider = 'salesforce';\n\nselect * from teams where id = 1;\nselect * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;\nselect * from groups where id = 565;\nselect * from playbooks where team_id = 1;\nselect * from playbooks where id = 175;\nselect * from playbook_categories where playbook_id = 175;\nselect * from users where team_id = 1;\nselect * from users where id = 7160;\nselect * from crm_profiles where user_id = 7160;\nselect * from features;\nselect\n *\n# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,\n# crm_configuration_id, crm_provider_id, transcription_id, status\nfrom activities where crm_configuration_id = 1 and type = 'conference'\n# and crm_provider_id IS NOT NULL\nand provider != 'uploader' and actual_start_time IS NOT NULL\nORDER by id desc;\nselect * from activities where id = 54747783; # 00UO400000pCzojMAC\n\nselect p.id, p.activity_type, pc.id, pc.name\nFROM playbooks p\njoin playbook_categories pc on p.id = pc.playbook_id\nwhere p.team_id = 1 and p.activity_type = 'event';\n\nSELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';\nSELECT * FROM crm_field_values WHERE crm_field_id = 4;\n\nselect * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id\nwhere crm_configuration_id = 1 and pl.playbook_id = 175;\n\nselect * from teams;\nSELECT r.* FROM automated_reports r\njoin teams t on r.team_id = t.id\nWHERE r.frequency = 'daily'\n and r.status = 1\nAND t.status = 'active'\nAND (r.expires_at >= now() OR r.expires_at IS NULL);\n\nselect * from automated_report_results where report_id IN (18, 33);\n\nselect * from automated_reports;\nselect * from automated_report_results where report_id IN (34);","depth":4,"value":"SELECT * FROM teams WHERE id = 1;\n\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;\nSELECT * FROM crm_fields WHERE id = 2234;\nSELECT * FROM crm_field_values WHERE crm_field_id = 2234;\n\nselect * from crm_profiles where user_id = 143;\n\nselect * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO\nselect * from business_processes where crm_configuration_id = 39;\n# 01941000000H669AAC, 01941000000H66JAAS\n\nselect * from record_type_field_values\n where record_type_id IN (24);\n\nselect * from crm_field_values where id IN (2730);\n\nselect * from crm_configurations where id = 39;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce'; #1035\n\n\nselect * from users where team_id = 1; # 222 group 3\nSELECT * FROM activities WHERE user_id = 222 order by id desc;\nselect * from sidekick_settings where team_id = 1;\nselect * from teams where id = 1;\nselect * from team_features where team_id = 1;\n\nselect * from activities where crm_configuration_id = 2\nand provider = 'ms-teams' and id = 608765;\n\nSELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';\n\nselect * from sidekick_settings where team_id = 2;\n\nSELECT * FROM activities WHERE id = 608660;\nselect * from activity_summary_logs where activity_id = 608660;\nselect * from ai_prompts where transcription_id = 11214;\n\n# ********************************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;\n# id: 608818, crm: 59628809737\nSELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;\n# id: 608821, crm: 59632069252\nSELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,\nplaybook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,\nscheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at\nFROM activities a\njoin calendar_events ce on a.calendar_event_id = ce.id\nWHERE a.id IN (608818, 608821);\n\nselect * from users where team_id = 1;\nselect * from team_settings where team_id = 1;\nselect * from crm_profiles where crm_configuration_id = 39 order by user_id;\n\nselect * from team_features where team_id = 1;\n\nselect * from users where team_id = 2;\n\nSELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639\n# Preslava N. Ivanova, grou id 3\n\nSELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;\n\nselect * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';\n\nselect\n a.id,\n a.type,\n a.scheduled_start_time,\n a.actual_start_time,\n a.created_at,\n a.opportunity_id,\n a.status\nFROM activities a\nWHERE opportunity_id = 344\nand status IN ('completed', 'received', 'delivered')\nand (\n (a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))\n;\n\nSELECT * FROM users WHERE id = 222;\n\nSELECT * FROM crm_profiles WHERE user_id = 222;\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;\n\nselect * from group_deal_risk_types;\n\nselect * from opportunities where team_id = 1;\n\nSELECT * FROM opportunities WHERE id = 315;\nSELECT * FROM crm_field_data WHERE object_id = 315;\nselect * from crm_field_data where object_id = 260;\n\nselect * from generic_ai_prompts where subject_id = 315;\n\nselect * from teams; # 36, 21, 121, james.graham@bullhorn.jiminny.com\nSELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';\n\n# ************************************************************************************\nselect * from teams where id = 1;\nselect * from crm_configurations where id = 39;\nselect * from users where team_id = 1;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 1;\n# 1 - 00541000004281rAAA\n# 204 - 0052g000003freeAAA\n# 429 - 0052g000003qGOiAAM\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\nselect * from activities where type = 'softphone'\nand created_at > '2024-12-11 15:24:36' order by id desc;\n\nselect * from activity_providers where team_id = 1;\nselect * from activity_provider_users where activity_provider_id = 328;\n\nselect * from opportunities where crm_configuration_id = 39\nAND account_id = 178 AND is_closed = false\norder by created_at DESC;\n\nselect * from contacts where id = 3952;\nselect * from accounts where id = 178;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations where id = 21;\nselect * from users where team_id = 36;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 36;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 36\nand sa.provider = 'bullhorn';\n\nselect * from social_accounts where id = 348;\nUPDATE social_accounts SET\nprovider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',\nprovider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',\nexpires = 1733998131,\nstate = 'connected'\nWHERE id = 348;\n\n# ************************************************************************************\nselect * from teams where id = 31;\nselect * from crm_configurations where id = 18;\n\nselect * from users where team_id = 31; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 31;\n\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 31\nand sa.provider = 'close';\n\nselect * from contacts where crm_configuration_id = 18;\n\n# ********************** NEPTUNE **************************************************************\nselect * from teams;\nselect * from users where id IN (1030, 1035, 1052);\nselect * from crm_configurations;\n\nselect * from users where team_id = 65; # 257\nselect * from team_settings where team_id = 65; # 257\nselect * from invitations where team_id = 65; # 257\nselect * from users where email = 'integration-account@jiminny.com'; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 65;\n\nselect * from crm_configurations where id = 53;\nselect * from accounts where crm_configuration_id = 53 order by id desc;\nselect * from leads where crm_configuration_id = 53 order by id desc;\nselect * from contacts where crm_configuration_id = 53 order by id desc;\nselect * from opportunities where crm_configuration_id = 53 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 53 order by id desc;\nselect * from crm_fields where crm_configuration_id = 53 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 53 order by id desc;\nselect * from stages where crm_configuration_id = 53 order by id desc;\n\n\nselect * from crm_profiles where crm_configuration_id = 13;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\nand sa.provider = 'integration-app';\n\nselect * from contacts where crm_configuration_id = 13;\n\nselect * from social_accounts where sociable_id = 283;\n\nSELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';\n\nselect * from activity_providers where team_id = 65;\nSELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\n;\n\n# ***************************** STAGING ********************************************\nSELECT * FROM teams;\nSELECT * FROM teams WHERE id = 88;\nSELECT * FROM teams WHERE id = 89;\nselect * from team_settings where team_id = 89;\nSELECT * FROM users WHERE team_id = 89;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 89;\n\nselect * from users;\nSELECT * FROM social_accounts WHERE sociable_id = 1761;\nSELECT * FROM crm_configurations WHERE id = 70;\nselect * from accounts where crm_configuration_id = 70 order by id desc;\nselect * from leads where crm_configuration_id = 70 order by id desc;\nselect * from contacts where crm_configuration_id = 70 order by id desc;\nselect * from opportunities where crm_configuration_id = 70 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 70 order by id desc;\nselect * from crm_fields where crm_configuration_id = 70 order by id desc;\nselect * from crm_field_values where crm_field_id = 3536 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 70 order by id desc;\nselect * from stages where crm_configuration_id = 70 order by id desc;\nselect * from business_processes where crm_configuration_id = 70 order by id desc;\nselect * from business_process_stages where business_process_id = 34;\n\nselect * from contacts where id = 10468;\n\nselect * from crm_layouts where crm_configuration_id = 70;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;\nSELECT * FROM crm_fields WHERE id IN (3533,3534,3535);\n\nselect * from activities where crm_configuration_id = 70\nand (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;\n\nSELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;\nSELECT * FROM activities where crm_configuration_id = 69 ;\n\nSELECT * FROM users WHERE email LIKE '%jiminny_web_sa2@jiminny.com%';\nSELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;\nSELECT * FROM opportunities WHERE id = 385;\n\nselect * from participants p\njoin activities a on p.activity_id = a.id\nwhere a.crm_configuration_id = 70\nand (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);\nSELECT * FROM participants WHERE id = 1013638;\n\nselect * from teams where id = 90;\nselect * from users where team_id = 90;\nselect * from social_accounts where social_accounts.sociable_id IN (1960,1760);\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 71;\nselect * from invitations where team_id = 90;\n\nselect * from crm_configurations where id = 71;\nselect * from accounts where crm_configuration_id = 71 order by id desc;\nselect * from leads where crm_configuration_id = 71 order by id desc;\nselect * from contacts where crm_configuration_id = 71 order by id desc;\nselect * from opportunities where crm_configuration_id = 71 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 71 order by id desc;\nselect * from crm_fields where crm_configuration_id = 71 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 71 order by id desc;\nselect * from stages where crm_configuration_id = 71 order by id desc;\n\nselect * from users order by secondary_email desc;\nselect u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa\n join users u on sa.sociable_id = u.id\nwhere sa.provider = 'google' and u.email LIKE 'aneliya%';\n\nselect * from failed_jobs order by id desc;\n\nselect * from users where email = 'ben.allwright@learningpeople.co.uk' or secondary_email = 'ben.allwright@learningpeople.co.uk';\n\nselect * from teams;\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 39;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\n# ************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;\nSELECT * FROM crm_configurations WHERE id = 70;\n\nselect * from teams where id = 1;\nselect * from groups where team_id = 1;\nselect * from users where team_id = 1;\n\nselect o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o\njoin users u on o.user_id = u.id\njoin groups g on u.group_id = g.id\njoin role_user ru on u.id = ru.user_id\njoin roles r on ru.role_id = r.id\nwhere o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';\n\nselect * from role_user where user_id = 143;\nselect * from roles;\n\nselect * from role_user;\nselect * from groups where id = 9;\nselect * from scope_groups where group_id = 9;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations;\nSELECT * FROM social_accounts WHERE sociable_id = 121;\n\nhttps://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105\nhttps://crmsandbox.zoho.com/crm/\n\nhttps://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080\n https://crm.zoho.com/crm/\n org3469620\n\nSELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;\n\nselect * from users where email LIKE \"%mobile_automation_%\";\nselect * from social_accounts where sociable_id IN (2228);\nselect * from crm_profiles where user_id IN (2222,2223,2226,2227);\n\nselect * from teams order by id desc;\nSELECT * FROM users WHERE id = 2229;\nSELECT * FROM crm_profiles WHERE user_id = 2229;\nselect * from opportunities where crm_configuration_id = 88;\nselect * from crm_fields where crm_configuration_id = 88;\nselect * from crm_profiles where crm_configuration_id = 88;\n\nSELECT * FROM teams WHERE id = 1;\n\nSELECT * FROM users WHERE id = 143;\nSELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;\n\nhttps://app.staging.jiminny.com/ondemand?\n min_duration=1\n &\n only_recorded=1\n &\n user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e\n &\n sequence_number=2\n\n select * from users where team_id = 1 and email like '%stoyan%'\n\nselect * from coaching_feedbacks;\n\nselect * from teams;\nSELECT * FROM users WHERE team_id = 36;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from users where id = 143;\n\nSELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\n\nselect * from users where team_id = 2;\nselect * from activities where crm_configuration_id = 39\nand activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'\nAND user_id = 143\norder by id desc;\n\n# ************************************************************************************\nselect * from teams where id = 142; # 2312, 126\nselect * from team_settings;\nselect * from users where team_id = 142; # 21642\nSELECT * FROM social_accounts WHERE sociable_id = 21642;\nSELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;\nselect * from crm_profiles where id IN (93);\nselect * from invitations;\nselect * from team_features where team_id = 1;\n\nSELECT * FROM crm_configurations WHERE id = 126;\nselect * from accounts where crm_configuration_id = 126 order by id desc;\nselect * from leads where crm_configuration_id = 126 order by id desc;\nselect * from contacts where crm_configuration_id = 126 order by id desc;\nselect * from opportunities where crm_configuration_id = 126 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 126 order by id desc;\nselect * from crm_fields where crm_configuration_id = 126 # 11060\n# and type IN ('picklist', 'status')\n# and object_type = 'task'\norder by id desc;\n# 5731,5732,5733\nselect DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;\nselect * from crm_layouts where crm_configuration_id = 126 order by id desc;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);\nselect * from stages where crm_configuration_id = 126 order by id desc;\nselect * from business_processes where crm_configuration_id = 126 order by id desc;\nselect * from business_process_stages where business_process_id IN (76,75,74,73);\nselect * from playbooks where team_id = 142;\nselect * from playbook_layouts where playbook_id IN (108);\nSELECT * FROM playbook_categories WHERE playbook_id IN (108);\n\nselect * from teams where id = 130;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 2\nand sa.provider = 'hubspot';\n\nSELECT * FROM activities\n WHERE crm_configuration_id = 110;\n\nselect * from teams;\nselect * from crm_configurations;\n\nSELECT * FROM activities WHERE id = 628773;\nSELECT * FROM crm_profiles WHERE user_id = 1460;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from teams;\nselect ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id\njoin permission_role pr on pr.role_id = ru.role_id\n join permissions p on p.id = pr.permission_id\nwhere team_id = 495 and p.name IN ('dial');\n\nselect * from teams where id = 145;\nselect * from crm_configurations where id = 129;\nselect * from social_accounts where sociable_id = 2317;\nSELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;\n\nselect * from teams where id = 1;\nSELECT * FROM crm_layouts WHERE crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;\nSELECT * FROM crm_layout_entities WHERE id = 5507;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');\n\nselect * from teams;\nselect * from activities where crm_configuration_id = 14;\n\nSELECT * FROM social_accounts where provider = 'copper';\n\nselect * from activities where id = 628467;\nselect * from participants where activity_id = 628467;\n\nSELECT * FROM contacts WHERE id = 3969;\nSELECT * FROM accounts WHERE id = 177;\n\nSELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;\n\n# ********************* BH\nselect * from teams where id = 36;\nSELECT * FROM crm_configurations WHERE id = 21;\nselect * from activities where crm_configuration_id = 21 and id = 607901;\nselect * from activities where crm_configuration_id = 21;\n\nselect * roles;\nselect * from permissions;\nselect * from permission_role where permission_id = 226;\n\nselect * from migrations order by id desc;\n\n# mercury\n# neptune\n# earth\n\nselect * from teams;\nselect * from teams where id = 19;\nselect * from teams where id = 27;\nselect * from users where team_id = 27;\nSELECT * FROM crm_configurations WHERE id = 42;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from activities where id = 631461;\nSELECT * FROM crm_field_values WHERE crm_field_id = 180;\n\nselect * from teams where id = 2;\nSELECT * FROM social_accounts WHERE sociable_id = 89;\n\nSELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273\nselect * from activity_summary_logs where activity_id = 634273;\n\nselect * from sidekick_settings where team_id = 2;\n\nselect * from teams; # 2, 2\nSELECT * FROM crm_configurations WHERE team_id = 2; # 2\nselect * from team_features where team_id = 2;\nselect * from features;\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;\n\nselect * from automated_reports order by id desc;\nselect * from automated_report_results order by id desc;\nselect * from users where team_id = 1 and id IN (7160, 3248);\nselect * from migrations order by id desc;\n\nSELECT\n CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,\n u.email,\n sa.*,\n t.owner_id FROM social_accounts sa\nJOIN users u on u.id = sa.sociable_id\nJOIN teams t on t.id = u.team_id\nWHERE u.team_id = 1 and sa.provider = 'salesforce';\n\nselect * from teams where id = 1;\nselect * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;\nselect * from groups where id = 565;\nselect * from playbooks where team_id = 1;\nselect * from playbooks where id = 175;\nselect * from playbook_categories where playbook_id = 175;\nselect * from users where team_id = 1;\nselect * from users where id = 7160;\nselect * from crm_profiles where user_id = 7160;\nselect * from features;\nselect\n *\n# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,\n# crm_configuration_id, crm_provider_id, transcription_id, status\nfrom activities where crm_configuration_id = 1 and type = 'conference'\n# and crm_provider_id IS NOT NULL\nand provider != 'uploader' and actual_start_time IS NOT NULL\nORDER by id desc;\nselect * from activities where id = 54747783; # 00UO400000pCzojMAC\n\nselect p.id, p.activity_type, pc.id, pc.name\nFROM playbooks p\njoin playbook_categories pc on p.id = pc.playbook_id\nwhere p.team_id = 1 and p.activity_type = 'event';\n\nSELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';\nSELECT * FROM crm_field_values WHERE crm_field_id = 4;\n\nselect * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id\nwhere crm_configuration_id = 1 and pl.playbook_id = 175;\n\nselect * from teams;\nSELECT r.* FROM automated_reports r\njoin teams t on r.team_id = t.id\nWHERE r.frequency = 'daily'\n and r.status = 1\nAND t.status = 'active'\nAND (r.expires_at >= now() OR r.expires_at IS NULL);\n\nselect * from automated_report_results where report_id IN (18, 33);\n\nselect * from automated_reports;\nselect * from automated_report_results where report_id IN (34);","role_description":"text entry area","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Project","depth":3,"role_description":"text"},{"role":"AXButton","text":"Project","depth":3,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"New File or Directory…","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Expand Selected","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Collapse All","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Options","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false}]...
|
-1978360131630512558
|
6686649039917036621
|
idle
|
accessibility
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
<?php
declare(strict_types=1);
namespace Jiminny\Console\Commands\Reports;
use Carbon\Carbon;
use Illuminate\Console\Command;
use Illuminate\Contracts\Bus\Dispatcher as BusDispatcher;
use Jiminny\Jobs\AutomatedReports\RequestGenerateAskJiminnyReportJob;
use Jiminny\Jobs\AutomatedReports\RequestGenerateReportJob;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\Team;
use Jiminny\Repositories\AutomatedReportsRepository;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Psr\Log\LoggerInterface;
class AutomatedReportsCommand extends Command
{
/**
* Log prefix for all log messages
*/
private const string LOG_PREFIX = '[automated-reports]';
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'automated-reports {--report-id= : Process a specific report by ID or UUID (bypasses frequency scheduling)}';
/**
* The console command description.
*
* @var string
*/
protected $description = 'Process automated reports based on their frequency (weekly, monthly, quarterly). Use --report-id to manually trigger a specific report by ID or UUID.';
public function __construct(
private readonly LoggerInterface $logger,
private readonly BusDispatcher $dispatcher,
private readonly AutomatedReportsRepository $reportRepository
) {
parent::__construct();
}
/**
* Execute the console command.
*
* @return int
*/
public function handle(): int
{
$this->logger->info(self::LOG_PREFIX . ' Started');
$reportId = $this->option('report-id');
if ($reportId !== null) {
return $this->processSingleReport((string) $reportId);
}
$now = Carbon::now();
$isMonday = $now->isMonday();
$isFirstDayOfMonth = $now->day === 1;
$currentMonth = $now->month;
// Check if the current month is a quarterly month (January, April, July, October)
$isQuarterlyMonth = in_array($currentMonth, [1, 4, 7, 10], true);
$this->logger->info(self::LOG_PREFIX . ' Checking conditions', [
'isMonday' => $isMonday,
'isFirstDayOfMonth' => $isFirstDayOfMonth,
'currentMonth' => $currentMonth,
'isQuarterlyMonth' => $isQuarterlyMonth,
]);
// Process daily reports
$this->processReports(AutomatedReportsService::FREQUENCY_DAILY);
// Process weekly reports on Mondays
if ($isMonday) {
$this->processReports(AutomatedReportsService::FREQUENCY_WEEKLY);
}
// Process monthly reports on the first day of the month
if ($isFirstDayOfMonth) {
$this->processReports(AutomatedReportsService::FREQUENCY_MONTHLY);
}
// Process quarterly reports on the first day of January, April, July, and October
if ($isFirstDayOfMonth && $isQuarterlyMonth) {
$this->processReports(AutomatedReportsService::FREQUENCY_QUARTERLY);
}
$this->logger->info(self::LOG_PREFIX . ' Completed');
return 0;
}
private function processSingleReport(string $reportId): int
{
$this->logger->info(self::LOG_PREFIX . ' Manual single-report mode', ['reportId' => $reportId]);
$report = is_numeric($reportId)
? AutomatedReport::withTrashed()->find((int) $reportId)
: AutomatedReport::withTrashed()->where('uuid', AutomatedReport::toOptimized($reportId))->first();
if ($report === null) {
$this->logger->error(self::LOG_PREFIX . ' Report not found', ['reportId' => $reportId]);
$this->error("Report not found: {$reportId}");
return 1;
}
$this->warnIfNotApplicableForSchedule($report);
$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [
'reportUuid' => $report->getUuid(),
'teamId' => $report->getTeamId(),
'frequency' => $report->getFrequency(),
'type' => $report->getType(),
]);
$job = $report->isAskJiminnyReport()
? new RequestGenerateAskJiminnyReportJob($report->getUuid())
: new RequestGenerateReportJob($report->getUuid());
$this->dispatcher->dispatchSync($job);
$this->logger->info(self::LOG_PREFIX . ' Completed');
return 0;
}
private function warnIfNotApplicableForSchedule(AutomatedReport $report): void
{
if ($report->trashed()) {
$this->warn('Report is soft-deleted (deleted_at: ' . $report->getDeletedAt()?->toDateTimeString() . ').');
}
if (! $report->getStatus()) {
$this->warn('Report status is inactive — would be skipped in scheduled run.');
}
$team = $report->getTeam();
if ($team->getStatus() !== Team::STATUS_ACTIVE) {
$this->warn("Team #{$report->getTeamId()} is not active (status: {$team->getStatus()}) — would be skipped in scheduled run.");
}
if ($report->isExpired()) {
$this->warn('Report is expired (expires_at: ' . $report->getExpiresAt()?->toDateString() . ') — would be skipped in scheduled run.');
}
$now = Carbon::now();
$frequency = $report->getFrequency();
$wouldRunToday = match ($frequency) {
AutomatedReportsService::FREQUENCY_DAILY => true,
AutomatedReportsService::FREQUENCY_WEEKLY => $now->isMonday(),
AutomatedReportsService::FREQUENCY_MONTHLY => $now->day === 1,
AutomatedReportsService::FREQUENCY_QUARTERLY => $now->day === 1 && in_array($now->month, [1, 4, 7, 10], true),
default => false,
};
if (! $wouldRunToday) {
$this->warn("Report frequency is '{$frequency}' — would NOT be scheduled to run today.");
}
}
/**
* Process reports for a specific frequency.
*
* @param string $frequency
*
* @return void
*/
private function processReports(string $frequency): void
{
$this->logger->info(self::LOG_PREFIX . " Processing $frequency reports");
$reportId = $this->option('report-id');
if ($reportId !== null) {
$reports = $this->getReportById($reportId);
} else {
// Get all enabled, not deleted reports with active teams for the specified frequency
$reports = $this->reportRepository->getActiveReportsByFrequency($frequency);
}
$this->logger->info(self::LOG_PREFIX . " Found {$reports->count()} $frequency reports to process");
/** @var AutomatedReport $report */
foreach ($reports as $report) {
$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [
'reportUuid' => $report->getUuid(),
'teamId' => $report->getTeamId(),
'frequency' => $report->getFrequency(),
'type' => $report->getType(),
]);
$job = $report->isAskJiminnyReport()
? new RequestGenerateAskJiminnyReportJob($report->getUuid())
: new RequestGenerateReportJob($report->getUuid());
// $this->dispatcher->dispatch($job);
$this->dispatcher->dispatchSync($job);
}
}
}
Execute
Explain Plan
Browse Query History
View Parameters
Open Query Execution Settings…
In-Editor Results
Tx: Auto
Cancel Running Statements
Playground
jiminny
Sync Changes
Hide This Notification
Code changed:
Hide
16
13
13
Previous Highlighted Error
Next Highlighted Error
SELECT * FROM teams WHERE id = 1;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;
SELECT * FROM crm_fields WHERE id = 2234;
SELECT * FROM crm_field_values WHERE crm_field_id = 2234;
select * from crm_profiles where user_id = 143;
select * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO
select * from business_processes where crm_configuration_id = 39;
# 01941000000H669AAC, 01941000000H66JAAS
select * from record_type_field_values
where record_type_id IN (24);
select * from crm_field_values where id IN (2730);
select * from crm_configurations where id = 39;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce'; #1035
select * from users where team_id = 1; # 222 group 3
SELECT * FROM activities WHERE user_id = 222 order by id desc;
select * from sidekick_settings where team_id = 1;
select * from teams where id = 1;
select * from team_features where team_id = 1;
select * from activities where crm_configuration_id = 2
and provider = 'ms-teams' and id = 608765;
SELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';
select * from sidekick_settings where team_id = 2;
SELECT * FROM activities WHERE id = 608660;
select * from activity_summary_logs where activity_id = 608660;
select * from ai_prompts where transcription_id = 11214;
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;
# id: 608818, crm: 59628809737
SELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;
# id: 608821, crm: 59632069252
SELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,
playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,
scheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at
FROM activities a
join calendar_events ce on a.calendar_event_id = ce.id
WHERE a.id IN (608818, 608821);
select * from users where team_id = 1;
select * from team_settings where team_id = 1;
select * from crm_profiles where crm_configuration_id = 39 order by user_id;
select * from team_features where team_id = 1;
select * from users where team_id = 2;
SELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639
# Preslava N. Ivanova, grou id 3
SELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;
select * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';
select
a.id,
a.type,
a.scheduled_start_time,
a.actual_start_time,
a.created_at,
a.opportunity_id,
a.status
FROM activities a
WHERE opportunity_id = 344
and status IN ('completed', 'received', 'delivered')
and (
(a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))
;
SELECT * FROM users WHERE id = 222;
SELECT * FROM crm_profiles WHERE user_id = 222;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;
select * from group_deal_risk_types;
select * from opportunities where team_id = 1;
SELECT * FROM opportunities WHERE id = 315;
SELECT * FROM crm_field_data WHERE object_id = 315;
select * from crm_field_data where object_id = 260;
select * from generic_ai_prompts where subject_id = 315;
select * from teams; # 36, 21, 121, [EMAIL]
SELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';
# [PASSWORD_DOTS]
select * from teams where id = 1;
select * from crm_configurations where id = 39;
select * from users where team_id = 1;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 1;
# 1 - 00541000004281rAAA
# 204 - 0052g000003freeAAA
# 429 - 0052g000003qGOiAAM
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
select * from activities where type = 'softphone'
and created_at > '2024-12-11 15:24:36' order by id desc;
select * from activity_providers where team_id = 1;
select * from activity_provider_users where activity_provider_id = 328;
select * from opportunities where crm_configuration_id = 39
AND account_id = 178 AND is_closed = false
order by created_at DESC;
select * from contacts where id = 3952;
select * from accounts where id = 178;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations where id = 21;
select * from users where team_id = 36;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 36
and sa.provider = 'bullhorn';
select * from social_accounts where id = 348;
UPDATE social_accounts SET
provider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',
provider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',
expires = 1733998131,
state = 'connected'
WHERE id = 348;
# [PASSWORD_DOTS]
select * from teams where id = 31;
select * from crm_configurations where id = 18;
select * from users where team_id = 31; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 31;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 31
and sa.provider = 'close';
select * from contacts where crm_configuration_id = 18;
# [PASSWORD_DOTS] NEPTUNE [PASSWORD_DOTS]
select * from teams;
select * from users where id IN (1030, 1035, 1052);
select * from crm_configurations;
select * from users where team_id = 65; # 257
select * from team_settings where team_id = 65; # 257
select * from invitations where team_id = 65; # 257
select * from users where email = '[EMAIL]'; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 65;
select * from crm_configurations where id = 53;
select * from accounts where crm_configuration_id = 53 order by id desc;
select * from leads where crm_configuration_id = 53 order by id desc;
select * from contacts where crm_configuration_id = 53 order by id desc;
select * from opportunities where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 53 order by id desc;
select * from crm_fields where crm_configuration_id = 53 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 53 order by id desc;
select * from stages where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 13;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
and sa.provider = 'integration-app';
select * from contacts where crm_configuration_id = 13;
select * from social_accounts where sociable_id = 283;
SELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';
select * from activity_providers where team_id = 65;
SELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
;
# [PASSWORD_DOTS] STAGING [PASSWORD_DOTS]
SELECT * FROM teams;
SELECT * FROM teams WHERE id = 88;
SELECT * FROM teams WHERE id = 89;
select * from team_settings where team_id = 89;
SELECT * FROM users WHERE team_id = 89;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 89;
select * from users;
SELECT * FROM social_accounts WHERE sociable_id = 1761;
SELECT * FROM crm_configurations WHERE id = 70;
select * from accounts where crm_configuration_id = 70 order by id desc;
select * from leads where crm_configuration_id = 70 order by id desc;
select * from contacts where crm_configuration_id = 70 order by id desc;
select * from opportunities where crm_configuration_id = 70 order by id desc;
select * from crm_profiles where crm_configuration_id = 70 order by id desc;
select * from crm_fields where crm_configuration_id = 70 order by id desc;
select * from crm_field_values where crm_field_id = 3536 order by id desc;
select * from crm_layouts where crm_configuration_id = 70 order by id desc;
select * from stages where crm_configuration_id = 70 order by id desc;
select * from business_processes where crm_configuration_id = 70 order by id desc;
select * from business_process_stages where business_process_id = 34;
select * from contacts where id = 10468;
select * from crm_layouts where crm_configuration_id = 70;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;
SELECT * FROM crm_fields WHERE id IN (3533,3534,3535);
select * from activities where crm_configuration_id = 70
and (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;
SELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;
SELECT * FROM activities where crm_configuration_id = 69 ;
SELECT * FROM users WHERE email LIKE '%[EMAIL]%';
SELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;
SELECT * FROM opportunities WHERE id = 385;
select * from participants p
join activities a on p.activity_id = a.id
where a.crm_configuration_id = 70
and (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);
SELECT * FROM participants WHERE id = 1013638;
select * from teams where id = 90;
select * from users where team_id = 90;
select * from social_accounts where social_accounts.sociable_id IN (1960,1760);
SELECT * FROM crm_profiles WHERE crm_configuration_id = 71;
select * from invitations where team_id = 90;
select * from crm_configurations where id = 71;
select * from accounts where crm_configuration_id = 71 order by id desc;
select * from leads where crm_configuration_id = 71 order by id desc;
select * from contacts where crm_configuration_id = 71 order by id desc;
select * from opportunities where crm_configuration_id = 71 order by id desc;
select * from crm_profiles where crm_configuration_id = 71 order by id desc;
select * from crm_fields where crm_configuration_id = 71 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 71 order by id desc;
select * from stages where crm_configuration_id = 71 order by id desc;
select * from users order by secondary_email desc;
select u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa
join users u on sa.sociable_id = u.id
where sa.provider = 'google' and u.email LIKE 'aneliya%';
select * from failed_jobs order by id desc;
select * from users where email = '[EMAIL]' or secondary_email = '[EMAIL]';
select * from teams;
SELECT * FROM crm_profiles WHERE crm_configuration_id = 39;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;
SELECT * FROM crm_configurations WHERE id = 70;
select * from teams where id = 1;
select * from groups where team_id = 1;
select * from users where team_id = 1;
select o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o
join users u on o.user_id = u.id
join groups g on u.group_id = g.id
join role_user ru on u.id = ru.user_id
join roles r on ru.role_id = r.id
where o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';
select * from role_user where user_id = 143;
select * from roles;
select * from role_user;
select * from groups where id = 9;
select * from scope_groups where group_id = 9;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations;
SELECT * FROM social_accounts WHERE sociable_id = 121;
https://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105
https://crmsandbox.zoho.com/crm/
https://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080
https://crm.zoho.com/crm/
org3469620
SELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;
select * from users where email LIKE "%mobile_automation_%";
select * from social_accounts where sociable_id IN (2228);
select * from crm_profiles where user_id IN (2222,2223,2226,2227);
select * from teams order by id desc;
SELECT * FROM users WHERE id = 2229;
SELECT * FROM crm_profiles WHERE user_id = 2229;
select * from opportunities where crm_configuration_id = 88;
select * from crm_fields where crm_configuration_id = 88;
select * from crm_profiles where crm_configuration_id = 88;
SELECT * FROM teams WHERE id = 1;
SELECT * FROM users WHERE id = 143;
SELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;
https://app.staging.jiminny.com/ondemand?
min_duration=1
&
only_recorded=1
&
user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e
&
sequence_number=2
select * from users where team_id = 1 and email like '%stoyan%'
select * from coaching_feedbacks;
select * from teams;
SELECT * FROM users WHERE team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from users where id = 143;
SELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
select * from users where team_id = 2;
select * from activities where crm_configuration_id = 39
and activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'
AND user_id = 143
order by id desc;
# [PASSWORD_DOTS]
select * from teams where id = 142; # 2312, 126
select * from team_settings;
select * from users where team_id = 142; # 21642
SELECT * FROM social_accounts WHERE sociable_id = 21642;
SELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;
select * from crm_profiles where id IN (93);
select * from invitations;
select * from team_features where team_id = 1;
SELECT * FROM crm_configurations WHERE id = 126;
select * from accounts where crm_configuration_id = 126 order by id desc;
select * from leads where crm_configuration_id = 126 order by id desc;
select * from contacts where crm_configuration_id = 126 order by id desc;
select * from opportunities where crm_configuration_id = 126 order by id desc;
select * from crm_profiles where crm_configuration_id = 126 order by id desc;
select * from crm_fields where crm_configuration_id = 126 # 11060
# and type IN ('picklist', 'status')
# and object_type = 'task'
order by id desc;
# 5731,5732,5733
select DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;
select * from crm_layouts where crm_configuration_id = 126 order by id desc;
SELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);
select * from stages where crm_configuration_id = 126 order by id desc;
select * from business_processes where crm_configuration_id = 126 order by id desc;
select * from business_process_stages where business_process_id IN (76,75,74,73);
select * from playbooks where team_id = 142;
select * from playbook_layouts where playbook_id IN (108);
SELECT * FROM playbook_categories WHERE playbook_id IN (108);
select * from teams where id = 130;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 2
and sa.provider = 'hubspot';
SELECT * FROM activities
WHERE crm_configuration_id = 110;
select * from teams;
select * from crm_configurations;
SELECT * FROM activities WHERE id = 628773;
SELECT * FROM crm_profiles WHERE user_id = 1460;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from teams;
select ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id
join permission_role pr on pr.role_id = ru.role_id
join permissions p on p.id = pr.permission_id
where team_id = 495 and p.name IN ('dial');
select * from teams where id = 145;
select * from crm_configurations where id = 129;
select * from social_accounts where sociable_id = 2317;
SELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;
select * from teams where id = 1;
SELECT * FROM crm_layouts WHERE crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;
SELECT * FROM crm_layout_entities WHERE id = 5507;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');
select * from teams;
select * from activities where crm_configuration_id = 14;
SELECT * FROM social_accounts where provider = 'copper';
select * from activities where id = 628467;
select * from participants where activity_id = 628467;
SELECT * FROM contacts WHERE id = 3969;
SELECT * FROM accounts WHERE id = 177;
SELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;
# [PASSWORD_DOTS] BH
select * from teams where id = 36;
SELECT * FROM crm_configurations WHERE id = 21;
select * from activities where crm_configuration_id = 21 and id = 607901;
select * from activities where crm_configuration_id = 21;
select * roles;
select * from permissions;
select * from permission_role where permission_id = 226;
select * from migrations order by id desc;
# mercury
# neptune
# earth
select * from teams;
select * from teams where id = 19;
select * from teams where id = 27;
select * from users where team_id = 27;
SELECT * FROM crm_configurations WHERE id = 42;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from activities where id = 631461;
SELECT * FROM crm_field_values WHERE crm_field_id = 180;
select * from teams where id = 2;
SELECT * FROM social_accounts WHERE sociable_id = 89;
SELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273
select * from activity_summary_logs where activity_id = 634273;
select * from sidekick_settings where team_id = 2;
select * from teams; # 2, 2
SELECT * FROM crm_configurations WHERE team_id = 2; # 2
select * from team_features where team_id = 2;
select * from features;
SELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';
SELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;
select * from automated_reports order by id desc;
select * from automated_report_results order by id desc;
select * from users where team_id = 1 and id IN (7160, 3248);
select * from migrations order by id desc;
SELECT
CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,
u.email,
sa.*,
t.owner_id FROM social_accounts sa
JOIN users u on u.id = sa.sociable_id
JOIN teams t on t.id = u.team_id
WHERE u.team_id = 1 and sa.provider = 'salesforce';
select * from teams where id = 1;
select * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;
select * from groups where id = 565;
select * from playbooks where team_id = 1;
select * from playbooks where id = 175;
select * from playbook_categories where playbook_id = 175;
select * from users where team_id = 1;
select * from users where id = 7160;
select * from crm_profiles where user_id = 7160;
select * from features;
select
*
# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,
# crm_configuration_id, crm_provider_id, transcription_id, status
from activities where crm_configuration_id = 1 and type = 'conference'
# and crm_provider_id IS NOT NULL
and provider != 'uploader' and actual_start_time IS NOT NULL
ORDER by id desc;
select * from activities where id = 54747783; # 00UO400000pCzojMAC
select p.id, p.activity_type, pc.id, pc.name
FROM playbooks p
join playbook_categories pc on p.id = pc.playbook_id
where p.team_id = 1 and p.activity_type = 'event';
SELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';
SELECT * FROM crm_field_values WHERE crm_field_id = 4;
select * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id
where crm_configuration_id = 1 and pl.playbook_id = 175;
select * from teams;
SELECT r.* FROM automated_reports r
join teams t on r.team_id = t.id
WHERE r.frequency = 'daily'
and r.status = 1
AND t.status = 'active'
AND (r.expires_at >= now() OR r.expires_at IS NULL);
select * from automated_report_results where report_id IN (18, 33);
select * from automated_reports;
select * from automated_report_results where report_id IN (34);
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
NULL
|
|
10330
|
NULL
|
0
|
2026-04-14T08:32:26.521832+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776155546521_m2.jpg...
|
PhpStorm
|
faVsco.js – AutomatedReportsCommand.php
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
<?php
declare(strict_types=1);
namespace Jiminny\Console\Commands\Reports;
use Carbon\Carbon;
use Illuminate\Console\Command;
use Illuminate\Contracts\Bus\Dispatcher as BusDispatcher;
use Jiminny\Jobs\AutomatedReports\RequestGenerateAskJiminnyReportJob;
use Jiminny\Jobs\AutomatedReports\RequestGenerateReportJob;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\Team;
use Jiminny\Repositories\AutomatedReportsRepository;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Psr\Log\LoggerInterface;
class AutomatedReportsCommand extends Command
{
/**
* Log prefix for all log messages
*/
private const string LOG_PREFIX = '[automated-reports]';
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'automated-reports {--report-id= : Process a specific report by ID or UUID (bypasses frequency scheduling)}';
/**
* The console command description.
*
* @var string
*/
protected $description = 'Process automated reports based on their frequency (weekly, monthly, quarterly). Use --report-id to manually trigger a specific report by ID or UUID.';
public function __construct(
private readonly LoggerInterface $logger,
private readonly BusDispatcher $dispatcher,
private readonly AutomatedReportsRepository $reportRepository
) {
parent::__construct();
}
/**
* Execute the console command.
*
* @return int
*/
public function handle(): int
{
$this->logger->info(self::LOG_PREFIX . ' Started');
$reportId = $this->option('report-id');
if ($reportId !== null) {
return $this->processSingleReport((string) $reportId);
}
$now = Carbon::now();
$isMonday = $now->isMonday();
$isFirstDayOfMonth = $now->day === 1;
$currentMonth = $now->month;
// Check if the current month is a quarterly month (January, April, July, October)
$isQuarterlyMonth = in_array($currentMonth, [1, 4, 7, 10], true);
$this->logger->info(self::LOG_PREFIX . ' Checking conditions', [
'isMonday' => $isMonday,
'isFirstDayOfMonth' => $isFirstDayOfMonth,
'currentMonth' => $currentMonth,
'isQuarterlyMonth' => $isQuarterlyMonth,
]);
// Process daily reports
$this->processReports(AutomatedReportsService::FREQUENCY_DAILY);
// Process weekly reports on Mondays
if ($isMonday) {
$this->processReports(AutomatedReportsService::FREQUENCY_WEEKLY);
}
// Process monthly reports on the first day of the month
if ($isFirstDayOfMonth) {
$this->processReports(AutomatedReportsService::FREQUENCY_MONTHLY);
}
// Process quarterly reports on the first day of January, April, July, and October
if ($isFirstDayOfMonth && $isQuarterlyMonth) {
$this->processReports(AutomatedReportsService::FREQUENCY_QUARTERLY);
}
$this->logger->info(self::LOG_PREFIX . ' Completed');
return 0;
}
private function processSingleReport(string $reportId): int
{
$this->logger->info(self::LOG_PREFIX . ' Manual single-report mode', ['reportId' => $reportId]);
$report = is_numeric($reportId)
? AutomatedReport::withTrashed()->find((int) $reportId)
: AutomatedReport::withTrashed()->where('uuid', AutomatedReport::toOptimized($reportId))->first();
if ($report === null) {
$this->logger->error(self::LOG_PREFIX . ' Report not found', ['reportId' => $reportId]);
$this->error("Report not found: {$reportId}");
return 1;
}
$this->warnIfNotApplicableForSchedule($report);
$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [
'reportUuid' => $report->getUuid(),
'teamId' => $report->getTeamId(),
'frequency' => $report->getFrequency(),
'type' => $report->getType(),
]);
$job = $report->isAskJiminnyReport()
? new RequestGenerateAskJiminnyReportJob($report->getUuid())
: new RequestGenerateReportJob($report->getUuid());
$this->dispatcher->dispatchSync($job);
$this->logger->info(self::LOG_PREFIX . ' Completed');
return 0;
}
private function warnIfNotApplicableForSchedule(AutomatedReport $report): void
{
if ($report->trashed()) {
$this->warn('Report is soft-deleted (deleted_at: ' . $report->getDeletedAt()?->toDateTimeString() . ').');
}
if (! $report->getStatus()) {
$this->warn('Report status is inactive — would be skipped in scheduled run.');
}
$team = $report->getTeam();
if ($team->getStatus() !== Team::STATUS_ACTIVE) {
$this->warn("Team #{$report->getTeamId()} is not active (status: {$team->getStatus()}) — would be skipped in scheduled run.");
}
if ($report->isExpired()) {
$this->warn('Report is expired (expires_at: ' . $report->getExpiresAt()?->toDateString() . ') — would be skipped in scheduled run.');
}
$now = Carbon::now();
$frequency = $report->getFrequency();
$wouldRunToday = match ($frequency) {
AutomatedReportsService::FREQUENCY_DAILY => true,
AutomatedReportsService::FREQUENCY_WEEKLY => $now->isMonday(),
AutomatedReportsService::FREQUENCY_MONTHLY => $now->day === 1,
AutomatedReportsService::FREQUENCY_QUARTERLY => $now->day === 1 && in_array($now->month, [1, 4, 7, 10], true),
default => false,
};
if (! $wouldRunToday) {
$this->warn("Report frequency is '{$frequency}' — would NOT be scheduled to run today.");
}
}
/**
* Process reports for a specific frequency.
*
* @param string $frequency
*
* @return void
*/
private function processReports(string $frequency): void
{
$this->logger->info(self::LOG_PREFIX . " Processing $frequency reports");
$reportId = $this->option('report-id');
if ($reportId !== null) {
$reports = $this->getReportById($reportId);
} else {
// Get all enabled, not deleted reports with active teams for the specified frequency
$reports = $this->reportRepository->getActiveReportsByFrequency($frequency);
}
$this->logger->info(self::LOG_PREFIX . " Found {$reports->count()} $frequency reports to process");
/** @var AutomatedReport $report */
foreach ($reports as $report) {
$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [
'reportUuid' => $report->getUuid(),
'teamId' => $report->getTeamId(),
'frequency' => $report->getFrequency(),
'type' => $report->getType(),
]);
$job = $report->isAskJiminnyReport()
? new RequestGenerateAskJiminnyReportJob($report->getUuid())
: new RequestGenerateReportJob($report->getUuid());
// $this->dispatcher->dispatch($job);
$this->dispatcher->dispatchSync($job);
}
}
}
Execute
Explain Plan
Browse Query History
View Parameters
Open Query Execution Settings…
In-Editor Results
Tx: Auto
Cancel Running Statements
Playground
jiminny
Sync Changes
Hide This Notification
Code changed:
Hide
16
13
13
Previous Highlighted Error
Next Highlighted Error
SELECT * FROM teams WHERE id = 1;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;
SELECT * FROM crm_fields WHERE id = 2234;
SELECT * FROM crm_field_values WHERE crm_field_id = 2234;
select * from crm_profiles where user_id = 143;
select * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO
select * from business_processes where crm_configuration_id = 39;
# 01941000000H669AAC, 01941000000H66JAAS
select * from record_type_field_values
where record_type_id IN (24);
select * from crm_field_values where id IN (2730);
select * from crm_configurations where id = 39;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce'; #1035
select * from users where team_id = 1; # 222 group 3
SELECT * FROM activities WHERE user_id = 222 order by id desc;
select * from sidekick_settings where team_id = 1;
select * from teams where id = 1;
select * from team_features where team_id = 1;
select * from activities where crm_configuration_id = 2
and provider = 'ms-teams' and id = 608765;
SELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';
select * from sidekick_settings where team_id = 2;
SELECT * FROM activities WHERE id = 608660;
select * from activity_summary_logs where activity_id = 608660;
select * from ai_prompts where transcription_id = 11214;
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;
# id: 608818, crm: 59628809737
SELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;
# id: 608821, crm: 59632069252
SELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,
playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,
scheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at
FROM activities a
join calendar_events ce on a.calendar_event_id = ce.id
WHERE a.id IN (608818, 608821);
select * from users where team_id = 1;
select * from team_settings where team_id = 1;
select * from crm_profiles where crm_configuration_id = 39 order by user_id;
select * from team_features where team_id = 1;
select * from users where team_id = 2;
SELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639
# Preslava N. Ivanova, grou id 3
SELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;
select * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';
select
a.id,
a.type,
a.scheduled_start_time,
a.actual_start_time,
a.created_at,
a.opportunity_id,
a.status
FROM activities a
WHERE opportunity_id = 344
and status IN ('completed', 'received', 'delivered')
and (
(a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))
;
SELECT * FROM users WHERE id = 222;
SELECT * FROM crm_profiles WHERE user_id = 222;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;
select * from group_deal_risk_types;
select * from opportunities where team_id = 1;
SELECT * FROM opportunities WHERE id = 315;
SELECT * FROM crm_field_data WHERE object_id = 315;
select * from crm_field_data where object_id = 260;
select * from generic_ai_prompts where subject_id = 315;
select * from teams; # 36, 21, 121, [EMAIL]
SELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';
# [PASSWORD_DOTS]
select * from teams where id = 1;
select * from crm_configurations where id = 39;
select * from users where team_id = 1;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 1;
# 1 - 00541000004281rAAA
# 204 - 0052g000003freeAAA
# 429 - 0052g000003qGOiAAM
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
select * from activities where type = 'softphone'
and created_at > '2024-12-11 15:24:36' order by id desc;
select * from activity_providers where team_id = 1;
select * from activity_provider_users where activity_provider_id = 328;
select * from opportunities where crm_configuration_id = 39
AND account_id = 178 AND is_closed = false
order by created_at DESC;
select * from contacts where id = 3952;
select * from accounts where id = 178;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations where id = 21;
select * from users where team_id = 36;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 36
and sa.provider = 'bullhorn';
select * from social_accounts where id = 348;
UPDATE social_accounts SET
provider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',
provider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',
expires = 1733998131,
state = 'connected'
WHERE id = 348;
# [PASSWORD_DOTS]
select * from teams where id = 31;
select * from crm_configurations where id = 18;
select * from users where team_id = 31; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 31;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 31
and sa.provider = 'close';
select * from contacts where crm_configuration_id = 18;
# [PASSWORD_DOTS] NEPTUNE [PASSWORD_DOTS]
select * from teams;
select * from users where id IN (1030, 1035, 1052);
select * from crm_configurations;
select * from users where team_id = 65; # 257
select * from team_settings where team_id = 65; # 257
select * from invitations where team_id = 65; # 257
select * from users where email = '[EMAIL]'; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 65;
select * from crm_configurations where id = 53;
select * from accounts where crm_configuration_id = 53 order by id desc;
select * from leads where crm_configuration_id = 53 order by id desc;
select * from contacts where crm_configuration_id = 53 order by id desc;
select * from opportunities where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 53 order by id desc;
select * from crm_fields where crm_configuration_id = 53 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 53 order by id desc;
select * from stages where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 13;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
and sa.provider = 'integration-app';
select * from contacts where crm_configuration_id = 13;
select * from social_accounts where sociable_id = 283;
SELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';
select * from activity_providers where team_id = 65;
SELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
;
# [PASSWORD_DOTS] STAGING [PASSWORD_DOTS]
SELECT * FROM teams;
SELECT * FROM teams WHERE id = 88;
SELECT * FROM teams WHERE id = 89;
select * from team_settings where team_id = 89;
SELECT * FROM users WHERE team_id = 89;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 89;
select * from users;
SELECT * FROM social_accounts WHERE sociable_id = 1761;
SELECT * FROM crm_configurations WHERE id = 70;
select * from accounts where crm_configuration_id = 70 order by id desc;
select * from leads where crm_configuration_id = 70 order by id desc;
select * from contacts where crm_configuration_id = 70 order by id desc;
select * from opportunities where crm_configuration_id = 70 order by id desc;
select * from crm_profiles where crm_configuration_id = 70 order by id desc;
select * from crm_fields where crm_configuration_id = 70 order by id desc;
select * from crm_field_values where crm_field_id = 3536 order by id desc;
select * from crm_layouts where crm_configuration_id = 70 order by id desc;
select * from stages where crm_configuration_id = 70 order by id desc;
select * from business_processes where crm_configuration_id = 70 order by id desc;
select * from business_process_stages where business_process_id = 34;
select * from contacts where id = 10468;
select * from crm_layouts where crm_configuration_id = 70;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;
SELECT * FROM crm_fields WHERE id IN (3533,3534,3535);
select * from activities where crm_configuration_id = 70
and (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;
SELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;
SELECT * FROM activities where crm_configuration_id = 69 ;
SELECT * FROM users WHERE email LIKE '%[EMAIL]%';
SELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;
SELECT * FROM opportunities WHERE id = 385;
select * from participants p
join activities a on p.activity_id = a.id
where a.crm_configuration_id = 70
and (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);
SELECT * FROM participants WHERE id = 1013638;
select * from teams where id = 90;
select * from users where team_id = 90;
select * from social_accounts where social_accounts.sociable_id IN (1960,1760);
SELECT * FROM crm_profiles WHERE crm_configuration_id = 71;
select * from invitations where team_id = 90;
select * from crm_configurations where id = 71;
select * from accounts where crm_configuration_id = 71 order by id desc;
select * from leads where crm_configuration_id = 71 order by id desc;
select * from contacts where crm_configuration_id = 71 order by id desc;
select * from opportunities where crm_configuration_id = 71 order by id desc;
select * from crm_profiles where crm_configuration_id = 71 order by id desc;
select * from crm_fields where crm_configuration_id = 71 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 71 order by id desc;
select * from stages where crm_configuration_id = 71 order by id desc;
select * from users order by secondary_email desc;
select u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa
join users u on sa.sociable_id = u.id
where sa.provider = 'google' and u.email LIKE 'aneliya%';
select * from failed_jobs order by id desc;
select * from users where email = '[EMAIL]' or secondary_email = '[EMAIL]';
select * from teams;
SELECT * FROM crm_profiles WHERE crm_configuration_id = 39;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;
SELECT * FROM crm_configurations WHERE id = 70;
select * from teams where id = 1;
select * from groups where team_id = 1;
select * from users where team_id = 1;
select o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o
join users u on o.user_id = u.id
join groups g on u.group_id = g.id
join role_user ru on u.id = ru.user_id
join roles r on ru.role_id = r.id
where o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';
select * from role_user where user_id = 143;
select * from roles;
select * from role_user;
select * from groups where id = 9;
select * from scope_groups where group_id = 9;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations;
SELECT * FROM social_accounts WHERE sociable_id = 121;
https://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105
https://crmsandbox.zoho.com/crm/
https://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080
https://crm.zoho.com/crm/
org3469620
SELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;
select * from users where email LIKE "%mobile_automation_%";
select * from social_accounts where sociable_id IN (2228);
select * from crm_profiles where user_id IN (2222,2223,2226,2227);
select * from teams order by id desc;
SELECT * FROM users WHERE id = 2229;
SELECT * FROM crm_profiles WHERE user_id = 2229;
select * from opportunities where crm_configuration_id = 88;
select * from crm_fields where crm_configuration_id = 88;
select * from crm_profiles where crm_configuration_id = 88;
SELECT * FROM teams WHERE id = 1;
SELECT * FROM users WHERE id = 143;
SELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;
https://app.staging.jiminny.com/ondemand?
min_duration=1
&
only_recorded=1
&
user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e
&
sequence_number=2
select * from users where team_id = 1 and email like '%stoyan%'
select * from coaching_feedbacks;
select * from teams;
SELECT * FROM users WHERE team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from users where id = 143;
SELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
select * from users where team_id = 2;
select * from activities where crm_configuration_id = 39
and activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'
AND user_id = 143
order by id desc;
# [PASSWORD_DOTS]
select * from teams where id = 142; # 2312, 126
select * from team_settings;
select * from users where team_id = 142; # 21642
SELECT * FROM social_accounts WHERE sociable_id = 21642;
SELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;
select * from crm_profiles where id IN (93);
select * from invitations;
select * from team_features where team_id = 1;
SELECT * FROM crm_configurations WHERE id = 126;
select * from accounts where crm_configuration_id = 126 order by id desc;
select * from leads where crm_configuration_id = 126 order by id desc;
select * from contacts where crm_configuration_id = 126 order by id desc;
select * from opportunities where crm_configuration_id = 126 order by id desc;
select * from crm_profiles where crm_configuration_id = 126 order by id desc;
select * from crm_fields where crm_configuration_id = 126 # 11060
# and type IN ('picklist', 'status')
# and object_type = 'task'
order by id desc;
# 5731,5732,5733
select DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;
select * from crm_layouts where crm_configuration_id = 126 order by id desc;
SELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);
select * from stages where crm_configuration_id = 126 order by id desc;
select * from business_processes where crm_configuration_id = 126 order by id desc;
select * from business_process_stages where business_process_id IN (76,75,74,73);
select * from playbooks where team_id = 142;
select * from playbook_layouts where playbook_id IN (108);
SELECT * FROM playbook_categories WHERE playbook_id IN (108);
select * from teams where id = 130;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 2
and sa.provider = 'hubspot';
SELECT * FROM activities
WHERE crm_configuration_id = 110;
select * from teams;
select * from crm_configurations;
SELECT * FROM activities WHERE id = 628773;
SELECT * FROM crm_profiles WHERE user_id = 1460;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from teams;
select ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id
join permission_role pr on pr.role_id = ru.role_id
join permissions p on p.id = pr.permission_id
where team_id = 495 and p.name IN ('dial');
select * from teams where id = 145;
select * from crm_configurations where id = 129;
select * from social_accounts where sociable_id = 2317;
SELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;
select * from teams where id = 1;
SELECT * FROM crm_layouts WHERE crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;
SELECT * FROM crm_layout_entities WHERE id = 5507;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');
select * from teams;
select * from activities where crm_configuration_id = 14;
SELECT * FROM social_accounts where provider = 'copper';
select * from activities where id = 628467;
select * from participants where activity_id = 628467;
SELECT * FROM contacts WHERE id = 3969;
SELECT * FROM accounts WHERE id = 177;
SELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;
# [PASSWORD_DOTS] BH
select * from teams where id = 36;
SELECT * FROM crm_configurations WHERE id = 21;
select * from activities where crm_configuration_id = 21 and id = 607901;
select * from activities where crm_configuration_id = 21;
select * roles;
select * from permissions;
select * from permission_role where permission_id = 226;
select * from migrations order by id desc;
# mercury
# neptune
# earth
select * from teams;
select * from teams where id = 19;
select * from teams where id = 27;
select * from users where team_id = 27;
SELECT * FROM crm_configurations WHERE id = 42;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from activities where id = 631461;
SELECT * FROM crm_field_values WHERE crm_field_id = 180;
select * from teams where id = 2;
SELECT * FROM social_accounts WHERE sociable_id = 89;
SELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273
select * from activity_summary_logs where activity_id = 634273;
select * from sidekick_settings where team_id = 2;
select * from teams; # 2, 2
SELECT * FROM crm_configurations WHERE team_id = 2; # 2
select * from team_features where team_id = 2;
select * from features;
SELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';
SELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;
select * from automated_reports order by id desc;
select * from automated_report_results order by id desc;
select * from users where team_id = 1 and id IN (7160, 3248);
select * from migrations order by id desc;
SELECT
CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,
u.email,
sa.*,
t.owner_id FROM social_accounts sa
JOIN users u on u.id = sa.sociable_id
JOIN teams t on t.id = u.team_id
WHERE u.team_id = 1 and sa.provider = 'salesforce';
select * from teams where id = 1;
select * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;
select * from groups where id = 565;
select * from playbooks where team_id = 1;
select * from playbooks where id = 175;
select * from playbook_categories where playbook_id = 175;
select * from users where team_id = 1;
select * from users where id = 7160;
select * from crm_profiles where user_id = 7160;
select * from features;
select
*
# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,
# crm_configuration_id, crm_provider_id, transcription_id, status
from activities where crm_configuration_id = 1 and type = 'conference'
# and crm_provider_id IS NOT NULL
and provider != 'uploader' and actual_start_time IS NOT NULL
ORDER by id desc;
select * from activities where id = 54747783; # 00UO400000pCzojMAC
select p.id, p.activity_type, pc.id, pc.name
FROM playbooks p
join playbook_categories pc on p.id = pc.playbook_id
where p.team_id = 1 and p.activity_type = 'event';
SELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';
SELECT * FROM crm_field_values WHERE crm_field_id = 4;
select * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id
where crm_configuration_id = 1 and pl.playbook_id = 175;
select * from teams;
SELECT r.* FROM automated_reports r
join teams t on r.team_id = t.id
WHERE r.frequency = 'daily'
and r.status = 1
AND t.status = 'active'
AND (r.expires_at >= now() OR r.expires_at IS NULL);
select * from automated_report_results where report_id IN (18, 33);
select * from automated_reports;
select * from automated_report_results where report_id IN (34);
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
[{"role":"AXButton","text" [{"role":"AXButton","text":"Project: faVsco.js, menu","depth":5,"bounds":{"left":0.03046875,"top":0.017361112,"width":0.0453125,"height":0.022222223},"help_text":"~/jiminny/app","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"#11894 on JY-18909-automated-reports-ask-jiminny, menu","depth":5,"bounds":{"left":0.07578125,"top":0.017361112,"width":0.14960937,"height":0.022222223},"help_text":"Pull request #11894 exists for current branch JY-18909-automated-reports-ask-jiminny, but local branch is out of sync with remote","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Start Listening for PHP Debug Connections","depth":5,"bounds":{"left":0.76171875,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"RequestGenerateAskJiminnyReportJobTest","depth":6,"bounds":{"left":0.7796875,"top":0.017361112,"width":0.12109375,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Run 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"bounds":{"left":0.9007813,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Debug 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"bounds":{"left":0.9140625,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"More Actions","depth":6,"bounds":{"left":0.9273437,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"JetBrains AI","depth":5,"bounds":{"left":0.96015626,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Search Everywhere","depth":5,"bounds":{"left":0.9734375,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"IDE and Project Settings","depth":5,"bounds":{"left":0.9867188,"top":0.017361112,"width":0.013281226,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.049609374,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Console\\Commands\\Reports;\n\nuse Carbon\\Carbon;\nuse Illuminate\\Console\\Command;\nuse Illuminate\\Contracts\\Bus\\Dispatcher as BusDispatcher;\nuse Jiminny\\Jobs\\AutomatedReports\\RequestGenerateAskJiminnyReportJob;\nuse Jiminny\\Jobs\\AutomatedReports\\RequestGenerateReportJob;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Repositories\\AutomatedReportsRepository;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Psr\\Log\\LoggerInterface;\n\nclass AutomatedReportsCommand extends Command\n{\n /**\n * Log prefix for all log messages\n */\n private const string LOG_PREFIX = '[automated-reports]';\n\n /**\n * The name and signature of the console command.\n *\n * @var string\n */\n protected $signature = 'automated-reports {--report-id= : Process a specific report by ID or UUID (bypasses frequency scheduling)}';\n\n /**\n * The console command description.\n *\n * @var string\n */\n protected $description = 'Process automated reports based on their frequency (weekly, monthly, quarterly). Use --report-id to manually trigger a specific report by ID or UUID.';\n\n\n public function __construct(\n private readonly LoggerInterface $logger,\n private readonly BusDispatcher $dispatcher,\n private readonly AutomatedReportsRepository $reportRepository\n ) {\n parent::__construct();\n }\n\n /**\n * Execute the console command.\n *\n * @return int\n */\n public function handle(): int\n {\n $this->logger->info(self::LOG_PREFIX . ' Started');\n\n $reportId = $this->option('report-id');\n\n if ($reportId !== null) {\n return $this->processSingleReport((string) $reportId);\n }\n\n $now = Carbon::now();\n $isMonday = $now->isMonday();\n $isFirstDayOfMonth = $now->day === 1;\n $currentMonth = $now->month;\n\n // Check if the current month is a quarterly month (January, April, July, October)\n $isQuarterlyMonth = in_array($currentMonth, [1, 4, 7, 10], true);\n\n $this->logger->info(self::LOG_PREFIX . ' Checking conditions', [\n 'isMonday' => $isMonday,\n 'isFirstDayOfMonth' => $isFirstDayOfMonth,\n 'currentMonth' => $currentMonth,\n 'isQuarterlyMonth' => $isQuarterlyMonth,\n ]);\n\n // Process daily reports\n $this->processReports(AutomatedReportsService::FREQUENCY_DAILY);\n\n // Process weekly reports on Mondays\n if ($isMonday) {\n $this->processReports(AutomatedReportsService::FREQUENCY_WEEKLY);\n }\n\n // Process monthly reports on the first day of the month\n if ($isFirstDayOfMonth) {\n $this->processReports(AutomatedReportsService::FREQUENCY_MONTHLY);\n }\n\n // Process quarterly reports on the first day of January, April, July, and October\n if ($isFirstDayOfMonth && $isQuarterlyMonth) {\n $this->processReports(AutomatedReportsService::FREQUENCY_QUARTERLY);\n }\n\n $this->logger->info(self::LOG_PREFIX . ' Completed');\n\n return 0;\n }\n\n private function processSingleReport(string $reportId): int\n {\n $this->logger->info(self::LOG_PREFIX . ' Manual single-report mode', ['reportId' => $reportId]);\n\n $report = is_numeric($reportId)\n ? AutomatedReport::withTrashed()->find((int) $reportId)\n : AutomatedReport::withTrashed()->where('uuid', AutomatedReport::toOptimized($reportId))->first();\n\n if ($report === null) {\n $this->logger->error(self::LOG_PREFIX . ' Report not found', ['reportId' => $reportId]);\n $this->error(\"Report not found: {$reportId}\");\n\n return 1;\n }\n\n $this->warnIfNotApplicableForSchedule($report);\n\n $this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [\n 'reportUuid' => $report->getUuid(),\n 'teamId' => $report->getTeamId(),\n 'frequency' => $report->getFrequency(),\n 'type' => $report->getType(),\n ]);\n\n $job = $report->isAskJiminnyReport()\n ? new RequestGenerateAskJiminnyReportJob($report->getUuid())\n : new RequestGenerateReportJob($report->getUuid());\n\n $this->dispatcher->dispatchSync($job);\n\n $this->logger->info(self::LOG_PREFIX . ' Completed');\n\n return 0;\n }\n\n private function warnIfNotApplicableForSchedule(AutomatedReport $report): void\n {\n if ($report->trashed()) {\n $this->warn('Report is soft-deleted (deleted_at: ' . $report->getDeletedAt()?->toDateTimeString() . ').');\n }\n\n if (! $report->getStatus()) {\n $this->warn('Report status is inactive — would be skipped in scheduled run.');\n }\n\n $team = $report->getTeam();\n if ($team->getStatus() !== Team::STATUS_ACTIVE) {\n $this->warn(\"Team #{$report->getTeamId()} is not active (status: {$team->getStatus()}) — would be skipped in scheduled run.\");\n }\n\n if ($report->isExpired()) {\n $this->warn('Report is expired (expires_at: ' . $report->getExpiresAt()?->toDateString() . ') — would be skipped in scheduled run.');\n }\n\n $now = Carbon::now();\n $frequency = $report->getFrequency();\n $wouldRunToday = match ($frequency) {\n AutomatedReportsService::FREQUENCY_DAILY => true,\n AutomatedReportsService::FREQUENCY_WEEKLY => $now->isMonday(),\n AutomatedReportsService::FREQUENCY_MONTHLY => $now->day === 1,\n AutomatedReportsService::FREQUENCY_QUARTERLY => $now->day === 1 && in_array($now->month, [1, 4, 7, 10], true),\n default => false,\n };\n\n if (! $wouldRunToday) {\n $this->warn(\"Report frequency is '{$frequency}' — would NOT be scheduled to run today.\");\n }\n }\n\n /**\n * Process reports for a specific frequency.\n *\n * @param string $frequency\n *\n * @return void\n */\n private function processReports(string $frequency): void\n {\n $this->logger->info(self::LOG_PREFIX . \" Processing $frequency reports\");\n \n $reportId = $this->option('report-id');\n\n if ($reportId !== null) {\n $reports = $this->getReportById($reportId);\n } else {\n // Get all enabled, not deleted reports with active teams for the specified frequency\n $reports = $this->reportRepository->getActiveReportsByFrequency($frequency);\n \n }\n\n $this->logger->info(self::LOG_PREFIX . \" Found {$reports->count()} $frequency reports to process\");\n\n /** @var AutomatedReport $report */\n foreach ($reports as $report) {\n $this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [\n 'reportUuid' => $report->getUuid(),\n 'teamId' => $report->getTeamId(),\n 'frequency' => $report->getFrequency(),\n 'type' => $report->getType(),\n ]);\n\n $job = $report->isAskJiminnyReport()\n ? new RequestGenerateAskJiminnyReportJob($report->getUuid())\n : new RequestGenerateReportJob($report->getUuid());\n\n // $this->dispatcher->dispatch($job);\n $this->dispatcher->dispatchSync($job);\n }\n }\n}","depth":4,"value":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Console\\Commands\\Reports;\n\nuse Carbon\\Carbon;\nuse Illuminate\\Console\\Command;\nuse Illuminate\\Contracts\\Bus\\Dispatcher as BusDispatcher;\nuse Jiminny\\Jobs\\AutomatedReports\\RequestGenerateAskJiminnyReportJob;\nuse Jiminny\\Jobs\\AutomatedReports\\RequestGenerateReportJob;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Repositories\\AutomatedReportsRepository;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Psr\\Log\\LoggerInterface;\n\nclass AutomatedReportsCommand extends Command\n{\n /**\n * Log prefix for all log messages\n */\n private const string LOG_PREFIX = '[automated-reports]';\n\n /**\n * The name and signature of the console command.\n *\n * @var string\n */\n protected $signature = 'automated-reports {--report-id= : Process a specific report by ID or UUID (bypasses frequency scheduling)}';\n\n /**\n * The console command description.\n *\n * @var string\n */\n protected $description = 'Process automated reports based on their frequency (weekly, monthly, quarterly). Use --report-id to manually trigger a specific report by ID or UUID.';\n\n\n public function __construct(\n private readonly LoggerInterface $logger,\n private readonly BusDispatcher $dispatcher,\n private readonly AutomatedReportsRepository $reportRepository\n ) {\n parent::__construct();\n }\n\n /**\n * Execute the console command.\n *\n * @return int\n */\n public function handle(): int\n {\n $this->logger->info(self::LOG_PREFIX . ' Started');\n\n $reportId = $this->option('report-id');\n\n if ($reportId !== null) {\n return $this->processSingleReport((string) $reportId);\n }\n\n $now = Carbon::now();\n $isMonday = $now->isMonday();\n $isFirstDayOfMonth = $now->day === 1;\n $currentMonth = $now->month;\n\n // Check if the current month is a quarterly month (January, April, July, October)\n $isQuarterlyMonth = in_array($currentMonth, [1, 4, 7, 10], true);\n\n $this->logger->info(self::LOG_PREFIX . ' Checking conditions', [\n 'isMonday' => $isMonday,\n 'isFirstDayOfMonth' => $isFirstDayOfMonth,\n 'currentMonth' => $currentMonth,\n 'isQuarterlyMonth' => $isQuarterlyMonth,\n ]);\n\n // Process daily reports\n $this->processReports(AutomatedReportsService::FREQUENCY_DAILY);\n\n // Process weekly reports on Mondays\n if ($isMonday) {\n $this->processReports(AutomatedReportsService::FREQUENCY_WEEKLY);\n }\n\n // Process monthly reports on the first day of the month\n if ($isFirstDayOfMonth) {\n $this->processReports(AutomatedReportsService::FREQUENCY_MONTHLY);\n }\n\n // Process quarterly reports on the first day of January, April, July, and October\n if ($isFirstDayOfMonth && $isQuarterlyMonth) {\n $this->processReports(AutomatedReportsService::FREQUENCY_QUARTERLY);\n }\n\n $this->logger->info(self::LOG_PREFIX . ' Completed');\n\n return 0;\n }\n\n private function processSingleReport(string $reportId): int\n {\n $this->logger->info(self::LOG_PREFIX . ' Manual single-report mode', ['reportId' => $reportId]);\n\n $report = is_numeric($reportId)\n ? AutomatedReport::withTrashed()->find((int) $reportId)\n : AutomatedReport::withTrashed()->where('uuid', AutomatedReport::toOptimized($reportId))->first();\n\n if ($report === null) {\n $this->logger->error(self::LOG_PREFIX . ' Report not found', ['reportId' => $reportId]);\n $this->error(\"Report not found: {$reportId}\");\n\n return 1;\n }\n\n $this->warnIfNotApplicableForSchedule($report);\n\n $this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [\n 'reportUuid' => $report->getUuid(),\n 'teamId' => $report->getTeamId(),\n 'frequency' => $report->getFrequency(),\n 'type' => $report->getType(),\n ]);\n\n $job = $report->isAskJiminnyReport()\n ? new RequestGenerateAskJiminnyReportJob($report->getUuid())\n : new RequestGenerateReportJob($report->getUuid());\n\n $this->dispatcher->dispatchSync($job);\n\n $this->logger->info(self::LOG_PREFIX . ' Completed');\n\n return 0;\n }\n\n private function warnIfNotApplicableForSchedule(AutomatedReport $report): void\n {\n if ($report->trashed()) {\n $this->warn('Report is soft-deleted (deleted_at: ' . $report->getDeletedAt()?->toDateTimeString() . ').');\n }\n\n if (! $report->getStatus()) {\n $this->warn('Report status is inactive — would be skipped in scheduled run.');\n }\n\n $team = $report->getTeam();\n if ($team->getStatus() !== Team::STATUS_ACTIVE) {\n $this->warn(\"Team #{$report->getTeamId()} is not active (status: {$team->getStatus()}) — would be skipped in scheduled run.\");\n }\n\n if ($report->isExpired()) {\n $this->warn('Report is expired (expires_at: ' . $report->getExpiresAt()?->toDateString() . ') — would be skipped in scheduled run.');\n }\n\n $now = Carbon::now();\n $frequency = $report->getFrequency();\n $wouldRunToday = match ($frequency) {\n AutomatedReportsService::FREQUENCY_DAILY => true,\n AutomatedReportsService::FREQUENCY_WEEKLY => $now->isMonday(),\n AutomatedReportsService::FREQUENCY_MONTHLY => $now->day === 1,\n AutomatedReportsService::FREQUENCY_QUARTERLY => $now->day === 1 && in_array($now->month, [1, 4, 7, 10], true),\n default => false,\n };\n\n if (! $wouldRunToday) {\n $this->warn(\"Report frequency is '{$frequency}' — would NOT be scheduled to run today.\");\n }\n }\n\n /**\n * Process reports for a specific frequency.\n *\n * @param string $frequency\n *\n * @return void\n */\n private function processReports(string $frequency): void\n {\n $this->logger->info(self::LOG_PREFIX . \" Processing $frequency reports\");\n \n $reportId = $this->option('report-id');\n\n if ($reportId !== null) {\n $reports = $this->getReportById($reportId);\n } else {\n // Get all enabled, not deleted reports with active teams for the specified frequency\n $reports = $this->reportRepository->getActiveReportsByFrequency($frequency);\n \n }\n\n $this->logger->info(self::LOG_PREFIX . \" Found {$reports->count()} $frequency reports to process\");\n\n /** @var AutomatedReport $report */\n foreach ($reports as $report) {\n $this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [\n 'reportUuid' => $report->getUuid(),\n 'teamId' => $report->getTeamId(),\n 'frequency' => $report->getFrequency(),\n 'type' => $report->getType(),\n ]);\n\n $job = $report->isAskJiminnyReport()\n ? new RequestGenerateAskJiminnyReportJob($report->getUuid())\n : new RequestGenerateReportJob($report->getUuid());\n\n // $this->dispatcher->dispatch($job);\n $this->dispatcher->dispatchSync($job);\n }\n }\n}","role_description":"text entry area","is_enabled":true,"is_focused":true,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Execute","depth":4,"bounds":{"left":0.4828125,"top":0.12916666,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Explain Plan","depth":4,"bounds":{"left":0.49296874,"top":0.12916666,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Browse Query History","depth":4,"bounds":{"left":0.5058594,"top":0.12916666,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"View Parameters","depth":4,"bounds":{"left":0.51601565,"top":0.12916666,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Open Query Execution Settings…","depth":4,"bounds":{"left":0.52617186,"top":0.12916666,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"In-Editor Results","depth":4,"bounds":{"left":0.5390625,"top":0.12916666,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Tx: Auto","depth":4,"bounds":{"left":0.55195314,"top":0.12916666,"width":0.028515626,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Cancel Running Statements","depth":4,"bounds":{"left":0.58320314,"top":0.12916666,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Playground","depth":4,"bounds":{"left":0.5960938,"top":0.12916666,"width":0.034765624,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"jiminny","depth":4,"bounds":{"left":0.6738281,"top":0.12916666,"width":0.033203125,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.049609374,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"16","depth":4,"bounds":{"left":0.65117186,"top":0.15069444,"width":0.011328125,"height":0.013194445},"role_description":"text"},{"role":"AXStaticText","text":"13","depth":4,"bounds":{"left":0.66484374,"top":0.15069444,"width":0.011328125,"height":0.013194445},"role_description":"text"},{"role":"AXStaticText","text":"13","depth":4,"bounds":{"left":0.6785156,"top":0.15069444,"width":0.011328125,"height":0.013194445},"role_description":"text"},{"role":"AXButton","text":"Previous Highlighted Error","depth":4,"bounds":{"left":0.6917969,"top":0.14930555,"width":0.00859375,"height":0.015972223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Next Highlighted Error","depth":4,"bounds":{"left":0.70039064,"top":0.14930555,"width":0.008203125,"height":0.015972223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"SELECT * FROM teams WHERE id = 1;\n\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;\nSELECT * FROM crm_fields WHERE id = 2234;\nSELECT * FROM crm_field_values WHERE crm_field_id = 2234;\n\nselect * from crm_profiles where user_id = 143;\n\nselect * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO\nselect * from business_processes where crm_configuration_id = 39;\n# 01941000000H669AAC, 01941000000H66JAAS\n\nselect * from record_type_field_values\n where record_type_id IN (24);\n\nselect * from crm_field_values where id IN (2730);\n\nselect * from crm_configurations where id = 39;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce'; #1035\n\n\nselect * from users where team_id = 1; # 222 group 3\nSELECT * FROM activities WHERE user_id = 222 order by id desc;\nselect * from sidekick_settings where team_id = 1;\nselect * from teams where id = 1;\nselect * from team_features where team_id = 1;\n\nselect * from activities where crm_configuration_id = 2\nand provider = 'ms-teams' and id = 608765;\n\nSELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';\n\nselect * from sidekick_settings where team_id = 2;\n\nSELECT * FROM activities WHERE id = 608660;\nselect * from activity_summary_logs where activity_id = 608660;\nselect * from ai_prompts where transcription_id = 11214;\n\n# ********************************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;\n# id: 608818, crm: 59628809737\nSELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;\n# id: 608821, crm: 59632069252\nSELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,\nplaybook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,\nscheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at\nFROM activities a\njoin calendar_events ce on a.calendar_event_id = ce.id\nWHERE a.id IN (608818, 608821);\n\nselect * from users where team_id = 1;\nselect * from team_settings where team_id = 1;\nselect * from crm_profiles where crm_configuration_id = 39 order by user_id;\n\nselect * from team_features where team_id = 1;\n\nselect * from users where team_id = 2;\n\nSELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639\n# Preslava N. Ivanova, grou id 3\n\nSELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;\n\nselect * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';\n\nselect\n a.id,\n a.type,\n a.scheduled_start_time,\n a.actual_start_time,\n a.created_at,\n a.opportunity_id,\n a.status\nFROM activities a\nWHERE opportunity_id = 344\nand status IN ('completed', 'received', 'delivered')\nand (\n (a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))\n;\n\nSELECT * FROM users WHERE id = 222;\n\nSELECT * FROM crm_profiles WHERE user_id = 222;\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;\n\nselect * from group_deal_risk_types;\n\nselect * from opportunities where team_id = 1;\n\nSELECT * FROM opportunities WHERE id = 315;\nSELECT * FROM crm_field_data WHERE object_id = 315;\nselect * from crm_field_data where object_id = 260;\n\nselect * from generic_ai_prompts where subject_id = 315;\n\nselect * from teams; # 36, 21, 121, james.graham@bullhorn.jiminny.com\nSELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';\n\n# ************************************************************************************\nselect * from teams where id = 1;\nselect * from crm_configurations where id = 39;\nselect * from users where team_id = 1;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 1;\n# 1 - 00541000004281rAAA\n# 204 - 0052g000003freeAAA\n# 429 - 0052g000003qGOiAAM\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\nselect * from activities where type = 'softphone'\nand created_at > '2024-12-11 15:24:36' order by id desc;\n\nselect * from activity_providers where team_id = 1;\nselect * from activity_provider_users where activity_provider_id = 328;\n\nselect * from opportunities where crm_configuration_id = 39\nAND account_id = 178 AND is_closed = false\norder by created_at DESC;\n\nselect * from contacts where id = 3952;\nselect * from accounts where id = 178;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations where id = 21;\nselect * from users where team_id = 36;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 36;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 36\nand sa.provider = 'bullhorn';\n\nselect * from social_accounts where id = 348;\nUPDATE social_accounts SET\nprovider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',\nprovider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',\nexpires = 1733998131,\nstate = 'connected'\nWHERE id = 348;\n\n# ************************************************************************************\nselect * from teams where id = 31;\nselect * from crm_configurations where id = 18;\n\nselect * from users where team_id = 31; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 31;\n\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 31\nand sa.provider = 'close';\n\nselect * from contacts where crm_configuration_id = 18;\n\n# ********************** NEPTUNE **************************************************************\nselect * from teams;\nselect * from users where id IN (1030, 1035, 1052);\nselect * from crm_configurations;\n\nselect * from users where team_id = 65; # 257\nselect * from team_settings where team_id = 65; # 257\nselect * from invitations where team_id = 65; # 257\nselect * from users where email = 'integration-account@jiminny.com'; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 65;\n\nselect * from crm_configurations where id = 53;\nselect * from accounts where crm_configuration_id = 53 order by id desc;\nselect * from leads where crm_configuration_id = 53 order by id desc;\nselect * from contacts where crm_configuration_id = 53 order by id desc;\nselect * from opportunities where crm_configuration_id = 53 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 53 order by id desc;\nselect * from crm_fields where crm_configuration_id = 53 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 53 order by id desc;\nselect * from stages where crm_configuration_id = 53 order by id desc;\n\n\nselect * from crm_profiles where crm_configuration_id = 13;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\nand sa.provider = 'integration-app';\n\nselect * from contacts where crm_configuration_id = 13;\n\nselect * from social_accounts where sociable_id = 283;\n\nSELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';\n\nselect * from activity_providers where team_id = 65;\nSELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\n;\n\n# ***************************** STAGING ********************************************\nSELECT * FROM teams;\nSELECT * FROM teams WHERE id = 88;\nSELECT * FROM teams WHERE id = 89;\nselect * from team_settings where team_id = 89;\nSELECT * FROM users WHERE team_id = 89;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 89;\n\nselect * from users;\nSELECT * FROM social_accounts WHERE sociable_id = 1761;\nSELECT * FROM crm_configurations WHERE id = 70;\nselect * from accounts where crm_configuration_id = 70 order by id desc;\nselect * from leads where crm_configuration_id = 70 order by id desc;\nselect * from contacts where crm_configuration_id = 70 order by id desc;\nselect * from opportunities where crm_configuration_id = 70 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 70 order by id desc;\nselect * from crm_fields where crm_configuration_id = 70 order by id desc;\nselect * from crm_field_values where crm_field_id = 3536 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 70 order by id desc;\nselect * from stages where crm_configuration_id = 70 order by id desc;\nselect * from business_processes where crm_configuration_id = 70 order by id desc;\nselect * from business_process_stages where business_process_id = 34;\n\nselect * from contacts where id = 10468;\n\nselect * from crm_layouts where crm_configuration_id = 70;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;\nSELECT * FROM crm_fields WHERE id IN (3533,3534,3535);\n\nselect * from activities where crm_configuration_id = 70\nand (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;\n\nSELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;\nSELECT * FROM activities where crm_configuration_id = 69 ;\n\nSELECT * FROM users WHERE email LIKE '%jiminny_web_sa2@jiminny.com%';\nSELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;\nSELECT * FROM opportunities WHERE id = 385;\n\nselect * from participants p\njoin activities a on p.activity_id = a.id\nwhere a.crm_configuration_id = 70\nand (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);\nSELECT * FROM participants WHERE id = 1013638;\n\nselect * from teams where id = 90;\nselect * from users where team_id = 90;\nselect * from social_accounts where social_accounts.sociable_id IN (1960,1760);\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 71;\nselect * from invitations where team_id = 90;\n\nselect * from crm_configurations where id = 71;\nselect * from accounts where crm_configuration_id = 71 order by id desc;\nselect * from leads where crm_configuration_id = 71 order by id desc;\nselect * from contacts where crm_configuration_id = 71 order by id desc;\nselect * from opportunities where crm_configuration_id = 71 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 71 order by id desc;\nselect * from crm_fields where crm_configuration_id = 71 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 71 order by id desc;\nselect * from stages where crm_configuration_id = 71 order by id desc;\n\nselect * from users order by secondary_email desc;\nselect u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa\n join users u on sa.sociable_id = u.id\nwhere sa.provider = 'google' and u.email LIKE 'aneliya%';\n\nselect * from failed_jobs order by id desc;\n\nselect * from users where email = 'ben.allwright@learningpeople.co.uk' or secondary_email = 'ben.allwright@learningpeople.co.uk';\n\nselect * from teams;\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 39;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\n# ************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;\nSELECT * FROM crm_configurations WHERE id = 70;\n\nselect * from teams where id = 1;\nselect * from groups where team_id = 1;\nselect * from users where team_id = 1;\n\nselect o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o\njoin users u on o.user_id = u.id\njoin groups g on u.group_id = g.id\njoin role_user ru on u.id = ru.user_id\njoin roles r on ru.role_id = r.id\nwhere o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';\n\nselect * from role_user where user_id = 143;\nselect * from roles;\n\nselect * from role_user;\nselect * from groups where id = 9;\nselect * from scope_groups where group_id = 9;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations;\nSELECT * FROM social_accounts WHERE sociable_id = 121;\n\nhttps://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105\nhttps://crmsandbox.zoho.com/crm/\n\nhttps://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080\n https://crm.zoho.com/crm/\n org3469620\n\nSELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;\n\nselect * from users where email LIKE \"%mobile_automation_%\";\nselect * from social_accounts where sociable_id IN (2228);\nselect * from crm_profiles where user_id IN (2222,2223,2226,2227);\n\nselect * from teams order by id desc;\nSELECT * FROM users WHERE id = 2229;\nSELECT * FROM crm_profiles WHERE user_id = 2229;\nselect * from opportunities where crm_configuration_id = 88;\nselect * from crm_fields where crm_configuration_id = 88;\nselect * from crm_profiles where crm_configuration_id = 88;\n\nSELECT * FROM teams WHERE id = 1;\n\nSELECT * FROM users WHERE id = 143;\nSELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;\n\nhttps://app.staging.jiminny.com/ondemand?\n min_duration=1\n &\n only_recorded=1\n &\n user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e\n &\n sequence_number=2\n\n select * from users where team_id = 1 and email like '%stoyan%'\n\nselect * from coaching_feedbacks;\n\nselect * from teams;\nSELECT * FROM users WHERE team_id = 36;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from users where id = 143;\n\nSELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\n\nselect * from users where team_id = 2;\nselect * from activities where crm_configuration_id = 39\nand activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'\nAND user_id = 143\norder by id desc;\n\n# ************************************************************************************\nselect * from teams where id = 142; # 2312, 126\nselect * from team_settings;\nselect * from users where team_id = 142; # 21642\nSELECT * FROM social_accounts WHERE sociable_id = 21642;\nSELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;\nselect * from crm_profiles where id IN (93);\nselect * from invitations;\nselect * from team_features where team_id = 1;\n\nSELECT * FROM crm_configurations WHERE id = 126;\nselect * from accounts where crm_configuration_id = 126 order by id desc;\nselect * from leads where crm_configuration_id = 126 order by id desc;\nselect * from contacts where crm_configuration_id = 126 order by id desc;\nselect * from opportunities where crm_configuration_id = 126 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 126 order by id desc;\nselect * from crm_fields where crm_configuration_id = 126 # 11060\n# and type IN ('picklist', 'status')\n# and object_type = 'task'\norder by id desc;\n# 5731,5732,5733\nselect DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;\nselect * from crm_layouts where crm_configuration_id = 126 order by id desc;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);\nselect * from stages where crm_configuration_id = 126 order by id desc;\nselect * from business_processes where crm_configuration_id = 126 order by id desc;\nselect * from business_process_stages where business_process_id IN (76,75,74,73);\nselect * from playbooks where team_id = 142;\nselect * from playbook_layouts where playbook_id IN (108);\nSELECT * FROM playbook_categories WHERE playbook_id IN (108);\n\nselect * from teams where id = 130;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 2\nand sa.provider = 'hubspot';\n\nSELECT * FROM activities\n WHERE crm_configuration_id = 110;\n\nselect * from teams;\nselect * from crm_configurations;\n\nSELECT * FROM activities WHERE id = 628773;\nSELECT * FROM crm_profiles WHERE user_id = 1460;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from teams;\nselect ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id\njoin permission_role pr on pr.role_id = ru.role_id\n join permissions p on p.id = pr.permission_id\nwhere team_id = 495 and p.name IN ('dial');\n\nselect * from teams where id = 145;\nselect * from crm_configurations where id = 129;\nselect * from social_accounts where sociable_id = 2317;\nSELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;\n\nselect * from teams where id = 1;\nSELECT * FROM crm_layouts WHERE crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;\nSELECT * FROM crm_layout_entities WHERE id = 5507;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');\n\nselect * from teams;\nselect * from activities where crm_configuration_id = 14;\n\nSELECT * FROM social_accounts where provider = 'copper';\n\nselect * from activities where id = 628467;\nselect * from participants where activity_id = 628467;\n\nSELECT * FROM contacts WHERE id = 3969;\nSELECT * FROM accounts WHERE id = 177;\n\nSELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;\n\n# ********************* BH\nselect * from teams where id = 36;\nSELECT * FROM crm_configurations WHERE id = 21;\nselect * from activities where crm_configuration_id = 21 and id = 607901;\nselect * from activities where crm_configuration_id = 21;\n\nselect * roles;\nselect * from permissions;\nselect * from permission_role where permission_id = 226;\n\nselect * from migrations order by id desc;\n\n# mercury\n# neptune\n# earth\n\nselect * from teams;\nselect * from teams where id = 19;\nselect * from teams where id = 27;\nselect * from users where team_id = 27;\nSELECT * FROM crm_configurations WHERE id = 42;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from activities where id = 631461;\nSELECT * FROM crm_field_values WHERE crm_field_id = 180;\n\nselect * from teams where id = 2;\nSELECT * FROM social_accounts WHERE sociable_id = 89;\n\nSELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273\nselect * from activity_summary_logs where activity_id = 634273;\n\nselect * from sidekick_settings where team_id = 2;\n\nselect * from teams; # 2, 2\nSELECT * FROM crm_configurations WHERE team_id = 2; # 2\nselect * from team_features where team_id = 2;\nselect * from features;\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;\n\nselect * from automated_reports order by id desc;\nselect * from automated_report_results order by id desc;\nselect * from users where team_id = 1 and id IN (7160, 3248);\nselect * from migrations order by id desc;\n\nSELECT\n CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,\n u.email,\n sa.*,\n t.owner_id FROM social_accounts sa\nJOIN users u on u.id = sa.sociable_id\nJOIN teams t on t.id = u.team_id\nWHERE u.team_id = 1 and sa.provider = 'salesforce';\n\nselect * from teams where id = 1;\nselect * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;\nselect * from groups where id = 565;\nselect * from playbooks where team_id = 1;\nselect * from playbooks where id = 175;\nselect * from playbook_categories where playbook_id = 175;\nselect * from users where team_id = 1;\nselect * from users where id = 7160;\nselect * from crm_profiles where user_id = 7160;\nselect * from features;\nselect\n *\n# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,\n# crm_configuration_id, crm_provider_id, transcription_id, status\nfrom activities where crm_configuration_id = 1 and type = 'conference'\n# and crm_provider_id IS NOT NULL\nand provider != 'uploader' and actual_start_time IS NOT NULL\nORDER by id desc;\nselect * from activities where id = 54747783; # 00UO400000pCzojMAC\n\nselect p.id, p.activity_type, pc.id, pc.name\nFROM playbooks p\njoin playbook_categories pc on p.id = pc.playbook_id\nwhere p.team_id = 1 and p.activity_type = 'event';\n\nSELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';\nSELECT * FROM crm_field_values WHERE crm_field_id = 4;\n\nselect * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id\nwhere crm_configuration_id = 1 and pl.playbook_id = 175;\n\nselect * from teams;\nSELECT r.* FROM automated_reports r\njoin teams t on r.team_id = t.id\nWHERE r.frequency = 'daily'\n and r.status = 1\nAND t.status = 'active'\nAND (r.expires_at >= now() OR r.expires_at IS NULL);\n\nselect * from automated_report_results where report_id IN (18, 33);\n\nselect * from automated_reports;\nselect * from automated_report_results where report_id IN (34);","depth":4,"value":"SELECT * FROM teams WHERE id = 1;\n\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;\nSELECT * FROM crm_fields WHERE id = 2234;\nSELECT * FROM crm_field_values WHERE crm_field_id = 2234;\n\nselect * from crm_profiles where user_id = 143;\n\nselect * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO\nselect * from business_processes where crm_configuration_id = 39;\n# 01941000000H669AAC, 01941000000H66JAAS\n\nselect * from record_type_field_values\n where record_type_id IN (24);\n\nselect * from crm_field_values where id IN (2730);\n\nselect * from crm_configurations where id = 39;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce'; #1035\n\n\nselect * from users where team_id = 1; # 222 group 3\nSELECT * FROM activities WHERE user_id = 222 order by id desc;\nselect * from sidekick_settings where team_id = 1;\nselect * from teams where id = 1;\nselect * from team_features where team_id = 1;\n\nselect * from activities where crm_configuration_id = 2\nand provider = 'ms-teams' and id = 608765;\n\nSELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';\n\nselect * from sidekick_settings where team_id = 2;\n\nSELECT * FROM activities WHERE id = 608660;\nselect * from activity_summary_logs where activity_id = 608660;\nselect * from ai_prompts where transcription_id = 11214;\n\n# ********************************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;\n# id: 608818, crm: 59628809737\nSELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;\n# id: 608821, crm: 59632069252\nSELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,\nplaybook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,\nscheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at\nFROM activities a\njoin calendar_events ce on a.calendar_event_id = ce.id\nWHERE a.id IN (608818, 608821);\n\nselect * from users where team_id = 1;\nselect * from team_settings where team_id = 1;\nselect * from crm_profiles where crm_configuration_id = 39 order by user_id;\n\nselect * from team_features where team_id = 1;\n\nselect * from users where team_id = 2;\n\nSELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639\n# Preslava N. Ivanova, grou id 3\n\nSELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;\n\nselect * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';\n\nselect\n a.id,\n a.type,\n a.scheduled_start_time,\n a.actual_start_time,\n a.created_at,\n a.opportunity_id,\n a.status\nFROM activities a\nWHERE opportunity_id = 344\nand status IN ('completed', 'received', 'delivered')\nand (\n (a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))\n;\n\nSELECT * FROM users WHERE id = 222;\n\nSELECT * FROM crm_profiles WHERE user_id = 222;\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;\n\nselect * from group_deal_risk_types;\n\nselect * from opportunities where team_id = 1;\n\nSELECT * FROM opportunities WHERE id = 315;\nSELECT * FROM crm_field_data WHERE object_id = 315;\nselect * from crm_field_data where object_id = 260;\n\nselect * from generic_ai_prompts where subject_id = 315;\n\nselect * from teams; # 36, 21, 121, james.graham@bullhorn.jiminny.com\nSELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';\n\n# ************************************************************************************\nselect * from teams where id = 1;\nselect * from crm_configurations where id = 39;\nselect * from users where team_id = 1;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 1;\n# 1 - 00541000004281rAAA\n# 204 - 0052g000003freeAAA\n# 429 - 0052g000003qGOiAAM\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\nselect * from activities where type = 'softphone'\nand created_at > '2024-12-11 15:24:36' order by id desc;\n\nselect * from activity_providers where team_id = 1;\nselect * from activity_provider_users where activity_provider_id = 328;\n\nselect * from opportunities where crm_configuration_id = 39\nAND account_id = 178 AND is_closed = false\norder by created_at DESC;\n\nselect * from contacts where id = 3952;\nselect * from accounts where id = 178;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations where id = 21;\nselect * from users where team_id = 36;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 36;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 36\nand sa.provider = 'bullhorn';\n\nselect * from social_accounts where id = 348;\nUPDATE social_accounts SET\nprovider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',\nprovider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',\nexpires = 1733998131,\nstate = 'connected'\nWHERE id = 348;\n\n# ************************************************************************************\nselect * from teams where id = 31;\nselect * from crm_configurations where id = 18;\n\nselect * from users where team_id = 31; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 31;\n\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 31\nand sa.provider = 'close';\n\nselect * from contacts where crm_configuration_id = 18;\n\n# ********************** NEPTUNE **************************************************************\nselect * from teams;\nselect * from users where id IN (1030, 1035, 1052);\nselect * from crm_configurations;\n\nselect * from users where team_id = 65; # 257\nselect * from team_settings where team_id = 65; # 257\nselect * from invitations where team_id = 65; # 257\nselect * from users where email = 'integration-account@jiminny.com'; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 65;\n\nselect * from crm_configurations where id = 53;\nselect * from accounts where crm_configuration_id = 53 order by id desc;\nselect * from leads where crm_configuration_id = 53 order by id desc;\nselect * from contacts where crm_configuration_id = 53 order by id desc;\nselect * from opportunities where crm_configuration_id = 53 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 53 order by id desc;\nselect * from crm_fields where crm_configuration_id = 53 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 53 order by id desc;\nselect * from stages where crm_configuration_id = 53 order by id desc;\n\n\nselect * from crm_profiles where crm_configuration_id = 13;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\nand sa.provider = 'integration-app';\n\nselect * from contacts where crm_configuration_id = 13;\n\nselect * from social_accounts where sociable_id = 283;\n\nSELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';\n\nselect * from activity_providers where team_id = 65;\nSELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\n;\n\n# ***************************** STAGING ********************************************\nSELECT * FROM teams;\nSELECT * FROM teams WHERE id = 88;\nSELECT * FROM teams WHERE id = 89;\nselect * from team_settings where team_id = 89;\nSELECT * FROM users WHERE team_id = 89;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 89;\n\nselect * from users;\nSELECT * FROM social_accounts WHERE sociable_id = 1761;\nSELECT * FROM crm_configurations WHERE id = 70;\nselect * from accounts where crm_configuration_id = 70 order by id desc;\nselect * from leads where crm_configuration_id = 70 order by id desc;\nselect * from contacts where crm_configuration_id = 70 order by id desc;\nselect * from opportunities where crm_configuration_id = 70 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 70 order by id desc;\nselect * from crm_fields where crm_configuration_id = 70 order by id desc;\nselect * from crm_field_values where crm_field_id = 3536 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 70 order by id desc;\nselect * from stages where crm_configuration_id = 70 order by id desc;\nselect * from business_processes where crm_configuration_id = 70 order by id desc;\nselect * from business_process_stages where business_process_id = 34;\n\nselect * from contacts where id = 10468;\n\nselect * from crm_layouts where crm_configuration_id = 70;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;\nSELECT * FROM crm_fields WHERE id IN (3533,3534,3535);\n\nselect * from activities where crm_configuration_id = 70\nand (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;\n\nSELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;\nSELECT * FROM activities where crm_configuration_id = 69 ;\n\nSELECT * FROM users WHERE email LIKE '%jiminny_web_sa2@jiminny.com%';\nSELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;\nSELECT * FROM opportunities WHERE id = 385;\n\nselect * from participants p\njoin activities a on p.activity_id = a.id\nwhere a.crm_configuration_id = 70\nand (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);\nSELECT * FROM participants WHERE id = 1013638;\n\nselect * from teams where id = 90;\nselect * from users where team_id = 90;\nselect * from social_accounts where social_accounts.sociable_id IN (1960,1760);\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 71;\nselect * from invitations where team_id = 90;\n\nselect * from crm_configurations where id = 71;\nselect * from accounts where crm_configuration_id = 71 order by id desc;\nselect * from leads where crm_configuration_id = 71 order by id desc;\nselect * from contacts where crm_configuration_id = 71 order by id desc;\nselect * from opportunities where crm_configuration_id = 71 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 71 order by id desc;\nselect * from crm_fields where crm_configuration_id = 71 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 71 order by id desc;\nselect * from stages where crm_configuration_id = 71 order by id desc;\n\nselect * from users order by secondary_email desc;\nselect u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa\n join users u on sa.sociable_id = u.id\nwhere sa.provider = 'google' and u.email LIKE 'aneliya%';\n\nselect * from failed_jobs order by id desc;\n\nselect * from users where email = 'ben.allwright@learningpeople.co.uk' or secondary_email = 'ben.allwright@learningpeople.co.uk';\n\nselect * from teams;\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 39;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\n# ************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;\nSELECT * FROM crm_configurations WHERE id = 70;\n\nselect * from teams where id = 1;\nselect * from groups where team_id = 1;\nselect * from users where team_id = 1;\n\nselect o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o\njoin users u on o.user_id = u.id\njoin groups g on u.group_id = g.id\njoin role_user ru on u.id = ru.user_id\njoin roles r on ru.role_id = r.id\nwhere o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';\n\nselect * from role_user where user_id = 143;\nselect * from roles;\n\nselect * from role_user;\nselect * from groups where id = 9;\nselect * from scope_groups where group_id = 9;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations;\nSELECT * FROM social_accounts WHERE sociable_id = 121;\n\nhttps://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105\nhttps://crmsandbox.zoho.com/crm/\n\nhttps://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080\n https://crm.zoho.com/crm/\n org3469620\n\nSELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;\n\nselect * from users where email LIKE \"%mobile_automation_%\";\nselect * from social_accounts where sociable_id IN (2228);\nselect * from crm_profiles where user_id IN (2222,2223,2226,2227);\n\nselect * from teams order by id desc;\nSELECT * FROM users WHERE id = 2229;\nSELECT * FROM crm_profiles WHERE user_id = 2229;\nselect * from opportunities where crm_configuration_id = 88;\nselect * from crm_fields where crm_configuration_id = 88;\nselect * from crm_profiles where crm_configuration_id = 88;\n\nSELECT * FROM teams WHERE id = 1;\n\nSELECT * FROM users WHERE id = 143;\nSELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;\n\nhttps://app.staging.jiminny.com/ondemand?\n min_duration=1\n &\n only_recorded=1\n &\n user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e\n &\n sequence_number=2\n\n select * from users where team_id = 1 and email like '%stoyan%'\n\nselect * from coaching_feedbacks;\n\nselect * from teams;\nSELECT * FROM users WHERE team_id = 36;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from users where id = 143;\n\nSELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\n\nselect * from users where team_id = 2;\nselect * from activities where crm_configuration_id = 39\nand activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'\nAND user_id = 143\norder by id desc;\n\n# ************************************************************************************\nselect * from teams where id = 142; # 2312, 126\nselect * from team_settings;\nselect * from users where team_id = 142; # 21642\nSELECT * FROM social_accounts WHERE sociable_id = 21642;\nSELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;\nselect * from crm_profiles where id IN (93);\nselect * from invitations;\nselect * from team_features where team_id = 1;\n\nSELECT * FROM crm_configurations WHERE id = 126;\nselect * from accounts where crm_configuration_id = 126 order by id desc;\nselect * from leads where crm_configuration_id = 126 order by id desc;\nselect * from contacts where crm_configuration_id = 126 order by id desc;\nselect * from opportunities where crm_configuration_id = 126 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 126 order by id desc;\nselect * from crm_fields where crm_configuration_id = 126 # 11060\n# and type IN ('picklist', 'status')\n# and object_type = 'task'\norder by id desc;\n# 5731,5732,5733\nselect DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;\nselect * from crm_layouts where crm_configuration_id = 126 order by id desc;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);\nselect * from stages where crm_configuration_id = 126 order by id desc;\nselect * from business_processes where crm_configuration_id = 126 order by id desc;\nselect * from business_process_stages where business_process_id IN (76,75,74,73);\nselect * from playbooks where team_id = 142;\nselect * from playbook_layouts where playbook_id IN (108);\nSELECT * FROM playbook_categories WHERE playbook_id IN (108);\n\nselect * from teams where id = 130;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 2\nand sa.provider = 'hubspot';\n\nSELECT * FROM activities\n WHERE crm_configuration_id = 110;\n\nselect * from teams;\nselect * from crm_configurations;\n\nSELECT * FROM activities WHERE id = 628773;\nSELECT * FROM crm_profiles WHERE user_id = 1460;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from teams;\nselect ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id\njoin permission_role pr on pr.role_id = ru.role_id\n join permissions p on p.id = pr.permission_id\nwhere team_id = 495 and p.name IN ('dial');\n\nselect * from teams where id = 145;\nselect * from crm_configurations where id = 129;\nselect * from social_accounts where sociable_id = 2317;\nSELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;\n\nselect * from teams where id = 1;\nSELECT * FROM crm_layouts WHERE crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;\nSELECT * FROM crm_layout_entities WHERE id = 5507;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');\n\nselect * from teams;\nselect * from activities where crm_configuration_id = 14;\n\nSELECT * FROM social_accounts where provider = 'copper';\n\nselect * from activities where id = 628467;\nselect * from participants where activity_id = 628467;\n\nSELECT * FROM contacts WHERE id = 3969;\nSELECT * FROM accounts WHERE id = 177;\n\nSELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;\n\n# ********************* BH\nselect * from teams where id = 36;\nSELECT * FROM crm_configurations WHERE id = 21;\nselect * from activities where crm_configuration_id = 21 and id = 607901;\nselect * from activities where crm_configuration_id = 21;\n\nselect * roles;\nselect * from permissions;\nselect * from permission_role where permission_id = 226;\n\nselect * from migrations order by id desc;\n\n# mercury\n# neptune\n# earth\n\nselect * from teams;\nselect * from teams where id = 19;\nselect * from teams where id = 27;\nselect * from users where team_id = 27;\nSELECT * FROM crm_configurations WHERE id = 42;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from activities where id = 631461;\nSELECT * FROM crm_field_values WHERE crm_field_id = 180;\n\nselect * from teams where id = 2;\nSELECT * FROM social_accounts WHERE sociable_id = 89;\n\nSELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273\nselect * from activity_summary_logs where activity_id = 634273;\n\nselect * from sidekick_settings where team_id = 2;\n\nselect * from teams; # 2, 2\nSELECT * FROM crm_configurations WHERE team_id = 2; # 2\nselect * from team_features where team_id = 2;\nselect * from features;\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;\n\nselect * from automated_reports order by id desc;\nselect * from automated_report_results order by id desc;\nselect * from users where team_id = 1 and id IN (7160, 3248);\nselect * from migrations order by id desc;\n\nSELECT\n CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,\n u.email,\n sa.*,\n t.owner_id FROM social_accounts sa\nJOIN users u on u.id = sa.sociable_id\nJOIN teams t on t.id = u.team_id\nWHERE u.team_id = 1 and sa.provider = 'salesforce';\n\nselect * from teams where id = 1;\nselect * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;\nselect * from groups where id = 565;\nselect * from playbooks where team_id = 1;\nselect * from playbooks where id = 175;\nselect * from playbook_categories where playbook_id = 175;\nselect * from users where team_id = 1;\nselect * from users where id = 7160;\nselect * from crm_profiles where user_id = 7160;\nselect * from features;\nselect\n *\n# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,\n# crm_configuration_id, crm_provider_id, transcription_id, status\nfrom activities where crm_configuration_id = 1 and type = 'conference'\n# and crm_provider_id IS NOT NULL\nand provider != 'uploader' and actual_start_time IS NOT NULL\nORDER by id desc;\nselect * from activities where id = 54747783; # 00UO400000pCzojMAC\n\nselect p.id, p.activity_type, pc.id, pc.name\nFROM playbooks p\njoin playbook_categories pc on p.id = pc.playbook_id\nwhere p.team_id = 1 and p.activity_type = 'event';\n\nSELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';\nSELECT * FROM crm_field_values WHERE crm_field_id = 4;\n\nselect * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id\nwhere crm_configuration_id = 1 and pl.playbook_id = 175;\n\nselect * from teams;\nSELECT r.* FROM automated_reports r\njoin teams t on r.team_id = t.id\nWHERE r.frequency = 'daily'\n and r.status = 1\nAND t.status = 'active'\nAND (r.expires_at >= now() OR r.expires_at IS NULL);\n\nselect * from automated_report_results where report_id IN (18, 33);\n\nselect * from automated_reports;\nselect * from automated_report_results where report_id IN (34);","role_description":"text entry area","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Project","depth":3,"role_description":"text"},{"role":"AXButton","text":"Project","depth":3,"bounds":{"left":0.0140625,"top":0.041666668,"width":0.028515626,"height":0.021527778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"New File or Directory…","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Expand Selected","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Collapse All","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Options","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false}]...
|
-1978360131630512558
|
6686649039917036621
|
idle
|
accessibility
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
<?php
declare(strict_types=1);
namespace Jiminny\Console\Commands\Reports;
use Carbon\Carbon;
use Illuminate\Console\Command;
use Illuminate\Contracts\Bus\Dispatcher as BusDispatcher;
use Jiminny\Jobs\AutomatedReports\RequestGenerateAskJiminnyReportJob;
use Jiminny\Jobs\AutomatedReports\RequestGenerateReportJob;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\Team;
use Jiminny\Repositories\AutomatedReportsRepository;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Psr\Log\LoggerInterface;
class AutomatedReportsCommand extends Command
{
/**
* Log prefix for all log messages
*/
private const string LOG_PREFIX = '[automated-reports]';
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'automated-reports {--report-id= : Process a specific report by ID or UUID (bypasses frequency scheduling)}';
/**
* The console command description.
*
* @var string
*/
protected $description = 'Process automated reports based on their frequency (weekly, monthly, quarterly). Use --report-id to manually trigger a specific report by ID or UUID.';
public function __construct(
private readonly LoggerInterface $logger,
private readonly BusDispatcher $dispatcher,
private readonly AutomatedReportsRepository $reportRepository
) {
parent::__construct();
}
/**
* Execute the console command.
*
* @return int
*/
public function handle(): int
{
$this->logger->info(self::LOG_PREFIX . ' Started');
$reportId = $this->option('report-id');
if ($reportId !== null) {
return $this->processSingleReport((string) $reportId);
}
$now = Carbon::now();
$isMonday = $now->isMonday();
$isFirstDayOfMonth = $now->day === 1;
$currentMonth = $now->month;
// Check if the current month is a quarterly month (January, April, July, October)
$isQuarterlyMonth = in_array($currentMonth, [1, 4, 7, 10], true);
$this->logger->info(self::LOG_PREFIX . ' Checking conditions', [
'isMonday' => $isMonday,
'isFirstDayOfMonth' => $isFirstDayOfMonth,
'currentMonth' => $currentMonth,
'isQuarterlyMonth' => $isQuarterlyMonth,
]);
// Process daily reports
$this->processReports(AutomatedReportsService::FREQUENCY_DAILY);
// Process weekly reports on Mondays
if ($isMonday) {
$this->processReports(AutomatedReportsService::FREQUENCY_WEEKLY);
}
// Process monthly reports on the first day of the month
if ($isFirstDayOfMonth) {
$this->processReports(AutomatedReportsService::FREQUENCY_MONTHLY);
}
// Process quarterly reports on the first day of January, April, July, and October
if ($isFirstDayOfMonth && $isQuarterlyMonth) {
$this->processReports(AutomatedReportsService::FREQUENCY_QUARTERLY);
}
$this->logger->info(self::LOG_PREFIX . ' Completed');
return 0;
}
private function processSingleReport(string $reportId): int
{
$this->logger->info(self::LOG_PREFIX . ' Manual single-report mode', ['reportId' => $reportId]);
$report = is_numeric($reportId)
? AutomatedReport::withTrashed()->find((int) $reportId)
: AutomatedReport::withTrashed()->where('uuid', AutomatedReport::toOptimized($reportId))->first();
if ($report === null) {
$this->logger->error(self::LOG_PREFIX . ' Report not found', ['reportId' => $reportId]);
$this->error("Report not found: {$reportId}");
return 1;
}
$this->warnIfNotApplicableForSchedule($report);
$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [
'reportUuid' => $report->getUuid(),
'teamId' => $report->getTeamId(),
'frequency' => $report->getFrequency(),
'type' => $report->getType(),
]);
$job = $report->isAskJiminnyReport()
? new RequestGenerateAskJiminnyReportJob($report->getUuid())
: new RequestGenerateReportJob($report->getUuid());
$this->dispatcher->dispatchSync($job);
$this->logger->info(self::LOG_PREFIX . ' Completed');
return 0;
}
private function warnIfNotApplicableForSchedule(AutomatedReport $report): void
{
if ($report->trashed()) {
$this->warn('Report is soft-deleted (deleted_at: ' . $report->getDeletedAt()?->toDateTimeString() . ').');
}
if (! $report->getStatus()) {
$this->warn('Report status is inactive — would be skipped in scheduled run.');
}
$team = $report->getTeam();
if ($team->getStatus() !== Team::STATUS_ACTIVE) {
$this->warn("Team #{$report->getTeamId()} is not active (status: {$team->getStatus()}) — would be skipped in scheduled run.");
}
if ($report->isExpired()) {
$this->warn('Report is expired (expires_at: ' . $report->getExpiresAt()?->toDateString() . ') — would be skipped in scheduled run.');
}
$now = Carbon::now();
$frequency = $report->getFrequency();
$wouldRunToday = match ($frequency) {
AutomatedReportsService::FREQUENCY_DAILY => true,
AutomatedReportsService::FREQUENCY_WEEKLY => $now->isMonday(),
AutomatedReportsService::FREQUENCY_MONTHLY => $now->day === 1,
AutomatedReportsService::FREQUENCY_QUARTERLY => $now->day === 1 && in_array($now->month, [1, 4, 7, 10], true),
default => false,
};
if (! $wouldRunToday) {
$this->warn("Report frequency is '{$frequency}' — would NOT be scheduled to run today.");
}
}
/**
* Process reports for a specific frequency.
*
* @param string $frequency
*
* @return void
*/
private function processReports(string $frequency): void
{
$this->logger->info(self::LOG_PREFIX . " Processing $frequency reports");
$reportId = $this->option('report-id');
if ($reportId !== null) {
$reports = $this->getReportById($reportId);
} else {
// Get all enabled, not deleted reports with active teams for the specified frequency
$reports = $this->reportRepository->getActiveReportsByFrequency($frequency);
}
$this->logger->info(self::LOG_PREFIX . " Found {$reports->count()} $frequency reports to process");
/** @var AutomatedReport $report */
foreach ($reports as $report) {
$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [
'reportUuid' => $report->getUuid(),
'teamId' => $report->getTeamId(),
'frequency' => $report->getFrequency(),
'type' => $report->getType(),
]);
$job = $report->isAskJiminnyReport()
? new RequestGenerateAskJiminnyReportJob($report->getUuid())
: new RequestGenerateReportJob($report->getUuid());
// $this->dispatcher->dispatch($job);
$this->dispatcher->dispatchSync($job);
}
}
}
Execute
Explain Plan
Browse Query History
View Parameters
Open Query Execution Settings…
In-Editor Results
Tx: Auto
Cancel Running Statements
Playground
jiminny
Sync Changes
Hide This Notification
Code changed:
Hide
16
13
13
Previous Highlighted Error
Next Highlighted Error
SELECT * FROM teams WHERE id = 1;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;
SELECT * FROM crm_fields WHERE id = 2234;
SELECT * FROM crm_field_values WHERE crm_field_id = 2234;
select * from crm_profiles where user_id = 143;
select * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO
select * from business_processes where crm_configuration_id = 39;
# 01941000000H669AAC, 01941000000H66JAAS
select * from record_type_field_values
where record_type_id IN (24);
select * from crm_field_values where id IN (2730);
select * from crm_configurations where id = 39;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce'; #1035
select * from users where team_id = 1; # 222 group 3
SELECT * FROM activities WHERE user_id = 222 order by id desc;
select * from sidekick_settings where team_id = 1;
select * from teams where id = 1;
select * from team_features where team_id = 1;
select * from activities where crm_configuration_id = 2
and provider = 'ms-teams' and id = 608765;
SELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';
select * from sidekick_settings where team_id = 2;
SELECT * FROM activities WHERE id = 608660;
select * from activity_summary_logs where activity_id = 608660;
select * from ai_prompts where transcription_id = 11214;
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;
# id: 608818, crm: 59628809737
SELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;
# id: 608821, crm: 59632069252
SELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,
playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,
scheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at
FROM activities a
join calendar_events ce on a.calendar_event_id = ce.id
WHERE a.id IN (608818, 608821);
select * from users where team_id = 1;
select * from team_settings where team_id = 1;
select * from crm_profiles where crm_configuration_id = 39 order by user_id;
select * from team_features where team_id = 1;
select * from users where team_id = 2;
SELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639
# Preslava N. Ivanova, grou id 3
SELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;
select * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';
select
a.id,
a.type,
a.scheduled_start_time,
a.actual_start_time,
a.created_at,
a.opportunity_id,
a.status
FROM activities a
WHERE opportunity_id = 344
and status IN ('completed', 'received', 'delivered')
and (
(a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))
;
SELECT * FROM users WHERE id = 222;
SELECT * FROM crm_profiles WHERE user_id = 222;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;
select * from group_deal_risk_types;
select * from opportunities where team_id = 1;
SELECT * FROM opportunities WHERE id = 315;
SELECT * FROM crm_field_data WHERE object_id = 315;
select * from crm_field_data where object_id = 260;
select * from generic_ai_prompts where subject_id = 315;
select * from teams; # 36, 21, 121, [EMAIL]
SELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';
# [PASSWORD_DOTS]
select * from teams where id = 1;
select * from crm_configurations where id = 39;
select * from users where team_id = 1;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 1;
# 1 - 00541000004281rAAA
# 204 - 0052g000003freeAAA
# 429 - 0052g000003qGOiAAM
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
select * from activities where type = 'softphone'
and created_at > '2024-12-11 15:24:36' order by id desc;
select * from activity_providers where team_id = 1;
select * from activity_provider_users where activity_provider_id = 328;
select * from opportunities where crm_configuration_id = 39
AND account_id = 178 AND is_closed = false
order by created_at DESC;
select * from contacts where id = 3952;
select * from accounts where id = 178;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations where id = 21;
select * from users where team_id = 36;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 36
and sa.provider = 'bullhorn';
select * from social_accounts where id = 348;
UPDATE social_accounts SET
provider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',
provider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',
expires = 1733998131,
state = 'connected'
WHERE id = 348;
# [PASSWORD_DOTS]
select * from teams where id = 31;
select * from crm_configurations where id = 18;
select * from users where team_id = 31; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 31;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 31
and sa.provider = 'close';
select * from contacts where crm_configuration_id = 18;
# [PASSWORD_DOTS] NEPTUNE [PASSWORD_DOTS]
select * from teams;
select * from users where id IN (1030, 1035, 1052);
select * from crm_configurations;
select * from users where team_id = 65; # 257
select * from team_settings where team_id = 65; # 257
select * from invitations where team_id = 65; # 257
select * from users where email = '[EMAIL]'; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 65;
select * from crm_configurations where id = 53;
select * from accounts where crm_configuration_id = 53 order by id desc;
select * from leads where crm_configuration_id = 53 order by id desc;
select * from contacts where crm_configuration_id = 53 order by id desc;
select * from opportunities where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 53 order by id desc;
select * from crm_fields where crm_configuration_id = 53 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 53 order by id desc;
select * from stages where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 13;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
and sa.provider = 'integration-app';
select * from contacts where crm_configuration_id = 13;
select * from social_accounts where sociable_id = 283;
SELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';
select * from activity_providers where team_id = 65;
SELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
;
# [PASSWORD_DOTS] STAGING [PASSWORD_DOTS]
SELECT * FROM teams;
SELECT * FROM teams WHERE id = 88;
SELECT * FROM teams WHERE id = 89;
select * from team_settings where team_id = 89;
SELECT * FROM users WHERE team_id = 89;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 89;
select * from users;
SELECT * FROM social_accounts WHERE sociable_id = 1761;
SELECT * FROM crm_configurations WHERE id = 70;
select * from accounts where crm_configuration_id = 70 order by id desc;
select * from leads where crm_configuration_id = 70 order by id desc;
select * from contacts where crm_configuration_id = 70 order by id desc;
select * from opportunities where crm_configuration_id = 70 order by id desc;
select * from crm_profiles where crm_configuration_id = 70 order by id desc;
select * from crm_fields where crm_configuration_id = 70 order by id desc;
select * from crm_field_values where crm_field_id = 3536 order by id desc;
select * from crm_layouts where crm_configuration_id = 70 order by id desc;
select * from stages where crm_configuration_id = 70 order by id desc;
select * from business_processes where crm_configuration_id = 70 order by id desc;
select * from business_process_stages where business_process_id = 34;
select * from contacts where id = 10468;
select * from crm_layouts where crm_configuration_id = 70;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;
SELECT * FROM crm_fields WHERE id IN (3533,3534,3535);
select * from activities where crm_configuration_id = 70
and (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;
SELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;
SELECT * FROM activities where crm_configuration_id = 69 ;
SELECT * FROM users WHERE email LIKE '%[EMAIL]%';
SELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;
SELECT * FROM opportunities WHERE id = 385;
select * from participants p
join activities a on p.activity_id = a.id
where a.crm_configuration_id = 70
and (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);
SELECT * FROM participants WHERE id = 1013638;
select * from teams where id = 90;
select * from users where team_id = 90;
select * from social_accounts where social_accounts.sociable_id IN (1960,1760);
SELECT * FROM crm_profiles WHERE crm_configuration_id = 71;
select * from invitations where team_id = 90;
select * from crm_configurations where id = 71;
select * from accounts where crm_configuration_id = 71 order by id desc;
select * from leads where crm_configuration_id = 71 order by id desc;
select * from contacts where crm_configuration_id = 71 order by id desc;
select * from opportunities where crm_configuration_id = 71 order by id desc;
select * from crm_profiles where crm_configuration_id = 71 order by id desc;
select * from crm_fields where crm_configuration_id = 71 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 71 order by id desc;
select * from stages where crm_configuration_id = 71 order by id desc;
select * from users order by secondary_email desc;
select u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa
join users u on sa.sociable_id = u.id
where sa.provider = 'google' and u.email LIKE 'aneliya%';
select * from failed_jobs order by id desc;
select * from users where email = '[EMAIL]' or secondary_email = '[EMAIL]';
select * from teams;
SELECT * FROM crm_profiles WHERE crm_configuration_id = 39;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;
SELECT * FROM crm_configurations WHERE id = 70;
select * from teams where id = 1;
select * from groups where team_id = 1;
select * from users where team_id = 1;
select o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o
join users u on o.user_id = u.id
join groups g on u.group_id = g.id
join role_user ru on u.id = ru.user_id
join roles r on ru.role_id = r.id
where o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';
select * from role_user where user_id = 143;
select * from roles;
select * from role_user;
select * from groups where id = 9;
select * from scope_groups where group_id = 9;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations;
SELECT * FROM social_accounts WHERE sociable_id = 121;
https://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105
https://crmsandbox.zoho.com/crm/
https://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080
https://crm.zoho.com/crm/
org3469620
SELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;
select * from users where email LIKE "%mobile_automation_%";
select * from social_accounts where sociable_id IN (2228);
select * from crm_profiles where user_id IN (2222,2223,2226,2227);
select * from teams order by id desc;
SELECT * FROM users WHERE id = 2229;
SELECT * FROM crm_profiles WHERE user_id = 2229;
select * from opportunities where crm_configuration_id = 88;
select * from crm_fields where crm_configuration_id = 88;
select * from crm_profiles where crm_configuration_id = 88;
SELECT * FROM teams WHERE id = 1;
SELECT * FROM users WHERE id = 143;
SELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;
https://app.staging.jiminny.com/ondemand?
min_duration=1
&
only_recorded=1
&
user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e
&
sequence_number=2
select * from users where team_id = 1 and email like '%stoyan%'
select * from coaching_feedbacks;
select * from teams;
SELECT * FROM users WHERE team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from users where id = 143;
SELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
select * from users where team_id = 2;
select * from activities where crm_configuration_id = 39
and activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'
AND user_id = 143
order by id desc;
# [PASSWORD_DOTS]
select * from teams where id = 142; # 2312, 126
select * from team_settings;
select * from users where team_id = 142; # 21642
SELECT * FROM social_accounts WHERE sociable_id = 21642;
SELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;
select * from crm_profiles where id IN (93);
select * from invitations;
select * from team_features where team_id = 1;
SELECT * FROM crm_configurations WHERE id = 126;
select * from accounts where crm_configuration_id = 126 order by id desc;
select * from leads where crm_configuration_id = 126 order by id desc;
select * from contacts where crm_configuration_id = 126 order by id desc;
select * from opportunities where crm_configuration_id = 126 order by id desc;
select * from crm_profiles where crm_configuration_id = 126 order by id desc;
select * from crm_fields where crm_configuration_id = 126 # 11060
# and type IN ('picklist', 'status')
# and object_type = 'task'
order by id desc;
# 5731,5732,5733
select DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;
select * from crm_layouts where crm_configuration_id = 126 order by id desc;
SELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);
select * from stages where crm_configuration_id = 126 order by id desc;
select * from business_processes where crm_configuration_id = 126 order by id desc;
select * from business_process_stages where business_process_id IN (76,75,74,73);
select * from playbooks where team_id = 142;
select * from playbook_layouts where playbook_id IN (108);
SELECT * FROM playbook_categories WHERE playbook_id IN (108);
select * from teams where id = 130;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 2
and sa.provider = 'hubspot';
SELECT * FROM activities
WHERE crm_configuration_id = 110;
select * from teams;
select * from crm_configurations;
SELECT * FROM activities WHERE id = 628773;
SELECT * FROM crm_profiles WHERE user_id = 1460;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from teams;
select ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id
join permission_role pr on pr.role_id = ru.role_id
join permissions p on p.id = pr.permission_id
where team_id = 495 and p.name IN ('dial');
select * from teams where id = 145;
select * from crm_configurations where id = 129;
select * from social_accounts where sociable_id = 2317;
SELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;
select * from teams where id = 1;
SELECT * FROM crm_layouts WHERE crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;
SELECT * FROM crm_layout_entities WHERE id = 5507;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');
select * from teams;
select * from activities where crm_configuration_id = 14;
SELECT * FROM social_accounts where provider = 'copper';
select * from activities where id = 628467;
select * from participants where activity_id = 628467;
SELECT * FROM contacts WHERE id = 3969;
SELECT * FROM accounts WHERE id = 177;
SELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;
# [PASSWORD_DOTS] BH
select * from teams where id = 36;
SELECT * FROM crm_configurations WHERE id = 21;
select * from activities where crm_configuration_id = 21 and id = 607901;
select * from activities where crm_configuration_id = 21;
select * roles;
select * from permissions;
select * from permission_role where permission_id = 226;
select * from migrations order by id desc;
# mercury
# neptune
# earth
select * from teams;
select * from teams where id = 19;
select * from teams where id = 27;
select * from users where team_id = 27;
SELECT * FROM crm_configurations WHERE id = 42;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from activities where id = 631461;
SELECT * FROM crm_field_values WHERE crm_field_id = 180;
select * from teams where id = 2;
SELECT * FROM social_accounts WHERE sociable_id = 89;
SELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273
select * from activity_summary_logs where activity_id = 634273;
select * from sidekick_settings where team_id = 2;
select * from teams; # 2, 2
SELECT * FROM crm_configurations WHERE team_id = 2; # 2
select * from team_features where team_id = 2;
select * from features;
SELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';
SELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;
select * from automated_reports order by id desc;
select * from automated_report_results order by id desc;
select * from users where team_id = 1 and id IN (7160, 3248);
select * from migrations order by id desc;
SELECT
CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,
u.email,
sa.*,
t.owner_id FROM social_accounts sa
JOIN users u on u.id = sa.sociable_id
JOIN teams t on t.id = u.team_id
WHERE u.team_id = 1 and sa.provider = 'salesforce';
select * from teams where id = 1;
select * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;
select * from groups where id = 565;
select * from playbooks where team_id = 1;
select * from playbooks where id = 175;
select * from playbook_categories where playbook_id = 175;
select * from users where team_id = 1;
select * from users where id = 7160;
select * from crm_profiles where user_id = 7160;
select * from features;
select
*
# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,
# crm_configuration_id, crm_provider_id, transcription_id, status
from activities where crm_configuration_id = 1 and type = 'conference'
# and crm_provider_id IS NOT NULL
and provider != 'uploader' and actual_start_time IS NOT NULL
ORDER by id desc;
select * from activities where id = 54747783; # 00UO400000pCzojMAC
select p.id, p.activity_type, pc.id, pc.name
FROM playbooks p
join playbook_categories pc on p.id = pc.playbook_id
where p.team_id = 1 and p.activity_type = 'event';
SELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';
SELECT * FROM crm_field_values WHERE crm_field_id = 4;
select * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id
where crm_configuration_id = 1 and pl.playbook_id = 175;
select * from teams;
SELECT r.* FROM automated_reports r
join teams t on r.team_id = t.id
WHERE r.frequency = 'daily'
and r.status = 1
AND t.status = 'active'
AND (r.expires_at >= now() OR r.expires_at IS NULL);
select * from automated_report_results where report_id IN (18, 33);
select * from automated_reports;
select * from automated_report_results where report_id IN (34);
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
NULL
|
|
10331
|
204
|
0
|
2026-04-14T08:32:36.474262+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776155556474_m1.jpg...
|
PhpStorm
|
faVsco.js – AutomatedReportsCommand.php
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
<?php
declare(strict_types=1);
namespace Jiminny\Console\Commands\Reports;
use Carbon\Carbon;
use Illuminate\Console\Command;
use Illuminate\Contracts\Bus\Dispatcher as BusDispatcher;
use Jiminny\Jobs\AutomatedReports\RequestGenerateAskJiminnyReportJob;
use Jiminny\Jobs\AutomatedReports\RequestGenerateReportJob;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\Team;
use Jiminny\Repositories\AutomatedReportsRepository;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Psr\Log\LoggerInterface;
class AutomatedReportsCommand extends Command
{
/**
* Log prefix for all log messages
*/
private const string LOG_PREFIX = '[automated-reports]';
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'automated-reports {--report-id= : Process a specific report by ID or UUID (bypasses frequency scheduling)}';
/**
* The console command description.
*
* @var string
*/
protected $description = 'Process automated reports based on their frequency (weekly, monthly, quarterly). Use --report-id to manually trigger a specific report by ID or UUID.';
public function __construct(
private readonly LoggerInterface $logger,
private readonly BusDispatcher $dispatcher,
private readonly AutomatedReportsRepository $reportRepository
) {
parent::__construct();
}
/**
* Execute the console command.
*
* @return int
*/
public function handle(): int
{
$this->logger->info(self::LOG_PREFIX . ' Started');
$reportId = $this->option('report-id');
if ($reportId !== null) {
return $this->processSingleReport((string) $reportId);
}
$now = Carbon::now();
$isMonday = $now->isMonday();
$isFirstDayOfMonth = $now->day === 1;
$currentMonth = $now->month;
// Check if the current month is a quarterly month (January, April, July, October)
$isQuarterlyMonth = in_array($currentMonth, [1, 4, 7, 10], true);
$this->logger->info(self::LOG_PREFIX . ' Checking conditions', [
'isMonday' => $isMonday,
'isFirstDayOfMonth' => $isFirstDayOfMonth,
'currentMonth' => $currentMonth,
'isQuarterlyMonth' => $isQuarterlyMonth,
]);
// Process daily reports
$this->processReports(AutomatedReportsService::FREQUENCY_DAILY);
// Process weekly reports on Mondays
if ($isMonday) {
$this->processReports(AutomatedReportsService::FREQUENCY_WEEKLY);
}
// Process monthly reports on the first day of the month
if ($isFirstDayOfMonth) {
$this->processReports(AutomatedReportsService::FREQUENCY_MONTHLY);
}
// Process quarterly reports on the first day of January, April, July, and October
if ($isFirstDayOfMonth && $isQuarterlyMonth) {
$this->processReports(AutomatedReportsService::FREQUENCY_QUARTERLY);
}
$this->logger->info(self::LOG_PREFIX . ' Completed');
return 0;
}
private function processSingleReport(string $reportId): int
{
$this->logger->info(self::LOG_PREFIX . ' Manual single-report mode', ['reportId' => $reportId]);
$report = is_numeric($reportId)
? AutomatedReport::withTrashed()->find((int) $reportId)
: AutomatedReport::withTrashed()->where('uuid', AutomatedReport::toOptimized($reportId))->first();
if ($report === null) {
$this->logger->error(self::LOG_PREFIX . ' Report not found', ['reportId' => $reportId]);
$this->error("Report not found: {$reportId}");
return 1;
}
$this->warnIfNotApplicableForSchedule($report);
$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [
'reportUuid' => $report->getUuid(),
'teamId' => $report->getTeamId(),
'frequency' => $report->getFrequency(),
'type' => $report->getType(),
]);
$job = $report->isAskJiminnyReport()
? new RequestGenerateAskJiminnyReportJob($report->getUuid())
: new RequestGenerateReportJob($report->getUuid());
$this->dispatcher->dispatchSync($job);
$this->logger->info(self::LOG_PREFIX . ' Completed');
return 0;
}
private function warnIfNotApplicableForSchedule(AutomatedReport $report): void
{
if ($report->trashed()) {
$this->warn('Report is soft-deleted (deleted_at: ' . $report->getDeletedAt()?->toDateTimeString() . ').');
}
if (! $report->getStatus()) {
$this->warn('Report status is inactive — would be skipped in scheduled run.');
}
$team = $report->getTeam();
if ($team->getStatus() !== Team::STATUS_ACTIVE) {
$this->warn("Team #{$report->getTeamId()} is not active (status: {$team->getStatus()}) — would be skipped in scheduled run.");
}
if ($report->isExpired()) {
$this->warn('Report is expired (expires_at: ' . $report->getExpiresAt()?->toDateString() . ') — would be skipped in scheduled run.');
}
$now = Carbon::now();
$frequency = $report->getFrequency();
$wouldRunToday = match ($frequency) {
AutomatedReportsService::FREQUENCY_DAILY => true,
AutomatedReportsService::FREQUENCY_WEEKLY => $now->isMonday(),
AutomatedReportsService::FREQUENCY_MONTHLY => $now->day === 1,
AutomatedReportsService::FREQUENCY_QUARTERLY => $now->day === 1 && in_array($now->month, [1, 4, 7, 10], true),
default => false,
};
if (! $wouldRunToday) {
$this->warn("Report frequency is '{$frequency}' — would NOT be scheduled to run today.");
}
}
/**
* Process reports for a specific frequency.
*
* @param string $frequency
*
* @return void
*/
private function processReports(string $frequency): void
{
$this->logger->info(self::LOG_PREFIX . " Processing $frequency reports");
$reportId = $this->option('report-id');
if ($reportId !== null) {
$reports = $this->getReportById($reportId);
} else {
// Get all enabled, not deleted reports with active teams for the specified frequency
$reports = $this->reportRepository->getActiveReportsByFrequency($frequency);
}
$this->logger->info(self::LOG_PREFIX . " Found {$reports->count()} $frequency reports to process");
/** @var AutomatedReport $report */
foreach ($reports as $report) {
$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [
'reportUuid' => $report->getUuid(),
'teamId' => $report->getTeamId(),
'frequency' => $report->getFrequency(),
'type' => $report->getType(),
]);
$job = $report->isAskJiminnyReport()
? new RequestGenerateAskJiminnyReportJob($report->getUuid())
: new RequestGenerateReportJob($report->getUuid());
// $this->dispatcher->dispatch($job);
$this->dispatcher->dispatchSync($job);
}
}
}
Execute
Explain Plan
Browse Query History
View Parameters
Open Query Execution Settings…
In-Editor Results
Tx: Auto
Cancel Running Statements
Playground
jiminny
Sync Changes
Hide This Notification
Code changed:
Hide
16
13
13
Previous Highlighted Error
Next Highlighted Error
SELECT * FROM teams WHERE id = 1;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;
SELECT * FROM crm_fields WHERE id = 2234;
SELECT * FROM crm_field_values WHERE crm_field_id = 2234;
select * from crm_profiles where user_id = 143;
select * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO
select * from business_processes where crm_configuration_id = 39;
# 01941000000H669AAC, 01941000000H66JAAS
select * from record_type_field_values
where record_type_id IN (24);
select * from crm_field_values where id IN (2730);
select * from crm_configurations where id = 39;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce'; #1035
select * from users where team_id = 1; # 222 group 3
SELECT * FROM activities WHERE user_id = 222 order by id desc;
select * from sidekick_settings where team_id = 1;
select * from teams where id = 1;
select * from team_features where team_id = 1;
select * from activities where crm_configuration_id = 2
and provider = 'ms-teams' and id = 608765;
SELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';
select * from sidekick_settings where team_id = 2;
SELECT * FROM activities WHERE id = 608660;
select * from activity_summary_logs where activity_id = 608660;
select * from ai_prompts where transcription_id = 11214;
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;
# id: 608818, crm: 59628809737
SELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;
# id: 608821, crm: 59632069252
SELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,
playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,
scheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at
FROM activities a
join calendar_events ce on a.calendar_event_id = ce.id
WHERE a.id IN (608818, 608821);
select * from users where team_id = 1;
select * from team_settings where team_id = 1;
select * from crm_profiles where crm_configuration_id = 39 order by user_id;
select * from team_features where team_id = 1;
select * from users where team_id = 2;
SELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639
# Preslava N. Ivanova, grou id 3
SELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;
select * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';
select
a.id,
a.type,
a.scheduled_start_time,
a.actual_start_time,
a.created_at,
a.opportunity_id,
a.status
FROM activities a
WHERE opportunity_id = 344
and status IN ('completed', 'received', 'delivered')
and (
(a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))
;
SELECT * FROM users WHERE id = 222;
SELECT * FROM crm_profiles WHERE user_id = 222;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;
select * from group_deal_risk_types;
select * from opportunities where team_id = 1;
SELECT * FROM opportunities WHERE id = 315;
SELECT * FROM crm_field_data WHERE object_id = 315;
select * from crm_field_data where object_id = 260;
select * from generic_ai_prompts where subject_id = 315;
select * from teams; # 36, 21, 121, [EMAIL]
SELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';
# [PASSWORD_DOTS]
select * from teams where id = 1;
select * from crm_configurations where id = 39;
select * from users where team_id = 1;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 1;
# 1 - 00541000004281rAAA
# 204 - 0052g000003freeAAA
# 429 - 0052g000003qGOiAAM
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
select * from activities where type = 'softphone'
and created_at > '2024-12-11 15:24:36' order by id desc;
select * from activity_providers where team_id = 1;
select * from activity_provider_users where activity_provider_id = 328;
select * from opportunities where crm_configuration_id = 39
AND account_id = 178 AND is_closed = false
order by created_at DESC;
select * from contacts where id = 3952;
select * from accounts where id = 178;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations where id = 21;
select * from users where team_id = 36;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 36
and sa.provider = 'bullhorn';
select * from social_accounts where id = 348;
UPDATE social_accounts SET
provider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',
provider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',
expires = 1733998131,
state = 'connected'
WHERE id = 348;
# [PASSWORD_DOTS]
select * from teams where id = 31;
select * from crm_configurations where id = 18;
select * from users where team_id = 31; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 31;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 31
and sa.provider = 'close';
select * from contacts where crm_configuration_id = 18;
# [PASSWORD_DOTS] NEPTUNE [PASSWORD_DOTS]
select * from teams;
select * from users where id IN (1030, 1035, 1052);
select * from crm_configurations;
select * from users where team_id = 65; # 257
select * from team_settings where team_id = 65; # 257
select * from invitations where team_id = 65; # 257
select * from users where email = '[EMAIL]'; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 65;
select * from crm_configurations where id = 53;
select * from accounts where crm_configuration_id = 53 order by id desc;
select * from leads where crm_configuration_id = 53 order by id desc;
select * from contacts where crm_configuration_id = 53 order by id desc;
select * from opportunities where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 53 order by id desc;
select * from crm_fields where crm_configuration_id = 53 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 53 order by id desc;
select * from stages where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 13;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
and sa.provider = 'integration-app';
select * from contacts where crm_configuration_id = 13;
select * from social_accounts where sociable_id = 283;
SELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';
select * from activity_providers where team_id = 65;
SELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
;
# [PASSWORD_DOTS] STAGING [PASSWORD_DOTS]
SELECT * FROM teams;
SELECT * FROM teams WHERE id = 88;
SELECT * FROM teams WHERE id = 89;
select * from team_settings where team_id = 89;
SELECT * FROM users WHERE team_id = 89;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 89;
select * from users;
SELECT * FROM social_accounts WHERE sociable_id = 1761;
SELECT * FROM crm_configurations WHERE id = 70;
select * from accounts where crm_configuration_id = 70 order by id desc;
select * from leads where crm_configuration_id = 70 order by id desc;
select * from contacts where crm_configuration_id = 70 order by id desc;
select * from opportunities where crm_configuration_id = 70 order by id desc;
select * from crm_profiles where crm_configuration_id = 70 order by id desc;
select * from crm_fields where crm_configuration_id = 70 order by id desc;
select * from crm_field_values where crm_field_id = 3536 order by id desc;
select * from crm_layouts where crm_configuration_id = 70 order by id desc;
select * from stages where crm_configuration_id = 70 order by id desc;
select * from business_processes where crm_configuration_id = 70 order by id desc;
select * from business_process_stages where business_process_id = 34;
select * from contacts where id = 10468;
select * from crm_layouts where crm_configuration_id = 70;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;
SELECT * FROM crm_fields WHERE id IN (3533,3534,3535);
select * from activities where crm_configuration_id = 70
and (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;
SELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;
SELECT * FROM activities where crm_configuration_id = 69 ;
SELECT * FROM users WHERE email LIKE '%[EMAIL]%';
SELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;
SELECT * FROM opportunities WHERE id = 385;
select * from participants p
join activities a on p.activity_id = a.id
where a.crm_configuration_id = 70
and (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);
SELECT * FROM participants WHERE id = 1013638;
select * from teams where id = 90;
select * from users where team_id = 90;
select * from social_accounts where social_accounts.sociable_id IN (1960,1760);
SELECT * FROM crm_profiles WHERE crm_configuration_id = 71;
select * from invitations where team_id = 90;
select * from crm_configurations where id = 71;
select * from accounts where crm_configuration_id = 71 order by id desc;
select * from leads where crm_configuration_id = 71 order by id desc;
select * from contacts where crm_configuration_id = 71 order by id desc;
select * from opportunities where crm_configuration_id = 71 order by id desc;
select * from crm_profiles where crm_configuration_id = 71 order by id desc;
select * from crm_fields where crm_configuration_id = 71 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 71 order by id desc;
select * from stages where crm_configuration_id = 71 order by id desc;
select * from users order by secondary_email desc;
select u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa
join users u on sa.sociable_id = u.id
where sa.provider = 'google' and u.email LIKE 'aneliya%';
select * from failed_jobs order by id desc;
select * from users where email = '[EMAIL]' or secondary_email = '[EMAIL]';
select * from teams;
SELECT * FROM crm_profiles WHERE crm_configuration_id = 39;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;
SELECT * FROM crm_configurations WHERE id = 70;
select * from teams where id = 1;
select * from groups where team_id = 1;
select * from users where team_id = 1;
select o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o
join users u on o.user_id = u.id
join groups g on u.group_id = g.id
join role_user ru on u.id = ru.user_id
join roles r on ru.role_id = r.id
where o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';
select * from role_user where user_id = 143;
select * from roles;
select * from role_user;
select * from groups where id = 9;
select * from scope_groups where group_id = 9;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations;
SELECT * FROM social_accounts WHERE sociable_id = 121;
https://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105
https://crmsandbox.zoho.com/crm/
https://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080
https://crm.zoho.com/crm/
org3469620
SELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;
select * from users where email LIKE "%mobile_automation_%";
select * from social_accounts where sociable_id IN (2228);
select * from crm_profiles where user_id IN (2222,2223,2226,2227);
select * from teams order by id desc;
SELECT * FROM users WHERE id = 2229;
SELECT * FROM crm_profiles WHERE user_id = 2229;
select * from opportunities where crm_configuration_id = 88;
select * from crm_fields where crm_configuration_id = 88;
select * from crm_profiles where crm_configuration_id = 88;
SELECT * FROM teams WHERE id = 1;
SELECT * FROM users WHERE id = 143;
SELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;
https://app.staging.jiminny.com/ondemand?
min_duration=1
&
only_recorded=1
&
user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e
&
sequence_number=2
select * from users where team_id = 1 and email like '%stoyan%'
select * from coaching_feedbacks;
select * from teams;
SELECT * FROM users WHERE team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from users where id = 143;
SELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
select * from users where team_id = 2;
select * from activities where crm_configuration_id = 39
and activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'
AND user_id = 143
order by id desc;
# [PASSWORD_DOTS]
select * from teams where id = 142; # 2312, 126
select * from team_settings;
select * from users where team_id = 142; # 21642
SELECT * FROM social_accounts WHERE sociable_id = 21642;
SELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;
select * from crm_profiles where id IN (93);
select * from invitations;
select * from team_features where team_id = 1;
SELECT * FROM crm_configurations WHERE id = 126;
select * from accounts where crm_configuration_id = 126 order by id desc;
select * from leads where crm_configuration_id = 126 order by id desc;
select * from contacts where crm_configuration_id = 126 order by id desc;
select * from opportunities where crm_configuration_id = 126 order by id desc;
select * from crm_profiles where crm_configuration_id = 126 order by id desc;
select * from crm_fields where crm_configuration_id = 126 # 11060
# and type IN ('picklist', 'status')
# and object_type = 'task'
order by id desc;
# 5731,5732,5733
select DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;
select * from crm_layouts where crm_configuration_id = 126 order by id desc;
SELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);
select * from stages where crm_configuration_id = 126 order by id desc;
select * from business_processes where crm_configuration_id = 126 order by id desc;
select * from business_process_stages where business_process_id IN (76,75,74,73);
select * from playbooks where team_id = 142;
select * from playbook_layouts where playbook_id IN (108);
SELECT * FROM playbook_categories WHERE playbook_id IN (108);
select * from teams where id = 130;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 2
and sa.provider = 'hubspot';
SELECT * FROM activities
WHERE crm_configuration_id = 110;
select * from teams;
select * from crm_configurations;
SELECT * FROM activities WHERE id = 628773;
SELECT * FROM crm_profiles WHERE user_id = 1460;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from teams;
select ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id
join permission_role pr on pr.role_id = ru.role_id
join permissions p on p.id = pr.permission_id
where team_id = 495 and p.name IN ('dial');
select * from teams where id = 145;
select * from crm_configurations where id = 129;
select * from social_accounts where sociable_id = 2317;
SELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;
select * from teams where id = 1;
SELECT * FROM crm_layouts WHERE crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;
SELECT * FROM crm_layout_entities WHERE id = 5507;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');
select * from teams;
select * from activities where crm_configuration_id = 14;
SELECT * FROM social_accounts where provider = 'copper';
select * from activities where id = 628467;
select * from participants where activity_id = 628467;
SELECT * FROM contacts WHERE id = 3969;
SELECT * FROM accounts WHERE id = 177;
SELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;
# [PASSWORD_DOTS] BH
select * from teams where id = 36;
SELECT * FROM crm_configurations WHERE id = 21;
select * from activities where crm_configuration_id = 21 and id = 607901;
select * from activities where crm_configuration_id = 21;
select * roles;
select * from permissions;
select * from permission_role where permission_id = 226;
select * from migrations order by id desc;
# mercury
# neptune
# earth
select * from teams;
select * from teams where id = 19;
select * from teams where id = 27;
select * from users where team_id = 27;
SELECT * FROM crm_configurations WHERE id = 42;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from activities where id = 631461;
SELECT * FROM crm_field_values WHERE crm_field_id = 180;
select * from teams where id = 2;
SELECT * FROM social_accounts WHERE sociable_id = 89;
SELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273
select * from activity_summary_logs where activity_id = 634273;
select * from sidekick_settings where team_id = 2;
select * from teams; # 2, 2
SELECT * FROM crm_configurations WHERE team_id = 2; # 2
select * from team_features where team_id = 2;
select * from features;
SELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';
SELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;
select * from automated_reports order by id desc;
select * from automated_report_results order by id desc;
select * from users where team_id = 1 and id IN (7160, 3248);
select * from migrations order by id desc;
SELECT
CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,
u.email,
sa.*,
t.owner_id FROM social_accounts sa
JOIN users u on u.id = sa.sociable_id
JOIN teams t on t.id = u.team_id
WHERE u.team_id = 1 and sa.provider = 'salesforce';
select * from teams where id = 1;
select * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;
select * from groups where id = 565;
select * from playbooks where team_id = 1;
select * from playbooks where id = 175;
select * from playbook_categories where playbook_id = 175;
select * from users where team_id = 1;
select * from users where id = 7160;
select * from crm_profiles where user_id = 7160;
select * from features;
select
*
# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,
# crm_configuration_id, crm_provider_id, transcription_id, status
from activities where crm_configuration_id = 1 and type = 'conference'
# and crm_provider_id IS NOT NULL
and provider != 'uploader' and actual_start_time IS NOT NULL
ORDER by id desc;
select * from activities where id = 54747783; # 00UO400000pCzojMAC
select p.id, p.activity_type, pc.id, pc.name
FROM playbooks p
join playbook_categories pc on p.id = pc.playbook_id
where p.team_id = 1 and p.activity_type = 'event';
SELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';
SELECT * FROM crm_field_values WHERE crm_field_id = 4;
select * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id
where crm_configuration_id = 1 and pl.playbook_id = 175;
select * from teams;
SELECT r.* FROM automated_reports r
join teams t on r.team_id = t.id
WHERE r.frequency = 'daily'
and r.status = 1
AND t.status = 'active'
AND (r.expires_at >= now() OR r.expires_at IS NULL);
select * from automated_report_results where report_id IN (18, 33);
select * from automated_reports;
select * from automated_report_results where report_id IN (34);
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
[{"role":"AXButton","text" [{"role":"AXButton","text":"Project: faVsco.js, menu","depth":5,"help_text":"~/jiminny/app","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"#11894 on JY-18909-automated-reports-ask-jiminny, menu","depth":5,"help_text":"Pull request #11894 exists for current branch JY-18909-automated-reports-ask-jiminny, but local branch is out of sync with remote","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Start Listening for PHP Debug Connections","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"RequestGenerateAskJiminnyReportJobTest","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Run 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Debug 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"More Actions","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"JetBrains AI","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Search Everywhere","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"IDE and Project Settings","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.088194445,"height":0.027777778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Console\\Commands\\Reports;\n\nuse Carbon\\Carbon;\nuse Illuminate\\Console\\Command;\nuse Illuminate\\Contracts\\Bus\\Dispatcher as BusDispatcher;\nuse Jiminny\\Jobs\\AutomatedReports\\RequestGenerateAskJiminnyReportJob;\nuse Jiminny\\Jobs\\AutomatedReports\\RequestGenerateReportJob;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Repositories\\AutomatedReportsRepository;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Psr\\Log\\LoggerInterface;\n\nclass AutomatedReportsCommand extends Command\n{\n /**\n * Log prefix for all log messages\n */\n private const string LOG_PREFIX = '[automated-reports]';\n\n /**\n * The name and signature of the console command.\n *\n * @var string\n */\n protected $signature = 'automated-reports {--report-id= : Process a specific report by ID or UUID (bypasses frequency scheduling)}';\n\n /**\n * The console command description.\n *\n * @var string\n */\n protected $description = 'Process automated reports based on their frequency (weekly, monthly, quarterly). Use --report-id to manually trigger a specific report by ID or UUID.';\n\n\n public function __construct(\n private readonly LoggerInterface $logger,\n private readonly BusDispatcher $dispatcher,\n private readonly AutomatedReportsRepository $reportRepository\n ) {\n parent::__construct();\n }\n\n /**\n * Execute the console command.\n *\n * @return int\n */\n public function handle(): int\n {\n $this->logger->info(self::LOG_PREFIX . ' Started');\n\n $reportId = $this->option('report-id');\n\n if ($reportId !== null) {\n return $this->processSingleReport((string) $reportId);\n }\n\n $now = Carbon::now();\n $isMonday = $now->isMonday();\n $isFirstDayOfMonth = $now->day === 1;\n $currentMonth = $now->month;\n\n // Check if the current month is a quarterly month (January, April, July, October)\n $isQuarterlyMonth = in_array($currentMonth, [1, 4, 7, 10], true);\n\n $this->logger->info(self::LOG_PREFIX . ' Checking conditions', [\n 'isMonday' => $isMonday,\n 'isFirstDayOfMonth' => $isFirstDayOfMonth,\n 'currentMonth' => $currentMonth,\n 'isQuarterlyMonth' => $isQuarterlyMonth,\n ]);\n\n // Process daily reports\n $this->processReports(AutomatedReportsService::FREQUENCY_DAILY);\n\n // Process weekly reports on Mondays\n if ($isMonday) {\n $this->processReports(AutomatedReportsService::FREQUENCY_WEEKLY);\n }\n\n // Process monthly reports on the first day of the month\n if ($isFirstDayOfMonth) {\n $this->processReports(AutomatedReportsService::FREQUENCY_MONTHLY);\n }\n\n // Process quarterly reports on the first day of January, April, July, and October\n if ($isFirstDayOfMonth && $isQuarterlyMonth) {\n $this->processReports(AutomatedReportsService::FREQUENCY_QUARTERLY);\n }\n\n $this->logger->info(self::LOG_PREFIX . ' Completed');\n\n return 0;\n }\n\n private function processSingleReport(string $reportId): int\n {\n $this->logger->info(self::LOG_PREFIX . ' Manual single-report mode', ['reportId' => $reportId]);\n\n $report = is_numeric($reportId)\n ? AutomatedReport::withTrashed()->find((int) $reportId)\n : AutomatedReport::withTrashed()->where('uuid', AutomatedReport::toOptimized($reportId))->first();\n\n if ($report === null) {\n $this->logger->error(self::LOG_PREFIX . ' Report not found', ['reportId' => $reportId]);\n $this->error(\"Report not found: {$reportId}\");\n\n return 1;\n }\n\n $this->warnIfNotApplicableForSchedule($report);\n\n $this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [\n 'reportUuid' => $report->getUuid(),\n 'teamId' => $report->getTeamId(),\n 'frequency' => $report->getFrequency(),\n 'type' => $report->getType(),\n ]);\n\n $job = $report->isAskJiminnyReport()\n ? new RequestGenerateAskJiminnyReportJob($report->getUuid())\n : new RequestGenerateReportJob($report->getUuid());\n\n $this->dispatcher->dispatchSync($job);\n\n $this->logger->info(self::LOG_PREFIX . ' Completed');\n\n return 0;\n }\n\n private function warnIfNotApplicableForSchedule(AutomatedReport $report): void\n {\n if ($report->trashed()) {\n $this->warn('Report is soft-deleted (deleted_at: ' . $report->getDeletedAt()?->toDateTimeString() . ').');\n }\n\n if (! $report->getStatus()) {\n $this->warn('Report status is inactive — would be skipped in scheduled run.');\n }\n\n $team = $report->getTeam();\n if ($team->getStatus() !== Team::STATUS_ACTIVE) {\n $this->warn(\"Team #{$report->getTeamId()} is not active (status: {$team->getStatus()}) — would be skipped in scheduled run.\");\n }\n\n if ($report->isExpired()) {\n $this->warn('Report is expired (expires_at: ' . $report->getExpiresAt()?->toDateString() . ') — would be skipped in scheduled run.');\n }\n\n $now = Carbon::now();\n $frequency = $report->getFrequency();\n $wouldRunToday = match ($frequency) {\n AutomatedReportsService::FREQUENCY_DAILY => true,\n AutomatedReportsService::FREQUENCY_WEEKLY => $now->isMonday(),\n AutomatedReportsService::FREQUENCY_MONTHLY => $now->day === 1,\n AutomatedReportsService::FREQUENCY_QUARTERLY => $now->day === 1 && in_array($now->month, [1, 4, 7, 10], true),\n default => false,\n };\n\n if (! $wouldRunToday) {\n $this->warn(\"Report frequency is '{$frequency}' — would NOT be scheduled to run today.\");\n }\n }\n\n /**\n * Process reports for a specific frequency.\n *\n * @param string $frequency\n *\n * @return void\n */\n private function processReports(string $frequency): void\n {\n $this->logger->info(self::LOG_PREFIX . \" Processing $frequency reports\");\n \n $reportId = $this->option('report-id');\n\n if ($reportId !== null) {\n $reports = $this->getReportById($reportId);\n } else {\n // Get all enabled, not deleted reports with active teams for the specified frequency\n $reports = $this->reportRepository->getActiveReportsByFrequency($frequency);\n \n }\n\n $this->logger->info(self::LOG_PREFIX . \" Found {$reports->count()} $frequency reports to process\");\n\n /** @var AutomatedReport $report */\n foreach ($reports as $report) {\n $this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [\n 'reportUuid' => $report->getUuid(),\n 'teamId' => $report->getTeamId(),\n 'frequency' => $report->getFrequency(),\n 'type' => $report->getType(),\n ]);\n\n $job = $report->isAskJiminnyReport()\n ? new RequestGenerateAskJiminnyReportJob($report->getUuid())\n : new RequestGenerateReportJob($report->getUuid());\n\n // $this->dispatcher->dispatch($job);\n $this->dispatcher->dispatchSync($job);\n }\n }\n}","depth":4,"value":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Console\\Commands\\Reports;\n\nuse Carbon\\Carbon;\nuse Illuminate\\Console\\Command;\nuse Illuminate\\Contracts\\Bus\\Dispatcher as BusDispatcher;\nuse Jiminny\\Jobs\\AutomatedReports\\RequestGenerateAskJiminnyReportJob;\nuse Jiminny\\Jobs\\AutomatedReports\\RequestGenerateReportJob;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Repositories\\AutomatedReportsRepository;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Psr\\Log\\LoggerInterface;\n\nclass AutomatedReportsCommand extends Command\n{\n /**\n * Log prefix for all log messages\n */\n private const string LOG_PREFIX = '[automated-reports]';\n\n /**\n * The name and signature of the console command.\n *\n * @var string\n */\n protected $signature = 'automated-reports {--report-id= : Process a specific report by ID or UUID (bypasses frequency scheduling)}';\n\n /**\n * The console command description.\n *\n * @var string\n */\n protected $description = 'Process automated reports based on their frequency (weekly, monthly, quarterly). Use --report-id to manually trigger a specific report by ID or UUID.';\n\n\n public function __construct(\n private readonly LoggerInterface $logger,\n private readonly BusDispatcher $dispatcher,\n private readonly AutomatedReportsRepository $reportRepository\n ) {\n parent::__construct();\n }\n\n /**\n * Execute the console command.\n *\n * @return int\n */\n public function handle(): int\n {\n $this->logger->info(self::LOG_PREFIX . ' Started');\n\n $reportId = $this->option('report-id');\n\n if ($reportId !== null) {\n return $this->processSingleReport((string) $reportId);\n }\n\n $now = Carbon::now();\n $isMonday = $now->isMonday();\n $isFirstDayOfMonth = $now->day === 1;\n $currentMonth = $now->month;\n\n // Check if the current month is a quarterly month (January, April, July, October)\n $isQuarterlyMonth = in_array($currentMonth, [1, 4, 7, 10], true);\n\n $this->logger->info(self::LOG_PREFIX . ' Checking conditions', [\n 'isMonday' => $isMonday,\n 'isFirstDayOfMonth' => $isFirstDayOfMonth,\n 'currentMonth' => $currentMonth,\n 'isQuarterlyMonth' => $isQuarterlyMonth,\n ]);\n\n // Process daily reports\n $this->processReports(AutomatedReportsService::FREQUENCY_DAILY);\n\n // Process weekly reports on Mondays\n if ($isMonday) {\n $this->processReports(AutomatedReportsService::FREQUENCY_WEEKLY);\n }\n\n // Process monthly reports on the first day of the month\n if ($isFirstDayOfMonth) {\n $this->processReports(AutomatedReportsService::FREQUENCY_MONTHLY);\n }\n\n // Process quarterly reports on the first day of January, April, July, and October\n if ($isFirstDayOfMonth && $isQuarterlyMonth) {\n $this->processReports(AutomatedReportsService::FREQUENCY_QUARTERLY);\n }\n\n $this->logger->info(self::LOG_PREFIX . ' Completed');\n\n return 0;\n }\n\n private function processSingleReport(string $reportId): int\n {\n $this->logger->info(self::LOG_PREFIX . ' Manual single-report mode', ['reportId' => $reportId]);\n\n $report = is_numeric($reportId)\n ? AutomatedReport::withTrashed()->find((int) $reportId)\n : AutomatedReport::withTrashed()->where('uuid', AutomatedReport::toOptimized($reportId))->first();\n\n if ($report === null) {\n $this->logger->error(self::LOG_PREFIX . ' Report not found', ['reportId' => $reportId]);\n $this->error(\"Report not found: {$reportId}\");\n\n return 1;\n }\n\n $this->warnIfNotApplicableForSchedule($report);\n\n $this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [\n 'reportUuid' => $report->getUuid(),\n 'teamId' => $report->getTeamId(),\n 'frequency' => $report->getFrequency(),\n 'type' => $report->getType(),\n ]);\n\n $job = $report->isAskJiminnyReport()\n ? new RequestGenerateAskJiminnyReportJob($report->getUuid())\n : new RequestGenerateReportJob($report->getUuid());\n\n $this->dispatcher->dispatchSync($job);\n\n $this->logger->info(self::LOG_PREFIX . ' Completed');\n\n return 0;\n }\n\n private function warnIfNotApplicableForSchedule(AutomatedReport $report): void\n {\n if ($report->trashed()) {\n $this->warn('Report is soft-deleted (deleted_at: ' . $report->getDeletedAt()?->toDateTimeString() . ').');\n }\n\n if (! $report->getStatus()) {\n $this->warn('Report status is inactive — would be skipped in scheduled run.');\n }\n\n $team = $report->getTeam();\n if ($team->getStatus() !== Team::STATUS_ACTIVE) {\n $this->warn(\"Team #{$report->getTeamId()} is not active (status: {$team->getStatus()}) — would be skipped in scheduled run.\");\n }\n\n if ($report->isExpired()) {\n $this->warn('Report is expired (expires_at: ' . $report->getExpiresAt()?->toDateString() . ') — would be skipped in scheduled run.');\n }\n\n $now = Carbon::now();\n $frequency = $report->getFrequency();\n $wouldRunToday = match ($frequency) {\n AutomatedReportsService::FREQUENCY_DAILY => true,\n AutomatedReportsService::FREQUENCY_WEEKLY => $now->isMonday(),\n AutomatedReportsService::FREQUENCY_MONTHLY => $now->day === 1,\n AutomatedReportsService::FREQUENCY_QUARTERLY => $now->day === 1 && in_array($now->month, [1, 4, 7, 10], true),\n default => false,\n };\n\n if (! $wouldRunToday) {\n $this->warn(\"Report frequency is '{$frequency}' — would NOT be scheduled to run today.\");\n }\n }\n\n /**\n * Process reports for a specific frequency.\n *\n * @param string $frequency\n *\n * @return void\n */\n private function processReports(string $frequency): void\n {\n $this->logger->info(self::LOG_PREFIX . \" Processing $frequency reports\");\n \n $reportId = $this->option('report-id');\n\n if ($reportId !== null) {\n $reports = $this->getReportById($reportId);\n } else {\n // Get all enabled, not deleted reports with active teams for the specified frequency\n $reports = $this->reportRepository->getActiveReportsByFrequency($frequency);\n \n }\n\n $this->logger->info(self::LOG_PREFIX . \" Found {$reports->count()} $frequency reports to process\");\n\n /** @var AutomatedReport $report */\n foreach ($reports as $report) {\n $this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [\n 'reportUuid' => $report->getUuid(),\n 'teamId' => $report->getTeamId(),\n 'frequency' => $report->getFrequency(),\n 'type' => $report->getType(),\n ]);\n\n $job = $report->isAskJiminnyReport()\n ? new RequestGenerateAskJiminnyReportJob($report->getUuid())\n : new RequestGenerateReportJob($report->getUuid());\n\n // $this->dispatcher->dispatch($job);\n $this->dispatcher->dispatchSync($job);\n }\n }\n}","role_description":"text entry area","is_enabled":true,"is_focused":true,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Execute","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Explain Plan","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Browse Query History","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"View Parameters","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Open Query Execution Settings…","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"In-Editor Results","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Tx: Auto","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Cancel Running Statements","depth":4,"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Playground","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"jiminny","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.088194445,"height":0.027777778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"16","depth":4,"role_description":"text"},{"role":"AXStaticText","text":"13","depth":4,"role_description":"text"},{"role":"AXStaticText","text":"13","depth":4,"role_description":"text"},{"role":"AXButton","text":"Previous Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Next Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"SELECT * FROM teams WHERE id = 1;\n\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;\nSELECT * FROM crm_fields WHERE id = 2234;\nSELECT * FROM crm_field_values WHERE crm_field_id = 2234;\n\nselect * from crm_profiles where user_id = 143;\n\nselect * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO\nselect * from business_processes where crm_configuration_id = 39;\n# 01941000000H669AAC, 01941000000H66JAAS\n\nselect * from record_type_field_values\n where record_type_id IN (24);\n\nselect * from crm_field_values where id IN (2730);\n\nselect * from crm_configurations where id = 39;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce'; #1035\n\n\nselect * from users where team_id = 1; # 222 group 3\nSELECT * FROM activities WHERE user_id = 222 order by id desc;\nselect * from sidekick_settings where team_id = 1;\nselect * from teams where id = 1;\nselect * from team_features where team_id = 1;\n\nselect * from activities where crm_configuration_id = 2\nand provider = 'ms-teams' and id = 608765;\n\nSELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';\n\nselect * from sidekick_settings where team_id = 2;\n\nSELECT * FROM activities WHERE id = 608660;\nselect * from activity_summary_logs where activity_id = 608660;\nselect * from ai_prompts where transcription_id = 11214;\n\n# ********************************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;\n# id: 608818, crm: 59628809737\nSELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;\n# id: 608821, crm: 59632069252\nSELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,\nplaybook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,\nscheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at\nFROM activities a\njoin calendar_events ce on a.calendar_event_id = ce.id\nWHERE a.id IN (608818, 608821);\n\nselect * from users where team_id = 1;\nselect * from team_settings where team_id = 1;\nselect * from crm_profiles where crm_configuration_id = 39 order by user_id;\n\nselect * from team_features where team_id = 1;\n\nselect * from users where team_id = 2;\n\nSELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639\n# Preslava N. Ivanova, grou id 3\n\nSELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;\n\nselect * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';\n\nselect\n a.id,\n a.type,\n a.scheduled_start_time,\n a.actual_start_time,\n a.created_at,\n a.opportunity_id,\n a.status\nFROM activities a\nWHERE opportunity_id = 344\nand status IN ('completed', 'received', 'delivered')\nand (\n (a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))\n;\n\nSELECT * FROM users WHERE id = 222;\n\nSELECT * FROM crm_profiles WHERE user_id = 222;\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;\n\nselect * from group_deal_risk_types;\n\nselect * from opportunities where team_id = 1;\n\nSELECT * FROM opportunities WHERE id = 315;\nSELECT * FROM crm_field_data WHERE object_id = 315;\nselect * from crm_field_data where object_id = 260;\n\nselect * from generic_ai_prompts where subject_id = 315;\n\nselect * from teams; # 36, 21, 121, james.graham@bullhorn.jiminny.com\nSELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';\n\n# ************************************************************************************\nselect * from teams where id = 1;\nselect * from crm_configurations where id = 39;\nselect * from users where team_id = 1;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 1;\n# 1 - 00541000004281rAAA\n# 204 - 0052g000003freeAAA\n# 429 - 0052g000003qGOiAAM\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\nselect * from activities where type = 'softphone'\nand created_at > '2024-12-11 15:24:36' order by id desc;\n\nselect * from activity_providers where team_id = 1;\nselect * from activity_provider_users where activity_provider_id = 328;\n\nselect * from opportunities where crm_configuration_id = 39\nAND account_id = 178 AND is_closed = false\norder by created_at DESC;\n\nselect * from contacts where id = 3952;\nselect * from accounts where id = 178;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations where id = 21;\nselect * from users where team_id = 36;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 36;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 36\nand sa.provider = 'bullhorn';\n\nselect * from social_accounts where id = 348;\nUPDATE social_accounts SET\nprovider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',\nprovider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',\nexpires = 1733998131,\nstate = 'connected'\nWHERE id = 348;\n\n# ************************************************************************************\nselect * from teams where id = 31;\nselect * from crm_configurations where id = 18;\n\nselect * from users where team_id = 31; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 31;\n\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 31\nand sa.provider = 'close';\n\nselect * from contacts where crm_configuration_id = 18;\n\n# ********************** NEPTUNE **************************************************************\nselect * from teams;\nselect * from users where id IN (1030, 1035, 1052);\nselect * from crm_configurations;\n\nselect * from users where team_id = 65; # 257\nselect * from team_settings where team_id = 65; # 257\nselect * from invitations where team_id = 65; # 257\nselect * from users where email = 'integration-account@jiminny.com'; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 65;\n\nselect * from crm_configurations where id = 53;\nselect * from accounts where crm_configuration_id = 53 order by id desc;\nselect * from leads where crm_configuration_id = 53 order by id desc;\nselect * from contacts where crm_configuration_id = 53 order by id desc;\nselect * from opportunities where crm_configuration_id = 53 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 53 order by id desc;\nselect * from crm_fields where crm_configuration_id = 53 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 53 order by id desc;\nselect * from stages where crm_configuration_id = 53 order by id desc;\n\n\nselect * from crm_profiles where crm_configuration_id = 13;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\nand sa.provider = 'integration-app';\n\nselect * from contacts where crm_configuration_id = 13;\n\nselect * from social_accounts where sociable_id = 283;\n\nSELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';\n\nselect * from activity_providers where team_id = 65;\nSELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\n;\n\n# ***************************** STAGING ********************************************\nSELECT * FROM teams;\nSELECT * FROM teams WHERE id = 88;\nSELECT * FROM teams WHERE id = 89;\nselect * from team_settings where team_id = 89;\nSELECT * FROM users WHERE team_id = 89;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 89;\n\nselect * from users;\nSELECT * FROM social_accounts WHERE sociable_id = 1761;\nSELECT * FROM crm_configurations WHERE id = 70;\nselect * from accounts where crm_configuration_id = 70 order by id desc;\nselect * from leads where crm_configuration_id = 70 order by id desc;\nselect * from contacts where crm_configuration_id = 70 order by id desc;\nselect * from opportunities where crm_configuration_id = 70 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 70 order by id desc;\nselect * from crm_fields where crm_configuration_id = 70 order by id desc;\nselect * from crm_field_values where crm_field_id = 3536 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 70 order by id desc;\nselect * from stages where crm_configuration_id = 70 order by id desc;\nselect * from business_processes where crm_configuration_id = 70 order by id desc;\nselect * from business_process_stages where business_process_id = 34;\n\nselect * from contacts where id = 10468;\n\nselect * from crm_layouts where crm_configuration_id = 70;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;\nSELECT * FROM crm_fields WHERE id IN (3533,3534,3535);\n\nselect * from activities where crm_configuration_id = 70\nand (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;\n\nSELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;\nSELECT * FROM activities where crm_configuration_id = 69 ;\n\nSELECT * FROM users WHERE email LIKE '%jiminny_web_sa2@jiminny.com%';\nSELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;\nSELECT * FROM opportunities WHERE id = 385;\n\nselect * from participants p\njoin activities a on p.activity_id = a.id\nwhere a.crm_configuration_id = 70\nand (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);\nSELECT * FROM participants WHERE id = 1013638;\n\nselect * from teams where id = 90;\nselect * from users where team_id = 90;\nselect * from social_accounts where social_accounts.sociable_id IN (1960,1760);\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 71;\nselect * from invitations where team_id = 90;\n\nselect * from crm_configurations where id = 71;\nselect * from accounts where crm_configuration_id = 71 order by id desc;\nselect * from leads where crm_configuration_id = 71 order by id desc;\nselect * from contacts where crm_configuration_id = 71 order by id desc;\nselect * from opportunities where crm_configuration_id = 71 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 71 order by id desc;\nselect * from crm_fields where crm_configuration_id = 71 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 71 order by id desc;\nselect * from stages where crm_configuration_id = 71 order by id desc;\n\nselect * from users order by secondary_email desc;\nselect u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa\n join users u on sa.sociable_id = u.id\nwhere sa.provider = 'google' and u.email LIKE 'aneliya%';\n\nselect * from failed_jobs order by id desc;\n\nselect * from users where email = 'ben.allwright@learningpeople.co.uk' or secondary_email = 'ben.allwright@learningpeople.co.uk';\n\nselect * from teams;\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 39;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\n# ************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;\nSELECT * FROM crm_configurations WHERE id = 70;\n\nselect * from teams where id = 1;\nselect * from groups where team_id = 1;\nselect * from users where team_id = 1;\n\nselect o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o\njoin users u on o.user_id = u.id\njoin groups g on u.group_id = g.id\njoin role_user ru on u.id = ru.user_id\njoin roles r on ru.role_id = r.id\nwhere o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';\n\nselect * from role_user where user_id = 143;\nselect * from roles;\n\nselect * from role_user;\nselect * from groups where id = 9;\nselect * from scope_groups where group_id = 9;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations;\nSELECT * FROM social_accounts WHERE sociable_id = 121;\n\nhttps://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105\nhttps://crmsandbox.zoho.com/crm/\n\nhttps://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080\n https://crm.zoho.com/crm/\n org3469620\n\nSELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;\n\nselect * from users where email LIKE \"%mobile_automation_%\";\nselect * from social_accounts where sociable_id IN (2228);\nselect * from crm_profiles where user_id IN (2222,2223,2226,2227);\n\nselect * from teams order by id desc;\nSELECT * FROM users WHERE id = 2229;\nSELECT * FROM crm_profiles WHERE user_id = 2229;\nselect * from opportunities where crm_configuration_id = 88;\nselect * from crm_fields where crm_configuration_id = 88;\nselect * from crm_profiles where crm_configuration_id = 88;\n\nSELECT * FROM teams WHERE id = 1;\n\nSELECT * FROM users WHERE id = 143;\nSELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;\n\nhttps://app.staging.jiminny.com/ondemand?\n min_duration=1\n &\n only_recorded=1\n &\n user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e\n &\n sequence_number=2\n\n select * from users where team_id = 1 and email like '%stoyan%'\n\nselect * from coaching_feedbacks;\n\nselect * from teams;\nSELECT * FROM users WHERE team_id = 36;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from users where id = 143;\n\nSELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\n\nselect * from users where team_id = 2;\nselect * from activities where crm_configuration_id = 39\nand activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'\nAND user_id = 143\norder by id desc;\n\n# ************************************************************************************\nselect * from teams where id = 142; # 2312, 126\nselect * from team_settings;\nselect * from users where team_id = 142; # 21642\nSELECT * FROM social_accounts WHERE sociable_id = 21642;\nSELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;\nselect * from crm_profiles where id IN (93);\nselect * from invitations;\nselect * from team_features where team_id = 1;\n\nSELECT * FROM crm_configurations WHERE id = 126;\nselect * from accounts where crm_configuration_id = 126 order by id desc;\nselect * from leads where crm_configuration_id = 126 order by id desc;\nselect * from contacts where crm_configuration_id = 126 order by id desc;\nselect * from opportunities where crm_configuration_id = 126 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 126 order by id desc;\nselect * from crm_fields where crm_configuration_id = 126 # 11060\n# and type IN ('picklist', 'status')\n# and object_type = 'task'\norder by id desc;\n# 5731,5732,5733\nselect DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;\nselect * from crm_layouts where crm_configuration_id = 126 order by id desc;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);\nselect * from stages where crm_configuration_id = 126 order by id desc;\nselect * from business_processes where crm_configuration_id = 126 order by id desc;\nselect * from business_process_stages where business_process_id IN (76,75,74,73);\nselect * from playbooks where team_id = 142;\nselect * from playbook_layouts where playbook_id IN (108);\nSELECT * FROM playbook_categories WHERE playbook_id IN (108);\n\nselect * from teams where id = 130;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 2\nand sa.provider = 'hubspot';\n\nSELECT * FROM activities\n WHERE crm_configuration_id = 110;\n\nselect * from teams;\nselect * from crm_configurations;\n\nSELECT * FROM activities WHERE id = 628773;\nSELECT * FROM crm_profiles WHERE user_id = 1460;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from teams;\nselect ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id\njoin permission_role pr on pr.role_id = ru.role_id\n join permissions p on p.id = pr.permission_id\nwhere team_id = 495 and p.name IN ('dial');\n\nselect * from teams where id = 145;\nselect * from crm_configurations where id = 129;\nselect * from social_accounts where sociable_id = 2317;\nSELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;\n\nselect * from teams where id = 1;\nSELECT * FROM crm_layouts WHERE crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;\nSELECT * FROM crm_layout_entities WHERE id = 5507;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');\n\nselect * from teams;\nselect * from activities where crm_configuration_id = 14;\n\nSELECT * FROM social_accounts where provider = 'copper';\n\nselect * from activities where id = 628467;\nselect * from participants where activity_id = 628467;\n\nSELECT * FROM contacts WHERE id = 3969;\nSELECT * FROM accounts WHERE id = 177;\n\nSELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;\n\n# ********************* BH\nselect * from teams where id = 36;\nSELECT * FROM crm_configurations WHERE id = 21;\nselect * from activities where crm_configuration_id = 21 and id = 607901;\nselect * from activities where crm_configuration_id = 21;\n\nselect * roles;\nselect * from permissions;\nselect * from permission_role where permission_id = 226;\n\nselect * from migrations order by id desc;\n\n# mercury\n# neptune\n# earth\n\nselect * from teams;\nselect * from teams where id = 19;\nselect * from teams where id = 27;\nselect * from users where team_id = 27;\nSELECT * FROM crm_configurations WHERE id = 42;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from activities where id = 631461;\nSELECT * FROM crm_field_values WHERE crm_field_id = 180;\n\nselect * from teams where id = 2;\nSELECT * FROM social_accounts WHERE sociable_id = 89;\n\nSELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273\nselect * from activity_summary_logs where activity_id = 634273;\n\nselect * from sidekick_settings where team_id = 2;\n\nselect * from teams; # 2, 2\nSELECT * FROM crm_configurations WHERE team_id = 2; # 2\nselect * from team_features where team_id = 2;\nselect * from features;\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;\n\nselect * from automated_reports order by id desc;\nselect * from automated_report_results order by id desc;\nselect * from users where team_id = 1 and id IN (7160, 3248);\nselect * from migrations order by id desc;\n\nSELECT\n CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,\n u.email,\n sa.*,\n t.owner_id FROM social_accounts sa\nJOIN users u on u.id = sa.sociable_id\nJOIN teams t on t.id = u.team_id\nWHERE u.team_id = 1 and sa.provider = 'salesforce';\n\nselect * from teams where id = 1;\nselect * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;\nselect * from groups where id = 565;\nselect * from playbooks where team_id = 1;\nselect * from playbooks where id = 175;\nselect * from playbook_categories where playbook_id = 175;\nselect * from users where team_id = 1;\nselect * from users where id = 7160;\nselect * from crm_profiles where user_id = 7160;\nselect * from features;\nselect\n *\n# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,\n# crm_configuration_id, crm_provider_id, transcription_id, status\nfrom activities where crm_configuration_id = 1 and type = 'conference'\n# and crm_provider_id IS NOT NULL\nand provider != 'uploader' and actual_start_time IS NOT NULL\nORDER by id desc;\nselect * from activities where id = 54747783; # 00UO400000pCzojMAC\n\nselect p.id, p.activity_type, pc.id, pc.name\nFROM playbooks p\njoin playbook_categories pc on p.id = pc.playbook_id\nwhere p.team_id = 1 and p.activity_type = 'event';\n\nSELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';\nSELECT * FROM crm_field_values WHERE crm_field_id = 4;\n\nselect * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id\nwhere crm_configuration_id = 1 and pl.playbook_id = 175;\n\nselect * from teams;\nSELECT r.* FROM automated_reports r\njoin teams t on r.team_id = t.id\nWHERE r.frequency = 'daily'\n and r.status = 1\nAND t.status = 'active'\nAND (r.expires_at >= now() OR r.expires_at IS NULL);\n\nselect * from automated_report_results where report_id IN (18, 33);\n\nselect * from automated_reports;\nselect * from automated_report_results where report_id IN (34);","depth":4,"value":"SELECT * FROM teams WHERE id = 1;\n\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;\nSELECT * FROM crm_fields WHERE id = 2234;\nSELECT * FROM crm_field_values WHERE crm_field_id = 2234;\n\nselect * from crm_profiles where user_id = 143;\n\nselect * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO\nselect * from business_processes where crm_configuration_id = 39;\n# 01941000000H669AAC, 01941000000H66JAAS\n\nselect * from record_type_field_values\n where record_type_id IN (24);\n\nselect * from crm_field_values where id IN (2730);\n\nselect * from crm_configurations where id = 39;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce'; #1035\n\n\nselect * from users where team_id = 1; # 222 group 3\nSELECT * FROM activities WHERE user_id = 222 order by id desc;\nselect * from sidekick_settings where team_id = 1;\nselect * from teams where id = 1;\nselect * from team_features where team_id = 1;\n\nselect * from activities where crm_configuration_id = 2\nand provider = 'ms-teams' and id = 608765;\n\nSELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';\n\nselect * from sidekick_settings where team_id = 2;\n\nSELECT * FROM activities WHERE id = 608660;\nselect * from activity_summary_logs where activity_id = 608660;\nselect * from ai_prompts where transcription_id = 11214;\n\n# ********************************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;\n# id: 608818, crm: 59628809737\nSELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;\n# id: 608821, crm: 59632069252\nSELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,\nplaybook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,\nscheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at\nFROM activities a\njoin calendar_events ce on a.calendar_event_id = ce.id\nWHERE a.id IN (608818, 608821);\n\nselect * from users where team_id = 1;\nselect * from team_settings where team_id = 1;\nselect * from crm_profiles where crm_configuration_id = 39 order by user_id;\n\nselect * from team_features where team_id = 1;\n\nselect * from users where team_id = 2;\n\nSELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639\n# Preslava N. Ivanova, grou id 3\n\nSELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;\n\nselect * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';\n\nselect\n a.id,\n a.type,\n a.scheduled_start_time,\n a.actual_start_time,\n a.created_at,\n a.opportunity_id,\n a.status\nFROM activities a\nWHERE opportunity_id = 344\nand status IN ('completed', 'received', 'delivered')\nand (\n (a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))\n;\n\nSELECT * FROM users WHERE id = 222;\n\nSELECT * FROM crm_profiles WHERE user_id = 222;\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;\n\nselect * from group_deal_risk_types;\n\nselect * from opportunities where team_id = 1;\n\nSELECT * FROM opportunities WHERE id = 315;\nSELECT * FROM crm_field_data WHERE object_id = 315;\nselect * from crm_field_data where object_id = 260;\n\nselect * from generic_ai_prompts where subject_id = 315;\n\nselect * from teams; # 36, 21, 121, james.graham@bullhorn.jiminny.com\nSELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';\n\n# ************************************************************************************\nselect * from teams where id = 1;\nselect * from crm_configurations where id = 39;\nselect * from users where team_id = 1;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 1;\n# 1 - 00541000004281rAAA\n# 204 - 0052g000003freeAAA\n# 429 - 0052g000003qGOiAAM\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\nselect * from activities where type = 'softphone'\nand created_at > '2024-12-11 15:24:36' order by id desc;\n\nselect * from activity_providers where team_id = 1;\nselect * from activity_provider_users where activity_provider_id = 328;\n\nselect * from opportunities where crm_configuration_id = 39\nAND account_id = 178 AND is_closed = false\norder by created_at DESC;\n\nselect * from contacts where id = 3952;\nselect * from accounts where id = 178;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations where id = 21;\nselect * from users where team_id = 36;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 36;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 36\nand sa.provider = 'bullhorn';\n\nselect * from social_accounts where id = 348;\nUPDATE social_accounts SET\nprovider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',\nprovider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',\nexpires = 1733998131,\nstate = 'connected'\nWHERE id = 348;\n\n# ************************************************************************************\nselect * from teams where id = 31;\nselect * from crm_configurations where id = 18;\n\nselect * from users where team_id = 31; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 31;\n\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 31\nand sa.provider = 'close';\n\nselect * from contacts where crm_configuration_id = 18;\n\n# ********************** NEPTUNE **************************************************************\nselect * from teams;\nselect * from users where id IN (1030, 1035, 1052);\nselect * from crm_configurations;\n\nselect * from users where team_id = 65; # 257\nselect * from team_settings where team_id = 65; # 257\nselect * from invitations where team_id = 65; # 257\nselect * from users where email = 'integration-account@jiminny.com'; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 65;\n\nselect * from crm_configurations where id = 53;\nselect * from accounts where crm_configuration_id = 53 order by id desc;\nselect * from leads where crm_configuration_id = 53 order by id desc;\nselect * from contacts where crm_configuration_id = 53 order by id desc;\nselect * from opportunities where crm_configuration_id = 53 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 53 order by id desc;\nselect * from crm_fields where crm_configuration_id = 53 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 53 order by id desc;\nselect * from stages where crm_configuration_id = 53 order by id desc;\n\n\nselect * from crm_profiles where crm_configuration_id = 13;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\nand sa.provider = 'integration-app';\n\nselect * from contacts where crm_configuration_id = 13;\n\nselect * from social_accounts where sociable_id = 283;\n\nSELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';\n\nselect * from activity_providers where team_id = 65;\nSELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\n;\n\n# ***************************** STAGING ********************************************\nSELECT * FROM teams;\nSELECT * FROM teams WHERE id = 88;\nSELECT * FROM teams WHERE id = 89;\nselect * from team_settings where team_id = 89;\nSELECT * FROM users WHERE team_id = 89;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 89;\n\nselect * from users;\nSELECT * FROM social_accounts WHERE sociable_id = 1761;\nSELECT * FROM crm_configurations WHERE id = 70;\nselect * from accounts where crm_configuration_id = 70 order by id desc;\nselect * from leads where crm_configuration_id = 70 order by id desc;\nselect * from contacts where crm_configuration_id = 70 order by id desc;\nselect * from opportunities where crm_configuration_id = 70 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 70 order by id desc;\nselect * from crm_fields where crm_configuration_id = 70 order by id desc;\nselect * from crm_field_values where crm_field_id = 3536 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 70 order by id desc;\nselect * from stages where crm_configuration_id = 70 order by id desc;\nselect * from business_processes where crm_configuration_id = 70 order by id desc;\nselect * from business_process_stages where business_process_id = 34;\n\nselect * from contacts where id = 10468;\n\nselect * from crm_layouts where crm_configuration_id = 70;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;\nSELECT * FROM crm_fields WHERE id IN (3533,3534,3535);\n\nselect * from activities where crm_configuration_id = 70\nand (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;\n\nSELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;\nSELECT * FROM activities where crm_configuration_id = 69 ;\n\nSELECT * FROM users WHERE email LIKE '%jiminny_web_sa2@jiminny.com%';\nSELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;\nSELECT * FROM opportunities WHERE id = 385;\n\nselect * from participants p\njoin activities a on p.activity_id = a.id\nwhere a.crm_configuration_id = 70\nand (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);\nSELECT * FROM participants WHERE id = 1013638;\n\nselect * from teams where id = 90;\nselect * from users where team_id = 90;\nselect * from social_accounts where social_accounts.sociable_id IN (1960,1760);\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 71;\nselect * from invitations where team_id = 90;\n\nselect * from crm_configurations where id = 71;\nselect * from accounts where crm_configuration_id = 71 order by id desc;\nselect * from leads where crm_configuration_id = 71 order by id desc;\nselect * from contacts where crm_configuration_id = 71 order by id desc;\nselect * from opportunities where crm_configuration_id = 71 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 71 order by id desc;\nselect * from crm_fields where crm_configuration_id = 71 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 71 order by id desc;\nselect * from stages where crm_configuration_id = 71 order by id desc;\n\nselect * from users order by secondary_email desc;\nselect u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa\n join users u on sa.sociable_id = u.id\nwhere sa.provider = 'google' and u.email LIKE 'aneliya%';\n\nselect * from failed_jobs order by id desc;\n\nselect * from users where email = 'ben.allwright@learningpeople.co.uk' or secondary_email = 'ben.allwright@learningpeople.co.uk';\n\nselect * from teams;\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 39;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\n# ************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;\nSELECT * FROM crm_configurations WHERE id = 70;\n\nselect * from teams where id = 1;\nselect * from groups where team_id = 1;\nselect * from users where team_id = 1;\n\nselect o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o\njoin users u on o.user_id = u.id\njoin groups g on u.group_id = g.id\njoin role_user ru on u.id = ru.user_id\njoin roles r on ru.role_id = r.id\nwhere o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';\n\nselect * from role_user where user_id = 143;\nselect * from roles;\n\nselect * from role_user;\nselect * from groups where id = 9;\nselect * from scope_groups where group_id = 9;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations;\nSELECT * FROM social_accounts WHERE sociable_id = 121;\n\nhttps://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105\nhttps://crmsandbox.zoho.com/crm/\n\nhttps://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080\n https://crm.zoho.com/crm/\n org3469620\n\nSELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;\n\nselect * from users where email LIKE \"%mobile_automation_%\";\nselect * from social_accounts where sociable_id IN (2228);\nselect * from crm_profiles where user_id IN (2222,2223,2226,2227);\n\nselect * from teams order by id desc;\nSELECT * FROM users WHERE id = 2229;\nSELECT * FROM crm_profiles WHERE user_id = 2229;\nselect * from opportunities where crm_configuration_id = 88;\nselect * from crm_fields where crm_configuration_id = 88;\nselect * from crm_profiles where crm_configuration_id = 88;\n\nSELECT * FROM teams WHERE id = 1;\n\nSELECT * FROM users WHERE id = 143;\nSELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;\n\nhttps://app.staging.jiminny.com/ondemand?\n min_duration=1\n &\n only_recorded=1\n &\n user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e\n &\n sequence_number=2\n\n select * from users where team_id = 1 and email like '%stoyan%'\n\nselect * from coaching_feedbacks;\n\nselect * from teams;\nSELECT * FROM users WHERE team_id = 36;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from users where id = 143;\n\nSELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\n\nselect * from users where team_id = 2;\nselect * from activities where crm_configuration_id = 39\nand activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'\nAND user_id = 143\norder by id desc;\n\n# ************************************************************************************\nselect * from teams where id = 142; # 2312, 126\nselect * from team_settings;\nselect * from users where team_id = 142; # 21642\nSELECT * FROM social_accounts WHERE sociable_id = 21642;\nSELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;\nselect * from crm_profiles where id IN (93);\nselect * from invitations;\nselect * from team_features where team_id = 1;\n\nSELECT * FROM crm_configurations WHERE id = 126;\nselect * from accounts where crm_configuration_id = 126 order by id desc;\nselect * from leads where crm_configuration_id = 126 order by id desc;\nselect * from contacts where crm_configuration_id = 126 order by id desc;\nselect * from opportunities where crm_configuration_id = 126 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 126 order by id desc;\nselect * from crm_fields where crm_configuration_id = 126 # 11060\n# and type IN ('picklist', 'status')\n# and object_type = 'task'\norder by id desc;\n# 5731,5732,5733\nselect DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;\nselect * from crm_layouts where crm_configuration_id = 126 order by id desc;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);\nselect * from stages where crm_configuration_id = 126 order by id desc;\nselect * from business_processes where crm_configuration_id = 126 order by id desc;\nselect * from business_process_stages where business_process_id IN (76,75,74,73);\nselect * from playbooks where team_id = 142;\nselect * from playbook_layouts where playbook_id IN (108);\nSELECT * FROM playbook_categories WHERE playbook_id IN (108);\n\nselect * from teams where id = 130;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 2\nand sa.provider = 'hubspot';\n\nSELECT * FROM activities\n WHERE crm_configuration_id = 110;\n\nselect * from teams;\nselect * from crm_configurations;\n\nSELECT * FROM activities WHERE id = 628773;\nSELECT * FROM crm_profiles WHERE user_id = 1460;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from teams;\nselect ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id\njoin permission_role pr on pr.role_id = ru.role_id\n join permissions p on p.id = pr.permission_id\nwhere team_id = 495 and p.name IN ('dial');\n\nselect * from teams where id = 145;\nselect * from crm_configurations where id = 129;\nselect * from social_accounts where sociable_id = 2317;\nSELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;\n\nselect * from teams where id = 1;\nSELECT * FROM crm_layouts WHERE crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;\nSELECT * FROM crm_layout_entities WHERE id = 5507;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');\n\nselect * from teams;\nselect * from activities where crm_configuration_id = 14;\n\nSELECT * FROM social_accounts where provider = 'copper';\n\nselect * from activities where id = 628467;\nselect * from participants where activity_id = 628467;\n\nSELECT * FROM contacts WHERE id = 3969;\nSELECT * FROM accounts WHERE id = 177;\n\nSELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;\n\n# ********************* BH\nselect * from teams where id = 36;\nSELECT * FROM crm_configurations WHERE id = 21;\nselect * from activities where crm_configuration_id = 21 and id = 607901;\nselect * from activities where crm_configuration_id = 21;\n\nselect * roles;\nselect * from permissions;\nselect * from permission_role where permission_id = 226;\n\nselect * from migrations order by id desc;\n\n# mercury\n# neptune\n# earth\n\nselect * from teams;\nselect * from teams where id = 19;\nselect * from teams where id = 27;\nselect * from users where team_id = 27;\nSELECT * FROM crm_configurations WHERE id = 42;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from activities where id = 631461;\nSELECT * FROM crm_field_values WHERE crm_field_id = 180;\n\nselect * from teams where id = 2;\nSELECT * FROM social_accounts WHERE sociable_id = 89;\n\nSELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273\nselect * from activity_summary_logs where activity_id = 634273;\n\nselect * from sidekick_settings where team_id = 2;\n\nselect * from teams; # 2, 2\nSELECT * FROM crm_configurations WHERE team_id = 2; # 2\nselect * from team_features where team_id = 2;\nselect * from features;\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;\n\nselect * from automated_reports order by id desc;\nselect * from automated_report_results order by id desc;\nselect * from users where team_id = 1 and id IN (7160, 3248);\nselect * from migrations order by id desc;\n\nSELECT\n CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,\n u.email,\n sa.*,\n t.owner_id FROM social_accounts sa\nJOIN users u on u.id = sa.sociable_id\nJOIN teams t on t.id = u.team_id\nWHERE u.team_id = 1 and sa.provider = 'salesforce';\n\nselect * from teams where id = 1;\nselect * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;\nselect * from groups where id = 565;\nselect * from playbooks where team_id = 1;\nselect * from playbooks where id = 175;\nselect * from playbook_categories where playbook_id = 175;\nselect * from users where team_id = 1;\nselect * from users where id = 7160;\nselect * from crm_profiles where user_id = 7160;\nselect * from features;\nselect\n *\n# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,\n# crm_configuration_id, crm_provider_id, transcription_id, status\nfrom activities where crm_configuration_id = 1 and type = 'conference'\n# and crm_provider_id IS NOT NULL\nand provider != 'uploader' and actual_start_time IS NOT NULL\nORDER by id desc;\nselect * from activities where id = 54747783; # 00UO400000pCzojMAC\n\nselect p.id, p.activity_type, pc.id, pc.name\nFROM playbooks p\njoin playbook_categories pc on p.id = pc.playbook_id\nwhere p.team_id = 1 and p.activity_type = 'event';\n\nSELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';\nSELECT * FROM crm_field_values WHERE crm_field_id = 4;\n\nselect * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id\nwhere crm_configuration_id = 1 and pl.playbook_id = 175;\n\nselect * from teams;\nSELECT r.* FROM automated_reports r\njoin teams t on r.team_id = t.id\nWHERE r.frequency = 'daily'\n and r.status = 1\nAND t.status = 'active'\nAND (r.expires_at >= now() OR r.expires_at IS NULL);\n\nselect * from automated_report_results where report_id IN (18, 33);\n\nselect * from automated_reports;\nselect * from automated_report_results where report_id IN (34);","role_description":"text entry area","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Project","depth":3,"role_description":"text"},{"role":"AXButton","text":"Project","depth":3,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"New File or Directory…","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Expand Selected","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Collapse All","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Options","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false}]...
|
-1978360131630512558
|
6686649039917036621
|
idle
|
accessibility
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
<?php
declare(strict_types=1);
namespace Jiminny\Console\Commands\Reports;
use Carbon\Carbon;
use Illuminate\Console\Command;
use Illuminate\Contracts\Bus\Dispatcher as BusDispatcher;
use Jiminny\Jobs\AutomatedReports\RequestGenerateAskJiminnyReportJob;
use Jiminny\Jobs\AutomatedReports\RequestGenerateReportJob;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\Team;
use Jiminny\Repositories\AutomatedReportsRepository;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Psr\Log\LoggerInterface;
class AutomatedReportsCommand extends Command
{
/**
* Log prefix for all log messages
*/
private const string LOG_PREFIX = '[automated-reports]';
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'automated-reports {--report-id= : Process a specific report by ID or UUID (bypasses frequency scheduling)}';
/**
* The console command description.
*
* @var string
*/
protected $description = 'Process automated reports based on their frequency (weekly, monthly, quarterly). Use --report-id to manually trigger a specific report by ID or UUID.';
public function __construct(
private readonly LoggerInterface $logger,
private readonly BusDispatcher $dispatcher,
private readonly AutomatedReportsRepository $reportRepository
) {
parent::__construct();
}
/**
* Execute the console command.
*
* @return int
*/
public function handle(): int
{
$this->logger->info(self::LOG_PREFIX . ' Started');
$reportId = $this->option('report-id');
if ($reportId !== null) {
return $this->processSingleReport((string) $reportId);
}
$now = Carbon::now();
$isMonday = $now->isMonday();
$isFirstDayOfMonth = $now->day === 1;
$currentMonth = $now->month;
// Check if the current month is a quarterly month (January, April, July, October)
$isQuarterlyMonth = in_array($currentMonth, [1, 4, 7, 10], true);
$this->logger->info(self::LOG_PREFIX . ' Checking conditions', [
'isMonday' => $isMonday,
'isFirstDayOfMonth' => $isFirstDayOfMonth,
'currentMonth' => $currentMonth,
'isQuarterlyMonth' => $isQuarterlyMonth,
]);
// Process daily reports
$this->processReports(AutomatedReportsService::FREQUENCY_DAILY);
// Process weekly reports on Mondays
if ($isMonday) {
$this->processReports(AutomatedReportsService::FREQUENCY_WEEKLY);
}
// Process monthly reports on the first day of the month
if ($isFirstDayOfMonth) {
$this->processReports(AutomatedReportsService::FREQUENCY_MONTHLY);
}
// Process quarterly reports on the first day of January, April, July, and October
if ($isFirstDayOfMonth && $isQuarterlyMonth) {
$this->processReports(AutomatedReportsService::FREQUENCY_QUARTERLY);
}
$this->logger->info(self::LOG_PREFIX . ' Completed');
return 0;
}
private function processSingleReport(string $reportId): int
{
$this->logger->info(self::LOG_PREFIX . ' Manual single-report mode', ['reportId' => $reportId]);
$report = is_numeric($reportId)
? AutomatedReport::withTrashed()->find((int) $reportId)
: AutomatedReport::withTrashed()->where('uuid', AutomatedReport::toOptimized($reportId))->first();
if ($report === null) {
$this->logger->error(self::LOG_PREFIX . ' Report not found', ['reportId' => $reportId]);
$this->error("Report not found: {$reportId}");
return 1;
}
$this->warnIfNotApplicableForSchedule($report);
$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [
'reportUuid' => $report->getUuid(),
'teamId' => $report->getTeamId(),
'frequency' => $report->getFrequency(),
'type' => $report->getType(),
]);
$job = $report->isAskJiminnyReport()
? new RequestGenerateAskJiminnyReportJob($report->getUuid())
: new RequestGenerateReportJob($report->getUuid());
$this->dispatcher->dispatchSync($job);
$this->logger->info(self::LOG_PREFIX . ' Completed');
return 0;
}
private function warnIfNotApplicableForSchedule(AutomatedReport $report): void
{
if ($report->trashed()) {
$this->warn('Report is soft-deleted (deleted_at: ' . $report->getDeletedAt()?->toDateTimeString() . ').');
}
if (! $report->getStatus()) {
$this->warn('Report status is inactive — would be skipped in scheduled run.');
}
$team = $report->getTeam();
if ($team->getStatus() !== Team::STATUS_ACTIVE) {
$this->warn("Team #{$report->getTeamId()} is not active (status: {$team->getStatus()}) — would be skipped in scheduled run.");
}
if ($report->isExpired()) {
$this->warn('Report is expired (expires_at: ' . $report->getExpiresAt()?->toDateString() . ') — would be skipped in scheduled run.');
}
$now = Carbon::now();
$frequency = $report->getFrequency();
$wouldRunToday = match ($frequency) {
AutomatedReportsService::FREQUENCY_DAILY => true,
AutomatedReportsService::FREQUENCY_WEEKLY => $now->isMonday(),
AutomatedReportsService::FREQUENCY_MONTHLY => $now->day === 1,
AutomatedReportsService::FREQUENCY_QUARTERLY => $now->day === 1 && in_array($now->month, [1, 4, 7, 10], true),
default => false,
};
if (! $wouldRunToday) {
$this->warn("Report frequency is '{$frequency}' — would NOT be scheduled to run today.");
}
}
/**
* Process reports for a specific frequency.
*
* @param string $frequency
*
* @return void
*/
private function processReports(string $frequency): void
{
$this->logger->info(self::LOG_PREFIX . " Processing $frequency reports");
$reportId = $this->option('report-id');
if ($reportId !== null) {
$reports = $this->getReportById($reportId);
} else {
// Get all enabled, not deleted reports with active teams for the specified frequency
$reports = $this->reportRepository->getActiveReportsByFrequency($frequency);
}
$this->logger->info(self::LOG_PREFIX . " Found {$reports->count()} $frequency reports to process");
/** @var AutomatedReport $report */
foreach ($reports as $report) {
$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [
'reportUuid' => $report->getUuid(),
'teamId' => $report->getTeamId(),
'frequency' => $report->getFrequency(),
'type' => $report->getType(),
]);
$job = $report->isAskJiminnyReport()
? new RequestGenerateAskJiminnyReportJob($report->getUuid())
: new RequestGenerateReportJob($report->getUuid());
// $this->dispatcher->dispatch($job);
$this->dispatcher->dispatchSync($job);
}
}
}
Execute
Explain Plan
Browse Query History
View Parameters
Open Query Execution Settings…
In-Editor Results
Tx: Auto
Cancel Running Statements
Playground
jiminny
Sync Changes
Hide This Notification
Code changed:
Hide
16
13
13
Previous Highlighted Error
Next Highlighted Error
SELECT * FROM teams WHERE id = 1;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;
SELECT * FROM crm_fields WHERE id = 2234;
SELECT * FROM crm_field_values WHERE crm_field_id = 2234;
select * from crm_profiles where user_id = 143;
select * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO
select * from business_processes where crm_configuration_id = 39;
# 01941000000H669AAC, 01941000000H66JAAS
select * from record_type_field_values
where record_type_id IN (24);
select * from crm_field_values where id IN (2730);
select * from crm_configurations where id = 39;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce'; #1035
select * from users where team_id = 1; # 222 group 3
SELECT * FROM activities WHERE user_id = 222 order by id desc;
select * from sidekick_settings where team_id = 1;
select * from teams where id = 1;
select * from team_features where team_id = 1;
select * from activities where crm_configuration_id = 2
and provider = 'ms-teams' and id = 608765;
SELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';
select * from sidekick_settings where team_id = 2;
SELECT * FROM activities WHERE id = 608660;
select * from activity_summary_logs where activity_id = 608660;
select * from ai_prompts where transcription_id = 11214;
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;
# id: 608818, crm: 59628809737
SELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;
# id: 608821, crm: 59632069252
SELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,
playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,
scheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at
FROM activities a
join calendar_events ce on a.calendar_event_id = ce.id
WHERE a.id IN (608818, 608821);
select * from users where team_id = 1;
select * from team_settings where team_id = 1;
select * from crm_profiles where crm_configuration_id = 39 order by user_id;
select * from team_features where team_id = 1;
select * from users where team_id = 2;
SELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639
# Preslava N. Ivanova, grou id 3
SELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;
select * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';
select
a.id,
a.type,
a.scheduled_start_time,
a.actual_start_time,
a.created_at,
a.opportunity_id,
a.status
FROM activities a
WHERE opportunity_id = 344
and status IN ('completed', 'received', 'delivered')
and (
(a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))
;
SELECT * FROM users WHERE id = 222;
SELECT * FROM crm_profiles WHERE user_id = 222;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;
select * from group_deal_risk_types;
select * from opportunities where team_id = 1;
SELECT * FROM opportunities WHERE id = 315;
SELECT * FROM crm_field_data WHERE object_id = 315;
select * from crm_field_data where object_id = 260;
select * from generic_ai_prompts where subject_id = 315;
select * from teams; # 36, 21, 121, [EMAIL]
SELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';
# [PASSWORD_DOTS]
select * from teams where id = 1;
select * from crm_configurations where id = 39;
select * from users where team_id = 1;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 1;
# 1 - 00541000004281rAAA
# 204 - 0052g000003freeAAA
# 429 - 0052g000003qGOiAAM
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
select * from activities where type = 'softphone'
and created_at > '2024-12-11 15:24:36' order by id desc;
select * from activity_providers where team_id = 1;
select * from activity_provider_users where activity_provider_id = 328;
select * from opportunities where crm_configuration_id = 39
AND account_id = 178 AND is_closed = false
order by created_at DESC;
select * from contacts where id = 3952;
select * from accounts where id = 178;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations where id = 21;
select * from users where team_id = 36;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 36
and sa.provider = 'bullhorn';
select * from social_accounts where id = 348;
UPDATE social_accounts SET
provider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',
provider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',
expires = 1733998131,
state = 'connected'
WHERE id = 348;
# [PASSWORD_DOTS]
select * from teams where id = 31;
select * from crm_configurations where id = 18;
select * from users where team_id = 31; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 31;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 31
and sa.provider = 'close';
select * from contacts where crm_configuration_id = 18;
# [PASSWORD_DOTS] NEPTUNE [PASSWORD_DOTS]
select * from teams;
select * from users where id IN (1030, 1035, 1052);
select * from crm_configurations;
select * from users where team_id = 65; # 257
select * from team_settings where team_id = 65; # 257
select * from invitations where team_id = 65; # 257
select * from users where email = '[EMAIL]'; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 65;
select * from crm_configurations where id = 53;
select * from accounts where crm_configuration_id = 53 order by id desc;
select * from leads where crm_configuration_id = 53 order by id desc;
select * from contacts where crm_configuration_id = 53 order by id desc;
select * from opportunities where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 53 order by id desc;
select * from crm_fields where crm_configuration_id = 53 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 53 order by id desc;
select * from stages where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 13;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
and sa.provider = 'integration-app';
select * from contacts where crm_configuration_id = 13;
select * from social_accounts where sociable_id = 283;
SELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';
select * from activity_providers where team_id = 65;
SELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
;
# [PASSWORD_DOTS] STAGING [PASSWORD_DOTS]
SELECT * FROM teams;
SELECT * FROM teams WHERE id = 88;
SELECT * FROM teams WHERE id = 89;
select * from team_settings where team_id = 89;
SELECT * FROM users WHERE team_id = 89;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 89;
select * from users;
SELECT * FROM social_accounts WHERE sociable_id = 1761;
SELECT * FROM crm_configurations WHERE id = 70;
select * from accounts where crm_configuration_id = 70 order by id desc;
select * from leads where crm_configuration_id = 70 order by id desc;
select * from contacts where crm_configuration_id = 70 order by id desc;
select * from opportunities where crm_configuration_id = 70 order by id desc;
select * from crm_profiles where crm_configuration_id = 70 order by id desc;
select * from crm_fields where crm_configuration_id = 70 order by id desc;
select * from crm_field_values where crm_field_id = 3536 order by id desc;
select * from crm_layouts where crm_configuration_id = 70 order by id desc;
select * from stages where crm_configuration_id = 70 order by id desc;
select * from business_processes where crm_configuration_id = 70 order by id desc;
select * from business_process_stages where business_process_id = 34;
select * from contacts where id = 10468;
select * from crm_layouts where crm_configuration_id = 70;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;
SELECT * FROM crm_fields WHERE id IN (3533,3534,3535);
select * from activities where crm_configuration_id = 70
and (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;
SELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;
SELECT * FROM activities where crm_configuration_id = 69 ;
SELECT * FROM users WHERE email LIKE '%[EMAIL]%';
SELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;
SELECT * FROM opportunities WHERE id = 385;
select * from participants p
join activities a on p.activity_id = a.id
where a.crm_configuration_id = 70
and (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);
SELECT * FROM participants WHERE id = 1013638;
select * from teams where id = 90;
select * from users where team_id = 90;
select * from social_accounts where social_accounts.sociable_id IN (1960,1760);
SELECT * FROM crm_profiles WHERE crm_configuration_id = 71;
select * from invitations where team_id = 90;
select * from crm_configurations where id = 71;
select * from accounts where crm_configuration_id = 71 order by id desc;
select * from leads where crm_configuration_id = 71 order by id desc;
select * from contacts where crm_configuration_id = 71 order by id desc;
select * from opportunities where crm_configuration_id = 71 order by id desc;
select * from crm_profiles where crm_configuration_id = 71 order by id desc;
select * from crm_fields where crm_configuration_id = 71 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 71 order by id desc;
select * from stages where crm_configuration_id = 71 order by id desc;
select * from users order by secondary_email desc;
select u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa
join users u on sa.sociable_id = u.id
where sa.provider = 'google' and u.email LIKE 'aneliya%';
select * from failed_jobs order by id desc;
select * from users where email = '[EMAIL]' or secondary_email = '[EMAIL]';
select * from teams;
SELECT * FROM crm_profiles WHERE crm_configuration_id = 39;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;
SELECT * FROM crm_configurations WHERE id = 70;
select * from teams where id = 1;
select * from groups where team_id = 1;
select * from users where team_id = 1;
select o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o
join users u on o.user_id = u.id
join groups g on u.group_id = g.id
join role_user ru on u.id = ru.user_id
join roles r on ru.role_id = r.id
where o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';
select * from role_user where user_id = 143;
select * from roles;
select * from role_user;
select * from groups where id = 9;
select * from scope_groups where group_id = 9;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations;
SELECT * FROM social_accounts WHERE sociable_id = 121;
https://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105
https://crmsandbox.zoho.com/crm/
https://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080
https://crm.zoho.com/crm/
org3469620
SELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;
select * from users where email LIKE "%mobile_automation_%";
select * from social_accounts where sociable_id IN (2228);
select * from crm_profiles where user_id IN (2222,2223,2226,2227);
select * from teams order by id desc;
SELECT * FROM users WHERE id = 2229;
SELECT * FROM crm_profiles WHERE user_id = 2229;
select * from opportunities where crm_configuration_id = 88;
select * from crm_fields where crm_configuration_id = 88;
select * from crm_profiles where crm_configuration_id = 88;
SELECT * FROM teams WHERE id = 1;
SELECT * FROM users WHERE id = 143;
SELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;
https://app.staging.jiminny.com/ondemand?
min_duration=1
&
only_recorded=1
&
user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e
&
sequence_number=2
select * from users where team_id = 1 and email like '%stoyan%'
select * from coaching_feedbacks;
select * from teams;
SELECT * FROM users WHERE team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from users where id = 143;
SELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
select * from users where team_id = 2;
select * from activities where crm_configuration_id = 39
and activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'
AND user_id = 143
order by id desc;
# [PASSWORD_DOTS]
select * from teams where id = 142; # 2312, 126
select * from team_settings;
select * from users where team_id = 142; # 21642
SELECT * FROM social_accounts WHERE sociable_id = 21642;
SELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;
select * from crm_profiles where id IN (93);
select * from invitations;
select * from team_features where team_id = 1;
SELECT * FROM crm_configurations WHERE id = 126;
select * from accounts where crm_configuration_id = 126 order by id desc;
select * from leads where crm_configuration_id = 126 order by id desc;
select * from contacts where crm_configuration_id = 126 order by id desc;
select * from opportunities where crm_configuration_id = 126 order by id desc;
select * from crm_profiles where crm_configuration_id = 126 order by id desc;
select * from crm_fields where crm_configuration_id = 126 # 11060
# and type IN ('picklist', 'status')
# and object_type = 'task'
order by id desc;
# 5731,5732,5733
select DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;
select * from crm_layouts where crm_configuration_id = 126 order by id desc;
SELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);
select * from stages where crm_configuration_id = 126 order by id desc;
select * from business_processes where crm_configuration_id = 126 order by id desc;
select * from business_process_stages where business_process_id IN (76,75,74,73);
select * from playbooks where team_id = 142;
select * from playbook_layouts where playbook_id IN (108);
SELECT * FROM playbook_categories WHERE playbook_id IN (108);
select * from teams where id = 130;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 2
and sa.provider = 'hubspot';
SELECT * FROM activities
WHERE crm_configuration_id = 110;
select * from teams;
select * from crm_configurations;
SELECT * FROM activities WHERE id = 628773;
SELECT * FROM crm_profiles WHERE user_id = 1460;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from teams;
select ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id
join permission_role pr on pr.role_id = ru.role_id
join permissions p on p.id = pr.permission_id
where team_id = 495 and p.name IN ('dial');
select * from teams where id = 145;
select * from crm_configurations where id = 129;
select * from social_accounts where sociable_id = 2317;
SELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;
select * from teams where id = 1;
SELECT * FROM crm_layouts WHERE crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;
SELECT * FROM crm_layout_entities WHERE id = 5507;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');
select * from teams;
select * from activities where crm_configuration_id = 14;
SELECT * FROM social_accounts where provider = 'copper';
select * from activities where id = 628467;
select * from participants where activity_id = 628467;
SELECT * FROM contacts WHERE id = 3969;
SELECT * FROM accounts WHERE id = 177;
SELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;
# [PASSWORD_DOTS] BH
select * from teams where id = 36;
SELECT * FROM crm_configurations WHERE id = 21;
select * from activities where crm_configuration_id = 21 and id = 607901;
select * from activities where crm_configuration_id = 21;
select * roles;
select * from permissions;
select * from permission_role where permission_id = 226;
select * from migrations order by id desc;
# mercury
# neptune
# earth
select * from teams;
select * from teams where id = 19;
select * from teams where id = 27;
select * from users where team_id = 27;
SELECT * FROM crm_configurations WHERE id = 42;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from activities where id = 631461;
SELECT * FROM crm_field_values WHERE crm_field_id = 180;
select * from teams where id = 2;
SELECT * FROM social_accounts WHERE sociable_id = 89;
SELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273
select * from activity_summary_logs where activity_id = 634273;
select * from sidekick_settings where team_id = 2;
select * from teams; # 2, 2
SELECT * FROM crm_configurations WHERE team_id = 2; # 2
select * from team_features where team_id = 2;
select * from features;
SELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';
SELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;
select * from automated_reports order by id desc;
select * from automated_report_results order by id desc;
select * from users where team_id = 1 and id IN (7160, 3248);
select * from migrations order by id desc;
SELECT
CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,
u.email,
sa.*,
t.owner_id FROM social_accounts sa
JOIN users u on u.id = sa.sociable_id
JOIN teams t on t.id = u.team_id
WHERE u.team_id = 1 and sa.provider = 'salesforce';
select * from teams where id = 1;
select * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;
select * from groups where id = 565;
select * from playbooks where team_id = 1;
select * from playbooks where id = 175;
select * from playbook_categories where playbook_id = 175;
select * from users where team_id = 1;
select * from users where id = 7160;
select * from crm_profiles where user_id = 7160;
select * from features;
select
*
# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,
# crm_configuration_id, crm_provider_id, transcription_id, status
from activities where crm_configuration_id = 1 and type = 'conference'
# and crm_provider_id IS NOT NULL
and provider != 'uploader' and actual_start_time IS NOT NULL
ORDER by id desc;
select * from activities where id = 54747783; # 00UO400000pCzojMAC
select p.id, p.activity_type, pc.id, pc.name
FROM playbooks p
join playbook_categories pc on p.id = pc.playbook_id
where p.team_id = 1 and p.activity_type = 'event';
SELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';
SELECT * FROM crm_field_values WHERE crm_field_id = 4;
select * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id
where crm_configuration_id = 1 and pl.playbook_id = 175;
select * from teams;
SELECT r.* FROM automated_reports r
join teams t on r.team_id = t.id
WHERE r.frequency = 'daily'
and r.status = 1
AND t.status = 'active'
AND (r.expires_at >= now() OR r.expires_at IS NULL);
select * from automated_report_results where report_id IN (18, 33);
select * from automated_reports;
select * from automated_report_results where report_id IN (34);
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
10329
|
|
10332
|
205
|
0
|
2026-04-14T08:32:56.844217+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776155576844_m2.jpg...
|
PhpStorm
|
faVsco.js – AutomatedReportsCommand.php
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
<?php
declare(strict_types=1);
namespace Jiminny\Console\Commands\Reports;
use Carbon\Carbon;
use Illuminate\Console\Command;
use Illuminate\Contracts\Bus\Dispatcher as BusDispatcher;
use Jiminny\Jobs\AutomatedReports\RequestGenerateAskJiminnyReportJob;
use Jiminny\Jobs\AutomatedReports\RequestGenerateReportJob;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\Team;
use Jiminny\Repositories\AutomatedReportsRepository;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Psr\Log\LoggerInterface;
class AutomatedReportsCommand extends Command
{
/**
* Log prefix for all log messages
*/
private const string LOG_PREFIX = '[automated-reports]';
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'automated-reports {--report-id= : Process a specific report by ID or UUID (bypasses frequency scheduling)}';
/**
* The console command description.
*
* @var string
*/
protected $description = 'Process automated reports based on their frequency (weekly, monthly, quarterly). Use --report-id to manually trigger a specific report by ID or UUID.';
public function __construct(
private readonly LoggerInterface $logger,
private readonly BusDispatcher $dispatcher,
private readonly AutomatedReportsRepository $reportRepository
) {
parent::__construct();
}
/**
* Execute the console command.
*
* @return int
*/
public function handle(): int
{
$this->logger->info(self::LOG_PREFIX . ' Started');
$reportId = $this->option('report-id');
if ($reportId !== null) {
return $this->processSingleReport((string) $reportId);
}
$now = Carbon::now();
$isMonday = $now->isMonday();
$isFirstDayOfMonth = $now->day === 1;
$currentMonth = $now->month;
// Check if the current month is a quarterly month (January, April, July, October)
$isQuarterlyMonth = in_array($currentMonth, [1, 4, 7, 10], true);
$this->logger->info(self::LOG_PREFIX . ' Checking conditions', [
'isMonday' => $isMonday,
'isFirstDayOfMonth' => $isFirstDayOfMonth,
'currentMonth' => $currentMonth,
'isQuarterlyMonth' => $isQuarterlyMonth,
]);
// Process daily reports
$this->processReports(AutomatedReportsService::FREQUENCY_DAILY);
// Process weekly reports on Mondays
if ($isMonday) {
$this->processReports(AutomatedReportsService::FREQUENCY_WEEKLY);
}
// Process monthly reports on the first day of the month
if ($isFirstDayOfMonth) {
$this->processReports(AutomatedReportsService::FREQUENCY_MONTHLY);
}
// Process quarterly reports on the first day of January, April, July, and October
if ($isFirstDayOfMonth && $isQuarterlyMonth) {
$this->processReports(AutomatedReportsService::FREQUENCY_QUARTERLY);
}
$this->logger->info(self::LOG_PREFIX . ' Completed');
return 0;
}
private function processSingleReport(string $reportId): int
{
$this->logger->info(self::LOG_PREFIX . ' Manual single-report mode', ['reportId' => $reportId]);
$report = is_numeric($reportId)
? AutomatedReport::withTrashed()->find((int) $reportId)
: AutomatedReport::withTrashed()->where('uuid', AutomatedReport::toOptimized($reportId))->first();
if ($report === null) {
$this->logger->error(self::LOG_PREFIX . ' Report not found', ['reportId' => $reportId]);
$this->error("Report not found: {$reportId}");
return 1;
}
$this->warnIfNotApplicableForSchedule($report);
$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [
'reportUuid' => $report->getUuid(),
'teamId' => $report->getTeamId(),
'frequency' => $report->getFrequency(),
'type' => $report->getType(),
]);
$job = $report->isAskJiminnyReport()
? new RequestGenerateAskJiminnyReportJob($report->getUuid())
: new RequestGenerateReportJob($report->getUuid());
$this->dispatcher->dispatchSync($job);
$this->logger->info(self::LOG_PREFIX . ' Completed');
return 0;
}
private function warnIfNotApplicableForSchedule(AutomatedReport $report): void
{
if ($report->trashed()) {
$this->warn('Report is soft-deleted (deleted_at: ' . $report->getDeletedAt()?->toDateTimeString() . ').');
}
if (! $report->getStatus()) {
$this->warn('Report status is inactive — would be skipped in scheduled run.');
}
$team = $report->getTeam();
if ($team->getStatus() !== Team::STATUS_ACTIVE) {
$this->warn("Team #{$report->getTeamId()} is not active (status: {$team->getStatus()}) — would be skipped in scheduled run.");
}
if ($report->isExpired()) {
$this->warn('Report is expired (expires_at: ' . $report->getExpiresAt()?->toDateString() . ') — would be skipped in scheduled run.');
}
$now = Carbon::now();
$frequency = $report->getFrequency();
$wouldRunToday = match ($frequency) {
AutomatedReportsService::FREQUENCY_DAILY => true,
AutomatedReportsService::FREQUENCY_WEEKLY => $now->isMonday(),
AutomatedReportsService::FREQUENCY_MONTHLY => $now->day === 1,
AutomatedReportsService::FREQUENCY_QUARTERLY => $now->day === 1 && in_array($now->month, [1, 4, 7, 10], true),
default => false,
};
if (! $wouldRunToday) {
$this->warn("Report frequency is '{$frequency}' — would NOT be scheduled to run today.");
}
}
/**
* Process reports for a specific frequency.
*
* @param string $frequency
*
* @return void
*/
private function processReports(string $frequency): void
{
$this->logger->info(self::LOG_PREFIX . " Processing $frequency reports");
$reportId = $this->option('report-id');
if ($reportId !== null) {
$reports = $this->getReportById($reportId);
} else {
// Get all enabled, not deleted reports with active teams for the specified frequency
$reports = $this->reportRepository->getActiveReportsByFrequency($frequency);
}
$this->logger->info(self::LOG_PREFIX . " Found {$reports->count()} $frequency reports to process");
/** @var AutomatedReport $report */
foreach ($reports as $report) {
$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [
'reportUuid' => $report->getUuid(),
'teamId' => $report->getTeamId(),
'frequency' => $report->getFrequency(),
'type' => $report->getType(),
]);
$job = $report->isAskJiminnyReport()
? new RequestGenerateAskJiminnyReportJob($report->getUuid())
: new RequestGenerateReportJob($report->getUuid());
// $this->dispatcher->dispatch($job);
$this->dispatcher->dispatchSync($job);
}
}
}
Execute
Explain Plan
Browse Query History
View Parameters
Open Query Execution Settings…
In-Editor Results
Tx: Auto
Cancel Running Statements
Playground
jiminny
Sync Changes
Hide This Notification
Code changed:
Hide
16
13
13
Previous Highlighted Error
Next Highlighted Error
SELECT * FROM teams WHERE id = 1;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;
SELECT * FROM crm_fields WHERE id = 2234;
SELECT * FROM crm_field_values WHERE crm_field_id = 2234;
select * from crm_profiles where user_id = 143;
select * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO
select * from business_processes where crm_configuration_id = 39;
# 01941000000H669AAC, 01941000000H66JAAS
select * from record_type_field_values
where record_type_id IN (24);
select * from crm_field_values where id IN (2730);
select * from crm_configurations where id = 39;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce'; #1035
select * from users where team_id = 1; # 222 group 3
SELECT * FROM activities WHERE user_id = 222 order by id desc;
select * from sidekick_settings where team_id = 1;
select * from teams where id = 1;
select * from team_features where team_id = 1;
select * from activities where crm_configuration_id = 2
and provider = 'ms-teams' and id = 608765;
SELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';
select * from sidekick_settings where team_id = 2;
SELECT * FROM activities WHERE id = 608660;
select * from activity_summary_logs where activity_id = 608660;
select * from ai_prompts where transcription_id = 11214;
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;
# id: 608818, crm: 59628809737
SELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;
# id: 608821, crm: 59632069252
SELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,
playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,
scheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at
FROM activities a
join calendar_events ce on a.calendar_event_id = ce.id
WHERE a.id IN (608818, 608821);
select * from users where team_id = 1;
select * from team_settings where team_id = 1;
select * from crm_profiles where crm_configuration_id = 39 order by user_id;
select * from team_features where team_id = 1;
select * from users where team_id = 2;
SELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639
# Preslava N. Ivanova, grou id 3
SELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;
select * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';
select
a.id,
a.type,
a.scheduled_start_time,
a.actual_start_time,
a.created_at,
a.opportunity_id,
a.status
FROM activities a
WHERE opportunity_id = 344
and status IN ('completed', 'received', 'delivered')
and (
(a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))
;
SELECT * FROM users WHERE id = 222;
SELECT * FROM crm_profiles WHERE user_id = 222;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;
select * from group_deal_risk_types;
select * from opportunities where team_id = 1;
SELECT * FROM opportunities WHERE id = 315;
SELECT * FROM crm_field_data WHERE object_id = 315;
select * from crm_field_data where object_id = 260;
select * from generic_ai_prompts where subject_id = 315;
select * from teams; # 36, 21, 121, [EMAIL]
SELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';
# [PASSWORD_DOTS]
select * from teams where id = 1;
select * from crm_configurations where id = 39;
select * from users where team_id = 1;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 1;
# 1 - 00541000004281rAAA
# 204 - 0052g000003freeAAA
# 429 - 0052g000003qGOiAAM
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
select * from activities where type = 'softphone'
and created_at > '2024-12-11 15:24:36' order by id desc;
select * from activity_providers where team_id = 1;
select * from activity_provider_users where activity_provider_id = 328;
select * from opportunities where crm_configuration_id = 39
AND account_id = 178 AND is_closed = false
order by created_at DESC;
select * from contacts where id = 3952;
select * from accounts where id = 178;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations where id = 21;
select * from users where team_id = 36;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 36
and sa.provider = 'bullhorn';
select * from social_accounts where id = 348;
UPDATE social_accounts SET
provider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',
provider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',
expires = 1733998131,
state = 'connected'
WHERE id = 348;
# [PASSWORD_DOTS]
select * from teams where id = 31;
select * from crm_configurations where id = 18;
select * from users where team_id = 31; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 31;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 31
and sa.provider = 'close';
select * from contacts where crm_configuration_id = 18;
# [PASSWORD_DOTS] NEPTUNE [PASSWORD_DOTS]
select * from teams;
select * from users where id IN (1030, 1035, 1052);
select * from crm_configurations;
select * from users where team_id = 65; # 257
select * from team_settings where team_id = 65; # 257
select * from invitations where team_id = 65; # 257
select * from users where email = '[EMAIL]'; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 65;
select * from crm_configurations where id = 53;
select * from accounts where crm_configuration_id = 53 order by id desc;
select * from leads where crm_configuration_id = 53 order by id desc;
select * from contacts where crm_configuration_id = 53 order by id desc;
select * from opportunities where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 53 order by id desc;
select * from crm_fields where crm_configuration_id = 53 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 53 order by id desc;
select * from stages where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 13;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
and sa.provider = 'integration-app';
select * from contacts where crm_configuration_id = 13;
select * from social_accounts where sociable_id = 283;
SELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';
select * from activity_providers where team_id = 65;
SELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
;
# [PASSWORD_DOTS] STAGING [PASSWORD_DOTS]
SELECT * FROM teams;
SELECT * FROM teams WHERE id = 88;
SELECT * FROM teams WHERE id = 89;
select * from team_settings where team_id = 89;
SELECT * FROM users WHERE team_id = 89;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 89;
select * from users;
SELECT * FROM social_accounts WHERE sociable_id = 1761;
SELECT * FROM crm_configurations WHERE id = 70;
select * from accounts where crm_configuration_id = 70 order by id desc;
select * from leads where crm_configuration_id = 70 order by id desc;
select * from contacts where crm_configuration_id = 70 order by id desc;
select * from opportunities where crm_configuration_id = 70 order by id desc;
select * from crm_profiles where crm_configuration_id = 70 order by id desc;
select * from crm_fields where crm_configuration_id = 70 order by id desc;
select * from crm_field_values where crm_field_id = 3536 order by id desc;
select * from crm_layouts where crm_configuration_id = 70 order by id desc;
select * from stages where crm_configuration_id = 70 order by id desc;
select * from business_processes where crm_configuration_id = 70 order by id desc;
select * from business_process_stages where business_process_id = 34;
select * from contacts where id = 10468;
select * from crm_layouts where crm_configuration_id = 70;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;
SELECT * FROM crm_fields WHERE id IN (3533,3534,3535);
select * from activities where crm_configuration_id = 70
and (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;
SELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;
SELECT * FROM activities where crm_configuration_id = 69 ;
SELECT * FROM users WHERE email LIKE '%[EMAIL]%';
SELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;
SELECT * FROM opportunities WHERE id = 385;
select * from participants p
join activities a on p.activity_id = a.id
where a.crm_configuration_id = 70
and (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);
SELECT * FROM participants WHERE id = 1013638;
select * from teams where id = 90;
select * from users where team_id = 90;
select * from social_accounts where social_accounts.sociable_id IN (1960,1760);
SELECT * FROM crm_profiles WHERE crm_configuration_id = 71;
select * from invitations where team_id = 90;
select * from crm_configurations where id = 71;
select * from accounts where crm_configuration_id = 71 order by id desc;
select * from leads where crm_configuration_id = 71 order by id desc;
select * from contacts where crm_configuration_id = 71 order by id desc;
select * from opportunities where crm_configuration_id = 71 order by id desc;
select * from crm_profiles where crm_configuration_id = 71 order by id desc;
select * from crm_fields where crm_configuration_id = 71 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 71 order by id desc;
select * from stages where crm_configuration_id = 71 order by id desc;
select * from users order by secondary_email desc;
select u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa
join users u on sa.sociable_id = u.id
where sa.provider = 'google' and u.email LIKE 'aneliya%';
select * from failed_jobs order by id desc;
select * from users where email = '[EMAIL]' or secondary_email = '[EMAIL]';
select * from teams;
SELECT * FROM crm_profiles WHERE crm_configuration_id = 39;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;
SELECT * FROM crm_configurations WHERE id = 70;
select * from teams where id = 1;
select * from groups where team_id = 1;
select * from users where team_id = 1;
select o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o
join users u on o.user_id = u.id
join groups g on u.group_id = g.id
join role_user ru on u.id = ru.user_id
join roles r on ru.role_id = r.id
where o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';
select * from role_user where user_id = 143;
select * from roles;
select * from role_user;
select * from groups where id = 9;
select * from scope_groups where group_id = 9;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations;
SELECT * FROM social_accounts WHERE sociable_id = 121;
https://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105
https://crmsandbox.zoho.com/crm/
https://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080
https://crm.zoho.com/crm/
org3469620
SELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;
select * from users where email LIKE "%mobile_automation_%";
select * from social_accounts where sociable_id IN (2228);
select * from crm_profiles where user_id IN (2222,2223,2226,2227);
select * from teams order by id desc;
SELECT * FROM users WHERE id = 2229;
SELECT * FROM crm_profiles WHERE user_id = 2229;
select * from opportunities where crm_configuration_id = 88;
select * from crm_fields where crm_configuration_id = 88;
select * from crm_profiles where crm_configuration_id = 88;
SELECT * FROM teams WHERE id = 1;
SELECT * FROM users WHERE id = 143;
SELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;
https://app.staging.jiminny.com/ondemand?
min_duration=1
&
only_recorded=1
&
user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e
&
sequence_number=2
select * from users where team_id = 1 and email like '%stoyan%'
select * from coaching_feedbacks;
select * from teams;
SELECT * FROM users WHERE team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from users where id = 143;
SELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
select * from users where team_id = 2;
select * from activities where crm_configuration_id = 39
and activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'
AND user_id = 143
order by id desc;
# [PASSWORD_DOTS]
select * from teams where id = 142; # 2312, 126
select * from team_settings;
select * from users where team_id = 142; # 21642
SELECT * FROM social_accounts WHERE sociable_id = 21642;
SELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;
select * from crm_profiles where id IN (93);
select * from invitations;
select * from team_features where team_id = 1;
SELECT * FROM crm_configurations WHERE id = 126;
select * from accounts where crm_configuration_id = 126 order by id desc;
select * from leads where crm_configuration_id = 126 order by id desc;
select * from contacts where crm_configuration_id = 126 order by id desc;
select * from opportunities where crm_configuration_id = 126 order by id desc;
select * from crm_profiles where crm_configuration_id = 126 order by id desc;
select * from crm_fields where crm_configuration_id = 126 # 11060
# and type IN ('picklist', 'status')
# and object_type = 'task'
order by id desc;
# 5731,5732,5733
select DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;
select * from crm_layouts where crm_configuration_id = 126 order by id desc;
SELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);
select * from stages where crm_configuration_id = 126 order by id desc;
select * from business_processes where crm_configuration_id = 126 order by id desc;
select * from business_process_stages where business_process_id IN (76,75,74,73);
select * from playbooks where team_id = 142;
select * from playbook_layouts where playbook_id IN (108);
SELECT * FROM playbook_categories WHERE playbook_id IN (108);
select * from teams where id = 130;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 2
and sa.provider = 'hubspot';
SELECT * FROM activities
WHERE crm_configuration_id = 110;
select * from teams;
select * from crm_configurations;
SELECT * FROM activities WHERE id = 628773;
SELECT * FROM crm_profiles WHERE user_id = 1460;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from teams;
select ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id
join permission_role pr on pr.role_id = ru.role_id
join permissions p on p.id = pr.permission_id
where team_id = 495 and p.name IN ('dial');
select * from teams where id = 145;
select * from crm_configurations where id = 129;
select * from social_accounts where sociable_id = 2317;
SELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;
select * from teams where id = 1;
SELECT * FROM crm_layouts WHERE crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;
SELECT * FROM crm_layout_entities WHERE id = 5507;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');
select * from teams;
select * from activities where crm_configuration_id = 14;
SELECT * FROM social_accounts where provider = 'copper';
select * from activities where id = 628467;
select * from participants where activity_id = 628467;
SELECT * FROM contacts WHERE id = 3969;
SELECT * FROM accounts WHERE id = 177;
SELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;
# [PASSWORD_DOTS] BH
select * from teams where id = 36;
SELECT * FROM crm_configurations WHERE id = 21;
select * from activities where crm_configuration_id = 21 and id = 607901;
select * from activities where crm_configuration_id = 21;
select * roles;
select * from permissions;
select * from permission_role where permission_id = 226;
select * from migrations order by id desc;
# mercury
# neptune
# earth
select * from teams;
select * from teams where id = 19;
select * from teams where id = 27;
select * from users where team_id = 27;
SELECT * FROM crm_configurations WHERE id = 42;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from activities where id = 631461;
SELECT * FROM crm_field_values WHERE crm_field_id = 180;
select * from teams where id = 2;
SELECT * FROM social_accounts WHERE sociable_id = 89;
SELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273
select * from activity_summary_logs where activity_id = 634273;
select * from sidekick_settings where team_id = 2;
select * from teams; # 2, 2
SELECT * FROM crm_configurations WHERE team_id = 2; # 2
select * from team_features where team_id = 2;
select * from features;
SELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';
SELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;
select * from automated_reports order by id desc;
select * from automated_report_results order by id desc;
select * from users where team_id = 1 and id IN (7160, 3248);
select * from migrations order by id desc;
SELECT
CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,
u.email,
sa.*,
t.owner_id FROM social_accounts sa
JOIN users u on u.id = sa.sociable_id
JOIN teams t on t.id = u.team_id
WHERE u.team_id = 1 and sa.provider = 'salesforce';
select * from teams where id = 1;
select * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;
select * from groups where id = 565;
select * from playbooks where team_id = 1;
select * from playbooks where id = 175;
select * from playbook_categories where playbook_id = 175;
select * from users where team_id = 1;
select * from users where id = 7160;
select * from crm_profiles where user_id = 7160;
select * from features;
select
*
# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,
# crm_configuration_id, crm_provider_id, transcription_id, status
from activities where crm_configuration_id = 1 and type = 'conference'
# and crm_provider_id IS NOT NULL
and provider != 'uploader' and actual_start_time IS NOT NULL
ORDER by id desc;
select * from activities where id = 54747783; # 00UO400000pCzojMAC
select p.id, p.activity_type, pc.id, pc.name
FROM playbooks p
join playbook_categories pc on p.id = pc.playbook_id
where p.team_id = 1 and p.activity_type = 'event';
SELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';
SELECT * FROM crm_field_values WHERE crm_field_id = 4;
select * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id
where crm_configuration_id = 1 and pl.playbook_id = 175;
select * from teams;
SELECT r.* FROM automated_reports r
join teams t on r.team_id = t.id
WHERE r.frequency = 'daily'
and r.status = 1
AND t.status = 'active'
AND (r.expires_at >= now() OR r.expires_at IS NULL);
select * from automated_report_results where report_id IN (18, 33);
select * from automated_reports;
select * from automated_report_results where report_id IN (34);
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
[{"role":"AXButton","text" [{"role":"AXButton","text":"Project: faVsco.js, menu","depth":5,"bounds":{"left":0.03046875,"top":0.017361112,"width":0.0453125,"height":0.022222223},"help_text":"~/jiminny/app","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"#11894 on JY-18909-automated-reports-ask-jiminny, menu","depth":5,"bounds":{"left":0.07578125,"top":0.017361112,"width":0.14960937,"height":0.022222223},"help_text":"Pull request #11894 exists for current branch JY-18909-automated-reports-ask-jiminny, but local branch is out of sync with remote","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Start Listening for PHP Debug Connections","depth":5,"bounds":{"left":0.76171875,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"RequestGenerateAskJiminnyReportJobTest","depth":6,"bounds":{"left":0.7796875,"top":0.017361112,"width":0.12109375,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Run 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"bounds":{"left":0.9007813,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Debug 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"bounds":{"left":0.9140625,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"More Actions","depth":6,"bounds":{"left":0.9273437,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"JetBrains AI","depth":5,"bounds":{"left":0.96015626,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Search Everywhere","depth":5,"bounds":{"left":0.9734375,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"IDE and Project Settings","depth":5,"bounds":{"left":0.9867188,"top":0.017361112,"width":0.013281226,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.049609374,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Console\\Commands\\Reports;\n\nuse Carbon\\Carbon;\nuse Illuminate\\Console\\Command;\nuse Illuminate\\Contracts\\Bus\\Dispatcher as BusDispatcher;\nuse Jiminny\\Jobs\\AutomatedReports\\RequestGenerateAskJiminnyReportJob;\nuse Jiminny\\Jobs\\AutomatedReports\\RequestGenerateReportJob;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Repositories\\AutomatedReportsRepository;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Psr\\Log\\LoggerInterface;\n\nclass AutomatedReportsCommand extends Command\n{\n /**\n * Log prefix for all log messages\n */\n private const string LOG_PREFIX = '[automated-reports]';\n\n /**\n * The name and signature of the console command.\n *\n * @var string\n */\n protected $signature = 'automated-reports {--report-id= : Process a specific report by ID or UUID (bypasses frequency scheduling)}';\n\n /**\n * The console command description.\n *\n * @var string\n */\n protected $description = 'Process automated reports based on their frequency (weekly, monthly, quarterly). Use --report-id to manually trigger a specific report by ID or UUID.';\n\n\n public function __construct(\n private readonly LoggerInterface $logger,\n private readonly BusDispatcher $dispatcher,\n private readonly AutomatedReportsRepository $reportRepository\n ) {\n parent::__construct();\n }\n\n /**\n * Execute the console command.\n *\n * @return int\n */\n public function handle(): int\n {\n $this->logger->info(self::LOG_PREFIX . ' Started');\n\n $reportId = $this->option('report-id');\n\n if ($reportId !== null) {\n return $this->processSingleReport((string) $reportId);\n }\n\n $now = Carbon::now();\n $isMonday = $now->isMonday();\n $isFirstDayOfMonth = $now->day === 1;\n $currentMonth = $now->month;\n\n // Check if the current month is a quarterly month (January, April, July, October)\n $isQuarterlyMonth = in_array($currentMonth, [1, 4, 7, 10], true);\n\n $this->logger->info(self::LOG_PREFIX . ' Checking conditions', [\n 'isMonday' => $isMonday,\n 'isFirstDayOfMonth' => $isFirstDayOfMonth,\n 'currentMonth' => $currentMonth,\n 'isQuarterlyMonth' => $isQuarterlyMonth,\n ]);\n\n // Process daily reports\n $this->processReports(AutomatedReportsService::FREQUENCY_DAILY);\n\n // Process weekly reports on Mondays\n if ($isMonday) {\n $this->processReports(AutomatedReportsService::FREQUENCY_WEEKLY);\n }\n\n // Process monthly reports on the first day of the month\n if ($isFirstDayOfMonth) {\n $this->processReports(AutomatedReportsService::FREQUENCY_MONTHLY);\n }\n\n // Process quarterly reports on the first day of January, April, July, and October\n if ($isFirstDayOfMonth && $isQuarterlyMonth) {\n $this->processReports(AutomatedReportsService::FREQUENCY_QUARTERLY);\n }\n\n $this->logger->info(self::LOG_PREFIX . ' Completed');\n\n return 0;\n }\n\n private function processSingleReport(string $reportId): int\n {\n $this->logger->info(self::LOG_PREFIX . ' Manual single-report mode', ['reportId' => $reportId]);\n\n $report = is_numeric($reportId)\n ? AutomatedReport::withTrashed()->find((int) $reportId)\n : AutomatedReport::withTrashed()->where('uuid', AutomatedReport::toOptimized($reportId))->first();\n\n if ($report === null) {\n $this->logger->error(self::LOG_PREFIX . ' Report not found', ['reportId' => $reportId]);\n $this->error(\"Report not found: {$reportId}\");\n\n return 1;\n }\n\n $this->warnIfNotApplicableForSchedule($report);\n\n $this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [\n 'reportUuid' => $report->getUuid(),\n 'teamId' => $report->getTeamId(),\n 'frequency' => $report->getFrequency(),\n 'type' => $report->getType(),\n ]);\n\n $job = $report->isAskJiminnyReport()\n ? new RequestGenerateAskJiminnyReportJob($report->getUuid())\n : new RequestGenerateReportJob($report->getUuid());\n\n $this->dispatcher->dispatchSync($job);\n\n $this->logger->info(self::LOG_PREFIX . ' Completed');\n\n return 0;\n }\n\n private function warnIfNotApplicableForSchedule(AutomatedReport $report): void\n {\n if ($report->trashed()) {\n $this->warn('Report is soft-deleted (deleted_at: ' . $report->getDeletedAt()?->toDateTimeString() . ').');\n }\n\n if (! $report->getStatus()) {\n $this->warn('Report status is inactive — would be skipped in scheduled run.');\n }\n\n $team = $report->getTeam();\n if ($team->getStatus() !== Team::STATUS_ACTIVE) {\n $this->warn(\"Team #{$report->getTeamId()} is not active (status: {$team->getStatus()}) — would be skipped in scheduled run.\");\n }\n\n if ($report->isExpired()) {\n $this->warn('Report is expired (expires_at: ' . $report->getExpiresAt()?->toDateString() . ') — would be skipped in scheduled run.');\n }\n\n $now = Carbon::now();\n $frequency = $report->getFrequency();\n $wouldRunToday = match ($frequency) {\n AutomatedReportsService::FREQUENCY_DAILY => true,\n AutomatedReportsService::FREQUENCY_WEEKLY => $now->isMonday(),\n AutomatedReportsService::FREQUENCY_MONTHLY => $now->day === 1,\n AutomatedReportsService::FREQUENCY_QUARTERLY => $now->day === 1 && in_array($now->month, [1, 4, 7, 10], true),\n default => false,\n };\n\n if (! $wouldRunToday) {\n $this->warn(\"Report frequency is '{$frequency}' — would NOT be scheduled to run today.\");\n }\n }\n\n /**\n * Process reports for a specific frequency.\n *\n * @param string $frequency\n *\n * @return void\n */\n private function processReports(string $frequency): void\n {\n $this->logger->info(self::LOG_PREFIX . \" Processing $frequency reports\");\n \n $reportId = $this->option('report-id');\n\n if ($reportId !== null) {\n $reports = $this->getReportById($reportId);\n } else {\n // Get all enabled, not deleted reports with active teams for the specified frequency\n $reports = $this->reportRepository->getActiveReportsByFrequency($frequency);\n \n }\n\n $this->logger->info(self::LOG_PREFIX . \" Found {$reports->count()} $frequency reports to process\");\n\n /** @var AutomatedReport $report */\n foreach ($reports as $report) {\n $this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [\n 'reportUuid' => $report->getUuid(),\n 'teamId' => $report->getTeamId(),\n 'frequency' => $report->getFrequency(),\n 'type' => $report->getType(),\n ]);\n\n $job = $report->isAskJiminnyReport()\n ? new RequestGenerateAskJiminnyReportJob($report->getUuid())\n : new RequestGenerateReportJob($report->getUuid());\n\n // $this->dispatcher->dispatch($job);\n $this->dispatcher->dispatchSync($job);\n }\n }\n}","depth":4,"value":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Console\\Commands\\Reports;\n\nuse Carbon\\Carbon;\nuse Illuminate\\Console\\Command;\nuse Illuminate\\Contracts\\Bus\\Dispatcher as BusDispatcher;\nuse Jiminny\\Jobs\\AutomatedReports\\RequestGenerateAskJiminnyReportJob;\nuse Jiminny\\Jobs\\AutomatedReports\\RequestGenerateReportJob;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Repositories\\AutomatedReportsRepository;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Psr\\Log\\LoggerInterface;\n\nclass AutomatedReportsCommand extends Command\n{\n /**\n * Log prefix for all log messages\n */\n private const string LOG_PREFIX = '[automated-reports]';\n\n /**\n * The name and signature of the console command.\n *\n * @var string\n */\n protected $signature = 'automated-reports {--report-id= : Process a specific report by ID or UUID (bypasses frequency scheduling)}';\n\n /**\n * The console command description.\n *\n * @var string\n */\n protected $description = 'Process automated reports based on their frequency (weekly, monthly, quarterly). Use --report-id to manually trigger a specific report by ID or UUID.';\n\n\n public function __construct(\n private readonly LoggerInterface $logger,\n private readonly BusDispatcher $dispatcher,\n private readonly AutomatedReportsRepository $reportRepository\n ) {\n parent::__construct();\n }\n\n /**\n * Execute the console command.\n *\n * @return int\n */\n public function handle(): int\n {\n $this->logger->info(self::LOG_PREFIX . ' Started');\n\n $reportId = $this->option('report-id');\n\n if ($reportId !== null) {\n return $this->processSingleReport((string) $reportId);\n }\n\n $now = Carbon::now();\n $isMonday = $now->isMonday();\n $isFirstDayOfMonth = $now->day === 1;\n $currentMonth = $now->month;\n\n // Check if the current month is a quarterly month (January, April, July, October)\n $isQuarterlyMonth = in_array($currentMonth, [1, 4, 7, 10], true);\n\n $this->logger->info(self::LOG_PREFIX . ' Checking conditions', [\n 'isMonday' => $isMonday,\n 'isFirstDayOfMonth' => $isFirstDayOfMonth,\n 'currentMonth' => $currentMonth,\n 'isQuarterlyMonth' => $isQuarterlyMonth,\n ]);\n\n // Process daily reports\n $this->processReports(AutomatedReportsService::FREQUENCY_DAILY);\n\n // Process weekly reports on Mondays\n if ($isMonday) {\n $this->processReports(AutomatedReportsService::FREQUENCY_WEEKLY);\n }\n\n // Process monthly reports on the first day of the month\n if ($isFirstDayOfMonth) {\n $this->processReports(AutomatedReportsService::FREQUENCY_MONTHLY);\n }\n\n // Process quarterly reports on the first day of January, April, July, and October\n if ($isFirstDayOfMonth && $isQuarterlyMonth) {\n $this->processReports(AutomatedReportsService::FREQUENCY_QUARTERLY);\n }\n\n $this->logger->info(self::LOG_PREFIX . ' Completed');\n\n return 0;\n }\n\n private function processSingleReport(string $reportId): int\n {\n $this->logger->info(self::LOG_PREFIX . ' Manual single-report mode', ['reportId' => $reportId]);\n\n $report = is_numeric($reportId)\n ? AutomatedReport::withTrashed()->find((int) $reportId)\n : AutomatedReport::withTrashed()->where('uuid', AutomatedReport::toOptimized($reportId))->first();\n\n if ($report === null) {\n $this->logger->error(self::LOG_PREFIX . ' Report not found', ['reportId' => $reportId]);\n $this->error(\"Report not found: {$reportId}\");\n\n return 1;\n }\n\n $this->warnIfNotApplicableForSchedule($report);\n\n $this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [\n 'reportUuid' => $report->getUuid(),\n 'teamId' => $report->getTeamId(),\n 'frequency' => $report->getFrequency(),\n 'type' => $report->getType(),\n ]);\n\n $job = $report->isAskJiminnyReport()\n ? new RequestGenerateAskJiminnyReportJob($report->getUuid())\n : new RequestGenerateReportJob($report->getUuid());\n\n $this->dispatcher->dispatchSync($job);\n\n $this->logger->info(self::LOG_PREFIX . ' Completed');\n\n return 0;\n }\n\n private function warnIfNotApplicableForSchedule(AutomatedReport $report): void\n {\n if ($report->trashed()) {\n $this->warn('Report is soft-deleted (deleted_at: ' . $report->getDeletedAt()?->toDateTimeString() . ').');\n }\n\n if (! $report->getStatus()) {\n $this->warn('Report status is inactive — would be skipped in scheduled run.');\n }\n\n $team = $report->getTeam();\n if ($team->getStatus() !== Team::STATUS_ACTIVE) {\n $this->warn(\"Team #{$report->getTeamId()} is not active (status: {$team->getStatus()}) — would be skipped in scheduled run.\");\n }\n\n if ($report->isExpired()) {\n $this->warn('Report is expired (expires_at: ' . $report->getExpiresAt()?->toDateString() . ') — would be skipped in scheduled run.');\n }\n\n $now = Carbon::now();\n $frequency = $report->getFrequency();\n $wouldRunToday = match ($frequency) {\n AutomatedReportsService::FREQUENCY_DAILY => true,\n AutomatedReportsService::FREQUENCY_WEEKLY => $now->isMonday(),\n AutomatedReportsService::FREQUENCY_MONTHLY => $now->day === 1,\n AutomatedReportsService::FREQUENCY_QUARTERLY => $now->day === 1 && in_array($now->month, [1, 4, 7, 10], true),\n default => false,\n };\n\n if (! $wouldRunToday) {\n $this->warn(\"Report frequency is '{$frequency}' — would NOT be scheduled to run today.\");\n }\n }\n\n /**\n * Process reports for a specific frequency.\n *\n * @param string $frequency\n *\n * @return void\n */\n private function processReports(string $frequency): void\n {\n $this->logger->info(self::LOG_PREFIX . \" Processing $frequency reports\");\n \n $reportId = $this->option('report-id');\n\n if ($reportId !== null) {\n $reports = $this->getReportById($reportId);\n } else {\n // Get all enabled, not deleted reports with active teams for the specified frequency\n $reports = $this->reportRepository->getActiveReportsByFrequency($frequency);\n \n }\n\n $this->logger->info(self::LOG_PREFIX . \" Found {$reports->count()} $frequency reports to process\");\n\n /** @var AutomatedReport $report */\n foreach ($reports as $report) {\n $this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [\n 'reportUuid' => $report->getUuid(),\n 'teamId' => $report->getTeamId(),\n 'frequency' => $report->getFrequency(),\n 'type' => $report->getType(),\n ]);\n\n $job = $report->isAskJiminnyReport()\n ? new RequestGenerateAskJiminnyReportJob($report->getUuid())\n : new RequestGenerateReportJob($report->getUuid());\n\n // $this->dispatcher->dispatch($job);\n $this->dispatcher->dispatchSync($job);\n }\n }\n}","role_description":"text entry area","is_enabled":true,"is_focused":true,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Execute","depth":4,"bounds":{"left":0.4828125,"top":0.12916666,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Explain Plan","depth":4,"bounds":{"left":0.49296874,"top":0.12916666,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Browse Query History","depth":4,"bounds":{"left":0.5058594,"top":0.12916666,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"View Parameters","depth":4,"bounds":{"left":0.51601565,"top":0.12916666,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Open Query Execution Settings…","depth":4,"bounds":{"left":0.52617186,"top":0.12916666,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"In-Editor Results","depth":4,"bounds":{"left":0.5390625,"top":0.12916666,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Tx: Auto","depth":4,"bounds":{"left":0.55195314,"top":0.12916666,"width":0.028515626,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Cancel Running Statements","depth":4,"bounds":{"left":0.58320314,"top":0.12916666,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Playground","depth":4,"bounds":{"left":0.5960938,"top":0.12916666,"width":0.034765624,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"jiminny","depth":4,"bounds":{"left":0.6738281,"top":0.12916666,"width":0.033203125,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.049609374,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"16","depth":4,"bounds":{"left":0.65117186,"top":0.15069444,"width":0.011328125,"height":0.013194445},"role_description":"text"},{"role":"AXStaticText","text":"13","depth":4,"bounds":{"left":0.66484374,"top":0.15069444,"width":0.011328125,"height":0.013194445},"role_description":"text"},{"role":"AXStaticText","text":"13","depth":4,"bounds":{"left":0.6785156,"top":0.15069444,"width":0.011328125,"height":0.013194445},"role_description":"text"},{"role":"AXButton","text":"Previous Highlighted Error","depth":4,"bounds":{"left":0.6917969,"top":0.14930555,"width":0.00859375,"height":0.015972223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Next Highlighted Error","depth":4,"bounds":{"left":0.70039064,"top":0.14930555,"width":0.008203125,"height":0.015972223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"SELECT * FROM teams WHERE id = 1;\n\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;\nSELECT * FROM crm_fields WHERE id = 2234;\nSELECT * FROM crm_field_values WHERE crm_field_id = 2234;\n\nselect * from crm_profiles where user_id = 143;\n\nselect * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO\nselect * from business_processes where crm_configuration_id = 39;\n# 01941000000H669AAC, 01941000000H66JAAS\n\nselect * from record_type_field_values\n where record_type_id IN (24);\n\nselect * from crm_field_values where id IN (2730);\n\nselect * from crm_configurations where id = 39;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce'; #1035\n\n\nselect * from users where team_id = 1; # 222 group 3\nSELECT * FROM activities WHERE user_id = 222 order by id desc;\nselect * from sidekick_settings where team_id = 1;\nselect * from teams where id = 1;\nselect * from team_features where team_id = 1;\n\nselect * from activities where crm_configuration_id = 2\nand provider = 'ms-teams' and id = 608765;\n\nSELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';\n\nselect * from sidekick_settings where team_id = 2;\n\nSELECT * FROM activities WHERE id = 608660;\nselect * from activity_summary_logs where activity_id = 608660;\nselect * from ai_prompts where transcription_id = 11214;\n\n# ********************************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;\n# id: 608818, crm: 59628809737\nSELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;\n# id: 608821, crm: 59632069252\nSELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,\nplaybook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,\nscheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at\nFROM activities a\njoin calendar_events ce on a.calendar_event_id = ce.id\nWHERE a.id IN (608818, 608821);\n\nselect * from users where team_id = 1;\nselect * from team_settings where team_id = 1;\nselect * from crm_profiles where crm_configuration_id = 39 order by user_id;\n\nselect * from team_features where team_id = 1;\n\nselect * from users where team_id = 2;\n\nSELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639\n# Preslava N. Ivanova, grou id 3\n\nSELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;\n\nselect * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';\n\nselect\n a.id,\n a.type,\n a.scheduled_start_time,\n a.actual_start_time,\n a.created_at,\n a.opportunity_id,\n a.status\nFROM activities a\nWHERE opportunity_id = 344\nand status IN ('completed', 'received', 'delivered')\nand (\n (a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))\n;\n\nSELECT * FROM users WHERE id = 222;\n\nSELECT * FROM crm_profiles WHERE user_id = 222;\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;\n\nselect * from group_deal_risk_types;\n\nselect * from opportunities where team_id = 1;\n\nSELECT * FROM opportunities WHERE id = 315;\nSELECT * FROM crm_field_data WHERE object_id = 315;\nselect * from crm_field_data where object_id = 260;\n\nselect * from generic_ai_prompts where subject_id = 315;\n\nselect * from teams; # 36, 21, 121, james.graham@bullhorn.jiminny.com\nSELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';\n\n# ************************************************************************************\nselect * from teams where id = 1;\nselect * from crm_configurations where id = 39;\nselect * from users where team_id = 1;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 1;\n# 1 - 00541000004281rAAA\n# 204 - 0052g000003freeAAA\n# 429 - 0052g000003qGOiAAM\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\nselect * from activities where type = 'softphone'\nand created_at > '2024-12-11 15:24:36' order by id desc;\n\nselect * from activity_providers where team_id = 1;\nselect * from activity_provider_users where activity_provider_id = 328;\n\nselect * from opportunities where crm_configuration_id = 39\nAND account_id = 178 AND is_closed = false\norder by created_at DESC;\n\nselect * from contacts where id = 3952;\nselect * from accounts where id = 178;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations where id = 21;\nselect * from users where team_id = 36;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 36;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 36\nand sa.provider = 'bullhorn';\n\nselect * from social_accounts where id = 348;\nUPDATE social_accounts SET\nprovider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',\nprovider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',\nexpires = 1733998131,\nstate = 'connected'\nWHERE id = 348;\n\n# ************************************************************************************\nselect * from teams where id = 31;\nselect * from crm_configurations where id = 18;\n\nselect * from users where team_id = 31; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 31;\n\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 31\nand sa.provider = 'close';\n\nselect * from contacts where crm_configuration_id = 18;\n\n# ********************** NEPTUNE **************************************************************\nselect * from teams;\nselect * from users where id IN (1030, 1035, 1052);\nselect * from crm_configurations;\n\nselect * from users where team_id = 65; # 257\nselect * from team_settings where team_id = 65; # 257\nselect * from invitations where team_id = 65; # 257\nselect * from users where email = 'integration-account@jiminny.com'; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 65;\n\nselect * from crm_configurations where id = 53;\nselect * from accounts where crm_configuration_id = 53 order by id desc;\nselect * from leads where crm_configuration_id = 53 order by id desc;\nselect * from contacts where crm_configuration_id = 53 order by id desc;\nselect * from opportunities where crm_configuration_id = 53 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 53 order by id desc;\nselect * from crm_fields where crm_configuration_id = 53 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 53 order by id desc;\nselect * from stages where crm_configuration_id = 53 order by id desc;\n\n\nselect * from crm_profiles where crm_configuration_id = 13;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\nand sa.provider = 'integration-app';\n\nselect * from contacts where crm_configuration_id = 13;\n\nselect * from social_accounts where sociable_id = 283;\n\nSELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';\n\nselect * from activity_providers where team_id = 65;\nSELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\n;\n\n# ***************************** STAGING ********************************************\nSELECT * FROM teams;\nSELECT * FROM teams WHERE id = 88;\nSELECT * FROM teams WHERE id = 89;\nselect * from team_settings where team_id = 89;\nSELECT * FROM users WHERE team_id = 89;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 89;\n\nselect * from users;\nSELECT * FROM social_accounts WHERE sociable_id = 1761;\nSELECT * FROM crm_configurations WHERE id = 70;\nselect * from accounts where crm_configuration_id = 70 order by id desc;\nselect * from leads where crm_configuration_id = 70 order by id desc;\nselect * from contacts where crm_configuration_id = 70 order by id desc;\nselect * from opportunities where crm_configuration_id = 70 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 70 order by id desc;\nselect * from crm_fields where crm_configuration_id = 70 order by id desc;\nselect * from crm_field_values where crm_field_id = 3536 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 70 order by id desc;\nselect * from stages where crm_configuration_id = 70 order by id desc;\nselect * from business_processes where crm_configuration_id = 70 order by id desc;\nselect * from business_process_stages where business_process_id = 34;\n\nselect * from contacts where id = 10468;\n\nselect * from crm_layouts where crm_configuration_id = 70;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;\nSELECT * FROM crm_fields WHERE id IN (3533,3534,3535);\n\nselect * from activities where crm_configuration_id = 70\nand (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;\n\nSELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;\nSELECT * FROM activities where crm_configuration_id = 69 ;\n\nSELECT * FROM users WHERE email LIKE '%jiminny_web_sa2@jiminny.com%';\nSELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;\nSELECT * FROM opportunities WHERE id = 385;\n\nselect * from participants p\njoin activities a on p.activity_id = a.id\nwhere a.crm_configuration_id = 70\nand (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);\nSELECT * FROM participants WHERE id = 1013638;\n\nselect * from teams where id = 90;\nselect * from users where team_id = 90;\nselect * from social_accounts where social_accounts.sociable_id IN (1960,1760);\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 71;\nselect * from invitations where team_id = 90;\n\nselect * from crm_configurations where id = 71;\nselect * from accounts where crm_configuration_id = 71 order by id desc;\nselect * from leads where crm_configuration_id = 71 order by id desc;\nselect * from contacts where crm_configuration_id = 71 order by id desc;\nselect * from opportunities where crm_configuration_id = 71 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 71 order by id desc;\nselect * from crm_fields where crm_configuration_id = 71 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 71 order by id desc;\nselect * from stages where crm_configuration_id = 71 order by id desc;\n\nselect * from users order by secondary_email desc;\nselect u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa\n join users u on sa.sociable_id = u.id\nwhere sa.provider = 'google' and u.email LIKE 'aneliya%';\n\nselect * from failed_jobs order by id desc;\n\nselect * from users where email = 'ben.allwright@learningpeople.co.uk' or secondary_email = 'ben.allwright@learningpeople.co.uk';\n\nselect * from teams;\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 39;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\n# ************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;\nSELECT * FROM crm_configurations WHERE id = 70;\n\nselect * from teams where id = 1;\nselect * from groups where team_id = 1;\nselect * from users where team_id = 1;\n\nselect o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o\njoin users u on o.user_id = u.id\njoin groups g on u.group_id = g.id\njoin role_user ru on u.id = ru.user_id\njoin roles r on ru.role_id = r.id\nwhere o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';\n\nselect * from role_user where user_id = 143;\nselect * from roles;\n\nselect * from role_user;\nselect * from groups where id = 9;\nselect * from scope_groups where group_id = 9;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations;\nSELECT * FROM social_accounts WHERE sociable_id = 121;\n\nhttps://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105\nhttps://crmsandbox.zoho.com/crm/\n\nhttps://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080\n https://crm.zoho.com/crm/\n org3469620\n\nSELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;\n\nselect * from users where email LIKE \"%mobile_automation_%\";\nselect * from social_accounts where sociable_id IN (2228);\nselect * from crm_profiles where user_id IN (2222,2223,2226,2227);\n\nselect * from teams order by id desc;\nSELECT * FROM users WHERE id = 2229;\nSELECT * FROM crm_profiles WHERE user_id = 2229;\nselect * from opportunities where crm_configuration_id = 88;\nselect * from crm_fields where crm_configuration_id = 88;\nselect * from crm_profiles where crm_configuration_id = 88;\n\nSELECT * FROM teams WHERE id = 1;\n\nSELECT * FROM users WHERE id = 143;\nSELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;\n\nhttps://app.staging.jiminny.com/ondemand?\n min_duration=1\n &\n only_recorded=1\n &\n user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e\n &\n sequence_number=2\n\n select * from users where team_id = 1 and email like '%stoyan%'\n\nselect * from coaching_feedbacks;\n\nselect * from teams;\nSELECT * FROM users WHERE team_id = 36;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from users where id = 143;\n\nSELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\n\nselect * from users where team_id = 2;\nselect * from activities where crm_configuration_id = 39\nand activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'\nAND user_id = 143\norder by id desc;\n\n# ************************************************************************************\nselect * from teams where id = 142; # 2312, 126\nselect * from team_settings;\nselect * from users where team_id = 142; # 21642\nSELECT * FROM social_accounts WHERE sociable_id = 21642;\nSELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;\nselect * from crm_profiles where id IN (93);\nselect * from invitations;\nselect * from team_features where team_id = 1;\n\nSELECT * FROM crm_configurations WHERE id = 126;\nselect * from accounts where crm_configuration_id = 126 order by id desc;\nselect * from leads where crm_configuration_id = 126 order by id desc;\nselect * from contacts where crm_configuration_id = 126 order by id desc;\nselect * from opportunities where crm_configuration_id = 126 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 126 order by id desc;\nselect * from crm_fields where crm_configuration_id = 126 # 11060\n# and type IN ('picklist', 'status')\n# and object_type = 'task'\norder by id desc;\n# 5731,5732,5733\nselect DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;\nselect * from crm_layouts where crm_configuration_id = 126 order by id desc;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);\nselect * from stages where crm_configuration_id = 126 order by id desc;\nselect * from business_processes where crm_configuration_id = 126 order by id desc;\nselect * from business_process_stages where business_process_id IN (76,75,74,73);\nselect * from playbooks where team_id = 142;\nselect * from playbook_layouts where playbook_id IN (108);\nSELECT * FROM playbook_categories WHERE playbook_id IN (108);\n\nselect * from teams where id = 130;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 2\nand sa.provider = 'hubspot';\n\nSELECT * FROM activities\n WHERE crm_configuration_id = 110;\n\nselect * from teams;\nselect * from crm_configurations;\n\nSELECT * FROM activities WHERE id = 628773;\nSELECT * FROM crm_profiles WHERE user_id = 1460;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from teams;\nselect ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id\njoin permission_role pr on pr.role_id = ru.role_id\n join permissions p on p.id = pr.permission_id\nwhere team_id = 495 and p.name IN ('dial');\n\nselect * from teams where id = 145;\nselect * from crm_configurations where id = 129;\nselect * from social_accounts where sociable_id = 2317;\nSELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;\n\nselect * from teams where id = 1;\nSELECT * FROM crm_layouts WHERE crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;\nSELECT * FROM crm_layout_entities WHERE id = 5507;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');\n\nselect * from teams;\nselect * from activities where crm_configuration_id = 14;\n\nSELECT * FROM social_accounts where provider = 'copper';\n\nselect * from activities where id = 628467;\nselect * from participants where activity_id = 628467;\n\nSELECT * FROM contacts WHERE id = 3969;\nSELECT * FROM accounts WHERE id = 177;\n\nSELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;\n\n# ********************* BH\nselect * from teams where id = 36;\nSELECT * FROM crm_configurations WHERE id = 21;\nselect * from activities where crm_configuration_id = 21 and id = 607901;\nselect * from activities where crm_configuration_id = 21;\n\nselect * roles;\nselect * from permissions;\nselect * from permission_role where permission_id = 226;\n\nselect * from migrations order by id desc;\n\n# mercury\n# neptune\n# earth\n\nselect * from teams;\nselect * from teams where id = 19;\nselect * from teams where id = 27;\nselect * from users where team_id = 27;\nSELECT * FROM crm_configurations WHERE id = 42;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from activities where id = 631461;\nSELECT * FROM crm_field_values WHERE crm_field_id = 180;\n\nselect * from teams where id = 2;\nSELECT * FROM social_accounts WHERE sociable_id = 89;\n\nSELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273\nselect * from activity_summary_logs where activity_id = 634273;\n\nselect * from sidekick_settings where team_id = 2;\n\nselect * from teams; # 2, 2\nSELECT * FROM crm_configurations WHERE team_id = 2; # 2\nselect * from team_features where team_id = 2;\nselect * from features;\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;\n\nselect * from automated_reports order by id desc;\nselect * from automated_report_results order by id desc;\nselect * from users where team_id = 1 and id IN (7160, 3248);\nselect * from migrations order by id desc;\n\nSELECT\n CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,\n u.email,\n sa.*,\n t.owner_id FROM social_accounts sa\nJOIN users u on u.id = sa.sociable_id\nJOIN teams t on t.id = u.team_id\nWHERE u.team_id = 1 and sa.provider = 'salesforce';\n\nselect * from teams where id = 1;\nselect * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;\nselect * from groups where id = 565;\nselect * from playbooks where team_id = 1;\nselect * from playbooks where id = 175;\nselect * from playbook_categories where playbook_id = 175;\nselect * from users where team_id = 1;\nselect * from users where id = 7160;\nselect * from crm_profiles where user_id = 7160;\nselect * from features;\nselect\n *\n# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,\n# crm_configuration_id, crm_provider_id, transcription_id, status\nfrom activities where crm_configuration_id = 1 and type = 'conference'\n# and crm_provider_id IS NOT NULL\nand provider != 'uploader' and actual_start_time IS NOT NULL\nORDER by id desc;\nselect * from activities where id = 54747783; # 00UO400000pCzojMAC\n\nselect p.id, p.activity_type, pc.id, pc.name\nFROM playbooks p\njoin playbook_categories pc on p.id = pc.playbook_id\nwhere p.team_id = 1 and p.activity_type = 'event';\n\nSELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';\nSELECT * FROM crm_field_values WHERE crm_field_id = 4;\n\nselect * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id\nwhere crm_configuration_id = 1 and pl.playbook_id = 175;\n\nselect * from teams;\nSELECT r.* FROM automated_reports r\njoin teams t on r.team_id = t.id\nWHERE r.frequency = 'daily'\n and r.status = 1\nAND t.status = 'active'\nAND (r.expires_at >= now() OR r.expires_at IS NULL);\n\nselect * from automated_report_results where report_id IN (18, 33);\n\nselect * from automated_reports;\nselect * from automated_report_results where report_id IN (34);","depth":4,"value":"SELECT * FROM teams WHERE id = 1;\n\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;\nSELECT * FROM crm_fields WHERE id = 2234;\nSELECT * FROM crm_field_values WHERE crm_field_id = 2234;\n\nselect * from crm_profiles where user_id = 143;\n\nselect * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO\nselect * from business_processes where crm_configuration_id = 39;\n# 01941000000H669AAC, 01941000000H66JAAS\n\nselect * from record_type_field_values\n where record_type_id IN (24);\n\nselect * from crm_field_values where id IN (2730);\n\nselect * from crm_configurations where id = 39;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce'; #1035\n\n\nselect * from users where team_id = 1; # 222 group 3\nSELECT * FROM activities WHERE user_id = 222 order by id desc;\nselect * from sidekick_settings where team_id = 1;\nselect * from teams where id = 1;\nselect * from team_features where team_id = 1;\n\nselect * from activities where crm_configuration_id = 2\nand provider = 'ms-teams' and id = 608765;\n\nSELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';\n\nselect * from sidekick_settings where team_id = 2;\n\nSELECT * FROM activities WHERE id = 608660;\nselect * from activity_summary_logs where activity_id = 608660;\nselect * from ai_prompts where transcription_id = 11214;\n\n# ********************************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;\n# id: 608818, crm: 59628809737\nSELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;\n# id: 608821, crm: 59632069252\nSELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,\nplaybook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,\nscheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at\nFROM activities a\njoin calendar_events ce on a.calendar_event_id = ce.id\nWHERE a.id IN (608818, 608821);\n\nselect * from users where team_id = 1;\nselect * from team_settings where team_id = 1;\nselect * from crm_profiles where crm_configuration_id = 39 order by user_id;\n\nselect * from team_features where team_id = 1;\n\nselect * from users where team_id = 2;\n\nSELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639\n# Preslava N. Ivanova, grou id 3\n\nSELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;\n\nselect * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';\n\nselect\n a.id,\n a.type,\n a.scheduled_start_time,\n a.actual_start_time,\n a.created_at,\n a.opportunity_id,\n a.status\nFROM activities a\nWHERE opportunity_id = 344\nand status IN ('completed', 'received', 'delivered')\nand (\n (a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))\n;\n\nSELECT * FROM users WHERE id = 222;\n\nSELECT * FROM crm_profiles WHERE user_id = 222;\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;\n\nselect * from group_deal_risk_types;\n\nselect * from opportunities where team_id = 1;\n\nSELECT * FROM opportunities WHERE id = 315;\nSELECT * FROM crm_field_data WHERE object_id = 315;\nselect * from crm_field_data where object_id = 260;\n\nselect * from generic_ai_prompts where subject_id = 315;\n\nselect * from teams; # 36, 21, 121, james.graham@bullhorn.jiminny.com\nSELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';\n\n# ************************************************************************************\nselect * from teams where id = 1;\nselect * from crm_configurations where id = 39;\nselect * from users where team_id = 1;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 1;\n# 1 - 00541000004281rAAA\n# 204 - 0052g000003freeAAA\n# 429 - 0052g000003qGOiAAM\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\nselect * from activities where type = 'softphone'\nand created_at > '2024-12-11 15:24:36' order by id desc;\n\nselect * from activity_providers where team_id = 1;\nselect * from activity_provider_users where activity_provider_id = 328;\n\nselect * from opportunities where crm_configuration_id = 39\nAND account_id = 178 AND is_closed = false\norder by created_at DESC;\n\nselect * from contacts where id = 3952;\nselect * from accounts where id = 178;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations where id = 21;\nselect * from users where team_id = 36;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 36;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 36\nand sa.provider = 'bullhorn';\n\nselect * from social_accounts where id = 348;\nUPDATE social_accounts SET\nprovider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',\nprovider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',\nexpires = 1733998131,\nstate = 'connected'\nWHERE id = 348;\n\n# ************************************************************************************\nselect * from teams where id = 31;\nselect * from crm_configurations where id = 18;\n\nselect * from users where team_id = 31; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 31;\n\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 31\nand sa.provider = 'close';\n\nselect * from contacts where crm_configuration_id = 18;\n\n# ********************** NEPTUNE **************************************************************\nselect * from teams;\nselect * from users where id IN (1030, 1035, 1052);\nselect * from crm_configurations;\n\nselect * from users where team_id = 65; # 257\nselect * from team_settings where team_id = 65; # 257\nselect * from invitations where team_id = 65; # 257\nselect * from users where email = 'integration-account@jiminny.com'; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 65;\n\nselect * from crm_configurations where id = 53;\nselect * from accounts where crm_configuration_id = 53 order by id desc;\nselect * from leads where crm_configuration_id = 53 order by id desc;\nselect * from contacts where crm_configuration_id = 53 order by id desc;\nselect * from opportunities where crm_configuration_id = 53 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 53 order by id desc;\nselect * from crm_fields where crm_configuration_id = 53 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 53 order by id desc;\nselect * from stages where crm_configuration_id = 53 order by id desc;\n\n\nselect * from crm_profiles where crm_configuration_id = 13;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\nand sa.provider = 'integration-app';\n\nselect * from contacts where crm_configuration_id = 13;\n\nselect * from social_accounts where sociable_id = 283;\n\nSELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';\n\nselect * from activity_providers where team_id = 65;\nSELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\n;\n\n# ***************************** STAGING ********************************************\nSELECT * FROM teams;\nSELECT * FROM teams WHERE id = 88;\nSELECT * FROM teams WHERE id = 89;\nselect * from team_settings where team_id = 89;\nSELECT * FROM users WHERE team_id = 89;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 89;\n\nselect * from users;\nSELECT * FROM social_accounts WHERE sociable_id = 1761;\nSELECT * FROM crm_configurations WHERE id = 70;\nselect * from accounts where crm_configuration_id = 70 order by id desc;\nselect * from leads where crm_configuration_id = 70 order by id desc;\nselect * from contacts where crm_configuration_id = 70 order by id desc;\nselect * from opportunities where crm_configuration_id = 70 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 70 order by id desc;\nselect * from crm_fields where crm_configuration_id = 70 order by id desc;\nselect * from crm_field_values where crm_field_id = 3536 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 70 order by id desc;\nselect * from stages where crm_configuration_id = 70 order by id desc;\nselect * from business_processes where crm_configuration_id = 70 order by id desc;\nselect * from business_process_stages where business_process_id = 34;\n\nselect * from contacts where id = 10468;\n\nselect * from crm_layouts where crm_configuration_id = 70;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;\nSELECT * FROM crm_fields WHERE id IN (3533,3534,3535);\n\nselect * from activities where crm_configuration_id = 70\nand (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;\n\nSELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;\nSELECT * FROM activities where crm_configuration_id = 69 ;\n\nSELECT * FROM users WHERE email LIKE '%jiminny_web_sa2@jiminny.com%';\nSELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;\nSELECT * FROM opportunities WHERE id = 385;\n\nselect * from participants p\njoin activities a on p.activity_id = a.id\nwhere a.crm_configuration_id = 70\nand (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);\nSELECT * FROM participants WHERE id = 1013638;\n\nselect * from teams where id = 90;\nselect * from users where team_id = 90;\nselect * from social_accounts where social_accounts.sociable_id IN (1960,1760);\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 71;\nselect * from invitations where team_id = 90;\n\nselect * from crm_configurations where id = 71;\nselect * from accounts where crm_configuration_id = 71 order by id desc;\nselect * from leads where crm_configuration_id = 71 order by id desc;\nselect * from contacts where crm_configuration_id = 71 order by id desc;\nselect * from opportunities where crm_configuration_id = 71 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 71 order by id desc;\nselect * from crm_fields where crm_configuration_id = 71 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 71 order by id desc;\nselect * from stages where crm_configuration_id = 71 order by id desc;\n\nselect * from users order by secondary_email desc;\nselect u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa\n join users u on sa.sociable_id = u.id\nwhere sa.provider = 'google' and u.email LIKE 'aneliya%';\n\nselect * from failed_jobs order by id desc;\n\nselect * from users where email = 'ben.allwright@learningpeople.co.uk' or secondary_email = 'ben.allwright@learningpeople.co.uk';\n\nselect * from teams;\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 39;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\n# ************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;\nSELECT * FROM crm_configurations WHERE id = 70;\n\nselect * from teams where id = 1;\nselect * from groups where team_id = 1;\nselect * from users where team_id = 1;\n\nselect o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o\njoin users u on o.user_id = u.id\njoin groups g on u.group_id = g.id\njoin role_user ru on u.id = ru.user_id\njoin roles r on ru.role_id = r.id\nwhere o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';\n\nselect * from role_user where user_id = 143;\nselect * from roles;\n\nselect * from role_user;\nselect * from groups where id = 9;\nselect * from scope_groups where group_id = 9;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations;\nSELECT * FROM social_accounts WHERE sociable_id = 121;\n\nhttps://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105\nhttps://crmsandbox.zoho.com/crm/\n\nhttps://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080\n https://crm.zoho.com/crm/\n org3469620\n\nSELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;\n\nselect * from users where email LIKE \"%mobile_automation_%\";\nselect * from social_accounts where sociable_id IN (2228);\nselect * from crm_profiles where user_id IN (2222,2223,2226,2227);\n\nselect * from teams order by id desc;\nSELECT * FROM users WHERE id = 2229;\nSELECT * FROM crm_profiles WHERE user_id = 2229;\nselect * from opportunities where crm_configuration_id = 88;\nselect * from crm_fields where crm_configuration_id = 88;\nselect * from crm_profiles where crm_configuration_id = 88;\n\nSELECT * FROM teams WHERE id = 1;\n\nSELECT * FROM users WHERE id = 143;\nSELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;\n\nhttps://app.staging.jiminny.com/ondemand?\n min_duration=1\n &\n only_recorded=1\n &\n user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e\n &\n sequence_number=2\n\n select * from users where team_id = 1 and email like '%stoyan%'\n\nselect * from coaching_feedbacks;\n\nselect * from teams;\nSELECT * FROM users WHERE team_id = 36;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from users where id = 143;\n\nSELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\n\nselect * from users where team_id = 2;\nselect * from activities where crm_configuration_id = 39\nand activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'\nAND user_id = 143\norder by id desc;\n\n# ************************************************************************************\nselect * from teams where id = 142; # 2312, 126\nselect * from team_settings;\nselect * from users where team_id = 142; # 21642\nSELECT * FROM social_accounts WHERE sociable_id = 21642;\nSELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;\nselect * from crm_profiles where id IN (93);\nselect * from invitations;\nselect * from team_features where team_id = 1;\n\nSELECT * FROM crm_configurations WHERE id = 126;\nselect * from accounts where crm_configuration_id = 126 order by id desc;\nselect * from leads where crm_configuration_id = 126 order by id desc;\nselect * from contacts where crm_configuration_id = 126 order by id desc;\nselect * from opportunities where crm_configuration_id = 126 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 126 order by id desc;\nselect * from crm_fields where crm_configuration_id = 126 # 11060\n# and type IN ('picklist', 'status')\n# and object_type = 'task'\norder by id desc;\n# 5731,5732,5733\nselect DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;\nselect * from crm_layouts where crm_configuration_id = 126 order by id desc;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);\nselect * from stages where crm_configuration_id = 126 order by id desc;\nselect * from business_processes where crm_configuration_id = 126 order by id desc;\nselect * from business_process_stages where business_process_id IN (76,75,74,73);\nselect * from playbooks where team_id = 142;\nselect * from playbook_layouts where playbook_id IN (108);\nSELECT * FROM playbook_categories WHERE playbook_id IN (108);\n\nselect * from teams where id = 130;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 2\nand sa.provider = 'hubspot';\n\nSELECT * FROM activities\n WHERE crm_configuration_id = 110;\n\nselect * from teams;\nselect * from crm_configurations;\n\nSELECT * FROM activities WHERE id = 628773;\nSELECT * FROM crm_profiles WHERE user_id = 1460;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from teams;\nselect ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id\njoin permission_role pr on pr.role_id = ru.role_id\n join permissions p on p.id = pr.permission_id\nwhere team_id = 495 and p.name IN ('dial');\n\nselect * from teams where id = 145;\nselect * from crm_configurations where id = 129;\nselect * from social_accounts where sociable_id = 2317;\nSELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;\n\nselect * from teams where id = 1;\nSELECT * FROM crm_layouts WHERE crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;\nSELECT * FROM crm_layout_entities WHERE id = 5507;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');\n\nselect * from teams;\nselect * from activities where crm_configuration_id = 14;\n\nSELECT * FROM social_accounts where provider = 'copper';\n\nselect * from activities where id = 628467;\nselect * from participants where activity_id = 628467;\n\nSELECT * FROM contacts WHERE id = 3969;\nSELECT * FROM accounts WHERE id = 177;\n\nSELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;\n\n# ********************* BH\nselect * from teams where id = 36;\nSELECT * FROM crm_configurations WHERE id = 21;\nselect * from activities where crm_configuration_id = 21 and id = 607901;\nselect * from activities where crm_configuration_id = 21;\n\nselect * roles;\nselect * from permissions;\nselect * from permission_role where permission_id = 226;\n\nselect * from migrations order by id desc;\n\n# mercury\n# neptune\n# earth\n\nselect * from teams;\nselect * from teams where id = 19;\nselect * from teams where id = 27;\nselect * from users where team_id = 27;\nSELECT * FROM crm_configurations WHERE id = 42;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from activities where id = 631461;\nSELECT * FROM crm_field_values WHERE crm_field_id = 180;\n\nselect * from teams where id = 2;\nSELECT * FROM social_accounts WHERE sociable_id = 89;\n\nSELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273\nselect * from activity_summary_logs where activity_id = 634273;\n\nselect * from sidekick_settings where team_id = 2;\n\nselect * from teams; # 2, 2\nSELECT * FROM crm_configurations WHERE team_id = 2; # 2\nselect * from team_features where team_id = 2;\nselect * from features;\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;\n\nselect * from automated_reports order by id desc;\nselect * from automated_report_results order by id desc;\nselect * from users where team_id = 1 and id IN (7160, 3248);\nselect * from migrations order by id desc;\n\nSELECT\n CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,\n u.email,\n sa.*,\n t.owner_id FROM social_accounts sa\nJOIN users u on u.id = sa.sociable_id\nJOIN teams t on t.id = u.team_id\nWHERE u.team_id = 1 and sa.provider = 'salesforce';\n\nselect * from teams where id = 1;\nselect * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;\nselect * from groups where id = 565;\nselect * from playbooks where team_id = 1;\nselect * from playbooks where id = 175;\nselect * from playbook_categories where playbook_id = 175;\nselect * from users where team_id = 1;\nselect * from users where id = 7160;\nselect * from crm_profiles where user_id = 7160;\nselect * from features;\nselect\n *\n# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,\n# crm_configuration_id, crm_provider_id, transcription_id, status\nfrom activities where crm_configuration_id = 1 and type = 'conference'\n# and crm_provider_id IS NOT NULL\nand provider != 'uploader' and actual_start_time IS NOT NULL\nORDER by id desc;\nselect * from activities where id = 54747783; # 00UO400000pCzojMAC\n\nselect p.id, p.activity_type, pc.id, pc.name\nFROM playbooks p\njoin playbook_categories pc on p.id = pc.playbook_id\nwhere p.team_id = 1 and p.activity_type = 'event';\n\nSELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';\nSELECT * FROM crm_field_values WHERE crm_field_id = 4;\n\nselect * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id\nwhere crm_configuration_id = 1 and pl.playbook_id = 175;\n\nselect * from teams;\nSELECT r.* FROM automated_reports r\njoin teams t on r.team_id = t.id\nWHERE r.frequency = 'daily'\n and r.status = 1\nAND t.status = 'active'\nAND (r.expires_at >= now() OR r.expires_at IS NULL);\n\nselect * from automated_report_results where report_id IN (18, 33);\n\nselect * from automated_reports;\nselect * from automated_report_results where report_id IN (34);","role_description":"text entry area","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Project","depth":3,"role_description":"text"},{"role":"AXButton","text":"Project","depth":3,"bounds":{"left":0.0140625,"top":0.041666668,"width":0.028515626,"height":0.021527778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"New File or Directory…","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Expand Selected","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Collapse All","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Options","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false}]...
|
-1978360131630512558
|
6686649039917036621
|
idle
|
accessibility
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
<?php
declare(strict_types=1);
namespace Jiminny\Console\Commands\Reports;
use Carbon\Carbon;
use Illuminate\Console\Command;
use Illuminate\Contracts\Bus\Dispatcher as BusDispatcher;
use Jiminny\Jobs\AutomatedReports\RequestGenerateAskJiminnyReportJob;
use Jiminny\Jobs\AutomatedReports\RequestGenerateReportJob;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\Team;
use Jiminny\Repositories\AutomatedReportsRepository;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Psr\Log\LoggerInterface;
class AutomatedReportsCommand extends Command
{
/**
* Log prefix for all log messages
*/
private const string LOG_PREFIX = '[automated-reports]';
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'automated-reports {--report-id= : Process a specific report by ID or UUID (bypasses frequency scheduling)}';
/**
* The console command description.
*
* @var string
*/
protected $description = 'Process automated reports based on their frequency (weekly, monthly, quarterly). Use --report-id to manually trigger a specific report by ID or UUID.';
public function __construct(
private readonly LoggerInterface $logger,
private readonly BusDispatcher $dispatcher,
private readonly AutomatedReportsRepository $reportRepository
) {
parent::__construct();
}
/**
* Execute the console command.
*
* @return int
*/
public function handle(): int
{
$this->logger->info(self::LOG_PREFIX . ' Started');
$reportId = $this->option('report-id');
if ($reportId !== null) {
return $this->processSingleReport((string) $reportId);
}
$now = Carbon::now();
$isMonday = $now->isMonday();
$isFirstDayOfMonth = $now->day === 1;
$currentMonth = $now->month;
// Check if the current month is a quarterly month (January, April, July, October)
$isQuarterlyMonth = in_array($currentMonth, [1, 4, 7, 10], true);
$this->logger->info(self::LOG_PREFIX . ' Checking conditions', [
'isMonday' => $isMonday,
'isFirstDayOfMonth' => $isFirstDayOfMonth,
'currentMonth' => $currentMonth,
'isQuarterlyMonth' => $isQuarterlyMonth,
]);
// Process daily reports
$this->processReports(AutomatedReportsService::FREQUENCY_DAILY);
// Process weekly reports on Mondays
if ($isMonday) {
$this->processReports(AutomatedReportsService::FREQUENCY_WEEKLY);
}
// Process monthly reports on the first day of the month
if ($isFirstDayOfMonth) {
$this->processReports(AutomatedReportsService::FREQUENCY_MONTHLY);
}
// Process quarterly reports on the first day of January, April, July, and October
if ($isFirstDayOfMonth && $isQuarterlyMonth) {
$this->processReports(AutomatedReportsService::FREQUENCY_QUARTERLY);
}
$this->logger->info(self::LOG_PREFIX . ' Completed');
return 0;
}
private function processSingleReport(string $reportId): int
{
$this->logger->info(self::LOG_PREFIX . ' Manual single-report mode', ['reportId' => $reportId]);
$report = is_numeric($reportId)
? AutomatedReport::withTrashed()->find((int) $reportId)
: AutomatedReport::withTrashed()->where('uuid', AutomatedReport::toOptimized($reportId))->first();
if ($report === null) {
$this->logger->error(self::LOG_PREFIX . ' Report not found', ['reportId' => $reportId]);
$this->error("Report not found: {$reportId}");
return 1;
}
$this->warnIfNotApplicableForSchedule($report);
$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [
'reportUuid' => $report->getUuid(),
'teamId' => $report->getTeamId(),
'frequency' => $report->getFrequency(),
'type' => $report->getType(),
]);
$job = $report->isAskJiminnyReport()
? new RequestGenerateAskJiminnyReportJob($report->getUuid())
: new RequestGenerateReportJob($report->getUuid());
$this->dispatcher->dispatchSync($job);
$this->logger->info(self::LOG_PREFIX . ' Completed');
return 0;
}
private function warnIfNotApplicableForSchedule(AutomatedReport $report): void
{
if ($report->trashed()) {
$this->warn('Report is soft-deleted (deleted_at: ' . $report->getDeletedAt()?->toDateTimeString() . ').');
}
if (! $report->getStatus()) {
$this->warn('Report status is inactive — would be skipped in scheduled run.');
}
$team = $report->getTeam();
if ($team->getStatus() !== Team::STATUS_ACTIVE) {
$this->warn("Team #{$report->getTeamId()} is not active (status: {$team->getStatus()}) — would be skipped in scheduled run.");
}
if ($report->isExpired()) {
$this->warn('Report is expired (expires_at: ' . $report->getExpiresAt()?->toDateString() . ') — would be skipped in scheduled run.');
}
$now = Carbon::now();
$frequency = $report->getFrequency();
$wouldRunToday = match ($frequency) {
AutomatedReportsService::FREQUENCY_DAILY => true,
AutomatedReportsService::FREQUENCY_WEEKLY => $now->isMonday(),
AutomatedReportsService::FREQUENCY_MONTHLY => $now->day === 1,
AutomatedReportsService::FREQUENCY_QUARTERLY => $now->day === 1 && in_array($now->month, [1, 4, 7, 10], true),
default => false,
};
if (! $wouldRunToday) {
$this->warn("Report frequency is '{$frequency}' — would NOT be scheduled to run today.");
}
}
/**
* Process reports for a specific frequency.
*
* @param string $frequency
*
* @return void
*/
private function processReports(string $frequency): void
{
$this->logger->info(self::LOG_PREFIX . " Processing $frequency reports");
$reportId = $this->option('report-id');
if ($reportId !== null) {
$reports = $this->getReportById($reportId);
} else {
// Get all enabled, not deleted reports with active teams for the specified frequency
$reports = $this->reportRepository->getActiveReportsByFrequency($frequency);
}
$this->logger->info(self::LOG_PREFIX . " Found {$reports->count()} $frequency reports to process");
/** @var AutomatedReport $report */
foreach ($reports as $report) {
$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', [
'reportUuid' => $report->getUuid(),
'teamId' => $report->getTeamId(),
'frequency' => $report->getFrequency(),
'type' => $report->getType(),
]);
$job = $report->isAskJiminnyReport()
? new RequestGenerateAskJiminnyReportJob($report->getUuid())
: new RequestGenerateReportJob($report->getUuid());
// $this->dispatcher->dispatch($job);
$this->dispatcher->dispatchSync($job);
}
}
}
Execute
Explain Plan
Browse Query History
View Parameters
Open Query Execution Settings…
In-Editor Results
Tx: Auto
Cancel Running Statements
Playground
jiminny
Sync Changes
Hide This Notification
Code changed:
Hide
16
13
13
Previous Highlighted Error
Next Highlighted Error
SELECT * FROM teams WHERE id = 1;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;
SELECT * FROM crm_fields WHERE id = 2234;
SELECT * FROM crm_field_values WHERE crm_field_id = 2234;
select * from crm_profiles where user_id = 143;
select * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO
select * from business_processes where crm_configuration_id = 39;
# 01941000000H669AAC, 01941000000H66JAAS
select * from record_type_field_values
where record_type_id IN (24);
select * from crm_field_values where id IN (2730);
select * from crm_configurations where id = 39;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce'; #1035
select * from users where team_id = 1; # 222 group 3
SELECT * FROM activities WHERE user_id = 222 order by id desc;
select * from sidekick_settings where team_id = 1;
select * from teams where id = 1;
select * from team_features where team_id = 1;
select * from activities where crm_configuration_id = 2
and provider = 'ms-teams' and id = 608765;
SELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';
select * from sidekick_settings where team_id = 2;
SELECT * FROM activities WHERE id = 608660;
select * from activity_summary_logs where activity_id = 608660;
select * from ai_prompts where transcription_id = 11214;
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;
# id: 608818, crm: 59628809737
SELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;
# id: 608821, crm: 59632069252
SELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,
playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,
scheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at
FROM activities a
join calendar_events ce on a.calendar_event_id = ce.id
WHERE a.id IN (608818, 608821);
select * from users where team_id = 1;
select * from team_settings where team_id = 1;
select * from crm_profiles where crm_configuration_id = 39 order by user_id;
select * from team_features where team_id = 1;
select * from users where team_id = 2;
SELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639
# Preslava N. Ivanova, grou id 3
SELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;
select * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';
select
a.id,
a.type,
a.scheduled_start_time,
a.actual_start_time,
a.created_at,
a.opportunity_id,
a.status
FROM activities a
WHERE opportunity_id = 344
and status IN ('completed', 'received', 'delivered')
and (
(a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))
;
SELECT * FROM users WHERE id = 222;
SELECT * FROM crm_profiles WHERE user_id = 222;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;
select * from group_deal_risk_types;
select * from opportunities where team_id = 1;
SELECT * FROM opportunities WHERE id = 315;
SELECT * FROM crm_field_data WHERE object_id = 315;
select * from crm_field_data where object_id = 260;
select * from generic_ai_prompts where subject_id = 315;
select * from teams; # 36, 21, 121, [EMAIL]
SELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';
# [PASSWORD_DOTS]
select * from teams where id = 1;
select * from crm_configurations where id = 39;
select * from users where team_id = 1;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 1;
# 1 - 00541000004281rAAA
# 204 - 0052g000003freeAAA
# 429 - 0052g000003qGOiAAM
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
select * from activities where type = 'softphone'
and created_at > '2024-12-11 15:24:36' order by id desc;
select * from activity_providers where team_id = 1;
select * from activity_provider_users where activity_provider_id = 328;
select * from opportunities where crm_configuration_id = 39
AND account_id = 178 AND is_closed = false
order by created_at DESC;
select * from contacts where id = 3952;
select * from accounts where id = 178;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations where id = 21;
select * from users where team_id = 36;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 36
and sa.provider = 'bullhorn';
select * from social_accounts where id = 348;
UPDATE social_accounts SET
provider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',
provider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',
expires = 1733998131,
state = 'connected'
WHERE id = 348;
# [PASSWORD_DOTS]
select * from teams where id = 31;
select * from crm_configurations where id = 18;
select * from users where team_id = 31; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 31;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 31
and sa.provider = 'close';
select * from contacts where crm_configuration_id = 18;
# [PASSWORD_DOTS] NEPTUNE [PASSWORD_DOTS]
select * from teams;
select * from users where id IN (1030, 1035, 1052);
select * from crm_configurations;
select * from users where team_id = 65; # 257
select * from team_settings where team_id = 65; # 257
select * from invitations where team_id = 65; # 257
select * from users where email = '[EMAIL]'; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 65;
select * from crm_configurations where id = 53;
select * from accounts where crm_configuration_id = 53 order by id desc;
select * from leads where crm_configuration_id = 53 order by id desc;
select * from contacts where crm_configuration_id = 53 order by id desc;
select * from opportunities where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 53 order by id desc;
select * from crm_fields where crm_configuration_id = 53 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 53 order by id desc;
select * from stages where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 13;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
and sa.provider = 'integration-app';
select * from contacts where crm_configuration_id = 13;
select * from social_accounts where sociable_id = 283;
SELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';
select * from activity_providers where team_id = 65;
SELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
;
# [PASSWORD_DOTS] STAGING [PASSWORD_DOTS]
SELECT * FROM teams;
SELECT * FROM teams WHERE id = 88;
SELECT * FROM teams WHERE id = 89;
select * from team_settings where team_id = 89;
SELECT * FROM users WHERE team_id = 89;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 89;
select * from users;
SELECT * FROM social_accounts WHERE sociable_id = 1761;
SELECT * FROM crm_configurations WHERE id = 70;
select * from accounts where crm_configuration_id = 70 order by id desc;
select * from leads where crm_configuration_id = 70 order by id desc;
select * from contacts where crm_configuration_id = 70 order by id desc;
select * from opportunities where crm_configuration_id = 70 order by id desc;
select * from crm_profiles where crm_configuration_id = 70 order by id desc;
select * from crm_fields where crm_configuration_id = 70 order by id desc;
select * from crm_field_values where crm_field_id = 3536 order by id desc;
select * from crm_layouts where crm_configuration_id = 70 order by id desc;
select * from stages where crm_configuration_id = 70 order by id desc;
select * from business_processes where crm_configuration_id = 70 order by id desc;
select * from business_process_stages where business_process_id = 34;
select * from contacts where id = 10468;
select * from crm_layouts where crm_configuration_id = 70;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;
SELECT * FROM crm_fields WHERE id IN (3533,3534,3535);
select * from activities where crm_configuration_id = 70
and (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;
SELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;
SELECT * FROM activities where crm_configuration_id = 69 ;
SELECT * FROM users WHERE email LIKE '%[EMAIL]%';
SELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;
SELECT * FROM opportunities WHERE id = 385;
select * from participants p
join activities a on p.activity_id = a.id
where a.crm_configuration_id = 70
and (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);
SELECT * FROM participants WHERE id = 1013638;
select * from teams where id = 90;
select * from users where team_id = 90;
select * from social_accounts where social_accounts.sociable_id IN (1960,1760);
SELECT * FROM crm_profiles WHERE crm_configuration_id = 71;
select * from invitations where team_id = 90;
select * from crm_configurations where id = 71;
select * from accounts where crm_configuration_id = 71 order by id desc;
select * from leads where crm_configuration_id = 71 order by id desc;
select * from contacts where crm_configuration_id = 71 order by id desc;
select * from opportunities where crm_configuration_id = 71 order by id desc;
select * from crm_profiles where crm_configuration_id = 71 order by id desc;
select * from crm_fields where crm_configuration_id = 71 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 71 order by id desc;
select * from stages where crm_configuration_id = 71 order by id desc;
select * from users order by secondary_email desc;
select u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa
join users u on sa.sociable_id = u.id
where sa.provider = 'google' and u.email LIKE 'aneliya%';
select * from failed_jobs order by id desc;
select * from users where email = '[EMAIL]' or secondary_email = '[EMAIL]';
select * from teams;
SELECT * FROM crm_profiles WHERE crm_configuration_id = 39;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;
SELECT * FROM crm_configurations WHERE id = 70;
select * from teams where id = 1;
select * from groups where team_id = 1;
select * from users where team_id = 1;
select o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o
join users u on o.user_id = u.id
join groups g on u.group_id = g.id
join role_user ru on u.id = ru.user_id
join roles r on ru.role_id = r.id
where o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';
select * from role_user where user_id = 143;
select * from roles;
select * from role_user;
select * from groups where id = 9;
select * from scope_groups where group_id = 9;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations;
SELECT * FROM social_accounts WHERE sociable_id = 121;
https://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105
https://crmsandbox.zoho.com/crm/
https://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080
https://crm.zoho.com/crm/
org3469620
SELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;
select * from users where email LIKE "%mobile_automation_%";
select * from social_accounts where sociable_id IN (2228);
select * from crm_profiles where user_id IN (2222,2223,2226,2227);
select * from teams order by id desc;
SELECT * FROM users WHERE id = 2229;
SELECT * FROM crm_profiles WHERE user_id = 2229;
select * from opportunities where crm_configuration_id = 88;
select * from crm_fields where crm_configuration_id = 88;
select * from crm_profiles where crm_configuration_id = 88;
SELECT * FROM teams WHERE id = 1;
SELECT * FROM users WHERE id = 143;
SELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;
https://app.staging.jiminny.com/ondemand?
min_duration=1
&
only_recorded=1
&
user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e
&
sequence_number=2
select * from users where team_id = 1 and email like '%stoyan%'
select * from coaching_feedbacks;
select * from teams;
SELECT * FROM users WHERE team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from users where id = 143;
SELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
select * from users where team_id = 2;
select * from activities where crm_configuration_id = 39
and activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'
AND user_id = 143
order by id desc;
# [PASSWORD_DOTS]
select * from teams where id = 142; # 2312, 126
select * from team_settings;
select * from users where team_id = 142; # 21642
SELECT * FROM social_accounts WHERE sociable_id = 21642;
SELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;
select * from crm_profiles where id IN (93);
select * from invitations;
select * from team_features where team_id = 1;
SELECT * FROM crm_configurations WHERE id = 126;
select * from accounts where crm_configuration_id = 126 order by id desc;
select * from leads where crm_configuration_id = 126 order by id desc;
select * from contacts where crm_configuration_id = 126 order by id desc;
select * from opportunities where crm_configuration_id = 126 order by id desc;
select * from crm_profiles where crm_configuration_id = 126 order by id desc;
select * from crm_fields where crm_configuration_id = 126 # 11060
# and type IN ('picklist', 'status')
# and object_type = 'task'
order by id desc;
# 5731,5732,5733
select DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;
select * from crm_layouts where crm_configuration_id = 126 order by id desc;
SELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);
select * from stages where crm_configuration_id = 126 order by id desc;
select * from business_processes where crm_configuration_id = 126 order by id desc;
select * from business_process_stages where business_process_id IN (76,75,74,73);
select * from playbooks where team_id = 142;
select * from playbook_layouts where playbook_id IN (108);
SELECT * FROM playbook_categories WHERE playbook_id IN (108);
select * from teams where id = 130;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 2
and sa.provider = 'hubspot';
SELECT * FROM activities
WHERE crm_configuration_id = 110;
select * from teams;
select * from crm_configurations;
SELECT * FROM activities WHERE id = 628773;
SELECT * FROM crm_profiles WHERE user_id = 1460;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from teams;
select ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id
join permission_role pr on pr.role_id = ru.role_id
join permissions p on p.id = pr.permission_id
where team_id = 495 and p.name IN ('dial');
select * from teams where id = 145;
select * from crm_configurations where id = 129;
select * from social_accounts where sociable_id = 2317;
SELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;
select * from teams where id = 1;
SELECT * FROM crm_layouts WHERE crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;
SELECT * FROM crm_layout_entities WHERE id = 5507;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');
select * from teams;
select * from activities where crm_configuration_id = 14;
SELECT * FROM social_accounts where provider = 'copper';
select * from activities where id = 628467;
select * from participants where activity_id = 628467;
SELECT * FROM contacts WHERE id = 3969;
SELECT * FROM accounts WHERE id = 177;
SELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;
# [PASSWORD_DOTS] BH
select * from teams where id = 36;
SELECT * FROM crm_configurations WHERE id = 21;
select * from activities where crm_configuration_id = 21 and id = 607901;
select * from activities where crm_configuration_id = 21;
select * roles;
select * from permissions;
select * from permission_role where permission_id = 226;
select * from migrations order by id desc;
# mercury
# neptune
# earth
select * from teams;
select * from teams where id = 19;
select * from teams where id = 27;
select * from users where team_id = 27;
SELECT * FROM crm_configurations WHERE id = 42;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from activities where id = 631461;
SELECT * FROM crm_field_values WHERE crm_field_id = 180;
select * from teams where id = 2;
SELECT * FROM social_accounts WHERE sociable_id = 89;
SELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273
select * from activity_summary_logs where activity_id = 634273;
select * from sidekick_settings where team_id = 2;
select * from teams; # 2, 2
SELECT * FROM crm_configurations WHERE team_id = 2; # 2
select * from team_features where team_id = 2;
select * from features;
SELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';
SELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;
select * from automated_reports order by id desc;
select * from automated_report_results order by id desc;
select * from users where team_id = 1 and id IN (7160, 3248);
select * from migrations order by id desc;
SELECT
CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,
u.email,
sa.*,
t.owner_id FROM social_accounts sa
JOIN users u on u.id = sa.sociable_id
JOIN teams t on t.id = u.team_id
WHERE u.team_id = 1 and sa.provider = 'salesforce';
select * from teams where id = 1;
select * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;
select * from groups where id = 565;
select * from playbooks where team_id = 1;
select * from playbooks where id = 175;
select * from playbook_categories where playbook_id = 175;
select * from users where team_id = 1;
select * from users where id = 7160;
select * from crm_profiles where user_id = 7160;
select * from features;
select
*
# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,
# crm_configuration_id, crm_provider_id, transcription_id, status
from activities where crm_configuration_id = 1 and type = 'conference'
# and crm_provider_id IS NOT NULL
and provider != 'uploader' and actual_start_time IS NOT NULL
ORDER by id desc;
select * from activities where id = 54747783; # 00UO400000pCzojMAC
select p.id, p.activity_type, pc.id, pc.name
FROM playbooks p
join playbook_categories pc on p.id = pc.playbook_id
where p.team_id = 1 and p.activity_type = 'event';
SELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';
SELECT * FROM crm_field_values WHERE crm_field_id = 4;
select * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id
where crm_configuration_id = 1 and pl.playbook_id = 175;
select * from teams;
SELECT r.* FROM automated_reports r
join teams t on r.team_id = t.id
WHERE r.frequency = 'daily'
and r.status = 1
AND t.status = 'active'
AND (r.expires_at >= now() OR r.expires_at IS NULL);
select * from automated_report_results where report_id IN (18, 33);
select * from automated_reports;
select * from automated_report_results where report_id IN (34);
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
10330
|
|
10385
|
NULL
|
0
|
2026-04-14T08:37:22.540404+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776155842540_m2.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
PhpStormFV faVsco.js~Projectv© Partner.php© Permis PhpStormFV faVsco.js~Projectv© Partner.php© Permission.php© PhoneNumber.php© PlaybackTheme.php© Playbook.php© PlaybookCategory.php© Playlist.php© RateLimit.phpC) Region.pho© Role.php©RoleChangeEvent.php© ScopeGroup.php© Session.php© SlackBot.php© SocialAccount.php© Stage.php© Task.php© Team.php©TeamAiContext.phpC) TeamDomain.php©TeamFeature.php©TeamSettings.php© TextRelay.php© Track.php© TranscriptionModel.php© TranscriptionModelLocale./© TranscriptionProvider.php© User.php© UserSettings.php©Vocabulary.php© VocabularyPronunciation.p© VoiceAccess.php©VoiceConsentPrefix.php> D Notifications› D Observers› C Policies> D Providers> D Queuev | Repositories> MAi> DJ AutoScoring> D Calendar>DCrm> D Geography© ActiveStreamsRepository.p©ActivityCommentRepositor©ActivityLogRepository.php© ActivityMessageRepository© ActivityMomentRepository.© ActivityProviderRepository.©ActivityRepository.php©ActivitySearchFilterReposit© ActivityShareRepository.phActivityUploadSettingRepo© AiPromptRepository.php© AskAnythingRepository.ph|© AutomatedReportsReposits© CalllmportRepository.php© CoachingFeedbackRepositViewNavigateCodeLaravelRefactonWindow#11894 on JY-18909-automated-reports-ask-jiminny k ~© ReportController.php© JiminnyDebugCommand.php© AutomatedReportsSendCommand.phpAutomatedReportsCommand.phpC AutomatedReportsRepository.php xAulomaleakeporisservice.onp© CreateHeldActivityEvent.php© TrackProviderInstalledEvent.php© ActivityLogged.php© AutomatedReportsCallbackService.phpCreateActivityLoggedEvent.phpRequestGenerateAskJiminnyReportJob.php© RequestGenerateReportJob.phpC AutomatedReportResult.php= custom.log= laravel.logA SF [jiminny@localhost]Hs local liminnyalocalnostconsole PRODA console [EU]© UserPilotActivityListener.phpA console [STAGING]© AskJiminnyReportActivityService.phpC) RequestGenerateAskJiminnyReportJobTest.phpTx. AutoyHlayground4155A13 V.4 ^uronarecreoorrskepostory520521creace a new aucomared reporaOparam array $dataQreturn AutomatedReportlic function create(array $data): AutomatedReportf...}Find an automated report bu UID@param string $uvid523526527528529530531532533534@return AutomatedReport|nulllic function findByUuid(string $uvid): ?AutomatedReportO0/1538539return AutomatedReport::where('uvid', AutomatedReport:: to0ptimized(Suvid))->firstO;542543Retrieve all standard (non-Ask Liminay) automated reports.5445451oparam scrine osorccocunnThe column to sort by. Allowed values: 'created_by','created_at'. Defaults to540Oparam string $sortDirection The sort direction. Allowed values:'asc','desc'. Defaults to 'desc'.541548Oreturn Collection<AutomatedReport>549Isageslic function getAllStandardReports(string $sortColumn = 'created_at',string $sortDirection = 'desc'Collection {.J552553554555556557Retrieve all Ask Liminny reports created by the given user.Oparam User$userThe user whose reports to retrieve.Oparam string $sortColumnThe column to sort by. Allowed values: 'created_by','created_at'. Defaults to 561Oparam string $sortDirection The sort direction. Allowed values:'asc','desc'. Defaults to 'desc'.559560563@return Collection<AutomatedReport>Gajiminny v016 A 13 X13 A Vsocial_accounts sa= sa.sociable_id: on t.id = u.team_idand sa.provider = 'salesforce';Wnere 10 = 11g JOIN playbooks p 1.n<->1: on g.playbook_id = p.id where g.team_iwhere id = 565;oks where team_id = 1;oks where id = 175;ok_categories where playbook_id = 175;where team_id = 1;where id = 7160;ofiles where user_id = 7160;ovlder, playbook_category-1a, user_1d, lead_1a, contact_la, accounyid, crm_provider_id, transcription_id,slaLuse crm_configuration_id = 1 and type = 'conference'd IS NOT NULLoader' and actual_start_time IS NOT NULLties where id = 54747783; # 00U0400000pCzojMACity_type, pc.id, pc.nameries pc 1<->1.n: on p.id = pc.playbook_idand p.activity_type = 'event';elds WHERE crm_configuration_id = 1 and object_type = 'event';eld_values WHERE crm_field_id = 4;youts cl join playbook_layouts pl 1<->1.n: on cl.id = pl.layout_idion_id = 1 and pl.playbook_id = 175;mared redorusraaid = t.id'daily've'now() OR r.expires.at IS NULL);ted_report_results where cepont.id IN (18, 33);565566 Vted_report_results where ceRontaig IN (34);IsagesLic function getAskJiminnyReportsByUser(User Suser.string $sortColumn = 'created_at',string $sortDirection = 'desc'> Collection {..$0.Support Daily • in 3h 23 mRequestGenerateAskJiminnyReportJobTest100% C2Tue 14 Apr 11:37:22CascadeFixing ReportControlleAutomated Report FaiIN @AutomatedReportsCommand.phpadd additional parameter report id and if provider then instead ofvy wrecuehell lakes wle levort vy le or uule.Add checks for status, team activity andorher stuff used for qurying. This iwll be used only manually so if there shold be info if not applicable based onstandara searenLet me read the command and related files first.kead Auloialecreoorsredosilorv.ono ›Now let me check the AutonatedReoort model tor relevanttielas:сxоlютeй hules|getTeam|expires_at|getFrequencylgetType|STATUS_lis›Now.nave every.ninelneeo. Let me imolement tne changes.• AutomatedReportsCommand.php+78 -2Also need to check if findByUuid handles soft-deleted — it doesn't, so for UUID lookup we need withTrashed too.Let me tix thatAutomatedReportsCommand.phpDone. Here's what was added:+1 -1Changes SummaryNew option: —report-id= — accepts either a numeric ID or a UUID.processsing lekeportl, — oypasses treouency logie entirely.• Looks up by ID (AutomatedReport: :withTrashed()->find() ) or UUID (also withTrashed so even deletedreports can be triggered manually)• Calls warnIfNotApplicableForSchedule() for informational outputDispatches the job the same way as the scheduled pathwarnIfNotApplicableForSchedule() - mirrors every condition from getActiveReportsByFrequency() and thejob's validateReport(), printing a warn() (yellow terminal output) for each condition that would cause the reportto oe skiooed in a normal scheculed run:CheckReport is soft-deletedstatus is inactiveTeam not STATUS_ACTIVEexpires_at is pastFrequency wouldn't run todayUsage:bash# By IDSourcewathi rashed — notln normal scopegetActiveReportsByFrequencygetActiveReportsByFrequencygetActiveReportsByFrequencyscheduling logic in handle()php artisan automated-reports —report-id=68#BY UULDphp artisan automated-reports --report-1d=some-uuid-hereC1l -1 file +84 -2 >Add findByldOrUuid+ <> CodeClaude Sonnet 4.6Reject allAccept allWinasun lean55:45uir-o( 4 spaces...
|
NULL
|
3214495664566001753
|
NULL
|
click
|
ocr
|
NULL
|
PhpStormFV faVsco.js~Projectv© Partner.php© Permis PhpStormFV faVsco.js~Projectv© Partner.php© Permission.php© PhoneNumber.php© PlaybackTheme.php© Playbook.php© PlaybookCategory.php© Playlist.php© RateLimit.phpC) Region.pho© Role.php©RoleChangeEvent.php© ScopeGroup.php© Session.php© SlackBot.php© SocialAccount.php© Stage.php© Task.php© Team.php©TeamAiContext.phpC) TeamDomain.php©TeamFeature.php©TeamSettings.php© TextRelay.php© Track.php© TranscriptionModel.php© TranscriptionModelLocale./© TranscriptionProvider.php© User.php© UserSettings.php©Vocabulary.php© VocabularyPronunciation.p© VoiceAccess.php©VoiceConsentPrefix.php> D Notifications› D Observers› C Policies> D Providers> D Queuev | Repositories> MAi> DJ AutoScoring> D Calendar>DCrm> D Geography© ActiveStreamsRepository.p©ActivityCommentRepositor©ActivityLogRepository.php© ActivityMessageRepository© ActivityMomentRepository.© ActivityProviderRepository.©ActivityRepository.php©ActivitySearchFilterReposit© ActivityShareRepository.phActivityUploadSettingRepo© AiPromptRepository.php© AskAnythingRepository.ph|© AutomatedReportsReposits© CalllmportRepository.php© CoachingFeedbackRepositViewNavigateCodeLaravelRefactonWindow#11894 on JY-18909-automated-reports-ask-jiminny k ~© ReportController.php© JiminnyDebugCommand.php© AutomatedReportsSendCommand.phpAutomatedReportsCommand.phpC AutomatedReportsRepository.php xAulomaleakeporisservice.onp© CreateHeldActivityEvent.php© TrackProviderInstalledEvent.php© ActivityLogged.php© AutomatedReportsCallbackService.phpCreateActivityLoggedEvent.phpRequestGenerateAskJiminnyReportJob.php© RequestGenerateReportJob.phpC AutomatedReportResult.php= custom.log= laravel.logA SF [jiminny@localhost]Hs local liminnyalocalnostconsole PRODA console [EU]© UserPilotActivityListener.phpA console [STAGING]© AskJiminnyReportActivityService.phpC) RequestGenerateAskJiminnyReportJobTest.phpTx. AutoyHlayground4155A13 V.4 ^uronarecreoorrskepostory520521creace a new aucomared reporaOparam array $dataQreturn AutomatedReportlic function create(array $data): AutomatedReportf...}Find an automated report bu UID@param string $uvid523526527528529530531532533534@return AutomatedReport|nulllic function findByUuid(string $uvid): ?AutomatedReportO0/1538539return AutomatedReport::where('uvid', AutomatedReport:: to0ptimized(Suvid))->firstO;542543Retrieve all standard (non-Ask Liminay) automated reports.5445451oparam scrine osorccocunnThe column to sort by. Allowed values: 'created_by','created_at'. Defaults to540Oparam string $sortDirection The sort direction. Allowed values:'asc','desc'. Defaults to 'desc'.541548Oreturn Collection<AutomatedReport>549Isageslic function getAllStandardReports(string $sortColumn = 'created_at',string $sortDirection = 'desc'Collection {.J552553554555556557Retrieve all Ask Liminny reports created by the given user.Oparam User$userThe user whose reports to retrieve.Oparam string $sortColumnThe column to sort by. Allowed values: 'created_by','created_at'. Defaults to 561Oparam string $sortDirection The sort direction. Allowed values:'asc','desc'. Defaults to 'desc'.559560563@return Collection<AutomatedReport>Gajiminny v016 A 13 X13 A Vsocial_accounts sa= sa.sociable_id: on t.id = u.team_idand sa.provider = 'salesforce';Wnere 10 = 11g JOIN playbooks p 1.n<->1: on g.playbook_id = p.id where g.team_iwhere id = 565;oks where team_id = 1;oks where id = 175;ok_categories where playbook_id = 175;where team_id = 1;where id = 7160;ofiles where user_id = 7160;ovlder, playbook_category-1a, user_1d, lead_1a, contact_la, accounyid, crm_provider_id, transcription_id,slaLuse crm_configuration_id = 1 and type = 'conference'd IS NOT NULLoader' and actual_start_time IS NOT NULLties where id = 54747783; # 00U0400000pCzojMACity_type, pc.id, pc.nameries pc 1<->1.n: on p.id = pc.playbook_idand p.activity_type = 'event';elds WHERE crm_configuration_id = 1 and object_type = 'event';eld_values WHERE crm_field_id = 4;youts cl join playbook_layouts pl 1<->1.n: on cl.id = pl.layout_idion_id = 1 and pl.playbook_id = 175;mared redorusraaid = t.id'daily've'now() OR r.expires.at IS NULL);ted_report_results where cepont.id IN (18, 33);565566 Vted_report_results where ceRontaig IN (34);IsagesLic function getAskJiminnyReportsByUser(User Suser.string $sortColumn = 'created_at',string $sortDirection = 'desc'> Collection {..$0.Support Daily • in 3h 23 mRequestGenerateAskJiminnyReportJobTest100% C2Tue 14 Apr 11:37:22CascadeFixing ReportControlleAutomated Report FaiIN @AutomatedReportsCommand.phpadd additional parameter report id and if provider then instead ofvy wrecuehell lakes wle levort vy le or uule.Add checks for status, team activity andorher stuff used for qurying. This iwll be used only manually so if there shold be info if not applicable based onstandara searenLet me read the command and related files first.kead Auloialecreoorsredosilorv.ono ›Now let me check the AutonatedReoort model tor relevanttielas:сxоlютeй hules|getTeam|expires_at|getFrequencylgetType|STATUS_lis›Now.nave every.ninelneeo. Let me imolement tne changes.• AutomatedReportsCommand.php+78 -2Also need to check if findByUuid handles soft-deleted — it doesn't, so for UUID lookup we need withTrashed too.Let me tix thatAutomatedReportsCommand.phpDone. Here's what was added:+1 -1Changes SummaryNew option: —report-id= — accepts either a numeric ID or a UUID.processsing lekeportl, — oypasses treouency logie entirely.• Looks up by ID (AutomatedReport: :withTrashed()->find() ) or UUID (also withTrashed so even deletedreports can be triggered manually)• Calls warnIfNotApplicableForSchedule() for informational outputDispatches the job the same way as the scheduled pathwarnIfNotApplicableForSchedule() - mirrors every condition from getActiveReportsByFrequency() and thejob's validateReport(), printing a warn() (yellow terminal output) for each condition that would cause the reportto oe skiooed in a normal scheculed run:CheckReport is soft-deletedstatus is inactiveTeam not STATUS_ACTIVEexpires_at is pastFrequency wouldn't run todayUsage:bash# By IDSourcewathi rashed — notln normal scopegetActiveReportsByFrequencygetActiveReportsByFrequencygetActiveReportsByFrequencyscheduling logic in handle()php artisan automated-reports —report-id=68#BY UULDphp artisan automated-reports --report-1d=some-uuid-hereC1l -1 file +84 -2 >Add findByldOrUuid+ <> CodeClaude Sonnet 4.6Reject allAccept allWinasun lean55:45uir-o( 4 spaces...
|
NULL
|
|
10388
|
NULL
|
0
|
2026-04-14T08:37:27.681832+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776155847681_m1.jpg...
|
Slack
|
platform-inner-team (Channel) - Jiminny Inc - Slac platform-inner-team (Channel) - Jiminny Inc - Slack...
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
Jiminny Inc
Jiminny (Staging)
Add workspaces
Home
Jiminny Inc
Jiminny (Staging)
Add workspaces
Home
Home
DMs
DMs
Activity
Activity
Files
Files
Later
Later
More…
More
Unreads
Threads
Huddles
Drafts & sent
Directories
platform-inner-team
ai-chapter
alerts
backend
confusion-clinic
curiosity_lab
engineering
frontend
general
infra-changes
jiminny-bg
platform-tickets
product_launches
random
releases
sofia-office
support
thank-yous
the_people_of_jiminny
Aneliya Angelova
,
Nikolay Yankov
,
Steliyan Georgiev
Steliyan Georgiev
Adelina Petrova
,
Ilian Kyuchukov
,
Steliyan Georgiev
Adelina Petrova
Galya Dimitrova
Vasil Vasilev
Nikolay Nikolov
Galya Dimitrova
,
Nikolay Nikolov
Galya Dimitrova
,
Nikolay Yankov
Nikolay Yankov
Jira Cloud
Toast
Google Calendar
Messages
Messages
Channel Overview
Channel Overview
Refinements
Refinements
Files
Files
Pins
Pins
Bookmarks
Bookmarks
Retro Action Items
Retro Action Items
Deleted file
Deleted file
Add and Edit Channel Tabs
Canvas
List
Folder
Jump to date
Nikolay Nikolov
Apr 9th at 10:43:44 AM
10:43 AM
Още един фикс за outh:
https://github.com/jiminny/app/pull/11926
https://github.com/jiminny/app/pull/11926
#11926 SRD-6771 | JY-20622 | Fix OAuth
#11926 SRD-6771 | JY-20622 | Fix OAuth
JIRA:
SRD-6771
SRD-6771
|
JY-20622
JY-20622
Deployment notes:
• None
Comments
3
jiminny/app
jiminny/app
|
Apr 9th
|
Added by
GitHub
GitHub
Nikolay Yankov
Apr 9th at 11:00:43 AM
11:00 AM
Марио ще пусне един тикет за user-и от
Immutable
които не могат да се логнат с SSO в Sidekick.
Изглежда ми приоритетно
[EMAIL]
[EMAIL]
същото е и за
[EMAIL]
[EMAIL]
1 reaction, react with +1 emoji
1
Add reaction…
Apr 9th at 11:04:25 AM
11:04
Някой може ли да го погледне
Steliyan Georgiev
Apr 9th at 11:43:52 AM
11:43 AM
Може ли approve на
https://github.com/jiminny/prophet/pull/465
https://github.com/jiminny/prophet/pull/465
? Знам от какво се оплаква claude - нямаме проблем с това за сега.
Nikolay Nikolov
Apr 9th at 12:36:57 PM
12:36 PM
Някой дали знае тая конфигурация можем ли да я сменим ние ?
https://jiminny.atlassian.net/browse/SRD-6779?focusedCommentId=72677
https://jiminny.atlassian.net/browse/SRD-6779?focusedCommentId=72677
Comment by Nikolay Nikolov on a Bug in
Analyzing
The Immutable SSO tenant is configured with
name_id_format = persistent
, but the code expects the SAML response to contain the user's email address.
When Okta sends a
persistent
NameID, it sends a unique identifier (not the email), so
$samlUser->getUserId()
returns something like a UUID instead
…
See more
Comment
Comment
More actions...
Added by
Jira Cloud
Jira Cloud
Apr 9th at 12:37:38 PM
12:37
Ако е 'emailAddress' би трябвало да сработи - но да не счупя нещо друго
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Nikolay Ivanov
Apr 9th at 12:44:22 PM
12:44 PM
Вес може да има идея
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Nikolay Nikolov
Apr 9th at 12:45:49 PM
12:45 PM
Той е отпуск - по принцип това може и да не сработи, но няма да стане по лошо - само казваме какво искаме да ни върне Okta
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Apr 9th at 12:45:53 PM
12:45
ше го пробвам
1 reaction, react with +1 emoji
1
Add reaction…
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Nikolay Nikolov
Apr 9th at 1:04:12 PM
1:04 PM
Няма да е от това май
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Jump to date
New
Nikolay Yankov
Today at 11:35:04 AM
11:35 AM
Преди малко създадох конфигурация за новите репорти и в резултат не идва никакъв генериран репорт.
След проверка в базата разбираме, че съм избрал Saved Search, който няма нито едно активити.
Това обаче по никакъв начин не се подсказва на user-a и си мисля, че ще идват support тикети за такива неща...
Какво мислите?
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
loading…
Channel platform-inner-team...
|
[{"role":"AXRadioButton","text [{"role":"AXRadioButton","text":"Jiminny Inc","depth":12,"bounds":{"left":0.009722223,"top":0.08777778,"width":0.022222223,"height":0.035555556},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":true,"is_expanded":false},{"role":"AXRadioButton","text":"Jiminny (Staging)","depth":12,"bounds":{"left":0.009722223,"top":0.14555556,"width":0.022222223,"height":0.035555556},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"Add workspaces","depth":12,"bounds":{"left":0.009722223,"top":0.20333333,"width":0.022222223,"height":0.035555556},"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXRadioButton","text":"Home","depth":14,"bounds":{"left":0.048611112,"top":0.07777778,"width":0.036111113,"height":0.075555556},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":true,"is_expanded":false},{"role":"AXStaticText","text":"Home","depth":16,"bounds":{"left":0.05625,"top":0.13,"width":0.020833334,"height":0.015555556},"role_description":"text"},{"role":"AXRadioButton","text":"DMs","depth":14,"bounds":{"left":0.048611112,"top":0.15333334,"width":0.036111113,"height":0.075555556},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"DMs","depth":16,"bounds":{"left":0.058333334,"top":0.20555556,"width":0.016666668,"height":0.015555556},"role_description":"text"},{"role":"AXRadioButton","text":"Activity","depth":14,"bounds":{"left":0.048611112,"top":0.22888888,"width":0.036111113,"height":0.075555556},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Activity","depth":16,"bounds":{"left":0.05277778,"top":0.28111112,"width":0.027083334,"height":0.015555556},"role_description":"text"},{"role":"AXRadioButton","text":"Files","depth":14,"bounds":{"left":0.048611112,"top":0.30444443,"width":0.036111113,"height":0.075555556},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Files","depth":16,"bounds":{"left":0.058333334,"top":0.35666665,"width":0.015972223,"height":0.015555556},"role_description":"text"},{"role":"AXRadioButton","text":"Later","depth":14,"bounds":{"left":0.048611112,"top":0.38,"width":0.036111113,"height":0.075555556},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Later","depth":16,"bounds":{"left":0.057638887,"top":0.43222222,"width":0.018055556,"height":0.015555556},"role_description":"text"},{"role":"AXRadioButton","text":"More…","depth":14,"bounds":{"left":0.048611112,"top":0.45555556,"width":0.036111113,"height":0.075555556},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"More","depth":16,"bounds":{"left":0.056944445,"top":0.50777775,"width":0.01875,"height":0.015555556},"role_description":"text"},{"role":"AXStaticText","text":"Unreads","depth":21,"bounds":{"left":0.11875,"top":0.12777779,"width":0.038194444,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Threads","depth":21,"bounds":{"left":0.11875,"top":0.12777779,"width":0.036805555,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Huddles","depth":21,"bounds":{"left":0.11875,"top":0.12777779,"width":0.038194444,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Drafts & sent","depth":21,"bounds":{"left":0.11875,"top":0.12777779,"width":0.06111111,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Directories","depth":21,"bounds":{"left":0.11875,"top":0.12777779,"width":0.050694443,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"platform-inner-team","depth":23,"bounds":{"left":0.12986112,"top":0.18222222,"width":0.093055554,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"ai-chapter","depth":21,"bounds":{"left":0.12986112,"top":0.25555557,"width":0.046527777,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"alerts","depth":21,"bounds":{"left":0.12986112,"top":0.28666666,"width":0.025694445,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"backend","depth":21,"bounds":{"left":0.12986112,"top":0.31777778,"width":0.038194444,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"confusion-clinic","depth":21,"bounds":{"left":0.12986112,"top":0.34888887,"width":0.072222225,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"curiosity_lab","depth":21,"bounds":{"left":0.12986112,"top":0.38,"width":0.057638887,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"engineering","depth":21,"bounds":{"left":0.12986112,"top":0.41111112,"width":0.054166667,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"frontend","depth":21,"bounds":{"left":0.12986112,"top":0.4422222,"width":0.04027778,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"general","depth":21,"bounds":{"left":0.12986112,"top":0.47333333,"width":0.034027778,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"infra-changes","depth":21,"bounds":{"left":0.12986112,"top":0.5044444,"width":0.061805554,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"jiminny-bg","depth":21,"bounds":{"left":0.12986112,"top":0.53555554,"width":0.048611112,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"platform-tickets","depth":21,"bounds":{"left":0.12986112,"top":0.56666666,"width":0.072916664,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"product_launches","depth":21,"bounds":{"left":0.12986112,"top":0.5977778,"width":0.08055556,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"random","depth":21,"bounds":{"left":0.12986112,"top":0.6288889,"width":0.035416666,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"releases","depth":21,"bounds":{"left":0.12986112,"top":0.66,"width":0.036805555,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"sofia-office","depth":21,"bounds":{"left":0.12986112,"top":0.6911111,"width":0.05138889,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"support","depth":21,"bounds":{"left":0.12986112,"top":0.7222222,"width":0.036111113,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"thank-yous","depth":21,"bounds":{"left":0.12986112,"top":0.75333333,"width":0.05138889,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"the_people_of_jiminny","depth":21,"bounds":{"left":0.12986112,"top":0.78444445,"width":0.094444446,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"Aneliya Angelova","depth":23,"bounds":{"left":0.12986112,"top":0.8577778,"width":0.07847222,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":",","depth":23,"bounds":{"left":0.20833333,"top":0.8577778,"width":0.013194445,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"Nikolay Yankov","depth":23,"bounds":{"left":0.21319444,"top":0.8577778,"width":0.029861111,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":",","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Steliyan Georgiev","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Steliyan Georgiev","depth":23,"bounds":{"left":0.12986112,"top":0.8888889,"width":0.07986111,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"Adelina Petrova","depth":23,"bounds":{"left":0.12986112,"top":0.92,"width":0.072222225,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":",","depth":23,"bounds":{"left":0.2013889,"top":0.92,"width":0.0055555557,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"Ilian Kyuchukov","depth":23,"bounds":{"left":0.20694445,"top":0.92,"width":0.015972223,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":",","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Steliyan Georgiev","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Adelina Petrova","depth":23,"bounds":{"left":0.12986112,"top":0.95111114,"width":0.072222225,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"Galya Dimitrova","depth":23,"bounds":{"left":0.12986112,"top":0.9822222,"width":0.07361111,"height":0.012222222},"role_description":"text"},{"role":"AXStaticText","text":"Vasil Vasilev","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Nikolay Nikolov","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Galya Dimitrova","depth":23,"role_description":"text"},{"role":"AXStaticText","text":",","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Nikolay Nikolov","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Galya Dimitrova","depth":23,"role_description":"text"},{"role":"AXStaticText","text":",","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Nikolay Yankov","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Nikolay Yankov","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Jira Cloud","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Toast","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Google Calendar","depth":23,"role_description":"text"},{"role":"AXRadioButton","text":"Messages","depth":17,"bounds":{"left":0.25486112,"top":0.12777779,"width":0.06458333,"height":0.04222222},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":true,"is_expanded":false},{"role":"AXStaticText","text":"Messages","depth":19,"bounds":{"left":0.27430555,"top":0.14,"width":0.039583333,"height":0.017777778},"role_description":"text"},{"role":"AXRadioButton","text":"Channel Overview","depth":17,"bounds":{"left":0.32152778,"top":0.12777779,"width":0.1,"height":0.04222222},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Channel Overview","depth":19,"bounds":{"left":0.34097221,"top":0.14,"width":0.075,"height":0.017777778},"role_description":"text"},{"role":"AXRadioButton","text":"Refinements","depth":17,"bounds":{"left":0.4236111,"top":0.12777779,"width":0.07847222,"height":0.04222222},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Refinements","depth":19,"bounds":{"left":0.44305557,"top":0.14,"width":0.050694443,"height":0.017777778},"role_description":"text"},{"role":"AXRadioButton","text":"Files","depth":17,"bounds":{"left":0.5048611,"top":0.12777779,"width":0.04375,"height":0.04222222},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Files","depth":19,"bounds":{"left":0.5243056,"top":0.14,"width":0.01875,"height":0.017777778},"role_description":"text"},{"role":"AXRadioButton","text":"Pins","depth":17,"bounds":{"left":0.55069447,"top":0.12777779,"width":0.04236111,"height":0.04222222},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Pins","depth":19,"bounds":{"left":0.5701389,"top":0.14,"width":0.017361112,"height":0.017777778},"role_description":"text"},{"role":"AXRadioButton","text":"Bookmarks","depth":17,"bounds":{"left":0.59583336,"top":0.12777779,"width":0.07083333,"height":0.04222222},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Bookmarks","depth":19,"bounds":{"left":0.61527777,"top":0.14,"width":0.045833334,"height":0.017777778},"role_description":"text"},{"role":"AXRadioButton","text":"Retro Action Items","depth":17,"bounds":{"left":0.66875,"top":0.12777779,"width":0.103472225,"height":0.04222222},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Retro Action Items","depth":19,"bounds":{"left":0.6888889,"top":0.14,"width":0.075,"height":0.017777778},"role_description":"text"},{"role":"AXRadioButton","text":"Deleted file","depth":17,"bounds":{"left":0.7743056,"top":0.12777779,"width":0.075,"height":0.04222222},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Deleted file","depth":19,"bounds":{"left":0.79375,"top":0.14,"width":0.047222223,"height":0.017777778},"role_description":"text"},{"role":"AXPopUpButton","text":"Add and Edit Channel Tabs","depth":17,"bounds":{"left":0.8513889,"top":0.12777779,"width":0.022916667,"height":0.04222222},"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Canvas","depth":17,"role_description":"text"},{"role":"AXStaticText","text":"List","depth":17,"role_description":"text"},{"role":"AXStaticText","text":"Folder","depth":17,"role_description":"text"},{"role":"AXPopUpButton","text":"Jump to date","depth":22,"bounds":{"left":0.56805557,"top":0.17666666,"width":0.10486111,"height":0.031111112},"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Nikolay Nikolov","depth":23,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.075,"height":0.0011111111},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"bounds":{"left":0.37708333,"top":0.16111112,"width":0.0055555557,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 10:43:44 AM","depth":23,"bounds":{"left":0.38194445,"top":0.16111112,"width":0.0375,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"10:43 AM","depth":24,"bounds":{"left":0.38194445,"top":0.16111112,"width":0.0375,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Още един фикс за outh:","depth":24,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.11736111,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"https://github.com/jiminny/app/pull/11926","depth":24,"bounds":{"left":0.40486112,"top":0.16111112,"width":0.19791667,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"https://github.com/jiminny/app/pull/11926","depth":25,"bounds":{"left":0.40486112,"top":0.16111112,"width":0.19791667,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"#11926 SRD-6771 | JY-20622 | Fix OAuth","depth":25,"bounds":{"left":0.29930556,"top":0.16111112,"width":0.19513889,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"#11926 SRD-6771 | JY-20622 | Fix OAuth","depth":26,"bounds":{"left":0.29930556,"top":0.16111112,"width":0.19513889,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"JIRA:","depth":25,"bounds":{"left":0.29930556,"top":0.16111112,"width":0.027083334,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"SRD-6771","depth":25,"bounds":{"left":0.32569444,"top":0.16111112,"width":0.049305554,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"SRD-6771","depth":26,"bounds":{"left":0.32569444,"top":0.16111112,"width":0.049305554,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"|","depth":25,"bounds":{"left":0.37430555,"top":0.16111112,"width":0.007638889,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"JY-20622","depth":25,"bounds":{"left":0.38194445,"top":0.16111112,"width":0.045138888,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"JY-20622","depth":26,"bounds":{"left":0.38194445,"top":0.16111112,"width":0.045138888,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Deployment notes:","depth":25,"bounds":{"left":0.29930556,"top":0.16111112,"width":0.088194445,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"• None","depth":25,"bounds":{"left":0.29930556,"top":0.16111112,"width":0.034027778,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Comments","depth":26,"bounds":{"left":0.29930556,"top":0.16111112,"width":0.050694443,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"3","depth":26,"bounds":{"left":0.29930556,"top":0.16111112,"width":0.00625,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"jiminny/app","depth":25,"bounds":{"left":0.31319445,"top":0.16111112,"width":0.043055557,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"jiminny/app","depth":26,"bounds":{"left":0.31319445,"top":0.16111112,"width":0.043055557,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"|","depth":25,"bounds":{"left":0.35625,"top":0.16111112,"width":0.00625,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Apr 9th","depth":25,"bounds":{"left":0.3625,"top":0.16111112,"width":0.027777778,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"|","depth":25,"bounds":{"left":0.39027777,"top":0.16111112,"width":0.00625,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Added by","depth":25,"bounds":{"left":0.39583334,"top":0.16111112,"width":0.0375,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"GitHub","depth":25,"bounds":{"left":0.43263888,"top":0.16111112,"width":0.027083334,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"GitHub","depth":26,"bounds":{"left":0.43263888,"top":0.16111112,"width":0.027083334,"height":0.0011111111},"role_description":"text"},{"role":"AXButton","text":"Nikolay Yankov","depth":23,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.072222225,"height":0.0011111111},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"bounds":{"left":0.35972223,"top":0.16111112,"width":0.00625,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 11:00:43 AM","depth":23,"bounds":{"left":0.36527777,"top":0.16111112,"width":0.036805555,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"11:00 AM","depth":24,"bounds":{"left":0.36527777,"top":0.16111112,"width":0.036805555,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Марио ще пусне един тикет за user-и от","depth":24,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.19722222,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Immutable","depth":25,"bounds":{"left":0.4875,"top":0.16111112,"width":0.045138888,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"които не могат да се логнат с SSO в Sidekick.","depth":24,"bounds":{"left":0.53541666,"top":0.16111112,"width":0.21805556,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Изглежда ми приоритетно","depth":24,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.12916666,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"vid.nedumaran@immutable.com","depth":24,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.14652778,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"vid.nedumaran@immutable.com","depth":25,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.14652778,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"същото е и за","depth":24,"bounds":{"left":0.43472221,"top":0.16111112,"width":0.07152778,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"alex.li@immutable.com","depth":24,"bounds":{"left":0.50555557,"top":0.16111112,"width":0.10486111,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"alex.li@immutable.com","depth":25,"bounds":{"left":0.50555557,"top":0.16111112,"width":0.10486111,"height":0.0011111111},"role_description":"text"},{"role":"AXCheckBox","text":"1 reaction, react with +1 emoji","depth":24,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.029861111,"height":0.0011111111},"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"1","depth":25,"bounds":{"left":0.30763888,"top":0.16111112,"width":0.0048611113,"height":0.0011111111},"role_description":"text"},{"role":"AXButton","text":"Add reaction…","depth":24,"bounds":{"left":0.32083333,"top":0.16111112,"width":0.023611112,"height":0.0011111111},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXLink","text":"Apr 9th at 11:04:25 AM","depth":24,"bounds":{"left":0.2611111,"top":0.16111112,"width":0.021527778,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"11:04","depth":25,"bounds":{"left":0.2611111,"top":0.16111112,"width":0.021527778,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Някой може ли да го погледне","depth":24,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.14861111,"height":0.0011111111},"role_description":"text"},{"role":"AXButton","text":"Steliyan Georgiev","depth":23,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.08263889,"height":0.0011111111},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"bounds":{"left":0.37083334,"top":0.16111112,"width":0.0055555557,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 11:43:52 AM","depth":23,"bounds":{"left":0.37569445,"top":0.16111112,"width":0.0375,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"11:43 AM","depth":24,"bounds":{"left":0.37569445,"top":0.16111112,"width":0.0375,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Може ли approve на","depth":24,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.1,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"https://github.com/jiminny/prophet/pull/465","depth":24,"bounds":{"left":0.3875,"top":0.16111112,"width":0.20555556,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"https://github.com/jiminny/prophet/pull/465","depth":25,"bounds":{"left":0.3875,"top":0.16111112,"width":0.20555556,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"? Знам от какво се оплаква claude - нямаме проблем с това за сега.","depth":24,"bounds":{"left":0.5923611,"top":0.16111112,"width":0.325,"height":0.0011111111},"role_description":"text"},{"role":"AXButton","text":"Nikolay Nikolov","depth":23,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.075,"height":0.0011111111},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"bounds":{"left":0.37708333,"top":0.16111112,"width":0.0055555557,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 12:36:57 PM","depth":23,"bounds":{"left":0.38194445,"top":0.16111112,"width":0.036805555,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"12:36 PM","depth":24,"bounds":{"left":0.38194445,"top":0.16111112,"width":0.036805555,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Някой дали знае тая конфигурация можем ли да я сменим ние ?","depth":24,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.31319445,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"https://jiminny.atlassian.net/browse/SRD-6779?focusedCommentId=72677","depth":24,"bounds":{"left":0.6006944,"top":0.16111112,"width":0.34583333,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"https://jiminny.atlassian.net/browse/SRD-6779?focusedCommentId=72677","depth":25,"bounds":{"left":0.6006944,"top":0.16111112,"width":0.34583333,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Comment by Nikolay Nikolov on a Bug in","depth":26,"bounds":{"left":0.29930556,"top":0.16111112,"width":0.19097222,"height":0.017777778},"role_description":"text"},{"role":"AXStaticText","text":"Analyzing","depth":27,"bounds":{"left":0.49305555,"top":0.16222222,"width":0.045138888,"height":0.016666668},"role_description":"text"},{"role":"AXStaticText","text":"The Immutable SSO tenant is configured with","depth":26,"bounds":{"left":0.29930556,"top":0.19666667,"width":0.2125,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"name_id_format = persistent","depth":27,"bounds":{"left":0.51458335,"top":0.2,"width":0.13541667,"height":0.016666668},"role_description":"text"},{"role":"AXStaticText","text":"","depth":26,"bounds":{"left":0.65208334,"top":0.19666667,"width":0.0027777778,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":", but the code expects the SAML response to contain the user's email address.","depth":26,"bounds":{"left":0.29930556,"top":0.19666667,"width":0.39444444,"height":0.044444446},"role_description":"text"},{"role":"AXStaticText","text":"When Okta sends a","depth":26,"bounds":{"left":0.29930556,"top":0.24555555,"width":0.09236111,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"persistent","depth":27,"bounds":{"left":0.39444444,"top":0.2488889,"width":0.05,"height":0.016666668},"role_description":"text"},{"role":"AXStaticText","text":"NameID, it sends a unique identifier (not the email), so","depth":26,"bounds":{"left":0.44722223,"top":0.24555555,"width":0.24930556,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"$samlUser->getUserId()","depth":27,"bounds":{"left":0.30208334,"top":0.27333334,"width":0.110416666,"height":0.016666668},"role_description":"text"},{"role":"AXStaticText","text":"returns something like a UUID instead","depth":26,"bounds":{"left":0.41458333,"top":0.27,"width":0.17708333,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"…","depth":26,"bounds":{"left":0.59097224,"top":0.27,"width":0.008333334,"height":0.02},"role_description":"text"},{"role":"AXButton","text":"See more","depth":25,"bounds":{"left":0.29930556,"top":0.29222223,"width":0.043055557,"height":0.024444444},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Comment","depth":25,"bounds":{"left":0.29930556,"top":0.33,"width":0.052083332,"height":0.031111112},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Comment","depth":27,"bounds":{"left":0.30555555,"top":0.33666667,"width":0.039583333,"height":0.017777778},"role_description":"text"},{"role":"AXComboBox","text":"More actions...","depth":26,"bounds":{"left":0.35694444,"top":0.33,"width":0.13194445,"height":0.031111112},"placeholder":"More actions...","role_description":"combo box","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Added by","depth":25,"bounds":{"left":0.29930556,"top":0.37444445,"width":0.036805555,"height":0.016666668},"role_description":"text"},{"role":"AXLink","text":"Jira Cloud","depth":25,"bounds":{"left":0.3361111,"top":0.37444445,"width":0.036111113,"height":0.016666668},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Jira Cloud","depth":26,"bounds":{"left":0.3361111,"top":0.37444445,"width":0.036111113,"height":0.016666668},"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 12:37:38 PM","depth":24,"bounds":{"left":0.2611111,"top":0.41,"width":0.021527778,"height":0.016666668},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"12:37","depth":25,"bounds":{"left":0.2611111,"top":0.41,"width":0.021527778,"height":0.016666668},"role_description":"text"},{"role":"AXStaticText","text":"Ако е 'emailAddress' би трябвало да сработи - но да не счупя нещо друго","depth":24,"bounds":{"left":0.28819445,"top":0.40666667,"width":0.35,"height":0.02},"role_description":"text"},{"role":"AXCheckBox","text":"React with white_check_mark","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with eyes","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with raised_hands","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Add reaction…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Reply in thread","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Forward message…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"Save for later","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"More actions","depth":25,"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Nikolay Ivanov","depth":23,"bounds":{"left":0.28819445,"top":0.4377778,"width":0.07013889,"height":0.024444444},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"bounds":{"left":0.3576389,"top":0.44,"width":0.0055555557,"height":0.02},"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 12:44:22 PM","depth":23,"bounds":{"left":0.36319444,"top":0.44333333,"width":0.036805555,"height":0.016666668},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"12:44 PM","depth":24,"bounds":{"left":0.36319444,"top":0.44333333,"width":0.036805555,"height":0.016666668},"role_description":"text"},{"role":"AXStaticText","text":"Вес може да има идея","depth":24,"bounds":{"left":0.28819445,"top":0.46444446,"width":0.10763889,"height":0.02},"role_description":"text"},{"role":"AXCheckBox","text":"React with white_check_mark","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with eyes","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with raised_hands","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Add reaction…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Reply in thread","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Forward message…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"Save for later","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"More actions","depth":25,"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Nikolay Nikolov","depth":23,"bounds":{"left":0.28819445,"top":0.49555555,"width":0.075,"height":0.024444444},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"bounds":{"left":0.37708333,"top":0.4977778,"width":0.0055555557,"height":0.02},"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 12:45:49 PM","depth":23,"bounds":{"left":0.38194445,"top":0.5011111,"width":0.036805555,"height":0.016666668},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"12:45 PM","depth":24,"bounds":{"left":0.38194445,"top":0.5011111,"width":0.036805555,"height":0.016666668},"role_description":"text"},{"role":"AXStaticText","text":"Той е отпуск - по принцип това може и да не сработи, но няма да стане по лошо - само казваме какво искаме да ни върне Okta","depth":24,"bounds":{"left":0.28819445,"top":0.5222222,"width":0.61319447,"height":0.02},"role_description":"text"},{"role":"AXCheckBox","text":"React with white_check_mark","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with eyes","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with raised_hands","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Add reaction…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Reply in thread","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Forward message…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"Save for later","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"More actions","depth":25,"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXLink","text":"Apr 9th at 12:45:53 PM","depth":24,"bounds":{"left":0.2611111,"top":0.5588889,"width":0.021527778,"height":0.016666668},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"12:45","depth":25,"bounds":{"left":0.2611111,"top":0.5588889,"width":0.021527778,"height":0.016666668},"role_description":"text"},{"role":"AXStaticText","text":"ше го пробвам","depth":24,"bounds":{"left":0.28819445,"top":0.5555556,"width":0.07083333,"height":0.02},"role_description":"text"},{"role":"AXCheckBox","text":"1 reaction, react with +1 emoji","depth":24,"bounds":{"left":0.28819445,"top":0.5822222,"width":0.029861111,"height":0.026666667},"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"1","depth":25,"bounds":{"left":0.30763888,"top":0.5877778,"width":0.0048611113,"height":0.015555556},"role_description":"text"},{"role":"AXButton","text":"Add reaction…","depth":24,"bounds":{"left":0.32083333,"top":0.5822222,"width":0.023611112,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with white_check_mark","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with eyes","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with raised_hands","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Add reaction…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Reply in thread","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Forward message…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"Save for later","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"More actions","depth":25,"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Nikolay Nikolov","depth":23,"bounds":{"left":0.28819445,"top":0.62222224,"width":0.075,"height":0.024444444},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"bounds":{"left":0.37708333,"top":0.6244444,"width":0.0055555557,"height":0.02},"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 1:04:12 PM","depth":23,"bounds":{"left":0.38194445,"top":0.62777776,"width":0.031944446,"height":0.016666668},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"1:04 PM","depth":24,"bounds":{"left":0.38194445,"top":0.62777776,"width":0.031944446,"height":0.016666668},"role_description":"text"},{"role":"AXStaticText","text":"Няма да е от това май","depth":24,"bounds":{"left":0.28819445,"top":0.6488889,"width":0.10694444,"height":0.02},"role_description":"text"},{"role":"AXCheckBox","text":"React with white_check_mark","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with eyes","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with raised_hands","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Add reaction…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Reply in thread","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Forward message…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"Save for later","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"More actions","depth":25,"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"Jump to date","depth":22,"bounds":{"left":0.59375,"top":0.6911111,"width":0.05277778,"height":0.031111112},"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"New","depth":22,"bounds":{"left":0.96458334,"top":0.69777775,"width":0.01875,"height":0.017777778},"role_description":"text"},{"role":"AXButton","text":"Nikolay Yankov","depth":23,"bounds":{"left":0.28819445,"top":0.73444444,"width":0.072222225,"height":0.024444444},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"bounds":{"left":0.35972223,"top":0.7366667,"width":0.00625,"height":0.02},"role_description":"text"},{"role":"AXLink","text":"Today at 11:35:04 AM","depth":23,"bounds":{"left":0.36527777,"top":0.74,"width":0.036805555,"height":0.016666668},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"11:35 AM","depth":24,"bounds":{"left":0.36527777,"top":0.74,"width":0.036805555,"height":0.016666668},"role_description":"text"},{"role":"AXStaticText","text":"Преди малко създадох конфигурация за новите репорти и в резултат не идва никакъв генериран репорт.","depth":24,"bounds":{"left":0.28819445,"top":0.76111114,"width":0.5076389,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"След проверка в базата разбираме, че съм избрал Saved Search, който няма нито едно активити.","depth":24,"bounds":{"left":0.28819445,"top":0.78555554,"width":0.46597221,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"Това обаче по никакъв начин не се подсказва на user-a и си мисля, че ще идват support тикети за такива неща...","depth":24,"bounds":{"left":0.28819445,"top":0.81,"width":0.5375,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"Какво мислите?","depth":24,"bounds":{"left":0.28819445,"top":0.83444446,"width":0.077083334,"height":0.02},"role_description":"text"},{"role":"AXCheckBox","text":"React with white_check_mark","depth":25,"bounds":{"left":0.8041667,"top":0.71666664,"width":0.022222223,"height":0.035555556},"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with eyes","depth":25,"bounds":{"left":0.8263889,"top":0.71666664,"width":0.022222223,"height":0.035555556},"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with raised_hands","depth":25,"bounds":{"left":0.8486111,"top":0.71666664,"width":0.022222223,"height":0.035555556},"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Add reaction…","depth":25,"bounds":{"left":0.87083334,"top":0.71666664,"width":0.022222223,"height":0.035555556},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Reply in thread","depth":25,"bounds":{"left":0.89305556,"top":0.71666664,"width":0.022222223,"height":0.035555556},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Forward message…","depth":25,"bounds":{"left":0.9152778,"top":0.71666664,"width":0.022222223,"height":0.035555556},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"Save for later","depth":25,"bounds":{"left":0.9375,"top":0.71666664,"width":0.022222223,"height":0.035555556},"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"More actions","depth":25,"bounds":{"left":0.9597222,"top":0.71666664,"width":0.022222223,"height":0.035555556},"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"","depth":23,"bounds":{"left":0.25833333,"top":0.88,"width":0.7236111,"height":0.04222222},"value":"","role_description":"text entry area","is_enabled":true,"is_focused":true,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"loading…","depth":11,"role_description":"text"},{"role":"AXStaticText","text":"Channel platform-inner-team","depth":11,"role_description":"text"}]...
|
7944518703698522703
|
-3600322415692461476
|
visual_change
|
hybrid
|
NULL
|
Jiminny Inc
Jiminny (Staging)
Add workspaces
Home
Jiminny Inc
Jiminny (Staging)
Add workspaces
Home
Home
DMs
DMs
Activity
Activity
Files
Files
Later
Later
More…
More
Unreads
Threads
Huddles
Drafts & sent
Directories
platform-inner-team
ai-chapter
alerts
backend
confusion-clinic
curiosity_lab
engineering
frontend
general
infra-changes
jiminny-bg
platform-tickets
product_launches
random
releases
sofia-office
support
thank-yous
the_people_of_jiminny
Aneliya Angelova
,
Nikolay Yankov
,
Steliyan Georgiev
Steliyan Georgiev
Adelina Petrova
,
Ilian Kyuchukov
,
Steliyan Georgiev
Adelina Petrova
Galya Dimitrova
Vasil Vasilev
Nikolay Nikolov
Galya Dimitrova
,
Nikolay Nikolov
Galya Dimitrova
,
Nikolay Yankov
Nikolay Yankov
Jira Cloud
Toast
Google Calendar
Messages
Messages
Channel Overview
Channel Overview
Refinements
Refinements
Files
Files
Pins
Pins
Bookmarks
Bookmarks
Retro Action Items
Retro Action Items
Deleted file
Deleted file
Add and Edit Channel Tabs
Canvas
List
Folder
Jump to date
Nikolay Nikolov
Apr 9th at 10:43:44 AM
10:43 AM
Още един фикс за outh:
https://github.com/jiminny/app/pull/11926
https://github.com/jiminny/app/pull/11926
#11926 SRD-6771 | JY-20622 | Fix OAuth
#11926 SRD-6771 | JY-20622 | Fix OAuth
JIRA:
SRD-6771
SRD-6771
|
JY-20622
JY-20622
Deployment notes:
• None
Comments
3
jiminny/app
jiminny/app
|
Apr 9th
|
Added by
GitHub
GitHub
Nikolay Yankov
Apr 9th at 11:00:43 AM
11:00 AM
Марио ще пусне един тикет за user-и от
Immutable
които не могат да се логнат с SSO в Sidekick.
Изглежда ми приоритетно
[EMAIL]
[EMAIL]
същото е и за
[EMAIL]
[EMAIL]
1 reaction, react with +1 emoji
1
Add reaction…
Apr 9th at 11:04:25 AM
11:04
Някой може ли да го погледне
Steliyan Georgiev
Apr 9th at 11:43:52 AM
11:43 AM
Може ли approve на
https://github.com/jiminny/prophet/pull/465
https://github.com/jiminny/prophet/pull/465
? Знам от какво се оплаква claude - нямаме проблем с това за сега.
Nikolay Nikolov
Apr 9th at 12:36:57 PM
12:36 PM
Някой дали знае тая конфигурация можем ли да я сменим ние ?
https://jiminny.atlassian.net/browse/SRD-6779?focusedCommentId=72677
https://jiminny.atlassian.net/browse/SRD-6779?focusedCommentId=72677
Comment by Nikolay Nikolov on a Bug in
Analyzing
The Immutable SSO tenant is configured with
name_id_format = persistent
, but the code expects the SAML response to contain the user's email address.
When Okta sends a
persistent
NameID, it sends a unique identifier (not the email), so
$samlUser->getUserId()
returns something like a UUID instead
…
See more
Comment
Comment
More actions...
Added by
Jira Cloud
Jira Cloud
Apr 9th at 12:37:38 PM
12:37
Ако е 'emailAddress' би трябвало да сработи - но да не счупя нещо друго
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Nikolay Ivanov
Apr 9th at 12:44:22 PM
12:44 PM
Вес може да има идея
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Nikolay Nikolov
Apr 9th at 12:45:49 PM
12:45 PM
Той е отпуск - по принцип това може и да не сработи, но няма да стане по лошо - само казваме какво искаме да ни върне Okta
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Apr 9th at 12:45:53 PM
12:45
ше го пробвам
1 reaction, react with +1 emoji
1
Add reaction…
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Nikolay Nikolov
Apr 9th at 1:04:12 PM
1:04 PM
Няма да е от това май
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Jump to date
New
Nikolay Yankov
Today at 11:35:04 AM
11:35 AM
Преди малко създадох конфигурация за новите репорти и в резултат не идва никакъв генериран репорт.
След проверка в базата разбираме, че съм избрал Saved Search, който няма нито едно активити.
Това обаче по никакъв начин не се подсказва на user-a и си мисля, че ще идват support тикети за такива неща...
Какво мислите?
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
loading…
Channel platform-inner-team
+SlackFileEditViewGoHistoryWindowHelpEDHomeDMsActivityFilesLater..•More*<→0 ll 0§ Support Daily • in 3 h 23 m100% <Tue 14 Apr 11:37:27+Jiminny ...# Starred8platform-inner-teamChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product_launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi...• Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili.... Adelina PetrovaO. Cala DimitravoSearch Jiminny Inc& platform-inner-team8 10MessagesP Channel OverviewP Refinements@ Filescommentuy minolay mindlov uita bugte anatyzinig< Pins• BookmarksP7 Retro Action Itemsw Deleted file+Thursday, April 9th~The Immutable SSO tenant is configured with name_id_formatpersestent, wut thecode expects the SAML response to contain the user's email address.When Okta sends a persistent NamelD, it sends a unique identifier (not the email), soSsamlUser->getUserId( returns something like a UUID instead...See moreCommentMore actions...Added by Jira CloudAко e 'emailAddress' би трябвало да сработи - но да не счупя нещо другоNikolay Ivanov 12:44 PMВес може да има идеяNikolay Nikolov™ 12:45 PMТой е отпуск - по принцип това може и да не сработи, но няма да стане по лошо - само казваме какво искаме да ни върне Oktaше го пробвамNikolay Nikolov ** 1:04 PMНяма да е от това майToday ~Nikolay Yankov 11:35 AMПреди малко създадох конфигурация за новите репорти и в резултат не идва никакьв генериран репорт.След проверка в базата разбираме, че съм избрал Saved Search, който няма нито едно активити.Това обаче по никакъв начин не се подсказва на user-a и си мисля, че ще идват support тивети за такива неща....Какво мислите?Message & platform-inner-team+AaNew...
|
10387
|
|
10389
|
207
|
0
|
2026-04-14T08:37:53.438577+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776155873438_m2.jpg...
|
Slack
|
platform-inner-team (Channel) - Jiminny Inc - Slac platform-inner-team (Channel) - Jiminny Inc - Slack...
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
Jiminny Inc
Jiminny (Staging)
Add workspaces
Home
Jiminny Inc
Jiminny (Staging)
Add workspaces
Home
Home
DMs
DMs
Activity
Activity
Files
Files
Later
Later
More…
More
Unreads
Threads
Huddles
Drafts & sent
Directories
platform-inner-team
ai-chapter
alerts
backend
confusion-clinic
curiosity_lab
engineering
frontend
general
infra-changes
jiminny-bg
platform-tickets
product_launches
random
releases
sofia-office
support
thank-yous
the_people_of_jiminny
Aneliya Angelova
,
Nikolay Yankov
,
Steliyan Georgiev
Steliyan Georgiev
Adelina Petrova
,
Ilian Kyuchukov
,
Steliyan Georgiev
Adelina Petrova
Galya Dimitrova
Vasil Vasilev
Nikolay Nikolov
Galya Dimitrova
,
Nikolay Nikolov
Galya Dimitrova
,
Nikolay Yankov
Nikolay Yankov
Jira Cloud
Toast
Google Calendar
Messages
Messages
Channel Overview
Channel Overview
Refinements
Refinements
Files
Files
Pins
Pins
Bookmarks
Bookmarks
Retro Action Items
Retro Action Items
Deleted file
Deleted file
Add and Edit Channel Tabs
Canvas
List
Folder
Jump to date
Nikolay Nikolov
Apr 9th at 10:43:44 AM
10:43 AM
Още един фикс за outh:
https://github.com/jiminny/app/pull/11926
https://github.com/jiminny/app/pull/11926
#11926 SRD-6771 | JY-20622 | Fix OAuth
#11926 SRD-6771 | JY-20622 | Fix OAuth
JIRA:
SRD-6771
SRD-6771
|
JY-20622
JY-20622
Deployment notes:
• None
Comments
3
jiminny/app
jiminny/app
|
Apr 9th
|
Added by
GitHub
GitHub
Nikolay Yankov
Apr 9th at 11:00:43 AM
11:00 AM
Марио ще пусне един тикет за user-и от
Immutable
които не могат да се логнат с SSO в Sidekick.
Изглежда ми приоритетно
[EMAIL]
[EMAIL]
същото е и за
[EMAIL]
[EMAIL]
1 reaction, react with +1 emoji
1
Add reaction…
Apr 9th at 11:04:25 AM
11:04
Някой може ли да го погледне
Steliyan Georgiev
Apr 9th at 11:43:52 AM
11:43 AM
Може ли approve на
https://github.com/jiminny/prophet/pull/465
https://github.com/jiminny/prophet/pull/465
? Знам от какво се оплаква claude - нямаме проблем с това за сега.
Nikolay Nikolov
Apr 9th at 12:36:57 PM
12:36 PM
Някой дали знае тая конфигурация можем ли да я сменим ние ?
https://jiminny.atlassian.net/browse/SRD-6779?focusedCommentId=72677
https://jiminny.atlassian.net/browse/SRD-6779?focusedCommentId=72677
Comment by Nikolay Nikolov on a Bug in
Analyzing
The Immutable SSO tenant is configured with
name_id_format = persistent
, but the code expects the SAML response to contain the user's email address.
When Okta sends a
persistent
NameID, it sends a unique identifier (not the email), so
$samlUser->getUserId()
returns something like a UUID instead
…
See more
Comment
Comment
More actions...
Added by
Jira Cloud
Jira Cloud
Apr 9th at 12:37:38 PM
12:37
Ако е 'emailAddress' би трябвало да сработи - но да не счупя нещо друго
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Nikolay Ivanov
Apr 9th at 12:44:22 PM
12:44 PM
Вес може да има идея
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Nikolay Nikolov
Apr 9th at 12:45:49 PM
12:45 PM
Той е отпуск - по принцип това може и да не сработи, но няма да стане по лошо - само казваме какво искаме да ни върне Okta
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Apr 9th at 12:45:53 PM
12:45
ше го пробвам
1 reaction, react with +1 emoji
1
Add reaction…
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Nikolay Nikolov
Apr 9th at 1:04:12 PM
1:04 PM
Няма да е от това май
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Jump to date
New
Nikolay Yankov
Today at 11:35:04 AM
11:35 AM
Преди малко създадох конфигурация за новите репорти и в резултат не идва никакъв генериран репорт.
След проверка в базата разбираме, че съм избрал Saved Search, който няма нито едно активити.
Това обаче по никакъв начин не се подсказва на user-a и си мисля, че ще идват support тикети за такива неща...
Какво мислите?
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
loading…
Channel platform-inner-team...
|
[{"role":"AXRadioButton","text [{"role":"AXRadioButton","text":"Jiminny Inc","depth":12,"bounds":{"left":0.23867187,"top":1.0,"width":0.0125,"height":-0.05486107},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":true,"is_expanded":false},{"role":"AXRadioButton","text":"Jiminny (Staging)","depth":12,"bounds":{"left":0.23867187,"top":1.0,"width":0.0125,"height":-0.090972185},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"Add workspaces","depth":12,"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXRadioButton","text":"Home","depth":14,"bounds":{"left":0.26054686,"top":1.0,"width":0.0203125,"height":-0.048611164},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":true,"is_expanded":false},{"role":"AXStaticText","text":"Home","depth":16,"bounds":{"left":0.26484376,"top":1.0,"width":0.01171875,"height":-0.08124995},"role_description":"text"},{"role":"AXRadioButton","text":"DMs","depth":14,"bounds":{"left":0.26054686,"top":1.0,"width":0.0203125,"height":-0.0958333},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"DMs","depth":16,"role_description":"text"},{"role":"AXRadioButton","text":"Activity","depth":14,"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Activity","depth":16,"role_description":"text"},{"role":"AXRadioButton","text":"Files","depth":14,"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Files","depth":16,"role_description":"text"},{"role":"AXRadioButton","text":"Later","depth":14,"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Later","depth":16,"role_description":"text"},{"role":"AXRadioButton","text":"More…","depth":14,"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"More","depth":16,"role_description":"text"},{"role":"AXStaticText","text":"Unreads","depth":21,"bounds":{"left":0.3,"top":1.0,"width":0.021484375,"height":-0.079861164},"role_description":"text"},{"role":"AXStaticText","text":"Threads","depth":21,"bounds":{"left":0.3,"top":1.0,"width":0.020703126,"height":-0.079861164},"role_description":"text"},{"role":"AXStaticText","text":"Huddles","depth":21,"bounds":{"left":0.3,"top":1.0,"width":0.021484375,"height":-0.079861164},"role_description":"text"},{"role":"AXStaticText","text":"Drafts & sent","depth":21,"bounds":{"left":0.3,"top":1.0,"width":0.034375,"height":-0.079861164},"role_description":"text"},{"role":"AXStaticText","text":"Directories","depth":21,"bounds":{"left":0.3,"top":1.0,"width":0.028515626,"height":-0.079861164},"role_description":"text"},{"role":"AXStaticText","text":"platform-inner-team","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"ai-chapter","depth":21,"role_description":"text"},{"role":"AXStaticText","text":"alerts","depth":21,"role_description":"text"},{"role":"AXStaticText","text":"backend","depth":21,"role_description":"text"},{"role":"AXStaticText","text":"confusion-clinic","depth":21,"role_description":"text"},{"role":"AXStaticText","text":"curiosity_lab","depth":21,"role_description":"text"},{"role":"AXStaticText","text":"engineering","depth":21,"role_description":"text"},{"role":"AXStaticText","text":"frontend","depth":21,"role_description":"text"},{"role":"AXStaticText","text":"general","depth":21,"role_description":"text"},{"role":"AXStaticText","text":"infra-changes","depth":21,"role_description":"text"},{"role":"AXStaticText","text":"jiminny-bg","depth":21,"role_description":"text"},{"role":"AXStaticText","text":"platform-tickets","depth":21,"role_description":"text"},{"role":"AXStaticText","text":"product_launches","depth":21,"role_description":"text"},{"role":"AXStaticText","text":"random","depth":21,"role_description":"text"},{"role":"AXStaticText","text":"releases","depth":21,"role_description":"text"},{"role":"AXStaticText","text":"sofia-office","depth":21,"role_description":"text"},{"role":"AXStaticText","text":"support","depth":21,"role_description":"text"},{"role":"AXStaticText","text":"thank-yous","depth":21,"role_description":"text"},{"role":"AXStaticText","text":"the_people_of_jiminny","depth":21,"role_description":"text"},{"role":"AXStaticText","text":"Aneliya Angelova","depth":23,"role_description":"text"},{"role":"AXStaticText","text":",","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Nikolay Yankov","depth":23,"role_description":"text"},{"role":"AXStaticText","text":",","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Steliyan Georgiev","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Steliyan Georgiev","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Adelina Petrova","depth":23,"role_description":"text"},{"role":"AXStaticText","text":",","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Ilian Kyuchukov","depth":23,"role_description":"text"},{"role":"AXStaticText","text":",","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Steliyan Georgiev","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Adelina Petrova","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Galya Dimitrova","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Vasil Vasilev","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Nikolay Nikolov","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Galya Dimitrova","depth":23,"role_description":"text"},{"role":"AXStaticText","text":",","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Nikolay Nikolov","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Galya Dimitrova","depth":23,"role_description":"text"},{"role":"AXStaticText","text":",","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Nikolay Yankov","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Nikolay Yankov","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Jira Cloud","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Toast","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Google Calendar","depth":23,"role_description":"text"},{"role":"AXRadioButton","text":"Messages","depth":17,"bounds":{"left":0.3765625,"top":1.0,"width":0.036328126,"height":-0.079861164},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":true,"is_expanded":false},{"role":"AXStaticText","text":"Messages","depth":19,"bounds":{"left":0.3875,"top":1.0,"width":0.022265624,"height":-0.087499976},"role_description":"text"},{"role":"AXRadioButton","text":"Channel Overview","depth":17,"bounds":{"left":0.4140625,"top":1.0,"width":0.05625,"height":-0.079861164},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Channel Overview","depth":19,"bounds":{"left":0.425,"top":1.0,"width":0.0421875,"height":-0.087499976},"role_description":"text"},{"role":"AXRadioButton","text":"Refinements","depth":17,"bounds":{"left":0.47148436,"top":1.0,"width":0.044140626,"height":-0.079861164},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Refinements","depth":19,"bounds":{"left":0.48242188,"top":1.0,"width":0.028515626,"height":-0.087499976},"role_description":"text"},{"role":"AXRadioButton","text":"Files","depth":17,"bounds":{"left":0.5171875,"top":1.0,"width":0.024609376,"height":-0.079861164},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Files","depth":19,"bounds":{"left":0.528125,"top":1.0,"width":0.010546875,"height":-0.087499976},"role_description":"text"},{"role":"AXRadioButton","text":"Pins","depth":17,"bounds":{"left":0.54296875,"top":1.0,"width":0.023828125,"height":-0.079861164},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Pins","depth":19,"bounds":{"left":0.55390626,"top":1.0,"width":0.009765625,"height":-0.087499976},"role_description":"text"},{"role":"AXRadioButton","text":"Bookmarks","depth":17,"bounds":{"left":0.5683594,"top":1.0,"width":0.03984375,"height":-0.079861164},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Bookmarks","depth":19,"bounds":{"left":0.5792969,"top":1.0,"width":0.02578125,"height":-0.087499976},"role_description":"text"},{"role":"AXRadioButton","text":"Retro Action Items","depth":17,"bounds":{"left":0.609375,"top":1.0,"width":0.058203124,"height":-0.079861164},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Retro Action Items","depth":19,"bounds":{"left":0.6207031,"top":1.0,"width":0.0421875,"height":-0.087499976},"role_description":"text"},{"role":"AXRadioButton","text":"Deleted file","depth":17,"bounds":{"left":0.66875,"top":1.0,"width":0.0421875,"height":-0.079861164},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Deleted file","depth":19,"bounds":{"left":0.6796875,"top":1.0,"width":0.0265625,"height":-0.087499976},"role_description":"text"},{"role":"AXPopUpButton","text":"Add and Edit Channel Tabs","depth":17,"bounds":{"left":0.7121094,"top":1.0,"width":0.012890625,"height":-0.079861164},"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Canvas","depth":17,"role_description":"text"},{"role":"AXStaticText","text":"List","depth":17,"role_description":"text"},{"role":"AXStaticText","text":"Folder","depth":17,"role_description":"text"},{"role":"AXPopUpButton","text":"Jump to date","depth":22,"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Nikolay Nikolov","depth":23,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 10:43:44 AM","depth":23,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"10:43 AM","depth":24,"role_description":"text"},{"role":"AXStaticText","text":"Още един фикс за outh:","depth":24,"role_description":"text"},{"role":"AXLink","text":"https://github.com/jiminny/app/pull/11926","depth":24,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"https://github.com/jiminny/app/pull/11926","depth":25,"role_description":"text"},{"role":"AXLink","text":"#11926 SRD-6771 | JY-20622 | Fix OAuth","depth":25,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"#11926 SRD-6771 | JY-20622 | Fix OAuth","depth":26,"role_description":"text"},{"role":"AXStaticText","text":"JIRA:","depth":25,"role_description":"text"},{"role":"AXLink","text":"SRD-6771","depth":25,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"SRD-6771","depth":26,"role_description":"text"},{"role":"AXStaticText","text":"|","depth":25,"role_description":"text"},{"role":"AXLink","text":"JY-20622","depth":25,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"JY-20622","depth":26,"role_description":"text"},{"role":"AXStaticText","text":"Deployment notes:","depth":25,"role_description":"text"},{"role":"AXStaticText","text":"• None","depth":25,"role_description":"text"},{"role":"AXStaticText","text":"Comments","depth":26,"role_description":"text"},{"role":"AXStaticText","text":"3","depth":26,"role_description":"text"},{"role":"AXLink","text":"jiminny/app","depth":25,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"jiminny/app","depth":26,"role_description":"text"},{"role":"AXStaticText","text":"|","depth":25,"role_description":"text"},{"role":"AXStaticText","text":"Apr 9th","depth":25,"role_description":"text"},{"role":"AXStaticText","text":"|","depth":25,"role_description":"text"},{"role":"AXStaticText","text":"Added by","depth":25,"role_description":"text"},{"role":"AXLink","text":"GitHub","depth":25,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"GitHub","depth":26,"role_description":"text"},{"role":"AXButton","text":"Nikolay Yankov","depth":23,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 11:00:43 AM","depth":23,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"11:00 AM","depth":24,"role_description":"text"},{"role":"AXStaticText","text":"Марио ще пусне един тикет за user-и от","depth":24,"role_description":"text"},{"role":"AXStaticText","text":"Immutable","depth":25,"role_description":"text"},{"role":"AXStaticText","text":"които не могат да се логнат с SSO в Sidekick.","depth":24,"role_description":"text"},{"role":"AXStaticText","text":"Изглежда ми приоритетно","depth":24,"role_description":"text"},{"role":"AXLink","text":"vid.nedumaran@immutable.com","depth":24,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"vid.nedumaran@immutable.com","depth":25,"role_description":"text"},{"role":"AXStaticText","text":"същото е и за","depth":24,"role_description":"text"},{"role":"AXLink","text":"alex.li@immutable.com","depth":24,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"alex.li@immutable.com","depth":25,"role_description":"text"},{"role":"AXCheckBox","text":"1 reaction, react with +1 emoji","depth":24,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"1","depth":25,"role_description":"text"},{"role":"AXButton","text":"Add reaction…","depth":24,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXLink","text":"Apr 9th at 11:04:25 AM","depth":24,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"11:04","depth":25,"role_description":"text"},{"role":"AXStaticText","text":"Някой може ли да го погледне","depth":24,"role_description":"text"},{"role":"AXButton","text":"Steliyan Georgiev","depth":23,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 11:43:52 AM","depth":23,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"11:43 AM","depth":24,"role_description":"text"},{"role":"AXStaticText","text":"Може ли approve на","depth":24,"role_description":"text"},{"role":"AXLink","text":"https://github.com/jiminny/prophet/pull/465","depth":24,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"https://github.com/jiminny/prophet/pull/465","depth":25,"role_description":"text"},{"role":"AXStaticText","text":"? Знам от какво се оплаква claude - нямаме проблем с това за сега.","depth":24,"role_description":"text"},{"role":"AXButton","text":"Nikolay Nikolov","depth":23,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 12:36:57 PM","depth":23,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"12:36 PM","depth":24,"role_description":"text"},{"role":"AXStaticText","text":"Някой дали знае тая конфигурация можем ли да я сменим ние ?","depth":24,"role_description":"text"},{"role":"AXLink","text":"https://jiminny.atlassian.net/browse/SRD-6779?focusedCommentId=72677","depth":24,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"https://jiminny.atlassian.net/browse/SRD-6779?focusedCommentId=72677","depth":25,"role_description":"text"},{"role":"AXStaticText","text":"Comment by Nikolay Nikolov on a Bug in","depth":26,"role_description":"text"},{"role":"AXStaticText","text":"Analyzing","depth":27,"role_description":"text"},{"role":"AXStaticText","text":"The Immutable SSO tenant is configured with","depth":26,"role_description":"text"},{"role":"AXStaticText","text":"name_id_format = persistent","depth":27,"role_description":"text"},{"role":"AXStaticText","text":"","depth":26,"role_description":"text"},{"role":"AXStaticText","text":", but the code expects the SAML response to contain the user's email address.","depth":26,"role_description":"text"},{"role":"AXStaticText","text":"When Okta sends a","depth":26,"role_description":"text"},{"role":"AXStaticText","text":"persistent","depth":27,"role_description":"text"},{"role":"AXStaticText","text":"NameID, it sends a unique identifier (not the email), so","depth":26,"role_description":"text"},{"role":"AXStaticText","text":"$samlUser->getUserId()","depth":27,"role_description":"text"},{"role":"AXStaticText","text":"returns something like a UUID instead","depth":26,"role_description":"text"},{"role":"AXStaticText","text":"…","depth":26,"role_description":"text"},{"role":"AXButton","text":"See more","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Comment","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Comment","depth":27,"role_description":"text"},{"role":"AXComboBox","text":"More actions...","depth":26,"placeholder":"More actions...","role_description":"combo box","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Added by","depth":25,"role_description":"text"},{"role":"AXLink","text":"Jira Cloud","depth":25,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Jira Cloud","depth":26,"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 12:37:38 PM","depth":24,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"12:37","depth":25,"role_description":"text"},{"role":"AXStaticText","text":"Ако е 'emailAddress' би трябвало да сработи - но да не счупя нещо друго","depth":24,"role_description":"text"},{"role":"AXCheckBox","text":"React with white_check_mark","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with eyes","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with raised_hands","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Add reaction…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Reply in thread","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Forward message…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"Save for later","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"More actions","depth":25,"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Nikolay Ivanov","depth":23,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 12:44:22 PM","depth":23,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"12:44 PM","depth":24,"role_description":"text"},{"role":"AXStaticText","text":"Вес може да има идея","depth":24,"role_description":"text"},{"role":"AXCheckBox","text":"React with white_check_mark","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with eyes","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with raised_hands","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Add reaction…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Reply in thread","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Forward message…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"Save for later","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"More actions","depth":25,"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Nikolay Nikolov","depth":23,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 12:45:49 PM","depth":23,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"12:45 PM","depth":24,"role_description":"text"},{"role":"AXStaticText","text":"Той е отпуск - по принцип това може и да не сработи, но няма да стане по лошо - само казваме какво искаме да ни върне Okta","depth":24,"role_description":"text"},{"role":"AXCheckBox","text":"React with white_check_mark","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with eyes","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with raised_hands","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Add reaction…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Reply in thread","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Forward message…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"Save for later","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"More actions","depth":25,"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXLink","text":"Apr 9th at 12:45:53 PM","depth":24,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"12:45","depth":25,"role_description":"text"},{"role":"AXStaticText","text":"ше го пробвам","depth":24,"role_description":"text"},{"role":"AXCheckBox","text":"1 reaction, react with +1 emoji","depth":24,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"1","depth":25,"role_description":"text"},{"role":"AXButton","text":"Add reaction…","depth":24,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with white_check_mark","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with eyes","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with raised_hands","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Add reaction…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Reply in thread","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Forward message…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"Save for later","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"More actions","depth":25,"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Nikolay Nikolov","depth":23,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 1:04:12 PM","depth":23,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"1:04 PM","depth":24,"role_description":"text"},{"role":"AXStaticText","text":"Няма да е от това май","depth":24,"role_description":"text"},{"role":"AXCheckBox","text":"React with white_check_mark","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with eyes","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with raised_hands","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Add reaction…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Reply in thread","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Forward message…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"Save for later","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"More actions","depth":25,"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"Jump to date","depth":22,"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"New","depth":22,"role_description":"text"},{"role":"AXButton","text":"Nikolay Yankov","depth":23,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"role_description":"text"},{"role":"AXLink","text":"Today at 11:35:04 AM","depth":23,"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"11:35 AM","depth":24,"role_description":"text"},{"role":"AXStaticText","text":"Преди малко създадох конфигурация за новите репорти и в резултат не идва никакъв генериран репорт.","depth":24,"role_description":"text"},{"role":"AXStaticText","text":"След проверка в базата разбираме, че съм избрал Saved Search, който няма нито едно активити.","depth":24,"role_description":"text"},{"role":"AXStaticText","text":"Това обаче по никакъв начин не се подсказва на user-a и си мисля, че ще идват support тикети за такива неща...","depth":24,"role_description":"text"},{"role":"AXStaticText","text":"Какво мислите?","depth":24,"role_description":"text"},{"role":"AXCheckBox","text":"React with white_check_mark","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with eyes","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with raised_hands","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Add reaction…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Reply in thread","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Forward message…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"Save for later","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"More actions","depth":25,"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"","depth":23,"value":"","role_description":"text entry area","is_enabled":true,"is_focused":true,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"loading…","depth":11,"role_description":"text"},{"role":"AXStaticText","text":"Channel platform-inner-team","depth":11,"role_description":"text"}]...
|
7944518703698522703
|
-3600322415692461476
|
idle
|
hybrid
|
NULL
|
Jiminny Inc
Jiminny (Staging)
Add workspaces
Home
Jiminny Inc
Jiminny (Staging)
Add workspaces
Home
Home
DMs
DMs
Activity
Activity
Files
Files
Later
Later
More…
More
Unreads
Threads
Huddles
Drafts & sent
Directories
platform-inner-team
ai-chapter
alerts
backend
confusion-clinic
curiosity_lab
engineering
frontend
general
infra-changes
jiminny-bg
platform-tickets
product_launches
random
releases
sofia-office
support
thank-yous
the_people_of_jiminny
Aneliya Angelova
,
Nikolay Yankov
,
Steliyan Georgiev
Steliyan Georgiev
Adelina Petrova
,
Ilian Kyuchukov
,
Steliyan Georgiev
Adelina Petrova
Galya Dimitrova
Vasil Vasilev
Nikolay Nikolov
Galya Dimitrova
,
Nikolay Nikolov
Galya Dimitrova
,
Nikolay Yankov
Nikolay Yankov
Jira Cloud
Toast
Google Calendar
Messages
Messages
Channel Overview
Channel Overview
Refinements
Refinements
Files
Files
Pins
Pins
Bookmarks
Bookmarks
Retro Action Items
Retro Action Items
Deleted file
Deleted file
Add and Edit Channel Tabs
Canvas
List
Folder
Jump to date
Nikolay Nikolov
Apr 9th at 10:43:44 AM
10:43 AM
Още един фикс за outh:
https://github.com/jiminny/app/pull/11926
https://github.com/jiminny/app/pull/11926
#11926 SRD-6771 | JY-20622 | Fix OAuth
#11926 SRD-6771 | JY-20622 | Fix OAuth
JIRA:
SRD-6771
SRD-6771
|
JY-20622
JY-20622
Deployment notes:
• None
Comments
3
jiminny/app
jiminny/app
|
Apr 9th
|
Added by
GitHub
GitHub
Nikolay Yankov
Apr 9th at 11:00:43 AM
11:00 AM
Марио ще пусне един тикет за user-и от
Immutable
които не могат да се логнат с SSO в Sidekick.
Изглежда ми приоритетно
[EMAIL]
[EMAIL]
същото е и за
[EMAIL]
[EMAIL]
1 reaction, react with +1 emoji
1
Add reaction…
Apr 9th at 11:04:25 AM
11:04
Някой може ли да го погледне
Steliyan Georgiev
Apr 9th at 11:43:52 AM
11:43 AM
Може ли approve на
https://github.com/jiminny/prophet/pull/465
https://github.com/jiminny/prophet/pull/465
? Знам от какво се оплаква claude - нямаме проблем с това за сега.
Nikolay Nikolov
Apr 9th at 12:36:57 PM
12:36 PM
Някой дали знае тая конфигурация можем ли да я сменим ние ?
https://jiminny.atlassian.net/browse/SRD-6779?focusedCommentId=72677
https://jiminny.atlassian.net/browse/SRD-6779?focusedCommentId=72677
Comment by Nikolay Nikolov on a Bug in
Analyzing
The Immutable SSO tenant is configured with
name_id_format = persistent
, but the code expects the SAML response to contain the user's email address.
When Okta sends a
persistent
NameID, it sends a unique identifier (not the email), so
$samlUser->getUserId()
returns something like a UUID instead
…
See more
Comment
Comment
More actions...
Added by
Jira Cloud
Jira Cloud
Apr 9th at 12:37:38 PM
12:37
Ако е 'emailAddress' би трябвало да сработи - но да не счупя нещо друго
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Nikolay Ivanov
Apr 9th at 12:44:22 PM
12:44 PM
Вес може да има идея
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Nikolay Nikolov
Apr 9th at 12:45:49 PM
12:45 PM
Той е отпуск - по принцип това може и да не сработи, но няма да стане по лошо - само казваме какво искаме да ни върне Okta
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Apr 9th at 12:45:53 PM
12:45
ше го пробвам
1 reaction, react with +1 emoji
1
Add reaction…
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Nikolay Nikolov
Apr 9th at 1:04:12 PM
1:04 PM
Няма да е от това май
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Jump to date
New
Nikolay Yankov
Today at 11:35:04 AM
11:35 AM
Преди малко създадох конфигурация за новите репорти и в резултат не идва никакъв генериран репорт.
След проверка в базата разбираме, че съм избрал Saved Search, който няма нито едно активити.
Това обаче по никакъв начин не се подсказва на user-a и си мисля, че ще идват support тикети за такива неща...
Какво мислите?
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
loading…
Channel platform-inner-team
PhpStormFV faVsco.js~Projectv© Partner.php© Permission.php© PhoneNumber.php© PlaybackTheme.php© Playbook.php© PlaybookCategory.php© Playlist.php© RateLimit.phpC) Region.pho© Role.php©RoleChangeEvent.php© ScopeGroup.php© Session.php© SlackBot.php© SocialAccount.php© Stage.php© Task.php© Team.php©TeamAiContext.phpC) TeamDomain.php©TeamFeature.php©TeamSettings.php© TextRelay.php© Track.php© TranscriptionModel.php© TranscriptionModelLocale./© TranscriptionProvider.php©User.php© UserSettings.php©Vocabulary.php© VocabularyPronunciation.p© VoiceAccess.php©VoiceConsentPrefix.php> D Notifications› D Observers› C Policies> D Providers> D Queuev | Repositories> MAi> DJ AutoScoring> D Calendar>DCrm> D Geography© ActiveStreamsRepository.p©ActivityCommentRepositor©ActivityLogRepository.php© ActivityMessageRepository© ActivityMomentRepository.© ActivityProviderRepository.©ActivityRepository.php©ActivitySearchFilterReposit© ActivityShareRepository.phActivityUploadSettingRepo© AiPromptRepository.php© AskAnythingRepository.ph|© AutomatedReportsReposits© CalllmportRepository.php© CoachingFeedbackRepositViewNavigateCodeLaravelRefactonWindow#11894 on JY-18909-automated-reports-ask-jiminny k ~© ReportController.php© JiminnyDebugCommand.php© AutomatedReportsSendCommand.phpAutomatedReportsCommand.phpC AutomatedReportsRepository.php xAulomaleakeporisservice.onp© CreateHeldActivityEvent.php© TrackProviderInstalledEvent.php© ActivityLogged.php© AutomatedReportsCallbackService.phpCreateActivityLoggedEvent.phpRequestGenerateAskJiminnyReportJob.php© RequestGenerateReportJob.phpC AutomatedReportResult.php= custom.log= laravel.logA SF [jiminny@localhost]Hs local liminnyalocalnostconsole PRODA console [EU]© UserPilotActivityListener.phpA console [STAGING]© AskJiminnyReportActivityService.phpC) RequestGenerateAskJiminnyReportJobTest.phpTx. AutoyHlayground4155A13 V.4 ^uronarecreoorrskepostory520521creace a new aucomared reporaOparam array $dataQreturn AutomatedReportlic function create(array $data): AutomatedReportf...}Find an automated report bu UID@param string $uvid523526527528529530531532533534@return AutomatedReport|nulllic function findByUuid(string $uvid): ?AutomatedReportO0/1538539return AutomatedReport::where('uvid', AutomatedReport:: to0ptimized(Suvid))->firstO;542543Retrieve all standard (non-Ask Liminay) automated reports.5445451oparam scrine osorccocunnThe column to sort by. Allowed values: 'created_by','created_at'. Defaults to540Oparam string $sortDirection The sort direction. Allowed values:'asc','desc'. Defaults to 'desc'.541548Oreturn Collection<AutomatedReport>549Isageslic function getAllStandardReports(string $sortColumn = 'created_at',string $sortDirection = 'desc'Collection {.J552553554555556557Retrieve all Ask Liminny reports created by the given user.Oparam User$userThe user whose reports to retrieve.Oparam string $sortColumnThe column to sort by. Allowed values: 'created_by','created_at'. Defaults to 561Oparam string $sortDirection The sort direction. Allowed values:'asc','desc'. Defaults to 'desc'.559560563@return Collection<AutomatedReport>Gajiminny v016 A 13 X13 A Vsocial_accounts sa= sa.sociable_id: on t.id = u.team_idand sa.provider = 'salesforce';Wnere 10 = 11g JOIN playbooks p 1.n<->1: on g.playbook_id = p.id where g.team_iwhere id = 565;oks where team_id = 1;oks where id = 175;ok_categories where playbook_id = 175;where team_id = 1;where id = 7160;ofiles where user_id = 7160;ovlder, playbook_category-1a, user_1d, lead_1a, contact_la, accounyid, crm_provider_id, transcription_id,slaLuse crm_configuration_id = 1 and type = 'conference'd IS NOT NULLoader' and actual_start_time IS NOT NULLties where id = 54747783; # 00U0400000pCzojMACity_type, pc.id, pc.nameries pc 1<->1.n: on p.id = pc.playbook_idand p.activity_type = 'event';elds WHERE crm_configuration_id = 1 and object_type = 'event';eld_values WHERE crm_field_id = 4;youts cl join playbook_layouts pl 1<->1.n: on cl.id = pl.layout_idion_id = 1 and pl.playbook_id = 175;mared redorusraaid = t.id'daily've'now() OR r.expires.at IS NULL);ted_report_results where cepont.id IN (18, 33);565566 Vted_report_results where ceRontaig IN (34);IsagesLic function getAskJiminnyReportsByUser(User Suser.string $sortColumn = 'created_at',string $sortDirection = 'desc'> Collection {..$0.Support Daily • in 3h 23 mRequestGenerateAskJiminnyReportJobTest100% C2Tue 14 Apr 11:37:53CascadeFixing ReportControlleAutomated Report FaiIN @AutomatedReportsCommand.phpadd additional parameter report id and if provider then instead ofvy wrecuehell lakes wle levort vy le or uule.nud checksut siatus, leaill aetivily aneorher stuff used for qurying. This iwll be used only manually so if there shold be info if not applicable based onstandara searenLet me read the command and related files first.kead Auloialecreoorsredosilorv.ono ›Now let me check the AutonatedReoort model tor relevanttielas:Explored AutorNow.nave every.ninelneeo. Let me imolement tne changes.s|getTeam|expires_at|getFrequencylgetType|STATUS_lis›• AutomatedReportsCommand.php+78 -2Also need to check if findByUuid handles soft-deleted — it doesn't, so for UUID lookup we need withTrashed too.Let me tix thatAutomatedReportsCommand.phpDone. Here's what was added:+1 -1Changes SummaryNew option: —report-id= — accepts either a numeric ID or a UUID.processsing lekeportl, — oypasses treouency logie entirely.• Looks up by ID (AutomatedReport: :withTrashed()->find() ) or UUID (also withTrashed so even deletedreports can be triggered manually)• Calls warnIfNotApplicableForSchedule() for informational outputDispatches the job the same way as the scheduled pathwarnIfNotApplicableForSchedule() - mirrors every condition from getActiveReportsByFrequency() and thejob's validateReport(), printing a warn() (yellow terminal output) for each condition that would cause the reportto oe skiooed in a normal scheculed run:CheckReport is soft-deletedstatus is inactiveTeam not STATUS_ACTIVEexpires_at is pastFrequency wouldn't run todayUsage:bash# By IDSourcewathi rashed — notln normal scopegetActiveReportsByFrequencygetActiveReportsByFrequencygetActiveReportsByFrequencyscheduling logic in handle()php artisan automated-reports —report-id=68#BY UULDphp artisan automated-reports --report-1d=some-uuid-hereC1l -1 file +84 -2 >Add findByldOrUuid+ <> CodeClaude Sonnet 4.6Reject allAccept allWinasun lean55:45uir-o( 4 spaces...
|
10385
|
|
10390
|
206
|
0
|
2026-04-14T08:38:00.855401+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776155880855_m1.jpg...
|
Slack
|
platform-inner-team (Channel) - Jiminny Inc - Slac platform-inner-team (Channel) - Jiminny Inc - Slack...
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
Jiminny Inc
Jiminny (Staging)
Add workspaces
Home
Jiminny Inc
Jiminny (Staging)
Add workspaces
Home
Home
DMs
DMs
Activity
Activity
Files
Files
Later
Later
More…
More
Unreads
Threads
Huddles
Drafts & sent
Directories
platform-inner-team
ai-chapter
alerts
backend
confusion-clinic
curiosity_lab
engineering
frontend
general
infra-changes
jiminny-bg
platform-tickets
product_launches
random
releases
sofia-office
support
thank-yous
the_people_of_jiminny
Aneliya Angelova
,
Nikolay Yankov
,
Steliyan Georgiev
Steliyan Georgiev
Adelina Petrova
,
Ilian Kyuchukov
,
Steliyan Georgiev
Adelina Petrova
Galya Dimitrova
Vasil Vasilev
Nikolay Nikolov
Galya Dimitrova
,
Nikolay Nikolov
Galya Dimitrova
,
Nikolay Yankov
Nikolay Yankov
Jira Cloud
Toast
Google Calendar
Messages
Messages
Channel Overview
Channel Overview
Refinements
Refinements
Files
Files
Pins
Pins
Bookmarks
Bookmarks
Retro Action Items
Retro Action Items
Deleted file
Deleted file
Add and Edit Channel Tabs
Canvas
List
Folder
Jump to date
Nikolay Nikolov
Apr 9th at 10:43:44 AM
10:43 AM
Още един фикс за outh:
https://github.com/jiminny/app/pull/11926
https://github.com/jiminny/app/pull/11926
#11926 SRD-6771 | JY-20622 | Fix OAuth
#11926 SRD-6771 | JY-20622 | Fix OAuth
JIRA:
SRD-6771
SRD-6771
|
JY-20622
JY-20622
Deployment notes:
• None
Comments
3
jiminny/app
jiminny/app
|
Apr 9th
|
Added by
GitHub
GitHub
Nikolay Yankov
Apr 9th at 11:00:43 AM
11:00 AM
Марио ще пусне един тикет за user-и от
Immutable
които не могат да се логнат с SSO в Sidekick.
Изглежда ми приоритетно
[EMAIL]
[EMAIL]
същото е и за
[EMAIL]
[EMAIL]
1 reaction, react with +1 emoji
1
Add reaction…
Apr 9th at 11:04:25 AM
11:04
Някой може ли да го погледне
Steliyan Georgiev
Apr 9th at 11:43:52 AM
11:43 AM
Може ли approve на
https://github.com/jiminny/prophet/pull/465
https://github.com/jiminny/prophet/pull/465
? Знам от какво се оплаква claude - нямаме проблем с това за сега.
Nikolay Nikolov
Apr 9th at 12:36:57 PM
12:36 PM
Някой дали знае тая конфигурация можем ли да я сменим ние ?
https://jiminny.atlassian.net/browse/SRD-6779?focusedCommentId=72677
https://jiminny.atlassian.net/browse/SRD-6779?focusedCommentId=72677
Comment by Nikolay Nikolov on a Bug in
Analyzing
The Immutable SSO tenant is configured with
name_id_format = persistent
, but the code expects the SAML response to contain the user's email address.
When Okta sends a
persistent
NameID, it sends a unique identifier (not the email), so
$samlUser->getUserId()
returns something like a UUID instead
…
See more
Comment
Comment
More actions...
Added by
Jira Cloud
Jira Cloud
Apr 9th at 12:37:38 PM
12:37
Ако е 'emailAddress' би трябвало да сработи - но да не счупя нещо друго
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Nikolay Ivanov
Apr 9th at 12:44:22 PM
12:44 PM
Вес може да има идея
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Nikolay Nikolov
Apr 9th at 12:45:49 PM
12:45 PM
Той е отпуск - по принцип това може и да не сработи, но няма да стане по лошо - само казваме какво искаме да ни върне Okta
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Apr 9th at 12:45:53 PM
12:45
ше го пробвам
1 reaction, react with +1 emoji
1
Add reaction…
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Nikolay Nikolov
Apr 9th at 1:04:12 PM
1:04 PM
Няма да е от това май
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Jump to date
New
Nikolay Yankov
Today at 11:35:04 AM
11:35 AM
Преди малко създадох конфигурация за новите репорти и в резултат не идва никакъв генериран репорт.
След проверка в базата разбираме, че съм избрал Saved Search, който няма нито едно активити.
Това обаче по никакъв начин не се подсказва на user-a и си мисля, че ще идват support тикети за такива неща...
Какво мислите?
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
loading…
Channel platform-inner-team...
|
[{"role":"AXRadioButton","text [{"role":"AXRadioButton","text":"Jiminny Inc","depth":12,"bounds":{"left":0.009722223,"top":0.08777778,"width":0.022222223,"height":0.035555556},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":true,"is_expanded":false},{"role":"AXRadioButton","text":"Jiminny (Staging)","depth":12,"bounds":{"left":0.009722223,"top":0.14555556,"width":0.022222223,"height":0.035555556},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"Add workspaces","depth":12,"bounds":{"left":0.009722223,"top":0.20333333,"width":0.022222223,"height":0.035555556},"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXRadioButton","text":"Home","depth":14,"bounds":{"left":0.048611112,"top":0.07777778,"width":0.036111113,"height":0.075555556},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":true,"is_expanded":false},{"role":"AXStaticText","text":"Home","depth":16,"bounds":{"left":0.05625,"top":0.13,"width":0.020833334,"height":0.015555556},"role_description":"text"},{"role":"AXRadioButton","text":"DMs","depth":14,"bounds":{"left":0.048611112,"top":0.15333334,"width":0.036111113,"height":0.075555556},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"DMs","depth":16,"bounds":{"left":0.058333334,"top":0.20555556,"width":0.016666668,"height":0.015555556},"role_description":"text"},{"role":"AXRadioButton","text":"Activity","depth":14,"bounds":{"left":0.048611112,"top":0.22888888,"width":0.036111113,"height":0.075555556},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Activity","depth":16,"bounds":{"left":0.05277778,"top":0.28111112,"width":0.027083334,"height":0.015555556},"role_description":"text"},{"role":"AXRadioButton","text":"Files","depth":14,"bounds":{"left":0.048611112,"top":0.30444443,"width":0.036111113,"height":0.075555556},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Files","depth":16,"bounds":{"left":0.058333334,"top":0.35666665,"width":0.015972223,"height":0.015555556},"role_description":"text"},{"role":"AXRadioButton","text":"Later","depth":14,"bounds":{"left":0.048611112,"top":0.38,"width":0.036111113,"height":0.075555556},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Later","depth":16,"bounds":{"left":0.057638887,"top":0.43222222,"width":0.018055556,"height":0.015555556},"role_description":"text"},{"role":"AXRadioButton","text":"More…","depth":14,"bounds":{"left":0.048611112,"top":0.45555556,"width":0.036111113,"height":0.075555556},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"More","depth":16,"bounds":{"left":0.056944445,"top":0.50777775,"width":0.01875,"height":0.015555556},"role_description":"text"},{"role":"AXStaticText","text":"Unreads","depth":21,"bounds":{"left":0.11875,"top":0.12777779,"width":0.038194444,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Threads","depth":21,"bounds":{"left":0.11875,"top":0.12777779,"width":0.036805555,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Huddles","depth":21,"bounds":{"left":0.11875,"top":0.12777779,"width":0.038194444,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Drafts & sent","depth":21,"bounds":{"left":0.11875,"top":0.12777779,"width":0.06111111,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Directories","depth":21,"bounds":{"left":0.11875,"top":0.12777779,"width":0.050694443,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"platform-inner-team","depth":23,"bounds":{"left":0.12986112,"top":0.18222222,"width":0.093055554,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"ai-chapter","depth":21,"bounds":{"left":0.12986112,"top":0.25555557,"width":0.046527777,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"alerts","depth":21,"bounds":{"left":0.12986112,"top":0.28666666,"width":0.025694445,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"backend","depth":21,"bounds":{"left":0.12986112,"top":0.31777778,"width":0.038194444,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"confusion-clinic","depth":21,"bounds":{"left":0.12986112,"top":0.34888887,"width":0.072222225,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"curiosity_lab","depth":21,"bounds":{"left":0.12986112,"top":0.38,"width":0.057638887,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"engineering","depth":21,"bounds":{"left":0.12986112,"top":0.41111112,"width":0.054166667,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"frontend","depth":21,"bounds":{"left":0.12986112,"top":0.4422222,"width":0.04027778,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"general","depth":21,"bounds":{"left":0.12986112,"top":0.47333333,"width":0.034027778,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"infra-changes","depth":21,"bounds":{"left":0.12986112,"top":0.5044444,"width":0.061805554,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"jiminny-bg","depth":21,"bounds":{"left":0.12986112,"top":0.53555554,"width":0.048611112,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"platform-tickets","depth":21,"bounds":{"left":0.12986112,"top":0.56666666,"width":0.072916664,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"product_launches","depth":21,"bounds":{"left":0.12986112,"top":0.5977778,"width":0.08055556,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"random","depth":21,"bounds":{"left":0.12986112,"top":0.6288889,"width":0.035416666,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"releases","depth":21,"bounds":{"left":0.12986112,"top":0.66,"width":0.036805555,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"sofia-office","depth":21,"bounds":{"left":0.12986112,"top":0.6911111,"width":0.05138889,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"support","depth":21,"bounds":{"left":0.12986112,"top":0.7222222,"width":0.036111113,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"thank-yous","depth":21,"bounds":{"left":0.12986112,"top":0.75333333,"width":0.05138889,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"the_people_of_jiminny","depth":21,"bounds":{"left":0.12986112,"top":0.78444445,"width":0.094444446,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"Aneliya Angelova","depth":23,"bounds":{"left":0.12986112,"top":0.8577778,"width":0.07847222,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":",","depth":23,"bounds":{"left":0.20833333,"top":0.8577778,"width":0.013194445,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"Nikolay Yankov","depth":23,"bounds":{"left":0.21319444,"top":0.8577778,"width":0.029861111,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":",","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Steliyan Georgiev","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Steliyan Georgiev","depth":23,"bounds":{"left":0.12986112,"top":0.8888889,"width":0.07986111,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"Adelina Petrova","depth":23,"bounds":{"left":0.12986112,"top":0.92,"width":0.072222225,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":",","depth":23,"bounds":{"left":0.2013889,"top":0.92,"width":0.0055555557,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"Ilian Kyuchukov","depth":23,"bounds":{"left":0.20694445,"top":0.92,"width":0.015972223,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":",","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Steliyan Georgiev","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Adelina Petrova","depth":23,"bounds":{"left":0.12986112,"top":0.95111114,"width":0.072222225,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"Galya Dimitrova","depth":23,"bounds":{"left":0.12986112,"top":0.9822222,"width":0.07361111,"height":0.012222222},"role_description":"text"},{"role":"AXStaticText","text":"Vasil Vasilev","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Nikolay Nikolov","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Galya Dimitrova","depth":23,"role_description":"text"},{"role":"AXStaticText","text":",","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Nikolay Nikolov","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Galya Dimitrova","depth":23,"role_description":"text"},{"role":"AXStaticText","text":",","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Nikolay Yankov","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Nikolay Yankov","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Jira Cloud","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Toast","depth":23,"role_description":"text"},{"role":"AXStaticText","text":"Google Calendar","depth":23,"role_description":"text"},{"role":"AXRadioButton","text":"Messages","depth":17,"bounds":{"left":0.25486112,"top":0.12777779,"width":0.06458333,"height":0.04222222},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":true,"is_expanded":false},{"role":"AXStaticText","text":"Messages","depth":19,"bounds":{"left":0.27430555,"top":0.14,"width":0.039583333,"height":0.017777778},"role_description":"text"},{"role":"AXRadioButton","text":"Channel Overview","depth":17,"bounds":{"left":0.32152778,"top":0.12777779,"width":0.1,"height":0.04222222},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Channel Overview","depth":19,"bounds":{"left":0.34097221,"top":0.14,"width":0.075,"height":0.017777778},"role_description":"text"},{"role":"AXRadioButton","text":"Refinements","depth":17,"bounds":{"left":0.4236111,"top":0.12777779,"width":0.07847222,"height":0.04222222},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Refinements","depth":19,"bounds":{"left":0.44305557,"top":0.14,"width":0.050694443,"height":0.017777778},"role_description":"text"},{"role":"AXRadioButton","text":"Files","depth":17,"bounds":{"left":0.5048611,"top":0.12777779,"width":0.04375,"height":0.04222222},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Files","depth":19,"bounds":{"left":0.5243056,"top":0.14,"width":0.01875,"height":0.017777778},"role_description":"text"},{"role":"AXRadioButton","text":"Pins","depth":17,"bounds":{"left":0.55069447,"top":0.12777779,"width":0.04236111,"height":0.04222222},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Pins","depth":19,"bounds":{"left":0.5701389,"top":0.14,"width":0.017361112,"height":0.017777778},"role_description":"text"},{"role":"AXRadioButton","text":"Bookmarks","depth":17,"bounds":{"left":0.59583336,"top":0.12777779,"width":0.07083333,"height":0.04222222},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Bookmarks","depth":19,"bounds":{"left":0.61527777,"top":0.14,"width":0.045833334,"height":0.017777778},"role_description":"text"},{"role":"AXRadioButton","text":"Retro Action Items","depth":17,"bounds":{"left":0.66875,"top":0.12777779,"width":0.103472225,"height":0.04222222},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Retro Action Items","depth":19,"bounds":{"left":0.6888889,"top":0.14,"width":0.075,"height":0.017777778},"role_description":"text"},{"role":"AXRadioButton","text":"Deleted file","depth":17,"bounds":{"left":0.7743056,"top":0.12777779,"width":0.075,"height":0.04222222},"role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Deleted file","depth":19,"bounds":{"left":0.79375,"top":0.14,"width":0.047222223,"height":0.017777778},"role_description":"text"},{"role":"AXPopUpButton","text":"Add and Edit Channel Tabs","depth":17,"bounds":{"left":0.8513889,"top":0.12777779,"width":0.022916667,"height":0.04222222},"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Canvas","depth":17,"role_description":"text"},{"role":"AXStaticText","text":"List","depth":17,"role_description":"text"},{"role":"AXStaticText","text":"Folder","depth":17,"role_description":"text"},{"role":"AXPopUpButton","text":"Jump to date","depth":22,"bounds":{"left":0.56805557,"top":0.17666666,"width":0.10486111,"height":0.031111112},"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Nikolay Nikolov","depth":23,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.075,"height":0.0011111111},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"bounds":{"left":0.37708333,"top":0.16111112,"width":0.0055555557,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 10:43:44 AM","depth":23,"bounds":{"left":0.38194445,"top":0.16111112,"width":0.0375,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"10:43 AM","depth":24,"bounds":{"left":0.38194445,"top":0.16111112,"width":0.0375,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Още един фикс за outh:","depth":24,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.11736111,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"https://github.com/jiminny/app/pull/11926","depth":24,"bounds":{"left":0.40486112,"top":0.16111112,"width":0.19791667,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"https://github.com/jiminny/app/pull/11926","depth":25,"bounds":{"left":0.40486112,"top":0.16111112,"width":0.19791667,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"#11926 SRD-6771 | JY-20622 | Fix OAuth","depth":25,"bounds":{"left":0.29930556,"top":0.16111112,"width":0.19513889,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"#11926 SRD-6771 | JY-20622 | Fix OAuth","depth":26,"bounds":{"left":0.29930556,"top":0.16111112,"width":0.19513889,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"JIRA:","depth":25,"bounds":{"left":0.29930556,"top":0.16111112,"width":0.027083334,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"SRD-6771","depth":25,"bounds":{"left":0.32569444,"top":0.16111112,"width":0.049305554,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"SRD-6771","depth":26,"bounds":{"left":0.32569444,"top":0.16111112,"width":0.049305554,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"|","depth":25,"bounds":{"left":0.37430555,"top":0.16111112,"width":0.007638889,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"JY-20622","depth":25,"bounds":{"left":0.38194445,"top":0.16111112,"width":0.045138888,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"JY-20622","depth":26,"bounds":{"left":0.38194445,"top":0.16111112,"width":0.045138888,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Deployment notes:","depth":25,"bounds":{"left":0.29930556,"top":0.16111112,"width":0.088194445,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"• None","depth":25,"bounds":{"left":0.29930556,"top":0.16111112,"width":0.034027778,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Comments","depth":26,"bounds":{"left":0.29930556,"top":0.16111112,"width":0.050694443,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"3","depth":26,"bounds":{"left":0.29930556,"top":0.16111112,"width":0.00625,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"jiminny/app","depth":25,"bounds":{"left":0.31319445,"top":0.16111112,"width":0.043055557,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"jiminny/app","depth":26,"bounds":{"left":0.31319445,"top":0.16111112,"width":0.043055557,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"|","depth":25,"bounds":{"left":0.35625,"top":0.16111112,"width":0.00625,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Apr 9th","depth":25,"bounds":{"left":0.3625,"top":0.16111112,"width":0.027777778,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"|","depth":25,"bounds":{"left":0.39027777,"top":0.16111112,"width":0.00625,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Added by","depth":25,"bounds":{"left":0.39583334,"top":0.16111112,"width":0.0375,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"GitHub","depth":25,"bounds":{"left":0.43263888,"top":0.16111112,"width":0.027083334,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"GitHub","depth":26,"bounds":{"left":0.43263888,"top":0.16111112,"width":0.027083334,"height":0.0011111111},"role_description":"text"},{"role":"AXButton","text":"Nikolay Yankov","depth":23,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.072222225,"height":0.0011111111},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"bounds":{"left":0.35972223,"top":0.16111112,"width":0.00625,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 11:00:43 AM","depth":23,"bounds":{"left":0.36527777,"top":0.16111112,"width":0.036805555,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"11:00 AM","depth":24,"bounds":{"left":0.36527777,"top":0.16111112,"width":0.036805555,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Марио ще пусне един тикет за user-и от","depth":24,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.19722222,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Immutable","depth":25,"bounds":{"left":0.4875,"top":0.16111112,"width":0.045138888,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"които не могат да се логнат с SSO в Sidekick.","depth":24,"bounds":{"left":0.53541666,"top":0.16111112,"width":0.21805556,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Изглежда ми приоритетно","depth":24,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.12916666,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"vid.nedumaran@immutable.com","depth":24,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.14652778,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"vid.nedumaran@immutable.com","depth":25,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.14652778,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"същото е и за","depth":24,"bounds":{"left":0.43472221,"top":0.16111112,"width":0.07152778,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"alex.li@immutable.com","depth":24,"bounds":{"left":0.50555557,"top":0.16111112,"width":0.10486111,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"alex.li@immutable.com","depth":25,"bounds":{"left":0.50555557,"top":0.16111112,"width":0.10486111,"height":0.0011111111},"role_description":"text"},{"role":"AXCheckBox","text":"1 reaction, react with +1 emoji","depth":24,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.029861111,"height":0.0011111111},"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"1","depth":25,"bounds":{"left":0.30763888,"top":0.16111112,"width":0.0048611113,"height":0.0011111111},"role_description":"text"},{"role":"AXButton","text":"Add reaction…","depth":24,"bounds":{"left":0.32083333,"top":0.16111112,"width":0.023611112,"height":0.0011111111},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXLink","text":"Apr 9th at 11:04:25 AM","depth":24,"bounds":{"left":0.2611111,"top":0.16111112,"width":0.021527778,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"11:04","depth":25,"bounds":{"left":0.2611111,"top":0.16111112,"width":0.021527778,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Някой може ли да го погледне","depth":24,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.14861111,"height":0.0011111111},"role_description":"text"},{"role":"AXButton","text":"Steliyan Georgiev","depth":23,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.08263889,"height":0.0011111111},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"bounds":{"left":0.37083334,"top":0.16111112,"width":0.0055555557,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 11:43:52 AM","depth":23,"bounds":{"left":0.37569445,"top":0.16111112,"width":0.0375,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"11:43 AM","depth":24,"bounds":{"left":0.37569445,"top":0.16111112,"width":0.0375,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Може ли approve на","depth":24,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.1,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"https://github.com/jiminny/prophet/pull/465","depth":24,"bounds":{"left":0.3875,"top":0.16111112,"width":0.20555556,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"https://github.com/jiminny/prophet/pull/465","depth":25,"bounds":{"left":0.3875,"top":0.16111112,"width":0.20555556,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"? Знам от какво се оплаква claude - нямаме проблем с това за сега.","depth":24,"bounds":{"left":0.5923611,"top":0.16111112,"width":0.325,"height":0.0011111111},"role_description":"text"},{"role":"AXButton","text":"Nikolay Nikolov","depth":23,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.075,"height":0.0011111111},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"bounds":{"left":0.37708333,"top":0.16111112,"width":0.0055555557,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 12:36:57 PM","depth":23,"bounds":{"left":0.38194445,"top":0.16111112,"width":0.036805555,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"12:36 PM","depth":24,"bounds":{"left":0.38194445,"top":0.16111112,"width":0.036805555,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Някой дали знае тая конфигурация можем ли да я сменим ние ?","depth":24,"bounds":{"left":0.28819445,"top":0.16111112,"width":0.31319445,"height":0.0011111111},"role_description":"text"},{"role":"AXLink","text":"https://jiminny.atlassian.net/browse/SRD-6779?focusedCommentId=72677","depth":24,"bounds":{"left":0.6006944,"top":0.16111112,"width":0.34583333,"height":0.0011111111},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"https://jiminny.atlassian.net/browse/SRD-6779?focusedCommentId=72677","depth":25,"bounds":{"left":0.6006944,"top":0.16111112,"width":0.34583333,"height":0.0011111111},"role_description":"text"},{"role":"AXStaticText","text":"Comment by Nikolay Nikolov on a Bug in","depth":26,"bounds":{"left":0.29930556,"top":0.16111112,"width":0.19097222,"height":0.017777778},"role_description":"text"},{"role":"AXStaticText","text":"Analyzing","depth":27,"bounds":{"left":0.49305555,"top":0.16222222,"width":0.045138888,"height":0.016666668},"role_description":"text"},{"role":"AXStaticText","text":"The Immutable SSO tenant is configured with","depth":26,"bounds":{"left":0.29930556,"top":0.19666667,"width":0.2125,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"name_id_format = persistent","depth":27,"bounds":{"left":0.51458335,"top":0.2,"width":0.13541667,"height":0.016666668},"role_description":"text"},{"role":"AXStaticText","text":"","depth":26,"bounds":{"left":0.65208334,"top":0.19666667,"width":0.0027777778,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":", but the code expects the SAML response to contain the user's email address.","depth":26,"bounds":{"left":0.29930556,"top":0.19666667,"width":0.39444444,"height":0.044444446},"role_description":"text"},{"role":"AXStaticText","text":"When Okta sends a","depth":26,"bounds":{"left":0.29930556,"top":0.24555555,"width":0.09236111,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"persistent","depth":27,"bounds":{"left":0.39444444,"top":0.2488889,"width":0.05,"height":0.016666668},"role_description":"text"},{"role":"AXStaticText","text":"NameID, it sends a unique identifier (not the email), so","depth":26,"bounds":{"left":0.44722223,"top":0.24555555,"width":0.24930556,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"$samlUser->getUserId()","depth":27,"bounds":{"left":0.30208334,"top":0.27333334,"width":0.110416666,"height":0.016666668},"role_description":"text"},{"role":"AXStaticText","text":"returns something like a UUID instead","depth":26,"bounds":{"left":0.41458333,"top":0.27,"width":0.17708333,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"…","depth":26,"bounds":{"left":0.59097224,"top":0.27,"width":0.008333334,"height":0.02},"role_description":"text"},{"role":"AXButton","text":"See more","depth":25,"bounds":{"left":0.29930556,"top":0.29222223,"width":0.043055557,"height":0.024444444},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Comment","depth":25,"bounds":{"left":0.29930556,"top":0.33,"width":0.052083332,"height":0.031111112},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Comment","depth":27,"bounds":{"left":0.30555555,"top":0.33666667,"width":0.039583333,"height":0.017777778},"role_description":"text"},{"role":"AXComboBox","text":"More actions...","depth":26,"bounds":{"left":0.35694444,"top":0.33,"width":0.13194445,"height":0.031111112},"placeholder":"More actions...","role_description":"combo box","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Added by","depth":25,"bounds":{"left":0.29930556,"top":0.37444445,"width":0.036805555,"height":0.016666668},"role_description":"text"},{"role":"AXLink","text":"Jira Cloud","depth":25,"bounds":{"left":0.3361111,"top":0.37444445,"width":0.036111113,"height":0.016666668},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Jira Cloud","depth":26,"bounds":{"left":0.3361111,"top":0.37444445,"width":0.036111113,"height":0.016666668},"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 12:37:38 PM","depth":24,"bounds":{"left":0.2611111,"top":0.41,"width":0.021527778,"height":0.016666668},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"12:37","depth":25,"bounds":{"left":0.2611111,"top":0.41,"width":0.021527778,"height":0.016666668},"role_description":"text"},{"role":"AXStaticText","text":"Ако е 'emailAddress' би трябвало да сработи - но да не счупя нещо друго","depth":24,"bounds":{"left":0.28819445,"top":0.40666667,"width":0.35,"height":0.02},"role_description":"text"},{"role":"AXCheckBox","text":"React with white_check_mark","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with eyes","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with raised_hands","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Add reaction…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Reply in thread","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Forward message…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"Save for later","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"More actions","depth":25,"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Nikolay Ivanov","depth":23,"bounds":{"left":0.28819445,"top":0.4377778,"width":0.07013889,"height":0.024444444},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"bounds":{"left":0.3576389,"top":0.44,"width":0.0055555557,"height":0.02},"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 12:44:22 PM","depth":23,"bounds":{"left":0.36319444,"top":0.44333333,"width":0.036805555,"height":0.016666668},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"12:44 PM","depth":24,"bounds":{"left":0.36319444,"top":0.44333333,"width":0.036805555,"height":0.016666668},"role_description":"text"},{"role":"AXStaticText","text":"Вес може да има идея","depth":24,"bounds":{"left":0.28819445,"top":0.46444446,"width":0.10763889,"height":0.02},"role_description":"text"},{"role":"AXCheckBox","text":"React with white_check_mark","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with eyes","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with raised_hands","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Add reaction…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Reply in thread","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Forward message…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"Save for later","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"More actions","depth":25,"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Nikolay Nikolov","depth":23,"bounds":{"left":0.28819445,"top":0.49555555,"width":0.075,"height":0.024444444},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"bounds":{"left":0.37708333,"top":0.4977778,"width":0.0055555557,"height":0.02},"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 12:45:49 PM","depth":23,"bounds":{"left":0.38194445,"top":0.5011111,"width":0.036805555,"height":0.016666668},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"12:45 PM","depth":24,"bounds":{"left":0.38194445,"top":0.5011111,"width":0.036805555,"height":0.016666668},"role_description":"text"},{"role":"AXStaticText","text":"Той е отпуск - по принцип това може и да не сработи, но няма да стане по лошо - само казваме какво искаме да ни върне Okta","depth":24,"bounds":{"left":0.28819445,"top":0.5222222,"width":0.61319447,"height":0.02},"role_description":"text"},{"role":"AXCheckBox","text":"React with white_check_mark","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with eyes","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with raised_hands","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Add reaction…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Reply in thread","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Forward message…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"Save for later","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"More actions","depth":25,"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXLink","text":"Apr 9th at 12:45:53 PM","depth":24,"bounds":{"left":0.2611111,"top":0.5588889,"width":0.021527778,"height":0.016666668},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"12:45","depth":25,"bounds":{"left":0.2611111,"top":0.5588889,"width":0.021527778,"height":0.016666668},"role_description":"text"},{"role":"AXStaticText","text":"ше го пробвам","depth":24,"bounds":{"left":0.28819445,"top":0.5555556,"width":0.07083333,"height":0.02},"role_description":"text"},{"role":"AXCheckBox","text":"1 reaction, react with +1 emoji","depth":24,"bounds":{"left":0.28819445,"top":0.5822222,"width":0.029861111,"height":0.026666667},"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"1","depth":25,"bounds":{"left":0.30763888,"top":0.5877778,"width":0.0048611113,"height":0.015555556},"role_description":"text"},{"role":"AXButton","text":"Add reaction…","depth":24,"bounds":{"left":0.32083333,"top":0.5822222,"width":0.023611112,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with white_check_mark","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with eyes","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with raised_hands","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Add reaction…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Reply in thread","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Forward message…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"Save for later","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"More actions","depth":25,"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Nikolay Nikolov","depth":23,"bounds":{"left":0.28819445,"top":0.62222224,"width":0.075,"height":0.024444444},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"bounds":{"left":0.37708333,"top":0.6244444,"width":0.0055555557,"height":0.02},"role_description":"text"},{"role":"AXLink","text":"Apr 9th at 1:04:12 PM","depth":23,"bounds":{"left":0.38194445,"top":0.62777776,"width":0.031944446,"height":0.016666668},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"1:04 PM","depth":24,"bounds":{"left":0.38194445,"top":0.62777776,"width":0.031944446,"height":0.016666668},"role_description":"text"},{"role":"AXStaticText","text":"Няма да е от това май","depth":24,"bounds":{"left":0.28819445,"top":0.6488889,"width":0.10694444,"height":0.02},"role_description":"text"},{"role":"AXCheckBox","text":"React with white_check_mark","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with eyes","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with raised_hands","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Add reaction…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Reply in thread","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Forward message…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"Save for later","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"More actions","depth":25,"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"Jump to date","depth":22,"bounds":{"left":0.59375,"top":0.6911111,"width":0.05277778,"height":0.031111112},"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"New","depth":22,"bounds":{"left":0.96458334,"top":0.69777775,"width":0.01875,"height":0.017777778},"role_description":"text"},{"role":"AXButton","text":"Nikolay Yankov","depth":23,"bounds":{"left":0.28819445,"top":0.73444444,"width":0.072222225,"height":0.024444444},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"","depth":23,"bounds":{"left":0.35972223,"top":0.7366667,"width":0.00625,"height":0.02},"role_description":"text"},{"role":"AXLink","text":"Today at 11:35:04 AM","depth":23,"bounds":{"left":0.36527777,"top":0.74,"width":0.036805555,"height":0.016666668},"role_description":"link","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"11:35 AM","depth":24,"bounds":{"left":0.36527777,"top":0.74,"width":0.036805555,"height":0.016666668},"role_description":"text"},{"role":"AXStaticText","text":"Преди малко създадох конфигурация за новите репорти и в резултат не идва никакъв генериран репорт.","depth":24,"bounds":{"left":0.28819445,"top":0.76111114,"width":0.5076389,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"След проверка в базата разбираме, че съм избрал Saved Search, който няма нито едно активити.","depth":24,"bounds":{"left":0.28819445,"top":0.78555554,"width":0.46597221,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"Това обаче по никакъв начин не се подсказва на user-a и си мисля, че ще идват support тикети за такива неща...","depth":24,"bounds":{"left":0.28819445,"top":0.81,"width":0.5375,"height":0.02},"role_description":"text"},{"role":"AXStaticText","text":"Какво мислите?","depth":24,"bounds":{"left":0.28819445,"top":0.83444446,"width":0.077083334,"height":0.02},"role_description":"text"},{"role":"AXCheckBox","text":"React with white_check_mark","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with eyes","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"React with raised_hands","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Add reaction…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Reply in thread","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Forward message…","depth":25,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXCheckBox","text":"Save for later","depth":25,"role_description":"toggle button","subrole":"AXToggleButton","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXPopUpButton","text":"More actions","depth":25,"role_description":"pop-up button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"","depth":23,"bounds":{"left":0.25833333,"top":0.88,"width":0.7236111,"height":0.04222222},"value":"","role_description":"text entry area","is_enabled":true,"is_focused":true,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"loading…","depth":11,"role_description":"text"},{"role":"AXStaticText","text":"Channel platform-inner-team","depth":11,"role_description":"text"}]...
|
7944518703698522703
|
-3600322415692461476
|
idle
|
hybrid
|
NULL
|
Jiminny Inc
Jiminny (Staging)
Add workspaces
Home
Jiminny Inc
Jiminny (Staging)
Add workspaces
Home
Home
DMs
DMs
Activity
Activity
Files
Files
Later
Later
More…
More
Unreads
Threads
Huddles
Drafts & sent
Directories
platform-inner-team
ai-chapter
alerts
backend
confusion-clinic
curiosity_lab
engineering
frontend
general
infra-changes
jiminny-bg
platform-tickets
product_launches
random
releases
sofia-office
support
thank-yous
the_people_of_jiminny
Aneliya Angelova
,
Nikolay Yankov
,
Steliyan Georgiev
Steliyan Georgiev
Adelina Petrova
,
Ilian Kyuchukov
,
Steliyan Georgiev
Adelina Petrova
Galya Dimitrova
Vasil Vasilev
Nikolay Nikolov
Galya Dimitrova
,
Nikolay Nikolov
Galya Dimitrova
,
Nikolay Yankov
Nikolay Yankov
Jira Cloud
Toast
Google Calendar
Messages
Messages
Channel Overview
Channel Overview
Refinements
Refinements
Files
Files
Pins
Pins
Bookmarks
Bookmarks
Retro Action Items
Retro Action Items
Deleted file
Deleted file
Add and Edit Channel Tabs
Canvas
List
Folder
Jump to date
Nikolay Nikolov
Apr 9th at 10:43:44 AM
10:43 AM
Още един фикс за outh:
https://github.com/jiminny/app/pull/11926
https://github.com/jiminny/app/pull/11926
#11926 SRD-6771 | JY-20622 | Fix OAuth
#11926 SRD-6771 | JY-20622 | Fix OAuth
JIRA:
SRD-6771
SRD-6771
|
JY-20622
JY-20622
Deployment notes:
• None
Comments
3
jiminny/app
jiminny/app
|
Apr 9th
|
Added by
GitHub
GitHub
Nikolay Yankov
Apr 9th at 11:00:43 AM
11:00 AM
Марио ще пусне един тикет за user-и от
Immutable
които не могат да се логнат с SSO в Sidekick.
Изглежда ми приоритетно
[EMAIL]
[EMAIL]
същото е и за
[EMAIL]
[EMAIL]
1 reaction, react with +1 emoji
1
Add reaction…
Apr 9th at 11:04:25 AM
11:04
Някой може ли да го погледне
Steliyan Georgiev
Apr 9th at 11:43:52 AM
11:43 AM
Може ли approve на
https://github.com/jiminny/prophet/pull/465
https://github.com/jiminny/prophet/pull/465
? Знам от какво се оплаква claude - нямаме проблем с това за сега.
Nikolay Nikolov
Apr 9th at 12:36:57 PM
12:36 PM
Някой дали знае тая конфигурация можем ли да я сменим ние ?
https://jiminny.atlassian.net/browse/SRD-6779?focusedCommentId=72677
https://jiminny.atlassian.net/browse/SRD-6779?focusedCommentId=72677
Comment by Nikolay Nikolov on a Bug in
Analyzing
The Immutable SSO tenant is configured with
name_id_format = persistent
, but the code expects the SAML response to contain the user's email address.
When Okta sends a
persistent
NameID, it sends a unique identifier (not the email), so
$samlUser->getUserId()
returns something like a UUID instead
…
See more
Comment
Comment
More actions...
Added by
Jira Cloud
Jira Cloud
Apr 9th at 12:37:38 PM
12:37
Ако е 'emailAddress' би трябвало да сработи - но да не счупя нещо друго
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Nikolay Ivanov
Apr 9th at 12:44:22 PM
12:44 PM
Вес може да има идея
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Nikolay Nikolov
Apr 9th at 12:45:49 PM
12:45 PM
Той е отпуск - по принцип това може и да не сработи, но няма да стане по лошо - само казваме какво искаме да ни върне Okta
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Apr 9th at 12:45:53 PM
12:45
ше го пробвам
1 reaction, react with +1 emoji
1
Add reaction…
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Nikolay Nikolov
Apr 9th at 1:04:12 PM
1:04 PM
Няма да е от това май
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
Jump to date
New
Nikolay Yankov
Today at 11:35:04 AM
11:35 AM
Преди малко създадох конфигурация за новите репорти и в резултат не идва никакъв генериран репорт.
След проверка в базата разбираме, че съм избрал Saved Search, който няма нито едно активити.
Това обаче по никакъв начин не се подсказва на user-a и си мисля, че ще идват support тикети за такива неща...
Какво мислите?
React with white_check_mark
React with eyes
React with raised_hands
Add reaction…
Reply in thread
Forward message…
Save for later
More actions
loading…
Channel platform-inner-team
+SlackFileEditViewGoHistoryWindowHelpEDHomeDMsActivityFilesLater..•More*Tue 14 Apr 11:38:00+Jiminny ...# Starred8platform-inner-teamChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product_launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi...• Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili...(. Adelina PetrovaO. Cala Dimitravo>0 lhl§ Support Daily • in 3h 22 m100% <Search Jiminny Inc& platform-inner-team8 10MessagesP Channel OverviewP Refinements@ Filescommentuy minolay mindlov uita bugte anatyzinig< Pins• BookmarksP7 Retro Action Itemsw Deleted file+Thursday, April 9th~The Immutable SSO tenant is configured with name_id_formatpersestent, wut thecode expects the SAML response to contain the user's email address.When Okta sends a persistent NamelD, it sends a unique identifier (not the email), soSsamlUser->getUserId( returns something like a UUID instead...See moreCommentMore actions...Added by Jira CloudAко e 'emailAddress' би трябвало да сработи - но да не счупя нещо другоNikolay Ivanov 12:44 PMВес може да има идеяNikolay Nikolov™ 12:45 PMТой е отпуск - по принцип това може и да не сработи, но няма да стане по лошо - само казваме какво искаме да ни върне Oktaше го пробвамNikolay Nikolov ** 1:04 PMНяма да е от това майToday~Nikolay Yankov 11:35 AMПреди малко създадох конфигурация за новите репорти и в резултат не идва никакьв генериран репорт.След проверка в базата разбираме, че съм избрал Saved Search, който няма нито едно активити.Това обаче по никакьв начин не се подсказва на user-a и си мисля, че ще идват support тикети за такива неща...Какво мислите?Message & platform-inner-team+AaNew...
|
NULL
|
|
10431
|
NULL
|
0
|
2026-04-14T08:42:32.996997+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776156152996_m1.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
+SlackEDHomeDMSActivityFilesLater..•More+FileEditV +SlackEDHomeDMSActivityFilesLater..•More+FileEditViewGoHistoryWindowHelpall• Support Daily • in 3 h 18 m100% <47Tue 14 Apr 11:42:32Jiminny ...# Starred8platform-inner-teamChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product_launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi…..Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili.... Adelina PetrovaO. Calea Dimitravo→Search Jiminny IncAneliya Angelova, Nikolay Yankov, Steliyan Georgiev84MessagesAdd canvas+SANCOTAUVURE 20.00 AIтова ще гледа всичко applicable за днес (ако не понедлник или Today ~лесец е само daily)крон го пуска през нощтака че мануално пусни при тестванеако трябва да тестваме други репорти може да променя команда за тестване да приема параметьр за report template и д си пускамеопределен когато тествамеNikolay Yankov 10:41 AMможеш ли да я рьннеш ти командатаLukas Kovalik 10:43 AMдаNikolay Yankov 10:45 AMпиши кат оя рьннешLukas Kovalik 10:52 AMзабавих се че ми се разбазикаха settings за средипуснах и мина и fail-наима result нo e failedзначиREASON_NOT_ENOUGH_ACTIVITIESвиж дали има нещо в OD със този филтьрNikolay Yankov 11:01 AMДобреNikolay Yankov 11:39 AMя рьнни пак LukasNewMessage Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev+Aa...
|
NULL
|
-7475086796828771245
|
NULL
|
click
|
ocr
|
NULL
|
+SlackEDHomeDMSActivityFilesLater..•More+FileEditV +SlackEDHomeDMSActivityFilesLater..•More+FileEditViewGoHistoryWindowHelpall• Support Daily • in 3 h 18 m100% <47Tue 14 Apr 11:42:32Jiminny ...# Starred8platform-inner-teamChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product_launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi…..Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili.... Adelina PetrovaO. Calea Dimitravo→Search Jiminny IncAneliya Angelova, Nikolay Yankov, Steliyan Georgiev84MessagesAdd canvas+SANCOTAUVURE 20.00 AIтова ще гледа всичко applicable за днес (ако не понедлник или Today ~лесец е само daily)крон го пуска през нощтака че мануално пусни при тестванеако трябва да тестваме други репорти може да променя команда за тестване да приема параметьр за report template и д си пускамеопределен когато тествамеNikolay Yankov 10:41 AMможеш ли да я рьннеш ти командатаLukas Kovalik 10:43 AMдаNikolay Yankov 10:45 AMпиши кат оя рьннешLukas Kovalik 10:52 AMзабавих се че ми се разбазикаха settings за средипуснах и мина и fail-наима result нo e failedзначиREASON_NOT_ENOUGH_ACTIVITIESвиж дали има нещо в OD със този филтьрNikolay Yankov 11:01 AMДобреNikolay Yankov 11:39 AMя рьнни пак LukasNewMessage Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev+Aa...
|
NULL
|
|
10432
|
NULL
|
0
|
2026-04-14T08:42:32.997006+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776156152997_m2.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
PhpStormFileEditViewNavigateCodeLaravelRefactorToo PhpStormFileEditViewNavigateCodeLaravelRefactorToolsWindowHelpFV faVsco.s v( #11894 on JY-18909-automated-reports-ask-jiminny k ~Project v© ReportController.php© JiminnyDebugCommand.php= custom.log= laravel.logA SF ljiminny@localhost]4 HS_local [jiminny@localhost]O dev.jsonAulomaleakeporissendcommand.onoC AutomatedReportsCommand.php= ids.txtAutomatedReportsRepository.php x© AutomatedReportsService.phpIx. AUto VFlaycroundv= infection.json.distу ІгаскrrovlderinstalleacventoneM+INS ALL.moIity_type,pc.1d, pc.nameM+INIERNAL WEB"OOKS-UP.mo© CreateActivityLoqgedEvent.phpC UserPilotActivityListener.php© ActivityLogged.phpEjiminny_storageM+ licenses.mdM MakefileOpackage-lock.json(e AutomatedRenortscalllbackService.onv© RequestGenerateAskJiminnyReportJob.phpRequestGenerateReportJob.php© AutomatedReportResult.php(C) AutomatedReport.php= phpstan.neon.distclass Auronarecreoortskerostorv= phpstan-baseline.neon< phpunit.xmlTeraw_sql_query.sqlAl console [PROD]console EUconsole slAGiNG XAskJiminnykeporiActivilyservice.ono© RequestGenerateAskJiminnyReportJobTest.phpD 65445455465471548549550A13 X4 A V551oparall ser ane osor cco conlnThe column to sort by.Allowed values: 'C552Oparam string $sortDirection The sort direction.Allowed values:'asc'553Mal iminnyv016 A13 X 13 ^ries pc"o>l.n: on p.1d = pc.playbook_10and p.accivity_type = "event:elds WHERE crm confiquration id = 1 and obiect tvpe = 'event':eld values WHERE crm_field id = 4youts cl join playbook_layouts pl 1<->1.n: on cl.id = pl.layout_idion_id = 1 and pl.playbook_id = 175;MeR-ADME.mosonar-project.propertiesOreturn Collection<AutomatedReport>= test.py4> Untited Diagram.Xmi555556557us vetur.confia.ismated_reports ramuid = t.id"daluir"M+ WEBHOOK_FILTERING_IMPLEMEI› Ih External LibrariesE® Scratches and Consolessagesilic function getAllStandardReports(string $sortColumn ='created_at',sarino osorturecmion = 'oesc'LoLecron "...hv D Database ConsolesAEU> A jiminny@localhostdPRODA QAL QAI4 QAI PROD5591S00561562563-564565 vOparam User$userThe user whose reports to retrieve.566Oparam string $sortColumnThe column to sort by. Allowed values: YC567Oparam string $sortDirection The sort direction. Allowed values:'astnow() OR r.expicesaat IS NULL);ted_ report_results where repontaid IN (18, 33);Retrieve all Ask Jiminny reports created by the given user.ted_reppr+];ted_report_results where repontaid IN (33, 34, 35);V L STAGING& console slAGiNgdrecurh coclection<Aucomacedkeport.A console_1 [STAGING]A uranus [STAGING]Services+oe|×~ D DatabaseV dEUA consolev djiminny@localhostans ocall4 SFV A PRODconsoleV A STAGINGs console 15 4541115& DockerOutput35 rowsyDid Ylini jiminny.automated reports XIx. Auleywuid (UUID with time-low and time-high swapped) TIn team id Y• 047 201-1800-40/-2501-8/11 8005ot%7 fa76bd0d-61bd-4fac-86c4-9cbf6f71ad2611 8a63a8f1-b5c2-4d70-b04b-3c24c69e496b12 acce2c65-665b-48f6-b48c-d13b6bf686cd13 1eec5e26-1a75-4h08-ad2a-88c47c0e567114 6043422f-184a-4c7e-8be6-e1ac72dc0f3515 8b79d9d8-fa16-4400-bbb8-1e2b0c74345216 f9334df3-6d16-47b4-b632-a2e95c628383stouonoc-oerc-uost-d.15a-110401760/01618 18c857ec-f1e5-432d-a873-28913f9e6d4d19 439ada99-7374-41b9-95f2-32c4fa691d8842400000-1100-4102-0/00-4000020700/021 f278e4f1-0f02-40e7-9461-6d18992c724122 d88089d5-3c70-48c1-98a4-c8b60dab685223 f264d0ba-3129-443a-9d82-7716cffb667f24 5a98c597-756b-4809-b096-91bcbce273fa33 fa7417aa-538e-49ab-8827-77235637a6f9type Y1 ask_jiminny1 ask_jiminny1 ask_jiminny1 ask iiminny1 ask_jiminny1 ask_jiminny1 ask_jiminny1 ask iiminny1 ask_jiminny1 ask_jiminny1 ask_jiminnyask aunannv1 ask_jiminny1 ask_jiminny1 ask_jiminny1 ask iiminny1 ask_jiminnyI status YI frequency Y1 dailyO daily1 dailyo daily1 daily1 daily1 weekly1 weekly1 monthly1 dailyO monthly1 daily1 weekly1 monthlyO dailyo monthly1 dailyWindsurf changelog 2.12.21: A new version is available. // View Changelog (today 10:33)I from T<null><null><null><null><null>snuud<null><null>SnULL><null><null><null>shuld<null>mto T<nullssnull><null><null>cnuue<null><null>SIULL<null>snull><null><null><null><null><null>SnULl<null>{ Support Daily • in 3h 18mA• RequestGenerateAskJiminnyReportJobTest v100% [Tue 14 Apr 11:42:32CascadeFixing ReportControlleAutomated Report FaiIN @AutomatedReportsCommand.php add additional parameter report id and if provider then instead ofrevorts by wecuency ll lakes we ledort vy la or uule.Add checks for status, team activity andoiel stull useu lor curymg. uns Iwi ve usee only mllanudlly sou mele shote ve mio l not duptlcadle baseu onlstandara searenwLet me read the command and related files first.reao Aulomalecreoorscommanc,ono ano auloalecreoorsredosilorv.ono ›Now let me check the AutonatedReoort model tor relevanttielas:expioreu nulomdleunevortono anla sedichleu geloloatus getTeam expires_at getFrequency getType STATUSis... ›Now.nave every.ninelneeo. Let me imolement tne changes.• AutomatedReportsCommand.php+/8-2Also need to check if findByUuid handles soft-deleted — it doesn't, so for UUID lookup we need withTrashed too.Let me tix thatAutomatedReportsCommand.phpDone. Here's what was added:+1 -1Changes SummaryNew option: —report-id= — accepts either a numeric ID or a UUID.processsing lekeportl, — oypasses treouency logie entirely.• Looks up by ID (AutomatedReport: :withTrashed()->find() ) or UUID (also withTrashed so even deletedreports can be triggered manually)• Calls warnIfNotApplicableForSchedule() for informational output• Dispatches the job the same way as the scheduled pathwarnIfNotApplicableForSchedule() - mirrors every condition from getActiveReportsByFrequency() and theke ect allAccept allAdd findByldOrUuidt "codeClaude Sonnet 4.6CSVvdeal_value_min Y• deal_value_max YI call_types Y<null><null><null> [<null> (]<null> []<null> []<null> [<null><null><null>SIULL<null><null>SNUL><null><null>ShULD<null><null> []<null> []<null> []<null> (]<null> []<null> []<null> []<null> []<null> []<null> []<null> []media_t)["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]W Windsurf Teams565:28UTF-84 spaces...
|
NULL
|
-7294054630421575566
|
NULL
|
click
|
ocr
|
NULL
|
PhpStormFileEditViewNavigateCodeLaravelRefactorToo PhpStormFileEditViewNavigateCodeLaravelRefactorToolsWindowHelpFV faVsco.s v( #11894 on JY-18909-automated-reports-ask-jiminny k ~Project v© ReportController.php© JiminnyDebugCommand.php= custom.log= laravel.logA SF ljiminny@localhost]4 HS_local [jiminny@localhost]O dev.jsonAulomaleakeporissendcommand.onoC AutomatedReportsCommand.php= ids.txtAutomatedReportsRepository.php x© AutomatedReportsService.phpIx. AUto VFlaycroundv= infection.json.distу ІгаскrrovlderinstalleacventoneM+INS ALL.moIity_type,pc.1d, pc.nameM+INIERNAL WEB"OOKS-UP.mo© CreateActivityLoqgedEvent.phpC UserPilotActivityListener.php© ActivityLogged.phpEjiminny_storageM+ licenses.mdM MakefileOpackage-lock.json(e AutomatedRenortscalllbackService.onv© RequestGenerateAskJiminnyReportJob.phpRequestGenerateReportJob.php© AutomatedReportResult.php(C) AutomatedReport.php= phpstan.neon.distclass Auronarecreoortskerostorv= phpstan-baseline.neon< phpunit.xmlTeraw_sql_query.sqlAl console [PROD]console EUconsole slAGiNG XAskJiminnykeporiActivilyservice.ono© RequestGenerateAskJiminnyReportJobTest.phpD 65445455465471548549550A13 X4 A V551oparall ser ane osor cco conlnThe column to sort by.Allowed values: 'C552Oparam string $sortDirection The sort direction.Allowed values:'asc'553Mal iminnyv016 A13 X 13 ^ries pc"o>l.n: on p.1d = pc.playbook_10and p.accivity_type = "event:elds WHERE crm confiquration id = 1 and obiect tvpe = 'event':eld values WHERE crm_field id = 4youts cl join playbook_layouts pl 1<->1.n: on cl.id = pl.layout_idion_id = 1 and pl.playbook_id = 175;MeR-ADME.mosonar-project.propertiesOreturn Collection<AutomatedReport>= test.py4> Untited Diagram.Xmi555556557us vetur.confia.ismated_reports ramuid = t.id"daluir"M+ WEBHOOK_FILTERING_IMPLEMEI› Ih External LibrariesE® Scratches and Consolessagesilic function getAllStandardReports(string $sortColumn ='created_at',sarino osorturecmion = 'oesc'LoLecron "...hv D Database ConsolesAEU> A jiminny@localhostdPRODA QAL QAI4 QAI PROD5591S00561562563-564565 vOparam User$userThe user whose reports to retrieve.566Oparam string $sortColumnThe column to sort by. Allowed values: YC567Oparam string $sortDirection The sort direction. Allowed values:'astnow() OR r.expicesaat IS NULL);ted_ report_results where repontaid IN (18, 33);Retrieve all Ask Jiminny reports created by the given user.ted_reppr+];ted_report_results where repontaid IN (33, 34, 35);V L STAGING& console slAGiNgdrecurh coclection<Aucomacedkeport.A console_1 [STAGING]A uranus [STAGING]Services+oe|×~ D DatabaseV dEUA consolev djiminny@localhostans ocall4 SFV A PRODconsoleV A STAGINGs console 15 4541115& DockerOutput35 rowsyDid Ylini jiminny.automated reports XIx. Auleywuid (UUID with time-low and time-high swapped) TIn team id Y• 047 201-1800-40/-2501-8/11 8005ot%7 fa76bd0d-61bd-4fac-86c4-9cbf6f71ad2611 8a63a8f1-b5c2-4d70-b04b-3c24c69e496b12 acce2c65-665b-48f6-b48c-d13b6bf686cd13 1eec5e26-1a75-4h08-ad2a-88c47c0e567114 6043422f-184a-4c7e-8be6-e1ac72dc0f3515 8b79d9d8-fa16-4400-bbb8-1e2b0c74345216 f9334df3-6d16-47b4-b632-a2e95c628383stouonoc-oerc-uost-d.15a-110401760/01618 18c857ec-f1e5-432d-a873-28913f9e6d4d19 439ada99-7374-41b9-95f2-32c4fa691d8842400000-1100-4102-0/00-4000020700/021 f278e4f1-0f02-40e7-9461-6d18992c724122 d88089d5-3c70-48c1-98a4-c8b60dab685223 f264d0ba-3129-443a-9d82-7716cffb667f24 5a98c597-756b-4809-b096-91bcbce273fa33 fa7417aa-538e-49ab-8827-77235637a6f9type Y1 ask_jiminny1 ask_jiminny1 ask_jiminny1 ask iiminny1 ask_jiminny1 ask_jiminny1 ask_jiminny1 ask iiminny1 ask_jiminny1 ask_jiminny1 ask_jiminnyask aunannv1 ask_jiminny1 ask_jiminny1 ask_jiminny1 ask iiminny1 ask_jiminnyI status YI frequency Y1 dailyO daily1 dailyo daily1 daily1 daily1 weekly1 weekly1 monthly1 dailyO monthly1 daily1 weekly1 monthlyO dailyo monthly1 dailyWindsurf changelog 2.12.21: A new version is available. // View Changelog (today 10:33)I from T<null><null><null><null><null>snuud<null><null>SnULL><null><null><null>shuld<null>mto T<nullssnull><null><null>cnuue<null><null>SIULL<null>snull><null><null><null><null><null>SnULl<null>{ Support Daily • in 3h 18mA• RequestGenerateAskJiminnyReportJobTest v100% [Tue 14 Apr 11:42:32CascadeFixing ReportControlleAutomated Report FaiIN @AutomatedReportsCommand.php add additional parameter report id and if provider then instead ofrevorts by wecuency ll lakes we ledort vy la or uule.Add checks for status, team activity andoiel stull useu lor curymg. uns Iwi ve usee only mllanudlly sou mele shote ve mio l not duptlcadle baseu onlstandara searenwLet me read the command and related files first.reao Aulomalecreoorscommanc,ono ano auloalecreoorsredosilorv.ono ›Now let me check the AutonatedReoort model tor relevanttielas:expioreu nulomdleunevortono anla sedichleu geloloatus getTeam expires_at getFrequency getType STATUSis... ›Now.nave every.ninelneeo. Let me imolement tne changes.• AutomatedReportsCommand.php+/8-2Also need to check if findByUuid handles soft-deleted — it doesn't, so for UUID lookup we need withTrashed too.Let me tix thatAutomatedReportsCommand.phpDone. Here's what was added:+1 -1Changes SummaryNew option: —report-id= — accepts either a numeric ID or a UUID.processsing lekeportl, — oypasses treouency logie entirely.• Looks up by ID (AutomatedReport: :withTrashed()->find() ) or UUID (also withTrashed so even deletedreports can be triggered manually)• Calls warnIfNotApplicableForSchedule() for informational output• Dispatches the job the same way as the scheduled pathwarnIfNotApplicableForSchedule() - mirrors every condition from getActiveReportsByFrequency() and theke ect allAccept allAdd findByldOrUuidt "codeClaude Sonnet 4.6CSVvdeal_value_min Y• deal_value_max YI call_types Y<null><null><null> [<null> (]<null> []<null> []<null> [<null><null><null>SIULL<null><null>SNUL><null><null>ShULD<null><null> []<null> []<null> []<null> (]<null> []<null> []<null> []<null> []<null> []<null> []<null> []media_t)["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]["pdf"]W Windsurf Teams565:28UTF-84 spaces...
|
NULL
|
|
10433
|
209
|
0
|
2026-04-14T08:42:43.311572+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776156163311_m2.jpg...
|
Firefox
|
JY-20543 add AJ reports User pilot tracking by Lak JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app — Work...
|
True
|
github.com/jiminny/app/pull/11932
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
CloudWatch | us-east-2
us-east-2.console.aws.amazo CloudWatch | us-east-2
us-east-2.console.aws.amazon.com
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
Platform Sprint 1 Q2 - Platform Team - Scrum Board - Jira
Platform Sprint 1 Q2 - Platform Team - Scrum Board - Jira
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
Close tab
Configure SSH access to multiple environment - Engineering - Confluence
Configure SSH access to multiple environment - Engineering - Confluence
Console Home | Console Home | us-east-2
Console Home | Console Home | us-east-2
SecurityGroup | EC2 | us-east-2
SecurityGroup | EC2 | us-east-2
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
SRD-6779 | JY-20632 | Unable to log in to Sidekick with SSO by yalokin-jiminny · Pull Request #11935 · jiminny/app
SRD-6779 | JY-20632 | Unable to log in to Sidekick with SSO by yalokin-jiminny · Pull Request #11935 · jiminny/app
Jy 19798 evaluation for ai activity types by nikolaybiaivanov · Pull Request #468 · jiminny/prophet
Jy 19798 evaluation for ai activity types by nikolaybiaivanov · Pull Request #468 · jiminny/prophet
Jiminny
Jiminny
Ask Jiminny test report - 8 Apr 2026 - Ask Jiminny test report - 13 Apr 2026.pdf
Ask Jiminny test report - 8 Apr 2026 - Ask Jiminny test report - 13 Apr 2026.pdf
Service-Desk - Queues - Platform team - Service space - Jira
Service-Desk - Queues - Platform team - Service space - Jira
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
Configure SSH access to multiple environment - Engineering - Confluence
Configure SSH access to multiple environment - Engineering - Confluence
CloudWatch | us-east-2
CloudWatch | us-east-2
Close tab
New Tab
Customize sidebar
Close Google Gemini (⌃X)
Tabs from other devices
Open history (⇧⌘H)
Open bookmarks (⌘B)
AI Chat settings
Close
WORK, Google Account: [EMAIL]
Main menu
New Chat
Open menu for conversation actions.
Conversation with Gemini
Conversation with Gemini
Copy prompt
Edit
You said why I can't see speaker data on meemt in firefox. ho wto set it up
You said
why I can't see speaker data on meemt in firefox. ho wto set it up
Listen
Show more options
Show thinking
Gemini said
Gemini said
Dealing with missing features right when you need them is incredibly frustrating. Assuming "meemt" means Google Meet, the reason you can't see your speaker data comes down to how Firefox interacts with Google's platform compared to Chrome.
Since "speaker data" can mean a couple of different things in a meeting, here are the two most likely causes for your issue and exactly how to get things working.
1. You Need "Speaker Notes" for Google Slides
1. You Need "Speaker Notes" for Google Slides
The Reality:
Google Meet has a native feature that lets you see your presentation's speaker notes right inside the video call interface.
However, this relies on a specific "Present a Tab" technology built exclusively for Google Chrome. Firefox handles screen sharing differently, so that native integration simply won't load.
View source details for citation from Google Workspace Updates. Opens side panel.
How to set it up (The Firefox Workaround):
You can still present and read your notes in Firefox by manually managing your windows.
Open your Google Slides presentation in a standard Firefox window.
Click the dropdown arrow next to the
Slideshow
button in the top right corner.
Select
Presenter view
to pop your speaker notes out into a separate, smaller window.
View source details for citation from Skywork. Opens side panel.
Join your Google Meet in a different Firefox window.
Click
Present now
and choose the
Window
option.
Select the window displaying your main slides (do not select your separate speaker notes window).
Resize your windows on your monitor so you can comfortably read the notes window while keeping an eye on the Meet window.
2. You Need "Speaker Labels" or Transcripts
2. You Need "Speaker Labels" or Transcripts
The Reality:
If you are trying to use a third-party AI note-taker (like Otter.ai, Tactiq, or tl;dv) to capture transcriptions and see who is speaking, Firefox is likely the roadblock. Firefox has strict privacy guardrails that prevent extensions from capturing internal browser audio easily, so most developers only build these tools for Chrome.
How to set it up:
Turn on built-in captions:
Google Meet has its own live captions that natively identify who is speaking, even in Firefox. Click the
CC
button at the bottom of your Meet screen to toggle them on.
Search for a Firefox add-on:
Check the Mozilla Add-ons store to see if your preferred tool actually has a supported Firefox version (for example, Fellow.ai offers one).
View source details for citation from Fellow.ai. Opens side panel.
Switch browsers temporarily:
If your specific transcription tool is explicitly Chrome-only, you will unfortunately need to join that specific meeting using a Chromium-based browser like Chrome, Edge, or Brave to capture the data.
Using Meet's built-in closed captions or the manual Presenter view workaround will get your speaker data back on track without forcing you to completely abandon Firefox.
Sources
Sources
I men in dia (arc) I can see my headphones in both microphone and speakers
I men in dia (arc) I can see my headphones in both microphone and speakers
Open upload file menu...
|
[{"role":"AXStaticText","text& [{"role":"AXStaticText","text":"CloudWatch | us-east-2","depth":4,"bounds":{"left":0.09804688,"top":0.45972222,"width":0.05078125,"height":0.009722223},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"us-east-2.console.aws.amazon.com","depth":4,"bounds":{"left":0.09804688,"top":0.46944445,"width":0.07382812,"height":0.009722223},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app","depth":4,"bounds":{"left":0.00234375,"top":0.045138888,"width":0.0890625,"height":0.028472222},"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXRadioButton","text":"Platform Sprint 1 Q2 - Platform Team - Scrum Board - Jira","depth":4,"bounds":{"left":0.0,"top":0.08263889,"width":0.09375,"height":0.028472222},"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Platform Sprint 1 Q2 - Platform Team - Scrum Board - Jira","depth":5,"bounds":{"left":0.015625,"top":0.09236111,"width":0.11796875,"height":0.009722223},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app","depth":4,"bounds":{"left":0.0,"top":0.11111111,"width":0.09375,"height":0.028472222},"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":true},{"role":"AXStaticText","text":"JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app","depth":5,"bounds":{"left":0.015625,"top":0.12083333,"width":0.18710938,"height":0.009722223},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"Close tab","depth":5,"bounds":{"left":0.07890625,"top":0.11736111,"width":0.009375,"height":0.016666668},"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXRadioButton","text":"Configure SSH access to multiple environment - Engineering - Confluence","depth":4,"bounds":{"left":0.0,"top":0.13958333,"width":0.09375,"height":0.028472222},"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Configure SSH access to multiple environment - Engineering - Confluence","depth":5,"bounds":{"left":0.015625,"top":0.14930555,"width":0.1515625,"height":0.009722223},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"Console Home | Console Home | us-east-2","depth":4,"bounds":{"left":0.0,"top":0.16805555,"width":0.09375,"height":0.028472222},"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Console Home | Console Home | us-east-2","depth":5,"bounds":{"left":0.015625,"top":0.17777778,"width":0.08671875,"height":0.009722223},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"SecurityGroup | EC2 | us-east-2","depth":4,"bounds":{"left":0.0,"top":0.19652778,"width":0.09375,"height":0.028472222},"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"SecurityGroup | EC2 | us-east-2","depth":5,"bounds":{"left":0.015625,"top":0.20625,"width":0.06484375,"height":0.009722223},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app","depth":4,"bounds":{"left":0.0,"top":0.225,"width":0.09375,"height":0.028472222},"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app","depth":5,"bounds":{"left":0.015625,"top":0.23472223,"width":0.18710938,"height":0.009722223},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"SRD-6779 | JY-20632 | Unable to log in to Sidekick with SSO by yalokin-jiminny · Pull Request #11935 · jiminny/app","depth":4,"bounds":{"left":0.0,"top":0.2534722,"width":0.09375,"height":0.028472222},"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"SRD-6779 | JY-20632 | Unable to log in to Sidekick with SSO by yalokin-jiminny · Pull Request #11935 · jiminny/app","depth":5,"bounds":{"left":0.015625,"top":0.26319444,"width":0.23476562,"height":0.009722223},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"Jy 19798 evaluation for ai activity types by nikolaybiaivanov · Pull Request #468 · jiminny/prophet","depth":4,"bounds":{"left":0.0,"top":0.28194445,"width":0.09375,"height":0.028472222},"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Jy 19798 evaluation for ai activity types by nikolaybiaivanov · Pull Request #468 · jiminny/prophet","depth":5,"bounds":{"left":0.015625,"top":0.29166666,"width":0.1984375,"height":0.009722223},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"Jiminny","depth":4,"bounds":{"left":0.0,"top":0.31041667,"width":0.09375,"height":0.028472222},"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Jiminny","depth":5,"bounds":{"left":0.015625,"top":0.3201389,"width":0.015625,"height":0.009722223},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"Ask Jiminny test report - 8 Apr 2026 - Ask Jiminny test report - 13 Apr 2026.pdf","depth":4,"bounds":{"left":0.0,"top":0.33888888,"width":0.09375,"height":0.028472222},"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Ask Jiminny test report - 8 Apr 2026 - Ask Jiminny test report - 13 Apr 2026.pdf","depth":5,"bounds":{"left":0.015625,"top":0.34861112,"width":0.1640625,"height":0.009722223},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"Service-Desk - Queues - Platform team - Service space - Jira","depth":4,"bounds":{"left":0.0,"top":0.3673611,"width":0.09375,"height":0.028472222},"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Service-Desk - Queues - Platform team - Service space - Jira","depth":5,"bounds":{"left":0.015625,"top":0.37708333,"width":0.12617187,"height":0.009722223},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app","depth":4,"bounds":{"left":0.0,"top":0.39583334,"width":0.09375,"height":0.028472222},"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app","depth":5,"bounds":{"left":0.015625,"top":0.40555555,"width":0.18710938,"height":0.009722223},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"Configure SSH access to multiple environment - Engineering - Confluence","depth":4,"bounds":{"left":0.0,"top":0.42430556,"width":0.09375,"height":0.028472222},"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Configure SSH access to multiple environment - Engineering - Confluence","depth":5,"bounds":{"left":0.015625,"top":0.4340278,"width":0.1515625,"height":0.009722223},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"CloudWatch | us-east-2","depth":4,"bounds":{"left":0.0,"top":0.45277777,"width":0.09375,"height":0.028472222},"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"CloudWatch | us-east-2","depth":5,"bounds":{"left":0.015625,"top":0.4625,"width":0.0484375,"height":0.009722223},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"Close tab","depth":5,"bounds":{"left":0.07890625,"top":0.45902777,"width":0.009375,"height":0.016666668},"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXButton","text":"New Tab","depth":4,"bounds":{"left":0.003125,"top":0.4826389,"width":0.08710937,"height":0.022222223},"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXCheckBox","text":"Customize sidebar","depth":6,"bounds":{"left":0.003125,"top":0.97430557,"width":0.0125,"height":0.022222223},"help_text":"","role_description":"toggle button","subrole":"AXToggle","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXCheckBox","text":"Close Google Gemini (⌃X)","depth":6,"bounds":{"left":0.01640625,"top":0.97430557,"width":0.0125,"height":0.022222223},"help_text":"","role_description":"toggle button","subrole":"AXToggle","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXCheckBox","text":"Tabs from other devices","depth":6,"bounds":{"left":0.029296875,"top":0.97430557,"width":0.0125,"height":0.022222223},"help_text":"","role_description":"toggle button","subrole":"AXToggle","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXCheckBox","text":"Open history (⇧⌘H)","depth":6,"bounds":{"left":0.0421875,"top":0.97430557,"width":0.0125,"height":0.022222223},"help_text":"","role_description":"toggle button","subrole":"AXToggle","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXCheckBox","text":"Open bookmarks (⌘B)","depth":6,"bounds":{"left":0.05546875,"top":0.97430557,"width":0.0125,"height":0.022222223},"help_text":"","role_description":"toggle button","subrole":"AXToggle","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXButton","text":"AI Chat settings","depth":7,"bounds":{"left":0.2171875,"top":0.047916666,"width":0.0125,"height":0.022222223},"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Close","depth":7,"bounds":{"left":0.23125,"top":0.047916666,"width":0.0125,"height":0.022222223},"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXButton","text":"WORK, Google Account: lukas.kovalik@jiminny.com","depth":12,"bounds":{"left":0.228125,"top":0.090277776,"width":0.015625,"height":0.027777778},"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Main menu","depth":12,"bounds":{"left":0.0984375,"top":0.090277776,"width":0.015625,"height":0.027777778},"role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXButton","text":"New Chat","depth":12,"bounds":{"left":0.1953125,"top":0.090277776,"width":0.015625,"height":0.027777778},"role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXButton","text":"Open menu for conversation actions.","depth":12,"bounds":{"left":0.2109375,"top":0.090277776,"width":0.015625,"height":0.027777778},"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXHeading","text":"Conversation with Gemini","depth":15,"bounds":{"left":0.09335937,"top":0.12847222,"width":0.000390625,"height":0.00069444446},"help_text":"","role_description":"heading","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Conversation with Gemini","depth":16,"bounds":{"left":0.09335937,"top":0.13055556,"width":0.14101562,"height":0.022222223},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"Copy prompt","depth":21,"bounds":{"left":0.1203125,"top":0.15972222,"width":0.015625,"height":0.027777778},"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXButton","text":"Edit","depth":21,"bounds":{"left":0.1375,"top":0.15972222,"width":0.015625,"height":0.027777778},"role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXHeading","text":"You said why I can't see speaker data on meemt in firefox. ho wto set it up","depth":21,"bounds":{"left":0.1609375,"top":0.16805555,"width":0.072265625,"height":0.058333334},"help_text":"","role_description":"heading","subrole":"AXUnknown"},{"role":"AXStaticText","text":"You said","depth":23,"bounds":{"left":0.09335937,"top":0.1701389,"width":0.0234375,"height":0.014583333},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"why I can't see speaker data on meemt in firefox. ho wto set it up","depth":23,"bounds":{"left":0.1609375,"top":0.17083333,"width":0.07070313,"height":0.05347222},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"Listen","depth":22,"bounds":{"left":0.22382812,"top":0.25416666,"width":0.015625,"height":0.027777778},"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXButton","text":"Show more options","depth":20,"bounds":{"left":0.22382812,"top":0.24930556,"width":0.015625,"height":0.027777778},"role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Show thinking","depth":26,"bounds":{"left":0.11953125,"top":0.25625,"width":0.036328126,"height":0.013194445},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXHeading","text":"Gemini said","depth":20,"bounds":{"left":0.11679687,"top":0.2923611,"width":0.000390625,"height":0.00069444446},"help_text":"","role_description":"heading","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Gemini said","depth":21,"bounds":{"left":0.11679687,"top":0.29375,"width":0.048046876,"height":0.016666668},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Dealing with missing features right when you need them is incredibly frustrating. Assuming \"meemt\" means Google Meet, the reason you can't see your speaker data comes down to how Firefox interacts with Google's platform compared to Chrome.","depth":24,"bounds":{"left":0.10390625,"top":0.30069444,"width":0.13046876,"height":0.10486111},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Since \"speaker data\" can mean a couple of different things in a meeting, here are the two most likely causes for your issue and exactly how to get things working.","depth":24,"bounds":{"left":0.10390625,"top":0.4201389,"width":0.13125,"height":0.06875},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXHeading","text":"1. You Need \"Speaker Notes\" for Google Slides","depth":23,"bounds":{"left":0.10390625,"top":0.52152777,"width":0.13242188,"height":0.033333335},"help_text":"","role_description":"heading","subrole":"AXUnknown"},{"role":"AXStaticText","text":"1. You Need \"Speaker Notes\" for Google Slides","depth":24,"bounds":{"left":0.10390625,"top":0.5229167,"width":0.12070312,"height":0.03125},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"The Reality:","depth":24,"bounds":{"left":0.10390625,"top":0.5625,"width":0.036328126,"height":0.014583333},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Google Meet has a native feature that lets you see your presentation's speaker notes right inside the video call interface.","depth":24,"bounds":{"left":0.10390625,"top":0.5625,"width":0.13242188,"height":0.050694443},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"However, this relies on a specific \"Present a Tab\" technology built exclusively for Google Chrome. Firefox handles screen sharing differently, so that native integration simply won't load.","depth":24,"bounds":{"left":0.10390625,"top":0.5986111,"width":0.12539062,"height":0.10486111},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"View source details for citation from Google Workspace Updates. Opens side panel.","depth":24,"bounds":{"left":0.13710937,"top":0.68958336,"width":0.01015625,"height":0.013888889},"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"How to set it up (The Firefox Workaround):","depth":24,"bounds":{"left":0.10390625,"top":0.71805555,"width":0.12851563,"height":0.014583333},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"You can still present and read your notes in Firefox by manually managing your windows.","depth":24,"bounds":{"left":0.10390625,"top":0.7361111,"width":0.12617187,"height":0.03263889},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Open your Google Slides presentation in a standard Firefox window.","depth":26,"bounds":{"left":0.11796875,"top":0.7777778,"width":0.115625,"height":0.03263889},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Click the dropdown arrow next to the","depth":26,"bounds":{"left":0.11796875,"top":0.8194444,"width":0.10703125,"height":0.014583333},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Slideshow","depth":26,"bounds":{"left":0.11796875,"top":0.8375,"width":0.03125,"height":0.014583333},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"button in the top right corner.","depth":26,"bounds":{"left":0.14921875,"top":0.8375,"width":0.08515625,"height":0.014583333},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Select","depth":26,"bounds":{"left":0.11796875,"top":0.8611111,"width":0.01953125,"height":0.014583333},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Presenter view","depth":26,"bounds":{"left":0.1375,"top":0.8611111,"width":0.0453125,"height":0.014583333},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"to pop your speaker notes out into a separate, smaller window.","depth":26,"bounds":{"left":0.11796875,"top":0.8611111,"width":0.10078125,"height":0.050694443},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"View source details for citation from Skywork. Opens side panel.","depth":26,"bounds":{"left":0.16523437,"top":0.8979167,"width":0.01015625,"height":0.013888889},"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Join your Google Meet in a different Firefox window.","depth":26,"bounds":{"left":0.11796875,"top":0.92083335,"width":0.103125,"height":0.03263889},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Click","depth":26,"bounds":{"left":0.11796875,"top":0.9625,"width":0.015234375,"height":0.014583333},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Present now","depth":26,"bounds":{"left":0.13320312,"top":0.9625,"width":0.037890624,"height":0.014583333},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"and choose the","depth":26,"bounds":{"left":0.17109375,"top":0.9625,"width":0.047265626,"height":0.014583333},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Window","depth":26,"bounds":{"left":0.11796875,"top":0.98055553,"width":0.02421875,"height":0.014583333},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"option.","depth":26,"bounds":{"left":0.1421875,"top":0.98055553,"width":0.02109375,"height":0.014583333},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Select the window displaying your main slides (do not select your separate speaker notes window).","depth":26,"bounds":{"left":0.11796875,"top":1.0,"width":0.11328125,"height":-0.0041667223},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Resize your windows on your monitor so you can comfortably read the notes window while keeping an eye on the Meet window.","depth":26,"bounds":{"left":0.11796875,"top":1.0,"width":0.11835937,"height":-0.06388891},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXHeading","text":"2. You Need \"Speaker Labels\" or Transcripts","depth":23,"help_text":"","role_description":"heading","subrole":"AXUnknown"},{"role":"AXStaticText","text":"2. You Need \"Speaker Labels\" or Transcripts","depth":24,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"The Reality:","depth":24,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"If you are trying to use a third-party AI note-taker (like Otter.ai, Tactiq, or tl;dv) to capture transcriptions and see who is speaking, Firefox is likely the roadblock. Firefox has strict privacy guardrails that prevent extensions from capturing internal browser audio easily, so most developers only build these tools for Chrome.","depth":24,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"How to set it up:","depth":24,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Turn on built-in captions:","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Google Meet has its own live captions that natively identify who is speaking, even in Firefox. Click the","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"CC","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"button at the bottom of your Meet screen to toggle them on.","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Search for a Firefox add-on:","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Check the Mozilla Add-ons store to see if your preferred tool actually has a supported Firefox version (for example, Fellow.ai offers one).","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"View source details for citation from Fellow.ai. Opens side panel.","depth":26,"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Switch browsers temporarily:","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"If your specific transcription tool is explicitly Chrome-only, you will unfortunately need to join that specific meeting using a Chromium-based browser like Chrome, Edge, or Brave to capture the data.","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Using Meet's built-in closed captions or the manual Presenter view workaround will get your speaker data back on track without forcing you to completely abandon Firefox.","depth":24,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"Sources","depth":23,"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Sources","depth":25,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXTextArea","text":"I men in dia (arc) I can see my headphones in both microphone and speakers","depth":20,"bounds":{"left":0.109375,"top":0.8020833,"width":0.125,"height":0.05},"value":"I men in dia (arc) I can see my headphones in both microphone and speakers","help_text":"","role_description":"text entry area","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"I men in dia (arc) I can see my headphones in both microphone and speakers","depth":22,"bounds":{"left":0.109375,"top":0.8034722,"width":0.10625,"height":0.047916666},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"Open upload file menu","depth":20,"bounds":{"left":0.1046875,"top":0.86527777,"width":0.015625,"height":0.027777778},"role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false}]...
|
-1102013187427270464
|
-779948878936804242
|
visual_change
|
accessibility
|
NULL
|
CloudWatch | us-east-2
us-east-2.console.aws.amazo CloudWatch | us-east-2
us-east-2.console.aws.amazon.com
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
Platform Sprint 1 Q2 - Platform Team - Scrum Board - Jira
Platform Sprint 1 Q2 - Platform Team - Scrum Board - Jira
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
Close tab
Configure SSH access to multiple environment - Engineering - Confluence
Configure SSH access to multiple environment - Engineering - Confluence
Console Home | Console Home | us-east-2
Console Home | Console Home | us-east-2
SecurityGroup | EC2 | us-east-2
SecurityGroup | EC2 | us-east-2
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
SRD-6779 | JY-20632 | Unable to log in to Sidekick with SSO by yalokin-jiminny · Pull Request #11935 · jiminny/app
SRD-6779 | JY-20632 | Unable to log in to Sidekick with SSO by yalokin-jiminny · Pull Request #11935 · jiminny/app
Jy 19798 evaluation for ai activity types by nikolaybiaivanov · Pull Request #468 · jiminny/prophet
Jy 19798 evaluation for ai activity types by nikolaybiaivanov · Pull Request #468 · jiminny/prophet
Jiminny
Jiminny
Ask Jiminny test report - 8 Apr 2026 - Ask Jiminny test report - 13 Apr 2026.pdf
Ask Jiminny test report - 8 Apr 2026 - Ask Jiminny test report - 13 Apr 2026.pdf
Service-Desk - Queues - Platform team - Service space - Jira
Service-Desk - Queues - Platform team - Service space - Jira
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
Configure SSH access to multiple environment - Engineering - Confluence
Configure SSH access to multiple environment - Engineering - Confluence
CloudWatch | us-east-2
CloudWatch | us-east-2
Close tab
New Tab
Customize sidebar
Close Google Gemini (⌃X)
Tabs from other devices
Open history (⇧⌘H)
Open bookmarks (⌘B)
AI Chat settings
Close
WORK, Google Account: [EMAIL]
Main menu
New Chat
Open menu for conversation actions.
Conversation with Gemini
Conversation with Gemini
Copy prompt
Edit
You said why I can't see speaker data on meemt in firefox. ho wto set it up
You said
why I can't see speaker data on meemt in firefox. ho wto set it up
Listen
Show more options
Show thinking
Gemini said
Gemini said
Dealing with missing features right when you need them is incredibly frustrating. Assuming "meemt" means Google Meet, the reason you can't see your speaker data comes down to how Firefox interacts with Google's platform compared to Chrome.
Since "speaker data" can mean a couple of different things in a meeting, here are the two most likely causes for your issue and exactly how to get things working.
1. You Need "Speaker Notes" for Google Slides
1. You Need "Speaker Notes" for Google Slides
The Reality:
Google Meet has a native feature that lets you see your presentation's speaker notes right inside the video call interface.
However, this relies on a specific "Present a Tab" technology built exclusively for Google Chrome. Firefox handles screen sharing differently, so that native integration simply won't load.
View source details for citation from Google Workspace Updates. Opens side panel.
How to set it up (The Firefox Workaround):
You can still present and read your notes in Firefox by manually managing your windows.
Open your Google Slides presentation in a standard Firefox window.
Click the dropdown arrow next to the
Slideshow
button in the top right corner.
Select
Presenter view
to pop your speaker notes out into a separate, smaller window.
View source details for citation from Skywork. Opens side panel.
Join your Google Meet in a different Firefox window.
Click
Present now
and choose the
Window
option.
Select the window displaying your main slides (do not select your separate speaker notes window).
Resize your windows on your monitor so you can comfortably read the notes window while keeping an eye on the Meet window.
2. You Need "Speaker Labels" or Transcripts
2. You Need "Speaker Labels" or Transcripts
The Reality:
If you are trying to use a third-party AI note-taker (like Otter.ai, Tactiq, or tl;dv) to capture transcriptions and see who is speaking, Firefox is likely the roadblock. Firefox has strict privacy guardrails that prevent extensions from capturing internal browser audio easily, so most developers only build these tools for Chrome.
How to set it up:
Turn on built-in captions:
Google Meet has its own live captions that natively identify who is speaking, even in Firefox. Click the
CC
button at the bottom of your Meet screen to toggle them on.
Search for a Firefox add-on:
Check the Mozilla Add-ons store to see if your preferred tool actually has a supported Firefox version (for example, Fellow.ai offers one).
View source details for citation from Fellow.ai. Opens side panel.
Switch browsers temporarily:
If your specific transcription tool is explicitly Chrome-only, you will unfortunately need to join that specific meeting using a Chromium-based browser like Chrome, Edge, or Brave to capture the data.
Using Meet's built-in closed captions or the manual Presenter view workaround will get your speaker data back on track without forcing you to completely abandon Firefox.
Sources
Sources
I men in dia (arc) I can see my headphones in both microphone and speakers
I men in dia (arc) I can see my headphones in both microphone and speakers
Open upload file menu...
|
10432
|
|
10434
|
208
|
0
|
2026-04-14T08:42:43.819471+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776156163819_m1.jpg...
|
Firefox
|
Jiminny — Work
|
True
|
app.staging.jiminny.com/ai-reports
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
JY-20543 add AJ reports User pilot tracking by Lak JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
Platform Sprint 1 Q2 - Platform Team - Scrum Board - Jira
Platform Sprint 1 Q2 - Platform Team - Scrum Board - Jira
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
Configure SSH access to multiple environment - Engineering - Confluence
Configure SSH access to multiple environment - Engineering - Confluence
Console Home | Console Home | us-east-2
Console Home | Console Home | us-east-2
SecurityGroup | EC2 | us-east-2
SecurityGroup | EC2 | us-east-2
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
SRD-6779 | JY-20632 | Unable to log in to Sidekick with SSO by yalokin-jiminny · Pull Request #11935 · jiminny/app
SRD-6779 | JY-20632 | Unable to log in to Sidekick with SSO by yalokin-jiminny · Pull Request #11935 · jiminny/app
Jy 19798 evaluation for ai activity types by nikolaybiaivanov · Pull Request #468 · jiminny/prophet
Jy 19798 evaluation for ai activity types by nikolaybiaivanov · Pull Request #468 · jiminny/prophet
Jiminny
Jiminny
Close tab
Ask Jiminny test report - 8 Apr 2026 - Ask Jiminny test report - 13 Apr 2026.pdf
Ask Jiminny test report - 8 Apr 2026 - Ask Jiminny test report - 13 Apr 2026.pdf
Service-Desk - Queues - Platform team - Service space - Jira
Service-Desk - Queues - Platform team - Service space - Jira
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
Configure SSH access to multiple environment - Engineering - Confluence
Configure SSH access to multiple environment - Engineering - Confluence
CloudWatch | us-east-2
CloudWatch | us-east-2
New Tab
Customize sidebar
Close Google Gemini (⌃X)
Tabs from other devices
Open history (⇧⌘H)
Open bookmarks (⌘B)
AI Chat settings
Close
WORK, Google Account: [EMAIL]
Main menu
New Chat
Open menu for conversation actions.
Conversation with Gemini
Conversation with Gemini
Copy prompt
Edit
You said why I can't see speaker data on meemt in firefox. ho wto set it up
You said
why I can't see speaker data on meemt in firefox. ho wto set it up
Listen
Show more options
Show thinking
Gemini said
Gemini said
Dealing with missing features right when you need them is incredibly frustrating. Assuming "meemt" means Google Meet, the reason you can't see your speaker data comes down to how Firefox interacts with Google's platform compared to Chrome.
Since "speaker data" can mean a couple of different things in a meeting, here are the two most likely causes for your issue and exactly how to get things working.
1. You Need "Speaker Notes" for Google Slides
1. You Need "Speaker Notes" for Google Slides
The Reality:
Google Meet has a native feature that lets you see your presentation's speaker notes right inside the video call interface.
However, this relies on a specific "Present a Tab" technology built exclusively for Google Chrome. Firefox handles screen sharing differently, so that native integration simply won't load.
View source details for citation from Google Workspace Updates. Opens side panel.
How to set it up (The Firefox Workaround):
You can still present and read your notes in Firefox by manually managing your windows.
Open your Google Slides presentation in a standard Firefox window.
Click the dropdown arrow next to the
Slideshow
button in the top right corner.
Select
Presenter view
to pop your speaker notes out into a separate, smaller window.
View source details for citation from Skywork. Opens side panel.
Join your Google Meet in a different Firefox window.
Click
Present now
and choose the
Window
option.
Select the window displaying your main slides (do not select your separate speaker notes window).
Resize your windows on your monitor so you can comfortably read the notes window while keeping an eye on the Meet window.
2. You Need "Speaker Labels" or Transcripts
2. You Need "Speaker Labels" or Transcripts
The Reality:
If you are trying to use a third-party AI note-taker (like Otter.ai, Tactiq, or tl;dv) to capture transcriptions and see who is speaking, Firefox is likely the roadblock. Firefox has strict privacy guardrails that prevent extensions from capturing internal browser audio easily, so most developers only build these tools for Chrome.
How to set it up:
Turn on built-in captions:
Google Meet has its own live captions that natively identify who is speaking, even in Firefox. Click the
CC
button at the bottom of your Meet screen to toggle them on.
Search for a Firefox add-on:
Check the Mozilla Add-ons store to see if your preferred tool actually has a supported Firefox version (for example, Fellow.ai offers one).
View source details for citation from Fellow.ai. Opens side panel.
Switch browsers temporarily:
If your specific transcription tool is explicitly Chrome-only, you will unfortunately need to join that specific meeting using a Chromium-based browser like Chrome, Edge, or Brave to capture the data.
Using Meet's built-in closed captions or the manual Presenter view workaround will get your speaker data back on track without forcing you to completely abandon Firefox.
Sources
Sources
I men in dia (arc) I can see my headphones in both microphone and speakers
I men in dia (arc) I can see my headphones in both microphone and speakers
Open upload file menu
Tools
Open mode picker
Pro
Send message
Your Jiminny chats aren’t used to improve our models. Gemini is AI and can make mistakes, including about people.
Your privacy & Gemini Opens in a new window
Your privacy & Gemini
Opens in a new window
Summarize page
Summarize page
JY-18909-automated-reports-ask-jiminny ■ 869720
28
28
AI Reports
AI Reports
Ask Jiminny reports
Ask Jiminny reports
Report name
Period
Report Type Report Type
Report Type
Report Type
Clear all
NAME
FREQUENCY
SHARED
DATE
ACTIONS
No reports have been created yet
You are currently impersonating Nikolay Yankov...
|
[{"role":"AXRadioButton","text [{"role":"AXRadioButton","text":"JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app","depth":4,"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXRadioButton","text":"Platform Sprint 1 Q2 - Platform Team - Scrum Board - Jira","depth":4,"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Platform Sprint 1 Q2 - Platform Team - Scrum Board - Jira","depth":5,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app","depth":4,"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app","depth":5,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"Configure SSH access to multiple environment - Engineering - Confluence","depth":4,"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Configure SSH access to multiple environment - Engineering - Confluence","depth":5,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"Console Home | Console Home | us-east-2","depth":4,"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Console Home | Console Home | us-east-2","depth":5,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"SecurityGroup | EC2 | us-east-2","depth":4,"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"SecurityGroup | EC2 | us-east-2","depth":5,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app","depth":4,"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app","depth":5,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"SRD-6779 | JY-20632 | Unable to log in to Sidekick with SSO by yalokin-jiminny · Pull Request #11935 · jiminny/app","depth":4,"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"SRD-6779 | JY-20632 | Unable to log in to Sidekick with SSO by yalokin-jiminny · Pull Request #11935 · jiminny/app","depth":5,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"Jy 19798 evaluation for ai activity types by nikolaybiaivanov · Pull Request #468 · jiminny/prophet","depth":4,"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Jy 19798 evaluation for ai activity types by nikolaybiaivanov · Pull Request #468 · jiminny/prophet","depth":5,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"Jiminny","depth":4,"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":true},{"role":"AXStaticText","text":"Jiminny","depth":5,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"Close tab","depth":5,"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXRadioButton","text":"Ask Jiminny test report - 8 Apr 2026 - Ask Jiminny test report - 13 Apr 2026.pdf","depth":4,"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Ask Jiminny test report - 8 Apr 2026 - Ask Jiminny test report - 13 Apr 2026.pdf","depth":5,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"Service-Desk - Queues - Platform team - Service space - Jira","depth":4,"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Service-Desk - Queues - Platform team - Service space - Jira","depth":5,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app","depth":4,"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app","depth":5,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"Configure SSH access to multiple environment - Engineering - Confluence","depth":4,"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Configure SSH access to multiple environment - Engineering - Confluence","depth":5,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXRadioButton","text":"CloudWatch | us-east-2","depth":4,"help_text":"","role_description":"tab","subrole":"AXTabButton","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"CloudWatch | us-east-2","depth":5,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"New Tab","depth":4,"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXCheckBox","text":"Customize sidebar","depth":6,"help_text":"","role_description":"toggle button","subrole":"AXToggle","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXCheckBox","text":"Close Google Gemini (⌃X)","depth":6,"help_text":"","role_description":"toggle button","subrole":"AXToggle","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXCheckBox","text":"Tabs from other devices","depth":6,"help_text":"","role_description":"toggle button","subrole":"AXToggle","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXCheckBox","text":"Open history (⇧⌘H)","depth":6,"help_text":"","role_description":"toggle button","subrole":"AXToggle","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXCheckBox","text":"Open bookmarks (⌘B)","depth":6,"help_text":"","role_description":"toggle button","subrole":"AXToggle","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXButton","text":"AI Chat settings","depth":7,"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Close","depth":7,"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXButton","text":"WORK, Google Account: lukas.kovalik@jiminny.com","depth":12,"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Main menu","depth":12,"role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXButton","text":"New Chat","depth":12,"role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXButton","text":"Open menu for conversation actions.","depth":12,"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXHeading","text":"Conversation with Gemini","depth":15,"help_text":"","role_description":"heading","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Conversation with Gemini","depth":16,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"Copy prompt","depth":21,"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXButton","text":"Edit","depth":21,"role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXHeading","text":"You said why I can't see speaker data on meemt in firefox. ho wto set it up","depth":21,"help_text":"","role_description":"heading","subrole":"AXUnknown"},{"role":"AXStaticText","text":"You said","depth":23,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"why I can't see speaker data on meemt in firefox. ho wto set it up","depth":23,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"Listen","depth":22,"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXButton","text":"Show more options","depth":20,"role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Show thinking","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXHeading","text":"Gemini said","depth":20,"help_text":"","role_description":"heading","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Gemini said","depth":21,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Dealing with missing features right when you need them is incredibly frustrating. Assuming \"meemt\" means Google Meet, the reason you can't see your speaker data comes down to how Firefox interacts with Google's platform compared to Chrome.","depth":24,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Since \"speaker data\" can mean a couple of different things in a meeting, here are the two most likely causes for your issue and exactly how to get things working.","depth":24,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXHeading","text":"1. You Need \"Speaker Notes\" for Google Slides","depth":23,"help_text":"","role_description":"heading","subrole":"AXUnknown"},{"role":"AXStaticText","text":"1. You Need \"Speaker Notes\" for Google Slides","depth":24,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"The Reality:","depth":24,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Google Meet has a native feature that lets you see your presentation's speaker notes right inside the video call interface.","depth":24,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"However, this relies on a specific \"Present a Tab\" technology built exclusively for Google Chrome. Firefox handles screen sharing differently, so that native integration simply won't load.","depth":24,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"View source details for citation from Google Workspace Updates. Opens side panel.","depth":24,"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"How to set it up (The Firefox Workaround):","depth":24,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"You can still present and read your notes in Firefox by manually managing your windows.","depth":24,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Open your Google Slides presentation in a standard Firefox window.","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Click the dropdown arrow next to the","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Slideshow","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"button in the top right corner.","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Select","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Presenter view","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"to pop your speaker notes out into a separate, smaller window.","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"View source details for citation from Skywork. Opens side panel.","depth":26,"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Join your Google Meet in a different Firefox window.","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Click","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Present now","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"and choose the","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Window","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"option.","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Select the window displaying your main slides (do not select your separate speaker notes window).","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Resize your windows on your monitor so you can comfortably read the notes window while keeping an eye on the Meet window.","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXHeading","text":"2. You Need \"Speaker Labels\" or Transcripts","depth":23,"help_text":"","role_description":"heading","subrole":"AXUnknown"},{"role":"AXStaticText","text":"2. You Need \"Speaker Labels\" or Transcripts","depth":24,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"The Reality:","depth":24,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"If you are trying to use a third-party AI note-taker (like Otter.ai, Tactiq, or tl;dv) to capture transcriptions and see who is speaking, Firefox is likely the roadblock. Firefox has strict privacy guardrails that prevent extensions from capturing internal browser audio easily, so most developers only build these tools for Chrome.","depth":24,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"How to set it up:","depth":24,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Turn on built-in captions:","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Google Meet has its own live captions that natively identify who is speaking, even in Firefox. Click the","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"CC","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"button at the bottom of your Meet screen to toggle them on.","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Search for a Firefox add-on:","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Check the Mozilla Add-ons store to see if your preferred tool actually has a supported Firefox version (for example, Fellow.ai offers one).","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"View source details for citation from Fellow.ai. Opens side panel.","depth":26,"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Switch browsers temporarily:","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"If your specific transcription tool is explicitly Chrome-only, you will unfortunately need to join that specific meeting using a Chromium-based browser like Chrome, Edge, or Brave to capture the data.","depth":26,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Using Meet's built-in closed captions or the manual Presenter view workaround will get your speaker data back on track without forcing you to completely abandon Firefox.","depth":24,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"Sources","depth":23,"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Sources","depth":25,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXTextArea","text":"I men in dia (arc) I can see my headphones in both microphone and speakers","depth":20,"value":"I men in dia (arc) I can see my headphones in both microphone and speakers","help_text":"","role_description":"text entry area","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"I men in dia (arc) I can see my headphones in both microphone and speakers","depth":22,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"Open upload file menu","depth":20,"role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Tools","depth":18,"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Open mode picker","depth":20,"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Pro","depth":23,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"Send message","depth":19,"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Your Jiminny chats aren’t used to improve our models. Gemini is AI and can make mistakes, including about people.","depth":17,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXLink","text":"Your privacy & Gemini Opens in a new window","depth":17,"help_text":"","role_description":"link","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Your privacy & Gemini","depth":18,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"Opens in a new window","depth":19,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"Summarize page","depth":7,"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Summarize page","depth":9,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"JY-18909-automated-reports-ask-jiminny ■ 869720","depth":9,"bounds":{"left":0.036805555,"top":0.0,"width":0.20972222,"height":0.017777778},"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"28","depth":12,"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"28","depth":14,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXHeading","text":"AI Reports","depth":13,"help_text":"","role_description":"heading","subrole":"AXUnknown"},{"role":"AXStaticText","text":"AI Reports","depth":14,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXLink","text":"Ask Jiminny reports","depth":13,"help_text":"","role_description":"link","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Ask Jiminny reports","depth":14,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXTextField","text":"Report name","depth":17,"help_text":"","role_description":"text field","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Period","depth":20,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXComboBox","text":"Report Type Report Type","depth":16,"value":"Report Type Report Type","help_text":"","role_description":"combo box","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextField","text":"Report Type","depth":18,"help_text":"","role_description":"text field","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"Report Type","depth":19,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXButton","text":"Clear all","depth":13,"help_text":"","role_description":"button","subrole":"AXUnknown","is_enabled":true,"is_focused":false,"is_selected":false},{"role":"AXStaticText","text":"NAME","depth":16,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"FREQUENCY","depth":16,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"SHARED","depth":16,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"DATE","depth":16,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"ACTIONS","depth":16,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"No reports have been created yet","depth":13,"help_text":"","role_description":"text","subrole":"AXUnknown"},{"role":"AXStaticText","text":"You are currently impersonating Nikolay Yankov","depth":11,"help_text":"","role_description":"text","subrole":"AXUnknown"}]...
|
6150637447665026841
|
-5679865273515787186
|
click
|
accessibility
|
NULL
|
JY-20543 add AJ reports User pilot tracking by Lak JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
Platform Sprint 1 Q2 - Platform Team - Scrum Board - Jira
Platform Sprint 1 Q2 - Platform Team - Scrum Board - Jira
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
Configure SSH access to multiple environment - Engineering - Confluence
Configure SSH access to multiple environment - Engineering - Confluence
Console Home | Console Home | us-east-2
Console Home | Console Home | us-east-2
SecurityGroup | EC2 | us-east-2
SecurityGroup | EC2 | us-east-2
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
SRD-6779 | JY-20632 | Unable to log in to Sidekick with SSO by yalokin-jiminny · Pull Request #11935 · jiminny/app
SRD-6779 | JY-20632 | Unable to log in to Sidekick with SSO by yalokin-jiminny · Pull Request #11935 · jiminny/app
Jy 19798 evaluation for ai activity types by nikolaybiaivanov · Pull Request #468 · jiminny/prophet
Jy 19798 evaluation for ai activity types by nikolaybiaivanov · Pull Request #468 · jiminny/prophet
Jiminny
Jiminny
Close tab
Ask Jiminny test report - 8 Apr 2026 - Ask Jiminny test report - 13 Apr 2026.pdf
Ask Jiminny test report - 8 Apr 2026 - Ask Jiminny test report - 13 Apr 2026.pdf
Service-Desk - Queues - Platform team - Service space - Jira
Service-Desk - Queues - Platform team - Service space - Jira
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
JY-20543 add AJ reports User pilot tracking by LakyLak · Pull Request #11932 · jiminny/app
Configure SSH access to multiple environment - Engineering - Confluence
Configure SSH access to multiple environment - Engineering - Confluence
CloudWatch | us-east-2
CloudWatch | us-east-2
New Tab
Customize sidebar
Close Google Gemini (⌃X)
Tabs from other devices
Open history (⇧⌘H)
Open bookmarks (⌘B)
AI Chat settings
Close
WORK, Google Account: [EMAIL]
Main menu
New Chat
Open menu for conversation actions.
Conversation with Gemini
Conversation with Gemini
Copy prompt
Edit
You said why I can't see speaker data on meemt in firefox. ho wto set it up
You said
why I can't see speaker data on meemt in firefox. ho wto set it up
Listen
Show more options
Show thinking
Gemini said
Gemini said
Dealing with missing features right when you need them is incredibly frustrating. Assuming "meemt" means Google Meet, the reason you can't see your speaker data comes down to how Firefox interacts with Google's platform compared to Chrome.
Since "speaker data" can mean a couple of different things in a meeting, here are the two most likely causes for your issue and exactly how to get things working.
1. You Need "Speaker Notes" for Google Slides
1. You Need "Speaker Notes" for Google Slides
The Reality:
Google Meet has a native feature that lets you see your presentation's speaker notes right inside the video call interface.
However, this relies on a specific "Present a Tab" technology built exclusively for Google Chrome. Firefox handles screen sharing differently, so that native integration simply won't load.
View source details for citation from Google Workspace Updates. Opens side panel.
How to set it up (The Firefox Workaround):
You can still present and read your notes in Firefox by manually managing your windows.
Open your Google Slides presentation in a standard Firefox window.
Click the dropdown arrow next to the
Slideshow
button in the top right corner.
Select
Presenter view
to pop your speaker notes out into a separate, smaller window.
View source details for citation from Skywork. Opens side panel.
Join your Google Meet in a different Firefox window.
Click
Present now
and choose the
Window
option.
Select the window displaying your main slides (do not select your separate speaker notes window).
Resize your windows on your monitor so you can comfortably read the notes window while keeping an eye on the Meet window.
2. You Need "Speaker Labels" or Transcripts
2. You Need "Speaker Labels" or Transcripts
The Reality:
If you are trying to use a third-party AI note-taker (like Otter.ai, Tactiq, or tl;dv) to capture transcriptions and see who is speaking, Firefox is likely the roadblock. Firefox has strict privacy guardrails that prevent extensions from capturing internal browser audio easily, so most developers only build these tools for Chrome.
How to set it up:
Turn on built-in captions:
Google Meet has its own live captions that natively identify who is speaking, even in Firefox. Click the
CC
button at the bottom of your Meet screen to toggle them on.
Search for a Firefox add-on:
Check the Mozilla Add-ons store to see if your preferred tool actually has a supported Firefox version (for example, Fellow.ai offers one).
View source details for citation from Fellow.ai. Opens side panel.
Switch browsers temporarily:
If your specific transcription tool is explicitly Chrome-only, you will unfortunately need to join that specific meeting using a Chromium-based browser like Chrome, Edge, or Brave to capture the data.
Using Meet's built-in closed captions or the manual Presenter view workaround will get your speaker data back on track without forcing you to completely abandon Firefox.
Sources
Sources
I men in dia (arc) I can see my headphones in both microphone and speakers
I men in dia (arc) I can see my headphones in both microphone and speakers
Open upload file menu
Tools
Open mode picker
Pro
Send message
Your Jiminny chats aren’t used to improve our models. Gemini is AI and can make mistakes, including about people.
Your privacy & Gemini Opens in a new window
Your privacy & Gemini
Opens in a new window
Summarize page
Summarize page
JY-18909-automated-reports-ask-jiminny ■ 869720
28
28
AI Reports
AI Reports
Ask Jiminny reports
Ask Jiminny reports
Report name
Period
Report Type Report Type
Report Type
Report Type
Clear all
NAME
FREQUENCY
SHARED
DATE
ACTIONS
No reports have been created yet
You are currently impersonating Nikolay Yankov...
|
10431
|
|
10549
|
NULL
|
0
|
2026-04-14T08:47:39.233025+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776156459233_m1.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
+SlackEDHomeDMSActivityFilesLater..•MoreFileEditVi +SlackEDHomeDMSActivityFilesLater..•MoreFileEditViewGoHistoryWindow→Helpla6lSupport Daily - in 3 h 13 mTue 14 Apr 11:47:39+Jiminny ...# Starredplatform-inner-teamChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product_launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi…..Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili...R. Adelina PetrovaO. Calea DimitravoSearch Jiminny IncAneliya Angelova, Nikolay Yankov, Steliyan GeorgievMessagesAdd canvas+Phooa да тестоan АРусротораmone nunronопределен когато тествамеNikolay Yankov 10:41 AMможеш ли да я рьннеш ти командатаLukas Kovalik 10:43 AMдаNikolay Yankov 10:45 AMпиши кат оя рьннешLukas Kovalik 10:52 AMзабавих се че ми се разбазикаха settings за средипуснах и мина и fail-наима result но e failedзначиREASON_NOT_ENOUGH_ACTIVITIESвиж дали има нещо в OD със този филтьрNikolay Yankov 11:01 AMДобреNikolay Yankov 11:39 AMя рьнни пак LukasLukas Kovalik 11:43 AMготовосьщотоCompetitive pitches беше втория нали такаMessage Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev+Aa100% C48uunie nToday ~New...
|
NULL
|
6345201114390045614
|
NULL
|
click
|
ocr
|
NULL
|
+SlackEDHomeDMSActivityFilesLater..•MoreFileEditVi +SlackEDHomeDMSActivityFilesLater..•MoreFileEditViewGoHistoryWindow→Helpla6lSupport Daily - in 3 h 13 mTue 14 Apr 11:47:39+Jiminny ...# Starredplatform-inner-teamChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product_launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi…..Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili...R. Adelina PetrovaO. Calea DimitravoSearch Jiminny IncAneliya Angelova, Nikolay Yankov, Steliyan GeorgievMessagesAdd canvas+Phooa да тестоan АРусротораmone nunronопределен когато тествамеNikolay Yankov 10:41 AMможеш ли да я рьннеш ти командатаLukas Kovalik 10:43 AMдаNikolay Yankov 10:45 AMпиши кат оя рьннешLukas Kovalik 10:52 AMзабавих се че ми се разбазикаха settings за средипуснах и мина и fail-наима result но e failedзначиREASON_NOT_ENOUGH_ACTIVITIESвиж дали има нещо в OD със този филтьрNikolay Yankov 11:01 AMДобреNikolay Yankov 11:39 AMя рьнни пак LukasLukas Kovalik 11:43 AMготовосьщотоCompetitive pitches беше втория нали такаMessage Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev+Aa100% C48uunie nToday ~New...
|
NULL
|
|
10550
|
NULL
|
0
|
2026-04-14T08:47:39.223711+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776156459223_m2.jpg...
|
PhpStorm
|
faVsco.js – console [STAGING]
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
13
4
Previous Highlighted Error
Next Highlighted Error
<?php
declare(strict_types=1);
namespace Jiminny\Repositories;
use Carbon\CarbonImmutable;
use Illuminate\Database\Eloquent\Builder;
use Illuminate\Support\Carbon;
use Illuminate\Database\Eloquent\Collection;
use Illuminate\Pagination\LengthAwarePaginator;
use Illuminate\Support\Facades\DB;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\AutomatedReportResult;
use Jiminny\Models\Team;
use Jiminny\Models\User;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Jiminny\Services\Kiosk\AutomatedReports\ReportSort;
use Jiminny\Services\Kiosk\AutomatedReports\ReportSortDirection;
class AutomatedReportsRepository
{
/**
* Create a new automated report
*
* @param array $data
*
* @return AutomatedReport
*/
public function create(array $data): AutomatedReport
{
return AutomatedReport::create($data);
}
/**
* Find an automated report by UUID
*
* @param string $uuid
*
* @return AutomatedReport|null
*/
public function findByUuid(string $uuid): ?AutomatedReport
{
return AutomatedReport::where('uuid', AutomatedReport::toOptimized($uuid))->first();
}
/**
* Retrieve all standard (non-Ask Jiminny) automated reports.
*
* @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.
* @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.
*
* @return Collection<AutomatedReport>
*/
public function getAllStandardReports(
string $sortColumn = 'created_at',
string $sortDirection = 'desc'
): Collection {
return $this->buildSortedQuery($sortColumn, $sortDirection)
->whereNot('type', AutomatedReportsService::TYPE_ASK_JIMINNY)
->get();
}
/**
* Retrieve all Ask Jiminny reports created by the given user.
*
* @param User $user The user whose reports to retrieve.
* @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.
* @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.
*
* @return Collection<AutomatedReport>
*/
public function getAskJiminnyReportsByUser(
User $user,
string $sortColumn = 'created_at',
string $sortDirection = 'desc'
): Collection {
return $this->buildSortedQuery($sortColumn, $sortDirection)
->where('type', AutomatedReportsService::TYPE_ASK_JIMINNY)
->where('created_by', $user->getId())
->get();
}
private function buildSortedQuery(string $sortColumn, string $sortDirection): \Illuminate\Database\Eloquent\Builder
{
$allowedColumns = ['created_by', 'created_at'];
if (! in_array($sortColumn, $allowedColumns)) {
$sortColumn = 'created_at';
}
$sortDirection = strtolower($sortDirection) === 'asc' ? 'asc' : 'desc';
$query = AutomatedReport::query()->with(['creator', 'team']);
if ($sortColumn === 'created_by') {
$query->leftJoin('users', 'users.id', '=', 'automated_reports.created_by')
->orderByRaw("users.name COLLATE utf8mb4_unicode_ci {$sortDirection}")
->select('automated_reports.*');
} else {
$query->orderBy($sortColumn, $sortDirection);
}
return $query;
}
/**
* Get all active and enabled reports with active teams for the specified frequency.
*
* @param string $frequency
*
* @return Collection<AutomatedReport>
*/
public function getActiveReportsByFrequency(string $frequency): Collection
{
return AutomatedReport::where('automated_reports.status', true)
->where('automated_reports.frequency', $frequency)
->join('teams', 'automated_reports.team_id', '=', 'teams.id')
->where('teams.status', Team::STATUS_ACTIVE)
->where(function ($query) {
$query->whereNull('automated_reports.expires_at')
->orWhere('automated_reports.expires_at', '>=', now()->toDateString());
})
->select('automated_reports.*')
->get();
}
/**
* Update an automated report
*
* @param AutomatedReport $report
* @param array $data
*
* @return AutomatedReport
*/
public function update(AutomatedReport $report, array $data): AutomatedReport
{
$report->update($data);
return $report;
}
/**
* Create a new automated report result.
*
* @param array $data The data to create the automated report result with.
*
* @return AutomatedReportResult The newly created automated report result.
*/
public function createResult(array $data): AutomatedReportResult
{
return AutomatedReportResult::create($data);
}
/**
* Find an automated report result by UUID.
*
* @param string $uuid The UUID to find the automated report result with.
*
* @return AutomatedReportResult|null The automated report result if found, otherwise null.
*/
public function findResultByUuid(string $uuid): ?AutomatedReportResult
{
return AutomatedReportResult::where('uuid', AutomatedReportResult::toOptimized($uuid))->first();
}
public function findResultByUuidForUser(string $uuid, User $user): ?AutomatedReportResult
{
return AutomatedReportResult::query()
->where('uuid', AutomatedReportResult::toOptimized($uuid))
->whereHas('report', static function ($query) use ($user): void {
$query->where('team_id', $user->getTeamId())
->where('created_by', $user->getId());
})
->first();
}
public function findChildResult(AutomatedReportResult $result, string $type): ?AutomatedReportResult
{
return AutomatedReportResult::query()
->where('parent_id', $result->getId())
->where('media_type', $type)
->first();
}
public function getGeneratedNotSentResults(): Collection
{
return AutomatedReportResult::query()
->whereNotNull('generated_at')
->whereNull('sent_at')
->where('status', AutomatedReportResult::STATUS_GENERATED)
->whereHas('report')
->with('report')
->get();
}
public function getPaginatedUserReports(
User $user,
ReportSort $sort,
ReportSortDirection $sortDirection,
int $resultsPerPage,
int $page,
?Carbon $fromDate,
?Carbon $toDate,
array $teamIds,
array $reportTypes,
?string $name,
): LengthAwarePaginator {
$query = AutomatedReportResult::query()
->whereNotNull('automated_report_results.generated_at')
->join('automated_reports', 'automated_report_results.report_id', '=', 'automated_reports.id')
->where('automated_reports.team_id', $user->getTeamId())
->whereJsonContains('automated_reports.recipients->users', $user->getId())
->orderByRaw("$sort->value COLLATE utf8mb4_unicode_ci {$sortDirection->value}")
->select('automated_report_results.*')
->with('report.team');
if ($fromDate !== null && $toDate !== null) {
$query->whereBetween('generated_at', [$fromDate, $toDate]);
}
if (! empty($teamIds)) {
$query->where(function ($q) use ($teamIds) {
foreach ($teamIds as $id) {
$q->orWhereJsonContains('automated_reports.groups', $id);
}
});
}
if (! empty($reportTypes)) {
$query->whereIn('automated_reports.type', $reportTypes);
}
if (! empty($name)) {
$query->whereLike('name', "%$name%");
}
return $query->paginate($resultsPerPage, ['*'], 'page', $page);
}
public function countUserReports(User $user): int
{
return AutomatedReportResult::query()
->whereNotNull('generated_at')
->whereNotNull('sent_at')
->whereHas('report', function ($q) use ($user) {
$q->where('team_id', $user->getTeamId())
->whereJsonContains('recipients->users', $user->getId());
})
->count();
}
/**
* Get report IDs for a specific team
*
* @param Team $team
*
* @return \Illuminate\Support\Collection
*/
public function getReportIdsByTeam(Team $team): \Illuminate\Support\Collection
{
return AutomatedReport::where('team_id', $team->getId())->pluck('id');
}
/**
* Get all reports for a specific team
*
* @param Team $team
*
* @return Collection
*/
public function getReportsByTeam(Team $team): Collection
{
return AutomatedReport::where('team_id', $team->getId())->get();
}
/**
* Get all report results for a specific report
*
* @param AutomatedReport $report
*
* @return Collection
*/
public function getResultsByReport(AutomatedReport $report): Collection
{
return $this->getResultsByReportQuery($report)->get();
}
public function getResultsByReportQuery(AutomatedReport $report): Builder
{
return AutomatedReportResult::where('report_id', $report->getId());
}
public function getReportResultsQueryForRetention(Team $team, CarbonImmutable $retentionDate): Builder
{
$reportIds = $this->getReportIdsByTeam($team);
return AutomatedReportResult::query()->whereIn('report_id', $reportIds)
->whereRaw('IFNULL(generated_at, created_at) <= ?', [$retentionDate]);
}
/**
* @param int|null $teamId Optional team ID to filter results
*
* @return \Illuminate\Support\Collection<int, int> Collection of team IDs
*/
public function getTeamIdsWithReportsResults(?int $teamId = null): \Illuminate\Support\Collection
{
$query = DB::table('automated_reports')
->join('teams', 'automated_reports.team_id', '=', 'teams.id')
->select('teams.id')
->distinct();
if ($teamId !== null) {
$query->where('teams.id', $teamId);
}
return $query->pluck('teams.id');
}
}
Execute
Explain Plan
Browse Query History
View Parameters
Open Query Execution Settings…
In-Editor Results
Tx: Auto
Cancel Running Statements
Playground
jiminny
Sync Changes
Hide This Notification
Code changed:
Hide
16
13
13
Previous Highlighted Error
Next Highlighted Error
SELECT * FROM teams WHERE id = 1;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;
SELECT * FROM crm_fields WHERE id = 2234;
SELECT * FROM crm_field_values WHERE crm_field_id = 2234;
select * from crm_profiles where user_id = 143;
select * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO
select * from business_processes where crm_configuration_id = 39;
# 01941000000H669AAC, 01941000000H66JAAS
select * from record_type_field_values
where record_type_id IN (24);
select * from crm_field_values where id IN (2730);
select * from crm_configurations where id = 39;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce'; #1035
select * from users where team_id = 1; # 222 group 3
SELECT * FROM activities WHERE user_id = 222 order by id desc;
select * from sidekick_settings where team_id = 1;
select * from teams where id = 1;
select * from team_features where team_id = 1;
select * from activities where crm_configuration_id = 2
and provider = 'ms-teams' and id = 608765;
SELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';
select * from sidekick_settings where team_id = 2;
SELECT * FROM activities WHERE id = 608660;
select * from activity_summary_logs where activity_id = 608660;
select * from ai_prompts where transcription_id = 11214;
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;
# id: 608818, crm: 59628809737
SELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;
# id: 608821, crm: 59632069252
SELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,
playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,
scheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at
FROM activities a
join calendar_events ce on a.calendar_event_id = ce.id
WHERE a.id IN (608818, 608821);
select * from users where team_id = 1;
select * from team_settings where team_id = 1;
select * from crm_profiles where crm_configuration_id = 39 order by user_id;
select * from team_features where team_id = 1;
select * from users where team_id = 2;
SELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639
# Preslava N. Ivanova, grou id 3
SELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;
select * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';
select
a.id,
a.type,
a.scheduled_start_time,
a.actual_start_time,
a.created_at,
a.opportunity_id,
a.status
FROM activities a
WHERE opportunity_id = 344
and status IN ('completed', 'received', 'delivered')
and (
(a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))
;
SELECT * FROM users WHERE id = 222;
SELECT * FROM crm_profiles WHERE user_id = 222;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;
select * from group_deal_risk_types;
select * from opportunities where team_id = 1;
SELECT * FROM opportunities WHERE id = 315;
SELECT * FROM crm_field_data WHERE object_id = 315;
select * from crm_field_data where object_id = 260;
select * from generic_ai_prompts where subject_id = 315;
select * from teams; # 36, 21, 121, [EMAIL]
SELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';
# [PASSWORD_DOTS]
select * from teams where id = 1;
select * from crm_configurations where id = 39;
select * from users where team_id = 1;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 1;
# 1 - 00541000004281rAAA
# 204 - 0052g000003freeAAA
# 429 - 0052g000003qGOiAAM
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
select * from activities where type = 'softphone'
and created_at > '2024-12-11 15:24:36' order by id desc;
select * from activity_providers where team_id = 1;
select * from activity_provider_users where activity_provider_id = 328;
select * from opportunities where crm_configuration_id = 39
AND account_id = 178 AND is_closed = false
order by created_at DESC;
select * from contacts where id = 3952;
select * from accounts where id = 178;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations where id = 21;
select * from users where team_id = 36;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 36
and sa.provider = 'bullhorn';
select * from social_accounts where id = 348;
UPDATE social_accounts SET
provider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',
provider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',
expires = 1733998131,
state = 'connected'
WHERE id = 348;
# [PASSWORD_DOTS]
select * from teams where id = 31;
select * from crm_configurations where id = 18;
select * from users where team_id = 31; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 31;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 31
and sa.provider = 'close';
select * from contacts where crm_configuration_id = 18;
# [PASSWORD_DOTS] NEPTUNE [PASSWORD_DOTS]
select * from teams;
select * from users where id IN (1030, 1035, 1052);
select * from crm_configurations;
select * from users where team_id = 65; # 257
select * from team_settings where team_id = 65; # 257
select * from invitations where team_id = 65; # 257
select * from users where email = '[EMAIL]'; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 65;
select * from crm_configurations where id = 53;
select * from accounts where crm_configuration_id = 53 order by id desc;
select * from leads where crm_configuration_id = 53 order by id desc;
select * from contacts where crm_configuration_id = 53 order by id desc;
select * from opportunities where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 53 order by id desc;
select * from crm_fields where crm_configuration_id = 53 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 53 order by id desc;
select * from stages where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 13;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
and sa.provider = 'integration-app';
select * from contacts where crm_configuration_id = 13;
select * from social_accounts where sociable_id = 283;
SELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';
select * from activity_providers where team_id = 65;
SELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
;
# [PASSWORD_DOTS] STAGING [PASSWORD_DOTS]
SELECT * FROM teams;
SELECT * FROM teams WHERE id = 88;
SELECT * FROM teams WHERE id = 89;
select * from team_settings where team_id = 89;
SELECT * FROM users WHERE team_id = 89;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 89;
select * from users;
SELECT * FROM social_accounts WHERE sociable_id = 1761;
SELECT * FROM crm_configurations WHERE id = 70;
select * from accounts where crm_configuration_id = 70 order by id desc;
select * from leads where crm_configuration_id = 70 order by id desc;
select * from contacts where crm_configuration_id = 70 order by id desc;
select * from opportunities where crm_configuration_id = 70 order by id desc;
select * from crm_profiles where crm_configuration_id = 70 order by id desc;
select * from crm_fields where crm_configuration_id = 70 order by id desc;
select * from crm_field_values where crm_field_id = 3536 order by id desc;
select * from crm_layouts where crm_configuration_id = 70 order by id desc;
select * from stages where crm_configuration_id = 70 order by id desc;
select * from business_processes where crm_configuration_id = 70 order by id desc;
select * from business_process_stages where business_process_id = 34;
select * from contacts where id = 10468;
select * from crm_layouts where crm_configuration_id = 70;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;
SELECT * FROM crm_fields WHERE id IN (3533,3534,3535);
select * from activities where crm_configuration_id = 70
and (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;
SELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;
SELECT * FROM activities where crm_configuration_id = 69 ;
SELECT * FROM users WHERE email LIKE '%[EMAIL]%';
SELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;
SELECT * FROM opportunities WHERE id = 385;
select * from participants p
join activities a on p.activity_id = a.id
where a.crm_configuration_id = 70
and (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);
SELECT * FROM participants WHERE id = 1013638;
select * from teams where id = 90;
select * from users where team_id = 90;
select * from social_accounts where social_accounts.sociable_id IN (1960,1760);
SELECT * FROM crm_profiles WHERE crm_configuration_id = 71;
select * from invitations where team_id = 90;
select * from crm_configurations where id = 71;
select * from accounts where crm_configuration_id = 71 order by id desc;
select * from leads where crm_configuration_id = 71 order by id desc;
select * from contacts where crm_configuration_id = 71 order by id desc;
select * from opportunities where crm_configuration_id = 71 order by id desc;
select * from crm_profiles where crm_configuration_id = 71 order by id desc;
select * from crm_fields where crm_configuration_id = 71 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 71 order by id desc;
select * from stages where crm_configuration_id = 71 order by id desc;
select * from users order by secondary_email desc;
select u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa
join users u on sa.sociable_id = u.id
where sa.provider = 'google' and u.email LIKE 'aneliya%';
select * from failed_jobs order by id desc;
select * from users where email = '[EMAIL]' or secondary_email = '[EMAIL]';
select * from teams;
SELECT * FROM crm_profiles WHERE crm_configuration_id = 39;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;
SELECT * FROM crm_configurations WHERE id = 70;
select * from teams where id = 1;
select * from groups where team_id = 1;
select * from users where team_id = 1;
select o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o
join users u on o.user_id = u.id
join groups g on u.group_id = g.id
join role_user ru on u.id = ru.user_id
join roles r on ru.role_id = r.id
where o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';
select * from role_user where user_id = 143;
select * from roles;
select * from role_user;
select * from groups where id = 9;
select * from scope_groups where group_id = 9;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations;
SELECT * FROM social_accounts WHERE sociable_id = 121;
https://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105
https://crmsandbox.zoho.com/crm/
https://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080
https://crm.zoho.com/crm/
org3469620
SELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;
select * from users where email LIKE "%mobile_automation_%";
select * from social_accounts where sociable_id IN (2228);
select * from crm_profiles where user_id IN (2222,2223,2226,2227);
select * from teams order by id desc;
SELECT * FROM users WHERE id = 2229;
SELECT * FROM crm_profiles WHERE user_id = 2229;
select * from opportunities where crm_configuration_id = 88;
select * from crm_fields where crm_configuration_id = 88;
select * from crm_profiles where crm_configuration_id = 88;
SELECT * FROM teams WHERE id = 1;
SELECT * FROM users WHERE id = 143;
SELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;
https://app.staging.jiminny.com/ondemand?
min_duration=1
&
only_recorded=1
&
user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e
&
sequence_number=2
select * from users where team_id = 1 and email like '%stoyan%'
select * from coaching_feedbacks;
select * from teams;
SELECT * FROM users WHERE team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from users where id = 143;
SELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
select * from users where team_id = 2;
select * from activities where crm_configuration_id = 39
and activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'
AND user_id = 143
order by id desc;
# [PASSWORD_DOTS]
select * from teams where id = 142; # 2312, 126
select * from team_settings;
select * from users where team_id = 142; # 21642
SELECT * FROM social_accounts WHERE sociable_id = 21642;
SELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;
select * from crm_profiles where id IN (93);
select * from invitations;
select * from team_features where team_id = 1;
SELECT * FROM crm_configurations WHERE id = 126;
select * from accounts where crm_configuration_id = 126 order by id desc;
select * from leads where crm_configuration_id = 126 order by id desc;
select * from contacts where crm_configuration_id = 126 order by id desc;
select * from opportunities where crm_configuration_id = 126 order by id desc;
select * from crm_profiles where crm_configuration_id = 126 order by id desc;
select * from crm_fields where crm_configuration_id = 126 # 11060
# and type IN ('picklist', 'status')
# and object_type = 'task'
order by id desc;
# 5731,5732,5733
select DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;
select * from crm_layouts where crm_configuration_id = 126 order by id desc;
SELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);
select * from stages where crm_configuration_id = 126 order by id desc;
select * from business_processes where crm_configuration_id = 126 order by id desc;
select * from business_process_stages where business_process_id IN (76,75,74,73);
select * from playbooks where team_id = 142;
select * from playbook_layouts where playbook_id IN (108);
SELECT * FROM playbook_categories WHERE playbook_id IN (108);
select * from teams where id = 130;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 2
and sa.provider = 'hubspot';
SELECT * FROM activities
WHERE crm_configuration_id = 110;
select * from teams;
select * from crm_configurations;
SELECT * FROM activities WHERE id = 628773;
SELECT * FROM crm_profiles WHERE user_id = 1460;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from teams;
select ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id
join permission_role pr on pr.role_id = ru.role_id
join permissions p on p.id = pr.permission_id
where team_id = 495 and p.name IN ('dial');
select * from teams where id = 145;
select * from crm_configurations where id = 129;
select * from social_accounts where sociable_id = 2317;
SELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;
select * from teams where id = 1;
SELECT * FROM crm_layouts WHERE crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;
SELECT * FROM crm_layout_entities WHERE id = 5507;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');
select * from teams;
select * from activities where crm_configuration_id = 14;
SELECT * FROM social_accounts where provider = 'copper';
select * from activities where id = 628467;
select * from participants where activity_id = 628467;
SELECT * FROM contacts WHERE id = 3969;
SELECT * FROM accounts WHERE id = 177;
SELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;
# [PASSWORD_DOTS] BH
select * from teams where id = 36;
SELECT * FROM crm_configurations WHERE id = 21;
select * from activities where crm_configuration_id = 21 and id = 607901;
select * from activities where crm_configuration_id = 21;
select * roles;
select * from permissions;
select * from permission_role where permission_id = 226;
select * from migrations order by id desc;
# mercury
# neptune
# earth
select * from teams;
select * from teams where id = 19;
select * from teams where id = 27;
select * from users where team_id = 27;
SELECT * FROM crm_configurations WHERE id = 42;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from activities where id = 631461;
SELECT * FROM crm_field_values WHERE crm_field_id = 180;
select * from teams where id = 2;
SELECT * FROM social_accounts WHERE sociable_id = 89;
SELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273
select * from activity_summary_logs where activity_id = 634273;
select * from sidekick_settings where team_id = 2;
select * from teams; # 2, 2
SELECT * FROM crm_configurations WHERE team_id = 2; # 2
select * from team_features where team_id = 2;
select * from features;
SELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';
SELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;
select * from automated_reports order by id desc;
select * from automated_report_results order by id desc;
select * from users where team_id = 1 and id IN (7160, 3248);
select * from migrations order by id desc;
SELECT
CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,
u.email,
sa.*,
t.owner_id FROM social_accounts sa
JOIN users u on u.id = sa.sociable_id
JOIN teams t on t.id = u.team_id
WHERE u.team_id = 1 and sa.provider = 'salesforce';
select * from teams where id = 1;
select * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;
select * from groups where id = 565;
select * from playbooks where team_id = 1;
select * from playbooks where id = 175;
select * from playbook_categories where playbook_id = 175;
select * from users where team_id = 1;
select * from users where id = 7160;
select * from crm_profiles where user_id = 7160;
select * from features;
select
*
# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,
# crm_configuration_id, crm_provider_id, transcription_id, status
from activities where crm_configuration_id = 1 and type = 'conference'
# and crm_provider_id IS NOT NULL
and provider != 'uploader' and actual_start_time IS NOT NULL
ORDER by id desc;
select * from activities where id = 54747783; # 00UO400000pCzojMAC
select p.id, p.activity_type, pc.id, pc.name
FROM playbooks p
join playbook_categories pc on p.id = pc.playbook_id
where p.team_id = 1 and p.activity_type = 'event';
SELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';
SELECT * FROM crm_field_values WHERE crm_field_id = 4;
select * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id
where crm_configuration_id = 1 and pl.playbook_id = 175;
select * from teams;
SELECT r.* FROM automated_reports r
join teams t on r.team_id = t.id
WHERE r.frequency = 'daily'
and r.status = 1
AND t.status = 'active'
AND (r.expires_at >= now() OR r.expires_at IS NULL);
select * from automated_report_results where report_id IN (18, 33);
select * from automated_reports;
select * from automated_report_results where report_id IN (34, 35);
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
[{"role":"AXButton","text" [{"role":"AXButton","text":"Project: faVsco.js, menu","depth":5,"bounds":{"left":0.03046875,"top":0.017361112,"width":0.0453125,"height":0.022222223},"help_text":"~/jiminny/app","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"#11894 on JY-18909-automated-reports-ask-jiminny, menu","depth":5,"bounds":{"left":0.07578125,"top":0.017361112,"width":0.14960937,"height":0.022222223},"help_text":"Pull request #11894 exists for current branch JY-18909-automated-reports-ask-jiminny, but local branch is out of sync with remote","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Start Listening for PHP Debug Connections","depth":5,"bounds":{"left":0.76171875,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"RequestGenerateAskJiminnyReportJobTest","depth":6,"bounds":{"left":0.7796875,"top":0.017361112,"width":0.12109375,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Run 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"bounds":{"left":0.9007813,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Debug 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"bounds":{"left":0.9140625,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"More Actions","depth":6,"bounds":{"left":0.9273437,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"JetBrains AI","depth":5,"bounds":{"left":0.96015626,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Search Everywhere","depth":5,"bounds":{"left":0.9734375,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"IDE and Project Settings","depth":5,"bounds":{"left":0.9867188,"top":0.017361112,"width":0.013281226,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.049609374,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"13","depth":4,"bounds":{"left":0.32382813,"top":0.21666667,"width":0.011328125,"height":0.013194445},"role_description":"text"},{"role":"AXStaticText","text":"4","depth":4,"bounds":{"left":0.3375,"top":0.21666667,"width":0.009375,"height":0.013194445},"role_description":"text"},{"role":"AXButton","text":"Previous Highlighted Error","depth":4,"bounds":{"left":0.34882814,"top":0.21527778,"width":0.00859375,"height":0.015972223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Next Highlighted Error","depth":4,"bounds":{"left":0.35742188,"top":0.21527778,"width":0.008203125,"height":0.015972223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Repositories;\n\nuse Carbon\\CarbonImmutable;\nuse Illuminate\\Database\\Eloquent\\Builder;\nuse Illuminate\\Support\\Carbon;\nuse Illuminate\\Database\\Eloquent\\Collection;\nuse Illuminate\\Pagination\\LengthAwarePaginator;\nuse Illuminate\\Support\\Facades\\DB;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\AutomatedReportResult;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Models\\User;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\ReportSort;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\ReportSortDirection;\n\nclass AutomatedReportsRepository\n{\n /**\n * Create a new automated report\n *\n * @param array $data\n *\n * @return AutomatedReport\n */\n public function create(array $data): AutomatedReport\n {\n return AutomatedReport::create($data);\n }\n\n /**\n * Find an automated report by UUID\n *\n * @param string $uuid\n *\n * @return AutomatedReport|null\n */\n public function findByUuid(string $uuid): ?AutomatedReport\n {\n return AutomatedReport::where('uuid', AutomatedReport::toOptimized($uuid))->first();\n }\n\n /**\n * Retrieve all standard (non-Ask Jiminny) automated reports.\n *\n * @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.\n * @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.\n *\n * @return Collection<AutomatedReport>\n */\n public function getAllStandardReports(\n string $sortColumn = 'created_at',\n string $sortDirection = 'desc'\n ): Collection {\n return $this->buildSortedQuery($sortColumn, $sortDirection)\n ->whereNot('type', AutomatedReportsService::TYPE_ASK_JIMINNY)\n ->get();\n }\n\n /**\n * Retrieve all Ask Jiminny reports created by the given user.\n *\n * @param User $user The user whose reports to retrieve.\n * @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.\n * @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.\n *\n * @return Collection<AutomatedReport>\n */\n public function getAskJiminnyReportsByUser(\n User $user,\n string $sortColumn = 'created_at',\n string $sortDirection = 'desc'\n ): Collection {\n return $this->buildSortedQuery($sortColumn, $sortDirection)\n ->where('type', AutomatedReportsService::TYPE_ASK_JIMINNY)\n ->where('created_by', $user->getId())\n ->get();\n }\n\n private function buildSortedQuery(string $sortColumn, string $sortDirection): \\Illuminate\\Database\\Eloquent\\Builder\n {\n $allowedColumns = ['created_by', 'created_at'];\n if (! in_array($sortColumn, $allowedColumns)) {\n $sortColumn = 'created_at';\n }\n\n $sortDirection = strtolower($sortDirection) === 'asc' ? 'asc' : 'desc';\n\n $query = AutomatedReport::query()->with(['creator', 'team']);\n\n if ($sortColumn === 'created_by') {\n $query->leftJoin('users', 'users.id', '=', 'automated_reports.created_by')\n ->orderByRaw(\"users.name COLLATE utf8mb4_unicode_ci {$sortDirection}\")\n ->select('automated_reports.*');\n } else {\n $query->orderBy($sortColumn, $sortDirection);\n }\n\n return $query;\n }\n\n /**\n * Get all active and enabled reports with active teams for the specified frequency.\n *\n * @param string $frequency\n *\n * @return Collection<AutomatedReport>\n */\n public function getActiveReportsByFrequency(string $frequency): Collection\n {\n return AutomatedReport::where('automated_reports.status', true)\n ->where('automated_reports.frequency', $frequency)\n ->join('teams', 'automated_reports.team_id', '=', 'teams.id')\n ->where('teams.status', Team::STATUS_ACTIVE)\n ->where(function ($query) {\n $query->whereNull('automated_reports.expires_at')\n ->orWhere('automated_reports.expires_at', '>=', now()->toDateString());\n })\n ->select('automated_reports.*')\n ->get();\n }\n\n /**\n * Update an automated report\n *\n * @param AutomatedReport $report\n * @param array $data\n *\n * @return AutomatedReport\n */\n public function update(AutomatedReport $report, array $data): AutomatedReport\n {\n $report->update($data);\n\n return $report;\n }\n\n /**\n * Create a new automated report result.\n *\n * @param array $data The data to create the automated report result with.\n *\n * @return AutomatedReportResult The newly created automated report result.\n */\n public function createResult(array $data): AutomatedReportResult\n {\n return AutomatedReportResult::create($data);\n }\n\n /**\n * Find an automated report result by UUID.\n *\n * @param string $uuid The UUID to find the automated report result with.\n *\n * @return AutomatedReportResult|null The automated report result if found, otherwise null.\n */\n public function findResultByUuid(string $uuid): ?AutomatedReportResult\n {\n return AutomatedReportResult::where('uuid', AutomatedReportResult::toOptimized($uuid))->first();\n }\n\n public function findResultByUuidForUser(string $uuid, User $user): ?AutomatedReportResult\n {\n return AutomatedReportResult::query()\n ->where('uuid', AutomatedReportResult::toOptimized($uuid))\n ->whereHas('report', static function ($query) use ($user): void {\n $query->where('team_id', $user->getTeamId())\n ->where('created_by', $user->getId());\n })\n ->first();\n }\n\n public function findChildResult(AutomatedReportResult $result, string $type): ?AutomatedReportResult\n {\n return AutomatedReportResult::query()\n ->where('parent_id', $result->getId())\n ->where('media_type', $type)\n ->first();\n }\n\n public function getGeneratedNotSentResults(): Collection\n {\n return AutomatedReportResult::query()\n ->whereNotNull('generated_at')\n ->whereNull('sent_at')\n ->where('status', AutomatedReportResult::STATUS_GENERATED)\n ->whereHas('report')\n ->with('report')\n ->get();\n }\n\n public function getPaginatedUserReports(\n User $user,\n ReportSort $sort,\n ReportSortDirection $sortDirection,\n int $resultsPerPage,\n int $page,\n ?Carbon $fromDate,\n ?Carbon $toDate,\n array $teamIds,\n array $reportTypes,\n ?string $name,\n ): LengthAwarePaginator {\n $query = AutomatedReportResult::query()\n ->whereNotNull('automated_report_results.generated_at')\n ->join('automated_reports', 'automated_report_results.report_id', '=', 'automated_reports.id')\n ->where('automated_reports.team_id', $user->getTeamId())\n ->whereJsonContains('automated_reports.recipients->users', $user->getId())\n ->orderByRaw(\"$sort->value COLLATE utf8mb4_unicode_ci {$sortDirection->value}\")\n ->select('automated_report_results.*')\n ->with('report.team');\n\n if ($fromDate !== null && $toDate !== null) {\n $query->whereBetween('generated_at', [$fromDate, $toDate]);\n }\n\n if (! empty($teamIds)) {\n $query->where(function ($q) use ($teamIds) {\n foreach ($teamIds as $id) {\n $q->orWhereJsonContains('automated_reports.groups', $id);\n }\n });\n }\n\n if (! empty($reportTypes)) {\n $query->whereIn('automated_reports.type', $reportTypes);\n }\n\n if (! empty($name)) {\n $query->whereLike('name', \"%$name%\");\n }\n\n return $query->paginate($resultsPerPage, ['*'], 'page', $page);\n }\n\n public function countUserReports(User $user): int\n {\n return AutomatedReportResult::query()\n ->whereNotNull('generated_at')\n ->whereNotNull('sent_at')\n ->whereHas('report', function ($q) use ($user) {\n $q->where('team_id', $user->getTeamId())\n ->whereJsonContains('recipients->users', $user->getId());\n })\n ->count();\n }\n\n /**\n * Get report IDs for a specific team\n *\n * @param Team $team\n *\n * @return \\Illuminate\\Support\\Collection\n */\n public function getReportIdsByTeam(Team $team): \\Illuminate\\Support\\Collection\n {\n return AutomatedReport::where('team_id', $team->getId())->pluck('id');\n }\n\n /**\n * Get all reports for a specific team\n *\n * @param Team $team\n *\n * @return Collection\n */\n public function getReportsByTeam(Team $team): Collection\n {\n return AutomatedReport::where('team_id', $team->getId())->get();\n }\n\n /**\n * Get all report results for a specific report\n *\n * @param AutomatedReport $report\n *\n * @return Collection\n */\n public function getResultsByReport(AutomatedReport $report): Collection\n {\n return $this->getResultsByReportQuery($report)->get();\n }\n\n public function getResultsByReportQuery(AutomatedReport $report): Builder\n {\n return AutomatedReportResult::where('report_id', $report->getId());\n }\n\n public function getReportResultsQueryForRetention(Team $team, CarbonImmutable $retentionDate): Builder\n {\n $reportIds = $this->getReportIdsByTeam($team);\n\n return AutomatedReportResult::query()->whereIn('report_id', $reportIds)\n ->whereRaw('IFNULL(generated_at, created_at) <= ?', [$retentionDate]);\n }\n\n /**\n * @param int|null $teamId Optional team ID to filter results\n *\n * @return \\Illuminate\\Support\\Collection<int, int> Collection of team IDs\n */\n public function getTeamIdsWithReportsResults(?int $teamId = null): \\Illuminate\\Support\\Collection\n {\n $query = DB::table('automated_reports')\n ->join('teams', 'automated_reports.team_id', '=', 'teams.id')\n ->select('teams.id')\n ->distinct();\n\n if ($teamId !== null) {\n $query->where('teams.id', $teamId);\n }\n\n return $query->pluck('teams.id');\n }\n}","depth":4,"value":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Repositories;\n\nuse Carbon\\CarbonImmutable;\nuse Illuminate\\Database\\Eloquent\\Builder;\nuse Illuminate\\Support\\Carbon;\nuse Illuminate\\Database\\Eloquent\\Collection;\nuse Illuminate\\Pagination\\LengthAwarePaginator;\nuse Illuminate\\Support\\Facades\\DB;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\AutomatedReportResult;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Models\\User;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\ReportSort;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\ReportSortDirection;\n\nclass AutomatedReportsRepository\n{\n /**\n * Create a new automated report\n *\n * @param array $data\n *\n * @return AutomatedReport\n */\n public function create(array $data): AutomatedReport\n {\n return AutomatedReport::create($data);\n }\n\n /**\n * Find an automated report by UUID\n *\n * @param string $uuid\n *\n * @return AutomatedReport|null\n */\n public function findByUuid(string $uuid): ?AutomatedReport\n {\n return AutomatedReport::where('uuid', AutomatedReport::toOptimized($uuid))->first();\n }\n\n /**\n * Retrieve all standard (non-Ask Jiminny) automated reports.\n *\n * @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.\n * @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.\n *\n * @return Collection<AutomatedReport>\n */\n public function getAllStandardReports(\n string $sortColumn = 'created_at',\n string $sortDirection = 'desc'\n ): Collection {\n return $this->buildSortedQuery($sortColumn, $sortDirection)\n ->whereNot('type', AutomatedReportsService::TYPE_ASK_JIMINNY)\n ->get();\n }\n\n /**\n * Retrieve all Ask Jiminny reports created by the given user.\n *\n * @param User $user The user whose reports to retrieve.\n * @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.\n * @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.\n *\n * @return Collection<AutomatedReport>\n */\n public function getAskJiminnyReportsByUser(\n User $user,\n string $sortColumn = 'created_at',\n string $sortDirection = 'desc'\n ): Collection {\n return $this->buildSortedQuery($sortColumn, $sortDirection)\n ->where('type', AutomatedReportsService::TYPE_ASK_JIMINNY)\n ->where('created_by', $user->getId())\n ->get();\n }\n\n private function buildSortedQuery(string $sortColumn, string $sortDirection): \\Illuminate\\Database\\Eloquent\\Builder\n {\n $allowedColumns = ['created_by', 'created_at'];\n if (! in_array($sortColumn, $allowedColumns)) {\n $sortColumn = 'created_at';\n }\n\n $sortDirection = strtolower($sortDirection) === 'asc' ? 'asc' : 'desc';\n\n $query = AutomatedReport::query()->with(['creator', 'team']);\n\n if ($sortColumn === 'created_by') {\n $query->leftJoin('users', 'users.id', '=', 'automated_reports.created_by')\n ->orderByRaw(\"users.name COLLATE utf8mb4_unicode_ci {$sortDirection}\")\n ->select('automated_reports.*');\n } else {\n $query->orderBy($sortColumn, $sortDirection);\n }\n\n return $query;\n }\n\n /**\n * Get all active and enabled reports with active teams for the specified frequency.\n *\n * @param string $frequency\n *\n * @return Collection<AutomatedReport>\n */\n public function getActiveReportsByFrequency(string $frequency): Collection\n {\n return AutomatedReport::where('automated_reports.status', true)\n ->where('automated_reports.frequency', $frequency)\n ->join('teams', 'automated_reports.team_id', '=', 'teams.id')\n ->where('teams.status', Team::STATUS_ACTIVE)\n ->where(function ($query) {\n $query->whereNull('automated_reports.expires_at')\n ->orWhere('automated_reports.expires_at', '>=', now()->toDateString());\n })\n ->select('automated_reports.*')\n ->get();\n }\n\n /**\n * Update an automated report\n *\n * @param AutomatedReport $report\n * @param array $data\n *\n * @return AutomatedReport\n */\n public function update(AutomatedReport $report, array $data): AutomatedReport\n {\n $report->update($data);\n\n return $report;\n }\n\n /**\n * Create a new automated report result.\n *\n * @param array $data The data to create the automated report result with.\n *\n * @return AutomatedReportResult The newly created automated report result.\n */\n public function createResult(array $data): AutomatedReportResult\n {\n return AutomatedReportResult::create($data);\n }\n\n /**\n * Find an automated report result by UUID.\n *\n * @param string $uuid The UUID to find the automated report result with.\n *\n * @return AutomatedReportResult|null The automated report result if found, otherwise null.\n */\n public function findResultByUuid(string $uuid): ?AutomatedReportResult\n {\n return AutomatedReportResult::where('uuid', AutomatedReportResult::toOptimized($uuid))->first();\n }\n\n public function findResultByUuidForUser(string $uuid, User $user): ?AutomatedReportResult\n {\n return AutomatedReportResult::query()\n ->where('uuid', AutomatedReportResult::toOptimized($uuid))\n ->whereHas('report', static function ($query) use ($user): void {\n $query->where('team_id', $user->getTeamId())\n ->where('created_by', $user->getId());\n })\n ->first();\n }\n\n public function findChildResult(AutomatedReportResult $result, string $type): ?AutomatedReportResult\n {\n return AutomatedReportResult::query()\n ->where('parent_id', $result->getId())\n ->where('media_type', $type)\n ->first();\n }\n\n public function getGeneratedNotSentResults(): Collection\n {\n return AutomatedReportResult::query()\n ->whereNotNull('generated_at')\n ->whereNull('sent_at')\n ->where('status', AutomatedReportResult::STATUS_GENERATED)\n ->whereHas('report')\n ->with('report')\n ->get();\n }\n\n public function getPaginatedUserReports(\n User $user,\n ReportSort $sort,\n ReportSortDirection $sortDirection,\n int $resultsPerPage,\n int $page,\n ?Carbon $fromDate,\n ?Carbon $toDate,\n array $teamIds,\n array $reportTypes,\n ?string $name,\n ): LengthAwarePaginator {\n $query = AutomatedReportResult::query()\n ->whereNotNull('automated_report_results.generated_at')\n ->join('automated_reports', 'automated_report_results.report_id', '=', 'automated_reports.id')\n ->where('automated_reports.team_id', $user->getTeamId())\n ->whereJsonContains('automated_reports.recipients->users', $user->getId())\n ->orderByRaw(\"$sort->value COLLATE utf8mb4_unicode_ci {$sortDirection->value}\")\n ->select('automated_report_results.*')\n ->with('report.team');\n\n if ($fromDate !== null && $toDate !== null) {\n $query->whereBetween('generated_at', [$fromDate, $toDate]);\n }\n\n if (! empty($teamIds)) {\n $query->where(function ($q) use ($teamIds) {\n foreach ($teamIds as $id) {\n $q->orWhereJsonContains('automated_reports.groups', $id);\n }\n });\n }\n\n if (! empty($reportTypes)) {\n $query->whereIn('automated_reports.type', $reportTypes);\n }\n\n if (! empty($name)) {\n $query->whereLike('name', \"%$name%\");\n }\n\n return $query->paginate($resultsPerPage, ['*'], 'page', $page);\n }\n\n public function countUserReports(User $user): int\n {\n return AutomatedReportResult::query()\n ->whereNotNull('generated_at')\n ->whereNotNull('sent_at')\n ->whereHas('report', function ($q) use ($user) {\n $q->where('team_id', $user->getTeamId())\n ->whereJsonContains('recipients->users', $user->getId());\n })\n ->count();\n }\n\n /**\n * Get report IDs for a specific team\n *\n * @param Team $team\n *\n * @return \\Illuminate\\Support\\Collection\n */\n public function getReportIdsByTeam(Team $team): \\Illuminate\\Support\\Collection\n {\n return AutomatedReport::where('team_id', $team->getId())->pluck('id');\n }\n\n /**\n * Get all reports for a specific team\n *\n * @param Team $team\n *\n * @return Collection\n */\n public function getReportsByTeam(Team $team): Collection\n {\n return AutomatedReport::where('team_id', $team->getId())->get();\n }\n\n /**\n * Get all report results for a specific report\n *\n * @param AutomatedReport $report\n *\n * @return Collection\n */\n public function getResultsByReport(AutomatedReport $report): Collection\n {\n return $this->getResultsByReportQuery($report)->get();\n }\n\n public function getResultsByReportQuery(AutomatedReport $report): Builder\n {\n return AutomatedReportResult::where('report_id', $report->getId());\n }\n\n public function getReportResultsQueryForRetention(Team $team, CarbonImmutable $retentionDate): Builder\n {\n $reportIds = $this->getReportIdsByTeam($team);\n\n return AutomatedReportResult::query()->whereIn('report_id', $reportIds)\n ->whereRaw('IFNULL(generated_at, created_at) <= ?', [$retentionDate]);\n }\n\n /**\n * @param int|null $teamId Optional team ID to filter results\n *\n * @return \\Illuminate\\Support\\Collection<int, int> Collection of team IDs\n */\n public function getTeamIdsWithReportsResults(?int $teamId = null): \\Illuminate\\Support\\Collection\n {\n $query = DB::table('automated_reports')\n ->join('teams', 'automated_reports.team_id', '=', 'teams.id')\n ->select('teams.id')\n ->distinct();\n\n if ($teamId !== null) {\n $query->where('teams.id', $teamId);\n }\n\n return $query->pluck('teams.id');\n }\n}","role_description":"text entry area","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Execute","depth":4,"bounds":{"left":0.3671875,"top":0.08611111,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Explain Plan","depth":4,"bounds":{"left":0.37734374,"top":0.08611111,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Browse Query History","depth":4,"bounds":{"left":0.39023438,"top":0.08611111,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"View Parameters","depth":4,"bounds":{"left":0.40039062,"top":0.08611111,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Open Query Execution Settings…","depth":4,"bounds":{"left":0.41054687,"top":0.08611111,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"In-Editor Results","depth":4,"bounds":{"left":0.4234375,"top":0.08611111,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Tx: Auto","depth":4,"bounds":{"left":0.4363281,"top":0.08611111,"width":0.028515626,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Cancel Running Statements","depth":4,"bounds":{"left":0.4675781,"top":0.08611111,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Playground","depth":4,"bounds":{"left":0.48046875,"top":0.08611111,"width":0.034765624,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"jiminny","depth":4,"bounds":{"left":0.6738281,"top":0.08611111,"width":0.033203125,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.049609374,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"16","depth":4,"bounds":{"left":0.65117186,"top":0.10763889,"width":0.011328125,"height":0.013194445},"role_description":"text"},{"role":"AXStaticText","text":"13","depth":4,"bounds":{"left":0.66484374,"top":0.10763889,"width":0.011328125,"height":0.013194445},"role_description":"text"},{"role":"AXStaticText","text":"13","depth":4,"bounds":{"left":0.6785156,"top":0.10763889,"width":0.011328125,"height":0.013194445},"role_description":"text"},{"role":"AXButton","text":"Previous Highlighted Error","depth":4,"bounds":{"left":0.6917969,"top":0.10625,"width":0.00859375,"height":0.015972223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Next Highlighted Error","depth":4,"bounds":{"left":0.70039064,"top":0.10625,"width":0.008203125,"height":0.015972223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"SELECT * FROM teams WHERE id = 1;\n\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;\nSELECT * FROM crm_fields WHERE id = 2234;\nSELECT * FROM crm_field_values WHERE crm_field_id = 2234;\n\nselect * from crm_profiles where user_id = 143;\n\nselect * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO\nselect * from business_processes where crm_configuration_id = 39;\n# 01941000000H669AAC, 01941000000H66JAAS\n\nselect * from record_type_field_values\n where record_type_id IN (24);\n\nselect * from crm_field_values where id IN (2730);\n\nselect * from crm_configurations where id = 39;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce'; #1035\n\n\nselect * from users where team_id = 1; # 222 group 3\nSELECT * FROM activities WHERE user_id = 222 order by id desc;\nselect * from sidekick_settings where team_id = 1;\nselect * from teams where id = 1;\nselect * from team_features where team_id = 1;\n\nselect * from activities where crm_configuration_id = 2\nand provider = 'ms-teams' and id = 608765;\n\nSELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';\n\nselect * from sidekick_settings where team_id = 2;\n\nSELECT * FROM activities WHERE id = 608660;\nselect * from activity_summary_logs where activity_id = 608660;\nselect * from ai_prompts where transcription_id = 11214;\n\n# ********************************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;\n# id: 608818, crm: 59628809737\nSELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;\n# id: 608821, crm: 59632069252\nSELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,\nplaybook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,\nscheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at\nFROM activities a\njoin calendar_events ce on a.calendar_event_id = ce.id\nWHERE a.id IN (608818, 608821);\n\nselect * from users where team_id = 1;\nselect * from team_settings where team_id = 1;\nselect * from crm_profiles where crm_configuration_id = 39 order by user_id;\n\nselect * from team_features where team_id = 1;\n\nselect * from users where team_id = 2;\n\nSELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639\n# Preslava N. Ivanova, grou id 3\n\nSELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;\n\nselect * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';\n\nselect\n a.id,\n a.type,\n a.scheduled_start_time,\n a.actual_start_time,\n a.created_at,\n a.opportunity_id,\n a.status\nFROM activities a\nWHERE opportunity_id = 344\nand status IN ('completed', 'received', 'delivered')\nand (\n (a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))\n;\n\nSELECT * FROM users WHERE id = 222;\n\nSELECT * FROM crm_profiles WHERE user_id = 222;\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;\n\nselect * from group_deal_risk_types;\n\nselect * from opportunities where team_id = 1;\n\nSELECT * FROM opportunities WHERE id = 315;\nSELECT * FROM crm_field_data WHERE object_id = 315;\nselect * from crm_field_data where object_id = 260;\n\nselect * from generic_ai_prompts where subject_id = 315;\n\nselect * from teams; # 36, 21, 121, james.graham@bullhorn.jiminny.com\nSELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';\n\n# ************************************************************************************\nselect * from teams where id = 1;\nselect * from crm_configurations where id = 39;\nselect * from users where team_id = 1;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 1;\n# 1 - 00541000004281rAAA\n# 204 - 0052g000003freeAAA\n# 429 - 0052g000003qGOiAAM\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\nselect * from activities where type = 'softphone'\nand created_at > '2024-12-11 15:24:36' order by id desc;\n\nselect * from activity_providers where team_id = 1;\nselect * from activity_provider_users where activity_provider_id = 328;\n\nselect * from opportunities where crm_configuration_id = 39\nAND account_id = 178 AND is_closed = false\norder by created_at DESC;\n\nselect * from contacts where id = 3952;\nselect * from accounts where id = 178;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations where id = 21;\nselect * from users where team_id = 36;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 36;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 36\nand sa.provider = 'bullhorn';\n\nselect * from social_accounts where id = 348;\nUPDATE social_accounts SET\nprovider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',\nprovider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',\nexpires = 1733998131,\nstate = 'connected'\nWHERE id = 348;\n\n# ************************************************************************************\nselect * from teams where id = 31;\nselect * from crm_configurations where id = 18;\n\nselect * from users where team_id = 31; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 31;\n\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 31\nand sa.provider = 'close';\n\nselect * from contacts where crm_configuration_id = 18;\n\n# ********************** NEPTUNE **************************************************************\nselect * from teams;\nselect * from users where id IN (1030, 1035, 1052);\nselect * from crm_configurations;\n\nselect * from users where team_id = 65; # 257\nselect * from team_settings where team_id = 65; # 257\nselect * from invitations where team_id = 65; # 257\nselect * from users where email = 'integration-account@jiminny.com'; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 65;\n\nselect * from crm_configurations where id = 53;\nselect * from accounts where crm_configuration_id = 53 order by id desc;\nselect * from leads where crm_configuration_id = 53 order by id desc;\nselect * from contacts where crm_configuration_id = 53 order by id desc;\nselect * from opportunities where crm_configuration_id = 53 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 53 order by id desc;\nselect * from crm_fields where crm_configuration_id = 53 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 53 order by id desc;\nselect * from stages where crm_configuration_id = 53 order by id desc;\n\n\nselect * from crm_profiles where crm_configuration_id = 13;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\nand sa.provider = 'integration-app';\n\nselect * from contacts where crm_configuration_id = 13;\n\nselect * from social_accounts where sociable_id = 283;\n\nSELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';\n\nselect * from activity_providers where team_id = 65;\nSELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\n;\n\n# ***************************** STAGING ********************************************\nSELECT * FROM teams;\nSELECT * FROM teams WHERE id = 88;\nSELECT * FROM teams WHERE id = 89;\nselect * from team_settings where team_id = 89;\nSELECT * FROM users WHERE team_id = 89;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 89;\n\nselect * from users;\nSELECT * FROM social_accounts WHERE sociable_id = 1761;\nSELECT * FROM crm_configurations WHERE id = 70;\nselect * from accounts where crm_configuration_id = 70 order by id desc;\nselect * from leads where crm_configuration_id = 70 order by id desc;\nselect * from contacts where crm_configuration_id = 70 order by id desc;\nselect * from opportunities where crm_configuration_id = 70 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 70 order by id desc;\nselect * from crm_fields where crm_configuration_id = 70 order by id desc;\nselect * from crm_field_values where crm_field_id = 3536 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 70 order by id desc;\nselect * from stages where crm_configuration_id = 70 order by id desc;\nselect * from business_processes where crm_configuration_id = 70 order by id desc;\nselect * from business_process_stages where business_process_id = 34;\n\nselect * from contacts where id = 10468;\n\nselect * from crm_layouts where crm_configuration_id = 70;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;\nSELECT * FROM crm_fields WHERE id IN (3533,3534,3535);\n\nselect * from activities where crm_configuration_id = 70\nand (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;\n\nSELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;\nSELECT * FROM activities where crm_configuration_id = 69 ;\n\nSELECT * FROM users WHERE email LIKE '%jiminny_web_sa2@jiminny.com%';\nSELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;\nSELECT * FROM opportunities WHERE id = 385;\n\nselect * from participants p\njoin activities a on p.activity_id = a.id\nwhere a.crm_configuration_id = 70\nand (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);\nSELECT * FROM participants WHERE id = 1013638;\n\nselect * from teams where id = 90;\nselect * from users where team_id = 90;\nselect * from social_accounts where social_accounts.sociable_id IN (1960,1760);\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 71;\nselect * from invitations where team_id = 90;\n\nselect * from crm_configurations where id = 71;\nselect * from accounts where crm_configuration_id = 71 order by id desc;\nselect * from leads where crm_configuration_id = 71 order by id desc;\nselect * from contacts where crm_configuration_id = 71 order by id desc;\nselect * from opportunities where crm_configuration_id = 71 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 71 order by id desc;\nselect * from crm_fields where crm_configuration_id = 71 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 71 order by id desc;\nselect * from stages where crm_configuration_id = 71 order by id desc;\n\nselect * from users order by secondary_email desc;\nselect u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa\n join users u on sa.sociable_id = u.id\nwhere sa.provider = 'google' and u.email LIKE 'aneliya%';\n\nselect * from failed_jobs order by id desc;\n\nselect * from users where email = 'ben.allwright@learningpeople.co.uk' or secondary_email = 'ben.allwright@learningpeople.co.uk';\n\nselect * from teams;\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 39;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\n# ************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;\nSELECT * FROM crm_configurations WHERE id = 70;\n\nselect * from teams where id = 1;\nselect * from groups where team_id = 1;\nselect * from users where team_id = 1;\n\nselect o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o\njoin users u on o.user_id = u.id\njoin groups g on u.group_id = g.id\njoin role_user ru on u.id = ru.user_id\njoin roles r on ru.role_id = r.id\nwhere o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';\n\nselect * from role_user where user_id = 143;\nselect * from roles;\n\nselect * from role_user;\nselect * from groups where id = 9;\nselect * from scope_groups where group_id = 9;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations;\nSELECT * FROM social_accounts WHERE sociable_id = 121;\n\nhttps://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105\nhttps://crmsandbox.zoho.com/crm/\n\nhttps://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080\n https://crm.zoho.com/crm/\n org3469620\n\nSELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;\n\nselect * from users where email LIKE \"%mobile_automation_%\";\nselect * from social_accounts where sociable_id IN (2228);\nselect * from crm_profiles where user_id IN (2222,2223,2226,2227);\n\nselect * from teams order by id desc;\nSELECT * FROM users WHERE id = 2229;\nSELECT * FROM crm_profiles WHERE user_id = 2229;\nselect * from opportunities where crm_configuration_id = 88;\nselect * from crm_fields where crm_configuration_id = 88;\nselect * from crm_profiles where crm_configuration_id = 88;\n\nSELECT * FROM teams WHERE id = 1;\n\nSELECT * FROM users WHERE id = 143;\nSELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;\n\nhttps://app.staging.jiminny.com/ondemand?\n min_duration=1\n &\n only_recorded=1\n &\n user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e\n &\n sequence_number=2\n\n select * from users where team_id = 1 and email like '%stoyan%'\n\nselect * from coaching_feedbacks;\n\nselect * from teams;\nSELECT * FROM users WHERE team_id = 36;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from users where id = 143;\n\nSELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\n\nselect * from users where team_id = 2;\nselect * from activities where crm_configuration_id = 39\nand activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'\nAND user_id = 143\norder by id desc;\n\n# ************************************************************************************\nselect * from teams where id = 142; # 2312, 126\nselect * from team_settings;\nselect * from users where team_id = 142; # 21642\nSELECT * FROM social_accounts WHERE sociable_id = 21642;\nSELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;\nselect * from crm_profiles where id IN (93);\nselect * from invitations;\nselect * from team_features where team_id = 1;\n\nSELECT * FROM crm_configurations WHERE id = 126;\nselect * from accounts where crm_configuration_id = 126 order by id desc;\nselect * from leads where crm_configuration_id = 126 order by id desc;\nselect * from contacts where crm_configuration_id = 126 order by id desc;\nselect * from opportunities where crm_configuration_id = 126 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 126 order by id desc;\nselect * from crm_fields where crm_configuration_id = 126 # 11060\n# and type IN ('picklist', 'status')\n# and object_type = 'task'\norder by id desc;\n# 5731,5732,5733\nselect DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;\nselect * from crm_layouts where crm_configuration_id = 126 order by id desc;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);\nselect * from stages where crm_configuration_id = 126 order by id desc;\nselect * from business_processes where crm_configuration_id = 126 order by id desc;\nselect * from business_process_stages where business_process_id IN (76,75,74,73);\nselect * from playbooks where team_id = 142;\nselect * from playbook_layouts where playbook_id IN (108);\nSELECT * FROM playbook_categories WHERE playbook_id IN (108);\n\nselect * from teams where id = 130;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 2\nand sa.provider = 'hubspot';\n\nSELECT * FROM activities\n WHERE crm_configuration_id = 110;\n\nselect * from teams;\nselect * from crm_configurations;\n\nSELECT * FROM activities WHERE id = 628773;\nSELECT * FROM crm_profiles WHERE user_id = 1460;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from teams;\nselect ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id\njoin permission_role pr on pr.role_id = ru.role_id\n join permissions p on p.id = pr.permission_id\nwhere team_id = 495 and p.name IN ('dial');\n\nselect * from teams where id = 145;\nselect * from crm_configurations where id = 129;\nselect * from social_accounts where sociable_id = 2317;\nSELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;\n\nselect * from teams where id = 1;\nSELECT * FROM crm_layouts WHERE crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;\nSELECT * FROM crm_layout_entities WHERE id = 5507;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');\n\nselect * from teams;\nselect * from activities where crm_configuration_id = 14;\n\nSELECT * FROM social_accounts where provider = 'copper';\n\nselect * from activities where id = 628467;\nselect * from participants where activity_id = 628467;\n\nSELECT * FROM contacts WHERE id = 3969;\nSELECT * FROM accounts WHERE id = 177;\n\nSELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;\n\n# ********************* BH\nselect * from teams where id = 36;\nSELECT * FROM crm_configurations WHERE id = 21;\nselect * from activities where crm_configuration_id = 21 and id = 607901;\nselect * from activities where crm_configuration_id = 21;\n\nselect * roles;\nselect * from permissions;\nselect * from permission_role where permission_id = 226;\n\nselect * from migrations order by id desc;\n\n# mercury\n# neptune\n# earth\n\nselect * from teams;\nselect * from teams where id = 19;\nselect * from teams where id = 27;\nselect * from users where team_id = 27;\nSELECT * FROM crm_configurations WHERE id = 42;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from activities where id = 631461;\nSELECT * FROM crm_field_values WHERE crm_field_id = 180;\n\nselect * from teams where id = 2;\nSELECT * FROM social_accounts WHERE sociable_id = 89;\n\nSELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273\nselect * from activity_summary_logs where activity_id = 634273;\n\nselect * from sidekick_settings where team_id = 2;\n\nselect * from teams; # 2, 2\nSELECT * FROM crm_configurations WHERE team_id = 2; # 2\nselect * from team_features where team_id = 2;\nselect * from features;\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;\n\nselect * from automated_reports order by id desc;\nselect * from automated_report_results order by id desc;\nselect * from users where team_id = 1 and id IN (7160, 3248);\nselect * from migrations order by id desc;\n\nSELECT\n CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,\n u.email,\n sa.*,\n t.owner_id FROM social_accounts sa\nJOIN users u on u.id = sa.sociable_id\nJOIN teams t on t.id = u.team_id\nWHERE u.team_id = 1 and sa.provider = 'salesforce';\n\nselect * from teams where id = 1;\nselect * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;\nselect * from groups where id = 565;\nselect * from playbooks where team_id = 1;\nselect * from playbooks where id = 175;\nselect * from playbook_categories where playbook_id = 175;\nselect * from users where team_id = 1;\nselect * from users where id = 7160;\nselect * from crm_profiles where user_id = 7160;\nselect * from features;\nselect\n *\n# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,\n# crm_configuration_id, crm_provider_id, transcription_id, status\nfrom activities where crm_configuration_id = 1 and type = 'conference'\n# and crm_provider_id IS NOT NULL\nand provider != 'uploader' and actual_start_time IS NOT NULL\nORDER by id desc;\nselect * from activities where id = 54747783; # 00UO400000pCzojMAC\n\nselect p.id, p.activity_type, pc.id, pc.name\nFROM playbooks p\njoin playbook_categories pc on p.id = pc.playbook_id\nwhere p.team_id = 1 and p.activity_type = 'event';\n\nSELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';\nSELECT * FROM crm_field_values WHERE crm_field_id = 4;\n\nselect * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id\nwhere crm_configuration_id = 1 and pl.playbook_id = 175;\n\nselect * from teams;\nSELECT r.* FROM automated_reports r\njoin teams t on r.team_id = t.id\nWHERE r.frequency = 'daily'\n and r.status = 1\nAND t.status = 'active'\nAND (r.expires_at >= now() OR r.expires_at IS NULL);\n\nselect * from automated_report_results where report_id IN (18, 33);\n\nselect * from automated_reports;\nselect * from automated_report_results where report_id IN (34, 35);","depth":4,"value":"SELECT * FROM teams WHERE id = 1;\n\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;\nSELECT * FROM crm_fields WHERE id = 2234;\nSELECT * FROM crm_field_values WHERE crm_field_id = 2234;\n\nselect * from crm_profiles where user_id = 143;\n\nselect * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO\nselect * from business_processes where crm_configuration_id = 39;\n# 01941000000H669AAC, 01941000000H66JAAS\n\nselect * from record_type_field_values\n where record_type_id IN (24);\n\nselect * from crm_field_values where id IN (2730);\n\nselect * from crm_configurations where id = 39;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce'; #1035\n\n\nselect * from users where team_id = 1; # 222 group 3\nSELECT * FROM activities WHERE user_id = 222 order by id desc;\nselect * from sidekick_settings where team_id = 1;\nselect * from teams where id = 1;\nselect * from team_features where team_id = 1;\n\nselect * from activities where crm_configuration_id = 2\nand provider = 'ms-teams' and id = 608765;\n\nSELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';\n\nselect * from sidekick_settings where team_id = 2;\n\nSELECT * FROM activities WHERE id = 608660;\nselect * from activity_summary_logs where activity_id = 608660;\nselect * from ai_prompts where transcription_id = 11214;\n\n# ********************************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;\n# id: 608818, crm: 59628809737\nSELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;\n# id: 608821, crm: 59632069252\nSELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,\nplaybook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,\nscheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at\nFROM activities a\njoin calendar_events ce on a.calendar_event_id = ce.id\nWHERE a.id IN (608818, 608821);\n\nselect * from users where team_id = 1;\nselect * from team_settings where team_id = 1;\nselect * from crm_profiles where crm_configuration_id = 39 order by user_id;\n\nselect * from team_features where team_id = 1;\n\nselect * from users where team_id = 2;\n\nSELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639\n# Preslava N. Ivanova, grou id 3\n\nSELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;\n\nselect * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';\n\nselect\n a.id,\n a.type,\n a.scheduled_start_time,\n a.actual_start_time,\n a.created_at,\n a.opportunity_id,\n a.status\nFROM activities a\nWHERE opportunity_id = 344\nand status IN ('completed', 'received', 'delivered')\nand (\n (a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))\n;\n\nSELECT * FROM users WHERE id = 222;\n\nSELECT * FROM crm_profiles WHERE user_id = 222;\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;\n\nselect * from group_deal_risk_types;\n\nselect * from opportunities where team_id = 1;\n\nSELECT * FROM opportunities WHERE id = 315;\nSELECT * FROM crm_field_data WHERE object_id = 315;\nselect * from crm_field_data where object_id = 260;\n\nselect * from generic_ai_prompts where subject_id = 315;\n\nselect * from teams; # 36, 21, 121, james.graham@bullhorn.jiminny.com\nSELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';\n\n# ************************************************************************************\nselect * from teams where id = 1;\nselect * from crm_configurations where id = 39;\nselect * from users where team_id = 1;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 1;\n# 1 - 00541000004281rAAA\n# 204 - 0052g000003freeAAA\n# 429 - 0052g000003qGOiAAM\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\nselect * from activities where type = 'softphone'\nand created_at > '2024-12-11 15:24:36' order by id desc;\n\nselect * from activity_providers where team_id = 1;\nselect * from activity_provider_users where activity_provider_id = 328;\n\nselect * from opportunities where crm_configuration_id = 39\nAND account_id = 178 AND is_closed = false\norder by created_at DESC;\n\nselect * from contacts where id = 3952;\nselect * from accounts where id = 178;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations where id = 21;\nselect * from users where team_id = 36;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 36;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 36\nand sa.provider = 'bullhorn';\n\nselect * from social_accounts where id = 348;\nUPDATE social_accounts SET\nprovider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',\nprovider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',\nexpires = 1733998131,\nstate = 'connected'\nWHERE id = 348;\n\n# ************************************************************************************\nselect * from teams where id = 31;\nselect * from crm_configurations where id = 18;\n\nselect * from users where team_id = 31; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 31;\n\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 31\nand sa.provider = 'close';\n\nselect * from contacts where crm_configuration_id = 18;\n\n# ********************** NEPTUNE **************************************************************\nselect * from teams;\nselect * from users where id IN (1030, 1035, 1052);\nselect * from crm_configurations;\n\nselect * from users where team_id = 65; # 257\nselect * from team_settings where team_id = 65; # 257\nselect * from invitations where team_id = 65; # 257\nselect * from users where email = 'integration-account@jiminny.com'; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 65;\n\nselect * from crm_configurations where id = 53;\nselect * from accounts where crm_configuration_id = 53 order by id desc;\nselect * from leads where crm_configuration_id = 53 order by id desc;\nselect * from contacts where crm_configuration_id = 53 order by id desc;\nselect * from opportunities where crm_configuration_id = 53 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 53 order by id desc;\nselect * from crm_fields where crm_configuration_id = 53 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 53 order by id desc;\nselect * from stages where crm_configuration_id = 53 order by id desc;\n\n\nselect * from crm_profiles where crm_configuration_id = 13;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\nand sa.provider = 'integration-app';\n\nselect * from contacts where crm_configuration_id = 13;\n\nselect * from social_accounts where sociable_id = 283;\n\nSELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';\n\nselect * from activity_providers where team_id = 65;\nSELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\n;\n\n# ***************************** STAGING ********************************************\nSELECT * FROM teams;\nSELECT * FROM teams WHERE id = 88;\nSELECT * FROM teams WHERE id = 89;\nselect * from team_settings where team_id = 89;\nSELECT * FROM users WHERE team_id = 89;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 89;\n\nselect * from users;\nSELECT * FROM social_accounts WHERE sociable_id = 1761;\nSELECT * FROM crm_configurations WHERE id = 70;\nselect * from accounts where crm_configuration_id = 70 order by id desc;\nselect * from leads where crm_configuration_id = 70 order by id desc;\nselect * from contacts where crm_configuration_id = 70 order by id desc;\nselect * from opportunities where crm_configuration_id = 70 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 70 order by id desc;\nselect * from crm_fields where crm_configuration_id = 70 order by id desc;\nselect * from crm_field_values where crm_field_id = 3536 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 70 order by id desc;\nselect * from stages where crm_configuration_id = 70 order by id desc;\nselect * from business_processes where crm_configuration_id = 70 order by id desc;\nselect * from business_process_stages where business_process_id = 34;\n\nselect * from contacts where id = 10468;\n\nselect * from crm_layouts where crm_configuration_id = 70;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;\nSELECT * FROM crm_fields WHERE id IN (3533,3534,3535);\n\nselect * from activities where crm_configuration_id = 70\nand (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;\n\nSELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;\nSELECT * FROM activities where crm_configuration_id = 69 ;\n\nSELECT * FROM users WHERE email LIKE '%jiminny_web_sa2@jiminny.com%';\nSELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;\nSELECT * FROM opportunities WHERE id = 385;\n\nselect * from participants p\njoin activities a on p.activity_id = a.id\nwhere a.crm_configuration_id = 70\nand (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);\nSELECT * FROM participants WHERE id = 1013638;\n\nselect * from teams where id = 90;\nselect * from users where team_id = 90;\nselect * from social_accounts where social_accounts.sociable_id IN (1960,1760);\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 71;\nselect * from invitations where team_id = 90;\n\nselect * from crm_configurations where id = 71;\nselect * from accounts where crm_configuration_id = 71 order by id desc;\nselect * from leads where crm_configuration_id = 71 order by id desc;\nselect * from contacts where crm_configuration_id = 71 order by id desc;\nselect * from opportunities where crm_configuration_id = 71 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 71 order by id desc;\nselect * from crm_fields where crm_configuration_id = 71 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 71 order by id desc;\nselect * from stages where crm_configuration_id = 71 order by id desc;\n\nselect * from users order by secondary_email desc;\nselect u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa\n join users u on sa.sociable_id = u.id\nwhere sa.provider = 'google' and u.email LIKE 'aneliya%';\n\nselect * from failed_jobs order by id desc;\n\nselect * from users where email = 'ben.allwright@learningpeople.co.uk' or secondary_email = 'ben.allwright@learningpeople.co.uk';\n\nselect * from teams;\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 39;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\n# ************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;\nSELECT * FROM crm_configurations WHERE id = 70;\n\nselect * from teams where id = 1;\nselect * from groups where team_id = 1;\nselect * from users where team_id = 1;\n\nselect o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o\njoin users u on o.user_id = u.id\njoin groups g on u.group_id = g.id\njoin role_user ru on u.id = ru.user_id\njoin roles r on ru.role_id = r.id\nwhere o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';\n\nselect * from role_user where user_id = 143;\nselect * from roles;\n\nselect * from role_user;\nselect * from groups where id = 9;\nselect * from scope_groups where group_id = 9;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations;\nSELECT * FROM social_accounts WHERE sociable_id = 121;\n\nhttps://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105\nhttps://crmsandbox.zoho.com/crm/\n\nhttps://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080\n https://crm.zoho.com/crm/\n org3469620\n\nSELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;\n\nselect * from users where email LIKE \"%mobile_automation_%\";\nselect * from social_accounts where sociable_id IN (2228);\nselect * from crm_profiles where user_id IN (2222,2223,2226,2227);\n\nselect * from teams order by id desc;\nSELECT * FROM users WHERE id = 2229;\nSELECT * FROM crm_profiles WHERE user_id = 2229;\nselect * from opportunities where crm_configuration_id = 88;\nselect * from crm_fields where crm_configuration_id = 88;\nselect * from crm_profiles where crm_configuration_id = 88;\n\nSELECT * FROM teams WHERE id = 1;\n\nSELECT * FROM users WHERE id = 143;\nSELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;\n\nhttps://app.staging.jiminny.com/ondemand?\n min_duration=1\n &\n only_recorded=1\n &\n user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e\n &\n sequence_number=2\n\n select * from users where team_id = 1 and email like '%stoyan%'\n\nselect * from coaching_feedbacks;\n\nselect * from teams;\nSELECT * FROM users WHERE team_id = 36;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from users where id = 143;\n\nSELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\n\nselect * from users where team_id = 2;\nselect * from activities where crm_configuration_id = 39\nand activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'\nAND user_id = 143\norder by id desc;\n\n# ************************************************************************************\nselect * from teams where id = 142; # 2312, 126\nselect * from team_settings;\nselect * from users where team_id = 142; # 21642\nSELECT * FROM social_accounts WHERE sociable_id = 21642;\nSELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;\nselect * from crm_profiles where id IN (93);\nselect * from invitations;\nselect * from team_features where team_id = 1;\n\nSELECT * FROM crm_configurations WHERE id = 126;\nselect * from accounts where crm_configuration_id = 126 order by id desc;\nselect * from leads where crm_configuration_id = 126 order by id desc;\nselect * from contacts where crm_configuration_id = 126 order by id desc;\nselect * from opportunities where crm_configuration_id = 126 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 126 order by id desc;\nselect * from crm_fields where crm_configuration_id = 126 # 11060\n# and type IN ('picklist', 'status')\n# and object_type = 'task'\norder by id desc;\n# 5731,5732,5733\nselect DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;\nselect * from crm_layouts where crm_configuration_id = 126 order by id desc;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);\nselect * from stages where crm_configuration_id = 126 order by id desc;\nselect * from business_processes where crm_configuration_id = 126 order by id desc;\nselect * from business_process_stages where business_process_id IN (76,75,74,73);\nselect * from playbooks where team_id = 142;\nselect * from playbook_layouts where playbook_id IN (108);\nSELECT * FROM playbook_categories WHERE playbook_id IN (108);\n\nselect * from teams where id = 130;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 2\nand sa.provider = 'hubspot';\n\nSELECT * FROM activities\n WHERE crm_configuration_id = 110;\n\nselect * from teams;\nselect * from crm_configurations;\n\nSELECT * FROM activities WHERE id = 628773;\nSELECT * FROM crm_profiles WHERE user_id = 1460;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from teams;\nselect ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id\njoin permission_role pr on pr.role_id = ru.role_id\n join permissions p on p.id = pr.permission_id\nwhere team_id = 495 and p.name IN ('dial');\n\nselect * from teams where id = 145;\nselect * from crm_configurations where id = 129;\nselect * from social_accounts where sociable_id = 2317;\nSELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;\n\nselect * from teams where id = 1;\nSELECT * FROM crm_layouts WHERE crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;\nSELECT * FROM crm_layout_entities WHERE id = 5507;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');\n\nselect * from teams;\nselect * from activities where crm_configuration_id = 14;\n\nSELECT * FROM social_accounts where provider = 'copper';\n\nselect * from activities where id = 628467;\nselect * from participants where activity_id = 628467;\n\nSELECT * FROM contacts WHERE id = 3969;\nSELECT * FROM accounts WHERE id = 177;\n\nSELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;\n\n# ********************* BH\nselect * from teams where id = 36;\nSELECT * FROM crm_configurations WHERE id = 21;\nselect * from activities where crm_configuration_id = 21 and id = 607901;\nselect * from activities where crm_configuration_id = 21;\n\nselect * roles;\nselect * from permissions;\nselect * from permission_role where permission_id = 226;\n\nselect * from migrations order by id desc;\n\n# mercury\n# neptune\n# earth\n\nselect * from teams;\nselect * from teams where id = 19;\nselect * from teams where id = 27;\nselect * from users where team_id = 27;\nSELECT * FROM crm_configurations WHERE id = 42;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from activities where id = 631461;\nSELECT * FROM crm_field_values WHERE crm_field_id = 180;\n\nselect * from teams where id = 2;\nSELECT * FROM social_accounts WHERE sociable_id = 89;\n\nSELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273\nselect * from activity_summary_logs where activity_id = 634273;\n\nselect * from sidekick_settings where team_id = 2;\n\nselect * from teams; # 2, 2\nSELECT * FROM crm_configurations WHERE team_id = 2; # 2\nselect * from team_features where team_id = 2;\nselect * from features;\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;\n\nselect * from automated_reports order by id desc;\nselect * from automated_report_results order by id desc;\nselect * from users where team_id = 1 and id IN (7160, 3248);\nselect * from migrations order by id desc;\n\nSELECT\n CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,\n u.email,\n sa.*,\n t.owner_id FROM social_accounts sa\nJOIN users u on u.id = sa.sociable_id\nJOIN teams t on t.id = u.team_id\nWHERE u.team_id = 1 and sa.provider = 'salesforce';\n\nselect * from teams where id = 1;\nselect * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;\nselect * from groups where id = 565;\nselect * from playbooks where team_id = 1;\nselect * from playbooks where id = 175;\nselect * from playbook_categories where playbook_id = 175;\nselect * from users where team_id = 1;\nselect * from users where id = 7160;\nselect * from crm_profiles where user_id = 7160;\nselect * from features;\nselect\n *\n# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,\n# crm_configuration_id, crm_provider_id, transcription_id, status\nfrom activities where crm_configuration_id = 1 and type = 'conference'\n# and crm_provider_id IS NOT NULL\nand provider != 'uploader' and actual_start_time IS NOT NULL\nORDER by id desc;\nselect * from activities where id = 54747783; # 00UO400000pCzojMAC\n\nselect p.id, p.activity_type, pc.id, pc.name\nFROM playbooks p\njoin playbook_categories pc on p.id = pc.playbook_id\nwhere p.team_id = 1 and p.activity_type = 'event';\n\nSELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';\nSELECT * FROM crm_field_values WHERE crm_field_id = 4;\n\nselect * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id\nwhere crm_configuration_id = 1 and pl.playbook_id = 175;\n\nselect * from teams;\nSELECT r.* FROM automated_reports r\njoin teams t on r.team_id = t.id\nWHERE r.frequency = 'daily'\n and r.status = 1\nAND t.status = 'active'\nAND (r.expires_at >= now() OR r.expires_at IS NULL);\n\nselect * from automated_report_results where report_id IN (18, 33);\n\nselect * from automated_reports;\nselect * from automated_report_results where report_id IN (34, 35);","role_description":"text entry area","is_enabled":true,"is_focused":true,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Project","depth":3,"role_description":"text"},{"role":"AXButton","text":"Project","depth":3,"bounds":{"left":0.0140625,"top":0.041666668,"width":0.028515626,"height":0.021527778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"New File or Directory…","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Expand Selected","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Collapse All","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Options","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false}]...
|
3798630016527344503
|
6686649039917036621
|
click
|
accessibility
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
13
4
Previous Highlighted Error
Next Highlighted Error
<?php
declare(strict_types=1);
namespace Jiminny\Repositories;
use Carbon\CarbonImmutable;
use Illuminate\Database\Eloquent\Builder;
use Illuminate\Support\Carbon;
use Illuminate\Database\Eloquent\Collection;
use Illuminate\Pagination\LengthAwarePaginator;
use Illuminate\Support\Facades\DB;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\AutomatedReportResult;
use Jiminny\Models\Team;
use Jiminny\Models\User;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Jiminny\Services\Kiosk\AutomatedReports\ReportSort;
use Jiminny\Services\Kiosk\AutomatedReports\ReportSortDirection;
class AutomatedReportsRepository
{
/**
* Create a new automated report
*
* @param array $data
*
* @return AutomatedReport
*/
public function create(array $data): AutomatedReport
{
return AutomatedReport::create($data);
}
/**
* Find an automated report by UUID
*
* @param string $uuid
*
* @return AutomatedReport|null
*/
public function findByUuid(string $uuid): ?AutomatedReport
{
return AutomatedReport::where('uuid', AutomatedReport::toOptimized($uuid))->first();
}
/**
* Retrieve all standard (non-Ask Jiminny) automated reports.
*
* @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.
* @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.
*
* @return Collection<AutomatedReport>
*/
public function getAllStandardReports(
string $sortColumn = 'created_at',
string $sortDirection = 'desc'
): Collection {
return $this->buildSortedQuery($sortColumn, $sortDirection)
->whereNot('type', AutomatedReportsService::TYPE_ASK_JIMINNY)
->get();
}
/**
* Retrieve all Ask Jiminny reports created by the given user.
*
* @param User $user The user whose reports to retrieve.
* @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.
* @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.
*
* @return Collection<AutomatedReport>
*/
public function getAskJiminnyReportsByUser(
User $user,
string $sortColumn = 'created_at',
string $sortDirection = 'desc'
): Collection {
return $this->buildSortedQuery($sortColumn, $sortDirection)
->where('type', AutomatedReportsService::TYPE_ASK_JIMINNY)
->where('created_by', $user->getId())
->get();
}
private function buildSortedQuery(string $sortColumn, string $sortDirection): \Illuminate\Database\Eloquent\Builder
{
$allowedColumns = ['created_by', 'created_at'];
if (! in_array($sortColumn, $allowedColumns)) {
$sortColumn = 'created_at';
}
$sortDirection = strtolower($sortDirection) === 'asc' ? 'asc' : 'desc';
$query = AutomatedReport::query()->with(['creator', 'team']);
if ($sortColumn === 'created_by') {
$query->leftJoin('users', 'users.id', '=', 'automated_reports.created_by')
->orderByRaw("users.name COLLATE utf8mb4_unicode_ci {$sortDirection}")
->select('automated_reports.*');
} else {
$query->orderBy($sortColumn, $sortDirection);
}
return $query;
}
/**
* Get all active and enabled reports with active teams for the specified frequency.
*
* @param string $frequency
*
* @return Collection<AutomatedReport>
*/
public function getActiveReportsByFrequency(string $frequency): Collection
{
return AutomatedReport::where('automated_reports.status', true)
->where('automated_reports.frequency', $frequency)
->join('teams', 'automated_reports.team_id', '=', 'teams.id')
->where('teams.status', Team::STATUS_ACTIVE)
->where(function ($query) {
$query->whereNull('automated_reports.expires_at')
->orWhere('automated_reports.expires_at', '>=', now()->toDateString());
})
->select('automated_reports.*')
->get();
}
/**
* Update an automated report
*
* @param AutomatedReport $report
* @param array $data
*
* @return AutomatedReport
*/
public function update(AutomatedReport $report, array $data): AutomatedReport
{
$report->update($data);
return $report;
}
/**
* Create a new automated report result.
*
* @param array $data The data to create the automated report result with.
*
* @return AutomatedReportResult The newly created automated report result.
*/
public function createResult(array $data): AutomatedReportResult
{
return AutomatedReportResult::create($data);
}
/**
* Find an automated report result by UUID.
*
* @param string $uuid The UUID to find the automated report result with.
*
* @return AutomatedReportResult|null The automated report result if found, otherwise null.
*/
public function findResultByUuid(string $uuid): ?AutomatedReportResult
{
return AutomatedReportResult::where('uuid', AutomatedReportResult::toOptimized($uuid))->first();
}
public function findResultByUuidForUser(string $uuid, User $user): ?AutomatedReportResult
{
return AutomatedReportResult::query()
->where('uuid', AutomatedReportResult::toOptimized($uuid))
->whereHas('report', static function ($query) use ($user): void {
$query->where('team_id', $user->getTeamId())
->where('created_by', $user->getId());
})
->first();
}
public function findChildResult(AutomatedReportResult $result, string $type): ?AutomatedReportResult
{
return AutomatedReportResult::query()
->where('parent_id', $result->getId())
->where('media_type', $type)
->first();
}
public function getGeneratedNotSentResults(): Collection
{
return AutomatedReportResult::query()
->whereNotNull('generated_at')
->whereNull('sent_at')
->where('status', AutomatedReportResult::STATUS_GENERATED)
->whereHas('report')
->with('report')
->get();
}
public function getPaginatedUserReports(
User $user,
ReportSort $sort,
ReportSortDirection $sortDirection,
int $resultsPerPage,
int $page,
?Carbon $fromDate,
?Carbon $toDate,
array $teamIds,
array $reportTypes,
?string $name,
): LengthAwarePaginator {
$query = AutomatedReportResult::query()
->whereNotNull('automated_report_results.generated_at')
->join('automated_reports', 'automated_report_results.report_id', '=', 'automated_reports.id')
->where('automated_reports.team_id', $user->getTeamId())
->whereJsonContains('automated_reports.recipients->users', $user->getId())
->orderByRaw("$sort->value COLLATE utf8mb4_unicode_ci {$sortDirection->value}")
->select('automated_report_results.*')
->with('report.team');
if ($fromDate !== null && $toDate !== null) {
$query->whereBetween('generated_at', [$fromDate, $toDate]);
}
if (! empty($teamIds)) {
$query->where(function ($q) use ($teamIds) {
foreach ($teamIds as $id) {
$q->orWhereJsonContains('automated_reports.groups', $id);
}
});
}
if (! empty($reportTypes)) {
$query->whereIn('automated_reports.type', $reportTypes);
}
if (! empty($name)) {
$query->whereLike('name', "%$name%");
}
return $query->paginate($resultsPerPage, ['*'], 'page', $page);
}
public function countUserReports(User $user): int
{
return AutomatedReportResult::query()
->whereNotNull('generated_at')
->whereNotNull('sent_at')
->whereHas('report', function ($q) use ($user) {
$q->where('team_id', $user->getTeamId())
->whereJsonContains('recipients->users', $user->getId());
})
->count();
}
/**
* Get report IDs for a specific team
*
* @param Team $team
*
* @return \Illuminate\Support\Collection
*/
public function getReportIdsByTeam(Team $team): \Illuminate\Support\Collection
{
return AutomatedReport::where('team_id', $team->getId())->pluck('id');
}
/**
* Get all reports for a specific team
*
* @param Team $team
*
* @return Collection
*/
public function getReportsByTeam(Team $team): Collection
{
return AutomatedReport::where('team_id', $team->getId())->get();
}
/**
* Get all report results for a specific report
*
* @param AutomatedReport $report
*
* @return Collection
*/
public function getResultsByReport(AutomatedReport $report): Collection
{
return $this->getResultsByReportQuery($report)->get();
}
public function getResultsByReportQuery(AutomatedReport $report): Builder
{
return AutomatedReportResult::where('report_id', $report->getId());
}
public function getReportResultsQueryForRetention(Team $team, CarbonImmutable $retentionDate): Builder
{
$reportIds = $this->getReportIdsByTeam($team);
return AutomatedReportResult::query()->whereIn('report_id', $reportIds)
->whereRaw('IFNULL(generated_at, created_at) <= ?', [$retentionDate]);
}
/**
* @param int|null $teamId Optional team ID to filter results
*
* @return \Illuminate\Support\Collection<int, int> Collection of team IDs
*/
public function getTeamIdsWithReportsResults(?int $teamId = null): \Illuminate\Support\Collection
{
$query = DB::table('automated_reports')
->join('teams', 'automated_reports.team_id', '=', 'teams.id')
->select('teams.id')
->distinct();
if ($teamId !== null) {
$query->where('teams.id', $teamId);
}
return $query->pluck('teams.id');
}
}
Execute
Explain Plan
Browse Query History
View Parameters
Open Query Execution Settings…
In-Editor Results
Tx: Auto
Cancel Running Statements
Playground
jiminny
Sync Changes
Hide This Notification
Code changed:
Hide
16
13
13
Previous Highlighted Error
Next Highlighted Error
SELECT * FROM teams WHERE id = 1;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;
SELECT * FROM crm_fields WHERE id = 2234;
SELECT * FROM crm_field_values WHERE crm_field_id = 2234;
select * from crm_profiles where user_id = 143;
select * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO
select * from business_processes where crm_configuration_id = 39;
# 01941000000H669AAC, 01941000000H66JAAS
select * from record_type_field_values
where record_type_id IN (24);
select * from crm_field_values where id IN (2730);
select * from crm_configurations where id = 39;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce'; #1035
select * from users where team_id = 1; # 222 group 3
SELECT * FROM activities WHERE user_id = 222 order by id desc;
select * from sidekick_settings where team_id = 1;
select * from teams where id = 1;
select * from team_features where team_id = 1;
select * from activities where crm_configuration_id = 2
and provider = 'ms-teams' and id = 608765;
SELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';
select * from sidekick_settings where team_id = 2;
SELECT * FROM activities WHERE id = 608660;
select * from activity_summary_logs where activity_id = 608660;
select * from ai_prompts where transcription_id = 11214;
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;
# id: 608818, crm: 59628809737
SELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;
# id: 608821, crm: 59632069252
SELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,
playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,
scheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at
FROM activities a
join calendar_events ce on a.calendar_event_id = ce.id
WHERE a.id IN (608818, 608821);
select * from users where team_id = 1;
select * from team_settings where team_id = 1;
select * from crm_profiles where crm_configuration_id = 39 order by user_id;
select * from team_features where team_id = 1;
select * from users where team_id = 2;
SELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639
# Preslava N. Ivanova, grou id 3
SELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;
select * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';
select
a.id,
a.type,
a.scheduled_start_time,
a.actual_start_time,
a.created_at,
a.opportunity_id,
a.status
FROM activities a
WHERE opportunity_id = 344
and status IN ('completed', 'received', 'delivered')
and (
(a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))
;
SELECT * FROM users WHERE id = 222;
SELECT * FROM crm_profiles WHERE user_id = 222;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;
select * from group_deal_risk_types;
select * from opportunities where team_id = 1;
SELECT * FROM opportunities WHERE id = 315;
SELECT * FROM crm_field_data WHERE object_id = 315;
select * from crm_field_data where object_id = 260;
select * from generic_ai_prompts where subject_id = 315;
select * from teams; # 36, 21, 121, [EMAIL]
SELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';
# [PASSWORD_DOTS]
select * from teams where id = 1;
select * from crm_configurations where id = 39;
select * from users where team_id = 1;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 1;
# 1 - 00541000004281rAAA
# 204 - 0052g000003freeAAA
# 429 - 0052g000003qGOiAAM
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
select * from activities where type = 'softphone'
and created_at > '2024-12-11 15:24:36' order by id desc;
select * from activity_providers where team_id = 1;
select * from activity_provider_users where activity_provider_id = 328;
select * from opportunities where crm_configuration_id = 39
AND account_id = 178 AND is_closed = false
order by created_at DESC;
select * from contacts where id = 3952;
select * from accounts where id = 178;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations where id = 21;
select * from users where team_id = 36;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 36
and sa.provider = 'bullhorn';
select * from social_accounts where id = 348;
UPDATE social_accounts SET
provider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',
provider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',
expires = 1733998131,
state = 'connected'
WHERE id = 348;
# [PASSWORD_DOTS]
select * from teams where id = 31;
select * from crm_configurations where id = 18;
select * from users where team_id = 31; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 31;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 31
and sa.provider = 'close';
select * from contacts where crm_configuration_id = 18;
# [PASSWORD_DOTS] NEPTUNE [PASSWORD_DOTS]
select * from teams;
select * from users where id IN (1030, 1035, 1052);
select * from crm_configurations;
select * from users where team_id = 65; # 257
select * from team_settings where team_id = 65; # 257
select * from invitations where team_id = 65; # 257
select * from users where email = '[EMAIL]'; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 65;
select * from crm_configurations where id = 53;
select * from accounts where crm_configuration_id = 53 order by id desc;
select * from leads where crm_configuration_id = 53 order by id desc;
select * from contacts where crm_configuration_id = 53 order by id desc;
select * from opportunities where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 53 order by id desc;
select * from crm_fields where crm_configuration_id = 53 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 53 order by id desc;
select * from stages where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 13;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
and sa.provider = 'integration-app';
select * from contacts where crm_configuration_id = 13;
select * from social_accounts where sociable_id = 283;
SELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';
select * from activity_providers where team_id = 65;
SELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
;
# [PASSWORD_DOTS] STAGING [PASSWORD_DOTS]
SELECT * FROM teams;
SELECT * FROM teams WHERE id = 88;
SELECT * FROM teams WHERE id = 89;
select * from team_settings where team_id = 89;
SELECT * FROM users WHERE team_id = 89;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 89;
select * from users;
SELECT * FROM social_accounts WHERE sociable_id = 1761;
SELECT * FROM crm_configurations WHERE id = 70;
select * from accounts where crm_configuration_id = 70 order by id desc;
select * from leads where crm_configuration_id = 70 order by id desc;
select * from contacts where crm_configuration_id = 70 order by id desc;
select * from opportunities where crm_configuration_id = 70 order by id desc;
select * from crm_profiles where crm_configuration_id = 70 order by id desc;
select * from crm_fields where crm_configuration_id = 70 order by id desc;
select * from crm_field_values where crm_field_id = 3536 order by id desc;
select * from crm_layouts where crm_configuration_id = 70 order by id desc;
select * from stages where crm_configuration_id = 70 order by id desc;
select * from business_processes where crm_configuration_id = 70 order by id desc;
select * from business_process_stages where business_process_id = 34;
select * from contacts where id = 10468;
select * from crm_layouts where crm_configuration_id = 70;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;
SELECT * FROM crm_fields WHERE id IN (3533,3534,3535);
select * from activities where crm_configuration_id = 70
and (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;
SELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;
SELECT * FROM activities where crm_configuration_id = 69 ;
SELECT * FROM users WHERE email LIKE '%[EMAIL]%';
SELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;
SELECT * FROM opportunities WHERE id = 385;
select * from participants p
join activities a on p.activity_id = a.id
where a.crm_configuration_id = 70
and (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);
SELECT * FROM participants WHERE id = 1013638;
select * from teams where id = 90;
select * from users where team_id = 90;
select * from social_accounts where social_accounts.sociable_id IN (1960,1760);
SELECT * FROM crm_profiles WHERE crm_configuration_id = 71;
select * from invitations where team_id = 90;
select * from crm_configurations where id = 71;
select * from accounts where crm_configuration_id = 71 order by id desc;
select * from leads where crm_configuration_id = 71 order by id desc;
select * from contacts where crm_configuration_id = 71 order by id desc;
select * from opportunities where crm_configuration_id = 71 order by id desc;
select * from crm_profiles where crm_configuration_id = 71 order by id desc;
select * from crm_fields where crm_configuration_id = 71 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 71 order by id desc;
select * from stages where crm_configuration_id = 71 order by id desc;
select * from users order by secondary_email desc;
select u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa
join users u on sa.sociable_id = u.id
where sa.provider = 'google' and u.email LIKE 'aneliya%';
select * from failed_jobs order by id desc;
select * from users where email = '[EMAIL]' or secondary_email = '[EMAIL]';
select * from teams;
SELECT * FROM crm_profiles WHERE crm_configuration_id = 39;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;
SELECT * FROM crm_configurations WHERE id = 70;
select * from teams where id = 1;
select * from groups where team_id = 1;
select * from users where team_id = 1;
select o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o
join users u on o.user_id = u.id
join groups g on u.group_id = g.id
join role_user ru on u.id = ru.user_id
join roles r on ru.role_id = r.id
where o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';
select * from role_user where user_id = 143;
select * from roles;
select * from role_user;
select * from groups where id = 9;
select * from scope_groups where group_id = 9;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations;
SELECT * FROM social_accounts WHERE sociable_id = 121;
https://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105
https://crmsandbox.zoho.com/crm/
https://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080
https://crm.zoho.com/crm/
org3469620
SELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;
select * from users where email LIKE "%mobile_automation_%";
select * from social_accounts where sociable_id IN (2228);
select * from crm_profiles where user_id IN (2222,2223,2226,2227);
select * from teams order by id desc;
SELECT * FROM users WHERE id = 2229;
SELECT * FROM crm_profiles WHERE user_id = 2229;
select * from opportunities where crm_configuration_id = 88;
select * from crm_fields where crm_configuration_id = 88;
select * from crm_profiles where crm_configuration_id = 88;
SELECT * FROM teams WHERE id = 1;
SELECT * FROM users WHERE id = 143;
SELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;
https://app.staging.jiminny.com/ondemand?
min_duration=1
&
only_recorded=1
&
user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e
&
sequence_number=2
select * from users where team_id = 1 and email like '%stoyan%'
select * from coaching_feedbacks;
select * from teams;
SELECT * FROM users WHERE team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from users where id = 143;
SELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
select * from users where team_id = 2;
select * from activities where crm_configuration_id = 39
and activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'
AND user_id = 143
order by id desc;
# [PASSWORD_DOTS]
select * from teams where id = 142; # 2312, 126
select * from team_settings;
select * from users where team_id = 142; # 21642
SELECT * FROM social_accounts WHERE sociable_id = 21642;
SELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;
select * from crm_profiles where id IN (93);
select * from invitations;
select * from team_features where team_id = 1;
SELECT * FROM crm_configurations WHERE id = 126;
select * from accounts where crm_configuration_id = 126 order by id desc;
select * from leads where crm_configuration_id = 126 order by id desc;
select * from contacts where crm_configuration_id = 126 order by id desc;
select * from opportunities where crm_configuration_id = 126 order by id desc;
select * from crm_profiles where crm_configuration_id = 126 order by id desc;
select * from crm_fields where crm_configuration_id = 126 # 11060
# and type IN ('picklist', 'status')
# and object_type = 'task'
order by id desc;
# 5731,5732,5733
select DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;
select * from crm_layouts where crm_configuration_id = 126 order by id desc;
SELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);
select * from stages where crm_configuration_id = 126 order by id desc;
select * from business_processes where crm_configuration_id = 126 order by id desc;
select * from business_process_stages where business_process_id IN (76,75,74,73);
select * from playbooks where team_id = 142;
select * from playbook_layouts where playbook_id IN (108);
SELECT * FROM playbook_categories WHERE playbook_id IN (108);
select * from teams where id = 130;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 2
and sa.provider = 'hubspot';
SELECT * FROM activities
WHERE crm_configuration_id = 110;
select * from teams;
select * from crm_configurations;
SELECT * FROM activities WHERE id = 628773;
SELECT * FROM crm_profiles WHERE user_id = 1460;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from teams;
select ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id
join permission_role pr on pr.role_id = ru.role_id
join permissions p on p.id = pr.permission_id
where team_id = 495 and p.name IN ('dial');
select * from teams where id = 145;
select * from crm_configurations where id = 129;
select * from social_accounts where sociable_id = 2317;
SELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;
select * from teams where id = 1;
SELECT * FROM crm_layouts WHERE crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;
SELECT * FROM crm_layout_entities WHERE id = 5507;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');
select * from teams;
select * from activities where crm_configuration_id = 14;
SELECT * FROM social_accounts where provider = 'copper';
select * from activities where id = 628467;
select * from participants where activity_id = 628467;
SELECT * FROM contacts WHERE id = 3969;
SELECT * FROM accounts WHERE id = 177;
SELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;
# [PASSWORD_DOTS] BH
select * from teams where id = 36;
SELECT * FROM crm_configurations WHERE id = 21;
select * from activities where crm_configuration_id = 21 and id = 607901;
select * from activities where crm_configuration_id = 21;
select * roles;
select * from permissions;
select * from permission_role where permission_id = 226;
select * from migrations order by id desc;
# mercury
# neptune
# earth
select * from teams;
select * from teams where id = 19;
select * from teams where id = 27;
select * from users where team_id = 27;
SELECT * FROM crm_configurations WHERE id = 42;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from activities where id = 631461;
SELECT * FROM crm_field_values WHERE crm_field_id = 180;
select * from teams where id = 2;
SELECT * FROM social_accounts WHERE sociable_id = 89;
SELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273
select * from activity_summary_logs where activity_id = 634273;
select * from sidekick_settings where team_id = 2;
select * from teams; # 2, 2
SELECT * FROM crm_configurations WHERE team_id = 2; # 2
select * from team_features where team_id = 2;
select * from features;
SELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';
SELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;
select * from automated_reports order by id desc;
select * from automated_report_results order by id desc;
select * from users where team_id = 1 and id IN (7160, 3248);
select * from migrations order by id desc;
SELECT
CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,
u.email,
sa.*,
t.owner_id FROM social_accounts sa
JOIN users u on u.id = sa.sociable_id
JOIN teams t on t.id = u.team_id
WHERE u.team_id = 1 and sa.provider = 'salesforce';
select * from teams where id = 1;
select * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;
select * from groups where id = 565;
select * from playbooks where team_id = 1;
select * from playbooks where id = 175;
select * from playbook_categories where playbook_id = 175;
select * from users where team_id = 1;
select * from users where id = 7160;
select * from crm_profiles where user_id = 7160;
select * from features;
select
*
# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,
# crm_configuration_id, crm_provider_id, transcription_id, status
from activities where crm_configuration_id = 1 and type = 'conference'
# and crm_provider_id IS NOT NULL
and provider != 'uploader' and actual_start_time IS NOT NULL
ORDER by id desc;
select * from activities where id = 54747783; # 00UO400000pCzojMAC
select p.id, p.activity_type, pc.id, pc.name
FROM playbooks p
join playbook_categories pc on p.id = pc.playbook_id
where p.team_id = 1 and p.activity_type = 'event';
SELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';
SELECT * FROM crm_field_values WHERE crm_field_id = 4;
select * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id
where crm_configuration_id = 1 and pl.playbook_id = 175;
select * from teams;
SELECT r.* FROM automated_reports r
join teams t on r.team_id = t.id
WHERE r.frequency = 'daily'
and r.status = 1
AND t.status = 'active'
AND (r.expires_at >= now() OR r.expires_at IS NULL);
select * from automated_report_results where report_id IN (18, 33);
select * from automated_reports;
select * from automated_report_results where report_id IN (34, 35);
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
NULL
|
|
10551
|
211
|
0
|
2026-04-14T08:47:47.221095+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776156467221_m2.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
PhpStormFileEditViewNavigateCodeLaravelRefactorToo PhpStormFileEditViewNavigateCodeLaravelRefactorToolsWindowHelpFV faVsco.s v#11894 on JY-18909-automated-reports-ask-jiminny k ~Project v© ReportController.php© JiminnyDebugCommand.phpO dev.jsonAulomaleakeporissendcommand.onoC AutomatedReportsCommand.php= ids.txtAutomatedReportsRepository.php x© AutomatedReportsService.php= infection.json.distу IгаскrrovldernstalleacventoneM+INS ALL.md544M+INIERNAL WEbOOKS-UP.mo© CreateActivityLoqgedEvent.phpC UserPilotActivityListener.php© ActivityLogged.php545Ejiminny_storage546(e AutomatedRenortscalllbackService.onvM+ licenses.md© RequestGenerateAskJiminnyReportJob.php547M MakefileRequestGenerateReportJob.php© AutomatedReportResult.php548Opackage-lock.json1547(C) AutomatedReport.php= phpstan.neon.dist550class Auronarecreoortskerostorv= phpstan-baseline.neonA13 X4 A V551< phpunit.xmloparall ser ane osor cco conlnThe column to sort by.Allowed values: 'C552Teraw_sql_query.sqlOparam string $sortDirection The sort direction.Allowed values:'asc'553MeR-ADME.mo554sonar-project.propertiesOreturn Collection<AutomatedReport>555= test.py5564> Untited Diagram.Xmisages557us vetur.confia.isilic function getAllStandardReports(M+ WEBHOOK_FILTERING_IMPLEMEIstring $sortColumn ='created_at',559› Ih External Librariessarino osorturecmion = 'oesc'1S00E® Scratches and ConsolesLoLecron "...h561v D Database Consoles562A EU563> A jiminny@localhostRetrieve all Ask Liminny reports created by the given user.-564dPROD565A QAOparam User$userThe user whose reports to retrieve.566 vOparam string $sortColumnThe column to sort by. Allowed values: 'C5674 QAI PROD@param string $sortDirection The sort direction. Allowed values:'ast" 568V L STAGING& console slAGiNgdrecurh coclection<aucomacedкeport.A console_1 [STAGING]A uranus [STAGING]= custom.log= laravel.logA SF ljiminny@localhost]4 HS_local [jiminny@localhost]Al console [PROD]console EUconsole SlAGiNGAskJiminnykeportAcuivilyservice.ono© RequestGenerateAskJiminnyReportJobTest.phpIx. AUto VFlaycroundvMal iminny v016 A13 Х13 ^select p.id, p.activity_type, pc.id, pc.nameFROM playbooks pjoin playbook_categories pc"o>lan: on p.1d = pc.playdooK_10wnere p.ceam_1d = 1 and p.acuivity_type = 'event":ISELECT * FROM crm fields WHERE crm confiquration id = 1 and obiect tvoe = 'event':SELECT * FROM crm_field_values WHERE crm_field_id = 4;select * from crm_layouts cl join playbook_layouts pl 1<->1.n: on cl.id = pl.layout_idwhere crm_configuration_id = 1 and pl.playbook_id = 175;select * from teams;SELECT r.* FROM automated_reports rjoin teams t on r.team.id = t.idWHERE r.freguensy = 'daily'and r.status = 1ANU T.status = acmve"DATMU(r. exRicesuat >= now() OR r.exeicesnat IS NULL);select * from automated_report_results where ceRentaid IN (18, 33);Services+oe|×~ D DatabaseV dEUA consolev djiminny@localhostansocall4 SFV A PRODconsoleV A STAGINGs console s sulms& DockerOutputliii jiminny.automated reports X35 rows yIx. Auleytages15I recipients Y{"users": [3248,23559]}{"users": [3248,23559]}{"users" : [7160,23309]}{"users" : [10633]}{"users": [10633]}{"users": [10633]}{"users" : [10633]}{"users" : []}{"users": []}{"users" : []}{"users" : [10633]}{"users" : [10633]}{"users": [10633]}{"users": [10633]}{"users" : [10633, 7160]}^"Users":| 10055.1409 16{"users" : [10633]}• jiminny_recipients Y<null>snull><null>{"users": [23525]}{"users":[11985]}{"users": []}{"users": [11985]}{"users": []}{"users":[11985]}{"users": []}{"users": [10633]}<null><null><null>snullshuld<null>select * from alselect * ff accounts (jiminny)select * ff activities (jiminny)f ai_prompts (jiminny)f activity_providers (jiminny)# activity_summary_logs (jiminny)ii team_features (jiminny)acmu ava conury nocn camions a iz 00vw accvity_coacn_requests ytmanny,i activity_comments (jiminny)# activity_export_logs (jiminny)f activity_export_tokens (jiminny)НН AАФ4и4+ИAUnAИtА (ітіИИІSTAGINGSTAGINGSTAGINGSTAGINGALSUMGS AGUNE•AOILNE•AOILNESIAULNGSTAGINGSTAGINGСТАСТИЕPress ^. to choose the selected (or first) suggestion and insert a dot afterwards Next Tip<null>Test 6<null>Test 5<null>Ask Jiminny test reportShared with groupWeekly report - disable Automated Reports flag<null>Jiminny recipientRecipientJiminny RecipientCreator - Mobile userJiminny Mobile<null><null><null><null>ShULD<null>cxoures un- o AortuExpires on - 5 AprilExpires On - 4 AprilExpires on - 3 aprilexolres un- 2 aprilY - expires on - 1 aprilWindsurf changelog 2.12.21: A new version is available. // View Changelog (today 10:33)j Support Daily • in 3 h 13 mA100% [Tue 14 Apr 11:47:47RequestGenerateAskJiminnyReportJobTest vCascadeFixing ReportControlleAutomated Report FaiiN ohulomaLeunevot tscollallus oheadd additional parameter report id and if provider then instead ofreports by frequency it takes the report by id or uuid.Add checks for status, team activity andoiel stull useu lor curymg. uns Iwi ve usee only mllanudlly sou mele shote ve mio l not duptlcadle baseu onlwstandara searenLet me read the command and related files first.reao Auloma lecreoorscommanc,ono anopAuloalecreoorsredosilorv.ono ›Now let me check the AutonatedReoort model tor relevanttielas:exptoreu nulomdieunevortone dnl sedicheu geloytus getTeam expires_at getFrequency getType STATUS_is... ›Now.nave everytnine.neeo. Lerme imolement tne changes.• AutomatedReportsCommand.php+78 -2Also need to check if findByUuid handles soft-deleted — it doesn't, so for UUID lookup we need withTrashed too.Let me tix thatAutomatedReportsCommand.php+1 -1Done. Here's what was added:Changes SummaryNew option: —report-id= — accepts either a numeric ID or a UUID.processsing lekeportl, — oypasses treouency logie entirely.• Looks up by ID (AutomatedReport: :withTrashed()->find() ) or UUID (also withTrashed so even deletedreports can be triggered manually)• Calls warnIfNotApplicableForSchedule() for informational output• Dispatches the job the same way as the scheduled pathwarnIfNotApplicableForSchedule() - mirrors every condition from getActiveReportsByFrequency() and theke ectalAccept allAdd findByldOrUuidt "codeClaude Sonnet 4.6CSVv• 8,Mactivity_search_id YIask anvthing promot id YI expires_at Y1093210933269120s 7070-04-1762 2026-04-1862 2026-04-30ShuLeo shull<nULEchuue chuu<null><null><null> <null><null> <null>ShULlshuceo shulu<null><null><null> <null><null> <null>SnUL>38114SNULD SnULL09 4040-04-003811458 2026-04-0558 2026-94-94J0110728713811453 2026-04-0350 2026-04-0255 2026-04-01W Windsurf Teams565:16UTF-84 spaces...
|
NULL
|
-8155013322295269362
|
NULL
|
visual_change
|
ocr
|
NULL
|
PhpStormFileEditViewNavigateCodeLaravelRefactorToo PhpStormFileEditViewNavigateCodeLaravelRefactorToolsWindowHelpFV faVsco.s v#11894 on JY-18909-automated-reports-ask-jiminny k ~Project v© ReportController.php© JiminnyDebugCommand.phpO dev.jsonAulomaleakeporissendcommand.onoC AutomatedReportsCommand.php= ids.txtAutomatedReportsRepository.php x© AutomatedReportsService.php= infection.json.distу IгаскrrovldernstalleacventoneM+INS ALL.md544M+INIERNAL WEbOOKS-UP.mo© CreateActivityLoqgedEvent.phpC UserPilotActivityListener.php© ActivityLogged.php545Ejiminny_storage546(e AutomatedRenortscalllbackService.onvM+ licenses.md© RequestGenerateAskJiminnyReportJob.php547M MakefileRequestGenerateReportJob.php© AutomatedReportResult.php548Opackage-lock.json1547(C) AutomatedReport.php= phpstan.neon.dist550class Auronarecreoortskerostorv= phpstan-baseline.neonA13 X4 A V551< phpunit.xmloparall ser ane osor cco conlnThe column to sort by.Allowed values: 'C552Teraw_sql_query.sqlOparam string $sortDirection The sort direction.Allowed values:'asc'553MeR-ADME.mo554sonar-project.propertiesOreturn Collection<AutomatedReport>555= test.py5564> Untited Diagram.Xmisages557us vetur.confia.isilic function getAllStandardReports(M+ WEBHOOK_FILTERING_IMPLEMEIstring $sortColumn ='created_at',559› Ih External Librariessarino osorturecmion = 'oesc'1S00E® Scratches and ConsolesLoLecron "...h561v D Database Consoles562A EU563> A jiminny@localhostRetrieve all Ask Liminny reports created by the given user.-564dPROD565A QAOparam User$userThe user whose reports to retrieve.566 vOparam string $sortColumnThe column to sort by. Allowed values: 'C5674 QAI PROD@param string $sortDirection The sort direction. Allowed values:'ast" 568V L STAGING& console slAGiNgdrecurh coclection<aucomacedкeport.A console_1 [STAGING]A uranus [STAGING]= custom.log= laravel.logA SF ljiminny@localhost]4 HS_local [jiminny@localhost]Al console [PROD]console EUconsole SlAGiNGAskJiminnykeportAcuivilyservice.ono© RequestGenerateAskJiminnyReportJobTest.phpIx. AUto VFlaycroundvMal iminny v016 A13 Х13 ^select p.id, p.activity_type, pc.id, pc.nameFROM playbooks pjoin playbook_categories pc"o>lan: on p.1d = pc.playdooK_10wnere p.ceam_1d = 1 and p.acuivity_type = 'event":ISELECT * FROM crm fields WHERE crm confiquration id = 1 and obiect tvoe = 'event':SELECT * FROM crm_field_values WHERE crm_field_id = 4;select * from crm_layouts cl join playbook_layouts pl 1<->1.n: on cl.id = pl.layout_idwhere crm_configuration_id = 1 and pl.playbook_id = 175;select * from teams;SELECT r.* FROM automated_reports rjoin teams t on r.team.id = t.idWHERE r.freguensy = 'daily'and r.status = 1ANU T.status = acmve"DATMU(r. exRicesuat >= now() OR r.exeicesnat IS NULL);select * from automated_report_results where ceRentaid IN (18, 33);Services+oe|×~ D DatabaseV dEUA consolev djiminny@localhostansocall4 SFV A PRODconsoleV A STAGINGs console s sulms& DockerOutputliii jiminny.automated reports X35 rows yIx. Auleytages15I recipients Y{"users": [3248,23559]}{"users": [3248,23559]}{"users" : [7160,23309]}{"users" : [10633]}{"users": [10633]}{"users": [10633]}{"users" : [10633]}{"users" : []}{"users": []}{"users" : []}{"users" : [10633]}{"users" : [10633]}{"users": [10633]}{"users": [10633]}{"users" : [10633, 7160]}^"Users":| 10055.1409 16{"users" : [10633]}• jiminny_recipients Y<null>snull><null>{"users": [23525]}{"users":[11985]}{"users": []}{"users": [11985]}{"users": []}{"users":[11985]}{"users": []}{"users": [10633]}<null><null><null>snullshuld<null>select * from alselect * ff accounts (jiminny)select * ff activities (jiminny)f ai_prompts (jiminny)f activity_providers (jiminny)# activity_summary_logs (jiminny)ii team_features (jiminny)acmu ava conury nocn camions a iz 00vw accvity_coacn_requests ytmanny,i activity_comments (jiminny)# activity_export_logs (jiminny)f activity_export_tokens (jiminny)НН AАФ4и4+ИAUnAИtА (ітіИИІSTAGINGSTAGINGSTAGINGSTAGINGALSUMGS AGUNE•AOILNE•AOILNESIAULNGSTAGINGSTAGINGСТАСТИЕPress ^. to choose the selected (or first) suggestion and insert a dot afterwards Next Tip<null>Test 6<null>Test 5<null>Ask Jiminny test reportShared with groupWeekly report - disable Automated Reports flag<null>Jiminny recipientRecipientJiminny RecipientCreator - Mobile userJiminny Mobile<null><null><null><null>ShULD<null>cxoures un- o AortuExpires on - 5 AprilExpires On - 4 AprilExpires on - 3 aprilexolres un- 2 aprilY - expires on - 1 aprilWindsurf changelog 2.12.21: A new version is available. // View Changelog (today 10:33)j Support Daily • in 3 h 13 mA100% [Tue 14 Apr 11:47:47RequestGenerateAskJiminnyReportJobTest vCascadeFixing ReportControlleAutomated Report FaiiN ohulomaLeunevot tscollallus oheadd additional parameter report id and if provider then instead ofreports by frequency it takes the report by id or uuid.Add checks for status, team activity andoiel stull useu lor curymg. uns Iwi ve usee only mllanudlly sou mele shote ve mio l not duptlcadle baseu onlwstandara searenLet me read the command and related files first.reao Auloma lecreoorscommanc,ono anopAuloalecreoorsredosilorv.ono ›Now let me check the AutonatedReoort model tor relevanttielas:exptoreu nulomdieunevortone dnl sedicheu geloytus getTeam expires_at getFrequency getType STATUS_is... ›Now.nave everytnine.neeo. Lerme imolement tne changes.• AutomatedReportsCommand.php+78 -2Also need to check if findByUuid handles soft-deleted — it doesn't, so for UUID lookup we need withTrashed too.Let me tix thatAutomatedReportsCommand.php+1 -1Done. Here's what was added:Changes SummaryNew option: —report-id= — accepts either a numeric ID or a UUID.processsing lekeportl, — oypasses treouency logie entirely.• Looks up by ID (AutomatedReport: :withTrashed()->find() ) or UUID (also withTrashed so even deletedreports can be triggered manually)• Calls warnIfNotApplicableForSchedule() for informational output• Dispatches the job the same way as the scheduled pathwarnIfNotApplicableForSchedule() - mirrors every condition from getActiveReportsByFrequency() and theke ectalAccept allAdd findByldOrUuidt "codeClaude Sonnet 4.6CSVv• 8,Mactivity_search_id YIask anvthing promot id YI expires_at Y1093210933269120s 7070-04-1762 2026-04-1862 2026-04-30ShuLeo shull<nULEchuue chuu<null><null><null> <null><null> <null>ShULlshuceo shulu<null><null><null> <null><null> <null>SnUL>38114SNULD SnULL09 4040-04-003811458 2026-04-0558 2026-94-94J0110728713811453 2026-04-0350 2026-04-0255 2026-04-01W Windsurf Teams565:16UTF-84 spaces...
|
10550
|
|
10554
|
210
|
0
|
2026-04-14T08:48:09.649736+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776156489649_m1.jpg...
|
PhpStorm
|
faVsco.js – console [STAGING]
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
13
4
Previous Highlighted Error
Next Highlighted Error
<?php
declare(strict_types=1);
namespace Jiminny\Repositories;
use Carbon\CarbonImmutable;
use Illuminate\Database\Eloquent\Builder;
use Illuminate\Support\Carbon;
use Illuminate\Database\Eloquent\Collection;
use Illuminate\Pagination\LengthAwarePaginator;
use Illuminate\Support\Facades\DB;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\AutomatedReportResult;
use Jiminny\Models\Team;
use Jiminny\Models\User;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Jiminny\Services\Kiosk\AutomatedReports\ReportSort;
use Jiminny\Services\Kiosk\AutomatedReports\ReportSortDirection;
class AutomatedReportsRepository
{
/**
* Create a new automated report
*
* @param array $data
*
* @return AutomatedReport
*/
public function create(array $data): AutomatedReport
{
return AutomatedReport::create($data);
}
/**
* Find an automated report by UUID
*
* @param string $uuid
*
* @return AutomatedReport|null
*/
public function findByUuid(string $uuid): ?AutomatedReport
{
return AutomatedReport::where('uuid', AutomatedReport::toOptimized($uuid))->first();
}
/**
* Retrieve all standard (non-Ask Jiminny) automated reports.
*
* @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.
* @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.
*
* @return Collection<AutomatedReport>
*/
public function getAllStandardReports(
string $sortColumn = 'created_at',
string $sortDirection = 'desc'
): Collection {
return $this->buildSortedQuery($sortColumn, $sortDirection)
->whereNot('type', AutomatedReportsService::TYPE_ASK_JIMINNY)
->get();
}
/**
* Retrieve all Ask Jiminny reports created by the given user.
*
* @param User $user The user whose reports to retrieve.
* @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.
* @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.
*
* @return Collection<AutomatedReport>
*/
public function getAskJiminnyReportsByUser(
User $user,
string $sortColumn = 'created_at',
string $sortDirection = 'desc'
): Collection {
return $this->buildSortedQuery($sortColumn, $sortDirection)
->where('type', AutomatedReportsService::TYPE_ASK_JIMINNY)
->where('created_by', $user->getId())
->get();
}
private function buildSortedQuery(string $sortColumn, string $sortDirection): \Illuminate\Database\Eloquent\Builder
{
$allowedColumns = ['created_by', 'created_at'];
if (! in_array($sortColumn, $allowedColumns)) {
$sortColumn = 'created_at';
}
$sortDirection = strtolower($sortDirection) === 'asc' ? 'asc' : 'desc';
$query = AutomatedReport::query()->with(['creator', 'team']);
if ($sortColumn === 'created_by') {
$query->leftJoin('users', 'users.id', '=', 'automated_reports.created_by')
->orderByRaw("users.name COLLATE utf8mb4_unicode_ci {$sortDirection}")
->select('automated_reports.*');
} else {
$query->orderBy($sortColumn, $sortDirection);
}
return $query;
}
/**
* Get all active and enabled reports with active teams for the specified frequency.
*
* @param string $frequency
*
* @return Collection<AutomatedReport>
*/
public function getActiveReportsByFrequency(string $frequency): Collection
{
return AutomatedReport::where('automated_reports.status', true)
->where('automated_reports.frequency', $frequency)
->join('teams', 'automated_reports.team_id', '=', 'teams.id')
->where('teams.status', Team::STATUS_ACTIVE)
->where(function ($query) {
$query->whereNull('automated_reports.expires_at')
->orWhere('automated_reports.expires_at', '>=', now()->toDateString());
})
->select('automated_reports.*')
->get();
}
/**
* Update an automated report
*
* @param AutomatedReport $report
* @param array $data
*
* @return AutomatedReport
*/
public function update(AutomatedReport $report, array $data): AutomatedReport
{
$report->update($data);
return $report;
}
/**
* Create a new automated report result.
*
* @param array $data The data to create the automated report result with.
*
* @return AutomatedReportResult The newly created automated report result.
*/
public function createResult(array $data): AutomatedReportResult
{
return AutomatedReportResult::create($data);
}
/**
* Find an automated report result by UUID.
*
* @param string $uuid The UUID to find the automated report result with.
*
* @return AutomatedReportResult|null The automated report result if found, otherwise null.
*/
public function findResultByUuid(string $uuid): ?AutomatedReportResult
{
return AutomatedReportResult::where('uuid', AutomatedReportResult::toOptimized($uuid))->first();
}
public function findResultByUuidForUser(string $uuid, User $user): ?AutomatedReportResult
{
return AutomatedReportResult::query()
->where('uuid', AutomatedReportResult::toOptimized($uuid))
->whereHas('report', static function ($query) use ($user): void {
$query->where('team_id', $user->getTeamId())
->where('created_by', $user->getId());
})
->first();
}
public function findChildResult(AutomatedReportResult $result, string $type): ?AutomatedReportResult
{
return AutomatedReportResult::query()
->where('parent_id', $result->getId())
->where('media_type', $type)
->first();
}
public function getGeneratedNotSentResults(): Collection
{
return AutomatedReportResult::query()
->whereNotNull('generated_at')
->whereNull('sent_at')
->where('status', AutomatedReportResult::STATUS_GENERATED)
->whereHas('report')
->with('report')
->get();
}
public function getPaginatedUserReports(
User $user,
ReportSort $sort,
ReportSortDirection $sortDirection,
int $resultsPerPage,
int $page,
?Carbon $fromDate,
?Carbon $toDate,
array $teamIds,
array $reportTypes,
?string $name,
): LengthAwarePaginator {
$query = AutomatedReportResult::query()
->whereNotNull('automated_report_results.generated_at')
->join('automated_reports', 'automated_report_results.report_id', '=', 'automated_reports.id')
->where('automated_reports.team_id', $user->getTeamId())
->whereJsonContains('automated_reports.recipients->users', $user->getId())
->orderByRaw("$sort->value COLLATE utf8mb4_unicode_ci {$sortDirection->value}")
->select('automated_report_results.*')
->with('report.team');
if ($fromDate !== null && $toDate !== null) {
$query->whereBetween('generated_at', [$fromDate, $toDate]);
}
if (! empty($teamIds)) {
$query->where(function ($q) use ($teamIds) {
foreach ($teamIds as $id) {
$q->orWhereJsonContains('automated_reports.groups', $id);
}
});
}
if (! empty($reportTypes)) {
$query->whereIn('automated_reports.type', $reportTypes);
}
if (! empty($name)) {
$query->whereLike('name', "%$name%");
}
return $query->paginate($resultsPerPage, ['*'], 'page', $page);
}
public function countUserReports(User $user): int
{
return AutomatedReportResult::query()
->whereNotNull('generated_at')
->whereNotNull('sent_at')
->whereHas('report', function ($q) use ($user) {
$q->where('team_id', $user->getTeamId())
->whereJsonContains('recipients->users', $user->getId());
})
->count();
}
/**
* Get report IDs for a specific team
*
* @param Team $team
*
* @return \Illuminate\Support\Collection
*/
public function getReportIdsByTeam(Team $team): \Illuminate\Support\Collection
{
return AutomatedReport::where('team_id', $team->getId())->pluck('id');
}
/**
* Get all reports for a specific team
*
* @param Team $team
*
* @return Collection
*/
public function getReportsByTeam(Team $team): Collection
{
return AutomatedReport::where('team_id', $team->getId())->get();
}
/**
* Get all report results for a specific report
*
* @param AutomatedReport $report
*
* @return Collection
*/
public function getResultsByReport(AutomatedReport $report): Collection
{
return $this->getResultsByReportQuery($report)->get();
}
public function getResultsByReportQuery(AutomatedReport $report): Builder
{
return AutomatedReportResult::where('report_id', $report->getId());
}
public function getReportResultsQueryForRetention(Team $team, CarbonImmutable $retentionDate): Builder
{
$reportIds = $this->getReportIdsByTeam($team);
return AutomatedReportResult::query()->whereIn('report_id', $reportIds)
->whereRaw('IFNULL(generated_at, created_at) <= ?', [$retentionDate]);
}
/**
* @param int|null $teamId Optional team ID to filter results
*
* @return \Illuminate\Support\Collection<int, int> Collection of team IDs
*/
public function getTeamIdsWithReportsResults(?int $teamId = null): \Illuminate\Support\Collection
{
$query = DB::table('automated_reports')
->join('teams', 'automated_reports.team_id', '=', 'teams.id')
->select('teams.id')
->distinct();
if ($teamId !== null) {
$query->where('teams.id', $teamId);
}
return $query->pluck('teams.id');
}
}
Execute
Explain Plan
Browse Query History
View Parameters
Open Query Execution Settings…
In-Editor Results
Tx: Auto
Cancel Running Statements
Playground
jiminny
Sync Changes
Hide This Notification
Code changed:
Hide
16
13
13
Previous Highlighted Error
Next Highlighted Error
SELECT * FROM teams WHERE id = 1;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;
SELECT * FROM crm_fields WHERE id = 2234;
SELECT * FROM crm_field_values WHERE crm_field_id = 2234;
select * from crm_profiles where user_id = 143;
select * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO
select * from business_processes where crm_configuration_id = 39;
# 01941000000H669AAC, 01941000000H66JAAS
select * from record_type_field_values
where record_type_id IN (24);
select * from crm_field_values where id IN (2730);
select * from crm_configurations where id = 39;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce'; #1035
select * from users where team_id = 1; # 222 group 3
SELECT * FROM activities WHERE user_id = 222 order by id desc;
select * from sidekick_settings where team_id = 1;
select * from teams where id = 1;
select * from team_features where team_id = 1;
select * from activities where crm_configuration_id = 2
and provider = 'ms-teams' and id = 608765;
SELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';
select * from sidekick_settings where team_id = 2;
SELECT * FROM activities WHERE id = 608660;
select * from activity_summary_logs where activity_id = 608660;
select * from ai_prompts where transcription_id = 11214;
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;
# id: 608818, crm: 59628809737
SELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;
# id: 608821, crm: 59632069252
SELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,
playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,
scheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at
FROM activities a
join calendar_events ce on a.calendar_event_id = ce.id
WHERE a.id IN (608818, 608821);
select * from users where team_id = 1;
select * from team_settings where team_id = 1;
select * from crm_profiles where crm_configuration_id = 39 order by user_id;
select * from team_features where team_id = 1;
select * from users where team_id = 2;
SELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639
# Preslava N. Ivanova, grou id 3
SELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;
select * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';
select
a.id,
a.type,
a.scheduled_start_time,
a.actual_start_time,
a.created_at,
a.opportunity_id,
a.status
FROM activities a
WHERE opportunity_id = 344
and status IN ('completed', 'received', 'delivered')
and (
(a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))
;
SELECT * FROM users WHERE id = 222;
SELECT * FROM crm_profiles WHERE user_id = 222;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;
select * from group_deal_risk_types;
select * from opportunities where team_id = 1;
SELECT * FROM opportunities WHERE id = 315;
SELECT * FROM crm_field_data WHERE object_id = 315;
select * from crm_field_data where object_id = 260;
select * from generic_ai_prompts where subject_id = 315;
select * from teams; # 36, 21, 121, [EMAIL]
SELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';
# [PASSWORD_DOTS]
select * from teams where id = 1;
select * from crm_configurations where id = 39;
select * from users where team_id = 1;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 1;
# 1 - 00541000004281rAAA
# 204 - 0052g000003freeAAA
# 429 - 0052g000003qGOiAAM
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
select * from activities where type = 'softphone'
and created_at > '2024-12-11 15:24:36' order by id desc;
select * from activity_providers where team_id = 1;
select * from activity_provider_users where activity_provider_id = 328;
select * from opportunities where crm_configuration_id = 39
AND account_id = 178 AND is_closed = false
order by created_at DESC;
select * from contacts where id = 3952;
select * from accounts where id = 178;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations where id = 21;
select * from users where team_id = 36;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 36
and sa.provider = 'bullhorn';
select * from social_accounts where id = 348;
UPDATE social_accounts SET
provider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',
provider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',
expires = 1733998131,
state = 'connected'
WHERE id = 348;
# [PASSWORD_DOTS]
select * from teams where id = 31;
select * from crm_configurations where id = 18;
select * from users where team_id = 31; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 31;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 31
and sa.provider = 'close';
select * from contacts where crm_configuration_id = 18;
# [PASSWORD_DOTS] NEPTUNE [PASSWORD_DOTS]
select * from teams;
select * from users where id IN (1030, 1035, 1052);
select * from crm_configurations;
select * from users where team_id = 65; # 257
select * from team_settings where team_id = 65; # 257
select * from invitations where team_id = 65; # 257
select * from users where email = '[EMAIL]'; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 65;
select * from crm_configurations where id = 53;
select * from accounts where crm_configuration_id = 53 order by id desc;
select * from leads where crm_configuration_id = 53 order by id desc;
select * from contacts where crm_configuration_id = 53 order by id desc;
select * from opportunities where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 53 order by id desc;
select * from crm_fields where crm_configuration_id = 53 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 53 order by id desc;
select * from stages where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 13;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
and sa.provider = 'integration-app';
select * from contacts where crm_configuration_id = 13;
select * from social_accounts where sociable_id = 283;
SELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';
select * from activity_providers where team_id = 65;
SELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
;
# [PASSWORD_DOTS] STAGING [PASSWORD_DOTS]
SELECT * FROM teams;
SELECT * FROM teams WHERE id = 88;
SELECT * FROM teams WHERE id = 89;
select * from team_settings where team_id = 89;
SELECT * FROM users WHERE team_id = 89;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 89;
select * from users;
SELECT * FROM social_accounts WHERE sociable_id = 1761;
SELECT * FROM crm_configurations WHERE id = 70;
select * from accounts where crm_configuration_id = 70 order by id desc;
select * from leads where crm_configuration_id = 70 order by id desc;
select * from contacts where crm_configuration_id = 70 order by id desc;
select * from opportunities where crm_configuration_id = 70 order by id desc;
select * from crm_profiles where crm_configuration_id = 70 order by id desc;
select * from crm_fields where crm_configuration_id = 70 order by id desc;
select * from crm_field_values where crm_field_id = 3536 order by id desc;
select * from crm_layouts where crm_configuration_id = 70 order by id desc;
select * from stages where crm_configuration_id = 70 order by id desc;
select * from business_processes where crm_configuration_id = 70 order by id desc;
select * from business_process_stages where business_process_id = 34;
select * from contacts where id = 10468;
select * from crm_layouts where crm_configuration_id = 70;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;
SELECT * FROM crm_fields WHERE id IN (3533,3534,3535);
select * from activities where crm_configuration_id = 70
and (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;
SELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;
SELECT * FROM activities where crm_configuration_id = 69 ;
SELECT * FROM users WHERE email LIKE '%[EMAIL]%';
SELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;
SELECT * FROM opportunities WHERE id = 385;
select * from participants p
join activities a on p.activity_id = a.id
where a.crm_configuration_id = 70
and (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);
SELECT * FROM participants WHERE id = 1013638;
select * from teams where id = 90;
select * from users where team_id = 90;
select * from social_accounts where social_accounts.sociable_id IN (1960,1760);
SELECT * FROM crm_profiles WHERE crm_configuration_id = 71;
select * from invitations where team_id = 90;
select * from crm_configurations where id = 71;
select * from accounts where crm_configuration_id = 71 order by id desc;
select * from leads where crm_configuration_id = 71 order by id desc;
select * from contacts where crm_configuration_id = 71 order by id desc;
select * from opportunities where crm_configuration_id = 71 order by id desc;
select * from crm_profiles where crm_configuration_id = 71 order by id desc;
select * from crm_fields where crm_configuration_id = 71 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 71 order by id desc;
select * from stages where crm_configuration_id = 71 order by id desc;
select * from users order by secondary_email desc;
select u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa
join users u on sa.sociable_id = u.id
where sa.provider = 'google' and u.email LIKE 'aneliya%';
select * from failed_jobs order by id desc;
select * from users where email = '[EMAIL]' or secondary_email = '[EMAIL]';
select * from teams;
SELECT * FROM crm_profiles WHERE crm_configuration_id = 39;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;
SELECT * FROM crm_configurations WHERE id = 70;
select * from teams where id = 1;
select * from groups where team_id = 1;
select * from users where team_id = 1;
select o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o
join users u on o.user_id = u.id
join groups g on u.group_id = g.id
join role_user ru on u.id = ru.user_id
join roles r on ru.role_id = r.id
where o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';
select * from role_user where user_id = 143;
select * from roles;
select * from role_user;
select * from groups where id = 9;
select * from scope_groups where group_id = 9;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations;
SELECT * FROM social_accounts WHERE sociable_id = 121;
https://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105
https://crmsandbox.zoho.com/crm/
https://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080
https://crm.zoho.com/crm/
org3469620
SELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;
select * from users where email LIKE "%mobile_automation_%";
select * from social_accounts where sociable_id IN (2228);
select * from crm_profiles where user_id IN (2222,2223,2226,2227);
select * from teams order by id desc;
SELECT * FROM users WHERE id = 2229;
SELECT * FROM crm_profiles WHERE user_id = 2229;
select * from opportunities where crm_configuration_id = 88;
select * from crm_fields where crm_configuration_id = 88;
select * from crm_profiles where crm_configuration_id = 88;
SELECT * FROM teams WHERE id = 1;
SELECT * FROM users WHERE id = 143;
SELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;
https://app.staging.jiminny.com/ondemand?
min_duration=1
&
only_recorded=1
&
user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e
&
sequence_number=2
select * from users where team_id = 1 and email like '%stoyan%'
select * from coaching_feedbacks;
select * from teams;
SELECT * FROM users WHERE team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from users where id = 143;
SELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
select * from users where team_id = 2;
select * from activities where crm_configuration_id = 39
and activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'
AND user_id = 143
order by id desc;
# [PASSWORD_DOTS]
select * from teams where id = 142; # 2312, 126
select * from team_settings;
select * from users where team_id = 142; # 21642
SELECT * FROM social_accounts WHERE sociable_id = 21642;
SELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;
select * from crm_profiles where id IN (93);
select * from invitations;
select * from team_features where team_id = 1;
SELECT * FROM crm_configurations WHERE id = 126;
select * from accounts where crm_configuration_id = 126 order by id desc;
select * from leads where crm_configuration_id = 126 order by id desc;
select * from contacts where crm_configuration_id = 126 order by id desc;
select * from opportunities where crm_configuration_id = 126 order by id desc;
select * from crm_profiles where crm_configuration_id = 126 order by id desc;
select * from crm_fields where crm_configuration_id = 126 # 11060
# and type IN ('picklist', 'status')
# and object_type = 'task'
order by id desc;
# 5731,5732,5733
select DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;
select * from crm_layouts where crm_configuration_id = 126 order by id desc;
SELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);
select * from stages where crm_configuration_id = 126 order by id desc;
select * from business_processes where crm_configuration_id = 126 order by id desc;
select * from business_process_stages where business_process_id IN (76,75,74,73);
select * from playbooks where team_id = 142;
select * from playbook_layouts where playbook_id IN (108);
SELECT * FROM playbook_categories WHERE playbook_id IN (108);
select * from teams where id = 130;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 2
and sa.provider = 'hubspot';
SELECT * FROM activities
WHERE crm_configuration_id = 110;
select * from teams;
select * from crm_configurations;
SELECT * FROM activities WHERE id = 628773;
SELECT * FROM crm_profiles WHERE user_id = 1460;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from teams;
select ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id
join permission_role pr on pr.role_id = ru.role_id
join permissions p on p.id = pr.permission_id
where team_id = 495 and p.name IN ('dial');
select * from teams where id = 145;
select * from crm_configurations where id = 129;
select * from social_accounts where sociable_id = 2317;
SELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;
select * from teams where id = 1;
SELECT * FROM crm_layouts WHERE crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;
SELECT * FROM crm_layout_entities WHERE id = 5507;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');
select * from teams;
select * from activities where crm_configuration_id = 14;
SELECT * FROM social_accounts where provider = 'copper';
select * from activities where id = 628467;
select * from participants where activity_id = 628467;
SELECT * FROM contacts WHERE id = 3969;
SELECT * FROM accounts WHERE id = 177;
SELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;
# [PASSWORD_DOTS] BH
select * from teams where id = 36;
SELECT * FROM crm_configurations WHERE id = 21;
select * from activities where crm_configuration_id = 21 and id = 607901;
select * from activities where crm_configuration_id = 21;
select * roles;
select * from permissions;
select * from permission_role where permission_id = 226;
select * from migrations order by id desc;
# mercury
# neptune
# earth
select * from teams;
select * from teams where id = 19;
select * from teams where id = 27;
select * from users where team_id = 27;
SELECT * FROM crm_configurations WHERE id = 42;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from activities where id = 631461;
SELECT * FROM crm_field_values WHERE crm_field_id = 180;
select * from teams where id = 2;
SELECT * FROM social_accounts WHERE sociable_id = 89;
SELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273
select * from activity_summary_logs where activity_id = 634273;
select * from sidekick_settings where team_id = 2;
select * from teams; # 2, 2
SELECT * FROM crm_configurations WHERE team_id = 2; # 2
select * from team_features where team_id = 2;
select * from features;
SELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';
SELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;
select * from automated_reports order by id desc;
select * from automated_report_results order by id desc;
select * from users where team_id = 1 and id IN (7160, 3248);
select * from migrations order by id desc;
SELECT
CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,
u.email,
sa.*,
t.owner_id FROM social_accounts sa
JOIN users u on u.id = sa.sociable_id
JOIN teams t on t.id = u.team_id
WHERE u.team_id = 1 and sa.provider = 'salesforce';
select * from teams where id = 1;
select * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;
select * from groups where id = 565;
select * from playbooks where team_id = 1;
select * from playbooks where id = 175;
select * from playbook_categories where playbook_id = 175;
select * from users where team_id = 1;
select * from users where id = 7160;
select * from crm_profiles where user_id = 7160;
select * from features;
select
*
# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,
# crm_configuration_id, crm_provider_id, transcription_id, status
from activities where crm_configuration_id = 1 and type = 'conference'
# and crm_provider_id IS NOT NULL
and provider != 'uploader' and actual_start_time IS NOT NULL
ORDER by id desc;
select * from activities where id = 54747783; # 00UO400000pCzojMAC
select p.id, p.activity_type, pc.id, pc.name
FROM playbooks p
join playbook_categories pc on p.id = pc.playbook_id
where p.team_id = 1 and p.activity_type = 'event';
SELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';
SELECT * FROM crm_field_values WHERE crm_field_id = 4;
select * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id
where crm_configuration_id = 1 and pl.playbook_id = 175;
select * from teams;
SELECT r.* FROM automated_reports r
join teams t on r.team_id = t.id
WHERE r.frequency = 'daily'
and r.status = 1
AND t.status = 'active'
AND (r.expires_at >= now() OR r.expires_at IS NULL);
select * from automated_report_results where report_id IN (18, 33);
select * from activity_searches where id = 10932;
select * from automated_reports;
select * from automated_report_results where report_id IN (34, 35);
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
[{"role":"AXButton","text" [{"role":"AXButton","text":"Project: faVsco.js, menu","depth":5,"help_text":"~/jiminny/app","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"#11894 on JY-18909-automated-reports-ask-jiminny, menu","depth":5,"help_text":"Pull request #11894 exists for current branch JY-18909-automated-reports-ask-jiminny, but local branch is out of sync with remote","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Start Listening for PHP Debug Connections","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"RequestGenerateAskJiminnyReportJobTest","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Run 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Debug 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"More Actions","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"JetBrains AI","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Search Everywhere","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"IDE and Project Settings","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.088194445,"height":0.027777778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"13","depth":4,"role_description":"text"},{"role":"AXStaticText","text":"4","depth":4,"role_description":"text"},{"role":"AXButton","text":"Previous Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Next Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Repositories;\n\nuse Carbon\\CarbonImmutable;\nuse Illuminate\\Database\\Eloquent\\Builder;\nuse Illuminate\\Support\\Carbon;\nuse Illuminate\\Database\\Eloquent\\Collection;\nuse Illuminate\\Pagination\\LengthAwarePaginator;\nuse Illuminate\\Support\\Facades\\DB;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\AutomatedReportResult;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Models\\User;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\ReportSort;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\ReportSortDirection;\n\nclass AutomatedReportsRepository\n{\n /**\n * Create a new automated report\n *\n * @param array $data\n *\n * @return AutomatedReport\n */\n public function create(array $data): AutomatedReport\n {\n return AutomatedReport::create($data);\n }\n\n /**\n * Find an automated report by UUID\n *\n * @param string $uuid\n *\n * @return AutomatedReport|null\n */\n public function findByUuid(string $uuid): ?AutomatedReport\n {\n return AutomatedReport::where('uuid', AutomatedReport::toOptimized($uuid))->first();\n }\n\n /**\n * Retrieve all standard (non-Ask Jiminny) automated reports.\n *\n * @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.\n * @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.\n *\n * @return Collection<AutomatedReport>\n */\n public function getAllStandardReports(\n string $sortColumn = 'created_at',\n string $sortDirection = 'desc'\n ): Collection {\n return $this->buildSortedQuery($sortColumn, $sortDirection)\n ->whereNot('type', AutomatedReportsService::TYPE_ASK_JIMINNY)\n ->get();\n }\n\n /**\n * Retrieve all Ask Jiminny reports created by the given user.\n *\n * @param User $user The user whose reports to retrieve.\n * @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.\n * @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.\n *\n * @return Collection<AutomatedReport>\n */\n public function getAskJiminnyReportsByUser(\n User $user,\n string $sortColumn = 'created_at',\n string $sortDirection = 'desc'\n ): Collection {\n return $this->buildSortedQuery($sortColumn, $sortDirection)\n ->where('type', AutomatedReportsService::TYPE_ASK_JIMINNY)\n ->where('created_by', $user->getId())\n ->get();\n }\n\n private function buildSortedQuery(string $sortColumn, string $sortDirection): \\Illuminate\\Database\\Eloquent\\Builder\n {\n $allowedColumns = ['created_by', 'created_at'];\n if (! in_array($sortColumn, $allowedColumns)) {\n $sortColumn = 'created_at';\n }\n\n $sortDirection = strtolower($sortDirection) === 'asc' ? 'asc' : 'desc';\n\n $query = AutomatedReport::query()->with(['creator', 'team']);\n\n if ($sortColumn === 'created_by') {\n $query->leftJoin('users', 'users.id', '=', 'automated_reports.created_by')\n ->orderByRaw(\"users.name COLLATE utf8mb4_unicode_ci {$sortDirection}\")\n ->select('automated_reports.*');\n } else {\n $query->orderBy($sortColumn, $sortDirection);\n }\n\n return $query;\n }\n\n /**\n * Get all active and enabled reports with active teams for the specified frequency.\n *\n * @param string $frequency\n *\n * @return Collection<AutomatedReport>\n */\n public function getActiveReportsByFrequency(string $frequency): Collection\n {\n return AutomatedReport::where('automated_reports.status', true)\n ->where('automated_reports.frequency', $frequency)\n ->join('teams', 'automated_reports.team_id', '=', 'teams.id')\n ->where('teams.status', Team::STATUS_ACTIVE)\n ->where(function ($query) {\n $query->whereNull('automated_reports.expires_at')\n ->orWhere('automated_reports.expires_at', '>=', now()->toDateString());\n })\n ->select('automated_reports.*')\n ->get();\n }\n\n /**\n * Update an automated report\n *\n * @param AutomatedReport $report\n * @param array $data\n *\n * @return AutomatedReport\n */\n public function update(AutomatedReport $report, array $data): AutomatedReport\n {\n $report->update($data);\n\n return $report;\n }\n\n /**\n * Create a new automated report result.\n *\n * @param array $data The data to create the automated report result with.\n *\n * @return AutomatedReportResult The newly created automated report result.\n */\n public function createResult(array $data): AutomatedReportResult\n {\n return AutomatedReportResult::create($data);\n }\n\n /**\n * Find an automated report result by UUID.\n *\n * @param string $uuid The UUID to find the automated report result with.\n *\n * @return AutomatedReportResult|null The automated report result if found, otherwise null.\n */\n public function findResultByUuid(string $uuid): ?AutomatedReportResult\n {\n return AutomatedReportResult::where('uuid', AutomatedReportResult::toOptimized($uuid))->first();\n }\n\n public function findResultByUuidForUser(string $uuid, User $user): ?AutomatedReportResult\n {\n return AutomatedReportResult::query()\n ->where('uuid', AutomatedReportResult::toOptimized($uuid))\n ->whereHas('report', static function ($query) use ($user): void {\n $query->where('team_id', $user->getTeamId())\n ->where('created_by', $user->getId());\n })\n ->first();\n }\n\n public function findChildResult(AutomatedReportResult $result, string $type): ?AutomatedReportResult\n {\n return AutomatedReportResult::query()\n ->where('parent_id', $result->getId())\n ->where('media_type', $type)\n ->first();\n }\n\n public function getGeneratedNotSentResults(): Collection\n {\n return AutomatedReportResult::query()\n ->whereNotNull('generated_at')\n ->whereNull('sent_at')\n ->where('status', AutomatedReportResult::STATUS_GENERATED)\n ->whereHas('report')\n ->with('report')\n ->get();\n }\n\n public function getPaginatedUserReports(\n User $user,\n ReportSort $sort,\n ReportSortDirection $sortDirection,\n int $resultsPerPage,\n int $page,\n ?Carbon $fromDate,\n ?Carbon $toDate,\n array $teamIds,\n array $reportTypes,\n ?string $name,\n ): LengthAwarePaginator {\n $query = AutomatedReportResult::query()\n ->whereNotNull('automated_report_results.generated_at')\n ->join('automated_reports', 'automated_report_results.report_id', '=', 'automated_reports.id')\n ->where('automated_reports.team_id', $user->getTeamId())\n ->whereJsonContains('automated_reports.recipients->users', $user->getId())\n ->orderByRaw(\"$sort->value COLLATE utf8mb4_unicode_ci {$sortDirection->value}\")\n ->select('automated_report_results.*')\n ->with('report.team');\n\n if ($fromDate !== null && $toDate !== null) {\n $query->whereBetween('generated_at', [$fromDate, $toDate]);\n }\n\n if (! empty($teamIds)) {\n $query->where(function ($q) use ($teamIds) {\n foreach ($teamIds as $id) {\n $q->orWhereJsonContains('automated_reports.groups', $id);\n }\n });\n }\n\n if (! empty($reportTypes)) {\n $query->whereIn('automated_reports.type', $reportTypes);\n }\n\n if (! empty($name)) {\n $query->whereLike('name', \"%$name%\");\n }\n\n return $query->paginate($resultsPerPage, ['*'], 'page', $page);\n }\n\n public function countUserReports(User $user): int\n {\n return AutomatedReportResult::query()\n ->whereNotNull('generated_at')\n ->whereNotNull('sent_at')\n ->whereHas('report', function ($q) use ($user) {\n $q->where('team_id', $user->getTeamId())\n ->whereJsonContains('recipients->users', $user->getId());\n })\n ->count();\n }\n\n /**\n * Get report IDs for a specific team\n *\n * @param Team $team\n *\n * @return \\Illuminate\\Support\\Collection\n */\n public function getReportIdsByTeam(Team $team): \\Illuminate\\Support\\Collection\n {\n return AutomatedReport::where('team_id', $team->getId())->pluck('id');\n }\n\n /**\n * Get all reports for a specific team\n *\n * @param Team $team\n *\n * @return Collection\n */\n public function getReportsByTeam(Team $team): Collection\n {\n return AutomatedReport::where('team_id', $team->getId())->get();\n }\n\n /**\n * Get all report results for a specific report\n *\n * @param AutomatedReport $report\n *\n * @return Collection\n */\n public function getResultsByReport(AutomatedReport $report): Collection\n {\n return $this->getResultsByReportQuery($report)->get();\n }\n\n public function getResultsByReportQuery(AutomatedReport $report): Builder\n {\n return AutomatedReportResult::where('report_id', $report->getId());\n }\n\n public function getReportResultsQueryForRetention(Team $team, CarbonImmutable $retentionDate): Builder\n {\n $reportIds = $this->getReportIdsByTeam($team);\n\n return AutomatedReportResult::query()->whereIn('report_id', $reportIds)\n ->whereRaw('IFNULL(generated_at, created_at) <= ?', [$retentionDate]);\n }\n\n /**\n * @param int|null $teamId Optional team ID to filter results\n *\n * @return \\Illuminate\\Support\\Collection<int, int> Collection of team IDs\n */\n public function getTeamIdsWithReportsResults(?int $teamId = null): \\Illuminate\\Support\\Collection\n {\n $query = DB::table('automated_reports')\n ->join('teams', 'automated_reports.team_id', '=', 'teams.id')\n ->select('teams.id')\n ->distinct();\n\n if ($teamId !== null) {\n $query->where('teams.id', $teamId);\n }\n\n return $query->pluck('teams.id');\n }\n}","depth":4,"value":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Repositories;\n\nuse Carbon\\CarbonImmutable;\nuse Illuminate\\Database\\Eloquent\\Builder;\nuse Illuminate\\Support\\Carbon;\nuse Illuminate\\Database\\Eloquent\\Collection;\nuse Illuminate\\Pagination\\LengthAwarePaginator;\nuse Illuminate\\Support\\Facades\\DB;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\AutomatedReportResult;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Models\\User;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\ReportSort;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\ReportSortDirection;\n\nclass AutomatedReportsRepository\n{\n /**\n * Create a new automated report\n *\n * @param array $data\n *\n * @return AutomatedReport\n */\n public function create(array $data): AutomatedReport\n {\n return AutomatedReport::create($data);\n }\n\n /**\n * Find an automated report by UUID\n *\n * @param string $uuid\n *\n * @return AutomatedReport|null\n */\n public function findByUuid(string $uuid): ?AutomatedReport\n {\n return AutomatedReport::where('uuid', AutomatedReport::toOptimized($uuid))->first();\n }\n\n /**\n * Retrieve all standard (non-Ask Jiminny) automated reports.\n *\n * @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.\n * @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.\n *\n * @return Collection<AutomatedReport>\n */\n public function getAllStandardReports(\n string $sortColumn = 'created_at',\n string $sortDirection = 'desc'\n ): Collection {\n return $this->buildSortedQuery($sortColumn, $sortDirection)\n ->whereNot('type', AutomatedReportsService::TYPE_ASK_JIMINNY)\n ->get();\n }\n\n /**\n * Retrieve all Ask Jiminny reports created by the given user.\n *\n * @param User $user The user whose reports to retrieve.\n * @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.\n * @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.\n *\n * @return Collection<AutomatedReport>\n */\n public function getAskJiminnyReportsByUser(\n User $user,\n string $sortColumn = 'created_at',\n string $sortDirection = 'desc'\n ): Collection {\n return $this->buildSortedQuery($sortColumn, $sortDirection)\n ->where('type', AutomatedReportsService::TYPE_ASK_JIMINNY)\n ->where('created_by', $user->getId())\n ->get();\n }\n\n private function buildSortedQuery(string $sortColumn, string $sortDirection): \\Illuminate\\Database\\Eloquent\\Builder\n {\n $allowedColumns = ['created_by', 'created_at'];\n if (! in_array($sortColumn, $allowedColumns)) {\n $sortColumn = 'created_at';\n }\n\n $sortDirection = strtolower($sortDirection) === 'asc' ? 'asc' : 'desc';\n\n $query = AutomatedReport::query()->with(['creator', 'team']);\n\n if ($sortColumn === 'created_by') {\n $query->leftJoin('users', 'users.id', '=', 'automated_reports.created_by')\n ->orderByRaw(\"users.name COLLATE utf8mb4_unicode_ci {$sortDirection}\")\n ->select('automated_reports.*');\n } else {\n $query->orderBy($sortColumn, $sortDirection);\n }\n\n return $query;\n }\n\n /**\n * Get all active and enabled reports with active teams for the specified frequency.\n *\n * @param string $frequency\n *\n * @return Collection<AutomatedReport>\n */\n public function getActiveReportsByFrequency(string $frequency): Collection\n {\n return AutomatedReport::where('automated_reports.status', true)\n ->where('automated_reports.frequency', $frequency)\n ->join('teams', 'automated_reports.team_id', '=', 'teams.id')\n ->where('teams.status', Team::STATUS_ACTIVE)\n ->where(function ($query) {\n $query->whereNull('automated_reports.expires_at')\n ->orWhere('automated_reports.expires_at', '>=', now()->toDateString());\n })\n ->select('automated_reports.*')\n ->get();\n }\n\n /**\n * Update an automated report\n *\n * @param AutomatedReport $report\n * @param array $data\n *\n * @return AutomatedReport\n */\n public function update(AutomatedReport $report, array $data): AutomatedReport\n {\n $report->update($data);\n\n return $report;\n }\n\n /**\n * Create a new automated report result.\n *\n * @param array $data The data to create the automated report result with.\n *\n * @return AutomatedReportResult The newly created automated report result.\n */\n public function createResult(array $data): AutomatedReportResult\n {\n return AutomatedReportResult::create($data);\n }\n\n /**\n * Find an automated report result by UUID.\n *\n * @param string $uuid The UUID to find the automated report result with.\n *\n * @return AutomatedReportResult|null The automated report result if found, otherwise null.\n */\n public function findResultByUuid(string $uuid): ?AutomatedReportResult\n {\n return AutomatedReportResult::where('uuid', AutomatedReportResult::toOptimized($uuid))->first();\n }\n\n public function findResultByUuidForUser(string $uuid, User $user): ?AutomatedReportResult\n {\n return AutomatedReportResult::query()\n ->where('uuid', AutomatedReportResult::toOptimized($uuid))\n ->whereHas('report', static function ($query) use ($user): void {\n $query->where('team_id', $user->getTeamId())\n ->where('created_by', $user->getId());\n })\n ->first();\n }\n\n public function findChildResult(AutomatedReportResult $result, string $type): ?AutomatedReportResult\n {\n return AutomatedReportResult::query()\n ->where('parent_id', $result->getId())\n ->where('media_type', $type)\n ->first();\n }\n\n public function getGeneratedNotSentResults(): Collection\n {\n return AutomatedReportResult::query()\n ->whereNotNull('generated_at')\n ->whereNull('sent_at')\n ->where('status', AutomatedReportResult::STATUS_GENERATED)\n ->whereHas('report')\n ->with('report')\n ->get();\n }\n\n public function getPaginatedUserReports(\n User $user,\n ReportSort $sort,\n ReportSortDirection $sortDirection,\n int $resultsPerPage,\n int $page,\n ?Carbon $fromDate,\n ?Carbon $toDate,\n array $teamIds,\n array $reportTypes,\n ?string $name,\n ): LengthAwarePaginator {\n $query = AutomatedReportResult::query()\n ->whereNotNull('automated_report_results.generated_at')\n ->join('automated_reports', 'automated_report_results.report_id', '=', 'automated_reports.id')\n ->where('automated_reports.team_id', $user->getTeamId())\n ->whereJsonContains('automated_reports.recipients->users', $user->getId())\n ->orderByRaw(\"$sort->value COLLATE utf8mb4_unicode_ci {$sortDirection->value}\")\n ->select('automated_report_results.*')\n ->with('report.team');\n\n if ($fromDate !== null && $toDate !== null) {\n $query->whereBetween('generated_at', [$fromDate, $toDate]);\n }\n\n if (! empty($teamIds)) {\n $query->where(function ($q) use ($teamIds) {\n foreach ($teamIds as $id) {\n $q->orWhereJsonContains('automated_reports.groups', $id);\n }\n });\n }\n\n if (! empty($reportTypes)) {\n $query->whereIn('automated_reports.type', $reportTypes);\n }\n\n if (! empty($name)) {\n $query->whereLike('name', \"%$name%\");\n }\n\n return $query->paginate($resultsPerPage, ['*'], 'page', $page);\n }\n\n public function countUserReports(User $user): int\n {\n return AutomatedReportResult::query()\n ->whereNotNull('generated_at')\n ->whereNotNull('sent_at')\n ->whereHas('report', function ($q) use ($user) {\n $q->where('team_id', $user->getTeamId())\n ->whereJsonContains('recipients->users', $user->getId());\n })\n ->count();\n }\n\n /**\n * Get report IDs for a specific team\n *\n * @param Team $team\n *\n * @return \\Illuminate\\Support\\Collection\n */\n public function getReportIdsByTeam(Team $team): \\Illuminate\\Support\\Collection\n {\n return AutomatedReport::where('team_id', $team->getId())->pluck('id');\n }\n\n /**\n * Get all reports for a specific team\n *\n * @param Team $team\n *\n * @return Collection\n */\n public function getReportsByTeam(Team $team): Collection\n {\n return AutomatedReport::where('team_id', $team->getId())->get();\n }\n\n /**\n * Get all report results for a specific report\n *\n * @param AutomatedReport $report\n *\n * @return Collection\n */\n public function getResultsByReport(AutomatedReport $report): Collection\n {\n return $this->getResultsByReportQuery($report)->get();\n }\n\n public function getResultsByReportQuery(AutomatedReport $report): Builder\n {\n return AutomatedReportResult::where('report_id', $report->getId());\n }\n\n public function getReportResultsQueryForRetention(Team $team, CarbonImmutable $retentionDate): Builder\n {\n $reportIds = $this->getReportIdsByTeam($team);\n\n return AutomatedReportResult::query()->whereIn('report_id', $reportIds)\n ->whereRaw('IFNULL(generated_at, created_at) <= ?', [$retentionDate]);\n }\n\n /**\n * @param int|null $teamId Optional team ID to filter results\n *\n * @return \\Illuminate\\Support\\Collection<int, int> Collection of team IDs\n */\n public function getTeamIdsWithReportsResults(?int $teamId = null): \\Illuminate\\Support\\Collection\n {\n $query = DB::table('automated_reports')\n ->join('teams', 'automated_reports.team_id', '=', 'teams.id')\n ->select('teams.id')\n ->distinct();\n\n if ($teamId !== null) {\n $query->where('teams.id', $teamId);\n }\n\n return $query->pluck('teams.id');\n }\n}","role_description":"text entry area","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Execute","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Explain Plan","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Browse Query History","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"View Parameters","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Open Query Execution Settings…","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"In-Editor Results","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Tx: Auto","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Cancel Running Statements","depth":4,"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Playground","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"jiminny","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.088194445,"height":0.027777778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"16","depth":4,"role_description":"text"},{"role":"AXStaticText","text":"13","depth":4,"role_description":"text"},{"role":"AXStaticText","text":"13","depth":4,"role_description":"text"},{"role":"AXButton","text":"Previous Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Next Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"SELECT * FROM teams WHERE id = 1;\n\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;\nSELECT * FROM crm_fields WHERE id = 2234;\nSELECT * FROM crm_field_values WHERE crm_field_id = 2234;\n\nselect * from crm_profiles where user_id = 143;\n\nselect * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO\nselect * from business_processes where crm_configuration_id = 39;\n# 01941000000H669AAC, 01941000000H66JAAS\n\nselect * from record_type_field_values\n where record_type_id IN (24);\n\nselect * from crm_field_values where id IN (2730);\n\nselect * from crm_configurations where id = 39;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce'; #1035\n\n\nselect * from users where team_id = 1; # 222 group 3\nSELECT * FROM activities WHERE user_id = 222 order by id desc;\nselect * from sidekick_settings where team_id = 1;\nselect * from teams where id = 1;\nselect * from team_features where team_id = 1;\n\nselect * from activities where crm_configuration_id = 2\nand provider = 'ms-teams' and id = 608765;\n\nSELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';\n\nselect * from sidekick_settings where team_id = 2;\n\nSELECT * FROM activities WHERE id = 608660;\nselect * from activity_summary_logs where activity_id = 608660;\nselect * from ai_prompts where transcription_id = 11214;\n\n# ********************************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;\n# id: 608818, crm: 59628809737\nSELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;\n# id: 608821, crm: 59632069252\nSELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,\nplaybook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,\nscheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at\nFROM activities a\njoin calendar_events ce on a.calendar_event_id = ce.id\nWHERE a.id IN (608818, 608821);\n\nselect * from users where team_id = 1;\nselect * from team_settings where team_id = 1;\nselect * from crm_profiles where crm_configuration_id = 39 order by user_id;\n\nselect * from team_features where team_id = 1;\n\nselect * from users where team_id = 2;\n\nSELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639\n# Preslava N. Ivanova, grou id 3\n\nSELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;\n\nselect * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';\n\nselect\n a.id,\n a.type,\n a.scheduled_start_time,\n a.actual_start_time,\n a.created_at,\n a.opportunity_id,\n a.status\nFROM activities a\nWHERE opportunity_id = 344\nand status IN ('completed', 'received', 'delivered')\nand (\n (a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))\n;\n\nSELECT * FROM users WHERE id = 222;\n\nSELECT * FROM crm_profiles WHERE user_id = 222;\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;\n\nselect * from group_deal_risk_types;\n\nselect * from opportunities where team_id = 1;\n\nSELECT * FROM opportunities WHERE id = 315;\nSELECT * FROM crm_field_data WHERE object_id = 315;\nselect * from crm_field_data where object_id = 260;\n\nselect * from generic_ai_prompts where subject_id = 315;\n\nselect * from teams; # 36, 21, 121, james.graham@bullhorn.jiminny.com\nSELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';\n\n# ************************************************************************************\nselect * from teams where id = 1;\nselect * from crm_configurations where id = 39;\nselect * from users where team_id = 1;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 1;\n# 1 - 00541000004281rAAA\n# 204 - 0052g000003freeAAA\n# 429 - 0052g000003qGOiAAM\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\nselect * from activities where type = 'softphone'\nand created_at > '2024-12-11 15:24:36' order by id desc;\n\nselect * from activity_providers where team_id = 1;\nselect * from activity_provider_users where activity_provider_id = 328;\n\nselect * from opportunities where crm_configuration_id = 39\nAND account_id = 178 AND is_closed = false\norder by created_at DESC;\n\nselect * from contacts where id = 3952;\nselect * from accounts where id = 178;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations where id = 21;\nselect * from users where team_id = 36;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 36;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 36\nand sa.provider = 'bullhorn';\n\nselect * from social_accounts where id = 348;\nUPDATE social_accounts SET\nprovider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',\nprovider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',\nexpires = 1733998131,\nstate = 'connected'\nWHERE id = 348;\n\n# ************************************************************************************\nselect * from teams where id = 31;\nselect * from crm_configurations where id = 18;\n\nselect * from users where team_id = 31; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 31;\n\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 31\nand sa.provider = 'close';\n\nselect * from contacts where crm_configuration_id = 18;\n\n# ********************** NEPTUNE **************************************************************\nselect * from teams;\nselect * from users where id IN (1030, 1035, 1052);\nselect * from crm_configurations;\n\nselect * from users where team_id = 65; # 257\nselect * from team_settings where team_id = 65; # 257\nselect * from invitations where team_id = 65; # 257\nselect * from users where email = 'integration-account@jiminny.com'; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 65;\n\nselect * from crm_configurations where id = 53;\nselect * from accounts where crm_configuration_id = 53 order by id desc;\nselect * from leads where crm_configuration_id = 53 order by id desc;\nselect * from contacts where crm_configuration_id = 53 order by id desc;\nselect * from opportunities where crm_configuration_id = 53 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 53 order by id desc;\nselect * from crm_fields where crm_configuration_id = 53 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 53 order by id desc;\nselect * from stages where crm_configuration_id = 53 order by id desc;\n\n\nselect * from crm_profiles where crm_configuration_id = 13;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\nand sa.provider = 'integration-app';\n\nselect * from contacts where crm_configuration_id = 13;\n\nselect * from social_accounts where sociable_id = 283;\n\nSELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';\n\nselect * from activity_providers where team_id = 65;\nSELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\n;\n\n# ***************************** STAGING ********************************************\nSELECT * FROM teams;\nSELECT * FROM teams WHERE id = 88;\nSELECT * FROM teams WHERE id = 89;\nselect * from team_settings where team_id = 89;\nSELECT * FROM users WHERE team_id = 89;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 89;\n\nselect * from users;\nSELECT * FROM social_accounts WHERE sociable_id = 1761;\nSELECT * FROM crm_configurations WHERE id = 70;\nselect * from accounts where crm_configuration_id = 70 order by id desc;\nselect * from leads where crm_configuration_id = 70 order by id desc;\nselect * from contacts where crm_configuration_id = 70 order by id desc;\nselect * from opportunities where crm_configuration_id = 70 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 70 order by id desc;\nselect * from crm_fields where crm_configuration_id = 70 order by id desc;\nselect * from crm_field_values where crm_field_id = 3536 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 70 order by id desc;\nselect * from stages where crm_configuration_id = 70 order by id desc;\nselect * from business_processes where crm_configuration_id = 70 order by id desc;\nselect * from business_process_stages where business_process_id = 34;\n\nselect * from contacts where id = 10468;\n\nselect * from crm_layouts where crm_configuration_id = 70;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;\nSELECT * FROM crm_fields WHERE id IN (3533,3534,3535);\n\nselect * from activities where crm_configuration_id = 70\nand (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;\n\nSELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;\nSELECT * FROM activities where crm_configuration_id = 69 ;\n\nSELECT * FROM users WHERE email LIKE '%jiminny_web_sa2@jiminny.com%';\nSELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;\nSELECT * FROM opportunities WHERE id = 385;\n\nselect * from participants p\njoin activities a on p.activity_id = a.id\nwhere a.crm_configuration_id = 70\nand (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);\nSELECT * FROM participants WHERE id = 1013638;\n\nselect * from teams where id = 90;\nselect * from users where team_id = 90;\nselect * from social_accounts where social_accounts.sociable_id IN (1960,1760);\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 71;\nselect * from invitations where team_id = 90;\n\nselect * from crm_configurations where id = 71;\nselect * from accounts where crm_configuration_id = 71 order by id desc;\nselect * from leads where crm_configuration_id = 71 order by id desc;\nselect * from contacts where crm_configuration_id = 71 order by id desc;\nselect * from opportunities where crm_configuration_id = 71 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 71 order by id desc;\nselect * from crm_fields where crm_configuration_id = 71 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 71 order by id desc;\nselect * from stages where crm_configuration_id = 71 order by id desc;\n\nselect * from users order by secondary_email desc;\nselect u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa\n join users u on sa.sociable_id = u.id\nwhere sa.provider = 'google' and u.email LIKE 'aneliya%';\n\nselect * from failed_jobs order by id desc;\n\nselect * from users where email = 'ben.allwright@learningpeople.co.uk' or secondary_email = 'ben.allwright@learningpeople.co.uk';\n\nselect * from teams;\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 39;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\n# ************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;\nSELECT * FROM crm_configurations WHERE id = 70;\n\nselect * from teams where id = 1;\nselect * from groups where team_id = 1;\nselect * from users where team_id = 1;\n\nselect o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o\njoin users u on o.user_id = u.id\njoin groups g on u.group_id = g.id\njoin role_user ru on u.id = ru.user_id\njoin roles r on ru.role_id = r.id\nwhere o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';\n\nselect * from role_user where user_id = 143;\nselect * from roles;\n\nselect * from role_user;\nselect * from groups where id = 9;\nselect * from scope_groups where group_id = 9;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations;\nSELECT * FROM social_accounts WHERE sociable_id = 121;\n\nhttps://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105\nhttps://crmsandbox.zoho.com/crm/\n\nhttps://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080\n https://crm.zoho.com/crm/\n org3469620\n\nSELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;\n\nselect * from users where email LIKE \"%mobile_automation_%\";\nselect * from social_accounts where sociable_id IN (2228);\nselect * from crm_profiles where user_id IN (2222,2223,2226,2227);\n\nselect * from teams order by id desc;\nSELECT * FROM users WHERE id = 2229;\nSELECT * FROM crm_profiles WHERE user_id = 2229;\nselect * from opportunities where crm_configuration_id = 88;\nselect * from crm_fields where crm_configuration_id = 88;\nselect * from crm_profiles where crm_configuration_id = 88;\n\nSELECT * FROM teams WHERE id = 1;\n\nSELECT * FROM users WHERE id = 143;\nSELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;\n\nhttps://app.staging.jiminny.com/ondemand?\n min_duration=1\n &\n only_recorded=1\n &\n user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e\n &\n sequence_number=2\n\n select * from users where team_id = 1 and email like '%stoyan%'\n\nselect * from coaching_feedbacks;\n\nselect * from teams;\nSELECT * FROM users WHERE team_id = 36;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from users where id = 143;\n\nSELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\n\nselect * from users where team_id = 2;\nselect * from activities where crm_configuration_id = 39\nand activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'\nAND user_id = 143\norder by id desc;\n\n# ************************************************************************************\nselect * from teams where id = 142; # 2312, 126\nselect * from team_settings;\nselect * from users where team_id = 142; # 21642\nSELECT * FROM social_accounts WHERE sociable_id = 21642;\nSELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;\nselect * from crm_profiles where id IN (93);\nselect * from invitations;\nselect * from team_features where team_id = 1;\n\nSELECT * FROM crm_configurations WHERE id = 126;\nselect * from accounts where crm_configuration_id = 126 order by id desc;\nselect * from leads where crm_configuration_id = 126 order by id desc;\nselect * from contacts where crm_configuration_id = 126 order by id desc;\nselect * from opportunities where crm_configuration_id = 126 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 126 order by id desc;\nselect * from crm_fields where crm_configuration_id = 126 # 11060\n# and type IN ('picklist', 'status')\n# and object_type = 'task'\norder by id desc;\n# 5731,5732,5733\nselect DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;\nselect * from crm_layouts where crm_configuration_id = 126 order by id desc;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);\nselect * from stages where crm_configuration_id = 126 order by id desc;\nselect * from business_processes where crm_configuration_id = 126 order by id desc;\nselect * from business_process_stages where business_process_id IN (76,75,74,73);\nselect * from playbooks where team_id = 142;\nselect * from playbook_layouts where playbook_id IN (108);\nSELECT * FROM playbook_categories WHERE playbook_id IN (108);\n\nselect * from teams where id = 130;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 2\nand sa.provider = 'hubspot';\n\nSELECT * FROM activities\n WHERE crm_configuration_id = 110;\n\nselect * from teams;\nselect * from crm_configurations;\n\nSELECT * FROM activities WHERE id = 628773;\nSELECT * FROM crm_profiles WHERE user_id = 1460;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from teams;\nselect ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id\njoin permission_role pr on pr.role_id = ru.role_id\n join permissions p on p.id = pr.permission_id\nwhere team_id = 495 and p.name IN ('dial');\n\nselect * from teams where id = 145;\nselect * from crm_configurations where id = 129;\nselect * from social_accounts where sociable_id = 2317;\nSELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;\n\nselect * from teams where id = 1;\nSELECT * FROM crm_layouts WHERE crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;\nSELECT * FROM crm_layout_entities WHERE id = 5507;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');\n\nselect * from teams;\nselect * from activities where crm_configuration_id = 14;\n\nSELECT * FROM social_accounts where provider = 'copper';\n\nselect * from activities where id = 628467;\nselect * from participants where activity_id = 628467;\n\nSELECT * FROM contacts WHERE id = 3969;\nSELECT * FROM accounts WHERE id = 177;\n\nSELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;\n\n# ********************* BH\nselect * from teams where id = 36;\nSELECT * FROM crm_configurations WHERE id = 21;\nselect * from activities where crm_configuration_id = 21 and id = 607901;\nselect * from activities where crm_configuration_id = 21;\n\nselect * roles;\nselect * from permissions;\nselect * from permission_role where permission_id = 226;\n\nselect * from migrations order by id desc;\n\n# mercury\n# neptune\n# earth\n\nselect * from teams;\nselect * from teams where id = 19;\nselect * from teams where id = 27;\nselect * from users where team_id = 27;\nSELECT * FROM crm_configurations WHERE id = 42;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from activities where id = 631461;\nSELECT * FROM crm_field_values WHERE crm_field_id = 180;\n\nselect * from teams where id = 2;\nSELECT * FROM social_accounts WHERE sociable_id = 89;\n\nSELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273\nselect * from activity_summary_logs where activity_id = 634273;\n\nselect * from sidekick_settings where team_id = 2;\n\nselect * from teams; # 2, 2\nSELECT * FROM crm_configurations WHERE team_id = 2; # 2\nselect * from team_features where team_id = 2;\nselect * from features;\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;\n\nselect * from automated_reports order by id desc;\nselect * from automated_report_results order by id desc;\nselect * from users where team_id = 1 and id IN (7160, 3248);\nselect * from migrations order by id desc;\n\nSELECT\n CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,\n u.email,\n sa.*,\n t.owner_id FROM social_accounts sa\nJOIN users u on u.id = sa.sociable_id\nJOIN teams t on t.id = u.team_id\nWHERE u.team_id = 1 and sa.provider = 'salesforce';\n\nselect * from teams where id = 1;\nselect * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;\nselect * from groups where id = 565;\nselect * from playbooks where team_id = 1;\nselect * from playbooks where id = 175;\nselect * from playbook_categories where playbook_id = 175;\nselect * from users where team_id = 1;\nselect * from users where id = 7160;\nselect * from crm_profiles where user_id = 7160;\nselect * from features;\nselect\n *\n# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,\n# crm_configuration_id, crm_provider_id, transcription_id, status\nfrom activities where crm_configuration_id = 1 and type = 'conference'\n# and crm_provider_id IS NOT NULL\nand provider != 'uploader' and actual_start_time IS NOT NULL\nORDER by id desc;\nselect * from activities where id = 54747783; # 00UO400000pCzojMAC\n\nselect p.id, p.activity_type, pc.id, pc.name\nFROM playbooks p\njoin playbook_categories pc on p.id = pc.playbook_id\nwhere p.team_id = 1 and p.activity_type = 'event';\n\nSELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';\nSELECT * FROM crm_field_values WHERE crm_field_id = 4;\n\nselect * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id\nwhere crm_configuration_id = 1 and pl.playbook_id = 175;\n\nselect * from teams;\nSELECT r.* FROM automated_reports r\njoin teams t on r.team_id = t.id\nWHERE r.frequency = 'daily'\n and r.status = 1\nAND t.status = 'active'\nAND (r.expires_at >= now() OR r.expires_at IS NULL);\n\nselect * from automated_report_results where report_id IN (18, 33);\n\nselect * from activity_searches where id = 10932;\nselect * from automated_reports;\nselect * from automated_report_results where report_id IN (34, 35);","depth":4,"value":"SELECT * FROM teams WHERE id = 1;\n\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;\nSELECT * FROM crm_fields WHERE id = 2234;\nSELECT * FROM crm_field_values WHERE crm_field_id = 2234;\n\nselect * from crm_profiles where user_id = 143;\n\nselect * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO\nselect * from business_processes where crm_configuration_id = 39;\n# 01941000000H669AAC, 01941000000H66JAAS\n\nselect * from record_type_field_values\n where record_type_id IN (24);\n\nselect * from crm_field_values where id IN (2730);\n\nselect * from crm_configurations where id = 39;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce'; #1035\n\n\nselect * from users where team_id = 1; # 222 group 3\nSELECT * FROM activities WHERE user_id = 222 order by id desc;\nselect * from sidekick_settings where team_id = 1;\nselect * from teams where id = 1;\nselect * from team_features where team_id = 1;\n\nselect * from activities where crm_configuration_id = 2\nand provider = 'ms-teams' and id = 608765;\n\nSELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';\n\nselect * from sidekick_settings where team_id = 2;\n\nSELECT * FROM activities WHERE id = 608660;\nselect * from activity_summary_logs where activity_id = 608660;\nselect * from ai_prompts where transcription_id = 11214;\n\n# ********************************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;\n# id: 608818, crm: 59628809737\nSELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;\n# id: 608821, crm: 59632069252\nSELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,\nplaybook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,\nscheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at\nFROM activities a\njoin calendar_events ce on a.calendar_event_id = ce.id\nWHERE a.id IN (608818, 608821);\n\nselect * from users where team_id = 1;\nselect * from team_settings where team_id = 1;\nselect * from crm_profiles where crm_configuration_id = 39 order by user_id;\n\nselect * from team_features where team_id = 1;\n\nselect * from users where team_id = 2;\n\nSELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639\n# Preslava N. Ivanova, grou id 3\n\nSELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;\n\nselect * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';\n\nselect\n a.id,\n a.type,\n a.scheduled_start_time,\n a.actual_start_time,\n a.created_at,\n a.opportunity_id,\n a.status\nFROM activities a\nWHERE opportunity_id = 344\nand status IN ('completed', 'received', 'delivered')\nand (\n (a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))\n;\n\nSELECT * FROM users WHERE id = 222;\n\nSELECT * FROM crm_profiles WHERE user_id = 222;\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;\n\nselect * from group_deal_risk_types;\n\nselect * from opportunities where team_id = 1;\n\nSELECT * FROM opportunities WHERE id = 315;\nSELECT * FROM crm_field_data WHERE object_id = 315;\nselect * from crm_field_data where object_id = 260;\n\nselect * from generic_ai_prompts where subject_id = 315;\n\nselect * from teams; # 36, 21, 121, james.graham@bullhorn.jiminny.com\nSELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';\n\n# ************************************************************************************\nselect * from teams where id = 1;\nselect * from crm_configurations where id = 39;\nselect * from users where team_id = 1;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 1;\n# 1 - 00541000004281rAAA\n# 204 - 0052g000003freeAAA\n# 429 - 0052g000003qGOiAAM\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\nselect * from activities where type = 'softphone'\nand created_at > '2024-12-11 15:24:36' order by id desc;\n\nselect * from activity_providers where team_id = 1;\nselect * from activity_provider_users where activity_provider_id = 328;\n\nselect * from opportunities where crm_configuration_id = 39\nAND account_id = 178 AND is_closed = false\norder by created_at DESC;\n\nselect * from contacts where id = 3952;\nselect * from accounts where id = 178;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations where id = 21;\nselect * from users where team_id = 36;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 36;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 36\nand sa.provider = 'bullhorn';\n\nselect * from social_accounts where id = 348;\nUPDATE social_accounts SET\nprovider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',\nprovider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',\nexpires = 1733998131,\nstate = 'connected'\nWHERE id = 348;\n\n# ************************************************************************************\nselect * from teams where id = 31;\nselect * from crm_configurations where id = 18;\n\nselect * from users where team_id = 31; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 31;\n\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 31\nand sa.provider = 'close';\n\nselect * from contacts where crm_configuration_id = 18;\n\n# ********************** NEPTUNE **************************************************************\nselect * from teams;\nselect * from users where id IN (1030, 1035, 1052);\nselect * from crm_configurations;\n\nselect * from users where team_id = 65; # 257\nselect * from team_settings where team_id = 65; # 257\nselect * from invitations where team_id = 65; # 257\nselect * from users where email = 'integration-account@jiminny.com'; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 65;\n\nselect * from crm_configurations where id = 53;\nselect * from accounts where crm_configuration_id = 53 order by id desc;\nselect * from leads where crm_configuration_id = 53 order by id desc;\nselect * from contacts where crm_configuration_id = 53 order by id desc;\nselect * from opportunities where crm_configuration_id = 53 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 53 order by id desc;\nselect * from crm_fields where crm_configuration_id = 53 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 53 order by id desc;\nselect * from stages where crm_configuration_id = 53 order by id desc;\n\n\nselect * from crm_profiles where crm_configuration_id = 13;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\nand sa.provider = 'integration-app';\n\nselect * from contacts where crm_configuration_id = 13;\n\nselect * from social_accounts where sociable_id = 283;\n\nSELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';\n\nselect * from activity_providers where team_id = 65;\nSELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\n;\n\n# ***************************** STAGING ********************************************\nSELECT * FROM teams;\nSELECT * FROM teams WHERE id = 88;\nSELECT * FROM teams WHERE id = 89;\nselect * from team_settings where team_id = 89;\nSELECT * FROM users WHERE team_id = 89;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 89;\n\nselect * from users;\nSELECT * FROM social_accounts WHERE sociable_id = 1761;\nSELECT * FROM crm_configurations WHERE id = 70;\nselect * from accounts where crm_configuration_id = 70 order by id desc;\nselect * from leads where crm_configuration_id = 70 order by id desc;\nselect * from contacts where crm_configuration_id = 70 order by id desc;\nselect * from opportunities where crm_configuration_id = 70 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 70 order by id desc;\nselect * from crm_fields where crm_configuration_id = 70 order by id desc;\nselect * from crm_field_values where crm_field_id = 3536 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 70 order by id desc;\nselect * from stages where crm_configuration_id = 70 order by id desc;\nselect * from business_processes where crm_configuration_id = 70 order by id desc;\nselect * from business_process_stages where business_process_id = 34;\n\nselect * from contacts where id = 10468;\n\nselect * from crm_layouts where crm_configuration_id = 70;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;\nSELECT * FROM crm_fields WHERE id IN (3533,3534,3535);\n\nselect * from activities where crm_configuration_id = 70\nand (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;\n\nSELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;\nSELECT * FROM activities where crm_configuration_id = 69 ;\n\nSELECT * FROM users WHERE email LIKE '%jiminny_web_sa2@jiminny.com%';\nSELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;\nSELECT * FROM opportunities WHERE id = 385;\n\nselect * from participants p\njoin activities a on p.activity_id = a.id\nwhere a.crm_configuration_id = 70\nand (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);\nSELECT * FROM participants WHERE id = 1013638;\n\nselect * from teams where id = 90;\nselect * from users where team_id = 90;\nselect * from social_accounts where social_accounts.sociable_id IN (1960,1760);\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 71;\nselect * from invitations where team_id = 90;\n\nselect * from crm_configurations where id = 71;\nselect * from accounts where crm_configuration_id = 71 order by id desc;\nselect * from leads where crm_configuration_id = 71 order by id desc;\nselect * from contacts where crm_configuration_id = 71 order by id desc;\nselect * from opportunities where crm_configuration_id = 71 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 71 order by id desc;\nselect * from crm_fields where crm_configuration_id = 71 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 71 order by id desc;\nselect * from stages where crm_configuration_id = 71 order by id desc;\n\nselect * from users order by secondary_email desc;\nselect u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa\n join users u on sa.sociable_id = u.id\nwhere sa.provider = 'google' and u.email LIKE 'aneliya%';\n\nselect * from failed_jobs order by id desc;\n\nselect * from users where email = 'ben.allwright@learningpeople.co.uk' or secondary_email = 'ben.allwright@learningpeople.co.uk';\n\nselect * from teams;\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 39;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\n# ************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;\nSELECT * FROM crm_configurations WHERE id = 70;\n\nselect * from teams where id = 1;\nselect * from groups where team_id = 1;\nselect * from users where team_id = 1;\n\nselect o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o\njoin users u on o.user_id = u.id\njoin groups g on u.group_id = g.id\njoin role_user ru on u.id = ru.user_id\njoin roles r on ru.role_id = r.id\nwhere o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';\n\nselect * from role_user where user_id = 143;\nselect * from roles;\n\nselect * from role_user;\nselect * from groups where id = 9;\nselect * from scope_groups where group_id = 9;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations;\nSELECT * FROM social_accounts WHERE sociable_id = 121;\n\nhttps://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105\nhttps://crmsandbox.zoho.com/crm/\n\nhttps://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080\n https://crm.zoho.com/crm/\n org3469620\n\nSELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;\n\nselect * from users where email LIKE \"%mobile_automation_%\";\nselect * from social_accounts where sociable_id IN (2228);\nselect * from crm_profiles where user_id IN (2222,2223,2226,2227);\n\nselect * from teams order by id desc;\nSELECT * FROM users WHERE id = 2229;\nSELECT * FROM crm_profiles WHERE user_id = 2229;\nselect * from opportunities where crm_configuration_id = 88;\nselect * from crm_fields where crm_configuration_id = 88;\nselect * from crm_profiles where crm_configuration_id = 88;\n\nSELECT * FROM teams WHERE id = 1;\n\nSELECT * FROM users WHERE id = 143;\nSELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;\n\nhttps://app.staging.jiminny.com/ondemand?\n min_duration=1\n &\n only_recorded=1\n &\n user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e\n &\n sequence_number=2\n\n select * from users where team_id = 1 and email like '%stoyan%'\n\nselect * from coaching_feedbacks;\n\nselect * from teams;\nSELECT * FROM users WHERE team_id = 36;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from users where id = 143;\n\nSELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\n\nselect * from users where team_id = 2;\nselect * from activities where crm_configuration_id = 39\nand activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'\nAND user_id = 143\norder by id desc;\n\n# ************************************************************************************\nselect * from teams where id = 142; # 2312, 126\nselect * from team_settings;\nselect * from users where team_id = 142; # 21642\nSELECT * FROM social_accounts WHERE sociable_id = 21642;\nSELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;\nselect * from crm_profiles where id IN (93);\nselect * from invitations;\nselect * from team_features where team_id = 1;\n\nSELECT * FROM crm_configurations WHERE id = 126;\nselect * from accounts where crm_configuration_id = 126 order by id desc;\nselect * from leads where crm_configuration_id = 126 order by id desc;\nselect * from contacts where crm_configuration_id = 126 order by id desc;\nselect * from opportunities where crm_configuration_id = 126 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 126 order by id desc;\nselect * from crm_fields where crm_configuration_id = 126 # 11060\n# and type IN ('picklist', 'status')\n# and object_type = 'task'\norder by id desc;\n# 5731,5732,5733\nselect DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;\nselect * from crm_layouts where crm_configuration_id = 126 order by id desc;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);\nselect * from stages where crm_configuration_id = 126 order by id desc;\nselect * from business_processes where crm_configuration_id = 126 order by id desc;\nselect * from business_process_stages where business_process_id IN (76,75,74,73);\nselect * from playbooks where team_id = 142;\nselect * from playbook_layouts where playbook_id IN (108);\nSELECT * FROM playbook_categories WHERE playbook_id IN (108);\n\nselect * from teams where id = 130;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 2\nand sa.provider = 'hubspot';\n\nSELECT * FROM activities\n WHERE crm_configuration_id = 110;\n\nselect * from teams;\nselect * from crm_configurations;\n\nSELECT * FROM activities WHERE id = 628773;\nSELECT * FROM crm_profiles WHERE user_id = 1460;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from teams;\nselect ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id\njoin permission_role pr on pr.role_id = ru.role_id\n join permissions p on p.id = pr.permission_id\nwhere team_id = 495 and p.name IN ('dial');\n\nselect * from teams where id = 145;\nselect * from crm_configurations where id = 129;\nselect * from social_accounts where sociable_id = 2317;\nSELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;\n\nselect * from teams where id = 1;\nSELECT * FROM crm_layouts WHERE crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;\nSELECT * FROM crm_layout_entities WHERE id = 5507;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');\n\nselect * from teams;\nselect * from activities where crm_configuration_id = 14;\n\nSELECT * FROM social_accounts where provider = 'copper';\n\nselect * from activities where id = 628467;\nselect * from participants where activity_id = 628467;\n\nSELECT * FROM contacts WHERE id = 3969;\nSELECT * FROM accounts WHERE id = 177;\n\nSELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;\n\n# ********************* BH\nselect * from teams where id = 36;\nSELECT * FROM crm_configurations WHERE id = 21;\nselect * from activities where crm_configuration_id = 21 and id = 607901;\nselect * from activities where crm_configuration_id = 21;\n\nselect * roles;\nselect * from permissions;\nselect * from permission_role where permission_id = 226;\n\nselect * from migrations order by id desc;\n\n# mercury\n# neptune\n# earth\n\nselect * from teams;\nselect * from teams where id = 19;\nselect * from teams where id = 27;\nselect * from users where team_id = 27;\nSELECT * FROM crm_configurations WHERE id = 42;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from activities where id = 631461;\nSELECT * FROM crm_field_values WHERE crm_field_id = 180;\n\nselect * from teams where id = 2;\nSELECT * FROM social_accounts WHERE sociable_id = 89;\n\nSELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273\nselect * from activity_summary_logs where activity_id = 634273;\n\nselect * from sidekick_settings where team_id = 2;\n\nselect * from teams; # 2, 2\nSELECT * FROM crm_configurations WHERE team_id = 2; # 2\nselect * from team_features where team_id = 2;\nselect * from features;\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;\n\nselect * from automated_reports order by id desc;\nselect * from automated_report_results order by id desc;\nselect * from users where team_id = 1 and id IN (7160, 3248);\nselect * from migrations order by id desc;\n\nSELECT\n CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,\n u.email,\n sa.*,\n t.owner_id FROM social_accounts sa\nJOIN users u on u.id = sa.sociable_id\nJOIN teams t on t.id = u.team_id\nWHERE u.team_id = 1 and sa.provider = 'salesforce';\n\nselect * from teams where id = 1;\nselect * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;\nselect * from groups where id = 565;\nselect * from playbooks where team_id = 1;\nselect * from playbooks where id = 175;\nselect * from playbook_categories where playbook_id = 175;\nselect * from users where team_id = 1;\nselect * from users where id = 7160;\nselect * from crm_profiles where user_id = 7160;\nselect * from features;\nselect\n *\n# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,\n# crm_configuration_id, crm_provider_id, transcription_id, status\nfrom activities where crm_configuration_id = 1 and type = 'conference'\n# and crm_provider_id IS NOT NULL\nand provider != 'uploader' and actual_start_time IS NOT NULL\nORDER by id desc;\nselect * from activities where id = 54747783; # 00UO400000pCzojMAC\n\nselect p.id, p.activity_type, pc.id, pc.name\nFROM playbooks p\njoin playbook_categories pc on p.id = pc.playbook_id\nwhere p.team_id = 1 and p.activity_type = 'event';\n\nSELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';\nSELECT * FROM crm_field_values WHERE crm_field_id = 4;\n\nselect * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id\nwhere crm_configuration_id = 1 and pl.playbook_id = 175;\n\nselect * from teams;\nSELECT r.* FROM automated_reports r\njoin teams t on r.team_id = t.id\nWHERE r.frequency = 'daily'\n and r.status = 1\nAND t.status = 'active'\nAND (r.expires_at >= now() OR r.expires_at IS NULL);\n\nselect * from automated_report_results where report_id IN (18, 33);\n\nselect * from activity_searches where id = 10932;\nselect * from automated_reports;\nselect * from automated_report_results where report_id IN (34, 35);","role_description":"text entry area","is_enabled":true,"is_focused":true,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Project","depth":3,"role_description":"text"},{"role":"AXButton","text":"Project","depth":3,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"New File or Directory…","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Expand Selected","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Collapse All","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Options","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false}]...
|
4320670858817783469
|
6686649039917036621
|
idle
|
accessibility
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
13
4
Previous Highlighted Error
Next Highlighted Error
<?php
declare(strict_types=1);
namespace Jiminny\Repositories;
use Carbon\CarbonImmutable;
use Illuminate\Database\Eloquent\Builder;
use Illuminate\Support\Carbon;
use Illuminate\Database\Eloquent\Collection;
use Illuminate\Pagination\LengthAwarePaginator;
use Illuminate\Support\Facades\DB;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\AutomatedReportResult;
use Jiminny\Models\Team;
use Jiminny\Models\User;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Jiminny\Services\Kiosk\AutomatedReports\ReportSort;
use Jiminny\Services\Kiosk\AutomatedReports\ReportSortDirection;
class AutomatedReportsRepository
{
/**
* Create a new automated report
*
* @param array $data
*
* @return AutomatedReport
*/
public function create(array $data): AutomatedReport
{
return AutomatedReport::create($data);
}
/**
* Find an automated report by UUID
*
* @param string $uuid
*
* @return AutomatedReport|null
*/
public function findByUuid(string $uuid): ?AutomatedReport
{
return AutomatedReport::where('uuid', AutomatedReport::toOptimized($uuid))->first();
}
/**
* Retrieve all standard (non-Ask Jiminny) automated reports.
*
* @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.
* @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.
*
* @return Collection<AutomatedReport>
*/
public function getAllStandardReports(
string $sortColumn = 'created_at',
string $sortDirection = 'desc'
): Collection {
return $this->buildSortedQuery($sortColumn, $sortDirection)
->whereNot('type', AutomatedReportsService::TYPE_ASK_JIMINNY)
->get();
}
/**
* Retrieve all Ask Jiminny reports created by the given user.
*
* @param User $user The user whose reports to retrieve.
* @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.
* @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.
*
* @return Collection<AutomatedReport>
*/
public function getAskJiminnyReportsByUser(
User $user,
string $sortColumn = 'created_at',
string $sortDirection = 'desc'
): Collection {
return $this->buildSortedQuery($sortColumn, $sortDirection)
->where('type', AutomatedReportsService::TYPE_ASK_JIMINNY)
->where('created_by', $user->getId())
->get();
}
private function buildSortedQuery(string $sortColumn, string $sortDirection): \Illuminate\Database\Eloquent\Builder
{
$allowedColumns = ['created_by', 'created_at'];
if (! in_array($sortColumn, $allowedColumns)) {
$sortColumn = 'created_at';
}
$sortDirection = strtolower($sortDirection) === 'asc' ? 'asc' : 'desc';
$query = AutomatedReport::query()->with(['creator', 'team']);
if ($sortColumn === 'created_by') {
$query->leftJoin('users', 'users.id', '=', 'automated_reports.created_by')
->orderByRaw("users.name COLLATE utf8mb4_unicode_ci {$sortDirection}")
->select('automated_reports.*');
} else {
$query->orderBy($sortColumn, $sortDirection);
}
return $query;
}
/**
* Get all active and enabled reports with active teams for the specified frequency.
*
* @param string $frequency
*
* @return Collection<AutomatedReport>
*/
public function getActiveReportsByFrequency(string $frequency): Collection
{
return AutomatedReport::where('automated_reports.status', true)
->where('automated_reports.frequency', $frequency)
->join('teams', 'automated_reports.team_id', '=', 'teams.id')
->where('teams.status', Team::STATUS_ACTIVE)
->where(function ($query) {
$query->whereNull('automated_reports.expires_at')
->orWhere('automated_reports.expires_at', '>=', now()->toDateString());
})
->select('automated_reports.*')
->get();
}
/**
* Update an automated report
*
* @param AutomatedReport $report
* @param array $data
*
* @return AutomatedReport
*/
public function update(AutomatedReport $report, array $data): AutomatedReport
{
$report->update($data);
return $report;
}
/**
* Create a new automated report result.
*
* @param array $data The data to create the automated report result with.
*
* @return AutomatedReportResult The newly created automated report result.
*/
public function createResult(array $data): AutomatedReportResult
{
return AutomatedReportResult::create($data);
}
/**
* Find an automated report result by UUID.
*
* @param string $uuid The UUID to find the automated report result with.
*
* @return AutomatedReportResult|null The automated report result if found, otherwise null.
*/
public function findResultByUuid(string $uuid): ?AutomatedReportResult
{
return AutomatedReportResult::where('uuid', AutomatedReportResult::toOptimized($uuid))->first();
}
public function findResultByUuidForUser(string $uuid, User $user): ?AutomatedReportResult
{
return AutomatedReportResult::query()
->where('uuid', AutomatedReportResult::toOptimized($uuid))
->whereHas('report', static function ($query) use ($user): void {
$query->where('team_id', $user->getTeamId())
->where('created_by', $user->getId());
})
->first();
}
public function findChildResult(AutomatedReportResult $result, string $type): ?AutomatedReportResult
{
return AutomatedReportResult::query()
->where('parent_id', $result->getId())
->where('media_type', $type)
->first();
}
public function getGeneratedNotSentResults(): Collection
{
return AutomatedReportResult::query()
->whereNotNull('generated_at')
->whereNull('sent_at')
->where('status', AutomatedReportResult::STATUS_GENERATED)
->whereHas('report')
->with('report')
->get();
}
public function getPaginatedUserReports(
User $user,
ReportSort $sort,
ReportSortDirection $sortDirection,
int $resultsPerPage,
int $page,
?Carbon $fromDate,
?Carbon $toDate,
array $teamIds,
array $reportTypes,
?string $name,
): LengthAwarePaginator {
$query = AutomatedReportResult::query()
->whereNotNull('automated_report_results.generated_at')
->join('automated_reports', 'automated_report_results.report_id', '=', 'automated_reports.id')
->where('automated_reports.team_id', $user->getTeamId())
->whereJsonContains('automated_reports.recipients->users', $user->getId())
->orderByRaw("$sort->value COLLATE utf8mb4_unicode_ci {$sortDirection->value}")
->select('automated_report_results.*')
->with('report.team');
if ($fromDate !== null && $toDate !== null) {
$query->whereBetween('generated_at', [$fromDate, $toDate]);
}
if (! empty($teamIds)) {
$query->where(function ($q) use ($teamIds) {
foreach ($teamIds as $id) {
$q->orWhereJsonContains('automated_reports.groups', $id);
}
});
}
if (! empty($reportTypes)) {
$query->whereIn('automated_reports.type', $reportTypes);
}
if (! empty($name)) {
$query->whereLike('name', "%$name%");
}
return $query->paginate($resultsPerPage, ['*'], 'page', $page);
}
public function countUserReports(User $user): int
{
return AutomatedReportResult::query()
->whereNotNull('generated_at')
->whereNotNull('sent_at')
->whereHas('report', function ($q) use ($user) {
$q->where('team_id', $user->getTeamId())
->whereJsonContains('recipients->users', $user->getId());
})
->count();
}
/**
* Get report IDs for a specific team
*
* @param Team $team
*
* @return \Illuminate\Support\Collection
*/
public function getReportIdsByTeam(Team $team): \Illuminate\Support\Collection
{
return AutomatedReport::where('team_id', $team->getId())->pluck('id');
}
/**
* Get all reports for a specific team
*
* @param Team $team
*
* @return Collection
*/
public function getReportsByTeam(Team $team): Collection
{
return AutomatedReport::where('team_id', $team->getId())->get();
}
/**
* Get all report results for a specific report
*
* @param AutomatedReport $report
*
* @return Collection
*/
public function getResultsByReport(AutomatedReport $report): Collection
{
return $this->getResultsByReportQuery($report)->get();
}
public function getResultsByReportQuery(AutomatedReport $report): Builder
{
return AutomatedReportResult::where('report_id', $report->getId());
}
public function getReportResultsQueryForRetention(Team $team, CarbonImmutable $retentionDate): Builder
{
$reportIds = $this->getReportIdsByTeam($team);
return AutomatedReportResult::query()->whereIn('report_id', $reportIds)
->whereRaw('IFNULL(generated_at, created_at) <= ?', [$retentionDate]);
}
/**
* @param int|null $teamId Optional team ID to filter results
*
* @return \Illuminate\Support\Collection<int, int> Collection of team IDs
*/
public function getTeamIdsWithReportsResults(?int $teamId = null): \Illuminate\Support\Collection
{
$query = DB::table('automated_reports')
->join('teams', 'automated_reports.team_id', '=', 'teams.id')
->select('teams.id')
->distinct();
if ($teamId !== null) {
$query->where('teams.id', $teamId);
}
return $query->pluck('teams.id');
}
}
Execute
Explain Plan
Browse Query History
View Parameters
Open Query Execution Settings…
In-Editor Results
Tx: Auto
Cancel Running Statements
Playground
jiminny
Sync Changes
Hide This Notification
Code changed:
Hide
16
13
13
Previous Highlighted Error
Next Highlighted Error
SELECT * FROM teams WHERE id = 1;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;
SELECT * FROM crm_fields WHERE id = 2234;
SELECT * FROM crm_field_values WHERE crm_field_id = 2234;
select * from crm_profiles where user_id = 143;
select * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO
select * from business_processes where crm_configuration_id = 39;
# 01941000000H669AAC, 01941000000H66JAAS
select * from record_type_field_values
where record_type_id IN (24);
select * from crm_field_values where id IN (2730);
select * from crm_configurations where id = 39;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce'; #1035
select * from users where team_id = 1; # 222 group 3
SELECT * FROM activities WHERE user_id = 222 order by id desc;
select * from sidekick_settings where team_id = 1;
select * from teams where id = 1;
select * from team_features where team_id = 1;
select * from activities where crm_configuration_id = 2
and provider = 'ms-teams' and id = 608765;
SELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';
select * from sidekick_settings where team_id = 2;
SELECT * FROM activities WHERE id = 608660;
select * from activity_summary_logs where activity_id = 608660;
select * from ai_prompts where transcription_id = 11214;
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;
# id: 608818, crm: 59628809737
SELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;
# id: 608821, crm: 59632069252
SELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,
playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,
scheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at
FROM activities a
join calendar_events ce on a.calendar_event_id = ce.id
WHERE a.id IN (608818, 608821);
select * from users where team_id = 1;
select * from team_settings where team_id = 1;
select * from crm_profiles where crm_configuration_id = 39 order by user_id;
select * from team_features where team_id = 1;
select * from users where team_id = 2;
SELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639
# Preslava N. Ivanova, grou id 3
SELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;
select * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';
select
a.id,
a.type,
a.scheduled_start_time,
a.actual_start_time,
a.created_at,
a.opportunity_id,
a.status
FROM activities a
WHERE opportunity_id = 344
and status IN ('completed', 'received', 'delivered')
and (
(a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))
;
SELECT * FROM users WHERE id = 222;
SELECT * FROM crm_profiles WHERE user_id = 222;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;
select * from group_deal_risk_types;
select * from opportunities where team_id = 1;
SELECT * FROM opportunities WHERE id = 315;
SELECT * FROM crm_field_data WHERE object_id = 315;
select * from crm_field_data where object_id = 260;
select * from generic_ai_prompts where subject_id = 315;
select * from teams; # 36, 21, 121, [EMAIL]
SELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';
# [PASSWORD_DOTS]
select * from teams where id = 1;
select * from crm_configurations where id = 39;
select * from users where team_id = 1;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 1;
# 1 - 00541000004281rAAA
# 204 - 0052g000003freeAAA
# 429 - 0052g000003qGOiAAM
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
select * from activities where type = 'softphone'
and created_at > '2024-12-11 15:24:36' order by id desc;
select * from activity_providers where team_id = 1;
select * from activity_provider_users where activity_provider_id = 328;
select * from opportunities where crm_configuration_id = 39
AND account_id = 178 AND is_closed = false
order by created_at DESC;
select * from contacts where id = 3952;
select * from accounts where id = 178;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations where id = 21;
select * from users where team_id = 36;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 36
and sa.provider = 'bullhorn';
select * from social_accounts where id = 348;
UPDATE social_accounts SET
provider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',
provider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',
expires = 1733998131,
state = 'connected'
WHERE id = 348;
# [PASSWORD_DOTS]
select * from teams where id = 31;
select * from crm_configurations where id = 18;
select * from users where team_id = 31; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 31;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 31
and sa.provider = 'close';
select * from contacts where crm_configuration_id = 18;
# [PASSWORD_DOTS] NEPTUNE [PASSWORD_DOTS]
select * from teams;
select * from users where id IN (1030, 1035, 1052);
select * from crm_configurations;
select * from users where team_id = 65; # 257
select * from team_settings where team_id = 65; # 257
select * from invitations where team_id = 65; # 257
select * from users where email = '[EMAIL]'; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 65;
select * from crm_configurations where id = 53;
select * from accounts where crm_configuration_id = 53 order by id desc;
select * from leads where crm_configuration_id = 53 order by id desc;
select * from contacts where crm_configuration_id = 53 order by id desc;
select * from opportunities where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 53 order by id desc;
select * from crm_fields where crm_configuration_id = 53 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 53 order by id desc;
select * from stages where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 13;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
and sa.provider = 'integration-app';
select * from contacts where crm_configuration_id = 13;
select * from social_accounts where sociable_id = 283;
SELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';
select * from activity_providers where team_id = 65;
SELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
;
# [PASSWORD_DOTS] STAGING [PASSWORD_DOTS]
SELECT * FROM teams;
SELECT * FROM teams WHERE id = 88;
SELECT * FROM teams WHERE id = 89;
select * from team_settings where team_id = 89;
SELECT * FROM users WHERE team_id = 89;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 89;
select * from users;
SELECT * FROM social_accounts WHERE sociable_id = 1761;
SELECT * FROM crm_configurations WHERE id = 70;
select * from accounts where crm_configuration_id = 70 order by id desc;
select * from leads where crm_configuration_id = 70 order by id desc;
select * from contacts where crm_configuration_id = 70 order by id desc;
select * from opportunities where crm_configuration_id = 70 order by id desc;
select * from crm_profiles where crm_configuration_id = 70 order by id desc;
select * from crm_fields where crm_configuration_id = 70 order by id desc;
select * from crm_field_values where crm_field_id = 3536 order by id desc;
select * from crm_layouts where crm_configuration_id = 70 order by id desc;
select * from stages where crm_configuration_id = 70 order by id desc;
select * from business_processes where crm_configuration_id = 70 order by id desc;
select * from business_process_stages where business_process_id = 34;
select * from contacts where id = 10468;
select * from crm_layouts where crm_configuration_id = 70;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;
SELECT * FROM crm_fields WHERE id IN (3533,3534,3535);
select * from activities where crm_configuration_id = 70
and (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;
SELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;
SELECT * FROM activities where crm_configuration_id = 69 ;
SELECT * FROM users WHERE email LIKE '%[EMAIL]%';
SELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;
SELECT * FROM opportunities WHERE id = 385;
select * from participants p
join activities a on p.activity_id = a.id
where a.crm_configuration_id = 70
and (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);
SELECT * FROM participants WHERE id = 1013638;
select * from teams where id = 90;
select * from users where team_id = 90;
select * from social_accounts where social_accounts.sociable_id IN (1960,1760);
SELECT * FROM crm_profiles WHERE crm_configuration_id = 71;
select * from invitations where team_id = 90;
select * from crm_configurations where id = 71;
select * from accounts where crm_configuration_id = 71 order by id desc;
select * from leads where crm_configuration_id = 71 order by id desc;
select * from contacts where crm_configuration_id = 71 order by id desc;
select * from opportunities where crm_configuration_id = 71 order by id desc;
select * from crm_profiles where crm_configuration_id = 71 order by id desc;
select * from crm_fields where crm_configuration_id = 71 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 71 order by id desc;
select * from stages where crm_configuration_id = 71 order by id desc;
select * from users order by secondary_email desc;
select u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa
join users u on sa.sociable_id = u.id
where sa.provider = 'google' and u.email LIKE 'aneliya%';
select * from failed_jobs order by id desc;
select * from users where email = '[EMAIL]' or secondary_email = '[EMAIL]';
select * from teams;
SELECT * FROM crm_profiles WHERE crm_configuration_id = 39;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;
SELECT * FROM crm_configurations WHERE id = 70;
select * from teams where id = 1;
select * from groups where team_id = 1;
select * from users where team_id = 1;
select o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o
join users u on o.user_id = u.id
join groups g on u.group_id = g.id
join role_user ru on u.id = ru.user_id
join roles r on ru.role_id = r.id
where o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';
select * from role_user where user_id = 143;
select * from roles;
select * from role_user;
select * from groups where id = 9;
select * from scope_groups where group_id = 9;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations;
SELECT * FROM social_accounts WHERE sociable_id = 121;
https://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105
https://crmsandbox.zoho.com/crm/
https://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080
https://crm.zoho.com/crm/
org3469620
SELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;
select * from users where email LIKE "%mobile_automation_%";
select * from social_accounts where sociable_id IN (2228);
select * from crm_profiles where user_id IN (2222,2223,2226,2227);
select * from teams order by id desc;
SELECT * FROM users WHERE id = 2229;
SELECT * FROM crm_profiles WHERE user_id = 2229;
select * from opportunities where crm_configuration_id = 88;
select * from crm_fields where crm_configuration_id = 88;
select * from crm_profiles where crm_configuration_id = 88;
SELECT * FROM teams WHERE id = 1;
SELECT * FROM users WHERE id = 143;
SELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;
https://app.staging.jiminny.com/ondemand?
min_duration=1
&
only_recorded=1
&
user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e
&
sequence_number=2
select * from users where team_id = 1 and email like '%stoyan%'
select * from coaching_feedbacks;
select * from teams;
SELECT * FROM users WHERE team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from users where id = 143;
SELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
select * from users where team_id = 2;
select * from activities where crm_configuration_id = 39
and activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'
AND user_id = 143
order by id desc;
# [PASSWORD_DOTS]
select * from teams where id = 142; # 2312, 126
select * from team_settings;
select * from users where team_id = 142; # 21642
SELECT * FROM social_accounts WHERE sociable_id = 21642;
SELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;
select * from crm_profiles where id IN (93);
select * from invitations;
select * from team_features where team_id = 1;
SELECT * FROM crm_configurations WHERE id = 126;
select * from accounts where crm_configuration_id = 126 order by id desc;
select * from leads where crm_configuration_id = 126 order by id desc;
select * from contacts where crm_configuration_id = 126 order by id desc;
select * from opportunities where crm_configuration_id = 126 order by id desc;
select * from crm_profiles where crm_configuration_id = 126 order by id desc;
select * from crm_fields where crm_configuration_id = 126 # 11060
# and type IN ('picklist', 'status')
# and object_type = 'task'
order by id desc;
# 5731,5732,5733
select DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;
select * from crm_layouts where crm_configuration_id = 126 order by id desc;
SELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);
select * from stages where crm_configuration_id = 126 order by id desc;
select * from business_processes where crm_configuration_id = 126 order by id desc;
select * from business_process_stages where business_process_id IN (76,75,74,73);
select * from playbooks where team_id = 142;
select * from playbook_layouts where playbook_id IN (108);
SELECT * FROM playbook_categories WHERE playbook_id IN (108);
select * from teams where id = 130;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 2
and sa.provider = 'hubspot';
SELECT * FROM activities
WHERE crm_configuration_id = 110;
select * from teams;
select * from crm_configurations;
SELECT * FROM activities WHERE id = 628773;
SELECT * FROM crm_profiles WHERE user_id = 1460;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from teams;
select ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id
join permission_role pr on pr.role_id = ru.role_id
join permissions p on p.id = pr.permission_id
where team_id = 495 and p.name IN ('dial');
select * from teams where id = 145;
select * from crm_configurations where id = 129;
select * from social_accounts where sociable_id = 2317;
SELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;
select * from teams where id = 1;
SELECT * FROM crm_layouts WHERE crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;
SELECT * FROM crm_layout_entities WHERE id = 5507;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');
select * from teams;
select * from activities where crm_configuration_id = 14;
SELECT * FROM social_accounts where provider = 'copper';
select * from activities where id = 628467;
select * from participants where activity_id = 628467;
SELECT * FROM contacts WHERE id = 3969;
SELECT * FROM accounts WHERE id = 177;
SELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;
# [PASSWORD_DOTS] BH
select * from teams where id = 36;
SELECT * FROM crm_configurations WHERE id = 21;
select * from activities where crm_configuration_id = 21 and id = 607901;
select * from activities where crm_configuration_id = 21;
select * roles;
select * from permissions;
select * from permission_role where permission_id = 226;
select * from migrations order by id desc;
# mercury
# neptune
# earth
select * from teams;
select * from teams where id = 19;
select * from teams where id = 27;
select * from users where team_id = 27;
SELECT * FROM crm_configurations WHERE id = 42;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from activities where id = 631461;
SELECT * FROM crm_field_values WHERE crm_field_id = 180;
select * from teams where id = 2;
SELECT * FROM social_accounts WHERE sociable_id = 89;
SELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273
select * from activity_summary_logs where activity_id = 634273;
select * from sidekick_settings where team_id = 2;
select * from teams; # 2, 2
SELECT * FROM crm_configurations WHERE team_id = 2; # 2
select * from team_features where team_id = 2;
select * from features;
SELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';
SELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;
select * from automated_reports order by id desc;
select * from automated_report_results order by id desc;
select * from users where team_id = 1 and id IN (7160, 3248);
select * from migrations order by id desc;
SELECT
CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,
u.email,
sa.*,
t.owner_id FROM social_accounts sa
JOIN users u on u.id = sa.sociable_id
JOIN teams t on t.id = u.team_id
WHERE u.team_id = 1 and sa.provider = 'salesforce';
select * from teams where id = 1;
select * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;
select * from groups where id = 565;
select * from playbooks where team_id = 1;
select * from playbooks where id = 175;
select * from playbook_categories where playbook_id = 175;
select * from users where team_id = 1;
select * from users where id = 7160;
select * from crm_profiles where user_id = 7160;
select * from features;
select
*
# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,
# crm_configuration_id, crm_provider_id, transcription_id, status
from activities where crm_configuration_id = 1 and type = 'conference'
# and crm_provider_id IS NOT NULL
and provider != 'uploader' and actual_start_time IS NOT NULL
ORDER by id desc;
select * from activities where id = 54747783; # 00UO400000pCzojMAC
select p.id, p.activity_type, pc.id, pc.name
FROM playbooks p
join playbook_categories pc on p.id = pc.playbook_id
where p.team_id = 1 and p.activity_type = 'event';
SELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';
SELECT * FROM crm_field_values WHERE crm_field_id = 4;
select * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id
where crm_configuration_id = 1 and pl.playbook_id = 175;
select * from teams;
SELECT r.* FROM automated_reports r
join teams t on r.team_id = t.id
WHERE r.frequency = 'daily'
and r.status = 1
AND t.status = 'active'
AND (r.expires_at >= now() OR r.expires_at IS NULL);
select * from automated_report_results where report_id IN (18, 33);
select * from activity_searches where id = 10932;
select * from automated_reports;
select * from automated_report_results where report_id IN (34, 35);
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
10549
|
|
10667
|
NULL
|
0
|
2026-04-14T08:52:37.721813+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776156757721_m1.jpg...
|
PhpStorm
|
faVsco.js – AddLayoutEntities.php
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
1
5
Previous Highlighted Error
Next Highlighted Error
<?php
namespace Jiminny\Console\Commands\Crm;
use Illuminate\Console\Command;
use Jiminny\Models\Team;
class AddLayoutEntities extends Command
{
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'crm:create-layout-entity
{--teamId=}
{--parentEntityId= : The layout entity label e.g. activity-summary}
{--crmLayoutId= : The crm layout id e.g. 6}
{--crmFieldId= : The crm provider field id}
{--searchable= : Setups the is_indexable/is_filterable field behaviour default: true}'
;
/**
* The console command description.
*
* @var string
*/
protected $description = 'Adds layouts to expose fields in the UI.';
/**
* Execute the console command.
*/
public function handle(): void
{
$teamId = $this->option('teamId');
$parentEntityId = $this->option('parentEntityId');
$crmLayoutId = $this->option('crmLayoutId');
$crmFieldId = $this->option('crmFieldId');
$isSearchable = $this->option('searchable');
if ($teamId == null
|| $parentEntityId === null
|| $crmLayoutId === null
|| $crmFieldId === null
) {
$this->error('Please provide all parameters.');
return;
}
$team = Team::idOrUUid($teamId);
if ($team === null) {
$this->error('Invalid team provided.');
return;
}
$crmConfig = $team->crm;
$layout = $crmConfig->layouts()->where('id', $crmLayoutId)->first();
if ($layout === null) {
$this->error('Invalid crmLayoutId provided.');
return;
}
$field = $crmConfig->fields()->where('crm_provider_id', $crmFieldId)->first();
if ($field === null) {
$this->error('Invalid field provided.');
return;
}
$existingEntity = $layout->entities()->where([
'crm_field_id' => $field->id,
])->first();
if ($existingEntity !== null) {
$this->error('The specified layout entity already exists.');
return;
}
$parentId = null;
$parentEntity = $layout->entities()->where('label', $parentEntityId)->first();
if ($parentEntity !== null) {
$parentId = $parentEntity->id;
}
$entity = $layout->entities()->create([
'crm_field_id' => $field->id,
'label' => $field->label,
'description' => $field->description,
'is_visible' => true,
'parent_entity_id' => $parentId,
]);
$isIndexable = true;
$isFilterable = true;
if ($isSearchable === false) {
$isIndexable = false;
$isFilterable = false;
}
$field->update([
'is_indexable' => $isIndexable,
'is_filterable' => $isFilterable,
]);
$this->comment('Created entity #' . $entity->id);
}
}
Execute
Explain Plan
Browse Query History
View Parameters
Open Query Execution Settings…
In-Editor Results
Tx: Auto
Cancel Running Statements
Playground
jiminny
Sync Changes
Hide This Notification
Code changed:
Hide
16
13
13
Previous Highlighted Error
Next Highlighted Error
SELECT * FROM teams WHERE id = 1;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;
SELECT * FROM crm_fields WHERE id = 2234;
SELECT * FROM crm_field_values WHERE crm_field_id = 2234;
select * from crm_profiles where user_id = 143;
select * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO
select * from business_processes where crm_configuration_id = 39;
# 01941000000H669AAC, 01941000000H66JAAS
select * from record_type_field_values
where record_type_id IN (24);
select * from crm_field_values where id IN (2730);
select * from crm_configurations where id = 39;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce'; #1035
select * from users where team_id = 1; # 222 group 3
SELECT * FROM activities WHERE user_id = 222 order by id desc;
select * from sidekick_settings where team_id = 1;
select * from teams where id = 1;
select * from team_features where team_id = 1;
select * from activities where crm_configuration_id = 2
and provider = 'ms-teams' and id = 608765;
SELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';
select * from sidekick_settings where team_id = 2;
SELECT * FROM activities WHERE id = 608660;
select * from activity_summary_logs where activity_id = 608660;
select * from ai_prompts where transcription_id = 11214;
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;
# id: 608818, crm: 59628809737
SELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;
# id: 608821, crm: 59632069252
SELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,
playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,
scheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at
FROM activities a
join calendar_events ce on a.calendar_event_id = ce.id
WHERE a.id IN (608818, 608821);
select * from users where team_id = 1;
select * from team_settings where team_id = 1;
select * from crm_profiles where crm_configuration_id = 39 order by user_id;
select * from team_features where team_id = 1;
select * from users where team_id = 2;
SELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639
# Preslava N. Ivanova, grou id 3
SELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;
select * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';
select
a.id,
a.type,
a.scheduled_start_time,
a.actual_start_time,
a.created_at,
a.opportunity_id,
a.status
FROM activities a
WHERE opportunity_id = 344
and status IN ('completed', 'received', 'delivered')
and (
(a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))
;
SELECT * FROM users WHERE id = 222;
SELECT * FROM crm_profiles WHERE user_id = 222;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;
select * from group_deal_risk_types;
select * from opportunities where team_id = 1;
SELECT * FROM opportunities WHERE id = 315;
SELECT * FROM crm_field_data WHERE object_id = 315;
select * from crm_field_data where object_id = 260;
select * from generic_ai_prompts where subject_id = 315;
select * from teams; # 36, 21, 121, [EMAIL]
SELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';
# [PASSWORD_DOTS]
select * from teams where id = 1;
select * from crm_configurations where id = 39;
select * from users where team_id = 1;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 1;
# 1 - 00541000004281rAAA
# 204 - 0052g000003freeAAA
# 429 - 0052g000003qGOiAAM
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
select * from activities where type = 'softphone'
and created_at > '2024-12-11 15:24:36' order by id desc;
select * from activity_providers where team_id = 1;
select * from activity_provider_users where activity_provider_id = 328;
select * from opportunities where crm_configuration_id = 39
AND account_id = 178 AND is_closed = false
order by created_at DESC;
select * from contacts where id = 3952;
select * from accounts where id = 178;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations where id = 21;
select * from users where team_id = 36;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 36
and sa.provider = 'bullhorn';
select * from social_accounts where id = 348;
UPDATE social_accounts SET
provider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',
provider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',
expires = 1733998131,
state = 'connected'
WHERE id = 348;
# [PASSWORD_DOTS]
select * from teams where id = 31;
select * from crm_configurations where id = 18;
select * from users where team_id = 31; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 31;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 31
and sa.provider = 'close';
select * from contacts where crm_configuration_id = 18;
# [PASSWORD_DOTS] NEPTUNE [PASSWORD_DOTS]
select * from teams;
select * from users where id IN (1030, 1035, 1052);
select * from crm_configurations;
select * from users where team_id = 65; # 257
select * from team_settings where team_id = 65; # 257
select * from invitations where team_id = 65; # 257
select * from users where email = '[EMAIL]'; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 65;
select * from crm_configurations where id = 53;
select * from accounts where crm_configuration_id = 53 order by id desc;
select * from leads where crm_configuration_id = 53 order by id desc;
select * from contacts where crm_configuration_id = 53 order by id desc;
select * from opportunities where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 53 order by id desc;
select * from crm_fields where crm_configuration_id = 53 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 53 order by id desc;
select * from stages where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 13;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
and sa.provider = 'integration-app';
select * from contacts where crm_configuration_id = 13;
select * from social_accounts where sociable_id = 283;
SELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';
select * from activity_providers where team_id = 65;
SELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
;
# [PASSWORD_DOTS] STAGING [PASSWORD_DOTS]
SELECT * FROM teams;
SELECT * FROM teams WHERE id = 88;
SELECT * FROM teams WHERE id = 89;
select * from team_settings where team_id = 89;
SELECT * FROM users WHERE team_id = 89;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 89;
select * from users;
SELECT * FROM social_accounts WHERE sociable_id = 1761;
SELECT * FROM crm_configurations WHERE id = 70;
select * from accounts where crm_configuration_id = 70 order by id desc;
select * from leads where crm_configuration_id = 70 order by id desc;
select * from contacts where crm_configuration_id = 70 order by id desc;
select * from opportunities where crm_configuration_id = 70 order by id desc;
select * from crm_profiles where crm_configuration_id = 70 order by id desc;
select * from crm_fields where crm_configuration_id = 70 order by id desc;
select * from crm_field_values where crm_field_id = 3536 order by id desc;
select * from crm_layouts where crm_configuration_id = 70 order by id desc;
select * from stages where crm_configuration_id = 70 order by id desc;
select * from business_processes where crm_configuration_id = 70 order by id desc;
select * from business_process_stages where business_process_id = 34;
select * from contacts where id = 10468;
select * from crm_layouts where crm_configuration_id = 70;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;
SELECT * FROM crm_fields WHERE id IN (3533,3534,3535);
select * from activities where crm_configuration_id = 70
and (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;
SELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;
SELECT * FROM activities where crm_configuration_id = 69 ;
SELECT * FROM users WHERE email LIKE '%[EMAIL]%';
SELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;
SELECT * FROM opportunities WHERE id = 385;
select * from participants p
join activities a on p.activity_id = a.id
where a.crm_configuration_id = 70
and (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);
SELECT * FROM participants WHERE id = 1013638;
select * from teams where id = 90;
select * from users where team_id = 90;
select * from social_accounts where social_accounts.sociable_id IN (1960,1760);
SELECT * FROM crm_profiles WHERE crm_configuration_id = 71;
select * from invitations where team_id = 90;
select * from crm_configurations where id = 71;
select * from accounts where crm_configuration_id = 71 order by id desc;
select * from leads where crm_configuration_id = 71 order by id desc;
select * from contacts where crm_configuration_id = 71 order by id desc;
select * from opportunities where crm_configuration_id = 71 order by id desc;
select * from crm_profiles where crm_configuration_id = 71 order by id desc;
select * from crm_fields where crm_configuration_id = 71 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 71 order by id desc;
select * from stages where crm_configuration_id = 71 order by id desc;
select * from users order by secondary_email desc;
select u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa
join users u on sa.sociable_id = u.id
where sa.provider = 'google' and u.email LIKE 'aneliya%';
select * from failed_jobs order by id desc;
select * from users where email = '[EMAIL]' or secondary_email = '[EMAIL]';
select * from teams;
SELECT * FROM crm_profiles WHERE crm_configuration_id = 39;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;
SELECT * FROM crm_configurations WHERE id = 70;
select * from teams where id = 1;
select * from groups where team_id = 1;
select * from users where team_id = 1;
select o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o
join users u on o.user_id = u.id
join groups g on u.group_id = g.id
join role_user ru on u.id = ru.user_id
join roles r on ru.role_id = r.id
where o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';
select * from role_user where user_id = 143;
select * from roles;
select * from role_user;
select * from groups where id = 9;
select * from scope_groups where group_id = 9;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations;
SELECT * FROM social_accounts WHERE sociable_id = 121;
https://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105
https://crmsandbox.zoho.com/crm/
https://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080
https://crm.zoho.com/crm/
org3469620
SELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;
select * from users where email LIKE "%mobile_automation_%";
select * from social_accounts where sociable_id IN (2228);
select * from crm_profiles where user_id IN (2222,2223,2226,2227);
select * from teams order by id desc;
SELECT * FROM users WHERE id = 2229;
SELECT * FROM crm_profiles WHERE user_id = 2229;
select * from opportunities where crm_configuration_id = 88;
select * from crm_fields where crm_configuration_id = 88;
select * from crm_profiles where crm_configuration_id = 88;
SELECT * FROM teams WHERE id = 1;
SELECT * FROM users WHERE id = 143;
SELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;
https://app.staging.jiminny.com/ondemand?
min_duration=1
&
only_recorded=1
&
user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e
&
sequence_number=2
select * from users where team_id = 1 and email like '%stoyan%'
select * from coaching_feedbacks;
select * from teams;
SELECT * FROM users WHERE team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from users where id = 143;
SELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
select * from users where team_id = 2;
select * from activities where crm_configuration_id = 39
and activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'
AND user_id = 143
order by id desc;
# [PASSWORD_DOTS]
select * from teams where id = 142; # 2312, 126
select * from team_settings;
select * from users where team_id = 142; # 21642
SELECT * FROM social_accounts WHERE sociable_id = 21642;
SELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;
select * from crm_profiles where id IN (93);
select * from invitations;
select * from team_features where team_id = 1;
SELECT * FROM crm_configurations WHERE id = 126;
select * from accounts where crm_configuration_id = 126 order by id desc;
select * from leads where crm_configuration_id = 126 order by id desc;
select * from contacts where crm_configuration_id = 126 order by id desc;
select * from opportunities where crm_configuration_id = 126 order by id desc;
select * from crm_profiles where crm_configuration_id = 126 order by id desc;
select * from crm_fields where crm_configuration_id = 126 # 11060
# and type IN ('picklist', 'status')
# and object_type = 'task'
order by id desc;
# 5731,5732,5733
select DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;
select * from crm_layouts where crm_configuration_id = 126 order by id desc;
SELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);
select * from stages where crm_configuration_id = 126 order by id desc;
select * from business_processes where crm_configuration_id = 126 order by id desc;
select * from business_process_stages where business_process_id IN (76,75,74,73);
select * from playbooks where team_id = 142;
select * from playbook_layouts where playbook_id IN (108);
SELECT * FROM playbook_categories WHERE playbook_id IN (108);
select * from teams where id = 130;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 2
and sa.provider = 'hubspot';
SELECT * FROM activities
WHERE crm_configuration_id = 110;
select * from teams;
select * from crm_configurations;
SELECT * FROM activities WHERE id = 628773;
SELECT * FROM crm_profiles WHERE user_id = 1460;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from teams;
select ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id
join permission_role pr on pr.role_id = ru.role_id
join permissions p on p.id = pr.permission_id
where team_id = 495 and p.name IN ('dial');
select * from teams where id = 145;
select * from crm_configurations where id = 129;
select * from social_accounts where sociable_id = 2317;
SELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;
select * from teams where id = 1;
SELECT * FROM crm_layouts WHERE crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;
SELECT * FROM crm_layout_entities WHERE id = 5507;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');
select * from teams;
select * from activities where crm_configuration_id = 14;
SELECT * FROM social_accounts where provider = 'copper';
select * from activities where id = 628467;
select * from participants where activity_id = 628467;
SELECT * FROM contacts WHERE id = 3969;
SELECT * FROM accounts WHERE id = 177;
SELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;
# [PASSWORD_DOTS] BH
select * from teams where id = 36;
SELECT * FROM crm_configurations WHERE id = 21;
select * from activities where crm_configuration_id = 21 and id = 607901;
select * from activities where crm_configuration_id = 21;
select * roles;
select * from permissions;
select * from permission_role where permission_id = 226;
select * from migrations order by id desc;
# mercury
# neptune
# earth
select * from teams;
select * from teams where id = 19;
select * from teams where id = 27;
select * from users where team_id = 27;
SELECT * FROM crm_configurations WHERE id = 42;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from activities where id = 631461;
SELECT * FROM crm_field_values WHERE crm_field_id = 180;
select * from teams where id = 2;
SELECT * FROM social_accounts WHERE sociable_id = 89;
SELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273
select * from activity_summary_logs where activity_id = 634273;
select * from sidekick_settings where team_id = 2;
select * from teams; # 2, 2
SELECT * FROM crm_configurations WHERE team_id = 2; # 2
select * from team_features where team_id = 2;
select * from features;
SELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';
SELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;
select * from automated_reports order by id desc;
select * from automated_report_results order by id desc;
select * from users where team_id = 1 and id IN (7160, 3248);
select * from migrations order by id desc;
SELECT
CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,
u.email,
sa.*,
t.owner_id FROM social_accounts sa
JOIN users u on u.id = sa.sociable_id
JOIN teams t on t.id = u.team_id
WHERE u.team_id = 1 and sa.provider = 'salesforce';
select * from teams where id = 1;
select * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;
select * from groups where id = 565;
select * from playbooks where team_id = 1;
select * from playbooks where id = 175;
select * from playbook_categories where playbook_id = 175;
select * from users where team_id = 1;
select * from users where id = 7160;
select * from crm_profiles where user_id = 7160;
select * from features;
select
*
# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,
# crm_configuration_id, crm_provider_id, transcription_id, status
from activities where crm_configuration_id = 1 and type = 'conference'
# and crm_provider_id IS NOT NULL
and provider != 'uploader' and actual_start_time IS NOT NULL
ORDER by id desc;
select * from activities where id = 54747783; # 00UO400000pCzojMAC
select p.id, p.activity_type, pc.id, pc.name
FROM playbooks p
join playbook_categories pc on p.id = pc.playbook_id
where p.team_id = 1 and p.activity_type = 'event';
SELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';
SELECT * FROM crm_field_values WHERE crm_field_id = 4;
select * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id
where crm_configuration_id = 1 and pl.playbook_id = 175;
select * from teams;
SELECT r.* FROM automated_reports r
join teams t on r.team_id = t.id
WHERE r.frequency = 'daily'
and r.status = 1
AND t.status = 'active'
AND (r.expires_at >= now() OR r.expires_at IS NULL);
select * from automated_report_results where report_id IN (18, 33);
select * from activity_searches where id = 10932;
select * from activity_search_filters where activity_search_id = 10932;
select * from automated_reports;
select * from automated_report_results where report_id IN (34, 35);
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
[{"role":"AXButton","text" [{"role":"AXButton","text":"Project: faVsco.js, menu","depth":5,"help_text":"~/jiminny/app","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"#11894 on JY-18909-automated-reports-ask-jiminny, menu","depth":5,"help_text":"Pull request #11894 exists for current branch JY-18909-automated-reports-ask-jiminny, but local branch is out of sync with remote","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Start Listening for PHP Debug Connections","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"RequestGenerateAskJiminnyReportJobTest","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Run 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Debug 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"More Actions","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"JetBrains AI","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Search Everywhere","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"IDE and Project Settings","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.088194445,"height":0.027777778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"1","depth":4,"role_description":"text"},{"role":"AXStaticText","text":"5","depth":4,"role_description":"text"},{"role":"AXButton","text":"Previous Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Next Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"<?php\n\nnamespace Jiminny\\Console\\Commands\\Crm;\n\nuse Illuminate\\Console\\Command;\nuse Jiminny\\Models\\Team;\n\nclass AddLayoutEntities extends Command\n{\n /**\n * The name and signature of the console command.\n *\n * @var string\n */\n protected $signature = 'crm:create-layout-entity\n {--teamId=}\n {--parentEntityId= : The layout entity label e.g. activity-summary}\n {--crmLayoutId= : The crm layout id e.g. 6}\n {--crmFieldId= : The crm provider field id}\n {--searchable= : Setups the is_indexable/is_filterable field behaviour default: true}'\n ;\n\n /**\n * The console command description.\n *\n * @var string\n */\n protected $description = 'Adds layouts to expose fields in the UI.';\n\n\n /**\n * Execute the console command.\n */\n public function handle(): void\n {\n $teamId = $this->option('teamId');\n $parentEntityId = $this->option('parentEntityId');\n $crmLayoutId = $this->option('crmLayoutId');\n $crmFieldId = $this->option('crmFieldId');\n $isSearchable = $this->option('searchable');\n\n if ($teamId == null\n || $parentEntityId === null\n || $crmLayoutId === null\n || $crmFieldId === null\n ) {\n $this->error('Please provide all parameters.');\n\n return;\n }\n\n $team = Team::idOrUUid($teamId);\n\n if ($team === null) {\n $this->error('Invalid team provided.');\n\n return;\n }\n\n $crmConfig = $team->crm;\n\n $layout = $crmConfig->layouts()->where('id', $crmLayoutId)->first();\n\n if ($layout === null) {\n $this->error('Invalid crmLayoutId provided.');\n\n return;\n }\n\n $field = $crmConfig->fields()->where('crm_provider_id', $crmFieldId)->first();\n\n if ($field === null) {\n $this->error('Invalid field provided.');\n\n return;\n }\n\n $existingEntity = $layout->entities()->where([\n 'crm_field_id' => $field->id,\n ])->first();\n\n if ($existingEntity !== null) {\n $this->error('The specified layout entity already exists.');\n\n return;\n }\n\n $parentId = null;\n $parentEntity = $layout->entities()->where('label', $parentEntityId)->first();\n\n if ($parentEntity !== null) {\n $parentId = $parentEntity->id;\n }\n\n $entity = $layout->entities()->create([\n 'crm_field_id' => $field->id,\n 'label' => $field->label,\n 'description' => $field->description,\n 'is_visible' => true,\n 'parent_entity_id' => $parentId,\n ]);\n\n $isIndexable = true;\n $isFilterable = true;\n\n if ($isSearchable === false) {\n $isIndexable = false;\n $isFilterable = false;\n }\n\n $field->update([\n 'is_indexable' => $isIndexable,\n 'is_filterable' => $isFilterable,\n ]);\n\n $this->comment('Created entity #' . $entity->id);\n }\n}","depth":4,"value":"<?php\n\nnamespace Jiminny\\Console\\Commands\\Crm;\n\nuse Illuminate\\Console\\Command;\nuse Jiminny\\Models\\Team;\n\nclass AddLayoutEntities extends Command\n{\n /**\n * The name and signature of the console command.\n *\n * @var string\n */\n protected $signature = 'crm:create-layout-entity\n {--teamId=}\n {--parentEntityId= : The layout entity label e.g. activity-summary}\n {--crmLayoutId= : The crm layout id e.g. 6}\n {--crmFieldId= : The crm provider field id}\n {--searchable= : Setups the is_indexable/is_filterable field behaviour default: true}'\n ;\n\n /**\n * The console command description.\n *\n * @var string\n */\n protected $description = 'Adds layouts to expose fields in the UI.';\n\n\n /**\n * Execute the console command.\n */\n public function handle(): void\n {\n $teamId = $this->option('teamId');\n $parentEntityId = $this->option('parentEntityId');\n $crmLayoutId = $this->option('crmLayoutId');\n $crmFieldId = $this->option('crmFieldId');\n $isSearchable = $this->option('searchable');\n\n if ($teamId == null\n || $parentEntityId === null\n || $crmLayoutId === null\n || $crmFieldId === null\n ) {\n $this->error('Please provide all parameters.');\n\n return;\n }\n\n $team = Team::idOrUUid($teamId);\n\n if ($team === null) {\n $this->error('Invalid team provided.');\n\n return;\n }\n\n $crmConfig = $team->crm;\n\n $layout = $crmConfig->layouts()->where('id', $crmLayoutId)->first();\n\n if ($layout === null) {\n $this->error('Invalid crmLayoutId provided.');\n\n return;\n }\n\n $field = $crmConfig->fields()->where('crm_provider_id', $crmFieldId)->first();\n\n if ($field === null) {\n $this->error('Invalid field provided.');\n\n return;\n }\n\n $existingEntity = $layout->entities()->where([\n 'crm_field_id' => $field->id,\n ])->first();\n\n if ($existingEntity !== null) {\n $this->error('The specified layout entity already exists.');\n\n return;\n }\n\n $parentId = null;\n $parentEntity = $layout->entities()->where('label', $parentEntityId)->first();\n\n if ($parentEntity !== null) {\n $parentId = $parentEntity->id;\n }\n\n $entity = $layout->entities()->create([\n 'crm_field_id' => $field->id,\n 'label' => $field->label,\n 'description' => $field->description,\n 'is_visible' => true,\n 'parent_entity_id' => $parentId,\n ]);\n\n $isIndexable = true;\n $isFilterable = true;\n\n if ($isSearchable === false) {\n $isIndexable = false;\n $isFilterable = false;\n }\n\n $field->update([\n 'is_indexable' => $isIndexable,\n 'is_filterable' => $isFilterable,\n ]);\n\n $this->comment('Created entity #' . $entity->id);\n }\n}","role_description":"text entry area","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Execute","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Explain Plan","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Browse Query History","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"View Parameters","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Open Query Execution Settings…","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"In-Editor Results","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Tx: Auto","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Cancel Running Statements","depth":4,"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Playground","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"jiminny","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.088194445,"height":0.027777778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"16","depth":4,"role_description":"text"},{"role":"AXStaticText","text":"13","depth":4,"role_description":"text"},{"role":"AXStaticText","text":"13","depth":4,"role_description":"text"},{"role":"AXButton","text":"Previous Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Next Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"SELECT * FROM teams WHERE id = 1;\n\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;\nSELECT * FROM crm_fields WHERE id = 2234;\nSELECT * FROM crm_field_values WHERE crm_field_id = 2234;\n\nselect * from crm_profiles where user_id = 143;\n\nselect * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO\nselect * from business_processes where crm_configuration_id = 39;\n# 01941000000H669AAC, 01941000000H66JAAS\n\nselect * from record_type_field_values\n where record_type_id IN (24);\n\nselect * from crm_field_values where id IN (2730);\n\nselect * from crm_configurations where id = 39;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce'; #1035\n\n\nselect * from users where team_id = 1; # 222 group 3\nSELECT * FROM activities WHERE user_id = 222 order by id desc;\nselect * from sidekick_settings where team_id = 1;\nselect * from teams where id = 1;\nselect * from team_features where team_id = 1;\n\nselect * from activities where crm_configuration_id = 2\nand provider = 'ms-teams' and id = 608765;\n\nSELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';\n\nselect * from sidekick_settings where team_id = 2;\n\nSELECT * FROM activities WHERE id = 608660;\nselect * from activity_summary_logs where activity_id = 608660;\nselect * from ai_prompts where transcription_id = 11214;\n\n# ********************************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;\n# id: 608818, crm: 59628809737\nSELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;\n# id: 608821, crm: 59632069252\nSELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,\nplaybook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,\nscheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at\nFROM activities a\njoin calendar_events ce on a.calendar_event_id = ce.id\nWHERE a.id IN (608818, 608821);\n\nselect * from users where team_id = 1;\nselect * from team_settings where team_id = 1;\nselect * from crm_profiles where crm_configuration_id = 39 order by user_id;\n\nselect * from team_features where team_id = 1;\n\nselect * from users where team_id = 2;\n\nSELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639\n# Preslava N. Ivanova, grou id 3\n\nSELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;\n\nselect * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';\n\nselect\n a.id,\n a.type,\n a.scheduled_start_time,\n a.actual_start_time,\n a.created_at,\n a.opportunity_id,\n a.status\nFROM activities a\nWHERE opportunity_id = 344\nand status IN ('completed', 'received', 'delivered')\nand (\n (a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))\n;\n\nSELECT * FROM users WHERE id = 222;\n\nSELECT * FROM crm_profiles WHERE user_id = 222;\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;\n\nselect * from group_deal_risk_types;\n\nselect * from opportunities where team_id = 1;\n\nSELECT * FROM opportunities WHERE id = 315;\nSELECT * FROM crm_field_data WHERE object_id = 315;\nselect * from crm_field_data where object_id = 260;\n\nselect * from generic_ai_prompts where subject_id = 315;\n\nselect * from teams; # 36, 21, 121, james.graham@bullhorn.jiminny.com\nSELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';\n\n# ************************************************************************************\nselect * from teams where id = 1;\nselect * from crm_configurations where id = 39;\nselect * from users where team_id = 1;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 1;\n# 1 - 00541000004281rAAA\n# 204 - 0052g000003freeAAA\n# 429 - 0052g000003qGOiAAM\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\nselect * from activities where type = 'softphone'\nand created_at > '2024-12-11 15:24:36' order by id desc;\n\nselect * from activity_providers where team_id = 1;\nselect * from activity_provider_users where activity_provider_id = 328;\n\nselect * from opportunities where crm_configuration_id = 39\nAND account_id = 178 AND is_closed = false\norder by created_at DESC;\n\nselect * from contacts where id = 3952;\nselect * from accounts where id = 178;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations where id = 21;\nselect * from users where team_id = 36;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 36;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 36\nand sa.provider = 'bullhorn';\n\nselect * from social_accounts where id = 348;\nUPDATE social_accounts SET\nprovider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',\nprovider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',\nexpires = 1733998131,\nstate = 'connected'\nWHERE id = 348;\n\n# ************************************************************************************\nselect * from teams where id = 31;\nselect * from crm_configurations where id = 18;\n\nselect * from users where team_id = 31; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 31;\n\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 31\nand sa.provider = 'close';\n\nselect * from contacts where crm_configuration_id = 18;\n\n# ********************** NEPTUNE **************************************************************\nselect * from teams;\nselect * from users where id IN (1030, 1035, 1052);\nselect * from crm_configurations;\n\nselect * from users where team_id = 65; # 257\nselect * from team_settings where team_id = 65; # 257\nselect * from invitations where team_id = 65; # 257\nselect * from users where email = 'integration-account@jiminny.com'; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 65;\n\nselect * from crm_configurations where id = 53;\nselect * from accounts where crm_configuration_id = 53 order by id desc;\nselect * from leads where crm_configuration_id = 53 order by id desc;\nselect * from contacts where crm_configuration_id = 53 order by id desc;\nselect * from opportunities where crm_configuration_id = 53 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 53 order by id desc;\nselect * from crm_fields where crm_configuration_id = 53 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 53 order by id desc;\nselect * from stages where crm_configuration_id = 53 order by id desc;\n\n\nselect * from crm_profiles where crm_configuration_id = 13;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\nand sa.provider = 'integration-app';\n\nselect * from contacts where crm_configuration_id = 13;\n\nselect * from social_accounts where sociable_id = 283;\n\nSELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';\n\nselect * from activity_providers where team_id = 65;\nSELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\n;\n\n# ***************************** STAGING ********************************************\nSELECT * FROM teams;\nSELECT * FROM teams WHERE id = 88;\nSELECT * FROM teams WHERE id = 89;\nselect * from team_settings where team_id = 89;\nSELECT * FROM users WHERE team_id = 89;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 89;\n\nselect * from users;\nSELECT * FROM social_accounts WHERE sociable_id = 1761;\nSELECT * FROM crm_configurations WHERE id = 70;\nselect * from accounts where crm_configuration_id = 70 order by id desc;\nselect * from leads where crm_configuration_id = 70 order by id desc;\nselect * from contacts where crm_configuration_id = 70 order by id desc;\nselect * from opportunities where crm_configuration_id = 70 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 70 order by id desc;\nselect * from crm_fields where crm_configuration_id = 70 order by id desc;\nselect * from crm_field_values where crm_field_id = 3536 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 70 order by id desc;\nselect * from stages where crm_configuration_id = 70 order by id desc;\nselect * from business_processes where crm_configuration_id = 70 order by id desc;\nselect * from business_process_stages where business_process_id = 34;\n\nselect * from contacts where id = 10468;\n\nselect * from crm_layouts where crm_configuration_id = 70;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;\nSELECT * FROM crm_fields WHERE id IN (3533,3534,3535);\n\nselect * from activities where crm_configuration_id = 70\nand (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;\n\nSELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;\nSELECT * FROM activities where crm_configuration_id = 69 ;\n\nSELECT * FROM users WHERE email LIKE '%jiminny_web_sa2@jiminny.com%';\nSELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;\nSELECT * FROM opportunities WHERE id = 385;\n\nselect * from participants p\njoin activities a on p.activity_id = a.id\nwhere a.crm_configuration_id = 70\nand (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);\nSELECT * FROM participants WHERE id = 1013638;\n\nselect * from teams where id = 90;\nselect * from users where team_id = 90;\nselect * from social_accounts where social_accounts.sociable_id IN (1960,1760);\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 71;\nselect * from invitations where team_id = 90;\n\nselect * from crm_configurations where id = 71;\nselect * from accounts where crm_configuration_id = 71 order by id desc;\nselect * from leads where crm_configuration_id = 71 order by id desc;\nselect * from contacts where crm_configuration_id = 71 order by id desc;\nselect * from opportunities where crm_configuration_id = 71 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 71 order by id desc;\nselect * from crm_fields where crm_configuration_id = 71 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 71 order by id desc;\nselect * from stages where crm_configuration_id = 71 order by id desc;\n\nselect * from users order by secondary_email desc;\nselect u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa\n join users u on sa.sociable_id = u.id\nwhere sa.provider = 'google' and u.email LIKE 'aneliya%';\n\nselect * from failed_jobs order by id desc;\n\nselect * from users where email = 'ben.allwright@learningpeople.co.uk' or secondary_email = 'ben.allwright@learningpeople.co.uk';\n\nselect * from teams;\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 39;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\n# ************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;\nSELECT * FROM crm_configurations WHERE id = 70;\n\nselect * from teams where id = 1;\nselect * from groups where team_id = 1;\nselect * from users where team_id = 1;\n\nselect o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o\njoin users u on o.user_id = u.id\njoin groups g on u.group_id = g.id\njoin role_user ru on u.id = ru.user_id\njoin roles r on ru.role_id = r.id\nwhere o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';\n\nselect * from role_user where user_id = 143;\nselect * from roles;\n\nselect * from role_user;\nselect * from groups where id = 9;\nselect * from scope_groups where group_id = 9;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations;\nSELECT * FROM social_accounts WHERE sociable_id = 121;\n\nhttps://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105\nhttps://crmsandbox.zoho.com/crm/\n\nhttps://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080\n https://crm.zoho.com/crm/\n org3469620\n\nSELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;\n\nselect * from users where email LIKE \"%mobile_automation_%\";\nselect * from social_accounts where sociable_id IN (2228);\nselect * from crm_profiles where user_id IN (2222,2223,2226,2227);\n\nselect * from teams order by id desc;\nSELECT * FROM users WHERE id = 2229;\nSELECT * FROM crm_profiles WHERE user_id = 2229;\nselect * from opportunities where crm_configuration_id = 88;\nselect * from crm_fields where crm_configuration_id = 88;\nselect * from crm_profiles where crm_configuration_id = 88;\n\nSELECT * FROM teams WHERE id = 1;\n\nSELECT * FROM users WHERE id = 143;\nSELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;\n\nhttps://app.staging.jiminny.com/ondemand?\n min_duration=1\n &\n only_recorded=1\n &\n user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e\n &\n sequence_number=2\n\n select * from users where team_id = 1 and email like '%stoyan%'\n\nselect * from coaching_feedbacks;\n\nselect * from teams;\nSELECT * FROM users WHERE team_id = 36;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from users where id = 143;\n\nSELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\n\nselect * from users where team_id = 2;\nselect * from activities where crm_configuration_id = 39\nand activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'\nAND user_id = 143\norder by id desc;\n\n# ************************************************************************************\nselect * from teams where id = 142; # 2312, 126\nselect * from team_settings;\nselect * from users where team_id = 142; # 21642\nSELECT * FROM social_accounts WHERE sociable_id = 21642;\nSELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;\nselect * from crm_profiles where id IN (93);\nselect * from invitations;\nselect * from team_features where team_id = 1;\n\nSELECT * FROM crm_configurations WHERE id = 126;\nselect * from accounts where crm_configuration_id = 126 order by id desc;\nselect * from leads where crm_configuration_id = 126 order by id desc;\nselect * from contacts where crm_configuration_id = 126 order by id desc;\nselect * from opportunities where crm_configuration_id = 126 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 126 order by id desc;\nselect * from crm_fields where crm_configuration_id = 126 # 11060\n# and type IN ('picklist', 'status')\n# and object_type = 'task'\norder by id desc;\n# 5731,5732,5733\nselect DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;\nselect * from crm_layouts where crm_configuration_id = 126 order by id desc;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);\nselect * from stages where crm_configuration_id = 126 order by id desc;\nselect * from business_processes where crm_configuration_id = 126 order by id desc;\nselect * from business_process_stages where business_process_id IN (76,75,74,73);\nselect * from playbooks where team_id = 142;\nselect * from playbook_layouts where playbook_id IN (108);\nSELECT * FROM playbook_categories WHERE playbook_id IN (108);\n\nselect * from teams where id = 130;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 2\nand sa.provider = 'hubspot';\n\nSELECT * FROM activities\n WHERE crm_configuration_id = 110;\n\nselect * from teams;\nselect * from crm_configurations;\n\nSELECT * FROM activities WHERE id = 628773;\nSELECT * FROM crm_profiles WHERE user_id = 1460;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from teams;\nselect ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id\njoin permission_role pr on pr.role_id = ru.role_id\n join permissions p on p.id = pr.permission_id\nwhere team_id = 495 and p.name IN ('dial');\n\nselect * from teams where id = 145;\nselect * from crm_configurations where id = 129;\nselect * from social_accounts where sociable_id = 2317;\nSELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;\n\nselect * from teams where id = 1;\nSELECT * FROM crm_layouts WHERE crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;\nSELECT * FROM crm_layout_entities WHERE id = 5507;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');\n\nselect * from teams;\nselect * from activities where crm_configuration_id = 14;\n\nSELECT * FROM social_accounts where provider = 'copper';\n\nselect * from activities where id = 628467;\nselect * from participants where activity_id = 628467;\n\nSELECT * FROM contacts WHERE id = 3969;\nSELECT * FROM accounts WHERE id = 177;\n\nSELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;\n\n# ********************* BH\nselect * from teams where id = 36;\nSELECT * FROM crm_configurations WHERE id = 21;\nselect * from activities where crm_configuration_id = 21 and id = 607901;\nselect * from activities where crm_configuration_id = 21;\n\nselect * roles;\nselect * from permissions;\nselect * from permission_role where permission_id = 226;\n\nselect * from migrations order by id desc;\n\n# mercury\n# neptune\n# earth\n\nselect * from teams;\nselect * from teams where id = 19;\nselect * from teams where id = 27;\nselect * from users where team_id = 27;\nSELECT * FROM crm_configurations WHERE id = 42;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from activities where id = 631461;\nSELECT * FROM crm_field_values WHERE crm_field_id = 180;\n\nselect * from teams where id = 2;\nSELECT * FROM social_accounts WHERE sociable_id = 89;\n\nSELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273\nselect * from activity_summary_logs where activity_id = 634273;\n\nselect * from sidekick_settings where team_id = 2;\n\nselect * from teams; # 2, 2\nSELECT * FROM crm_configurations WHERE team_id = 2; # 2\nselect * from team_features where team_id = 2;\nselect * from features;\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;\n\nselect * from automated_reports order by id desc;\nselect * from automated_report_results order by id desc;\nselect * from users where team_id = 1 and id IN (7160, 3248);\nselect * from migrations order by id desc;\n\nSELECT\n CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,\n u.email,\n sa.*,\n t.owner_id FROM social_accounts sa\nJOIN users u on u.id = sa.sociable_id\nJOIN teams t on t.id = u.team_id\nWHERE u.team_id = 1 and sa.provider = 'salesforce';\n\nselect * from teams where id = 1;\nselect * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;\nselect * from groups where id = 565;\nselect * from playbooks where team_id = 1;\nselect * from playbooks where id = 175;\nselect * from playbook_categories where playbook_id = 175;\nselect * from users where team_id = 1;\nselect * from users where id = 7160;\nselect * from crm_profiles where user_id = 7160;\nselect * from features;\nselect\n *\n# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,\n# crm_configuration_id, crm_provider_id, transcription_id, status\nfrom activities where crm_configuration_id = 1 and type = 'conference'\n# and crm_provider_id IS NOT NULL\nand provider != 'uploader' and actual_start_time IS NOT NULL\nORDER by id desc;\nselect * from activities where id = 54747783; # 00UO400000pCzojMAC\n\nselect p.id, p.activity_type, pc.id, pc.name\nFROM playbooks p\njoin playbook_categories pc on p.id = pc.playbook_id\nwhere p.team_id = 1 and p.activity_type = 'event';\n\nSELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';\nSELECT * FROM crm_field_values WHERE crm_field_id = 4;\n\nselect * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id\nwhere crm_configuration_id = 1 and pl.playbook_id = 175;\n\nselect * from teams;\nSELECT r.* FROM automated_reports r\njoin teams t on r.team_id = t.id\nWHERE r.frequency = 'daily'\n and r.status = 1\nAND t.status = 'active'\nAND (r.expires_at >= now() OR r.expires_at IS NULL);\n\nselect * from automated_report_results where report_id IN (18, 33);\n\nselect * from activity_searches where id = 10932;\nselect * from activity_search_filters where activity_search_id = 10932;\nselect * from automated_reports;\nselect * from automated_report_results where report_id IN (34, 35);","depth":4,"value":"SELECT * FROM teams WHERE id = 1;\n\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;\nSELECT * FROM crm_fields WHERE id = 2234;\nSELECT * FROM crm_field_values WHERE crm_field_id = 2234;\n\nselect * from crm_profiles where user_id = 143;\n\nselect * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO\nselect * from business_processes where crm_configuration_id = 39;\n# 01941000000H669AAC, 01941000000H66JAAS\n\nselect * from record_type_field_values\n where record_type_id IN (24);\n\nselect * from crm_field_values where id IN (2730);\n\nselect * from crm_configurations where id = 39;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce'; #1035\n\n\nselect * from users where team_id = 1; # 222 group 3\nSELECT * FROM activities WHERE user_id = 222 order by id desc;\nselect * from sidekick_settings where team_id = 1;\nselect * from teams where id = 1;\nselect * from team_features where team_id = 1;\n\nselect * from activities where crm_configuration_id = 2\nand provider = 'ms-teams' and id = 608765;\n\nSELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';\n\nselect * from sidekick_settings where team_id = 2;\n\nSELECT * FROM activities WHERE id = 608660;\nselect * from activity_summary_logs where activity_id = 608660;\nselect * from ai_prompts where transcription_id = 11214;\n\n# ********************************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;\n# id: 608818, crm: 59628809737\nSELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;\n# id: 608821, crm: 59632069252\nSELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,\nplaybook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,\nscheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at\nFROM activities a\njoin calendar_events ce on a.calendar_event_id = ce.id\nWHERE a.id IN (608818, 608821);\n\nselect * from users where team_id = 1;\nselect * from team_settings where team_id = 1;\nselect * from crm_profiles where crm_configuration_id = 39 order by user_id;\n\nselect * from team_features where team_id = 1;\n\nselect * from users where team_id = 2;\n\nSELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639\n# Preslava N. Ivanova, grou id 3\n\nSELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;\n\nselect * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';\n\nselect\n a.id,\n a.type,\n a.scheduled_start_time,\n a.actual_start_time,\n a.created_at,\n a.opportunity_id,\n a.status\nFROM activities a\nWHERE opportunity_id = 344\nand status IN ('completed', 'received', 'delivered')\nand (\n (a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))\n;\n\nSELECT * FROM users WHERE id = 222;\n\nSELECT * FROM crm_profiles WHERE user_id = 222;\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;\n\nselect * from group_deal_risk_types;\n\nselect * from opportunities where team_id = 1;\n\nSELECT * FROM opportunities WHERE id = 315;\nSELECT * FROM crm_field_data WHERE object_id = 315;\nselect * from crm_field_data where object_id = 260;\n\nselect * from generic_ai_prompts where subject_id = 315;\n\nselect * from teams; # 36, 21, 121, james.graham@bullhorn.jiminny.com\nSELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';\n\n# ************************************************************************************\nselect * from teams where id = 1;\nselect * from crm_configurations where id = 39;\nselect * from users where team_id = 1;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 1;\n# 1 - 00541000004281rAAA\n# 204 - 0052g000003freeAAA\n# 429 - 0052g000003qGOiAAM\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\nselect * from activities where type = 'softphone'\nand created_at > '2024-12-11 15:24:36' order by id desc;\n\nselect * from activity_providers where team_id = 1;\nselect * from activity_provider_users where activity_provider_id = 328;\n\nselect * from opportunities where crm_configuration_id = 39\nAND account_id = 178 AND is_closed = false\norder by created_at DESC;\n\nselect * from contacts where id = 3952;\nselect * from accounts where id = 178;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations where id = 21;\nselect * from users where team_id = 36;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 36;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 36\nand sa.provider = 'bullhorn';\n\nselect * from social_accounts where id = 348;\nUPDATE social_accounts SET\nprovider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',\nprovider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',\nexpires = 1733998131,\nstate = 'connected'\nWHERE id = 348;\n\n# ************************************************************************************\nselect * from teams where id = 31;\nselect * from crm_configurations where id = 18;\n\nselect * from users where team_id = 31; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 31;\n\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 31\nand sa.provider = 'close';\n\nselect * from contacts where crm_configuration_id = 18;\n\n# ********************** NEPTUNE **************************************************************\nselect * from teams;\nselect * from users where id IN (1030, 1035, 1052);\nselect * from crm_configurations;\n\nselect * from users where team_id = 65; # 257\nselect * from team_settings where team_id = 65; # 257\nselect * from invitations where team_id = 65; # 257\nselect * from users where email = 'integration-account@jiminny.com'; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 65;\n\nselect * from crm_configurations where id = 53;\nselect * from accounts where crm_configuration_id = 53 order by id desc;\nselect * from leads where crm_configuration_id = 53 order by id desc;\nselect * from contacts where crm_configuration_id = 53 order by id desc;\nselect * from opportunities where crm_configuration_id = 53 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 53 order by id desc;\nselect * from crm_fields where crm_configuration_id = 53 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 53 order by id desc;\nselect * from stages where crm_configuration_id = 53 order by id desc;\n\n\nselect * from crm_profiles where crm_configuration_id = 13;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\nand sa.provider = 'integration-app';\n\nselect * from contacts where crm_configuration_id = 13;\n\nselect * from social_accounts where sociable_id = 283;\n\nSELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';\n\nselect * from activity_providers where team_id = 65;\nSELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\n;\n\n# ***************************** STAGING ********************************************\nSELECT * FROM teams;\nSELECT * FROM teams WHERE id = 88;\nSELECT * FROM teams WHERE id = 89;\nselect * from team_settings where team_id = 89;\nSELECT * FROM users WHERE team_id = 89;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 89;\n\nselect * from users;\nSELECT * FROM social_accounts WHERE sociable_id = 1761;\nSELECT * FROM crm_configurations WHERE id = 70;\nselect * from accounts where crm_configuration_id = 70 order by id desc;\nselect * from leads where crm_configuration_id = 70 order by id desc;\nselect * from contacts where crm_configuration_id = 70 order by id desc;\nselect * from opportunities where crm_configuration_id = 70 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 70 order by id desc;\nselect * from crm_fields where crm_configuration_id = 70 order by id desc;\nselect * from crm_field_values where crm_field_id = 3536 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 70 order by id desc;\nselect * from stages where crm_configuration_id = 70 order by id desc;\nselect * from business_processes where crm_configuration_id = 70 order by id desc;\nselect * from business_process_stages where business_process_id = 34;\n\nselect * from contacts where id = 10468;\n\nselect * from crm_layouts where crm_configuration_id = 70;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;\nSELECT * FROM crm_fields WHERE id IN (3533,3534,3535);\n\nselect * from activities where crm_configuration_id = 70\nand (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;\n\nSELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;\nSELECT * FROM activities where crm_configuration_id = 69 ;\n\nSELECT * FROM users WHERE email LIKE '%jiminny_web_sa2@jiminny.com%';\nSELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;\nSELECT * FROM opportunities WHERE id = 385;\n\nselect * from participants p\njoin activities a on p.activity_id = a.id\nwhere a.crm_configuration_id = 70\nand (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);\nSELECT * FROM participants WHERE id = 1013638;\n\nselect * from teams where id = 90;\nselect * from users where team_id = 90;\nselect * from social_accounts where social_accounts.sociable_id IN (1960,1760);\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 71;\nselect * from invitations where team_id = 90;\n\nselect * from crm_configurations where id = 71;\nselect * from accounts where crm_configuration_id = 71 order by id desc;\nselect * from leads where crm_configuration_id = 71 order by id desc;\nselect * from contacts where crm_configuration_id = 71 order by id desc;\nselect * from opportunities where crm_configuration_id = 71 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 71 order by id desc;\nselect * from crm_fields where crm_configuration_id = 71 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 71 order by id desc;\nselect * from stages where crm_configuration_id = 71 order by id desc;\n\nselect * from users order by secondary_email desc;\nselect u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa\n join users u on sa.sociable_id = u.id\nwhere sa.provider = 'google' and u.email LIKE 'aneliya%';\n\nselect * from failed_jobs order by id desc;\n\nselect * from users where email = 'ben.allwright@learningpeople.co.uk' or secondary_email = 'ben.allwright@learningpeople.co.uk';\n\nselect * from teams;\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 39;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\n# ************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;\nSELECT * FROM crm_configurations WHERE id = 70;\n\nselect * from teams where id = 1;\nselect * from groups where team_id = 1;\nselect * from users where team_id = 1;\n\nselect o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o\njoin users u on o.user_id = u.id\njoin groups g on u.group_id = g.id\njoin role_user ru on u.id = ru.user_id\njoin roles r on ru.role_id = r.id\nwhere o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';\n\nselect * from role_user where user_id = 143;\nselect * from roles;\n\nselect * from role_user;\nselect * from groups where id = 9;\nselect * from scope_groups where group_id = 9;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations;\nSELECT * FROM social_accounts WHERE sociable_id = 121;\n\nhttps://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105\nhttps://crmsandbox.zoho.com/crm/\n\nhttps://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080\n https://crm.zoho.com/crm/\n org3469620\n\nSELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;\n\nselect * from users where email LIKE \"%mobile_automation_%\";\nselect * from social_accounts where sociable_id IN (2228);\nselect * from crm_profiles where user_id IN (2222,2223,2226,2227);\n\nselect * from teams order by id desc;\nSELECT * FROM users WHERE id = 2229;\nSELECT * FROM crm_profiles WHERE user_id = 2229;\nselect * from opportunities where crm_configuration_id = 88;\nselect * from crm_fields where crm_configuration_id = 88;\nselect * from crm_profiles where crm_configuration_id = 88;\n\nSELECT * FROM teams WHERE id = 1;\n\nSELECT * FROM users WHERE id = 143;\nSELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;\n\nhttps://app.staging.jiminny.com/ondemand?\n min_duration=1\n &\n only_recorded=1\n &\n user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e\n &\n sequence_number=2\n\n select * from users where team_id = 1 and email like '%stoyan%'\n\nselect * from coaching_feedbacks;\n\nselect * from teams;\nSELECT * FROM users WHERE team_id = 36;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from users where id = 143;\n\nSELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\n\nselect * from users where team_id = 2;\nselect * from activities where crm_configuration_id = 39\nand activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'\nAND user_id = 143\norder by id desc;\n\n# ************************************************************************************\nselect * from teams where id = 142; # 2312, 126\nselect * from team_settings;\nselect * from users where team_id = 142; # 21642\nSELECT * FROM social_accounts WHERE sociable_id = 21642;\nSELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;\nselect * from crm_profiles where id IN (93);\nselect * from invitations;\nselect * from team_features where team_id = 1;\n\nSELECT * FROM crm_configurations WHERE id = 126;\nselect * from accounts where crm_configuration_id = 126 order by id desc;\nselect * from leads where crm_configuration_id = 126 order by id desc;\nselect * from contacts where crm_configuration_id = 126 order by id desc;\nselect * from opportunities where crm_configuration_id = 126 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 126 order by id desc;\nselect * from crm_fields where crm_configuration_id = 126 # 11060\n# and type IN ('picklist', 'status')\n# and object_type = 'task'\norder by id desc;\n# 5731,5732,5733\nselect DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;\nselect * from crm_layouts where crm_configuration_id = 126 order by id desc;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);\nselect * from stages where crm_configuration_id = 126 order by id desc;\nselect * from business_processes where crm_configuration_id = 126 order by id desc;\nselect * from business_process_stages where business_process_id IN (76,75,74,73);\nselect * from playbooks where team_id = 142;\nselect * from playbook_layouts where playbook_id IN (108);\nSELECT * FROM playbook_categories WHERE playbook_id IN (108);\n\nselect * from teams where id = 130;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 2\nand sa.provider = 'hubspot';\n\nSELECT * FROM activities\n WHERE crm_configuration_id = 110;\n\nselect * from teams;\nselect * from crm_configurations;\n\nSELECT * FROM activities WHERE id = 628773;\nSELECT * FROM crm_profiles WHERE user_id = 1460;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from teams;\nselect ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id\njoin permission_role pr on pr.role_id = ru.role_id\n join permissions p on p.id = pr.permission_id\nwhere team_id = 495 and p.name IN ('dial');\n\nselect * from teams where id = 145;\nselect * from crm_configurations where id = 129;\nselect * from social_accounts where sociable_id = 2317;\nSELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;\n\nselect * from teams where id = 1;\nSELECT * FROM crm_layouts WHERE crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;\nSELECT * FROM crm_layout_entities WHERE id = 5507;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');\n\nselect * from teams;\nselect * from activities where crm_configuration_id = 14;\n\nSELECT * FROM social_accounts where provider = 'copper';\n\nselect * from activities where id = 628467;\nselect * from participants where activity_id = 628467;\n\nSELECT * FROM contacts WHERE id = 3969;\nSELECT * FROM accounts WHERE id = 177;\n\nSELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;\n\n# ********************* BH\nselect * from teams where id = 36;\nSELECT * FROM crm_configurations WHERE id = 21;\nselect * from activities where crm_configuration_id = 21 and id = 607901;\nselect * from activities where crm_configuration_id = 21;\n\nselect * roles;\nselect * from permissions;\nselect * from permission_role where permission_id = 226;\n\nselect * from migrations order by id desc;\n\n# mercury\n# neptune\n# earth\n\nselect * from teams;\nselect * from teams where id = 19;\nselect * from teams where id = 27;\nselect * from users where team_id = 27;\nSELECT * FROM crm_configurations WHERE id = 42;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from activities where id = 631461;\nSELECT * FROM crm_field_values WHERE crm_field_id = 180;\n\nselect * from teams where id = 2;\nSELECT * FROM social_accounts WHERE sociable_id = 89;\n\nSELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273\nselect * from activity_summary_logs where activity_id = 634273;\n\nselect * from sidekick_settings where team_id = 2;\n\nselect * from teams; # 2, 2\nSELECT * FROM crm_configurations WHERE team_id = 2; # 2\nselect * from team_features where team_id = 2;\nselect * from features;\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;\n\nselect * from automated_reports order by id desc;\nselect * from automated_report_results order by id desc;\nselect * from users where team_id = 1 and id IN (7160, 3248);\nselect * from migrations order by id desc;\n\nSELECT\n CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,\n u.email,\n sa.*,\n t.owner_id FROM social_accounts sa\nJOIN users u on u.id = sa.sociable_id\nJOIN teams t on t.id = u.team_id\nWHERE u.team_id = 1 and sa.provider = 'salesforce';\n\nselect * from teams where id = 1;\nselect * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;\nselect * from groups where id = 565;\nselect * from playbooks where team_id = 1;\nselect * from playbooks where id = 175;\nselect * from playbook_categories where playbook_id = 175;\nselect * from users where team_id = 1;\nselect * from users where id = 7160;\nselect * from crm_profiles where user_id = 7160;\nselect * from features;\nselect\n *\n# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,\n# crm_configuration_id, crm_provider_id, transcription_id, status\nfrom activities where crm_configuration_id = 1 and type = 'conference'\n# and crm_provider_id IS NOT NULL\nand provider != 'uploader' and actual_start_time IS NOT NULL\nORDER by id desc;\nselect * from activities where id = 54747783; # 00UO400000pCzojMAC\n\nselect p.id, p.activity_type, pc.id, pc.name\nFROM playbooks p\njoin playbook_categories pc on p.id = pc.playbook_id\nwhere p.team_id = 1 and p.activity_type = 'event';\n\nSELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';\nSELECT * FROM crm_field_values WHERE crm_field_id = 4;\n\nselect * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id\nwhere crm_configuration_id = 1 and pl.playbook_id = 175;\n\nselect * from teams;\nSELECT r.* FROM automated_reports r\njoin teams t on r.team_id = t.id\nWHERE r.frequency = 'daily'\n and r.status = 1\nAND t.status = 'active'\nAND (r.expires_at >= now() OR r.expires_at IS NULL);\n\nselect * from automated_report_results where report_id IN (18, 33);\n\nselect * from activity_searches where id = 10932;\nselect * from activity_search_filters where activity_search_id = 10932;\nselect * from automated_reports;\nselect * from automated_report_results where report_id IN (34, 35);","role_description":"text entry area","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Project","depth":3,"role_description":"text"},{"role":"AXButton","text":"Project","depth":3,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"New File or Directory…","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Expand Selected","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Collapse All","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Options","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false}]...
|
1882912414143491833
|
6686649039917069389
|
click
|
accessibility
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
1
5
Previous Highlighted Error
Next Highlighted Error
<?php
namespace Jiminny\Console\Commands\Crm;
use Illuminate\Console\Command;
use Jiminny\Models\Team;
class AddLayoutEntities extends Command
{
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'crm:create-layout-entity
{--teamId=}
{--parentEntityId= : The layout entity label e.g. activity-summary}
{--crmLayoutId= : The crm layout id e.g. 6}
{--crmFieldId= : The crm provider field id}
{--searchable= : Setups the is_indexable/is_filterable field behaviour default: true}'
;
/**
* The console command description.
*
* @var string
*/
protected $description = 'Adds layouts to expose fields in the UI.';
/**
* Execute the console command.
*/
public function handle(): void
{
$teamId = $this->option('teamId');
$parentEntityId = $this->option('parentEntityId');
$crmLayoutId = $this->option('crmLayoutId');
$crmFieldId = $this->option('crmFieldId');
$isSearchable = $this->option('searchable');
if ($teamId == null
|| $parentEntityId === null
|| $crmLayoutId === null
|| $crmFieldId === null
) {
$this->error('Please provide all parameters.');
return;
}
$team = Team::idOrUUid($teamId);
if ($team === null) {
$this->error('Invalid team provided.');
return;
}
$crmConfig = $team->crm;
$layout = $crmConfig->layouts()->where('id', $crmLayoutId)->first();
if ($layout === null) {
$this->error('Invalid crmLayoutId provided.');
return;
}
$field = $crmConfig->fields()->where('crm_provider_id', $crmFieldId)->first();
if ($field === null) {
$this->error('Invalid field provided.');
return;
}
$existingEntity = $layout->entities()->where([
'crm_field_id' => $field->id,
])->first();
if ($existingEntity !== null) {
$this->error('The specified layout entity already exists.');
return;
}
$parentId = null;
$parentEntity = $layout->entities()->where('label', $parentEntityId)->first();
if ($parentEntity !== null) {
$parentId = $parentEntity->id;
}
$entity = $layout->entities()->create([
'crm_field_id' => $field->id,
'label' => $field->label,
'description' => $field->description,
'is_visible' => true,
'parent_entity_id' => $parentId,
]);
$isIndexable = true;
$isFilterable = true;
if ($isSearchable === false) {
$isIndexable = false;
$isFilterable = false;
}
$field->update([
'is_indexable' => $isIndexable,
'is_filterable' => $isFilterable,
]);
$this->comment('Created entity #' . $entity->id);
}
}
Execute
Explain Plan
Browse Query History
View Parameters
Open Query Execution Settings…
In-Editor Results
Tx: Auto
Cancel Running Statements
Playground
jiminny
Sync Changes
Hide This Notification
Code changed:
Hide
16
13
13
Previous Highlighted Error
Next Highlighted Error
SELECT * FROM teams WHERE id = 1;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;
SELECT * FROM crm_fields WHERE id = 2234;
SELECT * FROM crm_field_values WHERE crm_field_id = 2234;
select * from crm_profiles where user_id = 143;
select * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO
select * from business_processes where crm_configuration_id = 39;
# 01941000000H669AAC, 01941000000H66JAAS
select * from record_type_field_values
where record_type_id IN (24);
select * from crm_field_values where id IN (2730);
select * from crm_configurations where id = 39;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce'; #1035
select * from users where team_id = 1; # 222 group 3
SELECT * FROM activities WHERE user_id = 222 order by id desc;
select * from sidekick_settings where team_id = 1;
select * from teams where id = 1;
select * from team_features where team_id = 1;
select * from activities where crm_configuration_id = 2
and provider = 'ms-teams' and id = 608765;
SELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';
select * from sidekick_settings where team_id = 2;
SELECT * FROM activities WHERE id = 608660;
select * from activity_summary_logs where activity_id = 608660;
select * from ai_prompts where transcription_id = 11214;
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;
# id: 608818, crm: 59628809737
SELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;
# id: 608821, crm: 59632069252
SELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,
playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,
scheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at
FROM activities a
join calendar_events ce on a.calendar_event_id = ce.id
WHERE a.id IN (608818, 608821);
select * from users where team_id = 1;
select * from team_settings where team_id = 1;
select * from crm_profiles where crm_configuration_id = 39 order by user_id;
select * from team_features where team_id = 1;
select * from users where team_id = 2;
SELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639
# Preslava N. Ivanova, grou id 3
SELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;
select * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';
select
a.id,
a.type,
a.scheduled_start_time,
a.actual_start_time,
a.created_at,
a.opportunity_id,
a.status
FROM activities a
WHERE opportunity_id = 344
and status IN ('completed', 'received', 'delivered')
and (
(a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))
;
SELECT * FROM users WHERE id = 222;
SELECT * FROM crm_profiles WHERE user_id = 222;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;
select * from group_deal_risk_types;
select * from opportunities where team_id = 1;
SELECT * FROM opportunities WHERE id = 315;
SELECT * FROM crm_field_data WHERE object_id = 315;
select * from crm_field_data where object_id = 260;
select * from generic_ai_prompts where subject_id = 315;
select * from teams; # 36, 21, 121, [EMAIL]
SELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';
# [PASSWORD_DOTS]
select * from teams where id = 1;
select * from crm_configurations where id = 39;
select * from users where team_id = 1;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 1;
# 1 - 00541000004281rAAA
# 204 - 0052g000003freeAAA
# 429 - 0052g000003qGOiAAM
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
select * from activities where type = 'softphone'
and created_at > '2024-12-11 15:24:36' order by id desc;
select * from activity_providers where team_id = 1;
select * from activity_provider_users where activity_provider_id = 328;
select * from opportunities where crm_configuration_id = 39
AND account_id = 178 AND is_closed = false
order by created_at DESC;
select * from contacts where id = 3952;
select * from accounts where id = 178;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations where id = 21;
select * from users where team_id = 36;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 36
and sa.provider = 'bullhorn';
select * from social_accounts where id = 348;
UPDATE social_accounts SET
provider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',
provider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',
expires = 1733998131,
state = 'connected'
WHERE id = 348;
# [PASSWORD_DOTS]
select * from teams where id = 31;
select * from crm_configurations where id = 18;
select * from users where team_id = 31; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 31;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 31
and sa.provider = 'close';
select * from contacts where crm_configuration_id = 18;
# [PASSWORD_DOTS] NEPTUNE [PASSWORD_DOTS]
select * from teams;
select * from users where id IN (1030, 1035, 1052);
select * from crm_configurations;
select * from users where team_id = 65; # 257
select * from team_settings where team_id = 65; # 257
select * from invitations where team_id = 65; # 257
select * from users where email = '[EMAIL]'; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 65;
select * from crm_configurations where id = 53;
select * from accounts where crm_configuration_id = 53 order by id desc;
select * from leads where crm_configuration_id = 53 order by id desc;
select * from contacts where crm_configuration_id = 53 order by id desc;
select * from opportunities where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 53 order by id desc;
select * from crm_fields where crm_configuration_id = 53 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 53 order by id desc;
select * from stages where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 13;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
and sa.provider = 'integration-app';
select * from contacts where crm_configuration_id = 13;
select * from social_accounts where sociable_id = 283;
SELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';
select * from activity_providers where team_id = 65;
SELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
;
# [PASSWORD_DOTS] STAGING [PASSWORD_DOTS]
SELECT * FROM teams;
SELECT * FROM teams WHERE id = 88;
SELECT * FROM teams WHERE id = 89;
select * from team_settings where team_id = 89;
SELECT * FROM users WHERE team_id = 89;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 89;
select * from users;
SELECT * FROM social_accounts WHERE sociable_id = 1761;
SELECT * FROM crm_configurations WHERE id = 70;
select * from accounts where crm_configuration_id = 70 order by id desc;
select * from leads where crm_configuration_id = 70 order by id desc;
select * from contacts where crm_configuration_id = 70 order by id desc;
select * from opportunities where crm_configuration_id = 70 order by id desc;
select * from crm_profiles where crm_configuration_id = 70 order by id desc;
select * from crm_fields where crm_configuration_id = 70 order by id desc;
select * from crm_field_values where crm_field_id = 3536 order by id desc;
select * from crm_layouts where crm_configuration_id = 70 order by id desc;
select * from stages where crm_configuration_id = 70 order by id desc;
select * from business_processes where crm_configuration_id = 70 order by id desc;
select * from business_process_stages where business_process_id = 34;
select * from contacts where id = 10468;
select * from crm_layouts where crm_configuration_id = 70;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;
SELECT * FROM crm_fields WHERE id IN (3533,3534,3535);
select * from activities where crm_configuration_id = 70
and (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;
SELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;
SELECT * FROM activities where crm_configuration_id = 69 ;
SELECT * FROM users WHERE email LIKE '%[EMAIL]%';
SELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;
SELECT * FROM opportunities WHERE id = 385;
select * from participants p
join activities a on p.activity_id = a.id
where a.crm_configuration_id = 70
and (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);
SELECT * FROM participants WHERE id = 1013638;
select * from teams where id = 90;
select * from users where team_id = 90;
select * from social_accounts where social_accounts.sociable_id IN (1960,1760);
SELECT * FROM crm_profiles WHERE crm_configuration_id = 71;
select * from invitations where team_id = 90;
select * from crm_configurations where id = 71;
select * from accounts where crm_configuration_id = 71 order by id desc;
select * from leads where crm_configuration_id = 71 order by id desc;
select * from contacts where crm_configuration_id = 71 order by id desc;
select * from opportunities where crm_configuration_id = 71 order by id desc;
select * from crm_profiles where crm_configuration_id = 71 order by id desc;
select * from crm_fields where crm_configuration_id = 71 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 71 order by id desc;
select * from stages where crm_configuration_id = 71 order by id desc;
select * from users order by secondary_email desc;
select u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa
join users u on sa.sociable_id = u.id
where sa.provider = 'google' and u.email LIKE 'aneliya%';
select * from failed_jobs order by id desc;
select * from users where email = '[EMAIL]' or secondary_email = '[EMAIL]';
select * from teams;
SELECT * FROM crm_profiles WHERE crm_configuration_id = 39;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;
SELECT * FROM crm_configurations WHERE id = 70;
select * from teams where id = 1;
select * from groups where team_id = 1;
select * from users where team_id = 1;
select o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o
join users u on o.user_id = u.id
join groups g on u.group_id = g.id
join role_user ru on u.id = ru.user_id
join roles r on ru.role_id = r.id
where o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';
select * from role_user where user_id = 143;
select * from roles;
select * from role_user;
select * from groups where id = 9;
select * from scope_groups where group_id = 9;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations;
SELECT * FROM social_accounts WHERE sociable_id = 121;
https://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105
https://crmsandbox.zoho.com/crm/
https://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080
https://crm.zoho.com/crm/
org3469620
SELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;
select * from users where email LIKE "%mobile_automation_%";
select * from social_accounts where sociable_id IN (2228);
select * from crm_profiles where user_id IN (2222,2223,2226,2227);
select * from teams order by id desc;
SELECT * FROM users WHERE id = 2229;
SELECT * FROM crm_profiles WHERE user_id = 2229;
select * from opportunities where crm_configuration_id = 88;
select * from crm_fields where crm_configuration_id = 88;
select * from crm_profiles where crm_configuration_id = 88;
SELECT * FROM teams WHERE id = 1;
SELECT * FROM users WHERE id = 143;
SELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;
https://app.staging.jiminny.com/ondemand?
min_duration=1
&
only_recorded=1
&
user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e
&
sequence_number=2
select * from users where team_id = 1 and email like '%stoyan%'
select * from coaching_feedbacks;
select * from teams;
SELECT * FROM users WHERE team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from users where id = 143;
SELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
select * from users where team_id = 2;
select * from activities where crm_configuration_id = 39
and activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'
AND user_id = 143
order by id desc;
# [PASSWORD_DOTS]
select * from teams where id = 142; # 2312, 126
select * from team_settings;
select * from users where team_id = 142; # 21642
SELECT * FROM social_accounts WHERE sociable_id = 21642;
SELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;
select * from crm_profiles where id IN (93);
select * from invitations;
select * from team_features where team_id = 1;
SELECT * FROM crm_configurations WHERE id = 126;
select * from accounts where crm_configuration_id = 126 order by id desc;
select * from leads where crm_configuration_id = 126 order by id desc;
select * from contacts where crm_configuration_id = 126 order by id desc;
select * from opportunities where crm_configuration_id = 126 order by id desc;
select * from crm_profiles where crm_configuration_id = 126 order by id desc;
select * from crm_fields where crm_configuration_id = 126 # 11060
# and type IN ('picklist', 'status')
# and object_type = 'task'
order by id desc;
# 5731,5732,5733
select DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;
select * from crm_layouts where crm_configuration_id = 126 order by id desc;
SELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);
select * from stages where crm_configuration_id = 126 order by id desc;
select * from business_processes where crm_configuration_id = 126 order by id desc;
select * from business_process_stages where business_process_id IN (76,75,74,73);
select * from playbooks where team_id = 142;
select * from playbook_layouts where playbook_id IN (108);
SELECT * FROM playbook_categories WHERE playbook_id IN (108);
select * from teams where id = 130;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 2
and sa.provider = 'hubspot';
SELECT * FROM activities
WHERE crm_configuration_id = 110;
select * from teams;
select * from crm_configurations;
SELECT * FROM activities WHERE id = 628773;
SELECT * FROM crm_profiles WHERE user_id = 1460;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from teams;
select ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id
join permission_role pr on pr.role_id = ru.role_id
join permissions p on p.id = pr.permission_id
where team_id = 495 and p.name IN ('dial');
select * from teams where id = 145;
select * from crm_configurations where id = 129;
select * from social_accounts where sociable_id = 2317;
SELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;
select * from teams where id = 1;
SELECT * FROM crm_layouts WHERE crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;
SELECT * FROM crm_layout_entities WHERE id = 5507;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');
select * from teams;
select * from activities where crm_configuration_id = 14;
SELECT * FROM social_accounts where provider = 'copper';
select * from activities where id = 628467;
select * from participants where activity_id = 628467;
SELECT * FROM contacts WHERE id = 3969;
SELECT * FROM accounts WHERE id = 177;
SELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;
# [PASSWORD_DOTS] BH
select * from teams where id = 36;
SELECT * FROM crm_configurations WHERE id = 21;
select * from activities where crm_configuration_id = 21 and id = 607901;
select * from activities where crm_configuration_id = 21;
select * roles;
select * from permissions;
select * from permission_role where permission_id = 226;
select * from migrations order by id desc;
# mercury
# neptune
# earth
select * from teams;
select * from teams where id = 19;
select * from teams where id = 27;
select * from users where team_id = 27;
SELECT * FROM crm_configurations WHERE id = 42;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from activities where id = 631461;
SELECT * FROM crm_field_values WHERE crm_field_id = 180;
select * from teams where id = 2;
SELECT * FROM social_accounts WHERE sociable_id = 89;
SELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273
select * from activity_summary_logs where activity_id = 634273;
select * from sidekick_settings where team_id = 2;
select * from teams; # 2, 2
SELECT * FROM crm_configurations WHERE team_id = 2; # 2
select * from team_features where team_id = 2;
select * from features;
SELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';
SELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;
select * from automated_reports order by id desc;
select * from automated_report_results order by id desc;
select * from users where team_id = 1 and id IN (7160, 3248);
select * from migrations order by id desc;
SELECT
CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,
u.email,
sa.*,
t.owner_id FROM social_accounts sa
JOIN users u on u.id = sa.sociable_id
JOIN teams t on t.id = u.team_id
WHERE u.team_id = 1 and sa.provider = 'salesforce';
select * from teams where id = 1;
select * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;
select * from groups where id = 565;
select * from playbooks where team_id = 1;
select * from playbooks where id = 175;
select * from playbook_categories where playbook_id = 175;
select * from users where team_id = 1;
select * from users where id = 7160;
select * from crm_profiles where user_id = 7160;
select * from features;
select
*
# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,
# crm_configuration_id, crm_provider_id, transcription_id, status
from activities where crm_configuration_id = 1 and type = 'conference'
# and crm_provider_id IS NOT NULL
and provider != 'uploader' and actual_start_time IS NOT NULL
ORDER by id desc;
select * from activities where id = 54747783; # 00UO400000pCzojMAC
select p.id, p.activity_type, pc.id, pc.name
FROM playbooks p
join playbook_categories pc on p.id = pc.playbook_id
where p.team_id = 1 and p.activity_type = 'event';
SELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';
SELECT * FROM crm_field_values WHERE crm_field_id = 4;
select * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id
where crm_configuration_id = 1 and pl.playbook_id = 175;
select * from teams;
SELECT r.* FROM automated_reports r
join teams t on r.team_id = t.id
WHERE r.frequency = 'daily'
and r.status = 1
AND t.status = 'active'
AND (r.expires_at >= now() OR r.expires_at IS NULL);
select * from automated_report_results where report_id IN (18, 33);
select * from activity_searches where id = 10932;
select * from activity_search_filters where activity_search_id = 10932;
select * from automated_reports;
select * from automated_report_results where report_id IN (34, 35);
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
10665
|
|
10668
|
NULL
|
0
|
2026-04-14T08:52:37.730807+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776156757730_m2.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
PhpStormFileEditViewNavigateCodeLaravelRefactorFV PhpStormFileEditViewNavigateCodeLaravelRefactorFV faVsco.s v#11894 on JY-18909-automated-reports-ask-iminny K vProject v© ReportController.phpToolsWindowHelp> D Hubspot> D IntegrationApp© AddLayoutEntities.pt© AutologDelayedCom© BullhornCommandAk© BullhornPingCommar© BullhornSearchComn© BullhornSessionComCheckActivityLoggal© CleanDuplicateFieldI© FullSyncOpportunityi(C) LogActivitiesComma© ManageSyncStrateg!© MatchCrmObjectsCa© MatchOpportunityAc© MigrateProvider.php© ProcessHubspotObje© PurgeDeletedOpport© ResetGovernorLimits© SendNotLogged.php© SetupActivity TypeFo© SetupCloseCrm.php© SetupCopperCrm.ph© SetupCrmCommand.© SetupLayouts.php© SyncAccount.php© SyncContact.php© SyncFieldMetadata.f© SyncHubspotActivel© SyncLead.php© SyncObjects.php© SyncOpportunitiesMil© SyncOpportunity.php• SyncProfileMetadata© SyncTeamMetadata.© UpdateOpportunityS• DeallnsightsO DevD DialersD DTOSD ElasticsearchEngagementStats1 Gecko=xportM Livestream• Mailboxes• Migrate_ PlaybackThemesD PlaybooksPlaylists0 PostmarkC ProphetAiv D Reports© AutomatedReportsCi© AutomatedReportsRe(C) AutomatedReportsSi© CreateMockAskJimir© DeleteReportComma© GenerateMarketingR© Team.phpAulomaleakeporscommand.ono© AutomatedReportsService.phpCrealenctivityLoggeaevent.oneJiminnyDeouecommana.ongAutomatedReportsSendCommand.php© AddLayoutEntities.php xC) Team.php© AutomatedReportsRepository.phpCreateHeldActivityEvent.php© TrackProviderInstalledEvent.php© UserPilotActivityListener.php© ActivityLogged.phpC RequestGenerateAskJiminnyReportJob.phpRequestGeneratekeporJob.ong= custom.log= laravel.log< console PRODAl console (EU]© AskJiminnyReportActivityService.phpX:Auto vA SF ljiminny@localhost]A HS_local [jiminny@localhost]A console [STAGING] X© RequestGenerateAskJiminnyReportJobTest.phpPlaygroundDo jiminny016 A13 M13 A V519© AutomatedReportResult.php© AutomatedReport.phpclass AddLayoutEntities extends Commandpublic function handle): vold*teamia = $tn1s->optiont key: "teamiау:3739$parentEntityId = $this->option( key: 'parentEntityId');$crmLayoutId = $this->option( key: 'ermLayoutid');ocrnrrelolo = "us->ootonl key:eoeeieldi:nspearchaoue = "uns-ooron key.searchadlersa.*,t.owner id FROM social accounts salJulrusers u on uni - sa.soclaote 1olJuir realls t1..n<->1: on t.id = u.team idWHERE U.team_id = 1 and sa.provider = 'salesforce':45if ($teamId == null|| $parentEntityId === null|1 $crmLayoutId === nullI| $crmFieldId=== null41 X5 лv 521524523524525526527528529530$this->error( string: 'Please provide all parameters.');533534return;$team = Team::idOrUUid($teamId);if ($team === null) {$this->error( string: 'Invalid team provided.');return;$crmConfig = $team->crm;$Layout = $crmConfig->layouts()->where( column: 'id', $crmLayoutId)->first();if (Slavout === null) «$this->error( string: "InvalidscaLaxoutid provided.');reLurna$field = $crmConfig->fields()->where( column: 'crm_provider_id', $crmFieldId)->first();if ($field === null) {puhis->errort string: "Invalld tleld provided.536537538539540541542-54354454554654754854955055155215535541555556557558559560561562563select * from teams where id = 1;select * from groups g JOIN playbooks p 1.n<->1: on g.playbook_id = p.id whersselect * from groups where id = 565;select * from playbooks where team_id = 1;select * from playbooks where id = 175;select * from playbook_categories where playbook_id = 175;seLect * trom users where team_1d = 1;select * TroIusers were 10 =100.select * from crm_profiles where user_id = 7160;select * fromTeacures,select# id, uvid, type, provider, playbook_category_id, user_id, lead_id, contact_1# crm_configuration_id, crm_provider_id, transcription_id, statusfrom activities where crm_configuration_id = 1 and type ='conference"# and crm_provider_id IS NOT NULLand provider != 'uploader' and actual_start_time IS NOT NULLURUER Dy 1d desc)select * from activities where id = 54747783; # 00U0400000pCzojMACselect p.lo, p.accivicy-type, pe.10, pc.nameFROM playbooks pjoin playbook_categories pc 1<->1.n: on p.id = pc.playbook_idwhere p.team_id = 1 and p.activity_type = 'event';SELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'evSELECT * FROM crm_field_values WHERE crm_field_id = 4;select * from crm_layouts cl join playbook_layouts pl1<->1.n: on cl.id = pl.:wnere crm_contiguration_1d = 1 and pL.playdook_1d = 175;select x trol reails?SELECT r.* FROM automated_reports rjoin teams t on r.teamid = t.idWHERE r.frequeney = 'daily'and r.status = 1AND t.status = 'active'AND (r.exRices.at >= now() OR r.expinesat IS NULL):select * from automated_report_results where reRontaid IN (18, 33);$existingEntity = $layout-›entities()->where(['crm_field_id' => $field->id,])->first();if ($existingEntity !==null){$this->error( string: 'The specified layout entity already exists.');select * tron acmur searches where 10 = 107521566 vselect * from activity_search_filters where activity_search_id = 10932;S0/select * from500select * from569automated_report_results where ceRontaid IN (34, 35);return;Winasur cha1og 2.12.21: A new version is available. // View Changelj Support Daily • in 3h 8 mA1 ReguestGenerateAskJiminnyReportJobTest100% [Tue 14 Apr 11:52:37CascadeFixing ReportControllerAutomated Report FNew Cascade+D ...WCascade Code #DCKick off a new project. Make changesdeross your cnule couebase.Automated Report Failure Analysis© Automated Reports Code Review FixesC Fixing ReportController TestsLets review logs what to follow in order to determine why wat the log+ <> CodeClaude Sonnet 4.6W Winasunt leams52:21uir-o( 4 spaces...
|
NULL
|
9127880277183834113
|
NULL
|
click
|
ocr
|
NULL
|
PhpStormFileEditViewNavigateCodeLaravelRefactorFV PhpStormFileEditViewNavigateCodeLaravelRefactorFV faVsco.s v#11894 on JY-18909-automated-reports-ask-iminny K vProject v© ReportController.phpToolsWindowHelp> D Hubspot> D IntegrationApp© AddLayoutEntities.pt© AutologDelayedCom© BullhornCommandAk© BullhornPingCommar© BullhornSearchComn© BullhornSessionComCheckActivityLoggal© CleanDuplicateFieldI© FullSyncOpportunityi(C) LogActivitiesComma© ManageSyncStrateg!© MatchCrmObjectsCa© MatchOpportunityAc© MigrateProvider.php© ProcessHubspotObje© PurgeDeletedOpport© ResetGovernorLimits© SendNotLogged.php© SetupActivity TypeFo© SetupCloseCrm.php© SetupCopperCrm.ph© SetupCrmCommand.© SetupLayouts.php© SyncAccount.php© SyncContact.php© SyncFieldMetadata.f© SyncHubspotActivel© SyncLead.php© SyncObjects.php© SyncOpportunitiesMil© SyncOpportunity.php• SyncProfileMetadata© SyncTeamMetadata.© UpdateOpportunityS• DeallnsightsO DevD DialersD DTOSD ElasticsearchEngagementStats1 Gecko=xportM Livestream• Mailboxes• Migrate_ PlaybackThemesD PlaybooksPlaylists0 PostmarkC ProphetAiv D Reports© AutomatedReportsCi© AutomatedReportsRe(C) AutomatedReportsSi© CreateMockAskJimir© DeleteReportComma© GenerateMarketingR© Team.phpAulomaleakeporscommand.ono© AutomatedReportsService.phpCrealenctivityLoggeaevent.oneJiminnyDeouecommana.ongAutomatedReportsSendCommand.php© AddLayoutEntities.php xC) Team.php© AutomatedReportsRepository.phpCreateHeldActivityEvent.php© TrackProviderInstalledEvent.php© UserPilotActivityListener.php© ActivityLogged.phpC RequestGenerateAskJiminnyReportJob.phpRequestGeneratekeporJob.ong= custom.log= laravel.log< console PRODAl console (EU]© AskJiminnyReportActivityService.phpX:Auto vA SF ljiminny@localhost]A HS_local [jiminny@localhost]A console [STAGING] X© RequestGenerateAskJiminnyReportJobTest.phpPlaygroundDo jiminny016 A13 M13 A V519© AutomatedReportResult.php© AutomatedReport.phpclass AddLayoutEntities extends Commandpublic function handle): vold*teamia = $tn1s->optiont key: "teamiау:3739$parentEntityId = $this->option( key: 'parentEntityId');$crmLayoutId = $this->option( key: 'ermLayoutid');ocrnrrelolo = "us->ootonl key:eoeeieldi:nspearchaoue = "uns-ooron key.searchadlersa.*,t.owner id FROM social accounts salJulrusers u on uni - sa.soclaote 1olJuir realls t1..n<->1: on t.id = u.team idWHERE U.team_id = 1 and sa.provider = 'salesforce':45if ($teamId == null|| $parentEntityId === null|1 $crmLayoutId === nullI| $crmFieldId=== null41 X5 лv 521524523524525526527528529530$this->error( string: 'Please provide all parameters.');533534return;$team = Team::idOrUUid($teamId);if ($team === null) {$this->error( string: 'Invalid team provided.');return;$crmConfig = $team->crm;$Layout = $crmConfig->layouts()->where( column: 'id', $crmLayoutId)->first();if (Slavout === null) «$this->error( string: "InvalidscaLaxoutid provided.');reLurna$field = $crmConfig->fields()->where( column: 'crm_provider_id', $crmFieldId)->first();if ($field === null) {puhis->errort string: "Invalld tleld provided.536537538539540541542-54354454554654754854955055155215535541555556557558559560561562563select * from teams where id = 1;select * from groups g JOIN playbooks p 1.n<->1: on g.playbook_id = p.id whersselect * from groups where id = 565;select * from playbooks where team_id = 1;select * from playbooks where id = 175;select * from playbook_categories where playbook_id = 175;seLect * trom users where team_1d = 1;select * TroIusers were 10 =100.select * from crm_profiles where user_id = 7160;select * fromTeacures,select# id, uvid, type, provider, playbook_category_id, user_id, lead_id, contact_1# crm_configuration_id, crm_provider_id, transcription_id, statusfrom activities where crm_configuration_id = 1 and type ='conference"# and crm_provider_id IS NOT NULLand provider != 'uploader' and actual_start_time IS NOT NULLURUER Dy 1d desc)select * from activities where id = 54747783; # 00U0400000pCzojMACselect p.lo, p.accivicy-type, pe.10, pc.nameFROM playbooks pjoin playbook_categories pc 1<->1.n: on p.id = pc.playbook_idwhere p.team_id = 1 and p.activity_type = 'event';SELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'evSELECT * FROM crm_field_values WHERE crm_field_id = 4;select * from crm_layouts cl join playbook_layouts pl1<->1.n: on cl.id = pl.:wnere crm_contiguration_1d = 1 and pL.playdook_1d = 175;select x trol reails?SELECT r.* FROM automated_reports rjoin teams t on r.teamid = t.idWHERE r.frequeney = 'daily'and r.status = 1AND t.status = 'active'AND (r.exRices.at >= now() OR r.expinesat IS NULL):select * from automated_report_results where reRontaid IN (18, 33);$existingEntity = $layout-›entities()->where(['crm_field_id' => $field->id,])->first();if ($existingEntity !==null){$this->error( string: 'The specified layout entity already exists.');select * tron acmur searches where 10 = 107521566 vselect * from activity_search_filters where activity_search_id = 10932;S0/select * from500select * from569automated_report_results where ceRontaid IN (34, 35);return;Winasur cha1og 2.12.21: A new version is available. // View Changelj Support Daily • in 3h 8 mA1 ReguestGenerateAskJiminnyReportJobTest100% [Tue 14 Apr 11:52:37CascadeFixing ReportControllerAutomated Report FNew Cascade+D ...WCascade Code #DCKick off a new project. Make changesdeross your cnule couebase.Automated Report Failure Analysis© Automated Reports Code Review FixesC Fixing ReportController TestsLets review logs what to follow in order to determine why wat the log+ <> CodeClaude Sonnet 4.6W Winasunt leams52:21uir-o( 4 spaces...
|
10666
|
|
10669
|
212
|
0
|
2026-04-14T08:53:02.152551+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776156782152_m1.jpg...
|
PhpStorm
|
faVsco.js – AddLayoutEntities.php
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
1
5
Previous Highlighted Error
Next Highlighted Error
<?php
namespace Jiminny\Console\Commands\Crm;
use Illuminate\Console\Command;
use Jiminny\Models\Team;
class AddLayoutEntities extends Command
{
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'crm:create-layout-entity
{--teamId=}
{--parentEntityId= : The layout entity label e.g. activity-summary}
{--crmLayoutId= : The crm layout id e.g. 6}
{--crmFieldId= : The crm provider field id}
{--searchable= : Setups the is_indexable/is_filterable field behaviour default: true}'
;
/**
* The console command description.
*
* @var string
*/
protected $description = 'Adds layouts to expose fields in the UI.';
/**
* Execute the console command.
*/
public function handle(): void
{
$teamId = $this->option('teamId');
$parentEntityId = $this->option('parentEntityId');
$crmLayoutId = $this->option('crmLayoutId');
$crmFieldId = $this->option('crmFieldId');
$isSearchable = $this->option('searchable');
if ($teamId == null
|| $parentEntityId === null
|| $crmLayoutId === null
|| $crmFieldId === null
) {
$this->error('Please provide all parameters.');
return;
}
$team = Team::idOrUUid($teamId);
if ($team === null) {
$this->error('Invalid team provided.');
return;
}
$crmConfig = $team->crm;
$layout = $crmConfig->layouts()->where('id', $crmLayoutId)->first();
if ($layout === null) {
$this->error('Invalid crmLayoutId provided.');
return;
}
$field = $crmConfig->fields()->where('crm_provider_id', $crmFieldId)->first();
if ($field === null) {
$this->error('Invalid field provided.');
return;
}
$existingEntity = $layout->entities()->where([
'crm_field_id' => $field->id,
])->first();
if ($existingEntity !== null) {
$this->error('The specified layout entity already exists.');
return;
}
$parentId = null;
$parentEntity = $layout->entities()->where('label', $parentEntityId)->first();
if ($parentEntity !== null) {
$parentId = $parentEntity->id;
}
$entity = $layout->entities()->create([
'crm_field_id' => $field->id,
'label' => $field->label,
'description' => $field->description,
'is_visible' => true,
'parent_entity_id' => $parentId,
]);
$isIndexable = true;
$isFilterable = true;
if ($isSearchable === false) {
$isIndexable = false;
$isFilterable = false;
}
$field->update([
'is_indexable' => $isIndexable,
'is_filterable' => $isFilterable,
]);
$this->comment('Created entity #' . $entity->id);
}
}
Execute
Explain Plan
Browse Query History
View Parameters
Open Query Execution Settings…
In-Editor Results
Tx: Auto
Cancel Running Statements
Playground
jiminny
Sync Changes
Hide This Notification
Code changed:...
|
[{"role":"AXButton","text" [{"role":"AXButton","text":"Project: faVsco.js, menu","depth":5,"help_text":"~/jiminny/app","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"#11894 on JY-18909-automated-reports-ask-jiminny, menu","depth":5,"help_text":"Pull request #11894 exists for current branch JY-18909-automated-reports-ask-jiminny, but local branch is out of sync with remote","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Start Listening for PHP Debug Connections","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"RequestGenerateAskJiminnyReportJobTest","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Run 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Debug 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"More Actions","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"JetBrains AI","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Search Everywhere","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"IDE and Project Settings","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.088194445,"height":0.027777778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"1","depth":4,"role_description":"text"},{"role":"AXStaticText","text":"5","depth":4,"role_description":"text"},{"role":"AXButton","text":"Previous Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Next Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"<?php\n\nnamespace Jiminny\\Console\\Commands\\Crm;\n\nuse Illuminate\\Console\\Command;\nuse Jiminny\\Models\\Team;\n\nclass AddLayoutEntities extends Command\n{\n /**\n * The name and signature of the console command.\n *\n * @var string\n */\n protected $signature = 'crm:create-layout-entity\n {--teamId=}\n {--parentEntityId= : The layout entity label e.g. activity-summary}\n {--crmLayoutId= : The crm layout id e.g. 6}\n {--crmFieldId= : The crm provider field id}\n {--searchable= : Setups the is_indexable/is_filterable field behaviour default: true}'\n ;\n\n /**\n * The console command description.\n *\n * @var string\n */\n protected $description = 'Adds layouts to expose fields in the UI.';\n\n\n /**\n * Execute the console command.\n */\n public function handle(): void\n {\n $teamId = $this->option('teamId');\n $parentEntityId = $this->option('parentEntityId');\n $crmLayoutId = $this->option('crmLayoutId');\n $crmFieldId = $this->option('crmFieldId');\n $isSearchable = $this->option('searchable');\n\n if ($teamId == null\n || $parentEntityId === null\n || $crmLayoutId === null\n || $crmFieldId === null\n ) {\n $this->error('Please provide all parameters.');\n\n return;\n }\n\n $team = Team::idOrUUid($teamId);\n\n if ($team === null) {\n $this->error('Invalid team provided.');\n\n return;\n }\n\n $crmConfig = $team->crm;\n\n $layout = $crmConfig->layouts()->where('id', $crmLayoutId)->first();\n\n if ($layout === null) {\n $this->error('Invalid crmLayoutId provided.');\n\n return;\n }\n\n $field = $crmConfig->fields()->where('crm_provider_id', $crmFieldId)->first();\n\n if ($field === null) {\n $this->error('Invalid field provided.');\n\n return;\n }\n\n $existingEntity = $layout->entities()->where([\n 'crm_field_id' => $field->id,\n ])->first();\n\n if ($existingEntity !== null) {\n $this->error('The specified layout entity already exists.');\n\n return;\n }\n\n $parentId = null;\n $parentEntity = $layout->entities()->where('label', $parentEntityId)->first();\n\n if ($parentEntity !== null) {\n $parentId = $parentEntity->id;\n }\n\n $entity = $layout->entities()->create([\n 'crm_field_id' => $field->id,\n 'label' => $field->label,\n 'description' => $field->description,\n 'is_visible' => true,\n 'parent_entity_id' => $parentId,\n ]);\n\n $isIndexable = true;\n $isFilterable = true;\n\n if ($isSearchable === false) {\n $isIndexable = false;\n $isFilterable = false;\n }\n\n $field->update([\n 'is_indexable' => $isIndexable,\n 'is_filterable' => $isFilterable,\n ]);\n\n $this->comment('Created entity #' . $entity->id);\n }\n}","depth":4,"value":"<?php\n\nnamespace Jiminny\\Console\\Commands\\Crm;\n\nuse Illuminate\\Console\\Command;\nuse Jiminny\\Models\\Team;\n\nclass AddLayoutEntities extends Command\n{\n /**\n * The name and signature of the console command.\n *\n * @var string\n */\n protected $signature = 'crm:create-layout-entity\n {--teamId=}\n {--parentEntityId= : The layout entity label e.g. activity-summary}\n {--crmLayoutId= : The crm layout id e.g. 6}\n {--crmFieldId= : The crm provider field id}\n {--searchable= : Setups the is_indexable/is_filterable field behaviour default: true}'\n ;\n\n /**\n * The console command description.\n *\n * @var string\n */\n protected $description = 'Adds layouts to expose fields in the UI.';\n\n\n /**\n * Execute the console command.\n */\n public function handle(): void\n {\n $teamId = $this->option('teamId');\n $parentEntityId = $this->option('parentEntityId');\n $crmLayoutId = $this->option('crmLayoutId');\n $crmFieldId = $this->option('crmFieldId');\n $isSearchable = $this->option('searchable');\n\n if ($teamId == null\n || $parentEntityId === null\n || $crmLayoutId === null\n || $crmFieldId === null\n ) {\n $this->error('Please provide all parameters.');\n\n return;\n }\n\n $team = Team::idOrUUid($teamId);\n\n if ($team === null) {\n $this->error('Invalid team provided.');\n\n return;\n }\n\n $crmConfig = $team->crm;\n\n $layout = $crmConfig->layouts()->where('id', $crmLayoutId)->first();\n\n if ($layout === null) {\n $this->error('Invalid crmLayoutId provided.');\n\n return;\n }\n\n $field = $crmConfig->fields()->where('crm_provider_id', $crmFieldId)->first();\n\n if ($field === null) {\n $this->error('Invalid field provided.');\n\n return;\n }\n\n $existingEntity = $layout->entities()->where([\n 'crm_field_id' => $field->id,\n ])->first();\n\n if ($existingEntity !== null) {\n $this->error('The specified layout entity already exists.');\n\n return;\n }\n\n $parentId = null;\n $parentEntity = $layout->entities()->where('label', $parentEntityId)->first();\n\n if ($parentEntity !== null) {\n $parentId = $parentEntity->id;\n }\n\n $entity = $layout->entities()->create([\n 'crm_field_id' => $field->id,\n 'label' => $field->label,\n 'description' => $field->description,\n 'is_visible' => true,\n 'parent_entity_id' => $parentId,\n ]);\n\n $isIndexable = true;\n $isFilterable = true;\n\n if ($isSearchable === false) {\n $isIndexable = false;\n $isFilterable = false;\n }\n\n $field->update([\n 'is_indexable' => $isIndexable,\n 'is_filterable' => $isFilterable,\n ]);\n\n $this->comment('Created entity #' . $entity->id);\n }\n}","role_description":"text entry area","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Execute","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Explain Plan","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Browse Query History","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"View Parameters","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Open Query Execution Settings…","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"In-Editor Results","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Tx: Auto","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Cancel Running Statements","depth":4,"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Playground","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"jiminny","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.088194445,"height":0.027777778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false}]...
|
-5663505936366205673
|
-1931805578127763186
|
click
|
accessibility
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
1
5
Previous Highlighted Error
Next Highlighted Error
<?php
namespace Jiminny\Console\Commands\Crm;
use Illuminate\Console\Command;
use Jiminny\Models\Team;
class AddLayoutEntities extends Command
{
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'crm:create-layout-entity
{--teamId=}
{--parentEntityId= : The layout entity label e.g. activity-summary}
{--crmLayoutId= : The crm layout id e.g. 6}
{--crmFieldId= : The crm provider field id}
{--searchable= : Setups the is_indexable/is_filterable field behaviour default: true}'
;
/**
* The console command description.
*
* @var string
*/
protected $description = 'Adds layouts to expose fields in the UI.';
/**
* Execute the console command.
*/
public function handle(): void
{
$teamId = $this->option('teamId');
$parentEntityId = $this->option('parentEntityId');
$crmLayoutId = $this->option('crmLayoutId');
$crmFieldId = $this->option('crmFieldId');
$isSearchable = $this->option('searchable');
if ($teamId == null
|| $parentEntityId === null
|| $crmLayoutId === null
|| $crmFieldId === null
) {
$this->error('Please provide all parameters.');
return;
}
$team = Team::idOrUUid($teamId);
if ($team === null) {
$this->error('Invalid team provided.');
return;
}
$crmConfig = $team->crm;
$layout = $crmConfig->layouts()->where('id', $crmLayoutId)->first();
if ($layout === null) {
$this->error('Invalid crmLayoutId provided.');
return;
}
$field = $crmConfig->fields()->where('crm_provider_id', $crmFieldId)->first();
if ($field === null) {
$this->error('Invalid field provided.');
return;
}
$existingEntity = $layout->entities()->where([
'crm_field_id' => $field->id,
])->first();
if ($existingEntity !== null) {
$this->error('The specified layout entity already exists.');
return;
}
$parentId = null;
$parentEntity = $layout->entities()->where('label', $parentEntityId)->first();
if ($parentEntity !== null) {
$parentId = $parentEntity->id;
}
$entity = $layout->entities()->create([
'crm_field_id' => $field->id,
'label' => $field->label,
'description' => $field->description,
'is_visible' => true,
'parent_entity_id' => $parentId,
]);
$isIndexable = true;
$isFilterable = true;
if ($isSearchable === false) {
$isIndexable = false;
$isFilterable = false;
}
$field->update([
'is_indexable' => $isIndexable,
'is_filterable' => $isFilterable,
]);
$this->comment('Created entity #' . $entity->id);
}
}
Execute
Explain Plan
Browse Query History
View Parameters
Open Query Execution Settings…
In-Editor Results
Tx: Auto
Cancel Running Statements
Playground
jiminny
Sync Changes
Hide This Notification
Code changed:...
|
NULL
|
|
10670
|
213
|
0
|
2026-04-14T08:53:02.166625+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776156782166_m2.jpg...
|
PhpStorm
|
faVsco.js – AddLayoutEntities.php
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
1
5
Previous Highlighted Error
Next Highlighted Error
<?php
namespace Jiminny\Console\Commands\Crm;
use Illuminate\Console\Command;
use Jiminny\Models\Team;
class AddLayoutEntities extends Command
{
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'crm:create-layout-entity
{--teamId=}
{--parentEntityId= : The layout entity label e.g. activity-summary}
{--crmLayoutId= : The crm layout id e.g. 6}
{--crmFieldId= : The crm provider field id}
{--searchable= : Setups the is_indexable/is_filterable field behaviour default: true}'
;
/**
* The console command description.
*
* @var string
*/
protected $description = 'Adds layouts to expose fields in the UI.';
/**
* Execute the console command.
*/
public function handle(): void
{
$teamId = $this->option('teamId');
$parentEntityId = $this->option('parentEntityId');
$crmLayoutId = $this->option('crmLayoutId');
$crmFieldId = $this->option('crmFieldId');
$isSearchable = $this->option('searchable');
if ($teamId == null
|| $parentEntityId === null
|| $crmLayoutId === null
|| $crmFieldId === null
) {
$this->error('Please provide all parameters.');
return;
}
$team = Team::idOrUUid($teamId);
if ($team === null) {
$this->error('Invalid team provided.');
return;
}
$crmConfig = $team->crm;
$layout = $crmConfig->layouts()->where('id', $crmLayoutId)->first();
if ($layout === null) {
$this->error('Invalid crmLayoutId provided.');
return;
}
$field = $crmConfig->fields()->where('crm_provider_id', $crmFieldId)->first();
if ($field === null) {
$this->error('Invalid field provided.');
return;
}
$existingEntity = $layout->entities()->where([
'crm_field_id' => $field->id,
])->first();
if ($existingEntity !== null) {
$this->error('The specified layout entity already exists.');
return;
}
$parentId = null;
$parentEntity = $layout->entities()->where('label', $parentEntityId)->first();
if ($parentEntity !== null) {
$parentId = $parentEntity->id;
}
$entity = $layout->entities()->create([
'crm_field_id' => $field->id,
'label' => $field->label,
'description' => $field->description,
'is_visible' => true,
'parent_entity_id' => $parentId,
]);
$isIndexable = true;
$isFilterable = true;
if ($isSearchable === false) {
$isIndexable = false;
$isFilterable = false;
}
$field->update([
'is_indexable' => $isIndexable,
'is_filterable' => $isFilterable,
]);
$this->comment('Created entity #' . $entity->id);
}
}
Execute
Explain Plan
Browse Query History
View Parameters
Open Query Execution Settings…
In-Editor Results
Tx: Auto
Cancel Running Statements
Playground
jiminny
Sync Changes
Hide This Notification
Code changed:
Hide
16
13
13
Previous Highlighted Error
Next Highlighted Error
SELECT * FROM teams WHERE id = 1;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;
SELECT * FROM crm_fields WHERE id = 2234;
SELECT * FROM crm_field_values WHERE crm_field_id = 2234;
select * from crm_profiles where user_id = 143;
select * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO
select * from business_processes where crm_configuration_id = 39;
# 01941000000H669AAC, 01941000000H66JAAS
select * from record_type_field_values
where record_type_id IN (24);
select * from crm_field_values where id IN (2730);
select * from crm_configurations where id = 39;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce'; #1035
select * from users where team_id = 1; # 222 group 3
SELECT * FROM activities WHERE user_id = 222 order by id desc;
select * from sidekick_settings where team_id = 1;
select * from teams where id = 1;
select * from team_features where team_id = 1;
select * from activities where crm_configuration_id = 2
and provider = 'ms-teams' and id = 608765;
SELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';
select * from sidekick_settings where team_id = 2;
SELECT * FROM activities WHERE id = 608660;
select * from activity_summary_logs where activity_id = 608660;
select * from ai_prompts where transcription_id = 11214;
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;
# id: 608818, crm: 59628809737
SELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;
# id: 608821, crm: 59632069252
SELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,
playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,
scheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at
FROM activities a
join calendar_events ce on a.calendar_event_id = ce.id
WHERE a.id IN (608818, 608821);
select * from users where team_id = 1;
select * from team_settings where team_id = 1;
select * from crm_profiles where crm_configuration_id = 39 order by user_id;
select * from team_features where team_id = 1;
select * from users where team_id = 2;
SELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639
# Preslava N. Ivanova, grou id 3
SELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;
select * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';
select
a.id,
a.type,
a.scheduled_start_time,
a.actual_start_time,
a.created_at,
a.opportunity_id,
a.status
FROM activities a
WHERE opportunity_id = 344
and status IN ('completed', 'received', 'delivered')
and (
(a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))
;
SELECT * FROM users WHERE id = 222;
SELECT * FROM crm_profiles WHERE user_id = 222;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;
select * from group_deal_risk_types;
select * from opportunities where team_id = 1;
SELECT * FROM opportunities WHERE id = 315;
SELECT * FROM crm_field_data WHERE object_id = 315;
select * from crm_field_data where object_id = 260;
select * from generic_ai_prompts where subject_id = 315;
select * from teams; # 36, 21, 121, [EMAIL]
SELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';
# [PASSWORD_DOTS]
select * from teams where id = 1;
select * from crm_configurations where id = 39;
select * from users where team_id = 1;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 1;
# 1 - 00541000004281rAAA
# 204 - 0052g000003freeAAA
# 429 - 0052g000003qGOiAAM
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
select * from activities where type = 'softphone'
and created_at > '2024-12-11 15:24:36' order by id desc;
select * from activity_providers where team_id = 1;
select * from activity_provider_users where activity_provider_id = 328;
select * from opportunities where crm_configuration_id = 39
AND account_id = 178 AND is_closed = false
order by created_at DESC;
select * from contacts where id = 3952;
select * from accounts where id = 178;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations where id = 21;
select * from users where team_id = 36;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 36
and sa.provider = 'bullhorn';
select * from social_accounts where id = 348;
UPDATE social_accounts SET
provider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',
provider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',
expires = 1733998131,
state = 'connected'
WHERE id = 348;
# [PASSWORD_DOTS]
select * from teams where id = 31;
select * from crm_configurations where id = 18;
select * from users where team_id = 31; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 31;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 31
and sa.provider = 'close';
select * from contacts where crm_configuration_id = 18;
# [PASSWORD_DOTS] NEPTUNE [PASSWORD_DOTS]
select * from teams;
select * from users where id IN (1030, 1035, 1052);
select * from crm_configurations;
select * from users where team_id = 65; # 257
select * from team_settings where team_id = 65; # 257
select * from invitations where team_id = 65; # 257
select * from users where email = '[EMAIL]'; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 65;
select * from crm_configurations where id = 53;
select * from accounts where crm_configuration_id = 53 order by id desc;
select * from leads where crm_configuration_id = 53 order by id desc;
select * from contacts where crm_configuration_id = 53 order by id desc;
select * from opportunities where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 53 order by id desc;
select * from crm_fields where crm_configuration_id = 53 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 53 order by id desc;
select * from stages where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 13;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
and sa.provider = 'integration-app';
select * from contacts where crm_configuration_id = 13;
select * from social_accounts where sociable_id = 283;
SELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';
select * from activity_providers where team_id = 65;
SELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
;
# [PASSWORD_DOTS] STAGING [PASSWORD_DOTS]
SELECT * FROM teams;
SELECT * FROM teams WHERE id = 88;
SELECT * FROM teams WHERE id = 89;
select * from team_settings where team_id = 89;
SELECT * FROM users WHERE team_id = 89;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 89;
select * from users;
SELECT * FROM social_accounts WHERE sociable_id = 1761;
SELECT * FROM crm_configurations WHERE id = 70;
select * from accounts where crm_configuration_id = 70 order by id desc;
select * from leads where crm_configuration_id = 70 order by id desc;
select * from contacts where crm_configuration_id = 70 order by id desc;
select * from opportunities where crm_configuration_id = 70 order by id desc;
select * from crm_profiles where crm_configuration_id = 70 order by id desc;
select * from crm_fields where crm_configuration_id = 70 order by id desc;
select * from crm_field_values where crm_field_id = 3536 order by id desc;
select * from crm_layouts where crm_configuration_id = 70 order by id desc;
select * from stages where crm_configuration_id = 70 order by id desc;
select * from business_processes where crm_configuration_id = 70 order by id desc;
select * from business_process_stages where business_process_id = 34;
select * from contacts where id = 10468;
select * from crm_layouts where crm_configuration_id = 70;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;
SELECT * FROM crm_fields WHERE id IN (3533,3534,3535);
select * from activities where crm_configuration_id = 70
and (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;
SELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;
SELECT * FROM activities where crm_configuration_id = 69 ;
SELECT * FROM users WHERE email LIKE '%[EMAIL]%';
SELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;
SELECT * FROM opportunities WHERE id = 385;
select * from participants p
join activities a on p.activity_id = a.id
where a.crm_configuration_id = 70
and (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);
SELECT * FROM participants WHERE id = 1013638;
select * from teams where id = 90;
select * from users where team_id = 90;
select * from social_accounts where social_accounts.sociable_id IN (1960,1760);
SELECT * FROM crm_profiles WHERE crm_configuration_id = 71;
select * from invitations where team_id = 90;
select * from crm_configurations where id = 71;
select * from accounts where crm_configuration_id = 71 order by id desc;
select * from leads where crm_configuration_id = 71 order by id desc;
select * from contacts where crm_configuration_id = 71 order by id desc;
select * from opportunities where crm_configuration_id = 71 order by id desc;
select * from crm_profiles where crm_configuration_id = 71 order by id desc;
select * from crm_fields where crm_configuration_id = 71 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 71 order by id desc;
select * from stages where crm_configuration_id = 71 order by id desc;
select * from users order by secondary_email desc;
select u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa
join users u on sa.sociable_id = u.id
where sa.provider = 'google' and u.email LIKE 'aneliya%';
select * from failed_jobs order by id desc;
select * from users where email = '[EMAIL]' or secondary_email = '[EMAIL]';
select * from teams;
SELECT * FROM crm_profiles WHERE crm_configuration_id = 39;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;
SELECT * FROM crm_configurations WHERE id = 70;
select * from teams where id = 1;
select * from groups where team_id = 1;
select * from users where team_id = 1;
select o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o
join users u on o.user_id = u.id
join groups g on u.group_id = g.id
join role_user ru on u.id = ru.user_id
join roles r on ru.role_id = r.id
where o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';
select * from role_user where user_id = 143;
select * from roles;
select * from role_user;
select * from groups where id = 9;
select * from scope_groups where group_id = 9;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations;
SELECT * FROM social_accounts WHERE sociable_id = 121;
https://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105
https://crmsandbox.zoho.com/crm/
https://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080
https://crm.zoho.com/crm/
org3469620
SELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;
select * from users where email LIKE "%mobile_automation_%";
select * from social_accounts where sociable_id IN (2228);
select * from crm_profiles where user_id IN (2222,2223,2226,2227);
select * from teams order by id desc;
SELECT * FROM users WHERE id = 2229;
SELECT * FROM crm_profiles WHERE user_id = 2229;
select * from opportunities where crm_configuration_id = 88;
select * from crm_fields where crm_configuration_id = 88;
select * from crm_profiles where crm_configuration_id = 88;
SELECT * FROM teams WHERE id = 1;
SELECT * FROM users WHERE id = 143;
SELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;
https://app.staging.jiminny.com/ondemand?
min_duration=1
&
only_recorded=1
&
user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e
&
sequence_number=2
select * from users where team_id = 1 and email like '%stoyan%'
select * from coaching_feedbacks;
select * from teams;
SELECT * FROM users WHERE team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from users where id = 143;
SELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
select * from users where team_id = 2;
select * from activities where crm_configuration_id = 39
and activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'
AND user_id = 143
order by id desc;
# [PASSWORD_DOTS]
select * from teams where id = 142; # 2312, 126
select * from team_settings;
select * from users where team_id = 142; # 21642
SELECT * FROM social_accounts WHERE sociable_id = 21642;
SELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;
select * from crm_profiles where id IN (93);
select * from invitations;
select * from team_features where team_id = 1;
SELECT * FROM crm_configurations WHERE id = 126;
select * from accounts where crm_configuration_id = 126 order by id desc;
select * from leads where crm_configuration_id = 126 order by id desc;
select * from contacts where crm_configuration_id = 126 order by id desc;
select * from opportunities where crm_configuration_id = 126 order by id desc;
select * from crm_profiles where crm_configuration_id = 126 order by id desc;
select * from crm_fields where crm_configuration_id = 126 # 11060
# and type IN ('picklist', 'status')
# and object_type = 'task'
order by id desc;
# 5731,5732,5733
select DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;
select * from crm_layouts where crm_configuration_id = 126 order by id desc;
SELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);
select * from stages where crm_configuration_id = 126 order by id desc;
select * from business_processes where crm_configuration_id = 126 order by id desc;
select * from business_process_stages where business_process_id IN (76,75,74,73);
select * from playbooks where team_id = 142;
select * from playbook_layouts where playbook_id IN (108);
SELECT * FROM playbook_categories WHERE playbook_id IN (108);
select * from teams where id = 130;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 2
and sa.provider = 'hubspot';
SELECT * FROM activities
WHERE crm_configuration_id = 110;
select * from teams;
select * from crm_configurations;
SELECT * FROM activities WHERE id = 628773;
SELECT * FROM crm_profiles WHERE user_id = 1460;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from teams;
select ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id
join permission_role pr on pr.role_id = ru.role_id
join permissions p on p.id = pr.permission_id
where team_id = 495 and p.name IN ('dial');
select * from teams where id = 145;
select * from crm_configurations where id = 129;
select * from social_accounts where sociable_id = 2317;
SELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;
select * from teams where id = 1;
SELECT * FROM crm_layouts WHERE crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;
SELECT * FROM crm_layout_entities WHERE id = 5507;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');
select * from teams;
select * from activities where crm_configuration_id = 14;
SELECT * FROM social_accounts where provider = 'copper';
select * from activities where id = 628467;
select * from participants where activity_id = 628467;
SELECT * FROM contacts WHERE id = 3969;
SELECT * FROM accounts WHERE id = 177;
SELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;
# [PASSWORD_DOTS] BH
select * from teams where id = 36;
SELECT * FROM crm_configurations WHERE id = 21;
select * from activities where crm_configuration_id = 21 and id = 607901;
select * from activities where crm_configuration_id = 21;
select * roles;
select * from permissions;
select * from permission_role where permission_id = 226;
select * from migrations order by id desc;
# mercury
# neptune
# earth
select * from teams;
select * from teams where id = 19;
select * from teams where id = 27;
select * from users where team_id = 27;
SELECT * FROM crm_configurations WHERE id = 42;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from activities where id = 631461;
SELECT * FROM crm_field_values WHERE crm_field_id = 180;
select * from teams where id = 2;
SELECT * FROM social_accounts WHERE sociable_id = 89;
SELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273
select * from activity_summary_logs where activity_id = 634273;
select * from sidekick_settings where team_id = 2;
select * from teams; # 2, 2
SELECT * FROM crm_configurations WHERE team_id = 2; # 2
select * from team_features where team_id = 2;
select * from features;
SELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';
SELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;
select * from automated_reports order by id desc;
select * from automated_report_results order by id desc;
select * from users where team_id = 1 and id IN (7160, 3248);
select * from migrations order by id desc;
SELECT
CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,
u.email,
sa.*,
t.owner_id FROM social_accounts sa
JOIN users u on u.id = sa.sociable_id
JOIN teams t on t.id = u.team_id
WHERE u.team_id = 1 and sa.provider = 'salesforce';
select * from teams where id = 1;
select * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;
select * from groups where id = 565;
select * from playbooks where team_id = 1;
select * from playbooks where id = 175;
select * from playbook_categories where playbook_id = 175;
select * from users where team_id = 1;
select * from users where id = 7160;
select * from crm_profiles where user_id = 7160;
select * from features;
select
*
# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,
# crm_configuration_id, crm_provider_id, transcription_id, status
from activities where crm_configuration_id = 1 and type = 'conference'
# and crm_provider_id IS NOT NULL
and provider != 'uploader' and actual_start_time IS NOT NULL
ORDER by id desc;
select * from activities where id = 54747783; # 00UO400000pCzojMAC
select p.id, p.activity_type, pc.id, pc.name
FROM playbooks p
join playbook_categories pc on p.id = pc.playbook_id
where p.team_id = 1 and p.activity_type = 'event';
SELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';
SELECT * FROM crm_field_values WHERE crm_field_id = 4;
select * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id
where crm_configuration_id = 1 and pl.playbook_id = 175;
select * from teams;
SELECT r.* FROM automated_reports r
join teams t on r.team_id = t.id
WHERE r.frequency = 'daily'
and r.status = 1
AND t.status = 'active'
AND (r.expires_at >= now() OR r.expires_at IS NULL);
select * from automated_report_results where report_id IN (18, 33);
select * from activity_searches where id = 10932;
select * from activity_search_filters where activity_search_id = 10932;
select * from automated_reports;
select * from automated_report_results where report_id IN (34, 35);
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
[{"role":"AXButton","text" [{"role":"AXButton","text":"Project: faVsco.js, menu","depth":5,"bounds":{"left":0.03046875,"top":0.017361112,"width":0.0453125,"height":0.022222223},"help_text":"~/jiminny/app","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"#11894 on JY-18909-automated-reports-ask-jiminny, menu","depth":5,"bounds":{"left":0.07578125,"top":0.017361112,"width":0.14960937,"height":0.022222223},"help_text":"Pull request #11894 exists for current branch JY-18909-automated-reports-ask-jiminny, but local branch is out of sync with remote","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Start Listening for PHP Debug Connections","depth":5,"bounds":{"left":0.76171875,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"RequestGenerateAskJiminnyReportJobTest","depth":6,"bounds":{"left":0.7796875,"top":0.017361112,"width":0.12109375,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Run 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"bounds":{"left":0.9007813,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Debug 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"bounds":{"left":0.9140625,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"More Actions","depth":6,"bounds":{"left":0.9273437,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"JetBrains AI","depth":5,"bounds":{"left":0.96015626,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Search Everywhere","depth":5,"bounds":{"left":0.9734375,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"IDE and Project Settings","depth":5,"bounds":{"left":0.9867188,"top":0.017361112,"width":0.013281226,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.049609374,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"1","depth":4,"bounds":{"left":0.40898436,"top":0.1736111,"width":0.00859375,"height":0.013194445},"role_description":"text"},{"role":"AXStaticText","text":"5","depth":4,"bounds":{"left":0.41992188,"top":0.1736111,"width":0.009375,"height":0.013194445},"role_description":"text"},{"role":"AXButton","text":"Previous Highlighted Error","depth":4,"bounds":{"left":0.43125,"top":0.17222223,"width":0.00859375,"height":0.015972223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Next Highlighted Error","depth":4,"bounds":{"left":0.43984374,"top":0.17222223,"width":0.008203125,"height":0.015972223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"<?php\n\nnamespace Jiminny\\Console\\Commands\\Crm;\n\nuse Illuminate\\Console\\Command;\nuse Jiminny\\Models\\Team;\n\nclass AddLayoutEntities extends Command\n{\n /**\n * The name and signature of the console command.\n *\n * @var string\n */\n protected $signature = 'crm:create-layout-entity\n {--teamId=}\n {--parentEntityId= : The layout entity label e.g. activity-summary}\n {--crmLayoutId= : The crm layout id e.g. 6}\n {--crmFieldId= : The crm provider field id}\n {--searchable= : Setups the is_indexable/is_filterable field behaviour default: true}'\n ;\n\n /**\n * The console command description.\n *\n * @var string\n */\n protected $description = 'Adds layouts to expose fields in the UI.';\n\n\n /**\n * Execute the console command.\n */\n public function handle(): void\n {\n $teamId = $this->option('teamId');\n $parentEntityId = $this->option('parentEntityId');\n $crmLayoutId = $this->option('crmLayoutId');\n $crmFieldId = $this->option('crmFieldId');\n $isSearchable = $this->option('searchable');\n\n if ($teamId == null\n || $parentEntityId === null\n || $crmLayoutId === null\n || $crmFieldId === null\n ) {\n $this->error('Please provide all parameters.');\n\n return;\n }\n\n $team = Team::idOrUUid($teamId);\n\n if ($team === null) {\n $this->error('Invalid team provided.');\n\n return;\n }\n\n $crmConfig = $team->crm;\n\n $layout = $crmConfig->layouts()->where('id', $crmLayoutId)->first();\n\n if ($layout === null) {\n $this->error('Invalid crmLayoutId provided.');\n\n return;\n }\n\n $field = $crmConfig->fields()->where('crm_provider_id', $crmFieldId)->first();\n\n if ($field === null) {\n $this->error('Invalid field provided.');\n\n return;\n }\n\n $existingEntity = $layout->entities()->where([\n 'crm_field_id' => $field->id,\n ])->first();\n\n if ($existingEntity !== null) {\n $this->error('The specified layout entity already exists.');\n\n return;\n }\n\n $parentId = null;\n $parentEntity = $layout->entities()->where('label', $parentEntityId)->first();\n\n if ($parentEntity !== null) {\n $parentId = $parentEntity->id;\n }\n\n $entity = $layout->entities()->create([\n 'crm_field_id' => $field->id,\n 'label' => $field->label,\n 'description' => $field->description,\n 'is_visible' => true,\n 'parent_entity_id' => $parentId,\n ]);\n\n $isIndexable = true;\n $isFilterable = true;\n\n if ($isSearchable === false) {\n $isIndexable = false;\n $isFilterable = false;\n }\n\n $field->update([\n 'is_indexable' => $isIndexable,\n 'is_filterable' => $isFilterable,\n ]);\n\n $this->comment('Created entity #' . $entity->id);\n }\n}","depth":4,"value":"<?php\n\nnamespace Jiminny\\Console\\Commands\\Crm;\n\nuse Illuminate\\Console\\Command;\nuse Jiminny\\Models\\Team;\n\nclass AddLayoutEntities extends Command\n{\n /**\n * The name and signature of the console command.\n *\n * @var string\n */\n protected $signature = 'crm:create-layout-entity\n {--teamId=}\n {--parentEntityId= : The layout entity label e.g. activity-summary}\n {--crmLayoutId= : The crm layout id e.g. 6}\n {--crmFieldId= : The crm provider field id}\n {--searchable= : Setups the is_indexable/is_filterable field behaviour default: true}'\n ;\n\n /**\n * The console command description.\n *\n * @var string\n */\n protected $description = 'Adds layouts to expose fields in the UI.';\n\n\n /**\n * Execute the console command.\n */\n public function handle(): void\n {\n $teamId = $this->option('teamId');\n $parentEntityId = $this->option('parentEntityId');\n $crmLayoutId = $this->option('crmLayoutId');\n $crmFieldId = $this->option('crmFieldId');\n $isSearchable = $this->option('searchable');\n\n if ($teamId == null\n || $parentEntityId === null\n || $crmLayoutId === null\n || $crmFieldId === null\n ) {\n $this->error('Please provide all parameters.');\n\n return;\n }\n\n $team = Team::idOrUUid($teamId);\n\n if ($team === null) {\n $this->error('Invalid team provided.');\n\n return;\n }\n\n $crmConfig = $team->crm;\n\n $layout = $crmConfig->layouts()->where('id', $crmLayoutId)->first();\n\n if ($layout === null) {\n $this->error('Invalid crmLayoutId provided.');\n\n return;\n }\n\n $field = $crmConfig->fields()->where('crm_provider_id', $crmFieldId)->first();\n\n if ($field === null) {\n $this->error('Invalid field provided.');\n\n return;\n }\n\n $existingEntity = $layout->entities()->where([\n 'crm_field_id' => $field->id,\n ])->first();\n\n if ($existingEntity !== null) {\n $this->error('The specified layout entity already exists.');\n\n return;\n }\n\n $parentId = null;\n $parentEntity = $layout->entities()->where('label', $parentEntityId)->first();\n\n if ($parentEntity !== null) {\n $parentId = $parentEntity->id;\n }\n\n $entity = $layout->entities()->create([\n 'crm_field_id' => $field->id,\n 'label' => $field->label,\n 'description' => $field->description,\n 'is_visible' => true,\n 'parent_entity_id' => $parentId,\n ]);\n\n $isIndexable = true;\n $isFilterable = true;\n\n if ($isSearchable === false) {\n $isIndexable = false;\n $isFilterable = false;\n }\n\n $field->update([\n 'is_indexable' => $isIndexable,\n 'is_filterable' => $isFilterable,\n ]);\n\n $this->comment('Created entity #' . $entity->id);\n }\n}","role_description":"text entry area","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Execute","depth":4,"bounds":{"left":0.45,"top":0.10763889,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Explain Plan","depth":4,"bounds":{"left":0.46015626,"top":0.10763889,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Browse Query History","depth":4,"bounds":{"left":0.47304687,"top":0.10763889,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"View Parameters","depth":4,"bounds":{"left":0.4832031,"top":0.10763889,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Open Query Execution Settings…","depth":4,"bounds":{"left":0.4933594,"top":0.10763889,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"In-Editor Results","depth":4,"bounds":{"left":0.50625,"top":0.10763889,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Tx: Auto","depth":4,"bounds":{"left":0.5191406,"top":0.10763889,"width":0.028515626,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Cancel Running Statements","depth":4,"bounds":{"left":0.5503906,"top":0.10763889,"width":0.01015625,"height":0.016666668},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Playground","depth":4,"bounds":{"left":0.56328124,"top":0.10763889,"width":0.034765624,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"jiminny","depth":4,"bounds":{"left":0.6738281,"top":0.10763889,"width":0.033203125,"height":0.016666668},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.049609374,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"16","depth":4,"bounds":{"left":0.65117186,"top":0.12916666,"width":0.011328125,"height":0.013194445},"role_description":"text"},{"role":"AXStaticText","text":"13","depth":4,"bounds":{"left":0.66484374,"top":0.12916666,"width":0.011328125,"height":0.013194445},"role_description":"text"},{"role":"AXStaticText","text":"13","depth":4,"bounds":{"left":0.6785156,"top":0.12916666,"width":0.011328125,"height":0.013194445},"role_description":"text"},{"role":"AXButton","text":"Previous Highlighted Error","depth":4,"bounds":{"left":0.6917969,"top":0.12777779,"width":0.00859375,"height":0.015972223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Next Highlighted Error","depth":4,"bounds":{"left":0.70039064,"top":0.12777779,"width":0.008203125,"height":0.015972223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"SELECT * FROM teams WHERE id = 1;\n\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;\nSELECT * FROM crm_fields WHERE id = 2234;\nSELECT * FROM crm_field_values WHERE crm_field_id = 2234;\n\nselect * from crm_profiles where user_id = 143;\n\nselect * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO\nselect * from business_processes where crm_configuration_id = 39;\n# 01941000000H669AAC, 01941000000H66JAAS\n\nselect * from record_type_field_values\n where record_type_id IN (24);\n\nselect * from crm_field_values where id IN (2730);\n\nselect * from crm_configurations where id = 39;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce'; #1035\n\n\nselect * from users where team_id = 1; # 222 group 3\nSELECT * FROM activities WHERE user_id = 222 order by id desc;\nselect * from sidekick_settings where team_id = 1;\nselect * from teams where id = 1;\nselect * from team_features where team_id = 1;\n\nselect * from activities where crm_configuration_id = 2\nand provider = 'ms-teams' and id = 608765;\n\nSELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';\n\nselect * from sidekick_settings where team_id = 2;\n\nSELECT * FROM activities WHERE id = 608660;\nselect * from activity_summary_logs where activity_id = 608660;\nselect * from ai_prompts where transcription_id = 11214;\n\n# ********************************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;\n# id: 608818, crm: 59628809737\nSELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;\n# id: 608821, crm: 59632069252\nSELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,\nplaybook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,\nscheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at\nFROM activities a\njoin calendar_events ce on a.calendar_event_id = ce.id\nWHERE a.id IN (608818, 608821);\n\nselect * from users where team_id = 1;\nselect * from team_settings where team_id = 1;\nselect * from crm_profiles where crm_configuration_id = 39 order by user_id;\n\nselect * from team_features where team_id = 1;\n\nselect * from users where team_id = 2;\n\nSELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639\n# Preslava N. Ivanova, grou id 3\n\nSELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;\n\nselect * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';\n\nselect\n a.id,\n a.type,\n a.scheduled_start_time,\n a.actual_start_time,\n a.created_at,\n a.opportunity_id,\n a.status\nFROM activities a\nWHERE opportunity_id = 344\nand status IN ('completed', 'received', 'delivered')\nand (\n (a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))\n;\n\nSELECT * FROM users WHERE id = 222;\n\nSELECT * FROM crm_profiles WHERE user_id = 222;\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;\n\nselect * from group_deal_risk_types;\n\nselect * from opportunities where team_id = 1;\n\nSELECT * FROM opportunities WHERE id = 315;\nSELECT * FROM crm_field_data WHERE object_id = 315;\nselect * from crm_field_data where object_id = 260;\n\nselect * from generic_ai_prompts where subject_id = 315;\n\nselect * from teams; # 36, 21, 121, james.graham@bullhorn.jiminny.com\nSELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';\n\n# ************************************************************************************\nselect * from teams where id = 1;\nselect * from crm_configurations where id = 39;\nselect * from users where team_id = 1;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 1;\n# 1 - 00541000004281rAAA\n# 204 - 0052g000003freeAAA\n# 429 - 0052g000003qGOiAAM\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\nselect * from activities where type = 'softphone'\nand created_at > '2024-12-11 15:24:36' order by id desc;\n\nselect * from activity_providers where team_id = 1;\nselect * from activity_provider_users where activity_provider_id = 328;\n\nselect * from opportunities where crm_configuration_id = 39\nAND account_id = 178 AND is_closed = false\norder by created_at DESC;\n\nselect * from contacts where id = 3952;\nselect * from accounts where id = 178;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations where id = 21;\nselect * from users where team_id = 36;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 36;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 36\nand sa.provider = 'bullhorn';\n\nselect * from social_accounts where id = 348;\nUPDATE social_accounts SET\nprovider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',\nprovider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',\nexpires = 1733998131,\nstate = 'connected'\nWHERE id = 348;\n\n# ************************************************************************************\nselect * from teams where id = 31;\nselect * from crm_configurations where id = 18;\n\nselect * from users where team_id = 31; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 31;\n\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 31\nand sa.provider = 'close';\n\nselect * from contacts where crm_configuration_id = 18;\n\n# ********************** NEPTUNE **************************************************************\nselect * from teams;\nselect * from users where id IN (1030, 1035, 1052);\nselect * from crm_configurations;\n\nselect * from users where team_id = 65; # 257\nselect * from team_settings where team_id = 65; # 257\nselect * from invitations where team_id = 65; # 257\nselect * from users where email = 'integration-account@jiminny.com'; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 65;\n\nselect * from crm_configurations where id = 53;\nselect * from accounts where crm_configuration_id = 53 order by id desc;\nselect * from leads where crm_configuration_id = 53 order by id desc;\nselect * from contacts where crm_configuration_id = 53 order by id desc;\nselect * from opportunities where crm_configuration_id = 53 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 53 order by id desc;\nselect * from crm_fields where crm_configuration_id = 53 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 53 order by id desc;\nselect * from stages where crm_configuration_id = 53 order by id desc;\n\n\nselect * from crm_profiles where crm_configuration_id = 13;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\nand sa.provider = 'integration-app';\n\nselect * from contacts where crm_configuration_id = 13;\n\nselect * from social_accounts where sociable_id = 283;\n\nSELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';\n\nselect * from activity_providers where team_id = 65;\nSELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\n;\n\n# ***************************** STAGING ********************************************\nSELECT * FROM teams;\nSELECT * FROM teams WHERE id = 88;\nSELECT * FROM teams WHERE id = 89;\nselect * from team_settings where team_id = 89;\nSELECT * FROM users WHERE team_id = 89;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 89;\n\nselect * from users;\nSELECT * FROM social_accounts WHERE sociable_id = 1761;\nSELECT * FROM crm_configurations WHERE id = 70;\nselect * from accounts where crm_configuration_id = 70 order by id desc;\nselect * from leads where crm_configuration_id = 70 order by id desc;\nselect * from contacts where crm_configuration_id = 70 order by id desc;\nselect * from opportunities where crm_configuration_id = 70 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 70 order by id desc;\nselect * from crm_fields where crm_configuration_id = 70 order by id desc;\nselect * from crm_field_values where crm_field_id = 3536 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 70 order by id desc;\nselect * from stages where crm_configuration_id = 70 order by id desc;\nselect * from business_processes where crm_configuration_id = 70 order by id desc;\nselect * from business_process_stages where business_process_id = 34;\n\nselect * from contacts where id = 10468;\n\nselect * from crm_layouts where crm_configuration_id = 70;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;\nSELECT * FROM crm_fields WHERE id IN (3533,3534,3535);\n\nselect * from activities where crm_configuration_id = 70\nand (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;\n\nSELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;\nSELECT * FROM activities where crm_configuration_id = 69 ;\n\nSELECT * FROM users WHERE email LIKE '%jiminny_web_sa2@jiminny.com%';\nSELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;\nSELECT * FROM opportunities WHERE id = 385;\n\nselect * from participants p\njoin activities a on p.activity_id = a.id\nwhere a.crm_configuration_id = 70\nand (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);\nSELECT * FROM participants WHERE id = 1013638;\n\nselect * from teams where id = 90;\nselect * from users where team_id = 90;\nselect * from social_accounts where social_accounts.sociable_id IN (1960,1760);\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 71;\nselect * from invitations where team_id = 90;\n\nselect * from crm_configurations where id = 71;\nselect * from accounts where crm_configuration_id = 71 order by id desc;\nselect * from leads where crm_configuration_id = 71 order by id desc;\nselect * from contacts where crm_configuration_id = 71 order by id desc;\nselect * from opportunities where crm_configuration_id = 71 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 71 order by id desc;\nselect * from crm_fields where crm_configuration_id = 71 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 71 order by id desc;\nselect * from stages where crm_configuration_id = 71 order by id desc;\n\nselect * from users order by secondary_email desc;\nselect u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa\n join users u on sa.sociable_id = u.id\nwhere sa.provider = 'google' and u.email LIKE 'aneliya%';\n\nselect * from failed_jobs order by id desc;\n\nselect * from users where email = 'ben.allwright@learningpeople.co.uk' or secondary_email = 'ben.allwright@learningpeople.co.uk';\n\nselect * from teams;\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 39;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\n# ************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;\nSELECT * FROM crm_configurations WHERE id = 70;\n\nselect * from teams where id = 1;\nselect * from groups where team_id = 1;\nselect * from users where team_id = 1;\n\nselect o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o\njoin users u on o.user_id = u.id\njoin groups g on u.group_id = g.id\njoin role_user ru on u.id = ru.user_id\njoin roles r on ru.role_id = r.id\nwhere o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';\n\nselect * from role_user where user_id = 143;\nselect * from roles;\n\nselect * from role_user;\nselect * from groups where id = 9;\nselect * from scope_groups where group_id = 9;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations;\nSELECT * FROM social_accounts WHERE sociable_id = 121;\n\nhttps://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105\nhttps://crmsandbox.zoho.com/crm/\n\nhttps://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080\n https://crm.zoho.com/crm/\n org3469620\n\nSELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;\n\nselect * from users where email LIKE \"%mobile_automation_%\";\nselect * from social_accounts where sociable_id IN (2228);\nselect * from crm_profiles where user_id IN (2222,2223,2226,2227);\n\nselect * from teams order by id desc;\nSELECT * FROM users WHERE id = 2229;\nSELECT * FROM crm_profiles WHERE user_id = 2229;\nselect * from opportunities where crm_configuration_id = 88;\nselect * from crm_fields where crm_configuration_id = 88;\nselect * from crm_profiles where crm_configuration_id = 88;\n\nSELECT * FROM teams WHERE id = 1;\n\nSELECT * FROM users WHERE id = 143;\nSELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;\n\nhttps://app.staging.jiminny.com/ondemand?\n min_duration=1\n &\n only_recorded=1\n &\n user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e\n &\n sequence_number=2\n\n select * from users where team_id = 1 and email like '%stoyan%'\n\nselect * from coaching_feedbacks;\n\nselect * from teams;\nSELECT * FROM users WHERE team_id = 36;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from users where id = 143;\n\nSELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\n\nselect * from users where team_id = 2;\nselect * from activities where crm_configuration_id = 39\nand activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'\nAND user_id = 143\norder by id desc;\n\n# ************************************************************************************\nselect * from teams where id = 142; # 2312, 126\nselect * from team_settings;\nselect * from users where team_id = 142; # 21642\nSELECT * FROM social_accounts WHERE sociable_id = 21642;\nSELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;\nselect * from crm_profiles where id IN (93);\nselect * from invitations;\nselect * from team_features where team_id = 1;\n\nSELECT * FROM crm_configurations WHERE id = 126;\nselect * from accounts where crm_configuration_id = 126 order by id desc;\nselect * from leads where crm_configuration_id = 126 order by id desc;\nselect * from contacts where crm_configuration_id = 126 order by id desc;\nselect * from opportunities where crm_configuration_id = 126 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 126 order by id desc;\nselect * from crm_fields where crm_configuration_id = 126 # 11060\n# and type IN ('picklist', 'status')\n# and object_type = 'task'\norder by id desc;\n# 5731,5732,5733\nselect DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;\nselect * from crm_layouts where crm_configuration_id = 126 order by id desc;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);\nselect * from stages where crm_configuration_id = 126 order by id desc;\nselect * from business_processes where crm_configuration_id = 126 order by id desc;\nselect * from business_process_stages where business_process_id IN (76,75,74,73);\nselect * from playbooks where team_id = 142;\nselect * from playbook_layouts where playbook_id IN (108);\nSELECT * FROM playbook_categories WHERE playbook_id IN (108);\n\nselect * from teams where id = 130;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 2\nand sa.provider = 'hubspot';\n\nSELECT * FROM activities\n WHERE crm_configuration_id = 110;\n\nselect * from teams;\nselect * from crm_configurations;\n\nSELECT * FROM activities WHERE id = 628773;\nSELECT * FROM crm_profiles WHERE user_id = 1460;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from teams;\nselect ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id\njoin permission_role pr on pr.role_id = ru.role_id\n join permissions p on p.id = pr.permission_id\nwhere team_id = 495 and p.name IN ('dial');\n\nselect * from teams where id = 145;\nselect * from crm_configurations where id = 129;\nselect * from social_accounts where sociable_id = 2317;\nSELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;\n\nselect * from teams where id = 1;\nSELECT * FROM crm_layouts WHERE crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;\nSELECT * FROM crm_layout_entities WHERE id = 5507;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');\n\nselect * from teams;\nselect * from activities where crm_configuration_id = 14;\n\nSELECT * FROM social_accounts where provider = 'copper';\n\nselect * from activities where id = 628467;\nselect * from participants where activity_id = 628467;\n\nSELECT * FROM contacts WHERE id = 3969;\nSELECT * FROM accounts WHERE id = 177;\n\nSELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;\n\n# ********************* BH\nselect * from teams where id = 36;\nSELECT * FROM crm_configurations WHERE id = 21;\nselect * from activities where crm_configuration_id = 21 and id = 607901;\nselect * from activities where crm_configuration_id = 21;\n\nselect * roles;\nselect * from permissions;\nselect * from permission_role where permission_id = 226;\n\nselect * from migrations order by id desc;\n\n# mercury\n# neptune\n# earth\n\nselect * from teams;\nselect * from teams where id = 19;\nselect * from teams where id = 27;\nselect * from users where team_id = 27;\nSELECT * FROM crm_configurations WHERE id = 42;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from activities where id = 631461;\nSELECT * FROM crm_field_values WHERE crm_field_id = 180;\n\nselect * from teams where id = 2;\nSELECT * FROM social_accounts WHERE sociable_id = 89;\n\nSELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273\nselect * from activity_summary_logs where activity_id = 634273;\n\nselect * from sidekick_settings where team_id = 2;\n\nselect * from teams; # 2, 2\nSELECT * FROM crm_configurations WHERE team_id = 2; # 2\nselect * from team_features where team_id = 2;\nselect * from features;\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;\n\nselect * from automated_reports order by id desc;\nselect * from automated_report_results order by id desc;\nselect * from users where team_id = 1 and id IN (7160, 3248);\nselect * from migrations order by id desc;\n\nSELECT\n CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,\n u.email,\n sa.*,\n t.owner_id FROM social_accounts sa\nJOIN users u on u.id = sa.sociable_id\nJOIN teams t on t.id = u.team_id\nWHERE u.team_id = 1 and sa.provider = 'salesforce';\n\nselect * from teams where id = 1;\nselect * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;\nselect * from groups where id = 565;\nselect * from playbooks where team_id = 1;\nselect * from playbooks where id = 175;\nselect * from playbook_categories where playbook_id = 175;\nselect * from users where team_id = 1;\nselect * from users where id = 7160;\nselect * from crm_profiles where user_id = 7160;\nselect * from features;\nselect\n *\n# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,\n# crm_configuration_id, crm_provider_id, transcription_id, status\nfrom activities where crm_configuration_id = 1 and type = 'conference'\n# and crm_provider_id IS NOT NULL\nand provider != 'uploader' and actual_start_time IS NOT NULL\nORDER by id desc;\nselect * from activities where id = 54747783; # 00UO400000pCzojMAC\n\nselect p.id, p.activity_type, pc.id, pc.name\nFROM playbooks p\njoin playbook_categories pc on p.id = pc.playbook_id\nwhere p.team_id = 1 and p.activity_type = 'event';\n\nSELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';\nSELECT * FROM crm_field_values WHERE crm_field_id = 4;\n\nselect * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id\nwhere crm_configuration_id = 1 and pl.playbook_id = 175;\n\nselect * from teams;\nSELECT r.* FROM automated_reports r\njoin teams t on r.team_id = t.id\nWHERE r.frequency = 'daily'\n and r.status = 1\nAND t.status = 'active'\nAND (r.expires_at >= now() OR r.expires_at IS NULL);\n\nselect * from automated_report_results where report_id IN (18, 33);\n\nselect * from activity_searches where id = 10932;\nselect * from activity_search_filters where activity_search_id = 10932;\nselect * from automated_reports;\nselect * from automated_report_results where report_id IN (34, 35);","depth":4,"value":"SELECT * FROM teams WHERE id = 1;\n\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;\nSELECT * FROM crm_fields WHERE id = 2234;\nSELECT * FROM crm_field_values WHERE crm_field_id = 2234;\n\nselect * from crm_profiles where user_id = 143;\n\nselect * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO\nselect * from business_processes where crm_configuration_id = 39;\n# 01941000000H669AAC, 01941000000H66JAAS\n\nselect * from record_type_field_values\n where record_type_id IN (24);\n\nselect * from crm_field_values where id IN (2730);\n\nselect * from crm_configurations where id = 39;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce'; #1035\n\n\nselect * from users where team_id = 1; # 222 group 3\nSELECT * FROM activities WHERE user_id = 222 order by id desc;\nselect * from sidekick_settings where team_id = 1;\nselect * from teams where id = 1;\nselect * from team_features where team_id = 1;\n\nselect * from activities where crm_configuration_id = 2\nand provider = 'ms-teams' and id = 608765;\n\nSELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';\n\nselect * from sidekick_settings where team_id = 2;\n\nSELECT * FROM activities WHERE id = 608660;\nselect * from activity_summary_logs where activity_id = 608660;\nselect * from ai_prompts where transcription_id = 11214;\n\n# ********************************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;\n# id: 608818, crm: 59628809737\nSELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;\n# id: 608821, crm: 59632069252\nSELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,\nplaybook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,\nscheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at\nFROM activities a\njoin calendar_events ce on a.calendar_event_id = ce.id\nWHERE a.id IN (608818, 608821);\n\nselect * from users where team_id = 1;\nselect * from team_settings where team_id = 1;\nselect * from crm_profiles where crm_configuration_id = 39 order by user_id;\n\nselect * from team_features where team_id = 1;\n\nselect * from users where team_id = 2;\n\nSELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639\n# Preslava N. Ivanova, grou id 3\n\nSELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;\n\nselect * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';\n\nselect\n a.id,\n a.type,\n a.scheduled_start_time,\n a.actual_start_time,\n a.created_at,\n a.opportunity_id,\n a.status\nFROM activities a\nWHERE opportunity_id = 344\nand status IN ('completed', 'received', 'delivered')\nand (\n (a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')\nOR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))\n;\n\nSELECT * FROM users WHERE id = 222;\n\nSELECT * FROM crm_profiles WHERE user_id = 222;\nselect * from crm_layouts where crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;\n\nselect * from group_deal_risk_types;\n\nselect * from opportunities where team_id = 1;\n\nSELECT * FROM opportunities WHERE id = 315;\nSELECT * FROM crm_field_data WHERE object_id = 315;\nselect * from crm_field_data where object_id = 260;\n\nselect * from generic_ai_prompts where subject_id = 315;\n\nselect * from teams; # 36, 21, 121, james.graham@bullhorn.jiminny.com\nSELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';\n\n# ************************************************************************************\nselect * from teams where id = 1;\nselect * from crm_configurations where id = 39;\nselect * from users where team_id = 1;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 1;\n# 1 - 00541000004281rAAA\n# 204 - 0052g000003freeAAA\n# 429 - 0052g000003qGOiAAM\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\nselect * from activities where type = 'softphone'\nand created_at > '2024-12-11 15:24:36' order by id desc;\n\nselect * from activity_providers where team_id = 1;\nselect * from activity_provider_users where activity_provider_id = 328;\n\nselect * from opportunities where crm_configuration_id = 39\nAND account_id = 178 AND is_closed = false\norder by created_at DESC;\n\nselect * from contacts where id = 3952;\nselect * from accounts where id = 178;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations where id = 21;\nselect * from users where team_id = 36;\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 36;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 36\nand sa.provider = 'bullhorn';\n\nselect * from social_accounts where id = 348;\nUPDATE social_accounts SET\nprovider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',\nprovider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',\nexpires = 1733998131,\nstate = 'connected'\nWHERE id = 348;\n\n# ************************************************************************************\nselect * from teams where id = 31;\nselect * from crm_configurations where id = 18;\n\nselect * from users where team_id = 31; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 31;\n\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 31\nand sa.provider = 'close';\n\nselect * from contacts where crm_configuration_id = 18;\n\n# ********************** NEPTUNE **************************************************************\nselect * from teams;\nselect * from users where id IN (1030, 1035, 1052);\nselect * from crm_configurations;\n\nselect * from users where team_id = 65; # 257\nselect * from team_settings where team_id = 65; # 257\nselect * from invitations where team_id = 65; # 257\nselect * from users where email = 'integration-account@jiminny.com'; # 257\nselect u.email, cp.* from users u\njoin crm_profiles cp on u.id = cp.user_id\nwhere u.team_id = 65;\n\nselect * from crm_configurations where id = 53;\nselect * from accounts where crm_configuration_id = 53 order by id desc;\nselect * from leads where crm_configuration_id = 53 order by id desc;\nselect * from contacts where crm_configuration_id = 53 order by id desc;\nselect * from opportunities where crm_configuration_id = 53 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 53 order by id desc;\nselect * from crm_fields where crm_configuration_id = 53 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 53 order by id desc;\nselect * from stages where crm_configuration_id = 53 order by id desc;\n\n\nselect * from crm_profiles where crm_configuration_id = 13;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\nand sa.provider = 'integration-app';\n\nselect * from contacts where crm_configuration_id = 13;\n\nselect * from social_accounts where sociable_id = 283;\n\nSELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';\n\nselect * from activity_providers where team_id = 65;\nSELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 65\n;\n\n# ***************************** STAGING ********************************************\nSELECT * FROM teams;\nSELECT * FROM teams WHERE id = 88;\nSELECT * FROM teams WHERE id = 89;\nselect * from team_settings where team_id = 89;\nSELECT * FROM users WHERE team_id = 89;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 89;\n\nselect * from users;\nSELECT * FROM social_accounts WHERE sociable_id = 1761;\nSELECT * FROM crm_configurations WHERE id = 70;\nselect * from accounts where crm_configuration_id = 70 order by id desc;\nselect * from leads where crm_configuration_id = 70 order by id desc;\nselect * from contacts where crm_configuration_id = 70 order by id desc;\nselect * from opportunities where crm_configuration_id = 70 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 70 order by id desc;\nselect * from crm_fields where crm_configuration_id = 70 order by id desc;\nselect * from crm_field_values where crm_field_id = 3536 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 70 order by id desc;\nselect * from stages where crm_configuration_id = 70 order by id desc;\nselect * from business_processes where crm_configuration_id = 70 order by id desc;\nselect * from business_process_stages where business_process_id = 34;\n\nselect * from contacts where id = 10468;\n\nselect * from crm_layouts where crm_configuration_id = 70;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;\nSELECT * FROM crm_fields WHERE id IN (3533,3534,3535);\n\nselect * from activities where crm_configuration_id = 70\nand (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;\n\nSELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;\nSELECT * FROM activities where crm_configuration_id = 69 ;\n\nSELECT * FROM users WHERE email LIKE '%jiminny_web_sa2@jiminny.com%';\nSELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;\nSELECT * FROM opportunities WHERE id = 385;\n\nselect * from participants p\njoin activities a on p.activity_id = a.id\nwhere a.crm_configuration_id = 70\nand (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);\nSELECT * FROM participants WHERE id = 1013638;\n\nselect * from teams where id = 90;\nselect * from users where team_id = 90;\nselect * from social_accounts where social_accounts.sociable_id IN (1960,1760);\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 71;\nselect * from invitations where team_id = 90;\n\nselect * from crm_configurations where id = 71;\nselect * from accounts where crm_configuration_id = 71 order by id desc;\nselect * from leads where crm_configuration_id = 71 order by id desc;\nselect * from contacts where crm_configuration_id = 71 order by id desc;\nselect * from opportunities where crm_configuration_id = 71 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 71 order by id desc;\nselect * from crm_fields where crm_configuration_id = 71 order by id desc;\nselect * from crm_field_values where crm_field_id = 3341 order by id desc;\nselect * from crm_layouts where crm_configuration_id = 71 order by id desc;\nselect * from stages where crm_configuration_id = 71 order by id desc;\n\nselect * from users order by secondary_email desc;\nselect u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa\n join users u on sa.sociable_id = u.id\nwhere sa.provider = 'google' and u.email LIKE 'aneliya%';\n\nselect * from failed_jobs order by id desc;\n\nselect * from users where email = 'ben.allwright@learningpeople.co.uk' or secondary_email = 'ben.allwright@learningpeople.co.uk';\n\nselect * from teams;\nSELECT * FROM crm_profiles WHERE crm_configuration_id = 39;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 1\nand sa.provider = 'salesforce';\n\n# ************************************************************************************\nSELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;\nSELECT * FROM crm_configurations WHERE id = 70;\n\nselect * from teams where id = 1;\nselect * from groups where team_id = 1;\nselect * from users where team_id = 1;\n\nselect o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o\njoin users u on o.user_id = u.id\njoin groups g on u.group_id = g.id\njoin role_user ru on u.id = ru.user_id\njoin roles r on ru.role_id = r.id\nwhere o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';\n\nselect * from role_user where user_id = 143;\nselect * from roles;\n\nselect * from role_user;\nselect * from groups where id = 9;\nselect * from scope_groups where group_id = 9;\n\n# ************************************************************************************\nselect * from teams where id = 36;\nselect * from crm_configurations;\nSELECT * FROM social_accounts WHERE sociable_id = 121;\n\nhttps://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105\nhttps://crmsandbox.zoho.com/crm/\n\nhttps://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080\n https://crm.zoho.com/crm/\n org3469620\n\nSELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;\n\nselect * from users where email LIKE \"%mobile_automation_%\";\nselect * from social_accounts where sociable_id IN (2228);\nselect * from crm_profiles where user_id IN (2222,2223,2226,2227);\n\nselect * from teams order by id desc;\nSELECT * FROM users WHERE id = 2229;\nSELECT * FROM crm_profiles WHERE user_id = 2229;\nselect * from opportunities where crm_configuration_id = 88;\nselect * from crm_fields where crm_configuration_id = 88;\nselect * from crm_profiles where crm_configuration_id = 88;\n\nSELECT * FROM teams WHERE id = 1;\n\nSELECT * FROM users WHERE id = 143;\nSELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;\n\nhttps://app.staging.jiminny.com/ondemand?\n min_duration=1\n &\n only_recorded=1\n &\n user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e\n &\n sequence_number=2\n\n select * from users where team_id = 1 and email like '%stoyan%'\n\nselect * from coaching_feedbacks;\n\nselect * from teams;\nSELECT * FROM users WHERE team_id = 36;\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from users where id = 143;\n\nSELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\nSELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;\n\nselect * from users where team_id = 2;\nselect * from activities where crm_configuration_id = 39\nand activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'\nAND user_id = 143\norder by id desc;\n\n# ************************************************************************************\nselect * from teams where id = 142; # 2312, 126\nselect * from team_settings;\nselect * from users where team_id = 142; # 21642\nSELECT * FROM social_accounts WHERE sociable_id = 21642;\nSELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;\nselect * from crm_profiles where id IN (93);\nselect * from invitations;\nselect * from team_features where team_id = 1;\n\nSELECT * FROM crm_configurations WHERE id = 126;\nselect * from accounts where crm_configuration_id = 126 order by id desc;\nselect * from leads where crm_configuration_id = 126 order by id desc;\nselect * from contacts where crm_configuration_id = 126 order by id desc;\nselect * from opportunities where crm_configuration_id = 126 order by id desc;\nselect * from crm_profiles where crm_configuration_id = 126 order by id desc;\nselect * from crm_fields where crm_configuration_id = 126 # 11060\n# and type IN ('picklist', 'status')\n# and object_type = 'task'\norder by id desc;\n# 5731,5732,5733\nselect DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;\nselect * from crm_layouts where crm_configuration_id = 126 order by id desc;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);\nselect * from stages where crm_configuration_id = 126 order by id desc;\nselect * from business_processes where crm_configuration_id = 126 order by id desc;\nselect * from business_process_stages where business_process_id IN (76,75,74,73);\nselect * from playbooks where team_id = 142;\nselect * from playbook_layouts where playbook_id IN (108);\nSELECT * FROM playbook_categories WHERE playbook_id IN (108);\n\nselect * from teams where id = 130;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 2\nand sa.provider = 'hubspot';\n\nSELECT * FROM activities\n WHERE crm_configuration_id = 110;\n\nselect * from teams;\nselect * from crm_configurations;\n\nSELECT * FROM activities WHERE id = 628773;\nSELECT * FROM crm_profiles WHERE user_id = 1460;\nSELECT * FROM social_accounts WHERE sociable_id = 2291;\n\nselect * from teams;\nselect ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id\njoin permission_role pr on pr.role_id = ru.role_id\n join permissions p on p.id = pr.permission_id\nwhere team_id = 495 and p.name IN ('dial');\n\nselect * from teams where id = 145;\nselect * from crm_configurations where id = 129;\nselect * from social_accounts where sociable_id = 2317;\nSELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;\n\nselect * from teams where id = 1;\nSELECT * FROM crm_layouts WHERE crm_configuration_id = 39;\nSELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;\nSELECT * FROM crm_layout_entities WHERE id = 5507;\nSELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');\n\nselect * from teams;\nselect * from activities where crm_configuration_id = 14;\n\nSELECT * FROM social_accounts where provider = 'copper';\n\nselect * from activities where id = 628467;\nselect * from participants where activity_id = 628467;\n\nSELECT * FROM contacts WHERE id = 3969;\nSELECT * FROM accounts WHERE id = 177;\n\nSELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;\n\n# ********************* BH\nselect * from teams where id = 36;\nSELECT * FROM crm_configurations WHERE id = 21;\nselect * from activities where crm_configuration_id = 21 and id = 607901;\nselect * from activities where crm_configuration_id = 21;\n\nselect * roles;\nselect * from permissions;\nselect * from permission_role where permission_id = 226;\n\nselect * from migrations order by id desc;\n\n# mercury\n# neptune\n# earth\n\nselect * from teams;\nselect * from teams where id = 19;\nselect * from teams where id = 27;\nselect * from users where team_id = 27;\nSELECT * FROM crm_configurations WHERE id = 42;\n\nselect * from social_accounts sa\njoin users u on sa.sociable_id = u.id\nwhere u.team_id = 19\nand sa.provider = 'pipedrive';\n\nselect * from activities where id = 631461;\nSELECT * FROM crm_field_values WHERE crm_field_id = 180;\n\nselect * from teams where id = 2;\nSELECT * FROM social_accounts WHERE sociable_id = 89;\n\nSELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273\nselect * from activity_summary_logs where activity_id = 634273;\n\nselect * from sidekick_settings where team_id = 2;\n\nselect * from teams; # 2, 2\nSELECT * FROM crm_configurations WHERE team_id = 2; # 2\nselect * from team_features where team_id = 2;\nselect * from features;\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';\nSELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;\n\nselect * from automated_reports order by id desc;\nselect * from automated_report_results order by id desc;\nselect * from users where team_id = 1 and id IN (7160, 3248);\nselect * from migrations order by id desc;\n\nSELECT\n CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,\n u.email,\n sa.*,\n t.owner_id FROM social_accounts sa\nJOIN users u on u.id = sa.sociable_id\nJOIN teams t on t.id = u.team_id\nWHERE u.team_id = 1 and sa.provider = 'salesforce';\n\nselect * from teams where id = 1;\nselect * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;\nselect * from groups where id = 565;\nselect * from playbooks where team_id = 1;\nselect * from playbooks where id = 175;\nselect * from playbook_categories where playbook_id = 175;\nselect * from users where team_id = 1;\nselect * from users where id = 7160;\nselect * from crm_profiles where user_id = 7160;\nselect * from features;\nselect\n *\n# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,\n# crm_configuration_id, crm_provider_id, transcription_id, status\nfrom activities where crm_configuration_id = 1 and type = 'conference'\n# and crm_provider_id IS NOT NULL\nand provider != 'uploader' and actual_start_time IS NOT NULL\nORDER by id desc;\nselect * from activities where id = 54747783; # 00UO400000pCzojMAC\n\nselect p.id, p.activity_type, pc.id, pc.name\nFROM playbooks p\njoin playbook_categories pc on p.id = pc.playbook_id\nwhere p.team_id = 1 and p.activity_type = 'event';\n\nSELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';\nSELECT * FROM crm_field_values WHERE crm_field_id = 4;\n\nselect * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id\nwhere crm_configuration_id = 1 and pl.playbook_id = 175;\n\nselect * from teams;\nSELECT r.* FROM automated_reports r\njoin teams t on r.team_id = t.id\nWHERE r.frequency = 'daily'\n and r.status = 1\nAND t.status = 'active'\nAND (r.expires_at >= now() OR r.expires_at IS NULL);\n\nselect * from automated_report_results where report_id IN (18, 33);\n\nselect * from activity_searches where id = 10932;\nselect * from activity_search_filters where activity_search_id = 10932;\nselect * from automated_reports;\nselect * from automated_report_results where report_id IN (34, 35);","role_description":"text entry area","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Project","depth":3,"role_description":"text"},{"role":"AXButton","text":"Project","depth":3,"bounds":{"left":0.0140625,"top":0.041666668,"width":0.028515626,"height":0.021527778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"New File or Directory…","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Expand Selected","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Collapse All","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Options","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false}]...
|
1882912414143491833
|
6686649039917069389
|
click
|
accessibility
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
1
5
Previous Highlighted Error
Next Highlighted Error
<?php
namespace Jiminny\Console\Commands\Crm;
use Illuminate\Console\Command;
use Jiminny\Models\Team;
class AddLayoutEntities extends Command
{
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'crm:create-layout-entity
{--teamId=}
{--parentEntityId= : The layout entity label e.g. activity-summary}
{--crmLayoutId= : The crm layout id e.g. 6}
{--crmFieldId= : The crm provider field id}
{--searchable= : Setups the is_indexable/is_filterable field behaviour default: true}'
;
/**
* The console command description.
*
* @var string
*/
protected $description = 'Adds layouts to expose fields in the UI.';
/**
* Execute the console command.
*/
public function handle(): void
{
$teamId = $this->option('teamId');
$parentEntityId = $this->option('parentEntityId');
$crmLayoutId = $this->option('crmLayoutId');
$crmFieldId = $this->option('crmFieldId');
$isSearchable = $this->option('searchable');
if ($teamId == null
|| $parentEntityId === null
|| $crmLayoutId === null
|| $crmFieldId === null
) {
$this->error('Please provide all parameters.');
return;
}
$team = Team::idOrUUid($teamId);
if ($team === null) {
$this->error('Invalid team provided.');
return;
}
$crmConfig = $team->crm;
$layout = $crmConfig->layouts()->where('id', $crmLayoutId)->first();
if ($layout === null) {
$this->error('Invalid crmLayoutId provided.');
return;
}
$field = $crmConfig->fields()->where('crm_provider_id', $crmFieldId)->first();
if ($field === null) {
$this->error('Invalid field provided.');
return;
}
$existingEntity = $layout->entities()->where([
'crm_field_id' => $field->id,
])->first();
if ($existingEntity !== null) {
$this->error('The specified layout entity already exists.');
return;
}
$parentId = null;
$parentEntity = $layout->entities()->where('label', $parentEntityId)->first();
if ($parentEntity !== null) {
$parentId = $parentEntity->id;
}
$entity = $layout->entities()->create([
'crm_field_id' => $field->id,
'label' => $field->label,
'description' => $field->description,
'is_visible' => true,
'parent_entity_id' => $parentId,
]);
$isIndexable = true;
$isFilterable = true;
if ($isSearchable === false) {
$isIndexable = false;
$isFilterable = false;
}
$field->update([
'is_indexable' => $isIndexable,
'is_filterable' => $isFilterable,
]);
$this->comment('Created entity #' . $entity->id);
}
}
Execute
Explain Plan
Browse Query History
View Parameters
Open Query Execution Settings…
In-Editor Results
Tx: Auto
Cancel Running Statements
Playground
jiminny
Sync Changes
Hide This Notification
Code changed:
Hide
16
13
13
Previous Highlighted Error
Next Highlighted Error
SELECT * FROM teams WHERE id = 1;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 283;
SELECT * FROM crm_fields WHERE id = 2234;
SELECT * FROM crm_field_values WHERE crm_field_id = 2234;
select * from crm_profiles where user_id = 143;
select * from record_types where crm_configuration_id = 39; # 0121K000001MHElQAO,0121K000001MHEqQAO
select * from business_processes where crm_configuration_id = 39;
# 01941000000H669AAC, 01941000000H66JAAS
select * from record_type_field_values
where record_type_id IN (24);
select * from crm_field_values where id IN (2730);
select * from crm_configurations where id = 39;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce'; #1035
select * from users where team_id = 1; # 222 group 3
SELECT * FROM activities WHERE user_id = 222 order by id desc;
select * from sidekick_settings where team_id = 1;
select * from teams where id = 1;
select * from team_features where team_id = 1;
select * from activities where crm_configuration_id = 2
and provider = 'ms-teams' and id = 608765;
SELECT * FROM activities WHERE crm_configuration_id = 2 and crm_provider_id = '59523413338';
select * from sidekick_settings where team_id = 2;
SELECT * FROM activities WHERE id = 608660;
select * from activity_summary_logs where activity_id = 608660;
select * from ai_prompts where transcription_id = 11214;
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('ed78a437-2804-450e-ab2f-56ab1c641346') = uuid;
# id: 608818, crm: 59628809737
SELECT * FROM activities WHERE uuid_to_bin('36b06e55-afdd-4782-8dee-c624cd0af191') = uuid;
# id: 608821, crm: 59632069252
SELECT ce.start_time, ce.end_time, a.id, a.uuid, crm_provider_id, calendar_event_id, title,
playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id,
scheduled_start_time, scheduled_end_time, actual_start_time, actual_end_time, a.created_at
FROM activities a
join calendar_events ce on a.calendar_event_id = ce.id
WHERE a.id IN (608818, 608821);
select * from users where team_id = 1;
select * from team_settings where team_id = 1;
select * from crm_profiles where crm_configuration_id = 39 order by user_id;
select * from team_features where team_id = 1;
select * from users where team_id = 2;
SELECT * FROM activities WHERE uuid_to_bin('ec7647e9-5225-458b-b475-f31aa2769204') = uuid; # 612639
# Preslava N. Ivanova, grou id 3
SELECT * FROM opportunities WHERE uuid_to_bin('a2928fe5-aec5-46cb-85d9-7654c89e46a6') = uuid;
select * from activities where opportunity_id = 344 and actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00';
select
a.id,
a.type,
a.scheduled_start_time,
a.actual_start_time,
a.created_at,
a.opportunity_id,
a.status
FROM activities a
WHERE opportunity_id = 344
and status IN ('completed', 'received', 'delivered')
and (
(a.actual_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.created_at between '2024-10-11 00:00:00' and '2024-10-12 00:00:00')
OR (a.scheduled_start_time between '2024-10-11 00:00:00' and '2024-10-12 00:00:00'))
;
SELECT * FROM users WHERE id = 222;
SELECT * FROM crm_profiles WHERE user_id = 222;
select * from crm_layouts where crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 281;
select * from group_deal_risk_types;
select * from opportunities where team_id = 1;
SELECT * FROM opportunities WHERE id = 315;
SELECT * FROM crm_field_data WHERE object_id = 315;
select * from crm_field_data where object_id = 260;
select * from generic_ai_prompts where subject_id = 315;
select * from teams; # 36, 21, 121, [EMAIL]
SELECT * FROM social_accounts WHERE sociable_id = 121 and provider = 'bullhorn';
# [PASSWORD_DOTS]
select * from teams where id = 1;
select * from crm_configurations where id = 39;
select * from users where team_id = 1;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 1;
# 1 - 00541000004281rAAA
# 204 - 0052g000003freeAAA
# 429 - 0052g000003qGOiAAM
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
select * from activities where type = 'softphone'
and created_at > '2024-12-11 15:24:36' order by id desc;
select * from activity_providers where team_id = 1;
select * from activity_provider_users where activity_provider_id = 328;
select * from opportunities where crm_configuration_id = 39
AND account_id = 178 AND is_closed = false
order by created_at DESC;
select * from contacts where id = 3952;
select * from accounts where id = 178;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations where id = 21;
select * from users where team_id = 36;
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 36
and sa.provider = 'bullhorn';
select * from social_accounts where id = 348;
UPDATE social_accounts SET
provider_user_token = '21442_6802599_91:41179a58-21e7-4d7c-ad58-56bb666b2f65',
provider_refresh_token = '21442_6802599_91:01c6b335-3f2a-42e4-85ff-8a08fa65fceb',
expires = 1733998131,
state = 'connected'
WHERE id = 348;
# [PASSWORD_DOTS]
select * from teams where id = 31;
select * from crm_configurations where id = 18;
select * from users where team_id = 31; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 31;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 31
and sa.provider = 'close';
select * from contacts where crm_configuration_id = 18;
# [PASSWORD_DOTS] NEPTUNE [PASSWORD_DOTS]
select * from teams;
select * from users where id IN (1030, 1035, 1052);
select * from crm_configurations;
select * from users where team_id = 65; # 257
select * from team_settings where team_id = 65; # 257
select * from invitations where team_id = 65; # 257
select * from users where email = '[EMAIL]'; # 257
select u.email, cp.* from users u
join crm_profiles cp on u.id = cp.user_id
where u.team_id = 65;
select * from crm_configurations where id = 53;
select * from accounts where crm_configuration_id = 53 order by id desc;
select * from leads where crm_configuration_id = 53 order by id desc;
select * from contacts where crm_configuration_id = 53 order by id desc;
select * from opportunities where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 53 order by id desc;
select * from crm_fields where crm_configuration_id = 53 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 53 order by id desc;
select * from stages where crm_configuration_id = 53 order by id desc;
select * from crm_profiles where crm_configuration_id = 13;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
and sa.provider = 'integration-app';
select * from contacts where crm_configuration_id = 13;
select * from social_accounts where sociable_id = 283;
SELECT * FROM opportunities WHERE crm_provider_id = '006O400000E9bzeIAB';
select * from activity_providers where team_id = 65;
SELECT * FROM activities WHERE crm_configuration_id IN (51, 52, 53);
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 65
;
# [PASSWORD_DOTS] STAGING [PASSWORD_DOTS]
SELECT * FROM teams;
SELECT * FROM teams WHERE id = 88;
SELECT * FROM teams WHERE id = 89;
select * from team_settings where team_id = 89;
SELECT * FROM users WHERE team_id = 89;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 89;
select * from users;
SELECT * FROM social_accounts WHERE sociable_id = 1761;
SELECT * FROM crm_configurations WHERE id = 70;
select * from accounts where crm_configuration_id = 70 order by id desc;
select * from leads where crm_configuration_id = 70 order by id desc;
select * from contacts where crm_configuration_id = 70 order by id desc;
select * from opportunities where crm_configuration_id = 70 order by id desc;
select * from crm_profiles where crm_configuration_id = 70 order by id desc;
select * from crm_fields where crm_configuration_id = 70 order by id desc;
select * from crm_field_values where crm_field_id = 3536 order by id desc;
select * from crm_layouts where crm_configuration_id = 70 order by id desc;
select * from stages where crm_configuration_id = 70 order by id desc;
select * from business_processes where crm_configuration_id = 70 order by id desc;
select * from business_process_stages where business_process_id = 34;
select * from contacts where id = 10468;
select * from crm_layouts where crm_configuration_id = 70;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 388;
SELECT * FROM crm_fields WHERE id IN (3533,3534,3535);
select * from activities where crm_configuration_id = 70
and (account_id IS NOT NULL or lead_id IS NOT NULL or contact_id IS NOT NULL or opportunity_id IS NOT NULL) order by id desc;
SELECT * FROM activities WHERE uuid_to_bin('2e10b60f-8a61-41c5-a3d4-28835353dc65') = uuid;
SELECT * FROM activities where crm_configuration_id = 69 ;
SELECT * FROM users WHERE email LIKE '%[EMAIL]%';
SELECT * FROM activities WHERE uuid_to_bin('5a150c93-40fc-42ec-b3bd-c1d328e09f6e') = uuid;
SELECT * FROM opportunities WHERE id = 385;
select * from participants p
join activities a on p.activity_id = a.id
where a.crm_configuration_id = 70
and (p.lead_id IS NOT NULL or p.contact_id IS NOT NULL);
SELECT * FROM participants WHERE id = 1013638;
select * from teams where id = 90;
select * from users where team_id = 90;
select * from social_accounts where social_accounts.sociable_id IN (1960,1760);
SELECT * FROM crm_profiles WHERE crm_configuration_id = 71;
select * from invitations where team_id = 90;
select * from crm_configurations where id = 71;
select * from accounts where crm_configuration_id = 71 order by id desc;
select * from leads where crm_configuration_id = 71 order by id desc;
select * from contacts where crm_configuration_id = 71 order by id desc;
select * from opportunities where crm_configuration_id = 71 order by id desc;
select * from crm_profiles where crm_configuration_id = 71 order by id desc;
select * from crm_fields where crm_configuration_id = 71 order by id desc;
select * from crm_field_values where crm_field_id = 3341 order by id desc;
select * from crm_layouts where crm_configuration_id = 71 order by id desc;
select * from stages where crm_configuration_id = 71 order by id desc;
select * from users order by secondary_email desc;
select u.id, u.email, u.status, sa.id, sa.provider_user_id from social_accounts sa
join users u on sa.sociable_id = u.id
where sa.provider = 'google' and u.email LIKE 'aneliya%';
select * from failed_jobs order by id desc;
select * from users where email = '[EMAIL]' or secondary_email = '[EMAIL]';
select * from teams;
SELECT * FROM crm_profiles WHERE crm_configuration_id = 39;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type = 'task';
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 1
and sa.provider = 'salesforce';
# [PASSWORD_DOTS]
SELECT * FROM activities WHERE uuid_to_bin('c38b3895-fd0f-4b1f-9fb2-c170dba137c6') = uuid;
SELECT * FROM crm_configurations WHERE id = 70;
select * from teams where id = 1;
select * from groups where team_id = 1;
select * from users where team_id = 1;
select o.id, o.name,o.close_date, u.id, u.name, u.group_id, r.id, r.display_name, g.name, g.scope from opportunities o
join users u on o.user_id = u.id
join groups g on u.group_id = g.id
join role_user ru on u.id = ru.user_id
join roles r on ru.role_id = r.id
where o.crm_configuration_id = 39 and close_date > '2024-01-01 00:00:00';
select * from role_user where user_id = 143;
select * from roles;
select * from role_user;
select * from groups where id = 9;
select * from scope_groups where group_id = 9;
# [PASSWORD_DOTS]
select * from teams where id = 36;
select * from crm_configurations;
SELECT * FROM social_accounts WHERE sociable_id = 121;
https://crmsandbox.zoho.com/crm/jiminnyw4/tab/Leads/4776201000005049105
https://crmsandbox.zoho.com/crm/
https://crm.zoho.com/crm/org3469620/tab/Leads/230045000229559080
https://crm.zoho.com/crm/
org3469620
SELECT * FROM activities WHERE uuid_to_bin('03382d20-c8bc-48e7-a3d4-90b52fa5ceab') = uuid;
select * from users where email LIKE "%mobile_automation_%";
select * from social_accounts where sociable_id IN (2228);
select * from crm_profiles where user_id IN (2222,2223,2226,2227);
select * from teams order by id desc;
SELECT * FROM users WHERE id = 2229;
SELECT * FROM crm_profiles WHERE user_id = 2229;
select * from opportunities where crm_configuration_id = 88;
select * from crm_fields where crm_configuration_id = 88;
select * from crm_profiles where crm_configuration_id = 88;
SELECT * FROM teams WHERE id = 1;
SELECT * FROM users WHERE id = 143;
SELECT * FROM users WHERE uuid_to_bin('fde193d3-06a2-4e1a-8895-62b94039215d') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73385071-a756-42ae-9c73-8b53f2309467') = uuid;
https://app.staging.jiminny.com/ondemand?
min_duration=1
&
only_recorded=1
&
user_id%5B%5D=641f1acb-16b8-42d1-8726-df52979dad0e
&
sequence_number=2
select * from users where team_id = 1 and email like '%stoyan%'
select * from coaching_feedbacks;
select * from teams;
SELECT * FROM users WHERE team_id = 36;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from users where id = 143;
SELECT * FROM users WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM teams WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
SELECT * FROM activity_shares WHERE uuid_to_bin('73180eeb-33de-4065-977d-ccbe0e6c94fc') = uuid;
select * from users where team_id = 2;
select * from activities where crm_configuration_id = 39
and activities.scheduled_start_time BETWEEN '2025-04-09 00:00:00' AND '2025-04-09 23:59:59'
AND user_id = 143
order by id desc;
# [PASSWORD_DOTS]
select * from teams where id = 142; # 2312, 126
select * from team_settings;
select * from users where team_id = 142; # 21642
SELECT * FROM social_accounts WHERE sociable_id = 21642;
SELECT * FROM crm_profiles cp join users u ON u.id = cp.user_id WHERE team_id = 142;
select * from crm_profiles where id IN (93);
select * from invitations;
select * from team_features where team_id = 1;
SELECT * FROM crm_configurations WHERE id = 126;
select * from accounts where crm_configuration_id = 126 order by id desc;
select * from leads where crm_configuration_id = 126 order by id desc;
select * from contacts where crm_configuration_id = 126 order by id desc;
select * from opportunities where crm_configuration_id = 126 order by id desc;
select * from crm_profiles where crm_configuration_id = 126 order by id desc;
select * from crm_fields where crm_configuration_id = 126 # 11060
# and type IN ('picklist', 'status')
# and object_type = 'task'
order by id desc;
# 5731,5732,5733
select DISTINCT crm_field_id from crm_field_values where crm_field_id IN (11151,12239,12215,12185,12175,12165,12144,12137,12127,12109,12107,12105,12103,12092,12037,12005,12003,11987,11969,11958,11951,11942,11931,11924,11921,11917,11915,11901,11893,11883,11872,11870,11868,11866,11839,11833,11821,11793,11780,11777,11769,11757,11737,11735,11656,11645,11638,11629,11618,11611,11602,11591,11584,11581,11558,11544,11543,11534,11532,11529,11527,11503,11497,11493,11488,11470,11468,11457,11455,11397,11387,11372,11363,11348,11323,11318,11309,11301,11300,11292,11290,11286,11284,11256,11252,11242,11237,11233,11219,11176,11160) order by id desc;
select * from crm_layouts where crm_configuration_id = 126 order by id desc;
SELECT * FROM crm_layout_entities WHERE crm_layout_id in (300,299,298);
select * from stages where crm_configuration_id = 126 order by id desc;
select * from business_processes where crm_configuration_id = 126 order by id desc;
select * from business_process_stages where business_process_id IN (76,75,74,73);
select * from playbooks where team_id = 142;
select * from playbook_layouts where playbook_id IN (108);
SELECT * FROM playbook_categories WHERE playbook_id IN (108);
select * from teams where id = 130;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 2
and sa.provider = 'hubspot';
SELECT * FROM activities
WHERE crm_configuration_id = 110;
select * from teams;
select * from crm_configurations;
SELECT * FROM activities WHERE id = 628773;
SELECT * FROM crm_profiles WHERE user_id = 1460;
SELECT * FROM social_accounts WHERE sociable_id = 2291;
select * from teams;
select ru.*, pr.*, p.* from users u join role_user ru on ru.user_id = u.id
join permission_role pr on pr.role_id = ru.role_id
join permissions p on p.id = pr.permission_id
where team_id = 495 and p.name IN ('dial');
select * from teams where id = 145;
select * from crm_configurations where id = 129;
select * from social_accounts where sociable_id = 2317;
SELECT * FROM activities WHERE uuid_to_bin('8dbab184-a333-4268-ad57-fb41f8d53a9a') = uuid;
select * from teams where id = 1;
SELECT * FROM crm_layouts WHERE crm_configuration_id = 39;
SELECT * FROM crm_layout_entities WHERE crm_layout_id = 280;
SELECT * FROM crm_layout_entities WHERE id = 5507;
SELECT * FROM crm_fields WHERE crm_configuration_id = 39 and object_type IN ('event');
select * from teams;
select * from activities where crm_configuration_id = 14;
SELECT * FROM social_accounts where provider = 'copper';
select * from activities where id = 628467;
select * from participants where activity_id = 628467;
SELECT * FROM contacts WHERE id = 3969;
SELECT * FROM accounts WHERE id = 177;
SELECT * FROM activities WHERE uuid_to_bin('4eb54c77-cfa3-2bd4-84a7-9ed46a21c988') = uuid;
# [PASSWORD_DOTS] BH
select * from teams where id = 36;
SELECT * FROM crm_configurations WHERE id = 21;
select * from activities where crm_configuration_id = 21 and id = 607901;
select * from activities where crm_configuration_id = 21;
select * roles;
select * from permissions;
select * from permission_role where permission_id = 226;
select * from migrations order by id desc;
# mercury
# neptune
# earth
select * from teams;
select * from teams where id = 19;
select * from teams where id = 27;
select * from users where team_id = 27;
SELECT * FROM crm_configurations WHERE id = 42;
select * from social_accounts sa
join users u on sa.sociable_id = u.id
where u.team_id = 19
and sa.provider = 'pipedrive';
select * from activities where id = 631461;
SELECT * FROM crm_field_values WHERE crm_field_id = 180;
select * from teams where id = 2;
SELECT * FROM social_accounts WHERE sociable_id = 89;
SELECT * FROM activities WHERE uuid_to_bin('ba0c029a-bc14-4e17-8603-64174acebcbb') = uuid; # 634273
select * from activity_summary_logs where activity_id = 634273;
select * from sidekick_settings where team_id = 2;
select * from teams; # 2, 2
SELECT * FROM crm_configurations WHERE team_id = 2; # 2
select * from team_features where team_id = 2;
select * from features;
SELECT * FROM opportunities WHERE crm_configuration_id = 2 and crm_provider_id = '51317301383';
SELECT * FROM opportunities WHERE crm_configuration_id = 2 order by id desc;
select * from automated_reports order by id desc;
select * from automated_report_results order by id desc;
select * from users where team_id = 1 and id IN (7160, 3248);
select * from migrations order by id desc;
SELECT
CONCAT(u.id, CASE WHEN u.id = t.owner_id THEN ' (owner)' ELSE '' END) AS user_id,
u.email,
sa.*,
t.owner_id FROM social_accounts sa
JOIN users u on u.id = sa.sociable_id
JOIN teams t on t.id = u.team_id
WHERE u.team_id = 1 and sa.provider = 'salesforce';
select * from teams where id = 1;
select * from groups g JOIN playbooks p on g.playbook_id = p.id where g.team_id = 1;
select * from groups where id = 565;
select * from playbooks where team_id = 1;
select * from playbooks where id = 175;
select * from playbook_categories where playbook_id = 175;
select * from users where team_id = 1;
select * from users where id = 7160;
select * from crm_profiles where user_id = 7160;
select * from features;
select
*
# id, uuid, type, provider, playbook_category_id, user_id, lead_id, contact_id, account_id, opportunity_id, stage_id,
# crm_configuration_id, crm_provider_id, transcription_id, status
from activities where crm_configuration_id = 1 and type = 'conference'
# and crm_provider_id IS NOT NULL
and provider != 'uploader' and actual_start_time IS NOT NULL
ORDER by id desc;
select * from activities where id = 54747783; # 00UO400000pCzojMAC
select p.id, p.activity_type, pc.id, pc.name
FROM playbooks p
join playbook_categories pc on p.id = pc.playbook_id
where p.team_id = 1 and p.activity_type = 'event';
SELECT * FROM crm_fields WHERE crm_configuration_id = 1 and object_type = 'event';
SELECT * FROM crm_field_values WHERE crm_field_id = 4;
select * from crm_layouts cl join playbook_layouts pl on cl.id = pl.layout_id
where crm_configuration_id = 1 and pl.playbook_id = 175;
select * from teams;
SELECT r.* FROM automated_reports r
join teams t on r.team_id = t.id
WHERE r.frequency = 'daily'
and r.status = 1
AND t.status = 'active'
AND (r.expires_at >= now() OR r.expires_at IS NULL);
select * from automated_report_results where report_id IN (18, 33);
select * from activity_searches where id = 10932;
select * from activity_search_filters where activity_search_id = 10932;
select * from automated_reports;
select * from automated_report_results where report_id IN (34, 35);
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
NULL
|
|
10779
|
NULL
|
0
|
2026-04-14T08:58:19.384651+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776157099384_m1.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
+SlackEDHomeDMSActivityFilesLater..•More+FileEditV +SlackEDHomeDMSActivityFilesLater..•More+FileEditViewGoHistoryWindowHelp> 0→Search Jiminny IncJiminny ...Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev# Starredplatform-inner-teamMessagesAdd canvas+Phooa да тестоan АРусротораmone nunpomопределен когато тествамеChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product_launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi…..Nikolay Yankov 10:41 AMможеш ли да я рьннеш ти командатаLukas Kovalik 10:43 AMдаNikolay Yankov 10:45 AMпиши кат оя рьннешLukas Kovalik 10:52 AMзабавих се че ми се разбазикаха settings за средипуснах и мина и fail-наима result но e failedзначиREASON_NOT_ENOUGH_ACTIVITIESвиж дали има нещо в OD със този филтьрNikolay Yankov 11:01 AMДобреNikolay Yankov 11:39 AMя рьнни пак LukasLukas Kovalik 11:43 AMготовосьщото• Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili...R. Adelina PetrovaO. Calea DimitravoCompetitive pitches беше втория нали такаMessage Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev+AaSupport Daily - in 3 h 2 m100% C48Tue 14 Apr 11:58:19Fuune 4Today ~New...
|
NULL
|
-8437864004237255915
|
NULL
|
click
|
ocr
|
NULL
|
+SlackEDHomeDMSActivityFilesLater..•More+FileEditV +SlackEDHomeDMSActivityFilesLater..•More+FileEditViewGoHistoryWindowHelp> 0→Search Jiminny IncJiminny ...Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev# Starredplatform-inner-teamMessagesAdd canvas+Phooa да тестоan АРусротораmone nunpomопределен когато тествамеChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product_launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi…..Nikolay Yankov 10:41 AMможеш ли да я рьннеш ти командатаLukas Kovalik 10:43 AMдаNikolay Yankov 10:45 AMпиши кат оя рьннешLukas Kovalik 10:52 AMзабавих се че ми се разбазикаха settings за средипуснах и мина и fail-наима result но e failedзначиREASON_NOT_ENOUGH_ACTIVITIESвиж дали има нещо в OD със този филтьрNikolay Yankov 11:01 AMДобреNikolay Yankov 11:39 AMя рьнни пак LukasLukas Kovalik 11:43 AMготовосьщото• Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili...R. Adelina PetrovaO. Calea DimitravoCompetitive pitches беше втория нали такаMessage Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev+AaSupport Daily - in 3 h 2 m100% C48Tue 14 Apr 11:58:19Fuune 4Today ~New...
|
10777
|
|
10780
|
NULL
|
0
|
2026-04-14T08:58:19.423899+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776157099423_m2.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
PhpStormFileEditFV faVsco.js vViewNavigateCodeLara PhpStormFileEditFV faVsco.js vViewNavigateCodeLaravelRefactor#11894 on JY-18909-automated-reports-ask-iminny K vToolsWindowHelpProjectv© DeviceRepository.php© ElasticActivityRepository.pl© EmailMessageRepository.p© GenericAiPromptRepositor:© GroupRepository.php(C) InboxEmailBatchRepositon)InboxRepository.php© InvitationRepository.php© JobRepository.php© LanguageRepository.php© MomentRepository.php© NotificationRepository.php© ParticipantRepository.php© ParticipantSpeechReposito© ParticipantStatsRepository© PlaybookCategoryRepositc© PlaybookRepository.php® PlaylistActivityRepository.fPlaylistRepository.phpPlaylistShareRepository.ph© QuestionRepository.php© RoleChangeEventRepositor© RoleRepository.php© SearchRepository.php© SnapshotRepository.php© SocialAccountRepository.p© StageRepository.php© SubscriptionSetRepository.TaskRepository.php© TeamAiContextRepository.TeamDomainsRepository.p©TeamInsightsRepository.pt©TeamRepository.php©ThemeRepository.php© TimezoneRepository.php© TopicRepository.php© TopicTriggerRepository.ph© TrackRepository.php© TranscriptionModelLocaleF© TranscriptionRepository.phC) TranscriptionSummarvRep© UserRepository.php© VocabularyRepository.pnp> D Rulesv D Services> [ Activity> C AjReportsDAvatarcalendarD ConferenceD Crm>MImport> MInternalv D Kioskv _ AutomatedReports© ActivityTypeService.© AskJiminnyReportAc© AutomatedReportsCi© AutomatedReportsSt© ReportController.php© JiminnyDebugCommand.php© AutomatedReportsSendCommand.phpC AutomatedReportsCommand.php© AddLayoutEntities.php© Team.phpAutomaleakeporsservice.ong© AutomatedReportsRepository.php© CreateHeldActivityEvent.php© TrackProviderInstalledEvent.phpCrealeAcuivilyLogqedbvent.ono(C) User?llorActivivuistener.ohn© ActivityLogged.phpc) AutomatedRenorscalloackoerwce.onv© RequestGenerateAskJiminnyReportJob.php x(©) RequestGenerateReportJob.php(C) AutomatedReportResult.php© AutomatedReport.phpclass RequestGenerateAskJiminnyReportJob implements opublic function handle(1):У3 ^v,258486878889100101102103104105106107110111.112return;ssavedsearcn = pautomatedkeport->gecsavedsearcnohif (SsavedSearch === null) &sLogger->warnangtsecr..Luo_Pkeria • Skipped, Saved $36'automatedReportUuid' = $this->reportUvid,1):lecurlin$prompt = $automatedReport->getAskAnythingPrompt();if ($prompt === null) {$logger->warning(self::LOG_PREFIX . ' Skipped, ask an45aucomatedkeporcuuld = suhis->reporcuula,1);recurny$this->reportResult = $reportService->createReportResult(automatedReport: $automatedReport,data: ['status' => AutomatedReportResult::STATUS_DEFAULT,'media_type' => AutomatedReportsService::MEDIA_TVF56SactivityIds = $activityService->getActivityIdsForSavedSe& 60savedSearch: $savedSearch,user: $creator,):$logger→>info(self::LOG_PREFIX . ' Fetched activity IDs','automatedReportUvid' = $this->reportUvid,'activityCount' => count($activityIds),I);if (count($activityIds) < self::MIN_ACTIVITIES_COUNT) {nuns->rau uredor reason. Aurolareckeportresult..kcAsul$logger->info(self::LOG_PREFIX .' Not enough activit:'automatedReportUuid' => $this->reportUvid,Windsurf changelog 2.12.21: A new version is available. // View Changelog (today 10:33)= custom.log4 console [EUl= laravel.logA SF [jiminny@localhost]A HS_local [jiminny@localhost]console SlAGING© AskJiminnyReportActivityService.php xA console [PROD]© RequestGenerateAskJiminnyReportJobTest.phpN2R1 A Yclass AskJiminnyReportActivityServiceprivate const int DEFAULT_TOP_ACTIVITIES_COUNT = 100;private const array [ENV_SECRET],ActivityActualDate::PARAM_END_DATE,ActivityUpdatedDate::PARAM_UPDATED_FROM,ActivityUpdatedDate: :PARAM_UPDATED_TO,ClosingPeriodFilter::KEY_START_DATE,ClosingPeriodFilter::KEY_END_DATE,public function __construct(private readonly ActivitySearch $activitySearch,private readonly ElasticActivityRepository $elasticRepository,orvare reaconuy Loccerinuertace "Lodder) 1...3/*** Fetch activity IDs for a saved search, passing its filters as-is to Criteria.* Date filters stored on the saved search are excluded; if no other filters exist,* no date constraint is applied - matching the behaviour of getContextForAskAnythingByFilter.* Oreturn string[] Activity IDspubLic tuncuion gecAculvity-asrorsavedsearcneSearch SsavedSearch,user puser.): array {$requestParams = $this->buildRequestParamsFromSearch($savedSearch, $user);$criteria = Criteria::createFromRequest(array_merge($requestParams, ['limit' => self::DEFAULT_TOP_ACTIVITIES_COUNT, 'page' => 1]),$user->getTimezone()ptilterset = suhls-›aculvitysearch-›gecunbemandrageriltersec(scriterla, suser):$activityIds = $this->elasticRepository->onDemandSearchIds0nly($user, $criteria, $filterSet);$this->logger→>info('[AsKLiminnxReRQrt] Fetched activity IDs for saved search', ['saved_search_id' => $savedSearch->getId(),'user_id' => $user-›getId(),'activity_count' => count($activityIds),1):return $activityIds;private function buildRequestParamsFromSearch(Search $savedSearch, User $user): arrayf...}j Support Daily • in 3h 2mAL RequestGenerateAskJiminnyReportJobTest v100% C•Tue 14 Apr 11:58:19CascadeFixing ReportControlle• Automated Report N• Automated Report L+D ...3. Activity fetch — [AskJiminnyReport] (from AskJiminnyReportActivityService)[AskJiminnyReport] Fetched activity IDs for saved searchSavea search lo user lo aculvity countunen immealalely aner in tne od[AskJiminnyReport:Generatel Fetched activity IDsauconacedkeporcuuld, actlvicycount4a. Failure path (< 1 activity):LAskJiminnyReport:Generatel Not enough activities, skippecautomatedReportUuid, activityCountThe AutomatedReportResult gets status=failed, reason=REASON_NOT_ENOUGH_ACTIVITIES.4b. Error path (exception):[AskJiminnyReport:Generatel ErrorautomatedReportUuid, reportUuid, code, messageWhat's missing for debuggingThe logs tell you count but not which filters were applied from the saved search. When a report fails with 0activities, you can't see why - what the saved search filters were, what date range was used, or what requestParams were bulltTwo gaps:1. AskJiminnyReportActivityService - the requestParams built from the saved search are not logged (only acalvity count2. RequestGenerateAskJiminnyReportJob - payload is only logged at "Request sent" (line 132-136), which isafter the activity count gate - so if we fail at count check, we never see the payloadIcan add loaaina to expose the apolied filters and the actual activity IDs when the count is low. Want me to addthat?Askino •uestion• What would you like to improve?What would you like to improve?Loo tne aoolee Tters recuestrarams)rrom the saveo searchAdd filter params to the existing log in AskJiminnyReportActivityService so you can see exactly what filters wereusea wnen u acuvilles are returneeLog actual activity IDs when count is lowAlso log the activity IDs themselves (not just the count) so you can inspect which specific calls were or weren'tInc ludedbolLog filters + activity IDs in AskJiminnyReportActivityServiceother answ+ <> CodeClaude Sonnet 4.6Skipwinasun leams48:40uir-o( 4 spaces...
|
NULL
|
1708373518180744534
|
NULL
|
click
|
ocr
|
NULL
|
PhpStormFileEditFV faVsco.js vViewNavigateCodeLara PhpStormFileEditFV faVsco.js vViewNavigateCodeLaravelRefactor#11894 on JY-18909-automated-reports-ask-iminny K vToolsWindowHelpProjectv© DeviceRepository.php© ElasticActivityRepository.pl© EmailMessageRepository.p© GenericAiPromptRepositor:© GroupRepository.php(C) InboxEmailBatchRepositon)InboxRepository.php© InvitationRepository.php© JobRepository.php© LanguageRepository.php© MomentRepository.php© NotificationRepository.php© ParticipantRepository.php© ParticipantSpeechReposito© ParticipantStatsRepository© PlaybookCategoryRepositc© PlaybookRepository.php® PlaylistActivityRepository.fPlaylistRepository.phpPlaylistShareRepository.ph© QuestionRepository.php© RoleChangeEventRepositor© RoleRepository.php© SearchRepository.php© SnapshotRepository.php© SocialAccountRepository.p© StageRepository.php© SubscriptionSetRepository.TaskRepository.php© TeamAiContextRepository.TeamDomainsRepository.p©TeamInsightsRepository.pt©TeamRepository.php©ThemeRepository.php© TimezoneRepository.php© TopicRepository.php© TopicTriggerRepository.ph© TrackRepository.php© TranscriptionModelLocaleF© TranscriptionRepository.phC) TranscriptionSummarvRep© UserRepository.php© VocabularyRepository.pnp> D Rulesv D Services> [ Activity> C AjReportsDAvatarcalendarD ConferenceD Crm>MImport> MInternalv D Kioskv _ AutomatedReports© ActivityTypeService.© AskJiminnyReportAc© AutomatedReportsCi© AutomatedReportsSt© ReportController.php© JiminnyDebugCommand.php© AutomatedReportsSendCommand.phpC AutomatedReportsCommand.php© AddLayoutEntities.php© Team.phpAutomaleakeporsservice.ong© AutomatedReportsRepository.php© CreateHeldActivityEvent.php© TrackProviderInstalledEvent.phpCrealeAcuivilyLogqedbvent.ono(C) User?llorActivivuistener.ohn© ActivityLogged.phpc) AutomatedRenorscalloackoerwce.onv© RequestGenerateAskJiminnyReportJob.php x(©) RequestGenerateReportJob.php(C) AutomatedReportResult.php© AutomatedReport.phpclass RequestGenerateAskJiminnyReportJob implements opublic function handle(1):У3 ^v,258486878889100101102103104105106107110111.112return;ssavedsearcn = pautomatedkeport->gecsavedsearcnohif (SsavedSearch === null) &sLogger->warnangtsecr..Luo_Pkeria • Skipped, Saved $36'automatedReportUuid' = $this->reportUvid,1):lecurlin$prompt = $automatedReport->getAskAnythingPrompt();if ($prompt === null) {$logger->warning(self::LOG_PREFIX . ' Skipped, ask an45aucomatedkeporcuuld = suhis->reporcuula,1);recurny$this->reportResult = $reportService->createReportResult(automatedReport: $automatedReport,data: ['status' => AutomatedReportResult::STATUS_DEFAULT,'media_type' => AutomatedReportsService::MEDIA_TVF56SactivityIds = $activityService->getActivityIdsForSavedSe& 60savedSearch: $savedSearch,user: $creator,):$logger→>info(self::LOG_PREFIX . ' Fetched activity IDs','automatedReportUvid' = $this->reportUvid,'activityCount' => count($activityIds),I);if (count($activityIds) < self::MIN_ACTIVITIES_COUNT) {nuns->rau uredor reason. Aurolareckeportresult..kcAsul$logger->info(self::LOG_PREFIX .' Not enough activit:'automatedReportUuid' => $this->reportUvid,Windsurf changelog 2.12.21: A new version is available. // View Changelog (today 10:33)= custom.log4 console [EUl= laravel.logA SF [jiminny@localhost]A HS_local [jiminny@localhost]console SlAGING© AskJiminnyReportActivityService.php xA console [PROD]© RequestGenerateAskJiminnyReportJobTest.phpN2R1 A Yclass AskJiminnyReportActivityServiceprivate const int DEFAULT_TOP_ACTIVITIES_COUNT = 100;private const array [ENV_SECRET],ActivityActualDate::PARAM_END_DATE,ActivityUpdatedDate::PARAM_UPDATED_FROM,ActivityUpdatedDate: :PARAM_UPDATED_TO,ClosingPeriodFilter::KEY_START_DATE,ClosingPeriodFilter::KEY_END_DATE,public function __construct(private readonly ActivitySearch $activitySearch,private readonly ElasticActivityRepository $elasticRepository,orvare reaconuy Loccerinuertace "Lodder) 1...3/*** Fetch activity IDs for a saved search, passing its filters as-is to Criteria.* Date filters stored on the saved search are excluded; if no other filters exist,* no date constraint is applied - matching the behaviour of getContextForAskAnythingByFilter.* Oreturn string[] Activity IDspubLic tuncuion gecAculvity-asrorsavedsearcneSearch SsavedSearch,user puser.): array {$requestParams = $this->buildRequestParamsFromSearch($savedSearch, $user);$criteria = Criteria::createFromRequest(array_merge($requestParams, ['limit' => self::DEFAULT_TOP_ACTIVITIES_COUNT, 'page' => 1]),$user->getTimezone()ptilterset = suhls-›aculvitysearch-›gecunbemandrageriltersec(scriterla, suser):$activityIds = $this->elasticRepository->onDemandSearchIds0nly($user, $criteria, $filterSet);$this->logger→>info('[AsKLiminnxReRQrt] Fetched activity IDs for saved search', ['saved_search_id' => $savedSearch->getId(),'user_id' => $user-›getId(),'activity_count' => count($activityIds),1):return $activityIds;private function buildRequestParamsFromSearch(Search $savedSearch, User $user): arrayf...}j Support Daily • in 3h 2mAL RequestGenerateAskJiminnyReportJobTest v100% C•Tue 14 Apr 11:58:19CascadeFixing ReportControlle• Automated Report N• Automated Report L+D ...3. Activity fetch — [AskJiminnyReport] (from AskJiminnyReportActivityService)[AskJiminnyReport] Fetched activity IDs for saved searchSavea search lo user lo aculvity countunen immealalely aner in tne od[AskJiminnyReport:Generatel Fetched activity IDsauconacedkeporcuuld, actlvicycount4a. Failure path (< 1 activity):LAskJiminnyReport:Generatel Not enough activities, skippecautomatedReportUuid, activityCountThe AutomatedReportResult gets status=failed, reason=REASON_NOT_ENOUGH_ACTIVITIES.4b. Error path (exception):[AskJiminnyReport:Generatel ErrorautomatedReportUuid, reportUuid, code, messageWhat's missing for debuggingThe logs tell you count but not which filters were applied from the saved search. When a report fails with 0activities, you can't see why - what the saved search filters were, what date range was used, or what requestParams were bulltTwo gaps:1. AskJiminnyReportActivityService - the requestParams built from the saved search are not logged (only acalvity count2. RequestGenerateAskJiminnyReportJob - payload is only logged at "Request sent" (line 132-136), which isafter the activity count gate - so if we fail at count check, we never see the payloadIcan add loaaina to expose the apolied filters and the actual activity IDs when the count is low. Want me to addthat?Askino •uestion• What would you like to improve?What would you like to improve?Loo tne aoolee Tters recuestrarams)rrom the saveo searchAdd filter params to the existing log in AskJiminnyReportActivityService so you can see exactly what filters wereusea wnen u acuvilles are returneeLog actual activity IDs when count is lowAlso log the activity IDs themselves (not just the count) so you can inspect which specific calls were or weren'tInc ludedbolLog filters + activity IDs in AskJiminnyReportActivityServiceother answ+ <> CodeClaude Sonnet 4.6Skipwinasun leams48:40uir-o( 4 spaces...
|
10778
|
|
10781
|
214
|
0
|
2026-04-14T08:58:50.085145+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776157130085_m1.jpg...
|
PhpStorm
|
faVsco.js – AskJiminnyReportActivityService.php
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
3
Previous Highlighted Error
Next Highlighted Error
<?php
declare(strict_types=1);
namespace Jiminny\Jobs\AutomatedReports;
use Carbon\Carbon;
use Illuminate\Bus\Queueable;
use Illuminate\Contracts\Queue\ShouldBeUnique;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Queue\InteractsWithQueue;
use Jiminny\Component\ProphetAi\Exceptions\ProphetException;
use Jiminny\Component\ProphetAi\ProphetClient;
use Jiminny\Component\Queue\Constants;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\AutomatedReportResult;
use Jiminny\Models\Team;
use Jiminny\Services\Kiosk\AutomatedReports\AskJiminnyReportActivityService;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Psr\Log\LoggerInterface;
use Throwable;
class RequestGenerateAskJiminnyReportJob implements ShouldQueue, ShouldBeUnique
{
use InteractsWithQueue;
use Queueable;
private const string LOG_PREFIX = '[AskJiminnyReport:Generate]';
private const int MIN_ACTIVITIES_COUNT = 1;
public int $tries = 2;
private ?AutomatedReportResult $reportResult = null;
public function __construct(private readonly string $reportUuid)
{
$this->onQueue(Constants::QUEUE_ANALYTICS);
}
public function uniqueId(): string
{
return $this->reportUuid;
}
public function handle(
AutomatedReportsService $reportService,
AskJiminnyReportActivityService $activityService,
ProphetClient $prophetClient,
LoggerInterface $logger,
): void {
$logger->info(self::LOG_PREFIX . ' Started', [
'automatedReportUuid' => $this->reportUuid,
]);
try {
$automatedReport = $reportService->getReport($this->reportUuid);
if (! $this->validateReport($automatedReport, $logger)) {
return;
}
$creator = $automatedReport->getCreator();
if ($creator === null) {
$logger->warning(self::LOG_PREFIX . ' Skipped, report creator not found', [
'automatedReportUuid' => $this->reportUuid,
]);
return;
}
$savedSearch = $automatedReport->getSavedSearch();
if ($savedSearch === null) {
$logger->warning(self::LOG_PREFIX . ' Skipped, saved search not found', [
'automatedReportUuid' => $this->reportUuid,
]);
return;
}
$prompt = $automatedReport->getAskAnythingPrompt();
if ($prompt === null) {
$logger->warning(self::LOG_PREFIX . ' Skipped, ask anything prompt not found', [
'automatedReportUuid' => $this->reportUuid,
]);
return;
}
$this->reportResult = $reportService->createReportResult(
automatedReport: $automatedReport,
data: [
'status' => AutomatedReportResult::STATUS_DEFAULT,
'media_type' => AutomatedReportsService::MEDIA_TYPE_PDF,
]
);
$activityIds = $activityService->getActivityIdsForSavedSearch(
savedSearch: $savedSearch,
user: $creator,
);
$logger->info(self::LOG_PREFIX . ' Fetched activity IDs', [
'automatedReportUuid' => $this->reportUuid,
'activityCount' => count($activityIds),
]);
if (count($activityIds) < self::MIN_ACTIVITIES_COUNT) {
$this->failReport(AutomatedReportResult::REASON_NOT_ENOUGH_ACTIVITIES);
$logger->info(self::LOG_PREFIX . ' Not enough activities, skipped', [
'automatedReportUuid' => $this->reportUuid,
'activityCount' => count($activityIds),
]);
return;
}
$payload = $reportService->getAskJiminnyGenerateReportPayload(
automatedReport: $automatedReport,
reportResult: $this->reportResult,
activityIds: $activityIds,
);
$this->reportResult->update([
'name' => $reportService->getReportFileName($this->reportResult),
'payload' => $payload,
'status' => AutomatedReportResult::STATUS_REQUESTED,
'requested_at' => Carbon::now()->toDateTimeString(),
]);
$logger->info(self::LOG_PREFIX . ' Request sent', [
'automatedReportUuid' => $this->reportUuid,
'reportUuid' => $this->reportResult->getUuid(),
'payload' => $payload,
]);
$response = $prophetClient->sendRequest(
endpoint: ProphetClient::ASK_JIMINNY_REPORT,
requestArray: $payload,
);
$logger->info(self::LOG_PREFIX . ' Response received', [
'response' => $response->getContent(),
]);
} catch (Throwable $exception) {
$reason = $exception instanceof ProphetException
? AutomatedReportResult::REASON_PROPHET_API_ERROR
: AutomatedReportResult::REASON_DEFAULT;
$this->failReport($reason);
$logger->error(self::LOG_PREFIX . ' Error', [
'automatedReportUuid' => $this->reportUuid,
'reportUuid' => $this->reportResult?->getUuid(),
'code' => $exception->getCode(),
'message' => $exception->getMessage(),
]);
if ($this->attempts() < $this->tries) {
$logger->info(self::LOG_PREFIX . ' Retry scheduled', [
'attempts' => $this->attempts(),
]);
$this->release(30);
} else {
$this->fail($exception);
}
}
}
private function validateReport(AutomatedReport $automatedReport, LoggerInterface $logger): bool
{
if ($automatedReport->getType() !== AutomatedReportsService::TYPE_ASK_JIMINNY) {
$logger->warning(self::LOG_PREFIX . ' Skipped, not an ask_jiminny report', [
'automatedReportUuid' => $this->reportUuid,
'type' => $automatedReport->getType(),
]);
return false;
}
if (! $automatedReport->getStatus()) {
$logger->info(self::LOG_PREFIX . ' Skipped, report is not active', [
'automatedReportUuid' => $this->reportUuid,
]);
return false;
}
if ($automatedReport->getTeam()->getStatus() !== Team::STATUS_ACTIVE) {
$logger->info(self::LOG_PREFIX . ' Skipped, team is inactive', [
'automatedReportUuid' => $this->reportUuid,
]);
return false;
}
return true;
}
private function failReport(int $reason): void
{
$this->reportResult?->update([
'status' => AutomatedReportResult::STATUS_FAILED,
'reason' => $reason,
]);
}
}
Sync Changes
Hide This Notification
Code changed:
Hide
2
1
Previous Highlighted Error
Next Highlighted Error
<?php
declare(strict_types=1);
namespace Jiminny\Services\Kiosk\AutomatedReports;
use Jiminny\Component\ActivitySearch\FilterDefinition\ActivityActualDate;
use Jiminny\Component\ActivitySearch\FilterDefinition\ActivityUpdatedDate;
use Jiminny\Component\ActivitySearch\FilterDefinition\DealInsights\ClosingPeriodFilter;
use Jiminny\Component\ActivitySearch\Service\ActivitySearch;
use Jiminny\Models\Activity\Search;
use Jiminny\Models\User;
use Jiminny\Repositories\ElasticActivityRepository;
use Jiminny\VO\Repository\OnDemandActivitySearch\Criteria;
use Psr\Log\LoggerInterface;
class AskJiminnyReportActivityService
{
private const int DEFAULT_TOP_ACTIVITIES_COUNT = 100;
private const array DATE_FILTER_KEYS = [
ActivityActualDate::PARAM_START_DATE,
ActivityActualDate::PARAM_END_DATE,
ActivityUpdatedDate::PARAM_UPDATED_FROM,
ActivityUpdatedDate::PARAM_UPDATED_TO,
ClosingPeriodFilter::KEY_START_DATE,
ClosingPeriodFilter::KEY_END_DATE,
];
public function __construct(
private readonly ActivitySearch $activitySearch,
private readonly ElasticActivityRepository $elasticRepository,
private readonly LoggerInterface $logger,
) {
}
/**
* Fetch activity IDs for a saved search, passing its filters as-is to Criteria.
* Date filters stored on the saved search are excluded; if no other filters exist,
* no date constraint is applied — matching the behaviour of getContextForAskAnythingByFilter.
*
* @return string[] Activity IDs
*/
public function getActivityIdsForSavedSearch(
Search $savedSearch,
User $user,
): array {
$requestParams = $this->buildRequestParamsFromSearch($savedSearch, $user);
$criteria = Criteria::createFromRequest(
array_merge($requestParams, ['limit' => self::DEFAULT_TOP_ACTIVITIES_COUNT, 'page' => 1]),
$user->getTimezone()
);
$filterSet = $this->activitySearch->getOnDemandPageFilterSet($criteria, $user);
$activityIds = $this->elasticRepository->onDemandSearchIdsOnly($user, $criteria, $filterSet);
$this->logger->info('[AskJiminnyReport] Fetched activity IDs for saved search', [
'saved_search_id' => $savedSearch->getId(),
'user_id' => $user->getId(),
'activity_count' => count($activityIds),
]);
return $activityIds;
}
private function buildRequestParamsFromSearch(Search $savedSearch, User $user): array
{
$params = [];
$arrayFilterKeys = $this->activitySearch->getArrayFilterKeys($user);
foreach ($savedSearch->getFilters() as $filter) {
$key = $filter->getFilterProperty();
$value = $filter->getFilterValue();
if (in_array($key, self::DATE_FILTER_KEYS, true)) {
continue;
}
if (isset($params[$key])) {
$params[$key][] = $value;
} elseif (in_array($key, $arrayFilterKeys, true)) {
$params[$key] = [$value];
} else {
$params[$key] = $value;
}
}
return $params;
}
}
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
[{"role":"AXButton","text" [{"role":"AXButton","text":"Project: faVsco.js, menu","depth":5,"help_text":"~/jiminny/app","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"#11894 on JY-18909-automated-reports-ask-jiminny, menu","depth":5,"help_text":"Pull request #11894 exists for current branch JY-18909-automated-reports-ask-jiminny, but local branch is out of sync with remote","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Start Listening for PHP Debug Connections","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"RequestGenerateAskJiminnyReportJobTest","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Run 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Debug 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"More Actions","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"JetBrains AI","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Search Everywhere","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"IDE and Project Settings","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.088194445,"height":0.027777778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"3","depth":4,"role_description":"text"},{"role":"AXButton","text":"Previous Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Next Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Jobs\\AutomatedReports;\n\nuse Carbon\\Carbon;\nuse Illuminate\\Bus\\Queueable;\nuse Illuminate\\Contracts\\Queue\\ShouldBeUnique;\nuse Illuminate\\Contracts\\Queue\\ShouldQueue;\nuse Illuminate\\Queue\\InteractsWithQueue;\nuse Jiminny\\Component\\ProphetAi\\Exceptions\\ProphetException;\nuse Jiminny\\Component\\ProphetAi\\ProphetClient;\nuse Jiminny\\Component\\Queue\\Constants;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\AutomatedReportResult;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AskJiminnyReportActivityService;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Psr\\Log\\LoggerInterface;\nuse Throwable;\n\nclass RequestGenerateAskJiminnyReportJob implements ShouldQueue, ShouldBeUnique\n{\n use InteractsWithQueue;\n use Queueable;\n\n private const string LOG_PREFIX = '[AskJiminnyReport:Generate]';\n\n private const int MIN_ACTIVITIES_COUNT = 1;\n\n public int $tries = 2;\n\n private ?AutomatedReportResult $reportResult = null;\n\n public function __construct(private readonly string $reportUuid)\n {\n $this->onQueue(Constants::QUEUE_ANALYTICS);\n }\n\n public function uniqueId(): string\n {\n return $this->reportUuid;\n }\n\n public function handle(\n AutomatedReportsService $reportService,\n AskJiminnyReportActivityService $activityService,\n ProphetClient $prophetClient,\n LoggerInterface $logger,\n ): void {\n $logger->info(self::LOG_PREFIX . ' Started', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n try {\n $automatedReport = $reportService->getReport($this->reportUuid);\n\n if (! $this->validateReport($automatedReport, $logger)) {\n return;\n }\n\n $creator = $automatedReport->getCreator();\n if ($creator === null) {\n $logger->warning(self::LOG_PREFIX . ' Skipped, report creator not found', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n return;\n }\n\n $savedSearch = $automatedReport->getSavedSearch();\n if ($savedSearch === null) {\n $logger->warning(self::LOG_PREFIX . ' Skipped, saved search not found', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n return;\n }\n\n $prompt = $automatedReport->getAskAnythingPrompt();\n if ($prompt === null) {\n $logger->warning(self::LOG_PREFIX . ' Skipped, ask anything prompt not found', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n return;\n }\n\n $this->reportResult = $reportService->createReportResult(\n automatedReport: $automatedReport,\n data: [\n 'status' => AutomatedReportResult::STATUS_DEFAULT,\n 'media_type' => AutomatedReportsService::MEDIA_TYPE_PDF,\n ]\n );\n\n $activityIds = $activityService->getActivityIdsForSavedSearch(\n savedSearch: $savedSearch,\n user: $creator,\n );\n\n $logger->info(self::LOG_PREFIX . ' Fetched activity IDs', [\n 'automatedReportUuid' => $this->reportUuid,\n 'activityCount' => count($activityIds),\n ]);\n\n if (count($activityIds) < self::MIN_ACTIVITIES_COUNT) {\n $this->failReport(AutomatedReportResult::REASON_NOT_ENOUGH_ACTIVITIES);\n\n $logger->info(self::LOG_PREFIX . ' Not enough activities, skipped', [\n 'automatedReportUuid' => $this->reportUuid,\n 'activityCount' => count($activityIds),\n ]);\n\n return;\n }\n\n $payload = $reportService->getAskJiminnyGenerateReportPayload(\n automatedReport: $automatedReport,\n reportResult: $this->reportResult,\n activityIds: $activityIds,\n );\n\n $this->reportResult->update([\n 'name' => $reportService->getReportFileName($this->reportResult),\n 'payload' => $payload,\n 'status' => AutomatedReportResult::STATUS_REQUESTED,\n 'requested_at' => Carbon::now()->toDateTimeString(),\n ]);\n\n $logger->info(self::LOG_PREFIX . ' Request sent', [\n 'automatedReportUuid' => $this->reportUuid,\n 'reportUuid' => $this->reportResult->getUuid(),\n 'payload' => $payload,\n ]);\n\n $response = $prophetClient->sendRequest(\n endpoint: ProphetClient::ASK_JIMINNY_REPORT,\n requestArray: $payload,\n );\n\n $logger->info(self::LOG_PREFIX . ' Response received', [\n 'response' => $response->getContent(),\n ]);\n } catch (Throwable $exception) {\n $reason = $exception instanceof ProphetException\n ? AutomatedReportResult::REASON_PROPHET_API_ERROR\n : AutomatedReportResult::REASON_DEFAULT;\n\n $this->failReport($reason);\n\n $logger->error(self::LOG_PREFIX . ' Error', [\n 'automatedReportUuid' => $this->reportUuid,\n 'reportUuid' => $this->reportResult?->getUuid(),\n 'code' => $exception->getCode(),\n 'message' => $exception->getMessage(),\n ]);\n\n if ($this->attempts() < $this->tries) {\n $logger->info(self::LOG_PREFIX . ' Retry scheduled', [\n 'attempts' => $this->attempts(),\n ]);\n\n $this->release(30);\n } else {\n $this->fail($exception);\n }\n }\n }\n\n private function validateReport(AutomatedReport $automatedReport, LoggerInterface $logger): bool\n {\n if ($automatedReport->getType() !== AutomatedReportsService::TYPE_ASK_JIMINNY) {\n $logger->warning(self::LOG_PREFIX . ' Skipped, not an ask_jiminny report', [\n 'automatedReportUuid' => $this->reportUuid,\n 'type' => $automatedReport->getType(),\n ]);\n\n return false;\n }\n\n if (! $automatedReport->getStatus()) {\n $logger->info(self::LOG_PREFIX . ' Skipped, report is not active', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n return false;\n }\n\n if ($automatedReport->getTeam()->getStatus() !== Team::STATUS_ACTIVE) {\n $logger->info(self::LOG_PREFIX . ' Skipped, team is inactive', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n return false;\n }\n\n return true;\n }\n\n private function failReport(int $reason): void\n {\n $this->reportResult?->update([\n 'status' => AutomatedReportResult::STATUS_FAILED,\n 'reason' => $reason,\n ]);\n }\n}","depth":4,"value":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Jobs\\AutomatedReports;\n\nuse Carbon\\Carbon;\nuse Illuminate\\Bus\\Queueable;\nuse Illuminate\\Contracts\\Queue\\ShouldBeUnique;\nuse Illuminate\\Contracts\\Queue\\ShouldQueue;\nuse Illuminate\\Queue\\InteractsWithQueue;\nuse Jiminny\\Component\\ProphetAi\\Exceptions\\ProphetException;\nuse Jiminny\\Component\\ProphetAi\\ProphetClient;\nuse Jiminny\\Component\\Queue\\Constants;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\AutomatedReportResult;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AskJiminnyReportActivityService;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Psr\\Log\\LoggerInterface;\nuse Throwable;\n\nclass RequestGenerateAskJiminnyReportJob implements ShouldQueue, ShouldBeUnique\n{\n use InteractsWithQueue;\n use Queueable;\n\n private const string LOG_PREFIX = '[AskJiminnyReport:Generate]';\n\n private const int MIN_ACTIVITIES_COUNT = 1;\n\n public int $tries = 2;\n\n private ?AutomatedReportResult $reportResult = null;\n\n public function __construct(private readonly string $reportUuid)\n {\n $this->onQueue(Constants::QUEUE_ANALYTICS);\n }\n\n public function uniqueId(): string\n {\n return $this->reportUuid;\n }\n\n public function handle(\n AutomatedReportsService $reportService,\n AskJiminnyReportActivityService $activityService,\n ProphetClient $prophetClient,\n LoggerInterface $logger,\n ): void {\n $logger->info(self::LOG_PREFIX . ' Started', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n try {\n $automatedReport = $reportService->getReport($this->reportUuid);\n\n if (! $this->validateReport($automatedReport, $logger)) {\n return;\n }\n\n $creator = $automatedReport->getCreator();\n if ($creator === null) {\n $logger->warning(self::LOG_PREFIX . ' Skipped, report creator not found', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n return;\n }\n\n $savedSearch = $automatedReport->getSavedSearch();\n if ($savedSearch === null) {\n $logger->warning(self::LOG_PREFIX . ' Skipped, saved search not found', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n return;\n }\n\n $prompt = $automatedReport->getAskAnythingPrompt();\n if ($prompt === null) {\n $logger->warning(self::LOG_PREFIX . ' Skipped, ask anything prompt not found', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n return;\n }\n\n $this->reportResult = $reportService->createReportResult(\n automatedReport: $automatedReport,\n data: [\n 'status' => AutomatedReportResult::STATUS_DEFAULT,\n 'media_type' => AutomatedReportsService::MEDIA_TYPE_PDF,\n ]\n );\n\n $activityIds = $activityService->getActivityIdsForSavedSearch(\n savedSearch: $savedSearch,\n user: $creator,\n );\n\n $logger->info(self::LOG_PREFIX . ' Fetched activity IDs', [\n 'automatedReportUuid' => $this->reportUuid,\n 'activityCount' => count($activityIds),\n ]);\n\n if (count($activityIds) < self::MIN_ACTIVITIES_COUNT) {\n $this->failReport(AutomatedReportResult::REASON_NOT_ENOUGH_ACTIVITIES);\n\n $logger->info(self::LOG_PREFIX . ' Not enough activities, skipped', [\n 'automatedReportUuid' => $this->reportUuid,\n 'activityCount' => count($activityIds),\n ]);\n\n return;\n }\n\n $payload = $reportService->getAskJiminnyGenerateReportPayload(\n automatedReport: $automatedReport,\n reportResult: $this->reportResult,\n activityIds: $activityIds,\n );\n\n $this->reportResult->update([\n 'name' => $reportService->getReportFileName($this->reportResult),\n 'payload' => $payload,\n 'status' => AutomatedReportResult::STATUS_REQUESTED,\n 'requested_at' => Carbon::now()->toDateTimeString(),\n ]);\n\n $logger->info(self::LOG_PREFIX . ' Request sent', [\n 'automatedReportUuid' => $this->reportUuid,\n 'reportUuid' => $this->reportResult->getUuid(),\n 'payload' => $payload,\n ]);\n\n $response = $prophetClient->sendRequest(\n endpoint: ProphetClient::ASK_JIMINNY_REPORT,\n requestArray: $payload,\n );\n\n $logger->info(self::LOG_PREFIX . ' Response received', [\n 'response' => $response->getContent(),\n ]);\n } catch (Throwable $exception) {\n $reason = $exception instanceof ProphetException\n ? AutomatedReportResult::REASON_PROPHET_API_ERROR\n : AutomatedReportResult::REASON_DEFAULT;\n\n $this->failReport($reason);\n\n $logger->error(self::LOG_PREFIX . ' Error', [\n 'automatedReportUuid' => $this->reportUuid,\n 'reportUuid' => $this->reportResult?->getUuid(),\n 'code' => $exception->getCode(),\n 'message' => $exception->getMessage(),\n ]);\n\n if ($this->attempts() < $this->tries) {\n $logger->info(self::LOG_PREFIX . ' Retry scheduled', [\n 'attempts' => $this->attempts(),\n ]);\n\n $this->release(30);\n } else {\n $this->fail($exception);\n }\n }\n }\n\n private function validateReport(AutomatedReport $automatedReport, LoggerInterface $logger): bool\n {\n if ($automatedReport->getType() !== AutomatedReportsService::TYPE_ASK_JIMINNY) {\n $logger->warning(self::LOG_PREFIX . ' Skipped, not an ask_jiminny report', [\n 'automatedReportUuid' => $this->reportUuid,\n 'type' => $automatedReport->getType(),\n ]);\n\n return false;\n }\n\n if (! $automatedReport->getStatus()) {\n $logger->info(self::LOG_PREFIX . ' Skipped, report is not active', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n return false;\n }\n\n if ($automatedReport->getTeam()->getStatus() !== Team::STATUS_ACTIVE) {\n $logger->info(self::LOG_PREFIX . ' Skipped, team is inactive', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n return false;\n }\n\n return true;\n }\n\n private function failReport(int $reason): void\n {\n $this->reportResult?->update([\n 'status' => AutomatedReportResult::STATUS_FAILED,\n 'reason' => $reason,\n ]);\n }\n}","role_description":"text entry area","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.088194445,"height":0.027777778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"2","depth":4,"role_description":"text"},{"role":"AXStaticText","text":"1","depth":4,"role_description":"text"},{"role":"AXButton","text":"Previous Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Next Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Services\\Kiosk\\AutomatedReports;\n\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\ActivityActualDate;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\ActivityUpdatedDate;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\DealInsights\\ClosingPeriodFilter;\nuse Jiminny\\Component\\ActivitySearch\\Service\\ActivitySearch;\nuse Jiminny\\Models\\Activity\\Search;\nuse Jiminny\\Models\\User;\nuse Jiminny\\Repositories\\ElasticActivityRepository;\nuse Jiminny\\VO\\Repository\\OnDemandActivitySearch\\Criteria;\nuse Psr\\Log\\LoggerInterface;\n\nclass AskJiminnyReportActivityService\n{\n private const int DEFAULT_TOP_ACTIVITIES_COUNT = 100;\n\n private const array DATE_FILTER_KEYS = [\n ActivityActualDate::PARAM_START_DATE,\n ActivityActualDate::PARAM_END_DATE,\n ActivityUpdatedDate::PARAM_UPDATED_FROM,\n ActivityUpdatedDate::PARAM_UPDATED_TO,\n ClosingPeriodFilter::KEY_START_DATE,\n ClosingPeriodFilter::KEY_END_DATE,\n ];\n\n public function __construct(\n private readonly ActivitySearch $activitySearch,\n private readonly ElasticActivityRepository $elasticRepository,\n private readonly LoggerInterface $logger,\n ) {\n }\n\n /**\n * Fetch activity IDs for a saved search, passing its filters as-is to Criteria.\n * Date filters stored on the saved search are excluded; if no other filters exist,\n * no date constraint is applied — matching the behaviour of getContextForAskAnythingByFilter.\n *\n * @return string[] Activity IDs\n */\n public function getActivityIdsForSavedSearch(\n Search $savedSearch,\n User $user,\n ): array {\n $requestParams = $this->buildRequestParamsFromSearch($savedSearch, $user);\n\n $criteria = Criteria::createFromRequest(\n array_merge($requestParams, ['limit' => self::DEFAULT_TOP_ACTIVITIES_COUNT, 'page' => 1]),\n $user->getTimezone()\n );\n\n $filterSet = $this->activitySearch->getOnDemandPageFilterSet($criteria, $user);\n\n $activityIds = $this->elasticRepository->onDemandSearchIdsOnly($user, $criteria, $filterSet);\n\n $this->logger->info('[AskJiminnyReport] Fetched activity IDs for saved search', [\n 'saved_search_id' => $savedSearch->getId(),\n 'user_id' => $user->getId(),\n 'activity_count' => count($activityIds),\n ]);\n\n return $activityIds;\n }\n\n private function buildRequestParamsFromSearch(Search $savedSearch, User $user): array\n {\n $params = [];\n $arrayFilterKeys = $this->activitySearch->getArrayFilterKeys($user);\n\n foreach ($savedSearch->getFilters() as $filter) {\n $key = $filter->getFilterProperty();\n $value = $filter->getFilterValue();\n\n if (in_array($key, self::DATE_FILTER_KEYS, true)) {\n continue;\n }\n\n if (isset($params[$key])) {\n $params[$key][] = $value;\n } elseif (in_array($key, $arrayFilterKeys, true)) {\n $params[$key] = [$value];\n } else {\n $params[$key] = $value;\n }\n }\n\n return $params;\n }\n}","depth":4,"value":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Services\\Kiosk\\AutomatedReports;\n\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\ActivityActualDate;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\ActivityUpdatedDate;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\DealInsights\\ClosingPeriodFilter;\nuse Jiminny\\Component\\ActivitySearch\\Service\\ActivitySearch;\nuse Jiminny\\Models\\Activity\\Search;\nuse Jiminny\\Models\\User;\nuse Jiminny\\Repositories\\ElasticActivityRepository;\nuse Jiminny\\VO\\Repository\\OnDemandActivitySearch\\Criteria;\nuse Psr\\Log\\LoggerInterface;\n\nclass AskJiminnyReportActivityService\n{\n private const int DEFAULT_TOP_ACTIVITIES_COUNT = 100;\n\n private const array DATE_FILTER_KEYS = [\n ActivityActualDate::PARAM_START_DATE,\n ActivityActualDate::PARAM_END_DATE,\n ActivityUpdatedDate::PARAM_UPDATED_FROM,\n ActivityUpdatedDate::PARAM_UPDATED_TO,\n ClosingPeriodFilter::KEY_START_DATE,\n ClosingPeriodFilter::KEY_END_DATE,\n ];\n\n public function __construct(\n private readonly ActivitySearch $activitySearch,\n private readonly ElasticActivityRepository $elasticRepository,\n private readonly LoggerInterface $logger,\n ) {\n }\n\n /**\n * Fetch activity IDs for a saved search, passing its filters as-is to Criteria.\n * Date filters stored on the saved search are excluded; if no other filters exist,\n * no date constraint is applied — matching the behaviour of getContextForAskAnythingByFilter.\n *\n * @return string[] Activity IDs\n */\n public function getActivityIdsForSavedSearch(\n Search $savedSearch,\n User $user,\n ): array {\n $requestParams = $this->buildRequestParamsFromSearch($savedSearch, $user);\n\n $criteria = Criteria::createFromRequest(\n array_merge($requestParams, ['limit' => self::DEFAULT_TOP_ACTIVITIES_COUNT, 'page' => 1]),\n $user->getTimezone()\n );\n\n $filterSet = $this->activitySearch->getOnDemandPageFilterSet($criteria, $user);\n\n $activityIds = $this->elasticRepository->onDemandSearchIdsOnly($user, $criteria, $filterSet);\n\n $this->logger->info('[AskJiminnyReport] Fetched activity IDs for saved search', [\n 'saved_search_id' => $savedSearch->getId(),\n 'user_id' => $user->getId(),\n 'activity_count' => count($activityIds),\n ]);\n\n return $activityIds;\n }\n\n private function buildRequestParamsFromSearch(Search $savedSearch, User $user): array\n {\n $params = [];\n $arrayFilterKeys = $this->activitySearch->getArrayFilterKeys($user);\n\n foreach ($savedSearch->getFilters() as $filter) {\n $key = $filter->getFilterProperty();\n $value = $filter->getFilterValue();\n\n if (in_array($key, self::DATE_FILTER_KEYS, true)) {\n continue;\n }\n\n if (isset($params[$key])) {\n $params[$key][] = $value;\n } elseif (in_array($key, $arrayFilterKeys, true)) {\n $params[$key] = [$value];\n } else {\n $params[$key] = $value;\n }\n }\n\n return $params;\n }\n}","role_description":"text entry area","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Project","depth":3,"role_description":"text"},{"role":"AXButton","text":"Project","depth":3,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"New File or Directory…","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Expand Selected","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Collapse All","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Options","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false}]...
|
-1920847021272450725
|
-5390502312724452628
|
idle
|
accessibility
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
3
Previous Highlighted Error
Next Highlighted Error
<?php
declare(strict_types=1);
namespace Jiminny\Jobs\AutomatedReports;
use Carbon\Carbon;
use Illuminate\Bus\Queueable;
use Illuminate\Contracts\Queue\ShouldBeUnique;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Queue\InteractsWithQueue;
use Jiminny\Component\ProphetAi\Exceptions\ProphetException;
use Jiminny\Component\ProphetAi\ProphetClient;
use Jiminny\Component\Queue\Constants;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\AutomatedReportResult;
use Jiminny\Models\Team;
use Jiminny\Services\Kiosk\AutomatedReports\AskJiminnyReportActivityService;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Psr\Log\LoggerInterface;
use Throwable;
class RequestGenerateAskJiminnyReportJob implements ShouldQueue, ShouldBeUnique
{
use InteractsWithQueue;
use Queueable;
private const string LOG_PREFIX = '[AskJiminnyReport:Generate]';
private const int MIN_ACTIVITIES_COUNT = 1;
public int $tries = 2;
private ?AutomatedReportResult $reportResult = null;
public function __construct(private readonly string $reportUuid)
{
$this->onQueue(Constants::QUEUE_ANALYTICS);
}
public function uniqueId(): string
{
return $this->reportUuid;
}
public function handle(
AutomatedReportsService $reportService,
AskJiminnyReportActivityService $activityService,
ProphetClient $prophetClient,
LoggerInterface $logger,
): void {
$logger->info(self::LOG_PREFIX . ' Started', [
'automatedReportUuid' => $this->reportUuid,
]);
try {
$automatedReport = $reportService->getReport($this->reportUuid);
if (! $this->validateReport($automatedReport, $logger)) {
return;
}
$creator = $automatedReport->getCreator();
if ($creator === null) {
$logger->warning(self::LOG_PREFIX . ' Skipped, report creator not found', [
'automatedReportUuid' => $this->reportUuid,
]);
return;
}
$savedSearch = $automatedReport->getSavedSearch();
if ($savedSearch === null) {
$logger->warning(self::LOG_PREFIX . ' Skipped, saved search not found', [
'automatedReportUuid' => $this->reportUuid,
]);
return;
}
$prompt = $automatedReport->getAskAnythingPrompt();
if ($prompt === null) {
$logger->warning(self::LOG_PREFIX . ' Skipped, ask anything prompt not found', [
'automatedReportUuid' => $this->reportUuid,
]);
return;
}
$this->reportResult = $reportService->createReportResult(
automatedReport: $automatedReport,
data: [
'status' => AutomatedReportResult::STATUS_DEFAULT,
'media_type' => AutomatedReportsService::MEDIA_TYPE_PDF,
]
);
$activityIds = $activityService->getActivityIdsForSavedSearch(
savedSearch: $savedSearch,
user: $creator,
);
$logger->info(self::LOG_PREFIX . ' Fetched activity IDs', [
'automatedReportUuid' => $this->reportUuid,
'activityCount' => count($activityIds),
]);
if (count($activityIds) < self::MIN_ACTIVITIES_COUNT) {
$this->failReport(AutomatedReportResult::REASON_NOT_ENOUGH_ACTIVITIES);
$logger->info(self::LOG_PREFIX . ' Not enough activities, skipped', [
'automatedReportUuid' => $this->reportUuid,
'activityCount' => count($activityIds),
]);
return;
}
$payload = $reportService->getAskJiminnyGenerateReportPayload(
automatedReport: $automatedReport,
reportResult: $this->reportResult,
activityIds: $activityIds,
);
$this->reportResult->update([
'name' => $reportService->getReportFileName($this->reportResult),
'payload' => $payload,
'status' => AutomatedReportResult::STATUS_REQUESTED,
'requested_at' => Carbon::now()->toDateTimeString(),
]);
$logger->info(self::LOG_PREFIX . ' Request sent', [
'automatedReportUuid' => $this->reportUuid,
'reportUuid' => $this->reportResult->getUuid(),
'payload' => $payload,
]);
$response = $prophetClient->sendRequest(
endpoint: ProphetClient::ASK_JIMINNY_REPORT,
requestArray: $payload,
);
$logger->info(self::LOG_PREFIX . ' Response received', [
'response' => $response->getContent(),
]);
} catch (Throwable $exception) {
$reason = $exception instanceof ProphetException
? AutomatedReportResult::REASON_PROPHET_API_ERROR
: AutomatedReportResult::REASON_DEFAULT;
$this->failReport($reason);
$logger->error(self::LOG_PREFIX . ' Error', [
'automatedReportUuid' => $this->reportUuid,
'reportUuid' => $this->reportResult?->getUuid(),
'code' => $exception->getCode(),
'message' => $exception->getMessage(),
]);
if ($this->attempts() < $this->tries) {
$logger->info(self::LOG_PREFIX . ' Retry scheduled', [
'attempts' => $this->attempts(),
]);
$this->release(30);
} else {
$this->fail($exception);
}
}
}
private function validateReport(AutomatedReport $automatedReport, LoggerInterface $logger): bool
{
if ($automatedReport->getType() !== AutomatedReportsService::TYPE_ASK_JIMINNY) {
$logger->warning(self::LOG_PREFIX . ' Skipped, not an ask_jiminny report', [
'automatedReportUuid' => $this->reportUuid,
'type' => $automatedReport->getType(),
]);
return false;
}
if (! $automatedReport->getStatus()) {
$logger->info(self::LOG_PREFIX . ' Skipped, report is not active', [
'automatedReportUuid' => $this->reportUuid,
]);
return false;
}
if ($automatedReport->getTeam()->getStatus() !== Team::STATUS_ACTIVE) {
$logger->info(self::LOG_PREFIX . ' Skipped, team is inactive', [
'automatedReportUuid' => $this->reportUuid,
]);
return false;
}
return true;
}
private function failReport(int $reason): void
{
$this->reportResult?->update([
'status' => AutomatedReportResult::STATUS_FAILED,
'reason' => $reason,
]);
}
}
Sync Changes
Hide This Notification
Code changed:
Hide
2
1
Previous Highlighted Error
Next Highlighted Error
<?php
declare(strict_types=1);
namespace Jiminny\Services\Kiosk\AutomatedReports;
use Jiminny\Component\ActivitySearch\FilterDefinition\ActivityActualDate;
use Jiminny\Component\ActivitySearch\FilterDefinition\ActivityUpdatedDate;
use Jiminny\Component\ActivitySearch\FilterDefinition\DealInsights\ClosingPeriodFilter;
use Jiminny\Component\ActivitySearch\Service\ActivitySearch;
use Jiminny\Models\Activity\Search;
use Jiminny\Models\User;
use Jiminny\Repositories\ElasticActivityRepository;
use Jiminny\VO\Repository\OnDemandActivitySearch\Criteria;
use Psr\Log\LoggerInterface;
class AskJiminnyReportActivityService
{
private const int DEFAULT_TOP_ACTIVITIES_COUNT = 100;
private const array DATE_FILTER_KEYS = [
ActivityActualDate::PARAM_START_DATE,
ActivityActualDate::PARAM_END_DATE,
ActivityUpdatedDate::PARAM_UPDATED_FROM,
ActivityUpdatedDate::PARAM_UPDATED_TO,
ClosingPeriodFilter::KEY_START_DATE,
ClosingPeriodFilter::KEY_END_DATE,
];
public function __construct(
private readonly ActivitySearch $activitySearch,
private readonly ElasticActivityRepository $elasticRepository,
private readonly LoggerInterface $logger,
) {
}
/**
* Fetch activity IDs for a saved search, passing its filters as-is to Criteria.
* Date filters stored on the saved search are excluded; if no other filters exist,
* no date constraint is applied — matching the behaviour of getContextForAskAnythingByFilter.
*
* @return string[] Activity IDs
*/
public function getActivityIdsForSavedSearch(
Search $savedSearch,
User $user,
): array {
$requestParams = $this->buildRequestParamsFromSearch($savedSearch, $user);
$criteria = Criteria::createFromRequest(
array_merge($requestParams, ['limit' => self::DEFAULT_TOP_ACTIVITIES_COUNT, 'page' => 1]),
$user->getTimezone()
);
$filterSet = $this->activitySearch->getOnDemandPageFilterSet($criteria, $user);
$activityIds = $this->elasticRepository->onDemandSearchIdsOnly($user, $criteria, $filterSet);
$this->logger->info('[AskJiminnyReport] Fetched activity IDs for saved search', [
'saved_search_id' => $savedSearch->getId(),
'user_id' => $user->getId(),
'activity_count' => count($activityIds),
]);
return $activityIds;
}
private function buildRequestParamsFromSearch(Search $savedSearch, User $user): array
{
$params = [];
$arrayFilterKeys = $this->activitySearch->getArrayFilterKeys($user);
foreach ($savedSearch->getFilters() as $filter) {
$key = $filter->getFilterProperty();
$value = $filter->getFilterValue();
if (in_array($key, self::DATE_FILTER_KEYS, true)) {
continue;
}
if (isset($params[$key])) {
$params[$key][] = $value;
} elseif (in_array($key, $arrayFilterKeys, true)) {
$params[$key] = [$value];
} else {
$params[$key] = $value;
}
}
return $params;
}
}
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
NULL
|
|
10782
|
215
|
0
|
2026-04-14T08:58:51.595540+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776157131595_m2.jpg...
|
PhpStorm
|
faVsco.js – AskJiminnyReportActivityService.php
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
3
Previous Highlighted Error
Next Highlighted Error
<?php
declare(strict_types=1);
namespace Jiminny\Jobs\AutomatedReports;
use Carbon\Carbon;
use Illuminate\Bus\Queueable;
use Illuminate\Contracts\Queue\ShouldBeUnique;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Queue\InteractsWithQueue;
use Jiminny\Component\ProphetAi\Exceptions\ProphetException;
use Jiminny\Component\ProphetAi\ProphetClient;
use Jiminny\Component\Queue\Constants;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\AutomatedReportResult;
use Jiminny\Models\Team;
use Jiminny\Services\Kiosk\AutomatedReports\AskJiminnyReportActivityService;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Psr\Log\LoggerInterface;
use Throwable;
class RequestGenerateAskJiminnyReportJob implements ShouldQueue, ShouldBeUnique
{
use InteractsWithQueue;
use Queueable;
private const string LOG_PREFIX = '[AskJiminnyReport:Generate]';
private const int MIN_ACTIVITIES_COUNT = 1;
public int $tries = 2;
private ?AutomatedReportResult $reportResult = null;
public function __construct(private readonly string $reportUuid)
{
$this->onQueue(Constants::QUEUE_ANALYTICS);
}
public function uniqueId(): string
{
return $this->reportUuid;
}
public function handle(
AutomatedReportsService $reportService,
AskJiminnyReportActivityService $activityService,
ProphetClient $prophetClient,
LoggerInterface $logger,
): void {
$logger->info(self::LOG_PREFIX . ' Started', [
'automatedReportUuid' => $this->reportUuid,
]);
try {
$automatedReport = $reportService->getReport($this->reportUuid);
if (! $this->validateReport($automatedReport, $logger)) {
return;
}
$creator = $automatedReport->getCreator();
if ($creator === null) {
$logger->warning(self::LOG_PREFIX . ' Skipped, report creator not found', [
'automatedReportUuid' => $this->reportUuid,
]);
return;
}
$savedSearch = $automatedReport->getSavedSearch();
if ($savedSearch === null) {
$logger->warning(self::LOG_PREFIX . ' Skipped, saved search not found', [
'automatedReportUuid' => $this->reportUuid,
]);
return;
}
$prompt = $automatedReport->getAskAnythingPrompt();
if ($prompt === null) {
$logger->warning(self::LOG_PREFIX . ' Skipped, ask anything prompt not found', [
'automatedReportUuid' => $this->reportUuid,
]);
return;
}
$this->reportResult = $reportService->createReportResult(
automatedReport: $automatedReport,
data: [
'status' => AutomatedReportResult::STATUS_DEFAULT,
'media_type' => AutomatedReportsService::MEDIA_TYPE_PDF,
]
);
$activityIds = $activityService->getActivityIdsForSavedSearch(
savedSearch: $savedSearch,
user: $creator,
);
$logger->info(self::LOG_PREFIX . ' Fetched activity IDs', [
'automatedReportUuid' => $this->reportUuid,
'activityCount' => count($activityIds),
]);
if (count($activityIds) < self::MIN_ACTIVITIES_COUNT) {
$this->failReport(AutomatedReportResult::REASON_NOT_ENOUGH_ACTIVITIES);
$logger->info(self::LOG_PREFIX . ' Not enough activities, skipped', [
'automatedReportUuid' => $this->reportUuid,
'activityCount' => count($activityIds),
]);
return;
}
$payload = $reportService->getAskJiminnyGenerateReportPayload(
automatedReport: $automatedReport,
reportResult: $this->reportResult,
activityIds: $activityIds,
);
$this->reportResult->update([
'name' => $reportService->getReportFileName($this->reportResult),
'payload' => $payload,
'status' => AutomatedReportResult::STATUS_REQUESTED,
'requested_at' => Carbon::now()->toDateTimeString(),
]);
$logger->info(self::LOG_PREFIX . ' Request sent', [
'automatedReportUuid' => $this->reportUuid,
'reportUuid' => $this->reportResult->getUuid(),
'payload' => $payload,
]);
$response = $prophetClient->sendRequest(
endpoint: ProphetClient::ASK_JIMINNY_REPORT,
requestArray: $payload,
);
$logger->info(self::LOG_PREFIX . ' Response received', [
'response' => $response->getContent(),
]);
} catch (Throwable $exception) {
$reason = $exception instanceof ProphetException
? AutomatedReportResult::REASON_PROPHET_API_ERROR
: AutomatedReportResult::REASON_DEFAULT;
$this->failReport($reason);
$logger->error(self::LOG_PREFIX . ' Error', [
'automatedReportUuid' => $this->reportUuid,
'reportUuid' => $this->reportResult?->getUuid(),
'code' => $exception->getCode(),
'message' => $exception->getMessage(),
]);
if ($this->attempts() < $this->tries) {
$logger->info(self::LOG_PREFIX . ' Retry scheduled', [
'attempts' => $this->attempts(),
]);
$this->release(30);
} else {
$this->fail($exception);
}
}
}
private function validateReport(AutomatedReport $automatedReport, LoggerInterface $logger): bool
{
if ($automatedReport->getType() !== AutomatedReportsService::TYPE_ASK_JIMINNY) {
$logger->warning(self::LOG_PREFIX . ' Skipped, not an ask_jiminny report', [
'automatedReportUuid' => $this->reportUuid,
'type' => $automatedReport->getType(),
]);
return false;
}
if (! $automatedReport->getStatus()) {
$logger->info(self::LOG_PREFIX . ' Skipped, report is not active', [
'automatedReportUuid' => $this->reportUuid,
]);
return false;
}
if ($automatedReport->getTeam()->getStatus() !== Team::STATUS_ACTIVE) {
$logger->info(self::LOG_PREFIX . ' Skipped, team is inactive', [
'automatedReportUuid' => $this->reportUuid,
]);
return false;
}
return true;
}
private function failReport(int $reason): void
{
$this->reportResult?->update([
'status' => AutomatedReportResult::STATUS_FAILED,
'reason' => $reason,
]);
}
}
Sync Changes
Hide This Notification
Code changed:
Hide
2
1
Previous Highlighted Error
Next Highlighted Error
<?php
declare(strict_types=1);
namespace Jiminny\Services\Kiosk\AutomatedReports;
use Jiminny\Component\ActivitySearch\FilterDefinition\ActivityActualDate;
use Jiminny\Component\ActivitySearch\FilterDefinition\ActivityUpdatedDate;
use Jiminny\Component\ActivitySearch\FilterDefinition\DealInsights\ClosingPeriodFilter;
use Jiminny\Component\ActivitySearch\Service\ActivitySearch;
use Jiminny\Models\Activity\Search;
use Jiminny\Models\User;
use Jiminny\Repositories\ElasticActivityRepository;
use Jiminny\VO\Repository\OnDemandActivitySearch\Criteria;
use Psr\Log\LoggerInterface;
class AskJiminnyReportActivityService
{
private const int DEFAULT_TOP_ACTIVITIES_COUNT = 100;
private const array DATE_FILTER_KEYS = [
ActivityActualDate::PARAM_START_DATE,
ActivityActualDate::PARAM_END_DATE,
ActivityUpdatedDate::PARAM_UPDATED_FROM,
ActivityUpdatedDate::PARAM_UPDATED_TO,
ClosingPeriodFilter::KEY_START_DATE,
ClosingPeriodFilter::KEY_END_DATE,
];
public function __construct(
private readonly ActivitySearch $activitySearch,
private readonly ElasticActivityRepository $elasticRepository,
private readonly LoggerInterface $logger,
) {
}
/**
* Fetch activity IDs for a saved search, passing its filters as-is to Criteria.
* Date filters stored on the saved search are excluded; if no other filters exist,
* no date constraint is applied — matching the behaviour of getContextForAskAnythingByFilter.
*
* @return string[] Activity IDs
*/
public function getActivityIdsForSavedSearch(
Search $savedSearch,
User $user,
): array {
$requestParams = $this->buildRequestParamsFromSearch($savedSearch, $user);
$criteria = Criteria::createFromRequest(
array_merge($requestParams, ['limit' => self::DEFAULT_TOP_ACTIVITIES_COUNT, 'page' => 1]),
$user->getTimezone()
);
$filterSet = $this->activitySearch->getOnDemandPageFilterSet($criteria, $user);
$activityIds = $this->elasticRepository->onDemandSearchIdsOnly($user, $criteria, $filterSet);
$this->logger->info('[AskJiminnyReport] Fetched activity IDs for saved search', [
'saved_search_id' => $savedSearch->getId(),
'user_id' => $user->getId(),
'activity_count' => count($activityIds),
]);
return $activityIds;
}
private function buildRequestParamsFromSearch(Search $savedSearch, User $user): array
{
$params = [];
$arrayFilterKeys = $this->activitySearch->getArrayFilterKeys($user);
foreach ($savedSearch->getFilters() as $filter) {
$key = $filter->getFilterProperty();
$value = $filter->getFilterValue();
if (in_array($key, self::DATE_FILTER_KEYS, true)) {
continue;
}
if (isset($params[$key])) {
$params[$key][] = $value;
} elseif (in_array($key, $arrayFilterKeys, true)) {
$params[$key] = [$value];
} else {
$params[$key] = $value;
}
}
return $params;
}
}
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
[{"role":"AXButton","text" [{"role":"AXButton","text":"Project: faVsco.js, menu","depth":5,"bounds":{"left":0.03046875,"top":0.017361112,"width":0.0453125,"height":0.022222223},"help_text":"~/jiminny/app","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"#11894 on JY-18909-automated-reports-ask-jiminny, menu","depth":5,"bounds":{"left":0.07578125,"top":0.017361112,"width":0.14960937,"height":0.022222223},"help_text":"Pull request #11894 exists for current branch JY-18909-automated-reports-ask-jiminny, but local branch is out of sync with remote","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Start Listening for PHP Debug Connections","depth":5,"bounds":{"left":0.76171875,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"RequestGenerateAskJiminnyReportJobTest","depth":6,"bounds":{"left":0.7796875,"top":0.017361112,"width":0.12109375,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Run 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"bounds":{"left":0.9007813,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Debug 'RequestGenerateAskJiminnyReportJobTest'","depth":6,"bounds":{"left":0.9140625,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"More Actions","depth":6,"bounds":{"left":0.9273437,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"JetBrains AI","depth":5,"bounds":{"left":0.96015626,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Search Everywhere","depth":5,"bounds":{"left":0.9734375,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"IDE and Project Settings","depth":5,"bounds":{"left":0.9867188,"top":0.017361112,"width":0.013281226,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.049609374,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"3","depth":4,"bounds":{"left":0.33632812,"top":0.23819445,"width":0.009375,"height":0.013194445},"role_description":"text"},{"role":"AXButton","text":"Previous Highlighted Error","depth":4,"bounds":{"left":0.34765625,"top":0.23680556,"width":0.00859375,"height":0.015972223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Next Highlighted Error","depth":4,"bounds":{"left":0.35625,"top":0.23680556,"width":0.008203125,"height":0.015972223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Jobs\\AutomatedReports;\n\nuse Carbon\\Carbon;\nuse Illuminate\\Bus\\Queueable;\nuse Illuminate\\Contracts\\Queue\\ShouldBeUnique;\nuse Illuminate\\Contracts\\Queue\\ShouldQueue;\nuse Illuminate\\Queue\\InteractsWithQueue;\nuse Jiminny\\Component\\ProphetAi\\Exceptions\\ProphetException;\nuse Jiminny\\Component\\ProphetAi\\ProphetClient;\nuse Jiminny\\Component\\Queue\\Constants;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\AutomatedReportResult;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AskJiminnyReportActivityService;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Psr\\Log\\LoggerInterface;\nuse Throwable;\n\nclass RequestGenerateAskJiminnyReportJob implements ShouldQueue, ShouldBeUnique\n{\n use InteractsWithQueue;\n use Queueable;\n\n private const string LOG_PREFIX = '[AskJiminnyReport:Generate]';\n\n private const int MIN_ACTIVITIES_COUNT = 1;\n\n public int $tries = 2;\n\n private ?AutomatedReportResult $reportResult = null;\n\n public function __construct(private readonly string $reportUuid)\n {\n $this->onQueue(Constants::QUEUE_ANALYTICS);\n }\n\n public function uniqueId(): string\n {\n return $this->reportUuid;\n }\n\n public function handle(\n AutomatedReportsService $reportService,\n AskJiminnyReportActivityService $activityService,\n ProphetClient $prophetClient,\n LoggerInterface $logger,\n ): void {\n $logger->info(self::LOG_PREFIX . ' Started', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n try {\n $automatedReport = $reportService->getReport($this->reportUuid);\n\n if (! $this->validateReport($automatedReport, $logger)) {\n return;\n }\n\n $creator = $automatedReport->getCreator();\n if ($creator === null) {\n $logger->warning(self::LOG_PREFIX . ' Skipped, report creator not found', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n return;\n }\n\n $savedSearch = $automatedReport->getSavedSearch();\n if ($savedSearch === null) {\n $logger->warning(self::LOG_PREFIX . ' Skipped, saved search not found', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n return;\n }\n\n $prompt = $automatedReport->getAskAnythingPrompt();\n if ($prompt === null) {\n $logger->warning(self::LOG_PREFIX . ' Skipped, ask anything prompt not found', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n return;\n }\n\n $this->reportResult = $reportService->createReportResult(\n automatedReport: $automatedReport,\n data: [\n 'status' => AutomatedReportResult::STATUS_DEFAULT,\n 'media_type' => AutomatedReportsService::MEDIA_TYPE_PDF,\n ]\n );\n\n $activityIds = $activityService->getActivityIdsForSavedSearch(\n savedSearch: $savedSearch,\n user: $creator,\n );\n\n $logger->info(self::LOG_PREFIX . ' Fetched activity IDs', [\n 'automatedReportUuid' => $this->reportUuid,\n 'activityCount' => count($activityIds),\n ]);\n\n if (count($activityIds) < self::MIN_ACTIVITIES_COUNT) {\n $this->failReport(AutomatedReportResult::REASON_NOT_ENOUGH_ACTIVITIES);\n\n $logger->info(self::LOG_PREFIX . ' Not enough activities, skipped', [\n 'automatedReportUuid' => $this->reportUuid,\n 'activityCount' => count($activityIds),\n ]);\n\n return;\n }\n\n $payload = $reportService->getAskJiminnyGenerateReportPayload(\n automatedReport: $automatedReport,\n reportResult: $this->reportResult,\n activityIds: $activityIds,\n );\n\n $this->reportResult->update([\n 'name' => $reportService->getReportFileName($this->reportResult),\n 'payload' => $payload,\n 'status' => AutomatedReportResult::STATUS_REQUESTED,\n 'requested_at' => Carbon::now()->toDateTimeString(),\n ]);\n\n $logger->info(self::LOG_PREFIX . ' Request sent', [\n 'automatedReportUuid' => $this->reportUuid,\n 'reportUuid' => $this->reportResult->getUuid(),\n 'payload' => $payload,\n ]);\n\n $response = $prophetClient->sendRequest(\n endpoint: ProphetClient::ASK_JIMINNY_REPORT,\n requestArray: $payload,\n );\n\n $logger->info(self::LOG_PREFIX . ' Response received', [\n 'response' => $response->getContent(),\n ]);\n } catch (Throwable $exception) {\n $reason = $exception instanceof ProphetException\n ? AutomatedReportResult::REASON_PROPHET_API_ERROR\n : AutomatedReportResult::REASON_DEFAULT;\n\n $this->failReport($reason);\n\n $logger->error(self::LOG_PREFIX . ' Error', [\n 'automatedReportUuid' => $this->reportUuid,\n 'reportUuid' => $this->reportResult?->getUuid(),\n 'code' => $exception->getCode(),\n 'message' => $exception->getMessage(),\n ]);\n\n if ($this->attempts() < $this->tries) {\n $logger->info(self::LOG_PREFIX . ' Retry scheduled', [\n 'attempts' => $this->attempts(),\n ]);\n\n $this->release(30);\n } else {\n $this->fail($exception);\n }\n }\n }\n\n private function validateReport(AutomatedReport $automatedReport, LoggerInterface $logger): bool\n {\n if ($automatedReport->getType() !== AutomatedReportsService::TYPE_ASK_JIMINNY) {\n $logger->warning(self::LOG_PREFIX . ' Skipped, not an ask_jiminny report', [\n 'automatedReportUuid' => $this->reportUuid,\n 'type' => $automatedReport->getType(),\n ]);\n\n return false;\n }\n\n if (! $automatedReport->getStatus()) {\n $logger->info(self::LOG_PREFIX . ' Skipped, report is not active', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n return false;\n }\n\n if ($automatedReport->getTeam()->getStatus() !== Team::STATUS_ACTIVE) {\n $logger->info(self::LOG_PREFIX . ' Skipped, team is inactive', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n return false;\n }\n\n return true;\n }\n\n private function failReport(int $reason): void\n {\n $this->reportResult?->update([\n 'status' => AutomatedReportResult::STATUS_FAILED,\n 'reason' => $reason,\n ]);\n }\n}","depth":4,"value":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Jobs\\AutomatedReports;\n\nuse Carbon\\Carbon;\nuse Illuminate\\Bus\\Queueable;\nuse Illuminate\\Contracts\\Queue\\ShouldBeUnique;\nuse Illuminate\\Contracts\\Queue\\ShouldQueue;\nuse Illuminate\\Queue\\InteractsWithQueue;\nuse Jiminny\\Component\\ProphetAi\\Exceptions\\ProphetException;\nuse Jiminny\\Component\\ProphetAi\\ProphetClient;\nuse Jiminny\\Component\\Queue\\Constants;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\AutomatedReportResult;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AskJiminnyReportActivityService;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Psr\\Log\\LoggerInterface;\nuse Throwable;\n\nclass RequestGenerateAskJiminnyReportJob implements ShouldQueue, ShouldBeUnique\n{\n use InteractsWithQueue;\n use Queueable;\n\n private const string LOG_PREFIX = '[AskJiminnyReport:Generate]';\n\n private const int MIN_ACTIVITIES_COUNT = 1;\n\n public int $tries = 2;\n\n private ?AutomatedReportResult $reportResult = null;\n\n public function __construct(private readonly string $reportUuid)\n {\n $this->onQueue(Constants::QUEUE_ANALYTICS);\n }\n\n public function uniqueId(): string\n {\n return $this->reportUuid;\n }\n\n public function handle(\n AutomatedReportsService $reportService,\n AskJiminnyReportActivityService $activityService,\n ProphetClient $prophetClient,\n LoggerInterface $logger,\n ): void {\n $logger->info(self::LOG_PREFIX . ' Started', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n try {\n $automatedReport = $reportService->getReport($this->reportUuid);\n\n if (! $this->validateReport($automatedReport, $logger)) {\n return;\n }\n\n $creator = $automatedReport->getCreator();\n if ($creator === null) {\n $logger->warning(self::LOG_PREFIX . ' Skipped, report creator not found', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n return;\n }\n\n $savedSearch = $automatedReport->getSavedSearch();\n if ($savedSearch === null) {\n $logger->warning(self::LOG_PREFIX . ' Skipped, saved search not found', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n return;\n }\n\n $prompt = $automatedReport->getAskAnythingPrompt();\n if ($prompt === null) {\n $logger->warning(self::LOG_PREFIX . ' Skipped, ask anything prompt not found', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n return;\n }\n\n $this->reportResult = $reportService->createReportResult(\n automatedReport: $automatedReport,\n data: [\n 'status' => AutomatedReportResult::STATUS_DEFAULT,\n 'media_type' => AutomatedReportsService::MEDIA_TYPE_PDF,\n ]\n );\n\n $activityIds = $activityService->getActivityIdsForSavedSearch(\n savedSearch: $savedSearch,\n user: $creator,\n );\n\n $logger->info(self::LOG_PREFIX . ' Fetched activity IDs', [\n 'automatedReportUuid' => $this->reportUuid,\n 'activityCount' => count($activityIds),\n ]);\n\n if (count($activityIds) < self::MIN_ACTIVITIES_COUNT) {\n $this->failReport(AutomatedReportResult::REASON_NOT_ENOUGH_ACTIVITIES);\n\n $logger->info(self::LOG_PREFIX . ' Not enough activities, skipped', [\n 'automatedReportUuid' => $this->reportUuid,\n 'activityCount' => count($activityIds),\n ]);\n\n return;\n }\n\n $payload = $reportService->getAskJiminnyGenerateReportPayload(\n automatedReport: $automatedReport,\n reportResult: $this->reportResult,\n activityIds: $activityIds,\n );\n\n $this->reportResult->update([\n 'name' => $reportService->getReportFileName($this->reportResult),\n 'payload' => $payload,\n 'status' => AutomatedReportResult::STATUS_REQUESTED,\n 'requested_at' => Carbon::now()->toDateTimeString(),\n ]);\n\n $logger->info(self::LOG_PREFIX . ' Request sent', [\n 'automatedReportUuid' => $this->reportUuid,\n 'reportUuid' => $this->reportResult->getUuid(),\n 'payload' => $payload,\n ]);\n\n $response = $prophetClient->sendRequest(\n endpoint: ProphetClient::ASK_JIMINNY_REPORT,\n requestArray: $payload,\n );\n\n $logger->info(self::LOG_PREFIX . ' Response received', [\n 'response' => $response->getContent(),\n ]);\n } catch (Throwable $exception) {\n $reason = $exception instanceof ProphetException\n ? AutomatedReportResult::REASON_PROPHET_API_ERROR\n : AutomatedReportResult::REASON_DEFAULT;\n\n $this->failReport($reason);\n\n $logger->error(self::LOG_PREFIX . ' Error', [\n 'automatedReportUuid' => $this->reportUuid,\n 'reportUuid' => $this->reportResult?->getUuid(),\n 'code' => $exception->getCode(),\n 'message' => $exception->getMessage(),\n ]);\n\n if ($this->attempts() < $this->tries) {\n $logger->info(self::LOG_PREFIX . ' Retry scheduled', [\n 'attempts' => $this->attempts(),\n ]);\n\n $this->release(30);\n } else {\n $this->fail($exception);\n }\n }\n }\n\n private function validateReport(AutomatedReport $automatedReport, LoggerInterface $logger): bool\n {\n if ($automatedReport->getType() !== AutomatedReportsService::TYPE_ASK_JIMINNY) {\n $logger->warning(self::LOG_PREFIX . ' Skipped, not an ask_jiminny report', [\n 'automatedReportUuid' => $this->reportUuid,\n 'type' => $automatedReport->getType(),\n ]);\n\n return false;\n }\n\n if (! $automatedReport->getStatus()) {\n $logger->info(self::LOG_PREFIX . ' Skipped, report is not active', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n return false;\n }\n\n if ($automatedReport->getTeam()->getStatus() !== Team::STATUS_ACTIVE) {\n $logger->info(self::LOG_PREFIX . ' Skipped, team is inactive', [\n 'automatedReportUuid' => $this->reportUuid,\n ]);\n\n return false;\n }\n\n return true;\n }\n\n private function failReport(int $reason): void\n {\n $this->reportResult?->update([\n 'status' => AutomatedReportResult::STATUS_FAILED,\n 'reason' => $reason,\n ]);\n }\n}","role_description":"text entry area","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.049609374,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"2","depth":4,"bounds":{"left":0.6699219,"top":0.0875,"width":0.009375,"height":0.013194445},"role_description":"text"},{"role":"AXStaticText","text":"1","depth":4,"bounds":{"left":0.6816406,"top":0.0875,"width":0.00859375,"height":0.013194445},"role_description":"text"},{"role":"AXButton","text":"Previous Highlighted Error","depth":4,"bounds":{"left":0.6921875,"top":0.08611111,"width":0.00859375,"height":0.015972223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Next Highlighted Error","depth":4,"bounds":{"left":0.7007812,"top":0.08611111,"width":0.008203125,"height":0.015972223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Services\\Kiosk\\AutomatedReports;\n\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\ActivityActualDate;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\ActivityUpdatedDate;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\DealInsights\\ClosingPeriodFilter;\nuse Jiminny\\Component\\ActivitySearch\\Service\\ActivitySearch;\nuse Jiminny\\Models\\Activity\\Search;\nuse Jiminny\\Models\\User;\nuse Jiminny\\Repositories\\ElasticActivityRepository;\nuse Jiminny\\VO\\Repository\\OnDemandActivitySearch\\Criteria;\nuse Psr\\Log\\LoggerInterface;\n\nclass AskJiminnyReportActivityService\n{\n private const int DEFAULT_TOP_ACTIVITIES_COUNT = 100;\n\n private const array DATE_FILTER_KEYS = [\n ActivityActualDate::PARAM_START_DATE,\n ActivityActualDate::PARAM_END_DATE,\n ActivityUpdatedDate::PARAM_UPDATED_FROM,\n ActivityUpdatedDate::PARAM_UPDATED_TO,\n ClosingPeriodFilter::KEY_START_DATE,\n ClosingPeriodFilter::KEY_END_DATE,\n ];\n\n public function __construct(\n private readonly ActivitySearch $activitySearch,\n private readonly ElasticActivityRepository $elasticRepository,\n private readonly LoggerInterface $logger,\n ) {\n }\n\n /**\n * Fetch activity IDs for a saved search, passing its filters as-is to Criteria.\n * Date filters stored on the saved search are excluded; if no other filters exist,\n * no date constraint is applied — matching the behaviour of getContextForAskAnythingByFilter.\n *\n * @return string[] Activity IDs\n */\n public function getActivityIdsForSavedSearch(\n Search $savedSearch,\n User $user,\n ): array {\n $requestParams = $this->buildRequestParamsFromSearch($savedSearch, $user);\n\n $criteria = Criteria::createFromRequest(\n array_merge($requestParams, ['limit' => self::DEFAULT_TOP_ACTIVITIES_COUNT, 'page' => 1]),\n $user->getTimezone()\n );\n\n $filterSet = $this->activitySearch->getOnDemandPageFilterSet($criteria, $user);\n\n $activityIds = $this->elasticRepository->onDemandSearchIdsOnly($user, $criteria, $filterSet);\n\n $this->logger->info('[AskJiminnyReport] Fetched activity IDs for saved search', [\n 'saved_search_id' => $savedSearch->getId(),\n 'user_id' => $user->getId(),\n 'activity_count' => count($activityIds),\n ]);\n\n return $activityIds;\n }\n\n private function buildRequestParamsFromSearch(Search $savedSearch, User $user): array\n {\n $params = [];\n $arrayFilterKeys = $this->activitySearch->getArrayFilterKeys($user);\n\n foreach ($savedSearch->getFilters() as $filter) {\n $key = $filter->getFilterProperty();\n $value = $filter->getFilterValue();\n\n if (in_array($key, self::DATE_FILTER_KEYS, true)) {\n continue;\n }\n\n if (isset($params[$key])) {\n $params[$key][] = $value;\n } elseif (in_array($key, $arrayFilterKeys, true)) {\n $params[$key] = [$value];\n } else {\n $params[$key] = $value;\n }\n }\n\n return $params;\n }\n}","depth":4,"value":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Services\\Kiosk\\AutomatedReports;\n\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\ActivityActualDate;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\ActivityUpdatedDate;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\DealInsights\\ClosingPeriodFilter;\nuse Jiminny\\Component\\ActivitySearch\\Service\\ActivitySearch;\nuse Jiminny\\Models\\Activity\\Search;\nuse Jiminny\\Models\\User;\nuse Jiminny\\Repositories\\ElasticActivityRepository;\nuse Jiminny\\VO\\Repository\\OnDemandActivitySearch\\Criteria;\nuse Psr\\Log\\LoggerInterface;\n\nclass AskJiminnyReportActivityService\n{\n private const int DEFAULT_TOP_ACTIVITIES_COUNT = 100;\n\n private const array DATE_FILTER_KEYS = [\n ActivityActualDate::PARAM_START_DATE,\n ActivityActualDate::PARAM_END_DATE,\n ActivityUpdatedDate::PARAM_UPDATED_FROM,\n ActivityUpdatedDate::PARAM_UPDATED_TO,\n ClosingPeriodFilter::KEY_START_DATE,\n ClosingPeriodFilter::KEY_END_DATE,\n ];\n\n public function __construct(\n private readonly ActivitySearch $activitySearch,\n private readonly ElasticActivityRepository $elasticRepository,\n private readonly LoggerInterface $logger,\n ) {\n }\n\n /**\n * Fetch activity IDs for a saved search, passing its filters as-is to Criteria.\n * Date filters stored on the saved search are excluded; if no other filters exist,\n * no date constraint is applied — matching the behaviour of getContextForAskAnythingByFilter.\n *\n * @return string[] Activity IDs\n */\n public function getActivityIdsForSavedSearch(\n Search $savedSearch,\n User $user,\n ): array {\n $requestParams = $this->buildRequestParamsFromSearch($savedSearch, $user);\n\n $criteria = Criteria::createFromRequest(\n array_merge($requestParams, ['limit' => self::DEFAULT_TOP_ACTIVITIES_COUNT, 'page' => 1]),\n $user->getTimezone()\n );\n\n $filterSet = $this->activitySearch->getOnDemandPageFilterSet($criteria, $user);\n\n $activityIds = $this->elasticRepository->onDemandSearchIdsOnly($user, $criteria, $filterSet);\n\n $this->logger->info('[AskJiminnyReport] Fetched activity IDs for saved search', [\n 'saved_search_id' => $savedSearch->getId(),\n 'user_id' => $user->getId(),\n 'activity_count' => count($activityIds),\n ]);\n\n return $activityIds;\n }\n\n private function buildRequestParamsFromSearch(Search $savedSearch, User $user): array\n {\n $params = [];\n $arrayFilterKeys = $this->activitySearch->getArrayFilterKeys($user);\n\n foreach ($savedSearch->getFilters() as $filter) {\n $key = $filter->getFilterProperty();\n $value = $filter->getFilterValue();\n\n if (in_array($key, self::DATE_FILTER_KEYS, true)) {\n continue;\n }\n\n if (isset($params[$key])) {\n $params[$key][] = $value;\n } elseif (in_array($key, $arrayFilterKeys, true)) {\n $params[$key] = [$value];\n } else {\n $params[$key] = $value;\n }\n }\n\n return $params;\n }\n}","role_description":"text entry area","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Project","depth":3,"role_description":"text"},{"role":"AXButton","text":"Project","depth":3,"bounds":{"left":0.0140625,"top":0.041666668,"width":0.028515626,"height":0.021527778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"New File or Directory…","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Expand Selected","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Collapse All","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Options","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false}]...
|
-1920847021272450725
|
-5390502312724452628
|
idle
|
accessibility
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
RequestGenerateAskJiminnyReportJobTest
Run 'RequestGenerateAskJiminnyReportJobTest'
Debug 'RequestGenerateAskJiminnyReportJobTest'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
3
Previous Highlighted Error
Next Highlighted Error
<?php
declare(strict_types=1);
namespace Jiminny\Jobs\AutomatedReports;
use Carbon\Carbon;
use Illuminate\Bus\Queueable;
use Illuminate\Contracts\Queue\ShouldBeUnique;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Queue\InteractsWithQueue;
use Jiminny\Component\ProphetAi\Exceptions\ProphetException;
use Jiminny\Component\ProphetAi\ProphetClient;
use Jiminny\Component\Queue\Constants;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\AutomatedReportResult;
use Jiminny\Models\Team;
use Jiminny\Services\Kiosk\AutomatedReports\AskJiminnyReportActivityService;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Psr\Log\LoggerInterface;
use Throwable;
class RequestGenerateAskJiminnyReportJob implements ShouldQueue, ShouldBeUnique
{
use InteractsWithQueue;
use Queueable;
private const string LOG_PREFIX = '[AskJiminnyReport:Generate]';
private const int MIN_ACTIVITIES_COUNT = 1;
public int $tries = 2;
private ?AutomatedReportResult $reportResult = null;
public function __construct(private readonly string $reportUuid)
{
$this->onQueue(Constants::QUEUE_ANALYTICS);
}
public function uniqueId(): string
{
return $this->reportUuid;
}
public function handle(
AutomatedReportsService $reportService,
AskJiminnyReportActivityService $activityService,
ProphetClient $prophetClient,
LoggerInterface $logger,
): void {
$logger->info(self::LOG_PREFIX . ' Started', [
'automatedReportUuid' => $this->reportUuid,
]);
try {
$automatedReport = $reportService->getReport($this->reportUuid);
if (! $this->validateReport($automatedReport, $logger)) {
return;
}
$creator = $automatedReport->getCreator();
if ($creator === null) {
$logger->warning(self::LOG_PREFIX . ' Skipped, report creator not found', [
'automatedReportUuid' => $this->reportUuid,
]);
return;
}
$savedSearch = $automatedReport->getSavedSearch();
if ($savedSearch === null) {
$logger->warning(self::LOG_PREFIX . ' Skipped, saved search not found', [
'automatedReportUuid' => $this->reportUuid,
]);
return;
}
$prompt = $automatedReport->getAskAnythingPrompt();
if ($prompt === null) {
$logger->warning(self::LOG_PREFIX . ' Skipped, ask anything prompt not found', [
'automatedReportUuid' => $this->reportUuid,
]);
return;
}
$this->reportResult = $reportService->createReportResult(
automatedReport: $automatedReport,
data: [
'status' => AutomatedReportResult::STATUS_DEFAULT,
'media_type' => AutomatedReportsService::MEDIA_TYPE_PDF,
]
);
$activityIds = $activityService->getActivityIdsForSavedSearch(
savedSearch: $savedSearch,
user: $creator,
);
$logger->info(self::LOG_PREFIX . ' Fetched activity IDs', [
'automatedReportUuid' => $this->reportUuid,
'activityCount' => count($activityIds),
]);
if (count($activityIds) < self::MIN_ACTIVITIES_COUNT) {
$this->failReport(AutomatedReportResult::REASON_NOT_ENOUGH_ACTIVITIES);
$logger->info(self::LOG_PREFIX . ' Not enough activities, skipped', [
'automatedReportUuid' => $this->reportUuid,
'activityCount' => count($activityIds),
]);
return;
}
$payload = $reportService->getAskJiminnyGenerateReportPayload(
automatedReport: $automatedReport,
reportResult: $this->reportResult,
activityIds: $activityIds,
);
$this->reportResult->update([
'name' => $reportService->getReportFileName($this->reportResult),
'payload' => $payload,
'status' => AutomatedReportResult::STATUS_REQUESTED,
'requested_at' => Carbon::now()->toDateTimeString(),
]);
$logger->info(self::LOG_PREFIX . ' Request sent', [
'automatedReportUuid' => $this->reportUuid,
'reportUuid' => $this->reportResult->getUuid(),
'payload' => $payload,
]);
$response = $prophetClient->sendRequest(
endpoint: ProphetClient::ASK_JIMINNY_REPORT,
requestArray: $payload,
);
$logger->info(self::LOG_PREFIX . ' Response received', [
'response' => $response->getContent(),
]);
} catch (Throwable $exception) {
$reason = $exception instanceof ProphetException
? AutomatedReportResult::REASON_PROPHET_API_ERROR
: AutomatedReportResult::REASON_DEFAULT;
$this->failReport($reason);
$logger->error(self::LOG_PREFIX . ' Error', [
'automatedReportUuid' => $this->reportUuid,
'reportUuid' => $this->reportResult?->getUuid(),
'code' => $exception->getCode(),
'message' => $exception->getMessage(),
]);
if ($this->attempts() < $this->tries) {
$logger->info(self::LOG_PREFIX . ' Retry scheduled', [
'attempts' => $this->attempts(),
]);
$this->release(30);
} else {
$this->fail($exception);
}
}
}
private function validateReport(AutomatedReport $automatedReport, LoggerInterface $logger): bool
{
if ($automatedReport->getType() !== AutomatedReportsService::TYPE_ASK_JIMINNY) {
$logger->warning(self::LOG_PREFIX . ' Skipped, not an ask_jiminny report', [
'automatedReportUuid' => $this->reportUuid,
'type' => $automatedReport->getType(),
]);
return false;
}
if (! $automatedReport->getStatus()) {
$logger->info(self::LOG_PREFIX . ' Skipped, report is not active', [
'automatedReportUuid' => $this->reportUuid,
]);
return false;
}
if ($automatedReport->getTeam()->getStatus() !== Team::STATUS_ACTIVE) {
$logger->info(self::LOG_PREFIX . ' Skipped, team is inactive', [
'automatedReportUuid' => $this->reportUuid,
]);
return false;
}
return true;
}
private function failReport(int $reason): void
{
$this->reportResult?->update([
'status' => AutomatedReportResult::STATUS_FAILED,
'reason' => $reason,
]);
}
}
Sync Changes
Hide This Notification
Code changed:
Hide
2
1
Previous Highlighted Error
Next Highlighted Error
<?php
declare(strict_types=1);
namespace Jiminny\Services\Kiosk\AutomatedReports;
use Jiminny\Component\ActivitySearch\FilterDefinition\ActivityActualDate;
use Jiminny\Component\ActivitySearch\FilterDefinition\ActivityUpdatedDate;
use Jiminny\Component\ActivitySearch\FilterDefinition\DealInsights\ClosingPeriodFilter;
use Jiminny\Component\ActivitySearch\Service\ActivitySearch;
use Jiminny\Models\Activity\Search;
use Jiminny\Models\User;
use Jiminny\Repositories\ElasticActivityRepository;
use Jiminny\VO\Repository\OnDemandActivitySearch\Criteria;
use Psr\Log\LoggerInterface;
class AskJiminnyReportActivityService
{
private const int DEFAULT_TOP_ACTIVITIES_COUNT = 100;
private const array DATE_FILTER_KEYS = [
ActivityActualDate::PARAM_START_DATE,
ActivityActualDate::PARAM_END_DATE,
ActivityUpdatedDate::PARAM_UPDATED_FROM,
ActivityUpdatedDate::PARAM_UPDATED_TO,
ClosingPeriodFilter::KEY_START_DATE,
ClosingPeriodFilter::KEY_END_DATE,
];
public function __construct(
private readonly ActivitySearch $activitySearch,
private readonly ElasticActivityRepository $elasticRepository,
private readonly LoggerInterface $logger,
) {
}
/**
* Fetch activity IDs for a saved search, passing its filters as-is to Criteria.
* Date filters stored on the saved search are excluded; if no other filters exist,
* no date constraint is applied — matching the behaviour of getContextForAskAnythingByFilter.
*
* @return string[] Activity IDs
*/
public function getActivityIdsForSavedSearch(
Search $savedSearch,
User $user,
): array {
$requestParams = $this->buildRequestParamsFromSearch($savedSearch, $user);
$criteria = Criteria::createFromRequest(
array_merge($requestParams, ['limit' => self::DEFAULT_TOP_ACTIVITIES_COUNT, 'page' => 1]),
$user->getTimezone()
);
$filterSet = $this->activitySearch->getOnDemandPageFilterSet($criteria, $user);
$activityIds = $this->elasticRepository->onDemandSearchIdsOnly($user, $criteria, $filterSet);
$this->logger->info('[AskJiminnyReport] Fetched activity IDs for saved search', [
'saved_search_id' => $savedSearch->getId(),
'user_id' => $user->getId(),
'activity_count' => count($activityIds),
]);
return $activityIds;
}
private function buildRequestParamsFromSearch(Search $savedSearch, User $user): array
{
$params = [];
$arrayFilterKeys = $this->activitySearch->getArrayFilterKeys($user);
foreach ($savedSearch->getFilters() as $filter) {
$key = $filter->getFilterProperty();
$value = $filter->getFilterValue();
if (in_array($key, self::DATE_FILTER_KEYS, true)) {
continue;
}
if (isset($params[$key])) {
$params[$key][] = $value;
} elseif (in_array($key, $arrayFilterKeys, true)) {
$params[$key] = [$value];
} else {
$params[$key] = $value;
}
}
return $params;
}
}
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide...
|
NULL
|
|
10907
|
NULL
|
0
|
2026-04-14T09:03:33.340257+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776157413340_m1.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
+SlackEDHomeDMSActivityFilesLater..•More+FileEditV +SlackEDHomeDMSActivityFilesLater..•More+FileEditViewGoHistoryWindowHelp> 0Jiminny ...# Starredplatform-inner-teamChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product_launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi…..• Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili...R. Adelina PetrovaO. Calea Dimitravo→Search Jiminny IncAneliya Angelova, Nikolay Yankov, Steliyan GeorgievMessagesAdd canvas+Phooa да тестоan АРусротораmone nunpomопределен когато тествамеNikolay Yankov 10:41 AMможеш ли да я рьннеш ти командатаLukas Kovalik 10:43 AMдаNikolay Yankov 10:45 AMпиши кат оя рьннешLukas Kovalik 10:52 AMзабавих се че ми се разбазикаха settings за средипуснах и мина и fail-наима result но e failedзначиREASON_NOT_ENOUGH_ACTIVITIESвиж дали има нещо в OD със този филтьрNikolay Yankov 11:01 AMДобреNikolay Yankov 11:39 AMя рьнни пак LukasLukas Kovalik 11:43 AMготовосьщотоCompetitive pitches беше втория нали такаMessage Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev+AaladlSupport Daily • in 2h 57 m100% C48Tue 14 Apr 12:03:33Fuune 4Today ~New...
|
NULL
|
-5529189722141514346
|
NULL
|
click
|
ocr
|
NULL
|
+SlackEDHomeDMSActivityFilesLater..•More+FileEditV +SlackEDHomeDMSActivityFilesLater..•More+FileEditViewGoHistoryWindowHelp> 0Jiminny ...# Starredplatform-inner-teamChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product_launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi…..• Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili...R. Adelina PetrovaO. Calea Dimitravo→Search Jiminny IncAneliya Angelova, Nikolay Yankov, Steliyan GeorgievMessagesAdd canvas+Phooa да тестоan АРусротораmone nunpomопределен когато тествамеNikolay Yankov 10:41 AMможеш ли да я рьннеш ти командатаLukas Kovalik 10:43 AMдаNikolay Yankov 10:45 AMпиши кат оя рьннешLukas Kovalik 10:52 AMзабавих се че ми се разбазикаха settings за средипуснах и мина и fail-наима result но e failedзначиREASON_NOT_ENOUGH_ACTIVITIESвиж дали има нещо в OD със този филтьрNikolay Yankov 11:01 AMДобреNikolay Yankov 11:39 AMя рьнни пак LukasLukas Kovalik 11:43 AMготовосьщотоCompetitive pitches беше втория нали такаMessage Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev+AaladlSupport Daily • in 2h 57 m100% C48Tue 14 Apr 12:03:33Fuune 4Today ~New...
|
10904
|
|
10908
|
NULL
|
0
|
2026-04-14T09:03:33.327245+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776157413327_m2.jpg...
|
PhpStorm
|
faVsco.js – AskJiminnyReportActivityService.php
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu...
|
[{"role":"AXButton","text" [{"role":"AXButton","text":"Project: faVsco.js, menu","depth":5,"bounds":{"left":0.03046875,"top":0.017361112,"width":0.0453125,"height":0.022222223},"help_text":"~/jiminny/app","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"#11894 on JY-18909-automated-reports-ask-jiminny, menu","depth":5,"bounds":{"left":0.07578125,"top":0.017361112,"width":0.14960937,"height":0.022222223},"help_text":"Pull request #11894 exists for current branch JY-18909-automated-reports-ask-jiminny, but local branch is out of sync with remote","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false}]...
|
-5081751640215339021
|
-4009658842534132447
|
click
|
hybrid
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
PhpStormFileFditViewNavigateCodelaraveRefactonRunToolsWindowHelpFV faVsco.s v#11894 on JY-18909-automated-reports-ask-jiminny k ~Project v(©) ReportController.php© JiminnyDebugCommand.phpC AutomatedReportsCommand.phpC) AutomatedReportsSendCommand.phpC) AddLayoutEntities.php(©) Team.php© DeviceRepository.php© AutomatedReportsRepository.php xAulomaleakeporisservice.onpc CrealenelaAcuiviyevent.ono© TrackProviderInstalledEvent.phpC CreateActivityLoggedEvent.phpC ElasticActivityRepository.p© EmailMessageRepository.p© GenericAiPromptRepositor© GroupRepository.php(C InboxEmailBatchRepositon)© UserPilotActivityListener.php© ActivityLogged.php© AutomatedReportsCallbackService.php© RequestGenerateAskJiminnyReportJob.phpC RequestGenerateReportJob.php(©) AutomatedReportResult.phpc) Automatedkeport.oneclass AucomaceareporcskepostcoryC InboxRepository.pnp© InvitationRepository.phpC) JobRepository.phpC) LanquageRepository.php© MomentRepository.phpNotificationRepository.phpC ParticipantRepository.php© ParticipantSpeechReposito© ParticipantStatsRepository© PlaybookCategoryRepositc© PlaybookRepository.phpC PlavlistActivityRepository.p(© PlaylistRepository.png(C PlaylistShareRepository.phC) QuestionRepository.php(C) RoleChangeEventRepositolC RoleRepository.php© SearchRepository.phpC SnapshotRepository.phpC) SocialAccountRepository.p© StageRepository.php© SubscriptionSetRepository.(C) TaskRepository.pho© TeamAiContextRepository.C TeamDomainsRepository.p(©) TeaminsightsRepository.phC) TeamRepository.phpC ThemeRepository.phpC TimezoneRepository.php© TopicRepository.php© TopicTriggerRepository.ph© TrackRepository.phpC) TranscriptionModelLocaleF© TranscriptionRepository.prC) TranscriptionSummarvRepC UserRepository.php© VocabularyRepository.pnp› Rulesv D Services>D Activity>D AReports>D AvatarM CalendarM ConferenceM Crm>MImport> MInternallv → Kioskv _ AutomatedReports(C) ActivityTypeService.(©) AskJiminnyReportAc(C) AutomatedReportse(C) AutomatedReportsS* areturn AutomatedRenortpubLic tunccion createlarray paata). Аuсопасеакероrиr. . .л* Find an automated report bu UUID* Oparam string Suuid* dreturn Automatedkeport/nullpubLic tuncclon tindbyuu1d(string puu1d): :Automatedкeрoгиre atomеероt.ee, оmерrcoupamizealoouna atmetTusagepublic function findByld0rUuid(string Sid0rUuid): ?AutomatedReportAcceotif (is_numeric($id0rUuid)) (return AutomatedReport::w1thlrashed(->f1nd((1nt) s1d0rUu1d);return AutomatedReport: :wit&Trashed()-›where( column: |'uuid', AutomatedReport:: to0ptimized(SidOrUvid))->firstO);* Retrieve all standard (non-Ask Jiminny) automated reports.* @param string $sortColumnThe column to sort by. Allowed values: 'created_by', "created_at'. Defaults to "created_at'.* aparam string $sortDirection The sort direction. Allowed values:'asc', 'desc'. Defaults to 'desc'.* dreturn collection<Automatedreport>12 usagespubLic tunction gecALLstandardkeportsstring ssortcolumn = "created_at",scring ssortbirection = 'desc': Collection (...l* Retrieve all Ask Jiminny reports created by the given user.* dparam UsersuserThe user whose reports to retrieve.* dparam string ssortcolumnThe column to sort by. Allowed values: 'created_by', "created_at'. Defaults to 'created_at'.* @param string $sortDirection The sort direction. Allowed values:"asc", desc". veraults to "desc".* drerurn couuectonsaurondredredor14 usagespublic function getAskJiminnyReportsByUserdUser Suser.string SsortColumn =created atWindsurf changelog 2.12.21: A new version is available. // View Changelog (today 10:33)Reiect1 eall\ Sa= custom.log= laravel.logs Sr iminny@localnosuic HS_local Liminny@localhost)e console (PROD]¿ console (EU]A console [STAGINGAskJiminnyReportActivityService.php xC RequestGenerateAskJiminnyReportJobTestclass ASkJiminnyReportActiviClosingPeriodFilter:public function __constrprivate readonly Actprivate readonly Elaprivate readonly Log) {...}* Fetch activity IDs fo* Date filters stored o* no dque conscrouns* dreturn stringl Actipublic function getActivSearch SsavedSearchUser suser,0: array {srequestParams = sthnenrera s urtueraAcceptmarcetsreqarray merge (Srecsuser->getTimez):btulterset = sthis-MacuVVOS =109Sthis->loqger->infod'saved search id'user id' => Sus'activity_countID:return sactivityidsprivate tuncuion bullakeJ v Accept File &+X Reject File 1 38&Support Daily • in 2h 57 m100% |45]Tue 14 Apr 12:03:33RequestGenerateAskJiminnyReportJobTestCascadeFixing ReportControlleAutomated Report MaAutomated Report !ip#L211 and add validation with logs insideGAutomatedRenortscommand. 0ho.5 209-710et me read the current state of the command tile firstkead Automateakeportscommana.ongIcan see the user's approach— processsing lekeport already exists trom my earlier work dut qetkeporcbyla iswhat's being used in processReports.Ineed to implement getReportByld properly with validation + logs, and addine reposttory metnoo. Leume also check the eutumtnare supportycoLlection impon stuatlon:Searched use luminate Suooort Colectionin apo/Console/Commands/Renorts/AutomatedRenortsCommand.oh...Now implement both changes - the repository method and the getReportByld method with proper validation:Error whlle ealting Aucomaceakepo rtscommand.onpRead AutomatecRenortscommand.onoThe file is now only 140 lines - the user removed the processSing leReport/warnlfNotApp Licab leForSchedu lemetnoas. Now limplementcom changes.• AutomatedReportsCommand.php+o -1Now add tindbyldoruuld to the repository:1 Aulomalecreoorsreroslorv.onoAlso tix the import order (Collection should be betore the models alphabetically):• AutomatedReportsCommand.php+1 -1• AutomatedReportsCommand.php+1 -1vone. oummary or changes.AUromareckedor skenos1rorv:: Tndbylouruu1o lautonarecrenorSkedos1t0rv.0no:4/—5492Numeric strine→ tindovinubNon-numenc → Uud ookuo via tooptimizedoBoth use withTrashed() so soft-deleted reports are findable manuallygetReportByld() (AutomatedReportsCommand.php: 135-194) — checks all conditions that getActiveReportsByFrequency enforces, logging a warning to the log channel and printing a warn() to the terminal for each violationbut sull rerurns the repor so processing continues.chockBehaviour on failINot Tounewarhina loe + terminal wam, rerurns empty collection sklos processine)Inactive statuswarnino loe + terminal warn, continueseam not activewarnino lloo + terminal warn, continuesExoiredwarning log + terminal warn, continuesFrequency wouldn't run todayinfo lod + terminal warn. continuesWC1l -2 files +51 >Ask anything (&+L)401 auesde Claude Sonnet 46Reject allAccept allwinasun leams51:1uir-oia 4 spaces...
|
10906
|
|
10909
|
216
|
0
|
2026-04-14T09:03:41.110267+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776157421110_m1.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
+SlackEDHomeDMSActivityFilesLater..•More+FileEditV +SlackEDHomeDMSActivityFilesLater..•More+FileEditViewGoHistoryWindowHelp> 0Jiminny ...# Starredplatform-inner-teamChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product_launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi…..• Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili...R. Adelina PetrovaO. Calea Dimitravo→Search Jiminny IncAneliya Angelova, Nikolay Yankov, Steliyan GeorgievMessagesAdd canvas+Phooa да тестоan АРусротораmone nunpomопределен когато тествамеNikolay Yankov 10:41 AMможеш ли да я рьннеш ти командатаLukas Kovalik 10:43 AMдаNikolay Yankov 10:45 AMпиши кат оя рьннешLukas Kovalik 10:52 AMзабавих се че ми се разбазикаха settings за средипуснах и мина и fail-наима result но e failedзначиREASON_NOT_ENOUGH_ACTIVITIESвиж дали има нещо в OD със този филтьрNikolay Yankov 11:01 AMДобреNikolay Yankov 11:39 AMя рьнни пак LukasLukas Kovalik 11:43 AMготовосьщотоCompetitive pitches беше втория нали такаMessage Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev+AaladlSupport Daily • in 2h 57 m100% C48Tue 14 Apr 12:03:40Fuune 4Today ~New...
|
NULL
|
8165261447115302344
|
NULL
|
click
|
ocr
|
NULL
|
+SlackEDHomeDMSActivityFilesLater..•More+FileEditV +SlackEDHomeDMSActivityFilesLater..•More+FileEditViewGoHistoryWindowHelp> 0Jiminny ...# Starredplatform-inner-teamChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product_launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi…..• Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili...R. Adelina PetrovaO. Calea Dimitravo→Search Jiminny IncAneliya Angelova, Nikolay Yankov, Steliyan GeorgievMessagesAdd canvas+Phooa да тестоan АРусротораmone nunpomопределен когато тествамеNikolay Yankov 10:41 AMможеш ли да я рьннеш ти командатаLukas Kovalik 10:43 AMдаNikolay Yankov 10:45 AMпиши кат оя рьннешLukas Kovalik 10:52 AMзабавих се че ми се разбазикаха settings за средипуснах и мина и fail-наима result но e failedзначиREASON_NOT_ENOUGH_ACTIVITIESвиж дали има нещо в OD със този филтьрNikolay Yankov 11:01 AMДобреNikolay Yankov 11:39 AMя рьнни пак LukasLukas Kovalik 11:43 AMготовосьщотоCompetitive pitches беше втория нали такаMessage Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev+AaladlSupport Daily • in 2h 57 m100% C48Tue 14 Apr 12:03:40Fuune 4Today ~New...
|
NULL
|
|
10910
|
217
|
0
|
2026-04-14T09:03:41.077023+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776157421077_m2.jpg...
|
PhpStorm
|
faVsco.js – AskJiminnyReportActivityService.php
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
PhpStormFileFditViewNavigateCodelaraveRefactonTool PhpStormFileFditViewNavigateCodelaraveRefactonToolsWindowHelpFV faVsco.s v#11894 on JY-18909-automated-reports-ask-jiminny k ~Project v© DeviceRepository.phpC ElasticActivityRepository.p© EmailMessageRepository.p© GenericAiPromptRepositor© GroupRepository.php(C InboxEmailBatchRepositon)C InboxRepository.pnp© InvitationRepository.phpC) JobRepository.phpC) LanquageRepository.php© MomentRepository.phpNotificationRepository.phpC ParticipantRepository.php© ParticipantSpeechReposito© ParticipantStatsRepository© PlaybookCategoryRepositc© PlaybookRepository.phpC PlavlistActivityRepository.p(© PlaylistRepository.png(C PlaylistShareRepository.phC) QuestionRepository.php(C) RoleChangeEventRepositolC RoleRepository.php© SearchRepository.phpC SnapshotRepository.phpC) SocialAccountRepository.pg stageRepository.php© SubscriptionSetRepository.(C) TaskRepository.pho© TeamAiContextRepository.©) TeamDomainsRepository.p(©) TeaminsightsRepository.phC) TeamRepository.phpC ThemeRepository.phpC TimezoneRepository.php© TopicRepository.php© TopicTriggerRepository.ph© TrackRepository.phpC) TranscriptionModelLocaleF© TranscriptionRepository.prC) TranscriptionSummarvRepC UserRepository.php© VocabularyRepository.pnp› Rulesv D Services> _ Activity>D AReports>D AvatarcalendarM ConferenceM Crm>MImport> MInternallv → Kioskv _ AutomatedReports(C) ActivityTypeService.(©) AskJiminnyReportAc(C) AutomatedReportse(C) AutomatedReportsS(©) ReportController.php© JiminnyDebugCommand.phpC AutomatedReportsCommand.phpC) AutomatedReportsSendCommand.phpC) AddLayoutEntities.php(©) Team.php© AutomatedReportsRepository.php xAulomaleakeporisservice.onp(c CrealenelaAcuiviyevent.ono© TrackProviderInstalledEvent.phpC CreateActivityLoggedEvent.php© UserPilotActivityListener.php© ActivityLogged.php© AutomatedReportsCallbackService.php© RequestGenerateAskJiminnyReportJob.phpC RequestGenerateReportJob.php(©) AutomatedReportResult.phpc) Automatedkeport.oneclass Aucomaceareporcskepostcory53* Oreturn AutomatedReportpubLic tunccion createlarray paata). Аuсопасеакероrиr. . .л* Find an automated report bu UUID* Oparam string Suuid* dreturn Automatedkeport/nullpubLic tuncclon tindbyuu1d(string puu1d): :Automatedкeрoгиre atomеероt.ee, оmерrcoupamizealoouna atmetTusagepublic function findByld0rUuid(string Sid0rUuid): ?AutomatedReportAcceotif (is_numeric($id0rUuid)) (return AutomateaReport: wathlrasned(->rzn antp szdoruuza)l;recurn Automacedkeport::Wichlrasnecu-›wherel column: "Ju1d, Automatedкeporu:. couptimized slauruula-tirstunCascade & l* Retrieve all standard (non-Ask Jiminny) automated reports.* @param string $sortColumnThe column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to "created_at'.* aparam string SsortDirection The sort direction. Allowed values:'asc', 'desc'. Defaults to 'desc'.* dreturn collection<Automatedreport>12 usagespubLic tunction gecALLstandardkeportsstring ssortcolumn = "created_at",scring ssortbirection = 'desc': Collection (...l* Retrieve all Ask Jiminny reports created by the given user.* dparam UsersuserThe user whose reports to retrieve.* dparam string ssortcolumnThe column to sort by. Allowed values: 'created_by', "created_at'. Defaults to 'created_at".* @param string $sortDirection The sort direction. Allowed values:"asc, "desc". veraults to "desc".* drerurn couuectonsaurondredredor14 usagespublic function getAskJiminnyReportsByUserdUser Suser.string SsortColumn =created atWindsurf changelog 2.12.21: A new version is available. // View Changelog (today 10:33)KenecuCommand*_51= custom.log= laravel.log4 SF [iiminny@localhostlc HS_local Jiminny@localhost)e console (PROD]¿ console (EU]A console [STAGINGAskJiminnyReportActivityService.php xC RequestGenerateAskJiminnyReportJobTestclass ASkJiminnyReportActiviClosingPeriodFilter:public function __constrprivate readonly Actprivate readonly Elaprivate readonly Log) {...}* Fetch activity IDs fo* Date filters stored o* no dque conscrouns* dreturn stringl Actipublic function getActivSearch SsavedSearchUser suser,D: arraysrequestParams = sthnenrera s urtueraAcceptmarcetsreqarray merge (Srecsuser->getTimez):btulterset = sthis-MacuVVOS =109Sthis->loqger->infod'saved search id'user id' => Sus'activity_countID:return sactivityidsprivate runcuion bulake1 eallJ v Accept File &+X Reject File 1 38&Support Daily • in 2h 57 m100% |45]Tue 14 Apr 12:03:40RequestGenerateAskJiminnyReportJobTestCascadeFixing ReportControlleAutomated Report Ma• Automated Report !ip#L211 and add validation with logs insideGAutomatedRenortscommand. 0ho.5 209-710et me read the current state of the command tile firstkead Automateakeportscommana.ongIcan see the user's approach— processsing lekeport already exists trom my earlier work dut qetkeporcbyla iswhat's being used in processReports.Ineed to implement getReportByld properly with validation + logs, and addine reposttory metnoo. Leume also check the eutumtnare supportycollection impon stuatlon:Searched use luminate Suooort Colectionin apo/Console/Commands/Renorts/AutomatedRenortsCommand.oh...Now implement both changes - the repository method and the getReportByld method with proper validation:Error whlle ealting Aucomaceakepo rtscommand.onpRead AutomatecRenortscommand.onoThe file is now only 140 lines - the user removed the processSing leReport/warnlfNotApp Licab leForSchedu Lemetnoas. Now limplementcom changes.• AutomatedReportsCommand.php+o -1Now add tindbyldoruuld to the repository:1 Aulomalecreoorsreroslorv.onoAlso tix the import order (Collection should be betore the models alphabetically):AutomatedReportsCommand.php+1 -1• AutomatedReportsCommand.php+1 -1vone. oummary or changes.AUromareckedor skenos1rorv:: Tndbylouruu1o lautonarecrenorSkedos1t0rv.0no:4/—5492Numeric strine→ tindovinubNon-numenc → Uud ookuo via tooptimizedoBoth use withTrashed() so soft-deleted reports are findable manuallygetReportByld() (AutomatedReportsCommand.php: 135-194) — checks all conditions that getActiveReportsByFrequency enforces, logging a warning to the log channel and printing a warn() to the terminal for each violationbut sull rerurns the repor so processing continues.chockBehaviour on failINot Tounewarhina loe + terminal warn, returns emoty collection skips processine)Inactive statuswarnino loe + terminal warn, continueseam not activewarnino lloo + terminal warn, continuesExoiredwarning log + terminal warn, continuesFrequency wouldn't run todayinfo lod + terminal warn. continuesWC1l -2 files +51 >Ask anything (&+L)401 auesde Claude Sonnet 46Reject allAccept allwinasur leams51:1uir-oia 4 spaces...
|
NULL
|
5012723601940443684
|
NULL
|
click
|
ocr
|
NULL
|
PhpStormFileFditViewNavigateCodelaraveRefactonTool PhpStormFileFditViewNavigateCodelaraveRefactonToolsWindowHelpFV faVsco.s v#11894 on JY-18909-automated-reports-ask-jiminny k ~Project v© DeviceRepository.phpC ElasticActivityRepository.p© EmailMessageRepository.p© GenericAiPromptRepositor© GroupRepository.php(C InboxEmailBatchRepositon)C InboxRepository.pnp© InvitationRepository.phpC) JobRepository.phpC) LanquageRepository.php© MomentRepository.phpNotificationRepository.phpC ParticipantRepository.php© ParticipantSpeechReposito© ParticipantStatsRepository© PlaybookCategoryRepositc© PlaybookRepository.phpC PlavlistActivityRepository.p(© PlaylistRepository.png(C PlaylistShareRepository.phC) QuestionRepository.php(C) RoleChangeEventRepositolC RoleRepository.php© SearchRepository.phpC SnapshotRepository.phpC) SocialAccountRepository.pg stageRepository.php© SubscriptionSetRepository.(C) TaskRepository.pho© TeamAiContextRepository.©) TeamDomainsRepository.p(©) TeaminsightsRepository.phC) TeamRepository.phpC ThemeRepository.phpC TimezoneRepository.php© TopicRepository.php© TopicTriggerRepository.ph© TrackRepository.phpC) TranscriptionModelLocaleF© TranscriptionRepository.prC) TranscriptionSummarvRepC UserRepository.php© VocabularyRepository.pnp› Rulesv D Services> _ Activity>D AReports>D AvatarcalendarM ConferenceM Crm>MImport> MInternallv → Kioskv _ AutomatedReports(C) ActivityTypeService.(©) AskJiminnyReportAc(C) AutomatedReportse(C) AutomatedReportsS(©) ReportController.php© JiminnyDebugCommand.phpC AutomatedReportsCommand.phpC) AutomatedReportsSendCommand.phpC) AddLayoutEntities.php(©) Team.php© AutomatedReportsRepository.php xAulomaleakeporisservice.onp(c CrealenelaAcuiviyevent.ono© TrackProviderInstalledEvent.phpC CreateActivityLoggedEvent.php© UserPilotActivityListener.php© ActivityLogged.php© AutomatedReportsCallbackService.php© RequestGenerateAskJiminnyReportJob.phpC RequestGenerateReportJob.php(©) AutomatedReportResult.phpc) Automatedkeport.oneclass Aucomaceareporcskepostcory53* Oreturn AutomatedReportpubLic tunccion createlarray paata). Аuсопасеакероrиr. . .л* Find an automated report bu UUID* Oparam string Suuid* dreturn Automatedkeport/nullpubLic tuncclon tindbyuu1d(string puu1d): :Automatedкeрoгиre atomеероt.ee, оmерrcoupamizealoouna atmetTusagepublic function findByld0rUuid(string Sid0rUuid): ?AutomatedReportAcceotif (is_numeric($id0rUuid)) (return AutomateaReport: wathlrasned(->rzn antp szdoruuza)l;recurn Automacedkeport::Wichlrasnecu-›wherel column: "Ju1d, Automatedкeporu:. couptimized slauruula-tirstunCascade & l* Retrieve all standard (non-Ask Jiminny) automated reports.* @param string $sortColumnThe column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to "created_at'.* aparam string SsortDirection The sort direction. Allowed values:'asc', 'desc'. Defaults to 'desc'.* dreturn collection<Automatedreport>12 usagespubLic tunction gecALLstandardkeportsstring ssortcolumn = "created_at",scring ssortbirection = 'desc': Collection (...l* Retrieve all Ask Jiminny reports created by the given user.* dparam UsersuserThe user whose reports to retrieve.* dparam string ssortcolumnThe column to sort by. Allowed values: 'created_by', "created_at'. Defaults to 'created_at".* @param string $sortDirection The sort direction. Allowed values:"asc, "desc". veraults to "desc".* drerurn couuectonsaurondredredor14 usagespublic function getAskJiminnyReportsByUserdUser Suser.string SsortColumn =created atWindsurf changelog 2.12.21: A new version is available. // View Changelog (today 10:33)KenecuCommand*_51= custom.log= laravel.log4 SF [iiminny@localhostlc HS_local Jiminny@localhost)e console (PROD]¿ console (EU]A console [STAGINGAskJiminnyReportActivityService.php xC RequestGenerateAskJiminnyReportJobTestclass ASkJiminnyReportActiviClosingPeriodFilter:public function __constrprivate readonly Actprivate readonly Elaprivate readonly Log) {...}* Fetch activity IDs fo* Date filters stored o* no dque conscrouns* dreturn stringl Actipublic function getActivSearch SsavedSearchUser suser,D: arraysrequestParams = sthnenrera s urtueraAcceptmarcetsreqarray merge (Srecsuser->getTimez):btulterset = sthis-MacuVVOS =109Sthis->loqger->infod'saved search id'user id' => Sus'activity_countID:return sactivityidsprivate runcuion bulake1 eallJ v Accept File &+X Reject File 1 38&Support Daily • in 2h 57 m100% |45]Tue 14 Apr 12:03:40RequestGenerateAskJiminnyReportJobTestCascadeFixing ReportControlleAutomated Report Ma• Automated Report !ip#L211 and add validation with logs insideGAutomatedRenortscommand. 0ho.5 209-710et me read the current state of the command tile firstkead Automateakeportscommana.ongIcan see the user's approach— processsing lekeport already exists trom my earlier work dut qetkeporcbyla iswhat's being used in processReports.Ineed to implement getReportByld properly with validation + logs, and addine reposttory metnoo. Leume also check the eutumtnare supportycollection impon stuatlon:Searched use luminate Suooort Colectionin apo/Console/Commands/Renorts/AutomatedRenortsCommand.oh...Now implement both changes - the repository method and the getReportByld method with proper validation:Error whlle ealting Aucomaceakepo rtscommand.onpRead AutomatecRenortscommand.onoThe file is now only 140 lines - the user removed the processSing leReport/warnlfNotApp Licab leForSchedu Lemetnoas. Now limplementcom changes.• AutomatedReportsCommand.php+o -1Now add tindbyldoruuld to the repository:1 Aulomalecreoorsreroslorv.onoAlso tix the import order (Collection should be betore the models alphabetically):AutomatedReportsCommand.php+1 -1• AutomatedReportsCommand.php+1 -1vone. oummary or changes.AUromareckedor skenos1rorv:: Tndbylouruu1o lautonarecrenorSkedos1t0rv.0no:4/—5492Numeric strine→ tindovinubNon-numenc → Uud ookuo via tooptimizedoBoth use withTrashed() so soft-deleted reports are findable manuallygetReportByld() (AutomatedReportsCommand.php: 135-194) — checks all conditions that getActiveReportsByFrequency enforces, logging a warning to the log channel and printing a warn() to the terminal for each violationbut sull rerurns the repor so processing continues.chockBehaviour on failINot Tounewarhina loe + terminal warn, returns emoty collection skips processine)Inactive statuswarnino loe + terminal warn, continueseam not activewarnino lloo + terminal warn, continuesExoiredwarning log + terminal warn, continuesFrequency wouldn't run todayinfo lod + terminal warn. continuesWC1l -2 files +51 >Ask anything (&+L)401 auesde Claude Sonnet 46Reject allAccept allwinasur leams51:1uir-oia 4 spaces...
|
NULL
|
|
11020
|
NULL
|
0
|
2026-04-14T09:08:39.627305+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776157719627_m1.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
+SlackEDHomeDMSActivityFilesLater..•More+FileEditV +SlackEDHomeDMSActivityFilesLater..•More+FileEditViewGoHistoryWindowHelpJiminny ...# Starredplatform-inner-teamChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi…..Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili.... Adelina PetrovaO. Calea Dimitravo→Search Jiminny IncAneliya Angelova, Nikolay Yankov, Steliyan GeorgievMessagesAdd canvas+Nikolay Yankov 10:45 AMпиши кат оя рьннешLukas Kovalik 10:52 AMзабавих се че ми се разбазикаха settings за средипуснах и мина и fail-наима result но e failedзначиREASON_NOT_ENOUGH_ACTIVITIESвиж дали има нещо в OD със този филтьрNikolay Yankov 11:01 AMДобреNikolay Yankov 11:39 AMя рьнни пак LukasLukas Kovalik 11:43 AMготовосьщотоCompetitive pitches беше втория нали такаNikolay Yankov 12:04 PMДа, там има 14 активитита, защо не сработи този пьт?Lukas Kovalik 12:05 PMпак изглежда sequenceгледам гоMessage Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev+Aa> 0ladl= Support Daily • in 2h 52 m100% <47Tue 14 Apr 12:08:3986 0Today ~...
|
NULL
|
-8257480601626042446
|
NULL
|
click
|
ocr
|
NULL
|
+SlackEDHomeDMSActivityFilesLater..•More+FileEditV +SlackEDHomeDMSActivityFilesLater..•More+FileEditViewGoHistoryWindowHelpJiminny ...# Starredplatform-inner-teamChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi…..Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili.... Adelina PetrovaO. Calea Dimitravo→Search Jiminny IncAneliya Angelova, Nikolay Yankov, Steliyan GeorgievMessagesAdd canvas+Nikolay Yankov 10:45 AMпиши кат оя рьннешLukas Kovalik 10:52 AMзабавих се че ми се разбазикаха settings за средипуснах и мина и fail-наима result но e failedзначиREASON_NOT_ENOUGH_ACTIVITIESвиж дали има нещо в OD със този филтьрNikolay Yankov 11:01 AMДобреNikolay Yankov 11:39 AMя рьнни пак LukasLukas Kovalik 11:43 AMготовосьщотоCompetitive pitches беше втория нали такаNikolay Yankov 12:04 PMДа, там има 14 активитита, защо не сработи този пьт?Lukas Kovalik 12:05 PMпак изглежда sequenceгледам гоMessage Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev+Aa> 0ladl= Support Daily • in 2h 52 m100% <47Tue 14 Apr 12:08:3986 0Today ~...
|
11016
|
|
11021
|
NULL
|
0
|
2026-04-14T09:08:42.495739+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776157722495_m2.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
PhpStormFileEditViewNavigateCodeLaravelRefactorFV PhpStormFileEditViewNavigateCodeLaravelRefactorFV faVsco.s v#11894 on JY-18909-automated-reports-ask-iminny K vProject v© ReportController.phpToolsWindowHelpJiminnybeouecommana.ong= custom.log= laravel.logA SF [jiminny@localhost]A HS_local [jiminny@localhost]A console [PROD]v _ ServiceAulomaleakeporscommand.ono< console LUlconsole SlAGiNG© AskJiminnyReportActivityService.php© ActivitySearch.php x© ActivityApiSearch.ph© ActivitySearch.php© AutomatedReportsSendCommand.php© AddLayoutEntities.php© AskJiminnyReportActivityServiceTest.phpRequestGenerateAskJiminnyReportJobTest.php© UserOptionsByGrour© Team.php© AutomatedReportsRepository.php X<?php© AbstractStageFilterDefil© AutomatedReportsService.phpC CreateHeldActivityEvent.phpActivitySearchServicePrdeclare(strict_types=1);C DeallnsightsPeriodFilter(e TrackProvidernstallled-vent.ono0 DealinsidnisPeriodrilteng FilterDetinition.php© CreateActivityLoggedEvent.php(©) ActivityLogged.php© UserPilotActivityListener.php(C) AutomatedReportsCallbackService.phpnamespace Jiminny \Component\ActivitySearch\Service;c rterverntoncolectousec rterverntoncuev.on© FilterDefinitionQueryColclass ActivitySearch© AutomatedReportResult.php• FilteredValueContainerli© IntMinMaxRange.php© RequestGenerateAskJiminnyReportJob.phpRequestGenerateReportJob.php(C) AutomatedReport.php[ AiActivityTypeclass Automacedкeрortskepo o:B15 X4 ^7 usagesprivate Container $container;[ AiAutomationD AiCallScoringpublic function __construct(Container $container){.}* Oreturn AutomatedReportD AskAnythingD AskJiminnyAipublic function getOnDemandPageFilters(): FilterDefinitionCollectionf...}DAWS• BillingManagementCache• CoachingFeedback> D CountryD CustomerApi35373839• DatabaseC DatadogC DateTimeDeallnsights• Dealkisks> IEasuicsearchpublic function create(array $data): Automate106107/**-108* Find an automated report by UUID109110* @param string $uvid111112* Oreturn AutomatedReport|null113114public function findByUuid(string $uvid): ?Al]115return AutomatedReport: :where('uvid', Aut118public function get0nDemandPageFilterSet(Criteria $criteria, User $consumer): FilterDefinitreturn $this->getOnDemandPageFilters()-›withCriteria($criteria)-›withConsumer ($consumer)->withRestrictions($consumer->getTeam()):› D Eloquent> DEncoding9 usages1 usage> M Encryption117public function getArrayFilterKeys(User $consumer): arrayf...}DESpubLie tunction tinabytaurousdlstring eiaurul 136> D Faker1 usage• FeatureFlagsif (is_numeric($id0rUuid)) {return AutomatedReport:: find((int) $1]private function getTeamInsightsPageFilters(bool $isExport = false): FilterDefinitionCollecO FFMpeg• FileSystemD GeckoD GongGuzzleHttp198return AutomatedReport: :where('uvid', Aut199200KeyPoints• Kiosk1 usageprivate function getDealInsightsPageFilters(bool $useCreatedDate = false,booL pincLudebeallype = ralse.bool +inctuderipellhe - Talse): FilterDefinitionCollection {..}M LanquageDetectionLiveFeedD Locks• Math• MediaPipeline• MeetingBot_ MobileSettings| ModelNotiticationD Nudge> [ ParagraphBreakerM ParticipantSpeechPartitionedCookie12402* Retrieve all standard (non-ASk Liminay) al 232*oodrdl sarno osorccocumin233The column tl 234*Cearal string ssorcosrection the sort a1m235236* Oreturn Collection<AutomatedReport>237— 24412 usagespublic function getAllStandardReports(string $sortColumn = 'created_at',string $sortDirection = 'desc'): Collection f...}/**245— 2462471248public function getTeamInsightsPageFilterSet(Criteria $criteria,User $consumer,bool $isExport = false): FilterDefinitionCollection i...rpublic function getDealInsightsPageFilterSet(Criteria $criteria,user consunen): FilterDefinitionCollectionf...}D PlaybackPageD PlaylistL07* Retrieve all ASK Lininny reports created k2601 usagepublic function getTeamAiAutomationFilterSet(Criteria $criteria,User $consumerWindsurf changelog 2.12.21: A new version is available. // View Changelog (today 10:33)Support Daily • in 2h 52mAL AskJiminny ReportActivityServiceT...Defaults100% C•Tue 14 Apr 12:08:42+D ...CascadeFixing ReportControllerAutomated Report Mar• Fixing Ask Jiminny RRoot Cause FoundThe buildRequestParamsFromSearch method in AskJiminnyReportActivityService passes sequence _number=0 implicitly (not in params), which meansisFirstRequest( returns true.When sequence_number is not in requestParams, the Criteria:: CreateFromkequest defaults it to 0, and isFirstRequest() returns true when empty I1sequenceNumber === 0.The frontend URL has sequence number=4— meaning it's not a first request. The service doesn't set it, so the criteria thinks it's a first request.Wnen 1srirstrequest = true.nese mollicttites are adalled tnar aren un tne saveo searehs" Acuvltylurar lonkande — aooles min curation = 1 lINAL MIN - tIters ourO-secono callls2. ActivityRecorded - applies only_recorded = 1 (DEFAULT_VALUE = OPTION_RECORDED) - filters to recorded-only3. OrganiserGroupIn - applies user's default group filterBut the frontend with sequence_number=4 skips all of these defaults, so it returns more results.The fix should be in buildRequestParamsFromSearch - it needs to pass sequence_number in the built params to signal "not a first request", so the implicitdefaults don't apolv. Or alternatively, alwavs pass a non-zero sequence number in the merge in getAct.ivitvIdsForSavedSearch.Read AskJiminnyReportActivityService.php #L44-93Now let me verify my understanding of isFirstRequest:Reao crierla,onoConfirmed. The fix is clear and minimal. The getAivityIdsForSavedSearch method needs to pass sequence_number with a non-zero value so that isFirstRequest () returns false and no implicit defaults are applied.• AskJiminnyReportActivityService.php+I-1Now let me check if there's an existing test for AskJiminnyReportActivityService to update:ExploredAskJiminnvReoortActivtvServicelest.onv and searchedAsk.iminnvReoortActivitvI need to add a test that verifies sequence_number=1 is passed to Criteria (so isFirstRequest() returns false ). Let me add it to the existing test file:• AskJiminnyReportActivityServiceTest.php+27Now let's run the test to verify:Command dockerdoste/ nkt sdovkeeskneate/ep/rts/ASktimannyReportActivityServiceTest.php --no-coverageCould not open input file: /var/www/html/artisandocker exec docker_lamp_1 php /app/artisantests/Unit/Services/Kiosk/testedReports/AskJiminnyReportActivityServiceTest.php --no-coverageCould not open input file: /app/artisanCommand dockel• docker exec docker lamp 1 bash -c "cd /var/www && php artisan testtests/Unit/Services/Kiosk/AutomatedReports/AskJiminnyReportActivityServiceTest.php --no-coverage 2>&1"Could not open input file: artisancommand dockelo docker exec docker_lamp_1 bash -c "find / -name artisan -maxdepth 6 2>/dev/null | head -5"Itlle win changesvapp/Services/Kiosk/AutomatedReports/ [ AskJiminnyReportActivityService.php +1 -1Ask anything (24L)+ <> Code Claude Sonnet 4.6Vew allliReject allAccept allWinasun leams11O:24uir-o( 4 spaces...
|
NULL
|
-1721715682181738533
|
NULL
|
visual_change
|
ocr
|
NULL
|
PhpStormFileEditViewNavigateCodeLaravelRefactorFV PhpStormFileEditViewNavigateCodeLaravelRefactorFV faVsco.s v#11894 on JY-18909-automated-reports-ask-iminny K vProject v© ReportController.phpToolsWindowHelpJiminnybeouecommana.ong= custom.log= laravel.logA SF [jiminny@localhost]A HS_local [jiminny@localhost]A console [PROD]v _ ServiceAulomaleakeporscommand.ono< console LUlconsole SlAGiNG© AskJiminnyReportActivityService.php© ActivitySearch.php x© ActivityApiSearch.ph© ActivitySearch.php© AutomatedReportsSendCommand.php© AddLayoutEntities.php© AskJiminnyReportActivityServiceTest.phpRequestGenerateAskJiminnyReportJobTest.php© UserOptionsByGrour© Team.php© AutomatedReportsRepository.php X<?php© AbstractStageFilterDefil© AutomatedReportsService.phpC CreateHeldActivityEvent.phpActivitySearchServicePrdeclare(strict_types=1);C DeallnsightsPeriodFilter(e TrackProvidernstallled-vent.ono0 DealinsidnisPeriodrilteng FilterDetinition.php© CreateActivityLoggedEvent.php(©) ActivityLogged.php© UserPilotActivityListener.php(C) AutomatedReportsCallbackService.phpnamespace Jiminny \Component\ActivitySearch\Service;c rterverntoncolectousec rterverntoncuev.on© FilterDefinitionQueryColclass ActivitySearch© AutomatedReportResult.php• FilteredValueContainerli© IntMinMaxRange.php© RequestGenerateAskJiminnyReportJob.phpRequestGenerateReportJob.php(C) AutomatedReport.php[ AiActivityTypeclass Automacedкeрortskepo o:B15 X4 ^7 usagesprivate Container $container;[ AiAutomationD AiCallScoringpublic function __construct(Container $container){.}* Oreturn AutomatedReportD AskAnythingD AskJiminnyAipublic function getOnDemandPageFilters(): FilterDefinitionCollectionf...}DAWS• BillingManagementCache• CoachingFeedback> D CountryD CustomerApi35373839• DatabaseC DatadogC DateTimeDeallnsights• Dealkisks> IEasuicsearchpublic function create(array $data): Automate106107/**-108* Find an automated report by UUID109110* @param string $uvid111112* Oreturn AutomatedReport|null113114public function findByUuid(string $uvid): ?Al]115return AutomatedReport: :where('uvid', Aut118public function get0nDemandPageFilterSet(Criteria $criteria, User $consumer): FilterDefinitreturn $this->getOnDemandPageFilters()-›withCriteria($criteria)-›withConsumer ($consumer)->withRestrictions($consumer->getTeam()):› D Eloquent> DEncoding9 usages1 usage> M Encryption117public function getArrayFilterKeys(User $consumer): arrayf...}DESpubLie tunction tinabytaurousdlstring eiaurul 136> D Faker1 usage• FeatureFlagsif (is_numeric($id0rUuid)) {return AutomatedReport:: find((int) $1]private function getTeamInsightsPageFilters(bool $isExport = false): FilterDefinitionCollecO FFMpeg• FileSystemD GeckoD GongGuzzleHttp198return AutomatedReport: :where('uvid', Aut199200KeyPoints• Kiosk1 usageprivate function getDealInsightsPageFilters(bool $useCreatedDate = false,booL pincLudebeallype = ralse.bool +inctuderipellhe - Talse): FilterDefinitionCollection {..}M LanquageDetectionLiveFeedD Locks• Math• MediaPipeline• MeetingBot_ MobileSettings| ModelNotiticationD Nudge> [ ParagraphBreakerM ParticipantSpeechPartitionedCookie12402* Retrieve all standard (non-ASk Liminay) al 232*oodrdl sarno osorccocumin233The column tl 234*Cearal string ssorcosrection the sort a1m235236* Oreturn Collection<AutomatedReport>237— 24412 usagespublic function getAllStandardReports(string $sortColumn = 'created_at',string $sortDirection = 'desc'): Collection f...}/**245— 2462471248public function getTeamInsightsPageFilterSet(Criteria $criteria,User $consumer,bool $isExport = false): FilterDefinitionCollection i...rpublic function getDealInsightsPageFilterSet(Criteria $criteria,user consunen): FilterDefinitionCollectionf...}D PlaybackPageD PlaylistL07* Retrieve all ASK Lininny reports created k2601 usagepublic function getTeamAiAutomationFilterSet(Criteria $criteria,User $consumerWindsurf changelog 2.12.21: A new version is available. // View Changelog (today 10:33)Support Daily • in 2h 52mAL AskJiminny ReportActivityServiceT...Defaults100% C•Tue 14 Apr 12:08:42+D ...CascadeFixing ReportControllerAutomated Report Mar• Fixing Ask Jiminny RRoot Cause FoundThe buildRequestParamsFromSearch method in AskJiminnyReportActivityService passes sequence _number=0 implicitly (not in params), which meansisFirstRequest( returns true.When sequence_number is not in requestParams, the Criteria:: CreateFromkequest defaults it to 0, and isFirstRequest() returns true when empty I1sequenceNumber === 0.The frontend URL has sequence number=4— meaning it's not a first request. The service doesn't set it, so the criteria thinks it's a first request.Wnen 1srirstrequest = true.nese mollicttites are adalled tnar aren un tne saveo searehs" Acuvltylurar lonkande — aooles min curation = 1 lINAL MIN - tIters ourO-secono callls2. ActivityRecorded - applies only_recorded = 1 (DEFAULT_VALUE = OPTION_RECORDED) - filters to recorded-only3. OrganiserGroupIn - applies user's default group filterBut the frontend with sequence_number=4 skips all of these defaults, so it returns more results.The fix should be in buildRequestParamsFromSearch - it needs to pass sequence_number in the built params to signal "not a first request", so the implicitdefaults don't apolv. Or alternatively, alwavs pass a non-zero sequence number in the merge in getAct.ivitvIdsForSavedSearch.Read AskJiminnyReportActivityService.php #L44-93Now let me verify my understanding of isFirstRequest:Reao crierla,onoConfirmed. The fix is clear and minimal. The getAivityIdsForSavedSearch method needs to pass sequence_number with a non-zero value so that isFirstRequest () returns false and no implicit defaults are applied.• AskJiminnyReportActivityService.php+I-1Now let me check if there's an existing test for AskJiminnyReportActivityService to update:ExploredAskJiminnvReoortActivtvServicelest.onv and searchedAsk.iminnvReoortActivitvI need to add a test that verifies sequence_number=1 is passed to Criteria (so isFirstRequest() returns false ). Let me add it to the existing test file:• AskJiminnyReportActivityServiceTest.php+27Now let's run the test to verify:Command dockerdoste/ nkt sdovkeeskneate/ep/rts/ASktimannyReportActivityServiceTest.php --no-coverageCould not open input file: /var/www/html/artisandocker exec docker_lamp_1 php /app/artisantests/Unit/Services/Kiosk/testedReports/AskJiminnyReportActivityServiceTest.php --no-coverageCould not open input file: /app/artisanCommand dockel• docker exec docker lamp 1 bash -c "cd /var/www && php artisan testtests/Unit/Services/Kiosk/AutomatedReports/AskJiminnyReportActivityServiceTest.php --no-coverage 2>&1"Could not open input file: artisancommand dockelo docker exec docker_lamp_1 bash -c "find / -name artisan -maxdepth 6 2>/dev/null | head -5"Itlle win changesvapp/Services/Kiosk/AutomatedReports/ [ AskJiminnyReportActivityService.php +1 -1Ask anything (24L)+ <> Code Claude Sonnet 4.6Vew allliReject allAccept allWinasun leams11O:24uir-o( 4 spaces...
|
NULL
|
|
11022
|
219
|
0
|
2026-04-14T09:08:57.582059+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776157737582_m2.jpg...
|
PhpStorm
|
faVsco.js – ActivitySearch.php
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
AskJiminnyReportActivityServiceT…Defaults
Rerun 'PHPUnit: AskJiminnyReportActivityServiceTest.testGetActivityIdsPassesNonZeroSequenceNumberToDisableFirstRequestDefaults'
Debug 'AskJiminnyReportActivityServiceTest.tes…uenceNumberToDisableFirstRequestDefaults'
Stop 'AskJiminnyReportActivityServiceTest.testGetActivityIdsPassesNonZeroSequenceNumberToDisableFirstRequestDefaults'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
<?php
declare(strict_types=1);
namespace Jiminny\Component\ActivitySearch\Service;
use Illuminate\Container\Container;
use Illuminate\Support\Collection;
use Jiminny\Component\ActivitySearch\FilterDefinition;
use Jiminny\Component\ActivitySearch\FilterDefinition\AiCallScoreFilter;
use Jiminny\Component\ActivitySearch\FilterDefinition\AutoScoreFilter;
use Jiminny\Component\ActivitySearch\FilterDefinition\ClosedDealsFilter;
use Jiminny\Component\ActivitySearch\FilterDefinition\DealCloseDate;
use Jiminny\Component\ActivitySearch\FilterDefinition\HasTopicTriggersFilterDefinition;
use Jiminny\Component\ActivitySearch\FilterDefinition\PlaybackTopicFilterDefinition;
use Jiminny\Component\ActivitySearch\FilterDefinition\Security\RestrictActivityChannel;
use Jiminny\Component\ActivitySearch\FilterDefinition\Security\RestrictPublicActivitiesOnly;
use Jiminny\Component\ActivitySearch\FilterDefinition\Security\RestrictTeam;
use Jiminny\Component\ActivitySearch\FilterDefinition\Security\RestrictUserActive;
use Jiminny\Component\ActivitySearch\FilterDefinition\Security\RestrictUserGroupScope;
use Jiminny\Component\ActivitySearch\FilterDefinition\TeamInsights\TopicFilterDefinition;
use Jiminny\Component\ActivitySearch\FilterDefinitionCollection;
use Jiminny\Models\Crm\Field;
use Jiminny\Models\User;
use Jiminny\Models\Crm\Configuration;
use Jiminny\Repositories\Crm\LayoutRepository;
use Jiminny\Services\TeamService;
use Jiminny\VO\Repository\OnDemandActivitySearch\Criteria;
class ActivitySearch
{
private Container $container;
public function __construct(Container $container)
{
$this->container = $container;
}
public function getOnDemandPageFilters(): FilterDefinitionCollection
{
return FilterDefinitionCollection::make(
Collection::make([
// special case filters
FilterDefinition\ActivityStatusIn::class,
FilterDefinition\ActivityUpdatedDate::class,
FilterDefinition\ActivityRecordingStopped::class,
FilterDefinition\ActivityFilter::class,
FilterDefinition\ExternalId::class,
FilterDefinition\NudgeRunId::class,
FilterDefinition\ParticipantUserIn::class,
FilterDefinition\PartnerFilterDefinition::class,
// healthy restrictions
RestrictTeam::class,
RestrictUserGroupScope::class,
RestrictActivityChannel::class,
RestrictUserActive::class,
FilterDefinition\Security\PrivateMeetingsForCurrentUserOnly::class,
// regular filters
FilterDefinition\ActivityActualDate::class,
FilterDefinition\ActivityChannel::class,
FilterDefinition\ActivityDurationRange::class,
FilterDefinition\ActivityPlaylistIn::class,
FilterDefinition\ActivityProviderIn::class,
FilterDefinition\ActivityRecorded::class,
FilterDefinition\ActivityType::class,
FilterDefinition\CoachingFeedbackAverageScore::class,
AutoScoreFilter::class,
AiCallScoreFilter::class,
FilterDefinition\CoachingFeedbackCoachUserIn::class,
FilterDefinition\CrmFieldCollection::class,
FilterDefinition\CurrentStage::class,
FilterDefinition\Customer::class,
FilterDefinition\CustomerMonologueDuration::class,
FilterDefinition\CustomerQuestionCount::class,
FilterDefinition\DealAge::class,
DealCloseDate::class,
FilterDefinition\DealValue::class,
FilterDefinition\EngagingQuestionCount::class,
FilterDefinition\ShowInternalExternalActivitiesFilter::class,
FilterDefinition\HasTranscription::class,
FilterDefinition\InsightfulQuestionCount::class,
FilterDefinition\LanguageFilterDefinition::class,
FilterDefinition\LoggedToCrm::class,
FilterDefinition\OrganiserGroupIn:[PASSWORD]
FilterDefinition\OrganiserUserIn::class,
FilterDefinition\PatienceRange::class,
PlaybackTopicFilterDefinition::class,
FilterDefinition\ProviderFilterDefinition::class,
FilterDefinition\SortBy::class,
FilterDefinition\SpeechRate::class,
FilterDefinition\StageAtCallFilterDefinition::class,
FilterDefinition\TalkTimeRatio::class,
FilterDefinition\TeamMemberUserIn::class,
FilterDefinition\TranscriptionComposite::class,
FilterDefinition\UserMonologueDuration::class,
FilterDefinition\UserQuestionCount::class,
FilterDefinition\CommentCountRange::class,
FilterDefinition\HasPendingAiCrmNotes::class,
])
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all(),
);
}
public function getOnDemandPageFilterSet(Criteria $criteria, User $consumer): FilterDefinitionCollection
{
return $this
->getOnDemandPageFilters()
->withCriteria($criteria)
->withConsumer($consumer)
->withRestrictions($consumer->getTeam());
}
/**
* @return string[]
*/
public function getArrayFilterKeys(User $consumer): array
{
return $this
->getOnDemandPageFilters()
->withConsumer($consumer)
->getPropertyTypes([FilterDefinitionCollection::PROPERTY_TYPE_ARRAY])
->keys()
->filter(static fn (string $key): bool => ! str_contains($key, '.'))
->values()
->all();
}
private function getTeamInsightsPageFilters(bool $isExport = false): FilterDefinitionCollection
{
$dateRangeFilterClass = $isExport
? FilterDefinition\TeamInsights\ConversationExport\DateRangeFilter::class
: FilterDefinition\TeamInsights\DateRangeFilter::class;
return FilterDefinitionCollection::make(
Collection::make([
// special cases
$dateRangeFilterClass,
FilterDefinition\TeamInsights\Exists::class,
// healthy restrictions
RestrictTeam::class,
RestrictUserGroupScope::class,
RestrictActivityChannel::class,
RestrictPublicActivitiesOnly::class,
RestrictUserActive::class,
// regular filters
FilterDefinition\ActivityChannel::class,
FilterDefinition\TeamInsights\ActivityDurationRange::class,
FilterDefinition\ActivityPlaylistIn::class,
FilterDefinition\ActivityProviderIn::class,
FilterDefinition\TeamInsights\ActivityRecorded::class,
FilterDefinition\ActivityType::class,
FilterDefinition\CoachingFeedbackAverageScore::class,
AutoScoreFilter::class,
AiCallScoreFilter::class,
FilterDefinition\CoachingFeedbackCoachUserIn::class,
FilterDefinition\CrmFieldCollection::class,
FilterDefinition\Customer::class,
FilterDefinition\CurrentStage::class,
FilterDefinition\CustomerMonologueDuration::class,
FilterDefinition\CustomerQuestionCount::class,
FilterDefinition\DealAge::class,
DealCloseDate::class,
FilterDefinition\DealValue::class,
FilterDefinition\EngagingQuestionCount::class,
FilterDefinition\ShowInternalExternalActivitiesFilter::class,
FilterDefinition\InsightfulQuestionCount::class,
FilterDefinition\LanguageFilterDefinition::class,
FilterDefinition\LoggedToCrm::class,
FilterDefinition\TeamInsights\UserInFilter::class,
FilterDefinition\TeamInsights\UserGroupInFilter::class,
FilterDefinition\PatienceRange::class,
PlaybackTopicFilterDefinition::class,
FilterDefinition\ProviderFilterDefinition::class,
FilterDefinition\SortBy::class,
FilterDefinition\SpeechRate::class,
FilterDefinition\StageAtCallFilterDefinition::class,
FilterDefinition\TalkTimeRatio::class,
FilterDefinition\TeamMemberUserIn::class,
FilterDefinition\TranscriptionComposite::class,
FilterDefinition\UserMonologueDuration::class,
FilterDefinition\UserQuestionCount::class,
FilterDefinition\CommentCountRange::class,
// Relevant for topics in deals.
ClosedDealsFilter::class,
HasTopicTriggersFilterDefinition::class,
TopicFilterDefinition::class,
])
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all(),
);
}
private function getDealInsightsPageFilters(
bool $useCreatedDate = false,
bool $includeDealType = false,
bool $includePipeline = false,
): FilterDefinitionCollection {
if ($useCreatedDate) {
$periodFilterClass = FilterDefinition\DealInsights\CreatedPeriodFilter::class;
} else {
$periodFilterClass = FilterDefinition\DealInsights\ClosingPeriodFilter::class;
}
$filterSet = [
RestrictTeam::class,
$periodFilterClass,
FilterDefinition\DealInsights\UserInFilter::class,
FilterDefinition\DealInsights\UserGroupInFilter::class,
FilterDefinition\DealInsights\DealStageInFilter::class,
FilterDefinition\DealInsights\DealNameFilter::class,
];
if ($includePipeline) {
$filterSet[] = FilterDefinition\DealInsights\DealPipelineInFilter::class;
}
if ($includeDealType) {
$filterSet[] = FilterDefinition\DealInsights\DealTypeInFilter::class;
}
return FilterDefinitionCollection::make(
Collection::make($filterSet)
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all(),
);
}
public function getTeamInsightsPageFilterSet(
Criteria $criteria,
User $consumer,
bool $isExport = false
): FilterDefinitionCollection {
return $this
->getTeamInsightsPageFilters($isExport)
->withCriteria($criteria)
->withConsumer($consumer)
->withRestrictions($consumer->getTeam());
}
public function getDealInsightsPageFilterSet(
Criteria $criteria,
User $consumer
): FilterDefinitionCollection {
$includeDealType = $this->shouldIncludeDealType($consumer);
$includePipeline = $this->shouldIncludePipeline($consumer);
$useCreatedDate = $this->shouldUseCreatedDate($consumer);
return $this
->getDealInsightsPageFilters($useCreatedDate, $includeDealType, $includePipeline)
->withCriteria($criteria)
->withConsumer($consumer);
}
public function getTeamAiAutomationFilterSet(
Criteria $criteria,
User $consumer
): FilterDefinitionCollection {
return $this
->getTeamAiAutomationPageFilterSet()
->withCriteria($criteria)
->withConsumer($consumer);
}
private function getTeamAiAutomationPageFilterSet(): FilterDefinitionCollection
{
$filterSet = [
RestrictTeam::class,
FilterDefinition\DealInsights\DealStageInFilter::class,
];
return FilterDefinitionCollection::make(
Collection::make($filterSet)
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all(),
);
}
public function getHomepageFilterSet(Criteria $criteria, User $consumer): FilterDefinitionCollection
{
$filterDefinitionCollection = FilterDefinitionCollection::make(
Collection::make([
RestrictTeam::class,
RestrictUserGroupScope::class,
RestrictActivityChannel::class,
RestrictUserActive::class,
FilterDefinition\Security\PrivateMeetingsForCurrentUserOnly::class,
FilterDefinition\ActivityActualDate::class,
FilterDefinition\Customer::class,
FilterDefinition\ActivityChannel::class,
FilterDefinition\ActivityDurationRange::class,
FilterDefinition\ActivityProviderIn::class,
FilterDefinition\ActivityRecorded::class,
FilterDefinition\ActivityRecordingStopped::class,
FilterDefinition\ActivityScheduledDate::class,
FilterDefinition\ActivityStatusIn::class,
FilterDefinition\LoggedToCrm::class,
FilterDefinition\OrganiserUserIn::class,
FilterDefinition\OrganiserUserNotIn::class,
FilterDefinition\ProviderFilterDefinition::class,
FilterDefinition\SortBy::class,
FilterDefinition\UserGroupInOptionalFilter::class,
FilterDefinition\OnlyActiveUsers::class,
])
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all(),
);
$filterDefinitionCollection->withCriteria($criteria);
$filterDefinitionCollection->withConsumer($consumer);
return $filterDefinitionCollection;
}
public function getPartnerFilterSet(Criteria $criteria): FilterDefinitionCollection
{
$filterDefinitionCollection = FilterDefinitionCollection::make(
Collection::make([
RestrictActivityChannel::class,
FilterDefinition\OrganiserTeamIn::class,
FilterDefinition\ActivityUpdatedDate::class,
FilterDefinition\ActivityStatusIn::class,
FilterDefinition\SortBy::class,
])
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all()
);
$filterDefinitionCollection->withCriteria($criteria);
return $filterDefinitionCollection;
}
private function shouldIncludeDealType(User $user): bool
{
$crmConfig = $user->getTeam()->getCrmConfiguration();
$crmProviderName = $crmConfig->getProviderName();
if (! array_key_exists($crmProviderName, Field::BUSINESS_TYPE_FIELDS)) {
return false;
}
$layoutRepository = app(LayoutRepository::class);
$layoutFields = $layoutRepository->getDealInsightLayoutFields($crmConfig);
$dealTypeField = Field::BUSINESS_TYPE_FIELDS[$crmProviderName];
if (! in_array($dealTypeField, $layoutFields)) {
return false;
}
return true;
}
private function shouldIncludePipeline(User $user): bool
{
$crmConfig = $user->getTeam()->getCrmConfiguration();
$crmProviderName = $crmConfig->getProviderName();
if (in_array($crmProviderName, [
Configuration::PROVIDER_SALESFORCE,
Configuration::PROVIDER_INTEGRATION_APP,
])) {
return false;
}
return true;
}
private function shouldUseCreatedDate(User $user): bool
{
$teamService = app(TeamService::class);
return ! $teamService->useDealInsightsClosedDateFilter($user->getTeam());
}
}
Sync Changes
Hide This Notification
Code changed:
Hide
15
4
Previous Highlighted Error
Next Highlighted Error
<?php
declare(strict_types=1);
namespace Jiminny\Repositories;
use Carbon\CarbonImmutable;
use Illuminate\Database\Eloquent\Builder;
use Illuminate\Support\Carbon;
use Illuminate\Database\Eloquent\Collection;
use Illuminate\Pagination\LengthAwarePaginator;
use Illuminate\Support\Facades\DB;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\AutomatedReportResult;
use Jiminny\Models\Team;
use Jiminny\Models\User;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Jiminny\Services\Kiosk\AutomatedReports\ReportSort;
use Jiminny\Services\Kiosk\AutomatedReports\ReportSortDirection;
class AutomatedReportsRepository
{
/**
* Create a new automated report
*
* @param array $data
*
* @return AutomatedReport
*/
public function create(array $data): AutomatedReport
{
return AutomatedReport::create($data);
}
/**
* Find an automated report by UUID
*
* @param string $uuid
*
* @return AutomatedReport|null
*/
public function findByUuid(string $uuid): ?AutomatedReport
{
return AutomatedReport::where('uuid', AutomatedReport::toOptimized($uuid))->first();
}
public function findByIdOrUuid(string $idOrUuid): ?AutomatedReport
{
if (is_numeric($idOrUuid)) {
return AutomatedReport::find((int) $idOrUuid);
}
return AutomatedReport::where('uuid', AutomatedReport::toOptimized($idOrUuid))->first();
}
/**
* Retrieve all standard (non-Ask Jiminny) automated reports.
*
* @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.
* @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.
*
* @return Collection<AutomatedReport>
*/
public function getAllStandardReports(
string $sortColumn = 'created_at',
string $sortDirection = 'desc'
): Collection {
return $this->buildSortedQuery($sortColumn, $sortDirection)
->whereNot('type', AutomatedReportsService::TYPE_ASK_JIMINNY)
->get();
}
/**
* Retrieve all Ask Jiminny reports created by the given user.
*
* @param User $user The user whose reports to retrieve.
* @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.
* @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.
*
* @return Collection<AutomatedReport>
*/
public function getAskJiminnyReportsByUser(
User $user,
string $sortColumn = 'created_at',
string $sortDirection = 'desc'
): Collection {
return $this->buildSortedQuery($sortColumn, $sortDirection)
->where('type', AutomatedReportsService::TYPE_ASK_JIMINNY)
->where('created_by', $user->getId())
->get();
}
private function buildSortedQuery(string $sortColumn, string $sortDirection): \Illuminate\Database\Eloquent\Builder
{
$allowedColumns = ['created_by', 'created_at'];
if (! in_array($sortColumn, $allowedColumns)) {
$sortColumn = 'created_at';
}
$sortDirection = strtolower($sortDirection) === 'asc' ? 'asc' : 'desc';
$query = AutomatedReport::query()->with(['creator', 'team']);
if ($sortColumn === 'created_by') {
$query->leftJoin('users', 'users.id', '=', 'automated_reports.created_by')
->orderByRaw("users.name COLLATE utf8mb4_unicode_ci {$sortDirection}")
->select('automated_reports.*');
} else {
$query->orderBy($sortColumn, $sortDirection);
}
return $query;
}
/**
* Get all active and enabled reports with active teams for the specified frequency.
*
* @param string $frequency
*
* @return Collection<AutomatedReport>
*/
public function getActiveReportsByFrequency(string $frequency): Collection
{
return AutomatedReport::where('automated_reports.status', true)
->where('automated_reports.frequency', $frequency)
->join('teams', 'automated_reports.team_id', '=', 'teams.id')
->where('teams.status', Team::STATUS_ACTIVE)
->where(function ($query) {
$query->whereNull('automated_reports.expires_at')
->orWhere('automated_reports.expires_at', '>=', now()->toDateString());
})
->select('automated_reports.*')
->get();
}
/**
* Update an automated report
*
* @param AutomatedReport $report
* @param array $data
*
* @return AutomatedReport
*/
public function update(AutomatedReport $report, array $data): AutomatedReport
{
$report->update($data);
return $report;
}
/**
* Create a new automated report result.
*
* @param array $data The data to create the automated report result with.
*
* @return AutomatedReportResult The newly created automated report result.
*/
public function createResult(array $data): AutomatedReportResult
{
return AutomatedReportResult::create($data);
}
/**
* Find an automated report result by UUID.
*
* @param string $uuid The UUID to find the automated report result with.
*
* @return AutomatedReportResult|null The automated report result if found, otherwise null.
*/
public function findResultByUuid(string $uuid): ?AutomatedReportResult
{
return AutomatedReportResult::where('uuid', AutomatedReportResult::toOptimized($uuid))->first();
}
public function findResultByUuidForUser(string $uuid, User $user): ?AutomatedReportResult
{
return AutomatedReportResult::query()
->where('uuid', AutomatedReportResult::toOptimized($uuid))
->whereHas('report', static function ($query) use ($user): void {
$query->where('team_id', $user->getTeamId())
->where('created_by', $user->getId());
})
->first();
}
public function findChildResult(AutomatedReportResult $result, string $type): ?AutomatedReportResult
{
return AutomatedReportResult::query()
->where('parent_id', $result->getId())
->where('media_type', $type)
->first();
}
public function getGeneratedNotSentResults(): Collection
{
return AutomatedReportResult::query()
->whereNotNull('generated_at')
->whereNull('sent_at')
->where('status', AutomatedReportResult::STATUS_GENERATED)
->whereHas('report')
->with('report')
->get();
}
public function getPaginatedUserReports(
User $user,
ReportSort $sort,
ReportSortDirection $sortDirection,
int $resultsPerPage,
int $page,
?Carbon $fromDate,
?Carbon $toDate,
array $teamIds,
array $reportTypes,
?string $name,
): LengthAwarePaginator {
$query = AutomatedReportResult::query()
->whereNotNull('automated_report_results.generated_at')
->join('automated_reports', 'automated_report_results.report_id', '=', 'automated_reports.id')
->where('automated_reports.team_id', $user->getTeamId())
->whereJsonContains('automated_reports.recipients->users', $user->getId())
->orderByRaw("$sort->value COLLATE utf8mb4_unicode_ci {$sortDirection->value}")
->select('automated_report_results.*')
->with('report.team');
if ($fromDate !== null && $toDate !== null) {
$query->whereBetween('generated_at', [$fromDate, $toDate]);
}
if (! empty($teamIds)) {
$query->where(function ($q) use ($teamIds) {
foreach ($teamIds as $id) {
$q->orWhereJsonContains('automated_reports.groups', $id);
}
});
}
if (! empty($reportTypes)) {
$query->whereIn('automated_reports.type', $reportTypes);
}
if (! empty($name)) {
$query->whereLike('name', "%$name%");
}
return $query->paginate($resultsPerPage, ['*'], 'page', $page);
}
public function countUserReports(User $user): int
{
return AutomatedReportResult::query()
->whereNotNull('generated_at')
->whereNotNull('sent_at')
->whereHas('report', function ($q) use ($user) {
$q->where('team_id', $user->getTeamId())
->whereJsonContains('recipients->users', $user->getId());
})
->count();
}
/**
* Get report IDs for a specific team
*
* @param Team $team
*
* @return \Illuminate\Support\Collection
*/
public function getReportIdsByTeam(Team $team): \Illuminate\Support\Collection
{
return AutomatedReport::where('team_id', $team->getId())->pluck('id');
}
/**
* Get all reports for a specific team
*
* @param Team $team
*
* @return Collection
*/
public function getReportsByTeam(Team $team): Collection
{
return AutomatedReport::where('team_id', $team->getId())->get();
}
/**
* Get all report results for a specific report
*
* @param AutomatedReport $report
*
* @return Collection
*/
public function getResultsByReport(AutomatedReport $report): Collection
{
return $this->getResultsByReportQuery($report)->get();
}
public function getResultsByReportQuery(AutomatedReport $report): Builder
{
return AutomatedReportResult::where('report_id', $report->getId());
}
public function getReportResultsQueryForRetention(Team $team, CarbonImmutable $retentionDate): Builder
{
$reportIds = $this->getReportIdsByTeam($team);
return AutomatedReportResult::query()->whereIn('report_id', $reportIds)
->whereRaw('IFNULL(generated_at, created_at) <= ?', [$retentionDate]);
}
/**
* @param int|null $teamId Optional team ID to filter results
*
* @return \Illuminate\Support\Collection<int, int> Collection of team IDs
*/
public function getTeamIdsWithReportsResults(?int $teamId = null): \Illuminate\Support\Collection
{
$query = DB::table('automated_reports')
->join('teams', 'automated_reports.team_id', '=', 'teams.id')
->select('teams.id')
->distinct();
if ($teamId !== null) {
$query->where('teams.id', $teamId);
}
return $query->pluck('teams.id');
}
}
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide
app ~/jiminny/app
.circleci
.cursor
.github
.sonarlint
.vscode
.windsurf
app, sources root
Actions
Component
Acl, folder
ActionItems, folder
Activity, folder
ActivityAnalytics, folder
ActivitySearch, folder
EventSubscriber, folder
FilterDefinition, folder
Service
ActivityApiSearch.php, class
ActivitySearch.php, class
UserOptionsByGroup.php, class
AbstractStageFilterDefinition.php, abstract class
ActivitySearchServiceProvider.php, final class
DealInsightsPeriodFilterFactory.php
DealInsightsPeriodFilterFactoryInterface.php, interface
FilterDefinition.php, abstract class
FilterDefinitionCollection.php, class
FilterDefinitionQuery.php, class
FilterDefinitionQueryCollection.php, class
FilteredValueContainerInterface.php, interface
IntMinMaxRange.php, class
AiActivityType
AiAutomation
AiCallScoring
AskAnything
AskJiminnyAi
AWS
BillingManagement
Cache
CoachingFeedback
Country
CustomerApi
Database
Datadog
DateTime
DealInsights
DealRisks
ElasticSearch
Eloquent
Encoding
Encryption
ES
Faker
FeatureFlags
FFMpeg
FileSystem
Gecko
Gong
GuzzleHttp
KeyPoints
Kiosk
LanguageDetection
LiveFeed
Locks
Math
MediaPipeline
MeetingBot
MobileSettings
Model
Notification
Nudge...
|
[{"role":"AXButton","text" [{"role":"AXButton","text":"Project: faVsco.js, menu","depth":5,"bounds":{"left":0.03046875,"top":0.017361112,"width":0.0453125,"height":0.022222223},"help_text":"~/jiminny/app","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"#11894 on JY-18909-automated-reports-ask-jiminny, menu","depth":5,"bounds":{"left":0.07578125,"top":0.017361112,"width":0.14960937,"height":0.022222223},"help_text":"Pull request #11894 exists for current branch JY-18909-automated-reports-ask-jiminny, but local branch is out of sync with remote","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Start Listening for PHP Debug Connections","depth":5,"bounds":{"left":0.7589844,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"AskJiminnyReportActivityServiceT…Defaults","depth":6,"bounds":{"left":0.7769531,"top":0.017361112,"width":0.12382813,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Rerun 'PHPUnit: AskJiminnyReportActivityServiceTest.testGetActivityIdsPassesNonZeroSequenceNumberToDisableFirstRequestDefaults'","depth":6,"bounds":{"left":0.9007813,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Debug 'AskJiminnyReportActivityServiceTest.tes…uenceNumberToDisableFirstRequestDefaults'","depth":6,"bounds":{"left":0.9140625,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Stop 'AskJiminnyReportActivityServiceTest.testGetActivityIdsPassesNonZeroSequenceNumberToDisableFirstRequestDefaults'","depth":6,"bounds":{"left":0.9273437,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"More Actions","depth":6,"bounds":{"left":0.940625,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"JetBrains AI","depth":5,"bounds":{"left":0.96015626,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Search Everywhere","depth":5,"bounds":{"left":0.9734375,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"IDE and Project Settings","depth":5,"bounds":{"left":0.9867188,"top":0.017361112,"width":0.013281226,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.049609374,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Component\\ActivitySearch\\Service;\n\nuse Illuminate\\Container\\Container;\nuse Illuminate\\Support\\Collection;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\AiCallScoreFilter;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\AutoScoreFilter;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\ClosedDealsFilter;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\DealCloseDate;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\HasTopicTriggersFilterDefinition;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\PlaybackTopicFilterDefinition;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\Security\\RestrictActivityChannel;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\Security\\RestrictPublicActivitiesOnly;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\Security\\RestrictTeam;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\Security\\RestrictUserActive;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\Security\\RestrictUserGroupScope;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\TeamInsights\\TopicFilterDefinition;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinitionCollection;\nuse Jiminny\\Models\\Crm\\Field;\nuse Jiminny\\Models\\User;\nuse Jiminny\\Models\\Crm\\Configuration;\nuse Jiminny\\Repositories\\Crm\\LayoutRepository;\nuse Jiminny\\Services\\TeamService;\nuse Jiminny\\VO\\Repository\\OnDemandActivitySearch\\Criteria;\n\nclass ActivitySearch\n{\n private Container $container;\n\n public function __construct(Container $container)\n {\n $this->container = $container;\n }\n\n public function getOnDemandPageFilters(): FilterDefinitionCollection\n {\n return FilterDefinitionCollection::make(\n Collection::make([\n // special case filters\n FilterDefinition\\ActivityStatusIn::class,\n FilterDefinition\\ActivityUpdatedDate::class,\n FilterDefinition\\ActivityRecordingStopped::class,\n FilterDefinition\\ActivityFilter::class,\n FilterDefinition\\ExternalId::class,\n FilterDefinition\\NudgeRunId::class,\n FilterDefinition\\ParticipantUserIn::class,\n FilterDefinition\\PartnerFilterDefinition::class,\n\n // healthy restrictions\n RestrictTeam::class,\n RestrictUserGroupScope::class,\n RestrictActivityChannel::class,\n RestrictUserActive::class,\n FilterDefinition\\Security\\PrivateMeetingsForCurrentUserOnly::class,\n\n // regular filters\n FilterDefinition\\ActivityActualDate::class,\n FilterDefinition\\ActivityChannel::class,\n FilterDefinition\\ActivityDurationRange::class,\n FilterDefinition\\ActivityPlaylistIn::class,\n FilterDefinition\\ActivityProviderIn::class,\n FilterDefinition\\ActivityRecorded::class,\n FilterDefinition\\ActivityType::class,\n FilterDefinition\\CoachingFeedbackAverageScore::class,\n AutoScoreFilter::class,\n AiCallScoreFilter::class,\n FilterDefinition\\CoachingFeedbackCoachUserIn::class,\n FilterDefinition\\CrmFieldCollection::class,\n FilterDefinition\\CurrentStage::class,\n FilterDefinition\\Customer::class,\n FilterDefinition\\CustomerMonologueDuration::class,\n FilterDefinition\\CustomerQuestionCount::class,\n FilterDefinition\\DealAge::class,\n DealCloseDate::class,\n FilterDefinition\\DealValue::class,\n FilterDefinition\\EngagingQuestionCount::class,\n FilterDefinition\\ShowInternalExternalActivitiesFilter::class,\n FilterDefinition\\HasTranscription::class,\n FilterDefinition\\InsightfulQuestionCount::class,\n FilterDefinition\\LanguageFilterDefinition::class,\n FilterDefinition\\LoggedToCrm::class,\n FilterDefinition\\OrganiserGroupIn::class,\n FilterDefinition\\OrganiserUserIn::class,\n FilterDefinition\\PatienceRange::class,\n PlaybackTopicFilterDefinition::class,\n FilterDefinition\\ProviderFilterDefinition::class,\n FilterDefinition\\SortBy::class,\n FilterDefinition\\SpeechRate::class,\n FilterDefinition\\StageAtCallFilterDefinition::class,\n FilterDefinition\\TalkTimeRatio::class,\n FilterDefinition\\TeamMemberUserIn::class,\n FilterDefinition\\TranscriptionComposite::class,\n FilterDefinition\\UserMonologueDuration::class,\n FilterDefinition\\UserQuestionCount::class,\n FilterDefinition\\CommentCountRange::class,\n FilterDefinition\\HasPendingAiCrmNotes::class,\n ])\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all(),\n );\n }\n\n public function getOnDemandPageFilterSet(Criteria $criteria, User $consumer): FilterDefinitionCollection\n {\n return $this\n ->getOnDemandPageFilters()\n ->withCriteria($criteria)\n ->withConsumer($consumer)\n ->withRestrictions($consumer->getTeam());\n }\n\n /**\n * @return string[]\n */\n public function getArrayFilterKeys(User $consumer): array\n {\n return $this\n ->getOnDemandPageFilters()\n ->withConsumer($consumer)\n ->getPropertyTypes([FilterDefinitionCollection::PROPERTY_TYPE_ARRAY])\n ->keys()\n ->filter(static fn (string $key): bool => ! str_contains($key, '.'))\n ->values()\n ->all();\n }\n\n private function getTeamInsightsPageFilters(bool $isExport = false): FilterDefinitionCollection\n {\n $dateRangeFilterClass = $isExport\n ? FilterDefinition\\TeamInsights\\ConversationExport\\DateRangeFilter::class\n : FilterDefinition\\TeamInsights\\DateRangeFilter::class;\n\n return FilterDefinitionCollection::make(\n Collection::make([\n // special cases\n $dateRangeFilterClass,\n FilterDefinition\\TeamInsights\\Exists::class,\n\n // healthy restrictions\n RestrictTeam::class,\n RestrictUserGroupScope::class,\n RestrictActivityChannel::class,\n RestrictPublicActivitiesOnly::class,\n RestrictUserActive::class,\n\n // regular filters\n FilterDefinition\\ActivityChannel::class,\n FilterDefinition\\TeamInsights\\ActivityDurationRange::class,\n FilterDefinition\\ActivityPlaylistIn::class,\n FilterDefinition\\ActivityProviderIn::class,\n FilterDefinition\\TeamInsights\\ActivityRecorded::class,\n FilterDefinition\\ActivityType::class,\n FilterDefinition\\CoachingFeedbackAverageScore::class,\n AutoScoreFilter::class,\n AiCallScoreFilter::class,\n FilterDefinition\\CoachingFeedbackCoachUserIn::class,\n FilterDefinition\\CrmFieldCollection::class,\n FilterDefinition\\Customer::class,\n FilterDefinition\\CurrentStage::class,\n FilterDefinition\\CustomerMonologueDuration::class,\n FilterDefinition\\CustomerQuestionCount::class,\n FilterDefinition\\DealAge::class,\n DealCloseDate::class,\n FilterDefinition\\DealValue::class,\n FilterDefinition\\EngagingQuestionCount::class,\n FilterDefinition\\ShowInternalExternalActivitiesFilter::class,\n FilterDefinition\\InsightfulQuestionCount::class,\n FilterDefinition\\LanguageFilterDefinition::class,\n FilterDefinition\\LoggedToCrm::class,\n FilterDefinition\\TeamInsights\\UserInFilter::class,\n FilterDefinition\\TeamInsights\\UserGroupInFilter::class,\n FilterDefinition\\PatienceRange::class,\n PlaybackTopicFilterDefinition::class,\n FilterDefinition\\ProviderFilterDefinition::class,\n FilterDefinition\\SortBy::class,\n FilterDefinition\\SpeechRate::class,\n FilterDefinition\\StageAtCallFilterDefinition::class,\n FilterDefinition\\TalkTimeRatio::class,\n FilterDefinition\\TeamMemberUserIn::class,\n FilterDefinition\\TranscriptionComposite::class,\n FilterDefinition\\UserMonologueDuration::class,\n FilterDefinition\\UserQuestionCount::class,\n FilterDefinition\\CommentCountRange::class,\n // Relevant for topics in deals.\n ClosedDealsFilter::class,\n HasTopicTriggersFilterDefinition::class,\n TopicFilterDefinition::class,\n ])\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all(),\n );\n }\n\n private function getDealInsightsPageFilters(\n bool $useCreatedDate = false,\n bool $includeDealType = false,\n bool $includePipeline = false,\n ): FilterDefinitionCollection {\n if ($useCreatedDate) {\n $periodFilterClass = FilterDefinition\\DealInsights\\CreatedPeriodFilter::class;\n } else {\n $periodFilterClass = FilterDefinition\\DealInsights\\ClosingPeriodFilter::class;\n }\n\n $filterSet = [\n RestrictTeam::class,\n $periodFilterClass,\n FilterDefinition\\DealInsights\\UserInFilter::class,\n FilterDefinition\\DealInsights\\UserGroupInFilter::class,\n FilterDefinition\\DealInsights\\DealStageInFilter::class,\n FilterDefinition\\DealInsights\\DealNameFilter::class,\n ];\n\n if ($includePipeline) {\n $filterSet[] = FilterDefinition\\DealInsights\\DealPipelineInFilter::class;\n }\n\n if ($includeDealType) {\n $filterSet[] = FilterDefinition\\DealInsights\\DealTypeInFilter::class;\n }\n\n return FilterDefinitionCollection::make(\n Collection::make($filterSet)\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all(),\n );\n }\n\n public function getTeamInsightsPageFilterSet(\n Criteria $criteria,\n User $consumer,\n bool $isExport = false\n ): FilterDefinitionCollection {\n return $this\n ->getTeamInsightsPageFilters($isExport)\n ->withCriteria($criteria)\n ->withConsumer($consumer)\n ->withRestrictions($consumer->getTeam());\n }\n\n public function getDealInsightsPageFilterSet(\n Criteria $criteria,\n User $consumer\n ): FilterDefinitionCollection {\n $includeDealType = $this->shouldIncludeDealType($consumer);\n $includePipeline = $this->shouldIncludePipeline($consumer);\n $useCreatedDate = $this->shouldUseCreatedDate($consumer);\n\n return $this\n ->getDealInsightsPageFilters($useCreatedDate, $includeDealType, $includePipeline)\n ->withCriteria($criteria)\n ->withConsumer($consumer);\n }\n\n public function getTeamAiAutomationFilterSet(\n Criteria $criteria,\n User $consumer\n ): FilterDefinitionCollection {\n return $this\n ->getTeamAiAutomationPageFilterSet()\n ->withCriteria($criteria)\n ->withConsumer($consumer);\n }\n\n private function getTeamAiAutomationPageFilterSet(): FilterDefinitionCollection\n {\n $filterSet = [\n RestrictTeam::class,\n FilterDefinition\\DealInsights\\DealStageInFilter::class,\n ];\n\n return FilterDefinitionCollection::make(\n Collection::make($filterSet)\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all(),\n );\n }\n\n public function getHomepageFilterSet(Criteria $criteria, User $consumer): FilterDefinitionCollection\n {\n $filterDefinitionCollection = FilterDefinitionCollection::make(\n Collection::make([\n RestrictTeam::class,\n RestrictUserGroupScope::class,\n RestrictActivityChannel::class,\n RestrictUserActive::class,\n FilterDefinition\\Security\\PrivateMeetingsForCurrentUserOnly::class,\n FilterDefinition\\ActivityActualDate::class,\n FilterDefinition\\Customer::class,\n FilterDefinition\\ActivityChannel::class,\n FilterDefinition\\ActivityDurationRange::class,\n FilterDefinition\\ActivityProviderIn::class,\n FilterDefinition\\ActivityRecorded::class,\n FilterDefinition\\ActivityRecordingStopped::class,\n FilterDefinition\\ActivityScheduledDate::class,\n FilterDefinition\\ActivityStatusIn::class,\n FilterDefinition\\LoggedToCrm::class,\n FilterDefinition\\OrganiserUserIn::class,\n FilterDefinition\\OrganiserUserNotIn::class,\n FilterDefinition\\ProviderFilterDefinition::class,\n FilterDefinition\\SortBy::class,\n FilterDefinition\\UserGroupInOptionalFilter::class,\n FilterDefinition\\OnlyActiveUsers::class,\n ])\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all(),\n );\n $filterDefinitionCollection->withCriteria($criteria);\n $filterDefinitionCollection->withConsumer($consumer);\n\n return $filterDefinitionCollection;\n }\n\n public function getPartnerFilterSet(Criteria $criteria): FilterDefinitionCollection\n {\n $filterDefinitionCollection = FilterDefinitionCollection::make(\n Collection::make([\n RestrictActivityChannel::class,\n FilterDefinition\\OrganiserTeamIn::class,\n FilterDefinition\\ActivityUpdatedDate::class,\n FilterDefinition\\ActivityStatusIn::class,\n FilterDefinition\\SortBy::class,\n ])\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all()\n );\n $filterDefinitionCollection->withCriteria($criteria);\n\n return $filterDefinitionCollection;\n }\n\n private function shouldIncludeDealType(User $user): bool\n {\n $crmConfig = $user->getTeam()->getCrmConfiguration();\n $crmProviderName = $crmConfig->getProviderName();\n\n if (! array_key_exists($crmProviderName, Field::BUSINESS_TYPE_FIELDS)) {\n return false;\n }\n\n $layoutRepository = app(LayoutRepository::class);\n $layoutFields = $layoutRepository->getDealInsightLayoutFields($crmConfig);\n $dealTypeField = Field::BUSINESS_TYPE_FIELDS[$crmProviderName];\n\n if (! in_array($dealTypeField, $layoutFields)) {\n return false;\n }\n\n return true;\n }\n\n private function shouldIncludePipeline(User $user): bool\n {\n $crmConfig = $user->getTeam()->getCrmConfiguration();\n $crmProviderName = $crmConfig->getProviderName();\n\n if (in_array($crmProviderName, [\n Configuration::PROVIDER_SALESFORCE,\n Configuration::PROVIDER_INTEGRATION_APP,\n ])) {\n return false;\n }\n\n return true;\n }\n\n private function shouldUseCreatedDate(User $user): bool\n {\n $teamService = app(TeamService::class);\n\n return ! $teamService->useDealInsightsClosedDateFilter($user->getTeam());\n }\n}","depth":4,"bounds":{"left":0.32617188,"top":0.10625,"width":0.34101564,"height":0.89375},"value":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Component\\ActivitySearch\\Service;\n\nuse Illuminate\\Container\\Container;\nuse Illuminate\\Support\\Collection;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\AiCallScoreFilter;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\AutoScoreFilter;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\ClosedDealsFilter;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\DealCloseDate;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\HasTopicTriggersFilterDefinition;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\PlaybackTopicFilterDefinition;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\Security\\RestrictActivityChannel;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\Security\\RestrictPublicActivitiesOnly;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\Security\\RestrictTeam;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\Security\\RestrictUserActive;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\Security\\RestrictUserGroupScope;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\TeamInsights\\TopicFilterDefinition;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinitionCollection;\nuse Jiminny\\Models\\Crm\\Field;\nuse Jiminny\\Models\\User;\nuse Jiminny\\Models\\Crm\\Configuration;\nuse Jiminny\\Repositories\\Crm\\LayoutRepository;\nuse Jiminny\\Services\\TeamService;\nuse Jiminny\\VO\\Repository\\OnDemandActivitySearch\\Criteria;\n\nclass ActivitySearch\n{\n private Container $container;\n\n public function __construct(Container $container)\n {\n $this->container = $container;\n }\n\n public function getOnDemandPageFilters(): FilterDefinitionCollection\n {\n return FilterDefinitionCollection::make(\n Collection::make([\n // special case filters\n FilterDefinition\\ActivityStatusIn::class,\n FilterDefinition\\ActivityUpdatedDate::class,\n FilterDefinition\\ActivityRecordingStopped::class,\n FilterDefinition\\ActivityFilter::class,\n FilterDefinition\\ExternalId::class,\n FilterDefinition\\NudgeRunId::class,\n FilterDefinition\\ParticipantUserIn::class,\n FilterDefinition\\PartnerFilterDefinition::class,\n\n // healthy restrictions\n RestrictTeam::class,\n RestrictUserGroupScope::class,\n RestrictActivityChannel::class,\n RestrictUserActive::class,\n FilterDefinition\\Security\\PrivateMeetingsForCurrentUserOnly::class,\n\n // regular filters\n FilterDefinition\\ActivityActualDate::class,\n FilterDefinition\\ActivityChannel::class,\n FilterDefinition\\ActivityDurationRange::class,\n FilterDefinition\\ActivityPlaylistIn::class,\n FilterDefinition\\ActivityProviderIn::class,\n FilterDefinition\\ActivityRecorded::class,\n FilterDefinition\\ActivityType::class,\n FilterDefinition\\CoachingFeedbackAverageScore::class,\n AutoScoreFilter::class,\n AiCallScoreFilter::class,\n FilterDefinition\\CoachingFeedbackCoachUserIn::class,\n FilterDefinition\\CrmFieldCollection::class,\n FilterDefinition\\CurrentStage::class,\n FilterDefinition\\Customer::class,\n FilterDefinition\\CustomerMonologueDuration::class,\n FilterDefinition\\CustomerQuestionCount::class,\n FilterDefinition\\DealAge::class,\n DealCloseDate::class,\n FilterDefinition\\DealValue::class,\n FilterDefinition\\EngagingQuestionCount::class,\n FilterDefinition\\ShowInternalExternalActivitiesFilter::class,\n FilterDefinition\\HasTranscription::class,\n FilterDefinition\\InsightfulQuestionCount::class,\n FilterDefinition\\LanguageFilterDefinition::class,\n FilterDefinition\\LoggedToCrm::class,\n FilterDefinition\\OrganiserGroupIn::class,\n FilterDefinition\\OrganiserUserIn::class,\n FilterDefinition\\PatienceRange::class,\n PlaybackTopicFilterDefinition::class,\n FilterDefinition\\ProviderFilterDefinition::class,\n FilterDefinition\\SortBy::class,\n FilterDefinition\\SpeechRate::class,\n FilterDefinition\\StageAtCallFilterDefinition::class,\n FilterDefinition\\TalkTimeRatio::class,\n FilterDefinition\\TeamMemberUserIn::class,\n FilterDefinition\\TranscriptionComposite::class,\n FilterDefinition\\UserMonologueDuration::class,\n FilterDefinition\\UserQuestionCount::class,\n FilterDefinition\\CommentCountRange::class,\n FilterDefinition\\HasPendingAiCrmNotes::class,\n ])\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all(),\n );\n }\n\n public function getOnDemandPageFilterSet(Criteria $criteria, User $consumer): FilterDefinitionCollection\n {\n return $this\n ->getOnDemandPageFilters()\n ->withCriteria($criteria)\n ->withConsumer($consumer)\n ->withRestrictions($consumer->getTeam());\n }\n\n /**\n * @return string[]\n */\n public function getArrayFilterKeys(User $consumer): array\n {\n return $this\n ->getOnDemandPageFilters()\n ->withConsumer($consumer)\n ->getPropertyTypes([FilterDefinitionCollection::PROPERTY_TYPE_ARRAY])\n ->keys()\n ->filter(static fn (string $key): bool => ! str_contains($key, '.'))\n ->values()\n ->all();\n }\n\n private function getTeamInsightsPageFilters(bool $isExport = false): FilterDefinitionCollection\n {\n $dateRangeFilterClass = $isExport\n ? FilterDefinition\\TeamInsights\\ConversationExport\\DateRangeFilter::class\n : FilterDefinition\\TeamInsights\\DateRangeFilter::class;\n\n return FilterDefinitionCollection::make(\n Collection::make([\n // special cases\n $dateRangeFilterClass,\n FilterDefinition\\TeamInsights\\Exists::class,\n\n // healthy restrictions\n RestrictTeam::class,\n RestrictUserGroupScope::class,\n RestrictActivityChannel::class,\n RestrictPublicActivitiesOnly::class,\n RestrictUserActive::class,\n\n // regular filters\n FilterDefinition\\ActivityChannel::class,\n FilterDefinition\\TeamInsights\\ActivityDurationRange::class,\n FilterDefinition\\ActivityPlaylistIn::class,\n FilterDefinition\\ActivityProviderIn::class,\n FilterDefinition\\TeamInsights\\ActivityRecorded::class,\n FilterDefinition\\ActivityType::class,\n FilterDefinition\\CoachingFeedbackAverageScore::class,\n AutoScoreFilter::class,\n AiCallScoreFilter::class,\n FilterDefinition\\CoachingFeedbackCoachUserIn::class,\n FilterDefinition\\CrmFieldCollection::class,\n FilterDefinition\\Customer::class,\n FilterDefinition\\CurrentStage::class,\n FilterDefinition\\CustomerMonologueDuration::class,\n FilterDefinition\\CustomerQuestionCount::class,\n FilterDefinition\\DealAge::class,\n DealCloseDate::class,\n FilterDefinition\\DealValue::class,\n FilterDefinition\\EngagingQuestionCount::class,\n FilterDefinition\\ShowInternalExternalActivitiesFilter::class,\n FilterDefinition\\InsightfulQuestionCount::class,\n FilterDefinition\\LanguageFilterDefinition::class,\n FilterDefinition\\LoggedToCrm::class,\n FilterDefinition\\TeamInsights\\UserInFilter::class,\n FilterDefinition\\TeamInsights\\UserGroupInFilter::class,\n FilterDefinition\\PatienceRange::class,\n PlaybackTopicFilterDefinition::class,\n FilterDefinition\\ProviderFilterDefinition::class,\n FilterDefinition\\SortBy::class,\n FilterDefinition\\SpeechRate::class,\n FilterDefinition\\StageAtCallFilterDefinition::class,\n FilterDefinition\\TalkTimeRatio::class,\n FilterDefinition\\TeamMemberUserIn::class,\n FilterDefinition\\TranscriptionComposite::class,\n FilterDefinition\\UserMonologueDuration::class,\n FilterDefinition\\UserQuestionCount::class,\n FilterDefinition\\CommentCountRange::class,\n // Relevant for topics in deals.\n ClosedDealsFilter::class,\n HasTopicTriggersFilterDefinition::class,\n TopicFilterDefinition::class,\n ])\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all(),\n );\n }\n\n private function getDealInsightsPageFilters(\n bool $useCreatedDate = false,\n bool $includeDealType = false,\n bool $includePipeline = false,\n ): FilterDefinitionCollection {\n if ($useCreatedDate) {\n $periodFilterClass = FilterDefinition\\DealInsights\\CreatedPeriodFilter::class;\n } else {\n $periodFilterClass = FilterDefinition\\DealInsights\\ClosingPeriodFilter::class;\n }\n\n $filterSet = [\n RestrictTeam::class,\n $periodFilterClass,\n FilterDefinition\\DealInsights\\UserInFilter::class,\n FilterDefinition\\DealInsights\\UserGroupInFilter::class,\n FilterDefinition\\DealInsights\\DealStageInFilter::class,\n FilterDefinition\\DealInsights\\DealNameFilter::class,\n ];\n\n if ($includePipeline) {\n $filterSet[] = FilterDefinition\\DealInsights\\DealPipelineInFilter::class;\n }\n\n if ($includeDealType) {\n $filterSet[] = FilterDefinition\\DealInsights\\DealTypeInFilter::class;\n }\n\n return FilterDefinitionCollection::make(\n Collection::make($filterSet)\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all(),\n );\n }\n\n public function getTeamInsightsPageFilterSet(\n Criteria $criteria,\n User $consumer,\n bool $isExport = false\n ): FilterDefinitionCollection {\n return $this\n ->getTeamInsightsPageFilters($isExport)\n ->withCriteria($criteria)\n ->withConsumer($consumer)\n ->withRestrictions($consumer->getTeam());\n }\n\n public function getDealInsightsPageFilterSet(\n Criteria $criteria,\n User $consumer\n ): FilterDefinitionCollection {\n $includeDealType = $this->shouldIncludeDealType($consumer);\n $includePipeline = $this->shouldIncludePipeline($consumer);\n $useCreatedDate = $this->shouldUseCreatedDate($consumer);\n\n return $this\n ->getDealInsightsPageFilters($useCreatedDate, $includeDealType, $includePipeline)\n ->withCriteria($criteria)\n ->withConsumer($consumer);\n }\n\n public function getTeamAiAutomationFilterSet(\n Criteria $criteria,\n User $consumer\n ): FilterDefinitionCollection {\n return $this\n ->getTeamAiAutomationPageFilterSet()\n ->withCriteria($criteria)\n ->withConsumer($consumer);\n }\n\n private function getTeamAiAutomationPageFilterSet(): FilterDefinitionCollection\n {\n $filterSet = [\n RestrictTeam::class,\n FilterDefinition\\DealInsights\\DealStageInFilter::class,\n ];\n\n return FilterDefinitionCollection::make(\n Collection::make($filterSet)\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all(),\n );\n }\n\n public function getHomepageFilterSet(Criteria $criteria, User $consumer): FilterDefinitionCollection\n {\n $filterDefinitionCollection = FilterDefinitionCollection::make(\n Collection::make([\n RestrictTeam::class,\n RestrictUserGroupScope::class,\n RestrictActivityChannel::class,\n RestrictUserActive::class,\n FilterDefinition\\Security\\PrivateMeetingsForCurrentUserOnly::class,\n FilterDefinition\\ActivityActualDate::class,\n FilterDefinition\\Customer::class,\n FilterDefinition\\ActivityChannel::class,\n FilterDefinition\\ActivityDurationRange::class,\n FilterDefinition\\ActivityProviderIn::class,\n FilterDefinition\\ActivityRecorded::class,\n FilterDefinition\\ActivityRecordingStopped::class,\n FilterDefinition\\ActivityScheduledDate::class,\n FilterDefinition\\ActivityStatusIn::class,\n FilterDefinition\\LoggedToCrm::class,\n FilterDefinition\\OrganiserUserIn::class,\n FilterDefinition\\OrganiserUserNotIn::class,\n FilterDefinition\\ProviderFilterDefinition::class,\n FilterDefinition\\SortBy::class,\n FilterDefinition\\UserGroupInOptionalFilter::class,\n FilterDefinition\\OnlyActiveUsers::class,\n ])\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all(),\n );\n $filterDefinitionCollection->withCriteria($criteria);\n $filterDefinitionCollection->withConsumer($consumer);\n\n return $filterDefinitionCollection;\n }\n\n public function getPartnerFilterSet(Criteria $criteria): FilterDefinitionCollection\n {\n $filterDefinitionCollection = FilterDefinitionCollection::make(\n Collection::make([\n RestrictActivityChannel::class,\n FilterDefinition\\OrganiserTeamIn::class,\n FilterDefinition\\ActivityUpdatedDate::class,\n FilterDefinition\\ActivityStatusIn::class,\n FilterDefinition\\SortBy::class,\n ])\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all()\n );\n $filterDefinitionCollection->withCriteria($criteria);\n\n return $filterDefinitionCollection;\n }\n\n private function shouldIncludeDealType(User $user): bool\n {\n $crmConfig = $user->getTeam()->getCrmConfiguration();\n $crmProviderName = $crmConfig->getProviderName();\n\n if (! array_key_exists($crmProviderName, Field::BUSINESS_TYPE_FIELDS)) {\n return false;\n }\n\n $layoutRepository = app(LayoutRepository::class);\n $layoutFields = $layoutRepository->getDealInsightLayoutFields($crmConfig);\n $dealTypeField = Field::BUSINESS_TYPE_FIELDS[$crmProviderName];\n\n if (! in_array($dealTypeField, $layoutFields)) {\n return false;\n }\n\n return true;\n }\n\n private function shouldIncludePipeline(User $user): bool\n {\n $crmConfig = $user->getTeam()->getCrmConfiguration();\n $crmProviderName = $crmConfig->getProviderName();\n\n if (in_array($crmProviderName, [\n Configuration::PROVIDER_SALESFORCE,\n Configuration::PROVIDER_INTEGRATION_APP,\n ])) {\n return false;\n }\n\n return true;\n }\n\n private function shouldUseCreatedDate(User $user): bool\n {\n $teamService = app(TeamService::class);\n\n return ! $teamService->useDealInsightsClosedDateFilter($user->getTeam());\n }\n}","role_description":"text entry area","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.049609374,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"15","depth":4,"bounds":{"left":0.2589844,"top":0.28125,"width":0.011328125,"height":0.013194445},"role_description":"text"},{"role":"AXStaticText","text":"4","depth":4,"bounds":{"left":0.27265626,"top":0.28125,"width":0.009375,"height":0.013194445},"role_description":"text"},{"role":"AXButton","text":"Previous Highlighted Error","depth":4,"bounds":{"left":0.28398436,"top":0.27986112,"width":0.00859375,"height":0.015972223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Next Highlighted Error","depth":4,"bounds":{"left":0.29257813,"top":0.27986112,"width":0.008203125,"height":0.015972223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Repositories;\n\nuse Carbon\\CarbonImmutable;\nuse Illuminate\\Database\\Eloquent\\Builder;\nuse Illuminate\\Support\\Carbon;\nuse Illuminate\\Database\\Eloquent\\Collection;\nuse Illuminate\\Pagination\\LengthAwarePaginator;\nuse Illuminate\\Support\\Facades\\DB;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\AutomatedReportResult;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Models\\User;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\ReportSort;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\ReportSortDirection;\n\nclass AutomatedReportsRepository\n{\n /**\n * Create a new automated report\n *\n * @param array $data\n *\n * @return AutomatedReport\n */\n public function create(array $data): AutomatedReport\n {\n return AutomatedReport::create($data);\n }\n\n /**\n * Find an automated report by UUID\n *\n * @param string $uuid\n *\n * @return AutomatedReport|null\n */\n public function findByUuid(string $uuid): ?AutomatedReport\n {\n return AutomatedReport::where('uuid', AutomatedReport::toOptimized($uuid))->first();\n }\n\n public function findByIdOrUuid(string $idOrUuid): ?AutomatedReport\n {\n if (is_numeric($idOrUuid)) {\n return AutomatedReport::find((int) $idOrUuid);\n }\n\n return AutomatedReport::where('uuid', AutomatedReport::toOptimized($idOrUuid))->first();\n }\n\n /**\n * Retrieve all standard (non-Ask Jiminny) automated reports.\n *\n * @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.\n * @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.\n *\n * @return Collection<AutomatedReport>\n */\n public function getAllStandardReports(\n string $sortColumn = 'created_at',\n string $sortDirection = 'desc'\n ): Collection {\n return $this->buildSortedQuery($sortColumn, $sortDirection)\n ->whereNot('type', AutomatedReportsService::TYPE_ASK_JIMINNY)\n ->get();\n }\n\n /**\n * Retrieve all Ask Jiminny reports created by the given user.\n *\n * @param User $user The user whose reports to retrieve.\n * @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.\n * @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.\n *\n * @return Collection<AutomatedReport>\n */\n public function getAskJiminnyReportsByUser(\n User $user,\n string $sortColumn = 'created_at',\n string $sortDirection = 'desc'\n ): Collection {\n return $this->buildSortedQuery($sortColumn, $sortDirection)\n ->where('type', AutomatedReportsService::TYPE_ASK_JIMINNY)\n ->where('created_by', $user->getId())\n ->get();\n }\n\n private function buildSortedQuery(string $sortColumn, string $sortDirection): \\Illuminate\\Database\\Eloquent\\Builder\n {\n $allowedColumns = ['created_by', 'created_at'];\n if (! in_array($sortColumn, $allowedColumns)) {\n $sortColumn = 'created_at';\n }\n\n $sortDirection = strtolower($sortDirection) === 'asc' ? 'asc' : 'desc';\n\n $query = AutomatedReport::query()->with(['creator', 'team']);\n\n if ($sortColumn === 'created_by') {\n $query->leftJoin('users', 'users.id', '=', 'automated_reports.created_by')\n ->orderByRaw(\"users.name COLLATE utf8mb4_unicode_ci {$sortDirection}\")\n ->select('automated_reports.*');\n } else {\n $query->orderBy($sortColumn, $sortDirection);\n }\n\n return $query;\n }\n\n /**\n * Get all active and enabled reports with active teams for the specified frequency.\n *\n * @param string $frequency\n *\n * @return Collection<AutomatedReport>\n */\n public function getActiveReportsByFrequency(string $frequency): Collection\n {\n return AutomatedReport::where('automated_reports.status', true)\n ->where('automated_reports.frequency', $frequency)\n ->join('teams', 'automated_reports.team_id', '=', 'teams.id')\n ->where('teams.status', Team::STATUS_ACTIVE)\n ->where(function ($query) {\n $query->whereNull('automated_reports.expires_at')\n ->orWhere('automated_reports.expires_at', '>=', now()->toDateString());\n })\n ->select('automated_reports.*')\n ->get();\n }\n\n /**\n * Update an automated report\n *\n * @param AutomatedReport $report\n * @param array $data\n *\n * @return AutomatedReport\n */\n public function update(AutomatedReport $report, array $data): AutomatedReport\n {\n $report->update($data);\n\n return $report;\n }\n\n /**\n * Create a new automated report result.\n *\n * @param array $data The data to create the automated report result with.\n *\n * @return AutomatedReportResult The newly created automated report result.\n */\n public function createResult(array $data): AutomatedReportResult\n {\n return AutomatedReportResult::create($data);\n }\n\n /**\n * Find an automated report result by UUID.\n *\n * @param string $uuid The UUID to find the automated report result with.\n *\n * @return AutomatedReportResult|null The automated report result if found, otherwise null.\n */\n public function findResultByUuid(string $uuid): ?AutomatedReportResult\n {\n return AutomatedReportResult::where('uuid', AutomatedReportResult::toOptimized($uuid))->first();\n }\n\n public function findResultByUuidForUser(string $uuid, User $user): ?AutomatedReportResult\n {\n return AutomatedReportResult::query()\n ->where('uuid', AutomatedReportResult::toOptimized($uuid))\n ->whereHas('report', static function ($query) use ($user): void {\n $query->where('team_id', $user->getTeamId())\n ->where('created_by', $user->getId());\n })\n ->first();\n }\n\n public function findChildResult(AutomatedReportResult $result, string $type): ?AutomatedReportResult\n {\n return AutomatedReportResult::query()\n ->where('parent_id', $result->getId())\n ->where('media_type', $type)\n ->first();\n }\n\n public function getGeneratedNotSentResults(): Collection\n {\n return AutomatedReportResult::query()\n ->whereNotNull('generated_at')\n ->whereNull('sent_at')\n ->where('status', AutomatedReportResult::STATUS_GENERATED)\n ->whereHas('report')\n ->with('report')\n ->get();\n }\n\n public function getPaginatedUserReports(\n User $user,\n ReportSort $sort,\n ReportSortDirection $sortDirection,\n int $resultsPerPage,\n int $page,\n ?Carbon $fromDate,\n ?Carbon $toDate,\n array $teamIds,\n array $reportTypes,\n ?string $name,\n ): LengthAwarePaginator {\n $query = AutomatedReportResult::query()\n ->whereNotNull('automated_report_results.generated_at')\n ->join('automated_reports', 'automated_report_results.report_id', '=', 'automated_reports.id')\n ->where('automated_reports.team_id', $user->getTeamId())\n ->whereJsonContains('automated_reports.recipients->users', $user->getId())\n ->orderByRaw(\"$sort->value COLLATE utf8mb4_unicode_ci {$sortDirection->value}\")\n ->select('automated_report_results.*')\n ->with('report.team');\n\n if ($fromDate !== null && $toDate !== null) {\n $query->whereBetween('generated_at', [$fromDate, $toDate]);\n }\n\n if (! empty($teamIds)) {\n $query->where(function ($q) use ($teamIds) {\n foreach ($teamIds as $id) {\n $q->orWhereJsonContains('automated_reports.groups', $id);\n }\n });\n }\n\n if (! empty($reportTypes)) {\n $query->whereIn('automated_reports.type', $reportTypes);\n }\n\n if (! empty($name)) {\n $query->whereLike('name', \"%$name%\");\n }\n\n return $query->paginate($resultsPerPage, ['*'], 'page', $page);\n }\n\n public function countUserReports(User $user): int\n {\n return AutomatedReportResult::query()\n ->whereNotNull('generated_at')\n ->whereNotNull('sent_at')\n ->whereHas('report', function ($q) use ($user) {\n $q->where('team_id', $user->getTeamId())\n ->whereJsonContains('recipients->users', $user->getId());\n })\n ->count();\n }\n\n /**\n * Get report IDs for a specific team\n *\n * @param Team $team\n *\n * @return \\Illuminate\\Support\\Collection\n */\n public function getReportIdsByTeam(Team $team): \\Illuminate\\Support\\Collection\n {\n return AutomatedReport::where('team_id', $team->getId())->pluck('id');\n }\n\n /**\n * Get all reports for a specific team\n *\n * @param Team $team\n *\n * @return Collection\n */\n public function getReportsByTeam(Team $team): Collection\n {\n return AutomatedReport::where('team_id', $team->getId())->get();\n }\n\n /**\n * Get all report results for a specific report\n *\n * @param AutomatedReport $report\n *\n * @return Collection\n */\n public function getResultsByReport(AutomatedReport $report): Collection\n {\n return $this->getResultsByReportQuery($report)->get();\n }\n\n public function getResultsByReportQuery(AutomatedReport $report): Builder\n {\n return AutomatedReportResult::where('report_id', $report->getId());\n }\n\n public function getReportResultsQueryForRetention(Team $team, CarbonImmutable $retentionDate): Builder\n {\n $reportIds = $this->getReportIdsByTeam($team);\n\n return AutomatedReportResult::query()->whereIn('report_id', $reportIds)\n ->whereRaw('IFNULL(generated_at, created_at) <= ?', [$retentionDate]);\n }\n\n /**\n * @param int|null $teamId Optional team ID to filter results\n *\n * @return \\Illuminate\\Support\\Collection<int, int> Collection of team IDs\n */\n public function getTeamIdsWithReportsResults(?int $teamId = null): \\Illuminate\\Support\\Collection\n {\n $query = DB::table('automated_reports')\n ->join('teams', 'automated_reports.team_id', '=', 'teams.id')\n ->select('teams.id')\n ->distinct();\n\n if ($teamId !== null) {\n $query->where('teams.id', $teamId);\n }\n\n return $query->pluck('teams.id');\n }\n}","depth":4,"bounds":{"left":0.15234375,"top":0.084027775,"width":0.39882812,"height":0.91597223},"value":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Repositories;\n\nuse Carbon\\CarbonImmutable;\nuse Illuminate\\Database\\Eloquent\\Builder;\nuse Illuminate\\Support\\Carbon;\nuse Illuminate\\Database\\Eloquent\\Collection;\nuse Illuminate\\Pagination\\LengthAwarePaginator;\nuse Illuminate\\Support\\Facades\\DB;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\AutomatedReportResult;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Models\\User;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\ReportSort;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\ReportSortDirection;\n\nclass AutomatedReportsRepository\n{\n /**\n * Create a new automated report\n *\n * @param array $data\n *\n * @return AutomatedReport\n */\n public function create(array $data): AutomatedReport\n {\n return AutomatedReport::create($data);\n }\n\n /**\n * Find an automated report by UUID\n *\n * @param string $uuid\n *\n * @return AutomatedReport|null\n */\n public function findByUuid(string $uuid): ?AutomatedReport\n {\n return AutomatedReport::where('uuid', AutomatedReport::toOptimized($uuid))->first();\n }\n\n public function findByIdOrUuid(string $idOrUuid): ?AutomatedReport\n {\n if (is_numeric($idOrUuid)) {\n return AutomatedReport::find((int) $idOrUuid);\n }\n\n return AutomatedReport::where('uuid', AutomatedReport::toOptimized($idOrUuid))->first();\n }\n\n /**\n * Retrieve all standard (non-Ask Jiminny) automated reports.\n *\n * @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.\n * @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.\n *\n * @return Collection<AutomatedReport>\n */\n public function getAllStandardReports(\n string $sortColumn = 'created_at',\n string $sortDirection = 'desc'\n ): Collection {\n return $this->buildSortedQuery($sortColumn, $sortDirection)\n ->whereNot('type', AutomatedReportsService::TYPE_ASK_JIMINNY)\n ->get();\n }\n\n /**\n * Retrieve all Ask Jiminny reports created by the given user.\n *\n * @param User $user The user whose reports to retrieve.\n * @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.\n * @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.\n *\n * @return Collection<AutomatedReport>\n */\n public function getAskJiminnyReportsByUser(\n User $user,\n string $sortColumn = 'created_at',\n string $sortDirection = 'desc'\n ): Collection {\n return $this->buildSortedQuery($sortColumn, $sortDirection)\n ->where('type', AutomatedReportsService::TYPE_ASK_JIMINNY)\n ->where('created_by', $user->getId())\n ->get();\n }\n\n private function buildSortedQuery(string $sortColumn, string $sortDirection): \\Illuminate\\Database\\Eloquent\\Builder\n {\n $allowedColumns = ['created_by', 'created_at'];\n if (! in_array($sortColumn, $allowedColumns)) {\n $sortColumn = 'created_at';\n }\n\n $sortDirection = strtolower($sortDirection) === 'asc' ? 'asc' : 'desc';\n\n $query = AutomatedReport::query()->with(['creator', 'team']);\n\n if ($sortColumn === 'created_by') {\n $query->leftJoin('users', 'users.id', '=', 'automated_reports.created_by')\n ->orderByRaw(\"users.name COLLATE utf8mb4_unicode_ci {$sortDirection}\")\n ->select('automated_reports.*');\n } else {\n $query->orderBy($sortColumn, $sortDirection);\n }\n\n return $query;\n }\n\n /**\n * Get all active and enabled reports with active teams for the specified frequency.\n *\n * @param string $frequency\n *\n * @return Collection<AutomatedReport>\n */\n public function getActiveReportsByFrequency(string $frequency): Collection\n {\n return AutomatedReport::where('automated_reports.status', true)\n ->where('automated_reports.frequency', $frequency)\n ->join('teams', 'automated_reports.team_id', '=', 'teams.id')\n ->where('teams.status', Team::STATUS_ACTIVE)\n ->where(function ($query) {\n $query->whereNull('automated_reports.expires_at')\n ->orWhere('automated_reports.expires_at', '>=', now()->toDateString());\n })\n ->select('automated_reports.*')\n ->get();\n }\n\n /**\n * Update an automated report\n *\n * @param AutomatedReport $report\n * @param array $data\n *\n * @return AutomatedReport\n */\n public function update(AutomatedReport $report, array $data): AutomatedReport\n {\n $report->update($data);\n\n return $report;\n }\n\n /**\n * Create a new automated report result.\n *\n * @param array $data The data to create the automated report result with.\n *\n * @return AutomatedReportResult The newly created automated report result.\n */\n public function createResult(array $data): AutomatedReportResult\n {\n return AutomatedReportResult::create($data);\n }\n\n /**\n * Find an automated report result by UUID.\n *\n * @param string $uuid The UUID to find the automated report result with.\n *\n * @return AutomatedReportResult|null The automated report result if found, otherwise null.\n */\n public function findResultByUuid(string $uuid): ?AutomatedReportResult\n {\n return AutomatedReportResult::where('uuid', AutomatedReportResult::toOptimized($uuid))->first();\n }\n\n public function findResultByUuidForUser(string $uuid, User $user): ?AutomatedReportResult\n {\n return AutomatedReportResult::query()\n ->where('uuid', AutomatedReportResult::toOptimized($uuid))\n ->whereHas('report', static function ($query) use ($user): void {\n $query->where('team_id', $user->getTeamId())\n ->where('created_by', $user->getId());\n })\n ->first();\n }\n\n public function findChildResult(AutomatedReportResult $result, string $type): ?AutomatedReportResult\n {\n return AutomatedReportResult::query()\n ->where('parent_id', $result->getId())\n ->where('media_type', $type)\n ->first();\n }\n\n public function getGeneratedNotSentResults(): Collection\n {\n return AutomatedReportResult::query()\n ->whereNotNull('generated_at')\n ->whereNull('sent_at')\n ->where('status', AutomatedReportResult::STATUS_GENERATED)\n ->whereHas('report')\n ->with('report')\n ->get();\n }\n\n public function getPaginatedUserReports(\n User $user,\n ReportSort $sort,\n ReportSortDirection $sortDirection,\n int $resultsPerPage,\n int $page,\n ?Carbon $fromDate,\n ?Carbon $toDate,\n array $teamIds,\n array $reportTypes,\n ?string $name,\n ): LengthAwarePaginator {\n $query = AutomatedReportResult::query()\n ->whereNotNull('automated_report_results.generated_at')\n ->join('automated_reports', 'automated_report_results.report_id', '=', 'automated_reports.id')\n ->where('automated_reports.team_id', $user->getTeamId())\n ->whereJsonContains('automated_reports.recipients->users', $user->getId())\n ->orderByRaw(\"$sort->value COLLATE utf8mb4_unicode_ci {$sortDirection->value}\")\n ->select('automated_report_results.*')\n ->with('report.team');\n\n if ($fromDate !== null && $toDate !== null) {\n $query->whereBetween('generated_at', [$fromDate, $toDate]);\n }\n\n if (! empty($teamIds)) {\n $query->where(function ($q) use ($teamIds) {\n foreach ($teamIds as $id) {\n $q->orWhereJsonContains('automated_reports.groups', $id);\n }\n });\n }\n\n if (! empty($reportTypes)) {\n $query->whereIn('automated_reports.type', $reportTypes);\n }\n\n if (! empty($name)) {\n $query->whereLike('name', \"%$name%\");\n }\n\n return $query->paginate($resultsPerPage, ['*'], 'page', $page);\n }\n\n public function countUserReports(User $user): int\n {\n return AutomatedReportResult::query()\n ->whereNotNull('generated_at')\n ->whereNotNull('sent_at')\n ->whereHas('report', function ($q) use ($user) {\n $q->where('team_id', $user->getTeamId())\n ->whereJsonContains('recipients->users', $user->getId());\n })\n ->count();\n }\n\n /**\n * Get report IDs for a specific team\n *\n * @param Team $team\n *\n * @return \\Illuminate\\Support\\Collection\n */\n public function getReportIdsByTeam(Team $team): \\Illuminate\\Support\\Collection\n {\n return AutomatedReport::where('team_id', $team->getId())->pluck('id');\n }\n\n /**\n * Get all reports for a specific team\n *\n * @param Team $team\n *\n * @return Collection\n */\n public function getReportsByTeam(Team $team): Collection\n {\n return AutomatedReport::where('team_id', $team->getId())->get();\n }\n\n /**\n * Get all report results for a specific report\n *\n * @param AutomatedReport $report\n *\n * @return Collection\n */\n public function getResultsByReport(AutomatedReport $report): Collection\n {\n return $this->getResultsByReportQuery($report)->get();\n }\n\n public function getResultsByReportQuery(AutomatedReport $report): Builder\n {\n return AutomatedReportResult::where('report_id', $report->getId());\n }\n\n public function getReportResultsQueryForRetention(Team $team, CarbonImmutable $retentionDate): Builder\n {\n $reportIds = $this->getReportIdsByTeam($team);\n\n return AutomatedReportResult::query()->whereIn('report_id', $reportIds)\n ->whereRaw('IFNULL(generated_at, created_at) <= ?', [$retentionDate]);\n }\n\n /**\n * @param int|null $teamId Optional team ID to filter results\n *\n * @return \\Illuminate\\Support\\Collection<int, int> Collection of team IDs\n */\n public function getTeamIdsWithReportsResults(?int $teamId = null): \\Illuminate\\Support\\Collection\n {\n $query = DB::table('automated_reports')\n ->join('teams', 'automated_reports.team_id', '=', 'teams.id')\n ->select('teams.id')\n ->distinct();\n\n if ($teamId !== null) {\n $query->where('teams.id', $teamId);\n }\n\n return $query->pluck('teams.id');\n }\n}","role_description":"text entry area","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Project","depth":3,"role_description":"text"},{"role":"AXButton","text":"Project","depth":3,"bounds":{"left":0.0140625,"top":0.041666668,"width":0.028515626,"height":0.021527778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"New File or Directory…","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Expand Selected","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Collapse All","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Options","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.23320313,"top":1.0,"width":0.01015625,"height":0.0},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"app ~/jiminny/app","depth":6,"role_description":"text"},{"role":"AXStaticText","text":".circleci","depth":7,"role_description":"text"},{"role":"AXStaticText","text":".cursor","depth":7,"role_description":"text"},{"role":"AXStaticText","text":".github","depth":7,"role_description":"text"},{"role":"AXStaticText","text":".sonarlint","depth":7,"role_description":"text"},{"role":"AXStaticText","text":".vscode","depth":7,"role_description":"text"},{"role":"AXStaticText","text":".windsurf","depth":7,"role_description":"text"},{"role":"AXStaticText","text":"app, sources root","depth":7,"bounds":{"left":0.03203125,"top":0.0,"width":0.01875,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"Actions","depth":8,"bounds":{"left":0.039453126,"top":0.0,"width":0.027734375,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"Component","depth":8,"bounds":{"left":0.039453126,"top":0.0,"width":0.0375,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"Acl, folder","depth":9,"bounds":{"left":0.046875,"top":0.0,"width":0.0171875,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"ActionItems, folder","depth":9,"bounds":{"left":0.046875,"top":0.0,"width":0.03828125,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"Activity, folder","depth":9,"bounds":{"left":0.046875,"top":0.0,"width":0.027734375,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"ActivityAnalytics, folder","depth":9,"bounds":{"left":0.046875,"top":0.0020833334,"width":0.049609374,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"ActivitySearch, folder","depth":9,"bounds":{"left":0.046875,"top":0.017361112,"width":0.04453125,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"EventSubscriber, folder","depth":10,"bounds":{"left":0.054296874,"top":0.03263889,"width":0.04921875,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"FilterDefinition, folder","depth":10,"bounds":{"left":0.054296874,"top":0.047916666,"width":0.04453125,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"Service","depth":10,"bounds":{"left":0.054296874,"top":0.063194446,"width":0.02734375,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"ActivityApiSearch.php, class","depth":11,"bounds":{"left":0.06171875,"top":0.07847222,"width":0.06289063,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"ActivitySearch.php, class","depth":11,"bounds":{"left":0.06171875,"top":0.09375,"width":0.055078126,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"UserOptionsByGroup.php, class","depth":11,"bounds":{"left":0.06171875,"top":0.10902778,"width":0.07109375,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"AbstractStageFilterDefinition.php, abstract class","depth":10,"bounds":{"left":0.054296874,"top":0.124305554,"width":0.08945312,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"ActivitySearchServiceProvider.php, final class","depth":10,"bounds":{"left":0.054296874,"top":0.13958333,"width":0.09296875,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"DealInsightsPeriodFilterFactory.php","depth":10,"bounds":{"left":0.054296874,"top":0.15486111,"width":0.0953125,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"DealInsightsPeriodFilterFactoryInterface.php, interface","depth":10,"bounds":{"left":0.054296874,"top":0.1701389,"width":0.11679687,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"FilterDefinition.php, abstract class","depth":10,"bounds":{"left":0.054296874,"top":0.18541667,"width":0.055078126,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"FilterDefinitionCollection.php, class","depth":10,"bounds":{"left":0.054296874,"top":0.20069444,"width":0.07890625,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"FilterDefinitionQuery.php, class","depth":10,"bounds":{"left":0.054296874,"top":0.21597221,"width":0.06953125,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"FilterDefinitionQueryCollection.php, class","depth":10,"bounds":{"left":0.054296874,"top":0.23125,"width":0.09375,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"FilteredValueContainerInterface.php, interface","depth":10,"bounds":{"left":0.054296874,"top":0.24652778,"width":0.096875,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"IntMinMaxRange.php, class","depth":10,"bounds":{"left":0.054296874,"top":0.26180556,"width":0.06015625,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"AiActivityType","depth":9,"bounds":{"left":0.046875,"top":0.27708334,"width":0.04453125,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"AiAutomation","depth":9,"bounds":{"left":0.046875,"top":0.2923611,"width":0.041796874,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"AiCallScoring","depth":9,"bounds":{"left":0.046875,"top":0.30763888,"width":0.04140625,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"AskAnything","depth":9,"bounds":{"left":0.046875,"top":0.32291666,"width":0.03984375,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"AskJiminnyAi","depth":9,"bounds":{"left":0.046875,"top":0.33819443,"width":0.04140625,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"AWS","depth":9,"bounds":{"left":0.046875,"top":0.35347223,"width":0.02109375,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"BillingManagement","depth":9,"bounds":{"left":0.046875,"top":0.36875,"width":0.055078126,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"Cache","depth":9,"bounds":{"left":0.046875,"top":0.38402778,"width":0.025,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"CoachingFeedback","depth":9,"bounds":{"left":0.046875,"top":0.39930555,"width":0.055859376,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"Country","depth":9,"bounds":{"left":0.046875,"top":0.41458333,"width":0.02890625,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"CustomerApi","depth":9,"bounds":{"left":0.046875,"top":0.4298611,"width":0.040625,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"Database","depth":9,"bounds":{"left":0.046875,"top":0.4451389,"width":0.032421876,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"Datadog","depth":9,"bounds":{"left":0.046875,"top":0.46041667,"width":0.030078124,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"DateTime","depth":9,"bounds":{"left":0.046875,"top":0.47569445,"width":0.0328125,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"DealInsights","depth":9,"bounds":{"left":0.046875,"top":0.49097222,"width":0.0390625,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"DealRisks","depth":9,"bounds":{"left":0.046875,"top":0.50625,"width":0.0328125,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"ElasticSearch","depth":9,"bounds":{"left":0.046875,"top":0.52152777,"width":0.0421875,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"Eloquent","depth":9,"bounds":{"left":0.046875,"top":0.53680557,"width":0.03046875,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"Encoding","depth":9,"bounds":{"left":0.046875,"top":0.5520833,"width":0.03203125,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"Encryption","depth":9,"bounds":{"left":0.046875,"top":0.5673611,"width":0.03515625,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"ES","depth":9,"bounds":{"left":0.046875,"top":0.58263886,"width":0.016015625,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"Faker","depth":9,"bounds":{"left":0.046875,"top":0.59791666,"width":0.023046875,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"FeatureFlags","depth":9,"bounds":{"left":0.046875,"top":0.61319447,"width":0.040625,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"FFMpeg","depth":9,"bounds":{"left":0.046875,"top":0.6284722,"width":0.029296875,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"FileSystem","depth":9,"bounds":{"left":0.046875,"top":0.64375,"width":0.0359375,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"Gecko","depth":9,"bounds":{"left":0.046875,"top":0.65902776,"width":0.025,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"Gong","depth":9,"bounds":{"left":0.046875,"top":0.67430556,"width":0.022265624,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"GuzzleHttp","depth":9,"bounds":{"left":0.046875,"top":0.68958336,"width":0.036328126,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"KeyPoints","depth":9,"bounds":{"left":0.046875,"top":0.7048611,"width":0.03359375,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"Kiosk","depth":9,"bounds":{"left":0.046875,"top":0.7201389,"width":0.02265625,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"LanguageDetection","depth":9,"bounds":{"left":0.046875,"top":0.73541665,"width":0.056640625,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"LiveFeed","depth":9,"bounds":{"left":0.046875,"top":0.75069445,"width":0.031640626,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"Locks","depth":9,"bounds":{"left":0.046875,"top":0.7659722,"width":0.023828125,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"Math","depth":9,"bounds":{"left":0.046875,"top":0.78125,"width":0.021875,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"MediaPipeline","depth":9,"bounds":{"left":0.046875,"top":0.7965278,"width":0.04296875,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"MeetingBot","depth":9,"bounds":{"left":0.046875,"top":0.81180555,"width":0.037109375,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"MobileSettings","depth":9,"bounds":{"left":0.046875,"top":0.82708335,"width":0.0453125,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"Model","depth":9,"bounds":{"left":0.046875,"top":0.8423611,"width":0.024609376,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"Notification","depth":9,"bounds":{"left":0.046875,"top":0.8576389,"width":0.037109375,"height":0.015277778},"role_description":"text"},{"role":"AXStaticText","text":"Nudge","depth":9,"bounds":{"left":0.046875,"top":0.87291664,"width":0.025390625,"height":0.015277778},"role_description":"text"}]...
|
-3507986962049824144
|
-3743354318684703676
|
visual_change
|
accessibility
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
AskJiminnyReportActivityServiceT…Defaults
Rerun 'PHPUnit: AskJiminnyReportActivityServiceTest.testGetActivityIdsPassesNonZeroSequenceNumberToDisableFirstRequestDefaults'
Debug 'AskJiminnyReportActivityServiceTest.tes…uenceNumberToDisableFirstRequestDefaults'
Stop 'AskJiminnyReportActivityServiceTest.testGetActivityIdsPassesNonZeroSequenceNumberToDisableFirstRequestDefaults'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
<?php
declare(strict_types=1);
namespace Jiminny\Component\ActivitySearch\Service;
use Illuminate\Container\Container;
use Illuminate\Support\Collection;
use Jiminny\Component\ActivitySearch\FilterDefinition;
use Jiminny\Component\ActivitySearch\FilterDefinition\AiCallScoreFilter;
use Jiminny\Component\ActivitySearch\FilterDefinition\AutoScoreFilter;
use Jiminny\Component\ActivitySearch\FilterDefinition\ClosedDealsFilter;
use Jiminny\Component\ActivitySearch\FilterDefinition\DealCloseDate;
use Jiminny\Component\ActivitySearch\FilterDefinition\HasTopicTriggersFilterDefinition;
use Jiminny\Component\ActivitySearch\FilterDefinition\PlaybackTopicFilterDefinition;
use Jiminny\Component\ActivitySearch\FilterDefinition\Security\RestrictActivityChannel;
use Jiminny\Component\ActivitySearch\FilterDefinition\Security\RestrictPublicActivitiesOnly;
use Jiminny\Component\ActivitySearch\FilterDefinition\Security\RestrictTeam;
use Jiminny\Component\ActivitySearch\FilterDefinition\Security\RestrictUserActive;
use Jiminny\Component\ActivitySearch\FilterDefinition\Security\RestrictUserGroupScope;
use Jiminny\Component\ActivitySearch\FilterDefinition\TeamInsights\TopicFilterDefinition;
use Jiminny\Component\ActivitySearch\FilterDefinitionCollection;
use Jiminny\Models\Crm\Field;
use Jiminny\Models\User;
use Jiminny\Models\Crm\Configuration;
use Jiminny\Repositories\Crm\LayoutRepository;
use Jiminny\Services\TeamService;
use Jiminny\VO\Repository\OnDemandActivitySearch\Criteria;
class ActivitySearch
{
private Container $container;
public function __construct(Container $container)
{
$this->container = $container;
}
public function getOnDemandPageFilters(): FilterDefinitionCollection
{
return FilterDefinitionCollection::make(
Collection::make([
// special case filters
FilterDefinition\ActivityStatusIn::class,
FilterDefinition\ActivityUpdatedDate::class,
FilterDefinition\ActivityRecordingStopped::class,
FilterDefinition\ActivityFilter::class,
FilterDefinition\ExternalId::class,
FilterDefinition\NudgeRunId::class,
FilterDefinition\ParticipantUserIn::class,
FilterDefinition\PartnerFilterDefinition::class,
// healthy restrictions
RestrictTeam::class,
RestrictUserGroupScope::class,
RestrictActivityChannel::class,
RestrictUserActive::class,
FilterDefinition\Security\PrivateMeetingsForCurrentUserOnly::class,
// regular filters
FilterDefinition\ActivityActualDate::class,
FilterDefinition\ActivityChannel::class,
FilterDefinition\ActivityDurationRange::class,
FilterDefinition\ActivityPlaylistIn::class,
FilterDefinition\ActivityProviderIn::class,
FilterDefinition\ActivityRecorded::class,
FilterDefinition\ActivityType::class,
FilterDefinition\CoachingFeedbackAverageScore::class,
AutoScoreFilter::class,
AiCallScoreFilter::class,
FilterDefinition\CoachingFeedbackCoachUserIn::class,
FilterDefinition\CrmFieldCollection::class,
FilterDefinition\CurrentStage::class,
FilterDefinition\Customer::class,
FilterDefinition\CustomerMonologueDuration::class,
FilterDefinition\CustomerQuestionCount::class,
FilterDefinition\DealAge::class,
DealCloseDate::class,
FilterDefinition\DealValue::class,
FilterDefinition\EngagingQuestionCount::class,
FilterDefinition\ShowInternalExternalActivitiesFilter::class,
FilterDefinition\HasTranscription::class,
FilterDefinition\InsightfulQuestionCount::class,
FilterDefinition\LanguageFilterDefinition::class,
FilterDefinition\LoggedToCrm::class,
FilterDefinition\OrganiserGroupIn:[PASSWORD]
FilterDefinition\OrganiserUserIn::class,
FilterDefinition\PatienceRange::class,
PlaybackTopicFilterDefinition::class,
FilterDefinition\ProviderFilterDefinition::class,
FilterDefinition\SortBy::class,
FilterDefinition\SpeechRate::class,
FilterDefinition\StageAtCallFilterDefinition::class,
FilterDefinition\TalkTimeRatio::class,
FilterDefinition\TeamMemberUserIn::class,
FilterDefinition\TranscriptionComposite::class,
FilterDefinition\UserMonologueDuration::class,
FilterDefinition\UserQuestionCount::class,
FilterDefinition\CommentCountRange::class,
FilterDefinition\HasPendingAiCrmNotes::class,
])
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all(),
);
}
public function getOnDemandPageFilterSet(Criteria $criteria, User $consumer): FilterDefinitionCollection
{
return $this
->getOnDemandPageFilters()
->withCriteria($criteria)
->withConsumer($consumer)
->withRestrictions($consumer->getTeam());
}
/**
* @return string[]
*/
public function getArrayFilterKeys(User $consumer): array
{
return $this
->getOnDemandPageFilters()
->withConsumer($consumer)
->getPropertyTypes([FilterDefinitionCollection::PROPERTY_TYPE_ARRAY])
->keys()
->filter(static fn (string $key): bool => ! str_contains($key, '.'))
->values()
->all();
}
private function getTeamInsightsPageFilters(bool $isExport = false): FilterDefinitionCollection
{
$dateRangeFilterClass = $isExport
? FilterDefinition\TeamInsights\ConversationExport\DateRangeFilter::class
: FilterDefinition\TeamInsights\DateRangeFilter::class;
return FilterDefinitionCollection::make(
Collection::make([
// special cases
$dateRangeFilterClass,
FilterDefinition\TeamInsights\Exists::class,
// healthy restrictions
RestrictTeam::class,
RestrictUserGroupScope::class,
RestrictActivityChannel::class,
RestrictPublicActivitiesOnly::class,
RestrictUserActive::class,
// regular filters
FilterDefinition\ActivityChannel::class,
FilterDefinition\TeamInsights\ActivityDurationRange::class,
FilterDefinition\ActivityPlaylistIn::class,
FilterDefinition\ActivityProviderIn::class,
FilterDefinition\TeamInsights\ActivityRecorded::class,
FilterDefinition\ActivityType::class,
FilterDefinition\CoachingFeedbackAverageScore::class,
AutoScoreFilter::class,
AiCallScoreFilter::class,
FilterDefinition\CoachingFeedbackCoachUserIn::class,
FilterDefinition\CrmFieldCollection::class,
FilterDefinition\Customer::class,
FilterDefinition\CurrentStage::class,
FilterDefinition\CustomerMonologueDuration::class,
FilterDefinition\CustomerQuestionCount::class,
FilterDefinition\DealAge::class,
DealCloseDate::class,
FilterDefinition\DealValue::class,
FilterDefinition\EngagingQuestionCount::class,
FilterDefinition\ShowInternalExternalActivitiesFilter::class,
FilterDefinition\InsightfulQuestionCount::class,
FilterDefinition\LanguageFilterDefinition::class,
FilterDefinition\LoggedToCrm::class,
FilterDefinition\TeamInsights\UserInFilter::class,
FilterDefinition\TeamInsights\UserGroupInFilter::class,
FilterDefinition\PatienceRange::class,
PlaybackTopicFilterDefinition::class,
FilterDefinition\ProviderFilterDefinition::class,
FilterDefinition\SortBy::class,
FilterDefinition\SpeechRate::class,
FilterDefinition\StageAtCallFilterDefinition::class,
FilterDefinition\TalkTimeRatio::class,
FilterDefinition\TeamMemberUserIn::class,
FilterDefinition\TranscriptionComposite::class,
FilterDefinition\UserMonologueDuration::class,
FilterDefinition\UserQuestionCount::class,
FilterDefinition\CommentCountRange::class,
// Relevant for topics in deals.
ClosedDealsFilter::class,
HasTopicTriggersFilterDefinition::class,
TopicFilterDefinition::class,
])
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all(),
);
}
private function getDealInsightsPageFilters(
bool $useCreatedDate = false,
bool $includeDealType = false,
bool $includePipeline = false,
): FilterDefinitionCollection {
if ($useCreatedDate) {
$periodFilterClass = FilterDefinition\DealInsights\CreatedPeriodFilter::class;
} else {
$periodFilterClass = FilterDefinition\DealInsights\ClosingPeriodFilter::class;
}
$filterSet = [
RestrictTeam::class,
$periodFilterClass,
FilterDefinition\DealInsights\UserInFilter::class,
FilterDefinition\DealInsights\UserGroupInFilter::class,
FilterDefinition\DealInsights\DealStageInFilter::class,
FilterDefinition\DealInsights\DealNameFilter::class,
];
if ($includePipeline) {
$filterSet[] = FilterDefinition\DealInsights\DealPipelineInFilter::class;
}
if ($includeDealType) {
$filterSet[] = FilterDefinition\DealInsights\DealTypeInFilter::class;
}
return FilterDefinitionCollection::make(
Collection::make($filterSet)
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all(),
);
}
public function getTeamInsightsPageFilterSet(
Criteria $criteria,
User $consumer,
bool $isExport = false
): FilterDefinitionCollection {
return $this
->getTeamInsightsPageFilters($isExport)
->withCriteria($criteria)
->withConsumer($consumer)
->withRestrictions($consumer->getTeam());
}
public function getDealInsightsPageFilterSet(
Criteria $criteria,
User $consumer
): FilterDefinitionCollection {
$includeDealType = $this->shouldIncludeDealType($consumer);
$includePipeline = $this->shouldIncludePipeline($consumer);
$useCreatedDate = $this->shouldUseCreatedDate($consumer);
return $this
->getDealInsightsPageFilters($useCreatedDate, $includeDealType, $includePipeline)
->withCriteria($criteria)
->withConsumer($consumer);
}
public function getTeamAiAutomationFilterSet(
Criteria $criteria,
User $consumer
): FilterDefinitionCollection {
return $this
->getTeamAiAutomationPageFilterSet()
->withCriteria($criteria)
->withConsumer($consumer);
}
private function getTeamAiAutomationPageFilterSet(): FilterDefinitionCollection
{
$filterSet = [
RestrictTeam::class,
FilterDefinition\DealInsights\DealStageInFilter::class,
];
return FilterDefinitionCollection::make(
Collection::make($filterSet)
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all(),
);
}
public function getHomepageFilterSet(Criteria $criteria, User $consumer): FilterDefinitionCollection
{
$filterDefinitionCollection = FilterDefinitionCollection::make(
Collection::make([
RestrictTeam::class,
RestrictUserGroupScope::class,
RestrictActivityChannel::class,
RestrictUserActive::class,
FilterDefinition\Security\PrivateMeetingsForCurrentUserOnly::class,
FilterDefinition\ActivityActualDate::class,
FilterDefinition\Customer::class,
FilterDefinition\ActivityChannel::class,
FilterDefinition\ActivityDurationRange::class,
FilterDefinition\ActivityProviderIn::class,
FilterDefinition\ActivityRecorded::class,
FilterDefinition\ActivityRecordingStopped::class,
FilterDefinition\ActivityScheduledDate::class,
FilterDefinition\ActivityStatusIn::class,
FilterDefinition\LoggedToCrm::class,
FilterDefinition\OrganiserUserIn::class,
FilterDefinition\OrganiserUserNotIn::class,
FilterDefinition\ProviderFilterDefinition::class,
FilterDefinition\SortBy::class,
FilterDefinition\UserGroupInOptionalFilter::class,
FilterDefinition\OnlyActiveUsers::class,
])
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all(),
);
$filterDefinitionCollection->withCriteria($criteria);
$filterDefinitionCollection->withConsumer($consumer);
return $filterDefinitionCollection;
}
public function getPartnerFilterSet(Criteria $criteria): FilterDefinitionCollection
{
$filterDefinitionCollection = FilterDefinitionCollection::make(
Collection::make([
RestrictActivityChannel::class,
FilterDefinition\OrganiserTeamIn::class,
FilterDefinition\ActivityUpdatedDate::class,
FilterDefinition\ActivityStatusIn::class,
FilterDefinition\SortBy::class,
])
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all()
);
$filterDefinitionCollection->withCriteria($criteria);
return $filterDefinitionCollection;
}
private function shouldIncludeDealType(User $user): bool
{
$crmConfig = $user->getTeam()->getCrmConfiguration();
$crmProviderName = $crmConfig->getProviderName();
if (! array_key_exists($crmProviderName, Field::BUSINESS_TYPE_FIELDS)) {
return false;
}
$layoutRepository = app(LayoutRepository::class);
$layoutFields = $layoutRepository->getDealInsightLayoutFields($crmConfig);
$dealTypeField = Field::BUSINESS_TYPE_FIELDS[$crmProviderName];
if (! in_array($dealTypeField, $layoutFields)) {
return false;
}
return true;
}
private function shouldIncludePipeline(User $user): bool
{
$crmConfig = $user->getTeam()->getCrmConfiguration();
$crmProviderName = $crmConfig->getProviderName();
if (in_array($crmProviderName, [
Configuration::PROVIDER_SALESFORCE,
Configuration::PROVIDER_INTEGRATION_APP,
])) {
return false;
}
return true;
}
private function shouldUseCreatedDate(User $user): bool
{
$teamService = app(TeamService::class);
return ! $teamService->useDealInsightsClosedDateFilter($user->getTeam());
}
}
Sync Changes
Hide This Notification
Code changed:
Hide
15
4
Previous Highlighted Error
Next Highlighted Error
<?php
declare(strict_types=1);
namespace Jiminny\Repositories;
use Carbon\CarbonImmutable;
use Illuminate\Database\Eloquent\Builder;
use Illuminate\Support\Carbon;
use Illuminate\Database\Eloquent\Collection;
use Illuminate\Pagination\LengthAwarePaginator;
use Illuminate\Support\Facades\DB;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\AutomatedReportResult;
use Jiminny\Models\Team;
use Jiminny\Models\User;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Jiminny\Services\Kiosk\AutomatedReports\ReportSort;
use Jiminny\Services\Kiosk\AutomatedReports\ReportSortDirection;
class AutomatedReportsRepository
{
/**
* Create a new automated report
*
* @param array $data
*
* @return AutomatedReport
*/
public function create(array $data): AutomatedReport
{
return AutomatedReport::create($data);
}
/**
* Find an automated report by UUID
*
* @param string $uuid
*
* @return AutomatedReport|null
*/
public function findByUuid(string $uuid): ?AutomatedReport
{
return AutomatedReport::where('uuid', AutomatedReport::toOptimized($uuid))->first();
}
public function findByIdOrUuid(string $idOrUuid): ?AutomatedReport
{
if (is_numeric($idOrUuid)) {
return AutomatedReport::find((int) $idOrUuid);
}
return AutomatedReport::where('uuid', AutomatedReport::toOptimized($idOrUuid))->first();
}
/**
* Retrieve all standard (non-Ask Jiminny) automated reports.
*
* @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.
* @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.
*
* @return Collection<AutomatedReport>
*/
public function getAllStandardReports(
string $sortColumn = 'created_at',
string $sortDirection = 'desc'
): Collection {
return $this->buildSortedQuery($sortColumn, $sortDirection)
->whereNot('type', AutomatedReportsService::TYPE_ASK_JIMINNY)
->get();
}
/**
* Retrieve all Ask Jiminny reports created by the given user.
*
* @param User $user The user whose reports to retrieve.
* @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.
* @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.
*
* @return Collection<AutomatedReport>
*/
public function getAskJiminnyReportsByUser(
User $user,
string $sortColumn = 'created_at',
string $sortDirection = 'desc'
): Collection {
return $this->buildSortedQuery($sortColumn, $sortDirection)
->where('type', AutomatedReportsService::TYPE_ASK_JIMINNY)
->where('created_by', $user->getId())
->get();
}
private function buildSortedQuery(string $sortColumn, string $sortDirection): \Illuminate\Database\Eloquent\Builder
{
$allowedColumns = ['created_by', 'created_at'];
if (! in_array($sortColumn, $allowedColumns)) {
$sortColumn = 'created_at';
}
$sortDirection = strtolower($sortDirection) === 'asc' ? 'asc' : 'desc';
$query = AutomatedReport::query()->with(['creator', 'team']);
if ($sortColumn === 'created_by') {
$query->leftJoin('users', 'users.id', '=', 'automated_reports.created_by')
->orderByRaw("users.name COLLATE utf8mb4_unicode_ci {$sortDirection}")
->select('automated_reports.*');
} else {
$query->orderBy($sortColumn, $sortDirection);
}
return $query;
}
/**
* Get all active and enabled reports with active teams for the specified frequency.
*
* @param string $frequency
*
* @return Collection<AutomatedReport>
*/
public function getActiveReportsByFrequency(string $frequency): Collection
{
return AutomatedReport::where('automated_reports.status', true)
->where('automated_reports.frequency', $frequency)
->join('teams', 'automated_reports.team_id', '=', 'teams.id')
->where('teams.status', Team::STATUS_ACTIVE)
->where(function ($query) {
$query->whereNull('automated_reports.expires_at')
->orWhere('automated_reports.expires_at', '>=', now()->toDateString());
})
->select('automated_reports.*')
->get();
}
/**
* Update an automated report
*
* @param AutomatedReport $report
* @param array $data
*
* @return AutomatedReport
*/
public function update(AutomatedReport $report, array $data): AutomatedReport
{
$report->update($data);
return $report;
}
/**
* Create a new automated report result.
*
* @param array $data The data to create the automated report result with.
*
* @return AutomatedReportResult The newly created automated report result.
*/
public function createResult(array $data): AutomatedReportResult
{
return AutomatedReportResult::create($data);
}
/**
* Find an automated report result by UUID.
*
* @param string $uuid The UUID to find the automated report result with.
*
* @return AutomatedReportResult|null The automated report result if found, otherwise null.
*/
public function findResultByUuid(string $uuid): ?AutomatedReportResult
{
return AutomatedReportResult::where('uuid', AutomatedReportResult::toOptimized($uuid))->first();
}
public function findResultByUuidForUser(string $uuid, User $user): ?AutomatedReportResult
{
return AutomatedReportResult::query()
->where('uuid', AutomatedReportResult::toOptimized($uuid))
->whereHas('report', static function ($query) use ($user): void {
$query->where('team_id', $user->getTeamId())
->where('created_by', $user->getId());
})
->first();
}
public function findChildResult(AutomatedReportResult $result, string $type): ?AutomatedReportResult
{
return AutomatedReportResult::query()
->where('parent_id', $result->getId())
->where('media_type', $type)
->first();
}
public function getGeneratedNotSentResults(): Collection
{
return AutomatedReportResult::query()
->whereNotNull('generated_at')
->whereNull('sent_at')
->where('status', AutomatedReportResult::STATUS_GENERATED)
->whereHas('report')
->with('report')
->get();
}
public function getPaginatedUserReports(
User $user,
ReportSort $sort,
ReportSortDirection $sortDirection,
int $resultsPerPage,
int $page,
?Carbon $fromDate,
?Carbon $toDate,
array $teamIds,
array $reportTypes,
?string $name,
): LengthAwarePaginator {
$query = AutomatedReportResult::query()
->whereNotNull('automated_report_results.generated_at')
->join('automated_reports', 'automated_report_results.report_id', '=', 'automated_reports.id')
->where('automated_reports.team_id', $user->getTeamId())
->whereJsonContains('automated_reports.recipients->users', $user->getId())
->orderByRaw("$sort->value COLLATE utf8mb4_unicode_ci {$sortDirection->value}")
->select('automated_report_results.*')
->with('report.team');
if ($fromDate !== null && $toDate !== null) {
$query->whereBetween('generated_at', [$fromDate, $toDate]);
}
if (! empty($teamIds)) {
$query->where(function ($q) use ($teamIds) {
foreach ($teamIds as $id) {
$q->orWhereJsonContains('automated_reports.groups', $id);
}
});
}
if (! empty($reportTypes)) {
$query->whereIn('automated_reports.type', $reportTypes);
}
if (! empty($name)) {
$query->whereLike('name', "%$name%");
}
return $query->paginate($resultsPerPage, ['*'], 'page', $page);
}
public function countUserReports(User $user): int
{
return AutomatedReportResult::query()
->whereNotNull('generated_at')
->whereNotNull('sent_at')
->whereHas('report', function ($q) use ($user) {
$q->where('team_id', $user->getTeamId())
->whereJsonContains('recipients->users', $user->getId());
})
->count();
}
/**
* Get report IDs for a specific team
*
* @param Team $team
*
* @return \Illuminate\Support\Collection
*/
public function getReportIdsByTeam(Team $team): \Illuminate\Support\Collection
{
return AutomatedReport::where('team_id', $team->getId())->pluck('id');
}
/**
* Get all reports for a specific team
*
* @param Team $team
*
* @return Collection
*/
public function getReportsByTeam(Team $team): Collection
{
return AutomatedReport::where('team_id', $team->getId())->get();
}
/**
* Get all report results for a specific report
*
* @param AutomatedReport $report
*
* @return Collection
*/
public function getResultsByReport(AutomatedReport $report): Collection
{
return $this->getResultsByReportQuery($report)->get();
}
public function getResultsByReportQuery(AutomatedReport $report): Builder
{
return AutomatedReportResult::where('report_id', $report->getId());
}
public function getReportResultsQueryForRetention(Team $team, CarbonImmutable $retentionDate): Builder
{
$reportIds = $this->getReportIdsByTeam($team);
return AutomatedReportResult::query()->whereIn('report_id', $reportIds)
->whereRaw('IFNULL(generated_at, created_at) <= ?', [$retentionDate]);
}
/**
* @param int|null $teamId Optional team ID to filter results
*
* @return \Illuminate\Support\Collection<int, int> Collection of team IDs
*/
public function getTeamIdsWithReportsResults(?int $teamId = null): \Illuminate\Support\Collection
{
$query = DB::table('automated_reports')
->join('teams', 'automated_reports.team_id', '=', 'teams.id')
->select('teams.id')
->distinct();
if ($teamId !== null) {
$query->where('teams.id', $teamId);
}
return $query->pluck('teams.id');
}
}
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide
app ~/jiminny/app
.circleci
.cursor
.github
.sonarlint
.vscode
.windsurf
app, sources root
Actions
Component
Acl, folder
ActionItems, folder
Activity, folder
ActivityAnalytics, folder
ActivitySearch, folder
EventSubscriber, folder
FilterDefinition, folder
Service
ActivityApiSearch.php, class
ActivitySearch.php, class
UserOptionsByGroup.php, class
AbstractStageFilterDefinition.php, abstract class
ActivitySearchServiceProvider.php, final class
DealInsightsPeriodFilterFactory.php
DealInsightsPeriodFilterFactoryInterface.php, interface
FilterDefinition.php, abstract class
FilterDefinitionCollection.php, class
FilterDefinitionQuery.php, class
FilterDefinitionQueryCollection.php, class
FilteredValueContainerInterface.php, interface
IntMinMaxRange.php, class
AiActivityType
AiAutomation
AiCallScoring
AskAnything
AskJiminnyAi
AWS
BillingManagement
Cache
CoachingFeedback
Country
CustomerApi
Database
Datadog
DateTime
DealInsights
DealRisks
ElasticSearch
Eloquent
Encoding
Encryption
ES
Faker
FeatureFlags
FFMpeg
FileSystem
Gecko
Gong
GuzzleHttp
KeyPoints
Kiosk
LanguageDetection
LiveFeed
Locks
Math
MediaPipeline
MeetingBot
MobileSettings
Model
Notification
Nudge...
|
11021
|
|
11023
|
218
|
0
|
2026-04-14T09:09:00.179423+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776157740179_m1.jpg...
|
PhpStorm
|
faVsco.js – ActivitySearch.php
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
AskJiminnyReportActivityServiceT…Defaults
Rerun 'PHPUnit: AskJiminnyReportActivityServiceTest.testGetActivityIdsPassesNonZeroSequenceNumberToDisableFirstRequestDefaults'
Debug 'AskJiminnyReportActivityServiceTest.tes…uenceNumberToDisableFirstRequestDefaults'
Stop 'AskJiminnyReportActivityServiceTest.testGetActivityIdsPassesNonZeroSequenceNumberToDisableFirstRequestDefaults'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
<?php
declare(strict_types=1);
namespace Jiminny\Component\ActivitySearch\Service;
use Illuminate\Container\Container;
use Illuminate\Support\Collection;
use Jiminny\Component\ActivitySearch\FilterDefinition;
use Jiminny\Component\ActivitySearch\FilterDefinition\AiCallScoreFilter;
use Jiminny\Component\ActivitySearch\FilterDefinition\AutoScoreFilter;
use Jiminny\Component\ActivitySearch\FilterDefinition\ClosedDealsFilter;
use Jiminny\Component\ActivitySearch\FilterDefinition\DealCloseDate;
use Jiminny\Component\ActivitySearch\FilterDefinition\HasTopicTriggersFilterDefinition;
use Jiminny\Component\ActivitySearch\FilterDefinition\PlaybackTopicFilterDefinition;
use Jiminny\Component\ActivitySearch\FilterDefinition\Security\RestrictActivityChannel;
use Jiminny\Component\ActivitySearch\FilterDefinition\Security\RestrictPublicActivitiesOnly;
use Jiminny\Component\ActivitySearch\FilterDefinition\Security\RestrictTeam;
use Jiminny\Component\ActivitySearch\FilterDefinition\Security\RestrictUserActive;
use Jiminny\Component\ActivitySearch\FilterDefinition\Security\RestrictUserGroupScope;
use Jiminny\Component\ActivitySearch\FilterDefinition\TeamInsights\TopicFilterDefinition;
use Jiminny\Component\ActivitySearch\FilterDefinitionCollection;
use Jiminny\Models\Crm\Field;
use Jiminny\Models\User;
use Jiminny\Models\Crm\Configuration;
use Jiminny\Repositories\Crm\LayoutRepository;
use Jiminny\Services\TeamService;
use Jiminny\VO\Repository\OnDemandActivitySearch\Criteria;
class ActivitySearch
{
private Container $container;
public function __construct(Container $container)
{
$this->container = $container;
}
public function getOnDemandPageFilters(): FilterDefinitionCollection
{
return FilterDefinitionCollection::make(
Collection::make([
// special case filters
FilterDefinition\ActivityStatusIn::class,
FilterDefinition\ActivityUpdatedDate::class,
FilterDefinition\ActivityRecordingStopped::class,
FilterDefinition\ActivityFilter::class,
FilterDefinition\ExternalId::class,
FilterDefinition\NudgeRunId::class,
FilterDefinition\ParticipantUserIn::class,
FilterDefinition\PartnerFilterDefinition::class,
// healthy restrictions
RestrictTeam::class,
RestrictUserGroupScope::class,
RestrictActivityChannel::class,
RestrictUserActive::class,
FilterDefinition\Security\PrivateMeetingsForCurrentUserOnly::class,
// regular filters
FilterDefinition\ActivityActualDate::class,
FilterDefinition\ActivityChannel::class,
FilterDefinition\ActivityDurationRange::class,
FilterDefinition\ActivityPlaylistIn::class,
FilterDefinition\ActivityProviderIn::class,
FilterDefinition\ActivityRecorded::class,
FilterDefinition\ActivityType::class,
FilterDefinition\CoachingFeedbackAverageScore::class,
AutoScoreFilter::class,
AiCallScoreFilter::class,
FilterDefinition\CoachingFeedbackCoachUserIn::class,
FilterDefinition\CrmFieldCollection::class,
FilterDefinition\CurrentStage::class,
FilterDefinition\Customer::class,
FilterDefinition\CustomerMonologueDuration::class,
FilterDefinition\CustomerQuestionCount::class,
FilterDefinition\DealAge::class,
DealCloseDate::class,
FilterDefinition\DealValue::class,
FilterDefinition\EngagingQuestionCount::class,
FilterDefinition\ShowInternalExternalActivitiesFilter::class,
FilterDefinition\HasTranscription::class,
FilterDefinition\InsightfulQuestionCount::class,
FilterDefinition\LanguageFilterDefinition::class,
FilterDefinition\LoggedToCrm::class,
FilterDefinition\OrganiserGroupIn:[PASSWORD]
FilterDefinition\OrganiserUserIn::class,
FilterDefinition\PatienceRange::class,
PlaybackTopicFilterDefinition::class,
FilterDefinition\ProviderFilterDefinition::class,
FilterDefinition\SortBy::class,
FilterDefinition\SpeechRate::class,
FilterDefinition\StageAtCallFilterDefinition::class,
FilterDefinition\TalkTimeRatio::class,
FilterDefinition\TeamMemberUserIn::class,
FilterDefinition\TranscriptionComposite::class,
FilterDefinition\UserMonologueDuration::class,
FilterDefinition\UserQuestionCount::class,
FilterDefinition\CommentCountRange::class,
FilterDefinition\HasPendingAiCrmNotes::class,
])
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all(),
);
}
public function getOnDemandPageFilterSet(Criteria $criteria, User $consumer): FilterDefinitionCollection
{
return $this
->getOnDemandPageFilters()
->withCriteria($criteria)
->withConsumer($consumer)
->withRestrictions($consumer->getTeam());
}
/**
* @return string[]
*/
public function getArrayFilterKeys(User $consumer): array
{
return $this
->getOnDemandPageFilters()
->withConsumer($consumer)
->getPropertyTypes([FilterDefinitionCollection::PROPERTY_TYPE_ARRAY])
->keys()
->filter(static fn (string $key): bool => ! str_contains($key, '.'))
->values()
->all();
}
private function getTeamInsightsPageFilters(bool $isExport = false): FilterDefinitionCollection
{
$dateRangeFilterClass = $isExport
? FilterDefinition\TeamInsights\ConversationExport\DateRangeFilter::class
: FilterDefinition\TeamInsights\DateRangeFilter::class;
return FilterDefinitionCollection::make(
Collection::make([
// special cases
$dateRangeFilterClass,
FilterDefinition\TeamInsights\Exists::class,
// healthy restrictions
RestrictTeam::class,
RestrictUserGroupScope::class,
RestrictActivityChannel::class,
RestrictPublicActivitiesOnly::class,
RestrictUserActive::class,
// regular filters
FilterDefinition\ActivityChannel::class,
FilterDefinition\TeamInsights\ActivityDurationRange::class,
FilterDefinition\ActivityPlaylistIn::class,
FilterDefinition\ActivityProviderIn::class,
FilterDefinition\TeamInsights\ActivityRecorded::class,
FilterDefinition\ActivityType::class,
FilterDefinition\CoachingFeedbackAverageScore::class,
AutoScoreFilter::class,
AiCallScoreFilter::class,
FilterDefinition\CoachingFeedbackCoachUserIn::class,
FilterDefinition\CrmFieldCollection::class,
FilterDefinition\Customer::class,
FilterDefinition\CurrentStage::class,
FilterDefinition\CustomerMonologueDuration::class,
FilterDefinition\CustomerQuestionCount::class,
FilterDefinition\DealAge::class,
DealCloseDate::class,
FilterDefinition\DealValue::class,
FilterDefinition\EngagingQuestionCount::class,
FilterDefinition\ShowInternalExternalActivitiesFilter::class,
FilterDefinition\InsightfulQuestionCount::class,
FilterDefinition\LanguageFilterDefinition::class,
FilterDefinition\LoggedToCrm::class,
FilterDefinition\TeamInsights\UserInFilter::class,
FilterDefinition\TeamInsights\UserGroupInFilter::class,
FilterDefinition\PatienceRange::class,
PlaybackTopicFilterDefinition::class,
FilterDefinition\ProviderFilterDefinition::class,
FilterDefinition\SortBy::class,
FilterDefinition\SpeechRate::class,
FilterDefinition\StageAtCallFilterDefinition::class,
FilterDefinition\TalkTimeRatio::class,
FilterDefinition\TeamMemberUserIn::class,
FilterDefinition\TranscriptionComposite::class,
FilterDefinition\UserMonologueDuration::class,
FilterDefinition\UserQuestionCount::class,
FilterDefinition\CommentCountRange::class,
// Relevant for topics in deals.
ClosedDealsFilter::class,
HasTopicTriggersFilterDefinition::class,
TopicFilterDefinition::class,
])
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all(),
);
}
private function getDealInsightsPageFilters(
bool $useCreatedDate = false,
bool $includeDealType = false,
bool $includePipeline = false,
): FilterDefinitionCollection {
if ($useCreatedDate) {
$periodFilterClass = FilterDefinition\DealInsights\CreatedPeriodFilter::class;
} else {
$periodFilterClass = FilterDefinition\DealInsights\ClosingPeriodFilter::class;
}
$filterSet = [
RestrictTeam::class,
$periodFilterClass,
FilterDefinition\DealInsights\UserInFilter::class,
FilterDefinition\DealInsights\UserGroupInFilter::class,
FilterDefinition\DealInsights\DealStageInFilter::class,
FilterDefinition\DealInsights\DealNameFilter::class,
];
if ($includePipeline) {
$filterSet[] = FilterDefinition\DealInsights\DealPipelineInFilter::class;
}
if ($includeDealType) {
$filterSet[] = FilterDefinition\DealInsights\DealTypeInFilter::class;
}
return FilterDefinitionCollection::make(
Collection::make($filterSet)
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all(),
);
}
public function getTeamInsightsPageFilterSet(
Criteria $criteria,
User $consumer,
bool $isExport = false
): FilterDefinitionCollection {
return $this
->getTeamInsightsPageFilters($isExport)
->withCriteria($criteria)
->withConsumer($consumer)
->withRestrictions($consumer->getTeam());
}
public function getDealInsightsPageFilterSet(
Criteria $criteria,
User $consumer
): FilterDefinitionCollection {
$includeDealType = $this->shouldIncludeDealType($consumer);
$includePipeline = $this->shouldIncludePipeline($consumer);
$useCreatedDate = $this->shouldUseCreatedDate($consumer);
return $this
->getDealInsightsPageFilters($useCreatedDate, $includeDealType, $includePipeline)
->withCriteria($criteria)
->withConsumer($consumer);
}
public function getTeamAiAutomationFilterSet(
Criteria $criteria,
User $consumer
): FilterDefinitionCollection {
return $this
->getTeamAiAutomationPageFilterSet()
->withCriteria($criteria)
->withConsumer($consumer);
}
private function getTeamAiAutomationPageFilterSet(): FilterDefinitionCollection
{
$filterSet = [
RestrictTeam::class,
FilterDefinition\DealInsights\DealStageInFilter::class,
];
return FilterDefinitionCollection::make(
Collection::make($filterSet)
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all(),
);
}
public function getHomepageFilterSet(Criteria $criteria, User $consumer): FilterDefinitionCollection
{
$filterDefinitionCollection = FilterDefinitionCollection::make(
Collection::make([
RestrictTeam::class,
RestrictUserGroupScope::class,
RestrictActivityChannel::class,
RestrictUserActive::class,
FilterDefinition\Security\PrivateMeetingsForCurrentUserOnly::class,
FilterDefinition\ActivityActualDate::class,
FilterDefinition\Customer::class,
FilterDefinition\ActivityChannel::class,
FilterDefinition\ActivityDurationRange::class,
FilterDefinition\ActivityProviderIn::class,
FilterDefinition\ActivityRecorded::class,
FilterDefinition\ActivityRecordingStopped::class,
FilterDefinition\ActivityScheduledDate::class,
FilterDefinition\ActivityStatusIn::class,
FilterDefinition\LoggedToCrm::class,
FilterDefinition\OrganiserUserIn::class,
FilterDefinition\OrganiserUserNotIn::class,
FilterDefinition\ProviderFilterDefinition::class,
FilterDefinition\SortBy::class,
FilterDefinition\UserGroupInOptionalFilter::class,
FilterDefinition\OnlyActiveUsers::class,
])
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all(),
);
$filterDefinitionCollection->withCriteria($criteria);
$filterDefinitionCollection->withConsumer($consumer);
return $filterDefinitionCollection;
}
public function getPartnerFilterSet(Criteria $criteria): FilterDefinitionCollection
{
$filterDefinitionCollection = FilterDefinitionCollection::make(
Collection::make([
RestrictActivityChannel::class,
FilterDefinition\OrganiserTeamIn::class,
FilterDefinition\ActivityUpdatedDate::class,
FilterDefinition\ActivityStatusIn::class,
FilterDefinition\SortBy::class,
])
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all()
);
$filterDefinitionCollection->withCriteria($criteria);
return $filterDefinitionCollection;
}
private function shouldIncludeDealType(User $user): bool
{
$crmConfig = $user->getTeam()->getCrmConfiguration();
$crmProviderName = $crmConfig->getProviderName();
if (! array_key_exists($crmProviderName, Field::BUSINESS_TYPE_FIELDS)) {
return false;
}
$layoutRepository = app(LayoutRepository::class);
$layoutFields = $layoutRepository->getDealInsightLayoutFields($crmConfig);
$dealTypeField = Field::BUSINESS_TYPE_FIELDS[$crmProviderName];
if (! in_array($dealTypeField, $layoutFields)) {
return false;
}
return true;
}
private function shouldIncludePipeline(User $user): bool
{
$crmConfig = $user->getTeam()->getCrmConfiguration();
$crmProviderName = $crmConfig->getProviderName();
if (in_array($crmProviderName, [
Configuration::PROVIDER_SALESFORCE,
Configuration::PROVIDER_INTEGRATION_APP,
])) {
return false;
}
return true;
}
private function shouldUseCreatedDate(User $user): bool
{
$teamService = app(TeamService::class);
return ! $teamService->useDealInsightsClosedDateFilter($user->getTeam());
}
}
Sync Changes
Hide This Notification
Code changed:
Hide
15
4
Previous Highlighted Error
Next Highlighted Error
<?php
declare(strict_types=1);
namespace Jiminny\Repositories;
use Carbon\CarbonImmutable;
use Illuminate\Database\Eloquent\Builder;
use Illuminate\Support\Carbon;
use Illuminate\Database\Eloquent\Collection;
use Illuminate\Pagination\LengthAwarePaginator;
use Illuminate\Support\Facades\DB;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\AutomatedReportResult;
use Jiminny\Models\Team;
use Jiminny\Models\User;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Jiminny\Services\Kiosk\AutomatedReports\ReportSort;
use Jiminny\Services\Kiosk\AutomatedReports\ReportSortDirection;
class AutomatedReportsRepository
{
/**
* Create a new automated report
*
* @param array $data
*
* @return AutomatedReport
*/
public function create(array $data): AutomatedReport
{
return AutomatedReport::create($data);
}
/**
* Find an automated report by UUID
*
* @param string $uuid
*
* @return AutomatedReport|null
*/
public function findByUuid(string $uuid): ?AutomatedReport
{
return AutomatedReport::where('uuid', AutomatedReport::toOptimized($uuid))->first();
}
public function findByIdOrUuid(string $idOrUuid): ?AutomatedReport
{
if (is_numeric($idOrUuid)) {
return AutomatedReport::find((int) $idOrUuid);
}
return AutomatedReport::where('uuid', AutomatedReport::toOptimized($idOrUuid))->first();
}
/**
* Retrieve all standard (non-Ask Jiminny) automated reports.
*
* @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.
* @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.
*
* @return Collection<AutomatedReport>
*/
public function getAllStandardReports(
string $sortColumn = 'created_at',
string $sortDirection = 'desc'
): Collection {
return $this->buildSortedQuery($sortColumn, $sortDirection)
->whereNot('type', AutomatedReportsService::TYPE_ASK_JIMINNY)
->get();
}
/**
* Retrieve all Ask Jiminny reports created by the given user.
*
* @param User $user The user whose reports to retrieve.
* @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.
* @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.
*
* @return Collection<AutomatedReport>
*/
public function getAskJiminnyReportsByUser(
User $user,
string $sortColumn = 'created_at',
string $sortDirection = 'desc'
): Collection {
return $this->buildSortedQuery($sortColumn, $sortDirection)
->where('type', AutomatedReportsService::TYPE_ASK_JIMINNY)
->where('created_by', $user->getId())
->get();
}
private function buildSortedQuery(string $sortColumn, string $sortDirection): \Illuminate\Database\Eloquent\Builder
{
$allowedColumns = ['created_by', 'created_at'];
if (! in_array($sortColumn, $allowedColumns)) {
$sortColumn = 'created_at';
}
$sortDirection = strtolower($sortDirection) === 'asc' ? 'asc' : 'desc';
$query = AutomatedReport::query()->with(['creator', 'team']);
if ($sortColumn === 'created_by') {
$query->leftJoin('users', 'users.id', '=', 'automated_reports.created_by')
->orderByRaw("users.name COLLATE utf8mb4_unicode_ci {$sortDirection}")
->select('automated_reports.*');
} else {
$query->orderBy($sortColumn, $sortDirection);
}
return $query;
}
/**
* Get all active and enabled reports with active teams for the specified frequency.
*
* @param string $frequency
*
* @return Collection<AutomatedReport>
*/
public function getActiveReportsByFrequency(string $frequency): Collection
{
return AutomatedReport::where('automated_reports.status', true)
->where('automated_reports.frequency', $frequency)
->join('teams', 'automated_reports.team_id', '=', 'teams.id')
->where('teams.status', Team::STATUS_ACTIVE)
->where(function ($query) {
$query->whereNull('automated_reports.expires_at')
->orWhere('automated_reports.expires_at', '>=', now()->toDateString());
})
->select('automated_reports.*')
->get();
}
/**
* Update an automated report
*
* @param AutomatedReport $report
* @param array $data
*
* @return AutomatedReport
*/
public function update(AutomatedReport $report, array $data): AutomatedReport
{
$report->update($data);
return $report;
}
/**
* Create a new automated report result.
*
* @param array $data The data to create the automated report result with.
*
* @return AutomatedReportResult The newly created automated report result.
*/
public function createResult(array $data): AutomatedReportResult
{
return AutomatedReportResult::create($data);
}
/**
* Find an automated report result by UUID.
*
* @param string $uuid The UUID to find the automated report result with.
*
* @return AutomatedReportResult|null The automated report result if found, otherwise null.
*/
public function findResultByUuid(string $uuid): ?AutomatedReportResult
{
return AutomatedReportResult::where('uuid', AutomatedReportResult::toOptimized($uuid))->first();
}
public function findResultByUuidForUser(string $uuid, User $user): ?AutomatedReportResult
{
return AutomatedReportResult::query()
->where('uuid', AutomatedReportResult::toOptimized($uuid))
->whereHas('report', static function ($query) use ($user): void {
$query->where('team_id', $user->getTeamId())
->where('created_by', $user->getId());
})
->first();
}
public function findChildResult(AutomatedReportResult $result, string $type): ?AutomatedReportResult
{
return AutomatedReportResult::query()
->where('parent_id', $result->getId())
->where('media_type', $type)
->first();
}
public function getGeneratedNotSentResults(): Collection
{
return AutomatedReportResult::query()
->whereNotNull('generated_at')
->whereNull('sent_at')
->where('status', AutomatedReportResult::STATUS_GENERATED)
->whereHas('report')
->with('report')
->get();
}
public function getPaginatedUserReports(
User $user,
ReportSort $sort,
ReportSortDirection $sortDirection,
int $resultsPerPage,
int $page,
?Carbon $fromDate,
?Carbon $toDate,
array $teamIds,
array $reportTypes,
?string $name,
): LengthAwarePaginator {
$query = AutomatedReportResult::query()
->whereNotNull('automated_report_results.generated_at')
->join('automated_reports', 'automated_report_results.report_id', '=', 'automated_reports.id')
->where('automated_reports.team_id', $user->getTeamId())
->whereJsonContains('automated_reports.recipients->users', $user->getId())
->orderByRaw("$sort->value COLLATE utf8mb4_unicode_ci {$sortDirection->value}")
->select('automated_report_results.*')
->with('report.team');
if ($fromDate !== null && $toDate !== null) {
$query->whereBetween('generated_at', [$fromDate, $toDate]);
}
if (! empty($teamIds)) {
$query->where(function ($q) use ($teamIds) {
foreach ($teamIds as $id) {
$q->orWhereJsonContains('automated_reports.groups', $id);
}
});
}
if (! empty($reportTypes)) {
$query->whereIn('automated_reports.type', $reportTypes);
}
if (! empty($name)) {
$query->whereLike('name', "%$name%");
}
return $query->paginate($resultsPerPage, ['*'], 'page', $page);
}
public function countUserReports(User $user): int
{
return AutomatedReportResult::query()
->whereNotNull('generated_at')
->whereNotNull('sent_at')
->whereHas('report', function ($q) use ($user) {
$q->where('team_id', $user->getTeamId())
->whereJsonContains('recipients->users', $user->getId());
})
->count();
}
/**
* Get report IDs for a specific team
*
* @param Team $team
*
* @return \Illuminate\Support\Collection
*/
public function getReportIdsByTeam(Team $team): \Illuminate\Support\Collection
{
return AutomatedReport::where('team_id', $team->getId())->pluck('id');
}
/**
* Get all reports for a specific team
*
* @param Team $team
*
* @return Collection
*/
public function getReportsByTeam(Team $team): Collection
{
return AutomatedReport::where('team_id', $team->getId())->get();
}
/**
* Get all report results for a specific report
*
* @param AutomatedReport $report
*
* @return Collection
*/
public function getResultsByReport(AutomatedReport $report): Collection
{
return $this->getResultsByReportQuery($report)->get();
}
public function getResultsByReportQuery(AutomatedReport $report): Builder
{
return AutomatedReportResult::where('report_id', $report->getId());
}
public function getReportResultsQueryForRetention(Team $team, CarbonImmutable $retentionDate): Builder
{
$reportIds = $this->getReportIdsByTeam($team);
return AutomatedReportResult::query()->whereIn('report_id', $reportIds)
->whereRaw('IFNULL(generated_at, created_at) <= ?', [$retentionDate]);
}
/**
* @param int|null $teamId Optional team ID to filter results
*
* @return \Illuminate\Support\Collection<int, int> Collection of team IDs
*/
public function getTeamIdsWithReportsResults(?int $teamId = null): \Illuminate\Support\Collection
{
$query = DB::table('automated_reports')
->join('teams', 'automated_reports.team_id', '=', 'teams.id')
->select('teams.id')
->distinct();
if ($teamId !== null) {
$query->where('teams.id', $teamId);
}
return $query->pluck('teams.id');
}
}
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide
app ~/jiminny/app
.circleci
.cursor
.github
.sonarlint
.vscode
.windsurf
app, sources root
Actions
Component
Acl, folder
ActionItems, folder
Activity, folder
ActivityAnalytics, folder
ActivitySearch, folder
EventSubscriber, folder
FilterDefinition, folder
Service
ActivityApiSearch.php, class
ActivitySearch.php, class
UserOptionsByGroup.php, class
AbstractStageFilterDefinition.php, abstract class
ActivitySearchServiceProvider.php, final class
DealInsightsPeriodFilterFactory.php
DealInsightsPeriodFilterFactoryInterface.php, interface...
|
[{"role":"AXButton","text" [{"role":"AXButton","text":"Project: faVsco.js, menu","depth":5,"help_text":"~/jiminny/app","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"#11894 on JY-18909-automated-reports-ask-jiminny, menu","depth":5,"help_text":"Pull request #11894 exists for current branch JY-18909-automated-reports-ask-jiminny, but local branch is out of sync with remote","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Start Listening for PHP Debug Connections","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"AskJiminnyReportActivityServiceT…Defaults","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Rerun 'PHPUnit: AskJiminnyReportActivityServiceTest.testGetActivityIdsPassesNonZeroSequenceNumberToDisableFirstRequestDefaults'","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Debug 'AskJiminnyReportActivityServiceTest.tes…uenceNumberToDisableFirstRequestDefaults'","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Stop 'AskJiminnyReportActivityServiceTest.testGetActivityIdsPassesNonZeroSequenceNumberToDisableFirstRequestDefaults'","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"More Actions","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"JetBrains AI","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Search Everywhere","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"IDE and Project Settings","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.088194445,"height":0.027777778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Component\\ActivitySearch\\Service;\n\nuse Illuminate\\Container\\Container;\nuse Illuminate\\Support\\Collection;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\AiCallScoreFilter;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\AutoScoreFilter;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\ClosedDealsFilter;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\DealCloseDate;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\HasTopicTriggersFilterDefinition;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\PlaybackTopicFilterDefinition;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\Security\\RestrictActivityChannel;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\Security\\RestrictPublicActivitiesOnly;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\Security\\RestrictTeam;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\Security\\RestrictUserActive;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\Security\\RestrictUserGroupScope;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\TeamInsights\\TopicFilterDefinition;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinitionCollection;\nuse Jiminny\\Models\\Crm\\Field;\nuse Jiminny\\Models\\User;\nuse Jiminny\\Models\\Crm\\Configuration;\nuse Jiminny\\Repositories\\Crm\\LayoutRepository;\nuse Jiminny\\Services\\TeamService;\nuse Jiminny\\VO\\Repository\\OnDemandActivitySearch\\Criteria;\n\nclass ActivitySearch\n{\n private Container $container;\n\n public function __construct(Container $container)\n {\n $this->container = $container;\n }\n\n public function getOnDemandPageFilters(): FilterDefinitionCollection\n {\n return FilterDefinitionCollection::make(\n Collection::make([\n // special case filters\n FilterDefinition\\ActivityStatusIn::class,\n FilterDefinition\\ActivityUpdatedDate::class,\n FilterDefinition\\ActivityRecordingStopped::class,\n FilterDefinition\\ActivityFilter::class,\n FilterDefinition\\ExternalId::class,\n FilterDefinition\\NudgeRunId::class,\n FilterDefinition\\ParticipantUserIn::class,\n FilterDefinition\\PartnerFilterDefinition::class,\n\n // healthy restrictions\n RestrictTeam::class,\n RestrictUserGroupScope::class,\n RestrictActivityChannel::class,\n RestrictUserActive::class,\n FilterDefinition\\Security\\PrivateMeetingsForCurrentUserOnly::class,\n\n // regular filters\n FilterDefinition\\ActivityActualDate::class,\n FilterDefinition\\ActivityChannel::class,\n FilterDefinition\\ActivityDurationRange::class,\n FilterDefinition\\ActivityPlaylistIn::class,\n FilterDefinition\\ActivityProviderIn::class,\n FilterDefinition\\ActivityRecorded::class,\n FilterDefinition\\ActivityType::class,\n FilterDefinition\\CoachingFeedbackAverageScore::class,\n AutoScoreFilter::class,\n AiCallScoreFilter::class,\n FilterDefinition\\CoachingFeedbackCoachUserIn::class,\n FilterDefinition\\CrmFieldCollection::class,\n FilterDefinition\\CurrentStage::class,\n FilterDefinition\\Customer::class,\n FilterDefinition\\CustomerMonologueDuration::class,\n FilterDefinition\\CustomerQuestionCount::class,\n FilterDefinition\\DealAge::class,\n DealCloseDate::class,\n FilterDefinition\\DealValue::class,\n FilterDefinition\\EngagingQuestionCount::class,\n FilterDefinition\\ShowInternalExternalActivitiesFilter::class,\n FilterDefinition\\HasTranscription::class,\n FilterDefinition\\InsightfulQuestionCount::class,\n FilterDefinition\\LanguageFilterDefinition::class,\n FilterDefinition\\LoggedToCrm::class,\n FilterDefinition\\OrganiserGroupIn::class,\n FilterDefinition\\OrganiserUserIn::class,\n FilterDefinition\\PatienceRange::class,\n PlaybackTopicFilterDefinition::class,\n FilterDefinition\\ProviderFilterDefinition::class,\n FilterDefinition\\SortBy::class,\n FilterDefinition\\SpeechRate::class,\n FilterDefinition\\StageAtCallFilterDefinition::class,\n FilterDefinition\\TalkTimeRatio::class,\n FilterDefinition\\TeamMemberUserIn::class,\n FilterDefinition\\TranscriptionComposite::class,\n FilterDefinition\\UserMonologueDuration::class,\n FilterDefinition\\UserQuestionCount::class,\n FilterDefinition\\CommentCountRange::class,\n FilterDefinition\\HasPendingAiCrmNotes::class,\n ])\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all(),\n );\n }\n\n public function getOnDemandPageFilterSet(Criteria $criteria, User $consumer): FilterDefinitionCollection\n {\n return $this\n ->getOnDemandPageFilters()\n ->withCriteria($criteria)\n ->withConsumer($consumer)\n ->withRestrictions($consumer->getTeam());\n }\n\n /**\n * @return string[]\n */\n public function getArrayFilterKeys(User $consumer): array\n {\n return $this\n ->getOnDemandPageFilters()\n ->withConsumer($consumer)\n ->getPropertyTypes([FilterDefinitionCollection::PROPERTY_TYPE_ARRAY])\n ->keys()\n ->filter(static fn (string $key): bool => ! str_contains($key, '.'))\n ->values()\n ->all();\n }\n\n private function getTeamInsightsPageFilters(bool $isExport = false): FilterDefinitionCollection\n {\n $dateRangeFilterClass = $isExport\n ? FilterDefinition\\TeamInsights\\ConversationExport\\DateRangeFilter::class\n : FilterDefinition\\TeamInsights\\DateRangeFilter::class;\n\n return FilterDefinitionCollection::make(\n Collection::make([\n // special cases\n $dateRangeFilterClass,\n FilterDefinition\\TeamInsights\\Exists::class,\n\n // healthy restrictions\n RestrictTeam::class,\n RestrictUserGroupScope::class,\n RestrictActivityChannel::class,\n RestrictPublicActivitiesOnly::class,\n RestrictUserActive::class,\n\n // regular filters\n FilterDefinition\\ActivityChannel::class,\n FilterDefinition\\TeamInsights\\ActivityDurationRange::class,\n FilterDefinition\\ActivityPlaylistIn::class,\n FilterDefinition\\ActivityProviderIn::class,\n FilterDefinition\\TeamInsights\\ActivityRecorded::class,\n FilterDefinition\\ActivityType::class,\n FilterDefinition\\CoachingFeedbackAverageScore::class,\n AutoScoreFilter::class,\n AiCallScoreFilter::class,\n FilterDefinition\\CoachingFeedbackCoachUserIn::class,\n FilterDefinition\\CrmFieldCollection::class,\n FilterDefinition\\Customer::class,\n FilterDefinition\\CurrentStage::class,\n FilterDefinition\\CustomerMonologueDuration::class,\n FilterDefinition\\CustomerQuestionCount::class,\n FilterDefinition\\DealAge::class,\n DealCloseDate::class,\n FilterDefinition\\DealValue::class,\n FilterDefinition\\EngagingQuestionCount::class,\n FilterDefinition\\ShowInternalExternalActivitiesFilter::class,\n FilterDefinition\\InsightfulQuestionCount::class,\n FilterDefinition\\LanguageFilterDefinition::class,\n FilterDefinition\\LoggedToCrm::class,\n FilterDefinition\\TeamInsights\\UserInFilter::class,\n FilterDefinition\\TeamInsights\\UserGroupInFilter::class,\n FilterDefinition\\PatienceRange::class,\n PlaybackTopicFilterDefinition::class,\n FilterDefinition\\ProviderFilterDefinition::class,\n FilterDefinition\\SortBy::class,\n FilterDefinition\\SpeechRate::class,\n FilterDefinition\\StageAtCallFilterDefinition::class,\n FilterDefinition\\TalkTimeRatio::class,\n FilterDefinition\\TeamMemberUserIn::class,\n FilterDefinition\\TranscriptionComposite::class,\n FilterDefinition\\UserMonologueDuration::class,\n FilterDefinition\\UserQuestionCount::class,\n FilterDefinition\\CommentCountRange::class,\n // Relevant for topics in deals.\n ClosedDealsFilter::class,\n HasTopicTriggersFilterDefinition::class,\n TopicFilterDefinition::class,\n ])\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all(),\n );\n }\n\n private function getDealInsightsPageFilters(\n bool $useCreatedDate = false,\n bool $includeDealType = false,\n bool $includePipeline = false,\n ): FilterDefinitionCollection {\n if ($useCreatedDate) {\n $periodFilterClass = FilterDefinition\\DealInsights\\CreatedPeriodFilter::class;\n } else {\n $periodFilterClass = FilterDefinition\\DealInsights\\ClosingPeriodFilter::class;\n }\n\n $filterSet = [\n RestrictTeam::class,\n $periodFilterClass,\n FilterDefinition\\DealInsights\\UserInFilter::class,\n FilterDefinition\\DealInsights\\UserGroupInFilter::class,\n FilterDefinition\\DealInsights\\DealStageInFilter::class,\n FilterDefinition\\DealInsights\\DealNameFilter::class,\n ];\n\n if ($includePipeline) {\n $filterSet[] = FilterDefinition\\DealInsights\\DealPipelineInFilter::class;\n }\n\n if ($includeDealType) {\n $filterSet[] = FilterDefinition\\DealInsights\\DealTypeInFilter::class;\n }\n\n return FilterDefinitionCollection::make(\n Collection::make($filterSet)\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all(),\n );\n }\n\n public function getTeamInsightsPageFilterSet(\n Criteria $criteria,\n User $consumer,\n bool $isExport = false\n ): FilterDefinitionCollection {\n return $this\n ->getTeamInsightsPageFilters($isExport)\n ->withCriteria($criteria)\n ->withConsumer($consumer)\n ->withRestrictions($consumer->getTeam());\n }\n\n public function getDealInsightsPageFilterSet(\n Criteria $criteria,\n User $consumer\n ): FilterDefinitionCollection {\n $includeDealType = $this->shouldIncludeDealType($consumer);\n $includePipeline = $this->shouldIncludePipeline($consumer);\n $useCreatedDate = $this->shouldUseCreatedDate($consumer);\n\n return $this\n ->getDealInsightsPageFilters($useCreatedDate, $includeDealType, $includePipeline)\n ->withCriteria($criteria)\n ->withConsumer($consumer);\n }\n\n public function getTeamAiAutomationFilterSet(\n Criteria $criteria,\n User $consumer\n ): FilterDefinitionCollection {\n return $this\n ->getTeamAiAutomationPageFilterSet()\n ->withCriteria($criteria)\n ->withConsumer($consumer);\n }\n\n private function getTeamAiAutomationPageFilterSet(): FilterDefinitionCollection\n {\n $filterSet = [\n RestrictTeam::class,\n FilterDefinition\\DealInsights\\DealStageInFilter::class,\n ];\n\n return FilterDefinitionCollection::make(\n Collection::make($filterSet)\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all(),\n );\n }\n\n public function getHomepageFilterSet(Criteria $criteria, User $consumer): FilterDefinitionCollection\n {\n $filterDefinitionCollection = FilterDefinitionCollection::make(\n Collection::make([\n RestrictTeam::class,\n RestrictUserGroupScope::class,\n RestrictActivityChannel::class,\n RestrictUserActive::class,\n FilterDefinition\\Security\\PrivateMeetingsForCurrentUserOnly::class,\n FilterDefinition\\ActivityActualDate::class,\n FilterDefinition\\Customer::class,\n FilterDefinition\\ActivityChannel::class,\n FilterDefinition\\ActivityDurationRange::class,\n FilterDefinition\\ActivityProviderIn::class,\n FilterDefinition\\ActivityRecorded::class,\n FilterDefinition\\ActivityRecordingStopped::class,\n FilterDefinition\\ActivityScheduledDate::class,\n FilterDefinition\\ActivityStatusIn::class,\n FilterDefinition\\LoggedToCrm::class,\n FilterDefinition\\OrganiserUserIn::class,\n FilterDefinition\\OrganiserUserNotIn::class,\n FilterDefinition\\ProviderFilterDefinition::class,\n FilterDefinition\\SortBy::class,\n FilterDefinition\\UserGroupInOptionalFilter::class,\n FilterDefinition\\OnlyActiveUsers::class,\n ])\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all(),\n );\n $filterDefinitionCollection->withCriteria($criteria);\n $filterDefinitionCollection->withConsumer($consumer);\n\n return $filterDefinitionCollection;\n }\n\n public function getPartnerFilterSet(Criteria $criteria): FilterDefinitionCollection\n {\n $filterDefinitionCollection = FilterDefinitionCollection::make(\n Collection::make([\n RestrictActivityChannel::class,\n FilterDefinition\\OrganiserTeamIn::class,\n FilterDefinition\\ActivityUpdatedDate::class,\n FilterDefinition\\ActivityStatusIn::class,\n FilterDefinition\\SortBy::class,\n ])\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all()\n );\n $filterDefinitionCollection->withCriteria($criteria);\n\n return $filterDefinitionCollection;\n }\n\n private function shouldIncludeDealType(User $user): bool\n {\n $crmConfig = $user->getTeam()->getCrmConfiguration();\n $crmProviderName = $crmConfig->getProviderName();\n\n if (! array_key_exists($crmProviderName, Field::BUSINESS_TYPE_FIELDS)) {\n return false;\n }\n\n $layoutRepository = app(LayoutRepository::class);\n $layoutFields = $layoutRepository->getDealInsightLayoutFields($crmConfig);\n $dealTypeField = Field::BUSINESS_TYPE_FIELDS[$crmProviderName];\n\n if (! in_array($dealTypeField, $layoutFields)) {\n return false;\n }\n\n return true;\n }\n\n private function shouldIncludePipeline(User $user): bool\n {\n $crmConfig = $user->getTeam()->getCrmConfiguration();\n $crmProviderName = $crmConfig->getProviderName();\n\n if (in_array($crmProviderName, [\n Configuration::PROVIDER_SALESFORCE,\n Configuration::PROVIDER_INTEGRATION_APP,\n ])) {\n return false;\n }\n\n return true;\n }\n\n private function shouldUseCreatedDate(User $user): bool\n {\n $teamService = app(TeamService::class);\n\n return ! $teamService->useDealInsightsClosedDateFilter($user->getTeam());\n }\n}","depth":4,"value":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Component\\ActivitySearch\\Service;\n\nuse Illuminate\\Container\\Container;\nuse Illuminate\\Support\\Collection;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\AiCallScoreFilter;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\AutoScoreFilter;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\ClosedDealsFilter;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\DealCloseDate;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\HasTopicTriggersFilterDefinition;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\PlaybackTopicFilterDefinition;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\Security\\RestrictActivityChannel;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\Security\\RestrictPublicActivitiesOnly;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\Security\\RestrictTeam;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\Security\\RestrictUserActive;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\Security\\RestrictUserGroupScope;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinition\\TeamInsights\\TopicFilterDefinition;\nuse Jiminny\\Component\\ActivitySearch\\FilterDefinitionCollection;\nuse Jiminny\\Models\\Crm\\Field;\nuse Jiminny\\Models\\User;\nuse Jiminny\\Models\\Crm\\Configuration;\nuse Jiminny\\Repositories\\Crm\\LayoutRepository;\nuse Jiminny\\Services\\TeamService;\nuse Jiminny\\VO\\Repository\\OnDemandActivitySearch\\Criteria;\n\nclass ActivitySearch\n{\n private Container $container;\n\n public function __construct(Container $container)\n {\n $this->container = $container;\n }\n\n public function getOnDemandPageFilters(): FilterDefinitionCollection\n {\n return FilterDefinitionCollection::make(\n Collection::make([\n // special case filters\n FilterDefinition\\ActivityStatusIn::class,\n FilterDefinition\\ActivityUpdatedDate::class,\n FilterDefinition\\ActivityRecordingStopped::class,\n FilterDefinition\\ActivityFilter::class,\n FilterDefinition\\ExternalId::class,\n FilterDefinition\\NudgeRunId::class,\n FilterDefinition\\ParticipantUserIn::class,\n FilterDefinition\\PartnerFilterDefinition::class,\n\n // healthy restrictions\n RestrictTeam::class,\n RestrictUserGroupScope::class,\n RestrictActivityChannel::class,\n RestrictUserActive::class,\n FilterDefinition\\Security\\PrivateMeetingsForCurrentUserOnly::class,\n\n // regular filters\n FilterDefinition\\ActivityActualDate::class,\n FilterDefinition\\ActivityChannel::class,\n FilterDefinition\\ActivityDurationRange::class,\n FilterDefinition\\ActivityPlaylistIn::class,\n FilterDefinition\\ActivityProviderIn::class,\n FilterDefinition\\ActivityRecorded::class,\n FilterDefinition\\ActivityType::class,\n FilterDefinition\\CoachingFeedbackAverageScore::class,\n AutoScoreFilter::class,\n AiCallScoreFilter::class,\n FilterDefinition\\CoachingFeedbackCoachUserIn::class,\n FilterDefinition\\CrmFieldCollection::class,\n FilterDefinition\\CurrentStage::class,\n FilterDefinition\\Customer::class,\n FilterDefinition\\CustomerMonologueDuration::class,\n FilterDefinition\\CustomerQuestionCount::class,\n FilterDefinition\\DealAge::class,\n DealCloseDate::class,\n FilterDefinition\\DealValue::class,\n FilterDefinition\\EngagingQuestionCount::class,\n FilterDefinition\\ShowInternalExternalActivitiesFilter::class,\n FilterDefinition\\HasTranscription::class,\n FilterDefinition\\InsightfulQuestionCount::class,\n FilterDefinition\\LanguageFilterDefinition::class,\n FilterDefinition\\LoggedToCrm::class,\n FilterDefinition\\OrganiserGroupIn::class,\n FilterDefinition\\OrganiserUserIn::class,\n FilterDefinition\\PatienceRange::class,\n PlaybackTopicFilterDefinition::class,\n FilterDefinition\\ProviderFilterDefinition::class,\n FilterDefinition\\SortBy::class,\n FilterDefinition\\SpeechRate::class,\n FilterDefinition\\StageAtCallFilterDefinition::class,\n FilterDefinition\\TalkTimeRatio::class,\n FilterDefinition\\TeamMemberUserIn::class,\n FilterDefinition\\TranscriptionComposite::class,\n FilterDefinition\\UserMonologueDuration::class,\n FilterDefinition\\UserQuestionCount::class,\n FilterDefinition\\CommentCountRange::class,\n FilterDefinition\\HasPendingAiCrmNotes::class,\n ])\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all(),\n );\n }\n\n public function getOnDemandPageFilterSet(Criteria $criteria, User $consumer): FilterDefinitionCollection\n {\n return $this\n ->getOnDemandPageFilters()\n ->withCriteria($criteria)\n ->withConsumer($consumer)\n ->withRestrictions($consumer->getTeam());\n }\n\n /**\n * @return string[]\n */\n public function getArrayFilterKeys(User $consumer): array\n {\n return $this\n ->getOnDemandPageFilters()\n ->withConsumer($consumer)\n ->getPropertyTypes([FilterDefinitionCollection::PROPERTY_TYPE_ARRAY])\n ->keys()\n ->filter(static fn (string $key): bool => ! str_contains($key, '.'))\n ->values()\n ->all();\n }\n\n private function getTeamInsightsPageFilters(bool $isExport = false): FilterDefinitionCollection\n {\n $dateRangeFilterClass = $isExport\n ? FilterDefinition\\TeamInsights\\ConversationExport\\DateRangeFilter::class\n : FilterDefinition\\TeamInsights\\DateRangeFilter::class;\n\n return FilterDefinitionCollection::make(\n Collection::make([\n // special cases\n $dateRangeFilterClass,\n FilterDefinition\\TeamInsights\\Exists::class,\n\n // healthy restrictions\n RestrictTeam::class,\n RestrictUserGroupScope::class,\n RestrictActivityChannel::class,\n RestrictPublicActivitiesOnly::class,\n RestrictUserActive::class,\n\n // regular filters\n FilterDefinition\\ActivityChannel::class,\n FilterDefinition\\TeamInsights\\ActivityDurationRange::class,\n FilterDefinition\\ActivityPlaylistIn::class,\n FilterDefinition\\ActivityProviderIn::class,\n FilterDefinition\\TeamInsights\\ActivityRecorded::class,\n FilterDefinition\\ActivityType::class,\n FilterDefinition\\CoachingFeedbackAverageScore::class,\n AutoScoreFilter::class,\n AiCallScoreFilter::class,\n FilterDefinition\\CoachingFeedbackCoachUserIn::class,\n FilterDefinition\\CrmFieldCollection::class,\n FilterDefinition\\Customer::class,\n FilterDefinition\\CurrentStage::class,\n FilterDefinition\\CustomerMonologueDuration::class,\n FilterDefinition\\CustomerQuestionCount::class,\n FilterDefinition\\DealAge::class,\n DealCloseDate::class,\n FilterDefinition\\DealValue::class,\n FilterDefinition\\EngagingQuestionCount::class,\n FilterDefinition\\ShowInternalExternalActivitiesFilter::class,\n FilterDefinition\\InsightfulQuestionCount::class,\n FilterDefinition\\LanguageFilterDefinition::class,\n FilterDefinition\\LoggedToCrm::class,\n FilterDefinition\\TeamInsights\\UserInFilter::class,\n FilterDefinition\\TeamInsights\\UserGroupInFilter::class,\n FilterDefinition\\PatienceRange::class,\n PlaybackTopicFilterDefinition::class,\n FilterDefinition\\ProviderFilterDefinition::class,\n FilterDefinition\\SortBy::class,\n FilterDefinition\\SpeechRate::class,\n FilterDefinition\\StageAtCallFilterDefinition::class,\n FilterDefinition\\TalkTimeRatio::class,\n FilterDefinition\\TeamMemberUserIn::class,\n FilterDefinition\\TranscriptionComposite::class,\n FilterDefinition\\UserMonologueDuration::class,\n FilterDefinition\\UserQuestionCount::class,\n FilterDefinition\\CommentCountRange::class,\n // Relevant for topics in deals.\n ClosedDealsFilter::class,\n HasTopicTriggersFilterDefinition::class,\n TopicFilterDefinition::class,\n ])\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all(),\n );\n }\n\n private function getDealInsightsPageFilters(\n bool $useCreatedDate = false,\n bool $includeDealType = false,\n bool $includePipeline = false,\n ): FilterDefinitionCollection {\n if ($useCreatedDate) {\n $periodFilterClass = FilterDefinition\\DealInsights\\CreatedPeriodFilter::class;\n } else {\n $periodFilterClass = FilterDefinition\\DealInsights\\ClosingPeriodFilter::class;\n }\n\n $filterSet = [\n RestrictTeam::class,\n $periodFilterClass,\n FilterDefinition\\DealInsights\\UserInFilter::class,\n FilterDefinition\\DealInsights\\UserGroupInFilter::class,\n FilterDefinition\\DealInsights\\DealStageInFilter::class,\n FilterDefinition\\DealInsights\\DealNameFilter::class,\n ];\n\n if ($includePipeline) {\n $filterSet[] = FilterDefinition\\DealInsights\\DealPipelineInFilter::class;\n }\n\n if ($includeDealType) {\n $filterSet[] = FilterDefinition\\DealInsights\\DealTypeInFilter::class;\n }\n\n return FilterDefinitionCollection::make(\n Collection::make($filterSet)\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all(),\n );\n }\n\n public function getTeamInsightsPageFilterSet(\n Criteria $criteria,\n User $consumer,\n bool $isExport = false\n ): FilterDefinitionCollection {\n return $this\n ->getTeamInsightsPageFilters($isExport)\n ->withCriteria($criteria)\n ->withConsumer($consumer)\n ->withRestrictions($consumer->getTeam());\n }\n\n public function getDealInsightsPageFilterSet(\n Criteria $criteria,\n User $consumer\n ): FilterDefinitionCollection {\n $includeDealType = $this->shouldIncludeDealType($consumer);\n $includePipeline = $this->shouldIncludePipeline($consumer);\n $useCreatedDate = $this->shouldUseCreatedDate($consumer);\n\n return $this\n ->getDealInsightsPageFilters($useCreatedDate, $includeDealType, $includePipeline)\n ->withCriteria($criteria)\n ->withConsumer($consumer);\n }\n\n public function getTeamAiAutomationFilterSet(\n Criteria $criteria,\n User $consumer\n ): FilterDefinitionCollection {\n return $this\n ->getTeamAiAutomationPageFilterSet()\n ->withCriteria($criteria)\n ->withConsumer($consumer);\n }\n\n private function getTeamAiAutomationPageFilterSet(): FilterDefinitionCollection\n {\n $filterSet = [\n RestrictTeam::class,\n FilterDefinition\\DealInsights\\DealStageInFilter::class,\n ];\n\n return FilterDefinitionCollection::make(\n Collection::make($filterSet)\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all(),\n );\n }\n\n public function getHomepageFilterSet(Criteria $criteria, User $consumer): FilterDefinitionCollection\n {\n $filterDefinitionCollection = FilterDefinitionCollection::make(\n Collection::make([\n RestrictTeam::class,\n RestrictUserGroupScope::class,\n RestrictActivityChannel::class,\n RestrictUserActive::class,\n FilterDefinition\\Security\\PrivateMeetingsForCurrentUserOnly::class,\n FilterDefinition\\ActivityActualDate::class,\n FilterDefinition\\Customer::class,\n FilterDefinition\\ActivityChannel::class,\n FilterDefinition\\ActivityDurationRange::class,\n FilterDefinition\\ActivityProviderIn::class,\n FilterDefinition\\ActivityRecorded::class,\n FilterDefinition\\ActivityRecordingStopped::class,\n FilterDefinition\\ActivityScheduledDate::class,\n FilterDefinition\\ActivityStatusIn::class,\n FilterDefinition\\LoggedToCrm::class,\n FilterDefinition\\OrganiserUserIn::class,\n FilterDefinition\\OrganiserUserNotIn::class,\n FilterDefinition\\ProviderFilterDefinition::class,\n FilterDefinition\\SortBy::class,\n FilterDefinition\\UserGroupInOptionalFilter::class,\n FilterDefinition\\OnlyActiveUsers::class,\n ])\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all(),\n );\n $filterDefinitionCollection->withCriteria($criteria);\n $filterDefinitionCollection->withConsumer($consumer);\n\n return $filterDefinitionCollection;\n }\n\n public function getPartnerFilterSet(Criteria $criteria): FilterDefinitionCollection\n {\n $filterDefinitionCollection = FilterDefinitionCollection::make(\n Collection::make([\n RestrictActivityChannel::class,\n FilterDefinition\\OrganiserTeamIn::class,\n FilterDefinition\\ActivityUpdatedDate::class,\n FilterDefinition\\ActivityStatusIn::class,\n FilterDefinition\\SortBy::class,\n ])\n ->map(fn (string $className): FilterDefinition => $this->container->make($className))\n ->all()\n );\n $filterDefinitionCollection->withCriteria($criteria);\n\n return $filterDefinitionCollection;\n }\n\n private function shouldIncludeDealType(User $user): bool\n {\n $crmConfig = $user->getTeam()->getCrmConfiguration();\n $crmProviderName = $crmConfig->getProviderName();\n\n if (! array_key_exists($crmProviderName, Field::BUSINESS_TYPE_FIELDS)) {\n return false;\n }\n\n $layoutRepository = app(LayoutRepository::class);\n $layoutFields = $layoutRepository->getDealInsightLayoutFields($crmConfig);\n $dealTypeField = Field::BUSINESS_TYPE_FIELDS[$crmProviderName];\n\n if (! in_array($dealTypeField, $layoutFields)) {\n return false;\n }\n\n return true;\n }\n\n private function shouldIncludePipeline(User $user): bool\n {\n $crmConfig = $user->getTeam()->getCrmConfiguration();\n $crmProviderName = $crmConfig->getProviderName();\n\n if (in_array($crmProviderName, [\n Configuration::PROVIDER_SALESFORCE,\n Configuration::PROVIDER_INTEGRATION_APP,\n ])) {\n return false;\n }\n\n return true;\n }\n\n private function shouldUseCreatedDate(User $user): bool\n {\n $teamService = app(TeamService::class);\n\n return ! $teamService->useDealInsightsClosedDateFilter($user->getTeam());\n }\n}","role_description":"text entry area","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Sync Changes","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide This Notification","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":false,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Code changed:","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.088194445,"height":0.027777778},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"15","depth":4,"role_description":"text"},{"role":"AXStaticText","text":"4","depth":4,"role_description":"text"},{"role":"AXButton","text":"Previous Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Next Highlighted Error","depth":4,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXTextArea","text":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Repositories;\n\nuse Carbon\\CarbonImmutable;\nuse Illuminate\\Database\\Eloquent\\Builder;\nuse Illuminate\\Support\\Carbon;\nuse Illuminate\\Database\\Eloquent\\Collection;\nuse Illuminate\\Pagination\\LengthAwarePaginator;\nuse Illuminate\\Support\\Facades\\DB;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\AutomatedReportResult;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Models\\User;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\ReportSort;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\ReportSortDirection;\n\nclass AutomatedReportsRepository\n{\n /**\n * Create a new automated report\n *\n * @param array $data\n *\n * @return AutomatedReport\n */\n public function create(array $data): AutomatedReport\n {\n return AutomatedReport::create($data);\n }\n\n /**\n * Find an automated report by UUID\n *\n * @param string $uuid\n *\n * @return AutomatedReport|null\n */\n public function findByUuid(string $uuid): ?AutomatedReport\n {\n return AutomatedReport::where('uuid', AutomatedReport::toOptimized($uuid))->first();\n }\n\n public function findByIdOrUuid(string $idOrUuid): ?AutomatedReport\n {\n if (is_numeric($idOrUuid)) {\n return AutomatedReport::find((int) $idOrUuid);\n }\n\n return AutomatedReport::where('uuid', AutomatedReport::toOptimized($idOrUuid))->first();\n }\n\n /**\n * Retrieve all standard (non-Ask Jiminny) automated reports.\n *\n * @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.\n * @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.\n *\n * @return Collection<AutomatedReport>\n */\n public function getAllStandardReports(\n string $sortColumn = 'created_at',\n string $sortDirection = 'desc'\n ): Collection {\n return $this->buildSortedQuery($sortColumn, $sortDirection)\n ->whereNot('type', AutomatedReportsService::TYPE_ASK_JIMINNY)\n ->get();\n }\n\n /**\n * Retrieve all Ask Jiminny reports created by the given user.\n *\n * @param User $user The user whose reports to retrieve.\n * @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.\n * @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.\n *\n * @return Collection<AutomatedReport>\n */\n public function getAskJiminnyReportsByUser(\n User $user,\n string $sortColumn = 'created_at',\n string $sortDirection = 'desc'\n ): Collection {\n return $this->buildSortedQuery($sortColumn, $sortDirection)\n ->where('type', AutomatedReportsService::TYPE_ASK_JIMINNY)\n ->where('created_by', $user->getId())\n ->get();\n }\n\n private function buildSortedQuery(string $sortColumn, string $sortDirection): \\Illuminate\\Database\\Eloquent\\Builder\n {\n $allowedColumns = ['created_by', 'created_at'];\n if (! in_array($sortColumn, $allowedColumns)) {\n $sortColumn = 'created_at';\n }\n\n $sortDirection = strtolower($sortDirection) === 'asc' ? 'asc' : 'desc';\n\n $query = AutomatedReport::query()->with(['creator', 'team']);\n\n if ($sortColumn === 'created_by') {\n $query->leftJoin('users', 'users.id', '=', 'automated_reports.created_by')\n ->orderByRaw(\"users.name COLLATE utf8mb4_unicode_ci {$sortDirection}\")\n ->select('automated_reports.*');\n } else {\n $query->orderBy($sortColumn, $sortDirection);\n }\n\n return $query;\n }\n\n /**\n * Get all active and enabled reports with active teams for the specified frequency.\n *\n * @param string $frequency\n *\n * @return Collection<AutomatedReport>\n */\n public function getActiveReportsByFrequency(string $frequency): Collection\n {\n return AutomatedReport::where('automated_reports.status', true)\n ->where('automated_reports.frequency', $frequency)\n ->join('teams', 'automated_reports.team_id', '=', 'teams.id')\n ->where('teams.status', Team::STATUS_ACTIVE)\n ->where(function ($query) {\n $query->whereNull('automated_reports.expires_at')\n ->orWhere('automated_reports.expires_at', '>=', now()->toDateString());\n })\n ->select('automated_reports.*')\n ->get();\n }\n\n /**\n * Update an automated report\n *\n * @param AutomatedReport $report\n * @param array $data\n *\n * @return AutomatedReport\n */\n public function update(AutomatedReport $report, array $data): AutomatedReport\n {\n $report->update($data);\n\n return $report;\n }\n\n /**\n * Create a new automated report result.\n *\n * @param array $data The data to create the automated report result with.\n *\n * @return AutomatedReportResult The newly created automated report result.\n */\n public function createResult(array $data): AutomatedReportResult\n {\n return AutomatedReportResult::create($data);\n }\n\n /**\n * Find an automated report result by UUID.\n *\n * @param string $uuid The UUID to find the automated report result with.\n *\n * @return AutomatedReportResult|null The automated report result if found, otherwise null.\n */\n public function findResultByUuid(string $uuid): ?AutomatedReportResult\n {\n return AutomatedReportResult::where('uuid', AutomatedReportResult::toOptimized($uuid))->first();\n }\n\n public function findResultByUuidForUser(string $uuid, User $user): ?AutomatedReportResult\n {\n return AutomatedReportResult::query()\n ->where('uuid', AutomatedReportResult::toOptimized($uuid))\n ->whereHas('report', static function ($query) use ($user): void {\n $query->where('team_id', $user->getTeamId())\n ->where('created_by', $user->getId());\n })\n ->first();\n }\n\n public function findChildResult(AutomatedReportResult $result, string $type): ?AutomatedReportResult\n {\n return AutomatedReportResult::query()\n ->where('parent_id', $result->getId())\n ->where('media_type', $type)\n ->first();\n }\n\n public function getGeneratedNotSentResults(): Collection\n {\n return AutomatedReportResult::query()\n ->whereNotNull('generated_at')\n ->whereNull('sent_at')\n ->where('status', AutomatedReportResult::STATUS_GENERATED)\n ->whereHas('report')\n ->with('report')\n ->get();\n }\n\n public function getPaginatedUserReports(\n User $user,\n ReportSort $sort,\n ReportSortDirection $sortDirection,\n int $resultsPerPage,\n int $page,\n ?Carbon $fromDate,\n ?Carbon $toDate,\n array $teamIds,\n array $reportTypes,\n ?string $name,\n ): LengthAwarePaginator {\n $query = AutomatedReportResult::query()\n ->whereNotNull('automated_report_results.generated_at')\n ->join('automated_reports', 'automated_report_results.report_id', '=', 'automated_reports.id')\n ->where('automated_reports.team_id', $user->getTeamId())\n ->whereJsonContains('automated_reports.recipients->users', $user->getId())\n ->orderByRaw(\"$sort->value COLLATE utf8mb4_unicode_ci {$sortDirection->value}\")\n ->select('automated_report_results.*')\n ->with('report.team');\n\n if ($fromDate !== null && $toDate !== null) {\n $query->whereBetween('generated_at', [$fromDate, $toDate]);\n }\n\n if (! empty($teamIds)) {\n $query->where(function ($q) use ($teamIds) {\n foreach ($teamIds as $id) {\n $q->orWhereJsonContains('automated_reports.groups', $id);\n }\n });\n }\n\n if (! empty($reportTypes)) {\n $query->whereIn('automated_reports.type', $reportTypes);\n }\n\n if (! empty($name)) {\n $query->whereLike('name', \"%$name%\");\n }\n\n return $query->paginate($resultsPerPage, ['*'], 'page', $page);\n }\n\n public function countUserReports(User $user): int\n {\n return AutomatedReportResult::query()\n ->whereNotNull('generated_at')\n ->whereNotNull('sent_at')\n ->whereHas('report', function ($q) use ($user) {\n $q->where('team_id', $user->getTeamId())\n ->whereJsonContains('recipients->users', $user->getId());\n })\n ->count();\n }\n\n /**\n * Get report IDs for a specific team\n *\n * @param Team $team\n *\n * @return \\Illuminate\\Support\\Collection\n */\n public function getReportIdsByTeam(Team $team): \\Illuminate\\Support\\Collection\n {\n return AutomatedReport::where('team_id', $team->getId())->pluck('id');\n }\n\n /**\n * Get all reports for a specific team\n *\n * @param Team $team\n *\n * @return Collection\n */\n public function getReportsByTeam(Team $team): Collection\n {\n return AutomatedReport::where('team_id', $team->getId())->get();\n }\n\n /**\n * Get all report results for a specific report\n *\n * @param AutomatedReport $report\n *\n * @return Collection\n */\n public function getResultsByReport(AutomatedReport $report): Collection\n {\n return $this->getResultsByReportQuery($report)->get();\n }\n\n public function getResultsByReportQuery(AutomatedReport $report): Builder\n {\n return AutomatedReportResult::where('report_id', $report->getId());\n }\n\n public function getReportResultsQueryForRetention(Team $team, CarbonImmutable $retentionDate): Builder\n {\n $reportIds = $this->getReportIdsByTeam($team);\n\n return AutomatedReportResult::query()->whereIn('report_id', $reportIds)\n ->whereRaw('IFNULL(generated_at, created_at) <= ?', [$retentionDate]);\n }\n\n /**\n * @param int|null $teamId Optional team ID to filter results\n *\n * @return \\Illuminate\\Support\\Collection<int, int> Collection of team IDs\n */\n public function getTeamIdsWithReportsResults(?int $teamId = null): \\Illuminate\\Support\\Collection\n {\n $query = DB::table('automated_reports')\n ->join('teams', 'automated_reports.team_id', '=', 'teams.id')\n ->select('teams.id')\n ->distinct();\n\n if ($teamId !== null) {\n $query->where('teams.id', $teamId);\n }\n\n return $query->pluck('teams.id');\n }\n}","depth":4,"value":"<?php\n\ndeclare(strict_types=1);\n\nnamespace Jiminny\\Repositories;\n\nuse Carbon\\CarbonImmutable;\nuse Illuminate\\Database\\Eloquent\\Builder;\nuse Illuminate\\Support\\Carbon;\nuse Illuminate\\Database\\Eloquent\\Collection;\nuse Illuminate\\Pagination\\LengthAwarePaginator;\nuse Illuminate\\Support\\Facades\\DB;\nuse Jiminny\\Models\\AutomatedReport;\nuse Jiminny\\Models\\AutomatedReportResult;\nuse Jiminny\\Models\\Team;\nuse Jiminny\\Models\\User;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\AutomatedReportsService;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\ReportSort;\nuse Jiminny\\Services\\Kiosk\\AutomatedReports\\ReportSortDirection;\n\nclass AutomatedReportsRepository\n{\n /**\n * Create a new automated report\n *\n * @param array $data\n *\n * @return AutomatedReport\n */\n public function create(array $data): AutomatedReport\n {\n return AutomatedReport::create($data);\n }\n\n /**\n * Find an automated report by UUID\n *\n * @param string $uuid\n *\n * @return AutomatedReport|null\n */\n public function findByUuid(string $uuid): ?AutomatedReport\n {\n return AutomatedReport::where('uuid', AutomatedReport::toOptimized($uuid))->first();\n }\n\n public function findByIdOrUuid(string $idOrUuid): ?AutomatedReport\n {\n if (is_numeric($idOrUuid)) {\n return AutomatedReport::find((int) $idOrUuid);\n }\n\n return AutomatedReport::where('uuid', AutomatedReport::toOptimized($idOrUuid))->first();\n }\n\n /**\n * Retrieve all standard (non-Ask Jiminny) automated reports.\n *\n * @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.\n * @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.\n *\n * @return Collection<AutomatedReport>\n */\n public function getAllStandardReports(\n string $sortColumn = 'created_at',\n string $sortDirection = 'desc'\n ): Collection {\n return $this->buildSortedQuery($sortColumn, $sortDirection)\n ->whereNot('type', AutomatedReportsService::TYPE_ASK_JIMINNY)\n ->get();\n }\n\n /**\n * Retrieve all Ask Jiminny reports created by the given user.\n *\n * @param User $user The user whose reports to retrieve.\n * @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.\n * @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.\n *\n * @return Collection<AutomatedReport>\n */\n public function getAskJiminnyReportsByUser(\n User $user,\n string $sortColumn = 'created_at',\n string $sortDirection = 'desc'\n ): Collection {\n return $this->buildSortedQuery($sortColumn, $sortDirection)\n ->where('type', AutomatedReportsService::TYPE_ASK_JIMINNY)\n ->where('created_by', $user->getId())\n ->get();\n }\n\n private function buildSortedQuery(string $sortColumn, string $sortDirection): \\Illuminate\\Database\\Eloquent\\Builder\n {\n $allowedColumns = ['created_by', 'created_at'];\n if (! in_array($sortColumn, $allowedColumns)) {\n $sortColumn = 'created_at';\n }\n\n $sortDirection = strtolower($sortDirection) === 'asc' ? 'asc' : 'desc';\n\n $query = AutomatedReport::query()->with(['creator', 'team']);\n\n if ($sortColumn === 'created_by') {\n $query->leftJoin('users', 'users.id', '=', 'automated_reports.created_by')\n ->orderByRaw(\"users.name COLLATE utf8mb4_unicode_ci {$sortDirection}\")\n ->select('automated_reports.*');\n } else {\n $query->orderBy($sortColumn, $sortDirection);\n }\n\n return $query;\n }\n\n /**\n * Get all active and enabled reports with active teams for the specified frequency.\n *\n * @param string $frequency\n *\n * @return Collection<AutomatedReport>\n */\n public function getActiveReportsByFrequency(string $frequency): Collection\n {\n return AutomatedReport::where('automated_reports.status', true)\n ->where('automated_reports.frequency', $frequency)\n ->join('teams', 'automated_reports.team_id', '=', 'teams.id')\n ->where('teams.status', Team::STATUS_ACTIVE)\n ->where(function ($query) {\n $query->whereNull('automated_reports.expires_at')\n ->orWhere('automated_reports.expires_at', '>=', now()->toDateString());\n })\n ->select('automated_reports.*')\n ->get();\n }\n\n /**\n * Update an automated report\n *\n * @param AutomatedReport $report\n * @param array $data\n *\n * @return AutomatedReport\n */\n public function update(AutomatedReport $report, array $data): AutomatedReport\n {\n $report->update($data);\n\n return $report;\n }\n\n /**\n * Create a new automated report result.\n *\n * @param array $data The data to create the automated report result with.\n *\n * @return AutomatedReportResult The newly created automated report result.\n */\n public function createResult(array $data): AutomatedReportResult\n {\n return AutomatedReportResult::create($data);\n }\n\n /**\n * Find an automated report result by UUID.\n *\n * @param string $uuid The UUID to find the automated report result with.\n *\n * @return AutomatedReportResult|null The automated report result if found, otherwise null.\n */\n public function findResultByUuid(string $uuid): ?AutomatedReportResult\n {\n return AutomatedReportResult::where('uuid', AutomatedReportResult::toOptimized($uuid))->first();\n }\n\n public function findResultByUuidForUser(string $uuid, User $user): ?AutomatedReportResult\n {\n return AutomatedReportResult::query()\n ->where('uuid', AutomatedReportResult::toOptimized($uuid))\n ->whereHas('report', static function ($query) use ($user): void {\n $query->where('team_id', $user->getTeamId())\n ->where('created_by', $user->getId());\n })\n ->first();\n }\n\n public function findChildResult(AutomatedReportResult $result, string $type): ?AutomatedReportResult\n {\n return AutomatedReportResult::query()\n ->where('parent_id', $result->getId())\n ->where('media_type', $type)\n ->first();\n }\n\n public function getGeneratedNotSentResults(): Collection\n {\n return AutomatedReportResult::query()\n ->whereNotNull('generated_at')\n ->whereNull('sent_at')\n ->where('status', AutomatedReportResult::STATUS_GENERATED)\n ->whereHas('report')\n ->with('report')\n ->get();\n }\n\n public function getPaginatedUserReports(\n User $user,\n ReportSort $sort,\n ReportSortDirection $sortDirection,\n int $resultsPerPage,\n int $page,\n ?Carbon $fromDate,\n ?Carbon $toDate,\n array $teamIds,\n array $reportTypes,\n ?string $name,\n ): LengthAwarePaginator {\n $query = AutomatedReportResult::query()\n ->whereNotNull('automated_report_results.generated_at')\n ->join('automated_reports', 'automated_report_results.report_id', '=', 'automated_reports.id')\n ->where('automated_reports.team_id', $user->getTeamId())\n ->whereJsonContains('automated_reports.recipients->users', $user->getId())\n ->orderByRaw(\"$sort->value COLLATE utf8mb4_unicode_ci {$sortDirection->value}\")\n ->select('automated_report_results.*')\n ->with('report.team');\n\n if ($fromDate !== null && $toDate !== null) {\n $query->whereBetween('generated_at', [$fromDate, $toDate]);\n }\n\n if (! empty($teamIds)) {\n $query->where(function ($q) use ($teamIds) {\n foreach ($teamIds as $id) {\n $q->orWhereJsonContains('automated_reports.groups', $id);\n }\n });\n }\n\n if (! empty($reportTypes)) {\n $query->whereIn('automated_reports.type', $reportTypes);\n }\n\n if (! empty($name)) {\n $query->whereLike('name', \"%$name%\");\n }\n\n return $query->paginate($resultsPerPage, ['*'], 'page', $page);\n }\n\n public function countUserReports(User $user): int\n {\n return AutomatedReportResult::query()\n ->whereNotNull('generated_at')\n ->whereNotNull('sent_at')\n ->whereHas('report', function ($q) use ($user) {\n $q->where('team_id', $user->getTeamId())\n ->whereJsonContains('recipients->users', $user->getId());\n })\n ->count();\n }\n\n /**\n * Get report IDs for a specific team\n *\n * @param Team $team\n *\n * @return \\Illuminate\\Support\\Collection\n */\n public function getReportIdsByTeam(Team $team): \\Illuminate\\Support\\Collection\n {\n return AutomatedReport::where('team_id', $team->getId())->pluck('id');\n }\n\n /**\n * Get all reports for a specific team\n *\n * @param Team $team\n *\n * @return Collection\n */\n public function getReportsByTeam(Team $team): Collection\n {\n return AutomatedReport::where('team_id', $team->getId())->get();\n }\n\n /**\n * Get all report results for a specific report\n *\n * @param AutomatedReport $report\n *\n * @return Collection\n */\n public function getResultsByReport(AutomatedReport $report): Collection\n {\n return $this->getResultsByReportQuery($report)->get();\n }\n\n public function getResultsByReportQuery(AutomatedReport $report): Builder\n {\n return AutomatedReportResult::where('report_id', $report->getId());\n }\n\n public function getReportResultsQueryForRetention(Team $team, CarbonImmutable $retentionDate): Builder\n {\n $reportIds = $this->getReportIdsByTeam($team);\n\n return AutomatedReportResult::query()->whereIn('report_id', $reportIds)\n ->whereRaw('IFNULL(generated_at, created_at) <= ?', [$retentionDate]);\n }\n\n /**\n * @param int|null $teamId Optional team ID to filter results\n *\n * @return \\Illuminate\\Support\\Collection<int, int> Collection of team IDs\n */\n public function getTeamIdsWithReportsResults(?int $teamId = null): \\Illuminate\\Support\\Collection\n {\n $query = DB::table('automated_reports')\n ->join('teams', 'automated_reports.team_id', '=', 'teams.id')\n ->select('teams.id')\n ->distinct();\n\n if ($teamId !== null) {\n $query->where('teams.id', $teamId);\n }\n\n return $query->pluck('teams.id');\n }\n}","role_description":"text entry area","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"Project","depth":3,"role_description":"text"},{"role":"AXButton","text":"Project","depth":3,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"New File or Directory…","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Expand Selected","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Collapse All","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Options","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Hide","depth":4,"bounds":{"left":0.0,"top":0.0,"width":0.018055556,"height":0.026666667},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXStaticText","text":"app ~/jiminny/app","depth":6,"role_description":"text"},{"role":"AXStaticText","text":".circleci","depth":7,"role_description":"text"},{"role":"AXStaticText","text":".cursor","depth":7,"role_description":"text"},{"role":"AXStaticText","text":".github","depth":7,"role_description":"text"},{"role":"AXStaticText","text":".sonarlint","depth":7,"role_description":"text"},{"role":"AXStaticText","text":".vscode","depth":7,"role_description":"text"},{"role":"AXStaticText","text":".windsurf","depth":7,"role_description":"text"},{"role":"AXStaticText","text":"app, sources root","depth":7,"role_description":"text"},{"role":"AXStaticText","text":"Actions","depth":8,"role_description":"text"},{"role":"AXStaticText","text":"Component","depth":8,"role_description":"text"},{"role":"AXStaticText","text":"Acl, folder","depth":9,"role_description":"text"},{"role":"AXStaticText","text":"ActionItems, folder","depth":9,"role_description":"text"},{"role":"AXStaticText","text":"Activity, folder","depth":9,"role_description":"text"},{"role":"AXStaticText","text":"ActivityAnalytics, folder","depth":9,"role_description":"text"},{"role":"AXStaticText","text":"ActivitySearch, folder","depth":9,"role_description":"text"},{"role":"AXStaticText","text":"EventSubscriber, folder","depth":10,"role_description":"text"},{"role":"AXStaticText","text":"FilterDefinition, folder","depth":10,"role_description":"text"},{"role":"AXStaticText","text":"Service","depth":10,"role_description":"text"},{"role":"AXStaticText","text":"ActivityApiSearch.php, class","depth":11,"role_description":"text"},{"role":"AXStaticText","text":"ActivitySearch.php, class","depth":11,"role_description":"text"},{"role":"AXStaticText","text":"UserOptionsByGroup.php, class","depth":11,"role_description":"text"},{"role":"AXStaticText","text":"AbstractStageFilterDefinition.php, abstract class","depth":10,"role_description":"text"},{"role":"AXStaticText","text":"ActivitySearchServiceProvider.php, final class","depth":10,"role_description":"text"},{"role":"AXStaticText","text":"DealInsightsPeriodFilterFactory.php","depth":10,"role_description":"text"},{"role":"AXStaticText","text":"DealInsightsPeriodFilterFactoryInterface.php, interface","depth":10,"role_description":"text"}]...
|
-9182788673990637262
|
-3734346844552059324
|
click
|
accessibility
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
AskJiminnyReportActivityServiceT…Defaults
Rerun 'PHPUnit: AskJiminnyReportActivityServiceTest.testGetActivityIdsPassesNonZeroSequenceNumberToDisableFirstRequestDefaults'
Debug 'AskJiminnyReportActivityServiceTest.tes…uenceNumberToDisableFirstRequestDefaults'
Stop 'AskJiminnyReportActivityServiceTest.testGetActivityIdsPassesNonZeroSequenceNumberToDisableFirstRequestDefaults'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
Sync Changes
Hide This Notification
Code changed:
Hide
<?php
declare(strict_types=1);
namespace Jiminny\Component\ActivitySearch\Service;
use Illuminate\Container\Container;
use Illuminate\Support\Collection;
use Jiminny\Component\ActivitySearch\FilterDefinition;
use Jiminny\Component\ActivitySearch\FilterDefinition\AiCallScoreFilter;
use Jiminny\Component\ActivitySearch\FilterDefinition\AutoScoreFilter;
use Jiminny\Component\ActivitySearch\FilterDefinition\ClosedDealsFilter;
use Jiminny\Component\ActivitySearch\FilterDefinition\DealCloseDate;
use Jiminny\Component\ActivitySearch\FilterDefinition\HasTopicTriggersFilterDefinition;
use Jiminny\Component\ActivitySearch\FilterDefinition\PlaybackTopicFilterDefinition;
use Jiminny\Component\ActivitySearch\FilterDefinition\Security\RestrictActivityChannel;
use Jiminny\Component\ActivitySearch\FilterDefinition\Security\RestrictPublicActivitiesOnly;
use Jiminny\Component\ActivitySearch\FilterDefinition\Security\RestrictTeam;
use Jiminny\Component\ActivitySearch\FilterDefinition\Security\RestrictUserActive;
use Jiminny\Component\ActivitySearch\FilterDefinition\Security\RestrictUserGroupScope;
use Jiminny\Component\ActivitySearch\FilterDefinition\TeamInsights\TopicFilterDefinition;
use Jiminny\Component\ActivitySearch\FilterDefinitionCollection;
use Jiminny\Models\Crm\Field;
use Jiminny\Models\User;
use Jiminny\Models\Crm\Configuration;
use Jiminny\Repositories\Crm\LayoutRepository;
use Jiminny\Services\TeamService;
use Jiminny\VO\Repository\OnDemandActivitySearch\Criteria;
class ActivitySearch
{
private Container $container;
public function __construct(Container $container)
{
$this->container = $container;
}
public function getOnDemandPageFilters(): FilterDefinitionCollection
{
return FilterDefinitionCollection::make(
Collection::make([
// special case filters
FilterDefinition\ActivityStatusIn::class,
FilterDefinition\ActivityUpdatedDate::class,
FilterDefinition\ActivityRecordingStopped::class,
FilterDefinition\ActivityFilter::class,
FilterDefinition\ExternalId::class,
FilterDefinition\NudgeRunId::class,
FilterDefinition\ParticipantUserIn::class,
FilterDefinition\PartnerFilterDefinition::class,
// healthy restrictions
RestrictTeam::class,
RestrictUserGroupScope::class,
RestrictActivityChannel::class,
RestrictUserActive::class,
FilterDefinition\Security\PrivateMeetingsForCurrentUserOnly::class,
// regular filters
FilterDefinition\ActivityActualDate::class,
FilterDefinition\ActivityChannel::class,
FilterDefinition\ActivityDurationRange::class,
FilterDefinition\ActivityPlaylistIn::class,
FilterDefinition\ActivityProviderIn::class,
FilterDefinition\ActivityRecorded::class,
FilterDefinition\ActivityType::class,
FilterDefinition\CoachingFeedbackAverageScore::class,
AutoScoreFilter::class,
AiCallScoreFilter::class,
FilterDefinition\CoachingFeedbackCoachUserIn::class,
FilterDefinition\CrmFieldCollection::class,
FilterDefinition\CurrentStage::class,
FilterDefinition\Customer::class,
FilterDefinition\CustomerMonologueDuration::class,
FilterDefinition\CustomerQuestionCount::class,
FilterDefinition\DealAge::class,
DealCloseDate::class,
FilterDefinition\DealValue::class,
FilterDefinition\EngagingQuestionCount::class,
FilterDefinition\ShowInternalExternalActivitiesFilter::class,
FilterDefinition\HasTranscription::class,
FilterDefinition\InsightfulQuestionCount::class,
FilterDefinition\LanguageFilterDefinition::class,
FilterDefinition\LoggedToCrm::class,
FilterDefinition\OrganiserGroupIn:[PASSWORD]
FilterDefinition\OrganiserUserIn::class,
FilterDefinition\PatienceRange::class,
PlaybackTopicFilterDefinition::class,
FilterDefinition\ProviderFilterDefinition::class,
FilterDefinition\SortBy::class,
FilterDefinition\SpeechRate::class,
FilterDefinition\StageAtCallFilterDefinition::class,
FilterDefinition\TalkTimeRatio::class,
FilterDefinition\TeamMemberUserIn::class,
FilterDefinition\TranscriptionComposite::class,
FilterDefinition\UserMonologueDuration::class,
FilterDefinition\UserQuestionCount::class,
FilterDefinition\CommentCountRange::class,
FilterDefinition\HasPendingAiCrmNotes::class,
])
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all(),
);
}
public function getOnDemandPageFilterSet(Criteria $criteria, User $consumer): FilterDefinitionCollection
{
return $this
->getOnDemandPageFilters()
->withCriteria($criteria)
->withConsumer($consumer)
->withRestrictions($consumer->getTeam());
}
/**
* @return string[]
*/
public function getArrayFilterKeys(User $consumer): array
{
return $this
->getOnDemandPageFilters()
->withConsumer($consumer)
->getPropertyTypes([FilterDefinitionCollection::PROPERTY_TYPE_ARRAY])
->keys()
->filter(static fn (string $key): bool => ! str_contains($key, '.'))
->values()
->all();
}
private function getTeamInsightsPageFilters(bool $isExport = false): FilterDefinitionCollection
{
$dateRangeFilterClass = $isExport
? FilterDefinition\TeamInsights\ConversationExport\DateRangeFilter::class
: FilterDefinition\TeamInsights\DateRangeFilter::class;
return FilterDefinitionCollection::make(
Collection::make([
// special cases
$dateRangeFilterClass,
FilterDefinition\TeamInsights\Exists::class,
// healthy restrictions
RestrictTeam::class,
RestrictUserGroupScope::class,
RestrictActivityChannel::class,
RestrictPublicActivitiesOnly::class,
RestrictUserActive::class,
// regular filters
FilterDefinition\ActivityChannel::class,
FilterDefinition\TeamInsights\ActivityDurationRange::class,
FilterDefinition\ActivityPlaylistIn::class,
FilterDefinition\ActivityProviderIn::class,
FilterDefinition\TeamInsights\ActivityRecorded::class,
FilterDefinition\ActivityType::class,
FilterDefinition\CoachingFeedbackAverageScore::class,
AutoScoreFilter::class,
AiCallScoreFilter::class,
FilterDefinition\CoachingFeedbackCoachUserIn::class,
FilterDefinition\CrmFieldCollection::class,
FilterDefinition\Customer::class,
FilterDefinition\CurrentStage::class,
FilterDefinition\CustomerMonologueDuration::class,
FilterDefinition\CustomerQuestionCount::class,
FilterDefinition\DealAge::class,
DealCloseDate::class,
FilterDefinition\DealValue::class,
FilterDefinition\EngagingQuestionCount::class,
FilterDefinition\ShowInternalExternalActivitiesFilter::class,
FilterDefinition\InsightfulQuestionCount::class,
FilterDefinition\LanguageFilterDefinition::class,
FilterDefinition\LoggedToCrm::class,
FilterDefinition\TeamInsights\UserInFilter::class,
FilterDefinition\TeamInsights\UserGroupInFilter::class,
FilterDefinition\PatienceRange::class,
PlaybackTopicFilterDefinition::class,
FilterDefinition\ProviderFilterDefinition::class,
FilterDefinition\SortBy::class,
FilterDefinition\SpeechRate::class,
FilterDefinition\StageAtCallFilterDefinition::class,
FilterDefinition\TalkTimeRatio::class,
FilterDefinition\TeamMemberUserIn::class,
FilterDefinition\TranscriptionComposite::class,
FilterDefinition\UserMonologueDuration::class,
FilterDefinition\UserQuestionCount::class,
FilterDefinition\CommentCountRange::class,
// Relevant for topics in deals.
ClosedDealsFilter::class,
HasTopicTriggersFilterDefinition::class,
TopicFilterDefinition::class,
])
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all(),
);
}
private function getDealInsightsPageFilters(
bool $useCreatedDate = false,
bool $includeDealType = false,
bool $includePipeline = false,
): FilterDefinitionCollection {
if ($useCreatedDate) {
$periodFilterClass = FilterDefinition\DealInsights\CreatedPeriodFilter::class;
} else {
$periodFilterClass = FilterDefinition\DealInsights\ClosingPeriodFilter::class;
}
$filterSet = [
RestrictTeam::class,
$periodFilterClass,
FilterDefinition\DealInsights\UserInFilter::class,
FilterDefinition\DealInsights\UserGroupInFilter::class,
FilterDefinition\DealInsights\DealStageInFilter::class,
FilterDefinition\DealInsights\DealNameFilter::class,
];
if ($includePipeline) {
$filterSet[] = FilterDefinition\DealInsights\DealPipelineInFilter::class;
}
if ($includeDealType) {
$filterSet[] = FilterDefinition\DealInsights\DealTypeInFilter::class;
}
return FilterDefinitionCollection::make(
Collection::make($filterSet)
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all(),
);
}
public function getTeamInsightsPageFilterSet(
Criteria $criteria,
User $consumer,
bool $isExport = false
): FilterDefinitionCollection {
return $this
->getTeamInsightsPageFilters($isExport)
->withCriteria($criteria)
->withConsumer($consumer)
->withRestrictions($consumer->getTeam());
}
public function getDealInsightsPageFilterSet(
Criteria $criteria,
User $consumer
): FilterDefinitionCollection {
$includeDealType = $this->shouldIncludeDealType($consumer);
$includePipeline = $this->shouldIncludePipeline($consumer);
$useCreatedDate = $this->shouldUseCreatedDate($consumer);
return $this
->getDealInsightsPageFilters($useCreatedDate, $includeDealType, $includePipeline)
->withCriteria($criteria)
->withConsumer($consumer);
}
public function getTeamAiAutomationFilterSet(
Criteria $criteria,
User $consumer
): FilterDefinitionCollection {
return $this
->getTeamAiAutomationPageFilterSet()
->withCriteria($criteria)
->withConsumer($consumer);
}
private function getTeamAiAutomationPageFilterSet(): FilterDefinitionCollection
{
$filterSet = [
RestrictTeam::class,
FilterDefinition\DealInsights\DealStageInFilter::class,
];
return FilterDefinitionCollection::make(
Collection::make($filterSet)
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all(),
);
}
public function getHomepageFilterSet(Criteria $criteria, User $consumer): FilterDefinitionCollection
{
$filterDefinitionCollection = FilterDefinitionCollection::make(
Collection::make([
RestrictTeam::class,
RestrictUserGroupScope::class,
RestrictActivityChannel::class,
RestrictUserActive::class,
FilterDefinition\Security\PrivateMeetingsForCurrentUserOnly::class,
FilterDefinition\ActivityActualDate::class,
FilterDefinition\Customer::class,
FilterDefinition\ActivityChannel::class,
FilterDefinition\ActivityDurationRange::class,
FilterDefinition\ActivityProviderIn::class,
FilterDefinition\ActivityRecorded::class,
FilterDefinition\ActivityRecordingStopped::class,
FilterDefinition\ActivityScheduledDate::class,
FilterDefinition\ActivityStatusIn::class,
FilterDefinition\LoggedToCrm::class,
FilterDefinition\OrganiserUserIn::class,
FilterDefinition\OrganiserUserNotIn::class,
FilterDefinition\ProviderFilterDefinition::class,
FilterDefinition\SortBy::class,
FilterDefinition\UserGroupInOptionalFilter::class,
FilterDefinition\OnlyActiveUsers::class,
])
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all(),
);
$filterDefinitionCollection->withCriteria($criteria);
$filterDefinitionCollection->withConsumer($consumer);
return $filterDefinitionCollection;
}
public function getPartnerFilterSet(Criteria $criteria): FilterDefinitionCollection
{
$filterDefinitionCollection = FilterDefinitionCollection::make(
Collection::make([
RestrictActivityChannel::class,
FilterDefinition\OrganiserTeamIn::class,
FilterDefinition\ActivityUpdatedDate::class,
FilterDefinition\ActivityStatusIn::class,
FilterDefinition\SortBy::class,
])
->map(fn (string $className): FilterDefinition => $this->container->make($className))
->all()
);
$filterDefinitionCollection->withCriteria($criteria);
return $filterDefinitionCollection;
}
private function shouldIncludeDealType(User $user): bool
{
$crmConfig = $user->getTeam()->getCrmConfiguration();
$crmProviderName = $crmConfig->getProviderName();
if (! array_key_exists($crmProviderName, Field::BUSINESS_TYPE_FIELDS)) {
return false;
}
$layoutRepository = app(LayoutRepository::class);
$layoutFields = $layoutRepository->getDealInsightLayoutFields($crmConfig);
$dealTypeField = Field::BUSINESS_TYPE_FIELDS[$crmProviderName];
if (! in_array($dealTypeField, $layoutFields)) {
return false;
}
return true;
}
private function shouldIncludePipeline(User $user): bool
{
$crmConfig = $user->getTeam()->getCrmConfiguration();
$crmProviderName = $crmConfig->getProviderName();
if (in_array($crmProviderName, [
Configuration::PROVIDER_SALESFORCE,
Configuration::PROVIDER_INTEGRATION_APP,
])) {
return false;
}
return true;
}
private function shouldUseCreatedDate(User $user): bool
{
$teamService = app(TeamService::class);
return ! $teamService->useDealInsightsClosedDateFilter($user->getTeam());
}
}
Sync Changes
Hide This Notification
Code changed:
Hide
15
4
Previous Highlighted Error
Next Highlighted Error
<?php
declare(strict_types=1);
namespace Jiminny\Repositories;
use Carbon\CarbonImmutable;
use Illuminate\Database\Eloquent\Builder;
use Illuminate\Support\Carbon;
use Illuminate\Database\Eloquent\Collection;
use Illuminate\Pagination\LengthAwarePaginator;
use Illuminate\Support\Facades\DB;
use Jiminny\Models\AutomatedReport;
use Jiminny\Models\AutomatedReportResult;
use Jiminny\Models\Team;
use Jiminny\Models\User;
use Jiminny\Services\Kiosk\AutomatedReports\AutomatedReportsService;
use Jiminny\Services\Kiosk\AutomatedReports\ReportSort;
use Jiminny\Services\Kiosk\AutomatedReports\ReportSortDirection;
class AutomatedReportsRepository
{
/**
* Create a new automated report
*
* @param array $data
*
* @return AutomatedReport
*/
public function create(array $data): AutomatedReport
{
return AutomatedReport::create($data);
}
/**
* Find an automated report by UUID
*
* @param string $uuid
*
* @return AutomatedReport|null
*/
public function findByUuid(string $uuid): ?AutomatedReport
{
return AutomatedReport::where('uuid', AutomatedReport::toOptimized($uuid))->first();
}
public function findByIdOrUuid(string $idOrUuid): ?AutomatedReport
{
if (is_numeric($idOrUuid)) {
return AutomatedReport::find((int) $idOrUuid);
}
return AutomatedReport::where('uuid', AutomatedReport::toOptimized($idOrUuid))->first();
}
/**
* Retrieve all standard (non-Ask Jiminny) automated reports.
*
* @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.
* @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.
*
* @return Collection<AutomatedReport>
*/
public function getAllStandardReports(
string $sortColumn = 'created_at',
string $sortDirection = 'desc'
): Collection {
return $this->buildSortedQuery($sortColumn, $sortDirection)
->whereNot('type', AutomatedReportsService::TYPE_ASK_JIMINNY)
->get();
}
/**
* Retrieve all Ask Jiminny reports created by the given user.
*
* @param User $user The user whose reports to retrieve.
* @param string $sortColumn The column to sort by. Allowed values: 'created_by', 'created_at'. Defaults to 'created_at'.
* @param string $sortDirection The sort direction. Allowed values: 'asc', 'desc'. Defaults to 'desc'.
*
* @return Collection<AutomatedReport>
*/
public function getAskJiminnyReportsByUser(
User $user,
string $sortColumn = 'created_at',
string $sortDirection = 'desc'
): Collection {
return $this->buildSortedQuery($sortColumn, $sortDirection)
->where('type', AutomatedReportsService::TYPE_ASK_JIMINNY)
->where('created_by', $user->getId())
->get();
}
private function buildSortedQuery(string $sortColumn, string $sortDirection): \Illuminate\Database\Eloquent\Builder
{
$allowedColumns = ['created_by', 'created_at'];
if (! in_array($sortColumn, $allowedColumns)) {
$sortColumn = 'created_at';
}
$sortDirection = strtolower($sortDirection) === 'asc' ? 'asc' : 'desc';
$query = AutomatedReport::query()->with(['creator', 'team']);
if ($sortColumn === 'created_by') {
$query->leftJoin('users', 'users.id', '=', 'automated_reports.created_by')
->orderByRaw("users.name COLLATE utf8mb4_unicode_ci {$sortDirection}")
->select('automated_reports.*');
} else {
$query->orderBy($sortColumn, $sortDirection);
}
return $query;
}
/**
* Get all active and enabled reports with active teams for the specified frequency.
*
* @param string $frequency
*
* @return Collection<AutomatedReport>
*/
public function getActiveReportsByFrequency(string $frequency): Collection
{
return AutomatedReport::where('automated_reports.status', true)
->where('automated_reports.frequency', $frequency)
->join('teams', 'automated_reports.team_id', '=', 'teams.id')
->where('teams.status', Team::STATUS_ACTIVE)
->where(function ($query) {
$query->whereNull('automated_reports.expires_at')
->orWhere('automated_reports.expires_at', '>=', now()->toDateString());
})
->select('automated_reports.*')
->get();
}
/**
* Update an automated report
*
* @param AutomatedReport $report
* @param array $data
*
* @return AutomatedReport
*/
public function update(AutomatedReport $report, array $data): AutomatedReport
{
$report->update($data);
return $report;
}
/**
* Create a new automated report result.
*
* @param array $data The data to create the automated report result with.
*
* @return AutomatedReportResult The newly created automated report result.
*/
public function createResult(array $data): AutomatedReportResult
{
return AutomatedReportResult::create($data);
}
/**
* Find an automated report result by UUID.
*
* @param string $uuid The UUID to find the automated report result with.
*
* @return AutomatedReportResult|null The automated report result if found, otherwise null.
*/
public function findResultByUuid(string $uuid): ?AutomatedReportResult
{
return AutomatedReportResult::where('uuid', AutomatedReportResult::toOptimized($uuid))->first();
}
public function findResultByUuidForUser(string $uuid, User $user): ?AutomatedReportResult
{
return AutomatedReportResult::query()
->where('uuid', AutomatedReportResult::toOptimized($uuid))
->whereHas('report', static function ($query) use ($user): void {
$query->where('team_id', $user->getTeamId())
->where('created_by', $user->getId());
})
->first();
}
public function findChildResult(AutomatedReportResult $result, string $type): ?AutomatedReportResult
{
return AutomatedReportResult::query()
->where('parent_id', $result->getId())
->where('media_type', $type)
->first();
}
public function getGeneratedNotSentResults(): Collection
{
return AutomatedReportResult::query()
->whereNotNull('generated_at')
->whereNull('sent_at')
->where('status', AutomatedReportResult::STATUS_GENERATED)
->whereHas('report')
->with('report')
->get();
}
public function getPaginatedUserReports(
User $user,
ReportSort $sort,
ReportSortDirection $sortDirection,
int $resultsPerPage,
int $page,
?Carbon $fromDate,
?Carbon $toDate,
array $teamIds,
array $reportTypes,
?string $name,
): LengthAwarePaginator {
$query = AutomatedReportResult::query()
->whereNotNull('automated_report_results.generated_at')
->join('automated_reports', 'automated_report_results.report_id', '=', 'automated_reports.id')
->where('automated_reports.team_id', $user->getTeamId())
->whereJsonContains('automated_reports.recipients->users', $user->getId())
->orderByRaw("$sort->value COLLATE utf8mb4_unicode_ci {$sortDirection->value}")
->select('automated_report_results.*')
->with('report.team');
if ($fromDate !== null && $toDate !== null) {
$query->whereBetween('generated_at', [$fromDate, $toDate]);
}
if (! empty($teamIds)) {
$query->where(function ($q) use ($teamIds) {
foreach ($teamIds as $id) {
$q->orWhereJsonContains('automated_reports.groups', $id);
}
});
}
if (! empty($reportTypes)) {
$query->whereIn('automated_reports.type', $reportTypes);
}
if (! empty($name)) {
$query->whereLike('name', "%$name%");
}
return $query->paginate($resultsPerPage, ['*'], 'page', $page);
}
public function countUserReports(User $user): int
{
return AutomatedReportResult::query()
->whereNotNull('generated_at')
->whereNotNull('sent_at')
->whereHas('report', function ($q) use ($user) {
$q->where('team_id', $user->getTeamId())
->whereJsonContains('recipients->users', $user->getId());
})
->count();
}
/**
* Get report IDs for a specific team
*
* @param Team $team
*
* @return \Illuminate\Support\Collection
*/
public function getReportIdsByTeam(Team $team): \Illuminate\Support\Collection
{
return AutomatedReport::where('team_id', $team->getId())->pluck('id');
}
/**
* Get all reports for a specific team
*
* @param Team $team
*
* @return Collection
*/
public function getReportsByTeam(Team $team): Collection
{
return AutomatedReport::where('team_id', $team->getId())->get();
}
/**
* Get all report results for a specific report
*
* @param AutomatedReport $report
*
* @return Collection
*/
public function getResultsByReport(AutomatedReport $report): Collection
{
return $this->getResultsByReportQuery($report)->get();
}
public function getResultsByReportQuery(AutomatedReport $report): Builder
{
return AutomatedReportResult::where('report_id', $report->getId());
}
public function getReportResultsQueryForRetention(Team $team, CarbonImmutable $retentionDate): Builder
{
$reportIds = $this->getReportIdsByTeam($team);
return AutomatedReportResult::query()->whereIn('report_id', $reportIds)
->whereRaw('IFNULL(generated_at, created_at) <= ?', [$retentionDate]);
}
/**
* @param int|null $teamId Optional team ID to filter results
*
* @return \Illuminate\Support\Collection<int, int> Collection of team IDs
*/
public function getTeamIdsWithReportsResults(?int $teamId = null): \Illuminate\Support\Collection
{
$query = DB::table('automated_reports')
->join('teams', 'automated_reports.team_id', '=', 'teams.id')
->select('teams.id')
->distinct();
if ($teamId !== null) {
$query->where('teams.id', $teamId);
}
return $query->pluck('teams.id');
}
}
Project
Project
New File or Directory…
Expand Selected
Collapse All
Options
Hide
app ~/jiminny/app
.circleci
.cursor
.github
.sonarlint
.vscode
.windsurf
app, sources root
Actions
Component
Acl, folder
ActionItems, folder
Activity, folder
ActivityAnalytics, folder
ActivitySearch, folder
EventSubscriber, folder
FilterDefinition, folder
Service
ActivityApiSearch.php, class
ActivitySearch.php, class
UserOptionsByGroup.php, class
AbstractStageFilterDefinition.php, abstract class
ActivitySearchServiceProvider.php, final class
DealInsightsPeriodFilterFactory.php
DealInsightsPeriodFilterFactoryInterface.php, interface...
|
NULL
|
|
11128
|
NULL
|
0
|
2026-04-14T09:14:07.319751+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776158047319_m1.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
+SlackEDHomeDMSActivityFilesLater..•More+FileEditV +SlackEDHomeDMSActivityFilesLater..•More+FileEditViewGoHistoryWindowHelpJiminny ...# Starredplatform-inner-teamChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi…..Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili.... Adelina PetrovaO. Calea Dimitravo→Search Jiminny IncAneliya Angelova, Nikolay Yankov, Steliyan GeorgievMessagesAdd canvas+Nikolay Yankov 10:45 AMпиши кат оя рьннешLukas Kovalik 10:52 AMзабавих се че ми се разбазикаха settings за средипуснах и мина и fail-наима result но e failedзначиREASON_NOT_ENOUGH_ACTIVITIESвиж дали има нещо в OD със този филтьрNikolay Yankov 11:01 AMДобреNikolay Yankov 11:39 AMя рьнни пак LukasLukas Kovalik 11:43 AMготовосьщотоCompetitive pitches беше втория нали такаNikolay Yankov 12:04 PMДа, там има 14 активитита, защо не сработи този пьт?Lukas Kovalik 12:05 PMпак изглежда sequenceгледам гоMessage Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev+Aalal]Support Daily - in 2h 46 m100% <47Tue 14 Apr 12:14:068Today ~...
|
NULL
|
1122675946128104533
|
NULL
|
click
|
ocr
|
NULL
|
+SlackEDHomeDMSActivityFilesLater..•More+FileEditV +SlackEDHomeDMSActivityFilesLater..•More+FileEditViewGoHistoryWindowHelpJiminny ...# Starredplatform-inner-teamChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi…..Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili.... Adelina PetrovaO. Calea Dimitravo→Search Jiminny IncAneliya Angelova, Nikolay Yankov, Steliyan GeorgievMessagesAdd canvas+Nikolay Yankov 10:45 AMпиши кат оя рьннешLukas Kovalik 10:52 AMзабавих се че ми се разбазикаха settings за средипуснах и мина и fail-наима result но e failedзначиREASON_NOT_ENOUGH_ACTIVITIESвиж дали има нещо в OD със този филтьрNikolay Yankov 11:01 AMДобреNikolay Yankov 11:39 AMя рьнни пак LukasLukas Kovalik 11:43 AMготовосьщотоCompetitive pitches беше втория нали такаNikolay Yankov 12:04 PMДа, там има 14 активитита, защо не сработи този пьт?Lukas Kovalik 12:05 PMпак изглежда sequenceгледам гоMessage Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev+Aalal]Support Daily - in 2h 46 m100% <47Tue 14 Apr 12:14:068Today ~...
|
11126
|
|
11129
|
NULL
|
0
|
2026-04-14T09:14:08.120867+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776158048120_m2.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
PhpStormFileEditViewNavigateCodeLaravelRefactorFV PhpStormFileEditViewNavigateCodeLaravelRefactorFV faVsco.s v#11894 on JY-18909-automated-reports-ask-iminny K vProject vToolsWindowHelp© JiminnyDebugCommanc© JiminnySetEncryptedTo© JiminnyTokenInfoComn© MakeSlackLiveCoachins© ManageScimForTeam.p(c Malkoanchrorenvironnc Mureu canzercnanner© PhpApm.php(C) PropagateCoachingFee© PurgeConferences.php© PurgeSoftDeletedOppor© PurgeSyncBatchesComiC RecalculateDealRisksCa© RemoveDeleteMarkersC© RemoveExpiredNudgesi© RemoveUnusedParticip:© ResetElasticsearch.phpc resto eAcctvrvcimrroy© RestoreActivityTypeCor© SeedActivities.php© SyncActivity.php©Tracklmported.php© UpdateActivitiesAverag© WhichWorkerlsWorkingr> D Scheduling© Kernel.php> D Contracts> M Domain> MDTO> M Emails› _ Enums> D Events> D Exceptions> DJ FFMpeg>D Formats› D Guards> D Helpersv UHttp> @ AccessTokenProviderv D ControllersV DAPI> DAiCallScoringAiReports> D Deallnsights> D Opportunity> C Page> • Scorecards> D SettingsTeamInsightsD Themes> MUserAutomatedRepov DV2C ACIMINVACONTOAskAnythingCont© AskJiminnyReporl© DealsV2Controlle:© OnDemandV2Cor© PlaylistController.© PlaylistShareCont© ReportController.php© AutomatedReportsCommand.phpyJiminnyDeouecommana.ong= custom.log< console LUl= laravel.logA SF [jiminny@localhost]A HS_local [jiminny@localhost]console SlAGiNG© AskJiminnyReportActivityService.phgA console [PROD]© ActivitySearch.pnp© Criteria.php© AutomatedReportsSendCommand.php© AddLayoutEntities.php© Team.php© AutomatedReportsRepository.php X© AutomatedReportsService.phpC CreateHeldActivityEvent.phpOnDemandV2Controller.php >© HistoryService.php© AskJiminnyReportActivityServiceTest.php© FilterDefinitionCollection.php© RequestGenerateAskJiminnyReportJobTest.phpCc W .*TIT:(e) TrackProvidernstallled-vent.ono© CreateActivityLoggedEvent.php• ActivityLogged.php© RequestGenerateAskJiminnyReportJob.phpRequestGenerateReportJob.php(C) AutomatedReport.php© UserPilotActivityListener.php(C) AutomatedReportsCallbackService.php© AutomatedReportResult.phpactivitySearch2.10.25 Kovalik2.10.25Kovalik2.10.25Kovalik2.10.25Kovalik2.10.25KovalikZ.10.23KovalikKovalik2.10.25KOVallKI<?phpA1X2 A Vdeclare(strict_types=1);mnamesoace Jalmnny htte controulens Ar>use ...class Automacedкeрortskepo o:A15 X4 ^61931141151161171181191211124123L.lU.Lonovallk2.10.25novallk2.10.25Kovalik2.10.25Kovalik* Retrieve all standard (non-Ask Jiminny) Mclass OnDemandV2Controller extends Controlleruse AuthorizesRequests;* @param string $sortColumnThe column tc31.10.25 Ivanov* Oparam string $sortDirection The sort dire 2.10.25Kovalikprivate const int DEFAULT_TOP_ACTIVITIES_COUNT = 100;* @return Collection<AutomatedReport>12 usagespublic function getAllStandardReports(string $sortColumn = 'created_at',string $sortDirection = 'desc'): Collection {...J19.12.25 Nikolov19.12.25 Nikolov19.12.25 Nikolov19.12.25 Nikolov19.12.25 Nikolov19.12.25 Nikolov19.12.25 Nikolov19.12.25 Nikolovprivate const array FILTER_KEY JE&CLUDED_PARAMS = [sequence_nunber'page','per_page','limit','offset',/*** Retrieve all Ask Liminny reports created2.10.25Kovalik2.10.25Kovalik* Oodrdll usernusenIne user Ynos2.10.25Kovalik* @param string $sortColumnThe column tc 2.10.25Kovalik* Oparam string $sortDirection The sort dire2.10.25KOVallKIzu.ll.zo Ivanov* @return Collection<AutomatedReport>8.10.25novallk*/2.10.25Kovalik14 usages2.10.25Kovalikpublic function getAskJiminnyReportsByUser(2.10.25KovalikUser $user,2.10.25Kovalikstring $sortColumn = 'created_at',17.10.25 Kovalikstring ssorcbirection = "desc"17.10.25 Kovalik): Collection {...}17.10.25 Kovalikpublic function __construct(private readonly ActivitySearch Saprivate readonly HistoryService ShistoryService,privace readonty Propnetservice spropnetservice,privace readonty leamaiconcexckepostcory preamaiconcexckeposicory.private readonly ActiveStreamsRepository $activeStreamsRepository,private readonly EventDispatcher $eventDispatcher,private readonly LoggerInterface $logger,/*** Check if the user's team has the ASK_JIMINNY_ON_ANYTHING feature enabled*/Ordo KoVallk2 usagesprivate function buildSortedQuery(string $sor17.10.25 Kovalik2.10.25novallk2.10.25Kovalik* Get all active and enabled reports with ac2.10.25Kovalik2.10.25* @param string $frequency2.10.25Kovalik2.10.25onvare Tuncron checkastunnvunanyum norectureluser "user, rusonkescons* Get top N activity IDs for Ask Jiminny feature based on filters* Othrows ValidationException* Othrows ActivityProviderException* dreturh coLcectzon<aucomacedкeрort>2.10.25Kovalik78 (LPpubuic tunccion gecconcexcrorAskanychingbyrilter kequest grequest, ElasulcA23 usagesZ.10.23Kovalikpublic function getActiveReportsByFrequency(s2.10.25Kovalik/** @var User $user */2.10.25KovalikTests passed: 1 (5 minutes ago), 0lablf Support Daily • in 2h 46 mAAskJiminnyReportActivityServiceT…Defaults100% C•Tue 14 Apr 12:14:07CascadeFixing ReportControllerAutomated Report MarFixing Ask Jiminny Rep+D..Now let's run the test to verifvwo desker nxe dovkcrs/ko3k Automwa/wports/arman yRgportActzvityserväceTest-php --no-coverageloul nor oen ndlr Tler var wi nunbarusanCommand dockerdoster nxe ceockes /kJosk/AuP /ape/a/poras/A5kJ1minyReportActivityServiceTest.php --no-coverageCould not open input file: /app/artisanCommand dockeroocker exec oocker vand ioash -d"cd /var/www&& php artisan testLests unlu services Klosk Aucomaceakeporcs AskJiminnykeportAccivityservicelest.ono =-no-coverade D&l'Could not open input file: artisan• docker exec docker_lamp_1 bash -c "find / -name artisan -maxdepth 6 2>/dev/null | head -5"/home/jiminny/artisan"cd /homee/jiminny && php artisan testtests/ext/ drvicrs/K2psk/Autonat eReports/A5KDiman ReportActivatyServiceTest,php --no-coverage 261"PASSgetTests\Unit\Services\Kiosk\AutomatedReports\AskJiminnyReportActivityServiceTestfiltersemoty when no resultsE tatt tnt hperiod date filtersids bassess snazer fsequence number to disable first _ 0.025All 8 tests pass. Here's a summary:Root Cause & FixRoot cause: buildRequestParamsFromSearch never set sequence number in the request params, so Criteria::createFromRequest defaulted it to 0Since isFirstRequest() returns true when sequenceNumber === 0, several implicit defaults were silently applied:Activitvourat ionRande → min duration = 1 Tilters ouf o-second activitiesiActivityRecorded → only_recorded = 1 (restricts to recorded activities only)OrganiserGroupin → apolies user's derault croup as a tiltelThe frontend URL you noticed uses sequence_number=4, which disables these defaults - explaining why the frontend returned activities but the servicereturned O.Fix: AskJiminnyReportActivityService.php:51—added 'sequence_number' » 1 to the Criteria::createFromRequest merge, ensuring isFirstRequest() returns false and no implicit defaults are injected.Test added: testGetAct.1cylasPassesNonzerosequencenumberloDisablerarsckequestberaulus assers that the captured uriteria ob ect nas 1srirstRequest() === false.Öul ..Vew allliItlle wiun changesvapp/Services/Kiosk/AutomatedReports/D AskJiminnyReportActivityService.php +1 -1Reject allAccept allExplain it to me again. Why is there issue with that? Where is it expected and why do l need to work with that. How is it used [EMAIL] | am trying to fetch the activities based on savedSearch‹> CodeClaude Sonnet 4.6winasun leams39:36uir-o( 4 spaces...
|
NULL
|
3294500289672538558
|
NULL
|
click
|
ocr
|
NULL
|
PhpStormFileEditViewNavigateCodeLaravelRefactorFV PhpStormFileEditViewNavigateCodeLaravelRefactorFV faVsco.s v#11894 on JY-18909-automated-reports-ask-iminny K vProject vToolsWindowHelp© JiminnyDebugCommanc© JiminnySetEncryptedTo© JiminnyTokenInfoComn© MakeSlackLiveCoachins© ManageScimForTeam.p(c Malkoanchrorenvironnc Mureu canzercnanner© PhpApm.php(C) PropagateCoachingFee© PurgeConferences.php© PurgeSoftDeletedOppor© PurgeSyncBatchesComiC RecalculateDealRisksCa© RemoveDeleteMarkersC© RemoveExpiredNudgesi© RemoveUnusedParticip:© ResetElasticsearch.phpc resto eAcctvrvcimrroy© RestoreActivityTypeCor© SeedActivities.php© SyncActivity.php©Tracklmported.php© UpdateActivitiesAverag© WhichWorkerlsWorkingr> D Scheduling© Kernel.php> D Contracts> M Domain> MDTO> M Emails› _ Enums> D Events> D Exceptions> DJ FFMpeg>D Formats› D Guards> D Helpersv UHttp> @ AccessTokenProviderv D ControllersV DAPI> DAiCallScoringAiReports> D Deallnsights> D Opportunity> C Page> • Scorecards> D SettingsTeamInsightsD Themes> MUserAutomatedRepov DV2C ACIMINVACONTOAskAnythingCont© AskJiminnyReporl© DealsV2Controlle:© OnDemandV2Cor© PlaylistController.© PlaylistShareCont© ReportController.php© AutomatedReportsCommand.phpyJiminnyDeouecommana.ong= custom.log< console LUl= laravel.logA SF [jiminny@localhost]A HS_local [jiminny@localhost]console SlAGiNG© AskJiminnyReportActivityService.phgA console [PROD]© ActivitySearch.pnp© Criteria.php© AutomatedReportsSendCommand.php© AddLayoutEntities.php© Team.php© AutomatedReportsRepository.php X© AutomatedReportsService.phpC CreateHeldActivityEvent.phpOnDemandV2Controller.php >© HistoryService.php© AskJiminnyReportActivityServiceTest.php© FilterDefinitionCollection.php© RequestGenerateAskJiminnyReportJobTest.phpCc W .*TIT:(e) TrackProvidernstallled-vent.ono© CreateActivityLoggedEvent.php• ActivityLogged.php© RequestGenerateAskJiminnyReportJob.phpRequestGenerateReportJob.php(C) AutomatedReport.php© UserPilotActivityListener.php(C) AutomatedReportsCallbackService.php© AutomatedReportResult.phpactivitySearch2.10.25 Kovalik2.10.25Kovalik2.10.25Kovalik2.10.25Kovalik2.10.25KovalikZ.10.23KovalikKovalik2.10.25KOVallKI<?phpA1X2 A Vdeclare(strict_types=1);mnamesoace Jalmnny htte controulens Ar>use ...class Automacedкeрortskepo o:A15 X4 ^61931141151161171181191211124123L.lU.Lonovallk2.10.25novallk2.10.25Kovalik2.10.25Kovalik* Retrieve all standard (non-Ask Jiminny) Mclass OnDemandV2Controller extends Controlleruse AuthorizesRequests;* @param string $sortColumnThe column tc31.10.25 Ivanov* Oparam string $sortDirection The sort dire 2.10.25Kovalikprivate const int DEFAULT_TOP_ACTIVITIES_COUNT = 100;* @return Collection<AutomatedReport>12 usagespublic function getAllStandardReports(string $sortColumn = 'created_at',string $sortDirection = 'desc'): Collection {...J19.12.25 Nikolov19.12.25 Nikolov19.12.25 Nikolov19.12.25 Nikolov19.12.25 Nikolov19.12.25 Nikolov19.12.25 Nikolov19.12.25 Nikolovprivate const array FILTER_KEY JE&CLUDED_PARAMS = [sequence_nunber'page','per_page','limit','offset',/*** Retrieve all Ask Liminny reports created2.10.25Kovalik2.10.25Kovalik* Oodrdll usernusenIne user Ynos2.10.25Kovalik* @param string $sortColumnThe column tc 2.10.25Kovalik* Oparam string $sortDirection The sort dire2.10.25KOVallKIzu.ll.zo Ivanov* @return Collection<AutomatedReport>8.10.25novallk*/2.10.25Kovalik14 usages2.10.25Kovalikpublic function getAskJiminnyReportsByUser(2.10.25KovalikUser $user,2.10.25Kovalikstring $sortColumn = 'created_at',17.10.25 Kovalikstring ssorcbirection = "desc"17.10.25 Kovalik): Collection {...}17.10.25 Kovalikpublic function __construct(private readonly ActivitySearch Saprivate readonly HistoryService ShistoryService,privace readonty Propnetservice spropnetservice,privace readonty leamaiconcexckepostcory preamaiconcexckeposicory.private readonly ActiveStreamsRepository $activeStreamsRepository,private readonly EventDispatcher $eventDispatcher,private readonly LoggerInterface $logger,/*** Check if the user's team has the ASK_JIMINNY_ON_ANYTHING feature enabled*/Ordo KoVallk2 usagesprivate function buildSortedQuery(string $sor17.10.25 Kovalik2.10.25novallk2.10.25Kovalik* Get all active and enabled reports with ac2.10.25Kovalik2.10.25* @param string $frequency2.10.25Kovalik2.10.25onvare Tuncron checkastunnvunanyum norectureluser "user, rusonkescons* Get top N activity IDs for Ask Jiminny feature based on filters* Othrows ValidationException* Othrows ActivityProviderException* dreturh coLcectzon<aucomacedкeрort>2.10.25Kovalik78 (LPpubuic tunccion gecconcexcrorAskanychingbyrilter kequest grequest, ElasulcA23 usagesZ.10.23Kovalikpublic function getActiveReportsByFrequency(s2.10.25Kovalik/** @var User $user */2.10.25KovalikTests passed: 1 (5 minutes ago), 0lablf Support Daily • in 2h 46 mAAskJiminnyReportActivityServiceT…Defaults100% C•Tue 14 Apr 12:14:07CascadeFixing ReportControllerAutomated Report MarFixing Ask Jiminny Rep+D..Now let's run the test to verifvwo desker nxe dovkcrs/ko3k Automwa/wports/arman yRgportActzvityserväceTest-php --no-coverageloul nor oen ndlr Tler var wi nunbarusanCommand dockerdoster nxe ceockes /kJosk/AuP /ape/a/poras/A5kJ1minyReportActivityServiceTest.php --no-coverageCould not open input file: /app/artisanCommand dockeroocker exec oocker vand ioash -d"cd /var/www&& php artisan testLests unlu services Klosk Aucomaceakeporcs AskJiminnykeportAccivityservicelest.ono =-no-coverade D&l'Could not open input file: artisan• docker exec docker_lamp_1 bash -c "find / -name artisan -maxdepth 6 2>/dev/null | head -5"/home/jiminny/artisan"cd /homee/jiminny && php artisan testtests/ext/ drvicrs/K2psk/Autonat eReports/A5KDiman ReportActivatyServiceTest,php --no-coverage 261"PASSgetTests\Unit\Services\Kiosk\AutomatedReports\AskJiminnyReportActivityServiceTestfiltersemoty when no resultsE tatt tnt hperiod date filtersids bassess snazer fsequence number to disable first _ 0.025All 8 tests pass. Here's a summary:Root Cause & FixRoot cause: buildRequestParamsFromSearch never set sequence number in the request params, so Criteria::createFromRequest defaulted it to 0Since isFirstRequest() returns true when sequenceNumber === 0, several implicit defaults were silently applied:Activitvourat ionRande → min duration = 1 Tilters ouf o-second activitiesiActivityRecorded → only_recorded = 1 (restricts to recorded activities only)OrganiserGroupin → apolies user's derault croup as a tiltelThe frontend URL you noticed uses sequence_number=4, which disables these defaults - explaining why the frontend returned activities but the servicereturned O.Fix: AskJiminnyReportActivityService.php:51—added 'sequence_number' » 1 to the Criteria::createFromRequest merge, ensuring isFirstRequest() returns false and no implicit defaults are injected.Test added: testGetAct.1cylasPassesNonzerosequencenumberloDisablerarsckequestberaulus assers that the captured uriteria ob ect nas 1srirstRequest() === false.Öul ..Vew allliItlle wiun changesvapp/Services/Kiosk/AutomatedReports/D AskJiminnyReportActivityService.php +1 -1Reject allAccept allExplain it to me again. Why is there issue with that? Where is it expected and why do l need to work with that. How is it used [EMAIL] | am trying to fetch the activities based on savedSearch‹> CodeClaude Sonnet 4.6winasun leams39:36uir-o( 4 spaces...
|
NULL
|
|
11130
|
220
|
0
|
2026-04-14T09:14:11.913533+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776158051913_m1.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
+SlackEDHomeDMSActivityFilesLater..•More+FileEditV +SlackEDHomeDMSActivityFilesLater..•More+FileEditViewGoHistoryWindowHelpJiminny ...# Starredplatform-inner-teamChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi…..Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili.... Adelina PetrovaO. Calea Dimitravo→Search Jiminny IncAneliya Angelova, Nikolay Yankov, Steliyan GeorgievMessagesAdd canvas+Nikolay Yankov 10:45 AMпиши кат оя рьннешLukas Kovalik 10:52 AMзабавих се че ми се разбазикаха settings за средипуснах и мина и fail-наима result но e failedзначиREASON_NOT_ENOUGH_ACTIVITIESвиж дали има нещо в OD със този филтьрNikolay Yankov 11:01 AMДобреNikolay Yankov 11:39 AMя рьнни пак LukasLukas Kovalik 11:43 AMготовосьщотоCompetitive pitches беше втория нали такаNikolay Yankov 12:04 PMДа, там има 14 активитита, защо не сработи този пьт?Lukas Kovalik 12:05 PMпак изглежда sequenceгледам гоMessage Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev+Aalal]Support Daily - in 2h 46 m100% <47Tue 14 Apr 12:14:118Today ~...
|
NULL
|
2272296577739235966
|
NULL
|
click
|
ocr
|
NULL
|
+SlackEDHomeDMSActivityFilesLater..•More+FileEditV +SlackEDHomeDMSActivityFilesLater..•More+FileEditViewGoHistoryWindowHelpJiminny ...# Starredplatform-inner-teamChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi…..Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili.... Adelina PetrovaO. Calea Dimitravo→Search Jiminny IncAneliya Angelova, Nikolay Yankov, Steliyan GeorgievMessagesAdd canvas+Nikolay Yankov 10:45 AMпиши кат оя рьннешLukas Kovalik 10:52 AMзабавих се че ми се разбазикаха settings за средипуснах и мина и fail-наима result но e failedзначиREASON_NOT_ENOUGH_ACTIVITIESвиж дали има нещо в OD със този филтьрNikolay Yankov 11:01 AMДобреNikolay Yankov 11:39 AMя рьнни пак LukasLukas Kovalik 11:43 AMготовосьщотоCompetitive pitches беше втория нали такаNikolay Yankov 12:04 PMДа, там има 14 активитита, защо не сработи този пьт?Lukas Kovalik 12:05 PMпак изглежда sequenceгледам гоMessage Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev+Aalal]Support Daily - in 2h 46 m100% <47Tue 14 Apr 12:14:118Today ~...
|
NULL
|
|
11131
|
221
|
0
|
2026-04-14T09:14:11.947514+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776158051947_m2.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
PhpStormFileEditViewNavigateCodeLaravelRefactorFV PhpStormFileEditViewNavigateCodeLaravelRefactorFV faVsco.js#11894 on JY-18909-automated-reports-ask-iminny K vProject vToolsWindowHelp© JiminnyDebugCommanc©JiminnySetEncryptedTo© JiminnyTokenInfoComm© MakeSlackLiveCoachins© ManageScimForTeam.p(c Malkoanchrocnvronnlc Mureu canzercnanner© PhpApm.php© PropagateCoachingFeer© PurgeConferences.php© PurgeSoftDeletedOppor© PurgeSyncBatchesComiC RecalculateDealRisksCa© RemoveDeleteMarkersC© RemoveExpiredNudgesi© RemoveUnusedParticip:© ResetElasticsearch.phpc resto eAcctvrvcimrroy© RestoreActivityTypeCor© SeedActivities.php© SyncActivity.php©Tracklmported.php© UpdateActivitiesAverag© WhichWorkerlsWorkingr> D Scheduling© Kernel.php> D Contracts> M Domain> MDTO> M Emails› _ Enums> D Events> D Exceptions> DJ FFMpeg>D Formats› D Guards› Helpersv UHttp> @ AccessTokenProviderv D ControllersV DAPI> D AiCallScoringAiReports> D Deallnsights> D Opportunity> C Page> • Scorecards> D SettingsTeamInsightsD Themes> MUserAutomatedRepov DV2C ACIMINVACOnTOAskAnythingCont© AskJiminnyReporl© DealsV2Controlle:© OnDemandV2Cor© PlaylistController.© PlaylistShareContNavicale lo the next occurrence© ReportController.php© AutomatedReportsCommand.phpyJiminnyDeouecommana.ong= custom.log< console EUi= laravel.logA SF [jiminny@localhost]A HS_local [jiminny@localhost]console SlAGiNG© AskJiminnyReportActivityService.phgA console [PROD]© ActivitySearch.pnp© Criteria.php© AutomatedReportsSendCommand.php© AddLayoutEntities.php© Team.php© AutomatedReportsRepository.php X© AutomatedReportsService.phpC CreateHeldActivityEvent.phpOnDemandV2Controller.php© HistoryService.php© AskJiminnyReportActivityServiceTest.phpFILIER KLY EXCLUDED PARAMS© FilterDefinitionCollection.php© RequestGenerateAskJiminnyReportJobTest.phpcc w .*TAT :(e) TrackProvidernstallled-vent.ono© CreateActivityLoggedEvent.php• ActivityLogged.php© RequestGenerateAskJiminnyReportJob.phpRequestGenerateReportJob.php(C) AutomatedReport.php© UserPilotActivityListener.php(C) AutomatedReportsCallbackService.php© AutomatedReportResult.phpZ.10.23KovalikKovallik4.10.40Kovallk2.10.25Kovallk2.10.25Kovalik2.10.25Kovalik2.10.25Kovalik2.10.25Kovalik<?phpA1X2 A Vaeclare strict types-1namespace Jiminny\Http\Controllers\API\V2;› use ..class Automacedкeрortskepo o:A15 X4 A619311411511611711811912111241232.10.25Kovalik2.10.25KovalikZ.10.23Kovalik* Retrieve all standard (non-Ask Jiminny) M2.10.25Kovalikclass OnDemandV2Controller extends Controlleruse Authorizeskequests)* @param string $sortColumnThe column tc 31.10.25 Ivanov* Cparam string $sortDirection The sort dire 2.10.25 Kovalikprivate const int DEFAULT_TOP_ACTIVITIES_COUNT = 100;* @return Collection<AutomatedReport>12 usagespublic function getAllStandardReports(string $sortColumn = 'created_at',string $sortDirection = 'desc'): Collection {...J19.12.25 Nikolov19.12.25 Nikolov19.12.25 Nikolov19.12.25 Nikolov19.12.25 Nikolov19.12.25 Nikolov19.12.25 NikolovN.L NKOOYprivate const array [ENV_SECRET],'per_page','limit','offset',/*** Retrieve all Ask Liminny reports created & 2.10.25Kovallk2.10.25Kovalik* Oodrdll usernusenThe user whos 2.10.25novallk* @param string $sortColumnThe column tc 2.10.25Kovalik* Oparam string $sortDirection The sort dire 2.10.25Kovalik20.11.25 Ivanov* @return Collection<AutomatedReport>8.10.25Kovalik2.10.252.10.25KovalikKovalikpublic function __construct(private readonly ActivitySearch $activitySearch,private readonly HistoryService ShistoryService,private readonly ProphetService $prophetService,private readonly TeamAiContextRepository $teamAiContextRepository,private readonly ActiveStreamsRepository $activeStreamsRepository,private readonly EventDispatcher $eventDispatcher,private readonly LoggerInterface $logger,*/14 usagespublic function getAskJiminnyReportsByUser(User $user,string $sortColumn = 'created_at'string ssorcbirection = "desc"): Collection {...}2.10.2517.10.25 Kovalik17.10.25 Kovalik17.10.25 Kovalik* Check if the user's team has the ASK_JIMINNY_ON_ANYTHING feature enabled2 usages17.10.25 Kovalikprivate function buildSortedQuery(string $sor 17.10.25 Kovalik2.10.25Kovalik/**2.10.25Kovalik* Get all active and enabled reports with ac 2.10.25KovalikKovalik* @param string $frequency2.10.25Kovallik4.10.40Kovallkprivate function checkAskJiminnyOnAnythingFeature(User $user): ?JsonRespons/*** Get top N activity IDs for Ask Jiminny feature based on filtersx ocnrows vecocronexcenronx ocnrows Acenurrovloerxceorron* dreturh coLcectzon<aucomacedкeрort>23 usages2.10.25 Kovalik78 Qg >public function getContextForAskAnythingByFilter(Request $request,ElasticA2.10.25Kovalikpublic function getActiveReportsByFrequency(s7.10.25 Kovalik, 0lablf Support Daily • in 2h 46 mAAskJiminnyReportActivityServiceT…Defaults100% C•Tue 14 Apr 12:14:11CascadeFixing ReportControllerAutomated Report MarFixing Ask Jiminny Rep+D..Now let's run the test to verifvmand dockenwo desker nxe dovkcrs/ko3k Automwa/wports/arman yRgportActzvityserväceTest-php --no-coveragecould not open input Tile: /var/www/ncml/artisanCommand dockerdockerdesks/nxe/ ervke /nosk/Autonape/aeport/ASkJiminnyReportActivityServiceTest.php --n-coverageCould not open input file: /app/artisarCommand dockeroocker exec oocker lano oash—e"cd /var/www&& php artisan testLests unlu services Klosk Aucomaceakeporcs AskJiminnykeportAccivityservicelest.ono =-no-coverade D&l'Could not open input file: artisan• docker exec docker_lamp_1 bash -c "find / -name artisan -maxdepth 6 2>/dev/null | head -5"/home/jiminny/artisan"cd /homee/jiminny && php artisan testtests/nxt/sdrvicrs/K2psk/Autonat e"Reports/A3kiminnyReportActivatyserviceTest.php --no-coverage 2261PASSgetTests\Unit\Services\Kiosk\AutomatedReports\AskJiminnyReportActivityServiceTestfiltersemoty when no resultsr get activityE tatt tnt hperiod date filters•der aculvicvids bassess snazer fsequence number to disable first _ 0.025All 8 tests pass. Here's a summary:Root Cause & FixRoot cause: buildRequestParamsFromSearch never set sequence number in the request params, so Criteria::createFromRequest defaulted it to 0Since isFirstRequest() returns true when sequenceNumber === 0, several implicit defaults were silently applied:Activitvourat ionRande → min duration = 1 Tilters ouf o-second activitiesiActivityRecorded → only_recorded = 1 (restricts to recorded activities only)OrganiserGroupIn → applies user's default group as a filtelThe frontend URL you noticed uses sequence_number=4, which disables these defaults - explaining why the frontend returned activities but the servicereturned O.Fix: AskJiminnyReportActivityService.php:51—added 'sequence_number' → 1 to the Criteria: : createFromRequest merge, ensuring isFirstRequest() returns false and no implicit defaults are injected.Test added: testGetAct:1cylasPassesNonzerosequencenumberloDisablerarsckequestberaulus assers that the captured uriteria ob ect nas 1srirstRequest() === false.Öul ..Vew allliItlle wiun changesvapp/Services/Kiosk/AutomatedReports/D AskJiminnyReportActivityService.php +1 -1Reject allAccept allExplain it to me again. Why is there issue with that? Where is it expected and why do l need to work with that. How is it used [EMAIL] | am trying to fetch the activities based on savedSearch‹ CodeClaude Sonnet 4.6W Windsurf Teams39:01.26 charsuir-o( 4 spaces...
|
NULL
|
-6591387869569782174
|
NULL
|
click
|
ocr
|
NULL
|
PhpStormFileEditViewNavigateCodeLaravelRefactorFV PhpStormFileEditViewNavigateCodeLaravelRefactorFV faVsco.js#11894 on JY-18909-automated-reports-ask-iminny K vProject vToolsWindowHelp© JiminnyDebugCommanc©JiminnySetEncryptedTo© JiminnyTokenInfoComm© MakeSlackLiveCoachins© ManageScimForTeam.p(c Malkoanchrocnvronnlc Mureu canzercnanner© PhpApm.php© PropagateCoachingFeer© PurgeConferences.php© PurgeSoftDeletedOppor© PurgeSyncBatchesComiC RecalculateDealRisksCa© RemoveDeleteMarkersC© RemoveExpiredNudgesi© RemoveUnusedParticip:© ResetElasticsearch.phpc resto eAcctvrvcimrroy© RestoreActivityTypeCor© SeedActivities.php© SyncActivity.php©Tracklmported.php© UpdateActivitiesAverag© WhichWorkerlsWorkingr> D Scheduling© Kernel.php> D Contracts> M Domain> MDTO> M Emails› _ Enums> D Events> D Exceptions> DJ FFMpeg>D Formats› D Guards› Helpersv UHttp> @ AccessTokenProviderv D ControllersV DAPI> D AiCallScoringAiReports> D Deallnsights> D Opportunity> C Page> • Scorecards> D SettingsTeamInsightsD Themes> MUserAutomatedRepov DV2C ACIMINVACOnTOAskAnythingCont© AskJiminnyReporl© DealsV2Controlle:© OnDemandV2Cor© PlaylistController.© PlaylistShareContNavicale lo the next occurrence© ReportController.php© AutomatedReportsCommand.phpyJiminnyDeouecommana.ong= custom.log< console EUi= laravel.logA SF [jiminny@localhost]A HS_local [jiminny@localhost]console SlAGiNG© AskJiminnyReportActivityService.phgA console [PROD]© ActivitySearch.pnp© Criteria.php© AutomatedReportsSendCommand.php© AddLayoutEntities.php© Team.php© AutomatedReportsRepository.php X© AutomatedReportsService.phpC CreateHeldActivityEvent.phpOnDemandV2Controller.php© HistoryService.php© AskJiminnyReportActivityServiceTest.phpFILIER KLY EXCLUDED PARAMS© FilterDefinitionCollection.php© RequestGenerateAskJiminnyReportJobTest.phpcc w .*TAT :(e) TrackProvidernstallled-vent.ono© CreateActivityLoggedEvent.php• ActivityLogged.php© RequestGenerateAskJiminnyReportJob.phpRequestGenerateReportJob.php(C) AutomatedReport.php© UserPilotActivityListener.php(C) AutomatedReportsCallbackService.php© AutomatedReportResult.phpZ.10.23KovalikKovallik4.10.40Kovallk2.10.25Kovallk2.10.25Kovalik2.10.25Kovalik2.10.25Kovalik2.10.25Kovalik<?phpA1X2 A Vaeclare strict types-1namespace Jiminny\Http\Controllers\API\V2;› use ..class Automacedкeрortskepo o:A15 X4 A619311411511611711811912111241232.10.25Kovalik2.10.25KovalikZ.10.23Kovalik* Retrieve all standard (non-Ask Jiminny) M2.10.25Kovalikclass OnDemandV2Controller extends Controlleruse Authorizeskequests)* @param string $sortColumnThe column tc 31.10.25 Ivanov* Cparam string $sortDirection The sort dire 2.10.25 Kovalikprivate const int DEFAULT_TOP_ACTIVITIES_COUNT = 100;* @return Collection<AutomatedReport>12 usagespublic function getAllStandardReports(string $sortColumn = 'created_at',string $sortDirection = 'desc'): Collection {...J19.12.25 Nikolov19.12.25 Nikolov19.12.25 Nikolov19.12.25 Nikolov19.12.25 Nikolov19.12.25 Nikolov19.12.25 NikolovN.L NKOOYprivate const array [ENV_SECRET],'per_page','limit','offset',/*** Retrieve all Ask Liminny reports created & 2.10.25Kovallk2.10.25Kovalik* Oodrdll usernusenThe user whos 2.10.25novallk* @param string $sortColumnThe column tc 2.10.25Kovalik* Oparam string $sortDirection The sort dire 2.10.25Kovalik20.11.25 Ivanov* @return Collection<AutomatedReport>8.10.25Kovalik2.10.252.10.25KovalikKovalikpublic function __construct(private readonly ActivitySearch $activitySearch,private readonly HistoryService ShistoryService,private readonly ProphetService $prophetService,private readonly TeamAiContextRepository $teamAiContextRepository,private readonly ActiveStreamsRepository $activeStreamsRepository,private readonly EventDispatcher $eventDispatcher,private readonly LoggerInterface $logger,*/14 usagespublic function getAskJiminnyReportsByUser(User $user,string $sortColumn = 'created_at'string ssorcbirection = "desc"): Collection {...}2.10.2517.10.25 Kovalik17.10.25 Kovalik17.10.25 Kovalik* Check if the user's team has the ASK_JIMINNY_ON_ANYTHING feature enabled2 usages17.10.25 Kovalikprivate function buildSortedQuery(string $sor 17.10.25 Kovalik2.10.25Kovalik/**2.10.25Kovalik* Get all active and enabled reports with ac 2.10.25KovalikKovalik* @param string $frequency2.10.25Kovallik4.10.40Kovallkprivate function checkAskJiminnyOnAnythingFeature(User $user): ?JsonRespons/*** Get top N activity IDs for Ask Jiminny feature based on filtersx ocnrows vecocronexcenronx ocnrows Acenurrovloerxceorron* dreturh coLcectzon<aucomacedкeрort>23 usages2.10.25 Kovalik78 Qg >public function getContextForAskAnythingByFilter(Request $request,ElasticA2.10.25Kovalikpublic function getActiveReportsByFrequency(s7.10.25 Kovalik, 0lablf Support Daily • in 2h 46 mAAskJiminnyReportActivityServiceT…Defaults100% C•Tue 14 Apr 12:14:11CascadeFixing ReportControllerAutomated Report MarFixing Ask Jiminny Rep+D..Now let's run the test to verifvmand dockenwo desker nxe dovkcrs/ko3k Automwa/wports/arman yRgportActzvityserväceTest-php --no-coveragecould not open input Tile: /var/www/ncml/artisanCommand dockerdockerdesks/nxe/ ervke /nosk/Autonape/aeport/ASkJiminnyReportActivityServiceTest.php --n-coverageCould not open input file: /app/artisarCommand dockeroocker exec oocker lano oash—e"cd /var/www&& php artisan testLests unlu services Klosk Aucomaceakeporcs AskJiminnykeportAccivityservicelest.ono =-no-coverade D&l'Could not open input file: artisan• docker exec docker_lamp_1 bash -c "find / -name artisan -maxdepth 6 2>/dev/null | head -5"/home/jiminny/artisan"cd /homee/jiminny && php artisan testtests/nxt/sdrvicrs/K2psk/Autonat e"Reports/A3kiminnyReportActivatyserviceTest.php --no-coverage 2261PASSgetTests\Unit\Services\Kiosk\AutomatedReports\AskJiminnyReportActivityServiceTestfiltersemoty when no resultsr get activityE tatt tnt hperiod date filters•der aculvicvids bassess snazer fsequence number to disable first _ 0.025All 8 tests pass. Here's a summary:Root Cause & FixRoot cause: buildRequestParamsFromSearch never set sequence number in the request params, so Criteria::createFromRequest defaulted it to 0Since isFirstRequest() returns true when sequenceNumber === 0, several implicit defaults were silently applied:Activitvourat ionRande → min duration = 1 Tilters ouf o-second activitiesiActivityRecorded → only_recorded = 1 (restricts to recorded activities only)OrganiserGroupIn → applies user's default group as a filtelThe frontend URL you noticed uses sequence_number=4, which disables these defaults - explaining why the frontend returned activities but the servicereturned O.Fix: AskJiminnyReportActivityService.php:51—added 'sequence_number' → 1 to the Criteria: : createFromRequest merge, ensuring isFirstRequest() returns false and no implicit defaults are injected.Test added: testGetAct:1cylasPassesNonzerosequencenumberloDisablerarsckequestberaulus assers that the captured uriteria ob ect nas 1srirstRequest() === false.Öul ..Vew allliItlle wiun changesvapp/Services/Kiosk/AutomatedReports/D AskJiminnyReportActivityService.php +1 -1Reject allAccept allExplain it to me again. Why is there issue with that? Where is it expected and why do l need to work with that. How is it used [EMAIL] | am trying to fetch the activities based on savedSearch‹ CodeClaude Sonnet 4.6W Windsurf Teams39:01.26 charsuir-o( 4 spaces...
|
11129
|
|
11199
|
NULL
|
0
|
2026-04-14T09:19:16.768076+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776158356768_m1.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
+SlackEDHomeDMSActivityFilesLater..•More+FileEditV +SlackEDHomeDMSActivityFilesLater..•More+FileEditViewGoHistoryWindowHelpJiminny ...# Starredplatform-inner-teamChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi…..Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili.... Adelina PetrovaO. Calea Dimitravo→Search Jiminny IncAneliya Angelova, Nikolay Yankov, Steliyan GeorgievMessagesAdd canvas+Nikolay Yankov 10:45 AMпиши кат оя рьннешLukas Kovalik 10:52 AMзабавих се че ми се разбазикаха settings за средипуснах и мина и fail-наима result но e failedзначиREASON_NOT_ENOUGH_ACTIVITIESвиж дали има нещо в OD със този филтьрNikolay Yankov 11:01 AMДобреNikolay Yankov 11:39 AMя рьнни пак LukasLukas Kovalik 11:43 AMготовосьщотоCompetitive pitches беше втория нали такаNikolay Yankov 12:04 PMДа, там има 14 активитита, защо не сработи този пьт?Lukas Kovalik 12:05 PMпак изглежда sequenceгледам гоMessage Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev+AalahlSupport Daily - in 2h 41 m100% <47Tue 14 Apr 12:19:1686 0Today ~...
|
NULL
|
5017641561575760569
|
NULL
|
click
|
ocr
|
NULL
|
+SlackEDHomeDMSActivityFilesLater..•More+FileEditV +SlackEDHomeDMSActivityFilesLater..•More+FileEditViewGoHistoryWindowHelpJiminny ...# Starredplatform-inner-teamChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi…..Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili.... Adelina PetrovaO. Calea Dimitravo→Search Jiminny IncAneliya Angelova, Nikolay Yankov, Steliyan GeorgievMessagesAdd canvas+Nikolay Yankov 10:45 AMпиши кат оя рьннешLukas Kovalik 10:52 AMзабавих се че ми се разбазикаха settings за средипуснах и мина и fail-наима result но e failedзначиREASON_NOT_ENOUGH_ACTIVITIESвиж дали има нещо в OD със този филтьрNikolay Yankov 11:01 AMДобреNikolay Yankov 11:39 AMя рьнни пак LukasLukas Kovalik 11:43 AMготовосьщотоCompetitive pitches беше втория нали такаNikolay Yankov 12:04 PMДа, там има 14 активитита, защо не сработи този пьт?Lukas Kovalik 12:05 PMпак изглежда sequenceгледам гоMessage Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev+AalahlSupport Daily - in 2h 41 m100% <47Tue 14 Apr 12:19:1686 0Today ~...
|
NULL
|
|
11200
|
NULL
|
0
|
2026-04-14T09:19:16.756329+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776158356756_m2.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
PhpStormFileEditFV faVsco.s vProject v> D Proph PhpStormFileEditFV faVsco.s vProject v> D ProphetAiv D Reports© AutomatedReportsCl© AutomatedReportsRe© AutomatedReportsSt© CreateMockAskJimir© DeleteReportComma© GenerateMarketingR© Team.php© Usage.phpD Slack• TeamsD TracksO TranscriptionO TwilioD UsersVocabularyDZoom© CoachingFeedbacksUpr© Command.php© CreateDatabaseUsers.pc Daraoase oecountoi© DeleteOldAiCrmNotesC:© DeleteS3LeftoversComiDevPostmanCommand./© DiarizeViaAiParticipantk© EncryptTokensComman© EngagementStatsRegen© FeatureFlagsHelper.php© FixCrossTenantlssues.p© FlushRolesPermissionsC(e) Generatelnterna wepho• GroupSetDefaultLangua© HelperTruncateCoachin© HubspotJournalPollingC© HubspotWebhookServic©ImportRecording.php© ImportUsersFromCsvFil© IterateUsersCommand.p© JiminnyCacheClearCom© JiminnyDebugCommanc© JiminnySetEncryptedTo(c) Jiminny okenintocomm© MakeSlackLiveCoaching© ManageScimForTeam.p© MarkBranchForEnvironn© MuteOrganizerChannel.© PhpApm.php© PropagateCoachingFeer© PurgeConferences.php© PurgeSoftDeletedOppor© PurgeSyncBatchesCom(e Recalculatebealkisksco(c) Removebe eremarkersc(e) Remove-xoiredNudoes© RemoveUnusedParticip:© ResetElasticSearch.php© RestoreActivityCrmProv© RestoreActivityTypeCorViewNavigateCodeLaravelRefactorToolsWindowHelp( #11894 on JY-18909-automated-reports-ask-jiminny k v© ReportController.php© JiminnyDebugCommand.php© AutomatedReportsSendCommand.php© AddLayoutEntities.php© AutomatedReportsRepository.php© AutomatedReportsService.php© TrackProviderInstalledEvent.phpC) CreateActivityLoggedEvent.php© ActivityLogged.phpC AutomatedReportsCallbackService.phplests passea: 1 (10 minutes ago)© AutomatedReportsCommand.php x© Team.php© CreateHeldActivityEvent.php© UserPilotActivityListener.php= custom.log= laravel.logA SF [jiminny@localhost]Hs local liminnyalocalnostconsole PRODL console [EUl(0) RequestGenerate.sk.liminnvRenor.ob.ohn© RequestGenerateReportJob.php© AutomatedReportResult.php© AutomatedReport.phpA2 ^¿ consoe STAGINGI© AskJiminnyReportActivityService.php© ActivitySearch.php•OnDemandV2Controller.phprilterDerinitioncollection.onpC Criteria.php© AskJiminnyReportActivityServiceTest.php x© RequestGenerateAskJiminnyReportJobTest.php26class AskJiminnyReportActivityServiceTe0bject $logger;© HistoryService.phpBLMSAYiervice;iryserulcce oserucen29 ot>oidf.19 D› tring $key, ?string $value): SearchFilter&Mock0bject(...}› User&MockObjectf...3>rch(array $filters): Search&Mock0bjectf...}71%>tyIdsForSavedSearchReturnsIds(): voidf...}31 6t| Process a specific report by ID or UUID (bypasses frequency scheduling)}';100 % > tyIdsForSavedSearchReturnsEmptyWhenNoResults(): void{...}38 641 đ117118 % > tyIdsFiltersOutDateFilters(): voidf...}156157 %>tyIdsFilters0utClosingPeriodDateFilters(): voidf..184185 % >tyIdsHandLesArrayFilters(): voidf...3ll on thean frequency (weekly, monthty, quarterly). Ufg--report-id to manually trig!205206 ₽ >tyIdsHandlesScalarFilters(): void{...}224225 ₽tyIdsPassesNonZeroSequenceNumberToDisableFirstRequestDefaults227IpoS1LoryeSavedSearch([]):229230eMock( originalClassName: FilterDefinitionCollection::class);chodl constraint: 'gecArrayrilterkeys )->wLLcreturnuLJ:1254258236237242243244245246247248-2472o0pects ($this->once())tOnDemandPageFilterSet')function (Criteria $criteria) use ($filterSet, &$capturedCrit>method( constraint: 'onDemandSearchIdsOnly') ->willReturn([]);istraint: 'info');tyIdsForSavedSearch($savedSearch, $user);Tureduriteria):reourrerarnsrurstre.uest.anvary, April, July, Uctober)252 8j Support Daily • in 2h 41 mAAskJiminnyReportActivityServiceT…Defaults100% C•Tue 14 Apr 12:19:16CascadeFixing ReportControllerAutomated Report MarFixing Ask Jiminny Rep+D..Explain it to me again. Why is there issue with thhat? Where is it expected and why do I need to work with that. How is it used inDelllaluvzcontroes vasee oll saveuoedichl. Une los m on celllane ane iiOnSkdILmlуnedoT LheLeveLyetVLceronorL44-00 snoule De salllewLet me read the OnDemandV2Controller to understand how it builds criteria there:Read OnDemanavzcontNow look at the key difference. The controller's getContextForAskAnythingByFilter at OnDemandV2Controller.php: 90-93:0 phpVO Repository OnDemandActivitySearch\Criteria::createFromRequest(arrav meroesrequesoaluo.' umir => 00c0unt "oade$user->getTimezone()It passes Srequest->all() - which includes sequence_number from the URL (e.g. sequence_number=4 from your staging URL). So when a user has beenpaginating on the frontend, sequence_number is naturally non-zero.The full explanationyou didn't ask for them:hsiauist kecuestaouncskenererurns true wnen seauenceNumber === u wnenttsine "trstreduestneseumolci detauirs kickinauromaricalveventFiterDefault on first requestEffectActiv1tvburat zonkangelmin_duration = 1 minDroos 0-secono activitiesActivityRecordedonly_recorded = 1Recorded activities onlvOrganiserGroupInUser's own groupRestricts to user's groupFrontend hits /api/v1/page/on-demand?topic id(]=...&sequence number=4 → sequence number=4 → isFirstRequest = false → no implicit defaults →returns 15 activities.AskJiminnyReportActivityService (before the fix) built params from the saved search filters but never included sequence number → defaulted to 0 → isFirstRequest() = true → implicit defaults applied → 0 activities returned because the topic filter + recorded-onlv + duration>1 together matchednothing.Why sequence_number=1 is the right fixThe service is doing a deliberate, one-shot search - not a paginated session. It should never apply first-request defaults, because:1. The saved search already encodes the user's intent (those filters were chosen explicitly)2. Date filters are already intentionally stripped (that's existing logic in DATE_FILTER_KEYS )3. Adding implicit min_duration, only_recorded, and group scope on top would contradict what the saved search representsSetting sequence number=1 is the minimal, correct signal: "this is not a fresh session open, don't apply page-load defaults". The criteria is otherwise builtidentically to how the controller builds it - same Criteria::createFromRequest, same get0nDemandPageFilterSet, same onDemandSearchIds0nly - so theresults will now match.O ul ...Ask anything (2*L)+ <> CodeClaude Sonnet 4.6Winasun leams124:10uir-o( 4 spaces...
|
NULL
|
4082850485442642471
|
NULL
|
click
|
ocr
|
NULL
|
PhpStormFileEditFV faVsco.s vProject v> D Proph PhpStormFileEditFV faVsco.s vProject v> D ProphetAiv D Reports© AutomatedReportsCl© AutomatedReportsRe© AutomatedReportsSt© CreateMockAskJimir© DeleteReportComma© GenerateMarketingR© Team.php© Usage.phpD Slack• TeamsD TracksO TranscriptionO TwilioD UsersVocabularyDZoom© CoachingFeedbacksUpr© Command.php© CreateDatabaseUsers.pc Daraoase oecountoi© DeleteOldAiCrmNotesC:© DeleteS3LeftoversComiDevPostmanCommand./© DiarizeViaAiParticipantk© EncryptTokensComman© EngagementStatsRegen© FeatureFlagsHelper.php© FixCrossTenantlssues.p© FlushRolesPermissionsC(e) Generatelnterna wepho• GroupSetDefaultLangua© HelperTruncateCoachin© HubspotJournalPollingC© HubspotWebhookServic©ImportRecording.php© ImportUsersFromCsvFil© IterateUsersCommand.p© JiminnyCacheClearCom© JiminnyDebugCommanc© JiminnySetEncryptedTo(c) Jiminny okenintocomm© MakeSlackLiveCoaching© ManageScimForTeam.p© MarkBranchForEnvironn© MuteOrganizerChannel.© PhpApm.php© PropagateCoachingFeer© PurgeConferences.php© PurgeSoftDeletedOppor© PurgeSyncBatchesCom(e Recalculatebealkisksco(c) Removebe eremarkersc(e) Remove-xoiredNudoes© RemoveUnusedParticip:© ResetElasticSearch.php© RestoreActivityCrmProv© RestoreActivityTypeCorViewNavigateCodeLaravelRefactorToolsWindowHelp( #11894 on JY-18909-automated-reports-ask-jiminny k v© ReportController.php© JiminnyDebugCommand.php© AutomatedReportsSendCommand.php© AddLayoutEntities.php© AutomatedReportsRepository.php© AutomatedReportsService.php© TrackProviderInstalledEvent.phpC) CreateActivityLoggedEvent.php© ActivityLogged.phpC AutomatedReportsCallbackService.phplests passea: 1 (10 minutes ago)© AutomatedReportsCommand.php x© Team.php© CreateHeldActivityEvent.php© UserPilotActivityListener.php= custom.log= laravel.logA SF [jiminny@localhost]Hs local liminnyalocalnostconsole PRODL console [EUl(0) RequestGenerate.sk.liminnvRenor.ob.ohn© RequestGenerateReportJob.php© AutomatedReportResult.php© AutomatedReport.phpA2 ^¿ consoe STAGINGI© AskJiminnyReportActivityService.php© ActivitySearch.php•OnDemandV2Controller.phprilterDerinitioncollection.onpC Criteria.php© AskJiminnyReportActivityServiceTest.php x© RequestGenerateAskJiminnyReportJobTest.php26class AskJiminnyReportActivityServiceTe0bject $logger;© HistoryService.phpBLMSAYiervice;iryserulcce oserucen29 ot>oidf.19 D› tring $key, ?string $value): SearchFilter&Mock0bject(...}› User&MockObjectf...3>rch(array $filters): Search&Mock0bjectf...}71%>tyIdsForSavedSearchReturnsIds(): voidf...}31 6t| Process a specific report by ID or UUID (bypasses frequency scheduling)}';100 % > tyIdsForSavedSearchReturnsEmptyWhenNoResults(): void{...}38 641 đ117118 % > tyIdsFiltersOutDateFilters(): voidf...}156157 %>tyIdsFilters0utClosingPeriodDateFilters(): voidf..184185 % >tyIdsHandLesArrayFilters(): voidf...3ll on thean frequency (weekly, monthty, quarterly). Ufg--report-id to manually trig!205206 ₽ >tyIdsHandlesScalarFilters(): void{...}224225 ₽tyIdsPassesNonZeroSequenceNumberToDisableFirstRequestDefaults227IpoS1LoryeSavedSearch([]):229230eMock( originalClassName: FilterDefinitionCollection::class);chodl constraint: 'gecArrayrilterkeys )->wLLcreturnuLJ:1254258236237242243244245246247248-2472o0pects ($this->once())tOnDemandPageFilterSet')function (Criteria $criteria) use ($filterSet, &$capturedCrit>method( constraint: 'onDemandSearchIdsOnly') ->willReturn([]);istraint: 'info');tyIdsForSavedSearch($savedSearch, $user);Tureduriteria):reourrerarnsrurstre.uest.anvary, April, July, Uctober)252 8j Support Daily • in 2h 41 mAAskJiminnyReportActivityServiceT…Defaults100% C•Tue 14 Apr 12:19:16CascadeFixing ReportControllerAutomated Report MarFixing Ask Jiminny Rep+D..Explain it to me again. Why is there issue with thhat? Where is it expected and why do I need to work with that. How is it used inDelllaluvzcontroes vasee oll saveuoedichl. Une los m on celllane ane iiOnSkdILmlуnedoT LheLeveLyetVLceronorL44-00 snoule De salllewLet me read the OnDemandV2Controller to understand how it builds criteria there:Read OnDemanavzcontNow look at the key difference. The controller's getContextForAskAnythingByFilter at OnDemandV2Controller.php: 90-93:0 phpVO Repository OnDemandActivitySearch\Criteria::createFromRequest(arrav meroesrequesoaluo.' umir => 00c0unt "oade$user->getTimezone()It passes Srequest->all() - which includes sequence_number from the URL (e.g. sequence_number=4 from your staging URL). So when a user has beenpaginating on the frontend, sequence_number is naturally non-zero.The full explanationyou didn't ask for them:hsiauist kecuestaouncskenererurns true wnen seauenceNumber === u wnenttsine "trstreduestneseumolci detauirs kickinauromaricalveventFiterDefault on first requestEffectActiv1tvburat zonkangelmin_duration = 1 minDroos 0-secono activitiesActivityRecordedonly_recorded = 1Recorded activities onlvOrganiserGroupInUser's own groupRestricts to user's groupFrontend hits /api/v1/page/on-demand?topic id(]=...&sequence number=4 → sequence number=4 → isFirstRequest = false → no implicit defaults →returns 15 activities.AskJiminnyReportActivityService (before the fix) built params from the saved search filters but never included sequence number → defaulted to 0 → isFirstRequest() = true → implicit defaults applied → 0 activities returned because the topic filter + recorded-onlv + duration>1 together matchednothing.Why sequence_number=1 is the right fixThe service is doing a deliberate, one-shot search - not a paginated session. It should never apply first-request defaults, because:1. The saved search already encodes the user's intent (those filters were chosen explicitly)2. Date filters are already intentionally stripped (that's existing logic in DATE_FILTER_KEYS )3. Adding implicit min_duration, only_recorded, and group scope on top would contradict what the saved search representsSetting sequence number=1 is the minimal, correct signal: "this is not a fresh session open, don't apply page-load defaults". The criteria is otherwise builtidentically to how the controller builds it - same Criteria::createFromRequest, same get0nDemandPageFilterSet, same onDemandSearchIds0nly - so theresults will now match.O ul ...Ask anything (2*L)+ <> CodeClaude Sonnet 4.6Winasun leams124:10uir-o( 4 spaces...
|
11198
|
|
11201
|
222
|
0
|
2026-04-14T09:19:34.545137+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776158374545_m1.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
+SlackEDHomeDMSActivityFilesLater..•More+FileEditV +SlackEDHomeDMSActivityFilesLater..•More+FileEditViewGoHistoryWindowHelpJiminny ...# Starredplatform-inner-teamChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product_launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi…..Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili.... Adelina PetrovaO. Calea Dimitravo→Search Jiminny IncAneliya Angelova, Nikolay Yankov, Steliyan GeorgievMessagesAdd canvas+Nikolay Yankov 10:45 AMпиши кат оя рьннешLukas Kovalik 10:52 AMзабавих се че ми се разбазикаха settings за средипуснах и мина и fail-наима result но e failedзначиREASON_NOT_ENOUGH_ACTIVITIESвиж дали има нещо в OD със този филтьрNikolay Yankov 11:01 AMДобреNikolay Yankov 11:39 AMя рьнни пак LukasLukas Kovalik 11:43 AMготовосьщотоCompetitive pitches беше втория нали такаNikolay Yankov 12:04 PMДа, там има 14 активитита, защо не сработи този пьт?Lukas Kovalik 12:05 PMпак изглежда sequenceгледам гоMessage Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev+AalahlSupport Daily - in 2h 41 m100% <47Tue 14 Apr 12:19:348Today ~...
|
NULL
|
-6334506220086603782
|
NULL
|
click
|
ocr
|
NULL
|
+SlackEDHomeDMSActivityFilesLater..•More+FileEditV +SlackEDHomeDMSActivityFilesLater..•More+FileEditViewGoHistoryWindowHelpJiminny ...# Starredplatform-inner-teamChannels# ai-chapter# alerts# backend# confusion-clinic# curiosity_lab# engineering# frontend# general# infra-changes# jiminny-bg# platform-tickets# product_launches# random# releases# sofia-office# support# thank-yous# the_people_of jimi…..Direct messagesAneliya Angelova, ...Steliyan GeorgievAdelina Petrova, Ili.... Adelina PetrovaO. Calea Dimitravo→Search Jiminny IncAneliya Angelova, Nikolay Yankov, Steliyan GeorgievMessagesAdd canvas+Nikolay Yankov 10:45 AMпиши кат оя рьннешLukas Kovalik 10:52 AMзабавих се че ми се разбазикаха settings за средипуснах и мина и fail-наима result но e failedзначиREASON_NOT_ENOUGH_ACTIVITIESвиж дали има нещо в OD със този филтьрNikolay Yankov 11:01 AMДобреNikolay Yankov 11:39 AMя рьнни пак LukasLukas Kovalik 11:43 AMготовосьщотоCompetitive pitches беше втория нали такаNikolay Yankov 12:04 PMДа, там има 14 активитита, защо не сработи този пьт?Lukas Kovalik 12:05 PMпак изглежда sequenceгледам гоMessage Aneliya Angelova, Nikolay Yankov, Steliyan Georgiev+AalahlSupport Daily - in 2h 41 m100% <47Tue 14 Apr 12:19:348Today ~...
|
11199
|
|
11202
|
223
|
0
|
2026-04-14T09:19:34.532004+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776158374532_m2.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
PhpStormProject vFileEditFV faVsco.js vViewNavigat PhpStormProject vFileEditFV faVsco.js vViewNavigateCodeLaravelRefactorToolsWindowHelp#11894 on JY-18909-automated-reports-ask-iminny K vProphetAiv D Reports© AutomatedReportsCl© AutomatedReportsRe© AutomatedReportsSt© CreateMockAskJimir© DeleteReportComma© GenerateMarketingR© Team.php© Usage.phpD Slack• TeamsD TracksO TranscriptionO TwilioD UsersVocabularyDZoom© CoachingFeedbacksUpr© Command.php© CreateDatabaseUsers.pc Daraoase oecountoi© DeleteOldAiCrmNotesC:© DeleteS3LeftoversComiDevPostmanCommand.|© DiarizeViaAiParticipantk© EncryptTokensComman© EngagementStatsRegen© FeatureFlagsHelper.php© FixCrossTenantissues.p© FlushRolesPermissionsC© GeneratelnternalWebho• GroupSetDefaultLangua© HelperTruncateCoachin© HubspotJournalPollingC© HubspotWebhookServic© ImportRecording.php@ Imnortli|sercFromCcvEil© IterateUsersCommand.gcJiminnvcacheclearcom(c) minnv Deouacommanc© JiminnySetEncryptedTo© JiminnyTokenInfoComn© MakeSlackLiveCoaching© ManageScimForTeam.p© MarkBranchForEnvironn© MuteOrganizerChannel.© PhpApm.php© PropagateCoachingFeer© PurgeConferences.php(©) PurgeSoftDeletedOppol© PurgeSyncBatchesCom© RecalculateDealRisksCaC) RemoveDeleteMarkersd© RemoveExpiredNudgest© RemoveUnusedParticip:© ResetElasticSearch.php© RestoreActivityCrmProv© RestoreActivityTypeCorTests passed: 1 (10 minutes ago)© ReportController.phpJiminnybeouecommana.ong© AutomatedReportsSendCommand.php© AddLayoutEntities.php© AutomatedReportsService.php• ІгаскrrovlderinstalleacventoneC) CreateActivityLoggedEvent.phpAutomatedReportsCommand.php X= custom.log= laravel.logA SF [jiminny@localhost]leam.onoHs local liminnyalocalnostconsole PRODL console [EUl© CreateHeldActivityEvent.php© UserPilotActivityListener.phpC AutomatedReportsCallbackService.php© RequestGenerateReportJob.php© AutomatedReportResult.phpA console [STAGING]© ActivitySearch.php© AskJiminnyReportActivityService.php•OnDemandV2Controller.phprilterDerinitioncollection.ongC Criteria.php© AskJiminnyReportActivityServiceTest.php x© RequestGenerateAskJiminnyReportJobTest.php26class AskJiminnyReportActivityServiceTe0bject $logger;© HistoryService.php19 D31 Ct38 đ42 Ct51535556© AutomatedReport.phpLs\Team;sitories\AutomatedReportsRepository;ices\Kiosk\AutomatedReports\AutomatedReportsService;erInterface;A2 ^BLMSAYiryserulcce oserucen29 ot>oidf.eoorrsconliano excenos conlano› tring $key, ?string $value): SearchFilter&Mock0bject(...}x for all log messagest string LOG_PREFIX = '[automated-reports]':› User&MockObjectf...}and signature of the console command.› rch(array $filters): Search&MockObject{...}71%>tyIdsForSavedSearchReturnsIds(): voidf...}lignature = 'automated-reports f--report-id= : Process a specific report by ID or Ul 100 P > tyIdsForSavedSearchReturnsEmptyWhenNoResults(): voidf...}Le command description.117118 % > tyIdsFiltersOutDateFilters(): voidf...}156157 % >tyIdsFilters0utClosingPeriodDateFilters(): voidf..}185 M >tyIdsHandLesArrayFilters(): voidf...3lescription = 'Process automated reports based on their frequency (weekly, monthly,port-id to manually trigger a specific report by ID or UUID.';206 ₽ >224225 ₽tyIdsHandlesScalarFilters(): void{...;tyIdsPassesNonZeroSequenceNumberToDisableFirstRequestDefaultsion __construct(readonly LoggerInterface $logger,readonly BusDispatcher $dispatcher,readonly AutomatedReportsRepository $reportRepositoryeSavedSearch([]):229230eMock( originalClassName: FilterDefinitionCollection::class);__construct();chodl constraint: 'gecArrayrilterkeys )->wLLcreturnuLJ:ne console conmonoiion handle(): intogger->info(self::LOG_PREFIX . ' Started');arbon: : now();y = Snow->1SMondayO:Dav0fMonth = Snow->dav === 1Month = Snow->month:1254258236237242243244245246247248— 2472o0pects ($this->once())tOnDemandPageFilterSet')function (Criteria $criteria) use ($filterSet, &$capturedCrit>method( constraint: 'onDemandSearchIdsOnly') ->willReturn([]);istraint: 'info');tyIdsForSavedSearch($savedSearch, $user);reourrerarnsrurstre.uest.252 Mj Support Daily • in 2h 41 mAAskJiminnyReportActivityServiceT…Defaults100% C•Tue 14 Apr 12:19:34CascadeFixing ReportControllerAutomated Report MarFixing Ask Jiminny Rep+D..Explain it to me again. Why is there issue with thhat? Where is it expected and why do I need to work with that. How is it used inDelllaluvzcontroes vasee oll saveuoedichl. Une los m on celllane ane iiOnSkdILmlуnedoT LheLeveLyetVLceronorL44-00 snoule De salllewLet me read the OnDemandV2Controller to understand how it builds criteria there:Read OnDemanavzcontNow look at the key difference. The controller's getContextForAskAnythingByFilter at OnDemandV2Controller.php: 90-93:0 phpVO Repository OnDemandActivitySearch\Criteria:: createFromRequest(arrav meroesrequesoaluo.' umir => 00c0unt "oade$user->getTimezone()It passes Srequest->all() - which includes sequence_number from the URL (e.g. sequence_number=4 from your staging URL). So when a user has beenpaginating on the frontend, sequence_number is naturally non-zero.The full explanationyou didn't ask for them:hsiauist kecuestaouncskenererurns true wnen seauenceNumber === u wnenttsine "trstreduestneseumolci detauirs kickinauromaricalveventFiterDefault on first requestEffectActiv1tvburat zonkangelmin_duration = 1 minDroos 0-secono activitiesActivityRecordedonly_recorded = 1Recorded activities onlvOrganiserGroupInUser's own groupRestricts to user's groupFrontend hits /api/v1/page/on-demand?topic id(]=...&sequence number=4 → sequence number=4 → isFirstRequest = false → no implicit defaults →returns 15 activities.AskJiminnyReportActivityService (before the fix) built params from the saved search filters but never included sequence number → defaulted to 0 → isFirstRequest() = true → implicit defaults applied → 0 activities returned because the topic filter + recorded-onlv + duration>1 together matchednothing.Why sequence_number=1 is the right fixThe service is doing a deliberate, one-shot search - not a paginated session. It should never apply first-request defaults, because:1. The saved search already encodes the user's intent (those filters were chosen explicitly)2. Date filters are already intentionally stripped (that's existing logic in DATE_FILTER_KEYS )3. Adding implicit min_duration, only_recorded, and group scope on top would contradict what the saved search representsSetting sequence number=1 is the minimal, correct signal: "this is not a fresh session open, don't apply page-load defaults". The criteria is otherwise builtidentically to how the controller builds it - same Criteria::createFromRequest, same get0nDemandPageFilterSet, same onDemandSearchIds0nly - so theresults will now match.Ö ul ...Ask anything (2*L)+ <> CodeClaude Sonnet 4.6Winasun leams39:9uir-o( 4 spaces...
|
NULL
|
8344973971912623520
|
NULL
|
click
|
ocr
|
NULL
|
PhpStormProject vFileEditFV faVsco.js vViewNavigat PhpStormProject vFileEditFV faVsco.js vViewNavigateCodeLaravelRefactorToolsWindowHelp#11894 on JY-18909-automated-reports-ask-iminny K vProphetAiv D Reports© AutomatedReportsCl© AutomatedReportsRe© AutomatedReportsSt© CreateMockAskJimir© DeleteReportComma© GenerateMarketingR© Team.php© Usage.phpD Slack• TeamsD TracksO TranscriptionO TwilioD UsersVocabularyDZoom© CoachingFeedbacksUpr© Command.php© CreateDatabaseUsers.pc Daraoase oecountoi© DeleteOldAiCrmNotesC:© DeleteS3LeftoversComiDevPostmanCommand.|© DiarizeViaAiParticipantk© EncryptTokensComman© EngagementStatsRegen© FeatureFlagsHelper.php© FixCrossTenantissues.p© FlushRolesPermissionsC© GeneratelnternalWebho• GroupSetDefaultLangua© HelperTruncateCoachin© HubspotJournalPollingC© HubspotWebhookServic© ImportRecording.php@ Imnortli|sercFromCcvEil© IterateUsersCommand.gcJiminnvcacheclearcom(c) minnv Deouacommanc© JiminnySetEncryptedTo© JiminnyTokenInfoComn© MakeSlackLiveCoaching© ManageScimForTeam.p© MarkBranchForEnvironn© MuteOrganizerChannel.© PhpApm.php© PropagateCoachingFeer© PurgeConferences.php(©) PurgeSoftDeletedOppol© PurgeSyncBatchesCom© RecalculateDealRisksCaC) RemoveDeleteMarkersd© RemoveExpiredNudgest© RemoveUnusedParticip:© ResetElasticSearch.php© RestoreActivityCrmProv© RestoreActivityTypeCorTests passed: 1 (10 minutes ago)© ReportController.phpJiminnybeouecommana.ong© AutomatedReportsSendCommand.php© AddLayoutEntities.php© AutomatedReportsService.php• ІгаскrrovlderinstalleacventoneC) CreateActivityLoggedEvent.phpAutomatedReportsCommand.php X= custom.log= laravel.logA SF [jiminny@localhost]leam.onoHs local liminnyalocalnostconsole PRODL console [EUl© CreateHeldActivityEvent.php© UserPilotActivityListener.phpC AutomatedReportsCallbackService.php© RequestGenerateReportJob.php© AutomatedReportResult.phpA console [STAGING]© ActivitySearch.php© AskJiminnyReportActivityService.php•OnDemandV2Controller.phprilterDerinitioncollection.ongC Criteria.php© AskJiminnyReportActivityServiceTest.php x© RequestGenerateAskJiminnyReportJobTest.php26class AskJiminnyReportActivityServiceTe0bject $logger;© HistoryService.php19 D31 Ct38 đ42 Ct51535556© AutomatedReport.phpLs\Team;sitories\AutomatedReportsRepository;ices\Kiosk\AutomatedReports\AutomatedReportsService;erInterface;A2 ^BLMSAYiryserulcce oserucen29 ot>oidf.eoorrsconliano excenos conlano› tring $key, ?string $value): SearchFilter&Mock0bject(...}x for all log messagest string LOG_PREFIX = '[automated-reports]':› User&MockObjectf...}and signature of the console command.› rch(array $filters): Search&MockObject{...}71%>tyIdsForSavedSearchReturnsIds(): voidf...}lignature = 'automated-reports f--report-id= : Process a specific report by ID or Ul 100 P > tyIdsForSavedSearchReturnsEmptyWhenNoResults(): voidf...}Le command description.117118 % > tyIdsFiltersOutDateFilters(): voidf...}156157 % >tyIdsFilters0utClosingPeriodDateFilters(): voidf..}185 M >tyIdsHandLesArrayFilters(): voidf...3lescription = 'Process automated reports based on their frequency (weekly, monthly,port-id to manually trigger a specific report by ID or UUID.';206 ₽ >224225 ₽tyIdsHandlesScalarFilters(): void{...;tyIdsPassesNonZeroSequenceNumberToDisableFirstRequestDefaultsion __construct(readonly LoggerInterface $logger,readonly BusDispatcher $dispatcher,readonly AutomatedReportsRepository $reportRepositoryeSavedSearch([]):229230eMock( originalClassName: FilterDefinitionCollection::class);__construct();chodl constraint: 'gecArrayrilterkeys )->wLLcreturnuLJ:ne console conmonoiion handle(): intogger->info(self::LOG_PREFIX . ' Started');arbon: : now();y = Snow->1SMondayO:Dav0fMonth = Snow->dav === 1Month = Snow->month:1254258236237242243244245246247248— 2472o0pects ($this->once())tOnDemandPageFilterSet')function (Criteria $criteria) use ($filterSet, &$capturedCrit>method( constraint: 'onDemandSearchIdsOnly') ->willReturn([]);istraint: 'info');tyIdsForSavedSearch($savedSearch, $user);reourrerarnsrurstre.uest.252 Mj Support Daily • in 2h 41 mAAskJiminnyReportActivityServiceT…Defaults100% C•Tue 14 Apr 12:19:34CascadeFixing ReportControllerAutomated Report MarFixing Ask Jiminny Rep+D..Explain it to me again. Why is there issue with thhat? Where is it expected and why do I need to work with that. How is it used inDelllaluvzcontroes vasee oll saveuoedichl. Une los m on celllane ane iiOnSkdILmlуnedoT LheLeveLyetVLceronorL44-00 snoule De salllewLet me read the OnDemandV2Controller to understand how it builds criteria there:Read OnDemanavzcontNow look at the key difference. The controller's getContextForAskAnythingByFilter at OnDemandV2Controller.php: 90-93:0 phpVO Repository OnDemandActivitySearch\Criteria:: createFromRequest(arrav meroesrequesoaluo.' umir => 00c0unt "oade$user->getTimezone()It passes Srequest->all() - which includes sequence_number from the URL (e.g. sequence_number=4 from your staging URL). So when a user has beenpaginating on the frontend, sequence_number is naturally non-zero.The full explanationyou didn't ask for them:hsiauist kecuestaouncskenererurns true wnen seauenceNumber === u wnenttsine "trstreduestneseumolci detauirs kickinauromaricalveventFiterDefault on first requestEffectActiv1tvburat zonkangelmin_duration = 1 minDroos 0-secono activitiesActivityRecordedonly_recorded = 1Recorded activities onlvOrganiserGroupInUser's own groupRestricts to user's groupFrontend hits /api/v1/page/on-demand?topic id(]=...&sequence number=4 → sequence number=4 → isFirstRequest = false → no implicit defaults →returns 15 activities.AskJiminnyReportActivityService (before the fix) built params from the saved search filters but never included sequence number → defaulted to 0 → isFirstRequest() = true → implicit defaults applied → 0 activities returned because the topic filter + recorded-onlv + duration>1 together matchednothing.Why sequence_number=1 is the right fixThe service is doing a deliberate, one-shot search - not a paginated session. It should never apply first-request defaults, because:1. The saved search already encodes the user's intent (those filters were chosen explicitly)2. Date filters are already intentionally stripped (that's existing logic in DATE_FILTER_KEYS )3. Adding implicit min_duration, only_recorded, and group scope on top would contradict what the saved search representsSetting sequence number=1 is the minimal, correct signal: "this is not a fresh session open, don't apply page-load defaults". The criteria is otherwise builtidentically to how the controller builds it - same Criteria::createFromRequest, same get0nDemandPageFilterSet, same onDemandSearchIds0nly - so theresults will now match.Ö ul ...Ask anything (2*L)+ <> CodeClaude Sonnet 4.6Winasun leams39:9uir-o( 4 spaces...
|
NULL
|
|
11290
|
NULL
|
0
|
2026-04-14T09:24:21.506712+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776158661506_m1.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
iTerm2ShellEditViewSessionScriptsProfilesWindowHel iTerm2ShellEditViewSessionScriptsProfilesWindowHelp(abl§ Support Daily • in 2h 36 m100% <47DEV (docker)DOCKER• ₴1DEV (docker)882APP (-zsh)X3jiminny-worker-processing-2:jiminny-worker-processing-2_00: stoppedjiminny-worker-processing-3:jiminny-worker-processing-3_00: stoppedjiminny-worker-processing-4:jiminny-worker-processing-4_00: stoppedjiminny-worker-processing-5:jiminny-worker-processing-5_00: stoppedworker-analytics:worker-analytics_00: stoppedworker-crm-update:worker-crm-update_00: stoppedworker-download:worker-download_00: stoppedworker-nudges:worker-nudges_00: stoppedworker-emails:worker-emails_00: stoppedworker-crm-sync:worker-crm-sync_00: stoppedjiminny-worker-processing-1:jiminny-worker-processing-1_00: stoppedworker-calendar:worker-calendar_00:stoppedworker-audio:worker-audio_00: stoppedworker-conferences:worker-conferences_00: stoppedworker:worker_00: stoppedworker-es-update:worker-es-update_00: stoppedartisan-schedule:artisan-schedule_00: stoppedartisan-schedule:artisan-schedule_00: startedjiminny-worker-processing-1:jiminny-worker-processing-1_00: startedjiminny-worker-processing-2: jiminny-worker-processing-2_00: startedjiminny-worker-processing-3:jiminny-worker-processing-3_00: startedjiminny-worker-processing-4:jiminny-worker-processing-4_00: startedjiminny-worker-processing-5:jiminny-worker-processing-5_00: startedjiminny-worker-processing-delayed: jiminny-worker-processing-delayed_00: startedworker:worker_00: startedworker-analytics:worker-analytics_00:startedworker-audio:worker-audio_00: startedworker-calendar:worker-calendar_00:startedworker-conferences:worker-conferences_00: startedworker-crm-sync:worker-crm-sync_00: startedworker-crm-update:worker-crm-update_00: startedworker-download:worker-download_00:startedworker-emails:worker-emails_00:startedworker-es-update:worker-es-update_00: startedworker-nudges:worker-nudges_00: startedroot@docker_lamp_1:/home/jiminny# php artisan automated-reports 265ec2-user@ip-10-30-…-zsh885-zsh86-zsh®O ₴7Tue 14 Apr 12:24:21181* Unable to acce...O 88DEVNo arguments expected for "automated-reports"command, got "265".root@docker_lamp_1:/home/jiminny# php artisan automated-reports --report-id 265Report not found: 265root@docker_lamp_1:/home/jiminny# php artisan automated-reports --report-id 68root@docker_lamp_1:/home/jiminny#...
|
NULL
|
5567257713055636728
|
NULL
|
click
|
ocr
|
NULL
|
iTerm2ShellEditViewSessionScriptsProfilesWindowHel iTerm2ShellEditViewSessionScriptsProfilesWindowHelp(abl§ Support Daily • in 2h 36 m100% <47DEV (docker)DOCKER• ₴1DEV (docker)882APP (-zsh)X3jiminny-worker-processing-2:jiminny-worker-processing-2_00: stoppedjiminny-worker-processing-3:jiminny-worker-processing-3_00: stoppedjiminny-worker-processing-4:jiminny-worker-processing-4_00: stoppedjiminny-worker-processing-5:jiminny-worker-processing-5_00: stoppedworker-analytics:worker-analytics_00: stoppedworker-crm-update:worker-crm-update_00: stoppedworker-download:worker-download_00: stoppedworker-nudges:worker-nudges_00: stoppedworker-emails:worker-emails_00: stoppedworker-crm-sync:worker-crm-sync_00: stoppedjiminny-worker-processing-1:jiminny-worker-processing-1_00: stoppedworker-calendar:worker-calendar_00:stoppedworker-audio:worker-audio_00: stoppedworker-conferences:worker-conferences_00: stoppedworker:worker_00: stoppedworker-es-update:worker-es-update_00: stoppedartisan-schedule:artisan-schedule_00: stoppedartisan-schedule:artisan-schedule_00: startedjiminny-worker-processing-1:jiminny-worker-processing-1_00: startedjiminny-worker-processing-2: jiminny-worker-processing-2_00: startedjiminny-worker-processing-3:jiminny-worker-processing-3_00: startedjiminny-worker-processing-4:jiminny-worker-processing-4_00: startedjiminny-worker-processing-5:jiminny-worker-processing-5_00: startedjiminny-worker-processing-delayed: jiminny-worker-processing-delayed_00: startedworker:worker_00: startedworker-analytics:worker-analytics_00:startedworker-audio:worker-audio_00: startedworker-calendar:worker-calendar_00:startedworker-conferences:worker-conferences_00: startedworker-crm-sync:worker-crm-sync_00: startedworker-crm-update:worker-crm-update_00: startedworker-download:worker-download_00:startedworker-emails:worker-emails_00:startedworker-es-update:worker-es-update_00: startedworker-nudges:worker-nudges_00: startedroot@docker_lamp_1:/home/jiminny# php artisan automated-reports 265ec2-user@ip-10-30-…-zsh885-zsh86-zsh®O ₴7Tue 14 Apr 12:24:21181* Unable to acce...O 88DEVNo arguments expected for "automated-reports"command, got "265".root@docker_lamp_1:/home/jiminny# php artisan automated-reports --report-id 265Report not found: 265root@docker_lamp_1:/home/jiminny# php artisan automated-reports --report-id 68root@docker_lamp_1:/home/jiminny#...
|
11286
|
|
11291
|
NULL
|
0
|
2026-04-14T09:24:24.202632+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776158664202_m2.jpg...
|
NULL
|
NULL
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
PhpStormFileEditFV faVsco.js vViewNavigateCodeLara PhpStormFileEditFV faVsco.js vViewNavigateCodeLaravelRefactor#11894 on JY-18909-automated-reports-ask-iminny K vToolsWindowHelpProject vProphetAiv D Reports© AutomatedReportsCl© AutomatedReportsRe© AutomatedReportsSt© CreateMockAskJimir© DeleteReportComma© GenerateMarketingR© Team.php© Usage.phpD Slack• TeamsD TracksO TranscriptionO TwilioD Users• VocabularyDZoom© CoachingFeedbacksUpr© Command.php© CreateDatabaseUsers.pc Daraoase oecountoi© DeleteOldAiCrmNotesC:© DeleteS3LeftoversComiDevPostmanCommand./© DiarizeViaAiParticipantk© EncryptTokensComman© EngagementStatsRegen©FeatureFlagsHelper.php© FixCrossTenantlssues.p(c) -ushro espermissionsa(e) Generatelnterna wepho• GroupSetDefaultLangua© HelperTruncateCoachin© HubspotJournalPollingC© HubspotWebhookServic© ImportRecording.php© ImportUsersFromCsvFil© IterateUsersCommand.p© JiminnyCacheClearCom© JiminnyDebugCommanc© JiminnySetEncryptedTo(c) Jiminny okenintocommMakeslackLvecoaching(c Manacescimror eam.oselvicesv DatabaseV AEUc consoev Ajiminny@localhostA HS_local4SF 1 s 140 msV PROnA consoleV & STAGING4 console 1 s 153 msDocker© ReportController.phpAddLayoutchuitles.ono)TrackProviderInstalledEvent.phpJiminnyDeouecommana.ongAutomaleakeportscommana.ongAutomatedReportsSendCommand.phpC Team.phpC AutomatedReportsRepository.phpC) AutomatedReportsService.php© CreateHeldActivityEvent.php© UserPilotActivityListener.php© ActivityLogged.php© CreateActivityLoggedEvent.php© RequestGenerateAskJiminnyReportJob.php© AutomatedReportResult.phpclass Automacedkeporcscommand extends commandprivate tunccion processkeportsiscring errequency). vona117$this->logger->info(self::LOG_PREFIX . " Found {$reports->count()} $frequency reports to process");118119120121122123124125/** @var AutomatedReport $report */foreach ($reports as $report) {$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', I'reportUvid'= $report->getUvid(),'teamId' = $report->getTeamId(),'frequency'= $report->getFrequency().'type' => $report->getType(),1261):1128$job = $report->isAskJiminnyReport()? new RequestGenerateAskJiminnyReportJob($report->getUvid()): new RequestGenerateReportJob($report->getUvid());130131132133134135136137$this->dispatcher->dispatch($job);private function getReportById(string $reportid): Collection$report = $this->reportRepository->findByIdOrUuid($reportId);13914014114214314414514614711481if ($report === null) {$this->logger->warning(self::LOG_PREFIX' Report not found for --report-id', ['reportid' => $reportId]);$this-›warn( string: "Repofft not found: ($reportId}");return collect();if (! $report->getStatus()) {$this->logger->warning(self::LOG_PREFIX . ' Report is inactive, processing anyway (manual override)', [reoorclo = reoorclo.150reoorcuuo = nreoor-raeruure115-I):152153$this->warn( string: 'Report is inactive - processing anyway (manual override). ');Outputfb jiminny.automated_reports>50 rowsDid YTix: Auto vWuuid (UUID with time-low a...68 efe7dcab-955f-46ed-bbff-21fe6cc4f4b767 81ad94e2-8b64-4281-9e45-fac2ffe17359484r2acec+-c7e5-4521-0250-05129588002747 90ac7a1d-7b2c-40ed-b7e6-af2f70b1fe8846 be413ea5-8e74-479f-af30-d2e76917ab6245 d8be3cbc-48d0-4d40-ad09-8657fe3f8fad44 66880ca7-15d0-4d3a-b7d4-C61302c61a7a• team_id T• type Y1 ask_jiminny1 ask iiminnv• status Y1 exec_summary1 exec_summary1 exec summary1 exec summary1 exec_summaryI frequency1 monthly1 dailyO quarterly1 weekly1 weeklyo one_offo one_offsu rows retrieved staruno Trom 1in g49 ms (execution: 4/ ms, Telching: goz ms82 .Suobort Dailv • in 2h 36m100% [45)Tue 14 Aor 12:24:24= custom.log= laravel.log X© AskJiminnyReportActivityService.phpch Ask.liminnvRenortActivitvServiceTest.ohrA SF ljiminny@localhost]A HS_local [jiminny@localhost]ACuiVilysearch.ongA console [PROD]© HistoryService.php7 console [STAGING]Criteria.php172829: [HubSpot Journal Polling] Service ending: [HubSpot Journal Pollingl Released pollingX81emlplyetales .u ounel"trace_id":"d9196bad-6e26-4865-8: Jiminny\Console\Commands\Command:: run: Jiminny \Console\Commands\Command: :run lcE: Monitoring suary{"correlation_id"nandInMb":62.0, "memccabaf2a840e"}Ce. Monntorino enoauronared-revorts started'"correlarion 10aurolldreo-reoortsChecking conditions-995f-4e6dcaa55953"}{"correlatioaurolideo-reoors rrocessino caily redoriING: [automated-reports] Report not found for: [automated-reports] Found O daily reports to: [automated-reports] Completed: Jiminny\Console\Commands\Command: :run Memory: Jiminny\Console\Commands\Command:: run Memory: Jiminny \Console\Commands\Command::run Memory usage before starting command {"command":Lemartscheduled StAklinG bauch process• LemartscheduleJ FiNIsHED bauch processsiminnyNconsole commands (command::run• Jamanay Nconso le (commands (command.. run•runnano conterence.ionror.cour coi"6f598ff2-e7b2-40: [conference:monitor:count] No activities found in (2026-04-14 09:21:00, 2026-04-14 09:23:00]{"correlation_id":"6f598ff2-e7b2-40aa-9bcb-9: Jiminny\Console\Commands\Command: :run Memoryand": "conference:monitor:count", "memoryBeforeCommandInMb" : 62.0, "memor: Jiminny\Console\Commands\Command: : runusage before starting command {"command": "mailbox:batch: create", "memoryBeforeCommandInMb" : 62.: [EmailSchedule] STARTING batch create("correlation_id":"42facf77-8a99-4264-ad0b-aa587cc25281", "trace_id":"303448: [EmailSchedule] FINISHED batch create {"hosamp_1"} {"correlation_id":"42facf77-8a99-4264-ad0b-aa587cc25281", "trace_id":"303448: Jiminny\Console\Commands\Command: : run Memory usagelandInMb": 62.0, "memoryAft: [automated-reports]Started{"correlation_id''0463a4df-3b14-44b0-93df-8fd36ec1bbb0"',"trace_id":"99c14596-1d69-43ee-ab9b-f8f435a5911d"}[automated-reports]Checking conditions"isQuarterlyMonth":true} {"correlatio: [automated-reports]Processing daily reports""correlacion 10":[CREDIT_CARD]-7501-81050ec10000"urace 10":"44014570-1007-45ee-a070auronared-reoortsFound 1 daily reports to process{"correlation_id":"0463a4df-3b14-44b0-93df-8fd36ec1bbb0"', "trace_id":"99c14596-1d69-4aurolldreo-reoortsDispatching Generate Report job for report {"reportUuid": "efe7dcab-955f-46ed-bbff-21fe6cc4F4b7" ,[automated-reports] Completed{"correlation_id":"0463a4df-3b14-44b0-93df-8fd36ec1bbb0", "trace_99c14596-1d69-43ee-ab9b-f8f435a5911d"}[AskJiminnyReport:Generate] Started {"automatedReportUuid": "efe7dcab-955f-46ed-bkff-21fe6cc4f4b7'{"correlation_id":"aeadba58-122b-407b-a[Jiminny\Jobs\Mailbox\CreateBatches] processed O inboxes and created O batches {"userId":null,chSize":30, "maxBatches" :1000} {"correlat[AskJiminnyReport] Fetched activity IDs for saved search {"saved_search_id":1982, "user_id":143,"activity_count":59} {"correlation_id":"aea: [AskJiminnyReport:Generate] Fetched activity IDs {"automatedReportUvid":"efe7dcab-955f-46ed-bkff-21fe6cc4f4b7""activityCount":59} {"corre: [AskJiminnyReport:Generate] Request sent {"automatedReportUuid": "efe7dcak-955f-46ed-bbff-21fe6cc4f4b7" ,"reportUvid":"40ea120d-4c63-4bf5-9dR: Jiminny\Component\ProphetAi\ProphetClient::sendRequest: An Guzzle exception occurred while sending the request ("message" :"CURL error 7:R: [AskJiminnyReport:Generate] Error {"automatedReportUvid":"efe7dcab-955f-46ed-bkff-21fe6cc4f4b7", "reportUvid":"40ea120d-4C63-4bf5-9d93-02c:[AskJiminnyReport:Generate] Retry scheduled {"attempts":1} {"correlation_id":"aeadba58-122b-407b-a43c-71262552db78", "trace_id" : "99c14596-1: Ximinny (Console\Commands\Command: :run Memory usage before starting command {"command": "activity:sync", "memoryBeforeCommandInMb" : 62.0,"memolimánny Cancala Commande Command •nun Momany ncono fon commond dilsanD from YSNULL>0to T• deal_value_min YI deal_value_max T• call_types TShULl<null><null>SNULL><hULl<null><null>SNULL><null><null2025-07-21 00.001002025-07-21 00:00:002025-07-2 00.001002025-07-25 00:00:00<null<null>100100<null> []<null> []‹nu> "conference" "olallen"<null> ["conference",<null> ["conference", "dialer"]2000 ["conference"]2000 ["conference"]eSyy1+08I media_types TIO call_["pdf"]["pdf"]["pdf"]["pdf", "podcast"]["pdf"]["pdf"]["pdf"]W Windsurf Teams138:534 spaces...
|
NULL
|
4100981191523905441
|
NULL
|
visual_change
|
ocr
|
NULL
|
PhpStormFileEditFV faVsco.js vViewNavigateCodeLara PhpStormFileEditFV faVsco.js vViewNavigateCodeLaravelRefactor#11894 on JY-18909-automated-reports-ask-iminny K vToolsWindowHelpProject vProphetAiv D Reports© AutomatedReportsCl© AutomatedReportsRe© AutomatedReportsSt© CreateMockAskJimir© DeleteReportComma© GenerateMarketingR© Team.php© Usage.phpD Slack• TeamsD TracksO TranscriptionO TwilioD Users• VocabularyDZoom© CoachingFeedbacksUpr© Command.php© CreateDatabaseUsers.pc Daraoase oecountoi© DeleteOldAiCrmNotesC:© DeleteS3LeftoversComiDevPostmanCommand./© DiarizeViaAiParticipantk© EncryptTokensComman© EngagementStatsRegen©FeatureFlagsHelper.php© FixCrossTenantlssues.p(c) -ushro espermissionsa(e) Generatelnterna wepho• GroupSetDefaultLangua© HelperTruncateCoachin© HubspotJournalPollingC© HubspotWebhookServic© ImportRecording.php© ImportUsersFromCsvFil© IterateUsersCommand.p© JiminnyCacheClearCom© JiminnyDebugCommanc© JiminnySetEncryptedTo(c) Jiminny okenintocommMakeslackLvecoaching(c Manacescimror eam.oselvicesv DatabaseV AEUc consoev Ajiminny@localhostA HS_local4SF 1 s 140 msV PROnA consoleV & STAGING4 console 1 s 153 msDocker© ReportController.phpAddLayoutchuitles.ono)TrackProviderInstalledEvent.phpJiminnyDeouecommana.ongAutomaleakeportscommana.ongAutomatedReportsSendCommand.phpC Team.phpC AutomatedReportsRepository.phpC) AutomatedReportsService.php© CreateHeldActivityEvent.php© UserPilotActivityListener.php© ActivityLogged.php© CreateActivityLoggedEvent.php© RequestGenerateAskJiminnyReportJob.php© AutomatedReportResult.phpclass Automacedkeporcscommand extends commandprivate tunccion processkeportsiscring errequency). vona117$this->logger->info(self::LOG_PREFIX . " Found {$reports->count()} $frequency reports to process");118119120121122123124125/** @var AutomatedReport $report */foreach ($reports as $report) {$this->logger->info(self::LOG_PREFIX . ' Dispatching Generate Report job for report', I'reportUvid'= $report->getUvid(),'teamId' = $report->getTeamId(),'frequency'= $report->getFrequency().'type' => $report->getType(),1261):1128$job = $report->isAskJiminnyReport()? new RequestGenerateAskJiminnyReportJob($report->getUvid()): new RequestGenerateReportJob($report->getUvid());130131132133134135136137$this->dispatcher->dispatch($job);private function getReportById(string $reportid): Collection$report = $this->reportRepository->findByIdOrUuid($reportId);13914014114214314414514614711481if ($report === null) {$this->logger->warning(self::LOG_PREFIX' Report not found for --report-id', ['reportid' => $reportId]);$this-›warn( string: "Repofft not found: ($reportId}");return collect();if (! $report->getStatus()) {$this->logger->warning(self::LOG_PREFIX . ' Report is inactive, processing anyway (manual override)', [reoorclo = reoorclo.150reoorcuuo = nreoor-raeruure115-I):152153$this->warn( string: 'Report is inactive - processing anyway (manual override). ');Outputfb jiminny.automated_reports>50 rowsDid YTix: Auto vWuuid (UUID with time-low a...68 efe7dcab-955f-46ed-bbff-21fe6cc4f4b767 81ad94e2-8b64-4281-9e45-fac2ffe17359484r2acec+-c7e5-4521-0250-05129588002747 90ac7a1d-7b2c-40ed-b7e6-af2f70b1fe8846 be413ea5-8e74-479f-af30-d2e76917ab6245 d8be3cbc-48d0-4d40-ad09-8657fe3f8fad44 66880ca7-15d0-4d3a-b7d4-C61302c61a7a• team_id T• type Y1 ask_jiminny1 ask iiminnv• status Y1 exec_summary1 exec_summary1 exec summary1 exec summary1 exec_summaryI frequency1 monthly1 dailyO quarterly1 weekly1 weeklyo one_offo one_offsu rows retrieved staruno Trom 1in g49 ms (execution: 4/ ms, Telching: goz ms82 .Suobort Dailv • in 2h 36m100% [45)Tue 14 Aor 12:24:24= custom.log= laravel.log X© AskJiminnyReportActivityService.phpch Ask.liminnvRenortActivitvServiceTest.ohrA SF ljiminny@localhost]A HS_local [jiminny@localhost]ACuiVilysearch.ongA console [PROD]© HistoryService.php7 console [STAGING]Criteria.php172829: [HubSpot Journal Polling] Service ending: [HubSpot Journal Pollingl Released pollingX81emlplyetales .u ounel"trace_id":"d9196bad-6e26-4865-8: Jiminny\Console\Commands\Command:: run: Jiminny \Console\Commands\Command: :run lcE: Monitoring suary{"correlation_id"nandInMb":62.0, "memccabaf2a840e"}Ce. Monntorino enoauronared-revorts started'"correlarion 10aurolldreo-reoortsChecking conditions-995f-4e6dcaa55953"}{"correlatioaurolideo-reoors rrocessino caily redoriING: [automated-reports] Report not found for: [automated-reports] Found O daily reports to: [automated-reports] Completed: Jiminny\Console\Commands\Command: :run Memory: Jiminny\Console\Commands\Command:: run Memory: Jiminny \Console\Commands\Command::run Memory usage before starting command {"command":Lemartscheduled StAklinG bauch process• LemartscheduleJ FiNIsHED bauch processsiminnyNconsole commands (command::run• Jamanay Nconso le (commands (command.. run•runnano conterence.ionror.cour coi"6f598ff2-e7b2-40: [conference:monitor:count] No activities found in (2026-04-14 09:21:00, 2026-04-14 09:23:00]{"correlation_id":"6f598ff2-e7b2-40aa-9bcb-9: Jiminny\Console\Commands\Command: :run Memoryand": "conference:monitor:count", "memoryBeforeCommandInMb" : 62.0, "memor: Jiminny\Console\Commands\Command: : runusage before starting command {"command": "mailbox:batch: create", "memoryBeforeCommandInMb" : 62.: [EmailSchedule] STARTING batch create("correlation_id":"42facf77-8a99-4264-ad0b-aa587cc25281", "trace_id":"303448: [EmailSchedule] FINISHED batch create {"hosamp_1"} {"correlation_id":"42facf77-8a99-4264-ad0b-aa587cc25281", "trace_id":"303448: Jiminny\Console\Commands\Command: : run Memory usagelandInMb": 62.0, "memoryAft: [automated-reports]Started{"correlation_id''0463a4df-3b14-44b0-93df-8fd36ec1bbb0"',"trace_id":"99c14596-1d69-43ee-ab9b-f8f435a5911d"}[automated-reports]Checking conditions"isQuarterlyMonth":true} {"correlatio: [automated-reports]Processing daily reports""correlacion 10":[CREDIT_CARD]-7501-81050ec10000"urace 10":"44014570-1007-45ee-a070auronared-reoortsFound 1 daily reports to process{"correlation_id":"0463a4df-3b14-44b0-93df-8fd36ec1bbb0"', "trace_id":"99c14596-1d69-4aurolldreo-reoortsDispatching Generate Report job for report {"reportUuid": "efe7dcab-955f-46ed-bbff-21fe6cc4F4b7" ,[automated-reports] Completed{"correlation_id":"0463a4df-3b14-44b0-93df-8fd36ec1bbb0", "trace_99c14596-1d69-43ee-ab9b-f8f435a5911d"}[AskJiminnyReport:Generate] Started {"automatedReportUuid": "efe7dcab-955f-46ed-bkff-21fe6cc4f4b7'{"correlation_id":"aeadba58-122b-407b-a[Jiminny\Jobs\Mailbox\CreateBatches] processed O inboxes and created O batches {"userId":null,chSize":30, "maxBatches" :1000} {"correlat[AskJiminnyReport] Fetched activity IDs for saved search {"saved_search_id":1982, "user_id":143,"activity_count":59} {"correlation_id":"aea: [AskJiminnyReport:Generate] Fetched activity IDs {"automatedReportUvid":"efe7dcab-955f-46ed-bkff-21fe6cc4f4b7""activityCount":59} {"corre: [AskJiminnyReport:Generate] Request sent {"automatedReportUuid": "efe7dcak-955f-46ed-bbff-21fe6cc4f4b7" ,"reportUvid":"40ea120d-4c63-4bf5-9dR: Jiminny\Component\ProphetAi\ProphetClient::sendRequest: An Guzzle exception occurred while sending the request ("message" :"CURL error 7:R: [AskJiminnyReport:Generate] Error {"automatedReportUvid":"efe7dcab-955f-46ed-bkff-21fe6cc4f4b7", "reportUvid":"40ea120d-4C63-4bf5-9d93-02c:[AskJiminnyReport:Generate] Retry scheduled {"attempts":1} {"correlation_id":"aeadba58-122b-407b-a43c-71262552db78", "trace_id" : "99c14596-1: Ximinny (Console\Commands\Command: :run Memory usage before starting command {"command": "activity:sync", "memoryBeforeCommandInMb" : 62.0,"memolimánny Cancala Commande Command •nun Momany ncono fon commond dilsanD from YSNULL>0to T• deal_value_min YI deal_value_max T• call_types TShULl<null><null>SNULL><hULl<null><null>SNULL><null><null2025-07-21 00.001002025-07-21 00:00:002025-07-2 00.001002025-07-25 00:00:00<null<null>100100<null> []<null> []‹nu> "conference" "olallen"<null> ["conference",<null> ["conference", "dialer"]2000 ["conference"]2000 ["conference"]eSyy1+08I media_types TIO call_["pdf"]["pdf"]["pdf"]["pdf", "podcast"]["pdf"]["pdf"]["pdf"]W Windsurf Teams138:534 spaces...
|
11289
|
|
11292
|
224
|
0
|
2026-04-14T09:24:39.149791+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776158679149_m1.jpg...
|
PhpStorm
|
faVsco.js – AutomatedReportsCommand.php
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
AskJiminnyReportActivityServiceT…Defaults
Run 'AskJiminnyReportActivityServiceTest.tes…uenceNumberToDisableFirstRequestDefaults'
Debug 'AskJiminnyReportActivityServiceTest.tes…uenceNumberToDisableFirstRequestDefaults'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings...
|
[{"role":"AXButton","text" [{"role":"AXButton","text":"Project: faVsco.js, menu","depth":5,"help_text":"~/jiminny/app","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"#11894 on JY-18909-automated-reports-ask-jiminny, menu","depth":5,"help_text":"Pull request #11894 exists for current branch JY-18909-automated-reports-ask-jiminny, but local branch is out of sync with remote","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Start Listening for PHP Debug Connections","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"AskJiminnyReportActivityServiceT…Defaults","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Run 'AskJiminnyReportActivityServiceTest.tes…uenceNumberToDisableFirstRequestDefaults'","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Debug 'AskJiminnyReportActivityServiceTest.tes…uenceNumberToDisableFirstRequestDefaults'","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"More Actions","depth":6,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"JetBrains AI","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Search Everywhere","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"IDE and Project Settings","depth":5,"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false}]...
|
-6884388984026562300
|
-8636777060039973950
|
click
|
hybrid
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
AskJiminnyReportActivityServiceT…Defaults
Run 'AskJiminnyReportActivityServiceTest.tes…uenceNumberToDisableFirstRequestDefaults'
Debug 'AskJiminnyReportActivityServiceTest.tes…uenceNumberToDisableFirstRequestDefaults'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
iTerm2ShellEditViewSessionScriptsProfilesWindowHelp(abl§ Support Daily • in 2h 36 m100% <47DEV (docker)DOCKER• ₴1DEV (docker)882APP (-zsh)X3jiminny-worker-processing-2:jiminny-worker-processing-2_00: stoppedjiminny-worker-processing-3:jiminny-worker-processing-3_00: stoppedjiminny-worker-processing-4:jiminny-worker-processing-4_00: stoppedjiminny-worker-processing-5:jiminny-worker-processing-5_00: stoppedworker-analytics:worker-analytics_00: stoppedworker-crm-update:worker-crm-update_00: stoppedworker-download:worker-download_00: stoppedworker-nudges:worker-nudges_00: stoppedworker-emails:worker-emails_00: stoppedworker-crm-sync:worker-crm-sync_00: stoppedjiminny-worker-processing-1:jiminny-worker-processing-1_00: stoppedworker-calendar:worker-calendar_00:stoppedworker-audio:worker-audio_00: stoppedworker-conferences:worker-conferences_00: stoppedworker:worker_00: stoppedworker-es-update:worker-es-update_00: stoppedartisan-schedule:artisan-schedule_00: stoppedartisan-schedule:artisan-schedule_00: startedjiminny-worker-processing-1:jiminny-worker-processing-1_00: startedjiminny-worker-processing-2: jiminny-worker-processing-2_00: startedjiminny-worker-processing-3:jiminny-worker-processing-3_00: startedjiminny-worker-processing-4:jiminny-worker-processing-4_00: startedjiminny-worker-processing-5:jiminny-worker-processing-5_00: startedjiminny-worker-processing-delayed: jiminny-worker-processing-delayed_00: startedworker:worker_00: startedworker-analytics:worker-analytics_00:startedworker-audio:worker-audio_00: startedworker-calendar:worker-calendar_00:startedworker-conferences:worker-conferences_00: startedworker-crm-sync:worker-crm-sync_00: startedworker-crm-update:worker-crm-update_00: startedworker-download:worker-download_00:startedworker-emails:worker-emails_00:startedworker-es-update:worker-es-update_00: startedworker-nudges:worker-nudges_00: startedroot@docker_lamp_1:/home/jiminny# php artisan automated-reports 265ec2-user@ip-10-30-…-zsh885-zsh86-zsh®O ₴7Tue 14 Apr 12:24:38181* Unable to acce...O 88DEVNo arguments expected for "automated-reports"command, got "265".root@docker_lamp_1:/home/jiminny# php artisan automated-reports --report-id 265Report not found: 265root@docker_lamp_1:/home/jiminny# php artisan automated-reports --report-id 68root@docker_lamp_1:/home/jiminny#...
|
NULL
|
|
11293
|
225
|
0
|
2026-04-14T09:24:39.156520+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776158679156_m2.jpg...
|
PhpStorm
|
faVsco.js – AutomatedReportsCommand.php
|
True
|
NULL
|
monitor_2
|
NULL
|
NULL
|
NULL
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
AskJiminnyReportActivityServiceT…Defaults
Run 'AskJiminnyReportActivityServiceTest.tes…uenceNumberToDisableFirstRequestDefaults'
Debug 'AskJiminnyReportActivityServiceTest.tes…uenceNumberToDisableFirstRequestDefaults'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings...
|
[{"role":"AXButton","text" [{"role":"AXButton","text":"Project: faVsco.js, menu","depth":5,"bounds":{"left":0.03046875,"top":0.017361112,"width":0.0453125,"height":0.022222223},"help_text":"~/jiminny/app","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"#11894 on JY-18909-automated-reports-ask-jiminny, menu","depth":5,"bounds":{"left":0.07578125,"top":0.017361112,"width":0.14960937,"height":0.022222223},"help_text":"Pull request #11894 exists for current branch JY-18909-automated-reports-ask-jiminny, but local branch is out of sync with remote","role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Start Listening for PHP Debug Connections","depth":5,"bounds":{"left":0.7589844,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"AskJiminnyReportActivityServiceT…Defaults","depth":6,"bounds":{"left":0.7769531,"top":0.017361112,"width":0.12382813,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Run 'AskJiminnyReportActivityServiceTest.tes…uenceNumberToDisableFirstRequestDefaults'","depth":6,"bounds":{"left":0.9007813,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Debug 'AskJiminnyReportActivityServiceTest.tes…uenceNumberToDisableFirstRequestDefaults'","depth":6,"bounds":{"left":0.9140625,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"More Actions","depth":6,"bounds":{"left":0.9273437,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"JetBrains AI","depth":5,"bounds":{"left":0.96015626,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"Search Everywhere","depth":5,"bounds":{"left":0.9734375,"top":0.017361112,"width":0.01328125,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false},{"role":"AXButton","text":"IDE and Project Settings","depth":5,"bounds":{"left":0.9867188,"top":0.017361112,"width":0.013281226,"height":0.022222223},"role_description":"button","is_enabled":true,"is_focused":false,"is_selected":false,"is_expanded":false}]...
|
-6884388984026562300
|
-8636777060039973950
|
click
|
hybrid
|
NULL
|
Project: faVsco.js, menu
#11894 on JY-18909-automa Project: faVsco.js, menu
#11894 on JY-18909-automated-reports-ask-jiminny, menu
Start Listening for PHP Debug Connections
AskJiminnyReportActivityServiceT…Defaults
Run 'AskJiminnyReportActivityServiceTest.tes…uenceNumberToDisableFirstRequestDefaults'
Debug 'AskJiminnyReportActivityServiceTest.tes…uenceNumberToDisableFirstRequestDefaults'
More Actions
JetBrains AI
Search Everywhere
IDE and Project Settings
PhpStormFileEditFV faVsco.js vViewNavigateCodeLaravelRefactor#11894 on JY-18909-automated-reports-ask-iminny K vToolsWindowHelpProject vProphetAiv D Reports© AutomatedReportsCl© AutomatedReportsRe© AutomatedReportsSt© CreateMockAskJimir© DeleteReportComma© GenerateMarketingR© Team.php© Usage.phpD Slack• TeamsD TracksO TranscriptionO TwilioD UsersVocabularyDZoom© CoachingFeedbacksUpr© Command.php© CreateDatabaseUsers.pc Daraoase oecountoi© DeleteOldAiCrmNotesC:© DeleteS3LeftoversComiDevPostmanCommand./© DiarizeViaAiParticipantk© EncryptTokensComman© EngagementStatsRegen©FeatureFlagsHelper.php© FixCrossTenantlssues.p(c) -ushro espermissionsc(e) Generatelnterna wepho• GroupSetDefaultLangua© HelperTruncateCoachin© HubspotJournalPollingC© HubspotWebhookServic© ImportRecording.php© ImportUsersFromCsvFil© IterateUsersCommand.p© JiminnyCacheClearCom© JiminnyDebugCommanc© JiminnySetEncryptedTo(c) Jiminny okenintocommMakeslackLvecoaching(c Manacescimror eam.oselvicesv DatabaseV AEUc consoev A jiminny@localhostA HS_local4SF 1 s 140 msV PROnA consoleV & STAGING4 console 1 s 153 msDocker© ReportController.phpAddLayoutchuitles.ono© TrackProviderInstalledEvent.phpJiminnyDeouecommana.ongAutomaleakeportscommana.ongAutomatedReportsSendCommand.phpC Team.phpC AutomatedReportsRepository.phpAutomatedReportsService.php© CreateHeldActivityEvent.php© UserPilotActivityListener.php© ActivityLogged.phpCreateActivityLoggedEvent.php© RequestGenerateAskJiminnyReportJob.php© AutomatedReportResult.phpA2147148149150151152153154155class Automacedkeporcscommand extends commandprivate tunccion geckeportbyra scring @reporcia). cotceccionif (! $report->getStatus()) {stpis→ logger→ warning (seLf:LOG_PREFIX . " Report is inactive, processing anyway (manual override)' ,'reportId' => $reportId,'reportuuid' => $report->getUuid(),1):$this->warn( string: 'Report is inactive - processing anyway (manual override).');157158159160161162163164165166+ceall - +report->gecrean),if ($team->getStatus() !== Team: :STATUS_ACTIVE) {$this->logger->warning(self::LOG_PREFIX'reportid' => Sreportid,'reportUvid' => $report->getUvid(),'teamId' => $report->getTeamId(),'teamStatus'→> $team->getStatus(),Team is not active, processing anyway (manual override)', [1);$this->warn( string: "Team #[$report->getTeamId(} is not active - processing anyway (manual override)."):1681107170171172173174175176177178if ($report->isExpired()) {$this->logger->warning(self::LOG_PREFIX . ' Report is expired, processing anyway (manual override)', ['reportId' => SreportId.'reportUvid' => $report->getUvid(),'expiresAt' => $report->getExpiresAt()?->toDateString(),I);$this->warn( string: 'Report is expired (expires_at:$report->getExpiresAt()?->toDateString()') - processing aireturn collect([$reportl);:Outputfb jiminny.automated_reports X50 rowsDid YTix: Auto vWuuid (UUID with time-low a...68 efe7dcab-955f-46ed-bbff-21fe6cc4f4b767 81ad94e2-8b64-4281-9e45-fac2ffe17359484r2acec+-c7e5-4521-0250-05129588002747 90ac7a1d-7b2c-40ed-b7e6-af2f70b1fe8846 be413ea5-8e74-479f-af30-d2e76917ab6245 d8be3cbc-48d0-4d40-ad09-8657fe3f8fad44 66880ca7-15d0-4d3a-b7d4-C61302c61a7a• team_id T• type Y1 ask_jiminny1 ask iiminnv• status YI frequency1 monthly1 exec_summary1 exec_summary1 exec summary1 exec summary1 exec_summaryIdallyO quarterly1 weekly1 weeklyo one_offo one_offsu rows retrieved staruno Trom 1in g49 ms (execution: 4/ ms, Telching: goz msSuobort Dailv • in 2h 36m100% [45)Tue 14 Aor 12:24:38= custom.log= laravel.log X© AskJiminnyReportActivityService.phpch Ask.liminnvRenortActivitvServiceTest.ohrA SF ljiminny@localhost]A HS_local [jiminny@localhost]ACuiVilysearch.ongA console [PROD]© HistoryService.php7 console [STAGING]Criteria.php173033: [HubSpot Journal Polling] Service ending: [HubSpot Journal Pollingl Released pollingX81emlplyetales .u ounel"trace_id":"d9196bad-6e26-4865-8: Jiminny\Console\Commands\Command::run: Jiminny \Console\Commands\Command: :run lcE: Monitoring suary{"correlation_id"nandInMb":62.0, "memccabaf2a840e"}Ce. Monntorino enolautomated-reportsl Started'"correlarion 10aurolldreo-reoortsChecking conditions-995f-4e6dcaa55953"}{"correlatioaurolldreo-reooris rrocessino caiuy reoorING: [automated-reports] Report not found for: [automated-reports] Found o daily reports to: [automated-reports] Completed{"correlation.: Jiminny\Console\Commands\Command::run Memory: Jiminny\Console\Commands\Command::run Memory: Jiminny \Console\Commands\Command::run Memory usage before starting command {"command":[EmailSchedule] STARTING batch processLemartscheduley Finished bauch processJiminnyNconsole commands (command:: run• Jamanay yeonsole (commands (command..run• knning conterence.montcor.count cor"6f598ff2-e7b2-40: [conference:monitor:count] No activities found in (2026-04-14 09:21:00, 2026-04-14 09:23:00]{"correlation_id":"6f598ff2-e7b2-40aa-9bcb-9: Jiminny\Console\Commands\Command: :run Memoryand": "conference:monitor:count", "memoryBeforeCommandInMb" : 62.0, "memor: Jiminny\ConsoLe\Commands\Command:: runusage before starting command {"command": "mailbox:batch: create", "memoryBeforeCommandInMb" : 62.: [EmailSchedule] STARTING batch create("correlation_id":"42facf77-8a99-4264-ad0b-aa587cc25281", "trace_id":"303448: [EmailSchedule] FINISHED batch create {"hosamp_1"} {"correlation_id":"42facf77-8a99-4264-ad0b-aa587cc25281", "trace_id":"303448: Jiminny\Console\Commands\Command: :run Memory usagelandInMb": 62.0, "memoryAft: [automated-reports]Started{"correlation_id''0463a4df-3b14-44b0-93df-8fd36ec1bbb0"',"trace_id":"99c14596-1d69-43ee-ab9b-f8f435a5911d"}[automated-reports]Checking conditions"isQuarterlyMonth":true} {"correlatio: [automated-reports]Processing daily reports""correlacion 10":[CREDIT_CARD]-7501-81050ec10000"urace 10":"44014570-1007-45ee-a070: [automated-reports] Found 1 daily reports to process{"correlation_id":"0463a4df-3b14-44b0-93df-8fd36ec1bbb0", "trace_id":"99c14596-1d69-4[automated-reports] Dispatching Generate Report job for report {"reportUuid": "efe7dcab-955f-46ed-bbff-21fe6cc4f4b7" ,[automated-reports] Completed{"correlation_id":"0463a4df-3b14-44b0-93df-8fd36ec1bbb0", "trace_99c14596-1d69-43ee-ab9b-f8f435a5911d"}[AskJiminnyReport:Generate] Started {"automatedReportUvid": "efe7dcab-955f-46ed-bbff-21fe6cc4F4b7'{"correlation_id":"aeadka58-122b-407b-a[Jiminny\Jobs\Mailbox\CreateBatches] processed O inboxes and created O batches {"userId":null,chSize":30, "maxBatches" :1000} {"correlat[AskJiminnyReport] Fetched activity IDs for saved search {"saved_search_id":1982, "user_id":143,"activity_count":59} {"correlation_id":"aea[AskJiminnyReport:Generate] Fetched activity IDs {"automatedReportUvid": "efe7dcab-955f-46ed-bbff-21fe6cc4f4b7""activityCount":59} {"corre: [AskJiminnyReport:Generate] Request sent {"automatedReportUuid": "efe7dcak-955f-46ed-bbff-21fe6cc4f4b7" ,"reportUvid":"40ea120d-4c63-4bf5-9dR: Jiminny\Component\ProphetAi\ProphetClient::sendRequest: An Guzzle exception occurred while sending the request ("message" :"CURL error 7:R: [AskJiminnyReport:Generate] Error {"automatedReportUvid":"efe7dcab-955f-46ed-bkff-21fe6cc4f4b7", "reportUvid":"40ea120d-4C63-4bf5-9d93-02c: [AskJiminnyReport:Generate] Retry scheduled {"attempts":1} {"correlation_id":"aeadka58-122b-407b-a43c-71262552db78", "trace_id" : "99c14596-1: Jiminny \Console\Commands\Command::run Memory usage before starting command {"command": "activity: sync", "memoryBeforeCommandInMb" :62.0, "memolimánny Cancala Commande Command •nun Momany ncono fon commond dilsanI from vto Y• deal_value_min YI deal_value_max T• call_types TSNULL>ShULl<null><null>SNULL><hULl<null><null>SNULL><null><null2025-07-21 00.001002025-07-21 00:00:002025-07-2 00.001002025-07-25 00:00:00<null<null>100100<null> []<null> []‹nu> "conference" "olallen"<null> ["conference",<null> ["conference", "dialer"]2000 ["conference"]2000 ["conference"]eSyy1+08I media_types TIO call_["pdf"]["pdf"]["pdf"]["pdf", "podcast"]["pdf"]["pdf"]["pdf"]W Windsurf Teams138:534 spaces...
|
NULL
|
|
11381
|
NULL
|
0
|
2026-04-14T09:29:46.418962+00:00
|
/Users/lukas/.screenpipe/data/data/2026-04-14/1776 /Users/lukas/.screenpipe/data/data/2026-04-14/1776158986418_m1.jpg...
|
iTerm2
|
✳ Unable to access screenpipe activity data
|
True
|
NULL
|
monitor_1
|
NULL
|
NULL
|
NULL
|
NULL
|
╭─── Claude Code v2.1.97 ───────────────────────── ╭─── Claude Code v2.1.97 ──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ │ Tips for getting started │ │
│ Welcome back Lukas! │ Run /init to create a CLAUDE.md file with instructions for Claude │ │
│ │ Note: You have launched claude in your home directory. For the best experience, launch it in a proje│ │
│ ▐▛███▜▌ │ ────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────│
│ ▝▜█████▛▘ │ Recent activity │ │
│ ▘▘ ▝▝ │ No recent activity │ │
│ Sonnet 4.6 · Claude Pro · │ │
│ [EMAIL]'s Organization │ │
│ /Users/lukas │ │
╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
❯ what did I do yesterday? Give me summary of my activity from screenpipe
⏺ Here's your activity summary for yesterday (April 11):
---
Total active time: ~3 hours (roughly 15:00–21:00 UTC)
Main focus areas
Screenpipe development (~2h combined)
- Heavy terminal work in iTerm2 (67 min in zsh + SSH)
- Building a screenpipe data UI — working remotely on [IP_ADDRESS] via SSH
- Editing report.py and a bash script in VS Code
- Checking the Screenpipe Dashboard in Firefox
Work (Jiminny) (~15 min)
- Checked the Scrum Board for Platform Sprint 1 Q2
- Looked at service desk queues
- Checked an email about an "Ask Jiminny" |