PageSourceSearch

https://www.dede.go.th/_next/static/chunks/pages/question-answer-582a932264c976e2.js

js dede.go.th collected 2026-10-01 11:44:08 UTC 5,845 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4194],{93777:function(e,t,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/question-answer",function(){return n(9659)}])},68069:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return c}});var i=n(85893);n(9008);var a=n(67294),s=n(70594),r=n(84433);n(41664);var l=n(81811);let o=n(30488);function c(){let[e,t]=(0,a.useState)([]),[n,c]=(0,a.useState)([]),[d,u]=(0,a.useState)(!0),[m,h]=(0,a.useState)(0);(0,a.useEffect)(()=>{let e=async()=>{u(!0);try{let{data:e}=await s.Z.get("".concat(r.UW,"/api/faqs?populate=*"));if(e.data.length>0){let n=e.data.map(e=>{var t,n,i,a,s,r;return{id:e.id,title:null===(t=e.attributes)||void 0===t?void 0:t.title,question:null===(n=e.attributes)||void 0===n?void 0:n.faq_question,answer:null===(i=e.attributes)||void 0===i?void 0:i.faq_answer,cat_id:null===(a=e.attributes)||void 0===a?void 0:null===(s=a.faq_category)||void 0===s?void 0:null===(r=s.data)||void 0===r?void 0:r.id}});t(n)}u(!1)}catch(i){console.error(i.message)}},n=async()=>{try{let{data:e}=await s.Z.get("".concat(r.UW,"/api/faq-categories"));if(e.data.length>0){let t=e.data.map(e=>{var t;return{id:e.id,name:null===(t=e.attributes)||void 0===t?void 0:t.name}});c(t);let n=0;t.length>0&&(n=t[0].id),h(n)}u(!1)}catch(i){console.error(i.message)}};n(),e()},[]);let x=t=>{let n=e.filter(e=>e.cat_id==t);return n.map(e=>(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)("p",{children:o((0,l.r)(e.question))}),(0,i.jsx)("p",{children:o((0,l.r)(e.answer))})]}))};return(0,i.jsx)("section",{className:"ls section_padding_top_100 section_padding_bottom_130 columns_padding_25",children:(0,i.jsx)("div",{className:"container",children:(0,i.jsx)("div",{className:"row vertical-tabs color4",children:!d&&(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)("div",{className:"col-sm-5",children:(0,i.jsx)("ul",{className:"nav",role:"tablist",style:{display:"block"},children:n&&n.map(e=>(0,i.jsxs)("li",{className:e.id==m?"active":"",onClick:()=>h(e.id),children:[" ",(0,i.jsx)("a",{href:"#",role:"tab","data-toggle":"tab",children:e.name})," "]},e.id))})}),(0,i.jsx)("div",{className:"col-sm-7",children:(0,i.jsx)("div",{className:"tab-content no-border",children:n&&n.map(e=>(0,i.jsx)("div",{className:e.id==m?"tab-pane fade in active":"tab-pane fade",children:x(e.id)},e.id))})})]})})})})}},9659:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return d}});var i=n(85893);n(9008);var a=n(67294),s=n(20840),r=n(33683),l=n(50747),o=n(68069),c=n(56108);function d(){let[e,t]=(0,a.useState)((0,c.ob)({title:"คำถามที่พบบ่อย (FAQ)"}));return(0,i.jsxs)(i.Fragment,{children:[e,(0,i.jsx)("div",{id:"canvas",children:(0,i.jsxs)("div",{id:"box_wrapper",children:[(0,i.jsx)(s.Z,{}),(0,i.jsx)(r.Z,{pageTitle:"คำถามที่พบบ่อย (FAQ)"}),(0,i.jsx)(o.default,{}),(0,i.jsx)(l.Z,{})]})})]})}},56108:function(e,t,n){"use strict";n.d(t,{mW:function(){return o},ob:function(){return l},vI:function(){return r}});var i=n(85893),a=n(9008),s=n.n(a);let r=async(e,t,n)=>{let a=e.main_content,r="กรมพัฒนาพลังงานทดแทนและอนุรักษ์พลังงาน (พพ.) กระทรวงพลังงาน",l=e.title;if(l&&(r=l+" | "+r),"string"==typeof a||a instanceof String){a=(a=(a=a.replace(/<[^>]+>/g,"")).replace(/\&nbsp;/g,"")).trim();let o=a.length;a=a.slice(0,150),o>=150&&(a+="...")}else a="กรมพัฒนาพลังงานทดแทนและอนุรักษ์พลังงาน (พพ.) กระทรวงพลังงาน";return n||(n="index, follow"),(0,i.jsxs)(s(),{children:[(0,i.jsx)("title",{children:r}),(0,i.jsx)("meta",{name:"description",content:a}),(0,i.jsx)("meta",{name:"keywords",content:t}),(0,i.jsx)("meta",{name:"robots",content:n}),(0,i.jsx)("meta",{name:"viewport",content:"width=device-width, initial-scale=1"}),(0,i.jsx)("link",{rel:"shortcut icon",href:"/uploads/dede_b439269179.ico"})]})},l=e=>{let t="กรมพัฒนาพลังงานทดแทนและอนุรักษ์พลังงาน (พพ.) กระทรวงพลังงาน",n=e.title?e.title+" | "+t:t,a=e.description?e.description:"กรมพัฒนาพลังงานทดแทนและอนุรักษ์พลังงาน (พพ.) กระทรวงพลังงาน";if("string"==typeof a||a instanceof String){a=(a=(a=a.replace(/<[^>]+>/g,"")).replace(/\&nbsp;/g,"")).trim();let r=a.length;a=a.slice(0,150),r>=150&&(a+="...")}else a=null;a||(a=n?n+" "+t:t);let l=e.keywords?e.keywords:"",o=e.robotKeywords?e.robotKeywords:"index, follow";return(0,i.jsxs)(s(),{children:[(0,i.jsx)("title",{children:n}),(0,i.jsx)("meta",{name:"description",content:a}),(0,i.jsx)("meta",{name:"keywords",content:l}),(0,i.jsx)("meta",{name:"robots",content:o}),(0,i.jsx)("meta",{name:"viewport",content:"width=device-width, initial-scale=1"}),(0,i.jsx)("link",{rel:"shortcut icon",href:"/uploads/dede_b439269179.ico"})]})},o=()=>(0,i.jsxs)(s(),{children:[(0,i.jsx)("title",{children:"กรมพัฒนาพลังงานทดแทนและอนุรักษ์พลังงาน (พพ.) กระทรวงพลังงาน"}),(0,i.jsx)("meta",{name:"description",content:"กรมพัฒนาพลังงานทดแทนและอนุรักษ์พลังงาน (พพ.) กระทรวงพลังงาน"}),(0,i.jsx)("meta",{name:"robots",content:"index, follow"}),(0,i.jsx)("meta",{name:"viewport",content:"width=device-width, initial-scale=1"}),(0,i.jsx)("link",{rel:"shortcut icon",href:"/uploads/dede_b439269179.ico"})]})}},function(e){e.O(0,[4885,1876,1664,594,5675,3539,488,3166,3683,9774,2888,179],function(){return e(e.s=93777)}),_N_E=e.O()}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.