Results 1 to 2 of 2

Thread: re-using module (Proposal as Quote)

  1. #1
    ElGato is offline Member
    Join Date
    Nov 2009
    Posts
    10

    Default re-using module (Proposal as Quote)

    I have pro_proposal module installed in my system. Each Proposal object contains set of pro_proposal products

    Now I need to use Quotes. Quote must be copy of Proposal. I mean Quote must contain same info as Proposal including products.

    I guess I need deep Quotes and Products (which linked with Quotes) customization. In other hand, I already have Proposal which match my needs.

    Is there any way to reuse Proposal like Quote? May be I can add some flag to Proposal, something like 'is_quote_mode'?


    I want to avoid code duplication in my 'Proposal' and 'Quotes' modules

  2. #2
    agcopley is offline Sugar Community Member
    Join Date
    Nov 2007
    Location
    Santiago, Chile
    Posts
    204

    Default Re: re-using module (Proposal as Quote)

    There are various ways of doing this but one of the most straightforward is to use logic hooks:

    1. On Quotes module, add a relate field to Proposals i.e. when you create a quote you can link it to Proposal.
    2. Create logic hook (after save) on Quotes (see wiki) that picks up Proposal Id
    3. In logic hook, retrieve related Proposal and populate Quote fields

    It does mean that you have to save the Quote to retrieve the proposal.

    If this is not suitable I can suggest more!

    Rgds

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Module QUOTE
    By z.chafi in forum Developer Help
    Replies: 6
    Last Post: 2007-09-28, 08:37 AM
  2. Add field in the quote module
    By fvermenouze in forum Developer Help
    Replies: 0
    Last Post: 2007-09-19, 02:10 PM
  3. Quote Module
    By kpettit in forum Classifieds
    Replies: 1
    Last Post: 2005-12-21, 10:17 PM
  4. Integrating a Quote/Proposal system into SugarCRM
    By rnull in forum General Discussion
    Replies: 1
    Last Post: 2005-06-22, 07:52 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •