mirror of
https://github.com/MrUnknownDE/panel.git
synced 2026-04-18 06:13:45 +02:00
Format all the files
This commit is contained in:
@@ -9,7 +9,7 @@ import {ServerDatabase} from "@/api/server/types";
|
||||
*/
|
||||
export function createDatabase(server: string, database: string, remote: string): Promise<ServerDatabase> {
|
||||
return new Promise((resolve, reject) => {
|
||||
http.post(route('api.client.servers.databases', { server }), {database, remote})
|
||||
http.post(route('api.client.servers.databases', {server}), {database, remote})
|
||||
.then(response => {
|
||||
const copy: any = response.data.attributes;
|
||||
copy.password = copy.relationships.password.attributes.password;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import http from '../http';
|
||||
import { filter, isObject } from 'lodash';
|
||||
import {filter, isObject} from 'lodash';
|
||||
// @ts-ignore
|
||||
import route from '../../../../../vendor/tightenco/ziggy/src/js/route';
|
||||
import {DirectoryContents} from "./types";
|
||||
@@ -7,9 +7,9 @@ import {DirectoryContents} from "./types";
|
||||
/**
|
||||
* Get the contents of a specific directory for a given server.
|
||||
*/
|
||||
export function getDirectoryContents (server: string, directory: string): Promise<DirectoryContents> {
|
||||
export function getDirectoryContents(server: string, directory: string): Promise<DirectoryContents> {
|
||||
return new Promise((resolve, reject) => {
|
||||
http.get(route('server.files', { server, directory }))
|
||||
http.get(route('server.files', {server, directory}))
|
||||
.then((response) => {
|
||||
return resolve({
|
||||
files: filter(response.data.contents, function (o) {
|
||||
|
||||
Reference in New Issue
Block a user