monkey-front-components 0.0.432 → 0.0.433
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/esm2020/lib/components/shared/filter/menu/menu.component.mjs +36 -19
- package/fesm2015/monkey-front-components.mjs +36 -18
- package/fesm2015/monkey-front-components.mjs.map +1 -1
- package/fesm2020/monkey-front-components.mjs +35 -18
- package/fesm2020/monkey-front-components.mjs.map +1 -1
- package/monkey-front-components-0.0.433.tgz +0 -0
- package/package.json +1 -1
- package/monkey-front-components-0.0.432.tgz +0 -0
|
@@ -2075,6 +2075,9 @@ class MECXFilterMenuComponent {
|
|
|
2075
2075
|
}
|
|
2076
2076
|
catch (e) {
|
|
2077
2077
|
// not to do
|
|
2078
|
+
console.log('=====3');
|
|
2079
|
+
console.log(e);
|
|
2080
|
+
console.log(value);
|
|
2078
2081
|
}
|
|
2079
2082
|
return false;
|
|
2080
2083
|
}
|
|
@@ -2111,30 +2114,44 @@ class MECXFilterMenuComponent {
|
|
|
2111
2114
|
});
|
|
2112
2115
|
}
|
|
2113
2116
|
ngOnChanges(changes) {
|
|
2114
|
-
|
|
2115
|
-
|
|
2116
|
-
|
|
2117
|
-
|
|
2117
|
+
try {
|
|
2118
|
+
if (changes.model) {
|
|
2119
|
+
const { currentValue } = changes.model;
|
|
2120
|
+
if (currentValue && JSON.stringify(currentValue) !== '{}') {
|
|
2121
|
+
this.onHandleMenus(currentValue);
|
|
2122
|
+
}
|
|
2118
2123
|
}
|
|
2119
2124
|
}
|
|
2125
|
+
catch (e) {
|
|
2126
|
+
console.log('=====4');
|
|
2127
|
+
console.log(e);
|
|
2128
|
+
console.log(changes?.model?.currentValue);
|
|
2129
|
+
}
|
|
2120
2130
|
}
|
|
2121
2131
|
onHandleChildrenAction(option, child) {
|
|
2122
|
-
|
|
2123
|
-
|
|
2124
|
-
|
|
2125
|
-
[option.field]: JSON.stringify({
|
|
2126
|
-
[field]: action()
|
|
2127
|
-
})
|
|
2128
|
-
});
|
|
2129
|
-
}
|
|
2130
|
-
else {
|
|
2131
|
-
this._showMenu = true;
|
|
2132
|
-
this._menuOption = child;
|
|
2133
|
-
this.onHandleSubmit = (event) => {
|
|
2132
|
+
try {
|
|
2133
|
+
const { field, type, action } = child;
|
|
2134
|
+
if (type === 'with-action') {
|
|
2134
2135
|
this.onHandleSubmitValue({
|
|
2135
|
-
[option.field]: JSON.stringify(
|
|
2136
|
+
[option.field]: JSON.stringify({
|
|
2137
|
+
[field]: action()
|
|
2138
|
+
})
|
|
2136
2139
|
});
|
|
2137
|
-
}
|
|
2140
|
+
}
|
|
2141
|
+
else {
|
|
2142
|
+
this._showMenu = true;
|
|
2143
|
+
this._menuOption = child;
|
|
2144
|
+
this.onHandleSubmit = (event) => {
|
|
2145
|
+
this.onHandleSubmitValue({
|
|
2146
|
+
[option.field]: JSON.stringify(event)
|
|
2147
|
+
});
|
|
2148
|
+
};
|
|
2149
|
+
}
|
|
2150
|
+
}
|
|
2151
|
+
catch (e) {
|
|
2152
|
+
console.log('=====5');
|
|
2153
|
+
console.log(e);
|
|
2154
|
+
console.log(child);
|
|
2138
2155
|
}
|
|
2139
2156
|
}
|
|
2140
2157
|
onHandleShowMenu(option) {
|