aboutsummaryrefslogtreecommitdiffstats
path: root/server/sonar-web/src/main/hbs/workspace/workspace-rule.hbs
blob: 3f55d9e8d38f516625d667446d2969ab69b6347b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
<div class="workspace-viewer-header"></div>

<div class="workspace-viewer-container">

  {{#if severity}}
    <ul class="coding-rules-detail-properties">
      {{#unless isManual}}
        <li class="coding-rules-detail-property"
            data-toggle="tooltip" data-placement="bottom" title="Default rule severity">
          {{severityIcon severity}}&nbsp;{{t "severity" severity}}
        </li>
      {{/unless}}

      {{#notEq status 'READY'}}
        <li class="coding-rules-detail-property"
            data-toggle="tooltip" data-placement="bottom" title="Rule status">{{status}}</li>
      {{/notEq}}

      <li class="coding-rules-detail-property coding-rules-detail-tag-list {{#if canWrite}}coding-rules-detail-tags-change{{/if}}"
          data-toggle="tooltip" data-placement="bottom" title="Rule tags">
        <i class="icon-tags"></i>
        <span>{{#if allTags}}{{join allTags ', '}}{{else}}{{t 'coding_rules.no_tags'}}{{/if}}</span>
      </li>

      <li class="coding-rules-detail-property">{{t 'coding_rules.available_since'}} {{d createdAt}}</li>

      <li class="pull-right spacer-left">
        <a class="icon-link" target="_blank" href="{{rulePermalink key}}"></a>
      </li>

      <li class="pull-right">
        <span class="note">{{key}}</span>
      </li>
    </ul>

    {{#if debtCharName}}
      <ul class="coding-rules-detail-properties">
        <li class="coding-rules-detail-property"
            data-toggle="tooltip" data-placement="bottom" title="Rule characteristic">
          {{debtCharName}}{{#if debtSubCharName}} > {{debtSubCharName}}{{/if}}
        </li>

        {{#if debtRemFnType}}
          <li class="coding-rules-detail-property"
              data-toggle="tooltip" data-placement="bottom" title="{{t 'coding_rules.remediation_function'}}">
            {{t 'coding_rules.remediation_function' debtRemFnType}}:

            {{#if debtRemFnOffset}}{{debtRemFnOffset}}{{/if}}
            {{#if debtRemFnCoeff}}{{#if debtRemFnOffset}}+{{/if}}{{debtRemFnCoeff}}{{/if}}
            {{#if effortToFixDescription}}{{effortToFixDescription}}{{/if}}
          </li>
        {{/if}}
      </ul>
    {{/if}}
  {{/if}}

  <div class="coding-rules-detail-description rule-desc markdown">{{{htmlDesc}}}</div>

  {{#if htmlNote}}
    <div id="coding-rules-detail-description-extra">
      <div class="rule-desc markdown">{{{htmlNote}}}</div>
    </div>
  {{/if}}

</div>