appsmith icon indicating copy to clipboard operation
appsmith copied to clipboard

[Bug]: JS code with additional text does not evaluate

Open Vidushi-Gupta opened this issue 3 years ago • 0 comments

Is there an existing issue for this?

  • [X] I have searched the existing issues

Description

When I write Returned: {{currentItem.date_returned === "" ? "No" : currentItem.date_returned}} I expect the output to be Returned: No

But instead I get the output to be

image image image

Steps To Reproduce

  1. Create an appsmith app
  2. In a text widget, in the text property mention {{currentItem.date_returned === "" ? "No" : currentItem.date_returned}} which checks if the there is no return date, it outputs No or if there is a return date, it outputs the date.
  3. Now, in another text widget mention Returned: {{currentItem.date_returned === "" ? "No" : currentItem.date_returned}} which should work the same way as in step 2 with a Returned: appended at the start. But, it does not evaluate the query correctly and just outputs when there is no return date.

Public Sample App

No response

Version

Cloud 1.7.7

Vidushi-Gupta avatar Jul 13 '22 07:07 Vidushi-Gupta