[users at bb.net] template question

Greg MacDonald gmacdonald at trionworlds.com
Thu Jun 16 19:00:42 UTC 2016


I found it, I needed to add the new property to the dict returned from the endpoint with forceScheduler2Data. Thx anyways. :)


From: users [mailto:users-bounces at buildbot.net] On Behalf Of Greg MacDonald
Sent: Wednesday, June 15, 2016 7:18 PM
To: Buildbot
Subject: [users at bb.net] template question

Hi Everyone,

I'm having problems figuring out how to get a value into a jade template. I've extended the data and mq api's to include an enabled field on a scheduler so the user can toggle a scheduler on and off. This is working well, but I would like to have a warning appear if the user tries to start a build on a disabled scheduler. In forcedialog.tpl.jade I've tried to add an alert with ng-show = !sch.enabled, but no luck:

.modal-content
    .modal-header
        h4 {{sch.label}}
    .modal-body
        div.form-horizontal
            .alert.alert-danger(ng-show="error") {{error}}
            .alert.alert-danger(ng-show="!sch.enabled") SCHEDULER DISABLED
            forcefield(field="rootfield" ng-if="rootfield")
    .modal-footer
      button.btn.btn-default(ng-click="cancel()") Cancel
      button.btn.btn-primary(ng-click="ok()") Start Build

I was able to use my new enabled property in schedulers.tpl.jade, so I'm lost on what to do next. Any ideas?

-Greg
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.buildbot.net/pipermail/users/attachments/20160616/0e20ab50/attachment.html>


More information about the users mailing list