소스 검색

Adjusted model definition in GeoDjango tutorial.

The example uses the world border data set, where
one of the entries has a null field value.
David Smith 4 년 전
부모
커밋
6bc9283751
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      docs/ref/contrib/gis/tutorial.txt

+ 1 - 1
docs/ref/contrib/gis/tutorial.txt

@@ -203,7 +203,7 @@ model to represent this data::
         name = models.CharField(max_length=50)
         area = models.IntegerField()
         pop2005 = models.IntegerField('Population 2005')
-        fips = models.CharField('FIPS Code', max_length=2)
+        fips = models.CharField('FIPS Code', max_length=2, null=True)
         iso2 = models.CharField('2 Digit ISO', max_length=2)
         iso3 = models.CharField('3 Digit ISO', max_length=3)
         un = models.IntegerField('United Nations Code')