3 Replies Latest reply on Feb 6, 2014 6:16 AM by philmodjunk

    Top feature in customers layout

    ultranix

      Title

      Top feature in customers layout

      Post


           Hey, this might sound complex, but I will try to explain it anyway.

           I want to be able to assign "Top" feature to the certain prospect for a specific period of time until he 1) becomes a client 2) refuses to sign the agreement.

           How I see it happening (I just don't know how to make it happen) is:

           1) You go to the layout where prospect's general info is placed (name, last name, phone number, email, etc.)

           2) Click a button "Top", and then it performs a script that adds new record into the table "Top", where all the record of those prospects, who have been assigned "Top" are placed. I think it should be enough to have 3 fields: 1) id_client (field which matches the main table of prospects), 2) date(date, when Top feature was assigned) 3) active (if the feature is active or not).

           3) You are then able to create a new layout and see all the ACTIVE prospects with "Top" label for a certain date (i.e. when active field comes into play).

           4) When you want to remove "Top" label from the prospect, you go again to that main layout mentioned in the 1st point, click the button "Remove from Top" and then it (MAYBE???) should create another record in Top table with the date of deactivating Top feature, client ID, and active field = false. Of the last thing I'm not sure, though.

           That's how it should be. I just don't get how to achieve that "ACTIVE" functionality, because if I want to see who were the "Top" prospects for, let's say 2013-10-25, and most of them wouldn't have that status now, How to do that?

           I know my explanation may sound confusing, but I really need this feature in my database.

           So, basically, 3 things I need - 1) ability to active "Top" prospect, 2) ability to deactivate "Top" prospect and 3) ability to view all active "Top" prospects by any given date.

        • 1. Re: Top feature in customers layout
          philmodjunk

               Instead of creating a second record, my not update a "DateDeactivated" field with today's date to drop the prospect off of the list?

               The script to add a new Top Prospect:

               Set Variable [ $ContactID ; Value: Contacts::__pkContactID ]
               Freeze WIndow
               Go to Layout [ "TopProspects" (TopProspects) ]
               New Record/Request
               Set Field [ TopProspects::_fkContactID ; $ContactID ]
               Go To Layout [original layout]

               Your date field can auto-enter the creation date to show when the contact became a top prospect.

          • 2. Re: Top feature in customers layout
            ultranix

                 adding another field date_deactivated to drop that from active list sounds like an option. But how will I see all those "active for the certain date" prospects? Relationships? Filter portal? I'm just out of imagination...

            • 3. Re: Top feature in customers layout
              philmodjunk

                   Perform a find for all records in this table where the Date activated is less than or equal  the specified date and the date deactivated field is either empty or greater than or equal to the specified date.

                   This can be scripted and you'd use two find requests--one for an empty date deactivated and one for a date > the specified date.