Home | Forums | Contact | Search | Syndication  
 
 [login] [create account]   Saturday, April 20, 2024 
 
slxdeveloper.com Community Forums  
   
The Forums on slxdeveloper.com are now retired. The forum archive will remain available for the time being. Thank you for your participation on slxdeveloper.com!
 Web Forums - SalesLogix Web Platform & Application Architect
Forum to discuss the use of the SalesLogix Web Platform, Client and Customer Portals, and the Application Architect (For version 7.2 and higher only). View the code of conduct for posting guidelines.
Forums RSS Feed


 Back to Forum List | Back to SalesLogix Web Platform & Application Architect | New ThreadView:  Search:  
 Author  Thread: Changing 'Opportunity' to 'Deal'
Jesse Roper
Posts: 9
 
Changing 'Opportunity' to 'Deal'Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 02 Sep 11 10:01 AM
fiogf49gjkf0d

I have the need to change all instances of 'Opportunity' to 'Deal' in SLX Web.  I have made all the changes but there is one I can't seem to change.  When I click on the opportunities level, a toolbar menu shows up at the top called 'Opportunities', containing the items 'Update Multiple Opportunities' and 'Opportunity Statistics'.  Does anyone know where I can go to change these values?  I was told it's something that is hard-coded in a SLX dll, so I'm not sure if it's something that can be adjusted, but where there's a will there's a way, right?


Thanks in advance!

[Reply][Quote]
Raul A. Chavez
Posts: 1300
Top 10 forum poster: 1300 posts
 
Re: Changing 'Opportunity' to 'Deal'Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 06 Sep 11 12:22 PM
fiogf49gjkf0d

Well, there are ways to get around it:


First of all, the Opportunity Menu can simply be relabeled as follows (add this javascript to the Base.Master file):


$(".x-btn-text:contains('Opportunities')").text('Deals'); 


 


That however doesn't give you access to the SubMenu items (because they don't exist when the page loads, but are created dynamically when the Menu is expanded).


Now, if you analyze the Toolbar, you'll notice that on the Base.Master file, the toolbar is a reference to a "Worspace:ToolbarWorkspace" object. This object renders a Span and some Javascript, which you could replace completely and just add code to render your own Script in place that would have your Own Captions built into them.


 



<span id="ToolbarArea_span" class="floatleft"></span><script pin="pin" type="text/javascript">


 



