Add missing model.
This commit is contained in:
parent
507c69d0b2
commit
abcdfcf48c
@ -14,6 +14,8 @@
|
||||
You should have received a copy of the GNU Affero General Public License
|
||||
along with Accountant. If not, see <http://www.gnu.org/licenses/>.
|
||||
"""
|
||||
from copy import deepcopy
|
||||
|
||||
from flask.ext.restful import fields
|
||||
|
||||
# Account model.
|
||||
@ -54,7 +56,7 @@ ohlc_model = {
|
||||
}
|
||||
|
||||
# Operation with sold model.
|
||||
operation_with_sold_model = {
|
||||
operation_model = {
|
||||
'id': fields.Integer(default=None),
|
||||
'operation_date': fields.DateTime(dt_format='iso8601'),
|
||||
'label': fields.String,
|
||||
@ -63,11 +65,13 @@ operation_with_sold_model = {
|
||||
'category': fields.String,
|
||||
'account_id': fields.Integer,
|
||||
'scheduled_operation_id': fields.Integer(default=None),
|
||||
'sold': fields.Float,
|
||||
'confirmed': fields.Boolean,
|
||||
'canceled': fields.Boolean,
|
||||
}
|
||||
|
||||
operation_with_sold_model = deepcopy(operation_model)
|
||||
operation_with_sold_model['sold'] = fields.Float
|
||||
|
||||
# Scheduled operation model.
|
||||
scheduled_operation_model = {
|
||||
'id': fields.Integer,
|
||||
|
Loading…
Reference in New Issue
Block a user