sumba 2.49.1 → 2.49.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -14,7 +14,7 @@ async function navDropdownUser () {
|
|
|
14
14
|
} else text = req.t('guest')
|
|
15
15
|
}
|
|
16
16
|
const html = []
|
|
17
|
-
const attr = omit(this.params.attr, ['
|
|
17
|
+
const attr = omit(this.params.attr, ['noMenu'])
|
|
18
18
|
attr.dropdown = true
|
|
19
19
|
attr.content = `${icon} ${text}`
|
|
20
20
|
if (this.params.attr.noMenu) {
|
|
@@ -4,7 +4,7 @@ const list = {
|
|
|
4
4
|
method: ['GET'],
|
|
5
5
|
handler: async function (req, reply) {
|
|
6
6
|
const { findRecord, getSchemaExt } = this.app.waibuDb
|
|
7
|
-
const {
|
|
7
|
+
const { createExcerpt } = this.app.lib.aneka
|
|
8
8
|
const { schema } = await getSchemaExt(model, 'list')
|
|
9
9
|
const options = { count: true }
|
|
10
10
|
const list = await findRecord({ model, req, options })
|
|
@@ -13,7 +13,7 @@ const list = {
|
|
|
13
13
|
schema.view.label = { subject: 'Your Message' }
|
|
14
14
|
schema.view.format = {
|
|
15
15
|
subject: (val, rec) => {
|
|
16
|
-
return `<strong>${val}</strong><br />${
|
|
16
|
+
return `<strong>${val}</strong><br />${createExcerpt({ content: rec.message, maxWords: 35 })}`
|
|
17
17
|
}
|
|
18
18
|
}
|
|
19
19
|
return await reply.view('sumba.template:/help/trouble-tickets/list.html', { list, schema })
|
package/package.json
CHANGED