public function edit($entity)
 {
     parent::edit($entity);
     // Simple code of filter and grid part.
     // List of all fields here: http://laravelpanel.com/docs/master/crud-fields
     // Pre-load the months to the select box
     $months = [null];
     for ($i = 1; $i < 13; $i++) {
         array_push($months, $i);
     }
     // Pre-load the years to the select box
     $years = [null];
     for ($i = 2000; $i < 2101; $i++) {
         array_push($years, $i);
     }
     $this->edit = \DataEdit::source(new \App\Symbols());
     $this->edit->label('Edit Symbols');
     $this->edit->add('exchange', 'Exchange', 'text');
     $this->edit->add('symbol', 'Symbol *', 'text')->rule('required');
     $this->edit->add('name', 'Name *', 'text')->rule('required');
     $this->edit->add('expire_month', 'Expire Month', 'select')->options($months);
     $this->edit->add('expire_year', 'Expire Year', 'select')->options($years);
     $this->edit->add('type', 'Type, i.e. future *', 'text')->rule('required');
     $this->edit->add('cat', 'Category *', 'text')->rule('required');
     return $this->returnEditView();
 }
Beispiel #2
0
 public function edit($entity)
 {
     $showPassword = true;
     $pass = Request::input('password');
     if (trim($pass)) {
         $new_input = array('password' => Hash::make($pass));
         Request::merge($new_input);
     } else {
         Request::merge(['password' => null]);
         if (in_array(Request::method(), ['PATCH', 'POST', 'PUT'])) {
             $showPassword = false;
         }
     }
     parent::edit($entity);
     $this->edit = \DataEdit::source(new Admin());
     $this->edit->label('Edit Admin');
     $this->edit->link("rapyd-demo/filter", "Articles", "TR")->back();
     $this->edit->add('email', 'Email', 'text')->rule('required|min:5');
     $this->edit->add('first_name', 'firstname', 'text');
     $this->edit->add('last_name', 'lastname', 'text');
     // hate to do this but the rapyd framework sucks something awful
     if ($showPassword) {
         $this->edit->add('password', 'password', 'password');
     }
     $this->edit->add('permissions', 'permissions', 'text')->rule('required');
     return $this->returnEditView();
 }
Beispiel #3
0
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\Grupos());
     $this->edit->label('Grupos');
     $this->edit->add('nome', 'Nome', 'text');
     return $this->returnEditView();
 }
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\VidCategoria());
     $this->edit->label('Edit Category');
     $this->edit->add('name', 'Nome', 'text');
     return $this->returnEditView();
 }
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\Area());
     $this->edit->label('Area');
     $this->edit->add('nombre', 'Nombre', 'text')->rule('required');
     return $this->returnEditView();
 }
Beispiel #6
0
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\Users());
     $this->edit->label('Editar redatores');
     $this->edit->add('name', 'Nome', 'text');
     return $this->returnEditView();
 }
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\Voluntario());
     $this->edit->label('Voluntário');
     $this->edit->add('name', 'Name', 'text');
     $this->edit->add('code', 'Code', 'text')->rule('required');
     return $this->returnEditView();
 }
Beispiel #8
0
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\User());
     $this->edit->label('Edit Category');
     $this->edit->add('name', 'Name', 'text');
     $this->edit->add('email', 'email', 'text')->rule('required');
     $this->edit->add('phone', 'phone', 'text')->rule('required');
     return $this->returnEditView();
 }
Beispiel #9
0
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\Slider());
     $this->edit->label('Edit Slider');
     $this->edit->add('active', 'Active', 'checkbox');
     $this->edit->add('weight', 'Weight', 'text');
     $this->edit->add('img_url', 'Image', 'file')->move('uploads/images/slider/');
     return $this->returnEditView();
 }
Beispiel #10
0
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\Video());
     $this->edit->label('Editar Videos');
     $this->edit->add('nome', 'Nome', 'text');
     $this->edit->add('description', 'Descrição', 'text');
     $this->edit->add('url', 'url', 'text');
     return $this->returnEditView();
 }
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\Gallery());
     $this->edit->label('Edit Gallery');
     $this->edit->add('title', 'Title', 'text');
     $this->edit->add('subtitle', 'Subtitle', 'text');
     $this->edit->add('image', 'Image', 'file')->rule('required');
     return $this->returnEditView();
 }
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\OpinionFinderSentiments());
     $this->edit->label('Edit OpinionFinder');
     $this->edit->add('date', 'Date', 'text')->rule('required');
     $this->edit->add('symbol_id', 'Symbol ID', 'text')->rule('required');
     $this->edit->add('polarity', 'Polarity', 'text')->rule('required');
     return $this->returnEditView();
 }
Beispiel #13
0
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\Mensagem());
     $this->edit->label('Editar Mensagem');
     $this->edit->add('nome', 'Nome', 'text')->rule('required');
     $this->edit->add('email', 'Email', 'text')->rule('required');
     $this->edit->add('bairro', 'Bairro', 'text')->rule('required');
     $this->edit->add('telefone', 'Telefone', 'text')->rule('required');
     return $this->returnEditView();
 }
Beispiel #14
0
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \Page());
     $this->edit->label('Edit Pages');
     $this->edit->add('title', 'Title', 'text')->rule('required|min:5');
     $this->edit->add('slug', 'Page url slug', 'text')->rule('required|min:5');
     $this->edit->add('content', 'Content', 'redactor');
     $this->edit->add('public', 'Public', 'checkbox');
     return $this->returnEditView();
 }
 public function edit($entity)
 {
     parent::edit($entity);
     // Simple code of  edit part , List of all fields here : http://laravelpanel.com/docs/master/crud-fields
     $this->edit = \DataEdit::source(new \App\Tweets());
     $this->edit->label('Edit Tweets');
     $this->edit->add('message_id', 'Message ID', 'text')->rule('integer|required');
     $this->edit->add('username', 'Username', 'text')->rule('required');
     $this->edit->add('body', 'Message Body', 'text')->rule('required');
     $this->edit->add('timestamp', 'Message Timestamp', 'text')->rule('required');
     return $this->returnEditView();
 }
Beispiel #16
0
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\Posts());
     $this->edit->label('Postagem');
     $this->edit->add('name', 'Nome', 'text');
     $this->edit->add('category_id', 'Categoria', 'select')->options(\App\Category::lists("name", "id")->all());
     $this->edit->add('description', 'description', 'redactor');
     $this->edit->add('date_old', 'Data fake', 'text');
     $this->edit->add('image', 'image', 'image')->move('uploads/images/')->preview(80, 80);
     return $this->returnEditView();
 }
Beispiel #17
0
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\Mark());
     $this->edit->label('Edit Category');
     $this->edit->add('address', 'Endereço', 'text');
     $this->edit->add('description', 'Descrição', 'text');
     $this->edit->add('name', 'Nome', 'text');
     $this->edit->add('email', 'E-mail', 'text');
     $this->edit->add('status', 'Status', 'text');
     return $this->returnEditView();
 }
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\People());
     $this->edit->label('Persona');
     $this->edit->text('nombre', 'Nombre')->rule('required');
     $this->edit->add('area_id', 'Area', 'select')->rule('required')->options(\App\Area::lists('nombre', 'id')->all());
     $this->edit->checkbox('destacado', 'Destacado');
     $this->edit->text('sueldo', 'Sueldo ($)')->rule('required');
     $this->edit->text('aporte', 'Aporte ($)')->rule('required');
     $this->edit->add('foto', 'Foto', 'image')->move('media/fotos/')->preview(80, 80);
     return $this->returnEditView();
 }
Beispiel #19
0
 public function edit($entity)
 {
     parent::edit($entity);
     \App\Admins::creating(function ($data) {
         $data->password = Hash::make(\Request::input('password'));
     });
     $this->edit = \DataEdit::source(new \App\Admins());
     $this->edit->label('Editar Administradores');
     $this->edit->add('first_name', 'Name', 'text');
     $this->edit->add('email', 'email', 'text')->rule('required');
     $this->edit->add('password', 'Senha', 'text')->rule('required');
     return $this->returnEditView();
 }
Beispiel #20
0
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\Comments());
     $this->edit->label('Edit Comment');
     $this->edit->add('active', 'Active', 'checkbox');
     /*its must be deleted*/
     $this->edit->add('comment_id', 'ID', 'select')->options(\App\News::lists('id', 'id')->toArray());
     $this->edit->add('name', 'Name', 'text');
     $this->edit->add('comment', 'Comment', 'text');
     /**/
     return $this->returnEditView();
 }
Beispiel #21
0
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\Posts());
     $this->edit->label('Editar Postagem');
     $this->edit->add('nome', 'Nome', 'text');
     $this->edit->add('categoria', 'Categoria', 'select')->options(\App\Categoria::lists("name", "id")->all());
     $this->edit->add('resumo', 'Resumo', 'text')->rule('required');
     $this->edit->add('foto', 'Foto', 'image')->move('img/upload/');
     $this->edit->add('descricao', 'Descrição', 'redactor')->rule('required');
     $this->edit->add('descricao2', 'Descrição 2', 'redactor')->rule('required');
     return $this->returnEditView();
 }
Beispiel #22
0
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\Blog());
     $this->edit->label('Edit Project');
     $this->edit->add('title', 'post title', 'text')->rule('required|min:3');
     $this->edit->add('author', 'author', 'text')->rule('required|min:2');
     $this->edit->add('content', 'content', 'redactor')->rule('required');
     $this->edit->add('image', 'image', 'image')->move('uploads/');
     $this->edit->add('color', 'Color', 'colorpicker');
     $this->edit->add('public', 'public', 'radiogroup')->option(0, 'Draft')->option(1, 'Ready');
     return $this->returnEditView();
 }
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\IBMWatsonSentiments());
     $this->edit->label('Edit IBM Watson Sentiments');
     $this->edit->add('date', 'Date', 'text')->rule('required');
     $this->edit->add('symbol_id', 'Symbol ID', 'text')->rule('required');
     $this->edit->add('anger', 'Anger', 'text')->rule('required');
     $this->edit->add('disgust', 'Disgust', 'text')->rule('required');
     $this->edit->add('fear', 'Fear', 'text')->rule('required');
     $this->edit->add('joy', 'Joy', 'text')->rule('required');
     $this->edit->add('sadness', 'Sadness', 'text')->rule('required');
     return $this->returnEditView();
 }
