Corrected replace all
This commit is contained in:
parent
dcfc625408
commit
c254f2c93a
|
@ -151,7 +151,7 @@ class SearchView extends Component {
|
||||||
find: this.searchbar.query
|
find: this.searchbar.query
|
||||||
};
|
};
|
||||||
|
|
||||||
if (searchOptions.usereplace) {
|
if (searchOptions.usereplace || searchOptions.isReplaceAll) {
|
||||||
params.replace = this.$replace.val();
|
params.replace = this.$replace.val();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -100,7 +100,7 @@ const Search = withTranslation()(props => {
|
||||||
const api = Common.EditorApi.get();
|
const api = Common.EditorApi.get();
|
||||||
|
|
||||||
if (params.find && params.find.length) {
|
if (params.find && params.find.length) {
|
||||||
api.asc_replaceText(params.find, params.replace, false, params.caseSensitive, params.highlight);
|
api.asc_replaceText(params.find, params.replace || '', false, params.caseSensitive, params.highlight);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -108,7 +108,7 @@ const Search = withTranslation()(props => {
|
||||||
const api = Common.EditorApi.get();
|
const api = Common.EditorApi.get();
|
||||||
|
|
||||||
if (params.find && params.find.length) {
|
if (params.find && params.find.length) {
|
||||||
api.asc_replaceText(params.find, params.replace, true, params.caseSensitive, params.highlight);
|
api.asc_replaceText(params.find, params.replace || '', true, params.caseSensitive, params.highlight);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -82,7 +82,7 @@ const Search = withTranslation()(props => {
|
||||||
const api = Common.EditorApi.get();
|
const api = Common.EditorApi.get();
|
||||||
|
|
||||||
if (params.find && params.find.length) {
|
if (params.find && params.find.length) {
|
||||||
api.asc_replaceText(params.find, params.replace, false, params.caseSensitive);
|
api.asc_replaceText(params.find, params.replace || '', false, params.caseSensitive);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -90,7 +90,7 @@ const Search = withTranslation()(props => {
|
||||||
const api = Common.EditorApi.get();
|
const api = Common.EditorApi.get();
|
||||||
|
|
||||||
if (params.find && params.find.length) {
|
if (params.find && params.find.length) {
|
||||||
api.asc_replaceText(params.find, params.replace, true, params.caseSensitive);
|
api.asc_replaceText(params.find, params.replace || '', true, params.caseSensitive);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -167,7 +167,7 @@ const Search = withTranslation()(props => {
|
||||||
let options = new Asc.asc_CFindOptions();
|
let options = new Asc.asc_CFindOptions();
|
||||||
|
|
||||||
options.asc_setFindWhat(params.find);
|
options.asc_setFindWhat(params.find);
|
||||||
options.asc_setReplaceWith(params.replace);
|
options.asc_setReplaceWith(params.replace || '');
|
||||||
options.asc_setIsMatchCase(params.caseSensitive);
|
options.asc_setIsMatchCase(params.caseSensitive);
|
||||||
options.asc_setIsWholeCell(params.matchCell);
|
options.asc_setIsWholeCell(params.matchCell);
|
||||||
options.asc_setScanOnOnlySheet(searchIn);
|
options.asc_setScanOnOnlySheet(searchIn);
|
||||||
|
@ -191,7 +191,7 @@ const Search = withTranslation()(props => {
|
||||||
let options = new Asc.asc_CFindOptions();
|
let options = new Asc.asc_CFindOptions();
|
||||||
|
|
||||||
options.asc_setFindWhat(params.find);
|
options.asc_setFindWhat(params.find);
|
||||||
options.asc_setReplaceWith(params.replace);
|
options.asc_setReplaceWith(params.replace || '');
|
||||||
options.asc_setIsMatchCase(params.caseSensitive);
|
options.asc_setIsMatchCase(params.caseSensitive);
|
||||||
options.asc_setIsWholeCell(params.matchCell);
|
options.asc_setIsWholeCell(params.matchCell);
|
||||||
options.asc_setScanOnOnlySheet(searchIn);
|
options.asc_setScanOnOnlySheet(searchIn);
|
||||||
|
|
Loading…
Reference in a new issue