On Wednesday, October 2, 2013 8:14:21 PM UTC-7, Lukasz Szybalski wrote:
>
>
>
> On Wednesday, October 2, 2013 12:49:23 PM UTC-5, RjOllos wrote:
>>
>> On Tuesday, October 1, 2013 12:24:00 PM UTC-7, Lukasz Szybalski wrote:
>>
>>> Hello,
>>> Is there a way to enforce a non empty value for a custom field.
>>>
>>> We have added a field called "contract_number". When people close the 
>>> ticket we want to make sure they do are NOT able to close the ticket 
>>> without entering a "contract_number".
>>>
>>> How can that be achieved?
>>>
>>> Thanks
>>> Lucas
>>>
>>
>> DynamicFieldsPlugin should help you accomplish that: 
>> http://trac-hacks.org/wiki/DynamicFieldsPlugin#Validaterule
>>
>
> Hello,
> Would you know how the code would look if I wanted to make sure its not 
> empty when sombody selects "Resolution:Fixed"; Status:Closed?
>
>
> aka,
> When somebody tries to close the ticket only then enforce the none empty 
> field.
> Thanks
> Lucas 
>

I haven't used the plugin, but from reading the docs, the following might 
work:

contract_number.invalid_if = 
contract_number.invalid_when_status = closed 

-- 
You received this message because you are subscribed to the Google Groups "Trac 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/trac-users.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to