<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
  <channel>
    <title>결핵마스터</title>
    <link>https://tb-master.tistory.com/</link>
    <description>국가결핵지침, 결핵 역학조사 등 다양한 결핵 정보에 대해 소개하는 블로그입니다. </description>
    <language>ko</language>
    <pubDate>Sun, 12 Apr 2026 11:22:04 +0900</pubDate>
    <generator>TISTORY</generator>
    <ttl>100</ttl>
    <managingEditor>결핵마스터</managingEditor>
    <image>
      <title>결핵마스터</title>
      <url>https://tistory1.daumcdn.net/tistory/7286808/attach/62a9ffafbc6644e5bd0fee1f7f1eee04</url>
      <link>https://tb-master.tistory.com</link>
    </image>
    <item>
      <title>결핵 전염성 추정 및 접촉시간 계산기</title>
      <link>https://tb-master.tistory.com/pages/%EC%A0%84%EC%97%BC%EC%84%B1-%EC%B6%94%EC%A0%95-%EB%B0%8F-%EC%A0%91%EC%B4%89%EC%8B%9C%EA%B0%84-%EA%B3%84%EC%82%B0%EA%B8%B0</link>
      <description>&lt;!DOCTYPE html&gt;
&lt;html lang=&quot;ko&quot;&gt;
&lt;head&gt;
  &lt;meta charset=&quot;UTF-8&quot;&gt;
  &lt;meta name=&quot;viewport&quot; content=&quot;width=device-width, initial-scale=1.0&quot;&gt;
  &lt;title&gt;결핵 역학조사 - 전염성 추정 및 접촉시간 계산기&lt;/title&gt;
  &lt;style&gt;
    body {
      background-color: #f4f7f6;
      margin: 0;
      padding: 20px;
    }
    .container {
      background-color: #ffffff;
      border-radius: 12px;
      box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
      padding: 20px;
      max-width: 1000px;
      margin: auto;
    }
    h1 {
      font-size: 24px;
      color: #333;
      margin-bottom: 20px;
      font-weight: 700;
      text-align: center;
    }
    h3 {
      border-left: 6px solid #007bff;
      padding-left: 10px;
      color: #007bff;
    }
    label {
      display: block;
      font-size: 16px;
      color: #495057;
      margin-top: 20px;
      margin-bottom: 8px;
      font-weight: 600;
    }
    .radio-group {
      display: flex;
      gap: 10px;
      margin-top: 5px;
    }
    .radio-group label {
      font-weight: normal;
      color: #495057;
    }
    input[type=&quot;radio&quot;] {
      margin-right: 5px;
    }
    input[type=&quot;date&quot;] {
      width: 100%;
      padding: 12px;
      font-size: 14px;
      border: 1px solid #ced4da;
      border-radius: 6px;
      margin-top: 5px;
      background-color: #f8f9fa;
    }
    button {
      background-color: #007bff;
      color: white;
      font-size: 16px;
      padding: 12px;
      border: none;
      border-radius: 8px;
      cursor: pointer;
      margin-top: 20px;
      width: 100%;
    }
    .result, .calendar-section {
      margin-top: 25px;
    }
    .calendar-month {
      margin-top: 40px;
      border: 2px solid #007bff;
      border-radius: 10px;
      overflow: hidden;
    }
    .calendar-month h4 {
      margin: 0;
      background-color: #007bff;
      color: white;
      padding: 10px;
      text-align: center;
    }
    table.calendar-table {
      width: 100%;
      border-collapse: collapse;
    }
    table.calendar-table th,
    table.calendar-table td {
      border: 1px solid #dee2e6;
      text-align: center;
      padding: 10px;
      vertical-align: top;
    }
    table.calendar-table input[type=&quot;number&quot;] {
      width: 50px;
      margin-top: 5px;
    }
    .summary {
      background-color: #e9ecef;
      padding: 15px;
      border-radius: 8px;
      font-size: 16px;
      font-weight: 600;
      color: #212529;
      text-align: center;
    }
    .result-box {
  background-color: #dbeafe;
  border: 1px solid #60a5fa;
  padding: 20px;
  border-radius: 8px;
  font-size: 18px;
  font-weight: 600;
  color: #1e3a8a;
  text-align: center;
  margin-top: 25px;
}
footer {
      text-align: center;
      margin-top: 40px;
      color: #888;
      font-size: 14px;
    }
    td input {
      width: 40px;
      margin-top: 5px;
      padding: 4px;
            border: 1px solid #cdd7df;

    }
  &lt;/style&gt;
&lt;/head&gt;
&lt;body&gt;
&lt;div class=&quot;container&quot;&gt;
  &lt;h1&gt;결핵 전염성 추정 및 접촉시간 계산기&lt;/h1&gt;
  &lt;form id=&quot;tbForm&quot;&gt;
    &lt;label&gt;결핵 증상:&lt;/label&gt;
    &lt;div class=&quot;radio-group&quot;&gt;
      &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;symptom&quot; value=&quot;yes&quot; onclick=&quot;toggleSymptomDate(true)&quot;&gt; 예&lt;/label&gt;
      &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;symptom&quot; value=&quot;no&quot; onclick=&quot;toggleSymptomDate(false)&quot;&gt; 아니오&lt;/label&gt;
    &lt;/div&gt;

    &lt;label&gt;가래(객담) 도말 양성:&lt;/label&gt;
    &lt;div class=&quot;radio-group&quot;&gt;
      &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;sputum&quot; value=&quot;yes&quot;&gt; 예&lt;/label&gt;
      &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;sputum&quot; value=&quot;no&quot;&gt; 아니오&lt;/label&gt;
    &lt;/div&gt;

    &lt;label&gt;흉부 X선 공동:&lt;/label&gt;
    &lt;div class=&quot;radio-group&quot;&gt;
      &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;xray&quot; value=&quot;yes&quot;&gt; 예&lt;/label&gt;
      &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;xray&quot; value=&quot;no&quot;&gt; 아니오&lt;/label&gt;
    &lt;/div&gt;

    &lt;label&gt;약 복용 여부:&lt;/label&gt;
    &lt;div class=&quot;radio-group&quot;&gt;
      &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;medication&quot; value=&quot;yes&quot; onclick=&quot;toggleMedicationDate(true)&quot;&gt; 예&lt;/label&gt;
      &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;medication&quot; value=&quot;no&quot; onclick=&quot;toggleMedicationDate(false)&quot;&gt; 아니오&lt;/label&gt;
    &lt;/div&gt;

    &lt;label&gt;증상 시작일:&lt;/label&gt;
    &lt;input type=&quot;date&quot; id=&quot;symptomDate&quot; disabled&gt;

    &lt;label&gt;가장 앞선 검사일:&lt;/label&gt;
    &lt;input type=&quot;date&quot; id=&quot;testDate&quot;&gt;

    &lt;label&gt;약 복용 시작일:&lt;/label&gt;
    &lt;input type=&quot;date&quot; id=&quot;medicationDate&quot; disabled&gt;

    &lt;button type=&quot;button&quot; onclick=&quot;calculatePeriod()&quot;&gt;전염성 추정기간 계산&lt;/button&gt;
  &lt;/form&gt;

  &lt;div class=&quot;result-box&quot; id=&quot;result&quot;&gt;&lt;/div&gt;

  &lt;div class=&quot;calendar-section&quot; id=&quot;calendarSection&quot; style=&quot;display:none;&quot;&gt;
    &lt;h3&gt;날짜별 접촉시간 입력&lt;/h3&gt;
    &lt;div id=&quot;calendarContainer&quot;&gt;&lt;/div&gt;
    &lt;button type=&quot;button&quot; onclick=&quot;calculateTotalTime()&quot;&gt;총 접촉시간 계산&lt;/button&gt;
    &lt;div class=&quot;summary&quot; id=&quot;totalHours&quot;&gt;&lt;/div&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;footer&gt;
    &amp;copy; unkidayeon
  &lt;/footer&gt;


&lt;script&gt;
  function toggleSymptomDate(enable) {
    document.getElementById(&quot;symptomDate&quot;).disabled = !enable;
  }

  function toggleMedicationDate(enable) {
    document.getElementById(&quot;medicationDate&quot;).disabled = !enable;
  }

  function calculatePeriod() {
    const symptom = document.querySelector('input[name=&quot;symptom&quot;]:checked')?.value;
    const sputum = document.querySelector('input[name=&quot;sputum&quot;]:checked')?.value;
    const xray = document.querySelector('input[name=&quot;xray&quot;]:checked')?.value;
    const medication = document.querySelector('input[name=&quot;medication&quot;]:checked')?.value;
    const symptomDate = new Date(document.getElementById(&quot;symptomDate&quot;).value);
    const testDate = new Date(document.getElementById(&quot;testDate&quot;).value);
    const medicationDate = new Date(document.getElementById(&quot;medicationDate&quot;).value);
    if (!testDate.getTime()) return alert(&quot;검사일을 입력하세요.&quot;);

    let startDate, endDate;

    if (symptom === &quot;yes&quot;) {
      if (!symptomDate.getTime()) return alert(&quot;증상 시작일을 입력하세요.&quot;);
      startDate = new Date(symptomDate);
      startDate.setMonth(startDate.getMonth() - 3);
      endDate = new Date(testDate);
    } else if (sputum === &quot;yes&quot; || xray === &quot;yes&quot;) {
      startDate = new Date(testDate);
      startDate.setMonth(startDate.getMonth() - 3);
      endDate = new Date(testDate);
    } else {
      startDate = new Date(testDate);
      startDate.setDate(startDate.getDate() - 28);
      endDate = new Date(testDate);
    }

    if (medication === &quot;yes&quot; &amp;&amp; medicationDate.getTime()) {
      endDate = new Date(medicationDate);
      endDate.setDate(endDate.getDate() + 14);
    }

    const diffWeeks = Math.ceil((endDate - startDate) / (1000 * 60 * 60 * 24 * 7));
    document.getElementById(&quot;result&quot;).innerHTML = `전염성 추정기간&lt;br&gt;&lt;strong&gt;${startDate.toLocaleDateString()} ~ ${endDate.toLocaleDateString()}&lt;/strong&gt;&lt;br&gt;(총 ${diffWeeks}주간)`;
    generateCalendar(startDate, endDate);
  }

  function generateCalendar(start, end) {
    const container = document.getElementById(&quot;calendarContainer&quot;);
    container.innerHTML = &quot;&quot;;

    const months = {};
    let current = new Date(start);
    while (current &lt;= end) {
      const y = current.getFullYear();
      const m = current.getMonth();
      const key = `${y}-${m}`;
      if (!months[key]) months[key] = [];
      months[key].push(new Date(current));
      current.setDate(current.getDate() + 1);
    }

    for (const key in months) {
      const dates = months[key];
      const monthName = `${dates[0].getFullYear()}년 ${dates[0].getMonth() + 1}월`;

      const section = document.createElement(&quot;div&quot;);
      section.className = &quot;calendar-month&quot;;

      const title = document.createElement(&quot;h4&quot;);
      title.textContent = monthName;
      section.appendChild(title);

      const table = document.createElement(&quot;table&quot;);
      table.className = &quot;calendar-table&quot;;

      const thead = document.createElement(&quot;thead&quot;);
      thead.innerHTML = `&lt;tr&gt;&lt;th&gt;일&lt;/th&gt;&lt;th&gt;월&lt;/th&gt;&lt;th&gt;화&lt;/th&gt;&lt;th&gt;수&lt;/th&gt;&lt;th&gt;목&lt;/th&gt;&lt;th&gt;금&lt;/th&gt;&lt;th&gt;토&lt;/th&gt;&lt;/tr&gt;`;
      table.appendChild(thead);

      const tbody = document.createElement(&quot;tbody&quot;);
      let row = document.createElement(&quot;tr&quot;);

      const firstDay = dates[0].getDay();
      for (let i = 0; i &lt; firstDay; i++) row.appendChild(document.createElement(&quot;td&quot;));

      dates.forEach(date =&gt; {
        const cell = document.createElement(&quot;td&quot;);
        cell.innerHTML = `${date.getDate()}&lt;br&gt;&lt;input type='number' min='0' value='0'&gt;`;
        row.appendChild(cell);
        if (date.getDay() === 6) {
          tbody.appendChild(row);
          row = document.createElement(&quot;tr&quot;);
        }
      });

      if (row.children.length &gt; 0) {
        while (row.children.length &lt; 7) row.appendChild(document.createElement(&quot;td&quot;));
        tbody.appendChild(row);
      }

      table.appendChild(tbody);
      section.appendChild(table);
      container.appendChild(section);
    }

    document.getElementById(&quot;calendarSection&quot;).style.display = 'block';
  }

  function calculateTotalTime() {
    const inputs = document.querySelectorAll(&quot;.calendar-table input&quot;);
    let total = 0;
    inputs.forEach(input =&gt; {
      total += Math.max(0, parseFloat(input.value) || 0);
    });
    document.getElementById(&quot;totalHours&quot;).textContent = `총 접촉시간: ${total}시간`;
  }
&lt;/script&gt;
&lt;/body&gt;
&lt;/html&gt;</description>
      <author>결핵마스터</author>
      <guid isPermaLink="true">https://tb-master.tistory.com/pages/%EC%A0%84%EC%97%BC%EC%84%B1-%EC%B6%94%EC%A0%95-%EB%B0%8F-%EC%A0%91%EC%B4%89%EC%8B%9C%EA%B0%84-%EA%B3%84%EC%82%B0%EA%B8%B0</guid>
      <pubDate>Tue, 8 Apr 2025 23:05:20 +0900</pubDate>
    </item>
    <item>
      <title>결핵 접촉시간 계산기(달력형)</title>
      <link>https://tb-master.tistory.com/pages/%EA%B2%B0%ED%95%B5-%EC%A0%91%EC%B4%89%EC%8B%9C%EA%B0%84-%EA%B3%84%EC%82%B0%EA%B8%B0%EB%8B%AC%EB%A0%A5%ED%98%95</link>
      <description>&lt;!DOCTYPE html&gt;
