From 0f2b88f86f4b11fe7a1c82dba1f482bd0bee4f38 Mon Sep 17 00:00:00 2001 From: Lenovo Date: Thu, 8 Aug 2024 15:49:00 +0800 Subject: [PATCH] =?UTF-8?q?=E9=97=AA=E8=B4=AD=E5=BA=97=E8=8E=B7=E5=8F=96?= =?UTF-8?q?=E6=89=8B=E6=9C=BA=E5=8F=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- expand/ert/content.js | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/expand/ert/content.js b/expand/ert/content.js index 238f144..28dc9f4 100644 --- a/expand/ert/content.js +++ b/expand/ert/content.js @@ -107,7 +107,7 @@ document.addEventListener("mouseup", function(e) { } if (location.host === 'shangoue.meituan.com') { var cookies = document.cookie - var systype + var phone = localStorage.getItem('phone') var username var result = window.prompt('请输入需要绑定的系统登录账户', '') username = result @@ -118,7 +118,12 @@ document.addEventListener("mouseup", function(e) { xhr.open('POST', 'https://youshi.bj.cn/prod-api/mt/cookies', true) //xhr.open('POST', 'http://localhost/dev-api/mt/cookies', true) xhr.setRequestHeader("Content-Type","application/json") - var sendData = {'bingType': 1, 'cookie': cookies, 'userName': username, 'account': null, 'password': null, 'wmPoiName': wmPoiName} + var sendData + if (phone !== null && phone !== 'null') { + sendData = {'bingType': 1, 'cookie': cookies, 'userName': username, 'account': phone, 'password': null, 'wmPoiName': wmPoiName} + }else{ + sendData = {'bingType': 1, 'cookie': cookies, 'userName': username, 'account': null, 'password': null, 'wmPoiName': wmPoiName} + } xhr.send(JSON.stringify(sendData)) xhr.onreadystatechange = function () { if (xhr.readyState === 4 && xhr.status === 200) {