{
- store.commit(`${ns}/setActiveDependency`, dep);
- store.commit(`${ns}/showDialog`, 'logs');
- }}
- >
- {{
- 'extra-items': () => {
- let color: string;
- switch (dep.status) {
- case 'installing':
- case 'uninstalling':
- color = 'var(--cl-warning-color)';
- break;
- case 'installed':
- case 'uninstalled':
- color = 'var(--cl-success-color)';
- break;
- case 'error':
- case 'abnormal':
- color = 'var(--cl-danger-color)';
- break;
- default:
- color = 'inherit';
- }
- return (
- <>
-
-
-
-
-
-
- {t(
- `views.env.deps.dependency.status.${dep.status}`
- )}
-
-
- {dep.error && (
+ value: (row: DependencyRepo) => {
+ return nodeState.allList
+ .sort((a, b) =>
+ a.is_master ? -1 : (a.name || '').localeCompare(b.name || '')
+ )
+ .filter(n => n.active)
+ .map(node => {
+ const dep = row.dependencies?.find(
+ dep => dep.node_id === node._id
+ );
+ if (!dep) return;
+ return (
+ {
+ store.commit(`${ns}/setActiveDependency`, dep);
+ store.commit(`${ns}/showDialog`, 'logs');
+ }}
+ >
+ {{
+ 'extra-items': () => {
+ let color: string;
+ switch (dep.status) {
+ case 'installing':
+ case 'uninstalling':
+ color = 'var(--cl-warning-color)';
+ break;
+ case 'installed':
+ case 'uninstalled':
+ color = 'var(--cl-success-color)';
+ break;
+ case 'error':
+ case 'abnormal':
+ color = 'var(--cl-danger-color)';
+ break;
+ default:
+ color = 'inherit';
+ }
+ return (
+ <>
+
+
+
- {dep.error}
+ {t(
+ `views.env.deps.dependency.status.${dep.status}`
+ )}
- )}
- {dep.version && (
-
-
- {dep.version}
-
- )}
- >
- );
- },
- }}
-
- );
- }),
+ {dep.error && (
+
+
+
+ {dep.error}
+
+
+ )}
+ {dep.version && (
+
+
+ {dep.version}
+
+ )}
+ >
+ );
+ },
+ }}
+
+ );
+ });
+ },
},
{
key: 'actions',
diff --git a/src/views/task/list/useTaskList.tsx b/src/views/task/list/useTaskList.tsx
index 480a5de70fe5b..62f1a2ccdfd34 100644
--- a/src/views/task/list/useTaskList.tsx
+++ b/src/views/task/list/useTaskList.tsx
@@ -113,15 +113,16 @@ const useTaskList = () => {
name: 'filter',
children: [
{
- action: ACTION_FILTER_SEARCH,
- id: 'filter-search',
- className: 'search',
- placeholder: t('views.tasks.navActions.filter.search.placeholder'),
+ action: ACTION_FILTER_SELECT,
+ id: 'filter-select-status',
+ className: 'filter-select-status',
+ label: t('views.tasks.navActionsExtra.filter.select.status.label'),
+ options: getStatusOptions(),
onChange: onListFilterChangeByKey(
store,
ns,
- 'name',
- FILTER_OP_CONTAINS
+ 'status',
+ FILTER_OP_EQUAL
),
},
{
@@ -169,46 +170,6 @@ const useTaskList = () => {
FILTER_OP_EQUAL
),
},
- {
- action: ACTION_FILTER_SELECT,
- id: 'filter-select-priority',
- className: 'filter-select-priority',
- label: t('views.tasks.navActionsExtra.filter.select.priority.label'),
- options: priorityOptions,
- onChange: onListFilterChangeByKey(
- store,
- ns,
- 'priority',
- FILTER_OP_EQUAL
- ),
- },
- {
- action: ACTION_FILTER_SEARCH,
- id: 'filter-search-cmd',
- className: 'search-cmd',
- placeholder: t(
- 'views.tasks.navActionsExtra.filter.search.cmd.placeholder'
- ),
- onChange: onListFilterChangeByKey(
- store,
- ns,
- 'cmd',
- FILTER_OP_CONTAINS
- ),
- },
- {
- action: ACTION_FILTER_SELECT,
- id: 'filter-select-status',
- className: 'filter-select-status',
- label: t('views.tasks.navActionsExtra.filter.select.status.label'),
- options: getStatusOptions(),
- onChange: onListFilterChangeByKey(
- store,
- ns,
- 'status',
- FILTER_OP_EQUAL
- ),
- },
],
},
]);