• Resolved qmguru

    (@qmguru)


    if Return = Sie sind Antragsberechtigt. Bitte machen sie nun Check Teil 2″ the text should be red

    if(fieldname5 > 0) return “Sie sind nicht antragsberechtigt”;
    the Text shoud be green

    can you help me

    (function(){

    if(fieldname5 <= 0) return “Sie sind Antragsberechtigt. Bitte machen sie nun Check Teil 2”;
    if(fieldname5 > 0) return “Sie sind nicht antragsberechtigt”;

    })();

    The page I need help with: [log in to see the link]

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author codepeople

    (@codepeople)

    Hello @qmguru

    A possible solution would be the following one:

    1. Assign a custom class name to the calculated field, for example: my-field

    Note: the class names are assigned to the fields through their attributes: “Add CSS Layout Keywords”

    2. And then, edit the equation as follows:

    
    (function(){
        var result, color;
        if(fieldname5 <= 0)
        {
            result = 'Sie sind Antragsberechtigt. Bitte machen sie nun Check Teil 2';
            color = 'red';
        }
        else
        {
            result = 'Sie sind nicht antragsberechtigt';
            color = 'green';
        }
        jQuery('.my-field input').css('color', color);
        return result;
    })()
    

    and that’s all.
    Best regards.

    Thread Starter qmguru

    (@qmguru)

    Thank you.

    it is working

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Color on unciot’ is closed to new replies.