Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
This repository was archived by the owner on Feb 16, 2023. It is now read-only.

Clarifying documentation on filename placeholders #1391

Open
denilsonsa wants to merge 1 commit into jonaswinkler:master
base: master
Choose a base branch
Loading
from denilsonsa:patch-4

Conversation

@denilsonsa
Copy link

@denilsonsa denilsonsa commented Oct 15, 2021

The documentation text now better describes what the code does. It is now clear that the time is not included, and that all date placeholders are either zero-padded or ISO-formatted.

created=datetime.date.isoformat(doc.created),
created_year=doc.created.year if doc.created else "none",
created_month=f"{doc.created.month:02}" if doc.created else "none", # NOQA: E501
created_day=f"{doc.created.day:02}" if doc.created else "none",
added=datetime.date.isoformat(doc.added),
added_year=doc.added.year if doc.added else "none",
added_month=f"{doc.added.month:02}" if doc.added else "none",
added_day=f"{doc.added.day:02}" if doc.added else "none",

guiguir68 reacted with thumbs up emoji
The documentation text now better describes what the code does. It is now clear that the time is not included, and that all date placeholders are either zero-padded or ISO-formatted.
https://github.com/jonaswinkler/paperless-ng/blob/05c36f91cfa5613bdea5b3c490774cc40b586eeb/src/documents/file_handling.py#L164-L171 
tribut pushed a commit to tribut/paperless-ng that referenced this pull request Aug 18, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

1 participant

AltStyle によって変換されたページ (->オリジナル) /