Пример #1
0
 /**
  * Store a newly created resource in storage.
  *
  * @param  \Illuminate\Http\Request  $request
  * @return \Illuminate\Http\Response
  */
 public function store(Requests\SupplierRequest $request)
 {
     //
     $data = $request->except(['_token']);
     Supplier::create($data);
     return redirect()->to('supplier');
 }
 /**
  * Store a newly created resource in storage.
  *
  * @param  \Illuminate\Http\Request  $request
  * @return \Illuminate\Http\Response
  */
 public function store(SupplierRequest $request)
 {
     if (Supplier::create($request->all())) {
         return redirect('/supplier')->with('succcess', 'Sukses simpan data supplier.');
     }
     return redirect()->back()->withErrors(['failed' => 'Gagal simpan data supplier.']);
 }
 /**
  * Run the database seeds.
  *
  * @return void
  */
 public function run()
 {
     $suppliers = ['KEMSA', 'MEDS', 'Others'];
     foreach ($suppliers as $supplier) {
         \App\Supplier::create(['name' => $supplier]);
     }
 }
Пример #4
0
 public function update($id)
 {
     // save updated
     $record = $this->records->find($id);
     if (!$record) {
         Supplier::create(Input::all());
         return $this->respond($record);
     }
     $record->fill(Input::all())->save();
     return $this->respond($record);
 }
 public function run()
 {
     //User::truncate();
     DB::Table('suppliers')->delete();
     //Supplier::create(['supplier_name' => '1010 Printing Australia']);
     //Supplier::create(['supplier_name' => 'Abel Labels']);
     foreach (explode("\n", "1010 PRINTING AUSTRALIA\n3L ELECTRONICS CO (SHEN ZHEN)\n7 DAYS PRINT\nABEL LABELS\nACE GRAPHICS & PRINT PTY LTD\nAD-MAG FRIDGE MAGNETS\nADHESIVE MAGNETIC SUPPLIES PTY LTD\nAGILITY LOGISTICS\nALLKOTES (VIC) PTY LTD\nANHUI PROVINCE TAIHU ZEHONG PLASTIC CO LTD\nANHUI TECHNOLOGY IMP & EXP CO LTD\nAO XIANG GREEN SHOPPING BAG\nART AND SOUL\nASIA PACIFIC OFFSET\nAUS ELECTRICAL SERVICES\nAWM ELECTRICAL\nB&H KING MOLD LIMITED\nBADGER MAKES BADGES PTY LTD\nBANNER CITY PTY LTD\nBASS STRAIT TRANSPORT\nBEE PRINTING CO LTD\nBETTER FINISH CO LTD\nBILTON GRAPHICS PTY LTD\nBIRK AND BLYME PTY LTD\nBLD SUPERIOR BAG CO LTD\nBOLG\nBRAYMAN GRAPHIC ENGINEERS PTY LTD\nBURELA INSTRUMENTATION PTY LTD\nC AND C OFFSET PRINTING CO LTD AUSTRALIA\nCANGNAN WELL BAGS CO LTD\nCARDPRO AUSTRALIA\nCARR GROUP\nCENTRUM PRINTING\nCHAINZONE TECHNOLOGY (FOSHAN) CO LTD\nCHANGCHUN TONG HUI TRADING CO LTD\nCHANGZHOU HUAPU CORK PRODUCTS CO LTD\nCHANGZHOU K K LIGHTING ELECTRIC CO LTD\nCHANGZHOU QUALITY FLAG INDUSTRY CO LTD\nCHAOZHOU SUKE PATE SANITARY WARE CO LTD\nCHECKEY/KOTOO LEATHER GOODS\nCHENGHAI MK TOYS CO LTD\nCHEQUEMATES\nCHER LEE LONG PACKING INDUSTRY CO LTD\nCHINA ELETA TECHNICAL CO LTD\nCHINA GOLD PRINTING GROUP LIMITED\nCHINESE-PRINTING CO LTD\nCHOICE DEVELOPMENT INC\nCHROMAPRINT INDIA PRIVATE LTD\nCITY SHELVING & STORAGE SYSTEMS\nCIXI CITY SMALL SAILBOAT STATIONERY CO LTD\nCIXI WEIER PLASTIC CO LTD\nCLEVER TRADE PRODUCTS\nCMYK HUB\nCOMPUFIX TAS\nCOMPUFIX TAS\nCONTEXT STATIONERY CO LTD\nCOPE SENSITIVE FREIGHT\nCORPORATE EXPRESS\nCOURTNEY\nCTI COLOUR PRINTERS\nCUSTOME-USB INTERNATIONAL CO LTD\nD & W INDUSTRY (ASIA) LIMITED\nDARK HORSE PRINT DESIGN\nDASTEK CORPORATOPN LIMITED\nDATAFLOW BUSINESS SYSTEMS\nDEBBIE JOSEPH\nDEEJAY SIGNS\nDHL EXPRESS\nDIGI LABELS\nDISK BANK\nDISK BANK\nDISPLAY POWER\nDOCKETS AND FORMS PTY LTD\nDONG QIAN LAKE INDUSTRIAL CO LTD\nDONG YANG JIRONG PLASTIC INDUSTRIAL CO LTD\nDONGGUAN CITY JINGLI CAN CO LTD\nDONGGUAN KLT & CASINE ELECTRONIC TERCHNOLOGY \nDONGGUAN SHUNTONG COLOR PRINTING CO LTD\nDREAMTIME STOCK IMAGES\nDUO TRADING\nE-PROMO CO LTD\nE-STAMPS\nEK INTERNATIONAL DEVELOPMENT CO LTD\nELECTRON KINGDOM CO LTD \nELITE MOLD (SHENZHEN) CO LTD\nENVOPRINT\nEURO SIGNS\nEVERBEST PRINTING CO LTD\nFC PRODUCTIONS\nFENG HUA SHUNFA ARTS & CRAFTS CO LTD\nFENG YUAN STATIONERY\nFENGHUA TECHNOLOGY DEVELOPMENT CO LTD\nFENGLOU PACKAGING & COLOUR PRINTING CO LTD\nFIRST PACK\nFLUIDLINE PTY LTD\nFLYING COLOURS\nFOILMASTERS\nFOOT & PLAYSTED\nFOXCIL\nFOYER PRINTING\nFRANKLIN DIRECT\nFRIDGE MAGNET FACTORY\nFUZHOU GREEN TRADING CO LTD\nG BOOK WRITING MATERIALS\nGARETH HOWARD\nGLJ LEDGER BAG MAKING FACTORY\nGLOBAL MARKET GROUP (ASIA) LTD\nGOLDBERRYBRONZE PTY LTD\nGOOD FLAG BIOTECHNOLOGY CORPORATION\nGRAPHFIX SOLUTIONS\nGRAPHIX LABELS PTY LTD\nGREENLAND MANUFACTURING & TRADING CO LTD\nGTL LIGHTING TECHNOLOGY LTD\nGUANG LI PAPER PDTS LTD\nGUANG ZHOU SUNSHINE ELECTRONIC TECHNOLOGY CO \nGUANGDONG BAOKE STATIONERY CO LTD\nGUANGDONG CLIPLEY ELECTRICAL INDUSTRIAL CO LT\nGUANGDONG TENGEN PRINTING CO LTD\nGUANGZHOU ANHORN INDUSTRIAL DEV CO LTD\nGUANGZHOU HOTIME PRINTING CO LTD\nGUANGZHOU HUIDUO ADVERTISING CO LTD\nGUANGZHOU KINGSONS LEATHER PRODUCTS CO LTD\nGUANGZHOU LETIAN PEN CO LTD\nGUANGZHOU LEVON SURPLUS PHOTOELECTRIC CO LTD\nGUANGZHOU LICAI ADVERTISEMENT PRODUCTS\nGUANGZHOU YANGLING ELECTRONIC SCIENCE & TECHN\nGUANGZHOU YINGMEI CRAFTS CO LTD\nGUANGZHOU YX PACKAGING PRODUCTS INDUSTRY CO L\nGUANGZHOU YXIANG PRINTING CO LTD\nGUMMING & VARNISHING SERVICES PTY LTD\nGUZHEN BAISHENG STATIONERY CO LTD\nH&C PRINTING CENTER LTD\nHANGZHOU TIGER ELECTRON & ELECTRIC CO LTD\nHAOYUAN ELECTRICAL LIGHTING FACTORY\nHEBEI LIGHT INDUSTRIAL PRODUCTS IMP & EXP GRO\nHEFEI HENGXIN ENVIRONMENTAL SCIENCE & TECH CO\nHEI LONG JIANG CHANNEL INTERNATIONAL TRADE CO\nHEIDELBERG GRAPHIC EQUIPMENT PTY LTD\nHENAN JIAOZUO FOREIGN TRADE CORP\nHENAN LIGHT IND PRODUCTS IMPORT & EXPORT CO L\nHENAN PREMTEC ENTERPRISE CORPORATION\nHENRY NISSICK\nHERBEN NUMBERING SYSTEMS\nHEROPRINT\nHIGHGATE GROUP\nHIPPO BIN\nHOBART HARDCHROME PTY LTD\nHOMI LIGHTING CO LTD\nHONG KONG DIANYI INDUSTRIAL CO LTD\nHONG KONG JNHE PAPER CO LTD\nHONG KONG TOTAL INDUSTRY\nHONGRUNDA (RUIAN) PHOTO ELECTRIC CO LTD\nHUAYI LIGHTING COMPANY LIMITED\nHUBEI PROVINCIAL LIGHT INDUSTRIAL PRODUCTS IM\nHUNAN DERUO TRADE CO LTD\nHUNAN FAMOUS TRADING CO LTD\nHYGRADE CUTTING FORMES\nI-LOVEPRINT CO LTD\nIBS CARDS\nINTUIT TECHNOLOGIES\nISO PRINTING\nISTOCKPHOTO\nJ L LENNARD PTY LTD\nJCS DIGITAL SOLUTION\nJIANGSU HIGH HOPE INTERNATIONAL GROUP\nJIANGSU SANTU GROUP CO LTD\nJIANGSU SHENGHUI LIGHTING & ELECTRONICS CO LT\nJIANGXI HUACAI PRINTING CO LTD\nJIANGXI LIANCHUANG OPTO-ELECTRONIC SCIENCE & \nJILIN PROVINCE BLUE AND GREEN WINE CO LTD\nJINYI PAPER PRODUCTS & PRINTING CO LTD\nJIUN YO CO LTD\nJIXIANG DECORATING & CRAFTS FACTORY CO LTD\nJOHN HOLTZCLAW\nJUIZHOU GREEBLE \nK W  DOGGETT FINE PAPER\nKALAMAZOO\nKANPRINT\nKEEUP PROMOTIONAL LTD\nKING HOW LIMITED\nKING PRINT\nKING YUAN FU PACKING CO LTD\nKWALITY PRINTING & STATIONERY\nKWIK KOPY\nL T PROMOTION TOY CO LTD\nLABEL LINE PTY LTD\nLABEL NAMES\nLABEL POWER\nLABELPRESS PTY LTD\nLAMSON PARAGON\nLEP COLOUR PRINTERS\nLEVON SURPLUS (PEIYING) OPTOELECTRONIC CO LTD\nLIAONING BAOLIN GROUP ENERGY -SAVING TECH CO \nLITHOTECH INTERNATIONAL\nLIZ SMEEKS CONSULTING\nLOGO CARPET\nLOGOSON ARTS & CRAFTS CO LTD\nLONGPACK CO LTD\nLOUFOR STATIONERY MANUFACTURING CO LTD\nLP PHOTOGRAPHY\nLUMEN LED CO LIMITED\nLUMIX LIGHTING & ELECTRICAL CO LTD\nM & M BINDERS PTY LTD \nM2 STUDIO\nMAC PLUS MORE \nMAC SOLUTIONS\nMADE-IN-CHINA\nMAGNET EXPRESS\nMAGNETS.COM.AU\nMAILHOUSE TAS DISTRIBUTION SERVICES\nMAN FERROSTAAL PTY LTD\nMARK MEDIA\nMARSDEN BROTHERS\nMCPHERSON BOOKBINDERS\nMCPHERSONS PRINTING GROUP\nMENG HUAN PLUSH TOYS\nMERCURY WALCH PTY LTD\nMIDAS PRINTING INTERNATIONAL LTD\nMOIRS PAPER\nMONOTONE ART PRINTERS\nMORNING PRINT\nMULLER MARTINI AUSTRALIA PTY LTD\nMY STICKER FACTORY\nNEW STAR CRAFTS CO LTD\nNINGBO BIN BIN STATIONERY CO LTD\nNINGBO FINELIFE PRODUCTS CO LTD\nNINGBO GELANTE ELECTRIC CO LTD\nNINGBO HIKING ENTERPRISE CO LTD\nNINGBO KAIXIANG ELECTRICAL APPLIANCE CO LTD\nNINGBO LUCKY CRAFT CO LTD\nNINGBO SHINSKY ELECTRICAL APPLIANCE CO LTD\nNINGBO TOPCOM LIGHTING CO LTD\nNINGBO YAMAO LIGHTING ELECTRIC APPLIANCE CO L\nNINGBO YONGTAI METAL PRODUCTS CO LTD\nNINGHAI HUIHUI STATIONERY CO LTD\nNINGHAI ZELYNN STATIONERY CO LTD\nOFFICE NATIONAL\nOFFICE WORKS\nONSITE BELTING\nPAC HOLDINGS PTY LTD\nPACK QUEEN\nPACKAGING PLUS\nPAPER ROLLS AUSTRALIA PTY LTD\nPAPERLINX OFFICE\nPENDA INTERNATIONAL TRADING CO LTD\nPLASTIC PASSPORT\nPLATYPUS GRAPHICS\nPML PRINT\nPNS GRAPHICS AUSTRALIA PTY LTD\nPOWERBEAUTY (DONGGUAN) INDUSTRIAL CO LTD\nPRESTIGE BOOKBINDERS\nPRESTIGE COURIERS\nPRINT BOUND\nPRINTERS CHOICE PTY LTD\nPRINTING AUTHORITY\nPRIORITY CARGO AUST PTY LTD\nPROMOTION PRODUCTS\nQINGDAO HUALONG PACKING CO LTD\nQPS ELECTRONICS CO LTD\nQUALITY BINDERS\nQUANZHOU QUANKANG CRAFT CO LTD\nRAYSON GLOBAL CO LTD\nREADY STEADY PRINT\nRED & BLUE COLOR PRINTING CO LTD\nRENOMA PRINTERY\nRMV (QUANZHOU) INTERNATIONAL TRADING CO LTD\nROASTAR\nROLLMAKERS PTY LTD\nS W GRAPHICS\nSAILING INTERNATIONAL LIMITED\nSALMAT LETTERBOX DROP SERVICES\nSANMAR INDUSTRIAL SUPPLIES\nSCORPION PRECISION INDUSTRY (HK) CO LTD\nSCREENSPRINT\nSEAGA (VIC) PTY LTD\nSHANGHAI BAGIFT ARTWARE CO LTD\nSHANGHAI DAHUA STATIONERY & SPORTING GOODS FA\nSHANGHAI DENGQING IMP & EXP CO LTD\nSHANGHAI FOREST PACKING CO LTD\nSHANGHAI GOODWIEW ELECTRONIC CO LTD\nSHANGHAI HONGTUO ECO-TECHNOLOGY CO LTD\nSHANGHAI SUNKEA PAPER CUP CO LTD\nSHANTOU BO CHUAN MACHINERY CO LTD\nSHANTOU CHENGHAI HUAJUN AERMODELLING & PLASTI\nSHANTOU WEIZIN INDUSTRIAL CO LTD\nSHANTOU XITONG STATIONERY INDUSTRY CO LTD\nSHEA PLASTICS\nSHENZHEN ANDASHENG BAG MANUFACTURING CO LTD\nSHENZHEN AOJIN HANDBAG CO LTD\nSHENZHEN CHUANGXINJIA RFID TAG CO LTD\nSHENZHEN FLEXWILL CO LTD\nSHENZHEN FONACA TECH\nSHENZHEN GUTON TECHNOLOGY CO LTD\nSHENZHEN LANCER ELECTRONIC CO LTD\nSHENZHEN NEW JIN KE CYBER DEVELOPING CO LTD\nSHENZHEN SANFENG PLASTIC PACKING CO LTDSANFEN\nSHENZHEN SCOPE SCIENTIFIC DEVELOPMENT CO LTD\nSHENZHEN SEMILUX LIGHTING TECHNOLOGY CO LTD\nSHENZHEN SHINEWAY LTD\nSHENZHEN SUNLANRFID TECHNOLOGY CO LTD\nSHENZHEN SUNLIGHT ELECTRONIC TECHNOLOGY CO LT\nSHENZHEN SUPERTAI TECHNOLOGY CO LTD\nSHENZHEN TOP TECHNOLOGY CO LTD\nSHENZHEN WANIDA TECHNOLOGY CO LTD\nSHENZHEN XINGZHIYE PRINTING & PACKING CO LTD\nSHENZHEN ZHONGHENGHUA TECHNOLOGY CO LTD \nSHUNKI TECHNOLOGY CO LTD\nSIGNWORKS\nSINO PATH ENTERPRISES LIMITED\nSLIMLINE WAREHOUSE\nSMARTEE\nSOCIAL PRINTING PTY LTD\nSOUTHERN SAW SERVICE\nSPEEDY\nSPICERS HOBART\nST VINCENT DE PAUL\nSTANDOUT MATS PTY LTD\nSTAR TRACK\nSTICKER COMPANY\nSTRAPMARK PTY LTD\nSTS SANTUCCI TAILORED SERVICES PTY LTD.\nSTUART AGAR EQUIPMENT SERVICES\nSTYGIAN STUDIO\nSUN-FLY\nSUNLIGHT ELECTRONIC TECHNOLOGY CO LTD\nSUNNY & SANDY CRAFTS CO LTD\nSUNNY YOUNG ENTERPRISE CO LTD\nTADPAC PRINT\nTAGS & TICKETS\nTAI ZHOU GODDESS PLAYING CARDS CO LTD\nTAIZHOU IDEAPAD STATIONERY CO LTD\nTASMANIAN FREIGHT SERVICES PTY LTD\nTENDER INTERNATIONAL CO LTD\nTENG FEI INTERNATIONAL DEVELOPMENT LTD\nTEST SUPPLIER\nTEST SUPPLIER2\nTHE POLYTHENE COMPANY\nTHE SIGN & PRINT SHOP\nTHE WORKS PRINTING GROUP PTY LTD\nTIEN WAH PRESS (PTE) LIMITED\nTIM CARTER\nTLC DIGITAL +\nTONGLU AI-DE IMP & EXP CO LTD\nTOP PRINT\nTOTAL NETWORKS\nTOURISM BROCHURE EXCHANGE\nTRADEKOREA.COM\nTST PRINTING\nTUNG YUNG INTERNATIONAL LIMITED\nTYPEFACE\nTest supplier\nUSB BOOK COMPANY LTD\nUSB SKY ELECTRONIC TECHNOLOGY CO LTD\nUSB-LIFETIME ELECTRONIC TECHNOLOGY CO LTD\nVISTAPRINT\nWAH SHING PACKING PRODUCTS CO LTD\nWALKABOUT ENTERPRISES\nWASSYS TRNSPORT\nWEIFANG TOPSUN TEXTILE CO LTD\nWELSON MOLD (HONG KONG) CO LTD\nWENZHOU DIVINE LAND DECORATION LIGHT CO LTD\nWENZHOU GUANGXIN PACKAGING CO LTD\nWENZHOU SUCCESS GROUP CO LTD\nWENZHOU TIANHAO PEN INDUSTRIAL CO LTD\nWENZHOU TREASURE CRAFTS CO LTD\nWENZHOUSHENGCAIGONGYILIPINCHANG\nWENZHOUY FEIYA STATIONERY CO LTD\nWHOLE VIEW SUPPLY CHAIN MANAGEMENT CO LTD\nWINBO INDUSTRIAL CO LTD\nXIAMEN BONSTAR BAGS CO LTD\nXIAMEN HAIRISHENG NON WOVEN PRIDUCTS LTD\nXIAMEN NOVELTY FLAG CO LTD\nXIAMEN WISELINK INDUSTRY & TRADE CO LTD\nXIAYI COUNTY SHENGONG PEN IDUSTRY CO LTD\nXING CHEN HAT INDUSTRY CO LTD\nYESING LABEL COMPANY\nYIWU BAILONG ELECTRICAL APPLIANCE CO LTD\nYIWU CITY JIANPING SCHOOL SUPPLY AND STATIONE\nYIWU HANFENG HANDBAG CO LTD\nYIWU HUA DA STATIONERY FIRM\nYIWU SHUANGDELI COLOR PRINTING FACTORY\nYIWU WAHU GIFT PACKING CO LTD\nYIWU XIAO BO SHI STATIONERY CO LTD\nYIWU XINGQIBA TOY BUSINESS\nYIWU ZHUO YUAN PACKAGING  FACTORY\nYOUNG SUN TRADING CO LTD\nZHANGJIAGANG JINGGONG PACKAGING & COLOR PRINT\nZHEJIANG HUAXU INDUSTRIAL CO LTD\nZHEJIANG OTOR CONTAINER TECHNOLOGY CO LTD\nZHEJIANG SANBAO PRINTING CO LTD\nZHEJIANG VOLONG SANITARY WARES CO LTD\nZHEJINAG YIWU BAOLONG WRAPPING S&T CO LTD\nZHONGQIAN LIGHTING\nZHONGSHAN LEADER LIGHTING TECHNOLOGY CO LTD\nZHONGSHAN NORSLAN LIGHTING & ELECTRONICS CO L\n") as $supplier_name) {
         Supplier::create(['supplier_name' => $supplier_name]);
     }
     $franklin = Supplier::where('supplier_name', '=', 'FRANKLIN DIRECT')->firstOrFail();
     $compufix = Supplier::where('supplier_name', '=', 'COMPUFIX TAS')->firstOrFail();
     SupplierContact::create(['supplier_id' => $franklin->id, 'first_name' => 'David', 'last_name' => 'Thorne', 'email' => '*****@*****.**']);
     SupplierContact::create(['supplier_id' => $compufix->id, 'first_name' => 'Craig', 'last_name' => 'Marshall', 'email' => '*****@*****.**']);
 }
 /**
  * Store a newly created resource in storage.
  *
  * @return Response
  */
 public function store(Request $request)
 {
     $this->validate($request, ['supplier_name' => 'required|unique:suppliers', 'web_address' => 'url', 'common_email' => 'required']);
     // Store input to session
     Input::flash();
     // Create Supplier
     $result = Supplier::create(Input::all());
     if (!$result->id) {
         return redirect()->route('suppliers.create')->with('message', 'Unable to create supplier, please try again.');
     }
     foreach ($request->input('contacts') as $key => $contact) {
         // If at least one of the fields is not null, store contact
         if (!empty($contact['first_name']) || !empty($contact['last_name']) || !empty($contact['phone']) || !empty($contact['mobile']) || !empty($contact['email'])) {
             $result->supplier_contacts()->create($contact);
         }
     }
     //redirect after successful save to customers.edit
     return redirect()->route('suppliers.edit', $result->id)->with('message', 'Supplier created!')->withInput();
 }
