Issue using icons on grid with validation.

Hi, I want to create a tempo Reports for the first time and I want to use an icon to showed on the grid column with validation.
If the result of the validation is yes for Product A, so it will show an Icon A on the grid column, and if the result of the validation is no for product A, it will show an icon B on the grid column.
Here, I attach a file that was my script, may someone could help me to correct my script if I have some wrong script on it, because my script can't work as well.

Thank you very much for helping :)
-----------------------------------------------------------------
load(
local!pagingInfo: a!pagingInfo(
startIndex: 1,
batchSize: 10,
sort: {
field: "dateTimeSubmit",
ascending: false
}
),
with(
local!datasubset: rule!Get_ProjectReport(
local!pagingInfo
),
if(
local!datasubset.totalCount < 1,
rule!APN_uiTextReadOnly(
label: "There are no Project Report"
),
...

OriginalPostID-111898

OriginalPostID-111898

  Discussion posts and replies are publicly visible

Parents
  • ... a!gridField(
    totalCount: local!datasubset.totalCount,
    columns: {
    'type!{www.appian.com/.../2009}GridTextColumn'(
    label: "Employee Name",
    data: local!datasubset.data.nameSubmit,
    field : "nameSubmit"
    ),
                         a!gridImageColumn (
                                  label: "Product",
                                  field: "product",
                                  data: {
                                  if(local!datasubset.data.product="A",
                                            a!webImage(
                                                      source: cons!Icon_A,
                                                      size: "ICON"
                                            ),
                                            a!webImage(
                                                      source:cons!Icon_Approve,
                                                      size: "ICON"
                                            )),
                                  if(local!datasubset.data.product="B",
                                            a!webImage(
                                                      source: cons!Icon_B,
                                                      size: "ICON"
                                            ),
                                            a!webImage(
                                                      source:cons!Icon_Approve,
                                                      size: "ICON"
                                            )),
                                  
                                  }
                         ),
    /*'type!{www.appian.com/.../2009}GridTextColumn'(
    label: "Product",
    data: local!datasubset.data.product
    ),*/
    'type!{www.appian.com/.../2009}GridTextColumn'(...
Reply
  • ... a!gridField(
    totalCount: local!datasubset.totalCount,
    columns: {
    'type!{www.appian.com/.../2009}GridTextColumn'(
    label: "Employee Name",
    data: local!datasubset.data.nameSubmit,
    field : "nameSubmit"
    ),
                         a!gridImageColumn (
                                  label: "Product",
                                  field: "product",
                                  data: {
                                  if(local!datasubset.data.product="A",
                                            a!webImage(
                                                      source: cons!Icon_A,
                                                      size: "ICON"
                                            ),
                                            a!webImage(
                                                      source:cons!Icon_Approve,
                                                      size: "ICON"
                                            )),
                                  if(local!datasubset.data.product="B",
                                            a!webImage(
                                                      source: cons!Icon_B,
                                                      size: "ICON"
                                            ),
                                            a!webImage(
                                                      source:cons!Icon_Approve,
                                                      size: "ICON"
                                            )),
                                  
                                  }
                         ),
    /*'type!{www.appian.com/.../2009}GridTextColumn'(
    label: "Product",
    data: local!datasubset.data.product
    ),*/
    'type!{www.appian.com/.../2009}GridTextColumn'(...
Children
No Data