|
|
@@ -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}} |
|
|
|
|
|
|
|