Hi,
I have an urgent business need to prevent estimates from being emailed which have not been approved. I have created the approval process using a combination of client-side and user-event suite scripts. Based on the approval status of the transaction, I can hide any buttons I want to via script in order to make the email, fax and print options unavailable to the user if the estimate has not yet been approved. So far so good.
But, the "Create New" button -the one with the cute green page with a plus symbol - is one I have been unable to completely remove. It appears twice on the page - once at the top and once at the bottom. I got rid of the one on top by using an Inline HTML field with the code:
document.getElementById('spn_CREATENEW_d1').style.visibility = 'hidden';
The problem is the one on the bottom. Even though I got it's ID, hiding it via the Inline HTML method doesn't work because it's not called in the page HTML until after the Inline HTML field. Since it can't hide something that doesn't exist yet, it just doesn't hide it.
I desperately need to remove ALL methods of transmitting the estimate if it is not approved. Maybe I'm approaching this wrong. If anyone out there has any ideas please let me know - I've exhausted all of mine. :h_a_w: