Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
228dcf5
add dataflow
Aug 13, 2025
49bc15c
add dataflow
Aug 13, 2025
b217607
add dataflow
Aug 13, 2025
8745478
remove antv/x6/lib/registry package
Aug 13, 2025
75aecb0
Fix bugs
Aug 14, 2025
63e67f4
Fix bugs
Aug 14, 2025
d05c58a
add package
Aug 14, 2025
3467eef
add package
Aug 14, 2025
3b826a3
add zhHantOps
Aug 14, 2025
9daff24
Merge pull request #1 from OpenCSGs/main
z275748353 Aug 17, 2025
08ff9c5
1.Adjust the image path for operator management
Aug 17, 2025
dae2cbe
Operator Management: Modification of dataflow/operator/ interface
Aug 17, 2025
04b703a
Merge pull request #3 from OpenCSGs/main
z275748353 Aug 18, 2025
1e5f80f
1.Add the cancellation of execution for internationalization and stat…
Aug 20, 2025
5f395ef
1.Add the cancellation of execution for internationalization and stat…
Aug 20, 2025
eeb2a9d
Merge pull request #4 from OpenCSGs/main
z275748353 Aug 23, 2025
fc375cd
1.Add the cancellation of execution for internationalization and stat…
Aug 23, 2025
9d422c9
Merge pull request #5 from OpenCSGs/main
z275748353 Sep 15, 2025
7aa41ad
Add newly developed operators, internationalize tools, and supplement…
Sep 15, 2025
00862d4
Add newly developed operators, internationalize tools, and supplement…
Sep 15, 2025
6778e54
Merge pull request #6 from OpenCSGs/main
z275748353 Oct 30, 2025
3a091dd
1.Add template deletion function
Oct 30, 2025
121a4e2
Fix the bug of dataflow with ID #36
Oct 30, 2025
6423588
Fix the bug of dataflow with ID OpenCSGS/csghub-dataflow#31
Oct 31, 2025
aadd742
Fix the bug of dataflow with ID OpenCSGS/csghub-dataflow#43
Nov 20, 2025
4098348
Merge branch 'main' into csghub-wl-jlp
z275748353 Nov 22, 2025
3717233
Merge pull request #7 from OpenCSGs/main
z275748353 Nov 26, 2025
27530ed
Fix the bug of dataflow with ID OpenCSGS/csghub-dataflow#34
Nov 27, 2025
a17cf85
Merge pull request #8 from OpenCSGs/main
z275748353 Nov 27, 2025
91a889c
Merge branch 'csghub-wl-jlp' of https://github.com/z275748353/csghub …
Nov 27, 2025
2debed9
Merge pull request #9 from OpenCSGs/main
z275748353 Nov 28, 2025
e6c7174
1.Fixed the issue where modifying the custom template operator name d…
Nov 28, 2025
014c55f
Merge remote-tracking branch 'origin/csghub-wl-jlp' into csghub-wl-jlp
Nov 28, 2025
d6598f8
Merge pull request #11 from OpenCSGs/main
z275748353 Dec 2, 2025
1ab36ac
1.Add horizontal and vertical alignment guides for operator task flow…
LP-J Dec 2, 2025
2231ffd
1. When dealing with operator overlap, there may be duplicate connect…
LP-J Dec 3, 2025
23fb4f1
Problem handling of model path display
LP-J Dec 5, 2025
7d31e95
Merge branch 'main' into csghub-wl-jlp
z275748353 Dec 5, 2025
ca9614c
1.Add a field for "whether to generate a meta file" and corresponding…
LP-J Dec 6, 2025
7ec80cd
Operator task list 'execution' status issue
LP-J Dec 8, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -249,6 +249,19 @@
</el-input>
</el-form-item>
</el-col>
<el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12">
<el-form-item prop="skip_meta" class="mt-[12px]">
<template #label>
<p class="text-gray-500 text-xs">
{{ t("dataPipelines.skipMeta") }}
</p>
</template>
<el-radio-group v-model="form.skip_meta">
<el-radio :label="true">{{ t("dataPipelines.yes") }}</el-radio>
<el-radio :label="false">{{ t("dataPipelines.no") }}</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
</el-row>
</el-form>

Expand Down Expand Up @@ -285,6 +298,7 @@ const formLoading = ref(false);
const userStore = useUserStore();
// 表单
const form = ref({
skip_meta: true,
// from_format_types: null,
// to_data_type: null,
});
Expand Down
21 changes: 11 additions & 10 deletions frontend/src/components/dataflow_config/dataflow/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -151,10 +151,7 @@

