SearchForm.ui.qml 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104
  1. import QtQuick 2.7
  2. import QtQuick.Controls 2.0
  3. import QtQuick.Layouts 1.0
  4. import "views" as Views
  5. Item {
  6. property alias unitCodesSwitch: unitCodesSwitch
  7. property alias unitsTree: unitsTree
  8. property alias resetButton: resetButton
  9. property alias unitFilterText: unitFilterText
  10. //property alias busyIndicator: busyIndicator
  11. ColumnLayout {
  12. id: searchLayout
  13. spacing: 1
  14. anchors.bottomMargin: 40
  15. anchors.fill: parent
  16. RowLayout {
  17. id: quickSearchLayout
  18. width: 100
  19. height: 100
  20. spacing: 1
  21. TextField {
  22. id: quickSearchText
  23. Layout.fillWidth: true
  24. placeholderText: qsTr("Быстрый поиск")
  25. }
  26. Button {
  27. id: quickSearchButton
  28. text: qsTr("Поиск")
  29. }
  30. }
  31. RowLayout {
  32. id: middle0Layout
  33. width: 100
  34. height: 100
  35. Switch {
  36. id: unitCodesSwitch
  37. text: qsTr("коды подр.")
  38. }
  39. Button {
  40. id: advancedSearchButton
  41. text: "Расширенный поиск"
  42. Layout.fillWidth: true
  43. }
  44. }
  45. RowLayout {
  46. id: middle1Layout
  47. width: 100
  48. height: 100
  49. Button {
  50. id: resetButton
  51. width: 75
  52. text: qsTr("Сбросить")
  53. }
  54. TextField {
  55. id: unitFilterText
  56. placeholderText: qsTr("Фильтр подразделений")
  57. Layout.fillWidth: true
  58. }
  59. }
  60. Views.UnitsTree {
  61. id: unitsTree
  62. Layout.fillHeight: true
  63. Layout.fillWidth: true
  64. }
  65. }
  66. Item {
  67. id: pageNameLayout
  68. height: 40
  69. anchors.right: parent.right
  70. anchors.rightMargin: 0
  71. anchors.left: parent.left
  72. anchors.leftMargin: 0
  73. anchors.bottom: parent.bottom
  74. anchors.bottomMargin: 0
  75. Text {
  76. id: pageName
  77. text: qsTr("Поиск")
  78. font.pixelSize: parent.width > 300 ? 24 : 12
  79. verticalAlignment: Text.AlignVCenter
  80. horizontalAlignment: Text.AlignHCenter
  81. renderType: Text.QtRendering
  82. font.capitalization: Font.MixedCase
  83. anchors.fill: parent
  84. }
  85. }
  86. }