You're on your way to the next level! Join the Kudos program to earn points and save your progress.
Level 1: Seed
25 / 150 points
Next: Root
1 badge earned
Challenges come and go, but your rewards stay with you. Do more to earn more!
What goes around comes around! Share the love by gifting kudos to your peers.
Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!
Join now to unlock these features and more
The Atlassian Community can help you and your team get more value out of Atlassian products and practices.
I want to keep the user from changing values in certain ConfiForm fields within a TableView macro after a certain date. Basically, I want to make all the previous weeks' fields readonly. I have JavaScript that figures out what "today" is and what week of the year it is. I have my fields named for those weeks. I have the code, what I'm trying to get are the HTML id's that will allow me to access those fields and make them ready only. Alternatively, I need a way tick the "Disable Inline Edit" box in the Form Field macro in JavaScript in the AJS.toInit function. Any ideas?
Ok. My collague fiugred it out. In my for loop in my AJS.toInit function, I needed:
let fieldname = "td.cfgrid.cf_week"+i.toString()+"hours";
document.querySelectorAll(fieldname)[0].style.pointerEvents = "none";
The above basically has the effect of checking the "Disable Inline Edit" box, but in JavaScript.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.