mirror of
https://github.com/1Panel-dev/1Panel.git
synced 2025-02-19 14:58:09 +08:00
feat: Improve the name of the professional version (#7855)
This commit is contained in:
parent
9a73537dfb
commit
ab03d5e40e
@ -219,6 +219,7 @@ export namespace Setting {
|
||||
licenseName: string;
|
||||
assigneeName: string;
|
||||
productPro: string;
|
||||
versionConstraint: string;
|
||||
trial: boolean;
|
||||
status: string;
|
||||
message: string;
|
||||
|
@ -16,15 +16,15 @@
|
||||
<el-divider direction="vertical" />
|
||||
</div>
|
||||
<div class="flex flex-wrap items-center">
|
||||
<el-link :underline="false" type="primary" @click="toLxware">
|
||||
<el-link :underline="false" class="-ml-2" type="primary" @click="toLxware">
|
||||
{{ $t(!isMasterProductPro ? 'license.community' : 'license.pro') }}
|
||||
</el-link>
|
||||
<el-link :underline="false" class="version" type="primary" @click="copyText(version)">
|
||||
{{ version }}
|
||||
</el-link>
|
||||
<el-badge is-dot class="-mt-0.5" v-if="version !== 'Waiting' && globalStore.hasNewVersion">
|
||||
<el-link :underline="false" type="primary" @click="onLoadUpgradeInfo">
|
||||
({{ $t('setting.hasNewVersion') }})
|
||||
<el-link class="ml-2" :underline="false" type="primary" @click="onLoadUpgradeInfo">
|
||||
{{ $t('commons.button.update') }}
|
||||
</el-link>
|
||||
</el-badge>
|
||||
<el-link
|
||||
@ -33,7 +33,7 @@
|
||||
:underline="false"
|
||||
@click="onLoadUpgradeInfo"
|
||||
>
|
||||
({{ $t('setting.upgradeCheck') }})
|
||||
{{ $t('commons.button.update') }}
|
||||
</el-link>
|
||||
<el-tag v-if="version === 'Waiting'" round style="margin-left: 10px">
|
||||
{{ $t('setting.upgrading') }}
|
||||
@ -136,10 +136,19 @@ onMounted(() => {
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.line-height {
|
||||
line-height: 25px;
|
||||
}
|
||||
:deep(.el-link__inner) {
|
||||
font-weight: 400;
|
||||
}
|
||||
.version {
|
||||
margin-left: 8px;
|
||||
font-size: 14px;
|
||||
color: var(--panel-color-primary-light-4);
|
||||
text-decoration: none;
|
||||
letter-spacing: 0.5px;
|
||||
cursor: pointer;
|
||||
font-family: auto;
|
||||
}
|
||||
</style>
|
||||
|
@ -114,9 +114,6 @@ defineExpose({
|
||||
font-size: 16px;
|
||||
}
|
||||
}
|
||||
:deep(.el-link__inner) {
|
||||
font-weight: 400;
|
||||
}
|
||||
:deep(.md-editor-dark) {
|
||||
background-color: var(--panel-main-bg-color-9);
|
||||
}
|
||||
|
@ -52,7 +52,7 @@ const message = {
|
||||
refresh: 'Refresh',
|
||||
get: 'Get',
|
||||
upgrade: 'Upgrade',
|
||||
update: 'update',
|
||||
update: 'Update',
|
||||
ignore: 'Ignore upgrade',
|
||||
copy: 'Copy',
|
||||
random: 'Random',
|
||||
@ -1763,20 +1763,18 @@ const message = {
|
||||
backupRecoverMessage: 'Please enter the compression or decompression password (leave blank to not set)',
|
||||
},
|
||||
license: {
|
||||
community: 'Community Edition: ',
|
||||
community2: 'Community Edition',
|
||||
pro: 'Professional Edition: ',
|
||||
xpack: 'Professional Edition',
|
||||
trial: 'Trial Version',
|
||||
community: 'OSS',
|
||||
oss: 'Open Source Software',
|
||||
pro: 'Pro',
|
||||
trial: 'Trial',
|
||||
subscription: 'Subscription',
|
||||
perpetual: 'Perpetual',
|
||||
versionConstraint: '{0} Version Buyout',
|
||||
forceDelete: 'Force delete, will ignore errors during the deletion process and eventually remove metadata',
|
||||
deleteHelper: 'Deleting the license may cause child nodes to be unable to switch, please proceed with caution!',
|
||||
office: 'Official Version',
|
||||
trialInfo: 'Version',
|
||||
authorizationId: 'Subscription Authorization ID',
|
||||
authorizationId: 'Authorization ID',
|
||||
authorizedUser: 'Authorized User',
|
||||
expiresAt: 'Expiration Date',
|
||||
productName: 'Product Name',
|
||||
productStatus: 'Product Status',
|
||||
lostHelper:
|
||||
'The license has reached the maximum number of retry attempts. Please manually click the sync button to ensure the professional version functions properly. detail: ',
|
||||
exceptionalHelper:
|
||||
@ -1788,7 +1786,6 @@ const message = {
|
||||
'There are currently other nodes besides the master node. The {0} operation is not supported. Please delete the nodes in the node management and try again.',
|
||||
importLicense: 'Import License',
|
||||
importHelper: 'Please click or drag the license file here',
|
||||
indefinitePeriod: 'Indefinite Period',
|
||||
levelUpPro: 'Upgrade to Professional Edition',
|
||||
licenseSync: 'License Sync',
|
||||
knowMorePro: 'Learn More',
|
||||
|
@ -1630,17 +1630,13 @@ const message = {
|
||||
community: '無料',
|
||||
oss: '無料',
|
||||
pro: '専門',
|
||||
trial: 'トライアル',
|
||||
office: '正式',
|
||||
trial: '体験',
|
||||
subscription: 'サブスクリプション',
|
||||
perpetual: '永久ライセンス',
|
||||
versionConstraint: '{0} バージョン買い取り',
|
||||
trialInfo: 'バージョン',
|
||||
authorizationId: 'サブスクリプション承認ID',
|
||||
authorizedUser: '認定ユーザー',
|
||||
expiresAt: '有効期限',
|
||||
productName: '製品名',
|
||||
productStatus: '製品ステータス',
|
||||
Lost: '失った',
|
||||
Enable: '有効になっています',
|
||||
Disable: '無効',
|
||||
lostHelper:
|
||||
'ライセンスは、再試行の最大数に達しました。プロのバージョン機能が適切に機能していることを確認するには、手動で同期ボタンをクリックしてください。세부사항: ',
|
||||
disableHelper:
|
||||
@ -1652,7 +1648,6 @@ const message = {
|
||||
importHelper: 'ここでライセンスファイルをクリックまたはドラッグしてください',
|
||||
technicalAdvice: '技術的な相談',
|
||||
advice: '相談',
|
||||
indefinitePeriod: '無期限',
|
||||
levelUpPro: 'Proにアップグレードします',
|
||||
licenseSync: 'ライセンス同期',
|
||||
knowMorePro: 'もっと詳しく知る',
|
||||
|
@ -1604,16 +1604,12 @@ const message = {
|
||||
oss: '오픈 소스 소프트웨어',
|
||||
pro: 'Pro',
|
||||
trial: '체험판',
|
||||
office: '공식',
|
||||
subscription: '구독',
|
||||
perpetual: '영구 라이선스',
|
||||
versionConstraint: '{0} 버전 일시불 구매',
|
||||
trialInfo: '버전',
|
||||
authorizationId: '구독 인증 ID',
|
||||
authorizedUser: '인증된 사용자',
|
||||
expiresAt: '만료일',
|
||||
productName: '제품명',
|
||||
productStatus: '제품 상태',
|
||||
Lost: '분실',
|
||||
Enable: '활성화됨',
|
||||
Disable: '비활성화됨',
|
||||
lostHelper:
|
||||
'라이센스가 최대 재시도 횟수를 초과했습니다. 전문가 버전 기능이 제대로 작동하는지 확인하려면 동기화 버튼을 수동으로 클릭하세요.',
|
||||
disableHelper:
|
||||
@ -1625,7 +1621,6 @@ const message = {
|
||||
importHelper: '라이센스 파일을 여기에 클릭하거나 드래그하세요',
|
||||
technicalAdvice: '기술 상담',
|
||||
advice: '상담',
|
||||
indefinitePeriod: '무제한 기간',
|
||||
levelUpPro: 'Pro 로 업그레이드',
|
||||
licenseSync: '라이센스 동기화',
|
||||
knowMorePro: '더 알아보기',
|
||||
|
@ -1687,16 +1687,12 @@ const message = {
|
||||
oss: 'Perisian Sumber Terbuka',
|
||||
pro: 'Pro',
|
||||
trial: 'Percubaan',
|
||||
office: 'Rasmi',
|
||||
subscription: 'Langganan',
|
||||
perpetual: 'Lesen Perpetual',
|
||||
versionConstraint: '{0} Pembelian versi',
|
||||
trialInfo: 'Versi',
|
||||
authorizationId: 'ID Kebenaran Langganan',
|
||||
authorizedUser: 'Pengguna yang Dibenarkan',
|
||||
expiresAt: 'Tarikh Tamat Tempoh',
|
||||
productName: 'Nama Produk',
|
||||
productStatus: 'Status Produk',
|
||||
Lost: 'Hilang',
|
||||
Enable: 'Diaktifkan',
|
||||
Disable: 'Dilumpuhkan',
|
||||
lostHelper:
|
||||
'Lesen telah mencapai jumlah percubaan semula maksimum. Sila klik butang penyegerakan secara manual untuk memastikan ciri versi profesional berfungsi dengan baik. butiran: ',
|
||||
disableHelper:
|
||||
@ -1708,7 +1704,6 @@ const message = {
|
||||
importHelper: 'Sila klik atau seret fail lesen ke sini',
|
||||
technicalAdvice: 'Konsultasi Teknikal',
|
||||
advice: 'Konsultasi',
|
||||
indefinitePeriod: 'Tempoh Tidak Terhad',
|
||||
levelUpPro: 'Tingkatkan ke Pro',
|
||||
licenseSync: 'Penyegerakan Lesen',
|
||||
knowMorePro: 'Ketahui Lebih Lanjut',
|
||||
|
@ -1671,18 +1671,15 @@ const message = {
|
||||
},
|
||||
license: {
|
||||
community: 'Gratuito',
|
||||
oss: 'Open Source Software',
|
||||
pro: 'Pro',
|
||||
trial: 'Teste',
|
||||
office: 'Oficial',
|
||||
subscription: 'Assinatura',
|
||||
perpetual: 'Licença Perpétua',
|
||||
versionConstraint: '{0} Compra do versão',
|
||||
trialInfo: 'Versão',
|
||||
authorizationId: 'ID de autorização de assinatura',
|
||||
authorizationId: 'ID de autorização',
|
||||
authorizedUser: 'Usuário autorizado',
|
||||
expiresAt: 'Data de expiração',
|
||||
productName: 'Nome do Produto',
|
||||
productStatus: 'Status do Produto',
|
||||
Lost: 'Perdido',
|
||||
Enable: 'Habilitado',
|
||||
Disable: 'Desabilitado',
|
||||
lostHelper:
|
||||
'A licença atingiu o número máximo de tentativas de reenvio. Por favor, clique manualmente no botão de sincronização para garantir que os recursos da versão profissional estão funcionando corretamente. detalhes: ',
|
||||
disableHelper:
|
||||
@ -1695,7 +1692,6 @@ const message = {
|
||||
importHelper: 'Clique ou arraste o arquivo de licença aqui',
|
||||
technicalAdvice: 'Consultoria técnica',
|
||||
advice: 'Consultoria',
|
||||
indefinitePeriod: 'Período Indefinido',
|
||||
levelUpPro: 'Upgrade para Pro',
|
||||
licenseSync: 'Sincronização de Licença',
|
||||
knowMorePro: 'Saiba mais',
|
||||
|
@ -1670,17 +1670,13 @@ const message = {
|
||||
community: 'OSS',
|
||||
oss: 'Open Source Software',
|
||||
pro: 'Pro',
|
||||
trial: 'Trial',
|
||||
office: 'Official',
|
||||
trial: 'Пробная версия',
|
||||
subscription: 'Подписка',
|
||||
perpetual: 'Пожизненная лицензия',
|
||||
versionConstraint: '{0} Выкуп версии',
|
||||
trialInfo: 'Версия',
|
||||
authorizationId: 'ID авторизации подписки',
|
||||
authorizedUser: 'Авторизованный пользователь',
|
||||
expiresAt: 'Дата истечения',
|
||||
productName: 'Название продукта',
|
||||
productStatus: 'Статус продукта',
|
||||
Lost: 'Потеряна',
|
||||
Enable: 'Включена',
|
||||
Disable: 'Отключена',
|
||||
lostHelper:
|
||||
'Лицензия достигла максимального количества попыток повторной проверки. Пожалуйста, вручную нажмите кнопку синхронизации, чтобы убедиться, что функции профессиональной версии работают правильно. Детали: ',
|
||||
disableHelper:
|
||||
@ -1692,7 +1688,6 @@ const message = {
|
||||
importHelper: 'Пожалуйста, нажмите или перетащите файл лицензии сюда',
|
||||
technicalAdvice: 'Техническая консультация',
|
||||
advice: 'Консультация',
|
||||
indefinitePeriod: 'Бессрочный период',
|
||||
levelUpPro: 'Обновить до Pro',
|
||||
licenseSync: 'Синхронизация лицензии',
|
||||
knowMorePro: 'Узнать больше',
|
||||
|
@ -52,7 +52,7 @@ const message = {
|
||||
refresh: '刷新',
|
||||
get: '獲取',
|
||||
upgrade: '升級',
|
||||
update: '編輯',
|
||||
update: '更新',
|
||||
ignore: '忽略升級',
|
||||
install: '安裝',
|
||||
copy: '復製',
|
||||
@ -1656,20 +1656,18 @@ const message = {
|
||||
backupRecoverMessage: '請輸入壓縮或解壓縮密碼(留空則不設定)',
|
||||
},
|
||||
license: {
|
||||
community: '社區版:',
|
||||
community2: '社區版',
|
||||
community: '社區版',
|
||||
oss: '社區版',
|
||||
pro: '專業版:',
|
||||
xpack: '專業版',
|
||||
trial: '試用版',
|
||||
trial: '試用',
|
||||
subscription: '訂閱',
|
||||
perpetual: '永久授權',
|
||||
versionConstraint: '{0} 版本買斷',
|
||||
forceDelete: '強制刪除,會忽略刪除過程中產生的錯誤並最終刪除元數據',
|
||||
deleteHelper: '刪除許可證可能導致子節點無法切換,請謹慎操作!',
|
||||
office: '正式版',
|
||||
trialInfo: '版本',
|
||||
authorizationId: '訂閱授權 ID',
|
||||
authorizedUser: '被授權方',
|
||||
expiresAt: '到期時間',
|
||||
productName: '產品名稱',
|
||||
productStatus: '產品狀態',
|
||||
lostHelper: '許可證已達到最大重試次數,請手動點擊同步按鈕,以確保專業版功能正常使用,詳情:',
|
||||
exceptionalHelper: '許可證同步驗證異常,請手動點擊同步按鈕,以確保專業版功能正常使用,詳情:',
|
||||
quickUpdate: '快速更新',
|
||||
@ -1678,7 +1676,6 @@ const message = {
|
||||
unbindMasterHelper: '當前已存在除主節點外其他節點,不支持 {0} 操作,請在節點管理中刪除節點後重試',
|
||||
importLicense: '導入許可證',
|
||||
importHelper: '請點擊或拖動許可文件到此處',
|
||||
indefinitePeriod: '無期限',
|
||||
levelUpPro: '升級專業版',
|
||||
licenseSync: '許可證同步',
|
||||
knowMorePro: '了解更多',
|
||||
|
@ -1624,20 +1624,18 @@ const message = {
|
||||
backupRecoverMessage: '请输入压缩或解压缩密码(留空则不设置)',
|
||||
},
|
||||
license: {
|
||||
community: '社区版:',
|
||||
community2: '社区版',
|
||||
pro: '专业版:',
|
||||
xpack: '专业版',
|
||||
trial: '试用版',
|
||||
community: '社区版',
|
||||
oss: '社区版',
|
||||
pro: '专业版',
|
||||
trial: '试用',
|
||||
subscription: '订阅',
|
||||
perpetual: '永久授权',
|
||||
versionConstraint: '{0} 版本买断',
|
||||
forceDelete: '强制删除,会忽略删除过程中产生的错误并最终删除元数据',
|
||||
deleteHelper: '删除许可证可能导致子节点无法切换,请谨慎操作!',
|
||||
office: '正式版',
|
||||
trialInfo: '版本',
|
||||
authorizationId: '订阅授权 ID',
|
||||
authorizedUser: '被授权方',
|
||||
expiresAt: '到期时间',
|
||||
productName: '产品名称',
|
||||
productStatus: '产品状态',
|
||||
lostHelper: '许可证已达到最大重试次数,请手动点击同步按钮,以确保专业版功能正常使用,详情:',
|
||||
exceptionalHelper: '许可证同步验证异常,请手动点击同步按钮,以确保专业版功能正常使用,详情:',
|
||||
quickUpdate: '快速更新',
|
||||
@ -1646,7 +1644,6 @@ const message = {
|
||||
unbindMasterHelper: '当前已存在除主节点外其他节点,不支持 {0} 操作,请在节点管理中删除节点后重试',
|
||||
importLicense: '导入许可证',
|
||||
importHelper: '请点击或拖动许可文件到此处',
|
||||
indefinitePeriod: '无限期',
|
||||
levelUpPro: '升级专业版',
|
||||
licenseSync: '许可证同步',
|
||||
knowMorePro: '了解更多',
|
||||
|
@ -40,7 +40,7 @@
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { getSettingInfo, getSystemAvailable } from '@/api/modules/setting';
|
||||
import { getSystemAvailable } from '@/api/modules/setting';
|
||||
import { onMounted, ref } from 'vue';
|
||||
import SystemUpgrade from '@/components/system-upgrade/index.vue';
|
||||
import { GlobalStore } from '@/store';
|
||||
@ -48,13 +48,7 @@ import PrimaryLogo from '@/assets/images/1panel-logo.svg?component';
|
||||
import { storeToRefs } from 'pinia';
|
||||
const globalStore = GlobalStore();
|
||||
const { docsUrl } = storeToRefs(globalStore);
|
||||
|
||||
const version = ref();
|
||||
const loading = ref();
|
||||
const search = async () => {
|
||||
const res = await getSettingInfo();
|
||||
version.value = res.data.systemVersion;
|
||||
};
|
||||
|
||||
const toDoc = () => {
|
||||
window.open(docsUrl.value, '_blank', 'noopener,noreferrer');
|
||||
@ -70,7 +64,6 @@ const toGithubStar = () => {
|
||||
};
|
||||
|
||||
onMounted(() => {
|
||||
search();
|
||||
getSystemAvailable();
|
||||
});
|
||||
</script>
|
||||
|
@ -6,6 +6,10 @@
|
||||
{{ $t('commons.button.add') }}
|
||||
</el-button>
|
||||
</template>
|
||||
<template #rightToolBar>
|
||||
<TableRefresh @search="search()" />
|
||||
<TableSetting title="backup-account-refresh" @search="search()" />
|
||||
</template>
|
||||
<template #main>
|
||||
<ComplexTable :pagination-config="paginationConfig" @sort-change="search" @search="search" :data="data">
|
||||
<el-table-column
|
||||
@ -19,9 +23,9 @@
|
||||
{{ row.assigneeName || '-' }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column :label="$t('license.expiresAt')" prop="expiresAt" show-overflow-tooltip>
|
||||
<el-table-column :label="$t('license.trialInfo')" show-overflow-tooltip :min-width="120">
|
||||
<template #default="{ row }">
|
||||
{{ row.expiresAt || '-' }}
|
||||
{{ loadVersion(row) }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column :label="$t('commons.table.status')" prop="status" show-overflow-tooltip>
|
||||
@ -171,10 +175,7 @@ const search = async () => {
|
||||
data.value = res.data.items || [];
|
||||
for (const item of data.value) {
|
||||
item.productName = 'product-1panel-pro';
|
||||
item.expiresAt =
|
||||
item.productPro === '0'
|
||||
? i18n.global.t('license.indefinitePeriod')
|
||||
: timestampToDate(Number(item.productPro));
|
||||
item.expiresAt = item.productPro === '0' ? '' : timestampToDate(Number(item.productPro));
|
||||
}
|
||||
paginationConfig.total = res.data.total;
|
||||
})
|
||||
@ -203,6 +204,19 @@ const toUpload = () => {
|
||||
licenseRef.value.acceptParams();
|
||||
};
|
||||
|
||||
const loadVersion = (row: any) => {
|
||||
if (row.trial === 'yes') {
|
||||
return i18n.global.t('license.trial');
|
||||
}
|
||||
if (row.productPro && row.productPro !== '0') {
|
||||
return i18n.global.t('license.subscription') + ' [ ' + row.expiresAt + ' ] ';
|
||||
}
|
||||
if (row.versionConstraint !== 'all') {
|
||||
return i18n.global.t('license.versionConstraint', ['v' + row.versionConstraint.replace('.x', '')]);
|
||||
}
|
||||
return i18n.global.t('license.perpetual');
|
||||
};
|
||||
|
||||
const buttons = [
|
||||
{
|
||||
label: i18n.global.t('commons.button.bind'),
|
||||
@ -255,11 +269,9 @@ const buttons = [
|
||||
{
|
||||
label: i18n.global.t('commons.button.delete'),
|
||||
click: (row: any) => {
|
||||
for (const item of data.value) {
|
||||
if (item.bindNode && row.freeCount != 0) {
|
||||
MsgError(i18n.global.t('license.unbindMasterHelper', [i18n.global.t('commons.button.delete')]));
|
||||
return;
|
||||
}
|
||||
if (row.freeNodes && row.freeCount != 0) {
|
||||
MsgError(i18n.global.t('license.unbindMasterHelper', [i18n.global.t('commons.button.delete')]));
|
||||
return;
|
||||
}
|
||||
delRef.value.acceptParams({ id: row.id, name: row.licenseName });
|
||||
},
|
||||
|
Loading…
x
Reference in New Issue
Block a user