The following code is working on Parent DocType records:
However, it is not working on the Child records. Is there any change in syntax for Child DocType records?
Here is the code :
f1 = document.querySelector('[data-doctype="Parent Document"][data-fieldname="my-field"]');
f1.style.border="solid 1px green";
This is working fine on the table view. But, I need it on the Child Form after pressing the “Edit” button at the end. Hope I communicate correctly.
@NCP , Thank you very much… It is working. But my situation is color should be based on condition where the selling price is less than the cost price…which is not available in the grid. I am working on it… Thanks a lot
@NCP , Really sorry… Since morning trying to sort it… but couldn’t. can you please help… I want to change the style if the rate is less than incoming_rate…
items child doctype is having 84 items. but
var rows = document.getElementsByClassName(“grid-row”);
showing only 63… I am having very less knowledge in js…