<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:th="http://www.thymeleaf.org"
      xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout"
      layout:decorate="~{/web/layout/homeLayout}">
<th:block layout:fragment="layout_css">
    <link href="https://cdn.jsdelivr.net/npm/summernote@0.8.18/dist/summernote.min.css" rel="stylesheet">
    <link rel="stylesheet" href="/css/web/webPhotoDietInsert.css">
    <link rel="stylesheet" href="/css/web/grid.css?v1.1">
</th:block>
<th:block layout:fragment="layout_top_script">
    <script src="/js/web/jquery.twbsPagination.js" type="text/javascript"></script>
    <script>
        let menuClass     = "[[${param.menuClass}]]"==""?"":"[[${param.menuClass}]]";

        let selectUseYn   = "[[${selectUseYn}]]"==""?"N":"[[${selectUseYn}]]";
        let insertUseYn   = "[[${insertUseYn}]]"==""?"N":"[[${insertUseYn}]]";
        let updateUseYn   = "[[${updateUseYn}]]"==""?"N":"[[${updateUseYn}]]";
        let deleteUseYn   = "[[${deleteUseYn}]]"==""?"N":"[[${deleteUseYn}]]";
        let downloadUseYn = "[[${downloadUseYn}]]"==""?"N":"[[${downloadUseYn}]]";
        
        let muWebPhotoDietId  = "[[${param.muWebPhotoDietId }]]";
        let categorylist = "[[${param.categorylist}]]";
        let categoryno = "[[${param.categoryno}]]";
        let originalCategoryNo = "[[${param.categoryno}]]";
        
        const CDN_URL = "[[${@environment.getProperty('url.cdn')}]]";
    </script>
</th:block>
<th:block layout:fragment="layout_content">
    <!-- 센터쪽 -->
    <div class="center_box">
        <p class="page_title">전후 사진(다이어트)</p>

        <!-- 테이블 -->
        <div class="content_box">
            <div class="content clear">
				<div class="wp60">
					<div class="top">
                        <label>Before 사진 첨부파일</label>
                        <label for="before_file" class="file_btn"><img src="/image/web/add.svg" alt="파일찾기"></label>
                    </div>
                    <div class="btm">
                        <div class="img_box" id="before_img_box"><!-- Before img 미리보기 --></div>
                        <input type="file" id="before_file" accept="image/jpeg, image/jpg, image/png" style="display: none;" multiple>
                        <button id="before_delete_btn">삭제</button>
                    </div>
                    <div class="top">
                        <label>After 사진 첨부파일</label>
                        <label for="after_file" class="file_btn"><img src="/image/web/add.svg" alt="파일찾기"></label>
                    </div>
                    <div class="btm">
                        <div class="img_box" id="after_img_box"><!-- After img 미리보기 --></div>
                        <input type="file" id="after_file" accept="image/jpeg, image/jpg, image/png" style="display: none;" multiple>
                        <button id="after_delete_btn">삭제</button>
                    </div>
				</div>
				<div class="wp40">
					<div class="consultation-info">
						<p id="main_category">
							카테고리
						</p>
						<select th:name="categorylist">
							<option value="">선택하세요</option>
  							<option th:each="category : ${categorylist}" th:value="${category.categoryNo}" th:text="${category.categoryNm}" ></option>
						</select>
						<p id="main_title">
							제목
						</p>
						<input type="text" id="title" placeholder="제목을 입력해주세요."/>
						<p id="main_content">
							내용
						</p>						
						<textarea id="content" placeholder="내용을 입력해주세요."></textarea>		                
						<p id="main_hashtag">
							해쉬태그
						</p>
						<input type="text" id="hashtag" placeholder="해쉬태그를 입력해주세요."/>
					</div>
				</div>
					
			</div>
			<div class="button_box">
            	<button class="cancel_btn btnCancle">취소</button>
            	<button class="registration_btn btnSave">수정</button>
            </div>
        </div>
    </div>
    <form id="excelForm" method="POST" target="_blank"></form>
</th:block>
<th:block layout:fragment="layout_popup">
</th:block>
<th:block layout:fragment="layout_script">
    <script src="/js/web/ag-grid-community-29.3.5.min.js"></script>
    <script src="/js/web/webphotodiet/webPhotoDietUpdate.js"></script>
    <script src="https://cdn.jsdelivr.net/npm/summernote@0.8.18/dist/summernote.min.js"></script>
</th:block>
</html>