/// class PD.Manage.Services.DataLoadService

PD.Manage.Services.DataLoadService =
Class.extend({

    //===================================
    // PUBLIC METHODS
    //===================================

    createJob: function (uploadId, uploadName, validateOnly, success, error) {

        PD.ajax({
            type: "POST",
            url: PD.Path.resolve("~/manage/dataload/createjob"),
            data: {
                uploadId: uploadId,
                uploadName: uploadName,
                validateOnly: validateOnly
            },
            success: success,
            error: error
        });

    },

    deleteJobs: function (jobIds, success, error) {

        PD.ajax({
            type: "DELETE",
            url: PD.Path.resolve("~/manage/dataload/deletejobs"),
            data: {
                ids: jobIds
            },
            success: success,
            error: error
        });

    },

    deleteAllJobs: function (success, error) {

        PD.ajax({
            type: "DELETE",
            url: PD.Path.resolve("~/manage/dataload/deletealljobs"),
            success: success,
            error: error
        });

    }

});