Bagisto Forum

    Bagisto

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

    how can override shop and admin vue js in new package

    Modules
    3
    7
    689
    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.
    • Z
      zainawan99 last edited by

      how can override shop and admin vue js in new package

      1 Reply Last reply Reply Quote 0
      • V
        vishalK last edited by

        Hi @zainawan99

        You can override vue js by override view file.

        You can read this one - https://forums.bagisto.com/topic/221/how-to-override-view-file-in-bagisto

        For overriding admin file:-

        So you need to create a view file (In your package & follow same path structure as core 's view file consist ) & publish this file according to path of that suggested in above topic or core's view file has, in your package's service provider. Like

        $this->publishes([
          __DIR__ . '/../Resources/views/admin/catalog/products/edit.blade.php' => resource_path('views/vendor/admin/catalog/products/edit.blade.php'),
                ]);
        

        Thanks

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

          @vishalK not view file vue js file webkul admin and shop components

          1 Reply Last reply Reply Quote 0
          • V
            vishalK last edited by

            Hi @zainawan99

            There are two ways:

            First:-

            First of all you have to create vue.js component file inside your package following the same path as you see in other package and create publishable asset by running npm run prod inside your package than you need to publish all asset of your package by using php artisan vendor:publish in root directory and then use this vue.js component in your view file and use view override technique to replace your view file with the existing one to reflect changes in front end so that's how you can overrride vue.js component.

            Second:-

            Make changes in the existing vue.js component according to your need.
            then run npm run prod inside package and run php artisan vendor:publish in root directory.

            Z 2 Replies Last reply Reply Quote 0
            • Z
              zainawan99 @vishalK last edited by

              @vishalK i m create new package ACME/Category/ in this package how can use?

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

                @vishalK kindly update your documentation most things are not added then every person contact this forum.

                1 Reply Last reply Reply Quote 0
                • S
                  sudo55 last edited by

                  @zainawan99 , did you find any way to achieve this?

                  @vishalK ,please tell me the exact way to do this, I want to override a VUE.JS file in my custom package?

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