2014-08-09 06:28:57 -04:00
|
|
|
/**
|
|
|
|
Data model for representing an export
|
|
|
|
|
|
|
|
@class ExportCsv
|
|
|
|
@extends Discourse.Model
|
|
|
|
@namespace Discourse
|
|
|
|
@module Discourse
|
|
|
|
**/
|
|
|
|
Discourse.ExportCsv = Discourse.Model.extend({});
|
|
|
|
|
|
|
|
Discourse.ExportCsv.reopenClass({
|
|
|
|
/**
|
|
|
|
Exports user list
|
|
|
|
|
|
|
|
@method export_user_list
|
|
|
|
**/
|
|
|
|
exportUserList: function() {
|
2014-12-06 23:15:22 -05:00
|
|
|
return Discourse.ajax("/admin/export_csv/export_entity.json", {data: {entity: 'user'}});
|
2014-11-21 10:25:04 -05:00
|
|
|
},
|
|
|
|
|
|
|
|
/**
|
2014-12-06 23:15:22 -05:00
|
|
|
Exports staff action logs
|
2014-11-21 10:25:04 -05:00
|
|
|
|
2014-12-06 23:15:22 -05:00
|
|
|
@method export_staff_action_logs
|
2014-11-21 10:25:04 -05:00
|
|
|
**/
|
2014-12-06 23:15:22 -05:00
|
|
|
exportStaffActionLogs: function() {
|
|
|
|
return Discourse.ajax("/admin/export_csv/export_entity.json", {data: {entity: 'staff_action'}});
|
|
|
|
},
|
|
|
|
|
|
|
|
/**
|
|
|
|
Exports screened email list
|
|
|
|
|
|
|
|
@method export_screened_email_list
|
|
|
|
**/
|
|
|
|
exportScreenedEmailList: function() {
|
|
|
|
return Discourse.ajax("/admin/export_csv/export_entity.json", {data: {entity: 'screened_email'}});
|
|
|
|
},
|
|
|
|
|
|
|
|
/**
|
|
|
|
Exports screened IP list
|
|
|
|
|
|
|
|
@method export_screened_ip_list
|
|
|
|
**/
|
|
|
|
exportScreenedIpList: function() {
|
|
|
|
return Discourse.ajax("/admin/export_csv/export_entity.json", {data: {entity: 'screened_ip'}});
|
|
|
|
},
|
|
|
|
|
|
|
|
/**
|
|
|
|
Exports screened URL list
|
|
|
|
|
|
|
|
@method export_screened_url_list
|
|
|
|
**/
|
|
|
|
exportScreenedUrlList: function() {
|
|
|
|
return Discourse.ajax("/admin/export_csv/export_entity.json", {data: {entity: 'screened_url'}});
|
2014-08-09 06:28:57 -04:00
|
|
|
}
|
|
|
|
});
|