mirror of
https://github.com/pelican-dev/panel.git
synced 2026-02-27 16:03:16 +03:00
15 lines
381 B
TypeScript
15 lines
381 B
TypeScript
|
|
import http from '@/api/http';
|
||
|
|
|
||
|
|
interface Data {
|
||
|
|
file: string;
|
||
|
|
mode: string;
|
||
|
|
}
|
||
|
|
|
||
|
|
export default (uuid: string, directory: string, files: Data[]): Promise<void> => {
|
||
|
|
return new Promise((resolve, reject) => {
|
||
|
|
http.post(`/api/client/servers/${uuid}/files/chmod`, { root: directory, files })
|
||
|
|
.then(() => resolve())
|
||
|
|
.catch(reject);
|
||
|
|
});
|
||
|
|
};
|