| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145 |
- <!DOCTYPE html>
- <html lang="zh">
- <head>
- <meta charset="UTF-8" />
- <title>登录</title>
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
- <link rel="icon" type="image/x-ico" href=""/>
- <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1"/>
- <meta http-equiv="X-UA-Compatible" content="IE=Edge" />
- <link rel="stylesheet" href="./public/static/amis-sdk/helper.css">
- <link rel="stylesheet" href="./public/static/amis-sdk/sdk.css">
- <style>
- html,
- body,
- .app-wrapper {
- position: relative;
- width: 100%;
- height: 100%;
- margin: 0;
- padding: 0;
- touch-action: pan-y;
- }
- :root {
- --Form-item-gap: 1.3rem;
- --InputGroup-height: 2.5rem;
- --Button-height: 2.5rem;
- --InputGroup-paddingX: .6rem;
- --InputGroup-addOn-bg: var(--Form-input-bg);
- /* --fontSizeBase: .9rem; */
- }
- .app-wrapper {
- position: relative;
- width: 100%;
- height: 100%;
- margin: 0;
- padding: 0;
- }
- .loginTitle {
- text-align: center;
- }
- .loginTitle p {
- margin: 10px auto;
- color: black;
- font-size: 25px;
- }
- </style>
- </head>
- <body>
- <div id="root" class="app-wrapper"></div>
- <script type='text/javascript' src='./public/static/amis-sdk/sdk.js'></script>
- <script type="text/javascript">
- (function () {
- let amis = amisRequire('amis/embed');
- const amisJSON = {
- type: 'page',
- title: "",
- style: {
- "backgroundImage": "linear-gradient(180deg, #86a4e9, transparent)"
- },
- cssVars: {
- "--Form-input-onFocused-borderColor": "#e8e9eb",
- "--Form-input-onHover-borderColor": "#e8e9eb",
- },
- body: {
- "type": "grid-2d",
- "cols": 12,
- "grids": [{
- x: 5,
- y: 5,
- h: 1,
- w: 4,
- width: 200,
- type: 'form',
- mode: 'horizontal',
- title: "",
- api: {
- url: "/api/new-login",
- method: "post",
- dataType: "form-data",
- adaptor: function(payload, response, api) {
- }
- },
- panelClassName: "p-r p-l p-b-md",
- redirect: "/admins",
- body: [{
- "type": "tpl",
- "tpl": "<div class='loginTitle'><p>管理后台</p></div>"
- },
- {
- type: "input-text",
- label: false,
- name: "userName",
- size: "full",
- placeholder: "登录名",
- addOn: {
- "label": "",
- "type": "text",
- "position": "left",
- "icon": "fa fa-user"
- },
- },
- {
- type: "input-password",
- label: false,
- name: "password",
- size: "full",
- placeholder: "密码",
- addOn: {
- "label": "",
- "type": "text",
- "position": "left",
- "icon": "fa fa-lock"
- },
- },
- {
- type: "control",
- label: false,
- body: {
- "type": "button",
- "level": "primary",
- "actionType": "submit",
- "block": true,
- "label": "登录"
- }
- }
- ]
- }
- ]
- }
- };
- let amisScoped = amis.embed('#root', amisJSON);
- })();
- </script>
- </body>
- </html>
|