[Fusioninventory-devel] Patchs for libserver php

taha goulamhoussen taha.goulamhoussen at gmail.com
Tue Sep 21 16:20:11 UTC 2010


On Wed, Aug 25, 2010 at 2:40 PM, taha goulamhoussen <
taha.goulamhoussen at gmail.com> wrote:

>
> On Wed, Aug 25, 2010 at 2:26 PM, taha goulamhoussen <
> taha.goulamhoussen at gmail.com> wrote:
>
>>
>> On Sat, Aug 21, 2010 at 11:02 PM, David DURIEUX <d.durieux at siprossii.com>wrote:
>>
>>> Always with libserverphp, there is problems :
>>>
>>> The hook addsections must return an array with id for each section, but
>>> for each section we must have only a number (because it is using by a key
>>> number in an array. So we can't have possibility to have same key
>>> for 2 sections.
>>>
>>> For example, I store in my DB, HARDWARE section in a table and SOFTWARE
>>> section in an other. And we can have same id. it's a big PROBLEM.
>>>
>>>
>>> Other things works for the moment ;)
>>>
>>>
>>    [sorry i complete the response]
>
>> Hi,
>>
>> I began  to develop an solution to fix this problem.
>>
>> In the addsections hook, the user have to send an associative array
>> (section type / id).
>>
>> For example: array('SOFTWARES' => array(4, 5, 6, 7),
>>
>                                'HARDWARES' => array(1,2,3,4,5))
>
>>
>> User have to specify sections Type with their sections name in the configs
>> file.
>
>
>    This will allow to format array from xml file, in order to compare the
> array from xml file with the array from database. This development isn't
> finalise yet.
>
>>
>> Otherwise, I noticed some anomalies in the library:
>>
>
>   - The logs file creation doesn't work.
>   - Array string is stored in the database, in dataSection column.
>
> Thanks.
>
>
Hi,

Finally,
I kept the initial treatment of the library. If users want to manage multi
tables, they have to concatenate table name with id in order to have an
unique id.
The logs file creation bug is resolved.
The problem with "Array" string stored in the database persists, is there
something missing if the hooks system perhaps ?

Thanks.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.alioth.debian.org/pipermail/fusioninventory-devel/attachments/20100921/b87593ac/attachment.htm>


More information about the Fusioninventory-devel mailing list