Custom Module create Manually stoped working.

Hi All,

I have 2 Modules create manually into a package , One works the other does not. This is the page I see when I trying to access the module, the strange thing these 2 modules were working fine, but after a reinstall one of the modules stoped working. 

I can see tables are created , I can see the modules Label displaying on the RolesModule, but it does not show on Sidecar. 

Does anyone knows what could be. 

Thanks

Rodrigo

Parents
  • No clue, but...

    I would:

    - Check permissions for the user (although if you are admin it should not matter)

    - Check the php log for errors

    - Check the Console for errors

    - Check file permissions.

    I use this from sugar root down to fix them all in one go (NOTE it's a pain if your uploads directory is too big and usually the culprit is in the directory I was working in or the cache folder so you can use them from whichever dir you want to rest)

    sudo chown -R  apache:apache * 

    sudo find . -type d -exec chmod 775 {} \;

    sudo find . -type f -exec chmod 664 {} \;

    - Do a QRR

    Hope you find the culprit

    FrancescaS

  • Thanks. I have look into the permission and all fine. when install via module loader,  where Sugar build the files? I can see call API using the normal rest without any customisations. I am sure is something related to sidecar.  

    Rodrigo Manara

    Sr. Developer

  • I believe the manifest will tell Sugar where to put the files.
    I've never built one but when I look at installable packages there is an

    $installdefs = array(
    "copy" => array(
       array(
         "from" => "<basepath>/....",
         "to" => "..."
       )
    ...
    

    This maps the files from the basepath (which I believe is your php temp directory) to the application itself.

    I've never built a module from scratch without Module Builder, but when you install a module built with module builder it usually creates files in:

    modules/<module name>
    custom/modules/<module name>
    custom/metadata/<module name*.php>
    custom/Extension/modules/<module name>
    custom/Extension/application/Ext/TableDictionary/<*module_name*.php>
    custom/Extension/application/Ext/Include/<module>
    custom/Extension/application/Ext/Language/<*field_names*.php>

    There could be other code for subpanels in the case of relationships
    custom/modules/.

    On the database side there should be a module_name table, a module_name_audit table if you have any fields that were audited. There will be relationship tables to other modules which are usually named something like tableA_tableB_c when created via studio though the table names may be oddly abbreviated if you have long table names.
    Once you make changes via Studio and add fields you'll also have a module_name_cstm for any fields added after deployment.

    I'm not 100% sure this is a full list, but those are the places I would look... 

    FrancescaS

  • The issue is on Sidecar, I can make api call create new records, get records from restart api  but when comes to view the list view and the records, it does not display anything , must be something that I am missing here. 

    Rodrigo Manara

    Sr. Developer

  • this is what I see when I run the code

     Now when I run on the module the have the problem 

    But when I call the api using postman works fine. 

    Rodrigo Manara

    Sr. Developer

  • I'm thinking the 404 you are seeing there is not the error but rather the interface displaying the layout for the error message.

    in your controller's context attributes the layout: error, errorType: 404

    just says display that gray page you see that says "Data not available"...

    The problem is elsewhere.

    You said there are no errors in your php log or sugar log or red lines in your Console... right?

    Did you check that the database tables exist?
    Do you get any errors when you do a QRR?

    Just fishing for things here...

Reply
  • I'm thinking the 404 you are seeing there is not the error but rather the interface displaying the layout for the error message.

    in your controller's context attributes the layout: error, errorType: 404

    just says display that gray page you see that says "Data not available"...

    The problem is elsewhere.

    You said there are no errors in your php log or sugar log or red lines in your Console... right?

    Did you check that the database tables exist?
    Do you get any errors when you do a QRR?

    Just fishing for things here...

Children