&lt;html lang=&quot;ko&quot;&gt;
&lt;head&gt;
  &lt;meta charset=&quot;UTF-8&quot;&gt;
  &lt;style&gt;
    body {
      background-color: #f4f8fb;
      padding: 40px;
      margin: auto;
      color: #333;
    }
    h1 {
      text-align: center;
      color: #005f73;
      margin-bottom: 30px;
    }
    .controls {
      display: flex;
      justify-content: center;
      gap: 10px;
      margin-bottom: 20px;
    }
    select {
      padding: 8px;
      font-size: 16px;
    }
    table {
      width: 100%;
      border-collapse: collapse;
      margin-top: 20px;
    }
    th, td {
      border: 1px solid #ccc;
      width: 14.28%;
      text-align: center;
      vertical-align: top;
      padding: 5px;
      background-color: #fff;
    }
    td input {
      width: 40px;
      margin-top: 5px;
      padding: 4px;
            border: 1px solid #cdd7df;

    }
    .result {
      margin-top: 30px;
      font-weight: bold;
      font-size: 18px;
      text-align: center;
      color: #005f73;
      padding: 15px;
      background-color: #e0fbfc;
      border-radius: 6px;
      border: 1px solid #cdd7df;
    }
    button {
      display: block;
      width: 100%;
      background-color: #94d2bd;
      color: #003845;
      font-weight: bold;
      border: none;
      padding: 12px;
      border-radius: 6px;
      font-size: 16px;
      margin-top: 25px;
      cursor: pointer;
      transition: background-color 0.3s ease;
    }
    button:hover {
      background-color: #72c2aa;
    }
    footer {
      text-align: center;
      margin-top: 40px;
      color: #888;
      font-size: 14px;
    }
  &lt;/style&gt;
