Webreport is showing DB time of the Workflow initiation instead of local time in smartview

Luis Reis
Luis Reis Member

We have created a custom dashboard based on a data source live report and a webreport to format the data.
The dashboard shows details of workflows, and our main issue is with the timestamp shown in the smart view, which is 3 hours ahead of the time at the location of the activity. That happens because we are working with a PaaS database, so it only works with utc timezone, and we are in Brazil, GMT-3.
Basically, the data fetched from the database through the live report is correct when the 'Get date and time from client' option is checked in the admin console. But, when using the livereport to feed the WR with data, the offset does not work and the data seems to be collected raw from the DB.

We've added these tags in the header section, to use as a quick check to see if any solution works:

Change the line:

<TD class="foraDoPrazo">&nbsp;[LL_REPTAG_2 DATE:"%d/%m/%Y %H:%M" /]</TD>

TO:

<TD class="foraDoPrazo">&nbsp;[LL_REPTAG_2 TZOFFSET DATE:"%d/%m/%Y %H:%M" /]</TD>

in classic view the changes have taken effect, as seen below

After apply the changes, the dates disappear in a smart view

so these tags worked for classic view and didn't work for smart view, could someone help us solve this problem?

thanks for your support

Answers

  • In the old CS setting the TZ offset was only in the classic UI. Later in better servers, they started adding a toggle in the Configure Smart View

    I also think in absolutely new CS this setting has been only in one place I am not sure. I have customers who perform SmartUI activities when the Livelink database is set to UTC.

  • Hi appuq, thanks for your suggestion, we made those changes including that "Use classic UI date/time format" flag but they had no effect. Do you have any other suggestions for changes to the code or configuration for us to try?
    Now even the user time is the same as the server

  • are there multiple Content Servers involved, the setting affects only the instance you make if it doesn't work open a ticket

  • we opened a ticket with OT on 04/01/24 and for all these weeks they couldn't resolve it, in the end they suggested we seek help on the forum lol
    thanks for your time

  • could it be then a problem with the WR code? if you bring up SmartUI after you change the setting does smartUI show the offset time?>Notice the changes to instances only get done after the server is started. You may also want to eliminate any browser caching.In IE and Edge there is a setting that says show me the page everytime ic lick it that kind

  • There is something wrong in our understanding of how this works, follow the script as I say

    I am using an old server Content Server 22.3, build 16.2.21.1994

    I used Admin as the user

    I went and made Admin's TZ manually to US Central, if you don't know what that is I found the Admin record, and the TZ offset was empty so I put it to US CENTRAL

    Then I ticked Classic to say I want TZ offset

    Then I went and enabled smartUI and said I want you to use SmartUI

    I restarted the server and on a new browser to rule out caching

    I dragged and dropped a File and my windows computer reported 10.41 am

    voila I got the SmartUI to do that

    I go to classic it disregarded it

    I suspect OT code is not fully flushed in all versions will try to post on a different server I have a cluster build of 23.4 so going to repeat there

    The OT WR code as you said did not do anything different

  • IN CS23.4 the Admin user did not need me to manually tweak the TZ on the user record.When I add in Classic it still reflected GMT (server) Smart applied offset automatically for UC central

    The WR showed both times as GMT

    [LL_REPTAG_TIMEZONE SHOW /]

    SERVER TZ [LL_REPTAG_DATETIME /]
    USERS BROWSER FOR ADMIN[LL_REPTAG_DATETIME TZOFFSET /]

    [LL_WEBREPORT_STARTROW /]

    [LL_WEBREPORT_ENDROW /]

    It is quite possible the WR when I execute in Smart is still in classic perhaps I ned to call this in a perspective.

    I would in your ticket involve @Nizar Ghazal of OT and perhaps include this thread so he may be able to enhance how it is supposed to be used

  • Luis Reis
    Luis Reis Member
    edited July 25, 2024 #9

    Hello appuq,

    this is the code with the settings you suggested

    The [LL_REPTAG_DATETIME TZOFFSET /] tag is working when we run the webreport for the classic view, but the same [LL_REPTAG_DATETIME TZOFFSET /] tag is blank when we run the same webreport for the smart view, so we can't set the date to the correct timezone and when we remove this tag the server time is displayed and not the time of the brazil timezone which would be the same as the time on the user's computer clock.

    when we run the same webreport as you can see below, the tag [LL_REPTAG_DATETIME TZOFFSET /] that works for the classic view doesn't work for the smart view.

    I'm sorry if I wasn't clear enough to explain the problem.
    but the problem is in the tag that is applied inside the webreport for the smart view.
    could you help me with this please?

  • perhaps you have to also do that in Configure Smart View

    If you are logging in as a USER make sure you have selected manually the USER's TZ as well.

  • appuq
    appuq Member
    edited July 25, 2024 #11

    another way I would have tried is using JS after your output is printed perhaps you can create a DIV and put the current date/time?

    A way a WR works is like this your TAG information is processed by the server and for ease, Oscript and the browser render it using the smartui SDK(the marionette/backbone/JS/Nucleus all that jazz which I don't fully know)

    I saw what you said playing with a perspective so I did this and it seems to be working for me

    I looked and it said Brazil is 3 hrs behind UTC so I made the math as 3*60*60