Mercurial > hg > extraction-interface
diff develop/views/Extractapp/taggingtext.php @ 20:04db1dd9d10d
update topic_regex_relation table when saving (new) regex file
author | Zoe Hong <zhong@mpiwg-berlin.mpg.de> |
---|---|
date | Mon, 23 Feb 2015 14:34:43 +0100 |
parents | 82f8c6bd2b69 |
children | c805470cefee |
line wrap: on
line diff
--- a/develop/views/Extractapp/taggingtext.php Mon Feb 23 12:46:03 2015 +0100 +++ b/develop/views/Extractapp/taggingtext.php Mon Feb 23 14:34:43 2015 +0100 @@ -101,6 +101,18 @@ }); */ + // Popup choosing topic if first time to this section. without branchId + var info = JSON.parse('<?php echo json_encode($info) ?>'); + if (info['file_id'] == 0) { // or info['branchId'] == 0, means new file + // ask to choose topic + $.ajax({ + + }); + var popup = document.getElementById('popup-window'); + + // alert('choose topic!'); + }; + }); $(document).on("click", "name", function (e) { @@ -476,6 +488,8 @@ </script> +<div id="popup-window" style="display: none; background-color:white; height:300px; width:300px; margin:200 0 0 200;position:fixed; z-index:2"> +</div> <div class="container-fluid"> <div class="row"> @@ -536,7 +550,7 @@ Range: <input type="text" size="5" id="regexPageStart">to<input type="text" size="5" id="regexPageEnd"><br> <button onclick="replaceSmartRun()" style="height: 30px; width: 220px">Run</button></br> <button onclick="replaceSmartRunSpace()" style="height: 30px; width: 220px">Run(Allow space between Group)</button></br> - <button onclick="smartRegexSave()" style="height: 30px; width: 70px">Save</button> + <button onclick="smartRegexSave(<?php echo $default_topic_id; ?>)" style="height: 30px; width: 70px">Save</button> <button onclick="smartRegexLoad(<?php echo $default_topic_id; ?>)" style="height: 30px; width: 70px">Load</button> <button onclick="smartRegexEmpty()" style="height: 30px; width: 70px">Clear</button></br> <!--