<el-popconfirm
:title="
scope.row.status === 'Failed' ||
scope.row.status === 'Timeout' ||
scope.row.status === 'Finished' ||
scope.row.status === 'Canceled' ? `${t('dataPipelines.executeConfirm')}?` : `${t('dataPipelines.cancelExecute')}?`
scope.row.status === 'Processing' ? `${t('dataPipelines.cancelExecute')}?` : `${t('dataPipelines.executeConfirm')}?`
"
:confirm-button-text="t('dataPipelines.confirm')"
:cancel-button-text="t('dataPipelines.cancel')"
Expand All @@ -164,12 +161,14 @@
<template #reference>
<el-button
type="text"
class="flex items-center justify-start cursor-pointer"
:class="[
'flex items-center justify-start cursor-pointer',
scope.row.status === 'Finished' ? 'text-gray-400' : ''
]"
:disabled="scope.row.status === 'Finished'"
>
{{
scope.row.status === 'Failed' ||
scope.row.status === 'Timeout' ||
scope.row.status === 'Finished' ? t("dataPipelines.execute") : t("dataPipelines.cancel")
scope.row.status === 'Processing' ? t("dataPipelines.cancel") : t("dataPipelines.execute")
}}
</el-button>
</template>
Expand Down Expand Up @@ -275,8 +274,7 @@ const handleSearch = () => {
};

