diff --git a/.gitignore b/.gitignore
index 8c55e8cb..c5759016 100755
--- a/.gitignore
+++ b/.gitignore
@@ -15,3 +15,4 @@ config/sysconfig.local.inc.php
sysconfig.inc.php
slims8_akasia.sublime-project
slims8_akasia.sublime-workspace
+Thumbs.db
\ No newline at end of file
diff --git a/admin/AJAX_vocabolary_control.php b/admin/AJAX_vocabolary_control.php
index c37620df..5d2d7551 100755
--- a/admin/AJAX_vocabolary_control.php
+++ b/admin/AJAX_vocabolary_control.php
@@ -94,15 +94,23 @@
$output = '
';
$output .= ''.$row[1].(isset($row[2])?' - '.$row[2]:'').(isset($row[3])?' - '.$row[3]:'');
- $output .= '';
+ $output .= '';
+ $li = '';
+ $scope = '';
- $voc_q = $dbs->query('SELECT rt_id, related_topic_id FROM mst_voc_ctrl WHERE topic_id='.$row[0]);
+ $voc_q = $dbs->query('SELECT rt_id, related_topic_id, scope FROM mst_voc_ctrl WHERE topic_id='.$row[0]);
while ($voc_d = $voc_q->fetch_row()) {
- $topic_q = $dbs->query('SELECT topic FROM mst_topic WHERE topic_id='.$voc_d[1]);
- $topic_d = $topic_q->fetch_row();
- $output .= '- '.$voc_d[0].''.$topic_d[0].'
';
+ if (is_null($voc_d[2])) {
+ $topic_q = $dbs->query('SELECT topic, topic_type FROM mst_topic WHERE topic_id='.$voc_d[1]);
+ $topic_d = $topic_q->fetch_row();
+ $li .= '- '.__($voc_d[0]).''.$topic_d[0].' - '.$topic_d[1].'
';
+ } else {
+ $scope = $voc_d[2];
+ }
}
+ $output .= $scope.$li;
+
$output .= '
';
$output .= '
';
diff --git a/admin/modules/master_file/iframe_vocabolary_control.php b/admin/modules/master_file/iframe_vocabolary_control.php
index 2d8ea156..e2f65315 100755
--- a/admin/modules/master_file/iframe_vocabolary_control.php
+++ b/admin/modules/master_file/iframe_vocabolary_control.php
@@ -55,26 +55,32 @@ function confirmProcess(topic_id, vocabolary_id)
$row = 1;
while ($voc_d = $voc_q->fetch_assoc()) {
-
- // fallback related topic id
- $topic_q = $dbs->query('SELECT topic FROM mst_topic WHERE topic_id='.$voc_d['related_topic_id']);
- $topic_d = $topic_q->fetch_row();
- // alternate the row color
- $row_class = ($row%2 == 0)?'alterCell':'alterCell2';
+ if (!is_null($voc_d['scope'])) {
+ echo 'Scope note: '.$voc_d['scope'].'
';
+ }
+
+ if (is_null($voc_d['scope'])) {
+ // fallback related topic id
+ $topic_q = $dbs->query('SELECT topic FROM mst_topic WHERE topic_id='.$voc_d['related_topic_id']);
+ $topic_d = $topic_q->fetch_row();
- // links
- $edit_link = '';
- $remove_link = '';
- $related_term = $voc_d['rt_id'];
+ // alternate the row color
+ $row_class = ($row%2 == 0)?'alterCell':'alterCell2';
- $table->appendTableRow(array($remove_link, $edit_link, $related_term, $topic_d[0]));
- $table->setCellAttr($row, null, 'valign="top" class="'.$row_class.'" style="font-weight: bold; width: auto;"');
- $table->setCellAttr($row, 0, 'valign="top" class="'.$row_class.'" style="font-weight: bold; width: 5%;"');
- $table->setCellAttr($row, 1, 'valign="top" class="'.$row_class.'" style="font-weight: bold; width: 5%;"');
- $table->setCellAttr($row, 2, 'valign="top" class="'.$row_class.'" style="font-weight: bold; width: 8%;"');
+ // links
+ $edit_link = '';
+ $remove_link = '';
+ $related_term = $voc_d['rt_id'];
- $row++;
+ $table->appendTableRow(array($remove_link, $edit_link, $related_term, $topic_d[0]));
+ $table->setCellAttr($row, null, 'valign="top" class="'.$row_class.'" style="font-weight: bold; width: auto;"');
+ $table->setCellAttr($row, 0, 'valign="top" class="'.$row_class.'" style="font-weight: bold; width: 5%;"');
+ $table->setCellAttr($row, 1, 'valign="top" class="'.$row_class.'" style="font-weight: bold; width: 5%;"');
+ $table->setCellAttr($row, 2, 'valign="top" class="'.$row_class.'" style="font-weight: bold; width: 8%;"');
+
+ $row++;
+ }
}
echo $table->printTable();
// hidden form
diff --git a/admin/modules/master_file/pop_scope_vocabolary.php b/admin/modules/master_file/pop_scope_vocabolary.php
new file mode 100644
index 00000000..18737865
--- /dev/null
+++ b/admin/modules/master_file/pop_scope_vocabolary.php
@@ -0,0 +1,111 @@
+escape_string(strip_tags($_POST['scope'])));
+
+ # create new sql op object
+ $sql_op = new simbio_dbop($dbs);
+
+ if (!empty($_POST['vocabolary_id'])) {
+ // do update
+ $save = $sql_op->update('mst_voc_ctrl', $data, 'vocabolary_id='.$_POST['vocabolary_id']);
+ } else {
+ // insert
+ $save = $sql_op->insert('mst_voc_ctrl', $data);
+ }
+
+ if (isset($_POST['delete'])) {
+ # create new sql op object
+ $save = $sql_op->delete('mst_voc_ctrl', 'vocabolary_id='.$_POST['vocabolary_id']);
+ }
+
+ if ($save) {
+ $alert_save = '';
+ echo $alert_save;
+ } else {
+ utility::jsAlert('Failed save data!');
+ }
+}
+
+// start buffer
+ob_start();
+
+// query scope
+$scope_q = $dbs->query('SELECT scope, vocabolary_id FROM mst_voc_ctrl WHERE topic_id='.$itemID.' AND scope IS NOT NULL');
+$scope_d = $scope_q->fetch_row();
+
+$page_title = 'Scope Note Vocabulary';
+?>
+
+
+
+
+addTextField('text', 'authList', __('Authority Files'), $rec_d['auth_list'], 'style="width: 30%;"');
// vocabolary control
if (!$in_pop_up AND $form->edit_mode) {
- $str_input = '';
+ $str_input = '';
+ $str_input .= '';
+ $str_input .= '';
+ $str_input .= '
';
$str_input .= ''."\n";
$form->addAnything(__('Vocabulary Control'), $str_input);
}
diff --git a/js/ckeditor/skins/moono/images/Thumbs.db b/js/ckeditor/skins/moono/images/Thumbs.db
new file mode 100644
index 00000000..8b234574
Binary files /dev/null and b/js/ckeditor/skins/moono/images/Thumbs.db differ