public function run()
 {
     DB::table('materialreplenishment')->delete();
     materialreplenishment::create(['product_id_fk' => '1', 'material_id_fk' => '1', 'material_count' => '50', 'created_at' => '2016-03-05 15:59:10']);
     materialreplenishment::create(['product_id_fk' => '4', 'material_id_fk' => '2`', 'material_count' => '13', 'created_at' => '2016-03-05 16:00:39']);
     materialreplenishment::create(['product_id_fk' => '7', 'material_id_fk' => '3', 'material_count' => '30', 'created_at' => '2016-03-05 15:59:10']);
 }
 public function updatereplenishment(Request $request)
 {
     $materialreplenishment = materialreplenishment::whereid($request->get('id'))->first();
     $materialreplenishment->fill($request->all());
     if ($materialreplenishment->save()) {
         return Redirect::back()->withFlash_message(['msg' => ' Material Replenishment successfully updated', 'type' => 'success']);
     }
     return false;
 }