Git Product home page Git Product logo

shopctrl's Issues

Can't use Order::model()->find($orderId);

When I try to request the data for one specific order I get the following error:

An uncaught Exception was encountered
Type: Afosto\Bp\Exceptions\ValidationException
Message: Model Afosto\ShopCtrl\Models\int not found
Filename: vendor/afosto/bp/src/Components/Validator.php
Line Number: 149

Backtrace:
File: vendor/afosto/bp/src/Components/Model.php
Line: 148
Function: getNewModel

File: vendor/afosto/shopctrl/src/Models/Order.php
Line: 188
Function: setAttributes

File: vendor/afosto/shopctrl/src/Components/Operations/Find.php
Line: 44
Function: setAttributes

I have tried to fix the error myself but I have to admit that I am having trouble understanding how the code is intertwined. This error (presumably) also prevents me from getting all order information when I use Order::model()->findAll(). Only the following attributes get retrieved correctly

  ["id"]=>
  int(118955)
  ["orderCode"]=>
  string(14) "test1530020452"
  ["date"]=>
  string(19) "2018-06-26T15:40:52"
  ["orderTotalIncVat"]=>
  float(5)
  ["orderTotalExVat"]=>
  float(0)
  ["currencyId"]=>
  int(0)
  ["currencyCode"]=>
  string(3) "EUR"
  ["deleted"]=>
  bool(false)
  ["changeTimestamp"]=>
  string(23) "2018-06-26T15:40:54.497"
  ["mainStatusId"]=>
  int(1)
  ["affiliateId"]=>
  NULL

All other possible order attributes are NULL. Can you help me fix this error? (I assume that this also effects your own business negatively.) Or am I just doing something wrong?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.