From eed0938b23d13ec4f2ef4588ccdb2e7abc0c1552 Mon Sep 17 00:00:00 2001 From: Ralph Amissah Date: Sun, 29 Mar 2020 18:29:44 -0400 Subject: 0.10.0 search sqlite & cgi --- src/doc_reform/io_out/hub.d | 26 +++++++++++++++++++++++--- 1 file changed, 23 insertions(+), 3 deletions(-) (limited to 'src/doc_reform/io_out/hub.d') diff --git a/src/doc_reform/io_out/hub.d b/src/doc_reform/io_out/hub.d index 548cceb..50ee897 100644 --- a/src/doc_reform/io_out/hub.d +++ b/src/doc_reform/io_out/hub.d @@ -7,7 +7,6 @@ template outputHub() { import doc_reform.io_out, doc_reform.io_out.metadata, doc_reform.io_out.xmls, - doc_reform.io_out.odt, doc_reform.io_out.create_zip_file, doc_reform.io_out.paths_output; @system void outputHub(D,I)( @@ -114,10 +113,9 @@ template outputHubOp() { import doc_reform.io_out, doc_reform.io_out.metadata, doc_reform.io_out.xmls, - doc_reform.io_out.odt, doc_reform.io_out.create_zip_file, doc_reform.io_out.paths_output; - @system void outputHubOp(E,O)(E env, O opt_action) { + @system void outputHubOp(E,O,M)(E env, O opt_action, M make_and_meta_struct) { mixin spineRgxOut; static auto rgx = RgxO(); if ((opt_action.sqlite_db_drop)) { @@ -132,6 +130,7 @@ template outputHubOp() { } if ((opt_action.sqlite_db_create)) { if ((opt_action.verbose)) { + auto pth_sqlite_db = spinePathsSQLite!()(opt_action.cgi_sqlite_search_filename, opt_action.output_dir_set); writeln("sqlite create table..."); } import doc_reform.io_out.sqlite; @@ -140,5 +139,26 @@ template outputHubOp() { writeln("sqlite create table done"); } } + if ((opt_action.cgi_search_form_codegen)) { + if ((opt_action.verbose)) { + string _sqlite_db_fn = (opt_action.sqlite_filename.empty) + ? make_and_meta_struct.conf.w_srv_db_sqlite + : opt_action.sqlite_filename; + string _cgi_search_script = (opt_action.cgi_sqlite_search_filename.empty) + ? make_and_meta_struct.conf.w_srv_cgi_search_script + : opt_action.cgi_sqlite_search_filename; + string _cgi_search_script_raw_fn_d = (opt_action.cgi_sqlite_search_filename_d.empty) + ? make_and_meta_struct.conf.w_srv_cgi_search_script_raw_fn_d + : opt_action.cgi_sqlite_search_filename_d; + auto pth_sqlite_cgi = spinePathsSQLiteCGI!()(_cgi_search_script_raw_fn_d, _cgi_search_script, opt_action.output_dir_set); + writeln("sqlite cgi search form..."); + writeln(" ", pth_sqlite_cgi.search_form_path_out); + } + import doc_reform.io_out.cgi_sqlite_search_form; + CGIsearchSQLite!()(env, opt_action, make_and_meta_struct); + if ((opt_action.very_verbose)) { + writeln("sqlite cgi search form done"); + } + } } } -- cgit v1.2.3