From e311a42e99ce69aa9de0ec8a62d3a460e1ef4eac Mon Sep 17 00:00:00 2001 From: yumoqing Date: Wed, 5 Aug 2026 17:54:51 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20script=20bind=E5=8A=A0=E8=AF=8A=E6=96=AD?= =?UTF-8?q?=E2=80=94=E8=8B=A5${id}$=E6=9C=AA=E6=9B=BF=E6=8D=A2=E5=88=99ale?= =?UTF-8?q?rt=E6=8F=90=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- json/discount_marketing_list.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/json/discount_marketing_list.json b/json/discount_marketing_list.json index f455e3d..fa6fe4c 100644 --- a/json/discount_marketing_list.json +++ b/json/discount_marketing_list.json @@ -78,7 +78,7 @@ "wid": "self", "event": "gen_promo", "actiontype": "script", - "script": "(function(){var id='${id}$';var x=new XMLHttpRequest();x.open('POST','{{entire_url('../api/gen_promo_from_mkt.dspy')}}',true);x.setRequestHeader('Content-Type','application/x-www-form-urlencoded');x.onload=function(){try{var d=JSON.parse(x.responseText);if(d.widgettype==='Message'){var m=new bricks.Message(d.options);m.show();}else{alert(d.options.message||x.responseText);}}catch(e){alert(x.responseText);}};x.send('marketing_id='+encodeURIComponent(id));})();" + "script": "(function(){var id='${id}$';if(!id||id==='${id}$'){alert('未获取到方案ID,请先选中一行。');return;}var x=new XMLHttpRequest();x.open('POST','{{entire_url('../api/gen_promo_from_mkt.dspy')}}',true);x.setRequestHeader('Content-Type','application/x-www-form-urlencoded');x.onload=function(){try{var d=JSON.parse(x.responseText);if(d.widgettype==='Message'){var m=new bricks.Message(d.options);m.show();}else{alert(d.options.message||x.responseText);}}catch(e){alert(x.responseText);}};x.send('marketing_id='+encodeURIComponent(id));})();" } ], "new_data_url": "{{entire_url('/discount/api/marketing_create.dspy')}}",