|
@@ -318,12 +318,20 @@
|
|
|
return out;
|
|
return out;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
+ // The owner dropdown used to be a plain <select>, but Phase 10 replaced
|
|
|
|
|
+ // it with a checkbox multi-filter. We now scrape the real source of
|
|
|
|
|
+ // truth: the [data-owner-filter-opt] inputs, skipping the special
|
|
|
|
|
+ // "__none__" entry. Empty list → new task rows get an empty dropdown,
|
|
|
|
|
+ // which was the symptom the user hit after Phase 10 landed.
|
|
|
function ownerChoices() {
|
|
function ownerChoices() {
|
|
|
const out = [];
|
|
const out = [];
|
|
|
- $root.find('[data-owner-filter] option').each(function () {
|
|
|
|
|
- const v = $(this).val();
|
|
|
|
|
|
|
+ $root.find('[data-owner-filter-opt]').each(function () {
|
|
|
|
|
+ const v = String($(this).val());
|
|
|
if (v === '' || v === '__none__') { return; }
|
|
if (v === '' || v === '__none__') { return; }
|
|
|
- out.push({ id: parseInt(String(v), 10), name: String($(this).text()).trim() });
|
|
|
|
|
|
|
+ const id = parseInt(v, 10);
|
|
|
|
|
+ if (!Number.isFinite(id)) { return; }
|
|
|
|
|
+ const name = String($(this).closest('label').find('span').text()).trim();
|
|
|
|
|
+ out.push({ id: id, name: name });
|
|
|
});
|
|
});
|
|
|
return out;
|
|
return out;
|
|
|
}
|
|
}
|