未验证 提交 1c4b8d18 编写于 作者: A Amy0104 提交者: GitHub

[Fix][UI Next][V1.0.0-Beta] Add a return button and set the form to disabled...

[Fix][UI Next][V1.0.0-Beta] Add a return button and set the form to disabled on the file detail page. (#9802)
上级 d618602a
......@@ -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>
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册