return tag
This commit is contained in:
parent
c1cf51e877
commit
7cb5af94b0
2 changed files with 5 additions and 4 deletions
|
@ -343,7 +343,7 @@ function addCustomField(listId, name, defaultValue, type, group, groupTemplate,
|
|||
break;
|
||||
default:
|
||||
connection.release();
|
||||
return callback(null, fieldId);
|
||||
return callback(null, fieldId, key);
|
||||
}
|
||||
|
||||
connection.query(query, err => {
|
||||
|
@ -352,7 +352,7 @@ function addCustomField(listId, name, defaultValue, type, group, groupTemplate,
|
|||
return callback(err);
|
||||
}
|
||||
connection.release();
|
||||
return callback(null, fieldId);
|
||||
return callback(null, fieldId, key);
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
|
@ -307,7 +307,7 @@ router.post('/field/:listId', (req, res) => {
|
|||
visible: !['false', 'no', '0', ''].includes((input.VISIBLE || '').toString().toLowerCase().trim())
|
||||
};
|
||||
|
||||
fields.create(list.id, field, (err, id) => {
|
||||
fields.create(list.id, field, (err, id, tag) => {
|
||||
if (err) {
|
||||
res.status(500);
|
||||
return res.json({
|
||||
|
@ -318,7 +318,8 @@ router.post('/field/:listId', (req, res) => {
|
|||
res.status(200);
|
||||
res.json({
|
||||
data: {
|
||||
id
|
||||
id,
|
||||
tag
|
||||
}
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue