This commit is contained in:
parent
317e84dd7b
commit
7820165939
1 changed files with 15 additions and 15 deletions
|
@ -133,21 +133,21 @@ export const setColOption = (protyle: IProtyle, data: IAV, target: HTMLElement,
|
|||
if (name === inputElement.value || !inputElement.value) {
|
||||
return;
|
||||
}
|
||||
let hasName = false;
|
||||
data.view.columns.find(column => {
|
||||
if (column.id === colId) {
|
||||
column.options.find((item) => {
|
||||
if (item.name === inputElement.value) {
|
||||
hasName = true;
|
||||
return true;
|
||||
}
|
||||
});
|
||||
return true;
|
||||
}
|
||||
});
|
||||
if (hasName) {
|
||||
return;
|
||||
}
|
||||
// let hasName = false;
|
||||
// data.view.columns.find(column => {
|
||||
// if (column.id === colId) {
|
||||
// column.options.find((item) => {
|
||||
// if (item.name === inputElement.value) {
|
||||
// hasName = true;
|
||||
// return true;
|
||||
// }
|
||||
// });
|
||||
// return true;
|
||||
// }
|
||||
// });
|
||||
// if (hasName) {
|
||||
// return;
|
||||
// }
|
||||
transaction(protyle, [{
|
||||
action: "updateAttrViewColOption",
|
||||
id: colId,
|
||||
|
|
Loading…
Add table
Reference in a new issue