| | |
| | | import config from "@/assets/js/config.js"; |
| | | |
| | | import config from "./config.js"; |
| | | import jobApi from "./middleGround/api/job"; // newJobWithNewView // newSession, |
| | | |
| | | export function setSessionGuid(type, id) { |
| | |
| | | }; |
| | | |
| | | jobApi.newSession(params).then(res => { |
| | | storage.set("sessionGuid", res, 30); |
| | | wx.setStorageSync("sessionGuid", res); |
| | | setNewView(type, id); |
| | | }); |
| | | } |
| | |
| | | } |
| | | |
| | | export function setNewView(type, id) { |
| | | if (!sessionStorage.getItem("sessionGuid")) { |
| | | if (!wx.getStorageSync("sessionGuid")) { |
| | | setSessionGuid(type, id); |
| | | } |
| | | |
| | | const sessionGuid = sessionStorage.getItem("sessionGuid"); |
| | | const fromPath = sessionStorage.getItem("fromPath"); |
| | | const toPath = sessionStorage.getItem("toPath"); |
| | | const sessionGuid = wx.getStorageSync("sessionGuid"); |
| | | const fromPath = wx.getStorageSync("fromPath"); |
| | | const toPath = wx.getStorageSync("toPath"); |
| | | if (sessionGuid) { |
| | | let params = { |
| | | sessionGuid: sessionGuid, |