@@ -727,18 +726,6 @@
$('#name').val(modelName)
$('#version').val("0.0.1")
}
- function renderSize(value) {
- if (null == value || value == '') {
- return "0 Bytes";
- }
- var unitArr = new Array("Bytes", "KB", "MB", "GB", "TB", "PB", "EB", "ZB", "YB");
- var index = 0;
- var srcsize = parseFloat(value);
- index = Math.floor(Math.log(srcsize) / Math.log(1024));
- var size = srcsize / Math.pow(1024, index);
- size = size.toFixed(0);//保留的小数位数
- return size + unitArr[index];
- }
function refreshStatus(version_name) {
$.get(`/api/v1/repos/${userName}/${repoPath}/modelarts/train-job/${jobID}?version_name=${version_name}`, (data) => {
// header status and duration
@@ -811,243 +798,5 @@
console.log(err);
});
}
- function loadModelFile(version_name, parents, filename, init) {
- parents = parents || ''
- filename = filename || ''
- init = init || ''
- $.get(`/api/v1/repos/${userName}/${repoPath}/modelarts/train-job/${jobID}/model_list?version_name=${version_name}&parentDir=${parents}`, (data) => {
- $(`#dir_list${version_name}`).empty()
- renderDir(data, version_name)
- if (init === "init") {
- $(`input[name=model${version_name}]`).val("")
- $(`input[name=modelback${version_name}]`).val(version_name)
- $(`#file_breadcrumb${version_name}`).empty()
- let htmlBread = ""
- htmlBread += `
${version_name}
`
- htmlBread += "
/
"
- $(`#file_breadcrumb${version_name}`).append(htmlBread)
- } else {
- renderBrend(version_name, parents, filename, init)
- }
- }).fail(function (err) {
- console.log(err, version_name);
- });
-
- }
- function renderBrend(version_name, parents, filename, init) {
- if (init == "folder") {
- let htmlBrend = ""
- let sectionName = $(`#file_breadcrumb${version_name} .active.section`).text()
- let parents1 = $(`input[name=model${version_name}]`).val()
- let filename1 = $(`input[name=modelback${version_name}]`).val()
- if (parents1 === "") {
- $(`#file_breadcrumb${version_name} .active.section`).replaceWith(`
${sectionName}`)
- } else {
- $(`#file_breadcrumb${version_name} .active.section`).replaceWith(`
${sectionName}`)
- }
-
- htmlBrend += `
${filename}
`
- htmlBrend += "
/
"
- $(`#file_breadcrumb${version_name}`).append(htmlBrend)
- $(`input[name=model${version_name}]`).val(parents)
- $(`input[name=modelback${version_name}]`).val(filename)
- } else {
- $(`input[name=model${version_name}]`).val(parents)
- $(`input[name=modelback${version_name}]`).val(filename)
- $(`#file_breadcrumb${version_name} a.section:contains(${filename})`).nextAll().remove()
- $(`#file_breadcrumb${version_name} a.section:contains(${filename})`).replaceWith(`
${filename}
`)
- $(`#file_breadcrumb${version_name} div.section:contains(${filename})`).append("
/
")
- }
-
- }
- function renderDir(data, version_name) {
- let html = ""
- html += "
"
- html += "
"
- html += "
"
- html += "
"
- html += "
"
- html += "
"
- html += "
"
- html += "
"
- html += "
"
- $(`#dir_list${version_name}`).append(html)
- }
- function debounce(fn, delay) {
- let timer;
- return (...args) => {
- // 判断定时器是否存在,清除定时器
- if (timer) {
- clearTimeout(timer);
- }
-
- // 重新调用setTimeout
- timer = setTimeout(() => {
- fn.apply(this, args);
- }, delay);
- };
- }
- const fn = debounce(logScroll, 500)
- function logScroll(version_name) {
- let container = document.querySelector(`#log${version_name}`)
- let scrollTop = container.scrollTop
- let scrollHeight = container.scrollHeight
- let clientHeight = container.clientHeight
- let scrollLeft = container.scrollLeft
- if (((parseInt(scrollTop) + clientHeight == scrollHeight || parseInt(scrollTop) + clientHeight + 1 == scrollHeight || parseInt(scrollTop) + clientHeight - 1 == scrollHeight)) && parseInt(scrollTop) !== 0 && scrollLeft == 0) {
- let end_line = $(`#log${version_name} input[name=end_line]`).val()
- $.get(`/api/v1/repos/${userName}/${repoPath}/modelarts/train-job/${jobID}/log?version_name=${version_name}&base_line=${end_line}&lines=50&order=desc`, (data) => {
- if (data.Lines == 0) {
- $(`.message${version_name} #header`).text('您已翻阅至日志底部')
- $(`.message${version_name}`).css('display', 'block')
- setTimeout(function () {
- $(`.message${version_name}`).css('display', 'none')
- }, 1000)
- } else {
- if (end_line === data.EndLine) {
- return
- }
- else {
- $(`#log${version_name} input[name=end_line]`).val(data.EndLine)
- $(`#log${version_name}`).append('
' + data.Content)
- }
-
- }
- }).fail(function (err) {
- console.log(err);
- });
- }
- if ([0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10].includes(scrollTop) && scrollLeft == 0) {
- let start_line = $(`#log${version_name} input[name=start_line]`).val()
- $.get(`/api/v1/repos/${userName}/${repoPath}/modelarts/train-job/${jobID}/log?version_name=${version_name}&base_line=${start_line}&lines=50&order=asc`, (data) => {
- if (data.Lines == 0) {
- $(`.message${version_name} #header`).text('您已翻阅至日志顶部')
- $(`.message${version_name}`).css('display', 'block')
- setTimeout(function () {
- $(`.message${version_name}`).css('display', 'none')
- }, 1000)
- } else {
- $(`#log${version_name} input[name=start_line]`).val(data.StartLine) //如果变动就改变所对应的值
- $(`#log${version_name}`).prepend('' + data.Content)
- }
- }).fail(function (err) {
- console.log(err);
- });
- }
- }
- function scrollAnimation(dom, currentY, targetY, currentX) {
- let needScrollTop = targetY - currentY;
- let _currentY = currentY;
- setTimeout(() => {
- // 一次调用滑动帧数,每次调用会不一样
- //取总距离的十分之一
- const dist = Math.ceil(needScrollTop / 10);
- _currentY += dist;
- //移动一个十分之一
- dom.scrollTo(currentX || 0, _currentY, 'smooth');
- // 如果移动幅度小于十个像素,直接移动,否则递归调用,实现动画效果
- if (needScrollTop > 10 || needScrollTop < -10) {
- scrollAnimation(dom, _currentY, targetY)
- } else {
- dom.scrollTo(0, targetY, 'smooth')
- }
- }, 1)
- }
-
- $('.log_top').click(function () {
- // let logContentDom = document.querySelector('.log')
- // if(!logContentDom)
- // return
- // let version_name = $('.log_top').data('version')
- let version_name = $(this).data('version')
- let logContentDom = document.querySelector(`#log${version_name}`)
-
- $(`#log_file${version_name}`).siblings('pre').remove()
- $.get(`/api/v1/repos/${userName}/${repoPath}/modelarts/train-job/${jobID}/log?version_name=${version_name}&base_line=&lines=50&order=asc`, (data) => {
-
- $(`#log${version_name} input[name=end_line]`).val(data.EndLine) //如果变动就改变所对应的值
- $(`#log${version_name} input[name=start_line]`).val(data.StartLine)
- $(`#log${version_name}`).prepend('' + data.Content)
- $(`.message${version_name} #header`).text('您已翻阅至日志顶部')
- $(`.message${version_name}`).css('display', 'block')
- setTimeout(function () {
- $(`.message${version_name}`).css('display', 'none')
- }, 1000)
- scrollAnimation(logContentDom, logContentDom.scrollTop, 0);
- })
-
- })
- $('.log_bottom').click(function (e) {
- let version_name = $(this).data('version')
- let logContentDom = document.querySelector(`#log${version_name}`)
- $(`#log_file${version_name}`).siblings('pre').remove()
- $.get(`/api/v1/repos/${userName}/${repoPath}/modelarts/train-job/${jobID}/log?version_name=${version_name}&base_line=&lines=50&order=desc`, (data) => {
-
- $(`#log${version_name} input[name=end_line]`).val(data.EndLine) //如果变动就改变所对应的值
- $(`#log${version_name} input[name=start_line]`).val(data.StartLine)
- $(`#log${version_name}`).append('' + data.Content)
- $.get(`/api/v1/repos/${userName}/${repoPath}/modelarts/train-job/${jobID}/log?version_name=${version_name}&base_line=${data.EndLine}&lines=50&order=desc`, (data) => {
- if (data.Lines == 0) {
- $(`.message${version_name} #header`).text('您已翻阅至日志底部')
- $(`.message${version_name}`).css('display', 'block')
- setTimeout(function () {
- $(`.message${version_name}`).css('display', 'none')
- }, 1000)
- } else {
- if (end_line === data.EndLine) {
- return
- }
- else {
- $(`#log${version_name} input[name=end_line]`).val(data.EndLine)
- $(`#log${version_name}`).append('' + data.Content)
- }
-
- }
- }).fail(function (err) {
- console.log(err);
- });
- scrollAnimation(logContentDom, logContentDom.scrollTop + 1, logContentDom.scrollHeight - logContentDom.clientHeight);
- })
- })
+
\ No newline at end of file
diff --git a/web_src/js/features/cloudbrainShow.js b/web_src/js/features/cloudbrainShow.js
new file mode 100644
index 000000000..864ea345f
--- /dev/null
+++ b/web_src/js/features/cloudbrainShow.js
@@ -0,0 +1,309 @@
+export default async function initCloudrainSow() {
+ function debounce(fn, delay) {
+ let timer;
+ return (...args) => {
+ // 判断定时器是否存在,清除定时器
+ if (timer) {
+ clearTimeout(timer);
+ }
+
+ // 重新调用setTimeout
+ timer = setTimeout(() => {
+ fn.apply(this, args);
+ }, delay);
+ };
+ }
+
+ function logScroll(version_name) {
+ let container = document.querySelector(`#log${version_name}`);
+ let scrollTop = container.scrollTop;
+ let scrollHeight = container.scrollHeight;
+ let clientHeight = container.clientHeight;
+ let scrollLeft = container.scrollLeft;
+ if (
+ (parseInt(scrollTop) + clientHeight == scrollHeight ||
+ parseInt(scrollTop) + clientHeight + 1 == scrollHeight ||
+ parseInt(scrollTop) + clientHeight - 1 == scrollHeight) &&
+ scrollLeft === 0
+ ) {
+ let end_line = $(`#log${version_name} input[name=end_line]`).val();
+ $.get(
+ `/api/v1/repos/${userName}/${repoPath}/modelarts/inference-job/${jobID}/log?version_name=${version_name}&base_line=${end_line}&lines=50&order=desc`,
+ (data) => {
+ if (data.Lines == 0) {
+ $(`.message${version_name} #header`).text("您已翻阅至日志底部");
+ $(`.message${version_name}`).css("display", "block");
+ setTimeout(function () {
+ $(`.message${version_name}`).css("display", "none");
+ }, 1000);
+ } else {
+ if (end_line === data.EndLine) {
+ return;
+ } else {
+ $(`#log${version_name} input[name=end_line]`).val(data.EndLine);
+ $(`#log${version_name}`).append("" + data.Content);
+ }
+ }
+ }
+ ).fail(function (err) {
+ console.log(err);
+ });
+ }
+ if (scrollTop == 0 && scrollLeft == 0) {
+ let start_line = $(`#log${version_name} input[name=start_line]`).val();
+ $.get(
+ `/api/v1/repos/${userName}/${repoPath}/modelarts/inference-job/${jobID}/log?version_name=${version_name}&base_line=${start_line}&lines=50&order=asc`,
+ (data) => {
+ if (data.Lines == 0) {
+ $(`.message${version_name} #header`).text("您已翻阅至日志顶部");
+ $(`.message${version_name}`).css("display", "block");
+ setTimeout(function () {
+ $(`.message${version_name}`).css("display", "none");
+ }, 1000);
+ } else {
+ $(`#log${version_name} input[name=start_line]`).val(data.StartLine); //如果变动就改变所对应的值
+ $(`#log${version_name}`).prepend("" + data.Content);
+ }
+ }
+ ).fail(function (err) {
+ console.log(err);
+ });
+ }
+ }
+ const fn = debounce(logScroll, 500);
+ $(".log-scroll").scroll(function () {
+ let version_name = $(this).data("version");
+ fn(version_name);
+ });
+ function scrollAnimation(dom, currentY, targetY, currentX) {
+ let needScrollTop = targetY - currentY;
+ let _currentY = currentY;
+ setTimeout(() => {
+ // 一次调用滑动帧数,每次调用会不一样
+ //取总距离的十分之一
+ const dist = Math.ceil(needScrollTop / 10);
+ _currentY += dist;
+ //移动一个十分之一
+ dom.scrollTo(currentX || 0, _currentY, "smooth");
+ // 如果移动幅度小于十个像素,直接移动,否则递归调用,实现动画效果
+ if (needScrollTop > 10 || needScrollTop < -10) {
+ scrollAnimation(dom, _currentY, targetY);
+ } else {
+ dom.scrollTo(0, targetY, "smooth");
+ }
+ }, 1);
+ }
+
+ $(".log_top").click(function () {
+ // let logContentDom = document.querySelector('.log')
+ // if(!logContentDom)
+ // return
+ // let version_name = $('.log_top').data('version')
+ let version_name = $(this).data("version");
+ let logContentDom = document.querySelector(`#log${version_name}`);
+
+ $(`#log_file${version_name}`).siblings("pre").remove();
+ $.get(
+ `/api/v1/repos/${userName}/${repoPath}/modelarts/train-job/${jobID}/log?version_name=${version_name}&base_line=&lines=50&order=asc`,
+ (data) => {
+ $(`#log${version_name} input[name=end_line]`).val(data.EndLine); //如果变动就改变所对应的值
+ $(`#log${version_name} input[name=start_line]`).val(data.StartLine);
+ $(`#log${version_name}`).prepend("" + data.Content);
+ $(`.message${version_name} #header`).text("您已翻阅至日志顶部");
+ $(`.message${version_name}`).css("display", "block");
+ setTimeout(function () {
+ $(`.message${version_name}`).css("display", "none");
+ }, 1000);
+ scrollAnimation(logContentDom, logContentDom.scrollTop, 0);
+ }
+ );
+ });
+ $(".log_bottom").click(function (e) {
+ let version_name = $(this).data("version");
+ let logContentDom = document.querySelector(`#log${version_name}`);
+ $(`#log_file${version_name}`).siblings("pre").remove();
+ $.get(
+ `/api/v1/repos/${userName}/${repoPath}/modelarts/train-job/${jobID}/log?version_name=${version_name}&base_line=&lines=50&order=desc`,
+ (data) => {
+ $(`#log${version_name} input[name=end_line]`).val(data.EndLine); //如果变动就改变所对应的值
+ $(`#log${version_name} input[name=start_line]`).val(data.StartLine);
+ $(`#log${version_name}`).append("" + data.Content);
+ $.get(
+ `/api/v1/repos/${userName}/${repoPath}/modelarts/train-job/${jobID}/log?version_name=${version_name}&base_line=${data.EndLine}&lines=50&order=desc`,
+ (data) => {
+ if (data.Lines == 0) {
+ $(`.message${version_name} #header`).text("您已翻阅至日志底部");
+ $(`.message${version_name}`).css("display", "block");
+ setTimeout(function () {
+ $(`.message${version_name}`).css("display", "none");
+ }, 1000);
+ } else {
+ if (end_line === data.EndLine) {
+ return;
+ } else {
+ $(`#log${version_name} input[name=end_line]`).val(data.EndLine);
+ $(`#log${version_name}`).append("" + data.Content);
+ }
+ }
+ }
+ ).fail(function (err) {
+ console.log(err);
+ });
+ scrollAnimation(
+ logContentDom,
+ logContentDom.scrollTop + 1,
+ logContentDom.scrollHeight - logContentDom.clientHeight
+ );
+ }
+ );
+ });
+
+ //
+ $(".content-pad").on("click", ".load-model-file", function () {
+ console.log("11111111111");
+ let version_name = $(this).data("version");
+ let parents = $(this).data("parents") || "";
+ let filename = $(this).data("filename") || "";
+ let init = $(this).data("init") || "";
+ let path = $(this).data("path");
+ let url = `/api/v1/repos${path}?version_name=${version_name}&parentDir=${parents}`;
+ console.log(url);
+ $.get(url, (data) => {
+ $(`#dir_list${version_name}`).empty();
+ renderDir(path, data, version_name);
+ if (init === "init") {
+ $(`input[name=model${version_name}]`).val("");
+ $(`input[name=modelback${version_name}]`).val(version_name);
+ $(`#file_breadcrumb${version_name}`).empty();
+ let htmlBread = "";
+ htmlBread += `${version_name}
`;
+ htmlBread += " /
";
+ $(`#file_breadcrumb${version_name}`).append(htmlBread);
+ } else {
+ renderBrend(path, version_name, parents, filename, init);
+ }
+ }).fail(function (err) {
+ console.log(err, version_name);
+ });
+ });
+ function renderSize(value) {
+ if (null == value || value == "") {
+ return "0 Bytes";
+ }
+ var unitArr = new Array(
+ "Bytes",
+ "KB",
+ "MB",
+ "GB",
+ "TB",
+ "PB",
+ "EB",
+ "ZB",
+ "YB"
+ );
+ var index = 0;
+ var srcsize = parseFloat(value);
+ index = Math.floor(Math.log(srcsize) / Math.log(1024));
+ var size = srcsize / Math.pow(1024, index);
+ size = size.toFixed(0); //保留的小数位数
+ return size + unitArr[index];
+ }
+ function renderBrend(path, version_name, parents, filename, init) {
+ if (init == "folder") {
+ let htmlBrend = "";
+ let sectionName = $(
+ `#file_breadcrumb${version_name} .active.section`
+ ).text();
+ let parents1 = $(`input[name=model${version_name}]`).val();
+ let filename1 = $(`input[name=modelback${version_name}]`).val();
+ if (parents1 === "") {
+ $(`#file_breadcrumb${version_name} .active.section`).replaceWith(
+ `${sectionName}`
+ );
+ } else {
+ $(`#file_breadcrumb${version_name} .active.section`).replaceWith(
+ `${sectionName}`
+ );
+ }
+
+ htmlBrend += `${filename}
`;
+ htmlBrend += " /
";
+ $(`#file_breadcrumb${version_name}`).append(htmlBrend);
+ $(`input[name=model${version_name}]`).val(parents);
+ $(`input[name=modelback${version_name}]`).val(filename);
+ } else {
+ $(`input[name=model${version_name}]`).val(parents);
+ $(`input[name=modelback${version_name}]`).val(filename);
+ $(`#file_breadcrumb${version_name} a.section:contains(${filename})`)
+ .nextAll()
+ .remove();
+ $(
+ `#file_breadcrumb${version_name} a.section:contains(${filename})`
+ ).replaceWith(`${filename}
`);
+ $(
+ `#file_breadcrumb${version_name} div.section:contains(${filename})`
+ ).append(" /
");
+ }
+ }
+
+ function renderDir(path, data, version_name) {
+ let html = "";
+ html += "";
+ html += "
";
+ html += "
";
+ html += "
";
+ html += "
";
+ html += "
";
+ html += "
";
+ html += "
";
+ html += "
";
+ $(`#dir_list${version_name}`).append(html);
+ }
+}
diff --git a/web_src/js/index.js b/web_src/js/index.js
index 754d6ca76..53dba8a88 100755
--- a/web_src/js/index.js
+++ b/web_src/js/index.js
@@ -43,6 +43,7 @@ import Contributors from "./components/Contributors.vue";
import Model from "./components/Model.vue";
import WxAutorize from "./components/WxAutorize.vue";
import initCloudrain from "./features/cloudrbanin.js";
+import initCloudrainSow from "./features/cloudbrainShow.js";
import initImage from "./features/images.js";
import selectDataset from "./components/dataset/selectDataset.vue";
// import $ from 'jquery.js'
@@ -2917,6 +2918,7 @@ $(document).ready(async () => {
initTribute();
initDropDown();
initCloudrain();
+ initCloudrainSow();
initImage();
initContextMenu();
@@ -3711,9 +3713,9 @@ function initVueDataset() {
if (!el) {
return;
}
- let link = $('#square-link').data('link')
- let repolink = $('.dataset-repolink').data('repolink')
- let datasetType = $('.dataset-repolink').data('dataset-type')
+ let link = $("#square-link").data("link");
+ let repolink = $(".dataset-repolink").data("repolink");
+ let datasetType = $(".dataset-repolink").data("dataset-type");
const clearBtn = document.getElementsByClassName("clear_dataset_value");
const params = new URLSearchParams(location.search);
for (let i = 0; i < clearBtn.length; i++) {
@@ -3873,10 +3875,10 @@ function initVueDataset() {
mounted() {
this.getTypeList();
- if (!!document.getElementById('dataset-repolink-init')) {
+ if (!!document.getElementById("dataset-repolink-init")) {
// this.datasetType = location.href.indexOf('cloudbrain') !== -1 ? 0 : 1
- this.datasetType = $('#dataset-repolink-init').data("dataset-type")
- this.getCurrentRepoDataset(this.repolink, this.datasetType)
+ this.datasetType = $("#dataset-repolink-init").data("dataset-type");
+ this.getCurrentRepoDataset(this.repolink, this.datasetType);
}
const params = new URLSearchParams(location.search);
@@ -3897,13 +3899,13 @@ function initVueDataset() {
this.ruleForm1 = ruleForm;
// this.getEditInit()
- this.starItems = starItems
- this.starActives = starActives
- this.taskLists = taskLists
- this.licenseLists = licenseLists
- this.descfile = dataset_file_desc
- this.repolink = repolink
- this.datasetType = datasetType
+ this.starItems = starItems;
+ this.starActives = starActives;
+ this.taskLists = taskLists;
+ this.licenseLists = licenseLists;
+ this.descfile = dataset_file_desc;
+ this.repolink = repolink;
+ this.datasetType = datasetType;
},
methods: {
copyUrl(url) {
@@ -3924,18 +3926,18 @@ function initVueDataset() {
handleCurrentChange(val) {
this.page = val;
switch (this.activeName) {
- case 'first':
- this.getCurrentRepoDataset(this.repolink, this.datasetType)
- break
- case 'second':
- this.getMyDataset(this.repolink, this.datasetType)
- break
- case 'third':
- this.getPublicDataset(this.repolink, this.datasetType)
- break
- case 'fourth':
- this.getStarDataset(this.repolink, this.datasetType)
- break
+ case "first":
+ this.getCurrentRepoDataset(this.repolink, this.datasetType);
+ break;
+ case "second":
+ this.getMyDataset(this.repolink, this.datasetType);
+ break;
+ case "third":
+ this.getPublicDataset(this.repolink, this.datasetType);
+ break;
+ case "fourth":
+ this.getStarDataset(this.repolink, this.datasetType);
+ break;
}
},
handleCheckedChange(val) {
@@ -4276,18 +4278,18 @@ function initVueDataset() {
},
refreshStatusDataset() {
switch (this.activeName) {
- case 'first':
- this.getCurrentRepoDataset(this.repolink, this.datasetType)
- break
- case 'second':
- this.getMyDataset(this.repolink, this.datasetType)
- break
- case 'third':
- this.getPublicDataset(this.repolink, this.datasetType)
- break
- case 'fourth':
- this.getStarDataset(this.repolink, this.datasetType)
- break
+ case "first":
+ this.getCurrentRepoDataset(this.repolink, this.datasetType);
+ break;
+ case "second":
+ this.getMyDataset(this.repolink, this.datasetType);
+ break;
+ case "third":
+ this.getPublicDataset(this.repolink, this.datasetType);
+ break;
+ case "fourth":
+ this.getStarDataset(this.repolink, this.datasetType);
+ break;
}
},
getCurrentRepoDataset(repoLink, type) {
@@ -4398,44 +4400,44 @@ function initVueDataset() {
},
searchDataset() {
switch (this.activeName) {
- case 'first':
- this.page = 1
- this.getCurrentRepoDataset(this.repolink, this.datasetType)
- break
- case 'second':
- this.page = 1
- this.getMyDataset(this.repolink, this.datasetType)
- break
- case 'third':
- this.page = 1
- this.getPublicDataset(this.repolink, this.datasetType)
- break
- case 'fourth':
- this.page = 1
- this.getStarDataset(this.repolink, this.datasetType)
- break
+ case "first":
+ this.page = 1;
+ this.getCurrentRepoDataset(this.repolink, this.datasetType);
+ break;
+ case "second":
+ this.page = 1;
+ this.getMyDataset(this.repolink, this.datasetType);
+ break;
+ case "third":
+ this.page = 1;
+ this.getPublicDataset(this.repolink, this.datasetType);
+ break;
+ case "fourth":
+ this.page = 1;
+ this.getStarDataset(this.repolink, this.datasetType);
+ break;
}
},
},
watch: {
searchDataItem() {
switch (this.activeName) {
- case 'first':
- this.page = 1
- this.getCurrentRepoDataset(this.repolink, this.datasetType)
- break
- case 'second':
- this.page = 1
- this.getMyDataset(this.repolink, this.datasetType)
- break
- case 'third':
- this.page = 1
- this.getPublicDataset(this.repolink, this.datasetType)
- break
- case 'fourth':
- this.page = 1
- this.getStarDataset(this.repolink, this.datasetType)
- break
+ case "first":
+ this.page = 1;
+ this.getCurrentRepoDataset(this.repolink, this.datasetType);
+ break;
+ case "second":
+ this.page = 1;
+ this.getMyDataset(this.repolink, this.datasetType);
+ break;
+ case "third":
+ this.page = 1;
+ this.getPublicDataset(this.repolink, this.datasetType);
+ break;
+ case "fourth":
+ this.page = 1;
+ this.getStarDataset(this.repolink, this.datasetType);
+ break;
}
},
},