2018-01-16 06:58:15 +01:00
|
|
|
# -*- coding: utf-8 -*-
|
2018-01-16 11:34:37 +01:00
|
|
|
# Part of Odoo, Flectra. See LICENSE file for full copyright and licensing details.
|
2018-01-16 06:58:15 +01:00
|
|
|
|
2018-01-16 11:34:37 +01:00
|
|
|
from flectra import api, fields, models
|
2018-01-16 06:58:15 +01:00
|
|
|
|
|
|
|
|
|
|
|
class ResConfigSettings(models.TransientModel):
|
|
|
|
_inherit = "res.config.settings"
|
|
|
|
|
|
|
|
website_slide_google_app_key = fields.Char(string='Google Doc Key')
|
|
|
|
|
|
|
|
@api.model
|
|
|
|
def get_values(self):
|
|
|
|
res = super(ResConfigSettings, self).get_values()
|
|
|
|
res.update(
|
|
|
|
website_slide_google_app_key=self.env['ir.config_parameter'].sudo().get_param('website_slides.google_app_key'),
|
|
|
|
)
|
|
|
|
return res
|
|
|
|
|
|
|
|
@api.multi
|
|
|
|
def set_values(self):
|
|
|
|
super(ResConfigSettings, self).set_values()
|
|
|
|
self.env['ir.config_parameter'].sudo().set_param('website_slides.google_app_key', self.website_slide_google_app_key)
|