W3C home > Mailing lists > Public > public-xformsusers@w3.org > October 2016

Re: toggle on a switch with caseref

From: Philip Fennell <Philip.Fennell@marklogic.com>
Date: Fri, 21 Oct 2016 07:24:06 +0000
To: Steven Pemberton <steven.pemberton@cwi.nl>, "public-xformsusers@w3.org" <public-xformsusers@w3.org>
Message-ID: <D50FB3B5-AE04-4B92-93BD-F66D82701AC8@marklogic.com>
Hello Steven,

> do we agree that @method gets the value "cash" assigned?

That’s both logical and consistent.


Philip



On 20/10/2016 14:14, "Steven Pemberton" <steven.pemberton@cwi.nl> wrote:

    In the context of
    
      <switch ref="payment/details" caseref="@method">
       <case name="creditCard" label="Credit Card Details">
         ...
       </case>
       <case name="cash" label="Cash">
         ...
       </case>
       ...
      </switch>
    
    if I do
    
      <setvalue "payment/details@method">cash</setvalue>
    
    then the cash case will be selected.
    
    If I do
    
      <toggle case="cash"/>
    
    do we agree that @method gets the value "cash" assigned?
    
    The current text is rather opaque:
    
    "If the switch that contains the identified case specifies the caseref  
    attribute, then the behavior of this action is associated with the ability  
    to successfully perform a setvalue on the node indicated by the caseref.  
    If the caseref does not indicate a node or if the node is readonly, then  
    this action has no effect. Otherwise, the node value is changed to the  
    IDREF value obtained above, which then results in the three toggle steps  
    described above."
    
    I intend to rewrite this, once I'm sure we agree on the effect.
    
    Steven
    
    

Received on Friday, 21 October 2016 07:24:38 UTC

This archive was generated by hypermail 2.3.1 : Friday, 21 October 2016 07:24:39 UTC