Пример #7
0
 public function handleAction(Request $request)
 {
     $action = $request->input('_action');
     if ($action == 'createSupplier') {
         //Creation :
         Supplier::create($request->all());
         // FLash messaging :
         flash()->success('Opération réussie!', 'Fournisseur créé avec succès.');
     } else {
         if ($action == 'addArt') {
             try {
                 $this->validate($request, ['reference' => 'unique:articles']);
                 Article::create($request->all());
             } catch (\Exception $e) {
                 return response(['status' => 'doublon'], 500);
             }
             return response(['status' => 'success']);
         } else {
         }
     }
     return redirect('/suppliers');
 }
Пример #8
0
 public function run()
 {
     DB::table('suppliers')->delete();
     Supplier::create(['email' => '*****@*****.**', 'first_name' => 'Samim', 'last_name' => 'Almamun', 'password' => md5('123456livingadventure'), 'status' => 'Active']);
 }
Пример #9
0
 /**
  * Store a newly created resource in storage.
  *
  * @param  Request  $request
  * @return Response
  */
 public function store(SupplierRequest $request)
 {
     Supplier::create($request->all());
     return redirect()->route('admin.suppliers.index')->with('status', 'Supplier added.');
 }
Пример #10
0
 /**
  * Store a newly created resource in storage.
  *
  * @return Response
  */
 public function store(CreateSupplierRequest $request)
 {
     Supplier::create($request->all());
     return redirect('supplier');
 }
Пример #11
0
 /**
  * Store a newly created resource in storage.
  *
  * @return Response
  */
 public function store()
 {
     $supplier = Request::all();
     Supplier::create($supplier);
     return redirect('suppliers');
 }
Пример #12
0
 /**
  * Store a newly created resource in storage.
  *
  * @param  \Illuminate\Http\Request  $request
  * @return \Illuminate\Http\Response
  */
 public function store(Request $request)
 {
     $this->validate($request, ['supplier_name' => 'required|max:255']);
     $supplier = Supplier::create(['supplier_name' => $request->supplier_name]);
     return redirect('/supplier')->with('message', 'Supplier added!');
 }