<%@ page import="com.lightinit.hsdataplatform.dictionary.DicResourceCatelogType" %>
<%@ page language="java" pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%>
<%@ page isELIgnored="false" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>

<%@taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%
    String basePath = request.getContextPath();
%>
<jsp:include page="../../../common/admin/modal_content_pre.jsp"><jsp:param name="modal_title" value="审核"/></jsp:include>
<form id="formEdit" action="<%=basePath%>/admin/microapp_publish/doAduit.action" method="post" class="form-horizontal">
    <div>
        <ul class="nav nav-tabs" role="tablist">
            <li role="presentation" class="active"><a href="#baseInfo" aria-controls="baseInfo" role="tab" data-toggle="tab">基本信息</a></li>
            <li role="presentation"><a href="#publish" aria-controls="publish" role="tab" data-toggle="tab">发布渠道</a></li>
        </ul>
        <div class="tab-content">
            <div role="tabpanel" class="tab-pane active" id="baseInfo">
                    <div class="form-group">
                        <label class="col-md-3 col-sm-3 control-label" >微应用名称：</label>

                        <div class="col-md-7 col-sm-7">
                            <p class="form-control-static">${resource.resourceName}</p>
                        </div>
                        <span class="field-validation-valid help-block"></span>
                    </div>
                    <div class="form-group">
                        <label class="col-md-3 col-sm-3 control-label" >微应用标示：</label>
                        <div class="col-md-7 col-sm-7">
                            <p class="form-control-static">${resource.resourceIdentity}</p>
                        </div>
                        <span class="field-validation-valid help-block"></span>
                    </div>
                    <div class="form-group">
                        <label  class="col-md-3 col-sm-3 control-label">微应用简介：</label>
                        <div class="col-md-7 col-sm-7">
                            <p class="form-control-static">${resource.resourceSummary}</p>
                        </div>
                        <span class="field-validation-valid help-block"></span>
                    </div>
                    <div class="form-group">
                        <label class="col-md-3 col-sm-3 control-label" >注册日期：</label>
                        <div class="col-md-7 col-sm-7">

                            <p class="form-control-static"><fmt:formatDate value="${resource.registerDate}" pattern="yyyy-MM-dd"/></p>
                        </div>
                        <span class="field-validation-valid help-block"></span>
                    </div>

                    <div class="form-group">
                        <label  class="col-md-3 col-sm-3 control-label">提供单位：</label>
                        <div  >
                            <p class="form-control-static"> ${dic.provider}</p>
                        </div>
                        <span class="field-validation-valid help-block"></span>
                    </div>
                    <div class="form-group">
                        <label  class="col-md-3 col-sm-3 control-label">服务方式：</label>
                        <div class="col-md-7 col-sm-7">
                            <p class="form-control-static">${microapp.serviceMethod}</p>
                        </div>
                        <span class="field-validation-valid help-block"></span>
                    </div>
                    <div class="form-group">
                        <label  class="col-md-3 col-sm-3 control-label">服务渠道：</label>
                        <div class="col-md-7 col-sm-7">
                            <p class="form-control-static">${microapp.serviceChannel}</p>
                        </div>
                        <span class="field-validation-valid help-block"></span>
                    </div>
                    <div class="form-group">
                        <label class="col-md-3 col-sm-3 control-label">演示地址：</label>
                        <div class="col-md-7 col-sm-7">
                            <p class="form-control-static">${microapp.demoUrl}</p>
                        </div>
                        <span class="field-validation-valid help-block"></span>
                    </div>
                    <div class="form-group">
                        <label  class="col-md-3 col-sm-3 control-label">访问URL：</label>
                        <div class="col-md-7 col-sm-7">
                            <p class="form-control-static">${microapp.url}</p>
                        </div>
                        <span class="field-validation-valid help-block"></span>
                    </div>
                    <div class="form-group">
                        <label  class="col-md-3 col-sm-3 control-label">页面截图：</label>
                        <div class="col-md-7 col-sm-7">
                            <p class="form-control-static">${screenshot == null ? "" : screenshot}</p>
                        </div>
                        <span class="field-validation-valid help-block"></span>
                    </div>

                    <div class="form-group">
                        <label  class="col-md-3 col-sm-3 control-label">主题分类：</label>
                        <div >
                            <p class="form-control-static">${dic.themename}</p>
                        </div>
                        <span class="field-validation-valid help-block"></span>
                    </div>
                    <div class="form-group">
                        <label  class="col-md-3 col-sm-3 control-label">服务标签：</label>
                        <div class="col-md-7 col-sm-7">
                            <p class="form-control-static">${publishInfo.dataTag}</p>
                            <%--<p class="form-control-static">${microapp.serviceTag}</p>--%>
                        </div>
                        <span class="field-validation-valid help-block"></span>
                    </div>
            </div>
            <div  role="tabpanel" class="tab-pane" id="publish" >
                    <div class="form-group">
                        <label  class="col-md-3 col-sm-3 control-label">共享类型：</label>
                        <div class="col-md-7 col-sm-7">
                            <p class="form-control-static">${resource.shareType}</p>
                        </div>
                        <span class="field-validation-valid help-block"></span>
                    </div>
                    <div class="form-group">
                        <label  class="col-md-3 col-sm-3 control-label">共享条件：</label>
                        <div class="col-md-7 col-sm-7">
                            <p class="form-control-static">${resource.shareType}</p>
                        </div>
                        <span class="field-validation-valid help-block"></span>
                    </div>
                    <div class="form-group">
                        <label  class="col-md-3 col-sm-3 control-label">开放类型：</label>
                        <div class="col-md-7 col-sm-7">
                            <p class="form-control-static"> ${resource.openType}</p>
                        </div>
                        <span class="field-validation-valid help-block"></span>
                    </div>
                    <div class="form-group">
                        <label  class="col-md-3 col-sm-3 control-label">开放条件：</label>
                        <div class="col-md-7 col-sm-7">
                            <p class="form-control-static">${resource.openType}</p>
                        </div>
                        <span class="field-validation-valid help-block"></span>
                    </div>
                    <table style="width: 68%" class="table table-hover  table-condensed table-bordered "
                           align="center">
                        <thead>
                        <tr>
                            <td>套餐名称</td>
                            <td>套餐价格</td>
                            <td>购买限制</td>
                            <td>使用限制</td>
                            <td>生效日期</td>
                            <td>失效日期</td>
                        </tr>
                        <c:forEach items="${publishSettingList}" var="item" >
                        <tr>
                            <td>${item.packageName}</td>
                            <td>${item.packagePrice    }</td>
                            <td>${item.buyTimesLimit}</td>
                            <td>${item.useTimesLimit}</td>
                            <td><fmt:formatDate value="${item.effectiveDate}" pattern="yyyy-MM-dd"/></td>
                            <td><fmt:formatDate value="${item.expiriedDate}" pattern="yyyy-MM-dd"/></td>
                        </tr>
                        </c:forEach>
                        <thead>

                    </table>
            </div>
                    <div class="form-group">
                        <label class="col-md-3 col-sm-3 control-label">审核意见：</label>
                        ${publishInfo.auditOpinion}
                        <span class="field-validation-valid help-block"></span>
                    </div>
    </div>
</form>
<jsp:include page="../../../common/admin/modal_content_post.jsp"></jsp:include>
<jsp:include page="../../../common/admin/modal_footer_pre.jsp"></jsp:include>
<jsp:include page="../../../common/admin/modal_footer_post.jsp"></jsp:include>
<script>
    $('#myTabs a').click(function (e) {
        /*e.preventDefault()*/
        $(this).tab('show')
    })
</script>