serializeData () {
const key = this.model.get('key');
const rulesSearchUrl = `/coding_rules#qprofile=${encodeURIComponent(key)}|activation=true`;
+ const activateRulesUrl = `/coding_rules#qprofile=${encodeURIComponent(key)}|activation=false`;
return _.extend(Marionette.ItemView.prototype.serializeData.apply(this, arguments), {
rulesSearchUrl,
+ activateRulesUrl,
canWrite: this.options.canWrite,
exporters: this.getExporters()
});
<div class="column-two-thirds" id="quality-profile-rules">
<header class="page-header">
<h3 class="page-title">{{t 'coding_rules'}}</h3>
+ <div class="button-group big-spacer-left">
+ <a class="button" href="{{link activateRulesUrl}}">{{t 'coding_rules.activate'}}</a>
+ </div>
</header>
<div>