You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
31 lines
1.0 KiB
31 lines
1.0 KiB
function IoTCenter_home() {
|
|
return Vue.component('IoTCenter_home', function (resolve, reject) {
|
|
axios.get("/IoTCenter/home.html").then(function (response) {
|
|
resolve({
|
|
template: response.data,
|
|
data() {
|
|
return {
|
|
name: 'home'
|
|
};
|
|
},
|
|
mounted: function () {
|
|
console.log('mounted');
|
|
weui.tab('#tab', { defaultIndex: 1 });
|
|
var url = '/IoTCenter/api/v1/node/getNodes';
|
|
var component = this;
|
|
axios.post(url)
|
|
.then(function (response) {
|
|
component.model = response.data;
|
|
})
|
|
.catch(function (error) {
|
|
})
|
|
.finally(function () {
|
|
|
|
});
|
|
},
|
|
methods: {
|
|
}
|
|
})
|
|
});
|
|
});
|
|
} |