mirror of
https://github.com/jumpserver/lina.git
synced 2026-01-29 21:28:52 +00:00
feat: 支持COS对象存储
This commit is contained in:
@@ -48,3 +48,16 @@ export const STORAGE_TYPE_META_MAP = {
|
||||
endpointHelpText: i18n.t('sessions.helpText.s3Endpoint')
|
||||
}
|
||||
}
|
||||
|
||||
export function getReplayStorageOptions() {
|
||||
const options = []
|
||||
const storages = Object.values(STORAGE_TYPE_META_MAP)
|
||||
for (const s of storages) {
|
||||
const option = {
|
||||
name: s.name,
|
||||
title: s.title
|
||||
}
|
||||
options.push(option)
|
||||
}
|
||||
return options
|
||||
}
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
<script>
|
||||
import ListTable from '@/components/ListTable'
|
||||
import { TestReplayStorage, SetToDefaultReplayStorage } from '@/api/sessions'
|
||||
import { getReplayStorageOptions } from '@/views/sessions/const'
|
||||
export default {
|
||||
name: 'ReplayStorage',
|
||||
components: {
|
||||
@@ -11,6 +12,7 @@ export default {
|
||||
},
|
||||
data() {
|
||||
const vm = this
|
||||
const storageOptions = getReplayStorageOptions()
|
||||
return {
|
||||
replayActions: {
|
||||
hasExport: false,
|
||||
@@ -21,36 +23,7 @@ export default {
|
||||
callback: (item) => {
|
||||
this.$router.push({ name: 'CreateReplayStorage', query: { type: item.name.toLowerCase() }})
|
||||
},
|
||||
dropdown: [
|
||||
{
|
||||
name: 'S3',
|
||||
title: 'S3'
|
||||
},
|
||||
{
|
||||
name: 'Ceph',
|
||||
title: 'Ceph'
|
||||
},
|
||||
{
|
||||
name: 'swift',
|
||||
title: 'Swift'
|
||||
},
|
||||
{
|
||||
name: 'OSS',
|
||||
title: 'OSS'
|
||||
},
|
||||
{
|
||||
name: 'Azure',
|
||||
title: 'Azure'
|
||||
},
|
||||
{
|
||||
name: 'obs',
|
||||
title: 'OBS'
|
||||
},
|
||||
{
|
||||
name: 'cos',
|
||||
title: 'COS'
|
||||
}
|
||||
]
|
||||
dropdown: storageOptions
|
||||
}
|
||||
},
|
||||
replayTableConfig: {
|
||||
|
||||
Reference in New Issue
Block a user