UPDATE: This only happens on new UI Pages.. like T...
# suitescript
s
UPDATE: This only happens on new UI Pages.. like TIMESHEET, and not on legacy pages…
N/ui/message
module: I am seeing text with HTML tags rendered as text without consideration for the tags…
N/ui/message
used to support some HTML characters like
<p></p>
and
<ul><li></li></ul>
does anyone know when this changed?
e
2023.2 I believe - latest release
e
I have a client on 2023.2 and it still works for them-
s
Yea, crazy right?!
Do you know if that’s a 2.0 module or 2.1?
I’m using SS 2.1.
e
Sorry @suitedev. I was thinking of the Saved Search change where they stopped allowing HTML in text values. This is different. I don't think I've seen anything about this.
e
I'm using 2.1 as well
Worth noting- mine is in a beforeLoad UE on a Sales Order using
form.addPageInitMessage
s
Yes, I’m using a UE with addpageinitmessage as well.
OH dang… I just figured it out…
e
I use <br> instead of <p> (idk if that matters)
s
The Timesheet page is one of those new UI Pages and it fails.
If I do the same on an Employee page, it works
e
Gotcha. (yeah <br> seems to work where <br/> doesnt)
s
Well, this is the page where it’s different.
e
I know that SS1.0 has an undocumented function for creating those banners... not sure if you could throw some logic into an inline html field
s
I didn’t change the tags.
e
Ohhhh I see what you're saying- <br/> works on Employee but not on Time Sheet
💥 1
s
I think it’s the implementation of the N/ui/message module on that new page UI./
notice how the blue circle icon has a different weight?
e
Shot in the dark here--- maybe try escaping your html characters? Maybe the new UI parses out text from the html... \<p\>Whatever here... \<\/p\>
s
The entire text block is being htmlencoded when the messages is presented.
<p>30.75 General & Administrative</p><p>16 Time Off</p>
s
looks like no more sneaking in html where it's not documented? Unless that string is documented to support HTML in which case you have a support case to file. :)
I've generally always tried to avoid HTML in spots where it's not officially supported. Being unsupported, it's quite acceptable for NS to make it stop working at any time - which looks like what's happening here?
e
Yep, looks like they moved from
element.innerHTML =
to
element.innerText =
Almost more frustrating that they only changed it on the newer (jet) forms, and not on the old ones also
s
I did file a support case already.
We need to be able to distinguish between lines in the message.. and also to create links in the messages.. so this is definitely a defect.
I’ll post here when the defect has been created. fingers crossed.
🤞 1