I have a smart contract contains this method:
function addOneUser (User memory _user) public {
bytes32 hash = keccak256(abi.encode(_user.name));
users[hash] = _user;
}
I want to invoke this method using singTransaction then sendSignedTransaction, how to encode data (which _user) into transaction raw ?