const system = require('../../../system');
const http = require('http');
const querystring = require('querystring');
const settings = require('../../../../config/settings');
const CtlBase = require('../../ctl.base');


const cacheBaseComp = null;
class PConfigCtl extends CtlBase {
  constructor() {
    super('common', CtlBase.getServiceName(PConfigCtl));
    this.userCtl = system.getObject('service.auth.userSve');
  }

  async initNewInstance(pobj, queryobj, req) {
    const rtn = {};
    return system.getResult(rtn);
  }
  async create(pobj, queryobj, req) {
    pobj.app_id = req.appid;
    pobj.appkey = req.appkey;
    const rtn = await super.create(pobj, queryobj, req);
    return system.getResult(rtn);
  }
  async update(pobj, queryobj, req) {
    pobj.app_id = req.appid;
    pobj.appkey = req.appkey;
    const rtn = await super.update(pobj);
    return system.getResult(rtn);
  }
}
module.exports = PConfigCtl;