&lt;/head&gt;
&lt;body&gt;
  &lt;h1&gt;결핵 접촉시간 계산기(달력형)&lt;/h1&gt;

  &lt;div class=&quot;controls&quot;&gt;
    &lt;label&gt;
      연도:
      &lt;select id=&quot;yearSelect&quot;&gt;&lt;/select&gt;
    &lt;/label&gt;
    &lt;label&gt;
      월:
      &lt;select id=&quot;monthSelect&quot;&gt;&lt;/select&gt;
    &lt;/label&gt;
    &lt;button onclick=&quot;generateCalendar()&quot;&gt;달력 생성&lt;/button&gt;
  &lt;/div&gt;

  &lt;table id=&quot;calendar&quot;&gt;
    &lt;thead&gt;
      &lt;tr&gt;
        &lt;th&gt;일&lt;/th&gt;&lt;th&gt;월&lt;/th&gt;&lt;th&gt;화&lt;/th&gt;&lt;th&gt;수&lt;/th&gt;&lt;th&gt;목&lt;/th&gt;&lt;th&gt;금&lt;/th&gt;&lt;th&gt;토&lt;/th&gt;
      &lt;/tr&gt;
    &lt;/thead&gt;
    &lt;tbody&gt;&lt;/tbody&gt;
  &lt;/table&gt;

  &lt;button onclick=&quot;calculateTotalTime()&quot;&gt;총 접촉시간 계산&lt;/button&gt;
  &lt;div class=&quot;result&quot; id=&quot;result&quot;&gt;&lt;/div&gt;

  &lt;footer&gt;
    &amp;copy; unkidayeon
  &lt;/footer&gt;

  &lt;script&gt;
    // 연도/월 선택 옵션 채우기
    const yearSelect = document.getElementById(&quot;yearSelect&quot;);
    const monthSelect = document.getElementById(&quot;monthSelect&quot;);
    const currentYear = new Date().getFullYear();

    for (let y = currentYear - 5; y &lt;= currentYear + 5; y++) {
      const opt = document.createElement(&quot;option&quot;);
      opt.value = y;
      opt.textContent = y;
      if (y === currentYear) opt.selected = true;
      yearSelect.appendChild(opt);
    }

    for (let m = 0; m &lt; 12; m++) {
      const opt = document.createElement(&quot;option&quot;);
      opt.value = m;
      opt.textContent = `${m + 1}월`;
      if (m === new Date().getMonth()) opt.selected = true;
      monthSelect.appendChild(opt);
    }

    function generateCalendar() {
      const year = parseInt(yearSelect.value);
      const month = parseInt(monthSelect.value);
      const firstDay = new Date(year, month, 1).getDay();
      const lastDate = new Date(year, month + 1, 0).getDate();
      const tbody = document.querySelector(&quot;#calendar tbody&quot;);
      tbody.innerHTML = &quot;&quot;;

      let row = document.createElement(&quot;tr&quot;);
      for (let i = 0; i &lt; firstDay; i++) {
        row.appendChild(document.createElement(&quot;td&quot;));
      }

      for (let d = 1; d &lt;= lastDate; d++) {
        const cell = document.createElement(&quot;td&quot;);
        cell.innerHTML = `${d}&lt;br&gt;&lt;input type='number' min='0' value='0'&gt;`;
        row.appendChild(cell);
        if ((firstDay + d - 1) % 7 === 6 || d === lastDate) {
          tbody.appendChild(row);
          row = document.createElement(&quot;tr&quot;);
        }
      }
    }

    function calculateTotalTime() {
      const inputs = document.querySelectorAll(&quot;#calendar input&quot;);
      let total = 0;
      inputs.forEach(input =&gt; {
        total += Math.max(0, parseFloat(input.value));
      });
      document.getElementById(&quot;result&quot;).textContent = `총 접촉시간: ${total}시간`;
    }

    window.onload = generateCalendar;
  &lt;/script&gt;
&lt;/body&gt;
&lt;/html&gt;</description>
      <author>결핵마스터</author>
      <guid isPermaLink="true">https://tb-master.tistory.com/pages/%EA%B2%B0%ED%95%B5-%EC%A0%91%EC%B4%89%EC%8B%9C%EA%B0%84-%EA%B3%84%EC%82%B0%EA%B8%B0%EB%8B%AC%EB%A0%A5%ED%98%95</guid>
      <pubDate>Tue, 8 Apr 2025 22:32:56 +0900</pubDate>
    </item>
    <item>
      <title>결핵 접촉시간 계산기</title>
      <link>https://tb-master.tistory.com/pages/%EA%B2%B0%ED%95%B5-%EC%A0%91%EC%B4%89%EC%8B%9C%EA%B0%84-%EA%B3%84%EC%82%B0%EA%B8%B0</link>
      <description>&lt;html lang=&quot;ko&quot;&gt;
&lt;head&gt;
  &lt;meta charset=&quot;UTF-8&quot;&gt;
  &lt;title&gt;결핵 접촉시간 계산기&lt;/title&gt;
  &lt;style&gt;
   body {
      background-color: #f4f8fb;
      padding: 40px;
      margin: auto;
      color: #333;
    }
    h1 {
      text-align: center;
      color: #005f73;
      margin-bottom: 30px;
    }
    label {
      display: flex;
      justify-content: space-between;
      align-items: center;
      background: #ffffff;
      padding: 10px 15px;
      margin-top: 10px;
      border: 1px solid #d3e0ea;
      border-radius: 5px;
      box-shadow: 0 1px 2px rgba(0,0,0,0.05);
    }
    input[type=&quot;number&quot;],
    input[type=&quot;date&quot;] {
      width: 120px;
      padding: 5px;
      font-size: 14px;
      border: 1px solid #ccc;
      border-radius: 4px;
    }
    h3 {
      margin-top: 30px;
      color: #0a9396;
    }
    .result {
      margin-top: 30px;
      font-weight: bold;
      font-size: 18px;
      text-align: center;
      color: #005f73;
      padding: 15px;
      background-color: #e0fbfc;
      border-radius: 6px;
      border: 1px solid #cdd7df;
    }
    button {
      display: block;
      width: 100%;
      background-color: #94d2bd;
      color: #003845;
      font-weight: bold;
      border: none;
      padding: 12px;
      border-radius: 6px;
      font-size: 16px;
      margin-top: 25px;
      cursor: pointer;
      transition: background-color 0.3s ease;
    }
    button:hover {
      background-color: #72c2aa;
    }
    footer {
      text-align: center;
      margin-top: 40px;
      color: #888;
      font-size: 14px;
    }
  &lt;/style&gt;
&lt;/head&gt;
&lt;body&gt;
  &lt;h1&gt;결핵 접촉시간 계산기&lt;/h1&gt;
  &lt;label&gt;조사 시작일: &lt;input type=&quot;date&quot; id=&quot;startDate&quot;&gt;&lt;/label&gt;
  &lt;label&gt;조사 종료일: &lt;input type=&quot;date&quot; id=&quot;endDate&quot;&gt;&lt;/label&gt;

  &lt;h3&gt;요일별 접촉시간 (시간)&lt;/h3&gt;
  &lt;label&gt;월요일: &lt;input type=&quot;number&quot; id=&quot;mon&quot; value=&quot;0&quot; min=&quot;0&quot;&gt;&lt;/label&gt;
  &lt;label&gt;화요일: &lt;input type=&quot;number&quot; id=&quot;tue&quot; value=&quot;0&quot; min=&quot;0&quot;&gt;&lt;/label&gt;
  &lt;label&gt;수요일: &lt;input type=&quot;number&quot; id=&quot;wed&quot; value=&quot;0&quot; min=&quot;0&quot;&gt;&lt;/label&gt;
  &lt;label&gt;목요일: &lt;input type=&quot;number&quot; id=&quot;thu&quot; value=&quot;0&quot; min=&quot;0&quot;&gt;&lt;/label&gt;
  &lt;label&gt;금요일: &lt;input type=&quot;number&quot; id=&quot;fri&quot; value=&quot;0&quot; min=&quot;0&quot;&gt;&lt;/label&gt;
  &lt;label&gt;토요일: &lt;input type=&quot;number&quot; id=&quot;sat&quot; value=&quot;0&quot; min=&quot;0&quot;&gt;&lt;/label&gt;
  &lt;label&gt;일요일: &lt;input type=&quot;number&quot; id=&quot;sun&quot; value=&quot;0&quot; min=&quot;0&quot;&gt;&lt;/label&gt;

  &lt;button onclick=&quot;calculateTime()&quot;&gt;총 접촉시간 계산&lt;/button&gt;

  &lt;div class=&quot;result&quot; id=&quot;result&quot;&gt;&lt;/div&gt;

  &lt;footer&gt;
    &amp;copy; unkidayeon
  &lt;/footer&gt;

  &lt;script&gt;
    function calculateTime() {
      const start = new Date(document.getElementById('startDate').value);
      const end = new Date(document.getElementById('endDate').value);
      if (isNaN(start.getTime()) || isNaN(end.getTime()) || start &gt; end) {
        alert('올바른 날짜를 입력해주세요.');
        return;
      }

      const hoursPerDay = [
        Math.max(0, parseFloat(document.getElementById('sun').value)),
        Math.max(0, parseFloat(document.getElementById('mon').value)),
        Math.max(0, parseFloat(document.getElementById('tue').value)),
        Math.max(0, parseFloat(document.getElementById('wed').value)),
        Math.max(0, parseFloat(document.getElementById('thu').value)),
        Math.max(0, parseFloat(document.getElementById('fri').value)),
        Math.max(0, parseFloat(document.getElementById('sat').value))
      ];

      let totalHours = 0;
      for (let d = new Date(start); d &lt;= end; d.setDate(d.getDate() + 1)) {
        const day = d.getDay();
        totalHours += hoursPerDay[day];
      }

      const result = `총 접촉시간: ${totalHours}시간`;
      document.getElementById('result').innerHTML = result;
    }
  &lt;/script&gt;
&lt;/body&gt;
&lt;/html&gt;</description>
      <author>결핵마스터</author>
      <guid isPermaLink="true">https://tb-master.tistory.com/pages/%EA%B2%B0%ED%95%B5-%EC%A0%91%EC%B4%89%EC%8B%9C%EA%B0%84-%EA%B3%84%EC%82%B0%EA%B8%B0</guid>
      <pubDate>Tue, 8 Apr 2025 22:18:51 +0900</pubDate>
    </item>
    <item>
      <title>결핵 약제 약어 설명</title>
      <link>https://tb-master.tistory.com/8</link>
      <description>&lt;p&gt;&lt;figure class=&quot;imageblock alignCenter&quot; data-ke-mobileStyle=&quot;widthOrigin&quot; data-filename=&quot;제목을-입력해주세요_-002.jpg&quot; data-origin-width=&quot;500&quot; data-origin-height=&quot;500&quot;&gt;&lt;span data-url=&quot;https://blog.kakaocdn.net/dn/vuDvt/btsJuGRkzA1/8TyE7bW7IlomkdUzbJnjNK/img.jpg&quot; data-phocus=&quot;https://blog.kakaocdn.net/dn/vuDvt/btsJuGRkzA1/8TyE7bW7IlomkdUzbJnjNK/img.jpg&quot;&gt;&lt;img src=&quot;https://blog.kakaocdn.net/dn/vuDvt/btsJuGRkzA1/8TyE7bW7IlomkdUzbJnjNK/img.jpg&quot; srcset=&quot;https://img1.daumcdn.net/thumb/R1280x0/?scode=mtistory2&amp;fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdn%2FvuDvt%2FbtsJuGRkzA1%2F8TyE7bW7IlomkdUzbJnjNK%2Fimg.jpg&quot; onerror=&quot;this.onerror=null; this.src='//t1.daumcdn.net/tistory_admin/static/images/no-image-v1.png'; this.srcset='//t1.daumcdn.net/tistory_admin/static/images/no-image-v1.png';&quot; alt=&quot;결핵 약제 약어 설명&quot; loading=&quot;lazy&quot; width=&quot;500&quot; height=&quot;500&quot; data-filename=&quot;제목을-입력해주세요_-002.jpg&quot; data-origin-width=&quot;500&quot; data-origin-height=&quot;500&quot;/&gt;&lt;/span&gt;&lt;/figure&gt;
&lt;/p&gt;
&lt;h2 data-ke-size=&quot;size26&quot;&gt;결핵 약제 약어 설명&lt;/h2&gt;
&lt;p data-ke-size=&quot;size16&quot;&gt;결핵 치료에 사용되는 약제는 크게 1차 약제와 2차 약제로 나뉩니다. 각 약제의 주요 내용을 설명드리겠습니다.&lt;/p&gt;
&lt;h3 data-ke-size=&quot;size23&quot;&gt;1차 약제&lt;/h3&gt;
&lt;p data-ke-size=&quot;size16&quot;&gt;1차 약제는 결핵 치료의 기본적인 약제로, 다음과 같은 약물이 포함됩니다.&lt;/p&gt;
&lt;ol style=&quot;list-style-type: decimal;&quot; data-ke-list-type=&quot;decimal&quot;&gt;
&lt;li&gt;&lt;b&gt;H (Isoniazid, INH)&lt;/b&gt;: 이소니아지드는 결핵 치료의 핵심 약물 중 하나로, 결핵균의 세포벽 합성을 억제하여 균의 증식을 막습니다. 간 독성이 있을 수 있어 치료 중 간 기능 모니터링이 필요합니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;R (Rifampicin, RIF)&lt;/b&gt;: 리팜핀은 결핵균의 RNA 합성을 억제하는 강력한 항결핵제입니다. 주로 H와 함께 결핵 치료의 중심을 이룹니다. 간독성과 약물 상호작용에 주의가 필요합니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;E (Ethambutol, EMB)&lt;/b&gt;: 에탐부톨은 결핵균의 세포벽 합성을 방해합니다. 시신경염 등 시력 관련 부작용이 있을 수 있으므로 정기적인 시력 검사가 필요합니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Z (Pyrazinamide, PZA)&lt;/b&gt;: 피라진아미드는 결핵균의 세포 내 산성 환경에서 활성을 보이며, 치료 초기(집중 치료 단계)에서 주로 사용됩니다. 간독성과 고요산혈증의 위험이 있습니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;RFB (Rifabutin)&lt;/b&gt;: 리파부틴은 리팜핀의 대체 약물로, 리팜핀과 유사한 작용을 하지만 약물 상호작용이 적고 부작용이 덜한 편입니다. 주로 HIV 동반 결핵환자에게 사용됩니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;RPT (Rifapentine)&lt;/b&gt;: 리파펜틴은 리팜핀 유사 약물로, 주로 잠복 결핵 치료에서 사용됩니다.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3 data-ke-size=&quot;size23&quot;&gt;2차 약제&lt;/h3&gt;
&lt;p data-ke-size=&quot;size16&quot;&gt;1차 약제에 내성이 있거나 부작용이 있는 경우, 2차 약제가 사용됩니다.&lt;/p&gt;
&lt;ol style=&quot;list-style-type: decimal;&quot; data-ke-list-type=&quot;decimal&quot;&gt;
&lt;li&gt;&lt;b&gt;Km (Kanamycin)&lt;/b&gt;: 카나마이신은 주사제로 투여되는 아미노글리코사이드 계열의 항생제로, 결핵균의 단백질 합성을 억제합니다. 신독성과 이독성이 있을 수 있습니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Am (Amikacin)&lt;/b&gt;: 아미카신은 카나마이신과 유사한 아미노글리코사이드 계열 약물로, 내성 결핵 치료에 사용됩니다. 신독성과 이독성 위험이 있습니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Cm (Capreomycin)&lt;/b&gt;: 카프레오마이신은 주사제로 투여되며, 단백질 합성을 억제하여 결핵균을 치료합니다. 신독성 및 이독성 부작용이 있습니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;S (Streptomycin)&lt;/b&gt;: 스트렙토마이신은 결핵 치료에 오래전부터 사용되어 온 주사제이며, 단백질 합성을 억제합니다. 신독성 및 이독성 부작용이 있을 수 있습니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Lfx (Levofloxacin)&lt;/b&gt;: 레보플록사신은 퀴놀론 계열의 항생제로, 결핵균의 DNA 복제를 억제합니다. 결핵 치료에서 중요한 2차 약제 중 하나입니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Mfx (Moxifloxacin)&lt;/b&gt;: 목시플록사신은 레보플록사신과 유사한 퀴놀론 계열 항생제로, 내성 결핵 치료에 자주 사용됩니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Ofx (Ofloxacin)&lt;/b&gt;: 오플록사신은 퀴놀론 계열의 항결핵제로, 레보플록사신이나 목시플록사신이 사용되지 못할 경우 사용됩니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Gfx (Gatifloxacin)&lt;/b&gt;: 가티플록사신은 다른 퀴놀론 계열 항생제와 유사한 작용을 하며, 내성 결핵 치료에 사용됩니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Pto (Protionamide)&lt;/b&gt;: 프로티오나미드는 이소니아지드와 유사하게 작용하지만 내성 결핵 치료에 사용됩니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Cs (Cycloserine)&lt;/b&gt;: 사이클로세린은 결핵균의 세포벽 합성을 억제하며, 내성 결핵 치료에 사용됩니다. 정신과적 부작용이 있을 수 있습니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;PAS (Para-aminosalicylic acid)&lt;/b&gt;: 파라아미노살리실산은 결핵균의 엽산 합성을 억제합니다. 내성 결핵 치료에 사용되며, 위장 장애가 부작용으로 나타날 수 있습니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Eto (Ethionamide)&lt;/b&gt;: 에티오나미드는 이소니아지드와 유사하게 결핵균의 세포벽 합성을 억제하며, 내성 결핵 치료에 사용됩니다. 간독성과 위장장애가 있을 수 있습니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Trd (Terizidone)&lt;/b&gt;: 테리지돈은 사이클로세린과 유사한 약물로, 내성 결핵 치료에 사용됩니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;PAS-Na&lt;/b&gt;: 파라아미노살리실산나트륨은 파라아미노살리실산의 나트륨염 형태로, 동일한 작용을 합니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Lzd (Linezolid)&lt;/b&gt;: 리네졸리드는 내성 결핵 치료에서 중요한 역할을 하는 약물로, 단백질 합성을 억제합니다. 장기 사용 시 골수억제, 신경병증 등의 부작용이 있을 수 있습니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Clr (Clarithromycin)&lt;/b&gt;: 클래리트로마이신은 결핵균의 단백질 합성을 억제하며, 비결핵항산균 치료에 사용되기도 합니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Bdq (Bedaquiline)&lt;/b&gt;: 베다퀼린은 ATP 합성을 억제하여 결핵균을 죽입니다. 내성 결핵 치료에서 중요하게 사용되며, 부정맥 위험이 있습니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Dlm (Delamanid)&lt;/b&gt;: 델라마니드는 결핵균의 세포벽 합성을 억제하는 약물로, 다제내성 결핵 치료에 사용됩니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Cfz (Clofazimine)&lt;/b&gt;: 클로파지민은 결핵과 나병 치료에 사용되며, 염증을 줄이고 결핵균을 억제합니다. 피부 변색 등의 부작용이 있습니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Mpm (Meropenem)&lt;/b&gt;: 메로페넴은 베타락탐계 항생제로, 주로 다른 약제와 병용하여 결핵 치료에 사용됩니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Amx/Clv (Amoxicillin/Clavulanate)&lt;/b&gt;: 아목시실린/클라불란산은 페니실린계 항생제로, 주로 다른 약제와 병용하여 사용됩니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Ipm/Cln (Imipenem/Cilastatin)&lt;/b&gt;: 이미페넴/실라스타틴은 결핵 치료에서 다른 약제와 병용하여 사용됩니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;High dose H (고용량 이소니아지드)&lt;/b&gt;: 고용량 이소니아지드는 이소니아지드 저항성을 가진 결핵균에 사용됩니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;T (Thioacetazone)&lt;/b&gt;: 티오아세타존은 오래된 결핵 치료제이며, 주로 다른 약제와 병용하여 사용됩니다.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Pa (Pretomanid)&lt;/b&gt;: 프레토마니드는 최근 개발된 항결핵제로, 다제내성 결핵 치료에 사용됩니다.&lt;/li&gt;
&lt;/ol&gt;
&lt;p data-ke-size=&quot;size16&quot;&gt;이 외에도 결핵 치료에 사용되는 약제가 있을 수 있으며, 치료는 환자의 상태와 내성 여부에 따라 개인화된 처방이 필요합니다. 약물 사용 중 부작용과 상호작용을 주의 깊게 모니터링하는 것이 중요합니다.&lt;/p&gt;</description>
      <category>결핵</category>
      <category>결핵 약제 설명</category>
      <author>결핵마스터</author>
      <guid isPermaLink="true">https://tb-master.tistory.com/8</guid>
      <comments>https://tb-master.tistory.com/8#entry8comment</comments>
      <pubDate>Sat, 7 Sep 2024 21:14:22 +0900</pubDate>
    </item>
    <item>
      <title>결핵 사례조사 작성</title>
      <link>https://tb-master.tistory.com/pages/%EA%B2%B0%ED%95%B5-%EC%82%AC%EB%A1%80%EC%A1%B0%EC%82%AC-%EC%9E%91%EC%84%B1</link>
      <description>&lt;p&gt;&lt;figure class=&quot;imageblock alignCenter&quot; data-ke-mobileStyle=&quot;widthOrigin&quot; data-filename=&quot;결핵 사례조사.jpg&quot; data-origin-width=&quot;500&quot; data-origin-height=&quot;500&quot;&gt;&lt;span data-url=&quot;https://blog.kakaocdn.net/dn/bUorxC/btsJpIghCNw/jTCxpaHMKtru730x3jkUw1/img.jpg&quot; data-phocus=&quot;https://blog.kakaocdn.net/dn/bUorxC/btsJpIghCNw/jTCxpaHMKtru730x3jkUw1/img.jpg&quot;&gt;&lt;img src=&quot;https://blog.kakaocdn.net/dn/bUorxC/btsJpIghCNw/jTCxpaHMKtru730x3jkUw1/img.jpg&quot; srcset=&quot;https://img1.daumcdn.net/thumb/R1280x0/?scode=mtistory2&amp;fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdn%2FbUorxC%2FbtsJpIghCNw%2FjTCxpaHMKtru730x3jkUw1%2Fimg.jpg&quot; onerror=&quot;this.onerror=null; this.src='//t1.daumcdn.net/tistory_admin/static/images/no-image-v1.png'; this.srcset='//t1.daumcdn.net/tistory_admin/static/images/no-image-v1.png';&quot; loading=&quot;lazy&quot; width=&quot;500&quot; height=&quot;500&quot; data-filename=&quot;결핵 사례조사.jpg&quot; data-origin-width=&quot;500&quot; data-origin-height=&quot;500&quot;/&gt;&lt;/span&gt;&lt;/figure&gt;
&lt;/p&gt;
&lt;!DOCTYPE html&gt;
&lt;html lang=&quot;ko&quot;&gt;
&lt;head&gt;
    &lt;meta charset=&quot;UTF-8&quot;&gt;
    &lt;meta name=&quot;viewport&quot; content=&quot;width=device-width, initial-scale=1.0&quot;&gt;
    &lt;title&gt;결핵 사례조사 양식&lt;/title&gt;
    &lt;style&gt;
        body {
            font-family: Arial, sans-serif;
            line-height: 1.6;
            margin: 20px;
        }
        .container {
            max-width: 800px;
            margin: 0 auto;
        }
        .section {
            margin-bottom: 20px;
            padding: 15px;
              border: 1px solid #ccc;
             border-radius: 8px;
             background-color: #f9f9f9;

        }
        h2 {
            margin-bottom: 10px;
        }
        label {
            display: block;
            margin-bottom: 5px;
        }
        input[type=&quot;text&quot;],
        input[type=&quot;date&quot;],
        input[type=&quot;number&quot;] {
            width: 80%;
            padding: 8px;
            margin-bottom: 10px;
            border: 1px solid #ddd;
            border-radius: 4px;
        }
        input[type=&quot;radio&quot;] {
            margin-right: 5px;
        }
        .checkbox-group label {
            display: inline-block;
            margin-right: 20px;
        }
        .conditional-input {
            display: none;
            margin-top: 10px;
            padding: 10px;
            border: 1px solid #ddd;
            border-radius: 4px;
            background-color: #e9ecef;
}        
        .conditional-input label {
            display: inline;
        }
        .detail-output {
            margin-top: 10px;
        }
        .detail-output span {
            font-weight: bold;
        }
        button {
            padding: 10px 20px;
            background-color: #007bff;
            color: #fff;
            border: none;
            border-radius: 4px;
            cursor: pointer;
        }
        button:hover {
            background-color: #0056b3;
        }
        #reportOutput {
            margin-top: 20px;
            padding: 10px;
            border: 1px solid #ddd;
            border-radius: 4px;
        }
    &lt;/style&gt;
&lt;/head&gt;
&lt;body&gt;
    &lt;div class=&quot;container&quot;&gt;
        &lt;form id=&quot;caseForm&quot;&gt;
            &lt;!-- 기본 정보 --&gt;
            &lt;div class=&quot;section&quot;&gt;
                &lt;h2&gt;기본 정보&lt;/h2&gt;
                &lt;label for=&quot;name&quot;&gt;이름:&lt;/label&gt;
                &lt;input type=&quot;text&quot; id=&quot;name&quot; name=&quot;name&quot; placeholder=&quot;이름을 입력하세요&quot;&gt;
                &lt;label for=&quot;dob&quot;&gt;생년월일:&lt;/label&gt;
                &lt;input type=&quot;date&quot; id=&quot;dob&quot; name=&quot;dob&quot; max=&quot;9999-12-31&quot; placeholder=&quot;YYYY-MM-DD&quot;&gt;
                &lt;label for=&quot;phone&quot;&gt;전화번호:&lt;/label&gt;
                &lt;input type=&quot;text&quot; id=&quot;phone&quot; name=&quot;phone&quot; placeholder=&quot;전화번호를 입력하세요&quot;&gt;
            &lt;/div&gt;

            &lt;!-- 신고 정보 --&gt;
            &lt;div class=&quot;section&quot;&gt;
                &lt;h2&gt;신고 정보&lt;/h2&gt;
                &lt;label for=&quot;report-date&quot;&gt;신고일자:&lt;/label&gt;
                &lt;input type=&quot;date&quot; id=&quot;report-date&quot; name=&quot;report-date&quot;&gt;
                &lt;label for=&quot;hospital&quot;&gt;병원:&lt;/label&gt;
                &lt;input type=&quot;text&quot; id=&quot;hospital&quot; name=&quot;hospital&quot; placeholder=&quot;병원을 입력하세요&quot;&gt;
                &lt;label for=&quot;cxr-date&quot;&gt;CXR 검사일자:&lt;/label&gt;
                &lt;input type=&quot;date&quot; id=&quot;cxr-date&quot; name=&quot;cxr-date&quot;&gt;
                &lt;label for=&quot;cxr-result&quot;&gt;CXR 검사 결과:&lt;/label&gt;
                &lt;input type=&quot;text&quot; id=&quot;cxr-result&quot; name=&quot;cxr-result&quot; placeholder=&quot;검사 결과를 입력하세요&quot;&gt;
                &lt;label for=&quot;sputum-test&quot;&gt;객담검사 결과:&lt;/label&gt;
                &lt;input type=&quot;text&quot; id=&quot;sputum-test&quot; name=&quot;sputum-test&quot; placeholder=&quot;객담검사 결과를 입력하세요&quot;&gt;
                &lt;label&gt;약제 시작:&lt;/label&gt;
                &lt;div class=&quot;checkbox-group&quot;&gt;
                    &lt;label&gt;&lt;input type=&quot;radio&quot; id=&quot;medication-start-yes&quot; name=&quot;medication-start&quot; value=&quot;yes&quot; onchange=&quot;toggleConditionalFields()&quot;&gt; 예&lt;/label&gt;
                    &lt;label&gt;&lt;input type=&quot;radio&quot; id=&quot;medication-start-no&quot; name=&quot;medication-start&quot; value=&quot;no&quot; onchange=&quot;toggleConditionalFields()&quot;&gt; 아니오&lt;/label&gt;
                &lt;/div&gt;
                &lt;div id=&quot;medication-date-group&quot; class=&quot;conditional-input&quot;&gt;
                    &lt;label for=&quot;medication-date&quot;&gt;약제 시작일:&lt;/label&gt;
                    &lt;input type=&quot;date&quot; id=&quot;medication-date&quot; name=&quot;medication-date&quot;&gt;
                &lt;/div&gt;
            &lt;/div&gt;

            &lt;!-- 개인력 --&gt;
            &lt;div class=&quot;section&quot;&gt;
                &lt;h2&gt;개인력&lt;/h2&gt;
                &lt;label for=&quot;underlying-disease&quot;&gt;기저질환:&lt;/label&gt;
                &lt;input type=&quot;text&quot; id=&quot;underlying-disease&quot; name=&quot;underlying-disease&quot; placeholder=&quot;기저질환을 입력하세요&quot;&gt;
                &lt;label for=&quot;family-history&quot;&gt;가족력:&lt;/label&gt;
                &lt;input type=&quot;text&quot; id=&quot;family-history&quot; name=&quot;family-history&quot; placeholder=&quot;가족력을 입력하세요&quot;&gt;
                &lt;label for=&quot;past-history&quot;&gt;과거력:&lt;/label&gt;
                &lt;input type=&quot;text&quot; id=&quot;past-history&quot; name=&quot;past-history&quot; placeholder=&quot;과거력을 입력하세요&quot;&gt;
                &lt;label for=&quot;symptom-start&quot;&gt;증상 시작일:&lt;/label&gt;
                &lt;input type=&quot;date&quot; id=&quot;symptom-start&quot; name=&quot;symptom-start&quot;&gt;
                &lt;label for=&quot;symptom-description&quot;&gt;증상 설명:&lt;/label&gt;
                &lt;input type=&quot;text&quot; id=&quot;symptom-description&quot; name=&quot;symptom-description&quot; placeholder=&quot;증상 설명을 입력하세요&quot;&gt;
            &lt;/div&gt;

            &lt;!-- 기관 정보 --&gt;
            &lt;div class=&quot;section&quot;&gt;
                &lt;h2&gt;기관 정보&lt;/h2&gt;
                &lt;label for=&quot;institution-name&quot;&gt;기관 이름:&lt;/label&gt;
                &lt;input type=&quot;text&quot; id=&quot;institution-name&quot; name=&quot;institution-name&quot; placeholder=&quot;기관 이름을 입력하세요&quot;&gt;
                &lt;label for=&quot;institution-address&quot;&gt;기관 주소:&lt;/label&gt;
                &lt;input type=&quot;text&quot; id=&quot;institution-address&quot; name=&quot;institution-address&quot; placeholder=&quot;기관 주소를 입력하세요&quot;&gt;
                &lt;label for=&quot;years-worked&quot;&gt;근무년수:&lt;/label&gt;
                &lt;input type=&quot;number&quot; id=&quot;years-worked&quot; name=&quot;years-worked&quot; placeholder=&quot;근무년수를 입력하세요&quot; min=&quot;0&quot;&gt;
                &lt;label for=&quot;last-work-date&quot;&gt;마지막 출근일:&lt;/label&gt;
                &lt;input type=&quot;date&quot; id=&quot;last-work-date&quot; name=&quot;last-work-date&quot;&gt;
                &lt;label for=&quot;work-hours&quot;&gt;업무시간:&lt;/label&gt;
                &lt;input type=&quot;text&quot; id=&quot;work-hours&quot; name=&quot;work-hours&quot; placeholder=&quot;업무시간을 입력하세요&quot;&gt;
                &lt;label&gt;형태 (내근직/외근직):&lt;/label&gt;
                &lt;div class=&quot;checkbox-group&quot;&gt;
                    &lt;label&gt;&lt;input type=&quot;radio&quot; id=&quot;on-site&quot; name=&quot;work-type&quot; value=&quot;on-site&quot; onchange=&quot;toggleConditionalFields()&quot;&gt; 내근직&lt;/label&gt;
                    &lt;label&gt;&lt;input type=&quot;radio&quot; id=&quot;field&quot; name=&quot;work-type&quot; value=&quot;field&quot; onchange=&quot;toggleConditionalFields()&quot;&gt; 외근직&lt;/label&gt;
                &lt;/div&gt;
                &lt;label for=&quot;work-location&quot;&gt;근무 위치:&lt;/label&gt;
                &lt;input type=&quot;text&quot; id=&quot;work-location&quot; name=&quot;work-location&quot; placeholder=&quot;근무 위치를 입력하세요&quot;&gt;
            &lt;/div&gt;

            &lt;!-- 식사 및 휴식 공간 --&gt;
            &lt;div class=&quot;section&quot;&gt;
                &lt;h2&gt;식사 및 휴식 공간&lt;/h2&gt;
                &lt;label&gt;식사여부:&lt;/label&gt;
                &lt;div class=&quot;checkbox-group&quot;&gt;
                    &lt;label&gt;&lt;input type=&quot;radio&quot; id=&quot;meal-info-yes&quot; name=&quot;meal-info&quot; value=&quot;yes&quot; onchange=&quot;toggleConditionalFields()&quot;&gt; 예&lt;/label&gt;
                    &lt;label&gt;&lt;input type=&quot;radio&quot; id=&quot;meal-info-no&quot; name=&quot;meal-info&quot; value=&quot;no&quot; onchange=&quot;toggleConditionalFields()&quot;&gt; 아니오&lt;/label&gt;
                &lt;/div&gt;
                &lt;div id=&quot;meal-details&quot; class=&quot;conditional-input&quot;&gt;
                    &lt;label for=&quot;meal-details-text&quot;&gt;세부사항:&lt;/label&gt;
                    &lt;input type=&quot;text&quot; id=&quot;meal-details-text&quot; name=&quot;meal-details-text&quot; placeholder=&quot;식사 여부 세부사항을 입력하세요&quot;&gt;
                &lt;/div&gt;
                &lt;label&gt;휴식공간:&lt;/label&gt;
                &lt;div class=&quot;checkbox-group&quot;&gt;
                    &lt;label&gt;&lt;input type=&quot;radio&quot; id=&quot;break-space-yes&quot; name=&quot;break-space&quot; value=&quot;yes&quot; onchange=&quot;toggleConditionalFields()&quot;&gt; 예&lt;/label&gt;
                    &lt;label&gt;&lt;input type=&quot;radio&quot; id=&quot;break-space-no&quot; name=&quot;break-space&quot; value=&quot;no&quot; onchange=&quot;toggleConditionalFields()&quot;&gt; 아니오&lt;/label&gt;
                &lt;/div&gt;
                &lt;div id=&quot;break-space-details&quot; class=&quot;conditional-input&quot;&gt;
                    &lt;label for=&quot;break-space-details-text&quot;&gt;세부사항:&lt;/label&gt;
                    &lt;input type=&quot;text&quot; id=&quot;break-space-details-text&quot; name=&quot;break-space-details-text&quot; placeholder=&quot;휴식공간 세부사항을 입력하세요&quot;&gt;
                &lt;/div&gt;
            &lt;/div&gt;

            &lt;!-- 검진 및 기타 사항 --&gt;
            &lt;div class=&quot;section&quot;&gt;
                &lt;h2&gt;검진 및 기타 사항&lt;/h2&gt;
                &lt;label&gt;채용검진/건강검진(보건증):&lt;/label&gt;
                &lt;div class=&quot;checkbox-group&quot;&gt;
                    &lt;label&gt;&lt;input type=&quot;radio&quot; id=&quot;health-check-yes&quot; name=&quot;health-check&quot; value=&quot;yes&quot; onchange=&quot;toggleConditionalFields()&quot;&gt; 예&lt;/label&gt;
                    &lt;label&gt;&lt;input type=&quot;radio&quot; id=&quot;health-check-no&quot; name=&quot;health-check&quot; value=&quot;no&quot; onchange=&quot;toggleConditionalFields()&quot;&gt; 아니오&lt;/label&gt;
                &lt;/div&gt;
                &lt;div id=&quot;health-check-details&quot; class=&quot;conditional-input&quot;&gt;
                    &lt;label for=&quot;health-check-date&quot;&gt;검진 날짜:&lt;/label&gt;
                    &lt;input type=&quot;date&quot; id=&quot;health-check-date&quot; name=&quot;health-check-date&quot;&gt;
                &lt;/div&gt;
                &lt;label&gt;출장/재택근무:&lt;/label&gt;
                &lt;div class=&quot;checkbox-group&quot;&gt;
                    &lt;label&gt;&lt;input type=&quot;radio&quot; id=&quot;business-travel-yes&quot; name=&quot;business-travel&quot; value=&quot;yes&quot; onchange=&quot;toggleConditionalFields()&quot;&gt; 예&lt;/label&gt;
                    &lt;label&gt;&lt;input type=&quot;radio&quot; id=&quot;business-travel-no&quot; name=&quot;business-travel&quot; value=&quot;no&quot; onchange=&quot;toggleConditionalFields()&quot;&gt; 아니오&lt;/label&gt;
                &lt;/div&gt;
                &lt;div id=&quot;business-travel-details&quot; class=&quot;conditional-input&quot;&gt;
                    &lt;label for=&quot;business-travel-details-text&quot;&gt;세부사항:&lt;/label&gt;
                    &lt;input type=&quot;text&quot; id=&quot;business-travel-details-text&quot; name=&quot;business-travel-details-text&quot; placeholder=&quot;출장/재택근무 세부사항을 입력하세요&quot;&gt;
                &lt;/div&gt;
                &lt;label&gt;동아리/카풀/공용식당:&lt;/label&gt;
                &lt;div class=&quot;checkbox-group&quot;&gt;
                    &lt;label&gt;&lt;input type=&quot;radio&quot; id=&quot;clubs-carpool-yes&quot; name=&quot;clubs-carpool&quot; value=&quot;yes&quot; onchange=&quot;toggleConditionalFields()&quot;&gt; 예&lt;/label&gt;
                    &lt;label&gt;&lt;input type=&quot;radio&quot; id=&quot;clubs-carpool-no&quot; name=&quot;clubs-carpool&quot; value=&quot;no&quot; onchange=&quot;toggleConditionalFields()&quot;&gt; 아니오&lt;/label&gt;
                &lt;/div&gt;
                &lt;div id=&quot;clubs-carpool-details&quot; class=&quot;conditional-input&quot;&gt;
                    &lt;label for=&quot;clubs-carpool-details-text&quot;&gt;세부사항:&lt;/label&gt;
                    &lt;input type=&quot;text&quot; id=&quot;clubs-carpool-details-text&quot; name=&quot;clubs-carpool-details-text&quot; placeholder=&quot;동아리/카풀/공용식당 세부사항을 입력하세요&quot;&gt;
                &lt;/div&gt;
                &lt;label for=&quot;close-colleagues&quot;&gt;친했던 동료:&lt;/label&gt;
                &lt;input type=&quot;text&quot; id=&quot;close-colleagues&quot; name=&quot;close-colleagues&quot; placeholder=&quot;친했던 동료를 입력하세요&quot;&gt;
            &lt;/div&gt;

            &lt;!-- 전염성 추정 기간 --&gt;
            &lt;div class=&quot;section&quot;&gt;
                &lt;h2&gt;전염성 추정 기간&lt;/h2&gt;
                &lt;label for=&quot;total-exposure-start&quot;&gt;전체 전염성 추정 기간 시작일:&lt;/label&gt;
                &lt;input type=&quot;date&quot; id=&quot;total-exposure-start&quot; name=&quot;total-exposure-start&quot;&gt;
                &lt;label for=&quot;total-exposure-end&quot;&gt;전체 전염성 추정 기간 종료일:&lt;/label&gt;
                &lt;input type=&quot;date&quot; id=&quot;total-exposure-end&quot; name=&quot;total-exposure-end&quot;&gt;
                &lt;label for=&quot;institution-exposure-start&quot;&gt;해당 기관 전염성 추정 기간 시작일:&lt;/label&gt;
                &lt;input type=&quot;date&quot; id=&quot;institution-exposure-start&quot; name=&quot;institution-exposure-start&quot;&gt;
                &lt;label for=&quot;institution-exposure-end&quot;&gt;해당 기관 전염성 추정 기간 종료일:&lt;/label&gt;
                &lt;input type=&quot;date&quot; id=&quot;institution-exposure-end&quot; name=&quot;institution-exposure-end&quot;&gt;
            &lt;/div&gt;

            &lt;!-- 제출 버튼 --&gt;
            &lt;button type=&quot;button&quot; onclick=&quot;generateReport()&quot;&gt;출력하기&lt;/button&gt;
        &lt;/form&gt;

        &lt;!-- 결과 출력 영역 --&gt;
        &lt;div id=&quot;reportOutput&quot;&gt;&lt;/div&gt;
    &lt;/div&gt;

    &lt;script&gt;
        // 조건부 입력 필드 표시/숨김
        function toggleConditionalFields() {
            const medicationStart = document.querySelector('input[name=&quot;medication-start&quot;]:checked');
            const mealInfo = document.querySelector('input[name=&quot;meal-info&quot;]:checked');
            const breakSpace = document.querySelector('input[name=&quot;break-space&quot;]:checked');
            const healthCheck = document.querySelector('input[name=&quot;health-check&quot;]:checked');
            const businessTravel = document.querySelector('input[name=&quot;business-travel&quot;]:checked');
            const clubsCarpool = document.querySelector('input[name=&quot;clubs-carpool&quot;]:checked');
            
            document.getElementById('medication-date-group').style.display = medicationStart &amp;&amp; medicationStart.value === 'yes' ? 'block' : 'none';
            document.getElementById('meal-details').style.display = mealInfo &amp;&amp; mealInfo.value === 'yes' ? 'block' : 'none';
            document.getElementById('break-space-details').style.display = breakSpace &amp;&amp; breakSpace.value === 'yes' ? 'block' : 'none';
            document.getElementById('health-check-details').style.display = healthCheck &amp;&amp; healthCheck.value === 'yes' ? 'block' : 'none';
            document.getElementById('business-travel-details').style.display = businessTravel &amp;&amp; businessTravel.value === 'yes' ? 'block' : 'none';
            document.getElementById('clubs-carpool-details').style.display = clubsCarpool &amp;&amp; clubsCarpool.value === 'yes' ? 'block' : 'none';
        }

        function calculateWeeks(startDate, endDate) {
            const start = new Date(startDate);
            const end = new Date(endDate);
            const oneWeek = 1000 * 60 * 60 * 24 * 7;
            return Math.round((end - start) / oneWeek);
        }

        function generateReport() {
            const name = document.getElementById('name').value;
            const dob = document.getElementById('dob').value;
            const phone = document.getElementById('phone').value;
            const reportDate = document.getElementById('report-date').value;
            const hospital = document.getElementById('hospital').value;
            const cxrDate = document.getElementById('cxr-date').value;
            const cxrResult = document.getElementById('cxr-result').value;
            const sputumTest = document.getElementById('sputum-test').value;
            const medicationStart = document.querySelector('input[name=&quot;medication-start&quot;]:checked')?.value;
            const medicationDate = document.getElementById('medication-date').value;
            const underlyingDisease = document.getElementById('underlying-disease').value;
            const familyHistory = document.getElementById('family-history').value;
            const pastHistory = document.getElementById('past-history').value;
            const symptomStart = document.getElementById('symptom-start').value;
            const symptomDescription = document.getElementById('symptom-description').value;
            const mealInfo = document.querySelector('input[name=&quot;meal-info&quot;]:checked')?.value;
            const mealDetails = mealInfo === 'yes' ? document.getElementById('meal-details-text').value : '';
            const breakSpace = document.querySelector('input[name=&quot;break-space&quot;]:checked')?.value;
            const breakSpaceDetails = breakSpace === 'yes' ? document.getElementById('break-space-details-text').value : '';
            const healthCheck = document.querySelector('input[name=&quot;health-check&quot;]:checked')?.value;
            const healthCheckDate = healthCheck === 'yes' ? document.getElementById('health-check-date').value : '';
            const businessTravel = document.querySelector('input[name=&quot;business-travel&quot;]:checked')?.value;
            const businessTravelDetails = businessTravel === 'yes' ? document.getElementById('business-travel-details-text').value : '';
            const clubsCarpool = document.querySelector('input[name=&quot;clubs-carpool&quot;]:checked')?.value;
            const clubsCarpoolDetails = clubsCarpool === 'yes' ? document.getElementById('clubs-carpool-details-text').value : '';
            const closeColleagues = document.getElementById('close-colleagues').value;
            const totalExposureStart = document.getElementById('total-exposure-start').value;
            const totalExposureEnd = document.getElementById('total-exposure-end').value;
            const institutionExposureStart = document.getElementById('institution-exposure-start').value;
            const institutionExposureEnd = document.getElementById('institution-exposure-end').value;
            
            const totalExposureWeeks = calculateWeeks(totalExposureStart, totalExposureEnd);
            const institutionExposureWeeks = calculateWeeks(institutionExposureStart, institutionExposureEnd);

            // 기관 정보
            const institutionName = document.getElementById('institution-name').value;
            const institutionAddress = document.getElementById('institution-address').value;
            const yearsWorked = document.getElementById('years-worked').value;
            const lastWorkDate = document.getElementById('last-work-date').value;
            const workHours = document.getElementById('work-hours').value;
            const workType = document.querySelector('input[name=&quot;work-type&quot;]:checked')?.value;
            const workLocation = document.getElementById('work-location').value;

            document.getElementById('reportOutput').innerHTML = `
                &lt;h2&gt;결핵 사례조사서&lt;/h2&gt;
                &lt;div class=&quot;detail-output&quot;&gt;
                    &lt;p&gt;&lt;span&gt; ▶ 이름:&lt;/span&gt; ${name} (${dob})&lt;/p&gt;
                    &lt;p&gt;&lt;span&gt;전화번호:&lt;/span&gt; ${phone}&lt;/p&gt;
                    &lt;p&gt;&lt;span&gt;신고일자:&lt;/span&gt; ${reportDate}&lt;/p&gt;
                    &lt;p&gt;&lt;span&gt;병원:&lt;/span&gt; ${hospital}&lt;/p&gt;
                    &lt;p&gt;&lt;span&gt;CXR 검사일자:&lt;/span&gt; ${cxrDate} (결과: ${cxrResult})&lt;/p&gt;
                    &lt;p&gt;&lt;span&gt;객담검사 결과:&lt;/span&gt; ${sputumTest}&lt;/p&gt;
                    &lt;p&gt;&lt;span&gt;약제 시작:&lt;/span&gt; ${medicationStart === 'yes' ? `예 (시작일: ${medicationDate})` : '아니오'}&lt;/p&gt;
                &lt;/div&gt;
                &lt;div class=&quot;detail-output&quot;&gt;
                    &lt;p&gt;&lt;span&gt;기저질환:&lt;/span&gt; ${underlyingDisease}&lt;/p&gt;
                    &lt;p&gt;&lt;span&gt;가족력:&lt;/span&gt; ${familyHistory}&lt;/p&gt;
                    &lt;p&gt;&lt;span&gt;과거력:&lt;/span&gt; ${pastHistory}&lt;/p&gt;
                    &lt;p&gt;&lt;span&gt;증상 시작일:&lt;/span&gt; ${symptomStart}&lt;/p&gt;
                    &lt;p&gt;&lt;span&gt;증상 설명:&lt;/span&gt; ${symptomDescription}&lt;/p&gt;
                &lt;/div&gt;
                &lt;br&gt;
                    &lt;div class=&quot;detail-output&quot;&gt;
                    &lt;p&gt;&lt;span&gt; ▶ 기관 이름:&lt;/span&gt; ${institutionName}(${institutionAddress})&lt;/p&gt;
                    &lt;p&gt;&lt;span&gt;근무년수:&lt;/span&gt; ${yearsWorked}&lt;/p&gt;
                    &lt;p&gt;&lt;span&gt;마지막 출근일:&lt;/span&gt; ${lastWorkDate}&lt;/p&gt;
                    &lt;p&gt;&lt;span&gt;업무시간:&lt;/span&gt; ${workHours}&lt;/p&gt;
                    &lt;p&gt;&lt;span&gt;형태:&lt;/span&gt; ${workType === 'on-site' ? '내근직' : '외근직'}&lt;/p&gt;
                    &lt;p&gt;&lt;span&gt;근무 위치:&lt;/span&gt; ${workLocation}&lt;/p&gt;
                &lt;/div&gt;
                &lt;div class=&quot;detail-output&quot;&gt;
                    &lt;p&gt;&lt;span&gt;식사 여부:&lt;/span&gt; ${mealInfo === 'yes' ? `예 (세부사항: ${mealDetails})` : '아니오'}&lt;/p&gt;
                    &lt;p&gt;&lt;span&gt;휴식공간:&lt;/span&gt; ${breakSpace === 'yes' ? `예 (세부사항: ${breakSpaceDetails})` : '아니오'}&lt;/p&gt;
                &lt;/div&gt;
                &lt;div class=&quot;detail-output&quot;&gt;
                    &lt;p&gt;&lt;span&gt;채용검진/건강검진:&lt;/span&gt; ${healthCheck === 'yes' ? `예 (검진 날짜: ${healthCheckDate})` : '아니오'}&lt;/p&gt;
                    &lt;p&gt;&lt;span&gt;출장/재택근무:&lt;/span&gt; ${businessTravel === 'yes' ? `예 (세부사항: ${businessTravelDetails})` : '아니오'}&lt;/p&gt;
                    &lt;p&gt;&lt;span&gt;동아리/카풀/공용식당:&lt;/span&gt; ${clubsCarpool === 'yes' ? `예 (세부사항: ${clubsCarpoolDetails})` : '아니오'}&lt;/p&gt;
                    &lt;p&gt;&lt;span&gt;친했던 동료:&lt;/span&gt; ${closeColleagues}&lt;/p&gt;
                &lt;/div&gt;
                &lt;div class=&quot;detail-output&quot;&gt;
                    &lt;p&gt;&lt;span&gt;전체 전염성 추정 기간:&lt;/span&gt; ${totalExposureWeeks} 주 (${totalExposureStart} ~ ${totalExposureEnd})&lt;/p&gt;
                    &lt;p&gt;&lt;span&gt;해당 기관 전염성 추정 기간:&lt;/span&gt; ${institutionExposureWeeks} 주 (${institutionExposureStart} ~ ${institutionExposureEnd})&lt;/p&gt;
                &lt;/div&gt;

            `;
        }
    &lt;/script&gt;
&lt;/body&gt;
&lt;/html&gt;</description>
      <author>결핵마스터</author>
      <guid isPermaLink="true">https://tb-master.tistory.com/pages/%EA%B2%B0%ED%95%B5-%EC%82%AC%EB%A1%80%EC%A1%B0%EC%82%AC-%EC%9E%91%EC%84%B1</guid>
      <pubDate>Mon, 2 Sep 2024 23:58:57 +0900</pubDate>
    </item>
    <item>
      <title>결핵 역학조사 전염성 추정기간 계산기 사용법</title>
      <link>https://tb-master.tistory.com/6</link>
      <description>&lt;p&gt;&lt;figure class=&quot;imageblock alignCenter&quot; data-ke-mobileStyle=&quot;widthOrigin&quot; data-filename=&quot;결핵 역학조사 전염성 .png&quot; data-origin-width=&quot;500&quot; data-origin-height=&quot;500&quot;&gt;&lt;span data-url=&quot;https://blog.kakaocdn.net/dn/oTrDH/btsJdzMvnR9/mLtmy3K7ffRwLKlFnT1N5K/img.png&quot; data-phocus=&quot;https://blog.kakaocdn.net/dn/oTrDH/btsJdzMvnR9/mLtmy3K7ffRwLKlFnT1N5K/img.png&quot;&gt;&lt;img src=&quot;https://blog.kakaocdn.net/dn/oTrDH/btsJdzMvnR9/mLtmy3K7ffRwLKlFnT1N5K/img.png&quot; srcset=&quot;https://img1.daumcdn.net/thumb/R1280x0/?scode=mtistory2&amp;fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdn%2FoTrDH%2FbtsJdzMvnR9%2FmLtmy3K7ffRwLKlFnT1N5K%2Fimg.png&quot; onerror=&quot;this.onerror=null; this.src='//t1.daumcdn.net/tistory_admin/static/images/no-image-v1.png'; this.srcset='//t1.daumcdn.net/tistory_admin/static/images/no-image-v1.png';&quot; alt=&quot;결핵 역학조사 전염성 추정기간 계산기 사용법&quot; loading=&quot;lazy&quot; width=&quot;500&quot; height=&quot;500&quot; data-filename=&quot;결핵 역학조사 전염성 .png&quot; data-origin-width=&quot;500&quot; data-origin-height=&quot;500&quot;/&gt;&lt;/span&gt;&lt;/figure&gt;
&lt;/p&gt;
&lt;h2 data-ke-size=&quot;size26&quot;&gt;결핵 전염성 추정 기간 계산기&amp;nbsp;&lt;/h2&gt;
&lt;p data-ke-size=&quot;size16&quot;&gt;결핵은 전염성이 있는 질병이므로, 언제부터 언제까지 전염성이 있었는지 추정하는 것은 매우 중요합니다. 아래 정보를 입력하여 전염성 기간을 간편하게 확인해보세요!&lt;/p&gt;
&lt;figure id=&quot;og_1724512886544&quot; contenteditable=&quot;false&quot; data-ke-type=&quot;opengraph&quot; data-ke-align=&quot;alignCenter&quot; data-og-type=&quot;article&quot; data-og-title=&quot;결핵 역학조사 전염성 추정기간 계산기(ver1.3)&quot; data-og-description=&quot;결핵 역학조사 결핵 증상: 예 아니오 가래(객담) 도말 양성: 예 아니오 흉부 X선 공동: 예 아니오 약 복용 여부: 예 아니오 ..&quot; data-og-host=&quot;tb.manual-master.com&quot; data-og-source-url=&quot;https://tb.manual-master.com/pages/%EA%B2%B0%ED%95%B5-%EC%97%AD%ED%95%99%EC%A1%B0%EC%82%AC-%EC%A0%84%EC%97%BC%EC%84%B1-%EC%B6%94%EC%A0%95%EA%B8%B0%EA%B0%84-%EA%B3%84%EC%82%B0%EA%B8%B0ver13&quot; data-og-url=&quot;https://tb.manual-master.com/pages/%EA%B2%B0%ED%95%B5-%EC%97%AD%ED%95%99%EC%A1%B0%EC%82%AC-%EC%A0%84%EC%97%BC%EC%84%B1-%EC%B6%94%EC%A0%95%EA%B8%B0%EA%B0%84-%EA%B3%84%EC%82%B0%EA%B8%B0ver13&quot; data-og-image=&quot;https://scrap.kakaocdn.net/dn/6z5EV/hyWSem8UGV/zA49LBCHLdBnN1MPaKrSk1/img.png?width=500&amp;amp;height=500&amp;amp;face=150_122_241_213,https://scrap.kakaocdn.net/dn/eIDrE/hyWSlGBlcu/uKOheWQEY0ecB2CIAV6F51/img.png?width=500&amp;amp;height=500&amp;amp;face=150_122_241_213,https://scrap.kakaocdn.net/dn/cX48Nr/hyWSlT4Y0f/bXKsnnmjurYM3YcZJqo3ok/img.png?width=500&amp;amp;height=500&amp;amp;face=150_122_241_213&quot;&gt;&lt;a href=&quot;https://tb.manual-master.com/pages/%EA%B2%B0%ED%95%B5-%EC%97%AD%ED%95%99%EC%A1%B0%EC%82%AC-%EC%A0%84%EC%97%BC%EC%84%B1-%EC%B6%94%EC%A0%95%EA%B8%B0%EA%B0%84-%EA%B3%84%EC%82%B0%EA%B8%B0ver13&quot; target=&quot;_blank&quot; rel=&quot;noopener&quot; data-source-url=&quot;https://tb.manual-master.com/pages/%EA%B2%B0%ED%95%B5-%EC%97%AD%ED%95%99%EC%A1%B0%EC%82%AC-%EC%A0%84%EC%97%BC%EC%84%B1-%EC%B6%94%EC%A0%95%EA%B8%B0%EA%B0%84-%EA%B3%84%EC%82%B0%EA%B8%B0ver13&quot;&gt;
&lt;div class=&quot;og-image&quot; style=&quot;background-image: url('https://scrap.kakaocdn.net/dn/6z5EV/hyWSem8UGV/zA49LBCHLdBnN1MPaKrSk1/img.png?width=500&amp;amp;height=500&amp;amp;face=150_122_241_213,https://scrap.kakaocdn.net/dn/eIDrE/hyWSlGBlcu/uKOheWQEY0ecB2CIAV6F51/img.png?width=500&amp;amp;height=500&amp;amp;face=150_122_241_213,https://scrap.kakaocdn.net/dn/cX48Nr/hyWSlT4Y0f/bXKsnnmjurYM3YcZJqo3ok/img.png?width=500&amp;amp;height=500&amp;amp;face=150_122_241_213');&quot;&gt;&amp;nbsp;&lt;/div&gt;
&lt;div class=&quot;og-text&quot;&gt;
&lt;p class=&quot;og-title&quot; data-ke-size=&quot;size16&quot;&gt;결핵 역학조사 전염성 추정기간 계산기(ver1.3)&lt;/p&gt;
&lt;p class=&quot;og-desc&quot; data-ke-size=&quot;size16&quot;&gt;결핵 역학조사 결핵 증상: 예 아니오 가래(객담) 도말 양성: 예 아니오 흉부 X선 공동: 예 아니오 약 복용 여부: 예 아니오 ..&lt;/p&gt;
&lt;p class=&quot;og-host&quot; data-ke-size=&quot;size16&quot;&gt;tb.manual-master.com&lt;/p&gt;
&lt;/div&gt;
&lt;/a&gt;&lt;/figure&gt;
&lt;p&gt;&lt;figure class=&quot;imageblock alignCenter&quot; data-ke-mobileStyle=&quot;widthOrigin&quot; data-filename=&quot;스크린샷 2024-08-23 오후 10.12.36.png&quot; data-origin-width=&quot;980&quot; data-origin-height=&quot;428&quot;&gt;&lt;span data-url=&quot;https://blog.kakaocdn.net/dn/ZeCgM/btsJeoDacid/hWRZpt02t7SfPBjTrbVucK/img.png&quot; data-phocus=&quot;https://blog.kakaocdn.net/dn/ZeCgM/btsJeoDacid/hWRZpt02t7SfPBjTrbVucK/img.png&quot;&gt;&lt;img src=&quot;https://blog.kakaocdn.net/dn/ZeCgM/btsJeoDacid/hWRZpt02t7SfPBjTrbVucK/img.png&quot; srcset=&quot;https://img1.daumcdn.net/thumb/R1280x0/?scode=mtistory2&amp;fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdn%2FZeCgM%2FbtsJeoDacid%2FhWRZpt02t7SfPBjTrbVucK%2Fimg.png&quot; onerror=&quot;this.onerror=null; this.src='//t1.daumcdn.net/tistory_admin/static/images/no-image-v1.png'; this.srcset='//t1.daumcdn.net/tistory_admin/static/images/no-image-v1.png';&quot; alt=&quot;결핵 역학조사 전염성 추정기간 계산기 사용법&quot; loading=&quot;lazy&quot; width=&quot;980&quot; height=&quot;428&quot; data-filename=&quot;스크린샷 2024-08-23 오후 10.12.36.png&quot; data-origin-width=&quot;980&quot; data-origin-height=&quot;428&quot;/&gt;&lt;/span&gt;&lt;/figure&gt;
&lt;/p&gt;
&lt;h3 data-ke-size=&quot;size23&quot;&gt;  정보 입력&lt;/h3&gt;
&lt;ul style=&quot;list-style-type: disc;&quot; data-ke-list-type=&quot;disc&quot;&gt;
&lt;li&gt;&lt;b&gt;결핵 증상:&lt;/b&gt; 증상이 있었는지 여부를 선택하세요.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;가래(객담) 도말 양성:&lt;/b&gt; 가래 검사 결과가 양성인지 여부를 선택하세요.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;흉부 X선 공동:&lt;/b&gt; 흉부 X선 검사에서 공동 소견이 있는지 여부를 선택하세요.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;약 복용 여부:&lt;/b&gt; 결핵 약을 복용했는지 여부를 선택하세요.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;증상 시작일:&lt;/b&gt; 결핵 증상이 시작된 날짜를 입력하세요. (증상이 없었다면 입력하지 않아도 됩니다.)&lt;/li&gt;
&lt;li&gt;&lt;b&gt;가장 앞선 검사일:&lt;/b&gt; 결핵 관련 검사를 받은 가장 빠른 날짜를 입력하세요.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;약 복용 시작일:&lt;/b&gt; 결핵 약 복용을 시작한 날짜를 입력하세요. (약을 복용하지 않았다면 입력하지 않아도 됩니다.)&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 data-ke-size=&quot;size23&quot;&gt;  기간 계산&lt;/h3&gt;
&lt;p data-ke-size=&quot;size16&quot;&gt;모든 정보를 입력한 후, &quot;전염성 추정기간 계산&quot; 버튼을 클릭하세요. 전염성이 있었을 것으로 추정되는 기간이 화면에 표시됩니다.&lt;/p&gt;
&lt;h3 data-ke-size=&quot;size23&quot;&gt;❗ 주의사항&lt;/h3&gt;
&lt;ul style=&quot;list-style-type: disc;&quot; data-ke-list-type=&quot;disc&quot;&gt;
&lt;li&gt;이 계산기는 전염성 기간을 &lt;b&gt;추정&lt;/b&gt;하는 도구이며, 실제 전염성 기간과 다를 수 있습니다.&lt;/li&gt;
&lt;li&gt;개인 정보는 수집하거나 저장하지 않습니다. 안심하고 사용하세요.&lt;/li&gt;
&lt;/ul&gt;
&lt;p data-ke-size=&quot;size16&quot;&gt;&lt;b&gt;건강은 소중합니다. 결핵 예방과 조기 발견에 힘쓰세요!&lt;/b&gt;&lt;/p&gt;</description>
      <category>결핵</category>
      <category>결핵 역학조사 전염성 추정기간 계산기 사용법</category>
      <author>결핵마스터</author>
      <guid isPermaLink="true">https://tb-master.tistory.com/6</guid>
      <comments>https://tb-master.tistory.com/6#entry6comment</comments>
      <pubDate>Fri, 23 Aug 2024 22:13:27 +0900</pubDate>
    </item>
    <item>
      <title>결핵 역학조사 전염성 추정기간 계산기(ver1.3)</title>
      <link>https://tb-master.tistory.com/pages/%EA%B2%B0%ED%95%B5-%EC%97%AD%ED%95%99%EC%A1%B0%EC%82%AC-%EC%A0%84%EC%97%BC%EC%84%B1-%EC%B6%94%EC%A0%95%EA%B8%B0%EA%B0%84-%EA%B3%84%EC%82%B0%EA%B8%B0ver13</link>
      <description>&lt;p&gt;&lt;figure class=&quot;imageblock alignleft&quot; data-ke-mobileStyle=&quot;widthOrigin&quot; data-origin-width=&quot;500&quot; data-origin-height=&quot;500&quot;&gt;&lt;span data-url=&quot;https://blog.kakaocdn.net/dn/dp00PN/btsJd3fbugM/Z759hxIUGFq4nbRKRThMW0/img.png&quot; data-phocus=&quot;https://blog.kakaocdn.net/dn/dp00PN/btsJd3fbugM/Z759hxIUGFq4nbRKRThMW0/img.png&quot;&gt;&lt;img src=&quot;https://blog.kakaocdn.net/dn/dp00PN/btsJd3fbugM/Z759hxIUGFq4nbRKRThMW0/img.png&quot; srcset=&quot;https://img1.daumcdn.net/thumb/R1280x0/?scode=mtistory2&amp;fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdn%2Fdp00PN%2FbtsJd3fbugM%2FZ759hxIUGFq4nbRKRThMW0%2Fimg.png&quot; onerror=&quot;this.onerror=null; this.src='//t1.daumcdn.net/tistory_admin/static/images/no-image-v1.png'; this.srcset='//t1.daumcdn.net/tistory_admin/static/images/no-image-v1.png';&quot; loading=&quot;lazy&quot; width=&quot;500&quot; height=&quot;500&quot; data-origin-width=&quot;500&quot; data-origin-height=&quot;500&quot;/&gt;&lt;/span&gt;&lt;/figure&gt;
&lt;/p&gt;
  &lt;div&gt;
&lt;head&gt;
    &lt;meta charset=&quot;UTF-8&quot;&gt;
    &lt;meta name=&quot;viewport&quot; content=&quot;width=device-width, initial-scale=1.0&quot;&gt;
    &lt;title&gt;결핵 역학조사 - 전염성 추정기간 계산&lt;/title&gt;
    &lt;style&gt;
        body {
            margin: 0;
            padding: 0;
            display: flex;
            justify-content: center;
            align-items: center;
            min-height: 100vh;
        }
        .container {
            background-color: #ffffff;
            border-radius: 12px;
            box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
            padding: 20px;
            max-width: 500px;
            width: 90%;
            text-align: center;
        }
        h1 {
            font-size: 24px;
            color: #333;
            margin-bottom: 20px;
            font-weight: 700;
        }
        label {
            display: block;
            font-size: 16px;
            color: #495057;
            margin-top: 20px;
            margin-bottom: 8px;
            text-align: left;
            font-weight: 600;
        }
        input[type=&quot;radio&quot;] {
            margin-right: 10px;
        }
        input[type=&quot;date&quot;] {
            width: 80%;
            padding: 12px;
            font-size: 14px;
            border: 1px solid #ced4da;
            border-radius: 6px;
            margin-top: 5px;
            background-color: #f8f9fa;
            transition: border-color 0.3s, background-color 0.3s;
        }
        input[type=&quot;date&quot;]:focus {
            border-color: #80bdff;
            background-color: #ffffff;
            outline: none;
        }
        button {
            background-color: #007bff;
            color: white;
            font-size: 16px;
            padding: 12px;
            border: none;
            border-radius: 8px;
            cursor: pointer;
            margin-top: 20px;
            width: 100%;
            transition: background-color 0.3s, transform 0.3s;
        }
        button:hover {
            background-color: #0056b3;
            transform: translateY(-2px);
        }
        .result {
            margin-top: 25px;
            font-size: 18px;
            color: #212529;
            font-weight: 600;
            background-color: #e9ecef;
            padding: 15px;
            border-radius: 8px;
        }
        .radio-group {
            display: flex;
            justify-content: space-between;
            margin-top: 5px;
        }
        .radio-group label {
            font-weight: normal;
            color: #495057;
        }
        .form-section {
            margin-bottom: 20px;
        }

        /* 반응형 디자인: 작은 화면에서의 스타일 조정 */
        @media (max-width: 600px) {
            h1 {
                font-size: 20px;
            }
            label {
                font-size: 14px;
            }
            button {
                font-size: 14px;
                padding: 10px;
            }
            .result {
                font-size: 16px;
                padding: 12px;
            }
        }
    &lt;/style&gt;
&lt;/head&gt;
&lt;body&gt;

&lt;div class=&quot;container&quot;&gt;
    &lt;h1&gt;결핵 역학조사&lt;/h1&gt;
    &lt;form id=&quot;tbForm&quot;&gt;
        &lt;div class=&quot;form-section&quot;&gt;
            &lt;label&gt;결핵 증상:&lt;/label&gt;
            &lt;div class=&quot;radio-group&quot;&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;symptom&quot; value=&quot;yes&quot; onclick=&quot;toggleSymptomDate(true)&quot;&gt; 예&lt;/label&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;symptom&quot; value=&quot;no&quot; onclick=&quot;toggleSymptomDate(false)&quot;&gt; 아니오&lt;/label&gt;
            &lt;/div&gt;
        &lt;/div&gt;

        &lt;div class=&quot;form-section&quot;&gt;
            &lt;label&gt;가래(객담) 도말 양성:&lt;/label&gt;
            &lt;div class=&quot;radio-group&quot;&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;sputum&quot; value=&quot;yes&quot;&gt; 예&lt;/label&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;sputum&quot; value=&quot;no&quot;&gt; 아니오&lt;/label&gt;
            &lt;/div&gt;
        &lt;/div&gt;

        &lt;div class=&quot;form-section&quot;&gt;
            &lt;label&gt;흉부 X선 공동:&lt;/label&gt;
            &lt;div class=&quot;radio-group&quot;&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;xray&quot; value=&quot;yes&quot;&gt; 예&lt;/label&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;xray&quot; value=&quot;no&quot;&gt; 아니오&lt;/label&gt;
            &lt;/div&gt;
        &lt;/div&gt;

        &lt;div class=&quot;form-section&quot;&gt;
            &lt;label&gt;약 복용 여부:&lt;/label&gt;
            &lt;div class=&quot;radio-group&quot;&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;medication&quot; value=&quot;yes&quot; onclick=&quot;toggleMedicationDate(true)&quot;&gt; 예&lt;/label&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;medication&quot; value=&quot;no&quot; onclick=&quot;toggleMedicationDate(false)&quot;&gt; 아니오&lt;/label&gt;
            &lt;/div&gt;
        &lt;/div&gt;

        &lt;div class=&quot;form-section&quot;&gt;
            &lt;label&gt;증상 시작일:&lt;/label&gt;
            &lt;input type=&quot;date&quot; id=&quot;symptomDate&quot; pattern=&quot;\d{4}-\d{2}-\d{2}&quot; placeholder=&quot;YYYY-MM-DD&quot; max=&quot;9999-12-31&quot; disabled&gt;
        &lt;/div&gt;

        &lt;div class=&quot;form-section&quot;&gt;
            &lt;label&gt;가장 앞선 검사일:&lt;/label&gt;
            &lt;input type=&quot;date&quot; id=&quot;testDate&quot; pattern=&quot;\d{4}-\d{2}-\d{2}&quot; placeholder=&quot;YYYY-MM-DD&quot; max=&quot;9999-12-31&quot;&gt;
        &lt;/div&gt;

        &lt;div class=&quot;form-section&quot;&gt;
            &lt;label&gt;약 복용 시작일:&lt;/label&gt;
            &lt;input type=&quot;date&quot; id=&quot;medicationDate&quot; pattern=&quot;\d{4}-\d{2}-\d{2}&quot; placeholder=&quot;YYYY-MM-DD&quot; max=&quot;9999-12-31&quot; disabled&gt;
        &lt;/div&gt;

        &lt;button type=&quot;button&quot; onclick=&quot;calculatePeriod()&quot;&gt;전염성 추정기간 계산&lt;/button&gt;
    &lt;/form&gt;

    &lt;div class=&quot;result&quot; id=&quot;result&quot;&gt;&lt;/div&gt;
&lt;/div&gt;

&lt;script&gt;
    function toggleSymptomDate(enable) {
        const symptomDateInput = document.getElementById(&quot;symptomDate&quot;);
        symptomDateInput.disabled = !enable;
        if (!enable) {
            symptomDateInput.value = &quot;&quot;; // 초기화
        }
    }

    function toggleMedicationDate(enable) {
        const medicationDateInput = document.getElementById(&quot;medicationDate&quot;);
        medicationDateInput.disabled = !enable;
        if (!enable) {
            medicationDateInput.value = &quot;&quot;; // 초기화
        }
    }

function calculatePeriod() {
    const symptom = document.querySelector('input[name=&quot;symptom&quot;]:checked').value;
    const sputum = document.querySelector('input[name=&quot;sputum&quot;]:checked').value;
    const xray = document.querySelector('input[name=&quot;xray&quot;]:checked').value;
    const medication = document.querySelector('input[name=&quot;medication&quot;]:checked').value;
    const symptomDate = new Date(document.getElementById(&quot;symptomDate&quot;).value);
    const testDate = new Date(document.getElementById(&quot;testDate&quot;).value);
    const medicationDate = new Date(document.getElementById(&quot;medicationDate&quot;).value);
    let resultText = &quot;&quot;;

    if (isNaN(testDate)) {
        alert(&quot;검사일을 선택해 주세요.&quot;);
        return;
    }

    let startDate, endDate;

    // 결핵 증상이 있는 경우
    if (symptom === &quot;yes&quot;) {
        if (isNaN(symptomDate)) {
            alert(&quot;증상 시작일을 입력해 주세요.&quot;);
            return;
        }
        // 증상 시작일과 검사일 중 더 이른 날짜로부터 3개월 전 계산
        let earlyDate = symptomDate &lt; testDate ? symptomDate : testDate;
        startDate = new Date(earlyDate);
        startDate.setMonth(startDate.getMonth() - 3);
        endDate = new Date(testDate);
    } 
    // 결핵 증상은 없으나 가래 도말 양성 또는 흉부 X선 공동이 있는 경우
    else if (sputum === &quot;yes&quot; || xray === &quot;yes&quot;) {
        startDate = new Date(testDate);
        startDate.setMonth(startDate.getMonth() - 3);
        endDate = new Date(testDate);
    } 
    // 결핵 증상, 가래 도말 양성, 흉부 X선 공동 모두 없는 경우
    else {
        startDate = new Date(testDate);
        startDate.setDate(startDate.getDate() - 28);
        endDate = new Date(testDate);
    }

    // 약 복용 여부가 &quot;예&quot;인 경우, 종료 날짜를 약 복용 시작일 + 2주로 설정
    if (medication === &quot;yes&quot; &amp;&amp; !isNaN(medicationDate)) {
        endDate = new Date(medicationDate);
        endDate.setDate(endDate.getDate() + 14); // 약 복용 시작일로부터 2주
    }

    resultText = `전염성 추정기간: ${startDate.toLocaleDateString()} ~ ${endDate.toLocaleDateString()} (${Math.ceil((endDate - startDate) / (1000 * 60 * 60 * 24 * 7))}주간)`;

    document.getElementById(&quot;result&quot;).innerText = resultText;
}
&lt;/script&gt;
&lt;/body&gt;
  &lt;/div&gt;</description>
      <author>결핵마스터</author>
      <guid isPermaLink="true">https://tb-master.tistory.com/pages/%EA%B2%B0%ED%95%B5-%EC%97%AD%ED%95%99%EC%A1%B0%EC%82%AC-%EC%A0%84%EC%97%BC%EC%84%B1-%EC%B6%94%EC%A0%95%EA%B8%B0%EA%B0%84-%EA%B3%84%EC%82%B0%EA%B8%B0ver13</guid>
      <pubDate>Fri, 23 Aug 2024 21:41:26 +0900</pubDate>
    </item>
    <item>
      <title>결핵 역학조사 전염성 추정기간 계산기(ver1.2)</title>
      <link>https://tb-master.tistory.com/pages/%EA%B2%B0%ED%95%B5-%EC%97%AD%ED%95%99%EC%A1%B0%EC%82%AC-%EC%A0%84%EC%97%BC%EC%84%B1-%EC%B6%94%EC%A0%95%EA%B8%B0%EA%B0%84-%EA%B3%84%EC%82%B0%EA%B8%B0ver12</link>
      <description>&lt;p data-ke-size=&quot;size16&quot;&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;figure class=&quot;imageblock alignleft&quot; data-ke-mobileStyle=&quot;widthOrigin&quot; data-origin-width=&quot;500&quot; data-origin-height=&quot;500&quot;&gt;&lt;span data-url=&quot;https://blog.kakaocdn.net/dn/sycze/btsJrAQWtvs/3pmqf80URMk9wetB58pvbK/img.png&quot; data-phocus=&quot;https://blog.kakaocdn.net/dn/sycze/btsJrAQWtvs/3pmqf80URMk9wetB58pvbK/img.png&quot;&gt;&lt;img src=&quot;https://blog.kakaocdn.net/dn/sycze/btsJrAQWtvs/3pmqf80URMk9wetB58pvbK/img.png&quot; srcset=&quot;https://img1.daumcdn.net/thumb/R1280x0/?scode=mtistory2&amp;fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdn%2Fsycze%2FbtsJrAQWtvs%2F3pmqf80URMk9wetB58pvbK%2Fimg.png&quot; onerror=&quot;this.onerror=null; this.src='//t1.daumcdn.net/tistory_admin/static/images/no-image-v1.png'; this.srcset='//t1.daumcdn.net/tistory_admin/static/images/no-image-v1.png';&quot; loading=&quot;lazy&quot; width=&quot;500&quot; height=&quot;500&quot; data-origin-width=&quot;500&quot; data-origin-height=&quot;500&quot;/&gt;&lt;/span&gt;&lt;/figure&gt;
&lt;/p&gt;
  &lt;div&gt;
&lt;head&gt;
    &lt;meta charset=&quot;UTF-8&quot;&gt;
    &lt;meta name=&quot;viewport&quot; content=&quot;width=device-width, initial-scale=1.0&quot;&gt;
    &lt;title&gt;결핵 역학조사 - 전염성 추정기간 계산&lt;/title&gt;
    &lt;style&gt;
        body {
            margin: 0;
            padding: 0;
            display: flex;
            justify-content: center;
            align-items: center;
            min-height: 100vh;
        }
        .container {
            background-color: #ffffff;
            border-radius: 12px;
            box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
            padding: 20px;
            max-width: 500px;
            width: 90%;
            text-align: center;
        }
        h1 {
            font-size: 24px;
            color: #333;
            margin-bottom: 20px;
            font-weight: 700;
        }
        label {
            display: block;
            font-size: 16px;
            color: #495057;
            margin-top: 20px;
            margin-bottom: 8px;
            text-align: left;
            font-weight: 600;
        }
        input[type=&quot;radio&quot;] {
            margin-right: 10px;
        }
        input[type=&quot;date&quot;] {
            width: 80%;
            padding: 12px;
            font-size: 14px;
            border: 1px solid #ced4da;
            border-radius: 6px;
            margin-top: 5px;
            background-color: #f8f9fa;
            transition: border-color 0.3s, background-color 0.3s;
        }
        input[type=&quot;date&quot;]:focus {
            border-color: #80bdff;
            background-color: #ffffff;
            outline: none;
        }
        button {
            background-color: #007bff;
            color: white;
            font-size: 16px;
            padding: 12px;
            border: none;
            border-radius: 8px;
            cursor: pointer;
            margin-top: 20px;
            width: 100%;
            transition: background-color 0.3s, transform 0.3s;
        }
        button:hover {
            background-color: #0056b3;
            transform: translateY(-2px);
        }
        .result {
            margin-top: 25px;
            font-size: 18px;
            color: #212529;
            font-weight: 600;
            background-color: #e9ecef;
            padding: 15px;
            border-radius: 8px;
        }
        .radio-group {
            display: flex;
            justify-content: space-between;
            margin-top: 5px;
        }
        .radio-group label {
            font-weight: normal;
            color: #495057;
        }
        .form-section {
            margin-bottom: 20px;
        }

        /* 반응형 디자인: 작은 화면에서의 스타일 조정 */
        @media (max-width: 600px) {
            h1 {
                font-size: 20px;
            }
            label {
                font-size: 14px;
            }
            button {
                font-size: 14px;
                padding: 10px;
            }
            .result {
                font-size: 16px;
                padding: 12px;
            }
        }
    &lt;/style&gt;
&lt;/head&gt;
&lt;body&gt;

&lt;div class=&quot;container&quot;&gt;
    &lt;h1&gt;결핵 역학조사&lt;/h1&gt;
    &lt;form id=&quot;tbForm&quot;&gt;
        &lt;div class=&quot;form-section&quot;&gt;
            &lt;label&gt;결핵 증상:&lt;/label&gt;
            &lt;div class=&quot;radio-group&quot;&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;symptom&quot; value=&quot;yes&quot; onclick=&quot;toggleSymptomDate(true)&quot;&gt; 예&lt;/label&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;symptom&quot; value=&quot;no&quot; onclick=&quot;toggleSymptomDate(false)&quot;&gt; 아니오&lt;/label&gt;
            &lt;/div&gt;
        &lt;/div&gt;

        &lt;div class=&quot;form-section&quot;&gt;
            &lt;label&gt;가래(객담) 도말 양성:&lt;/label&gt;
            &lt;div class=&quot;radio-group&quot;&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;sputum&quot; value=&quot;yes&quot;&gt; 예&lt;/label&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;sputum&quot; value=&quot;no&quot;&gt; 아니오&lt;/label&gt;
            &lt;/div&gt;
        &lt;/div&gt;

        &lt;div class=&quot;form-section&quot;&gt;
            &lt;label&gt;흉부 X선 공동:&lt;/label&gt;
            &lt;div class=&quot;radio-group&quot;&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;xray&quot; value=&quot;yes&quot;&gt; 예&lt;/label&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;xray&quot; value=&quot;no&quot;&gt; 아니오&lt;/label&gt;
            &lt;/div&gt;
        &lt;/div&gt;

        &lt;div class=&quot;form-section&quot;&gt;
            &lt;label&gt;약 복용 여부:&lt;/label&gt;
            &lt;div class=&quot;radio-group&quot;&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;medication&quot; value=&quot;yes&quot; onclick=&quot;toggleMedicationDate(true)&quot;&gt; 예&lt;/label&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;medication&quot; value=&quot;no&quot; onclick=&quot;toggleMedicationDate(false)&quot;&gt; 아니오&lt;/label&gt;
            &lt;/div&gt;
        &lt;/div&gt;

        &lt;div class=&quot;form-section&quot;&gt;
            &lt;label&gt;증상 시작일:&lt;/label&gt;
            &lt;input type=&quot;date&quot; id=&quot;symptomDate&quot; pattern=&quot;\d{4}-\d{2}-\d{2}&quot; placeholder=&quot;YYYY-MM-DD&quot; max=&quot;9999-12-31&quot; disabled&gt;
        &lt;/div&gt;

        &lt;div class=&quot;form-section&quot;&gt;
            &lt;label&gt;가장 앞선 검사일:&lt;/label&gt;
            &lt;input type=&quot;date&quot; id=&quot;testDate&quot; pattern=&quot;\d{4}-\d{2}-\d{2}&quot; placeholder=&quot;YYYY-MM-DD&quot; max=&quot;9999-12-31&quot;&gt;
        &lt;/div&gt;

        &lt;div class=&quot;form-section&quot;&gt;
            &lt;label&gt;약 복용 시작일:&lt;/label&gt;
            &lt;input type=&quot;date&quot; id=&quot;medicationDate&quot; pattern=&quot;\d{4}-\d{2}-\d{2}&quot; placeholder=&quot;YYYY-MM-DD&quot; max=&quot;9999-12-31&quot; disabled&gt;
        &lt;/div&gt;

        &lt;button type=&quot;button&quot; onclick=&quot;calculatePeriod()&quot;&gt;전염성 추정기간 계산&lt;/button&gt;
    &lt;/form&gt;

    &lt;div class=&quot;result&quot; id=&quot;result&quot;&gt;&lt;/div&gt;
&lt;/div&gt;

&lt;script&gt;
    function toggleSymptomDate(enable) {
        const symptomDateInput = document.getElementById(&quot;symptomDate&quot;);
        symptomDateInput.disabled = !enable;
        if (!enable) {
            symptomDateInput.value = &quot;&quot;; // 초기화
        }
    }

    function toggleMedicationDate(enable) {
        const medicationDateInput = document.getElementById(&quot;medicationDate&quot;);
        medicationDateInput.disabled = !enable;
        if (!enable) {
            medicationDateInput.value = &quot;&quot;; // 초기화
        }
    }

function calculatePeriod() {
    const symptom = document.querySelector('input[name=&quot;symptom&quot;]:checked').value;
    const sputum = document.querySelector('input[name=&quot;sputum&quot;]:checked').value;
    const xray = document.querySelector('input[name=&quot;xray&quot;]:checked').value;
    const medication = document.querySelector('input[name=&quot;medication&quot;]:checked').value;
    const symptomDate = new Date(document.getElementById(&quot;symptomDate&quot;).value);
    const testDate = new Date(document.getElementById(&quot;testDate&quot;).value);
    const medicationDate = new Date(document.getElementById(&quot;medicationDate&quot;).value);
    let resultText = &quot;&quot;;

    if (isNaN(testDate)) {
        alert(&quot;검사일을 선택해 주세요.&quot;);
        return;
    }

    let startDate, endDate;

    // 결핵 증상이 있는 경우
    if (symptom === &quot;yes&quot;) {
        if (isNaN(symptomDate)) {
            alert(&quot;증상 시작일을 입력해 주세요.&quot;);
            return;
        }
        // 증상 시작일과 검사일 중 더 이른 날짜로부터 3개월 전 계산
        let earlyDate = symptomDate &lt; testDate ? symptomDate : testDate;
        startDate = new Date(earlyDate);
        startDate.setMonth(startDate.getMonth() - 3);
        endDate = new Date(testDate);
    } 
    // 결핵 증상은 없으나 가래 도말 양성 또는 흉부 X선 공동이 있는 경우
    else if (sputum === &quot;yes&quot; || xray === &quot;yes&quot;) {
        startDate = new Date(testDate);
        startDate.setMonth(startDate.getMonth() - 3);
        endDate = new Date(testDate);
    } 
    // 결핵 증상, 가래 도말 양성, 흉부 X선 공동 모두 없는 경우
    else {
        startDate = new Date(testDate);
        startDate.setDate(startDate.getDate() - 28);
        endDate = new Date(testDate);
    }

    // 약 복용 여부가 &quot;예&quot;인 경우, 종료 날짜를 약 복용 시작일 + 2주로 설정
    if (medication === &quot;yes&quot; &amp;&amp; !isNaN(medicationDate)) {
        endDate = new Date(medicationDate);
        endDate.setDate(endDate.getDate() + 14); // 약 복용 시작일로부터 2주
    }

    resultText = `전염성 추정기간: ${startDate.toLocaleDateString()} ~ ${endDate.toLocaleDateString()} (${Math.ceil((endDate - startDate) / (1000 * 60 * 60 * 24 * 7))}주간)`;

    document.getElementById(&quot;result&quot;).innerText = resultText;
}
&lt;/script&gt;
&lt;/body&gt;
  &lt;/div&gt;</description>
      <author>결핵마스터</author>
      <guid isPermaLink="true">https://tb-master.tistory.com/pages/%EA%B2%B0%ED%95%B5-%EC%97%AD%ED%95%99%EC%A1%B0%EC%82%AC-%EC%A0%84%EC%97%BC%EC%84%B1-%EC%B6%94%EC%A0%95%EA%B8%B0%EA%B0%84-%EA%B3%84%EC%82%B0%EA%B8%B0ver12</guid>
      <pubDate>Fri, 23 Aug 2024 19:15:48 +0900</pubDate>
    </item>
    <item>
      <title>결핵 역학조사 전염성 추정기간 계산기</title>
      <link>https://tb-master.tistory.com/pages/%EA%B2%B0%ED%95%B5-%EC%97%AD%ED%95%99%EC%A1%B0%EC%82%AC-%EC%A0%84%EC%97%BC%EC%84%B1-%EC%B6%94%EC%A0%95%EA%B8%B0%EA%B0%84-%EA%B3%84%EC%82%B0%EA%B8%B0</link>
      <description>&lt;!DOCTYPE html&gt;
&lt;html lang=&quot;ko&quot;&gt;
&lt;head&gt;
    &lt;meta charset=&quot;UTF-8&quot;&gt;
    &lt;meta name=&quot;viewport&quot; content=&quot;width=device-width, initial-scale=1.0&quot;&gt;
    &lt;title&gt;결핵 역학조사 - 전염성 추정기간 계산&lt;/title&gt;
    &lt;style&gt;
        body {
            font-family: 'Helvetica Neue', Arial, sans-serif;
            background-color: #f4f7f6;
            margin: 0;
            padding: 0;
            display: flex;
            justify-content: center;
            align-items: center;
            min-height: 100vh;
        }
        .container {
            background-color: #ffffff;
            border-radius: 12px;
            box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
            padding: 20px;
            max-width: 500px;
            width: 90%;
            text-align: center;
        }
        h1 {
            font-size: 24px;
            color: #333;
            margin-bottom: 20px;
            font-weight: 700;
        }
        label {
            display: block;
            font-size: 16px;
            color: #495057;
            margin-top: 20px;
            margin-bottom: 8px;
            text-align: left;
            font-weight: 600;
        }
        input[type=&quot;radio&quot;] {
            margin-right: 10px;
        }
        input[type=&quot;date&quot;] {
            width: 100%;
            padding: 12px;
            font-size: 14px;
            border: 1px solid #ced4da;
            border-radius: 6px;
            margin-top: 5px;
            background-color: #f8f9fa;
            transition: border-color 0.3s, background-color 0.3s;
        }
        input[type=&quot;date&quot;]:focus {
            border-color: #80bdff;
            background-color: #ffffff;
            outline: none;
        }
        button {
            background-color: #007bff;
            color: white;
            font-size: 16px;
            padding: 12px;
            border: none;
            border-radius: 8px;
            cursor: pointer;
            margin-top: 20px;
            width: 100%;
            transition: background-color 0.3s, transform 0.3s;
        }
        button:hover {
            background-color: #0056b3;
            transform: translateY(-2px);
        }
        .result {
            margin-top: 25px;
            font-size: 18px;
            color: #212529;
            font-weight: 600;
            background-color: #e9ecef;
            padding: 15px;
            border-radius: 8px;
        }
        .radio-group {
            display: flex;
            justify-content: space-between;
            margin-top: 5px;
        }
        .radio-group label {
            font-weight: normal;
            color: #495057;
        }
        .form-section {
            margin-bottom: 20px;
        }

        /* 반응형 디자인: 작은 화면에서의 스타일 조정 */
        @media (max-width: 600px) {
            h1 {
                font-size: 20px;
            }
            label {
                font-size: 14px;
            }
            button {
                font-size: 14px;
                padding: 10px;
            }
            .result {
                font-size: 16px;
                padding: 12px;
            }
        }
    &lt;/style&gt;
&lt;/head&gt;
&lt;body&gt;

&lt;div class=&quot;container&quot;&gt;
    &lt;h1&gt;결핵 역학조사&lt;/h1&gt;
    &lt;form id=&quot;tbForm&quot;&gt;
        &lt;div class=&quot;form-section&quot;&gt;
            &lt;label&gt;결핵 증상:&lt;/label&gt;
            &lt;div class=&quot;radio-group&quot;&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;symptom&quot; value=&quot;yes&quot; onclick=&quot;toggleSymptomDate(true)&quot;&gt; 예&lt;/label&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;symptom&quot; value=&quot;no&quot; onclick=&quot;toggleSymptomDate(false)&quot;&gt; 아니오&lt;/label&gt;
            &lt;/div&gt;
        &lt;/div&gt;

        &lt;div class=&quot;form-section&quot;&gt;
            &lt;label&gt;가래(객담) 도말 양성:&lt;/label&gt;
            &lt;div class=&quot;radio-group&quot;&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;sputum&quot; value=&quot;yes&quot;&gt; 예&lt;/label&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;sputum&quot; value=&quot;no&quot;&gt; 아니오&lt;/label&gt;
            &lt;/div&gt;
        &lt;/div&gt;

        &lt;div class=&quot;form-section&quot;&gt;
            &lt;label&gt;흉부 X선 공동:&lt;/label&gt;
            &lt;div class=&quot;radio-group&quot;&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;xray&quot; value=&quot;yes&quot;&gt; 예&lt;/label&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;xray&quot; value=&quot;no&quot;&gt; 아니오&lt;/label&gt;
            &lt;/div&gt;
        &lt;/div&gt;

        &lt;div class=&quot;form-section&quot;&gt;
            &lt;label&gt;약 복용 여부:&lt;/label&gt;
            &lt;div class=&quot;radio-group&quot;&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;medication&quot; value=&quot;yes&quot; onclick=&quot;toggleMedicationDate(true)&quot;&gt; 예&lt;/label&gt;
                &lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;medication&quot; value=&quot;no&quot; onclick=&quot;toggleMedicationDate(false)&quot;&gt; 아니오&lt;/label&gt;
            &lt;/div&gt;
        &lt;/div&gt;

        &lt;div class=&quot;form-section&quot;&gt;
            &lt;label&gt;증상 시작일:&lt;/label&gt;
            &lt;input type=&quot;date&quot; id=&quot;symptomDate&quot; pattern=&quot;\d{4}-\d{2}-\d{2}&quot; placeholder=&quot;YYYY-MM-DD&quot; max=&quot;9999-12-31&quot; disabled&gt;
        &lt;/div&gt;

        &lt;div class=&quot;form-section&quot;&gt;
            &lt;label&gt;가장 앞선 검사일:&lt;/label&gt;
            &lt;input type=&quot;date&quot; id=&quot;testDate&quot; pattern=&quot;\d{4}-\d{2}-\d{2}&quot; placeholder=&quot;YYYY-MM-DD&quot; max=&quot;9999-12-31&quot;&gt;
        &lt;/div&gt;

        &lt;div class=&quot;form-section&quot;&gt;
            &lt;label&gt;약 복용 시작일:&lt;/label&gt;
            &lt;input type=&quot;date&quot; id=&quot;medicationDate&quot; pattern=&quot;\d{4}-\d{2}-\d{2}&quot; placeholder=&quot;YYYY-MM-DD&quot; max=&quot;9999-12-31&quot; disabled&gt;
        &lt;/div&gt;

        &lt;button type=&quot;button&quot; onclick=&quot;calculatePeriod()&quot;&gt;전염성 추정기간 계산&lt;/button&gt;
    &lt;/form&gt;

    &lt;div class=&quot;result&quot; id=&quot;result&quot;&gt;&lt;/div&gt;
&lt;/div&gt;

&lt;script&gt;
    function toggleSymptomDate(enable) {
        document.getElementById(&quot;symptomDate&quot;).disabled = !enable;
    }

    function toggleMedicationDate(enable) {
        document.getElementById(&quot;medicationDate&quot;).disabled = !enable;
    }

    function calculatePeriod() {
        const symptom = document.querySelector('input[name=&quot;symptom&quot;]:checked').value;
        const sputum = document.querySelector('input[name=&quot;sputum&quot;]:checked').value;
        const xray = document.querySelector('input[name=&quot;xray&quot;]:checked').value;
        const medication = document.querySelector('input[name=&quot;medication&quot;]:checked').value;
        const symptomDate = new Date(document.getElementById(&quot;symptomDate&quot;).value);
        const testDate = new Date(document.getElementById(&quot;testDate&quot;).value);
        const medicationDate = new Date(document.getElementById(&quot;medicationDate&quot;).value);
        let resultText = &quot;&quot;;

        if (isNaN(testDate)) {
            alert(&quot;검사일을 선택해 주세요.&quot;);
            return;
        }

        let startDate, endDate;

        // 결핵 증상이 있는 경우
        if (symptom === &quot;yes&quot;) {
            if (isNaN(symptomDate)) {
                alert(&quot;증상 시작일을 입력해 주세요.&quot;);
                return;
            }
            startDate = new Date(symptomDate);
            startDate.setMonth(startDate.getMonth() - 3);
            endDate = new Date(testDate);
        } 
        // 결핵 증상은 없으나 가래 도말 양성 또는 흉부 X선 공동이 있는 경우
        else if (sputum === &quot;yes&quot; || xray === &quot;yes&quot;) {
            startDate = new Date(testDate);
            startDate.setMonth(startDate.getMonth() - 3);
            endDate = new Date(testDate);
        } 
        // 결핵 증상, 가래 도말 양성, 흉부 X선 공동 모두 없는 경우
        else {
            startDate = new Date(testDate);
            startDate.setDate(startDate.getDate() - 28);
            endDate = new Date(testDate);
        }

        // 약 복용 여부가 &quot;예&quot;인 경우, 종료 날짜를 약 복용 시작일 + 2주로 설정
        if (medication === &quot;yes&quot; &amp;&amp; !isNaN(medicationDate)) {
            endDate = new Date(medicationDate);
            endDate.setDate(endDate.getDate() + 14); // 약 복용 시작일로부터 2주
        }

        resultText = `전염성 추정기간: ${startDate.toLocaleDateString()} ~ ${endDate.toLocaleDateString()} (${Math.ceil((endDate - startDate) / (1000 * 60 * 60 * 24 * 7))}주간)`;

        document.getElementById(&quot;result&quot;).innerText = resultText;
    }
&lt;/script&gt;

&lt;/body&gt;
&lt;/html&gt;</description>
      <author>결핵마스터</author>
      <guid isPermaLink="true">https://tb-master.tistory.com/pages/%EA%B2%B0%ED%95%B5-%EC%97%AD%ED%95%99%EC%A1%B0%EC%82%AC-%EC%A0%84%EC%97%BC%EC%84%B1-%EC%B6%94%EC%A0%95%EA%B8%B0%EA%B0%84-%EA%B3%84%EC%82%B0%EA%B8%B0</guid>
      <pubDate>Fri, 23 Aug 2024 19:07:39 +0900</pubDate>
    </item>
  </channel>
</rss>