Changeset 6515
- Timestamp:
- Dec 19, 2017, 9:26:01 AM (3 years ago)
- Location:
- lmd/trunk/fuentes/admin-center-ltsp.install/modul/lliurex-ltsp/src
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
lmd/trunk/fuentes/admin-center-ltsp.install/modul/lliurex-ltsp/src/images.html
r3008 r6515 89 89 <div i18n image_client_desc="Minimal Thin Client Image" id="llx_ltsp_lliurex_minimal_image" image_client_name="LliureXMini" class="llx_ltsp_template_div col-md-6"> 90 90 <div class="llx_ltsp_template_img col-md-2" style="background-image: url(modules/lliurex-ltsp/src/css/img/llx-mini16.png);"></div> 91 <div class="llx_ltsp_template_namedesc col-md-10"><div class="llx_ltsp_template_name" i18n>Minimal Thin Client</div><div class="llx_ltsp_template_desc" i18n>This is a minimal image to run thin clients with no need of a mirror in the server. Easy and quick.</div></div> 92 </div> 91 <div class="llx_ltsp_template_namedesc col-md-10"><div class="llx_ltsp_template_name" i18n>Minimal Thin Client</div><div class="llx_ltsp_template_desc" i18n>This is a minimal image to run thin clients with no need of a mirror in the server. Easy and quick.</div></div> 92 </div> 93 <!-- Image from ISO --> 94 <div i18n image_client_desc="Image from ISO" id="llx_ltsp_lliurex_from_iso" image_client_name="LliureXISO" class="llx_ltsp_template_div col-md-6"> 95 <div class="llx_ltsp_template_img col-md-2" style="background-image: url(modules/lliurex-ltsp/src/css/img/llx-ISO16.png);"></div> 96 <div class="llx_ltsp_template_namedesc col-md-10"><div class="llx_ltsp_template_name" i18n>Build image from ISO</div><div class="llx_ltsp_template_desc" i18n>Build a client from a downloaded LliureX ISO. This process should be faster than building a client from scratch. </div></div> 97 </div> 93 98 </div></div> 94 99 <div class="modal-footer"> … … 113 118 114 119 <div class="form-group"> 115 <label for="llx_ltsp_new_image_name" class="col-md-2 control-label" i18n>lmd.image.assistant.Name</label> 120 <label for="llx_ltsp_new_image_name" class="col-md-2 control-label" i18n>lmd.image.assistant.Name</label> 116 121 <div class="col-md-10"> 117 122 <input class="form-control" id="llx_ltsp_new_image_name" type="text"> … … 135 140 </div> 136 141 </div> 137 142 143 <div class="form-group" id="llx_ltsp_new_image_assistant_iso_selector"> 144 <label for="llx_ltsp_new_image_arch" class="col-md-2 control-label" i18n>lmd.image.assistant.Architecture</label> 145 <div class="col-md-10"> 146 <input type="file" class="form-control" id="llx_ltsp_new_image_iso" /> 147 </div> 148 </div> 149 138 150 <!--div class="form-group" id="llx_ltsp_new_image_assistant_arch_selector"> 139 151 <label class="col-md-2 control-label" i18n>Architecture</label> -
lmd/trunk/fuentes/admin-center-ltsp.install/modul/lliurex-ltsp/src/js/imageManager.js
r6275 r6515 1389 1389 $("#llx-ltsp-new-image-assistant").fadeOut(); 1390 1390 //alert("create image"); 1391 if(image_data. name=="LliureXMini"){1391 if(image_data.type == "mini"){ 1392 1392 self.deployMinimalClient(); 1393 } 1394 else if( image_data.type == "ISO"){ 1393 1395 } 1394 1396 else { // Let's rock'n'roll … … 1500 1502 $("#llx-ltsp-goto-image-assistant-stage-2").on("click", function(){ 1501 1503 1502 itemSelected=$(".llx_ltsp_template_div_selected"); 1503 1504 if(($(itemSelected).attr("id")!="ltsp_template_client")&& 1505 ($(itemSelected).attr("id")!="ltsp_template_infantil")&& 1506 ($(itemSelected).attr("id")!="llx_ltsp_lliurex_minimal_image")&& 1507 ($(itemSelected).attr("id")!="ltsp_template_desktop")) return -1; 1508 1509 1504 var available_type_images = ["ltsp_template_client", "ltsp_template_infantil", "llx_ltsp_lliurex_minimal_image", "llx_ltsp_lliurex_from_iso", "ltsp_template_desktop"]; 1505 1506 var itemSelected=$(".llx_ltsp_template_div_selected"); 1507 var id_image_selected = $(itemSelected).attr("id"); 1508 1509 /* Check template is supported */ 1510 if( available_type_images.indexOf(id_image_selected) < 0 ) return -1; 1511 1512 $("#llx_ltsp_new_image_assistant_arch_selector").hide(); 1513 $("#llx_ltsp_new_image_assistant_iso_selector").hide(); 1514 1510 1515 if ($(itemSelected).attr("image_client_name")==="LliureXMini") { 1511 1516 // Hiding architecture 1512 $("#llx_ltsp_new_image_assistant_arch_selector").hide(); 1513 } else { 1517 } 1518 else if($(itemSelected).attr("image_client_name")==="LliureXISO"){ 1519 $("#llx_ltsp_new_image_assistant_iso_selector").show(); 1520 } 1521 else { 1514 1522 // Show architecture 1515 1523 $("#llx_ltsp_new_image_assistant_arch_selector").show(); … … 1528 1536 1529 1537 } 1530 1531 1532 1533 1534 1535 1536 1537 // $("#llx_ltsp_new_image_desc").val("#ltsp_template_desktop".find(".llx_ltsp_template_desc").html()); 1538 1539 1538 1540 1539 $("#llx-ltsp-image-assistant-stage-1").fadeOut(function(){ 1541 1540 $("#llx-ltsp-image-assistant-stage-2").fadeIn(); … … 1544 1543 1545 1544 $("#llx-ltsp-create-new-image").on("click", function(){ 1545 1546 /* Define types values */ 1547 1548 var list_templates = { 1549 "ltsp_template_client":{ 1550 "i386":"lliurex-ltsp-client.conf", 1551 "amd64":"lliurex-ltsp-client-amd64.conf", 1552 }, 1553 "ltsp_template_desktop":{ 1554 "i386":"lliurex-ltsp-desktop.conf", 1555 "amd64":"lliurex-ltsp-desktop-amd64.conf", 1556 }, 1557 "ltsp_template_infantil":{ 1558 "i386":"lliurex-ltsp-infantil.conf", 1559 "amd64":"lliurex-ltsp-infantil-amd64.conf" 1560 }, 1561 "llx_ltsp_lliurex_minimal_image":{ 1562 "i386":"", 1563 "amd64":"" 1564 } 1565 }; 1566 1567 var type_image = { 1568 "llx_ltsp_lliurex_from_iso" : "ISO", 1569 "llx_ltsp_lliurex_minimal_image" : "mini", 1570 } 1571 1546 1572 // Check templates 1547 1573 var id=$(".llx_ltsp_template_div_selected").attr("id"); … … 1550 1576 var image_desc=$("#llx_ltsp_new_image_desc").val(); 1551 1577 var arch=$("#llx_ltsp_new_image_arch").val(); 1552 1553 var template=""; 1554 1555 if (id==="ltsp_template_client" && arch==="i386") template="lliurex-ltsp-client.conf"; 1556 else if (id==="ltsp_template_client" && arch==="amd64") template="lliurex-ltsp-client-amd64.conf"; 1557 else if (id==="ltsp_template_desktop" && arch==="i386") template="lliurex-ltsp-desktop.conf"; 1558 else if (id==="ltsp_template_desktop" && arch==="amd64") template="lliurex-ltsp-desktop-amd64.conf"; 1559 else if (id==="ltsp_template_infantil" && arch==="i386") template="lliurex-ltsp-infantil.conf"; 1560 else if (id==="ltsp_template_infantil" && arch==="amd64") template="lliurex-ltsp-infantil-amd64.conf"; 1561 else if (id==="llx_ltsp_lliurex_minimal_image") template=""; 1578 var iso_file = $("#llx_ltsp_new_image_iso"); 1579 1580 var template = ""; 1581 var type = "generated"; 1582 1583 /* 1584 Select template according to image selected and architecture . 1585 If not exists template for options selected or it's not needed then template is void 1586 */ 1587 try{ template = list_templates[id][arch] } catch(err){} 1588 try{ type = type_image[id] } catch(err){} 1562 1589 1563 1590 // Setting image arch to description … … 1569 1596 1570 1597 1571 var info_image={"template": template, 1572 "name": image_name, 1573 "desc": image_desc, 1574 "arch": arch}; 1598 var info_image = {"template": template, 1599 "name": image_name, 1600 "desc": image_desc, 1601 "arch": arch, 1602 "type": type 1603 }; 1575 1604 1576 1605 self.confirmImageCreation(info_image);
Note: See TracChangeset
for help on using the changeset viewer.