guest_create.html 27 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610
  1. {% extends theme("layout.html") %}
  2. {% block head %}
  3. {{ super() }}
  4. <style type="text/css">
  5. @media (min-width: 768px) {
  6. .form-horizontal .control-label {
  7. text-align: left;
  8. }
  9. }
  10. label>span {
  11. color: deepskyblue;
  12. }
  13. .btn,
  14. .form-group>div>div,
  15. .form-control {
  16. border-radius: 0;
  17. }
  18. .btn-ability {
  19. margin-right: 16px;
  20. height: 50px;
  21. padding: 8px 50px;
  22. margin-bottom: 30px;
  23. }
  24. .btn-ability-line {
  25. }
  26. </style>
  27. {% endblock head %}
  28. {% block body %}
  29. <script>
  30. var advanced_show = false;
  31. $(document).ready(function() {
  32. $('body').addClass('add-transition');
  33. $('.add-page-transition').on('click', function(){
  34. var transAttr = $(this).attr('data-transition');
  35. $('.add-transition').attr('class', 'add-transition');
  36. $('.add-transition').addClass(transAttr);
  37. });
  38. $('#create_guest_form').formValidation({
  39. framework: 'bootstrap4',
  40. icon: {
  41. valid: 'fa fa-check',
  42. invalid: 'fa fa-times',
  43. validating: 'fa fa-refresh'
  44. },
  45. // Since the Bootstrap Button hides the radio and checkbox
  46. // We exclude the disabled elements only
  47. excluded: ':disabled',
  48. locale: 'zh_CN',
  49. fields: {
  50. ability: {
  51. validators: {
  52. notEmpty: {
  53. }
  54. }
  55. },
  56. os_template_image_id: {
  57. validators: {
  58. notEmpty: {
  59. }
  60. }
  61. },
  62. quantity: {
  63. validators: {
  64. between: {
  65. min: 1,
  66. max: 20
  67. }
  68. }
  69. },
  70. password: {
  71. validators: {
  72. identical: {
  73. field: 'confirm_password'
  74. },
  75. stringLength: {
  76. max: 128
  77. }
  78. }
  79. },
  80. confirm_password: {
  81. validators: {
  82. identical: {
  83. field: 'password'
  84. }
  85. }
  86. },
  87. remark: {
  88. validators: {
  89. stringLength: {
  90. max: 64
  91. }
  92. }
  93. },
  94. ip_pool_id: {
  95. validators: {
  96. notEmpty: {
  97. }
  98. }
  99. },
  100. vlan_id: {
  101. validators: {
  102. notEmpty: {
  103. }
  104. }
  105. },
  106. project_id: {
  107. validators: {
  108. notEmpty: {
  109. }
  110. }
  111. },
  112. service_id: {
  113. validators: {
  114. notEmpty: {
  115. }
  116. }
  117. }
  118. }
  119. })
  120. .on('success.field.fv', function(e, data) {
  121. if (data.fv.getInvalidFields().length > 0) { // There is invalid field
  122. data.fv.disableSubmitButtons(true);
  123. }
  124. }).on('success.form.fv', function (e, data) {
  125. create();
  126. });
  127. refresh_os_template_image_id_selectpicker($('#os_template_image_id'));
  128. refresh_ssh_keys_checkboxer($('#ssh_keys_id_div'));
  129. refresh_ip_pool_id_selectpicker($('#ip_pool_id'));
  130. refresh_vlan_id_selectpicker($('#vlan_id'));
  131. refresh_project_id_selectpicker($('#project_id'));
  132. refresh_service_id_selectpicker($('#service_id'), 1);
  133. $('#bandwidth_unit').on('changed.bs.select', function (me) {
  134. render_bandwidth_slider($("#bandwidth"), 'update', $('#bandwidth_unit').val())
  135. });
  136. render_bandwidth_slider($("#bandwidth"), 'create', 'm');
  137. $('#project_id').on('changed.bs.select', function (me) {
  138. refresh_service_id_selectpicker($('#service_id'), $('#project_id').val());
  139. });
  140. });
  141. function advanced_onclick(me) {
  142. if (advanced_show) {
  143. $('.advanced').css('display', 'none');
  144. advanced_show = false;
  145. $(me).find('span').removeClass('icon-caret-up').addClass('icon-caret-down');
  146. } else {
  147. $('.advanced').css('display', 'block');
  148. advanced_show = true;
  149. $(me).find('span').removeClass('icon-caret-down').addClass('icon-caret-up');
  150. }
  151. }
  152. function get_os_templates_profile_mapping_by_id() {
  153. var os_templates_profile_mapping_by_id = {};
  154. $.ajax({
  155. url : '/api/os_templates_profile',
  156. type : 'GET',
  157. contentType: "application/json; charset=utf-8",
  158. dataType: 'json',
  159. async: false,
  160. error : function() {
  161. },
  162. success : function(data, textStatus, xhr) {
  163. $.each(data.data, function(k, v) {
  164. os_templates_profile_mapping_by_id[v['id']] = v;
  165. });
  166. }
  167. });
  168. return os_templates_profile_mapping_by_id;
  169. }
  170. function refresh_os_template_image_id_selectpicker(selectpicker) {
  171. $.ajax({
  172. url : '/api/os_templates_image?filter=active:eq:1',
  173. type : 'GET',
  174. contentType: "application/json; charset=utf-8",
  175. dataType: 'json',
  176. async: false,
  177. error : function() {
  178. },
  179. success : function(data, textStatus, xhr) {
  180. var os_templates_profile_mapping_by_id = get_os_templates_profile_mapping_by_id();
  181. selectpicker.empty();
  182. $.each(data.data, function(k, v) {
  183. if (v['logo'] === "") {
  184. v['logo'] = os_templates_profile_mapping_by_id[v['os_template_profile_id']].icon;
  185. }
  186. selectpicker.append(
  187. $('<option>', {value: v['id'], text: '\xa0\xa0' + v['label'], 'data-icon': v['logo']})
  188. );
  189. });
  190. selectpicker.selectpicker('refresh');
  191. }
  192. });
  193. }
  194. function refresh_ip_pool_id_selectpicker(selectpicker) {
  195. $.ajax({
  196. url : '/api/ip_pools',
  197. type : 'GET',
  198. contentType: "application/json; charset=utf-8",
  199. dataType: 'json',
  200. async: false,
  201. error : function() {
  202. },
  203. success : function(data, textStatus, xhr) {
  204. selectpicker.empty();
  205. var selected = '';
  206. $.each(data.data, function(k, v) {
  207. selectpicker.append(
  208. $('<option>', {value: v['id'], text: '\xa0\xa0' + v['name']})
  209. );
  210. if (v['activity']) {
  211. selected = v['id'];
  212. }
  213. });
  214. selectpicker.selectpicker('refresh');
  215. selectpicker.val(selected).change();
  216. }
  217. });
  218. }
  219. function refresh_vlan_id_selectpicker(selectpicker) {
  220. $.ajax({
  221. url : '/api/vlans',
  222. type : 'GET',
  223. contentType: "application/json; charset=utf-8",
  224. dataType: 'json',
  225. async: false,
  226. error : function() {
  227. },
  228. success : function(data, textStatus, xhr) {
  229. selectpicker.empty();
  230. $.each(data.data, function(k, v) {
  231. selectpicker.append(
  232. $('<option>', {value: v['vlan_id'], text: '\xa0\xa0' + v['label'], 'data-subtext': v['description']})
  233. );
  234. });
  235. selectpicker.selectpicker('refresh');
  236. selectpicker.val('-1').change();
  237. }
  238. });
  239. }
  240. function refresh_project_id_selectpicker(selectpicker) {
  241. $.ajax({
  242. url : '/api/projects',
  243. type : 'GET',
  244. contentType: "application/json; charset=utf-8",
  245. dataType: 'json',
  246. async: false,
  247. error : function() {
  248. },
  249. success : function(data, textStatus, xhr) {
  250. selectpicker.empty();
  251. $.each(data.data, function(k, v) {
  252. selectpicker.append(
  253. $('<option>', {value: v['id'], text: '\xa0\xa0' + v['name'], 'data-subtext': v['description']})
  254. );
  255. });
  256. selectpicker.selectpicker('refresh');
  257. selectpicker.val('1').change();
  258. }
  259. });
  260. }
  261. function refresh_service_id_selectpicker(selectpicker, project_id) {
  262. $.ajax({
  263. url : '/api/projects/' + project_id,
  264. type : 'GET',
  265. contentType: "application/json; charset=utf-8",
  266. dataType: 'json',
  267. async: false,
  268. error : function() {
  269. },
  270. success : function(data, textStatus, xhr) {
  271. selectpicker.empty();
  272. $.each(data.data['services'], function(k, v) {
  273. selectpicker.append(
  274. $('<option>', {value: v['id'], text: '\xa0\xa0' + v['name'], 'data-subtext': v['description']})
  275. );
  276. });
  277. selectpicker.selectpicker('refresh');
  278. if (project_id === 1) {
  279. selectpicker.val('1').change();
  280. }
  281. }
  282. });
  283. }
  284. function refresh_ssh_keys_checkboxer(checkboxer) {
  285. $.ajax({
  286. url : '/api/ssh_keys',
  287. type : 'GET',
  288. contentType: "application/json; charset=utf-8",
  289. dataType: 'json',
  290. async: false,
  291. error : function() {
  292. },
  293. success : function(data, textStatus, xhr) {
  294. checkboxer.empty();
  295. $.each(data.data, function(k, v) {
  296. checkboxer.append(
  297. '<label class="checkbox-inline"><input type="checkbox" name="ssh_keys_id" value="' + v['id'] + '">' + v['label'] + '</label>'
  298. );
  299. });
  300. }
  301. });
  302. }
  303. function create() {
  304. var ability_value = $('#create_guest_form input:radio[name="ability"]:checked').val();
  305. ability_value = ability_value.match(/^(\d+)c(\d+)g$/i);
  306. if (ability_value === null) {
  307. alter_danger('指定的配置取值有误!');
  308. return
  309. }
  310. var cpu = ability_value[1];
  311. var memory = ability_value[2];
  312. var data = {
  313. cpu: parseInt(cpu),
  314. memory: parseInt(memory),
  315. bandwidth: parseInt($('#bandwidth').val()),
  316. bandwidth_unit: $('#bandwidth_unit').val(),
  317. os_template_image_id: parseInt($('#os_template_image_id').val()),
  318. quantity: parseInt($('#quantity').val()),
  319. remark: $('#remark').val(),
  320. password: $('#password').val(),
  321. ssh_keys_id: $("input[name=ssh_keys_id]:checked").map(function () {return this.value}).get(),
  322. ip_pool_id: parseInt($('#ip_pool_id').val()),
  323. service_id: parseInt($('#service_id').val()),
  324. vlan_id: parseInt($('#vlan_id').val()),
  325. lease_term: 100
  326. };
  327. if (!$('#allocation_by_random').prop('checked')) {
  328. data['node_id'] = $('#node_id').val()
  329. }
  330. var go_back_url = '/guests';
  331. $.ajax({
  332. url : '/api/guest',
  333. type : 'POST',
  334. contentType: "application/json; charset=utf-8",
  335. async: false,
  336. dataType: "json",
  337. data : JSON.stringify(data),
  338. error : function(data, textStatus, xhr) {
  339. alter_warning('创建实例失败!');
  340. alter_danger(data.responseText);
  341. },
  342. success : function(data, textStatus, xhr) {
  343. alter_success('您所提交的资源正在创建中。根据所提交资源的大小,需要等待几到十几分钟。页面将在3秒钟后自动跳转到实例列表页面!');
  344. $.ajax({
  345. url: '/api/guests',
  346. type : 'GET',
  347. dataType: "json",
  348. error : function(data, textStatus, xhr) {
  349. },
  350. success : function(data, textStatus, xhr) {
  351. var page_size = 20;
  352. var last_page = Math.ceil(data['paging']['total'] / page_size);
  353. go_back_url = "/guests?page_size=" + page_size + "&page=" + last_page;
  354. }
  355. });
  356. }
  357. });
  358. setTimeout(function() {
  359. window.location.href=go_back_url;
  360. }, 3000);
  361. }
  362. $(function() { "use strict";
  363. $("#quantity").TouchSpin({
  364. max: 20,
  365. min: 1,
  366. verticalbuttons: true,
  367. verticalupclass: 'glyph-icon icon-plus',
  368. verticaldownclass: 'glyph-icon icon-minus'
  369. });
  370. });
  371. function allocation_by_random_click_handler(me) {
  372. if ($(me).prop('checked')) {
  373. $('#create_guest_form').formValidation('removeField', 'node_id');
  374. $('#node_id').parent().parent().css('display', 'none');
  375. } else {
  376. $('#create_guest_form').formValidation('addField', 'node_id', {validators: {notEmpty: {}}});
  377. $('#node_id').parent().parent().css('display', 'unset');
  378. }
  379. }
  380. </script>
  381. <div id="page-content-wrapper">
  382. <div id="alert-success-tip" class="alert alert-success alert-top">
  383. </div>
  384. <div id="alert-warning-tip" class="alert alert-warning alert-top">
  385. </div>
  386. <div id="alert-danger-tip" class="alert alert-danger alert-top">
  387. </div>
  388. </div>
  389. <div class="container" style="padding-top: 100px;">
  390. <div class="panel">
  391. <div class="panel-body">
  392. <h3 class="title-hero" style="display: inline;">
  393. 创建实例
  394. </h3>
  395. <a href="/guests" class="btn btn-xs btn-default add-page-transition" data-transition="pt-page-moveFromLeft-init" style="margin-bottom: 4px; margin-left: 10px;">
  396. <span class="glyph-icon icon-separator" style="transform: rotateY(-180deg);">
  397. <i class="glyph-icon icon-level-up"></i>
  398. </span>
  399. <span class="button-content">
  400. 返回虚拟机列表
  401. </span>
  402. </a>
  403. <div class="example-box-wrapper">
  404. <form id="create_guest_form" class="form-horizontal bordered-row" action="javascript:;">
  405. <div class="form-group">
  406. <label class="col-sm-2 control-label"><span class="glyph-icon icon-elusive-gauge"></span>&nbsp;&nbsp;运算能力</label>
  407. <div class="col-sm-10">
  408. <div class="btn-ability-line" data-toggle="buttons">
  409. <label class="btn btn-default btn-ability">
  410. <input title="1 CPU 1GB Memory" name="ability" type="radio" value="1c1g">1&nbsp;&nbsp;核&nbsp;&nbsp;1&nbsp;&nbsp;GB
  411. </label>
  412. <label class="btn btn-default btn-ability">
  413. <input title="1 CPU 2GB Memory" name="ability" type="radio" value="1c2g">1&nbsp;&nbsp;核&nbsp;&nbsp;2&nbsp;&nbsp;GB
  414. </label>
  415. <label class="btn btn-default btn-ability">
  416. <input title="2 CPU 2GB Memory" name="ability" type="radio" value="2c2g">2&nbsp;&nbsp;核&nbsp;&nbsp;2&nbsp;&nbsp;GB
  417. </label>
  418. <label class="btn btn-default btn-ability">
  419. <input title="2 CPU 4GB Memory" name="ability" type="radio" value="2c4g">2&nbsp;&nbsp;核&nbsp;&nbsp;4&nbsp;&nbsp;GB
  420. </label>
  421. <label class="btn btn-default btn-ability">
  422. <input title="4 CPU 4GB Memory" name="ability" type="radio" value="4c4g">4&nbsp;&nbsp;核&nbsp;&nbsp;4&nbsp;&nbsp;GB
  423. </label>
  424. <label class="btn btn-default btn-ability">
  425. <input title="4 CPU 8GB Memory" name="ability" type="radio" value="4c8g">4&nbsp;&nbsp;核&nbsp;&nbsp;8&nbsp;&nbsp;GB
  426. </label>
  427. <label class="btn btn-default btn-ability">
  428. <input title="8 CPU 8GB Memory" name="ability" type="radio" value="8c8g">8&nbsp;&nbsp;核&nbsp;&nbsp;8&nbsp;&nbsp;GB
  429. </label>
  430. <label class="btn btn-default btn-ability">
  431. <input title="8 CPU 16GB Memory" name="ability" type="radio" value="8c16g">8&nbsp;&nbsp;核&nbsp;&nbsp;16GB
  432. </label>
  433. <label class="btn btn-default btn-ability">
  434. <input title="1 CPU 16GB Memory" name="ability" type="radio" value="1c16g">1&nbsp;&nbsp;核&nbsp;&nbsp;16GB
  435. </label>
  436. <label class="btn btn-default btn-ability">
  437. <input title="4 CPU 32GB Memory" name="ability" type="radio" value="4c32g">4&nbsp;&nbsp;核&nbsp;&nbsp;32GB
  438. </label>
  439. <label class="btn btn-default btn-ability">
  440. <input title="8 CPU 32GB Memory" name="ability" type="radio" value="8c32g">8&nbsp;&nbsp;核&nbsp;&nbsp;32GB
  441. </label>
  442. <label class="btn btn-default btn-ability">
  443. <input title="8 CPU 64GB Memory" name="ability" type="radio" value="8c64g">8&nbsp;&nbsp;核&nbsp;&nbsp;64GB
  444. </label>
  445. <label class="btn btn-default btn-ability">
  446. <input title="16 CPU 16GB Memory" name="ability" type="radio" value="16c16g">16核&nbsp;&nbsp;16GB
  447. </label>
  448. <label class="btn btn-default btn-ability">
  449. <input title="24 CPU 24GB Memory" name="ability" type="radio" value="24c24g">24核&nbsp;&nbsp;24GB
  450. </label>
  451. <label class="btn btn-default btn-ability">
  452. <input title="32 CPU 32GB Memory" name="ability" type="radio" value="32c32g">32核&nbsp;&nbsp;32GB
  453. </label>
  454. <label class="btn btn-default btn-ability">
  455. <input title="64 CPU 64GB Memory" name="ability" type="radio" value="64c64g">64核&nbsp;&nbsp;64GB
  456. </label>
  457. </div>
  458. </div>
  459. </div>
  460. <div class="form-group">
  461. <label class="col-sm-2 control-label"><span class="glyph-icon icon-elusive-inbox-alt"></span>&nbsp;&nbsp;系统模板</label>
  462. <div class="col-sm-6">
  463. <select id="os_template_image_id" name="os_template_image_id" title="请选择系统模板..." class="selectpicker" data-width="100%">
  464. </select>
  465. </div>
  466. </div>
  467. <div class="form-group">
  468. <label class="col-sm-2 control-label"><span class="glyph-icon icon-elusive-th-list"></span>&nbsp;&nbsp;数量</label>
  469. <div class="col-sm-6">
  470. <input id="quantity" title="实例数量" class="form-control" type="text" value="1" name="quantity">
  471. </div>
  472. </div>
  473. <div class="form-group">
  474. <label class="col-sm-2 control-label"><span class="glyph-icon icon-elusive-compass-circled"></span>&nbsp;&nbsp;标识&密码</label>
  475. <div class="col-sm-6">
  476. <div class="row form-group">
  477. <label class="col-sm-2 control-label">登录密码:</label>
  478. <div class="col-sm-6">
  479. <input type="password" name="password" title="实例密码" class="form-control" id="password" placeholder="如不填写,系统自动生成16位随机密码">
  480. </div>
  481. </div>
  482. <div class="row form-group">
  483. <label class="col-sm-2 control-label">确认密码:</label>
  484. <div class="col-sm-6">
  485. <input type="password" name="confirm_password" title="确认实例密码" class="form-control" id="confirm_password">
  486. </div>
  487. </div>
  488. <div style="height: 10px;"></div>
  489. <div class="row form-group">
  490. <label class="col-sm-2 control-label">实例名称:</label>
  491. <div class="col-sm-6">
  492. <input id="remark" name="remark" type="text" title="实例名称" class="form-control" placeholder="如不填写,系统自动默认生成">
  493. </div>
  494. </div>
  495. </div>
  496. </div>
  497. <div class="form-group">
  498. <label class="col-sm-2 control-label"><span class="glyph-icon icon-signal"></span>&nbsp;&nbsp;带宽</label>
  499. <div class="col-sm-7">
  500. <input id="bandwidth" title="带宽" type="text" name="bandwidth">
  501. </div>
  502. <div class="col-sm-1" style="bottom: -10px;">
  503. <select id="bandwidth_unit" name="bandwidth_unit" title="单位..." class="selectpicker" data-width="120%">
  504. <option value="k">&nbsp;&nbsp;Kbps</option>
  505. <option value="m" selected>&nbsp;&nbsp;Mbps</option>
  506. <option value="g">&nbsp;&nbsp;Gbps</option>
  507. </select>
  508. </div>
  509. </div>
  510. <div class="form-group">
  511. <label class="col-sm-2 control-label"><span class="glyph-icon icon-key"></span>&nbsp;&nbsp;SSH-KEY</label>
  512. <div class="col-sm-6" id="ssh_keys_id_div">
  513. </div>
  514. </div>
  515. <div class="form-group" style="text-align: center;">
  516. <a href="javascript:;" id="advanced" onclick="advanced_onclick(this);">高级&nbsp;&nbsp;&nbsp;&nbsp;<span class="glyph-icon icon-caret-down"></span></a>
  517. </div>
  518. <div class="form-group advanced" style="display: none;">
  519. <label class="col-sm-2 control-label"><span class="glyph-icon icon-elusive-shuffle"></span>&nbsp;&nbsp;创建模式</label>
  520. <div class="col-sm-6">
  521. <div class="row form-group">
  522. <label class="col-sm-2 control-label">随机分配:</label>
  523. <div class="col-sm-6">
  524. <input onclick="allocation_by_random_click_handler(this);" type="checkbox" name="allocation_by_random" title="随机分配" class="form-control" id="allocation_by_random" checked>
  525. </div>
  526. </div>
  527. <div class="row form-group" style="display: none;">
  528. <select id="node_id" name="node_id" title="请选择计算节点..." class="selectpicker" data-width="100%">
  529. {% for item in hosts_ret.data %}
  530. <option value="{{ item.node_id }}" data-icon="{{ item.icon }}">&nbsp;&nbsp;{{ item.hostname }}</option>
  531. {% endfor %}
  532. </select>
  533. </div>
  534. </div>
  535. </div>
  536. <div class="form-group advanced" style="display: none;">
  537. <label class="col-sm-2 control-label"><span class="glyph-icon icon-elusive-address-book"></span>&nbsp;&nbsp;IP 池</label>
  538. <div class="col-sm-6">
  539. <select id="ip_pool_id" name="ip_pool_id" title="请选 IP 池..." class="selectpicker" data-width="100%">
  540. </select>
  541. </div>
  542. </div>
  543. <div class="form-group advanced" style="display: none;">
  544. <label class="col-sm-2 control-label"><span class="glyph-icon icon-elusive-network"></span>&nbsp;&nbsp;VLAN</label>
  545. <div class="col-sm-6">
  546. <select id="vlan_id" name="vlan_id" title="请选所属网络..." class="selectpicker" data-width="100%">
  547. </select>
  548. </div>
  549. </div>
  550. <div class="form-group advanced" style="display: none;">
  551. <label class="col-sm-2 control-label"><span class="glyph-icon icon-cubes"></span>&nbsp;&nbsp;项目编制</label>
  552. <div class="col-sm-3">
  553. <select id="project_id" name="project_id" title="请选所属项目..." class="selectpicker" data-width="100%">
  554. </select>
  555. </div>
  556. <div class="col-sm-3">
  557. <select id="service_id" name="service_id" title="请选所属服务..." class="selectpicker" data-width="100%">
  558. </select>
  559. </div>
  560. </div>
  561. <div class="form-group">
  562. <label class="col-sm-2 control-label"></label>
  563. <div class="col-sm-3 pull-right">
  564. <button id="create_guest_form_button" type="submit" class="btn btn-blue-alt" style="width: 180px; height: 40px; font-size: 16px;" disabled>创建</button>
  565. </div>
  566. </div>
  567. </form>
  568. </div>
  569. </div>
  570. </div>
  571. </div>
  572. {% endblock body %}