Drupal查看如何过滤重叠日期范围的项目 [英] Drupal Views how to filter items overlapping a date range

查看:281
本文介绍了Drupal查看如何过滤重叠日期范围的项目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在Drupal我使用CCK添加一个datetime字段到我的自定义数据类型。它插入开始日期和结束日期字段。这就是我想要的。现在,我希望视图过滤和显示只有具有daterange(开始日期和结束日期)重叠今天日期的项目。有关如何在视图上设置它的任何想法?我认为奇怪的是,我的自定义内容类型的日期字段似乎不出现在视图列表中,当我试图添加一个过滤器。感谢。

in Drupal I have used CCK to add a datetime field to my custom data type. It inserts start date and end date fields. That is what I want. Now, I want Views to filter and show only the items that have the daterange (start date and end date) overlapping today's date. Any ideas on how to set it up on Views? What I think is strange is that the date fields of my custom content type don't seem to appear on the Views list when I am trying to add a filter. Thanks.

推荐答案

您应该启用日期模块,并使用特定于日期的过滤。它将比你更容易为你工作比CCK日期。

You should enable the Date module, and use the Date specific filtering. It will work much easier for you than getting CCK Date to work.

这篇关于Drupal查看如何过滤重叠日期范围的项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