const openExecuteDialog = async (job_id, status) => {
if (status === 'Failed' || status === 'Timeout' || status === 'Finished') {
console.log('执行', job_id)
if (status === 'Failed' || status === 'Timeout' || status === 'Finished' || status === 'Queued') {
const url = `/dataflow/jobs/job/execute/${job_id}`;
const { data } = await useFetchApi(url).post().json();
if (data.value.code === 200) {
Expand Down Expand Up @@ -395,6 +393,9 @@ onMounted(() => {
.el-button--text {
border: none;
}
.el-button--text.is-disabled {
color: #9ca3af !important;
}
.el-table__cell {
font-size: 14px;
color: #101828;
Expand Down
144 changes: 144 additions & 0 deletions frontend/src/components/dataflow_config/newTask/ModelSelectItem.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,144 @@
<template>
<div :class="[
`${repoType}-card`,
repoType === 'model' ? 'bg-gradient-to-r from-[#fafefe] to-white' : '',
repoType === 'dataset' ? 'bg-gradient-to-r from-[#fbfaff] to-white' : '',
repoType === 'code' ? 'bg-gradient-to-r from-[#F9FAFA] to-white' : ''
]"
class="flex flex-col justify-between focus:outline focus:outline-4 focus:outline-gray-200 hover:shadow-md p-4 gap-1 md:w-full border border-gray-200 rounded-md flex-grow xl:basis-full min-w-[250px] xl:max-w-full h-fit cursor-pointer"
:style="isCollection ? 'width:100%' : ''"
>
<div class="flex items-center justify-between mb-1 gap-2 w-full">
<SvgIcon v-if="repoType === 'model'" name="models" width="18" height="18" />
<SvgIcon v-if="repoType === 'dataset'" name="datasets" width="18" height="18" />
<SvgIcon v-if="repoType === 'code'" name="codes" width="18" height="18" />
<SvgIcon v-if="repoType === 'space'" name="spaces" width="18" height="18" />
<div :class="`${repoType}-path`"
class="text-sm font-medium text-gray-700 text-ellipsis overflow-hidden whitespace-nowrap w-full flex items-center gap-2"
>
<div :class="showNewTag ? 'max-w-[80%] overflow-hidden text-ellipsis' : 'w-full'">{{ getComputed.path }}</div>
<div v-if="showNewTag">
<el-tooltip :content="$t(`${repoType}s.newTips`)" placement="top">
<NewTag />
</el-tooltip>
</div>
</div>
<RepoItemSyncIcon
:source="repo.source"
:syncStatus="repo.sync_status"
:httpCloneUrl="repo.repository && repo.repository.http_clone_url"
/>
</div>

<p v-if="getComputed.showDescription"
class="w-full min-h-[18px] leading-[18px] mb-1.5 text-gray-500 text-sm font-normal overflow-hidden text-ellipsis line-clamp-1 text-left"
:class="isCollection ? 'hidden' : ''"
>
{{ repo.description || '\u00A0' }}
</p>

<div class="flex flex-nowrap overflow-hidden text-ellipsis items-center gap-2 text-xs text-gray-500">
<span v-if="getComputed.taskTag"
class="w-fit xl:max-w-full overflow-hidden text-ellipsis whitespace-nowrap flex items-center gap-1"
>
<img v-if="getComputed.taskTagIconPath && taskTagIconExists" :src="getComputed.taskTagIconPath" class="w-3 h-3 text-gray-500 filter-gray" alt="" />
{{ getComputed.taskTag }}
</span>

<span v-if="getComputed.taskTag">
<SvgIcon name="vertical_divider" />
</span>

<div class="overflow-hidden text-ellipsis whitespace-nowrap flex gap-1 items-center">
<SvgIcon name="clock" />
{{$t('all.lastTime')}}:{{ repo.updated_at.substring(0, 10) }}
</div>

<template v-if="getComputed.visibility">
<span> <SvgIcon name="vertical_divider" /> </span>
<span class="visibility-label">{{ getComputed.visibility }}</span>
</template>

<span> <SvgIcon name="vertical_divider" /> </span>

<span class="whitespace-nowrap flex gap-1 items-center">
<SvgIcon name="download2" />
{{ repo.downloads }}
</span>
</div>
</div>
</template>

<script setup>
import RepoItemSyncIcon from '../../shared/RepoItemSyncIcon.vue';
import { computed, ref, watch } from 'vue'
import { useI18n } from 'vue-i18n'
import NewTag from '../../shared/NewTag.vue'
import { isWithinTwoWeeks } from '../../../packs/datetimeUtils'

const props = defineProps({
repo: Object,
repoType: String,
isCollection: Boolean,
cardType: {
type: String,
default: 'index'
}
})
const { t, locale } = useI18n()
const taskTagIconExists = ref(false)
const showNewTag = computed(() => {
return ((props.repoType === 'model' || props.repoType === 'dataset')) && (isWithinTwoWeeks(props.repo.created_at) || isWithinTwoWeeks(props.repo.updated_at));
});

const getComputed = computed(() => {
const path = props.repo.path

const visibility = props.repo.private ? t('all.private') : ''
const showDescription = props.cardType === 'index' || !!props.repo.description?.trim()

const taskTagObj = (props.repo.tags || []).find(tag => tag.category === "task")
let taskTag = null
if (taskTagObj) {
if (locale.value === 'en') {
taskTag = taskTagObj["name"].replace(/-/g, ' ')
} else {
taskTag = taskTagObj["show_name"]
}

// 获取标签对应的图标路径,图标文件名与标签名完全一致
const taskTagIconPath = taskTagObj.name ? `/images/tags/${taskTagObj.name}.svg` : null
return { path, visibility, taskTag, showDescription, taskTagIconPath }
}

return { path, visibility, taskTag: null, showDescription, taskTagIconPath: null }

})

// 检查图标是否存在的函数
const checkIconExists = (iconPath) => {
if (!iconPath) {
taskTagIconExists.value = false
return
}

const img = new Image()
img.onload = () => {
taskTagIconExists.value = true
}
img.onerror = () => {
taskTagIconExists.value = false
}
img.src = iconPath
}

watch(() => getComputed.value.taskTagIconPath, (newIconPath) => {
checkIconExists(newIconPath)
}, { immediate: true }) // immediate: true to run on initial load
</script>

<style scoped>
.filter-gray {
filter: invert(56%) sepia(11%) saturate(207%) hue-rotate(176deg) brightness(93%) contrast(84%);
}
</style>
16 changes: 12 additions & 4 deletions frontend/src/components/dataflow_config/newTask/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -677,10 +677,13 @@
<div
v-for="model in modelList"
:key="model.id"
@click="selectModel(model)"
class="cursor-pointer model-select-item"
@click="!modelValidating && selectModel(model)"
:class="[
'model-select-item',
modelValidating ? 'cursor-not-allowed opacity-60' : 'cursor-pointer'
]"
>
<repo-item
<ModelSelectItem
:repo="model"
repo-type="model"
/>
Expand Down Expand Up @@ -720,7 +723,7 @@
import Sortable from 'sortablejs'
import { useI18n } from 'vue-i18n'
import { Search } from '@element-plus/icons-vue'
import RepoItem from '../../shared/RepoItem.vue'
import ModelSelectItem from './ModelSelectItem.vue'
import CsgPagination from '../../shared/CsgPagination.vue'

const userStore = useUserStore()
Expand Down Expand Up @@ -1135,6 +1138,11 @@

// 选择模型
const selectModel = async (model) => {
// 正在验证中
if (modelValidating.value) {
return
}

if (!currentSelectModelItem.value) {
return
}
Expand Down
3 changes: 3 additions & 0 deletions frontend/src/locales/en_js/datapipelines.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ export const dataPipelines = {
"sourceFormat": "Source Format",
"targetFormat": "Target Format",
"dataFlowBranch": "Data Flow Branch",
"skipMeta": "Generate Meta File",
"yes": "Yes",
"no": "No",
"startExecution": "Start Execution",
"searchTaskName": "Search Task Name",
"confirmTermination": "Confirm Termination",
Expand Down
3 changes: 3 additions & 0 deletions frontend/src/locales/zh_hant_js/datapipelines.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ export const dataPipelines = {
"sourceFormat": "來源格式",
"targetFormat": "目標格式",
"dataFlowBranch": "資料流向分支",
"skipMeta": "是否生成Meta文件",
"yes": "是",
"no": "否",
"startExecution": "開始執行",
"searchTaskName": "搜尋任務名稱",
"confirmTermination": "確認終止",
Expand Down
3 changes: 3 additions & 0 deletions frontend/src/locales/zh_js/datapipelines.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ export const dataPipelines = {
"sourceFormat": "源格式",
"targetFormat": "目标格式",
"dataFlowBranch": "数据流向分支",
"skipMeta": "是否生成Meta文件",
"yes": "是",
"no": "否",
"startExecution": "开始执行",
"searchTaskName": "搜索任务名称",
"confirmTermination": "确认终止",
Expand Down