@kigi/components 1.27.8-alpha → 1.27.9-alpha

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": "@kigi/components",
3
- "version": "1.27.8-alpha",
3
+ "version": "1.27.9-alpha",
4
4
  "description": "@kigi/components",
5
5
  "main": "src/components/index.ts",
6
6
  "scripts": {
@@ -8,4 +8,4 @@
8
8
  <span ng-if="$ctrl.loading || $ctrl.virtualDisable"
9
9
  class="mbg-btn-loading"></span>
10
10
  </button>
11
- </div>
11
+ </div>
@@ -23,7 +23,7 @@ class MbgBtnFormController {
23
23
  }
24
24
  }
25
25
  }
26
- MbgBtnFormController['$inject'] = ['$scope', '$element', '$attrs', '$timeout']
26
+ MbgBtnFormController.$inject = ['$scope', '$element', '$attrs', '$timeout']
27
27
 
28
28
  const mbgBtnForm = {
29
29
  bindings: {
@@ -1,8 +1,8 @@
1
1
  import './mbg-list.scss'
2
2
  import * as angular from 'angular'
3
3
  import template from './mbg-list.html'
4
- import {MbgListColumnController} from './components/mbg-list-column/mbg-list-column'
5
- import {MbgListRowController} from './components/mbg-list-row/mbg-list-row'
4
+ import { MbgListColumnController } from './components/mbg-list-column/mbg-list-column'
5
+ import { MbgListRowController } from './components/mbg-list-row/mbg-list-row'
6
6
 
7
7
  export class MbgListController {
8
8
  public rows: Array<any>
@@ -28,8 +28,7 @@ export class MbgListController {
28
28
  public indexToPush
29
29
  private movementManual
30
30
 
31
- constructor(public $scope, public $element, public $attrs, public $timeout, public $transclude) {
32
- }
31
+ constructor(public $scope, public $element, public $attrs, public $timeout, public $transclude) {}
33
32
 
34
33
  $onInit() {
35
34
  this.enableOnSelectByRow =
@@ -96,7 +95,6 @@ export class MbgListController {
96
95
  removeCircularJson(json) {
97
96
  const parsed = JSON.parse(json)
98
97
  delete parsed.$json
99
- delete parsed.$$hashKey
100
98
  return JSON.stringify(parsed)
101
99
  }
102
100
 
@@ -195,7 +193,7 @@ export class MbgListController {
195
193
 
196
194
  isAllSelected() {
197
195
  if (this.checkboxIf) {
198
- const possibleActive = this.list.filter((row) => this.checkboxIf({$row: row}))
196
+ const possibleActive = this.list.filter((row) => this.checkboxIf({ $row: row }))
199
197
  return (
200
198
  possibleActive.filter(
201
199
  (row) => !this.selectedMap[this.removeCircularJson(JSON.stringify(row))],
@@ -211,7 +209,7 @@ export class MbgListController {
211
209
  toogleAll(selectAll) {
212
210
  this.list.forEach((row) => {
213
211
  if (this.checkboxIf) {
214
- if (this.checkboxIf({$row: row})) {
212
+ if (this.checkboxIf({ $row: row })) {
215
213
  this.selectedMap[this.removeCircularJson(JSON.stringify(row))] = selectAll
216
214
  }
217
215
  } else {
@@ -242,7 +240,7 @@ export class MbgListController {
242
240
  if (this.rowsAdicional !== index && (this.checkbox || this.radio) && this.enableOnSelectByRow) {
243
241
  if (this.radio) {
244
242
  if (this.checkboxIf) {
245
- if (this.checkboxIf({$row: row})) {
243
+ if (this.checkboxIf({ $row: row })) {
246
244
  this.toogleRadio(row.$json)
247
245
  }
248
246
  } else {
@@ -250,7 +248,7 @@ export class MbgListController {
250
248
  }
251
249
  } else {
252
250
  if (this.checkboxIf) {
253
- if (this.checkboxIf({$row: row})) {
251
+ if (this.checkboxIf({ $row: row })) {
254
252
  this.selectedMap[row.$json] = !this.selectedMap[row.$json]
255
253
  this.toogleCheckbox()
256
254
  }
@@ -261,7 +259,7 @@ export class MbgListController {
261
259
  }
262
260
  }
263
261
  if (this.onClickRow) {
264
- this.onClickRow({$row: row})
262
+ this.onClickRow({ $row: row })
265
263
  }
266
264
  }
267
265
 
@@ -284,7 +282,7 @@ export class MbgListController {
284
282
  getRowStripedStyle(row, index) {
285
283
  if (row.isAdicional) {
286
284
  const background = this.$element.find(`table tr`)[index].style.backgroundColor
287
- return {background}
285
+ return { background }
288
286
  }
289
287
 
290
288
  return {
@@ -295,7 +293,7 @@ export class MbgListController {
295
293
  r.$json ? r.$json : JSON.stringify(r),
296
294
  )
297
295
  }) %
298
- 2 ===
296
+ 2 ===
299
297
  0
300
298
  ? '#eaeaea'
301
299
  : '#F5F5F5',
@@ -327,4 +325,4 @@ const mbgList = {
327
325
  controller: MbgListController,
328
326
  }
329
327
 
330
- export {mbgList}
328
+ export { mbgList }
@@ -6,7 +6,7 @@ class MbgStatusLabelController {
6
6
  private label: string
7
7
  private labelClass: string
8
8
 
9
- constructor(public $scope, public $element, public $attrs, public $timeout) { }
9
+ constructor(public $scope, public $element, public $attrs, public $timeout) {}
10
10
 
11
11
  $onInit() {
12
12
  this.$scope.$watch('$ctrl.status', (data) => {
@@ -52,10 +52,12 @@ class MbgStatusLabelController {
52
52
  this.label = 'Cancelada'
53
53
  break
54
54
  case 'REJEITADA':
55
- case 'PENDING_REJECT':
56
55
  case 'REJECTED':
57
56
  this.label = 'Rejeitada'
58
57
  break
58
+ case 'PENDING_REJECT':
59
+ this.label = 'Aguardando recusa'
60
+ break
59
61
  case 'DENEGADA':
60
62
  this.label = 'Denegada'
61
63
  break
@@ -101,13 +103,15 @@ class MbgStatusLabelController {
101
103
  case 'RETURNED':
102
104
  case 'CANCELADA':
103
105
  case 'REJEITADA':
104
- case 'PENDING_REJECT':
105
106
  case 'REJECTED':
106
107
  case 'CANCELLED':
107
108
  case 'CANCELED':
108
109
  case 'NOT_PROCESSED':
109
110
  this.labelClass = 'error'
110
111
  break
112
+ case 'PENDING_REJECT':
113
+ this.labelClass = 'warn'
114
+ break
111
115
  case 'PASSED_ALONG':
112
116
  case 'ENVIADA':
113
117
  case 'NAO_ENVIADA':