Vue.component("ns-cluster-selector", { props: ["v-cluster-id"], mounted: function () { let that = this Tea.action("/ns/clusters/options") .post() .success(function (resp) { that.clusters = resp.data.clusters }) }, data: function () { let clusterId = this.vClusterId if (clusterId == null) { clusterId = 0 } return { clusters: [], clusterId: clusterId } }, template: `
` })