On 19/05/11 16:05 +0200, Cédric Krier wrote:
> Hi,
> 
> I'm working on improving the XML import.
> I find there is a lot of code that try to detect if a imported record has been
> changed since the last import. If it changed then there is no update done.
> This behavior is almost never used because by default every xml record is
> readonly. There is some exceptions:
> 
>     - ir.lang
>     - ir.model.access
>     - ir.model.access.field
>     - ir.cron
>     - stock.location
>     - currency.currency
>     - product.uom
> 
> I think we could drop this feature because it is unuseful and can generate
> issue by wrongly not update a record. And we will be sure to have the same
> data in the database then in the XML.
> 
> For the execptions, I think we can manage them with just the noupdate
> attribute. And for the *.access.* models, we can define that we don't allow to
> modify the records.

I got a talk with Dominique and indeed there is some cases where it could be
good to be able to modify a xml record and also to get it updated next time.

One of my concern about removing this feature was that the user is not able to
get the update of the record if he modified it.

So I thought about an other solution, we could store the values that should be
written in a new field of ir.model.data when the record was not updated (due
to changes). Then we can have a wizard on ir.model.data that allow the user to
force the update of those records (once done the records will be seen by the
system as an unmodified one).

Thoughts?

-- 
Cédric Krier

B2CK SPRL
Rue de Rotterdam, 4
4000 Liège
Belgium
Tel: +32 472 54 46 59
Email/Jabber: [email protected]
Website: http://www.b2ck.com/

Attachment: pgpXxCVQ1u6vN.pgp
Description: PGP signature

Reply via email to