From 33b94cc15e25dedcc6fb93d00942b97823090a4b Mon Sep 17 00:00:00 2001 From: Ralph Amissah Date: Sun, 28 Sep 2014 21:46:45 -0400 Subject: v5 v6: sql, clean searchable text * update for (ao/dal) text representation, fix legacy action --- lib/sisu/v5/db_import.rb | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) (limited to 'lib/sisu/v5/db_import.rb') diff --git a/lib/sisu/v5/db_import.rb b/lib/sisu/v5/db_import.rb index a7f33939..8a500f8a 100644 --- a/lib/sisu/v5/db_import.rb +++ b/lib/sisu/v5/db_import.rb @@ -292,7 +292,7 @@ module SiSU_DbImport src=txt_arr.join("\n") src=special_character_escape(src) @tp[:sisutxt_f],@tp[:sisutxt_i]='sisutxt, ',"'#{src}', " - txt=clean_searchable_text(txt_arr) + txt=clean_searchable_text_from_document_source(txt_arr) #txt=special_character_escape(txt) @tp[:fulltxt_f],@tp[:fulltxt_i]='fulltxt, ',"'#{txt}', " end @@ -374,9 +374,9 @@ module SiSU_DbImport @col[:body]=special_character_escape(body) plaintext=@col[:body].dup plaintext=strip_markup(plaintext) - @col[:plaintext]=clean_searchable_text(plaintext) + @col[:plaintext]=clean_searchable_text_from_document_objects(plaintext) book_idx=book_idx_hash_to_str(data.idx) - @col[:book_idx]=clean_searchable_text(book_idx) + @col[:book_idx]=clean_searchable_text_from_document_objects(book_idx) if @en[0] then @en_a,@en_z=@en[0].first,@en[0].last end if @en_ast[0] then @en_a_asterisk,@en_z_asterisk=@en_ast[0].first,@en_ast[0].last @@ -425,9 +425,9 @@ module SiSU_DbImport @col[:body]=special_character_escape(body) plaintext=@col[:body].dup plaintext=strip_markup(plaintext) - @col[:plaintext]=clean_searchable_text(plaintext) + @col[:plaintext]=clean_searchable_text_from_document_objects(plaintext) book_idx=book_idx_hash_to_str(data.idx) - @col[:book_idx]=clean_searchable_text(book_idx) + @col[:book_idx]=clean_searchable_text_from_document_objects(book_idx) @en_a,@en_z=@en[0].first,@en[0].last if @en[0] @en_a_asterisk,@en_z_asterisk=@en_ast[0].first,@en_ast[0].last if @en_ast[0] @en_a_plus,@en_z_plus=@en_pls[0].first,@en_pls[0].last if @en_pls[0] @@ -470,9 +470,9 @@ module SiSU_DbImport @col[:body]=special_character_escape(body) plaintext=@col[:body].dup plaintext=strip_markup(plaintext) - @col[:plaintext]=clean_searchable_text(plaintext) + @col[:plaintext]=clean_searchable_text_from_document_objects(plaintext) book_idx=book_idx_hash_to_str(data.idx) - @col[:book_idx]=clean_searchable_text(book_idx) + @col[:book_idx]=clean_searchable_text_from_document_objects(book_idx) @en_a,@en_z=@en[0].first,@en[0].last if @en[0] @en_a_asterisk,@en_z_asterisk=@en_ast[0].first,@en_ast[0].last if @en_ast[0] @en_a_plus,@en_z_plus=@en_pls[0].first,@en_pls[0].last if @en_pls[0] @@ -501,9 +501,9 @@ module SiSU_DbImport @col[:body]=special_character_escape(body) plaintext=@col[:body].dup plaintext=strip_markup(plaintext) - @col[:plaintext]=clean_searchable_text(plaintext) + @col[:plaintext]=clean_searchable_text_from_document_objects(plaintext) book_idx=book_idx_hash_to_str(data.idx) - @col[:book_idx]=clean_searchable_text(book_idx) + @col[:book_idx]=clean_searchable_text_from_document_objects(book_idx) @en_a,@en_z=@en[0].first,@en[0].last if @en[0] @en_a_asterisk,@en_z_asterisk=@en_ast[0].first,@en_ast[0].last if @en_ast[0] @en_a_plus,@en_z_plus=@en_pls[0].first,@en_pls[0].last if @en_pls[0] @@ -532,9 +532,9 @@ module SiSU_DbImport @col[:body]=special_character_escape(body) plaintext=@col[:body].dup plaintext=strip_markup(plaintext) - @col[:plaintext]=clean_searchable_text(plaintext) + @col[:plaintext]=clean_searchable_text_from_document_objects(plaintext) book_idx=book_idx_hash_to_str(data.idx) - @col[:book_idx]=clean_searchable_text(book_idx) + @col[:book_idx]=clean_searchable_text_from_document_objects(book_idx) @en_a,@en_z=@en[0].first,@en[0].last if @en[0] @en_a_asterisk,@en_z_asterisk=@en_ast[0].first,@en_ast[0].last if @en_ast[0] @en_a_plus,@en_z_plus=@en_pls[0].first,@en_pls[0].last if @en_pls[0] @@ -603,9 +603,9 @@ module SiSU_DbImport @col[:body]=special_character_escape(body) plaintext=@col[:body].dup plaintext=strip_markup(plaintext) - @col[:plaintext]=clean_searchable_text(plaintext) + @col[:plaintext]=clean_searchable_text_from_document_objects(plaintext) book_idx=book_idx_hash_to_str(data.idx) - @col[:book_idx]=clean_searchable_text(book_idx) + @col[:book_idx]=clean_searchable_text_from_document_objects(book_idx) t=SiSU_DbTuple::LoadDocuments.new(@conn,@col,@opt,@file_maint) @tuple_array << t.tuple @en,@en_ast,@en_pls=[],[],[] -- cgit v1.2.3