Skip to content

Commit

Permalink
[Fix][UI Next][V1.0.0-Beta] Fix the resource Center dark mode display…
Browse files Browse the repository at this point in the history
… exception when viewing the file details.
  • Loading branch information
songjianet committed Apr 16, 2022
1 parent 79fe5b0 commit e1faaec
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 18 deletions.
5 changes: 4 additions & 1 deletion dolphinscheduler-ui-next/src/components/modal/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,10 @@ const Modal = defineComponent({
.filter((item: any) => item.show)
.map((item: any) => {
return (
<ButtonLink onClick={item.action} disabled={item.disabled}>
<ButtonLink
onClick={item.action}
disabled={item.disabled}
>
{{
default: () => item.text,
icon: () => item.icon()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import {
} from 'vue'
import { useFormItem } from 'naive-ui/es/_mixins'
import { call } from 'naive-ui/es/_utils'
import {useThemeStore} from "@/store/theme/theme";
import { useThemeStore } from '@/store/theme/theme'
import * as monaco from 'monaco-editor'
import editorWorker from 'monaco-editor/esm/vs/editor/editor.worker?worker'
import jsonWorker from 'monaco-editor/esm/vs/language/json/json.worker?worker'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,7 @@ import type {
IWorkflowTaskInstance,
WorkflowInstance
} from './types'
import {
querySubProcessInstanceByTaskCode
} from '@/service/modules/process-instances'
import { querySubProcessInstanceByTaskCode } from '@/service/modules/process-instances'

const props = {
show: {
Expand Down Expand Up @@ -156,18 +154,22 @@ const NodeDetailModal = defineComponent({
{
text: t('project.node.enter_this_child_node'),
show: props.data.taskType === 'SUB_PROCESS',
disabled: !props.data.id || (router.currentRoute.value.name === 'workflow-instance-detail' && !props.taskInstance),
disabled:
!props.data.id ||
(router.currentRoute.value.name === 'workflow-instance-detail' &&
!props.taskInstance),
action: () => {
if (router.currentRoute.value.name === 'workflow-instance-detail') {
querySubProcessInstanceByTaskCode({ taskId: props.taskInstance?.id }, { projectCode: props.projectCode }).then(
(res: any) => {
router.push({
name: 'workflow-instance-detail',
params: { id: res.subProcessInstanceId },
query: { code: props.data.taskParams?.processDefinitionCode }
})
}
)
querySubProcessInstanceByTaskCode(
{ taskId: props.taskInstance?.id },
{ projectCode: props.projectCode }
).then((res: any) => {
router.push({
name: 'workflow-instance-detail',
params: { id: res.subProcessInstanceId },
query: { code: props.data.taskParams?.processDefinitionCode }
})
})
} else {
router.push({
name: 'workflow-definition-detail',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,7 @@ export default defineComponent({
class={styles['form-content']}
>
<NFormItem path='content'>
<MonacoEditor
v-model={[this.resourceViewRef.content, 'value']}
/>
<MonacoEditor v-model={[this.resourceViewRef.content, 'value']} />
</NFormItem>
{this.componentName === 'resource-file-edit' && (
<NSpace>
Expand Down

0 comments on commit e1faaec

Please sign in to comment.