Browse Source

[Fix][UI Next][V1.0.0-Beta] Add a return button and set the form to disabled on the file detail page. (#9802)

3.0.0/version-upgrade
Amy0104 3 years ago committed by GitHub
parent
commit
1c4b8d1811
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 29
      dolphinscheduler-ui-next/src/views/resource/file/edit/index.tsx

29
dolphinscheduler-ui-next/src/views/resource/file/edit/index.tsx

@ -73,22 +73,23 @@ export default defineComponent({
rules={this.rules}
ref='fileFormRef'
class={styles['form-content']}
disabled={this.componentName !== 'resource-file-edit'}
>
<NFormItem path='content'>
<MonacoEditor v-model={[this.resourceViewRef.content, 'value']} />
</NFormItem>
{this.componentName === 'resource-file-edit' && (
<NSpace>
<NButton
type='info'
size='small'
text
style={{ marginRight: '15px' }}
onClick={this.handleReturn}
class='btn-cancel'
>
{t('resource.file.return')}
</NButton>
<NSpace>
<NButton
type='info'
size='small'
text
style={{ marginRight: '15px' }}
onClick={this.handleReturn}
class='btn-cancel'
>
{t('resource.file.return')}
</NButton>
{this.componentName === 'resource-file-edit' && (
<NButton
type='info'
size='small'
@ -98,8 +99,8 @@ export default defineComponent({
>
{t('resource.file.save')}
</NButton>
</NSpace>
)}
)}
</NSpace>
</NForm>
</div>
</Card>

Loading…
Cancel
Save