"use strict";
const common_vendor = require("../../../common/vendor.js");
const request_api = require("../../../request/api.js");
const common_assets = require("../../../common/assets.js");
const _sfc_main = {
  data() {
    return {
      navH: common_vendor.inject("navHeight"),
      content: ""
    };
  },
  onLoad() {
  },
  methods: {
    clickSubmit() {
      if (!this.content) {
        common_vendor.index.showToast({
          title: "请输入您要反馈的问题",
          icon: "none"
        });
        return;
      }
      let param = { content: this.content, isJson: 1 };
      request_api.feedback(param).then((res) => {
        if (res.code == 200) {
          common_vendor.index.showToast({
            title: res.message,
            icon: "none"
          });
          setTimeout(function() {
            common_vendor.index.navigateBack();
          }, 1e3);
        } else
          common_vendor.index.showToast({
            title: res.message,
            icon: "none"
          });
      }).catch((error) => {
      });
    }
  }
};
if (!Array) {
  const _easycom_navBar2 = common_vendor.resolveComponent("navBar");
  _easycom_navBar2();
}
const _easycom_navBar = () => "../../../components/navBar/navBar.js";
if (!Math) {
  _easycom_navBar();
}
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
  return {
    a: common_vendor.p({
      leftText: "意见反馈"
    }),
    b: common_assets._imports_0,
    c: $data.content,
    d: common_vendor.o(($event) => $data.content = $event.detail.value),
    e: common_vendor.s("top:" + $data.navH + "px;"),
    f: common_vendor.o(($event) => $options.clickSubmit())
  };
}
const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render]]);
wx.createPage(MiniProgramPage);
//# sourceMappingURL=../../../../.sourcemap/mp-weixin/pages/mine/feedback/feedback.js.map
