Skip to content

Instantly share code, notes, and snippets.

@vikingmute
Created January 14, 2016 07:30
Show Gist options
  • Save vikingmute/d9b11c94af703670d6c4 to your computer and use it in GitHub Desktop.
Save vikingmute/d9b11c94af703670d6c4 to your computer and use it in GitHub Desktop.
<div class="agent-status status-light status-{{status}}"></div>
{{#if navToIndex}}
{{#link-to 'agents' class="agent-item-link"}}
<aid class="agent-item-header">{{agent.id}}</aid>
<component class={{if component.name 'agent-tag'}}>{{component.name}}</component>
<project class={{if project.name 'agent-tag'}}>{{project.name}}</project>
<address class={{if agent.addr 'agent-tag'}}>{{agent.addr}}</address>
<kind class={{if agent.kind 'agent-tag'}}>{{agent.kind}}</kind>
<model class={{if agent.model 'agent-tag'}}>{{agent.model}}</model>
<version class={{if agent.firmware 'agent-tag'}}>{{agent.firmware}}</version>
{{/link-to}}
{{else}}
{{#link-to 'agents.detail' agent class="agent-item-link"}}
<aid class="agent-item-header">{{agent.id}}</aid>
<component class={{if component.name 'agent-tag'}}>{{component.name}}</component>
<project class={{if project.name 'agent-tag'}}>{{project.name}}</project>
<address class={{if agent.addr 'agent-tag'}}>{{agent.addr}}</address>
<kind class={{if agent.kind 'agent-tag'}}>{{agent.kind}}</kind>
<model class={{if agent.model 'agent-tag'}}>{{agent.model}}</model>
<version class={{if agent.firmware 'agent-tag'}}>{{agent.firmware}}</version>
{{/link-to}}
{{/if}}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment