mirror of
https://gitlab.com/hashborgir/d2tools.git
synced 2025-10-13 08:24:24 -05:00
DescFunc 14 done
This commit is contained in:
25
res/app.js
25
res/app.js
@@ -141,11 +141,30 @@ $(document).ready(function () {
|
||||
$('.uniqueitems-select').change(function () {
|
||||
$(".item").attr("src", "/img/items/1.png");
|
||||
$.get("/ajax/uniqueitems.php?cmd=getUniqueItem&index=" + this.value, function (data) {
|
||||
|
||||
|
||||
props = data.props;
|
||||
|
||||
console.log(props);
|
||||
$('.item_desc').html("<p></p>");
|
||||
$.each(props, function (i, v) {
|
||||
|
||||
if (v.par1) {
|
||||
$s1 = '';
|
||||
}
|
||||
|
||||
|
||||
if(v.string){
|
||||
$('.item_desc p').append(v.string[0]+"<br>");
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
|
||||
|
||||
invImg = "/img/items/" + data.invfile + ".png";
|
||||
$(".item").attr("src", invImg);
|
||||
|
||||
$.each(data, function (i, v) {
|
||||
|
||||
$.each(data, function (i, v) {
|
||||
$('*[name="' + i.replace(/\s/g, '') + '"]').val(v);
|
||||
if (i == 'code') {
|
||||
$('select[name="code[]"]').val(v);
|
||||
|
@@ -165,7 +165,21 @@ option {
|
||||
margin: 15px 0;
|
||||
}
|
||||
|
||||
.item {
|
||||
|
||||
.item_desc {
|
||||
height: auto;
|
||||
width: 420px;
|
||||
position: absolute;
|
||||
left: 110px;
|
||||
top: 23px;
|
||||
|
||||
|
||||
text-align: center;
|
||||
background: black;
|
||||
padding: 10px;
|
||||
|
||||
}
|
||||
|
||||
.item_desc p {
|
||||
font-size: 14px;
|
||||
color: #4169E1;
|
||||
}
|
Reference in New Issue
Block a user