excludeFromIndexes: [] 不起作用。实体属性仍然被索引
excludeFromIndexes: [] does not work. entity properties are still indexed
我有一个事务,我正在保存一个实体并且我有一个数组 excludesFromIndexes.when 实体被保存它显示属性为索引,即使我添加了 excludefromindexes。
function test(user,pass,array,callback){
let transaction = ds.transaction();
let key = ds.key('questions')
transaction.run()
.then(()=>
transaction.save(
{key: key,
data:{
'user':user,
'pass':pass
},
excludeFromIndexes:['user','pass']}))
.then(()=> transaction.commit())
.then(function(apiResponse){
callback({response:'successful'});
})
.catch(function(err){
transaction.rollback()
callback({'error':err});
})
}
不同版本的 Google 数据存储库使用不同的语法,可能会完全忽略 excludefromindexes。
建议更新到最新版本。
我有一个事务,我正在保存一个实体并且我有一个数组 excludesFromIndexes.when 实体被保存它显示属性为索引,即使我添加了 excludefromindexes。
function test(user,pass,array,callback){
let transaction = ds.transaction();
let key = ds.key('questions')
transaction.run()
.then(()=>
transaction.save(
{key: key,
data:{
'user':user,
'pass':pass
},
excludeFromIndexes:['user','pass']}))
.then(()=> transaction.commit())
.then(function(apiResponse){
callback({response:'successful'});
})
.catch(function(err){
transaction.rollback()
callback({'error':err});
})
}
不同版本的 Google 数据存储库使用不同的语法,可能会完全忽略 excludefromindexes。
建议更新到最新版本。