{"id":8,"date":"2026-03-13T18:51:15","date_gmt":"2026-03-13T18:51:15","guid":{"rendered":"https:\/\/rswindor.com\/?page_id=8"},"modified":"2026-03-13T18:52:16","modified_gmt":"2026-03-13T18:52:16","slug":"crm","status":"publish","type":"page","link":"https:\/\/rswindor.com\/","title":{"rendered":"crm"},"content":{"rendered":"\n<div id=\"rwd-portal-root\">\n<link href=\"https:\/\/fonts.googleapis.com\/css2?family=DM+Sans:wght@400;500;600;700;800&display=swap\" rel=\"stylesheet\">\n<style>\n#rwd-portal-root{font-family:'DM Sans',system-ui,sans-serif;min-height:100vh;margin:0}\n#rwd-portal-root *{box-sizing:border-box}\n.rp-login{min-height:100vh;display:flex;align-items:center;justify-content:center;background:linear-gradient(135deg,#0f1f11 0%,#1a3320 100%);padding:20px}\n.rp-card{background:white;border-radius:20px;padding:40px 36px;width:100%;max-width:380px;box-shadow:0 24px 80px rgba(0,0,0,.35)}\n.rp-logo{display:flex;align-items:center;justify-content:center;margin-bottom:28px}\n.rp-logo img{height:52px;object-fit:contain}\n.rp-logo-icon{width:52px;height:52px;border-radius:14px;background:#4a7c59;display:flex;align-items:center;justify-content:center;color:white;font-size:24px;font-weight:800}\n.rp-title{font-size:20px;font-weight:800;color:#1a2b1c;text-align:center;margin-bottom:6px}\n.rp-sub{font-size:13px;color:#6b7280;text-align:center;margin-bottom:28px}\n.rp-label{font-size:10px;font-weight:800;color:#6b7280;text-transform:uppercase;letter-spacing:.05em;display:block;margin-bottom:6px}\n.rp-pin{width:100%;padding:14px 16px;border:2px solid #e2e8f0;border-radius:10px;font-size:20px;font-family:inherit;color:#1a2b1c;background:#f9fbf9;outline:none;text-align:center;letter-spacing:.25em;transition:border-color .2s;margin-bottom:6px}\n.rp-pin:focus{border-color:#4a7c59;background:white}\n.rp-err{color:#dc2626;font-size:12px;font-weight:700;text-align:center;min-height:18px;margin-bottom:10px}\n.rp-btn{width:100%;padding:13px;background:#4a7c59;color:white;border:none;border-radius:10px;font-size:14px;font-weight:800;font-family:inherit;cursor:pointer;transition:filter .18s;letter-spacing:.02em}\n.rp-btn:hover{filter:brightness(1.08)}\n.rp-btn:disabled{opacity:.55;cursor:default}\n.rp-hp{display:none!important}\n#rwd-portal-app{position:fixed;top:0;left:0;right:0;bottom:0;z-index:9999;background:#f0f4f0;display:none}\n<\/style>\n\n<div class=\"rp-login\" id=\"rp-login\">\n  <div class=\"rp-card\">\n    <div class=\"rp-logo\">\n      <div class=\"rp-logo-icon\">R<\/div>    <\/div>\n    <div class=\"rp-title\">Rudy&#039;s W&amp;D CRM<\/div>\n    <div class=\"rp-sub\">Enter your access PIN to continue<\/div>\n    <label class=\"rp-label\" for=\"rp-pin-input\">Access PIN<\/label>\n    <input class=\"rp-pin\" id=\"rp-pin-input\" type=\"password\" inputmode=\"numeric\" maxlength=\"20\" placeholder=\"\u2022\u2022\u2022\u2022\" autocomplete=\"off\">\n    <div class=\"rp-err\" id=\"rp-err\"><\/div>\n    <button class=\"rp-btn\" id=\"rp-submit\">Unlock Access<\/button>\n    <div class=\"rp-hp\"><input type=\"text\" id=\"rp-hp\"><\/div>\n  <\/div>\n<\/div>\n<div id=\"rwd-portal-app\"><\/div>\n<script>\n(function(){\n  var REST=\"https:\/\/rswindor.com\/index.php\/wp-json\/\";\n  var JSX=\"https:\/\/rswindor.com\/wp-content\/plugins\/rudy-wd-crm\/assets\/js\/estimate-generator.jsx?v=1.5.2\";\n  var COLOR=\"#4a7c59\";\n  var pin=document.getElementById('rp-pin-input');\n  var btn=document.getElementById('rp-submit');\n  var err=document.getElementById('rp-err');\n  var hp=document.getElementById('rp-hp');\n\n  function tryLogin(){\n    var p=pin.value.trim();\n    if(!p){err.textContent='Please enter your PIN.';return;}\n    btn.disabled=true;btn.textContent='Verifying\u2026';err.textContent='';\n    fetch(REST+'rwd\/v1\/portal-auth',{\n      method:'POST',headers:{'Content-Type':'application\/json'},\n      body:JSON.stringify({pin:p,_hp:hp?hp.value:''})\n    }).then(function(r){return r.json();}).then(function(d){\n      if(d.success){\n        document.getElementById('rp-login').style.display='none';\n        loadPortalApp(d.permissions||'full');\n      }else{\n        err.textContent=d.error||'Incorrect PIN.';\n        btn.disabled=false;btn.textContent='Unlock Access';\n        pin.value='';pin.focus();\n      }\n    }).catch(function(){\n      err.textContent='Connection error. Please try again.';\n      btn.disabled=false;btn.textContent='Unlock Access';\n    });\n  }\n\n  btn.addEventListener('click',tryLogin);\n  pin.addEventListener('keydown',function(e){if(e.key==='Enter')tryLogin();});\n\n  function loadPortalApp(perms){\n    var appEl=document.getElementById('rwd-portal-app');\n    appEl.style.display='block';\n    appEl.innerHTML='<div id=\"rwd-crm-root\" style=\"height:100%;display:flex;flex-direction:column\"><\/div>';\n    \/\/ Set portal config (token-cookie based, no WP nonce needed)\n    window.rwdCrmConfig={\n      restUrl:REST,\n      nonce:'',\n      version:\"1.5.2\",\n      isPortal:true,\n      portalPermissions:perms,\n    };\n    \/\/ Load React + Babel + App\n    function loadScript(src,cb){var s=document.createElement('script');s.src=src;s.onload=cb;document.head.appendChild(s);}\n    loadScript('https:\/\/unpkg.com\/react@18\/umd\/react.production.min.js',function(){\n      loadScript('https:\/\/unpkg.com\/react-dom@18\/umd\/react-dom.production.min.js',function(){\n        loadScript('https:\/\/unpkg.com\/@babel\/standalone\/babel.min.js',function(){\n          var x=new XMLHttpRequest();x.open('GET',JSX,true);\n          x.onload=function(){\n            if(x.status===200){\n              try{\n                var code=Babel.transform(x.responseText,{presets:['react']}).code;\n                var s=document.createElement('script');s.textContent=code;document.body.appendChild(s);\n              }catch(e){appEl.innerHTML='<div style=\"padding:40px;color:red\"><b>Error loading CRM:<\/b><pre>'+e.message+'<\/pre><\/div>';}\n            }\n          };x.send();\n        });\n      });\n    });\n  }\n})();\n<\/script>\n\n<\/div>\n\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-8","page","type-page","status-publish","hentry"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.1.1 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>crm - Rudys Windows and Doors<\/title>\n<meta name=\"robots\" content=\"noindex, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"crm - Rudys Windows and Doors\" \/>\n<meta property=\"og:url\" content=\"https:\/\/rswindor.com\/\" \/>\n<meta property=\"og:site_name\" content=\"Rudys Windows and Doors\" \/>\n<meta property=\"article:modified_time\" content=\"2026-03-13T18:52:16+00:00\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"1 minute\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/rswindor.com\/\",\"url\":\"https:\/\/rswindor.com\/\",\"name\":\"crm - Rudys Windows and Doors\",\"isPartOf\":{\"@id\":\"https:\/\/rswindor.com\/#website\"},\"datePublished\":\"2026-03-13T18:51:15+00:00\",\"dateModified\":\"2026-03-13T18:52:16+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/rswindor.com\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/rswindor.com\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/rswindor.com\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/rswindor.com\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"crm\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/rswindor.com\/#website\",\"url\":\"https:\/\/rswindor.com\/\",\"name\":\"Rudys Windows and Doors\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/rswindor.com\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"crm - Rudys Windows and Doors","robots":{"index":"noindex","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"og_locale":"en_US","og_type":"article","og_title":"crm - Rudys Windows and Doors","og_url":"https:\/\/rswindor.com\/","og_site_name":"Rudys Windows and Doors","article_modified_time":"2026-03-13T18:52:16+00:00","twitter_card":"summary_large_image","twitter_misc":{"Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/rswindor.com\/","url":"https:\/\/rswindor.com\/","name":"crm - Rudys Windows and Doors","isPartOf":{"@id":"https:\/\/rswindor.com\/#website"},"datePublished":"2026-03-13T18:51:15+00:00","dateModified":"2026-03-13T18:52:16+00:00","breadcrumb":{"@id":"https:\/\/rswindor.com\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/rswindor.com\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/rswindor.com\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/rswindor.com\/"},{"@type":"ListItem","position":2,"name":"crm"}]},{"@type":"WebSite","@id":"https:\/\/rswindor.com\/#website","url":"https:\/\/rswindor.com\/","name":"Rudys Windows and Doors","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/rswindor.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"}]}},"_links":{"self":[{"href":"https:\/\/rswindor.com\/index.php\/wp-json\/wp\/v2\/pages\/8","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/rswindor.com\/index.php\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/rswindor.com\/index.php\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/rswindor.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/rswindor.com\/index.php\/wp-json\/wp\/v2\/comments?post=8"}],"version-history":[{"count":4,"href":"https:\/\/rswindor.com\/index.php\/wp-json\/wp\/v2\/pages\/8\/revisions"}],"predecessor-version":[{"id":14,"href":"https:\/\/rswindor.com\/index.php\/wp-json\/wp\/v2\/pages\/8\/revisions\/14"}],"wp:attachment":[{"href":"https:\/\/rswindor.com\/index.php\/wp-json\/wp\/v2\/media?parent=8"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}