Просмотр исходного кода

修改statementbill页面中样式中列宽度

klzhangweiya 7 месяцев назад
Родитель
Сommit
8e118566a8

+ 3 - 3
src_0nline/ShwasherSys/ShwasherSys.Web/Views/InvoiceInfo/InvoiceCreate.cshtml

@@ -161,9 +161,9 @@ new SearchItem("isbill", "开票状态").SetSearchItem(stickBillStatusList)
 
             <form class="form-horizontal" style="padding: 0 10px" id="form">
                 <div class="form-group-sm row">
-                    <label class="iwb-label col-md-1 control-label" for="customerName">客户:</label>
+                    <label class="iwb-label col-md-1 control-label" for="customerName1">客户:</label>
                     <div class="col-md-2">
-                        <label class="lable-value" id="customerName"></label>
+                        <label class="lable-value" id="customerName1"></label>
                     </div>
                     <label class="iwb-label col-md-1 control-label " for="address">地址:</label>
                     <div class="col-md-2" style="padding: 0 5px">
@@ -283,7 +283,7 @@ new SearchItem("isbill", "开票状态").SetSearchItem(stickBillStatusList)
                 isValiate: false,
                 success: function(res) {
                     if (res) {
-                        $("#customerName").html(res.customerName);
+                        $("#customerName1").html(res.customerName);
                         $("#address").html(res.address);
                         $("#telephone").html(res.telephone);
                         $("#linkMan").html(res.linkMan);

+ 28 - 17
src_0nline/ShwasherSys/ShwasherSys.Web/Views/InvoiceInfo/StatementBill.cshtml

@@ -209,26 +209,26 @@
                                data-query-params="QueryParams"
                                data-response-handler="ResponseHandler"
                                data-click-to-select="true"
-                               data-single-select="false">
+                               data-single-select="false" >
                             <thead>
                             <tr class="row" id="header">
                                 <th data-field="state" data-checkbox="true"></th>
                                 <th data-align="center" data-field="orderNo">流水号</th>
-                                <th data-align="center" data-field="stockNo">客户订单号 </th>
+                                <th data-align="center" data-field="stockNo"  >客户订单号 </th>
                                 <th data-align="center" data-field="orderSendBillNo">发货单号</th>
                                 <th data-align="center" data-field="customerId">客户编号</th>
-                                <th data-align="center" data-field="productNo">产品编号</th>
-                                <th data-align="center" data-field="productDesc">产品描述</th>
-                                <th data-align="center" data-field="partNo">零件号</th>
-                                <th data-align="center" data-field="productName">产品名称</th>
-                                <th data-align="center" data-field="model">规格</th>
-                                <th data-align="center" data-field="surfaceColor">表色</th>
+                                <th data-align="center" data-field="productNo"  >产品编号</th>
+                                <th data-align="center" data-field="partNo"   >零件号</th>
+                                <th data-align="center" data-field="productName" >产品名称</th>
+                                <th data-align="center" data-field="model"  >规格</th>
+                                <th data-align="center" data-field="surfaceColor"  data-formatter="SurfaceColorFormatter">表色</th>
                                 <th data-align="center" data-field="rigidity">硬度</th>
-                                <th data-align="center" data-field="sendQuantity">数量</th>
+                                <th data-align="center" data-field="sendQuantity" >数量</th>
                                 <th data-align="center" data-field="orderUnitName">单位</th>
-                                <th data-align="center" data-field="orderDate">订单日期</th>
-                                <th data-align="center" data-field="sendActionDate">送货日期</th>
+                                <th data-align="center" data-field="orderDate" data-formatter="DateFormatter">订单日期</th>
+                                <th data-align="center" data-field="sendActionDate" data-formatter="DateFormatter">送货日期</th>
                                 <th data-align="center" data-field="linkName">联系人</th>
+                                <th data-align="center" data-field="productDesc"   data-formatter="ProductDescFormatter">产品描述</th>
 
                             </tr>
                             </thead>
@@ -251,18 +251,18 @@
                                     <th data-align="center" data-field="orderSendBillNo">发货单号</th>
                                     <th data-align="center" data-field="customerId">客户编号</th>
                                     <th data-align="center" data-field="productNo">产品编号</th>
-                                    <th data-align="center" data-field="productDesc">产品描述</th>
+                                   
                                     <th data-align="center" data-field="partNo">零件号</th>
                                     <th data-align="center" data-field="productName">产品名称</th>
                                     <th data-align="center" data-field="model">规格</th>
-                                    <th data-align="center" data-field="surfaceColor">表色</th>
+                                    <th data-align="center" data-field="surfaceColor" data-formatter="SurfaceColorFormatter">表色</th>
                                     <th data-align="center" data-field="rigidity">硬度</th>
                                     <th data-align="center" data-field="sendQuantity">数量</th>
                                     <th data-align="center" data-field="orderUnitName">单位</th>
-                                    <th data-align="center" data-field="orderDate">订单日期</th>
-                                    <th data-align="center" data-field="sendActionDate">送货日期</th>
+                                    <th data-align="center" data-field="orderDate" data-formatter="DateFormatter">订单日期</th>
+                                    <th data-align="center" data-field="sendActionDate" data-formatter="DateFormatter">送货日期</th>
                                     <th data-align="center" data-field="linkName">联系人</th>
-
+                                    <th data-align="center" data-field="productDesc" data-formatter="ProductDescFormatter">产品描述</th>
                                 </tr>
                                 </thead>
                             </table>
@@ -329,7 +329,7 @@
             funs["btnShow"] = function () {
                 var row = $table.bootstrapTable("getSelections")[0];
                 if (row) {
-                    window.open("@Url.Action("StatementBillDetail","InvoiceInfo")/" + row.statementBillNo, "_blank");
+                    window.open("@Url.Action("StatementBillDetail", "InvoiceInfo")/" + row.statementBillNo, "_blank");
                 }
                 @*window.open("@Url.Action("InvoiceDetail","InvoiceInfo")/" + row.id, "_blank");*@
             }
@@ -504,6 +504,16 @@
 
     <!--格式化-->
     <script id="formatter-script" type="text/javascript">
+        function SurfaceColorFormatter(v) {
+			return `<div style="text-align: center; overflow: hidden;width: 120px;
+                      text-overflow: ellipsis;
+                      white-space: nowrap;">${v}</div>`
+        }
+		function ProductDescFormatter(v) {
+			return `<div style="text-align: center; overflow: hidden;width: 150px;
+              text-overflow: ellipsis;
+              white-space: nowrap;">${v?v:'-'}</div>`
+		}
         function DutyFormatter(v) {
             var name = $('#hid-du option[value="' + v + '"]').text();
             if (name) {
@@ -546,6 +556,7 @@
 
             }
         }
+    
     </script>
 }