Confirmation on BrowseBean.clickSpace method

Hi All,
I am working on customizing an Alfresco page browse.jsp. And i have been finding it very difficult to pass parameters from the jsp to my Backing bean.After analysing a few f:param tags in the browse.jsp page i stumbled upon line no 271
<a:actionLink id="col1-act1" value="#{r.name}" image="/images/icons/#{r.smallIcon}.gif" actionListener="#{BrowseBean.clickSpace}" showLink="false">
<f:param name="id" value="#{r.id}" />
</a:actionLink>The actionListener 'BrowseBean.clickSpace' inside BrowseBean.java is
public void clickSpace(ActionEvent event)
      UIActionLink link = (UIActionLink)event.getComponent();
      Map<String, String> params = link.getParameterMap();
      String id = params.get("id");
      if (id != null && id.length() != 0)
         try
              System.out.println("ClickSpace event called");
            NodeRef ref = new NodeRef(Repository.getStoreRef(), id);
            // handle special folder link node case
            if (ApplicationModel.TYPE_FOLDERLINK.equals(this.getNodeService().getType(ref)))
               ref = (NodeRef)this.getNodeService().getProperty(ref, ContentModel.PROP_LINK_DESTINATION);
            clickSpace(ref);
         catch (InvalidNodeRefException refErr)
            Utils.addErrorMessage(MessageFormat.format(Application.getMessage(
               FacesContext.getCurrentInstance(), Repository.ERROR_NODEREF), new Object[] {id}) );
   }The inference i have drawn from the above two code sources is that
1)Considering the JSP code, i assume that the id parameter passed using f:param is 'one id for every content'.Almost like a collection of id's
2) The actionListener BrowseBean.clickSpace is called for every id of the content .So if i had an arrayList to capture all the id's from inside the clickSpace actionListener i will be successfull in doing that.
3)I will be able to pass the parameter like r.name in the place of r.id.
Just need a confirmation on whether my assumptions are true.I have tried customizing the page using these inferences but have failed.Thank You.

you are definitely right
here is my code which works fine
page:
<h:commandLink action="doRefresh" actionListener="#{AdminBatchesBean.doSort}">
    <h:outputText id="selectBatchColumn" value=" ">
        <f:param value="rows"/>
        <f:param value="selected"/>
    </h:outputText>
</h:commandLink>bean:
public void doSort(ActionEvent event) {
    final UIComponent out = (UIComponent) event.getComponent().getChildren().get(0);
    UIParameter param = (UIParameter) out.getChildren().get(0);
    final String listName = (String) param.getValue();
    param = (UIParameter) out.getChildren().get(1);
    final String fieldName = (String) param.getValue();
    blah-blah-blah
}

