123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687 |
- "use strict";
- const common_vendor = require("../../common/vendor.js");
- const _sfc_main = {
- data() {
- return {
- isChecked: true,
- isShake: false
- };
- },
- onLoad() {
- this.createUser();
- },
- methods: {
- //查询用户信息
- createUser() {
- this.$request.get({
- url: "system/temporaryUser",
- loadingTip: "加载中..."
- }).then((res) => {
- sessionStorage.setItem("user", JSON.stringify(res.data.user));
- sessionStorage.setItem("token", res.data.token);
- });
- },
- checkboxChange(e) {
- this.isChecked = !this.isChecked;
- },
- goTest() {
- if (!this.isChecked) {
- common_vendor.index.showToast({
- icon: "none",
- title: "请勾选并同意测评服务条款"
- });
- this.isShake = true;
- setTimeout(() => {
- this.isShake = false;
- }, 500);
- return;
- }
- common_vendor.index.navigateTo({
- url: "/newScale/EQtest/testPage"
- });
- },
- toggle() {
- this.$refs.popup.open();
- },
- close() {
- this.$refs.popup.close();
- this.isChecked = true;
- }
- }
- };
- if (!Array) {
- const _easycom_uni_icons2 = common_vendor.resolveComponent("uni-icons");
- const _easycom_uni_popup2 = common_vendor.resolveComponent("uni-popup");
- (_easycom_uni_icons2 + _easycom_uni_popup2)();
- }
- const _easycom_uni_icons = () => "../../node-modules/@dcloudio/uni-ui/lib/uni-icons/uni-icons.js";
- const _easycom_uni_popup = () => "../../node-modules/@dcloudio/uni-ui/lib/uni-popup/uni-popup.js";
- if (!Math) {
- (_easycom_uni_icons + _easycom_uni_popup)();
- }
- function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
- return {
- a: $data.isChecked,
- b: common_vendor.o((...args) => $options.checkboxChange && $options.checkboxChange(...args)),
- c: common_vendor.o((...args) => $options.toggle && $options.toggle(...args)),
- d: $data.isShake ? 1 : "",
- e: common_vendor.o((...args) => $options.goTest && $options.goTest(...args)),
- f: common_vendor.o(($event) => $options.close()),
- g: common_vendor.p({
- type: "clear",
- size: "30"
- }),
- h: common_vendor.o(($event) => $options.close()),
- i: common_vendor.sr("popup", "4f3adda6-0"),
- j: common_vendor.p({
- type: "bottom",
- ["background-color"]: "#fff"
- }),
- k: common_vendor.o(($event) => $options.toggle()),
- l: common_vendor.o(($event) => _ctx.agreeFun()),
- m: common_vendor.o(($event) => _ctx.unAgreeFun()),
- n: _ctx.modalFlag
- };
- }
- const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-4f3adda6"], ["__file", "E:/psy_web_share/newScale/EQtest/index.vue"]]);
- tt.createPage(MiniProgramPage);
|