public function overwriteForm($return, $returnfull)
 {
     $return = parent::overwriteForm($return, $returnfull);
     //        if ($this->image_logo == "") {
     //            $this->image_logo = "noimage.jpg";
     //        }
     //        $return['image_logo'] = new InputFotoMR("foto", "image_logo", $this->image_logo);
     $return['image_logo'] = new \Leap\View\InputFotoCropperPop("1:1", "image_logo", "image_logo", $this->image_logo);
     if (!isset($this->time_open)) {
         $dt = leap_mysqldate();
     } else {
         $dt = $this->time_open;
     }
     $return['time_open'] = new \Leap\View\InputText("time", "time_open", "time_open", $dt);
     if (!isset($this->time_close)) {
         $dt = leap_mysqldate();
     } else {
         $dt = $this->time_close;
     }
     $return['time_close'] = new \Leap\View\InputText("time", "time_close", "time_close", $dt);
     $return['halal'] = new Leap\View\InputSelect(array("1" => "Yes", "0" => "No"), "halal", "halal", $this->status);
     $return['aktiv'] = new Leap\View\InputSelect(array("1" => "Yes", "0" => "No"), "aktiv", "aktiv", $this->aktiv);
     $return['menu_status'] = new Leap\View\InputSelect(array("1" => "Active", "0" => "Inactive"), "menu_status", "menu_status", $this->menu_status);
     $return['menu_status']->setReadOnly();
     $return['address'] = new \Leap\View\InputMap('address' . time(), 'latitude', 'longitude', $this->latitude, $this->longitude, 'address', $this->address);
     $return['district'] = new \Leap\View\InputText("text", "district" . time(), "district", $this->district);
     $return['district']->setReadOnly();
     $return['city'] = new \Leap\View\InputText("text", "city" . time(), "city", $this->city);
     $return['city']->setReadOnly();
     $return['latitude'] = new \Leap\View\InputText("text", "latitude" . time(), "latitude", $this->latitude);
     $return['latitude']->setReadOnly();
     $return['longitude'] = new \Leap\View\InputText("text", "longitude" . time(), "longitude", $this->longitude);
     $return['longitude']->setReadOnly();
     $ca = new MasterCategoryModel();
     $arr = $ca->getWhere("status='1'");
     $arrCats = array();
     foreach ($arr as $cat) {
         $arrCats[$cat->id_category] = $cat->name;
     }
     $return['id_categories'] = new \Leap\View\InputMultiTablet($arrCats, "id_categories", "id_categories", $this->id_categories);
     $rt = new MasterRestaurantTagModel();
     $arr = $rt->getAll();
     $arrTags = array();
     foreach ($arr as $tag) {
         $arrTags[$tag->id_tag] = $tag->tag_name;
     }
     //        $return['restaurant_tags'] = new \Leap\View\InputMultiTablet($arrTags, "restaurant_tags", "restaurant_tags", $this->restaurant_tags);
     $return['restaurant_tags'] = new \Leap\View\InputText("hidden", "restaurant_tags", "restaurant_tags", $this->restaurant_tags);
     $return['fav'] = new \Leap\View\InputText("text", "fav", "fav", $this->fav);
     $return['fav']->setReadOnly();
     $return['id_set_tables'] = new \Leap\View\InputText("text", "id_set_tables", "id_set_tables", $this->id_set_tables);
     $return['id_set_tables']->setReadOnly();
     if ($return['id_set_tables']->value == 0) {
         $return['id_set_tables']->value = "Active";
     }
     global $db;
     $q = "SELECT id_restaurant_type, name FROM menurevo__ms_restaurant_type WHERE 1";
     $res = $db->query($q, 2);
     foreach ($res as $value) {
         $arrHelp[$value->id_restaurant_type] = $value->name;
     }
     $return['restaurant_type'] = new Leap\View\InputSelect($arrHelp, "restaurant_type", "restaurant_type", $this->restaurant_type);
     // Cuisine
     $q = "SELECT id_cuisine, name_cuisine FROM menurevo__cuisine WHERE 1";
     $res = $db->query($q, 2);
     foreach ($res as $value) {
         $arrHelp[$value->id_cuisine] = $value->name_cuisine;
     }
     $return['id_cuisine'] = new Leap\View\InputSelect($arrHelp, "id_cuisine", "id_cuisine", $this->id_cuisine);
     $return['service_charge'] = new \Leap\View\InputTextRightAddOn("text", "service_charge", "service_charge", " % ", $this->service_charge);
     $return['tax_pb_1'] = new \Leap\View\InputTextRightAddOn("text", "tax_pb_1", "tax_pb_1", " % ", $this->tax_pb_1);
     $return['disc_resto'] = new \Leap\View\InputTextRightAddOn("text", "disc_resto", "disc_resto", " % ", $this->disc_resto);
     $return['new_set_table'] = new Leap\View\InputSelect(array("1" => "Yes", "0" => "No"), "new_set_table", "new_set_table", $this->new_set_table);
     $return['new_set_table']->setReadOnly();
     $return['table_quantity'] = new \Leap\View\InputText("text", "table_quantity", "table_quantity", $this->table_quantity);
     $return['table_quantity']->setReadOnly();
     $return['table_column'] = new \Leap\View\InputText("text", "table_column", "table_column", $this->table_column);
     $return['table_column']->setReadOnly();
     $return['layout_type'] = new Leap\View\InputSelect(array("1" => "Type 1", "2" => "Type 2"), "layout_type", "layout_type", $this->layout_type);
     $return['order_number'] = new \Leap\View\InputText("text", "order_number", "order_number", $this->order_number);
     $return['order_number']->setReadOnly();
     $return['now_open'] = new Leap\View\InputSelect(array("1" => "Yes", "0" => "No"), "now_open", "now_open", $this->now_open);
     $return['show_in_apps'] = new Leap\View\InputSelect(array("1" => "Yes", "0" => "No"), "show_in_apps", "show_in_apps", $this->show_in_apps);
     return $return;
 }