feat(item): add filterParams in main
gitea/salix/pipeline/head This commit looks good
Details
gitea/salix/pipeline/head This commit looks good
Details
This commit is contained in:
parent
26815ad5a3
commit
b59cabe41a
|
@ -1,16 +1,19 @@
|
||||||
<vn-crud-model
|
<vn-crud-model
|
||||||
vn-id="model"
|
vn-id="model"
|
||||||
url="Items/filter"
|
url="Items/filter"
|
||||||
|
user-params="::$ctrl.filterParams"
|
||||||
limit="12"
|
limit="12"
|
||||||
order="isActive DESC, name, id"
|
order="isActive DESC, name, id"
|
||||||
data="items">
|
data="items"
|
||||||
|
auto-load="true">
|
||||||
</vn-crud-model>
|
</vn-crud-model>
|
||||||
<vn-portal slot="topbar">
|
<vn-portal slot="topbar">
|
||||||
<vn-searchbar
|
<vn-searchbar
|
||||||
vn-focus
|
vn-focus
|
||||||
panel="vn-item-search-panel"
|
panel="vn-item-search-panel"
|
||||||
info="Search items by id, name or barcode"
|
info="Search items by id, name or barcode"
|
||||||
suggested-filter="{isActive: true}"
|
suggested-filter="$ctrl.filterParams"
|
||||||
|
filter="$ctrl.filterParams"
|
||||||
model="model">
|
model="model">
|
||||||
</vn-searchbar>
|
</vn-searchbar>
|
||||||
</vn-portal>
|
</vn-portal>
|
||||||
|
|
|
@ -1,7 +1,15 @@
|
||||||
import ngModule from '../module';
|
import ngModule from '../module';
|
||||||
import ModuleMain from 'salix/components/module-main';
|
import ModuleMain from 'salix/components/module-main';
|
||||||
|
export default class Items extends ModuleMain {
|
||||||
|
constructor($element, $) {
|
||||||
|
super($element, $);
|
||||||
|
|
||||||
export default class Items extends ModuleMain {}
|
this.filterParams = {
|
||||||
|
isActive: true,
|
||||||
|
isFloramondo: false
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
ngModule.vnComponent('vnItems', {
|
ngModule.vnComponent('vnItems', {
|
||||||
controller: Items,
|
controller: Items,
|
||||||
|
|
Loading…
Reference in New Issue