Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

extend fileInfoV2-API with hide flag #234

Open
henryk86 opened this issue Nov 1, 2024 · 4 comments
Open

extend fileInfoV2-API with hide flag #234

henryk86 opened this issue Nov 1, 2024 · 4 comments
Labels
enhancement New feature or request

Comments

@henryk86
Copy link
Collaborator

henryk86 commented Nov 1, 2024

I would like to display a hint in the filebrowser, that a tag/taf is actually marked as hidden. The hide information is stored within the json file. Can this information be also provided in the fileInfoV2-API result per entry?

Default for that flag would be false.

@henryk86 henryk86 added the enhancement New feature or request label Nov 1, 2024
@SciLor
Copy link
Contributor

SciLor commented Nov 9, 2024

only tags can be hidden, not TAFs

@henryk86
Copy link
Collaborator Author

henryk86 commented Nov 9, 2024

Then only for the tags ;) in the content folder

@henryk86
Copy link
Collaborator Author

src/handler_api.c: In function ‘handleApiFileIndexV2’:
src/handler_api.c:703:71: error: passing argument 3 of ‘cJSON_AddStringToObject’ makes pointer from integer without a cast [-Werror=int-conversion]
703 | cJSON_AddStringToObject(jsonEntry, "hide", contentJson.hide);
| ~~~~~~~~~~~^~~~~
| |
| bool_t {aka int}
In file included from src/handler_api.c:19:
cJSON/cJSON.h:269:112: note: expected ‘const char * const’ but argument is of type ‘bool_t’ {aka ‘int’}
269 | CJSON_PUBLIC(cJSON*) cJSON_AddStringToObject(cJSON * const object, const char * const name, const char * const string);
| ~~~~~~~~~~~~~~~~~~~^~~~~~
cc1: all warnings being treated as errors
make: *** [Makefile:506: obj/src/handler_api.o] Error 1

@henryk86
Copy link
Collaborator Author

henryk86 commented Nov 10, 2024

thats the goal of this addition:

image

if i saw it correctly, the flag is added only in the json file case, Would it be possible to also add it in the parent level like the tonieinfo is already? right after on same level as "isDir"?

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants