租房小程序前端代码
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

85 lines
2.7 KiB

6 months ago
6 months ago
6 months ago
  1. "use strict";
  2. const common_vendor = require("../../common/vendor.js");
  3. const _sfc_main = {
  4. data() {
  5. return {
  6. form: {
  7. invite: "",
  8. password: ""
  9. },
  10. rules: {
  11. invite: [
  12. {
  13. type: "string",
  14. required: true,
  15. message: "请输入邀请码",
  16. trigger: ["blur", "change"]
  17. }
  18. ]
  19. }
  20. };
  21. },
  22. methods: {
  23. submit() {
  24. common_vendor.index.navigateTo({
  25. url: "/pages_subpack/success/index?type=homeowner"
  26. });
  27. this.$refs.form.validate().then((res) => {
  28. common_vendor.index.showToast({
  29. icon: "none",
  30. title: "校验通过"
  31. });
  32. }).catch((errors) => {
  33. common_vendor.index.showToast({
  34. icon: "none",
  35. title: "校验失败"
  36. });
  37. });
  38. }
  39. }
  40. };
  41. if (!Array) {
  42. const _easycom_uv_input2 = common_vendor.resolveComponent("uv-input");
  43. const _easycom_uv_form_item2 = common_vendor.resolveComponent("uv-form-item");
  44. const _easycom_uv_button2 = common_vendor.resolveComponent("uv-button");
  45. const _easycom_uv_form2 = common_vendor.resolveComponent("uv-form");
  46. (_easycom_uv_input2 + _easycom_uv_form_item2 + _easycom_uv_button2 + _easycom_uv_form2)();
  47. }
  48. const _easycom_uv_input = () => "../../uni_modules/uv-input/components/uv-input/uv-input.js";
  49. const _easycom_uv_form_item = () => "../../uni_modules/uv-form/components/uv-form-item/uv-form-item.js";
  50. const _easycom_uv_button = () => "../../uni_modules/uv-button/components/uv-button/uv-button.js";
  51. const _easycom_uv_form = () => "../../uni_modules/uv-form/components/uv-form/uv-form.js";
  52. if (!Math) {
  53. (_easycom_uv_input + _easycom_uv_form_item + _easycom_uv_button + _easycom_uv_form)();
  54. }
  55. function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
  56. return {
  57. a: common_vendor.o(($event) => $data.form.invite = $event),
  58. b: common_vendor.p({
  59. type: "text",
  60. placeholder: "请输入邀请码",
  61. customStyle: "border-radius: 30px;margin-top:5px;background-color: #ffffff;padding:5px 20px;",
  62. border: "none",
  63. modelValue: $data.form.invite
  64. }),
  65. c: common_vendor.p({
  66. label: "经纪人邀请码",
  67. prop: "invite",
  68. labelWidth: "220"
  69. }),
  70. d: common_vendor.o($options.submit),
  71. e: common_vendor.p({
  72. type: "primary",
  73. text: "登录",
  74. customStyle: "margin-top: 30px;background-color: #1EC77A;border-radius: 30px;"
  75. }),
  76. f: common_vendor.sr("form", "2b213a40-0"),
  77. g: common_vendor.p({
  78. labelPosition: "top",
  79. model: $data.form,
  80. rules: $data.rules
  81. })
  82. };
  83. }
  84. const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render]]);
  85. wx.createPage(MiniProgramPage);