Similar Messages

  • Pop Up to confirm execution of Task / Method

    Hello,
    we have a Deletion Task, which runs before starting with new Month End closing procedure. This task can be executed by the user. Unfortunately it happend, that some users executed this task, after they have loaded their reported financial data.
    Now our business wants to have a "Confirmation Popup" that the task should realy be executed.
    I already checked the Method's customizing, but there is no "BADI Exit" forseen, as it is available in some other methods. e.g. Load from Data Stream.
    I want to avoid modifying a standard method / class , adding a confirmation popup.
    I thought of creating a "Custom Task" which is calling than the "Delete Method" or "Task".
    Can someone give me an example coding how to call a standard customized Method / Task from a customer defined task ?
    Thanks for your help.
    Dieter

    HI,
    when user says no try to
    CALL transaction 'ME22n'.
    or
    LEAVE TO  TRANSACTION ta
    or
    Leave to CURRENT TRANSACTION ta
    regrads
    Basavaraj

  • Timeframe Default Value in Confirmation

    Hi,
    My requirement is that , In Confirm Goods/Services BBPCF02 under "Search for Purchase Order section" we have ("Item Description" "Name of Shopping Cart" " Timeframe" "Purchase Order Number" ) fieds.At present the TIMEFRAME value is always defaulted to "Last 7 Days".I need to chnage TIMEFRAME value dfault to "Last 90 Days" instead.
    Regards

    Hi,
    If you are using screen variant,you need to use the badi "BBP_SCREENVARIANT".
    Here is the documenation of the BADI.
    BBP_SCREENVARIANT
    Short Text
    Determine Screen Variants
    Use
    In this BAdI you can change the screen variant that controls the display of the item overviews and search results. As default, the following screen variants are called up:
    · Item data overview in the invoice without purchase order reference: Screen variant BBP_IV_NON_PO
    Method GET_SCREENVARIANT_INV
    · Item data overview in the invoice with purchase order reference: Screen variant BBP_IV
    Method GET_SCREENVARIANT_INV
    · Item data overview in the confirmation: Screen variant BBP_CF
    Method GET_SCREENVARIANT_CONF
    · Item data overview in the confirmation for time recording: Screen variant BBP_CF_TIMEREC
    Method GET_SCREENVARIANT_CONF
    · Item data overview in the purchase order: Screen variant BBP_PO
    Method GET_SCREENVARIANT_PO
    · Item overview for contracts: Screen variant BBP_CTR_ITEMLIST
    Method GET_SCREENVARIANT_CTR
    · Item overview for contract selection: Screen variant BBP_CTR_ITEM_SELLIST
    Method GET_SCREENVARIANT_CTR
    · Search results for creating an invoice and/or confirmation: Screen variant BBP_SEARCH_PO
    Method GET_SCREENVARIANT_SEARCH
    · Search results for creating a purchase order: Screen variant BBP_SEARCH_SC
    Method GET_SCREENVARIANT_SEARCH
    · Search results for displaying/changing an invoice: Screen variant BBP_CHANGE_IV
    Method GET_SCREENVARIANT_SEARCH
    · Search results for displaying/changing a confirmation: Screen variant BBP_CHANGE_CF
    Method GET_SCREENVARIANT_SEARCH
    · Item overview for creating/displaying/processing/status of a shopping cart: Screen variant BBP_SC
    Method GET_SCREENVARIANT_SC
    · Worklist for Sourcing: Screen variant BBP_SOCO_WL
    Method GET_SCREENVARIANT_SOCO
    · Work area in Sourcing: Screen variant BBP_SOCO_GA
    Method GET_SCREENVARIANT_SOCO
    Activities
    If you wish to hide or show fields, proceed as follows:
    1. Determine the screen variant, for example, BBP_IV, using the list above.
    2. Copy this screen variant, for example, in ZZ_BBP_IV_1, in Transaction SHD0.
    3. Change the new screen variant as required. Note that you can only change the display properties for fields of table controls. You can switch the display on and off (column Invisible in Transaction SHD0). You can recognize the fields of a table control because they have a 1 on the right side of the first column. In addition, the heading for this area contains (Table CTRL.
    4. Implement the appropriate method (see the list above). Fill the export parameter EV_SCVARIANT with the new screen variant.
    You can create multiple screen variants for a screen and then select these in the BAdI depending on the user or on other criteria.
    If you are not using screen variant,then you need to do the std code changes in Include LBBP_SC_UI_ITSF44 or the corresponding Confirmation screen include.
    Hope this clarifies your confusion.
    P.S. Do reward points if you find the answers helpful in solving your problem.
    BR,
    Disha.

  • Confirmation button in check status

    Hello,
    when confirming goods in "Confirm Goods / Services" I enter the quantity and I can confirm.
    When I press 'create confirmation' in 'check status' I get 'confirmation still contains errors; check the confirmation'. Is this because the amount is missing? Can the amount be filled automatically?
    Also I would like to know if it is possible to hide the button?
    thanks and regards
    stefan

    Stefan,
    You can remove the confirmation button in various methods..
    1) change the authorization for BBPSC04 for all the roles..
    2) Use BBP UI CTRL BADI for hiding the confirmation button..
    3) Use SHD0.. transaction variant to achieve the same..
    Try any one of these that is easy to implement for you..
    Let me know if you have more questions..
    Regards
    Rakesh
    Ps. Please close the thread if your question is answered..

  • Valid methods to back up ASO database

    Hi Experts,
    I think there are 2 ways to back up ASO database
    1) Maxl alter database commands
    2)Esscmd BEGIN ARCHIVE/END ARCHIVE
    Can any one confirm me that above methods are valid to do the tasks .If invalid let me know which one is invalid.I went through dbag and it give me little confusion in finding which one is valid methid.

    Hi John,
    Thank you for the reply.
    I have some clarification on the following question which i came in certification last 2 days back.
    A calcualtion is performed on a database for which create block on equation is off.The command SET CREATEBLOCKONEQ ON is issued immediately before an equation in the script.which statements accurately describe when blocks will be created?
    1) blocks will be created ONLY when the equation assigns non - constant values to members of sparse diemension.
    2)blocks will be created only when the equation assigns constant values to memebers of sparse dimension
    3)blocks will be created when the equation assignes either constant or non constant values to a members of sparse dimension
    4)No blocks will be created.
    please clarify on the above.

  • Change Confirmation Dialog Title

    Hi all,
    Does anyone know how can I change the title of a confirmation dialog ?
    Thanks,
    Jesus.

    Hi Jesus,
    IWDWindow has the setTitle() method only from SP12 onwards (https://media.sdn.sap.com/javadocs/NW04/SP12/webdynpro/com/sap/tc/webdynpro/services/session/api/IWDWindow.html).
    So it all depends on your version. If you are using an older version, you have no <b>recommended</b> method for this (check the following links )
    Title Change of the confirmation dialogue
    Confirmation Dialog setTitle
    setTitle Method of interface IWDConfirmationDialog
    Best Regards,
    Nibu.

  • IMessage Confirmed Not working.

    Hi. I upgraded my iPhone 4 to iOS 5 from the latest iOS 4 version, Everything seems to be working fine except iMessage. It will not work, no matter how hard I try.
    Whenever I send an iMessage, it says delivery failed after a long while. If I tap the exclamation mark next to the bubble and select the try again option, I get no progress bar unless I go back to home, lock the phone, unlock and open Messaging again. The progress bar then shows and remains stuck at 90% for a long while before failing again. This happens again and again, no matter how many times I retry. I cannot receive any iMessages either. Every other method is working fine, including tweets, emails and text messages. If I add my own phone number as a contact and send an iMessage, it goes through and shows up in as received too almost instantly.
    I have tried with 2 different people for whom it works perfectly when they send iMessages to each other, I have confirmed all settings and methods to be identical. I have confirmed that activation is successful and have reconfirmed my Apple ID and have viewed all details within the configuration options located in the Settings > Messages menu. I have tried over Edge, 3G and Wifi. I have restarted Messaging many times along with turning the iMessages option on and off multiple times. I have tried rebooting the phone and turning iMessages off before and on after and leaving it on during the reboot. I have also tried a factory restore with and without reinstalling my apps on it.
    Nothing fixes the problem and I am very frustrated. How can I fix it? Please help.

    Hey Guys
    Im getting a little bit confused with this imessage
    i can imessage to my 2 girls ipods from my iphone and they can imessage me back. but when they try to imessage each other its says they are not registered for imessage??
    but they must be or they wouldnt recieve my imessages!!!
    Very strange

  • CSV-2012-1675 IPC METHOD CORRECT

    Hi, I’m hoping someone can confirm I applied the csv-2012-1675 patch against the poison attack correctly? I applied the IPC method. A few days ago I started getting ORA-3136 on one of my servers. I need to rule out the poison attack as a possible cause!
    The instructions said I could use IPC method but it looks like it now has a TCP fix as well. I tried confirming the patch following instructions but I do not get the errors as described. My llistener "services" does show connecting as IPC.
    My server is a windows 11.1.0.7 NON-Rac used for our data warehouse. The data warehouse Informatica software is housed offsite so it does have an offsite client connection to another server. When I get an ORA-3136 error the data warehouse job also fails.
    Can anyone confirm the IPC patch method should work for my type of server OR why the COST test to see if it is working is not showing the expected error?
    Thanks for taking my questions!!
    Kathie

    Hi, I’m hoping someone can confirm I applied the csv-2012-1675 patch against the poison attack correctly? I applied the IPC method. A few days ago I started getting ORA-3136 on one of my servers. I need to rule out the poison attack as a possible cause!
    The instructions said I could use IPC method but it looks like it now has a TCP fix as well. I tried confirming the patch following instructions but I do not get the errors as described. My llistener "services" does show connecting as IPC.
    My server is a windows 11.1.0.7 NON-Rac used for our data warehouse. The data warehouse Informatica software is housed offsite so it does have an offsite client connection to another server. When I get an ORA-3136 error the data warehouse job also fails.
    Can anyone confirm the IPC patch method should work for my type of server OR why the COST test to see if it is working is not showing the expected error?
    Thanks for taking my questions!!
    Kathie

  • Re: junit test for entity beans ... ejb 3.0

    I'm confused. I'm trying to test my entity bean.
    I have:
    - an entity bean
    - a stateless session bean for accessing the entity bean (facade)
    - an interface for accessing the the stateless bean
    And I'm trying to write a JUnit test class to test this bean. However, I am uncertain as to how to test this (I'm new to EJB 3.0, JBoss and Eclipse).
    What would the JUnit test look like? I'm confused as to whether or not I should be injecting the interface/bean/what???
    I've tried several variations. I either get "NameNotFound" - not bound exceptions or Null pointer exceptions.
    What would the @EJB syntax look like or how would I do it through the context?
    For Example:
    @EJB private TestFacade myTest; //interface to stateless bean ?
    OR
    InitialContext ctx = new InitialContext();
    TestResultFacadeBean myTest = (TestResultFacadeBean) ctx.lookup("localTest");
    I'm confused at to which method I should be using and what object I should be accessing. If I could get either one to work, I'd be happy. :)
    How do I ensure my bean is deployed to the container? What do I need to do?
    If anyone has a simple example or explanation as to which method I should use and how to use it, I'd be very grateful.
    Thanks very much,
    LisaD

    OK, you need to have several layers of testing.
    Layer 0. Test the entity beans are deployable (more on this later). Basically, you need to know that all your annotations work. Things to watch out for are multiple @Id fields in one class or @EmbeddedID or @IdClass in conjuction with @ManyToOne, @ManyToMany, @OneToMany, @OneToOne and fun with @JoinTable, @JoinColumn and @JoinColumns. Once you know how these are supposed to work with the spec, it's not too bad to write it correctly each time. But there are some gotchas that will break things later on.
    Layer 1. Do the functions in the classes that don't depend on annotations work as expected. Typically, this is just going to be the getters and setters in your entity classes. Of course JUnit best practice says we don't bother testing functions that look like:
    public T getX() {
    return this.x;
    or
    public void setX(T x) {
    this.x = x;
    as there is nothing that can go wrong with them. So in that case, your level 1 tests will just be initial values specified from constructors and verifying that the non-get/set pairs work, and that the getters you have tagged @Transient work (because you've likely put some logic in them)
    Layer 2. Test the session bean methods that don't require injection to work.
    Layer 3. Test the session bean methods that require injection (Mock Objects). Simulate the injection for yourself, injecting Mock Objects for the entity manager. Then you can confirm that the correct methods are being called in the correct sequences, etc.
    [Note this may require some skill in designing the mock.  I'm working on developing my own entitymanager mock, and if it looks usefull I'll release it to the world.
    Layer 4. Test the session bean methods that require injection (Real entity manager) (See Layer 0)
    For this you will need an out of container persistence implementation.  Currently Hibernate and Glassfish provide beta versions.  You will need a different persistence.xml file that lists all the entities.  You will have to use reflection to inject the entity manager(s) that you create from an entity manager factory unless you provide a constructor that takes an EntityManager as a parameter.  You may need to use reflection to call any @PostConstruct method if you made it private.
    Layer 5. Navigate the relationships in the objects returned from Layer 4 using a database that has been loaded with test data.
    I am currently using Layers 0, 1, 2 & 4 to test my session beans and entity beans.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • NTLMv2 in Windows 2008 active or not?

    I have a Windows 2008 R2 member server which has no settings configured for NTLM.
    When I open the local group policy I see that the setting "Network security: LAN Manager authentication level" is "Not Defined"
    If I take a look at the registry location: Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa
    I see that there is no LMCompatibilitysetting present.
    What I want to know is how can I see if there are any NTLM settings active? Microsoft says that in Windows 2008 (r2) by default "NTLMv2 Response only" is active (LMcompatibilitysetting 3)
    If we look in Windows 2012 r2 we see also that this settings is configured as "Not Defined"

    Ok, but why doesn't it show in the register: Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa
    It only adds an entry when I make a choice for NTLM version in the local group policy
    If I do that it adds: LMCompatibilitysetting
    How can we see that it actually uses NTLMv2?
    Windows, and probably almost all modern computer software too, has defaults coded within the programs.
    These defaults apply even if the settings to set alternate/optional values don't exist. This is a very common practise in modern programming.
    In this example, LSA and the related lsass.exe will operate in default mode when the registry setting is absent.
    There is no value (to the program) to have the default setting recorded in registry - the program doesn't need that, and, to have every default setting recorded in registry is wasteful (increases the size of the registry while delivering no benefit to the
    program).
    It's a separate matter to determine/confirm the actual NTLM methods in use. To do that, you probably need to perform network traffic capture and analysis (e.g. with MSFT NetMon, or Wireshark [formerly known as Ethereal] and examine the packets captured)
    Don
    (Please take a moment to "Vote as Helpful" and/or "Mark as Answer", where applicable.
    This helps the community, keeps the forums tidy, and recognises useful contributions. Thanks!)

  • Create GR using BBP_PD_CONF_CREATE

    Hi Experts
    I have a requirement in which I have to automatically create GR from PO.
    For this I have created an FM. In this FM I first call BBP_CF_ASSIGNMENT and then map the header structure(without the dummy guid as it gives error in the BBP_PD_CONF_CREATE FM) and the item table.
    When I pass this data to BBP_PD_CONF_CREATE, my returned header structure has the new guid of confirmation but no object id, ie the confirmation number is not present. Also the returned item table is empty and when I try to save the confirmation I get the error 'Enter atleast one item'.
    Please help me out. I have been stuck here for a very long time now.
    Points will be rewarded.
    Thanks

    Hi Surendra
    I'm using SRM 7.1
    I have tried that approach. I can create confirmation for some POs but not for all using the class.
    I get a dump in create_conf_adv_instance method saying that : PO  contains no items for confirmation.
    Here is my code.
      lo_pd_model = /sapsrm/cl_pdo_model_factory=>get_instance( ).
      lo_pd_model->get_detail( EXPORTING iv_guid = im_po_guid
                                         iv_object_type = c_obj_typ_po
                               IMPORTING es_header   = ls_pd_header ).
      ls_selection-h_object_type = ls_pd_header-be_object_type.
    *ls_selection-number_int    = 1.
      ls_selection-logsys        = ls_pd_header-be_log_system."itm logsys
      ls_selection-object_id     = im_po_num.
      APPEND ls_selection TO lt_selection.
      CREATE OBJECT l_helper.
      TRY.
          CALL METHOD l_helper->get_enriched_po_data_for_conf   "To get open PO items
            EXPORTING
              iv_object_type     = c_obj_typ_be
              iv_subtype         = c_subtyp
              it_selection       = lt_selection
              iv_user_info       = ls_user_info
              iv_mode            = c_mode_dspl
              iv_process_type    = c_process_type
              iv_no_messages     = abap_false
            IMPORTING
              et_cfitem          = li_cfitem
    *         et_sdln_exist      = lt_sdln_exist
    *         ev_sdln_exist      = lv_sdln_exist
            CHANGING
              co_message_handler = co_message_handler.
       CATCH /sapsrm/cx_pdo_abort.                          "#EC NO_HANDLER
       CATCH /sapsrm/cx_pdo_parameter_error.                "#EC NO_HANDLER
      ENDTRY.
    CALL METHOD /sapsrm/cl_pdo_bo_conf_adv=>create_conf_adv_instance
        EXPORTING
          iv_subtype         = c_subtyp
          iv_header_guid     = im_po_guid
          iv_object_type     = c_obj_typ_be
    *     iv_number_int      = c_number_int
    *     iv_logsys          =
          iv_object_id       = im_po_num
          iv_user_type       = c_user_typ
        IMPORTING
          eo_instance        = lo_conf
        CHANGING
          co_message_handler = co_message_handler.
    *Getting header data of confirmation for updation
      TRY.
          CALL METHOD lo_conf->/sapsrm/if_pdo_bo_conf~get_header_detail
    *  EXPORTING
    *    it_requested_fields  =
            IMPORTING
              es_header            = ls_header_im
    *    eo_meta_data_handler =
            CHANGING
              co_message_handler   = co_message_handler
        CATCH /sapsrm/cx_pdo_abort .
      ENDTRY.
    *Updating header data of confirmation
      MOVE-CORRESPONDING ls_header_im TO ls_header_ex.
      ls_header_ex-description = 'TEST 10/2/2012'.
      l_guid = ls_header_im-guid.
      TRY.
          CALL METHOD lo_conf->/sapsrm/if_pdo_bo_conf~update_header
            EXPORTING
              is_header          = ls_header_ex
            CHANGING
              co_message_handler = co_message_handler.
        CATCH /sapsrm/cx_pdo_wrong_mode .
        CATCH /sapsrm/cx_pdo_abort .
      ENDTRY.
    *getting item data of confirmation
      CALL METHOD lo_conf->get_item_details_buffer
        IMPORTING
          et_itm_dtls_buf = li_item.
      LOOP AT li_cfitem INTO ls_cfitem.
        READ TABLE li_item ASSIGNING <fs_item>    
        WITH KEY number_int = ls_cfitem-number_int.
        IF sy-subrc EQ 0.
          MOVE-CORRESPONDING <fs_item> TO ls_item.
    *Marking final entry in confirmation
          ls_item-final_entry = c_x.
          BREAK-POINT.
          CONCATENATE c_obj_typ_po
                      <fs_item>-be_refobj_item+7(3)
                      INTO l_be_refobj_item_hist.
          ls_object_key-h_object_type = c_obj_typ_po.                   "'BUS2201'.   "PO Header
          ls_object_key-i_object_type = l_be_refobj_item_hist.        "'BUS2201001'. "Po Item
          ls_object_key-logsys = 'T85-010'.
          MOVE im_po_guid TO ls_object_key-h_guid.
          READ TABLE li_item_po ASSIGNING <fs_item_po>   " li_item_po contains PO data fetched using BBP_PD_PO_GETDETAIL
          WITH KEY NUMBER_INT = <fs_item>-NUMBER_INT.
          IF sy-subrc eq 0.
            MOVE <fs_item_po>-guid TO ls_object_key-i_guid.
          ENDIF.
    *       Get the PO Docuemnt History
          CALL FUNCTION 'BBP_PD_GETHISTORY'
            EXPORTING
              i_object_key                  = ls_object_key
            TABLES
              et_history                    = li_history
            EXCEPTIONS
              incomplete_object_information = 1
              OTHERS                        = 2.
          IF sy-subrc EQ 0.
            LOOP AT li_history INTO ls_history WHERE objtype EQ 'BUS2017'.
              IF ls_history-dcind EQ 'S'.    "Debit
                l_total_gr_qty = l_total_gr_qty + ls_history-quantity.
              ELSE."Credit
                l_total_gr_qty = l_total_gr_qty - ls_history-quantity.
              ENDIF.
              CLEAR ls_history.
            ENDLOOP.
            READ TABLE li_history INTO ls_history WITH KEY
            objtype = c_obj_typ_be. "'BUS2012'.
            IF sy-subrc EQ 0.
              l_total_po_qty = ls_history-quantity.
            ENDIF.
            ls_item-quantity = l_total_po_qty - l_total_gr_qty.
            BREAK-POINT.
          ENDIF.
          APPEND ls_item TO li_item_ex.
          CLEAR ls_item.
        ENDIF.
      ENDLOOP.
      TRY.
          CALL METHOD lo_conf->/sapsrm/if_pdo_bo_conf~update_item
            EXPORTING
              it_item            = li_item_ex
            CHANGING
              co_message_handler = co_message_handler.
        CATCH /sapsrm/cx_pdo_wrong_mode .
        CATCH /sapsrm/cx_pdo_abort .
      ENDTRY.
      TRY.
          CALL METHOD lo_conf->/sapsrm/if_pdo_base~submit_update
            CHANGING
              co_message_handler = co_message_handler.
        CATCH /sapsrm/cx_pdo_wrong_mode .
        CATCH /sapsrm/cx_pdo_abort .
      ENDTRY.
      TRY.
          CALL METHOD lo_conf->/sapsrm/if_pdo_adv_base~submit_decision
            CHANGING
              co_message_handler = co_message_handler.
        CATCH /sapsrm/cx_wf_decision_missing .
        CATCH /sapsrm/cx_pdo_error .
        CATCH /sapsrm/cx_pdo_abort .
      ENDTRY.
      TRY.
          CALL METHOD lo_conf->/sapsrm/if_pdo_base~save
    *  EXPORTING
    *    iv_msg_scenario    =
            CHANGING
              co_message_handler = co_message_handler
        CATCH /sapsrm/cx_pdo_abort .
        CATCH /sapsrm/cx_pdo_error .
      ENDTRY.
      CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
       EXPORTING
         wait          = 'X'
    * IMPORTING
    *   RETURN        =
    *Confirming
        TRY.
            CALL METHOD lo_conf->/sapsrm/if_pdo_bo_conf~confirm
              CHANGING
                co_message_handler = co_message_handler.
          CATCH /sapsrm/cx_pdo_abort .
          CATCH /sapsrm/cx_pdo_order_invalid .
          CATCH /sapsrm/cx_pdo_status_change .
          CATCH /sapsrm/cx_pdo_no_authorizatio .
          CATCH /sapsrm/cx_pdo_ts_not_found .
          CATCH /sapsrm/cx_pdo_error .
        ENDTRY.
    *Commit after confirmation completed
        CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
         EXPORTING
           wait          = 'X'
    * IMPORTING
    *   RETURN        =
    As I said, I dont know why but this code doesn't work for all the POs.
    Please share your code/suggest modification to my code.
    Also please share your contact details so that I can contact you, I'm stuck in this issue for a very long time and I need to close it asap.
    Thanks
    Ankit Pradhan

  • How to include javascript resources in  Facelet tag library

    I've been trying out Duncans watermark behavior tag (https://blogs.oracle.com/groundside/entry/placeholder_watermarks_with_adf_11). Indeed a great article and the example work perfectly when the tag library is included within the project and when the javascript resource (common.js) file is added to the document using af:resource tag.
    I would like to create a deployable tag library, including a setWatermarkBehavior tag, for reuse in various apps. I'm able to create and deploy the tag library as a ADF library and include it for use in an application. But on runtime, the pages are not able to find the "addWatermarkBehavior" method, which I hoped automatically got loaded from the javascript file defined in the tag library jar. In the tag library file, I've added a "adf-js-features.xml" in META-INF. This file and the .js file is included in the ADF library jar. "adf-js-features.xml" looks like this:
    <adf-js-features xmlns="http://xmlns.oracle.com/adf/faces/feature">
    <features xmlns="http://xmlns.oracle.com/adf/faces/feature">
    <feature>
    <feature-name>adfExtTaglib</feature-name>
    <feature-class>com/cgi/adf/ext/taglib/js/adfExtTaglib.js</feature-class>
    </feature>
    </features>
    </adf-js-features>
    I'm not sure, what value should be used for "feature-name" - I've tried many different "meaningful" names. I presume, that the ADF framework, should automatically discover all "adf-js-features" files and automatically load js-file on pages, which are using tags from the particular tag library. But apparently I'm missing something. In the facelets page used for testing, I have these few components.
    <f:view xmlns:f="http://java.sun.com/jsf/core" xmlns:af="http://xmlns.oracle.com/adf/faces/rich"
    xmlns:adfext="http://xmlns.cgi.com/adf/ext">
    <af:document title="testAdfExtTaglib" id="d1">
    <!-- af:resource type="javascript" source="/resources/js/common.js" / -->
    <af:form id="f1">
    <af:inputText label="Label 1" id="it1">
    <adfext:setWatermarkBehavior value="CHR-Nr"/>
    </af:inputText>
    </af:form>
    </af:document>
    </f:view>
    Doing some debugging, I can confirm that the "getScript" method of the setWatermarkBehavior class is called. I can also find the javascript produced by the "getScript" method in the DOM. But I cannot find anywhere in the DOM, where the javascript file from the tag library is loaded.
    Please, help me out?
    Edited by: wmjaboj on 2012-09-23 23:58

    The Javascript source URI has the value "RES_NOT_FOUND".
    If I try to access it using ".../faces/javax.faces.resource/javascript.js?ln=js" I get a blank page (contains a Html and Body only).
    If I try to access it using ".../faces/resources/js/javascript.js" I can download the javascript file from the taglib.
    If I manually copy the javascript.js file from the taglib into the enclosing project and save it in "resource/js", then the javascript source URI is resolved correctly to ".../faces/javax.faces.resource/javascript.js?ln=js" and I can downloaded it, but then it is the local copy and not the one from the taglib jar.
    Do I need some specific configuration in web.xml or other deployment descriptors, to be able to use "javax.faces.resource"?
    The only configurations whoch smells like "javax.faces.resource" is this context param: javax.faces.FACELETS_RESOURCE_RESOLVER=oracle.adfinternal.view.faces.facelets.rich.AdfFaceletsResourceResolver
    In web.xml various "resource" servlets is defined (I'm not sure whether I need them, JDeveloper has created them automatically):
    a) resources = org.apache.myfaces.trinidad.webapp.ResourceServlet, maps to: /adf/*, /afr/*, /bi/*
    b) adflibResources = oracle.adf.library.webapp.ResourceServlet, maps to: /adflib/*
    I appreciate your help.

  • Can't set the "print to file" path in firefox 10

    print.printer_PDF.print_to_filename
    print.printer_Print_to_File.print_to_filename
    In the previous version of Firefox those settings allowed me to print to a pdf file in a specified directory by default. In the ff10 they don't appear to have any effect? Are there new settings that replace these? Or, has this (awesome) functionality been removed for some reason?

    This is another suggestion if the bridge > preferences > file association option doesn't work. I just confirmed that the bridge method does work for me (Mac user who wants to mostly use CS5 but wants to use CS6 occasionally).
    My method that I worked out yesterday was to create a zip of the application files and then delete the originals (if you have extensions visible, they are the .app files). The logic being that if there is no application then the application can't open. Easy enough to unzip the applications when they are needed—and I confirmed taking the .apps out of cryofreeze will work.
    I know this won't work for most but it can work in a pinch - if you need to doubly ensure that you don't open and resave items in a version that doesn't work for your workflow.
    But hopefully the bridge preferences file association thing will keep working. Don't know what people do who doesn't install bridge.

  • Setting BitmapImage source inside the skin

    Hi all
    As a Flex 4 newbie, I've been banging my head for two days trying do to something that could seem pretty trivial to you (and to me as well at first sight) but lefted me completely clueless...
    I want to design a fairly simple custom component using the Gumbo architecture. My component falls into 2 parts:
    * a logo picture on the left side
    * a buttonbar next on the right side
    My component must be designed to be quite generic, that is to say the source of the logo image is a property of the component as well as the items of the ButtonBar.
    So here is what I did so far:
    I wrote an AS class describing the behavior of my component "MapToolBar.as":
    package nova.style
        import spark.components.ButtonBar;
        import spark.components.supportClasses.SkinnableComponent;
        import spark.primitives.BitmapImage;
        [SkinState("normal")]
        [SkinState("disabled")]
        public class MapToolBar extends SkinnableComponent
            // Define skin parts
            [SkinPart(required="false")]
            public var clientLogo:BitmapImage;
            [SkinPart(required="true")]
            public var tools:ButtonBar;
            // Define component data
            private var _logoSrc:String;
            public function set logoSrc(src:String):void {
                _logoSrc=src;
            [Bindable]
            public function get logoSrc():String {
                return _logoSrc;
            private var _toolsItems:Array;
            public function set toolsItems(items:Array):void {
                _toolsItems=items;
            [Bindable]
            public function get toolsItems():Array {
                return _toolsItems;
            public function MapToolBar()
                super();
            override protected function getCurrentSkinState():String {
                if (enabled) {
                    return "normal";
                } else {
                    return "disabled";
    And the associated skin mxml class:
    <?xml version="1.0" encoding="utf-8"?>
    <s:SparkSkin xmlns:fx="http://ns.adobe.com/mxml/2009"
                 xmlns:s="library://ns.adobe.com/flex/spark"
                 xmlns:mx="library://ns.adobe.com/flex/halo">
        <fx:Declarations>
            <!-- Place non-visual elements (e.g., services, value objects) here -->
        </fx:Declarations>
        <fx:Script>
            <![CDATA[
                import mx.collections.ArrayList;
                import nova.style.skins.ToolBarSkin;
                // Initialise les données des skinparts après leur création.
                private function handleCreationComplete(event:Event):void {
                    clientLogo.source = hostComponent.logoSrc;
                    tools.dataProvider = new ArrayList(hostComponent.toolsItems);
            ]]>
        </fx:Script>
        <s:states>
            <s:State name="disabled"/>
            <s:State name="normal"/>
        </s:states>
        <!-- host component -->
        <fx:Metadata>
            [HostComponent("nova.style.MapToolBar")]
        </fx:Metadata>
        <s:layout>
            <s:BasicLayout />
        </s:layout>
        <s:HGroup creationComplete="handleCreationComplete(event);">
            <s:BitmapImage id="clientLogo"/>
            <s:ButtonBar id="tools" skinClass="nova.style.skins.ToolBarSkin"/>
        </s:HGroup>
    </s:SparkSkin>
    As you can notice, my inner ButtonBar has got its own skinClass has well. This is because I'm trying to divide my application in as many reusable bricks as possible. So here's ToolBarSkin:
    <?xml version="1.0" encoding="utf-8"?>
    <s:SparkSkin xmlns:fx="http://ns.adobe.com/mxml/2009" xmlns:s="library://ns.adobe.com/flex/spark" alpha.disabled="0.5" xmlns:mx="library://ns.adobe.com/flex/halo">
        <!-- host component -->
        <fx:Metadata>
            <![CDATA[
             * @copy spark.skins.spark.ApplicationSkin#hostComponent
            [HostComponent("spark.components.ButtonBar")]
            ]]>
        </fx:Metadata>
        <s:states>
            <s:State name="normal"/>
            <s:State name="disabled"/>
        </s:states>
        <fx:Declarations>
            <!---
                 Specifies the skin class for the middle button(s) on the ButtonBar.
                 @default spark.skins.spark.ButtonBarMiddleButtonSkin
            -->
            <fx:Component id="middleButton">
                <s:ButtonBarButton skinClass="nova.style.skins.ToolBarButtonSkin"/>
            </fx:Component>
        </fx:Declarations>
        <s:Rect x="-5" alpha="0.8" left="1" right="1" top="1" bottom="1" radiusX="10" radiusY="10">
            <s:fill>
                <s:LinearGradient rotation="-90">
                    <s:GradientEntry color="#040303" ratio="0"/>
                    <s:GradientEntry color="#858584" ratio="1"/>
                </s:LinearGradient>
            </s:fill>
        </s:Rect>
        <!---
             @copy spark.components.SkinnableDataContainer#dataGroup
        -->
        <s:DataGroup id="dataGroup" top="5" left="10" right="5" bottom="5">
            <s:layout>
                <s:HorizontalLayout gap="12" />
            </s:layout>
        </s:DataGroup>
    </s:SparkSkin>
    And yes, the ButtonBarButton skin is also customized, 'cause I want to display an icon on them... Here it is :
    <?xml version="1.0" encoding="utf-8"?>
    <s:SparkSkin xmlns:fx="http://ns.adobe.com/mxml/2009"
                 xmlns:s="library://ns.adobe.com/flex/spark"
                 xmlns:mx="library://ns.adobe.com/flex/halo" xmlns:d="http://ns.adobe.com/fxg/2008/dt" xmlns:ai="http://ns.adobe.com/ai/2008" minWidth="21" minHeight="21" alpha.disabledStates="0.5">
        <!-- states -->
        <s:states>
            <s:State name="up" />
            <s:State name="over" stateGroups="overStates" />
            <s:State name="down" stateGroups="downStates" />
            <s:State name="disabled" stateGroups="disabledStates" />
            <s:State name="upAndSelected" stateGroups="selectedStates, selectedUpStates" />
            <s:State name="overAndSelected" stateGroups="overStates, selectedStates" />
            <s:State name="downAndSelected" stateGroups="downStates, selectedStates" />
            <s:State name="disabledAndSelected" stateGroups="selectedUpStates, disabledStates, selectedStates" />
        </s:states>
        <!-- host component -->
        <fx:Metadata>
            <![CDATA[
            [HostComponent("spark.components.ButtonBarButton")]
            ]]>
        </fx:Metadata>
        <fx:Script>
            /* Define the skin elements that should not be colorized.
            For toggle button, the graphics are colorized but the label is not. */
            static private const exclusions:Array = ["labelDisplay"];
            override public function get colorizeExclusions():Array {return exclusions;}
        </fx:Script>
        <s:Group d:id="2" d:type="layer" d:userLabel="Calque 1">
            <s:Group x="1" y="1" d:id="3">
                <s:Path alpha="0.7" winding="nonZero" ai:knockout="0" data="M2 30C0.896484 30 0 29.1016 0 28L0 2C0 0.896484 0.896484 0 2 0L28 0C29.1025 0 30 0.896484 30 2L30 28C30 29.1016 29.1025 30 28 30L2 30Z" >
                    <s:fill>
                        <s:LinearGradient x="15.0005" y="30" scaleX="29.9995" rotation="-90">
                            <s:GradientEntry color="#d9d9d9" ratio="0"/>
                            <s:GradientEntry color="#f2f2f2" ratio="1"/>
                        </s:LinearGradient>
                    </s:fill>
                </s:Path>
            </s:Group>
        </s:Group>
        <!-- Icone embarquée -->
        <s:HGroup horizontalCenter="0" verticalCenter="0"
                  creationComplete="img.source = hostComponent.data;">
            <!-- layer 8: icon -->
            <s:BitmapImage id="img" />
        </s:HGroup> 
    </s:SparkSkin>
    Finally, in my main application I invoke my component like this :
    <nova:MapToolBar logoSrc="@Embed(source='/assets/img/clients/ge.png')" skinClass="nova.style.MapToolBarSkin">
            <nova:toolsItems>
                <s:ButtonBarButton id="redBtn"
                                   label="Red"
                                   data="@Embed(source='/assets/img/crown.png')"
                                   />
                <s:ButtonBarButton id="orangeBtn"
                                   label="Orange"
                                   data="@Embed(source='/assets/img/disk.png')"
                                   />
                <s:ButtonBarButton id="yelloyBtn"
                                   label="Yellow"
                                   data="@Embed(source='/assets/img/nuclear.png')"
                                   />
            </nova:toolsItems>
        </nova:MapToolBar>
    Unfortunately,I get the following at runtime:
    * the logo image is never displayed - yet the path is correct and the step-by-step debug confirms that the handleCreationComplete() method gets called with correct values being assigned to my parts !
    * each buttonbarbutton throws this stackexception, and of course my button icons aren't displayed either, only buttons' backgrounds show up:
    ArgumentError: Error #2015: BitmapData non valide.
         at flash.display::BitmapData()
         at spark.primitives::BitmapImage/set source()[E:\dev\gumbo_beta2\frameworks\projects\spark\src\spark\primitives\BitmapImage.as:269]
         at nova.style.skins::ToolBarButtonSkin/___ToolBarButtonSkin_HGroup1_creationComplete()[C:\EnvDevEclipse\Workspace-Head\novacom-flex-proto-customcomp\src\nova\style\skins\ToolBarButtonSkin.mxml:56]
         at flash.events::EventDispatcher/dispatchEventFunction()
         at flash.events::EventDispatcher/dispatchEvent()
         at mx.core::UIComponent/dispatchEvent()[E:\dev\gumbo_beta2\frameworks\projects\framework\src\mx\core\UIComponent.as:11749]
         at mx.core::UIComponent/set initialized()[E:\dev\gumbo_beta2\frameworks\projects\framework\src\mx\core\UIComponent.as:1525]
         at mx.managers::LayoutManager/doPhasedInstantiation()[E:\dev\gumbo_beta2\frameworks\projects\framework\src\mx\managers\LayoutManager.as:759]
         at mx.managers::LayoutManager/doPhasedInstantiationCallback()[E:\dev\gumbo_beta2\frameworks\projects\framework\src\mx\managers\LayoutManager.as:1069]
    Any help would be really much appreciated
    Thanks
    Matt

    Well, I've already solved one of the two issues
    In order to display the icons on my buttonbar buttons, I just needed to point at {hostComponent.data.data} instead of {hostComponent.data}. I'm not sure why, but {hostComponent.data} in my skin class is a handle on my instance of ButtonBarButton, not its "data" property. Any explanation is welcomed
    I still have got the first issue though. Oddly enough my design works if I put an mx Image instead of the spark BitmapImage for the client logo. That will do the trick for the moment but I'd prefer to deliver a 100% pure spark component in my prototype, and I can see no reason why BitmapImage works inside my ButtonBarButtons and doesn't otherwise...

  • JSF 1.2 - Go Back hyperlink not really working

    I have this scenario: one.jsf displays a list of records whereby each record has a link to two.jsf. A simple page layout is below:
    <header section>
    <menu>
    <search options: selectOneMenu1, selectOneMenu2, inputText, and commandButton>
    <detail section - list of 10 records with hyperlinks to navigate to two.jsf>
    <page option>
    <footer>To navigate from one.jsf to two.jsf, I have this:
    <h:outputLink value="two.jsf" title="Click to view record's detail">
       <f:param name="id" value="#{item.ref}"/>
       <h:outputText value="#{msg.MORE_LABEL}" />
    </h:outputLink>     TEST 1: To navigate back from two.jsf to one.jsf, I have tried this without success - because all selected values on one.jsf are reset:
    <h:outputLink title="Go back" value="#{header['Referer']}">
       <h:outputText value="#{msg.BACK_LABEL}" />
    </h:outputLink>     TEST 2: Change scope of a backing bean of one.jsf to session scope. The ugly thing about doing it this way is the post results will always be shown (until the session expired). Yuck!
    TEST 3: I tried some JavaScript without success:
    <h:outputLink title="Go back" onclick="javascript:history.back();">
       <h:outputText value="#{msg.BACK_LABEL}" />
    </h:outputLink>     This, however, just refreshed/resubmitted two.jsf. What the...? I gather this is an inherent behaviour of JSF - or, at least up to version 1.2...
    Has anyone successfully implemented a Go Back button? Also, if you have, were you also able to bypass the browser's prompt requesting a re-submission? This seems to be a trivial functionality to have on a form but it seems JSF doesn't do it so easily. Hmm...

    Further to my reply above, I've managed to get the navigation from two.jsf back to one.jsf working...sort of. The codes below seem to cause a java.lang.NullPointerException:
    PageListing pl = (PageListing) FacesUtil.getRequestBeanMap("pageList");  // throws java.lang.NullPointerException
    pl.getCount(sql, values);Where getRequestBeanMap is:
    public static Object getRequestBeanMap(String bean)
       ExternalContext ec = FacesContext.getCurrentInstance().getExternalContext();
       return ec.getRequestMap().get(bean);
    }And PageListing is defined in faces-config.xml as:
    <managed-bean>
            <managed-bean-name>pageList</managed-bean-name>
            <managed-bean-class>mypackage.PageListing</managed-bean-class>       
            <managed-bean-scope>request</managed-bean-scope>
    </managed-bean>From what I can gather, the getRequestBeanMap method cannot return a reference to the pageList bean. Does h:outputLink generates a post method when clicked? I can confirm that the getCount method is working as it initially generates a list of pages for one.jsf.

Maybe you are looking for