改太多
This commit is contained in:
1 parent
be5352efed
commit
1cb2a7a35e
48 files changed
+17970
-485
No files matched your search
@@ -29,15 +29,20 @@ function init_print() {
|
||||
}
|
||||
//console.log(n,t,t.trim().length);
|
||||
});
|
||||
//console.log(i, $(this).html(),$(this).text());
|
||||
//console.log(i, txt==htm);
|
||||
//console.log(i, txt_arr, line, line_len);
|
||||
console.log(i, $(this).html(),$(this).text());
|
||||
console.log(i, txt==htm);
|
||||
console.log(i, txt_arr, line, line_len);
|
||||
line_len = Math.ceil(line_len / 3) * 3;
|
||||
//if(line>1){
|
||||
css = $(this).attr("style")||"";
|
||||
if(css.length>0){
|
||||
css += ";";
|
||||
}
|
||||
if (line_len > 20) {
|
||||
line = Math.ceil( line_len / 20);
|
||||
line_len = 20;
|
||||
|
||||
}
|
||||
css += "--lines:" + line + ";--line_len:" + line_len + ";";
|
||||
|
||||
//字少時, 加空間
|
||||
|
||||
@@ -152,7 +152,7 @@
|
||||
.catch(error => console.log(error))
|
||||
},
|
||||
yulan_print() {
|
||||
_url = HTTP_HOST + 'admin/printpw/index.aspx';
|
||||
_url = HTTP_HOST + 'admin/print/print_multi_preview.aspx'; //'admin/printpw/index.aspx';
|
||||
var form = document.createElement("form");
|
||||
form.method = "POST";
|
||||
form.action = _url;
|
||||
@@ -166,20 +166,27 @@
|
||||
hiddenField.value = value;
|
||||
form.appendChild(hiddenField);
|
||||
};
|
||||
let orders=[]
|
||||
let orders = []
|
||||
let list = []
|
||||
console.log("Selected orders:", this.order_data.selected);
|
||||
this.order_data.selected.forEach(x => {
|
||||
orders.push(x.order_no)
|
||||
list.push({
|
||||
num: x.f_num, order_no: x.order_no
|
||||
})
|
||||
})
|
||||
if (orders.length==0) {
|
||||
return false;
|
||||
}
|
||||
|
||||
localStorage.setItem("list", JSON.stringify(list));
|
||||
addHiddenField("orders", orders);
|
||||
document.body.appendChild(form); // Not entirely sure if this is necessary
|
||||
form.submit();
|
||||
document.body.removeChild(form);
|
||||
},
|
||||
yulan_single(item) {
|
||||
_url = HTTP_HOST + '/admin/printpw/index.aspx';
|
||||
_url = HTTP_HOST + 'admin/print/print_multi_preview.aspx'; //'/admin/printpw/index.aspx';
|
||||
var form = document.createElement("form");
|
||||
form.method = "POST";
|
||||
form.action = _url;
|
||||
@@ -193,6 +200,16 @@
|
||||
hiddenField.value = value;
|
||||
form.appendChild(hiddenField);
|
||||
};
|
||||
console.log("Selected orders:", this.order_data.selected);
|
||||
let list = []
|
||||
//console.log("print_data.selected:",this.print_data.item);
|
||||
this.order_data.selected.forEach(item => {
|
||||
list.push({
|
||||
num: item.f_num, order_no: item.order_no
|
||||
})
|
||||
})
|
||||
console.log("Selected orders list:", list);
|
||||
localStorage.setItem("list", JSON.stringify(list));
|
||||
addHiddenField("order_no", item.order_no);
|
||||
document.body.appendChild(form); // Not entirely sure if this is necessary
|
||||
form.submit();
|
||||
|
||||
Reference in new issue
Block a user