Перейти к содержимому
Меню
Чтобы взаимодействовать с сообществом, необходимо зарегистрироваться.
Этот вопрос был отмечен
1 Ответить
7434 Представления

I want to show a warning "The user information may be too old" if a res.partner's write_date (last modified date) is older than a year when form view is displayed on web. How can i achieve it if possible.

The warning can be placed anywhere on the web and it can be popup or fade out message, it doesn't matter. 

Аватар
Отменить
Лучший ответ

 Hi,

   we can make an alert on the form view by 

<xpath expr="//header" position="after">
<div class="alert alert-info" role="alert" style="height: 40px; margin-bottom:0px;" attrs="{'invisible':[condition]}">
The information is too old <strong></strong>.
</div>
</xpath>

  You can create a boolean field and update its values based on the condition  you have 

Аватар
Отменить