waibu-db 1.0.6 → 1.0.7

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "waibu-db",
3
- "version": "1.0.6",
3
+ "version": "1.0.7",
4
4
  "description": "DB Helper",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -35,14 +35,14 @@ async function btnDelete () {
35
35
  this.params.attr['x-data'] = `{
36
36
  selected: ['${req.query.id}'],
37
37
  remove (modalId, ids) {
38
+ ids = JSON.parse(wmpa.fromBase64(ids)).join(',')
38
39
  wmpa.postForm({ ids }, '${this.component.buildUrl({ base: 'delete', exclude: ['id', 'page'] })}')
39
40
  }
40
41
  }`
41
42
  }
42
43
  const msg = 'You\'re about to remove one or more records. Are you really sure to do this?'
43
44
  this.params.attr['@click'] = `
44
- const opts = selected.join(',')
45
- await wbs.confirmation(\`${req.t(msg)}\`, { ok: '${this.params.attr.id}:remove', close: 'y', opts })
45
+ await wbs.confirmation(\`${req.t(msg)}\`, { ok: '${this.params.attr.id}:remove', close: 'y', opts: selected })
46
46
  `
47
47
  this.params.html = await this.component.buildTag({ tag: 'btn', attr: this.params.attr, html: this.params.html })
48
48
  }
@@ -91,7 +91,6 @@ async function query () {
91
91
  val = opv.slice(v.length).replaceAll('[', '').replaceAll(']', '').replaceAll('\\'', '')
92
92
  }
93
93
  })
94
- console.log(op, val)
95
94
  if (_.isEmpty(op)) continue
96
95
  this[f + 'Op'] = op
97
96
  this[f + 'Val'] = val