dever 4 yıl önce
ebeveyn
işleme
659cda06a7
1 değiştirilmiş dosya ile 11 ekleme ve 1 silme
  1. 11 1
      src/Database.php

+ 11 - 1
src/Database.php

@@ -2151,7 +2151,17 @@ class Database
                                     $m = 'group';
                                 }
 
-                                $show = Html::$m($vi, 'form-list', '', 'style="min-width: 100px;" data-old="'.$show.'" onchange="update($(this), \'' . $v['id'] . '\', \'' . $this->project . '\', \'' . $this->table . '\')"');
+                                $show_edit = $this->value($vi['edit'], $data[$k], $config['struct']);
+                                if ($show_edit) {
+                                    $show = Html::$m($vi, 'form-list', '', 'style="min-width: 100px;" data-old="'.$show.'" onchange="update($(this), \'' . $v['id'] . '\', \'' . $this->project . '\', \'' . $this->table . '\')"');
+                                } else {
+                                    if (isset($vi['option'][$show]) && is_array($vi['option'][$show])) {
+                                        $show = $vi['option'][$show]['name'];
+                                    } else {
+                                        $show = isset($vi['option'][$show]) ? $vi['option'][$show] : $show;
+                                    }
+                                }
+
                             } else {
                                 if (strstr($show, ',')) {
                                     $temp = explode(',', $show);