filterhouse.vue 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121
  1. <template>
  2. <div>
  3. <van-nav-bar
  4. @click-left="onClickLeft"
  5. @click-right="onClickRight"
  6. style="background-color: #1989fa"
  7. >
  8. <template #title>
  9. <van-col style="color: #ffffff">筛选房源</van-col>
  10. </template>
  11. <template #left>
  12. <i
  13. class="fa fa-arrow-circle-left"
  14. aria-hidden="true"
  15. style="color: #ffffff; font-size: 18px"
  16. ></i>
  17. </template>
  18. <template #right>
  19. <van-icon name="replay" size="18" color="#ffffff" />
  20. </template>
  21. </van-nav-bar>
  22. <van-form @submit="onSubmit">
  23. <van-cell title="楼栋" value="请选择" is-link title-class="title1" value-class="value1"></van-cell>
  24. <van-cell title="户型" value="请选择" is-link title-class="title1" value-class="value1"></van-cell>
  25. <van-field
  26. v-model="danyuan"
  27. label="单元号"
  28. placeholder="请输入"
  29. input-align="right"
  30. label-class="title1"
  31. />
  32. <van-field
  33. v-model="fangjian"
  34. label="房间号"
  35. placeholder="请输入"
  36. input-align="right"
  37. label-class="title1"
  38. />
  39. <div style="margin: 16px;">
  40. <van-button round block type="info" native-type="submit">查询</van-button>
  41. </div>
  42. </van-form>
  43. </div>
  44. </template>
  45. <script>
  46. import { GetSaClientSummary } from "@/common/api/loginApi.js";
  47. export default {
  48. name: "login",
  49. data() {
  50. return {
  51. data: [],
  52. danyuan:'',
  53. fangjian:''
  54. };
  55. },
  56. created: function () {
  57. console.info("created");
  58. //console.info(this.$util);
  59. this.$util.persistLogin(this);
  60. },
  61. computed:{ //计算属性
  62. },
  63. methods: {
  64. GetSaClientSummary: function () {
  65. var that = this;
  66. var data = {
  67. userCode: that.$store.state.data.userCode,
  68. projectId: that.$store.state.projectId
  69. };
  70. console.info("data", data);
  71. GetSaClientSummary(data).then((res) => {
  72. console.info("GetSaClientSummary", res);
  73. if (!res.result) {
  74. that.$toast(res.msg);
  75. return;
  76. }
  77. res.data.forEach(function (item, index, array) {
  78. that.$set(that.data, index, item);
  79. });
  80. that.loading = false;
  81. that.finished = true;
  82. });
  83. },
  84. onSubmit(values) { //提交按钮
  85. console.log('submit', values);
  86. },
  87. onClickLeft() {
  88. // this.$toast('返回')
  89. console.info("left");
  90. this.$router.go(-1);
  91. },
  92. onClickRight() {
  93. this.$router.go(0);
  94. },
  95. },
  96. };
  97. </script>
  98. <!-- Add "scoped" attribute to limit CSS to this component only -->
  99. <style scoped>
  100. .title1 {
  101. color: #999;
  102. text-align: left;
  103. }
  104. .value1 {
  105. color: #1732cf;
  106. font-size: 18px;
  107. font-weight: 800;
  108. }
  109. .size{
  110. font-size:16px;
  111. }
  112. </style>