콘텐츠로 건너뛰기
메뉴
커뮤니티에 참여하려면 회원 가입을 하시기 바랍니다.
신고된 질문입니다
1 회신
3404 화면

Hey guys, I was hoping someone could check over my implementation.

I have defined this model (and only included the relevant parts)


class EstateProperty(models.Model): 

  expected_price = fields.Float(required=True)

  _sql_constraints = [        ('check_expected_price', 'CHECK(expected_price > 0)',         'The expected price should be positive')    ]


Is this wrong? When I try to save negative numbers onto my form, my system is allowing it. 

아바타
취소
베스트 답변

Hi, did you upgrade your module ?

Gus

아바타
취소
관련 게시물 답글 화면 활동
1
11월 22
5838
2
11월 18
10316
1
3월 15
6122
4
3월 15
5375
1
3월 15
3683