1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-09-05 08:53:14 +00:00

Org admin api (#7030)

* [org admin] moved related APIs from seafile-js to org-admin-api.js; use 'orgAdminAPI' instead of 'seafileAPI' for the dialogs

* [org admin] use 'orgAdminAPI' instead of 'seafileAPI' for the pages
This commit is contained in:
llj
2024-11-12 12:14:01 +08:00
committed by GitHub
parent 91c50d6765
commit c26b593a55
49 changed files with 600 additions and 129 deletions

View File

@@ -2,7 +2,7 @@ import React from 'react';
import PropTypes from 'prop-types';
import { Button, Modal, ModalHeader, ModalBody, ModalFooter, Input, InputGroupAddon, InputGroup } from 'reactstrap';
import { gettext, orgID } from '../../utils/constants';
import { seafileAPI } from '../../utils/seafile-api';
import { orgAdminAPI } from '../../utils/org-admin-api';
import { Utils } from '../../utils/utils';
import toaster from '../toast';
@@ -28,7 +28,7 @@ class SetGroupQuotaDialog extends React.Component {
if ((quota.length && myReg.test(quota)) || quota == -2) {
this.setState({ errMessage: '' });
let newQuota = this.state.quota == -2 ? this.state.quota : this.state.quota * 1000000;
seafileAPI.orgAdminSetGroupQuota(orgID, this.props.groupID, newQuota).then((res) => {
orgAdminAPI.orgAdminSetGroupQuota(orgID, this.props.groupID, newQuota).then((res) => {
this.props.toggle();
this.props.onSetQuota(res.data);
}).catch(error => {