list.gsp
上传用户:steveyhw
上传日期:2019-05-13
资源大小:307k
文件大小:9k
- <html>
- <head>
- <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
- <meta name="layout" content="main" />
- <title><g:message code="customer.list" default="Customer List" /></title>
- <script type="text/javascript" src="${createLinkTo(dir:'js/dojo',file:'dojo.js')}">
- </script>
- <script type="text/javascript">
- dojo.require("dojo.widget.validate");
- dojo.require("dojo.widget.ComboBox");
- dojo.require("dojo.widget.Checkbox");
- dojo.require("dojo.widget.Editor");
- dojo.require("dojo.widget.DropdownDatePicker");
- dojo.require("dojo.widget.Button");
- </script>
- </head>
- <body>
- <div class="nav">
- <span class="menuButton"><a class="home" href="${createLinkTo(dir:'')}"><g:message code="home" default="Home" /></a></span>
- <span class="menuButton"><g:link class="create" action="create" params="${[_cusName:params._cusName,_cusProfession_id:params._cusProfession_id,_cusType_id:params._cusType_id,_cusLastchangefrom:params._cusLastchangefrom,_cusLastchangeto:params._cusLastchangeto,_cusDel:params._cusDel,max:params.max,sort:params.sort,offset:params.offset,order:params.order]}"><g:message code="customer.new" default="New Customer" /></g:link></span>
- </div>
- <div class="body">
- <h1><g:message code="customer.list" default="Customer List" /></h1>
- <g:if test="${flash.message}">
- <div class="message"><g:message code="${flash.message}" args="${flash.args}" default="${flash.defaultMessage}" /></div>
- </g:if>
- <g:form name="customer" controller="customer" action="list" method="post" enctype="multipart/form-data">
- <table border="0">
- <div >
- <tr >
- <td valign='middle' class='name'>
- <label for='_cusName' ><g:message code="customer.cusName" default="Cus Name" />:</label>
- </td>
- <td valign='middle' class='value ${hasErrors(bean:customer,field:'cusName','errors')}'>
- <input type="text" id='_cusName' name='_cusName' value="${params._cusName}" size="16" maxlength="12"/>
- </td>
- <td valign='middle' class='name'>
- <label for='_cusProfession'><g:message code="customer.cusProfession" default="Cus Profession" />:</label>
- </td>
- <td valign='middle' class='value'>
- <g:select optionKey="id" noSelection="['':'-全部-']" from="${Code.findAllByCkind(Ckind.findByCkiFlag('ProfessionType'))}" name='_cusProfession_id' value="${params._cusProfession_id}" ></g:select>
- </td>
- <td valign='middle' class='name'>
- <label for='_cusType_id'><g:message code="customer.cusType" default="Cus Type" />:</label>
- </td>
- <td valign='middle' class='value ${hasErrors(bean:customer,field:'conManType','errors')}'>
- <g:select optionKey="id" noSelection="['':'-全部-']" from="${Code.findAllByCkind(Ckind.findByCkiFlag('CustomerType'))}" name='_cusType_id' value="${params._cusType_id}" ></g:select>
- </td>
- </tr>
- <tr>
- <td valign='middle' class='name'>
- <label for='_cusLastchangefrom'><g:message code="customer.cusLastchange" default="cus Lastchange" />:</label>
- </td>
- <td valign='middle' class='value ${hasErrors(bean:customer,field:'Lastchange','errors')}'>
- <input readonly="true" type="text" dojoType="DropdownDatePicker" id="_cusLastchangefrom" name="_cusLastchangefrom" value="${params._cusLastchangefrom}"/>
- <input readonly="true" type="text" dojoType="DropdownDatePicker" id="_cusLastchangeto" name="_cusLastchangeto" value="${params._cusLastchangeto}"/>
- </td>
- <td valign='middle' class='name'>
- <g:checkBox name="_cusDel" value="${params._cusDel=='on'}" />
- </td>
- <td valign='middle' class='name'>
- <label for='_cusDel'><g:message code="search.all" default="Search all" /></label>
- </td>
- <td valign='middle' class='value' >
- <input class="save" type="submit" value="${message(code:'search', 'default':'Search')}"></input>
- </td>
- <td valign='middle' class='value'>
- </td>
- </tr>
- </div>
- </table>
- </g:form>
-
- <div class="list">
- <br>
- <table>
- <thead>
- <tr>
-
-
- <g:sortableColumn property="cusId" title="Cus Id" titleKey="customer.cusId" params="${[_cusName:params._cusName,_cusProfession_id:params._cusProfession_id,_cusType_id:params._cusType_id,_cusLastchangefrom:params._cusLastchangefrom,_cusLastchangeto:params._cusLastchangeto,_cusDel:params._cusDel,max:params.max,offset:params.offset]}"/>
-
- <g:sortableColumn property="cusName" title="Cus Name" titleKey="customer.cusName" params="${[_cusName:params._cusName,_cusProfession_id:params._cusProfession_id,_cusType_id:params._cusType_id,_cusLastchangefrom:params._cusLastchangefrom,_cusLastchangeto:params._cusLastchangeto,_cusDel:params._cusDel,max:params.max,offset:params.offset]}"/>
-
- <g:sortableColumn property="cusEname" title="Cus Ename" titleKey="customer.cusEname" params="${[_cusName:params._cusName,_cusProfession_id:params._cusProfession_id,_cusType_id:params._cusType_id,_cusLastchangefrom:params._cusLastchangefrom,_cusLastchangeto:params._cusLastchangeto,_cusDel:params._cusDel,max:params.max,offset:params.offset]}"/>
-
- <g:sortableColumn property="cusCompany" title="Cus Company" titleKey="customer.cusCompany" params="${[_cusName:params._cusName,_cusProfession_id:params._cusProfession_id,_cusType_id:params._cusType_id,_cusLastchangefrom:params._cusLastchangefrom,_cusLastchangeto:params._cusLastchangeto,_cusDel:params._cusDel,max:params.max,offset:params.offset]}"/>
-
- <th><g:message code="customer.cusSex" default="Cus Sex" /></th>
- <th><g:message code="state" default="State" /></th>
- </tr>
- </thead>
- <tbody>
- <g:each in="${customerList}" status="i" var="customer">
- <tr class="${(i % 2) == 0 ? 'odd' : 'even'}">
-
-
-
- <td><g:link action="show" id="${customer.id}" params="${[_cusName:params._cusName,_cusProfession_id:params._cusProfession_id,_cusType_id:params._cusType_id,_cusLastchangefrom:params._cusLastchangefrom,_cusLastchangeto:params._cusLastchangeto,_cusDel:params._cusDel,max:params.max,sort:params.sort,offset:params.offset,order:params.order]}">${customer.cusId?.encodeAsHTML()}</g:link></td>
-
- <td>${customer.cusName?.encodeAsHTML()}</td>
-
- <td>${customer.cusEname?.encodeAsHTML()}</td>
-
- <td>${customer.cusCompany?.encodeAsHTML()}</td>
-
- <td>${customer.cusSex?.encodeAsHTML()}</td>
- <td><g:delState del="${customer.cusDel}"/></td>
- </tr>
- </g:each>
- <% index = customerList.size() %>
- <g:while test="${index < 10}">
- <% index++ %>
- <tr class="${(index % 2) == 1 ? 'odd' : 'even'}">
- <td> </td>
- <td> </td>
- <td> </td>
- <td> </td>
- <td> </td>
- <td> </td>
- </tr>
- </g:while>
- </tbody>
- </table>
- </div>
- <div class="paginateButtons">
- <g:paginate total="${params.count}" params="${[_cusName:params._cusName,_cusProfession_id:params._cusProfession_id,_cusType_id:params._cusType_id,_cusLastchangefrom:params._cusLastchangefrom,_cusLastchangeto:params._cusLastchangeto,_cusDel:params._cusDel]}"/>
- </div>
- </div>
- </body>
- </html>