Browse Source

尝试增加打印。

Signed-off-by: zouap <zouap@pcl.ac.cn>
pull/2469/head
zouap 2 years ago
parent
commit
707ea6f3ba
2 changed files with 34 additions and 6 deletions
  1. +34
    -0
      templates/base/footer.tmpl
  2. +0
    -6
      templates/home.tmpl

+ 34
- 0
templates/base/footer.tmpl View File

@@ -51,10 +51,40 @@
<script src="/rotation3D/vue-2.6.10.min.js"></script>
<script src="/rotation3D/rotation3D.js?v={{MD5 AppVer}}"></script>
<script>
function queryAiCenterInfo(){
$.ajax({
type:"GET",
url:"/api/v1/cloudbrain/get_center_info",
headers: {
authorization:token,
},
dataType:"json",
async:false,
success:function(json){
displayAiCenterInfo(json);
},
error:function(response) {
}
});
}
function displayAiCenterInfo(json){
for(var i=0;i<json.length;i++){
var tmp ={};
tmp["name"]=json[i].name;
tmp["type"]="green";
tmp["icon"]="";
serverItemList.push(tmp);
}
}

var serverItemList=[];
queryAiCenterInfo();
var app = new Vue({
el: "#app",
//数据 blue, green, yellow
data: {
itemList:serverItemList,
/*
itemList: [
{ name:'鹏城云脑一号', type:'blue', icon:'', },
{ name:'鹏城云脑二号', type:'blue', icon:'', },
@@ -68,6 +98,7 @@
{ name:'横琴先进智能计算中心', type:'green', icon:'', },
{ name:'国家超级计算济南中心', type:'green', icon:'', },
],
*/
},
mounted: function () {
new Rotation3D({
@@ -84,6 +115,9 @@
},
methods: {},
});
var pArrays = $('.itemList').find("p");
console.log(pArrays.length);

</script>
{{end}}



+ 0
- 6
templates/home.tmpl View File

@@ -94,12 +94,6 @@
</div>

<div id="app" v-cloak>
<!--数据
<div class="aiData">
<p>完成AI任务<br><strong id="completed_task">1716</strong></p>
<p>运行AI任务<br><strong id="running_task">120</strong></p>
<p>等待AI任务<br><strong id="wait_task">80</strong></p>
</div>-->
<!--底座-->
<div class="rotation3D-baseMap"></div>
<!--旋转3D-->


Loading…
Cancel
Save