{% load static simpletags %}
<!DOCTYPE html>
<html lang="zh-hans">
<head>
    <meta charset="UTF-8">
    <title>Simple Pro 激活信息</title>
    {% block css %}
        {% if "SIMPLEUI_STATIC_OFFLINE"|get_config %}
            <link rel="stylesheet" href="{% static '/admin/simpleui-x/elementui/theme-chalk/index.css' %}">
        {% else %}
            <link rel="stylesheet" href="https://unpkg.com/element-ui/lib/theme-chalk/index.css">
        {% endif %}
    {% endblock %}
</head>
<body>

<div id="app">
    {% if is_active %}
        <el-alert
                title="您的Simple Pro已经成功激活！"
                type="success"
                show-icon>
        </el-alert>
        <el-form style="margin-top: 20px" ref="form" :model="form" label-width="80px">
            <el-form-item label="设备ID">
                <el-input v-model="form.device_id"></el-input>
            </el-form-item>
            <el-form-item label="激活码">
                <el-input v-model="form.code"></el-input>
            </el-form-item>
            <el-form-item label="到期时间">
                <el-input v-model="form.end_date"></el-input>
            </el-form-item>
        </el-form>

    {% else %}
        <el-alert
                title="您的Simple Pro未激活！"
                type="info"
                show-icon>
        </el-alert>
    {% endif %}
</div>
<script type="text/javascript">
    var data =
    {{ data|safe }}
</script>
<script type="text/javascript" src="{% static '/admin/simpleui-x/js/cookie.js' %}"></script>
{% if "SIMPLEUI_STATIC_OFFLINE"|get_config %}
    <script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
    <script type="text/javascript" src="{% static '/admin/simpleui-x/elementui/index.js' %}"></script>
{% else %}
    <script src="https://cdn.jsdelivr.net/npm/vue"></script>
    <script src="https://unpkg.com/element-ui/lib/index.js"></script>
{% endif %}
<script type="text/javascript" src="{% static '/admin/simplepro/js/info.js' %}"></script>
</body>
</html>