mirror of
https://github.com/1Panel-dev/1Panel.git
synced 2024-11-23 18:49:21 +08:00
Fix typos (#3897)
* Fix typos in backend folder * Fix typos in frontend * Fix typos in frontend * Fix Percent typo
This commit is contained in:
parent
046d8f526b
commit
51d09b7164
@ -181,7 +181,7 @@ func (u *DockerService) UpdateConf(req dto.SettingUpdate) error {
|
||||
} else {
|
||||
daemonMap["iptables"] = false
|
||||
}
|
||||
case "Dirver":
|
||||
case "Driver":
|
||||
if opts, ok := daemonMap["exec-opts"]; ok {
|
||||
if optsValue, isArray := opts.([]interface{}); isArray {
|
||||
for i := 0; i < len(optsValue); i++ {
|
||||
|
@ -97,11 +97,11 @@ func snapAppData(snap snapHelper, targetDir string) {
|
||||
}
|
||||
}
|
||||
}
|
||||
for _, rumtime := range runtimes {
|
||||
for _, runtime := range runtimes {
|
||||
for _, existImage := range existImages {
|
||||
if rumtime.Image == existImage && !duplicateMap[rumtime.Image] {
|
||||
imageSaveList = append(imageSaveList, rumtime.Image)
|
||||
duplicateMap[rumtime.Image] = true
|
||||
if runtime.Image == existImage && !duplicateMap[runtime.Image] {
|
||||
imageSaveList = append(imageSaveList, runtime.Image)
|
||||
duplicateMap[runtime.Image] = true
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -261,8 +261,8 @@ func loadArch() (string, error) {
|
||||
if std == "armv7l\n" {
|
||||
return "armv7", nil
|
||||
}
|
||||
return "", fmt.Errorf("unsupport such arch: arm-%s", std)
|
||||
return "", fmt.Errorf("unsupported such arch: arm-%s", std)
|
||||
default:
|
||||
return "", fmt.Errorf("unsupport such arch: %s", runtime.GOARCH)
|
||||
return "", fmt.Errorf("unsupported such arch: %s", runtime.GOARCH)
|
||||
}
|
||||
}
|
||||
|
@ -23,7 +23,7 @@ func syncApp() {
|
||||
|
||||
func syncInstalledApp() {
|
||||
if err := service.NewIAppInstalledService().SyncAll(true); err != nil {
|
||||
global.LOG.Errorf("sync instaled app error: %s", err.Error())
|
||||
global.LOG.Errorf("sync installed app error: %s", err.Error())
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -17,13 +17,13 @@ import (
|
||||
func Init() {
|
||||
if _, err := os.Stat(global.CONF.System.DbPath); err != nil {
|
||||
if err := os.MkdirAll(global.CONF.System.DbPath, os.ModePerm); err != nil {
|
||||
panic(fmt.Errorf("init db dir falied, err: %v", err))
|
||||
panic(fmt.Errorf("init db dir failed, err: %v", err))
|
||||
}
|
||||
}
|
||||
fullPath := global.CONF.System.DbPath + "/" + global.CONF.System.DbFile
|
||||
if _, err := os.Stat(fullPath); err != nil {
|
||||
if _, err := os.Create(fullPath); err != nil {
|
||||
panic(fmt.Errorf("init db file falied, err: %v", err))
|
||||
panic(fmt.Errorf("init db file failed, err: %v", err))
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -56,8 +56,8 @@ type MineFormatter struct{}
|
||||
func (s *MineFormatter) Format(entry *logrus.Entry) ([]byte, error) {
|
||||
detailInfo := ""
|
||||
if entry.Caller != nil {
|
||||
funcion := strings.ReplaceAll(entry.Caller.Function, "github.com/1Panel-dev/1Panel/backend/", "")
|
||||
detailInfo = fmt.Sprintf("(%s: %d)", funcion, entry.Caller.Line)
|
||||
function := strings.ReplaceAll(entry.Caller.Function, "github.com/1Panel-dev/1Panel/backend/", "")
|
||||
detailInfo = fmt.Sprintf("(%s: %d)", function, entry.Caller.Line)
|
||||
}
|
||||
if len(entry.Data) == 0 {
|
||||
msg := fmt.Sprintf("[%s] [%s] %s %s \n", time.Now().Format(TimeFormat), strings.ToUpper(entry.Level.String()), entry.Message, detailInfo)
|
||||
|
@ -141,7 +141,7 @@ func (f *Ufw) Port(port FireInfo, operation string) error {
|
||||
case "drop":
|
||||
port.Strategy = "deny"
|
||||
default:
|
||||
return fmt.Errorf("unsupport strategy %s", port.Strategy)
|
||||
return fmt.Errorf("unsupported strategy %s", port.Strategy)
|
||||
}
|
||||
if cmd.CheckIllegal(port.Protocol, port.Port) {
|
||||
return buserr.New(constant.ErrCmdIllegal)
|
||||
@ -168,7 +168,7 @@ func (f *Ufw) RichRules(rule FireInfo, operation string) error {
|
||||
case "drop":
|
||||
rule.Strategy = "deny"
|
||||
default:
|
||||
return fmt.Errorf("unsupport strategy %s", rule.Strategy)
|
||||
return fmt.Errorf("unsupported strategy %s", rule.Strategy)
|
||||
}
|
||||
|
||||
if cmd.CheckIllegal(operation, rule.Protocol, rule.Address, rule.Port) {
|
||||
|
@ -152,7 +152,7 @@ func Dump(dns string, opts ...DumpOption) error {
|
||||
var columns []string
|
||||
columns, err = lineRows.Columns()
|
||||
if err != nil {
|
||||
global.LOG.Errorf("get columes falied, err: %v", err)
|
||||
global.LOG.Errorf("get columes failed, err: %v", err)
|
||||
return err
|
||||
}
|
||||
columnTypes, err := lineRows.ColumnTypes()
|
||||
|
@ -27,8 +27,8 @@ class RequestHttp {
|
||||
...config.headers,
|
||||
};
|
||||
if (config.url === '/auth/login' || config.url === '/auth/mfalogin') {
|
||||
let entrace = Base64.encode(globalStore.entrance);
|
||||
config.headers.EntranceCode = entrace;
|
||||
let entrance = Base64.encode(globalStore.entrance);
|
||||
config.headers.EntranceCode = entrance;
|
||||
}
|
||||
return {
|
||||
...config,
|
||||
|
@ -245,7 +245,7 @@ export namespace Container {
|
||||
path: string;
|
||||
template: number;
|
||||
}
|
||||
export interface ComposeOpration {
|
||||
export interface ComposeOperation {
|
||||
name: string;
|
||||
operation: string;
|
||||
path: string;
|
||||
|
@ -156,7 +156,7 @@ export const upCompose = (params: Container.ComposeCreate) => {
|
||||
export const testCompose = (params: Container.ComposeCreate) => {
|
||||
return http.post<boolean>(`/containers/compose/test`, params);
|
||||
};
|
||||
export const composeOperator = (params: Container.ComposeOpration) => {
|
||||
export const composeOperator = (params: Container.ComposeOperation) => {
|
||||
return http.post(`/containers/compose/operate`, params);
|
||||
};
|
||||
export const composeUpdate = (params: Container.ComposeUpdate) => {
|
||||
|
@ -164,7 +164,7 @@ const getContent = () => {
|
||||
}
|
||||
data.value = res.data;
|
||||
if (res.data.content != '') {
|
||||
if (stopSignals.some((singal) => res.data.content.endsWith(singal))) {
|
||||
if (stopSignals.some((signal) => res.data.content.endsWith(signal))) {
|
||||
onCloseLog();
|
||||
}
|
||||
if (end.value) {
|
||||
|
@ -13,7 +13,7 @@ import { onMounted, ref } from 'vue';
|
||||
const props = defineProps({
|
||||
status: {
|
||||
type: String,
|
||||
default: 'runnning',
|
||||
default: 'running',
|
||||
},
|
||||
});
|
||||
let status = ref('running');
|
||||
|
@ -36,9 +36,9 @@
|
||||
</template>
|
||||
<div class="panel-MdEditor">
|
||||
<el-alert :closable="false">
|
||||
<span class="line-heigth">{{ $t('setting.versionHelper') }}</span>
|
||||
<li class="line-heigth">{{ $t('setting.versionHelper1') }}</li>
|
||||
<li class="line-heigth">{{ $t('setting.versionHelper2') }}</li>
|
||||
<span class="line-height">{{ $t('setting.versionHelper') }}</span>
|
||||
<li class="line-height">{{ $t('setting.versionHelper1') }}</li>
|
||||
<li class="line-height">{{ $t('setting.versionHelper2') }}</li>
|
||||
</el-alert>
|
||||
<div class="default-theme" style="margin-left: 20px">
|
||||
<h2 class="inline-block">{{ $t('app.version') }}</h2>
|
||||
@ -161,7 +161,7 @@ onMounted(() => {
|
||||
text-decoration: none;
|
||||
letter-spacing: 0.5px;
|
||||
}
|
||||
.line-heigth {
|
||||
.line-height {
|
||||
line-height: 25px;
|
||||
}
|
||||
.panel-MdEditor {
|
||||
|
@ -7,7 +7,7 @@ export enum CompressType {
|
||||
Xz = 'xz',
|
||||
}
|
||||
|
||||
export enum CompressExtention {
|
||||
export enum CompressExtension {
|
||||
zip = '.zip',
|
||||
gz = '.gz',
|
||||
bz2 = '.tar.bz2',
|
||||
|
@ -1084,7 +1084,7 @@ const message = {
|
||||
infoDetail: 'File Properties',
|
||||
list: 'File List',
|
||||
sub: 'Subdirectory',
|
||||
downlodSuccess: 'Download Success',
|
||||
downloadSuccess: 'Download Success',
|
||||
theme: 'Theme',
|
||||
language: 'Language',
|
||||
eol: 'End Of Line',
|
||||
@ -1099,7 +1099,7 @@ const message = {
|
||||
uploadFailed: '[{0}] File Upload file',
|
||||
fileUploadStart: 'Uploading [{0}]....',
|
||||
currentSelect: 'Current Select: ',
|
||||
unsupportType: 'Unsupported file type',
|
||||
unsupportedType: 'Unsupported file type',
|
||||
deleteHelper:
|
||||
'Are you sure you want to delete the following files? By default, it will enter the recycle bin after deletion',
|
||||
fileHeper: 'Note: 1. Search results do not support sorting. 2. Folders cannot be sorted by size.',
|
||||
|
@ -1032,7 +1032,7 @@ const message = {
|
||||
root: '根目錄',
|
||||
list: '文件列表',
|
||||
sub: '子目錄',
|
||||
downlodSuccess: '下載完成',
|
||||
downloadSuccess: '下載完成',
|
||||
theme: '主題',
|
||||
language: '語言',
|
||||
eol: '行尾符',
|
||||
@ -1046,7 +1046,7 @@ const message = {
|
||||
uploadFailed: '【{0}】 文件上傳失敗',
|
||||
fileUploadStart: '正在上傳【{0}】....',
|
||||
currentSelect: '當前選中: ',
|
||||
unsupportType: '不支持的文件類型',
|
||||
unsupportedType: '不支持的文件類型',
|
||||
deleteHelper: '確定刪除所選檔案? 預設刪除之後將進入回收站?',
|
||||
fileHeper: '注意:1. 搜尋結果不支援排序功能 2. 資料夾無法依大小排序。',
|
||||
forceDeleteHelper: '永久刪除檔案(不進入回收站,直接刪除)',
|
||||
|
@ -1033,7 +1033,7 @@ const message = {
|
||||
root: '根目录',
|
||||
list: '文件列表',
|
||||
sub: '子目录',
|
||||
downlodSuccess: '下载完成',
|
||||
downloadSuccess: '下载完成',
|
||||
theme: '主题',
|
||||
language: '语言',
|
||||
eol: '行尾符',
|
||||
@ -1047,7 +1047,7 @@ const message = {
|
||||
uploadFailed: '【{0}】 文件上传失败',
|
||||
fileUploadStart: '正在上传【{0}】....',
|
||||
currentSelect: '当前选中: ',
|
||||
unsupportType: '不支持的文件类型',
|
||||
unsupportedType: '不支持的文件类型',
|
||||
deleteHelper: '确定删除所选文件? 默认删除之后将进入回收站',
|
||||
fileHeper: '注意:1. 搜索结果不支持排序功能 2. 文件夹无法按大小排序。',
|
||||
forceDeleteHelper: '永久删除文件(不进入回收站,直接删除)',
|
||||
|
@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<div :class="classObj" class="app-wrapper" v-loading="loading" :element-loading-text="loadinText" fullscreen>
|
||||
<div :class="classObj" class="app-wrapper" v-loading="loading" :element-loading-text="loadingText" fullscreen>
|
||||
<div v-if="classObj.mobile && classObj.openSidebar" class="drawer-bg" @click="handleClickOutside" />
|
||||
<div class="app-sidebar" v-if="!globalStore.isFullScreen">
|
||||
<Sidebar />
|
||||
@ -31,7 +31,7 @@ const globalStore = GlobalStore();
|
||||
|
||||
const i18n = useI18n();
|
||||
const loading = ref(false);
|
||||
const loadinText = ref();
|
||||
const loadingText = ref();
|
||||
const themeConfig = computed(() => globalStore.themeConfig);
|
||||
const { switchDark } = useTheme();
|
||||
|
||||
@ -84,7 +84,7 @@ const updateDarkMode = async (event: MediaQueryListEvent) => {
|
||||
|
||||
const loadStatus = async () => {
|
||||
loading.value = globalStore.isLoading;
|
||||
loadinText.value = globalStore.loadingText;
|
||||
loadingText.value = globalStore.loadingText;
|
||||
if (loading.value) {
|
||||
timer = setInterval(async () => {
|
||||
await getSystemAvailable()
|
||||
|
@ -201,9 +201,9 @@ let icons = new Map([
|
||||
['.pdf', 'p-file-pdf'],
|
||||
]);
|
||||
|
||||
export function getIcon(extention: string): string {
|
||||
if (icons.get(extention) != undefined) {
|
||||
const icon = icons.get(extention);
|
||||
export function getIcon(extension: string): string {
|
||||
if (icons.get(extension) != undefined) {
|
||||
const icon = icons.get(extension);
|
||||
return String(icon);
|
||||
} else {
|
||||
return 'p-file-normal';
|
||||
|
@ -17,7 +17,7 @@
|
||||
</div>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-button type="primary" link @click="cancelIngore(app.detailID)">
|
||||
<el-button type="primary" link @click="cancelIgnore(app.detailID)">
|
||||
{{ $t('app.cancelIgnore') }}
|
||||
</el-button>
|
||||
</el-col>
|
||||
@ -61,7 +61,7 @@ const getApps = async () => {
|
||||
} catch (error) {}
|
||||
};
|
||||
|
||||
const cancelIngore = async (id: number) => {
|
||||
const cancelIgnore = async (id: number) => {
|
||||
loading.value = true;
|
||||
await IgnoreUpgrade({ detailID: id, operate: 'cancel' })
|
||||
.then(() => {
|
||||
|
@ -72,7 +72,7 @@
|
||||
<el-button @click="sync" type="primary" plain v-if="mode === 'installed' && data != null">
|
||||
{{ $t('app.sync') }}
|
||||
</el-button>
|
||||
<el-button @click="openIngore" type="primary" plain v-if="mode === 'upgrade'">
|
||||
<el-button @click="openIgnore" type="primary" plain v-if="mode === 'upgrade'">
|
||||
{{ $t('app.showIgnore') }}
|
||||
</el-button>
|
||||
</template>
|
||||
@ -458,7 +458,7 @@ const openOperate = (row: any, op: string) => {
|
||||
}
|
||||
};
|
||||
|
||||
const openIngore = () => {
|
||||
const openIgnore = () => {
|
||||
ignoreRef.value.acceptParams();
|
||||
};
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<div v-loading="loading">
|
||||
<div v-show="isOnDetail">
|
||||
<ComposeDetial @back="backList" ref="composeDetailRef" />
|
||||
<ComposeDetail @back="backList" ref="composeDetailRef" />
|
||||
</div>
|
||||
<el-card v-if="dockerStatus != 'Running'" class="mask-prompt">
|
||||
<span>{{ $t('container.serviceUnavailable') }}</span>
|
||||
@ -97,7 +97,7 @@ import { reactive, onMounted, ref } from 'vue';
|
||||
import EditDialog from '@/views/container/compose/edit/index.vue';
|
||||
import CreateDialog from '@/views/container/compose/create/index.vue';
|
||||
import DeleteDialog from '@/views/container/compose/delete/index.vue';
|
||||
import ComposeDetial from '@/views/container/compose/detail/index.vue';
|
||||
import ComposeDetail from '@/views/container/compose/detail/index.vue';
|
||||
import { loadContainerLog, loadDockerStatus, searchCompose } from '@/api/modules/container';
|
||||
import i18n from '@/lang';
|
||||
import { Container } from '@/api/interface/container';
|
||||
|
@ -93,7 +93,7 @@
|
||||
:row-style="{ height: '65px' }"
|
||||
style="width: 100%"
|
||||
:columns="columns"
|
||||
localKey="contanerColumn"
|
||||
localKey="containerColumn"
|
||||
>
|
||||
<el-table-column type="selection" />
|
||||
<el-table-column
|
||||
|
@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<el-drawer
|
||||
v-model="drawerVisiable"
|
||||
v-model="drawerVisible"
|
||||
:destroy-on-close="true"
|
||||
@close="handleClose"
|
||||
:close-on-click-modal="false"
|
||||
@ -58,7 +58,7 @@
|
||||
ref="logRef"
|
||||
:config="logConfig"
|
||||
:default-button="false"
|
||||
v-if="logVisiable"
|
||||
v-if="logVisible"
|
||||
:style="'height: calc(100vh - 370px);min-height: 200px'"
|
||||
/>
|
||||
</el-col>
|
||||
@ -66,7 +66,7 @@
|
||||
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button @click="drawerVisiable = false">{{ $t('commons.button.cancel') }}</el-button>
|
||||
<el-button @click="drawerVisible = false">{{ $t('commons.button.cancel') }}</el-button>
|
||||
<el-button :disabled="buttonDisabled" type="primary" @click="onSubmit(formRef)">
|
||||
{{ $t('commons.button.confirm') }}
|
||||
</el-button>
|
||||
@ -87,10 +87,10 @@ import { ElForm, ElMessage } from 'element-plus';
|
||||
import { imageBuild } from '@/api/modules/container';
|
||||
import DrawerHeader from '@/components/drawer-header/index.vue';
|
||||
|
||||
const logVisiable = ref<boolean>(false);
|
||||
const logVisible = ref<boolean>(false);
|
||||
const extensions = [javascript(), oneDark];
|
||||
const buttonDisabled = ref(false);
|
||||
const drawerVisiable = ref(false);
|
||||
const drawerVisible = ref(false);
|
||||
const logRef = ref();
|
||||
|
||||
const logConfig = reactive({
|
||||
@ -111,8 +111,8 @@ const rules = reactive({
|
||||
dockerfile: [Rules.requiredInput],
|
||||
});
|
||||
const acceptParams = async () => {
|
||||
logVisiable.value = false;
|
||||
drawerVisiable.value = true;
|
||||
logVisible.value = false;
|
||||
drawerVisible.value = true;
|
||||
form.from = 'path';
|
||||
form.dockerfile = '';
|
||||
form.tagStr = '';
|
||||
@ -122,7 +122,7 @@ const acceptParams = async () => {
|
||||
const emit = defineEmits<{ (e: 'search'): void }>();
|
||||
|
||||
const handleClose = () => {
|
||||
drawerVisiable.value = false;
|
||||
drawerVisible.value = false;
|
||||
emit('search');
|
||||
};
|
||||
|
||||
@ -145,9 +145,9 @@ const onSubmit = async (formEl: FormInstance | undefined) => {
|
||||
};
|
||||
|
||||
const loadLogs = () => {
|
||||
logVisiable.value = false;
|
||||
logVisible.value = false;
|
||||
nextTick(() => {
|
||||
logVisiable.value = true;
|
||||
logVisible.value = true;
|
||||
nextTick(() => {
|
||||
logRef.value.changeTail(true);
|
||||
});
|
||||
|
@ -18,10 +18,10 @@
|
||||
</el-form>
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button :disabeld="loading" @click="loadVisible = false">
|
||||
<el-button :disabled="loading" @click="loadVisible = false">
|
||||
{{ $t('commons.button.cancel') }}
|
||||
</el-button>
|
||||
<el-button :disabeld="loading" type="primary" @click="onSubmit(formRef)">
|
||||
<el-button :disabled="loading" type="primary" @click="onSubmit(formRef)">
|
||||
{{ $t('commons.button.import') }}
|
||||
</el-button>
|
||||
</span>
|
||||
|
@ -38,7 +38,7 @@
|
||||
ref="logRef"
|
||||
:config="logConfig"
|
||||
:default-button="false"
|
||||
v-if="logVisiable"
|
||||
v-if="logVisible"
|
||||
:style="'height: calc(100vh - 370px);min-height: 200px'"
|
||||
v-model:loading="loading"
|
||||
/>
|
||||
@ -76,7 +76,7 @@ const form = reactive({
|
||||
name: '',
|
||||
});
|
||||
|
||||
const logVisiable = ref(false);
|
||||
const logVisible = ref(false);
|
||||
const loading = ref(false);
|
||||
|
||||
const logRef = ref();
|
||||
@ -95,7 +95,7 @@ const dialogData = ref<DialogProps>({
|
||||
});
|
||||
|
||||
const acceptParams = async (params: DialogProps): Promise<void> => {
|
||||
logVisiable.value = false;
|
||||
logVisible.value = false;
|
||||
loading.value = false;
|
||||
drawerVisible.value = true;
|
||||
form.tags = params.tags;
|
||||
@ -114,7 +114,7 @@ const onSubmit = async (formEl: FormInstance | undefined) => {
|
||||
formEl.validate(async (valid) => {
|
||||
if (!valid) return;
|
||||
const res = await imagePush(form);
|
||||
logVisiable.value = true;
|
||||
logVisible.value = true;
|
||||
logConfig.name = res.data;
|
||||
loadLogs();
|
||||
MsgSuccess(i18n.global.t('commons.msg.operationSuccess'));
|
||||
@ -122,9 +122,9 @@ const onSubmit = async (formEl: FormInstance | undefined) => {
|
||||
};
|
||||
|
||||
const loadLogs = () => {
|
||||
logVisiable.value = false;
|
||||
logVisible.value = false;
|
||||
nextTick(() => {
|
||||
logVisiable.value = true;
|
||||
logVisible.value = true;
|
||||
nextTick(() => {
|
||||
logRef.value.changeTail(true);
|
||||
});
|
||||
|
@ -35,10 +35,10 @@
|
||||
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button :disabeld="loading" @click="drawerVisible = false">
|
||||
<el-button :disabled="loading" @click="drawerVisible = false">
|
||||
{{ $t('commons.button.cancel') }}
|
||||
</el-button>
|
||||
<el-button :disabeld="loading" type="primary" @click="onSubmit(formRef)">
|
||||
<el-button :disabled="loading" type="primary" @click="onSubmit(formRef)">
|
||||
{{ $t('container.export') }}
|
||||
</el-button>
|
||||
</span>
|
||||
|
@ -43,10 +43,10 @@
|
||||
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button :disabeld="loading" @click="drawerVisible = false">
|
||||
<el-button :disabled="loading" @click="drawerVisible = false">
|
||||
{{ $t('commons.button.cancel') }}
|
||||
</el-button>
|
||||
<el-button :disabeld="loading" type="primary" @click="onSubmit(formRef)">
|
||||
<el-button :disabled="loading" type="primary" @click="onSubmit(formRef)">
|
||||
{{ $t('commons.button.save') }}
|
||||
</el-button>
|
||||
</span>
|
||||
|
@ -414,7 +414,7 @@ const handleCgroup = async () => {
|
||||
confirmDialogRefCgroup.value!.acceptParams(params);
|
||||
};
|
||||
const onSubmitSaveCgroup = () => {
|
||||
save('Dirver', form.cgroupDriver);
|
||||
save('Driver', form.cgroupDriver);
|
||||
};
|
||||
|
||||
const save = async (key: string, value: string) => {
|
||||
|
@ -2,7 +2,7 @@
|
||||
<div v-if="statusShow" class="database-status">
|
||||
<el-form label-position="top">
|
||||
<span class="title">{{ $t('database.baseParam') }}</span>
|
||||
<el-divider class="devider" />
|
||||
<el-divider class="divider" />
|
||||
<el-row class="content">
|
||||
<el-col :xs="8" :sm="6" :md="6" :lg="6" :xl="6">
|
||||
<el-form-item>
|
||||
@ -34,7 +34,7 @@
|
||||
</el-row>
|
||||
|
||||
<span class="title">{{ $t('database.performanceParam') }}</span>
|
||||
<el-divider class="devider" />
|
||||
<el-divider class="divider" />
|
||||
<el-row class="content">
|
||||
<el-col :xs="12" :sm="12" :md="6" :lg="6" :xl="6">
|
||||
<el-form-item>
|
||||
@ -203,7 +203,7 @@ defineExpose({
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.database-status {
|
||||
.devider {
|
||||
.divider {
|
||||
display: block;
|
||||
height: 1px;
|
||||
width: 100%;
|
||||
|
@ -57,7 +57,7 @@ import { computed, reactive, ref } from 'vue';
|
||||
import { File } from '@/api/interface/file';
|
||||
import { FormInstance, FormRules } from 'element-plus';
|
||||
import { Rules } from '@/global/form-rules';
|
||||
import { CompressExtention, CompressType } from '@/enums/files';
|
||||
import { CompressExtension, CompressType } from '@/enums/files';
|
||||
import { CompressFile } from '@/api/modules/files';
|
||||
import FileList from '@/components/file-list/index.vue';
|
||||
import DrawerHeader from '@/components/drawer-header/index.vue';
|
||||
@ -87,7 +87,7 @@ const operate = ref('compress');
|
||||
const em = defineEmits(['close']);
|
||||
|
||||
const extension = computed(() => {
|
||||
return CompressExtention[form.value.type];
|
||||
return CompressExtension[form.value.type];
|
||||
});
|
||||
|
||||
const handleClose = () => {
|
||||
|
@ -37,7 +37,7 @@
|
||||
|
||||
<script setup lang="ts">
|
||||
import { FormInstance, FormRules } from 'element-plus';
|
||||
import { CompressExtention, CompressType } from '@/enums/files';
|
||||
import { CompressExtension, CompressType } from '@/enums/files';
|
||||
import { computed, reactive, ref } from 'vue';
|
||||
import { DownloadFile } from '@/api/modules/files';
|
||||
import { File } from '@/api/interface/file';
|
||||
@ -76,7 +76,7 @@ let addForm = ref({
|
||||
});
|
||||
|
||||
const extension = computed(() => {
|
||||
return CompressExtention[addForm.value.type];
|
||||
return CompressExtension[addForm.value.type];
|
||||
});
|
||||
|
||||
const submit = async (formEl: FormInstance | undefined) => {
|
||||
|
@ -541,10 +541,10 @@ const getPaths = (reqPath: string) => {
|
||||
}
|
||||
};
|
||||
|
||||
const handleCreate = (commnad: string) => {
|
||||
const handleCreate = (command: string) => {
|
||||
fileCreate.path = req.path;
|
||||
fileCreate.isDir = false;
|
||||
if (commnad === 'dir') {
|
||||
if (command === 'dir') {
|
||||
fileCreate.isDir = true;
|
||||
}
|
||||
createRef.value.acceptParams(fileCreate);
|
||||
|
@ -7,7 +7,7 @@
|
||||
:title="$t('file.downloadProcess')"
|
||||
>
|
||||
<div v-for="(value, index) in res" :key="index">
|
||||
<span>{{ value['percent'] === 100 ? $t('file.downlodSuccess') : $t('file.downloading') }}</span>
|
||||
<span>{{ value['percent'] === 100 ? $t('file.downloadSuccess') : $t('file.downloading') }}</span>
|
||||
<MsgInfo :info="value['name']" width="250" />
|
||||
<el-progress v-if="value['total'] == 0" :percentage="100" :indeterminate="true" :duration="1" />
|
||||
<el-progress v-else :text-inside="true" :stroke-width="15" :percentage="value['percent']"></el-progress>
|
||||
|
@ -46,7 +46,7 @@
|
||||
>
|
||||
<template #tip>
|
||||
<el-text>{{ uploadHelper }}</el-text>
|
||||
<el-progress v-if="loading" text-inside :stroke-width="20" :percentage="uploadPrecent"></el-progress>
|
||||
<el-progress v-if="loading" text-inside :stroke-width="20" :percentage="uploadPercent"></el-progress>
|
||||
</template>
|
||||
</el-upload>
|
||||
|
||||
@ -103,7 +103,7 @@ interface UploadFileProps {
|
||||
|
||||
const uploadRef = ref<UploadInstance>();
|
||||
const loading = ref(false);
|
||||
let uploadPrecent = ref(0);
|
||||
let uploadPercent = ref(0);
|
||||
const open = ref(false);
|
||||
const path = ref();
|
||||
let uploadHelper = ref('');
|
||||
@ -124,9 +124,9 @@ const uploadType = ref('file');
|
||||
const tmpFiles = ref<UploadFiles>([]);
|
||||
const breakFlag = ref(false);
|
||||
|
||||
const upload = (commnad: string) => {
|
||||
uploadType.value = commnad;
|
||||
if (commnad == 'dir') {
|
||||
const upload = (command: string) => {
|
||||
uploadType.value = command;
|
||||
if (command == 'dir') {
|
||||
state.uploadEle.webkitdirectory = true;
|
||||
} else {
|
||||
state.uploadEle.webkitdirectory = false;
|
||||
@ -281,11 +281,11 @@ const submit = async () => {
|
||||
} else {
|
||||
formData.append('path', path.value + '/' + getPathWithoutFilename(file.name));
|
||||
}
|
||||
uploadPrecent.value = 0;
|
||||
uploadPercent.value = 0;
|
||||
await UploadFileData(formData, {
|
||||
onUploadProgress: (progressEvent) => {
|
||||
const progress = Math.round((progressEvent.loaded / progressEvent.total) * 100);
|
||||
uploadPrecent.value = progress;
|
||||
uploadPercent.value = progress;
|
||||
},
|
||||
timeout: 40000,
|
||||
});
|
||||
@ -317,7 +317,7 @@ const submit = async () => {
|
||||
const progress = Math.round(
|
||||
((uploadedChunkCount + progressEvent.loaded / progressEvent.total) * 100) / chunkCount,
|
||||
);
|
||||
uploadPrecent.value = progress;
|
||||
uploadPercent.value = progress;
|
||||
},
|
||||
timeout: TimeoutEnum.T_60S,
|
||||
});
|
||||
@ -353,7 +353,7 @@ const getPathWithoutFilename = (path: string) => {
|
||||
const acceptParams = (props: UploadFileProps) => {
|
||||
path.value = props.path;
|
||||
open.value = true;
|
||||
uploadPrecent.value = 0;
|
||||
uploadPercent.value = 0;
|
||||
uploadHelper.value = '';
|
||||
|
||||
nextTick(() => {
|
||||
|
@ -11,7 +11,7 @@
|
||||
<el-col :span="8">
|
||||
<div class="search-button">
|
||||
<el-input
|
||||
typpe="number"
|
||||
type="number"
|
||||
v-model.number="netSearch.processID"
|
||||
clearable
|
||||
@clear="search()"
|
||||
|
@ -128,7 +128,7 @@ function checkDriveCode(rule: any, value: any, callback: any) {
|
||||
}
|
||||
|
||||
const emit = defineEmits(['search']);
|
||||
const ondDriveInfo = ref();
|
||||
const oneDriveInfo = ref();
|
||||
|
||||
interface DialogProps {
|
||||
title: string;
|
||||
@ -145,7 +145,7 @@ const acceptParams = async (params: DialogProps): Promise<void> => {
|
||||
title.value = i18n.global.t('commons.button.' + oneDriveData.value.title);
|
||||
drawerVisible.value = true;
|
||||
const res = await getOneDriveInfo();
|
||||
ondDriveInfo.value = res.data;
|
||||
oneDriveInfo.value = res.data;
|
||||
if (!oneDriveData.value.rowData.id) {
|
||||
oneDriveData.value.rowData.varsJson = {
|
||||
isCN: false,
|
||||
@ -167,9 +167,9 @@ const changeFrom = () => {
|
||||
} else {
|
||||
oneDriveData.value.rowData.varsJson = {
|
||||
isCN: false,
|
||||
client_id: ondDriveInfo.value.client_id,
|
||||
client_secret: ondDriveInfo.value.client_secret,
|
||||
redirect_uri: ondDriveInfo.value.redirect_uri,
|
||||
client_id: oneDriveInfo.value.client_id,
|
||||
client_secret: oneDriveInfo.value.client_secret,
|
||||
redirect_uri: oneDriveInfo.value.redirect_uri,
|
||||
};
|
||||
}
|
||||
};
|
||||
|
@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<el-tabs tab-position="left" v-model="tabIndex">
|
||||
<el-tab-pane :label="$t('website.domainConfig')">
|
||||
<Doamin :key="id" :id="id" v-if="tabIndex == '0' && id > 0"></Doamin>
|
||||
<Domain :key="id" :id="id" v-if="tabIndex == '0' && id > 0"></Domain>
|
||||
</el-tab-pane>
|
||||
<el-tab-pane :label="$t('website.sitePath')">
|
||||
<SitePath :id="id" v-if="tabIndex == '1'"></SitePath>
|
||||
@ -39,7 +39,7 @@
|
||||
<script lang="ts" setup name="Basic">
|
||||
import { computed, onMounted, ref } from 'vue';
|
||||
|
||||
import Doamin from './domain/index.vue';
|
||||
import Domain from './domain/index.vue';
|
||||
import Default from './default-doc/index.vue';
|
||||
import LimitConn from './limit-conn/index.vue';
|
||||
import Other from './other/index.vue';
|
||||
|
@ -96,7 +96,7 @@ const enableUpdate = ref<Website.WafUpdate>({
|
||||
let add = ref({
|
||||
value: '',
|
||||
remark: '',
|
||||
enbale: 1,
|
||||
enable: 1,
|
||||
});
|
||||
let contentArray = ref([]);
|
||||
|
||||
@ -132,7 +132,7 @@ const openCreate = () => {
|
||||
let newArray = [];
|
||||
newArray[0] = add.value.value;
|
||||
newArray[1] = add.value.remark;
|
||||
newArray[2] = add.value.enbale;
|
||||
newArray[2] = add.value.enable;
|
||||
|
||||
data.value.push(newArray);
|
||||
submit(newArray);
|
||||
@ -161,7 +161,7 @@ const submit = async (addArray: string[]) => {
|
||||
add.value = {
|
||||
value: '',
|
||||
remark: '',
|
||||
enbale: 1,
|
||||
enable: 1,
|
||||
};
|
||||
MsgSuccess(i18n.global.t('commons.msg.updateSuccess'));
|
||||
get();
|
||||
|
@ -104,7 +104,7 @@
|
||||
>
|
||||
<el-select v-model="website.appInstallId">
|
||||
<el-option
|
||||
v-for="(appInstall, index) in appInstalles"
|
||||
v-for="(appInstall, index) in appInstalls"
|
||||
:key="index"
|
||||
:label="appInstall.name"
|
||||
:value="appInstall.id"
|
||||
@ -410,7 +410,7 @@ const open = ref(false);
|
||||
const loading = ref(false);
|
||||
const groups = ref<Group.GroupInfo[]>([]);
|
||||
|
||||
const appInstalles = ref<App.AppInstalled[]>([]);
|
||||
const appInstalls = ref<App.AppInstalled[]>([]);
|
||||
const appReq = reactive({
|
||||
type: 'website',
|
||||
page: 1,
|
||||
@ -442,8 +442,8 @@ const changeType = (type: string) => {
|
||||
switch (type) {
|
||||
case 'deployment':
|
||||
website.value.appType = 'installed';
|
||||
if (appInstalles.value && appInstalles.value.length > 0) {
|
||||
website.value.appInstallId = appInstalles.value[0].id;
|
||||
if (appInstalls.value && appInstalls.value.length > 0) {
|
||||
website.value.appInstallId = appInstalls.value[0].id;
|
||||
}
|
||||
break;
|
||||
case 'runtime':
|
||||
@ -459,7 +459,7 @@ const changeType = (type: string) => {
|
||||
|
||||
const searchAppInstalled = () => {
|
||||
GetAppInstalled({ type: 'website', unused: true, all: true, page: 1, pageSize: 100 }).then((res) => {
|
||||
appInstalles.value = res.data;
|
||||
appInstalls.value = res.data;
|
||||
if (res.data && res.data.length > 0) {
|
||||
website.value.appInstallId = res.data[0].id;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user