maelstrom-cms/odin

Timezone and x-axis of uptime monitor

Closed this issue · 4 comments

Hi,

I think the timezone shouldn't be hard-coded in app/Console/Kernel.php but using the config from config/app.pp.

protected function scheduleTimezone()
    {
        return 'Europe/London';
    }

--->

protected function scheduleTimezone()
    {
        return config('app.timezone');
    }

so we can set the timezone in .env.

Would you accept a PR?

Another thing I noticed is that the timescale for the uptime monitor goes from right-to-left. Is this intentional? Normally timescales go ltr.

Hi,

Yeah we'd accept a PR to configure the time zone from the env as long as it defaults to London :)

I'm not sure what you mean about the right to left thing sorry?

Thanks

Hey @OwenMelbz,

about the "right-to-left" thing: I think what @martin-ro means is that normally a time scale would draw from oldest (left) to newest (right) entries. Currently it is the other way around for the Response Time chart having the latest data on the left.

... and towards the time zone configuration:

I think, since the core class already uses the config key app.schedule_timezone and app.timezone as fallback, it should be safe to remove the method scheduleTimezone from app/Console/Kernel.php.

Thanks for the help 👍

Have merged and closed :)