当前位置: 首页 > 知识库问答 >
问题:

如何设置PrimeFaces中的OrderList宽度

唐涛
2023-03-14

如何更改Primefaces中ListOrder的宽度?

我尝试了宽度或样式,但它不想要我想要的。它用卷轴保持小:

你知道吗?

我尝试了css:

    .orderlist {
        width:1000px;
    }

和p: orderList style leClass="orderlist"...

这样做,我的页面更大,但包含数据的区域(可滚动列表仍然很小。

共有3个答案

邹毅
2023-03-14
.ui-orderlist-list-container {
  width: 70%;
  margin-left: auto;
  margin-right: auto;
}
周浩淼
2023-03-14
.ui-orderlist .ui-orderlist-list {
    list-style-type: none;
    margin: 0;
    padding: 0;
    overflow:auto;
    height:200px;
    width:100%;
}

.ui-orderlist .ui-orderlist-list li {
    margin: 1px;
    padding: 2px;
}

.ui-orderlist .ui-orderlist-button {
    display:block;
    margin-bottom:0.3em;
}

.ui-orderlist .ui-orderlist-button.ui-button-text-icon-primary {
    width:100%;
}

.ui-orderlist .ui-orderlist-item {
    cursor:pointer;
    border:0px none;
    font-weight: inherit;
}

.ui-orderlist .ui-orderlist-caption {
    text-align: center;
    padding:4px 10px 4px 10px;
    border-bottom:0px none;
}

.ui-orderlist table {
    width:100%;
    border-collapse:collapse;
}
韦正业
2023-03-14

以下CSS对我来说很好:

.ui-orderlist-list {
    width:300px;
}
 类似资料:
  • @FacesConverter(“ContactConverter”)公共类ContactConverter实现转换器{ 我正在使用primefaces orderlist示例。但我面临这个空指针异常。谷歌后,我发现这个问题是一些与conveter有关的事情,但我不确定。谁能帮助我与转换器的简单的primeface orderlist。

  • 我使用PrimeFaces 3.5。我想在我的页面上使用orderList。下面是我的豆类课。 这是我的页面内容。 我对此破例了。 我在PrimeFaces showcase上尝试过这个例子,但它仍然不起作用。谁能告诉我出了什么问题吗?

  • 在每个按钮周围创建有点乏味,所以我想知道他们为什么选择这样做。我很确定他们有很好的理由这样做,但我不认为。对于初学者来说,脚手架很难阅读和建造。

  • 问题内容: 简单方案: 我需要为设置一个固定宽度。我试过了: 也 对于 乃至 但是的宽度仍然相同。 问题答案: 对于Bootstrap 4.0: 在Bootstrap4.0.0中,您不能可靠地使用这些类(在Firefox中有效,但在Chrome中不适用)。您需要使用OhadR的答案: 对于Bootstrap 3.0: 在twitter bootstrap 3中使用:其中*是宽度的列数。 对于Boo

  • 本文向大家介绍如何在HTML中设置表格宽度?,包括了如何在HTML中设置表格宽度?的使用技巧和注意事项,需要的朋友参考一下 要设置HTML中的表格宽度,请使用style属性。style属性指定元素的内联样式。该属性与HTML <table>标记一起使用,具有CSS属性的宽度。HTML5不支持<table>的width属性,因此CSS属性width与style属性一起用于设置表宽度。 请记住,样式属

  • orderList中的订单更改对list变量没有影响。我试过primefaces orderlist没有更新更改的顺序,primefaces:如何保存p:orderlist中重新排序的数据?并检查了其他多个问题,但没有一个对我有效。我在提交命令按钮中添加了流程和更新订单列表,在命令按钮中添加了ajax处理,直接添加到订单列表,但仍然没有任何内容。