adminforth 1.7.0-next.15 → 1.7.0-next.16

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.
@@ -213,7 +213,7 @@ const removeClickListener = () => {
213
213
 
214
214
  const toogleItem = (item) => {
215
215
  if (selectedItems.value.includes(item)) {
216
- selectedItems.value = selectedItems.value.filter(i => i !== item);
216
+ selectedItems.value = selectedItems.value.filter(i => i.value !== item.value);
217
217
  } else {
218
218
  if (!props.multiple) {
219
219
  selectedItems.value = [item];
@@ -252,8 +252,10 @@ const columnOptions = computedAsync(async () => {
252
252
  offset: 0,
253
253
  },
254
254
  });
255
- console.log(`columnOptions for ${column.name}: ${JSON.stringify(list.items, null, 2)}`);
256
- return { [column.name]: [...list.items, { value: null, label: t('Unset')}] };
255
+
256
+ if (!column.required[props.source]) list.items.push({ value: null, label: t('Unset') });
257
+
258
+ return { [column.name]: list.items };
257
259
  }
258
260
  })
259
261
  )).reduce((acc, val) => Object.assign(acc, val), {})
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "adminforth",
3
- "version": "1.7.0-next.15",
3
+ "version": "1.7.0-next.16",
4
4
  "description": "OpenSource Vue3 powered forth-generation admin panel",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.js",