2014-07-17 15:43 GMT+02:00 Cédric Krier <cedric.kr...@b2ck.com>: > On 17 Jul 01:49, Albert Cervera i Areny wrote: >> 2014-07-16 22:39 GMT+02:00 Cédric Krier <cedric.kr...@b2ck.com>: >> > On 10 Jul 16:39, Albert Cervera i Areny wrote: >> >> Hi, >> >> we just did the first commit of a new module named 'network' [1]. The >> >> module is intended to allow describing the IT infrastructure with the >> >> flexibility of having physical machines, virtual machines inside them, >> >> applications, services, raids, hard drives and relate them easily with >> >> the same mechanism provided by the party_relationship module. Things >> >> are not always hierarchical: for example, a server can have two hard >> >> drives but they are also shared by the RAID of the server so you need >> >> links between all elements (RAID, hard drives and server). >> >> >> >> It also allows the user to define attributes to each network item >> >> acording to its type. For example, "eth0 from server X" will be of >> >> type "Network Interface" and as such can have IPs, Card Model, Serial >> >> number, whatever.. This' been implemented with the dict field (just >> >> like product_attribute module). >> >> >> >> The thing is that the resulting module is very generic and I'm >> >> thinking that it might make sense to name it "asset" and use it to >> >> define not only IT elements but any kind of asset of a company. >> >> Indeed, I'd say it's very similar to the basic structure a CMMS [2] >> >> provides. I'm thinking each asset could have (with an extra module) a >> >> m2o to stock.lot and (with another module) a o2m to account.asset. >> >> >> >> Thoughts? >> > >> > OK let's move the discussion to tryton-dev@ and start a blueprint. >> > Initial thoughts are there should be at least two modules: >> > >> > - asset (probably with possible link with account_asset) >> > - asset_relationship >> >> As suggested by Cédric I move the discussion to tryton-dev. I just >> created a wiki page with the initial blueprint and model definitions >> just like they currently look in the network module [1] only replacing >> "network.item" by "asset". >> >> >> [1] https://bitbucket.org/nantic/trytond-network > > Base on https://code.google.com/p/tryton/wiki/Assets > > I think it should be more integrated with account_asset. > So for me, asset should be linked to a product of type asset (not > necesseray depreciable) and the account_asset should link to this asset > instead of product.
In fact, maybe we could even remove the m2o to asset.type and replace it with the link to product.product. So we simply drop the asset.type model. > I will reuse the same terms for Dict stuffs as in product_attribute and > move it to a module asset_attribute Agreed and relates with my comment above. > The icon stuff should be in a separate module and even perhaps for > custom module. Ok. > name and code seem redondant I don't think they're redundant. I see it just like party and product which both have product and code. Though maybe we could make it work like in party, by default. So the sequence is not required. > notes should be replaced by > https://code.google.com/p/tryton/wiki/StickyNote Ok. > The linkage with stock_lot doesn't seem to me as a real benefit. But it > could be a simple informational link if both modules are installed. It should not be a requirement but it has some use cases. For example, a company who sells a large machine for which it later manages its maintenance for the customer. When sold, it should use the lot as a serial number but as soon as it starts doing the maintenance it will need to create the asset. I think that whereas the relationship between asset and account.asset should be o2m (you can have different depreciation tables because the asset is paid in several invoices) I think the link between stock.lot and asset it would be a o2o. At least I cannot imagine a reason for o2m or m2o here. -- Albert Cervera i Areny Tel. 93 553 18 03 @albertnan www.NaN-tic.com