mirror of
https://github.com/frappe/books.git
synced 2024-11-14 01:14:03 +00:00
Format code
This commit is contained in:
parent
66c439d3d1
commit
349faf0695
@ -64,6 +64,7 @@ module.exports = () => {
|
||||
email: user.name,
|
||||
exp: timeInSecondsAfterHr(24)
|
||||
};
|
||||
|
||||
const token = jwt.encode(payload, jwtSecret);
|
||||
res.json({
|
||||
token: token
|
||||
|
@ -50,14 +50,14 @@ class todo_meta extends frappe.meta.Meta {
|
||||
|
||||
Standard events on which you can bind handlers are
|
||||
|
||||
- `before_insert`
|
||||
- `before_update`
|
||||
- `beforeInsert`
|
||||
- `beforeUpdate`
|
||||
- `validate` (called before any write)
|
||||
- `after_insert`,
|
||||
- `after_update` (called after any write)
|
||||
- `before_submit`
|
||||
- `after_submit`
|
||||
- `before_cancel`
|
||||
- `after_cancel`
|
||||
- `before_delete`
|
||||
- `after_delete`
|
||||
- `afterInsert`,
|
||||
- `afterUpdate` (called after any write)
|
||||
- `beforeSubmit`
|
||||
- `afterSubmit`
|
||||
- `beforeCancel`
|
||||
- `afterCancel`
|
||||
- `beforeDelete`
|
||||
- `afterDelete`
|
||||
|
@ -274,9 +274,9 @@ module.exports = class BaseDocument extends Observable {
|
||||
}
|
||||
|
||||
async delete() {
|
||||
await this.trigger('before_delete');
|
||||
await this.trigger('beforeDelete');
|
||||
await frappe.db.delete(this.doctype, this.name);
|
||||
await this.trigger('after_delete');
|
||||
await this.trigger('afterDelete');
|
||||
}
|
||||
|
||||
async submit() {
|
||||
|
Loading…
Reference in New Issue
Block a user