(self, compiler, connection)
| 199 | lookup_name = "inmonth" |
| 200 | |
| 201 | def as_sql(self, compiler, connection): |
| 202 | lhs, lhs_params = self.process_lhs(compiler, connection) |
| 203 | rhs, rhs_params = self.process_rhs(compiler, connection) |
| 204 | # We need to be careful so that we get the params in right |
| 205 | # places. |
| 206 | params = lhs_params + rhs_params + lhs_params + rhs_params |
| 207 | return ( |
| 208 | "%s >= date_trunc('month', %s) and " |
| 209 | "%s < date_trunc('month', %s) + interval '1 months'" % (lhs, rhs, lhs, rhs), |
| 210 | params, |
| 211 | ) |
| 212 | |
| 213 | |
| 214 | class DateTimeTransform(models.Transform): |
nothing calls this directly
no test coverage detected