Allow a jobset to be created from an evaluation

[?]
Jul 6, 2015, 1:17 PM
UQA4FMUAWSGCX33ZN5R5UC25QZTJ2X6DMP4L7XDFNMHC5QYHR2CQC

Dependencies

  • [2] UOINKJ2J Add an action to cancel all builds in a jobset eval
  • [3] LUYDIGYM Make input value wider
  • [4] VJFLX7B6 Fix rendering of jobset inputs
  • [5] NIX2TKYV Use redirectJSON
  • [6] RQI3GRC6 Enable setting checkresponsible in the edit jobset form
  • [7] OK4P3AMK Remove the ability to add multiple jobset input alternatives
  • [8] PVIRRARJ Turn hiding/unhiding a jobset into a checkbox
  • [9] ZFEN2MAO Simplify jobset cloning
  • [10] VZX6HJ3I Fix jobset input handling in the API
  • [11] ODNCGFQ5 * Improved the navigation bar: don't include all projects (since that
  • [12] 6LTPI6B2
  • [13] GEADFVZ5 hydra-queue-runner: Improved scheduling
  • [14] LHBSOI2D Fix adding jobset inputs
  • [15] TQVKZQUG Use the REST API in the web interface for editing jobsets
  • [16] OX6NYJDV Split viewing and editing a jobset
  • [17] LZVO64YG Merge in the first bits of the API work
  • [18] 2G63HKCH Fix some wellformedness issues
  • [19] DAPOSS44 Use the REST API in the web interface for editing projects
  • [20] K3HODXGH Check all inputs for blame but only email selected inputs
  • [21] RSEGBU6C Hydra/20: Jobset clone feature
  • [22] JY7BXXOP Split viewing and editing a project
  • [23] 3HZY24CX * Make jobsets viewable under
  • [24] FPK5LF53 * Put the project-related actions in a separate controller. Put the
  • [*] U4TD3AIQ Add support for viewing jobset evaluations
  • [*] T273UOB7 Support obtaining the contents of an evaluation as a channel
  • [*] 6HWHYPSW Add an action menu to evaluations

Change contents

  • replacement in src/lib/Hydra/Controller/Jobset.pm at line 166
    [4.705][4.0:63]()
    $c->stash->{clone} = defined $c->stash->{params}->{clone};
    [4.705]
    [4.795]
    $c->stash->{cloneJobset} = defined $c->stash->{params}->{cloneJobset};
  • replacement in src/lib/Hydra/Controller/Jobset.pm at line 272
    [4.1086][4.1086:1114]()
    $c->stash->{clone} = 1;
    [4.1086]
    [4.1114]
    $c->stash->{cloneJobset} = 1;
  • edit in src/lib/Hydra/Controller/JobsetEval.pm at line 158
    [27.51]
    [27.51]
    sub create_jobset : Chained('eval') PathPart('create-jobset') Args(0) {
    my ($self, $c) = @_;
    my $eval = $c->stash->{eval};
  • edit in src/lib/Hydra/Controller/JobsetEval.pm at line 164
    [27.52]
    [27.52]
    requireProjectOwner($c, $c->stash->{project});
  • edit in src/lib/Hydra/Controller/JobsetEval.pm at line 166
    [27.53]
    [2.668]
    $c->stash->{template} = 'edit-jobset.tt';
    $c->stash->{createFromEval} = 1;
    }
  • edit in src/lib/Hydra/Controller/Project.pm at line 116
    [4.3065][4.3065:3092]()
    $c->stash->{edit} = 1;
  • edit in src/lib/Hydra/Controller/Project.pm at line 126
    [4.5000][4.5000:5027]()
    $c->stash->{edit} = 1;
  • replacement in src/root/edit-jobset.tt at line 1
    [4.367][4.1187:1369]()
    [% WRAPPER layout.tt title=(create ? "Create jobset in project $project.name" : clone ? "Cloning jobset $project.name:$jobset.name" : "Editing jobset $project.name:$jobset.name") %]
    [4.367]
    [4.496]
    [% WRAPPER layout.tt title=
    (create ? "Creating jobset in project $project.name" :
    createFromEval ? "Creating jobset from evaluation $eval.id of $project.name:$jobset.name" :
    cloneJobset ? "Cloning jobset $project.name:$jobset.name" :
    "Editing jobset $project.name:$jobset.name") %]
  • replacement in src/root/edit-jobset.tt at line 18
    [4.1173][4.1173:1271]()
    [% INCLUDE renderSelection curValue=input.type param="$baseName-type" options=inputTypes %]
    [4.1173]
    [4.1271]
    [% INCLUDE renderSelection curValue=input.type param="$baseName-type" options=inputTypes edit=1 %]
  • replacement in src/root/edit-jobset.tt at line 21
    [4.563][4.563:635](),[4.635][3.87:227](),[3.227][4.756:806](),[4.756][4.756:806]()
    [% alt = input.search_related('jobsetinputalts', {altnr => 0}) %]
    <input style="width: 95%" type="text" [% HTML.attributes(value => alt.value, id => "$baseName-value", name => "$baseName-value") %]/>
    [% IF input.jobsetinputalts_rs.count > 1 %]
    [4.563]
    [4.806]
    [% IF createFromEval %]
    [% value = (input.uri or input.value); IF input.revision; value = value _ " " _ input.revision; END;
    warn = input.altnr != 0;
    %]
    [% ELSE %]
    [% alt = input.search_related('jobsetinputalts', {altnr => 0});
    value = alt.value
    warn = input.jobsetinputalts_rs.count > 1;
    %]
    [% END %]
    [% IF warn %]
  • edit in src/root/edit-jobset.tt at line 36
    [4.1512]
    [4.225]
    <input style="width: 95%" type="text" [% HTML.attributes(value => value, id => "$baseName-value", name => "$baseName-value") %]/>
  • replacement in src/root/edit-jobset.tt at line 50
    [4.1891][4.1891:1940]()
    [% FOREACH input IN jobset.jobsetinputs %]
    [4.1891]
    [4.175]
    [% inputs = createFromEval ? eval.jobsetevalinputs : jobset.jobsetinputs; FOREACH input IN inputs %]
  • replacement in src/root/edit-jobset.tt at line 87
    [4.2855][4.1370:1482]()
    <input type="text" class="span3" name="name" [% HTML.attributes(value => clone ? "" : jobset.name) %]/>
    [4.2855]
    [4.2961]
    <input type="text" class="span3" name="name" [% HTML.attributes(value => edit ? jobset.name : "") %]/>
  • replacement in src/root/edit-jobset.tt at line 155
    [4.4510][4.1483:1667]()
    <button id="submit-jobset" type="submit" class="btn btn-primary"><i class="icon-ok icon-white"></i> [%IF create || clone %]Create jobset[% ELSE %]Apply changes[% END %]</button>
    [4.4510]
    [4.4659]
    <button id="submit-jobset" type="submit" class="btn btn-primary"><i class="icon-ok icon-white"></i> [%IF !edit %]Create jobset[% ELSE %]Apply changes[% END %]</button>
  • replacement in src/root/edit-jobset.tt at line 207
    [4.19][4.1668:1699](),[4.2763][4.1668:1699]()
    [% IF create || clone %]
    [4.19]
    [4.2785]
    [% IF !edit %]
  • edit in src/root/jobset-eval.tt at line 49
    [28.353]
    [2.1621]
    <li><a href="[% c.uri_for(c.controller('JobsetEval').action_for('create_jobset'), [eval.id]) %]">Create a jobset from this evaluation</a></li>