1234567891011121314151617181920212223242526272829 |
- class CtiController < ApplicationController
- prepend_before_action { authentication_check(permission: 'cti.agent') }
-
- def index
- backends = [
- {
- name: 'sipgate.io',
- enabled: Setting.get('sipgate_integration'),
- url: '#system/integration/sipgate',
- }
- ]
- result = Cti::Log.log
- result[:backends] = backends
- render json: result
- end
-
- def done
- log = Cti::Log.find(params['id'])
- log.done = params['done']
- log.save!
- render json: {}
- end
- end
|