Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cell Color On The Basis Of Retest Status #501

Open
UbaidAhmed2803 opened this issue Oct 19, 2023 · 2 comments
Open

Cell Color On The Basis Of Retest Status #501

UbaidAhmed2803 opened this issue Oct 19, 2023 · 2 comments
Labels
enhancement New feature or request

Comments

@UbaidAhmed2803
Copy link

UbaidAhmed2803 commented Oct 19, 2023

Is your feature request related to a problem? Please describe.
I am looking for a way to color-code the cell in my report for reassessment or retest. I am able to write the retest status using the following:
{#retestStatus==’ko’}Open{/retestStatus==’ko’}{#retestStatus==’ok’}Fixed{/retestStatus==’ok’}{#retestStatus==’unknown’}Not Verified{/retestStatus==’unknown’}{#retestStatus==’partial’}Partially Fixed{/retestStatus==’partial’}

Next what I want to do is change the background of this particular cell in the table to Red, Orange or Green in case the status is Open, Partially Fixed, and Fixed respectively.

--

Describe the solution you'd like
Just like we have {@cvss.cellColor}, can't we have something similar for these statuses as well?

@UbaidAhmed2803 UbaidAhmed2803 added the enhancement New feature or request label Oct 19, 2023
@brunomcuesta
Copy link

Hello!
I answered in the other post. Did you see?

#238 (comment)

You put retestStatus, but it is retestColor.

expressions.filters.retestStatus <--- Must be retestColor

And then you can use:

{@retestStatus | retestColor}

Best regards!

@UbaidAhmed2803
Copy link
Author

Yes tried that as well but report generation fails and I get to see the below line in logs:

"rootError": { pwndoc-backend | "stack": "Error: Filter 'retestColor' is not defined\n at isStateless (/app/node_modules/angular-expressions/lib/parse.js:2905:9)\n at findConstantAndWatchExpressions (/app/node_modules/angular-expressions/lib/parse.js:2967:7)\n at /app/node_modules/angular-expressions/lib/parse.js:2918:5\n at forEach (/app/node_modules/angular-expressions/lib/parse.js:324:15)\n at findConstantAndWatchExpressions (/app/node_modules/angular-expressions/lib/parse.js:2917:4)\n at ASTCompiler.compile (/app/node_modules/angular-expressions/lib/parse.js:3078:3)\n at Parser.parse (/app/node_modules/angular-expressions/lib/parse.js:4205:27)\n at Object.compile (/app/node_modules/angular-expressions/lib/main.js:54:40)\n at angularParser (/app/src/lib/report-generator.js:126:30)\n at Render.parser (/app/src/lib/report-generator.js:163:12)",

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants