yii 自动生成的内容,分页信息(Displaying 1-10 of 15 results.)如何修改或是yii cgridview template summary
问的白一点就是 Displaying 1-10 of 15 results 如何翻译
如果搜索的话, 搜这个会出来很多内容 yii cgridview template summary
好了,其他不说了,说下如何解决,解决前,先看一段官方介绍
http://www.yiiframework.com/doc/api/1.1/CBaseListView#summaryText-detail
参考:http://www.yiiframework.com/forum/index.php/topic/45752-modify-cgridview-template-summary/
打开慢的朋友,看下边我摘出来的就行了
the summary text template for the view. These tokens are recognized and will be replaced with the corresponding values:
- {start}: the starting row number (1-based) currently being displayed
- {end}: the ending row number (1-based) currently being displayed
- {count}: the total number of rows
- {page}: the page number (1-based) current being displayed, available since version 1.1.3
- {pages}: the total number of pages, available since version 1.1.3
按我的意思来理解,其实,这就是一个模板(template),里面提供了一些固定的变量(start,end,count,page,pages)在里面,这些固定的变量不能变,其他的随便你怎么搞都行,有兴趣的话,可以点链接多了解一些,急于解决问题的,往下看
<?php $this->widget('zii.widgets.grid.CGridView', array(
'id'=>'mv-film-chart-grid',
'dataProvider'=>$model->search(),
'filter'=>$model,
'summaryText' => '显示{start}-{end},一共{count}条记录',
'columns'=>array(
'id',
'vid',
'paixu',
'show_time',
array(
'class'=>'CButtonColumn',
),
),
)); ?>
'summaryText' => '显示{start}-{end},一共{count}条记录',
嗯,就是它了,加上,保存,再刷新看下吧 :)
yii 自动生成的内容,分页信息(Displaying 1-10 of 15 results.)如何修改或是yii cgridview template summary的更多相关文章
- Yii自动生成项目
我喜欢尝试新鲜的东西.以前一直用gii生成工具,前几天突然发现用shell的方法,感觉很不错.特此总结一下yii的几个命令. gii的工具页面: - Controller Generator ...
- [转] 不要被C++“自动生成”所蒙骗
http://www.cnblogs.com/fanzhidongyzby/archive/2013/01/12/2858040.html C++对象可以使用两种方式进行创建:构造函数和复制构造函数. ...
- 试试使用 eolinker 扫描 GitLab 代码注释自动生成 API 文档?
前言: 一般写完代码之后,还要将各类参数注解写入API文档,方便后续进行对接和测试,这个过程通常都很麻烦,如果有工具可以读取代码注释直接生成API文档的话,那会十分方便. 此前一直都是在使用eolin ...
- 不要被C++“自动生成”所蒙骗
http://www.cnblogs.com/fanzhidongyzby/archive/2013/01/12/2858040.html C++对象可以使用两种方式进行创建:构造函数和复制构造函数. ...
- airtest+poco多脚本、多设备批处理运行测试用例自动生成测试报告
一:主要内容 框架功能及测试报告效果 airtest安装.环境搭建 框架搭建.框架运行说明 airtest自动化脚本编写注意事项 二:框架功能及测试报告效果 1. 框架功能: 该框架笔者用来作为公司的 ...
- spring和mybatis集成,自动生成model、mapper,增加mybatis分页功能
软件简介 Spring是一个流行的控制反转(IoC)和面向切面(AOP)的容器框架,在java webapp开发中使用广泛.http://projects.spring.io/spring-frame ...
- springboot和mybatis集成,自动生成model、mapper,增加mybatis分页功能
整体思路和http://www.cnblogs.com/mahuan2/p/5859921.html相同. 主要讲maven的pom.xml和一些配置变化,详细说明. 软件简介 Spring是一个流行 ...
- day74:drf:drf其他功能:认证/权限/限流/过滤/排序/分页/异常处理&自动生成接口文档
目录 1.django-admin 2.认证:Authentication 3.权限:Permissions 4.限流:Throttling 5.过滤:Filtering 6.排序:OrderingF ...
- Spring boot入门(三):SpringBoot集成结合AdminLTE(Freemarker),利用generate自动生成代码,利用DataTable和PageHelper进行分页显示
关于SpringBoot和PageHelper,前篇博客已经介绍过Spring boot入门(二):Spring boot集成MySql,Mybatis和PageHelper插件,前篇博客大致讲述了S ...
随机推荐
- cas配置全攻略(转)
转:http://www.blogjava.net/tufanshu/archive/2011/01/21/343290.html 经过将近两天的测试,参考众多网友的贡献,终于完成了对cas的主要配置 ...
- [转]python集合set
Python中集合set是基本数据类型的一种,它有可变集合(set)和不可变集合(frozenset)两种.创建集合set.集合set添加.集合删除.交集.并集.差集的操作都是非常实用的方法. 来源网 ...
- JavaScript-学习一字符串
字符串可以存储一系列字符,如 "John Doe". 字符串可以是插入到引号中的任何字符.你可以使用单引号或双引号: 用于字符串的 + 运算符 + 运算符用于把文本值或字符串变量加 ...
- javascript小数相减会出现一长串的小数位数的原因
javascript小数相减会出现一长串的小数位数的原因 <script> var a='38.8'; var b='6.8'; alert(parseFloat(a)-parseFloa ...
- javascript 键值对
<script type="text/javascript"> var arr = new Array(); arr['cn'] = '中国'; arr['usa'] ...
- 【leetcode】62. Uniqe Paths
题目 https://oj.leetcode.com/problems/unique-paths/ A robot is located at the top-left corner of a m ...
- overload and overwrite in C++
1. overload : don't using it in different scope. it will hidden the one in base or global scope. 2. ...
- 直接插入排序(Straight Insertion Sort)的C语言实现
原创文章,转载请注明来自钢铁侠Mac博客http://www.cnblogs.com/gangtiexia 直接插入排序(Straight Insertion Sort)的基本思想是将新记录插入到 ...
- Kafka 集群消息监控系统:Kafka Eagle
Kafka Eagle 1.概述 在开发工作当中,消费 Kafka 集群中的消息时,数据的变动是我们所关心的,当业务并不复杂的前提下,我们可以使用 Kafka 提供的命令工具,配合 Zookeeper ...
- Tomcat基础教程(二)
上一篇说到了Tomcat的介绍,下载及安装,这一篇我会详述Tomcat服务器结构 一.Tomcat服务器结构图: Tomcat服务器中可以配置多个Service,每个Service可以包含多个Conn ...