Beispiel #24
0
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\News());
     $this->edit->label('Edit News');
     $this->edit->add('active', 'Active', 'checkbox');
     $this->edit->add('title', 'Title', 'text');
     $this->edit->add('title_en', 'Title(En)', 'text');
     $this->edit->add('segment', 'Segment', 'text');
     $this->edit->add('content', 'Content', 'redactor');
     $this->edit->add('published_at', 'Pub. Date', 'datetime')->format('Y-m-d H:i:s', 'uk');
     $this->edit->add('img_url', 'Image', 'file')->move('uploads/images/news/');
     return $this->returnEditView();
 }
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\Prices());
     $this->edit->label('Edit Prices');
     $this->edit->add('date', 'Date i.e. 2010-05-13 *', 'text')->rule('required|date_format:Y-m-d');
     $this->edit->add('open', 'Open', 'text');
     $this->edit->add('high', 'High', 'text');
     $this->edit->add('low', 'Low', 'text');
     $this->edit->add('last', 'Last', 'text');
     $this->edit->add('settle', 'Settle', 'text');
     $this->edit->add('volume', 'Volume', 'text');
     $this->edit->add('open_interest', 'Open Interest', 'text');
     return $this->returnEditView();
 }
Beispiel #26
0
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\Posts());
     $this->edit->label('Editar Postagem');
     $this->edit->add('nome', 'Nome', 'text');
     $this->edit->add('tipo', 'Tipo', 'radiogroup')->option('postagem', 'Postagem')->option('programas', 'Programas');
     $this->edit->add('categoria', 'Categoria', 'select')->options(\App\Categoria::lists("name", "id")->all());
     $this->edit->add('grupo', 'Grupo', 'select')->options(\App\Grupo::lists("nome", "id")->all());
     $this->edit->add('resumo', 'Resumo', 'redactor');
     $this->edit->add('foto', 'Foto', 'image')->move('img/upload/');
     $this->edit->add('link', 'Link da prefeitura', 'text');
     $this->edit->add('classe', 'Classe de Grid', 'text');
     return $this->returnEditView();
 }
Beispiel #27
0
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new Link());
     Link::creating(function ($link) {
         //dd(__DIR__);
         $appHelper = new libs\AppHelper();
         return class_exists($appHelper->getNameSpace() . $link['url']);
     });
     $this->edit->label('Edit Admin');
     $this->edit->link("rapyd-demo/filter", "Articles", "TR")->back();
     $this->edit->add('display', 'Display', 'text');
     $this->edit->add('url', 'link', 'text');
     return $this->returnEditView();
 }
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\Movement());
     $this->edit->label('Movimeiento');
     $this->edit->add('fecha', 'Fecha', 'date')->rule('required')->format('d/m/Y', 'es');
     $this->edit->add('tipo', 'Tipo', 'radiogroup')->rule('required')->option('ingreso', 'Ingreso')->option('egreso', 'Egreso')->insertValue('egreso');
     $this->edit->add('category_id', 'Categoría', 'select')->rule('required')->options(\App\Category::lists('nombre', 'id')->all());
     $this->edit->add('person_id', 'Persona', 'select')->rule('required')->options(\App\People::lists('nombre', 'id')->all());
     $this->edit->add('group_id', 'Grupo', 'select')->rule('required')->options(\App\Group::lists('nombre', 'id')->all());
     $this->edit->add('monto', 'Monto ($)', 'text')->rule('required');
     $this->edit->add('comprobante', 'Comprobante', 'file')->move('media/comprobantes/');
     $this->edit->add('notas', 'Notas', 'textarea')->rule('required');
     return $this->returnEditView();
 }
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new \App\Contributor());
     $this->edit->label('Edit Category');
     $this->edit->add('name', 'Name', 'text');
     $this->edit->add('id', 'id', 'text');
     $this->edit->add('fb_id', 'fb_id', 'text');
     $this->edit->add('name', 'name', 'text');
     $this->edit->add('email', 'email', 'text');
     $this->edit->add('birthbay', 'birthbay', 'text');
     $this->edit->add('education', 'education', 'text');
     $this->edit->add('gender', 'gender', 'text');
     return $this->returnEditView();
 }
Beispiel #30
0
 public function edit($entity)
 {
     parent::edit($entity);
     $this->edit = \DataEdit::source(new Link());
     Link::creating(function ($link) {
         $appHelper = new libs\AppHelper();
         return class_exists($appHelper->getNameSpace() . $link['url']);
     });
     $helpMessage = trans('rapyd::rapyd.links_help');
     $this->edit->label('Edit Links');
     $this->edit->link("rapyd-demo/filter", "Articles", "TR")->back();
     $this->edit->add('display', 'Display', 'text');
     $this->edit->add('url', 'link', 'text');
     $this->addHelperMessage($helpMessage);
     return $this->returnEditView();
 }