在检索uuid值时出现以下错误
TypeError:“ str”对象不可调用
//checks for the status of menu
let menuFull = false;
$(document).ready(function () {
//Handle navigation button
let navButton = document.getElementById("nav_button");
navButton.addEventListener('click',function (event) {
toggleMenu();
})
});
let toggleMenu = function () {
//Check for the status here
let menuArea = document.getElementById("nav_container");
let containerArea = document.getElementsByClassname("body_container")[0];
if (menuFull) {
menuArea.style.left = "-11.5%";
menuFull = false;
console.log("I am in true area!");
} else {
menuArea.style.left = "0%";
containerArea.style.left = "18.5%";
menuFull = true;
console.log("I am in false area!")
}
console.log(menuFull);
}
import uuid
hash_val = uuid.uuid4().hex()
print(hash_val)
任何人都可以帮助解决此问题吗?
谢谢