var ToolBarMenuData = {"id": "toolbarid", "items": [{ "id": "", "text": "Recently Viewed" ................

................

</script>
[Reply][Quote]
Jesse Roper
Posts: 9
 
Re: Changing 'Opportunity' to 'Deal'Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 13 Sep 11 11:33 AM
fiogf49gjkf0d

Thanks for your response, Raul.  I was able to change the title of menu easily, but couldn't figure out how to change the titles for the menu items.  I don't need to change the functionality of either of these - I just need to change the captions.  Shouldn't these be stored in a resource file somewhere, even if the menu items are created dynamically?


 


<p> 

 


 


 <workSpace:ToolbarWorkspace runat="server" ID="ToolBar" CssClass="floatleft"></workSpace:ToolbarWorkspace>


                    <div id="ssDrowdown" class="ssdropdown" onmouseover="this.className='ssdropdownhighlite'" onmouseout="javascript:MenuBtnLeave(this)" onclick="javascript:ShowMenuItem()">


                        <asp:Image ID="imgSSOptions" runat="server" ImageUrl="~/images/blue/menuDropDown.gif" 


                            ImageAlign="Middle" AlternateText="<%$ resources: SpeedSearchOptions %>" />


                        </div>


                    <div id="SSButtons" class="ssbutton" onmouseover="this.className='ssbuttonhighlite'" onmouseout="this.className='ssbutton'">


           <asp:ImageButton ID="Search1"  runat="server" Width="12" Height="12" ImageUrl="~/images/icons/Speed_Search_16x16.gif" ImageAlign="Middle" OnClick="Search1_Click" AlternateText="<%$ resources: Search %>"  />


                        </div>


                    <div id="ssTextDiv" style="float:right;">


                        <asp:TextBox ID="SearchText" runat="server" style="width:150px;height:16px;padding-left:3px;" Text="<%$ resources: SpeedSearch %>" CssClass="tboxinfo" onfocus="checkSSText(this)" onkeydown="javascript:HandleEnterKeyMaster(event, this.id)"></asp:TextBox></div>


 


 


 

[Reply][Quote]
Jesse Roper
Posts: 9
 
Re: Changing 'Opportunity' to 'Deal'Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 15 Sep 11 8:30 AM
fiogf49gjkf0d

Can anyone help with this?

[Reply][Quote]
Lane
Posts: 121
 
Re: Changing 'Opportunity' to 'Deal'Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 15 Sep 11 11:43 AM
fiogf49gjkf0d

This has been an issue since web came out and there is no "nice" answers.


You can try a hack we did to modify the Edit Address dialog (embedded in a sage dll)


we added the following code to the base.master just after the


    <form id="mainform" runat="server" style="width:100%; height:100%;">


    <form id="mainform" runat="server" style="width:100%; height:100%;">
          ...
    </form>


    <!-- roduction Code added to customize the address edit screen -->   
    <script type="text/javascript">  
     try
     {
         AddressControl.fixUp = AddressControl.fixUp || {};
         AddressControl.fixUp.createFormItems = AddressControl.prototype.createFormItems;
         AddressControl.prototype.createFormItems = function() {
                for (var i = 0; i < this._fields.length; i++)
                {
                    if (this._fields[i].name == "county" || this._fields[i].name == "attention")
                        this._fields[i].visible = false;
                    if (this._fields[i].name == "state")
                        this._fields[i].fieldLabel = "State/Province:";              
                }
             return AddressControl.fixUp.createFormItems.call(this); 
         };
      }
     catch (Exception) {}
    </script> 


Now this can go after almost anything, we limited it to reduce conflicts with other forms, but the idea is here.


In your case you'd need to look for all properties containing "opportunity" ... it could be slow.


Run wild at your own peril

[Reply][Quote]
Jesse Roper
Posts: 9
 
Re: Changing 'Opportunity' to 'Deal'Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 19 Sep 11 9:53 AM
fiogf49gjkf0d

Thanks, Lane.  This makes sense, but how would I apply it to the Opportunities menu. So, instead of "AddressControl", I would need an OpportunityMenu object or something along those lines.  I'm rather new to SalesLogix so please forgive if my questions are elementary. 

[Reply][Quote]
Baxin
Posts: 3
 
Re: Changing 'Opportunity' to 'Deal'Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 16 Mar 12 1:58 AM
fiogf49gjkf0d



Hi.
 Opportunity menu hardcoded in Sage.SalesLogix.Client.Opportunity.Modules.resources.dll. This is a resource assembly. It is used in Sage.SalesLogix.Client.Opportunity.Modules.dll. To change the menu, it is necessary to replace the assembly on its own, with the right names submenu. Once the correct assembly is ready, it should be put Portal -> SalesLogix -> SupportedFiles -> Bin. Then open the Opportunity Detail Page,Modules tab to insert our assembly, Run in mode = List. And the old assembly to remove.

The code for the assembly:

<pre>using System;
using System.Collections.Generic;
using System.Text;
using Microsoft.Practices.ObjectBuilder;
using Sage.Platform.Application;
using Sage.Platform.WebPortal.SmartParts;
using Sage.Platform.Application.UI;
using Sage.Platform.Application.UI.Web;
using Sage.SalesLogix.Web;
using Sage.Platform.Security;
using Sage.Platform.WebPortal.Workspaces;
using Sage.SalesLogix.Client.GroupBuilder;
using Sage.Platform.WebPortal.Workspaces.Tab;
using Sage.SalesLogix.BusinessRules;

namespace OverrideOpportunityModule
{
public class OpportunityModuleCustom : IModule
{
// Fields
private IEntityContextService _EntityService;
private IPageWorkItemLocator _pageWorkItemLocator;
private UIWorkItem _parentWorkItem;
private WebPortalUserService _webPortalUserService;
private NavItemCollection navItems;

// Properties
[ServiceDependency(Type = typeof(IEntityContextService), Required = true)]
public IEntityContextService EntityService
{
get
{
return this._EntityService;
}
set
{
this._EntityService = value;
}
}

[ServiceDependency]
public IPageWorkItemLocator PageWorkItemLocator
{
get
{
return this._pageWorkItemLocator;
}
set
{
this._pageWorkItemLocator = value;
}
}

[ServiceDependency(Type = typeof(WorkItem))]
public UIWorkItem ParentWorkItem
{
get
{
return this._parentWorkItem;
}
set
{
this._parentWorkItem = value;
}
}



// Methods
private void DecorateGroupMenu(ToolbarWorkspace workSpace)
{
GroupContext groupContext = GroupContext.GetGroupContext();
string currentTable = groupContext.CurrentTable;
if (this.navItems != null)
{
this.navItems.Items.Clear();
if (groupContext.CurrentTable == "OPPORTUNITY")
{
NavItem item = new NavItem("navItem1", "PUT HERE!", "UpdateOpportunities.aspx", "", "~/images/icons/Edit_Multiple_Opportunities_16x16.gif");
this.navItems.Add(item);
NavItem item2 = new NavItem("navItem2", "PUT HERE!", "OpportunityStatistics.aspx", "", "~/images/icons/Opportunity_dashboard_16x16.gif");
this.navItems.Add(item2);
}
}
}

public void Load()
{
this._webPortalUserService = ApplicationContext.Current.Services.Get<IUserService>() as WebPortalUserService;
ToolbarWorkspace workSpace = this._parentWorkItem.Workspaces["ToolBar"] as ToolbarWorkspace;
TabWorkspace workspace2 = this.PageWorkItemLocator.GetPageWorkItem().Workspaces["TabControl"] as TabWorkspace;
GroupContext.GetGroupContext();
if (this._webPortalUserService == null)
{
this.RebuildNavItems(workSpace);
this.DecorateGroupMenu(workSpace);
}
if (BusinessRuleHelper.AccountingSystemHandlesSO())
{
workspace2.Hide("OpportunityProducts", true);
workspace2.Hide("SalesOrders", true);
}
}

private void RebuildNavItems(ToolbarWorkspace workSpace)
{
this.navItems = new NavItemCollection();
WebSmartPartInfo smartPartInfo = new WebSmartPartInfo("PUT HERE!", "PUT HERE!")
{
SmallImagePath = "ImageResource.axd?scope=global&type=Global_Images&key=Opportunity_List_16x16"
};
workSpace.ShowBefore("mnuHelp", this.navItems, smartPartInfo);
}

}
}

Refernces :


[Reply][Quote]
Baxin
Posts: 3
 
Re: Changing 'Opportunity' to 'Deal'Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 16 Mar 12 1:59 AM
fiogf49gjkf0d


References: 


[URL=http://imageshack.us/photo/my-images/214/referencest.png/][IMG]http://img214.imageshack.us/img214/503/referencest.png[/IMG][/URL]


[Reply][Quote]
 Page 1 of 1 
  You can subscribe to receive a daily forum digest in your user profile. View the site code of conduct for posting guidelines.

   Forum RSS Feed - Subscribe to the forum RSS feed to keep on top of the latest forum activity!
 

 
 slxdeveloper.com is brought to you courtesy of Ryan Farley & Customer FX Corporation.
 This site, and all contents herein, are Copyright © 2024 Customer FX Corporation. The information and opinions expressed here are not endorsed by Sage Software.

code of conduct | Subscribe to the slxdeveloper.com Latest Article RSS feed
   
 
page cache (param): 4/20/2024 3:07:00 AM