\r\n"},{"id":37579,"bundle":"topic_content","heading":"More Sustainability Insights","terms":[{"id":551,"name":"sustainability"}],"items":[{"id":24162,"bundle":"article","title":"Crocs Launches Takeback Pilot Program","url":"/crocs-launches-takeback-pilot-program","summary":"Crocs has initiated a retail takeback pilot program, aimed at enhancing its sustainability and circular economy efforts. The program encourages shoppers to bring their old Crocs shoes to select stores in ten states across the country, regardless of their condition. ","teaserImage":{"url":"https://assets1.risnews.com/styles/secondary_articles_short/s3/2023-10/crocs_interior.jpg?h=dec22bcf&itok=XSZOhVk-","width":960,"height":720,"alt":"crocs"}},{"id":24144,"bundle":"article","title":"Amazon Progresses on End-to-End Sustainability","url":"/amazon-progresses-end-end-sustainability","summary":"Amazon has been very vocal about its continued efforts to reduce carbon emissions and introduce sustainable business practices across its enterprise. The latest progress reports come from the company’s grocery segment, transportation fleet, and its tech offerings. ","teaserImage":{"url":"https://assets1.risnews.com/styles/secondary_articles_short/s3/2023-10/amazon_fresh.jpg?h=dec22bcf&itok=LOpea_Sf","width":960,"height":720,"alt":"Amazon Fresh"}},{"id":24126,"bundle":"article","title":"4 Ways to Increase Sustainability in Your Supply Chain","url":"/4-ways-increase-sustainability-your-supply-chain","summary":"Read on for 4 ways to boost sustainability in your supply chain and how to integrate your supply chain into your overarching ESG strategy.","teaserImage":{"url":"https://assets1.risnews.com/styles/secondary_articles_short/s3/2023-10/sustainable_supply_chain.jpg?h=27a93da2&itok=5ntEu2o-","width":960,"height":576,"alt":"sustainable supply chain"}}]}]}}; const country = "HK"; const language = "en, *"; const SITE_LANGUAGE = "en"; const siteName = "RIS News"; const userRoles = ["anonymous"]; const userUid = 0; const indexName = "risnews"; window.dataLayer = window.dataLayer || []; const data = {}; data.entityTaxonomy = {}; const contentTypes = [ "article", "blog", "bulletin", "embed_page", "landing_page", "event", "image", "page", "product", "whitepaper", "video", "tags", ]; if ( routeInfo && "bundle" in routeInfo && contentTypes.includes(routeInfo["bundle"]) ) { data.entityBundle = routeInfo.bundle; data.entityTitle = `${routeInfo.title} | ${siteName}`; data.entityId = routeInfo.id; data.entityName = routeInfo.author?.uname; data.entityCreated = routeInfo.created; data.sponsored = routeInfo.sponsored; data.sponsor = routeInfo.sponsoringCompany; data.entityType = "node"; data.entityLangcode = SITE_LANGUAGE; data.siteName = siteName; data.drupalLanguage = language; data.drupalCountry = country; data.userRoles = userRoles; data.userUid = userUid; data.entityTaxonomyKeys = {}; data.entityTaxonomyHierarchies = {}; data.parentNaicsCode = {}; data.isPro = false; data.algoliaIndexName = indexName; // Add toxonomy data const taxonomies = { businessTopic: "business_topic", contentType: "content_type", company: "company", marketSegment: "market_segment", }; const getHierarchy = (term, terms = []) => { terms.push({ id: term.id, name: term.name }); if (term.parentTerm != null) { getHierarchy(term.parentTerm, terms); } return terms; }; const getTerms = (term, useApiId = false) => { return { id: useApiId ? term.apiId : term.id, name: term.name }; }; const getKeys = (term) => { return { id: term.id, name: term.apiId }; }; Object.entries(taxonomies).forEach(([key, item]) => { terms = routeInfo[key]; if (terms && terms.length > 0) { data["entityTaxonomy"][item] = terms.map((term) => getTerms(term, key === "company") ); if (key !== "company") { data["entityTaxonomyKeys"][item] = terms.map(getKeys); termGroups = []; terms.forEach((term, termInd) => { termGroups[termInd] = getHierarchy(term); }); data["entityTaxonomyHierarchies"][item] = termGroups; } } }); data["entityTaxonomy"]["tags"] = routeInfo["topics"] || []; // Primary Topic is either the business topic or the top tag. if (routeInfo["businessTopic"]?.length > 0) { data["entityPrimaryTopic"] = routeInfo["businessTopic"][0]["name"]; } else { if (routeInfo["topics"]?.length > 0) { data["entityPrimaryTopic"] = routeInfo["topics"][0]["name"]; } } // Primary and secondary entityNaicsCodes come from the MarketSegment if (routeInfo.marketSegment?.length > 0) { data.entityNaicsCode = {}; data["entityNaicsCode"]["id"] = routeInfo["marketSegment"][0]["id"]; data["entityNaicsCode"]["name"] = routeInfo["marketSegment"][0]["naicsCode"]; if (routeInfo["marketSegment"][0]["parentTerm"] != null) { data["parentNaicsCode"]["id"] = routeInfo["marketSegment"][0]["parentTerm"]["id"]; data["parentNaicsCode"]["name"] = routeInfo["marketSegment"][0]["parentTerm"]["naicsCode"]; } } else { data.entityNaicsCode = []; } if (routeInfo.taggedPro) { data.isPro = routeInfo.taggedPro; } window.dataLayer.push(data); } else if (routeInfo && "vid" in routeInfo) { data.entityBundle = "tags"; data.entityTitle = routeInfo.name; data.entityId = routeInfo.id; data.entityName = routeInfo.author?.uname; data.entityCreated = routeInfo.created; data.entityType = "taxonomy_term"; data.entityLangcode = SITE_LANGUAGE; data.siteName = siteName; data.sponsored = routeInfo.sponsored; data.sponsor = routeInfo.sponsoringCompany; data.drupalLanguage = language; data.drupalCountry = country; data.userRoles = userRoles; data.userUid = userUid; data.algoliaIndexName = indexName; data["entityTaxonomy"]["tags"] = { id: routeInfo["id"], name: routeInfo["name"], }; window.dataLayer.push(data); } })();