Как мы можем показать диалоговое окно предупреждения для проверки, например, диалоговое окно предупреждения в гобелене 4?Tapestry 5 Alert Dialog
0
A
ответ
0
Вы имеете в виду Errors component, в котором содержится краткое содержание всех вализующих сообщений?
0
В гобелене вы можете использовать AlertManager для отображения предупреждения Dailog. Например,
public class Contact {
@Property
private Info info;
@Inject
private Session session;
@Inject
private AlertManager alertManager;
@InjectComponent
private Zone clickZone;
@Property
@Persist
private int clickCount;
@CommitAfter
public void onSuccess() {
session.persist(info);
}
public void onActionFromIncrement() {
clickCount++;
alertManager.info("increment clicked"); // here you can see how alertManager is working.
}
Object onActionFromIncrementByAjay() {
clickCount++;
alertManager.info("ajax call");
return clickZone;
}
}
Вам не нужно ничего добавлять в свои файлы в формате tml. Вы просто импортируете и используете информационный метод alertManager и показываете оповещение по умолчанию, как хотите.
Смежные вопросы
- 1. Android alert alert dialog
- 2. Tapestry - Alert - Hide Dismiss All
- 3. Tapestry 5.4 Beanedit form alert
- 4. Tapestry 5, jQuery UI Dialog и действие close
- 5. Alert Dialog- Получение ошибки
- 6. Alert Dialog Two Buttons
- 7. Alert Dialog Не подходит
- 8. Alert Dialog error
- 9. Alert Dialog не закрыт
- 10. Alert Dialog сбой приложения
- 11. Alert Dialog Customization
- 12. spinner in Alert Dialog
- 13. Android AsyncTask Dialog Alert
- 14. Javafx Alert Dialog + HTML
- 15. Alert Dialog in android
- 16. Android Alert Dialog Looping
- 17. Tapestry 5 аутентификация пользователя
- 18. Tapestry 5 component problem
- 19. Показать сообщение в Alert Dialog
- 20. update ui on alert dialog
- 21. Android Custom Alert Dialog Design
- 22. Hide Alert Dialog in MonoDroid
- 23. Simple Alert Dialog Issue - Android
- 24. clickable text in alert dialog
- 25. Alert Dialog from Thread - Android
- 26. Capture Alert Dialog Button Событие
- 27. Android Alert Dialog не увольняет
- 28. Normal Alert Dialog в Android
- 29. Android - Alert Dialog force close
- 30. Ошибка Alert Dialog в Android
Нет, не компонент ошибки. Это похоже на диалог, содержащий всю проверку ошибок в форме. он не отправляет запрос на сервер. потому что все проверки выполняются на клиенте. как этот http://tapestry.apache.org/tapestry4.1/javascript/form-validation.html – nathan21
@Nathan: Это было заменено встроенными уведомлениями о проверке, которые показывают ошибки прямо в местах, где они происходят (красная метка , всплывающий пузырь). Такой диалог предупреждения не существует в T5. – Henning
Ok Спасибо, Хеннинг – nathan21