Bagisto Forum

    Bagisto

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups

    How to Extend/Change features of an existing package from another package?

    Modules
    3
    3
    885
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • R
      RK REZA last edited by

      Is there any way where I can extend/change some features of an existing package from another package?

      Like:

      • Add brand to products table.
      • Add category type to categories table.
      • Add category to slider
      1 Reply Last reply Reply Quote 0
      • R
        rahul last edited by

        Hello,

        You can create a separate package for it & can override model.
        Link are -https://devdocs.bagisto.com/override-core-model.html & https://devdocs.bagisto.com/create_package.html#how-to-create-package.

        In your package, add desired column in model & create migration for it and use your model instead of core.

        To ovveride layout, you can create your own view in laravel's default view folder.
        Check laravel's default view folder (resources -> views), you will find a folder name as vendor, In this vendor folder create your own view but make sure that it consist the same directory structure as package have.

        For shop, create a folder name shop in this folder create a same directory of view as shop package consist.
        Example - like I have to override master file , then in shop folder i will create layouts folder & inside this folder, create file name master.blade.php & write own code here.

        Thanks
        Rahul Shukla

        Z 1 Reply Last reply Reply Quote 0
        • Z
          zainawan99 @rahul last edited by

          @rahul How to Extend/Change features of an existing package from another package?

          1 Reply Last reply Reply Quote 0
          • First post
            Last post