def _create_dashboard(self, ip):
url = 'http://admin:admin@{}:{}/api/dashboards/db'.format(ip, 3000)
- path = os.path.join(consts.REPOS_DIR, 'dashboard', '*dashboard.json')
+ path = os.path.join(consts.REPOS_DIR, 'dashboard', 'opnfv_yardstick_tc*.json')
for i in sorted(glob.iglob(path)):
with open(i) as f:
data = jsonutils.load(f)
try:
- HttpClient().post(url, data)
+ HttpClient().post(url, {'dashboard': data})
except Exception:
LOG.exception('Create dashboard %s failed', i)
raise
<th>status</th>
</tr>
<tr ng-repeat="(name, value) in yardstickImage">
- <td ng-if="selectImageList.indexOf(name) > -1"><img src="images/checkyes.png" style="height:12px;cursor:pointer" ng-click="unselectImage(name)" /></td>
- <td ng-if="selectImageList.indexOf(name) == -1"><img src="images/checkno.png" style="height:12px;cursor:pointer" ng-click="selectImage(name)" /></td>
+ <td ng-if="selectImageList.indexOf(name) > -1"><span class="glyphicon glyphicon-check" aria-hidden="true" ng-click="unselectImage(name)"></span></td>
+ <td ng-if="selectImageList.indexOf(name) == -1"><span class="glyphicon glyphicon-unchecked" aria-hidden="true" ng-click="selectImage(name)"></span></td>
<td>{{name}}</td>
<td>{{value.description}}</td>
<td>{{value.status}}</td>
<div style="display:flex;flex-direction:row;justify-content:space-between;padding:8px;border-top: 1px solid #e9ecec;" ng-class="{deepColor: $index%2==0}">
<div> {{env.name}}</div>
<!--<button class="btn btn-default btn-sm" ng-click="gotoDetail('false',env.uuid)">detail</button>-->
- <img src="images/checkyes.png" style="height:18px;cursor:pointer" ng-click="constructTestSuit(env.uuid,env.name)" ng-show="selectEnv==env.uuid" />
- <img src="images/checkno.png" style="height:18px;cursor:pointer" ng-click="constructTestSuit(env.uuid,env.name)" ng-show="selectEnv!=env.uuid" />
+ <span class="glyphicon glyphicon-check" aria-hidden="true" ng-click="constructTestSuit(env.uuid,env.name)" ng-show="selectEnv==env.uuid"></span>
+ <span class="glyphicon glyphicon-unchecked" aria-hidden="true" ng-click="constructTestSuit(env.uuid,env.name)" ng-show="selectEnv!=env.uuid"></span>
</div>
<!--<hr style="margin-top:5px;margin-bottom:5px;" />-->
<div style="display:flex;flex-direction:row;justify-content:space-between;padding:8px;border-top: 1px solid #e9ecec;" ng-class="{deepColor: $index%2==0}">
<div> {{test.Name}}</div>
<div style="font-size:10px;">{{test.Description}}</div>
- <img src="images/checkyes.png" style="height:18px;cursor:pointer" ng-click="constructTestCase(test.Name)" ng-show="selectCase==test.Name" />
- <img src="images/checkno.png" style="height:18px;cursor:pointer" ng-click="constructTestCase(test.Name)" ng-show="selectCase!=test.Name" />
+ <span class="glyphicon glyphicon-check" aria-hidden="true" ng-click="constructTestCase(test.Name)" ng-show="selectCase==test.Name"></span>
+ <span class="glyphicon glyphicon-unchecked" aria-hidden="true" ng-click="constructTestCase(test.Name)" ng-show="selectCase!=test.Name"></span>
</div>
<!--<hr style="margin-top:5px;margin-bottom:5px;" />-->
<div style="display:flex;flex-direction:row;justify-content:space-between;padding:8px;border-top: 1px solid #e9ecec;" ng-class="{deepColor: $index%2==0}">
<div> {{suite}}</div>
- <img src="images/checkyes.png" style="height:18px;cursor:pointer" ng-click="constructTestCase(suite)" ng-show="selectCase==suite" />
- <img src="images/checkno.png" style="height:18px;cursor:pointer" ng-click="constructTestCase(suite)" ng-show="selectCase!=suite" />
+ <span class="glyphicon glyphicon-check" aria-hidden="true" ng-click="constructTestCase(suite)" ng-show="selectCase==suite"></span>
+ <span class="glyphicon glyphicon-unchecked" aria-hidden="true" ng-click="constructTestCase(suite)" ng-show="selectCase!=suite"></span>
</div>
<!--<hr style="margin-top:5px;margin-bottom:5px;" />-->
<div style="display:flex;flex-direction:row;justify-content:space-between;padding:8px;border-top: 1px solid #e9ecec;" ng-class="{deepColor: $index%2==0}">
<div> {{env.name}}</div>
<!--<button class="btn btn-default btn-sm" ng-click="gotoDetail('false',env.uuid)">detail</button>-->
- <img src="images/checkyes.png" style="height:18px;cursor:pointer" ng-click="constructTestSuit(env.uuid,env.name)" ng-show="selectEnv==env.uuid" />
- <img src="images/checkno.png" style="height:18px;cursor:pointer" ng-click="constructTestSuit(env.uuid,env.name)" ng-show="selectEnv!=env.uuid" />
+ <span class="glyphicon glyphicon-check" aria-hidden="true" ng-click="constructTestSuit(env.uuid,env.name)" ng-show="selectEnv==env.uuid"></span>
+ <span class="glyphicon glyphicon-unchecked" aria-hidden="true" ng-click="constructTestSuit(env.uuid,env.name)" ng-show="selectEnv!=env.uuid"></span>
</div>
<!--<hr style="margin-top:5px;margin-bottom:5px;" />-->
<div style="display:flex;flex-direction:row;justify-content:space-between;padding:8px;border-top: 1px solid #e9ecec;" ng-class="{deepColor: $index%2==0}">
<div> {{test.Name}}</div>
<div style="font-size:10px;">{{test.Description}}</div>
- <img src="images/checkyes.png" style="height:18px;cursor:pointer" ng-click="constructTestCase(test.Name)" ng-show="selectCase==test.Name" />
- <img src="images/checkno.png" style="height:18px;cursor:pointer" ng-click="constructTestCase(test.Name)" ng-show="selectCase!=test.Name" />
+ <span class="glyphicon glyphicon-check" aria-hidden="true" ng-click="constructTestCase(test.Name)" ng-show="selectCase==test.Name"></span>
+ <span class="glyphicon glyphicon-unchecked" aria-hidden="true" ng-click="constructTestCase(test.Name)" ng-show="selectCase!=test.Name"></span>
</div>
<!--<hr style="margin-top:5px;margin-bottom:5px;" />-->
<div style="display:flex;flex-direction:row;justify-content:space-between;padding:8px;border-top: 1px solid #e9ecec;" ng-class="{deepColor: $index%2==0}">
<div> {{suite}}</div>
- <img src="images/checkyes.png" style="height:18px;cursor:pointer" ng-click="constructTestCase(suite)" ng-show="selectCase==suite" />
- <img src="images/checkno.png" style="height:18px;cursor:pointer" ng-click="constructTestCase(suite)" ng-show="selectCase!=suite" />
+ <span class="glyphicon glyphicon-check" aria-hidden="true" ng-click="constructTestCase(suite)" ng-show="selectCase==suite"></span>
+ <span class="glyphicon glyphicon-unchecked" aria-hidden="true" ng-click="constructTestCase(suite)" ng-show="selectCase!=suite"></span>
</div>
<!--<hr style="margin-top:5px;margin-bottom:5px;" />-->
</div>-->
<div dir-paginate="test in testcaselist.testcases | itemsPerPage: 10">
<div style="display:flex;flex-direction:row;">
- <img src="images/checkyes.png" style="height:12px;cursor:pointer" ng-click="constructTestSuit(test.Name)" ng-show="testsuiteList.indexOf(test.Name)>-1" />
- <img src="images/checkno.png" style="height:12px;cursor:pointer" ng-click="constructTestSuit(test.Name)" ng-show="testsuiteList.indexOf(test.Name)==-1" />
+ <span class="glyphicon glyphicon-check" aria-hidden="true" ng-click="constructTestSuit(test.Name)" ng-show="testsuiteList.indexOf(test.Name)>-1"></span>
+ <span class="glyphicon glyphicon-unchecked" aria-hidden="true" ng-click="constructTestSuit(test.Name)" ng-show="testsuiteList.indexOf(test.Name)==-1"></span>
<div style="margin-left:50px;"> {{test.Name}}</div>
<div style="font-size:10px;margin-left:100px">{{test.Description}}</div>