ブラウザの開発者ツールのコンソールから下記エラーが出ています。
if (!tablecode) res=match[keys.internal].value;
原因はなんでしょうか。
ブラウザの開発者ツールのコンソールから下記エラーが出ています。
if (!tablecode) res=match[keys.internal].value;
原因はなんでしょうか。
エラー内容はその1行しか出力されてないですか?
最初の太字の行が光って、太字のところで「✕」マークがついています。
var autolookup=setting.autolookups[index];
for (var i=0;i<autolookup.keys.length;i++)
{
if (!(‘external’ in autolookup.keys[i])) autolookup.keys[i][‘external’]=autolookup.keys[i].from;
if (!(‘internal’ in autolookup.keys[i])) autolookup.keys[i][‘internal’]=autolookup.keys[i].to;
}
for (var i=0;i<autolookup.fields.length;i++)
{
if (!(‘external’ in autolookup.fields[i])) autolookup.fields[i][‘external’]=autolookup.fields[i].from;
if (!(‘internal’ in autolookup.fields[i])) autolookup.fields[i][‘internal’]=autolookup.fields[i].to;
}
kintone.api(kintone.api.url(‘/k/v1/app/form/fields’,true),‘GET’,{app:autolookup.app,lang:‘user’},function(resp){
var fieldinfos=$.fieldparallelize(resp.properties);
var keeps={
tablecode:‘’
};
var rowrange=(function(){
var res=1;
for (var i=0;i<autolookup.keys.length;i++)
{
var keys=autolookup.keys[i];
if (keys.internal in vars.fieldinfos)
{
var tablecode=vars.fieldinfos[keys.internal].tablecode;
if (tablecode)
{
res=(match[tablecode].value.length!=0)?match[tablecode].value.length:0;
keeps.tablecode=tablecode;
break;
}
}
}
return res;
})();
var get=function(rowindex,callback){
if (rowrange!=0)
{
var body={
app:autolookup.app,
query:(function(conditions){
var query=‘’;
var res=[];
for (var i=0;i<autolookup.keys.length;i++)
{
var keys=autolookup.keys[i];
if ((keys.external in fieldinfos) && (keys.internal in vars.fieldinfos))
{
var tablecode=vars.fieldinfos[keys.internal].tablecode;
query=$.fieldcompquery(fieldinfos[keys.external],keys.comp,(function(){
var res=null;
if (!tablecode) res=match[keys.internal].value;
else res=match[tablecode].value[rowindex].value[keys.internal].value;
return res;
})());
このトピックはベストアンサーに選ばれた返信から 3 日が経過したので自動的にクローズされました。新たに返信することはできません。