123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103 |
- "use strict";
- var common_vendor = require("../common/vendor.js");
- var api_inquiryOrder = require("../api/inquiryOrder.js");
- var api_doctor = require("../api/doctor.js");
- require("../common/request.js");
- const _sfc_main = {
- data() {
- return {
- hospital: null,
- department: null,
- doctor: null,
- form: {
- orderId: null,
- starCount: 5,
- pingStar: 0,
- pingContent: ""
- }
- };
- },
- onLoad(options) {
- this.form.orderId = options.orderId;
- this.getMyInquiryOrderById();
- },
- methods: {
- getMyInquiryOrderById() {
- var data = { orderId: this.form.orderId };
- api_inquiryOrder.getMyInquiryOrderById(data).then((res) => {
- if (res.code == 200) {
- this.order = res.data.order;
- this.doctorId = this.order.doctorId;
- this.getDoctorDetails();
- }
- }, (err) => {
- });
- },
- getDoctorDetails() {
- var data = { doctorId: this.doctorId };
- api_doctor.getDoctorDetails(data).then((res) => {
- if (res.code == 200) {
- this.doctor = res.data.doctor;
- this.department = res.data.department;
- this.hospital = res.data.hospital;
- }
- }, (rej) => {
- });
- },
- submit() {
- common_vendor.index.showLoading({
- title: "\u5904\u7406\u4E2D..."
- });
- api_inquiryOrder.pingOrder(this.form).then((res) => {
- common_vendor.index.hideLoading();
- if (res.code == 200) {
- common_vendor.index.showToast({
- icon: "success",
- title: "\u8BC4\u4EF7\u6210\u529F"
- });
- common_vendor.index.$emit("refreshInquiryOrder");
- setTimeout(function() {
- common_vendor.index.navigateBack({
- delta: 1
- });
- }, 2e3);
- } else {
- common_vendor.index.showToast({
- icon: "none",
- title: res.msg
- });
- }
- }, (rej) => {
- });
- }
- }
- };
- if (!Array) {
- const _easycom_u_rate2 = common_vendor.resolveComponent("u-rate");
- _easycom_u_rate2();
- }
- const _easycom_u_rate = () => "../uni_modules/uview-plus/components/u-rate/u-rate.js";
- if (!Math) {
- _easycom_u_rate();
- }
- function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
- return {
- a: $data.doctor.avatar,
- b: common_vendor.t($data.doctor.doctorName),
- c: common_vendor.t($data.department.deptName),
- d: common_vendor.t($data.doctor.position),
- e: common_vendor.t($data.hospital.hospitalName),
- f: common_vendor.o(($event) => $data.form.pingStar = $event),
- g: common_vendor.p({
- size: "24",
- ["active-color"]: "#fcab36",
- modelValue: $data.form.pingStar
- }),
- h: $data.form.pingContent,
- i: common_vendor.o(($event) => $data.form.pingContent = $event.detail.value),
- j: common_vendor.t($data.form.pingContent.length),
- k: common_vendor.o(($event) => $options.submit())
- };
- }
- var MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-057d5462"], ["__file", "E:/Project/2023/\u95EE\u8BCA\u5E73\u53F0/his_user_miniapp/pages_order/pingOrder.vue"]]);
- wx.createPage(MiniProgramPage);
|