RulesGroup

This commit is contained in:
Vins 2024-04-18 14:33:06 +02:00
parent 1ecb4711cf
commit c3c9282af6
3 changed files with 76 additions and 0 deletions

9
dist/Admin/RulesGroup.d.ts vendored Normal file
View File

@ -0,0 +1,9 @@
import Resource from "../Resource";
import { Rule } from "../Notary";
export default class RulesGroup extends Resource {
uid?: string;
name?: string;
created_at: Date | null;
updated_at: Date | null;
rules?: Rule[];
}

46
dist/Admin/RulesGroup.js vendored Normal file
View File

@ -0,0 +1,46 @@
"use strict";
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
return c > 3 && r && Object.defineProperty(target, key, r), r;
};
var __metadata = (this && this.__metadata) || function (k, v) {
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
};
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
const Resource_1 = __importDefault(require("../Resource"));
const class_transformer_1 = require("class-transformer");
const Notary_1 = require("../Notary");
class RulesGroup extends Resource_1.default {
constructor() {
super(...arguments);
this.created_at = null;
this.updated_at = null;
}
}
__decorate([
(0, class_transformer_1.Expose)(),
__metadata("design:type", String)
], RulesGroup.prototype, "uid", void 0);
__decorate([
(0, class_transformer_1.Expose)(),
__metadata("design:type", String)
], RulesGroup.prototype, "name", void 0);
__decorate([
(0, class_transformer_1.Expose)(),
__metadata("design:type", Object)
], RulesGroup.prototype, "created_at", void 0);
__decorate([
(0, class_transformer_1.Expose)(),
__metadata("design:type", Object)
], RulesGroup.prototype, "updated_at", void 0);
__decorate([
(0, class_transformer_1.Expose)(),
(0, class_transformer_1.Type)(() => Notary_1.Rule),
__metadata("design:type", Array)
], RulesGroup.prototype, "rules", void 0);
exports.default = RulesGroup;

21
src/Admin/RulesGroup.ts Normal file
View File

@ -0,0 +1,21 @@
import Resource from "../Resource";
import { Expose, Type } from "class-transformer";
import { Rule } from "../Notary";
export default class RulesGroup extends Resource {
@Expose()
public uid?: string;
@Expose()
public name?: string;
@Expose()
public created_at: Date | null = null;
@Expose()
public updated_at: Date | null = null;
@Expose()
@Type(() => Rule)
public rules?: Rule[];
}