"use strict";
Object.defineProperty(exports, "__esModule", {
    value: true
});
function _export(target, all) {
    for(var name in all)Object.defineProperty(target, name, {
        enumerable: true,
        get: all[name]
    });
}
_export(exports, {
    createFloorRules: function() {
        return createFloorRules;
    },
    printerInFloorRules: function() {
        return printerInFloorRules;
    },
    removePrinterInFloorRules: function() {
        return removePrinterInFloorRules;
    },
    updateFloorNameRules: function() {
        return updateFloorNameRules;
    },
    updateFloorNumberRules: function() {
        return updateFloorNumberRules;
    },
    updateFloorRules: function() {
        return updateFloorRules;
    }
});
const _serviceconstants = require("../../constants/service.constants");
const _genericvalidation = require("../../controllers/validation/generic.validation");
const removePrinterInFloorRules = (isSqlite)=>({
        printerId: (0, _genericvalidation.idRuleV2)(isSqlite)
    });
const printerInFloorRules = (isSqlite)=>({
        printerId: (0, _genericvalidation.idRuleV2)(isSqlite),
        floorId: isSqlite ? (0, _genericvalidation.idRuleV2)(true) : "not",
        x: "required|integer|between:0,12",
        y: "required|integer|between:0,12"
    });
const updateFloorNameRules = {
    name: `required|minLength:${_serviceconstants.minFloorNameLength}`
};
const updateFloorNumberRules = {
    floor: "required|integer"
};
const updateFloorRules = {
    name: `required|minLength:${_serviceconstants.minFloorNameLength}`,
    floor: "required|integer",
    printers: "array",
    "printer.*.printerId": "required|mongoId",
    "printer.*.x": "required|integer|between:0,12",
    "printer.*.y": "required|integer|between:0,12"
};
const createFloorRules = {
    name: `required|minLength:${_serviceconstants.minFloorNameLength}`,
    floor: "required|integer",
    printers: "array"
};

//# sourceMappingURL=floor-service.validation.js.map