如何在sapui5文本或输入框中放入换行符?

时间:2019-02-13 09:28:07

标签: sapui5

我似乎找不到找到放置var fireHex = new FireHex(); // this will copy data and change behavior var waterHex = new WaterHex(fireHex); <DatePicker id="DP1" placeholder="Enter Date" value="{/recipient2/name}" change="handleChange" class="sapUiSmallMarginBottom"/>的方法 在新行中。它们显示在同一行中,但我希望它们显示在两条不同的行中。

<Select selectedKey="{/recipient3/name}"  id="input-c" forceSelection="false">

1 个答案:

答案 0 :(得分:1)

尝试将两者放入 Vbox

<Vbox>   
   <DatePicker id="DP1" placeholder="Enter Date" value="{/recipient2/name}" 
    change="handleChange" class="sapUiSmallMarginBottom"/>

  <InputListItem label="Country" >
       <Select selectedKey="{/recipient3/name}"  id="input-c" 
        forceSelection="false">
            <core:Item key="Greece" text="Greece"/>
            <core:Item key="Mexico" text="Mexico"/>
            <core:Item key="Norway" text="Norway"/>
            <core:Item key="New Zealand" text="New Zealand"/>
            <core:Item key="Netherlands" text="Netherlands"/>
       </Select>
  </InputListItem>

  <Button text="{i18n>showHelloButtonText}" press="onShowHello"/>
</Vbox>