diff options
author | Michael Wood <michael.g.wood@intel.com> | 2015-12-07 18:42:16 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-02-10 13:29:19 +0000 |
commit | 4b3c9d61dc0c416d4d277de680604e2f6697e288 (patch) | |
tree | 6e36faa75bfbf317f1083c595b2eb89a1bdad2a9 /bitbake/lib/toaster/toastergui/templates/customrecipe.html | |
parent | b213907afe2b37f66d8fae88af8e5edf50464f04 (diff) | |
download | poky-4b3c9d61dc0c416d4d277de680604e2f6697e288.tar.gz |
bitbake: toaster: customrecipe Add further front end features using new API
This adds some basic package dependency hint modals when you add and
remove a package. It also makes sure that if the CustomImageRecipe has
no current included packages that we go and check this with the server
to see if a relevant build has taken place which will provide this
information.
[YOCTO #8082]
(Bitbake rev: 418f5509e74d46d36a8eb966a245083006e5f4ba)
Signed-off-by: Michael Wood <michael.g.wood@intel.com>
Signed-off-by: brian avery <avery.brian@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/toaster/toastergui/templates/customrecipe.html')
-rw-r--r-- | bitbake/lib/toaster/toastergui/templates/customrecipe.html | 46 |
1 files changed, 43 insertions, 3 deletions
diff --git a/bitbake/lib/toaster/toastergui/templates/customrecipe.html b/bitbake/lib/toaster/toastergui/templates/customrecipe.html index 2f3aee3686..4d88be054d 100644 --- a/bitbake/lib/toaster/toastergui/templates/customrecipe.html +++ b/bitbake/lib/toaster/toastergui/templates/customrecipe.html | |||
@@ -26,6 +26,8 @@ | |||
26 | recipe : { | 26 | recipe : { |
27 | id: {{recipe.pk}}, | 27 | id: {{recipe.pk}}, |
28 | name: "{{recipe.name}}", | 28 | name: "{{recipe.name}}", |
29 | includedPackagesCount: {{recipe.includes_set.count}}, | ||
30 | baseRecipeId: {{recipe.base_recipe.pk}}, | ||
29 | } | 31 | } |
30 | }; | 32 | }; |
31 | 33 | ||
@@ -37,6 +39,44 @@ | |||
37 | } | 39 | } |
38 | }); | 40 | }); |
39 | </script> | 41 | </script> |
42 | <!-- package dependencies modal --> | ||
43 | <div style="display:none" id="package-deps-modal" class="modal hide fade in" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="false"> | ||
44 | <div class="modal-header"> | ||
45 | <button type="button" class="close" data-dismiss="modal" aria-hidden="true">x</button> | ||
46 | <h3><span class="package-to-add-name"></span> dependencies</h3> | ||
47 | </div> | ||
48 | <div class="modal-body"> | ||
49 | <p>Based on information from a previous build it is likely that adding <strong class="package-to-add-name"></strong> will also add the following packages to your custom image:</p> | ||
50 | <ul id="package-add-dep-list"> | ||
51 | </ul> | ||
52 | </div> | ||
53 | <div class="modal-footer"> | ||
54 | <p class="help-block text-left">Total package size: <strong id="package-deps-total-size"></strong></p> | ||
55 | <button id="add-package-deps-modal-btn" type="submit" class="btn btn-primary" data-dismiss="modal">Add package</button> | ||
56 | <button class="btn" data-dismiss="modal">Cancel</button> | ||
57 | </div> | ||
58 | </div> | ||
59 | <!-- end package dependencies modal --> | ||
60 | |||
61 | <!-- package reverse dependencies modal --> | ||
62 | <div style="display:none" id="package-reverse-deps-modal" class="modal hide fade in" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="false"> | ||
63 | <div class="modal-header"> | ||
64 | <button type="button" class="close" data-dismiss="modal" aria-hidden="true">x</button> | ||
65 | <h3><span class="package-to-rm-name"></span> reverse dependencies</h3> | ||
66 | </div> | ||
67 | <div class="modal-body"> | ||
68 | <p>Based on information from a previous build it is likely that <strong class="package-to-rm-name"></strong> may be added again as the following packages directly depend on it for your custom image:</p> | ||
69 | <ul id="package-reverse-dep-list"> | ||
70 | </ul> | ||
71 | </div> | ||
72 | <div class="modal-footer"> | ||
73 | <p class="help-block text-left">Total package size: <strong id="package-reverse-deps-total-size"></strong></p> | ||
74 | <button id="rm-package-reverse-deps-modal-btn" type="submit" class="btn btn-primary" data-dismiss="modal">Remove package</button> | ||
75 | <button class="btn" data-dismiss="modal">Cancel</button> | ||
76 | </div> | ||
77 | </div> | ||
78 | <!-- end package dependencies modal --> | ||
79 | |||
40 | 80 | ||
41 | <div class="row-fluid span11"> | 81 | <div class="row-fluid span11"> |
42 | <div class="alert alert-success lead" id="image-created-notification" style="margin-top: 15px; display: none"> | 82 | <div class="alert alert-success lead" id="image-created-notification" style="margin-top: 15px; display: none"> |
@@ -81,11 +121,11 @@ | |||
81 | </div> | 121 | </div> |
82 | </div> | 122 | </div> |
83 | <div id="packages-table"> | 123 | <div id="packages-table"> |
84 | {% if recipe.package_set.count == 0 and last_build == None %} | 124 | {% if recipe.get_all_packages.count == 0 and last_build == None %} |
85 | <h2> Add | Remove packages </h2> | 125 | <h2> Add | Remove packages </h2> |
86 | <div class="alert alert-info air"> | 126 | <div class="alert alert-info air"> |
87 | <p class="lead">Toaster has no package information for {{recipe.name}}. To generate package information, build {{recipe.name}}</p> | 127 | <p class="lead">Toaster has no package information for {{recipe.name}}. To generate package information, build {{recipe.name}}</p> |
88 | <button class="btn btn-info btn-large build-custom-recipe" style="margin:20px 0 10px 0;">Build {{recipe.name}}</button> | 128 | <button class="btn btn-info btn-large build-custom-image" style="margin:20px 0 10px 0;">Build {{recipe.name}}</button> |
89 | </div> | 129 | </div> |
90 | {% else %} | 130 | {% else %} |
91 | {# ToasterTable for Adding remove packages #} | 131 | {# ToasterTable for Adding remove packages #} |
@@ -103,7 +143,7 @@ | |||
103 | Approx. packages included | 143 | Approx. packages included |
104 | <i class="icon-question-sign get-help" title="" data-original-title="The number of packages included is based on information from previous builds and from parsing layers, so we can never be sure it is 100% accurate"></i> | 144 | <i class="icon-question-sign get-help" title="" data-original-title="The number of packages included is based on information from previous builds and from parsing layers, so we can never be sure it is 100% accurate"></i> |
105 | </dt> | 145 | </dt> |
106 | <dd class="no-packages">{{recipe.package_set.all.count}}</dd> | 146 | <dd class="no-packages">{{recipe.get_all_packages.count}}</dd> |
107 | <dt> | 147 | <dt> |
108 | Approx. package size | 148 | Approx. package size |
109 | <i class="icon-question-sign get-help" title="" data-original-title="Package size is based on information from previous builds, so we can never be sure it is 100% accurate"></i> | 149 | <i class="icon-question-sign get-help" title="" data-original-title="Package size is based on information from previous builds, so we can never be sure it is 100% accurate"></i> |