Feat: startup hiper task

This commit is contained in:
unitwk 2022-10-29 15:07:12 +08:00
parent 9774b09820
commit 3b641d6f0d
2 changed files with 24 additions and 3 deletions

View File

@ -87,19 +87,26 @@
<script>
import Dialog from "@/components/Dialog";
import SelectBlock from "@/components/SelectBlock";
import { API_INSTANCE_ASYNC_TASK } from "../../service/common";
import { request } from "../../service/protocol";
export default {
components: { Dialog, SelectBlock },
props: {
visible: {
type: Boolean,
default: false
},
daemonUuid: {
type: String,
default: ""
}
},
data() {
return {
v: false,
viewType: 0,
indexCode: ""
indexCode: "",
hiperTaskInfo: {}
};
},
watch: {
@ -121,7 +128,21 @@ export default {
select(type) {
this.viewType = type;
},
startHiPer() {}
async startHiPer() {
this.hiperTaskInfo = await request({
method: "POST",
url: API_INSTANCE_ASYNC_TASK,
params: {
remote_uuid: this.daemonUuid,
uuid: "-",
task_name: "hiper"
},
data: {
indexCode: this.indexCode
}
});
console.log("this.hiperTaskInfo", this.hiperTaskInfo);
}
}
};
</script>

View File

@ -520,7 +520,7 @@
>
</TermSetting>
<NetworkTip v-model:visible="networkTip"></NetworkTip>
<NetworkTip v-model:visible="networkTip" :daemonUuid="serviceUuid"></NetworkTip>
</div>
</template>