소스 검색

Update sharpspring service

Amauri CHAMPEAUX 4 년 전
부모
커밋
5fa27e1b5c
1개의 변경된 파일8개의 추가작업 그리고 6개의 파일을 삭제
  1. 8 6
      tarteaucitron.services.js

+ 8 - 6
tarteaucitron.services.js

@@ -42,16 +42,18 @@ tarteaucitron.services.sharpspring = {
     "js": function () {
         "use strict";
 
-        if (tarteaucitron.user.sharpspringAccount === undefined || tarteaucitron.user.sharpspringForm === undefined) {
+        if (tarteaucitron.user.ssId === undefined || tarteaucitron.user.ssAccount === undefined) {
             return;
         }
 
-        window.ss_form = {'account': tarteaucitron.user.sharpspringAccount, 'formID': tarteaucitron.user.sharpspringForm};
-        window.ss_form.width = '100%';
-        window.ss_form.height = '1000';
-        window.ss_form.domain = tarteaucitron.user.sharpspringUrl;
+        window._ss = window._ss || [];
+        window._ss.push(['_setDomain', 'https://' + tarteaucitron.user.ssId + '.marketingautomation.services/net']);
+        window._ss.push(['_setAccount', tarteaucitron.user.ssAccount]);
+        window._ss.push(['_trackPageView']);
 
-        tarteaucitron.addScript('https://' + tarteaucitron.user.sharpspringUrl + '/client/form.js?ver=2.0.1');
+        window._pa = window._pa || {};
+
+        tarteaucitron.addScript('https://' + tarteaucitron.user.ssId + '.marketingautomation.services/client/ss.js');
     }
 };