mirror of
https://github.com/haiwen/seahub.git
synced 2025-08-29 12:04:02 +00:00
feat: update code
This commit is contained in:
parent
7a47c647a2
commit
46e8aac5c6
@ -62,7 +62,7 @@ const FileDetails = React.memo(({ repoID, repoInfo, dirent, path, direntDetail,
|
|||||||
</div>
|
</div>
|
||||||
</DetailItem>
|
</DetailItem>
|
||||||
)}
|
)}
|
||||||
{window.app.pageOptions.enableMetadataManagement && (
|
{window.app.pageOptions.enableMetadataManagement && enableMetadata && (
|
||||||
<MetadataDetails repoID={repoID} filePath={direntPath} repoInfo={repoInfo} direntType="file" />
|
<MetadataDetails repoID={repoID} filePath={direntPath} repoInfo={repoInfo} direntType="file" />
|
||||||
)}
|
)}
|
||||||
{isEditFileTagShow &&
|
{isEditFileTagShow &&
|
||||||
|
@ -13,7 +13,7 @@ import { CellType, getColumnOptions, getOptionName, PREDEFINED_COLUMN_KEYS, getC
|
|||||||
|
|
||||||
import './index.css';
|
import './index.css';
|
||||||
|
|
||||||
const MetadataDetails = ({ repoID, filePath, repoInfo, direntType, emptyTip }) => {
|
const MetadataDetails = ({ repoID, filePath, repoInfo, direntType }) => {
|
||||||
const [isLoading, setLoading] = useState(true);
|
const [isLoading, setLoading] = useState(true);
|
||||||
const [metadata, setMetadata] = useState({ record: {}, fields: [] });
|
const [metadata, setMetadata] = useState({ record: {}, fields: [] });
|
||||||
const permission = useMemo(() => repoInfo.permission !== 'admin' && repoInfo.permission !== 'rw' ? 'r' : 'rw', [repoInfo]);
|
const permission = useMemo(() => repoInfo.permission !== 'admin' && repoInfo.permission !== 'rw' ? 'r' : 'rw', [repoInfo]);
|
||||||
|
Loading…
Reference in New Issue
Block a user