【发布时间】:2020-01-30 06:38:25
【问题描述】:
我尝试使用下面的代码使用最新的 DateTime 填充 qrcode,但没有任何反应。但是,如果我尝试手动设置 qrcode 显示的文本的值。
我正在使用这个plugin
var options = "";
var url_date = "@Url.Action("GetDate", "Test")"
$.get(url_date, function (e) {
$("span[class='DatePrinted']").html(e);
console.log("DatePrinted: " + e);
options = {
render: 'div',
minVersion: 1,
maxVersion: 1,
ecLevel: 'L',
left: 0,
top: 0,
size: 75,
text: e.toString(),
radius: 0,
quiet: 0,
mode: 0
}
}).done(function () {
$("div[class='qr_code']").qrcode(options);
});
【问题讨论】: