This topic contains 3 replies, has 2 voices, and was last updated by Sean Sean 2 years, 1 month ago.

Angular Theme: How to add datatables to dashboard.html view


  • m_its
    Participant

    Posts: 1
    Member Reply #7423

    Hi,

     

    I have an issue. Hope I can get a solution.

     

    Scenario

    I have the pristine Metronic theme admin_1_angularjs.

    I am trying to get a sample database from /views/datatables/managed.html to work in views/dashboard.html. My problem is that the changes i make to the pristine code don’t work properly. I have made changes to main.js and dashboard.html.

     

    Changes to main.js

    Added entries of files from state(‘datatablesAdvanced’,  …..) to state(‘dashboard’, …….)

    All the entries of files were copied except GeneralPageController.js

     

    Changes to dashboard.html

    Copied the sample datatable with id=”sample_1″ from managed.html to dashboard.html. I have copied the parent <div class=”row”> tag containing the table in its entirety.

     

    Output

    The output which I expected was the same table as in managed.html. But, all the records are being displayed continuously. The controls at the bottom of the table and the search box are not visible.

     

    Clearly, I am missing something which is causing this behavior. Could you help me out??

     

    Note:

    Apart from the above described change, there have been no changes made to the code. I did everything on a pristine source.

    I have also attached my dashboard.html and main.js files.

    My changes are surrounded but the following comments

    <!– MODIFIED CODE STARTS HERE –>

    <!– MODIFIED CODE ENDS HERE –>

     

    Thank you in advance


    m_its
    Participant

    Posts: 1
    Member Reply #7427

    I found the issue. I wasn’t calling the init function in the script area.

     

    Also, there is an issue with the upload file feature while posting a topic. I tried posting the topic after I had attached a zip file containing dashboard.html and main.js, the site wouldn’t allow me to post the topic. Infinite loading would occur. The file size was around 150kb. I tried it from two different computers on different networks. You might want to look into it.

    Sean
    Sean
    Keymaster

    Posts: 4527
    Support Staff Reply #7433

    Hi :),

    Thanks for your feedback on this file uploading issue. We will check look at it further.

    Thanks

    Sean
    Sean
    Keymaster

    Posts: 4527
    Support Staff Reply #7435

    Hi,

    Could you please try to upload a file now ? As per our testing we were able to upload

    Thanks.

     

You must be logged in to reply to this topic.