Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- try {
- $product = \ProductEditor::createProduct([
- 'title' => $title,
- 'shortTitle' => $shortTitle,
- 'sku' => $sku
- ]);
- } catch (\Exceptions\MissingField $ex) {
- $this->flash->error( _('Nincs minden mező kitöltve!') );
- return;
- } catch (\Exceptions\Product\SKUAlreadyExists $ex) {
- $this->flash->error( sprintf(_('Ez a cikkszám már használatban van: %s'), $sku) );
- return;
- } catch(\Exception $ex) {
- $this->flash->error( sprintf(_('ISMERETLEN HIBA @ %s:%i > %s'), __FILE__, __LINE__, "createAction") );
- return;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement