実現したいこと
フォームブリッジ上にボタンを設置し、ボタンをクリックするとテキストボックスに文字が入力されるようにしたのですが、回答をクリックしてもデータが保存されません。
エラー情報
kintone上では空欄のままです。
利用したソースコード
(function() {
“use strict”;
const pButton3 = document.createElement(‘button’); //ボタン生成
pButton3.style.height = ‘40px’; //ボタンの高さ
pButton3.style.width = ‘140px’; //ボタンの横幅
pButton3.style.fontSize = ‘25px’; //ボタンのフォントサイズ
pButton3.innerHTML = ‘文字入力’; //ボタンの表示名
pButton3.style.margin = ‘10px 0px 0px 10px’; //余白(上 右 下 左)
pButton3.style.borderRadius = ‘0px’; //ボタンのデザイン
pButton3.onclick = function(){
var s = fb.getElementByCode(‘文字列’).getElementsByTagName(‘input’)[0];
s.value = ‘こんにちは’;
};
fb.events.form.mounted.push(function () {
document.querySelector(‘[data-vv-name=“文字列”]’).appendChild(pButton3);
});
})();