some questions about account_invoice / attachments

18 views
Skip to first unread message

Richard PALO

unread,
Mar 19, 2017, 1:11:42 PM3/19/17
to tryton
I have the following questions concerning account_invoice (running on trunk, for now)

1. I'm trying the following in trytond.conf but I can't seem to find my invoices on the filesystem:
> [database]
> path = /var/lib/trytond
> ...
> [account_invoice]
> filestore = True

naturally the server has been restarted, and the process has rw access to /var/lib/trytond

Is there somewhere else things need to be turned on?

FWIW: Just to be sure, I tried an attachment, and it creates the file in the filestore just fine.

2. Once new invoices work, how to migrate the in-database cached invoices?

3. I noticed that if I add an attachment, then delete it, the file remains in the filestore.

Is this expected behaviour?

Is there a mechanism to clean the filestore when all references go to zero?
(that is, perhaps via a tryton-admin sort of function, not brute force filesystem deletions)

4. Trying with the [attachment] section, I noticed setting store_prefix is parallel to the default,
which is the database name.

Is there a mechanism to get the prefix to work as a subdirectory of the database name?

cheers,
--
Richard PALO

Cédric Krier

unread,
Mar 19, 2017, 2:05:09 PM3/19/17
to tryton
On 2017-03-19 18:11, Richard PALO wrote:
> I have the following questions concerning account_invoice (running on trunk, for now)
>
> 1. I'm trying the following in trytond.conf but I can't seem to find my invoices on the filesystem:
> > [database]
> > path = /var/lib/trytond
> > ...
> > [account_invoice]
> > filestore = True
>
> naturally the server has been restarted, and the process has rw access to /var/lib/trytond
>
> Is there somewhere else things need to be turned on?

No but invoice are stored only when posted.

> FWIW: Just to be sure, I tried an attachment, and it creates the file in the filestore just fine.
>
> 2. Once new invoices work, how to migrate the in-database cached invoices?

There is no migration available. Old invoices stay in the database.

> 3. I noticed that if I add an attachment, then delete it, the file remains in the filestore.
>
> Is this expected behaviour?

Yes.

> Is there a mechanism to clean the filestore when all references go to zero?
> (that is, perhaps via a tryton-admin sort of function, not brute force filesystem deletions)

No.

> 4. Trying with the [attachment] section, I noticed setting store_prefix is parallel to the default,
> which is the database name.
>
> Is there a mechanism to get the prefix to work as a subdirectory of the database name?

No.

--
Cédric Krier - B2CK SPRL
Email/Jabber: cedric...@b2ck.com
Tel: +32 472 54 46 59
Website: http://www.b2ck.com/
Reply all
Reply to author
Forward
0 new messages