import { wxminiConfigService } from "@reco-mobile/ipark-common";
interface ParamProp {
secondTypeValue: string | number;
thirdTypeValue: string | number;
img: string;
}
export class Share {
code;
param;
constructor(code) {
this.code = code;
}
async refreshShareConfig(param: ParamProp) {
let data = await wxminiConfigService.bycode(this.code);
console.log("data", param, data, location);
wx["miniProgram"].postMessage({
data: {
title: "7895556",
path: `/apps-web-view/apps-web-view/apps-web-view?route=${JSON.stringify(encodeURIComponent(location.href))}&anonymous=true`,
imageUrl: "",
},
});
}
}
export default BiparkShare;
share = new Share("GoodsServicesShare");
this.share.refreshShareConfig({
secondTypeValue: this.secondGoodsTypeValue,
thirdTypeValue: this.thirdGoodTypeValue,
img: "",
});