Jump to content

Customize core features


wandros

Recommended Posts

Hello!

Is there any way to customize/add onto core features directly from plugins without having to actually edit the core files?

I need to add additional functionality to the invoicecreate form, but would if possible keep everything about the plugin in the plugin code and not splash it around in the core.

 

How do you guys resolve this issue?

Swapping out core files with modified ones on plugin install?

 

Thanks!

/Wandros

Link to comment
Share on other sites

18 hours ago, wandros said:

I need to add additional functionality to the invoicecreate form, but would if possible keep everything about the plugin in the plugin code and not splash it around in the core.

Modifying the invoice creation form would be part of the core. However, you could create a plugin that adds an action to the Actions section on a client profile page, when clicked, would load the plugin with your own invoice creation form. You'd have full control over it. The core form would still exist, but you could use the one you created instead. This is a good place to start - https://docs.blesta.com/display/dev/Creating+a+Plugin

Link to comment
Share on other sites

Thanks for the responses!

Instead of modifying the existing invoice creation page, I'm going to do as follows.

Create my own invoice creation page, based on the original one but residing inside my plugin.

Then hijack all the requests to the original invoicecreate form using preAction event in plugin with url filtering to redirect to my plugins own invoicecreate page.

 

Any disadvantage to this approach?

 

Thanks!

/Wandros 

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...