mirror of
https://github.com/1Panel-dev/1Panel.git
synced 2025-01-31 14:08:06 +08:00
feat: 容器编辑提示增加判断条件 (#2553)
This commit is contained in:
parent
2d2869d184
commit
99951029c8
@ -25,7 +25,7 @@
|
||||
<el-row type="flex" justify="center">
|
||||
<el-col :span="22">
|
||||
<el-alert
|
||||
v-if="dialogData.title === 'edit'"
|
||||
v-if="dialogData.title === 'edit' && isFromApp(dialogData.rowData!)"
|
||||
:title="$t('container.containerFromAppHelper')"
|
||||
class="common-prompt"
|
||||
:closable="false"
|
||||
@ -579,6 +579,13 @@ const checkPortValid = () => {
|
||||
}
|
||||
return true;
|
||||
};
|
||||
|
||||
const isFromApp = (rowData: Container.ContainerHelper) => {
|
||||
if (rowData && rowData.labels) {
|
||||
return rowData.labels.indexOf('createdBy=Apps') > -1;
|
||||
}
|
||||
return false;
|
||||
};
|
||||
defineExpose({
|
||||
acceptParams,
|
||||
});
|
||||
|
Loading…
x
Reference in New Issue
Block a user