import { Injectable } from '@angular/core'; import { SystemVariables } from "../../../../models/admin/system/systemvariables/systemvariables"; import { CommonEnum } from "../../../../models/common-enum"; import { CoredataService } from '../../../../core/coredata.service'; @Injectable({ providedIn: 'root' }) export class SystemVariableService { constructor(private coreData: CoredataService) { } getSystemVariable(success, error) { this.coreData.Get(CommonEnum.SystemAPP, CommonEnum.SystemVariablesAPI , null, (result) => { if (result != null) { return success(result); } return null; }, (error) => { return error(error); }); } saveSystemVariable(modelSystemVariables: SystemVariables, success, error) { // const headers = { 'content-type': 'application/json' } this.coreData.Post(CommonEnum.SystemAPP, CommonEnum.SystemVariablesAPI, modelSystemVariables, (result) => { if (result != null ) { return success(result); } return null; }, (error) => { return error(error); }); } }