sass-cms-template-common 0.0.5 → 0.0.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +7165 -477
- package/dist/index.js +3980 -554
- package/dist/index.js.map +1 -1
- package/dist/server.d.ts +4923 -207
- package/dist/server.js +2 -2
- package/dist/services-C2aqnM7h.js +3741 -0
- package/dist/services-C2aqnM7h.js.map +1 -0
- package/package.json +2 -1
- package/dist/services-CK6pkce_.js +0 -178
- package/dist/services-CK6pkce_.js.map +0 -1
|
@@ -0,0 +1,3741 @@
|
|
|
1
|
+
//#region src/lib/theme/variables.ts
|
|
2
|
+
var e = {
|
|
3
|
+
primary: "#0067C4",
|
|
4
|
+
primaryHover: "#005CAF",
|
|
5
|
+
primaryDisabled: "#1D1B201A",
|
|
6
|
+
secondary: "#D8E2FF",
|
|
7
|
+
secondaryHover: "#E1E2EA",
|
|
8
|
+
onSecondaryContainer: "#2C4678",
|
|
9
|
+
secondaryStrong: "#455E91",
|
|
10
|
+
controlBorder: "#727784",
|
|
11
|
+
controlText: "#000000",
|
|
12
|
+
controlHoverBg: "#F9F9FF",
|
|
13
|
+
whiteBtnBorder: "#DDDDDD",
|
|
14
|
+
whiteBtnText: "#515253",
|
|
15
|
+
iconButtonHoverBg: "#E6E6E6",
|
|
16
|
+
iconButtonIcon: "#929193",
|
|
17
|
+
menuSurface: "#ECEDF6",
|
|
18
|
+
menuItemActive: "#E1E2EB",
|
|
19
|
+
surfaceHover: "#E3E2E6",
|
|
20
|
+
alphabetIdle: "#B4BEDA",
|
|
21
|
+
textStrong: "#191C22",
|
|
22
|
+
textNav: "#414752",
|
|
23
|
+
textMuted: "#94A2AA",
|
|
24
|
+
link: "#004F99",
|
|
25
|
+
danger: "#BA1A1A",
|
|
26
|
+
dangerHover: "#93000A",
|
|
27
|
+
success: "#1E8E3E",
|
|
28
|
+
border: "#C1C6D4",
|
|
29
|
+
avatarBg: "#F2F6FC",
|
|
30
|
+
avatarBorder: "#DEE2E6",
|
|
31
|
+
white: "#FFFFFF"
|
|
32
|
+
}, t = {
|
|
33
|
+
sm: "8px",
|
|
34
|
+
md: "10px",
|
|
35
|
+
lg: "14px",
|
|
36
|
+
xl: "28px",
|
|
37
|
+
dialog: "24px",
|
|
38
|
+
pill: "999px"
|
|
39
|
+
}, n = {
|
|
40
|
+
button: "0 1px 2px rgba(0, 0, 0, 0.10)",
|
|
41
|
+
menu: "0px 1px 3px 0px rgba(0, 0, 0, 0.30), 0px 4px 8px 3px rgba(0, 0, 0, 0.15)",
|
|
42
|
+
menuSoft: "0 10px 30px rgba(0, 0, 0, 0.18)",
|
|
43
|
+
menuDropdown: "0px 4px 4px 0px rgba(0, 0, 0, 0.30), 0px 8px 12px 6px rgba(0, 0, 0, 0.15)",
|
|
44
|
+
flyout: "0px 8px 16px rgba(0, 0, 0, 0.18)"
|
|
45
|
+
}, r = {
|
|
46
|
+
buttonHeight: 40,
|
|
47
|
+
buttonHeightSm: 34,
|
|
48
|
+
searchHeight: 48
|
|
49
|
+
}, i = {
|
|
50
|
+
surface: "#2E2E2E",
|
|
51
|
+
onSurface: "#FFFFFF",
|
|
52
|
+
onSurfaceMuted: "#C7C7C7",
|
|
53
|
+
success: "#00C853",
|
|
54
|
+
warning: "#FFAB00",
|
|
55
|
+
error: "#FF1744",
|
|
56
|
+
info: "#2196F3"
|
|
57
|
+
}, a = {
|
|
58
|
+
active: {
|
|
59
|
+
bg: "#D6F4DE",
|
|
60
|
+
on: "#1D6B2E"
|
|
61
|
+
},
|
|
62
|
+
generating: {
|
|
63
|
+
bg: "#DCE3FF",
|
|
64
|
+
on: "#001551"
|
|
65
|
+
},
|
|
66
|
+
assigned: {
|
|
67
|
+
bg: "#EADDFF",
|
|
68
|
+
on: "#4F378A"
|
|
69
|
+
},
|
|
70
|
+
discarded: {
|
|
71
|
+
bg: "#ECEDF6",
|
|
72
|
+
on: "#43474E"
|
|
73
|
+
}
|
|
74
|
+
}, o = {
|
|
75
|
+
active: {
|
|
76
|
+
bg: "#92F7B7",
|
|
77
|
+
on: "#002112"
|
|
78
|
+
},
|
|
79
|
+
inactive: {
|
|
80
|
+
bg: "#E1E2E9",
|
|
81
|
+
on: "#002112"
|
|
82
|
+
}
|
|
83
|
+
}, s = {
|
|
84
|
+
high: {
|
|
85
|
+
bg: "#D7F5DD",
|
|
86
|
+
on: "#0D5B2B"
|
|
87
|
+
},
|
|
88
|
+
medium: {
|
|
89
|
+
bg: "#FFF0C8",
|
|
90
|
+
on: "#6B4D00"
|
|
91
|
+
},
|
|
92
|
+
low: {
|
|
93
|
+
bg: "#E7E8EE",
|
|
94
|
+
on: "#43474E"
|
|
95
|
+
}
|
|
96
|
+
}, c = {
|
|
97
|
+
like: "#1E8E3E",
|
|
98
|
+
dislike: "#D93025"
|
|
99
|
+
}, l = {
|
|
100
|
+
rss: "#FB923C",
|
|
101
|
+
gtrends: "#4285F4",
|
|
102
|
+
sconsole: "#0F9D58",
|
|
103
|
+
x: "#111111"
|
|
104
|
+
}, u = {
|
|
105
|
+
roboto: "\"Roboto\",\"Helvetica\",\"Arial\",sans-serif",
|
|
106
|
+
productSans: "\"Product Sans\",\"Roboto\",\"Helvetica\",\"Arial\",sans-serif"
|
|
107
|
+
}, d = {
|
|
108
|
+
"000.000": "The user is already logged in",
|
|
109
|
+
"000.001": "The user does not exist",
|
|
110
|
+
"000.002": "The user will be disabled after 3 invalid login attempts.",
|
|
111
|
+
"000.003": "The user is disabled",
|
|
112
|
+
"000.004": "General error",
|
|
113
|
+
"000.005": "Insufficient permissions",
|
|
114
|
+
"000.006": "Your session has expired (failed to identify the intended token)",
|
|
115
|
+
"000.007": "The password should not contain personal information",
|
|
116
|
+
"000.008": "The password is longer than allowed",
|
|
117
|
+
"000.009": "The password must be at least %%min characters",
|
|
118
|
+
"000.010": "The password must contain at least one numeric character",
|
|
119
|
+
"000.011": "The password must contain at least one special character",
|
|
120
|
+
"000.012": "Password must contain at least one lowercase letter",
|
|
121
|
+
"000.013": "Password must contain at least one uppercase letter",
|
|
122
|
+
"000.014": "Generic error check the error variable",
|
|
123
|
+
"000.015": "The email does not correspond to a registered user",
|
|
124
|
+
"000.016": "The time to change your password has expired. Try again",
|
|
125
|
+
"000.017": "Did not start with the password recovery process",
|
|
126
|
+
"000.018": "Email format error",
|
|
127
|
+
"000.019": "The user has been disabled due to 3 invalid login attempts. The user will be available in %%1 minutes.",
|
|
128
|
+
"000.020": "This method is not configured on the server.",
|
|
129
|
+
"000.021": "The user has not created the temporary code, to advance.",
|
|
130
|
+
"000.023": "The code is invalid",
|
|
131
|
+
"000.024": "Error when sending the sms.",
|
|
132
|
+
"000.025": "Error when sending the email.",
|
|
133
|
+
"000.027": "This email has already been registered.",
|
|
134
|
+
"001.001": "The operation could not be performed",
|
|
135
|
+
"002.001": "User has no selected pins",
|
|
136
|
+
"002.002": "Could not update pins",
|
|
137
|
+
"002.003": "User already has that pin",
|
|
138
|
+
"002.004": "User does not have that pin",
|
|
139
|
+
"003.001": "The tag status could not be changed",
|
|
140
|
+
"003.002": "The tag name is required",
|
|
141
|
+
"003.003": "Select a value for the tag type",
|
|
142
|
+
"003.004": "A tag with the same name already exists",
|
|
143
|
+
"003.005": "Tag data could not be validated",
|
|
144
|
+
"003.006": "The tag could not be deleted",
|
|
145
|
+
"003.007": "The tag could not be updated",
|
|
146
|
+
"003.008": "There is no tag for id and type",
|
|
147
|
+
"004.001": "Could not change the status of the person",
|
|
148
|
+
"004.002": "The name of the person is required",
|
|
149
|
+
"004.003": "A person with the same name already exists",
|
|
150
|
+
"004.004": "Data validation error",
|
|
151
|
+
"004.005": "Could not delete person",
|
|
152
|
+
"005.001": "The username is required",
|
|
153
|
+
"005.002": "Another error in profile",
|
|
154
|
+
"005.003": "Account could not be linked",
|
|
155
|
+
"005.004": "You do not have a G-SUITE account linked to the system. Contact your administrator",
|
|
156
|
+
"006.001": "Failed to create a zone, duplicate zone",
|
|
157
|
+
"006.002": "Duplicate zone",
|
|
158
|
+
"006.003": "Description is required",
|
|
159
|
+
"006.004": "Color is mandatory",
|
|
160
|
+
"006.005": "Failed to delete a zone",
|
|
161
|
+
"007.001": "There is no survey",
|
|
162
|
+
"007.002": "Can not save survey",
|
|
163
|
+
"007.003": "Poll blocked by someone else",
|
|
164
|
+
"008.000": "Could not post a note",
|
|
165
|
+
"008.001": "No post was sent to publish",
|
|
166
|
+
"008.002": "This note is already pinned",
|
|
167
|
+
"008.003": "This note cannot be removed",
|
|
168
|
+
"008.004": "The note does not exist",
|
|
169
|
+
"008.005": "The scheduled publication date must be in the future",
|
|
170
|
+
"008.006": "Unidentified error, check the variable \"error\"",
|
|
171
|
+
"008.012": "Error getting XSD definition",
|
|
172
|
+
"008.013": "Failed to unlock note on exit",
|
|
173
|
+
"008.014": "Note locked by someone else",
|
|
174
|
+
"008.015": "This post has a draft",
|
|
175
|
+
"008.016": "The availability date is not valid",
|
|
176
|
+
"008.017": "The note could not be updated, with the desired last modification date",
|
|
177
|
+
"008.018": "There are fields with invalid content",
|
|
178
|
+
"009.002": "It is not a number",
|
|
179
|
+
"010.001": "The change could not be saved due to invalid fields",
|
|
180
|
+
"010.011": "Internal error while fetching the information",
|
|
181
|
+
"010.012": "The resource is locked by another user",
|
|
182
|
+
"015.001": "The video already exists",
|
|
183
|
+
"015.011": "An error occurred in the service",
|
|
184
|
+
"999.000": "The request does not have the expected format",
|
|
185
|
+
"999.001a": "The request has an error that was not captured. Contact your Administrator and detail the steps you followed",
|
|
186
|
+
"999.002a": "An error occurred in the service",
|
|
187
|
+
"999.003a": "CMS internal error. Please contact your Administrator",
|
|
188
|
+
"999.006a": "Login failed",
|
|
189
|
+
"999.009a": "Maximum number of pins exceeded"
|
|
190
|
+
}, f = {
|
|
191
|
+
"000.000": "El usuario ya se encuentra logueado",
|
|
192
|
+
"000.001": "El usuario no existe",
|
|
193
|
+
"000.002": "El usuario será deshabilitado luego de 3 intentos de inicio de sesión no válidos.",
|
|
194
|
+
"000.003": "El usuario está deshabilitado",
|
|
195
|
+
"000.004": "Error general",
|
|
196
|
+
"000.005": "Permisos insuficientes",
|
|
197
|
+
"000.006": "Su sesión ha expirado (falló identificando el token previsto)",
|
|
198
|
+
"000.007": "La contraseña no debe contener información personal",
|
|
199
|
+
"000.008": "La contraseña tiene una longitud mayor a la permitida",
|
|
200
|
+
"000.009": "La contraseña debe tener como mínimo %%min caracteres",
|
|
201
|
+
"000.010": "La contraseña debe contener al menos un caracter numérico",
|
|
202
|
+
"000.011": "La contraseña debe contener al menos un caracter especial",
|
|
203
|
+
"000.012": "La contraseña debe contener al menos una letra en minúscula",
|
|
204
|
+
"000.013": "La contraseña debe contener al menos una letra en mayúscula",
|
|
205
|
+
"000.014": "Error genérico revisar la variable error",
|
|
206
|
+
"000.015": "El email no corresponde a un usuario registrado",
|
|
207
|
+
"000.016": "Expiró el tiempo para cambiar su contraseña. Vuelva a intentarlo",
|
|
208
|
+
"000.017": "No inició con el proceso de recuperar contraseña",
|
|
209
|
+
"000.018": "Error con el formato del email",
|
|
210
|
+
"000.019": "El usuario ha sido deshabilitado debido a 3 intentos de inicio de sesión no válidos. El usuario estará disponible en %%1 minutos.",
|
|
211
|
+
"000.020": "No esta configurado ese método en el servidor.",
|
|
212
|
+
"000.021": "El usuario no tiene creado el código temporal, para avanzar.",
|
|
213
|
+
"000.023": "El código es inválido",
|
|
214
|
+
"000.024": "Error al enviar el sms.",
|
|
215
|
+
"000.025": "Error al enviar el email.",
|
|
216
|
+
"000.027": "Este email ya se encuentra registrado.",
|
|
217
|
+
"001.001": "No se pudo realizar la operación",
|
|
218
|
+
"002.001": "El usuario no tiene pines seleccionados",
|
|
219
|
+
"002.002": "No se pudo actualizar los pines",
|
|
220
|
+
"002.003": "El usuario ya tiene ese pin",
|
|
221
|
+
"002.004": "El usuario no tiene ese pin",
|
|
222
|
+
"003.001": "No se pudo cambiar el status del tag",
|
|
223
|
+
"003.002": "El nombre del tag es obligatorio",
|
|
224
|
+
"003.003": "Seleccione un valor para el tipo de tag",
|
|
225
|
+
"003.004": "Ya existe un tag con el mismo nombre",
|
|
226
|
+
"003.005": "No se pudo validar los datos del tag",
|
|
227
|
+
"003.006": "No se pudo borrar el tag",
|
|
228
|
+
"003.007": "No se pudo actualizar el tag",
|
|
229
|
+
"003.008": "No existe el tag para el id y el type",
|
|
230
|
+
"004.001": "No se pudo cambiar el status de la persona",
|
|
231
|
+
"004.002": "El nombre de la persona es obligatorio",
|
|
232
|
+
"004.003": "Ya existe una persona con el mismo nombre",
|
|
233
|
+
"004.004": "Error en validación de datos",
|
|
234
|
+
"004.005": "No se pudo borrar la persona",
|
|
235
|
+
"005.001": "El username es obligatorio",
|
|
236
|
+
"005.002": "Otro error en perfil",
|
|
237
|
+
"005.003": "No se pudo vincular la cuenta",
|
|
238
|
+
"005.004": "No tiene vinculada una cuenta G-SUITE con el sistema. Contacte con su administrador",
|
|
239
|
+
"006.001": "Error al crear una zona, zona duplicada",
|
|
240
|
+
"006.002": "Zona duplicada",
|
|
241
|
+
"006.003": "La descripción es obligatoria",
|
|
242
|
+
"006.004": "El color es obligatorio",
|
|
243
|
+
"006.005": "Error al borrar una zona",
|
|
244
|
+
"007.001": "No existe la encuesta",
|
|
245
|
+
"007.002": "No se puede guardar la encuesta",
|
|
246
|
+
"007.003": "Encuesta bloqueada por otra persona",
|
|
247
|
+
"008.000": "No se pudo publicar una nota",
|
|
248
|
+
"008.001": "No se enviaron noticias a publicar",
|
|
249
|
+
"008.002": "Esta nota ya esta pineada",
|
|
250
|
+
"008.003": "No se puede despinear esta nota",
|
|
251
|
+
"008.004": "La nota no existe",
|
|
252
|
+
"008.005": "La fecha de publicación programada debe ser en el futuro",
|
|
253
|
+
"008.006": "Error no identificado, revisar la variable \"error\"",
|
|
254
|
+
"008.012": "Error al obtener definición del XSD",
|
|
255
|
+
"008.013": "Error al desbloquear la nota en el exit",
|
|
256
|
+
"008.014": "Nota bloqueada por otra persona",
|
|
257
|
+
"008.015": "Esta noticia tiene un borrador",
|
|
258
|
+
"008.016": "La fecha de disponibilidad no es válida",
|
|
259
|
+
"008.017": "No se pudo actualizar la nota, con la fecha de ultima modificacion deseada",
|
|
260
|
+
"008.018": "Algunos campos no cumplen con el formato valido",
|
|
261
|
+
"009.002": "No es un número ",
|
|
262
|
+
"010.001": "No se pudo guardar el cambio por errores en los campos.",
|
|
263
|
+
"010.011": "Error interno al consultar la información",
|
|
264
|
+
"010.012": "El recurso está bloqueado por otro usuario",
|
|
265
|
+
"015.001": "El vídeo ya existe",
|
|
266
|
+
"015.011": "Se produjo un error en el servicio",
|
|
267
|
+
"999.000": "El requerimiento no cuenta con el formato esperado",
|
|
268
|
+
"999.001a": "El requerimiento tiene un error que no se capturó. Comuniquese con su Administrador y detalle los pasos que siguió",
|
|
269
|
+
"999.002a": "Se produjo un error en el servicio",
|
|
270
|
+
"999.003a": "Error interno de CMS. Comuniquese con su administrador",
|
|
271
|
+
"999.006a": "Falló el login",
|
|
272
|
+
"999.009a": "Supero el máximo de pines"
|
|
273
|
+
}, p = {
|
|
274
|
+
"000.000": "O usuário já está logado",
|
|
275
|
+
"000.001": "O usuário não existe",
|
|
276
|
+
"000.002": "O usuário será desabilitado após 3 tentativas de login inválidas.",
|
|
277
|
+
"000.003": "O usuário está desabilitado",
|
|
278
|
+
"000.004": "Erro geral",
|
|
279
|
+
"000.005": "Permissões insuficientes",
|
|
280
|
+
"000.006": "Sua sessão expirou (falha ao identificar o token pretendido)",
|
|
281
|
+
"000.007": "A senha não deve conter informações pessoais",
|
|
282
|
+
"000.008": "A senha é maior que o permitido",
|
|
283
|
+
"000.009": "A senha deve ter pelo menos %%min caracteres",
|
|
284
|
+
"000.010": "A senha deve conter pelo menos um caractere numérico",
|
|
285
|
+
"000.011": "A senha deve conter pelo menos um caractere especial",
|
|
286
|
+
"000.012": "A senha deve conter pelo menos uma letra minúscula",
|
|
287
|
+
"000.013": "A senha deve conter pelo menos uma letra maiúscula",
|
|
288
|
+
"000.014": "Erro genérico verifique a variável de erro",
|
|
289
|
+
"000.015": "O email não corresponde a um usuário registrado",
|
|
290
|
+
"000.016": "O tempo para alterar sua senha expirou. tente novamente",
|
|
291
|
+
"000.017": "Não iniciou o processo de recuperação de senha",
|
|
292
|
+
"000.018": "Erro no formato do e-mail",
|
|
293
|
+
"000.019": "O usuário foi desativado devido a 3 tentativas de login inválidas. O usuário estará disponível em %%1 minutos.",
|
|
294
|
+
"000.020": "Este método não está configurado no servidor.",
|
|
295
|
+
"000.021": "O usuário não criou o código temporal para avançar.",
|
|
296
|
+
"000.023": "O código é inválido",
|
|
297
|
+
"000.024": "Erro ao enviar a mensagem.",
|
|
298
|
+
"000.025": "Erro ao enviar o email.",
|
|
299
|
+
"000.027": "Este e-mail já está registado.",
|
|
300
|
+
"001.001": "A operação não pôde ser executada",
|
|
301
|
+
"002.001": "Usuário não selecionou pinos",
|
|
302
|
+
"002.002": "Não foi possível atualizar os pinos",
|
|
303
|
+
"002.003": "O usuário já possui esse pin",
|
|
304
|
+
"002.004": "Usuário não possui esse pin",
|
|
305
|
+
"003.001": "Não foi possível alterar o status da tag",
|
|
306
|
+
"003.002": "O nome da tag é obrigatório",
|
|
307
|
+
"003.003": "Selecione um valor para o tipo de tag",
|
|
308
|
+
"003.004": "Já existe uma tag com o mesmo nome",
|
|
309
|
+
"003.005": "Os dados da tag não puderam ser validados",
|
|
310
|
+
"003.006": "A tag não pôde ser excluída",
|
|
311
|
+
"003.007": "A tag não pôde ser atualizada",
|
|
312
|
+
"003.008": "Não há tag para id e tipo",
|
|
313
|
+
"004.001": "Não foi possível alterar o status da pessoa",
|
|
314
|
+
"004.002": "O nome da pessoa é obrigatório",
|
|
315
|
+
"004.003": "Já existe uma pessoa com o mesmo nome",
|
|
316
|
+
"004.004": "Falha na validação de dados",
|
|
317
|
+
"004.005": "Não foi possível excluir a pessoa",
|
|
318
|
+
"005.001": "O nome de usuário é obrigatório",
|
|
319
|
+
"005.002": "Outro erro no perfil",
|
|
320
|
+
"005.003": "A conta não pôde ser vinculada",
|
|
321
|
+
"005.004": "Você não tem uma conta G-SUITE vinculada ao sistema. Entre em contato com seu administrador",
|
|
322
|
+
"006.001": "Falha ao criar uma zona, zona duplicada",
|
|
323
|
+
"006.002": "Zona duplicada",
|
|
324
|
+
"006.003": "A descrição é obrigatória",
|
|
325
|
+
"006.004": "A cor é obrigatória",
|
|
326
|
+
"006.005": "Falha ao excluir uma zona",
|
|
327
|
+
"007.001": "Não há pesquisa",
|
|
328
|
+
"007.002": "Não é possível salvar pesquisa",
|
|
329
|
+
"007.003": "Enquete bloqueada por outra pessoa",
|
|
330
|
+
"008.000": "Não foi possível postar uma nota",
|
|
331
|
+
"008.001": "Nenhuma notícia foi enviada para publicação",
|
|
332
|
+
"008.002": "Esta nota já está fixada",
|
|
333
|
+
"008.003": "Esta nota não pode ser removida",
|
|
334
|
+
"008.004": "A nota não existe",
|
|
335
|
+
"008.005": "A data de publicação programada deve ser futura",
|
|
336
|
+
"008.006": "Erro não identificado, verifique a variável \"erro\"",
|
|
337
|
+
"008.012": "Erro ao obter definição XSD",
|
|
338
|
+
"008.013": "Falha ao desbloquear nota ao sair",
|
|
339
|
+
"008.014": "Nota bloqueada por outra pessoa",
|
|
340
|
+
"008.015": "Esta notícia tem um rascunho",
|
|
341
|
+
"008.016": "A data de disponibilidade não é válida",
|
|
342
|
+
"008.017": "Não foi possível atualizar a nota, com a data da última modificação desejada",
|
|
343
|
+
"008.018": "Existem campos com conteúdo inválido",
|
|
344
|
+
"009.002": "Não é um número",
|
|
345
|
+
"010.001": "A alteração não pôde ser salva devido a campos inválidos",
|
|
346
|
+
"010.011": "Erro interno ao consultar a informação",
|
|
347
|
+
"010.012": "O recurso está bloqueado por outro usuário",
|
|
348
|
+
"015.001": "O vídeo já existe",
|
|
349
|
+
"015.011": "Ocorreu um erro no serviço",
|
|
350
|
+
"999.000": "A solicitação não tem o formato esperado",
|
|
351
|
+
"999.001a": "O pedido tem um erro que não foi capturado. Entre em contato com seu administrador e detalhe as etapas que você seguiu",
|
|
352
|
+
"999.002a": "Ocorreu um erro no serviço",
|
|
353
|
+
"999.003a": "Erro interno do CMS. Entre em contato com seu administrador",
|
|
354
|
+
"999.006a": "Falha no login",
|
|
355
|
+
"999.009a": "Número máximo de pinos excedido"
|
|
356
|
+
}, m = {
|
|
357
|
+
es: f,
|
|
358
|
+
en: d,
|
|
359
|
+
pt: p
|
|
360
|
+
}, h = new Set([
|
|
361
|
+
"000.005",
|
|
362
|
+
"000.001",
|
|
363
|
+
"000.015",
|
|
364
|
+
"003.008",
|
|
365
|
+
"008.004",
|
|
366
|
+
"000.018",
|
|
367
|
+
"999.000",
|
|
368
|
+
"009.002",
|
|
369
|
+
"004.004",
|
|
370
|
+
"008.018",
|
|
371
|
+
"000.007",
|
|
372
|
+
"000.008",
|
|
373
|
+
"000.009",
|
|
374
|
+
"000.010",
|
|
375
|
+
"000.011",
|
|
376
|
+
"000.012",
|
|
377
|
+
"000.013",
|
|
378
|
+
"000.027",
|
|
379
|
+
"002.001",
|
|
380
|
+
"002.003",
|
|
381
|
+
"002.004",
|
|
382
|
+
"003.004",
|
|
383
|
+
"004.003",
|
|
384
|
+
"006.002",
|
|
385
|
+
"999.009a"
|
|
386
|
+
]);
|
|
387
|
+
function g(e) {
|
|
388
|
+
if (e == null) return;
|
|
389
|
+
if (Array.isArray(e)) {
|
|
390
|
+
let t = e.find((e) => e != null && e !== "");
|
|
391
|
+
return t === void 0 ? void 0 : String(t);
|
|
392
|
+
}
|
|
393
|
+
let t = String(e);
|
|
394
|
+
return t === "" ? void 0 : t;
|
|
395
|
+
}
|
|
396
|
+
function _(e, t = "es") {
|
|
397
|
+
let n = g(e);
|
|
398
|
+
if (!n) return;
|
|
399
|
+
let r = m[t] ?? d;
|
|
400
|
+
return r[n] ?? r[`${n}a`] ?? d[n] ?? d[`${n}a`];
|
|
401
|
+
}
|
|
402
|
+
function v(e) {
|
|
403
|
+
let t = g(e);
|
|
404
|
+
return t && h.has(t) ? "warning" : "error";
|
|
405
|
+
}
|
|
406
|
+
//#endregion
|
|
407
|
+
//#region src/lib/utils/site-selector.ts
|
|
408
|
+
var y = e.menuSurface, b = e.secondary, ee = e.white, x = "bluestack-es";
|
|
409
|
+
function S(e) {
|
|
410
|
+
return e.flatMap((e) => e.publications);
|
|
411
|
+
}
|
|
412
|
+
function C(e, t) {
|
|
413
|
+
return S(e).find((e) => String(e.id) === t);
|
|
414
|
+
}
|
|
415
|
+
function w(e, t) {
|
|
416
|
+
return S(e).find((e) => String(e.id) === t)?.description ?? "Seleccionar publicación";
|
|
417
|
+
}
|
|
418
|
+
function T(e) {
|
|
419
|
+
let t = S(e)[0];
|
|
420
|
+
return t ? String(t.id) : "1";
|
|
421
|
+
}
|
|
422
|
+
function E(e) {
|
|
423
|
+
let t = Number(e);
|
|
424
|
+
return Number.isFinite(t) && t > 0 ? t : 1;
|
|
425
|
+
}
|
|
426
|
+
//#endregion
|
|
427
|
+
//#region src/lib/utils/site-time.ts
|
|
428
|
+
function D(e) {
|
|
429
|
+
if (!e) return 0;
|
|
430
|
+
let t = String(e).trim().replace(/^(GMT|UTC)/i, "").trim().match(/^([+-]?)(\d{1,2})(?::(\d{2}))?$/);
|
|
431
|
+
if (!t) return 0;
|
|
432
|
+
let n = t[1] === "-" ? -1 : 1, r = Number(t[2]), i = t[3] ? Number(t[3]) : 0;
|
|
433
|
+
return n * (r * 60 + i);
|
|
434
|
+
}
|
|
435
|
+
function O(e, t) {
|
|
436
|
+
return e + D(t) * 6e4;
|
|
437
|
+
}
|
|
438
|
+
var k = {
|
|
439
|
+
day: "2-digit",
|
|
440
|
+
month: "2-digit",
|
|
441
|
+
year: "numeric",
|
|
442
|
+
hour: "2-digit",
|
|
443
|
+
minute: "2-digit"
|
|
444
|
+
};
|
|
445
|
+
function A(e, t, n, r = k) {
|
|
446
|
+
let i = O(e, t);
|
|
447
|
+
return new Intl.DateTimeFormat(n, {
|
|
448
|
+
...r,
|
|
449
|
+
timeZone: "UTC"
|
|
450
|
+
}).format(i);
|
|
451
|
+
}
|
|
452
|
+
function j(e, t, n = k) {
|
|
453
|
+
return A(Date.now(), e, t, n);
|
|
454
|
+
}
|
|
455
|
+
//#endregion
|
|
456
|
+
//#region src/lib/services/auth.ts
|
|
457
|
+
var M = class {
|
|
458
|
+
props;
|
|
459
|
+
authentication;
|
|
460
|
+
constructor(e) {
|
|
461
|
+
this.props = e, this.authentication = e.authentication;
|
|
462
|
+
}
|
|
463
|
+
relogin = async () => {
|
|
464
|
+
try {
|
|
465
|
+
return (await this.props.axiosApi.post("/auth/relogin", { authentication: this.authentication })).data;
|
|
466
|
+
} catch (e) {
|
|
467
|
+
return console.error("[/auth/relogin]", e), Promise.reject(e);
|
|
468
|
+
}
|
|
469
|
+
};
|
|
470
|
+
logout = async () => {
|
|
471
|
+
try {
|
|
472
|
+
return (await this.props.axiosApi.post("/auth/logout", { authentication: this.authentication })).data;
|
|
473
|
+
} catch (e) {
|
|
474
|
+
return console.error("[/auth/logout]", e), Promise.reject(e);
|
|
475
|
+
}
|
|
476
|
+
};
|
|
477
|
+
changePassword = async (e) => {
|
|
478
|
+
try {
|
|
479
|
+
return (await this.props.axiosApi.post("/auth/changePassword", {
|
|
480
|
+
authentication: this.authentication,
|
|
481
|
+
newPassword: e
|
|
482
|
+
})).data;
|
|
483
|
+
} catch (e) {
|
|
484
|
+
return console.error("[/auth/changePassword]", e), Promise.reject(e);
|
|
485
|
+
}
|
|
486
|
+
};
|
|
487
|
+
getPermissions = async () => {
|
|
488
|
+
try {
|
|
489
|
+
return (await this.props.axiosApi.post("/auth/permissions", { authentication: this.authentication })).data;
|
|
490
|
+
} catch (e) {
|
|
491
|
+
return console.error("[/auth/permissions]", e), Promise.reject(e);
|
|
492
|
+
}
|
|
493
|
+
};
|
|
494
|
+
getModulesAvailable = async () => {
|
|
495
|
+
try {
|
|
496
|
+
return (await this.props.axiosApi.post("/auth/modulesAvailable", { authentication: this.authentication })).data;
|
|
497
|
+
} catch (e) {
|
|
498
|
+
return console.error("[/auth/modulesAvailable]", e), Promise.reject(e);
|
|
499
|
+
}
|
|
500
|
+
};
|
|
501
|
+
getCreatePermissions = async () => {
|
|
502
|
+
try {
|
|
503
|
+
return (await this.props.axiosApi.post("/auth/create", { authentication: this.authentication })).data;
|
|
504
|
+
} catch (e) {
|
|
505
|
+
return console.error("[/auth/create]", e), Promise.reject(e);
|
|
506
|
+
}
|
|
507
|
+
};
|
|
508
|
+
}, N = class {
|
|
509
|
+
props;
|
|
510
|
+
authentication;
|
|
511
|
+
constructor(e) {
|
|
512
|
+
this.props = e, this.authentication = e.authentication;
|
|
513
|
+
}
|
|
514
|
+
countNotifications = async () => {
|
|
515
|
+
try {
|
|
516
|
+
return (await this.props.axiosApi.post("/dashboard/countNotifications", { authentication: this.authentication })).data;
|
|
517
|
+
} catch (e) {
|
|
518
|
+
return console.error("[/dashboard/countNotifications]", e), Promise.reject(e);
|
|
519
|
+
}
|
|
520
|
+
};
|
|
521
|
+
getNotifications = async () => {
|
|
522
|
+
try {
|
|
523
|
+
return (await this.props.axiosApi.post("/dashboard/notification", { authentication: this.authentication })).data;
|
|
524
|
+
} catch (e) {
|
|
525
|
+
return console.error("[/dashboard/notification]", e), Promise.reject(e);
|
|
526
|
+
}
|
|
527
|
+
};
|
|
528
|
+
}, P = class {
|
|
529
|
+
props;
|
|
530
|
+
authentication;
|
|
531
|
+
constructor(e) {
|
|
532
|
+
this.props = e, this.authentication = e.authentication;
|
|
533
|
+
}
|
|
534
|
+
getProfile = async () => {
|
|
535
|
+
try {
|
|
536
|
+
return (await this.props.axiosApi.post("/profile/get", { authentication: this.authentication })).data;
|
|
537
|
+
} catch (e) {
|
|
538
|
+
return console.error("[/profile/get]", e), Promise.reject(e);
|
|
539
|
+
}
|
|
540
|
+
};
|
|
541
|
+
updateProfile = async (e) => {
|
|
542
|
+
try {
|
|
543
|
+
return (await this.props.axiosApi.post("/profile/update", {
|
|
544
|
+
authentication: this.authentication,
|
|
545
|
+
user: e
|
|
546
|
+
})).data;
|
|
547
|
+
} catch (e) {
|
|
548
|
+
return console.error("[/profile/update]", e), Promise.reject(e);
|
|
549
|
+
}
|
|
550
|
+
};
|
|
551
|
+
deleteImage = async () => {
|
|
552
|
+
try {
|
|
553
|
+
return (await this.props.axiosApi.post("/profile/image/delete", { authentication: this.authentication })).data;
|
|
554
|
+
} catch (e) {
|
|
555
|
+
return console.error("[/profile/image/delete]", e), Promise.reject(e);
|
|
556
|
+
}
|
|
557
|
+
};
|
|
558
|
+
getModuleAlerts = async () => {
|
|
559
|
+
try {
|
|
560
|
+
return (await this.props.axiosApi.post("/profile/moduleAlerts/get", { authentication: this.authentication })).data;
|
|
561
|
+
} catch (e) {
|
|
562
|
+
return console.error("[/profile/moduleAlerts/get]", e), Promise.reject(e);
|
|
563
|
+
}
|
|
564
|
+
};
|
|
565
|
+
hideModuleAlert = async (e) => {
|
|
566
|
+
try {
|
|
567
|
+
return (await this.props.axiosApi.post("/profile/moduleAlerts/hide", {
|
|
568
|
+
authentication: this.authentication,
|
|
569
|
+
module: e
|
|
570
|
+
})).data;
|
|
571
|
+
} catch (e) {
|
|
572
|
+
return console.error("[/profile/moduleAlerts/hide]", e), Promise.reject(e);
|
|
573
|
+
}
|
|
574
|
+
};
|
|
575
|
+
addPins = async (e) => {
|
|
576
|
+
try {
|
|
577
|
+
return (await this.props.axiosApi.post("/profile/pines/add", {
|
|
578
|
+
authentication: this.authentication,
|
|
579
|
+
pines: { pin: e }
|
|
580
|
+
})).data;
|
|
581
|
+
} catch (e) {
|
|
582
|
+
return console.error("[/profile/pines/add]", e), Promise.reject(e);
|
|
583
|
+
}
|
|
584
|
+
};
|
|
585
|
+
deletePins = async (e) => {
|
|
586
|
+
try {
|
|
587
|
+
return (await this.props.axiosApi.post("/profile/pines/delete", {
|
|
588
|
+
authentication: this.authentication,
|
|
589
|
+
pines: { pin: e }
|
|
590
|
+
})).data;
|
|
591
|
+
} catch (e) {
|
|
592
|
+
return console.error("[/profile/pines/delete]", e), Promise.reject(e);
|
|
593
|
+
}
|
|
594
|
+
};
|
|
595
|
+
getPins = async () => {
|
|
596
|
+
try {
|
|
597
|
+
return (await this.props.axiosApi.post("/profile/pines/get", { authentication: this.authentication })).data;
|
|
598
|
+
} catch (e) {
|
|
599
|
+
return console.error("[/profile/pines/get]", e), Promise.reject(e);
|
|
600
|
+
}
|
|
601
|
+
};
|
|
602
|
+
disableTwoFactorMethod = async (e) => {
|
|
603
|
+
try {
|
|
604
|
+
return (await this.props.axiosApi.post("/profile/twoFactor/method/disable", {
|
|
605
|
+
authentication: this.authentication,
|
|
606
|
+
method: e
|
|
607
|
+
})).data;
|
|
608
|
+
} catch (e) {
|
|
609
|
+
return console.error("[/profile/twoFactor/method/disable]", e), Promise.reject(e);
|
|
610
|
+
}
|
|
611
|
+
};
|
|
612
|
+
enableTwoFactorMethod = async (e) => {
|
|
613
|
+
try {
|
|
614
|
+
return (await this.props.axiosApi.post("/profile/twoFactor/method/enable", {
|
|
615
|
+
authentication: this.authentication,
|
|
616
|
+
method: e
|
|
617
|
+
})).data;
|
|
618
|
+
} catch (e) {
|
|
619
|
+
return console.error("[/profile/twoFactor/method/enable]", e), Promise.reject(e);
|
|
620
|
+
}
|
|
621
|
+
};
|
|
622
|
+
setTwoFactorActive = async () => {
|
|
623
|
+
try {
|
|
624
|
+
return (await this.props.axiosApi.post("/profile/twoFactor/setActive", { authentication: this.authentication })).data;
|
|
625
|
+
} catch (e) {
|
|
626
|
+
return console.error("[/profile/twoFactor/setActive]", e), Promise.reject(e);
|
|
627
|
+
}
|
|
628
|
+
};
|
|
629
|
+
setTwoFactorEmail = async (e) => {
|
|
630
|
+
try {
|
|
631
|
+
return (await this.props.axiosApi.post("/profile/twoFactor/setEmail", {
|
|
632
|
+
authentication: this.authentication,
|
|
633
|
+
email: e
|
|
634
|
+
})).data;
|
|
635
|
+
} catch (e) {
|
|
636
|
+
return console.error("[/profile/twoFactor/setEmail]", e), Promise.reject(e);
|
|
637
|
+
}
|
|
638
|
+
};
|
|
639
|
+
setTwoFactorFavorite = async (e) => {
|
|
640
|
+
try {
|
|
641
|
+
return (await this.props.axiosApi.post("/profile/twoFactor/setFavorite", {
|
|
642
|
+
authentication: this.authentication,
|
|
643
|
+
method: e
|
|
644
|
+
})).data;
|
|
645
|
+
} catch (e) {
|
|
646
|
+
return console.error("[/profile/twoFactor/setFavorite]", e), Promise.reject(e);
|
|
647
|
+
}
|
|
648
|
+
};
|
|
649
|
+
setTwoFactorPhone = async (e) => {
|
|
650
|
+
try {
|
|
651
|
+
return (await this.props.axiosApi.post("/profile/twoFactor/setPhone", {
|
|
652
|
+
authentication: this.authentication,
|
|
653
|
+
phone: e
|
|
654
|
+
})).data;
|
|
655
|
+
} catch (e) {
|
|
656
|
+
return console.error("[/profile/twoFactor/setPhone]", e), Promise.reject(e);
|
|
657
|
+
}
|
|
658
|
+
};
|
|
659
|
+
showOtc = async () => {
|
|
660
|
+
try {
|
|
661
|
+
return (await this.props.axiosApi.post("/profile/twoFactor/showOtc", { authentication: this.authentication })).data;
|
|
662
|
+
} catch (e) {
|
|
663
|
+
return console.error("[/profile/twoFactor/showOtc]", e), Promise.reject(e);
|
|
664
|
+
}
|
|
665
|
+
};
|
|
666
|
+
}, F = class {
|
|
667
|
+
props;
|
|
668
|
+
authentication;
|
|
669
|
+
constructor(e) {
|
|
670
|
+
this.props = e, this.authentication = e.authentication;
|
|
671
|
+
}
|
|
672
|
+
getPublications = async () => {
|
|
673
|
+
try {
|
|
674
|
+
return (await this.props.axiosApi.post("/publications/get", { authentication: this.authentication })).data;
|
|
675
|
+
} catch (e) {
|
|
676
|
+
return console.error("[/publications/get]", e), Promise.reject(e);
|
|
677
|
+
}
|
|
678
|
+
};
|
|
679
|
+
getDefaultPublication = async () => {
|
|
680
|
+
try {
|
|
681
|
+
return (await this.props.axiosApi.post("/publications/default", { authentication: this.authentication })).data;
|
|
682
|
+
} catch (e) {
|
|
683
|
+
return console.error("[/publications/default]", e), Promise.reject(e);
|
|
684
|
+
}
|
|
685
|
+
};
|
|
686
|
+
}, I = class {
|
|
687
|
+
props;
|
|
688
|
+
authentication;
|
|
689
|
+
constructor(e) {
|
|
690
|
+
this.props = e, this.authentication = e.authentication;
|
|
691
|
+
}
|
|
692
|
+
getSites = async () => {
|
|
693
|
+
try {
|
|
694
|
+
return (await this.props.axiosApi.post("/sites/get", { authentication: this.authentication })).data;
|
|
695
|
+
} catch (e) {
|
|
696
|
+
return console.error("[/sites/get]", e), Promise.reject(e);
|
|
697
|
+
}
|
|
698
|
+
};
|
|
699
|
+
}, L = class {
|
|
700
|
+
props;
|
|
701
|
+
constructor(e) {
|
|
702
|
+
this.props = e;
|
|
703
|
+
}
|
|
704
|
+
login = async (e, t, n, r = "Online") => {
|
|
705
|
+
try {
|
|
706
|
+
let i = new URLSearchParams({
|
|
707
|
+
username: e,
|
|
708
|
+
password: t,
|
|
709
|
+
browserId: n,
|
|
710
|
+
project: r
|
|
711
|
+
});
|
|
712
|
+
return (await this.props.axiosApi.post("/auth/login", i, { headers: { "Content-Type": "application/x-www-form-urlencoded" } })).data;
|
|
713
|
+
} catch (e) {
|
|
714
|
+
return console.error("[/auth/login]", e), Promise.reject(e);
|
|
715
|
+
}
|
|
716
|
+
};
|
|
717
|
+
forgotPassword = async (e) => {
|
|
718
|
+
try {
|
|
719
|
+
let t = new URLSearchParams({ email: e });
|
|
720
|
+
return (await this.props.axiosApi.post("/auth/forgotPassword", t, { headers: { "Content-Type": "application/x-www-form-urlencoded" } })).data;
|
|
721
|
+
} catch (e) {
|
|
722
|
+
return console.error("[/auth/forgotPassword]", e), Promise.reject(e);
|
|
723
|
+
}
|
|
724
|
+
};
|
|
725
|
+
forgotUsername = async (e) => {
|
|
726
|
+
try {
|
|
727
|
+
let t = new URLSearchParams({ email: e });
|
|
728
|
+
return (await this.props.axiosApi.post("/auth/forgotUsername", t, { headers: { "Content-Type": "application/x-www-form-urlencoded" } })).data;
|
|
729
|
+
} catch (e) {
|
|
730
|
+
return console.error("[/auth/forgotUsername]", e), Promise.reject(e);
|
|
731
|
+
}
|
|
732
|
+
};
|
|
733
|
+
passwordConfiguration = async () => {
|
|
734
|
+
try {
|
|
735
|
+
return (await this.props.axiosApi.get("/auth/passwordConfiguration")).data;
|
|
736
|
+
} catch (e) {
|
|
737
|
+
return console.error("[/auth/passwordConfiguration]", e), Promise.reject(e);
|
|
738
|
+
}
|
|
739
|
+
};
|
|
740
|
+
validatePassword = async (e, t) => {
|
|
741
|
+
try {
|
|
742
|
+
return (await this.props.axiosApi.post("/auth/validatePassword", { user: {
|
|
743
|
+
username: e,
|
|
744
|
+
password: t
|
|
745
|
+
} })).data;
|
|
746
|
+
} catch (e) {
|
|
747
|
+
return console.error("[/auth/validatePassword]", e), Promise.reject(e);
|
|
748
|
+
}
|
|
749
|
+
};
|
|
750
|
+
loginValid = async (e) => {
|
|
751
|
+
try {
|
|
752
|
+
return (await this.props.axiosApi.post("/auth/loginValid", { data: e })).data;
|
|
753
|
+
} catch (e) {
|
|
754
|
+
return console.error("[/auth/loginValid]", e), Promise.reject(e);
|
|
755
|
+
}
|
|
756
|
+
};
|
|
757
|
+
setNewPassword = async (e, t, n) => {
|
|
758
|
+
try {
|
|
759
|
+
return (await this.props.axiosApi.post("/auth/setNewPassword", {
|
|
760
|
+
authentication: { browserId: n },
|
|
761
|
+
codeTemp: e,
|
|
762
|
+
newPassword: t
|
|
763
|
+
})).data;
|
|
764
|
+
} catch (e) {
|
|
765
|
+
return console.error("[/auth/setNewPassword]", e), Promise.reject(e);
|
|
766
|
+
}
|
|
767
|
+
};
|
|
768
|
+
twoFactor = {
|
|
769
|
+
generateCode: async (e) => {
|
|
770
|
+
try {
|
|
771
|
+
return (await this.props.axiosApi.post("/auth/twoFactor/generateCode", { authentication: e })).data;
|
|
772
|
+
} catch (e) {
|
|
773
|
+
return console.error("[/auth/twoFactor/generateCode]", e), Promise.reject(e);
|
|
774
|
+
}
|
|
775
|
+
},
|
|
776
|
+
sendCode: async (e) => {
|
|
777
|
+
try {
|
|
778
|
+
return (await this.props.axiosApi.post("/auth/twoFactor/sendCode", { ...e })).data;
|
|
779
|
+
} catch (e) {
|
|
780
|
+
return console.error("[/auth/twoFactor/sendCode]", e), Promise.reject(e);
|
|
781
|
+
}
|
|
782
|
+
},
|
|
783
|
+
verify: async (e) => {
|
|
784
|
+
try {
|
|
785
|
+
let { tempId: t, code: n, method: r, user: i, browserId: a, project: o } = e;
|
|
786
|
+
return (await this.props.axiosApi.post("/auth/twoFactor/verify", {
|
|
787
|
+
tempId: t,
|
|
788
|
+
code: n,
|
|
789
|
+
method: r,
|
|
790
|
+
user: i,
|
|
791
|
+
authentication: {
|
|
792
|
+
browserId: a,
|
|
793
|
+
project: o
|
|
794
|
+
}
|
|
795
|
+
})).data;
|
|
796
|
+
} catch (e) {
|
|
797
|
+
return console.error("[/auth/twoFactor/verify]", e), Promise.reject(e);
|
|
798
|
+
}
|
|
799
|
+
}
|
|
800
|
+
};
|
|
801
|
+
}, R = (e) => btoa(e), z = class {
|
|
802
|
+
props;
|
|
803
|
+
authentication;
|
|
804
|
+
constructor(e) {
|
|
805
|
+
this.props = e, this.authentication = e.authentication;
|
|
806
|
+
}
|
|
807
|
+
authParams = () => {
|
|
808
|
+
let { token: e, browserId: t, publication: n, siteName: r, project: i } = this.authentication;
|
|
809
|
+
return {
|
|
810
|
+
token: R(e),
|
|
811
|
+
browserId: t,
|
|
812
|
+
publication: n,
|
|
813
|
+
siteName: r,
|
|
814
|
+
project: i
|
|
815
|
+
};
|
|
816
|
+
};
|
|
817
|
+
upload = async (e, t, n) => {
|
|
818
|
+
try {
|
|
819
|
+
let r = new FormData();
|
|
820
|
+
return r.append(n?.fileField ?? "files[]", t), n?.fields && Object.entries(n.fields).forEach(([e, t]) => {
|
|
821
|
+
r.append(e, t);
|
|
822
|
+
}), (await this.props.axiosApi.post(e, r, { params: this.authParams() })).data;
|
|
823
|
+
} catch (t) {
|
|
824
|
+
return console.error("[" + e + "]", t), Promise.reject(t);
|
|
825
|
+
}
|
|
826
|
+
};
|
|
827
|
+
uploadImageVFS = (e, t) => this.upload("/images/uploadVFS", e, { fields: t });
|
|
828
|
+
uploadImageSERVER = (e, t) => this.upload("/images/uploadSERVER", e, { fields: t });
|
|
829
|
+
uploadImageAMZ = (e, t) => this.upload("/images/uploadAMZ", e, { fields: t });
|
|
830
|
+
uploadProfilePicture = (e, t) => this.upload("/profile/image/uploadUserPicture", e, { fields: t });
|
|
831
|
+
uploadTranscribeAMZ = (e, t) => this.upload("/transcribe/uploadAMZ", e, { fields: t });
|
|
832
|
+
uploadVideoS3 = (e, t, n) => this.upload("/videos/nativos/uploadS3", e, {
|
|
833
|
+
fileField: "item[0]",
|
|
834
|
+
fields: {
|
|
835
|
+
videoPath: t,
|
|
836
|
+
...n ?? {}
|
|
837
|
+
}
|
|
838
|
+
});
|
|
839
|
+
}, B = class {
|
|
840
|
+
props;
|
|
841
|
+
authentication;
|
|
842
|
+
constructor(e) {
|
|
843
|
+
this.props = e, this.authentication = e.authentication;
|
|
844
|
+
}
|
|
845
|
+
buildUrl = (e, t) => {
|
|
846
|
+
let n = this.props.axiosApi.defaults.baseURL ?? "", r = Object.entries(t).filter(([, e]) => e != null && e !== "").map(([e, t]) => e + "=" + t).join("&");
|
|
847
|
+
return n + e + "?" + r;
|
|
848
|
+
};
|
|
849
|
+
getVideoEmbeddedPreviewUrl = (e) => {
|
|
850
|
+
let { token: t, browserId: n, siteName: r, publication: i } = this.authentication;
|
|
851
|
+
return this.buildUrl("/videos/edit/previewEmbedded", {
|
|
852
|
+
browserID: n,
|
|
853
|
+
authToken: btoa(t),
|
|
854
|
+
siteName: r,
|
|
855
|
+
publication: i,
|
|
856
|
+
path: e
|
|
857
|
+
});
|
|
858
|
+
};
|
|
859
|
+
getCkeditorPreviewUrl = (e, t) => {
|
|
860
|
+
let { token: n, browserId: r, siteName: i, publication: a } = this.authentication;
|
|
861
|
+
return this.buildUrl("/ckeditor/" + e, {
|
|
862
|
+
authToken: btoa(n),
|
|
863
|
+
browserID: r,
|
|
864
|
+
siteName: i,
|
|
865
|
+
publication: a,
|
|
866
|
+
...t
|
|
867
|
+
});
|
|
868
|
+
};
|
|
869
|
+
}, te = class {
|
|
870
|
+
props;
|
|
871
|
+
authentication;
|
|
872
|
+
constructor(e) {
|
|
873
|
+
this.props = e, this.authentication = e.authentication;
|
|
874
|
+
}
|
|
875
|
+
getAudios = async (e = {}) => {
|
|
876
|
+
try {
|
|
877
|
+
return (await this.props.axiosApi.post("/audios/get", {
|
|
878
|
+
authentication: this.authentication,
|
|
879
|
+
filters: e
|
|
880
|
+
})).data;
|
|
881
|
+
} catch (e) {
|
|
882
|
+
return console.error("[/audios/get]", e), Promise.reject(e);
|
|
883
|
+
}
|
|
884
|
+
};
|
|
885
|
+
getAdminConfiguration = async () => {
|
|
886
|
+
try {
|
|
887
|
+
return (await this.props.axiosApi.post("/audios/adminConfiguration", { authentication: this.authentication })).data;
|
|
888
|
+
} catch (e) {
|
|
889
|
+
return console.error("[/audios/adminConfiguration]", e), Promise.reject(e);
|
|
890
|
+
}
|
|
891
|
+
};
|
|
892
|
+
}, V = class {
|
|
893
|
+
props;
|
|
894
|
+
authentication;
|
|
895
|
+
constructor(e) {
|
|
896
|
+
this.props = e, this.authentication = e.authentication;
|
|
897
|
+
}
|
|
898
|
+
getCategories = async (e) => {
|
|
899
|
+
try {
|
|
900
|
+
return (await this.props.axiosApi.post("/categories/get", {
|
|
901
|
+
authentication: this.authentication,
|
|
902
|
+
filter: e
|
|
903
|
+
})).data;
|
|
904
|
+
} catch (e) {
|
|
905
|
+
return console.error("[/categories/get]", e), Promise.reject(e);
|
|
906
|
+
}
|
|
907
|
+
};
|
|
908
|
+
refactorCategories = async (e = {}) => {
|
|
909
|
+
try {
|
|
910
|
+
return (await this.props.axiosApi.post("/categories/refactor", {
|
|
911
|
+
authentication: this.authentication,
|
|
912
|
+
filter: e
|
|
913
|
+
})).data;
|
|
914
|
+
} catch (e) {
|
|
915
|
+
return console.error("[/categories/refactor]", e), Promise.reject(e);
|
|
916
|
+
}
|
|
917
|
+
};
|
|
918
|
+
testCategories = async (e = {}) => {
|
|
919
|
+
try {
|
|
920
|
+
return (await this.props.axiosApi.post("/categories/test", {
|
|
921
|
+
authentication: this.authentication,
|
|
922
|
+
filter: e
|
|
923
|
+
})).data;
|
|
924
|
+
} catch (e) {
|
|
925
|
+
return console.error("[/categories/test]", e), Promise.reject(e);
|
|
926
|
+
}
|
|
927
|
+
};
|
|
928
|
+
}, H = class {
|
|
929
|
+
props;
|
|
930
|
+
authentication;
|
|
931
|
+
constructor(e) {
|
|
932
|
+
this.props = e, this.authentication = e.authentication;
|
|
933
|
+
}
|
|
934
|
+
getAdminConfiguration = async () => {
|
|
935
|
+
try {
|
|
936
|
+
return (await this.props.axiosApi.post("/ckeditor/adminConfiguration", { authentication: this.authentication })).data;
|
|
937
|
+
} catch (e) {
|
|
938
|
+
return console.error("[/ckeditor/adminConfiguration]", e), Promise.reject(e);
|
|
939
|
+
}
|
|
940
|
+
};
|
|
941
|
+
assistanceAI = async (e) => {
|
|
942
|
+
try {
|
|
943
|
+
return (await this.props.axiosApi.post("/ckeditor/assistanceAI", {
|
|
944
|
+
authentication: this.authentication,
|
|
945
|
+
...e
|
|
946
|
+
})).data;
|
|
947
|
+
} catch (e) {
|
|
948
|
+
return console.error("[/ckeditor/assistanceAI]", e), Promise.reject(e);
|
|
949
|
+
}
|
|
950
|
+
};
|
|
951
|
+
assistanceAINew = async (e) => {
|
|
952
|
+
try {
|
|
953
|
+
return (await this.props.axiosApi.post("/ckeditor/assistanceAINew", {
|
|
954
|
+
authentication: this.authentication,
|
|
955
|
+
...e
|
|
956
|
+
})).data;
|
|
957
|
+
} catch (e) {
|
|
958
|
+
return console.error("[/ckeditor/assistanceAINew]", e), Promise.reject(e);
|
|
959
|
+
}
|
|
960
|
+
};
|
|
961
|
+
getAudioCode = async (e) => {
|
|
962
|
+
try {
|
|
963
|
+
return (await this.props.axiosApi.post("/ckeditor/audioCode", {
|
|
964
|
+
authentication: this.authentication,
|
|
965
|
+
...e
|
|
966
|
+
})).data;
|
|
967
|
+
} catch (e) {
|
|
968
|
+
return console.error("[/ckeditor/audioCode]", e), Promise.reject(e);
|
|
969
|
+
}
|
|
970
|
+
};
|
|
971
|
+
}, U = class {
|
|
972
|
+
props;
|
|
973
|
+
authentication;
|
|
974
|
+
constructor(e) {
|
|
975
|
+
this.props = e, this.authentication = e.authentication;
|
|
976
|
+
}
|
|
977
|
+
getComments = async (e = {}) => {
|
|
978
|
+
try {
|
|
979
|
+
return (await this.props.axiosApi.post("/comments/get", {
|
|
980
|
+
authentication: this.authentication,
|
|
981
|
+
filters: e
|
|
982
|
+
})).data;
|
|
983
|
+
} catch (e) {
|
|
984
|
+
return console.error("[/comments/get]", e), Promise.reject(e);
|
|
985
|
+
}
|
|
986
|
+
};
|
|
987
|
+
approveComments = async (e) => {
|
|
988
|
+
try {
|
|
989
|
+
return (await this.props.axiosApi.post("/comments/approve", {
|
|
990
|
+
authentication: this.authentication,
|
|
991
|
+
filters: e
|
|
992
|
+
})).data;
|
|
993
|
+
} catch (e) {
|
|
994
|
+
return console.error("[/comments/approve]", e), Promise.reject(e);
|
|
995
|
+
}
|
|
996
|
+
};
|
|
997
|
+
rejectComments = async (e) => {
|
|
998
|
+
try {
|
|
999
|
+
return (await this.props.axiosApi.post("/comments/reject", {
|
|
1000
|
+
authentication: this.authentication,
|
|
1001
|
+
filters: e
|
|
1002
|
+
})).data;
|
|
1003
|
+
} catch (e) {
|
|
1004
|
+
return console.error("[/comments/reject]", e), Promise.reject(e);
|
|
1005
|
+
}
|
|
1006
|
+
};
|
|
1007
|
+
deleteComments = async (e) => {
|
|
1008
|
+
try {
|
|
1009
|
+
return (await this.props.axiosApi.post("/comments/delete", {
|
|
1010
|
+
authentication: this.authentication,
|
|
1011
|
+
filters: e
|
|
1012
|
+
})).data;
|
|
1013
|
+
} catch (e) {
|
|
1014
|
+
return console.error("[/comments/delete]", e), Promise.reject(e);
|
|
1015
|
+
}
|
|
1016
|
+
};
|
|
1017
|
+
highlightComments = async (e) => {
|
|
1018
|
+
try {
|
|
1019
|
+
return (await this.props.axiosApi.post("/comments/highlight", {
|
|
1020
|
+
authentication: this.authentication,
|
|
1021
|
+
filters: e
|
|
1022
|
+
})).data;
|
|
1023
|
+
} catch (e) {
|
|
1024
|
+
return console.error("[/comments/highlight]", e), Promise.reject(e);
|
|
1025
|
+
}
|
|
1026
|
+
};
|
|
1027
|
+
getAdminConfiguration = async () => {
|
|
1028
|
+
try {
|
|
1029
|
+
return (await this.props.axiosApi.post("/comments/adminConfiguration", {
|
|
1030
|
+
authentication: this.authentication,
|
|
1031
|
+
filters: {}
|
|
1032
|
+
})).data;
|
|
1033
|
+
} catch (e) {
|
|
1034
|
+
return console.error("[/comments/adminConfiguration]", e), Promise.reject(e);
|
|
1035
|
+
}
|
|
1036
|
+
};
|
|
1037
|
+
addDictionaryWord = async (e) => {
|
|
1038
|
+
try {
|
|
1039
|
+
return (await this.props.axiosApi.post("/comments/dictionary/add", {
|
|
1040
|
+
authentication: this.authentication,
|
|
1041
|
+
filters: e
|
|
1042
|
+
})).data;
|
|
1043
|
+
} catch (e) {
|
|
1044
|
+
return console.error("[/comments/dictionary/add]", e), Promise.reject(e);
|
|
1045
|
+
}
|
|
1046
|
+
};
|
|
1047
|
+
changeDictionaryWordType = async (e) => {
|
|
1048
|
+
try {
|
|
1049
|
+
return (await this.props.axiosApi.post("/comments/dictionary/changeType", {
|
|
1050
|
+
authentication: this.authentication,
|
|
1051
|
+
filters: e
|
|
1052
|
+
})).data;
|
|
1053
|
+
} catch (e) {
|
|
1054
|
+
return console.error("[/comments/dictionary/changeType]", e), Promise.reject(e);
|
|
1055
|
+
}
|
|
1056
|
+
};
|
|
1057
|
+
deleteDictionaryWord = async (e) => {
|
|
1058
|
+
try {
|
|
1059
|
+
return (await this.props.axiosApi.post("/comments/dictionary/delete", {
|
|
1060
|
+
authentication: this.authentication,
|
|
1061
|
+
filters: { word: e }
|
|
1062
|
+
})).data;
|
|
1063
|
+
} catch (e) {
|
|
1064
|
+
return console.error("[/comments/dictionary/delete]", e), Promise.reject(e);
|
|
1065
|
+
}
|
|
1066
|
+
};
|
|
1067
|
+
getDictionary = async (e = {}) => {
|
|
1068
|
+
try {
|
|
1069
|
+
return (await this.props.axiosApi.post("/comments/dictionary/get", {
|
|
1070
|
+
authentication: this.authentication,
|
|
1071
|
+
filters: e
|
|
1072
|
+
})).data;
|
|
1073
|
+
} catch (e) {
|
|
1074
|
+
return console.error("[/comments/dictionary/get]", e), Promise.reject(e);
|
|
1075
|
+
}
|
|
1076
|
+
};
|
|
1077
|
+
getCommentEvents = async (e) => {
|
|
1078
|
+
try {
|
|
1079
|
+
return (await this.props.axiosApi.post("/comments/events/get", {
|
|
1080
|
+
authentication: this.authentication,
|
|
1081
|
+
filters: { commentId: e }
|
|
1082
|
+
})).data;
|
|
1083
|
+
} catch (e) {
|
|
1084
|
+
return console.error("[/comments/events/get]", e), Promise.reject(e);
|
|
1085
|
+
}
|
|
1086
|
+
};
|
|
1087
|
+
getReasons = async () => {
|
|
1088
|
+
try {
|
|
1089
|
+
return (await this.props.axiosApi.post("/comments/reasons/get", {
|
|
1090
|
+
authentication: this.authentication,
|
|
1091
|
+
filters: {}
|
|
1092
|
+
})).data;
|
|
1093
|
+
} catch (e) {
|
|
1094
|
+
return console.error("[/comments/reasons/get]", e), Promise.reject(e);
|
|
1095
|
+
}
|
|
1096
|
+
};
|
|
1097
|
+
getReasonsTest = async () => {
|
|
1098
|
+
try {
|
|
1099
|
+
return (await this.props.axiosApi.post("/comments/reasons/prueba", {
|
|
1100
|
+
authentication: this.authentication,
|
|
1101
|
+
filters: {}
|
|
1102
|
+
})).data;
|
|
1103
|
+
} catch (e) {
|
|
1104
|
+
return console.error("[/comments/reasons/prueba]", e), Promise.reject(e);
|
|
1105
|
+
}
|
|
1106
|
+
};
|
|
1107
|
+
disableUser = async (e) => {
|
|
1108
|
+
try {
|
|
1109
|
+
return (await this.props.axiosApi.post("/comments/user/disable", {
|
|
1110
|
+
authentication: this.authentication,
|
|
1111
|
+
filters: { username: e }
|
|
1112
|
+
})).data;
|
|
1113
|
+
} catch (e) {
|
|
1114
|
+
return console.error("[/comments/user/disable]", e), Promise.reject(e);
|
|
1115
|
+
}
|
|
1116
|
+
};
|
|
1117
|
+
enableUser = async (e) => {
|
|
1118
|
+
try {
|
|
1119
|
+
return (await this.props.axiosApi.post("/comments/user/enable", {
|
|
1120
|
+
authentication: this.authentication,
|
|
1121
|
+
filters: { username: e }
|
|
1122
|
+
})).data;
|
|
1123
|
+
} catch (e) {
|
|
1124
|
+
return console.error("[/comments/user/enable]", e), Promise.reject(e);
|
|
1125
|
+
}
|
|
1126
|
+
};
|
|
1127
|
+
getUser = async (e) => {
|
|
1128
|
+
try {
|
|
1129
|
+
return (await this.props.axiosApi.post("/comments/user/get", {
|
|
1130
|
+
authentication: this.authentication,
|
|
1131
|
+
filters: { username: e }
|
|
1132
|
+
})).data;
|
|
1133
|
+
} catch (e) {
|
|
1134
|
+
return console.error("[/comments/user/get]", e), Promise.reject(e);
|
|
1135
|
+
}
|
|
1136
|
+
};
|
|
1137
|
+
}, W = class {
|
|
1138
|
+
props;
|
|
1139
|
+
authentication;
|
|
1140
|
+
constructor(e) {
|
|
1141
|
+
this.props = e, this.authentication = e.authentication;
|
|
1142
|
+
}
|
|
1143
|
+
getContributions = async (e = {}) => {
|
|
1144
|
+
try {
|
|
1145
|
+
return (await this.props.axiosApi.post("/contributions/get", {
|
|
1146
|
+
authentication: this.authentication,
|
|
1147
|
+
filters: e
|
|
1148
|
+
})).data;
|
|
1149
|
+
} catch (e) {
|
|
1150
|
+
return console.error("[/contributions/get]", e), Promise.reject(e);
|
|
1151
|
+
}
|
|
1152
|
+
};
|
|
1153
|
+
editContribution = async (e) => {
|
|
1154
|
+
try {
|
|
1155
|
+
return (await this.props.axiosApi.post("/contributions/edit", {
|
|
1156
|
+
authentication: this.authentication,
|
|
1157
|
+
contribution: e
|
|
1158
|
+
})).data;
|
|
1159
|
+
} catch (e) {
|
|
1160
|
+
return console.error("[/contributions/edit]", e), Promise.reject(e);
|
|
1161
|
+
}
|
|
1162
|
+
};
|
|
1163
|
+
getDefinitions = async (e = {}) => {
|
|
1164
|
+
try {
|
|
1165
|
+
return (await this.props.axiosApi.post("/contributions/getDefinitions", {
|
|
1166
|
+
authentication: this.authentication,
|
|
1167
|
+
filters: e
|
|
1168
|
+
})).data;
|
|
1169
|
+
} catch (e) {
|
|
1170
|
+
return console.error("[/contributions/getDefinitions]", e), Promise.reject(e);
|
|
1171
|
+
}
|
|
1172
|
+
};
|
|
1173
|
+
getSubscriptions = async (e = {}) => {
|
|
1174
|
+
try {
|
|
1175
|
+
return (await this.props.axiosApi.post("/contributions/getSuscriptions", {
|
|
1176
|
+
authentication: this.authentication,
|
|
1177
|
+
filters: e
|
|
1178
|
+
})).data;
|
|
1179
|
+
} catch (e) {
|
|
1180
|
+
return console.error("[/contributions/getSuscriptions]", e), Promise.reject(e);
|
|
1181
|
+
}
|
|
1182
|
+
};
|
|
1183
|
+
getContribuciones = async (e = {}) => {
|
|
1184
|
+
try {
|
|
1185
|
+
return (await this.props.axiosApi.post("/contributions/contribuciones/get", {
|
|
1186
|
+
authentication: this.authentication,
|
|
1187
|
+
filters: e
|
|
1188
|
+
})).data;
|
|
1189
|
+
} catch (e) {
|
|
1190
|
+
return console.error("[/contributions/contribuciones/get]", e), Promise.reject(e);
|
|
1191
|
+
}
|
|
1192
|
+
};
|
|
1193
|
+
insertCrm = async (e = {}) => {
|
|
1194
|
+
try {
|
|
1195
|
+
return (await this.props.axiosApi.post("/contributions/contribuciones/insertCrm", {
|
|
1196
|
+
authentication: this.authentication,
|
|
1197
|
+
filters: e
|
|
1198
|
+
})).data;
|
|
1199
|
+
} catch (e) {
|
|
1200
|
+
return console.error("[/contributions/contribuciones/insertCrm]", e), Promise.reject(e);
|
|
1201
|
+
}
|
|
1202
|
+
};
|
|
1203
|
+
getPaymentGateways = async (e = {}) => {
|
|
1204
|
+
try {
|
|
1205
|
+
return (await this.props.axiosApi.post("/contributions/paymentGateways/get", {
|
|
1206
|
+
authentication: this.authentication,
|
|
1207
|
+
filters: e
|
|
1208
|
+
})).data;
|
|
1209
|
+
} catch (e) {
|
|
1210
|
+
return console.error("[/contributions/paymentGateways/get]", e), Promise.reject(e);
|
|
1211
|
+
}
|
|
1212
|
+
};
|
|
1213
|
+
}, G = class {
|
|
1214
|
+
props;
|
|
1215
|
+
authentication;
|
|
1216
|
+
constructor(e) {
|
|
1217
|
+
this.props = e, this.authentication = e.authentication;
|
|
1218
|
+
}
|
|
1219
|
+
addSection = async (e) => {
|
|
1220
|
+
try {
|
|
1221
|
+
return (await this.props.axiosApi.post("/sections/add", {
|
|
1222
|
+
authentication: this.authentication,
|
|
1223
|
+
section: e
|
|
1224
|
+
})).data;
|
|
1225
|
+
} catch (e) {
|
|
1226
|
+
return console.error("[/sections/add]", e), Promise.reject(e);
|
|
1227
|
+
}
|
|
1228
|
+
};
|
|
1229
|
+
deleteSection = async (e) => {
|
|
1230
|
+
try {
|
|
1231
|
+
return (await this.props.axiosApi.post("/sections/delete", {
|
|
1232
|
+
authentication: this.authentication,
|
|
1233
|
+
section: e
|
|
1234
|
+
})).data;
|
|
1235
|
+
} catch (e) {
|
|
1236
|
+
return console.error("[/sections/delete]", e), Promise.reject(e);
|
|
1237
|
+
}
|
|
1238
|
+
};
|
|
1239
|
+
getSections = async (e) => {
|
|
1240
|
+
try {
|
|
1241
|
+
return (await this.props.axiosApi.post("/sections/get", {
|
|
1242
|
+
authentication: this.authentication,
|
|
1243
|
+
visibility: e
|
|
1244
|
+
})).data;
|
|
1245
|
+
} catch (e) {
|
|
1246
|
+
return console.error("[/sections/get]", e), Promise.reject(e);
|
|
1247
|
+
}
|
|
1248
|
+
};
|
|
1249
|
+
existSections = async (e) => {
|
|
1250
|
+
try {
|
|
1251
|
+
return (await this.props.axiosApi.post("/sections/exist", {
|
|
1252
|
+
authentication: this.authentication,
|
|
1253
|
+
visibility: e
|
|
1254
|
+
})).data;
|
|
1255
|
+
} catch (e) {
|
|
1256
|
+
return console.error("[/sections/exist]", e), Promise.reject(e);
|
|
1257
|
+
}
|
|
1258
|
+
};
|
|
1259
|
+
updateSection = async (e) => {
|
|
1260
|
+
try {
|
|
1261
|
+
return (await this.props.axiosApi.post("/sections/update", {
|
|
1262
|
+
authentication: this.authentication,
|
|
1263
|
+
section: e
|
|
1264
|
+
})).data;
|
|
1265
|
+
} catch (e) {
|
|
1266
|
+
return console.error("[/sections/update]", e), Promise.reject(e);
|
|
1267
|
+
}
|
|
1268
|
+
};
|
|
1269
|
+
}, K = class {
|
|
1270
|
+
props;
|
|
1271
|
+
authentication;
|
|
1272
|
+
constructor(e) {
|
|
1273
|
+
this.props = e, this.authentication = e.authentication;
|
|
1274
|
+
}
|
|
1275
|
+
createPlan = async (e = {}) => {
|
|
1276
|
+
try {
|
|
1277
|
+
return (await this.props.axiosApi.post("/productivityPlan/create", {
|
|
1278
|
+
authentication: this.authentication,
|
|
1279
|
+
...e
|
|
1280
|
+
})).data;
|
|
1281
|
+
} catch (e) {
|
|
1282
|
+
return console.error("[/productivityPlan/create]", e), Promise.reject(e);
|
|
1283
|
+
}
|
|
1284
|
+
};
|
|
1285
|
+
getPlans = async (e = {}) => {
|
|
1286
|
+
try {
|
|
1287
|
+
return (await this.props.axiosApi.post("/productivityPlan/get", {
|
|
1288
|
+
authentication: this.authentication,
|
|
1289
|
+
filters: e
|
|
1290
|
+
})).data;
|
|
1291
|
+
} catch (e) {
|
|
1292
|
+
return console.error("[/productivityPlan/get]", e), Promise.reject(e);
|
|
1293
|
+
}
|
|
1294
|
+
};
|
|
1295
|
+
readPlan = async (e) => {
|
|
1296
|
+
try {
|
|
1297
|
+
return (await this.props.axiosApi.post("/productivityPlan/read", {
|
|
1298
|
+
authentication: this.authentication,
|
|
1299
|
+
path: e
|
|
1300
|
+
})).data;
|
|
1301
|
+
} catch (e) {
|
|
1302
|
+
return console.error("[/productivityPlan/read]", e), Promise.reject(e);
|
|
1303
|
+
}
|
|
1304
|
+
};
|
|
1305
|
+
reviewPlan = async (e, t) => {
|
|
1306
|
+
try {
|
|
1307
|
+
return (await this.props.axiosApi.post("/productivityPlan/review", {
|
|
1308
|
+
authentication: this.authentication,
|
|
1309
|
+
path: e,
|
|
1310
|
+
type: t
|
|
1311
|
+
})).data;
|
|
1312
|
+
} catch (e) {
|
|
1313
|
+
return console.error("[/productivityPlan/review]", e), Promise.reject(e);
|
|
1314
|
+
}
|
|
1315
|
+
};
|
|
1316
|
+
savePlan = async (e, t) => {
|
|
1317
|
+
try {
|
|
1318
|
+
return (await this.props.axiosApi.post("/productivityPlan/edit/save", {
|
|
1319
|
+
authentication: this.authentication,
|
|
1320
|
+
path: e,
|
|
1321
|
+
content: t
|
|
1322
|
+
})).data;
|
|
1323
|
+
} catch (e) {
|
|
1324
|
+
return console.error("[/productivityPlan/edit/save]", e), Promise.reject(e);
|
|
1325
|
+
}
|
|
1326
|
+
};
|
|
1327
|
+
changeStatus = async (e) => {
|
|
1328
|
+
try {
|
|
1329
|
+
return (await this.props.axiosApi.post("/productivityPlan/edit/changeStatus", {
|
|
1330
|
+
authentication: this.authentication,
|
|
1331
|
+
path: e
|
|
1332
|
+
})).data;
|
|
1333
|
+
} catch (e) {
|
|
1334
|
+
return console.error("[/productivityPlan/edit/changeStatus]", e), Promise.reject(e);
|
|
1335
|
+
}
|
|
1336
|
+
};
|
|
1337
|
+
getAdminConfiguration = async (e) => {
|
|
1338
|
+
try {
|
|
1339
|
+
return (await this.props.axiosApi.post("/productivityPlan/edit/adminConfiguration", {
|
|
1340
|
+
authentication: this.authentication,
|
|
1341
|
+
path: e
|
|
1342
|
+
})).data;
|
|
1343
|
+
} catch (e) {
|
|
1344
|
+
return console.error("[/productivityPlan/edit/adminConfiguration]", e), Promise.reject(e);
|
|
1345
|
+
}
|
|
1346
|
+
};
|
|
1347
|
+
getRolsPlans = async () => {
|
|
1348
|
+
try {
|
|
1349
|
+
return (await this.props.axiosApi.post("/productivityPlan/rolsPlans/get", { authentication: this.authentication })).data;
|
|
1350
|
+
} catch (e) {
|
|
1351
|
+
return console.error("[/productivityPlan/rolsPlans/get]", e), Promise.reject(e);
|
|
1352
|
+
}
|
|
1353
|
+
};
|
|
1354
|
+
moveRolToPlan = async (e, t) => {
|
|
1355
|
+
try {
|
|
1356
|
+
return (await this.props.axiosApi.post("/productivityPlan/rolsPlans/moveToPlan", {
|
|
1357
|
+
authentication: this.authentication,
|
|
1358
|
+
url: e,
|
|
1359
|
+
rolName: t
|
|
1360
|
+
})).data;
|
|
1361
|
+
} catch (e) {
|
|
1362
|
+
return console.error("[/productivityPlan/rolsPlans/moveToPlan]", e), Promise.reject(e);
|
|
1363
|
+
}
|
|
1364
|
+
};
|
|
1365
|
+
getUsersPlans = async () => {
|
|
1366
|
+
try {
|
|
1367
|
+
return (await this.props.axiosApi.post("/productivityPlan/usersPlans/get", { authentication: this.authentication })).data;
|
|
1368
|
+
} catch (e) {
|
|
1369
|
+
return console.error("[/productivityPlan/usersPlans/get]", e), Promise.reject(e);
|
|
1370
|
+
}
|
|
1371
|
+
};
|
|
1372
|
+
getUsersInPlan = async (e) => {
|
|
1373
|
+
try {
|
|
1374
|
+
return (await this.props.axiosApi.post("/productivityPlan/usersPlans/getInPlan", {
|
|
1375
|
+
authentication: this.authentication,
|
|
1376
|
+
planId: e
|
|
1377
|
+
})).data;
|
|
1378
|
+
} catch (e) {
|
|
1379
|
+
return console.error("[/productivityPlan/usersPlans/getInPlan]", e), Promise.reject(e);
|
|
1380
|
+
}
|
|
1381
|
+
};
|
|
1382
|
+
moveUserToPlan = async (e, t) => {
|
|
1383
|
+
try {
|
|
1384
|
+
return (await this.props.axiosApi.post("/productivityPlan/usersPlans/moveToPlan", {
|
|
1385
|
+
authentication: this.authentication,
|
|
1386
|
+
url: e,
|
|
1387
|
+
userName: t
|
|
1388
|
+
})).data;
|
|
1389
|
+
} catch (e) {
|
|
1390
|
+
return console.error("[/productivityPlan/usersPlans/moveToPlan]", e), Promise.reject(e);
|
|
1391
|
+
}
|
|
1392
|
+
};
|
|
1393
|
+
deletePlan = async (e) => {
|
|
1394
|
+
try {
|
|
1395
|
+
return (await this.props.axiosApi.post("/productivityPlan/unpublish/delete", {
|
|
1396
|
+
authentication: this.authentication,
|
|
1397
|
+
path: e
|
|
1398
|
+
})).data;
|
|
1399
|
+
} catch (e) {
|
|
1400
|
+
return console.error("[/productivityPlan/unpublish/delete]", e), Promise.reject(e);
|
|
1401
|
+
}
|
|
1402
|
+
};
|
|
1403
|
+
getComplianceReport = async (e) => {
|
|
1404
|
+
try {
|
|
1405
|
+
return (await this.props.axiosApi.post("/productivityPlan/reports/compliance", {
|
|
1406
|
+
authentication: this.authentication,
|
|
1407
|
+
...e
|
|
1408
|
+
})).data;
|
|
1409
|
+
} catch (e) {
|
|
1410
|
+
return console.error("[/productivityPlan/reports/compliance]", e), Promise.reject(e);
|
|
1411
|
+
}
|
|
1412
|
+
};
|
|
1413
|
+
getComplianceBackupReport = async (e) => {
|
|
1414
|
+
try {
|
|
1415
|
+
return (await this.props.axiosApi.post("/productivityPlan/reports/complianceBackup", {
|
|
1416
|
+
authentication: this.authentication,
|
|
1417
|
+
...e
|
|
1418
|
+
})).data;
|
|
1419
|
+
} catch (e) {
|
|
1420
|
+
return console.error("[/productivityPlan/reports/complianceBackup]", e), Promise.reject(e);
|
|
1421
|
+
}
|
|
1422
|
+
};
|
|
1423
|
+
getComplianceDetail = async (e) => {
|
|
1424
|
+
try {
|
|
1425
|
+
let t = { path: e };
|
|
1426
|
+
return (await this.props.axiosApi.post("/productivityPlan/reports/complianceDetail", {
|
|
1427
|
+
authentication: this.authentication,
|
|
1428
|
+
filters: t
|
|
1429
|
+
})).data;
|
|
1430
|
+
} catch (e) {
|
|
1431
|
+
return console.error("[/productivityPlan/reports/complianceDetail]", e), Promise.reject(e);
|
|
1432
|
+
}
|
|
1433
|
+
};
|
|
1434
|
+
getFrequencyReports = async (e) => {
|
|
1435
|
+
try {
|
|
1436
|
+
return (await this.props.axiosApi.post("/productivityPlan/reports/frequencyReports", {
|
|
1437
|
+
authentication: this.authentication,
|
|
1438
|
+
filters: e
|
|
1439
|
+
})).data;
|
|
1440
|
+
} catch (e) {
|
|
1441
|
+
return console.error("[/productivityPlan/reports/frequencyReports]", e), Promise.reject(e);
|
|
1442
|
+
}
|
|
1443
|
+
};
|
|
1444
|
+
getMetrics = async (e) => {
|
|
1445
|
+
try {
|
|
1446
|
+
return (await this.props.axiosApi.post("/productivityPlan/reports/metrics", {
|
|
1447
|
+
authentication: this.authentication,
|
|
1448
|
+
filters: e
|
|
1449
|
+
})).data;
|
|
1450
|
+
} catch (e) {
|
|
1451
|
+
return console.error("[/productivityPlan/reports/metrics]", e), Promise.reject(e);
|
|
1452
|
+
}
|
|
1453
|
+
};
|
|
1454
|
+
getComplianceReportV2 = async (e) => {
|
|
1455
|
+
try {
|
|
1456
|
+
return (await this.props.axiosApi.post("/productivityPlan/reports/v2/compliance", {
|
|
1457
|
+
authentication: this.authentication,
|
|
1458
|
+
...e
|
|
1459
|
+
})).data;
|
|
1460
|
+
} catch (e) {
|
|
1461
|
+
return console.error("[/productivityPlan/reports/v2/compliance]", e), Promise.reject(e);
|
|
1462
|
+
}
|
|
1463
|
+
};
|
|
1464
|
+
createException = async (e) => {
|
|
1465
|
+
try {
|
|
1466
|
+
return (await this.props.axiosApi.post("/productivityPlan/exceptions/create", {
|
|
1467
|
+
authentication: this.authentication,
|
|
1468
|
+
exception: e
|
|
1469
|
+
})).data;
|
|
1470
|
+
} catch (e) {
|
|
1471
|
+
return console.error("[/productivityPlan/exceptions/create]", e), Promise.reject(e);
|
|
1472
|
+
}
|
|
1473
|
+
};
|
|
1474
|
+
deleteException = async (e) => {
|
|
1475
|
+
try {
|
|
1476
|
+
return (await this.props.axiosApi.post("/productivityPlan/exceptions/delete", {
|
|
1477
|
+
authentication: this.authentication,
|
|
1478
|
+
id: e
|
|
1479
|
+
})).data;
|
|
1480
|
+
} catch (e) {
|
|
1481
|
+
return console.error("[/productivityPlan/exceptions/delete]", e), Promise.reject(e);
|
|
1482
|
+
}
|
|
1483
|
+
};
|
|
1484
|
+
editException = async (e) => {
|
|
1485
|
+
try {
|
|
1486
|
+
return (await this.props.axiosApi.post("/productivityPlan/exceptions/edit", {
|
|
1487
|
+
authentication: this.authentication,
|
|
1488
|
+
exception: e
|
|
1489
|
+
})).data;
|
|
1490
|
+
} catch (e) {
|
|
1491
|
+
return console.error("[/productivityPlan/exceptions/edit]", e), Promise.reject(e);
|
|
1492
|
+
}
|
|
1493
|
+
};
|
|
1494
|
+
getExceptions = async (e = {}) => {
|
|
1495
|
+
try {
|
|
1496
|
+
return (await this.props.axiosApi.post("/productivityPlan/exceptions/get", {
|
|
1497
|
+
authentication: this.authentication,
|
|
1498
|
+
filters: e
|
|
1499
|
+
})).data;
|
|
1500
|
+
} catch (e) {
|
|
1501
|
+
return console.error("[/productivityPlan/exceptions/get]", e), Promise.reject(e);
|
|
1502
|
+
}
|
|
1503
|
+
};
|
|
1504
|
+
createExceptionReason = async (e) => {
|
|
1505
|
+
try {
|
|
1506
|
+
return (await this.props.axiosApi.post("/productivityPlan/exceptions/reasons/create", {
|
|
1507
|
+
authentication: this.authentication,
|
|
1508
|
+
exceptionReason: e
|
|
1509
|
+
})).data;
|
|
1510
|
+
} catch (e) {
|
|
1511
|
+
return console.error("[/productivityPlan/exceptions/reasons/create]", e), Promise.reject(e);
|
|
1512
|
+
}
|
|
1513
|
+
};
|
|
1514
|
+
deleteExceptionReason = async (e) => {
|
|
1515
|
+
try {
|
|
1516
|
+
return (await this.props.axiosApi.post("/productivityPlan/exceptions/reasons/delete", {
|
|
1517
|
+
authentication: this.authentication,
|
|
1518
|
+
id: e
|
|
1519
|
+
})).data;
|
|
1520
|
+
} catch (e) {
|
|
1521
|
+
return console.error("[/productivityPlan/exceptions/reasons/delete]", e), Promise.reject(e);
|
|
1522
|
+
}
|
|
1523
|
+
};
|
|
1524
|
+
getExceptionReasons = async (e = {}) => {
|
|
1525
|
+
try {
|
|
1526
|
+
return (await this.props.axiosApi.post("/productivityPlan/exceptions/reasons/get", {
|
|
1527
|
+
authentication: this.authentication,
|
|
1528
|
+
filters: e
|
|
1529
|
+
})).data;
|
|
1530
|
+
} catch (e) {
|
|
1531
|
+
return console.error("[/productivityPlan/exceptions/reasons/get]", e), Promise.reject(e);
|
|
1532
|
+
}
|
|
1533
|
+
};
|
|
1534
|
+
updateExceptionReason = async (e) => {
|
|
1535
|
+
try {
|
|
1536
|
+
return (await this.props.axiosApi.post("/productivityPlan/exceptions/reasons/update", {
|
|
1537
|
+
authentication: this.authentication,
|
|
1538
|
+
exceptionReason: e
|
|
1539
|
+
})).data;
|
|
1540
|
+
} catch (e) {
|
|
1541
|
+
return console.error("[/productivityPlan/exceptions/reasons/update]", e), Promise.reject(e);
|
|
1542
|
+
}
|
|
1543
|
+
};
|
|
1544
|
+
getReviewrDetail = async (e, t) => {
|
|
1545
|
+
try {
|
|
1546
|
+
return (await this.props.axiosApi.post("/productivityPlan/reviewr/detail", {
|
|
1547
|
+
authentication: this.authentication,
|
|
1548
|
+
path: e,
|
|
1549
|
+
type: t
|
|
1550
|
+
})).data;
|
|
1551
|
+
} catch (e) {
|
|
1552
|
+
return console.error("[/productivityPlan/reviewr/detail]", e), Promise.reject(e);
|
|
1553
|
+
}
|
|
1554
|
+
};
|
|
1555
|
+
}, q = class {
|
|
1556
|
+
props;
|
|
1557
|
+
authentication;
|
|
1558
|
+
constructor(e) {
|
|
1559
|
+
this.props = e, this.authentication = e.authentication;
|
|
1560
|
+
}
|
|
1561
|
+
createEvent = async () => {
|
|
1562
|
+
try {
|
|
1563
|
+
return (await this.props.axiosApi.post("/events/create", { authentication: this.authentication })).data;
|
|
1564
|
+
} catch (e) {
|
|
1565
|
+
return console.error("[/events/create]", e), Promise.reject(e);
|
|
1566
|
+
}
|
|
1567
|
+
};
|
|
1568
|
+
getEvents = async (e = {}) => {
|
|
1569
|
+
try {
|
|
1570
|
+
return (await this.props.axiosApi.post("/events/get", {
|
|
1571
|
+
authentication: this.authentication,
|
|
1572
|
+
filters: e
|
|
1573
|
+
})).data;
|
|
1574
|
+
} catch (e) {
|
|
1575
|
+
return console.error("[/events/get]", e), Promise.reject(e);
|
|
1576
|
+
}
|
|
1577
|
+
};
|
|
1578
|
+
}, J = class {
|
|
1579
|
+
props;
|
|
1580
|
+
authentication;
|
|
1581
|
+
constructor(e) {
|
|
1582
|
+
this.props = e, this.authentication = e.authentication;
|
|
1583
|
+
}
|
|
1584
|
+
getFiles = async (e) => {
|
|
1585
|
+
try {
|
|
1586
|
+
return (await this.props.axiosApi.post("/fileExplorer/getFiles", {
|
|
1587
|
+
authentication: this.authentication,
|
|
1588
|
+
path: e
|
|
1589
|
+
})).data;
|
|
1590
|
+
} catch (e) {
|
|
1591
|
+
return console.error("[/fileExplorer/getFiles]", e), Promise.reject(e);
|
|
1592
|
+
}
|
|
1593
|
+
};
|
|
1594
|
+
getFolders = async (e) => {
|
|
1595
|
+
try {
|
|
1596
|
+
return (await this.props.axiosApi.post("/fileExplorer/getFolders", {
|
|
1597
|
+
authentication: this.authentication,
|
|
1598
|
+
path: e
|
|
1599
|
+
})).data;
|
|
1600
|
+
} catch (e) {
|
|
1601
|
+
return console.error("[/fileExplorer/getFolders]", e), Promise.reject(e);
|
|
1602
|
+
}
|
|
1603
|
+
};
|
|
1604
|
+
}, Y = class {
|
|
1605
|
+
props;
|
|
1606
|
+
authentication;
|
|
1607
|
+
constructor(e) {
|
|
1608
|
+
this.props = e, this.authentication = e.authentication;
|
|
1609
|
+
}
|
|
1610
|
+
updateCDN = async (e) => {
|
|
1611
|
+
try {
|
|
1612
|
+
return (await this.props.axiosApi.post("/updateCDN", {
|
|
1613
|
+
authentication: this.authentication,
|
|
1614
|
+
path: e
|
|
1615
|
+
})).data;
|
|
1616
|
+
} catch (e) {
|
|
1617
|
+
return console.error("[/updateCDN]", e), Promise.reject(e);
|
|
1618
|
+
}
|
|
1619
|
+
};
|
|
1620
|
+
}, X = class {
|
|
1621
|
+
props;
|
|
1622
|
+
authentication;
|
|
1623
|
+
constructor(e) {
|
|
1624
|
+
this.props = e, this.authentication = e.authentication;
|
|
1625
|
+
}
|
|
1626
|
+
getImages = async (e = {}) => {
|
|
1627
|
+
try {
|
|
1628
|
+
return (await this.props.axiosApi.post("/images/get", {
|
|
1629
|
+
authentication: this.authentication,
|
|
1630
|
+
filters: e
|
|
1631
|
+
})).data;
|
|
1632
|
+
} catch (e) {
|
|
1633
|
+
return console.error("[/images/get]", e), Promise.reject(e);
|
|
1634
|
+
}
|
|
1635
|
+
};
|
|
1636
|
+
read = async (e) => {
|
|
1637
|
+
try {
|
|
1638
|
+
return (await this.props.axiosApi.post("/images/read", {
|
|
1639
|
+
authentication: this.authentication,
|
|
1640
|
+
path: e
|
|
1641
|
+
})).data;
|
|
1642
|
+
} catch (e) {
|
|
1643
|
+
return console.error("[/images/read]", e), Promise.reject(e);
|
|
1644
|
+
}
|
|
1645
|
+
};
|
|
1646
|
+
getAdminConfiguration = async () => {
|
|
1647
|
+
try {
|
|
1648
|
+
return (await this.props.axiosApi.post("/images/adminConfiguration", { authentication: this.authentication })).data;
|
|
1649
|
+
} catch (e) {
|
|
1650
|
+
return console.error("[/images/adminConfiguration]", e), Promise.reject(e);
|
|
1651
|
+
}
|
|
1652
|
+
};
|
|
1653
|
+
publishCheck = async (e) => {
|
|
1654
|
+
try {
|
|
1655
|
+
return (await this.props.axiosApi.post("/images/publish/check", {
|
|
1656
|
+
authentication: this.authentication,
|
|
1657
|
+
images: e
|
|
1658
|
+
})).data;
|
|
1659
|
+
} catch (e) {
|
|
1660
|
+
return console.error("[/images/publish/check]", e), Promise.reject(e);
|
|
1661
|
+
}
|
|
1662
|
+
};
|
|
1663
|
+
publishNow = async (e) => {
|
|
1664
|
+
try {
|
|
1665
|
+
return (await this.props.axiosApi.post("/images/publish/now", {
|
|
1666
|
+
authentication: this.authentication,
|
|
1667
|
+
images: e
|
|
1668
|
+
})).data;
|
|
1669
|
+
} catch (e) {
|
|
1670
|
+
return console.error("[/images/publish/now]", e), Promise.reject(e);
|
|
1671
|
+
}
|
|
1672
|
+
};
|
|
1673
|
+
unlockCheck = async (e) => {
|
|
1674
|
+
try {
|
|
1675
|
+
return (await this.props.axiosApi.post("/images/unlock/check", {
|
|
1676
|
+
authentication: this.authentication,
|
|
1677
|
+
path: e
|
|
1678
|
+
})).data;
|
|
1679
|
+
} catch (e) {
|
|
1680
|
+
return console.error("[/images/unlock/check]", e), Promise.reject(e);
|
|
1681
|
+
}
|
|
1682
|
+
};
|
|
1683
|
+
unlockNow = async (e) => {
|
|
1684
|
+
try {
|
|
1685
|
+
return (await this.props.axiosApi.post("/images/unlock/now", {
|
|
1686
|
+
authentication: this.authentication,
|
|
1687
|
+
path: e
|
|
1688
|
+
})).data;
|
|
1689
|
+
} catch (e) {
|
|
1690
|
+
return console.error("[/images/unlock/now]", e), Promise.reject(e);
|
|
1691
|
+
}
|
|
1692
|
+
};
|
|
1693
|
+
unlockRemove = async (e) => {
|
|
1694
|
+
try {
|
|
1695
|
+
return (await this.props.axiosApi.post("/images/unlock/remove", {
|
|
1696
|
+
authentication: this.authentication,
|
|
1697
|
+
path: e
|
|
1698
|
+
})).data;
|
|
1699
|
+
} catch (e) {
|
|
1700
|
+
return console.error("[/images/unlock/remove]", e), Promise.reject(e);
|
|
1701
|
+
}
|
|
1702
|
+
};
|
|
1703
|
+
unlockValid = async (e) => {
|
|
1704
|
+
try {
|
|
1705
|
+
return (await this.props.axiosApi.post("/images/unlock/valid", {
|
|
1706
|
+
authentication: this.authentication,
|
|
1707
|
+
path: e
|
|
1708
|
+
})).data;
|
|
1709
|
+
} catch (e) {
|
|
1710
|
+
return console.error("[/images/unlock/valid]", e), Promise.reject(e);
|
|
1711
|
+
}
|
|
1712
|
+
};
|
|
1713
|
+
unpublishCheck = async (e, t) => {
|
|
1714
|
+
try {
|
|
1715
|
+
return (await this.props.axiosApi.post("/images/unpublish/check", {
|
|
1716
|
+
authentication: this.authentication,
|
|
1717
|
+
path: e,
|
|
1718
|
+
action: t
|
|
1719
|
+
})).data;
|
|
1720
|
+
} catch (e) {
|
|
1721
|
+
return console.error("[/images/unpublish/check]", e), Promise.reject(e);
|
|
1722
|
+
}
|
|
1723
|
+
};
|
|
1724
|
+
unpublishNow = async (e) => {
|
|
1725
|
+
try {
|
|
1726
|
+
return (await this.props.axiosApi.post("/images/unpublish/now", {
|
|
1727
|
+
authentication: this.authentication,
|
|
1728
|
+
path: e
|
|
1729
|
+
})).data;
|
|
1730
|
+
} catch (e) {
|
|
1731
|
+
return console.error("[/images/unpublish/now]", e), Promise.reject(e);
|
|
1732
|
+
}
|
|
1733
|
+
};
|
|
1734
|
+
unpublishDelete = async (e) => {
|
|
1735
|
+
try {
|
|
1736
|
+
return (await this.props.axiosApi.post("/images/unpublish/delete", {
|
|
1737
|
+
authentication: this.authentication,
|
|
1738
|
+
path: e
|
|
1739
|
+
})).data;
|
|
1740
|
+
} catch (e) {
|
|
1741
|
+
return console.error("[/images/unpublish/delete]", e), Promise.reject(e);
|
|
1742
|
+
}
|
|
1743
|
+
};
|
|
1744
|
+
discardDraft = async (e) => {
|
|
1745
|
+
try {
|
|
1746
|
+
return (await this.props.axiosApi.post("/images/edit/discardDraft", {
|
|
1747
|
+
authentication: this.authentication,
|
|
1748
|
+
path: e
|
|
1749
|
+
})).data;
|
|
1750
|
+
} catch (e) {
|
|
1751
|
+
return console.error("[/images/edit/discardDraft]", e), Promise.reject(e);
|
|
1752
|
+
}
|
|
1753
|
+
};
|
|
1754
|
+
editInline = async (e) => {
|
|
1755
|
+
try {
|
|
1756
|
+
return (await this.props.axiosApi.post("/images/edit/inline", {
|
|
1757
|
+
authentication: this.authentication,
|
|
1758
|
+
image: e
|
|
1759
|
+
})).data;
|
|
1760
|
+
} catch (e) {
|
|
1761
|
+
return console.error("[/images/edit/inline]", e), Promise.reject(e);
|
|
1762
|
+
}
|
|
1763
|
+
};
|
|
1764
|
+
editRemoveLock = async (e) => {
|
|
1765
|
+
try {
|
|
1766
|
+
return (await this.props.axiosApi.post("/images/edit/removelock", {
|
|
1767
|
+
authentication: this.authentication,
|
|
1768
|
+
path: e
|
|
1769
|
+
})).data;
|
|
1770
|
+
} catch (e) {
|
|
1771
|
+
return console.error("[/images/edit/removelock]", e), Promise.reject(e);
|
|
1772
|
+
}
|
|
1773
|
+
};
|
|
1774
|
+
save = async (e, t, n = {}) => {
|
|
1775
|
+
try {
|
|
1776
|
+
return (await this.props.axiosApi.post("/images/edit/save", {
|
|
1777
|
+
authentication: this.authentication,
|
|
1778
|
+
imagePath: e,
|
|
1779
|
+
content: t,
|
|
1780
|
+
...n
|
|
1781
|
+
})).data;
|
|
1782
|
+
} catch (e) {
|
|
1783
|
+
return console.error("[/images/edit/save]", e), Promise.reject(e);
|
|
1784
|
+
}
|
|
1785
|
+
};
|
|
1786
|
+
setFocalPoint = async (e) => {
|
|
1787
|
+
try {
|
|
1788
|
+
return (await this.props.axiosApi.post("/images/edit/setFocalPoint", {
|
|
1789
|
+
authentication: this.authentication,
|
|
1790
|
+
path: e
|
|
1791
|
+
})).data;
|
|
1792
|
+
} catch (e) {
|
|
1793
|
+
return console.error("[/images/edit/setFocalPoint]", e), Promise.reject(e);
|
|
1794
|
+
}
|
|
1795
|
+
};
|
|
1796
|
+
getGallery = async (e) => {
|
|
1797
|
+
try {
|
|
1798
|
+
return (await this.props.axiosApi.post("/images/ckeditor/getGallery", {
|
|
1799
|
+
authentication: this.authentication,
|
|
1800
|
+
image: e
|
|
1801
|
+
})).data;
|
|
1802
|
+
} catch (e) {
|
|
1803
|
+
return console.error("[/images/ckeditor/getGallery]", e), Promise.reject(e);
|
|
1804
|
+
}
|
|
1805
|
+
};
|
|
1806
|
+
getImageComparation = async (e) => {
|
|
1807
|
+
try {
|
|
1808
|
+
return (await this.props.axiosApi.post("/images/ckeditor/getImageComparation", {
|
|
1809
|
+
authentication: this.authentication,
|
|
1810
|
+
image: e
|
|
1811
|
+
})).data;
|
|
1812
|
+
} catch (e) {
|
|
1813
|
+
return console.error("[/images/ckeditor/getImageComparation]", e), Promise.reject(e);
|
|
1814
|
+
}
|
|
1815
|
+
};
|
|
1816
|
+
}, Z = class {
|
|
1817
|
+
props;
|
|
1818
|
+
authentication;
|
|
1819
|
+
constructor(e) {
|
|
1820
|
+
this.props = e, this.authentication = e.authentication;
|
|
1821
|
+
}
|
|
1822
|
+
available = async (e) => {
|
|
1823
|
+
try {
|
|
1824
|
+
return (await this.props.axiosApi.post("/news/available", {
|
|
1825
|
+
authentication: this.authentication,
|
|
1826
|
+
path: e
|
|
1827
|
+
})).data;
|
|
1828
|
+
} catch (e) {
|
|
1829
|
+
return console.error("[/news/available]", e), Promise.reject(e);
|
|
1830
|
+
}
|
|
1831
|
+
};
|
|
1832
|
+
copy = async (e) => {
|
|
1833
|
+
try {
|
|
1834
|
+
return (await this.props.axiosApi.post("/news/copy", {
|
|
1835
|
+
authentication: this.authentication,
|
|
1836
|
+
news: { new: e }
|
|
1837
|
+
})).data;
|
|
1838
|
+
} catch (e) {
|
|
1839
|
+
return console.error("[/news/copy]", e), Promise.reject(e);
|
|
1840
|
+
}
|
|
1841
|
+
};
|
|
1842
|
+
create = async (e) => {
|
|
1843
|
+
try {
|
|
1844
|
+
return (await this.props.axiosApi.post("/news/create", {
|
|
1845
|
+
authentication: this.authentication,
|
|
1846
|
+
newsType: e
|
|
1847
|
+
})).data;
|
|
1848
|
+
} catch (e) {
|
|
1849
|
+
return console.error("[/news/create]", e), Promise.reject(e);
|
|
1850
|
+
}
|
|
1851
|
+
};
|
|
1852
|
+
exportNews = async (e) => {
|
|
1853
|
+
try {
|
|
1854
|
+
let t = e.map((e) => ({ path: e }));
|
|
1855
|
+
return (await this.props.axiosApi.post("/news/export", {
|
|
1856
|
+
authentication: this.authentication,
|
|
1857
|
+
news: { new: t }
|
|
1858
|
+
})).data;
|
|
1859
|
+
} catch (e) {
|
|
1860
|
+
return console.error("[/news/export]", e), Promise.reject(e);
|
|
1861
|
+
}
|
|
1862
|
+
};
|
|
1863
|
+
getPreviewFormats = async () => {
|
|
1864
|
+
try {
|
|
1865
|
+
return (await this.props.axiosApi.post("/news/previewFormats", { authentication: this.authentication })).data;
|
|
1866
|
+
} catch (e) {
|
|
1867
|
+
return console.error("[/news/previewFormats]", e), Promise.reject(e);
|
|
1868
|
+
}
|
|
1869
|
+
};
|
|
1870
|
+
read = async (e, t) => {
|
|
1871
|
+
try {
|
|
1872
|
+
return (await this.props.axiosApi.post("/news/read", {
|
|
1873
|
+
authentication: this.authentication,
|
|
1874
|
+
path: e,
|
|
1875
|
+
pagination: t
|
|
1876
|
+
})).data;
|
|
1877
|
+
} catch (e) {
|
|
1878
|
+
return console.error("[/news/read]", e), Promise.reject(e);
|
|
1879
|
+
}
|
|
1880
|
+
};
|
|
1881
|
+
readPage = async (e) => {
|
|
1882
|
+
try {
|
|
1883
|
+
return (await this.props.axiosApi.post("/news/read_page", {
|
|
1884
|
+
authentication: this.authentication,
|
|
1885
|
+
...e
|
|
1886
|
+
})).data;
|
|
1887
|
+
} catch (e) {
|
|
1888
|
+
return console.error("[/news/read_page]", e), Promise.reject(e);
|
|
1889
|
+
}
|
|
1890
|
+
};
|
|
1891
|
+
removeLock = async (e) => {
|
|
1892
|
+
try {
|
|
1893
|
+
return (await this.props.axiosApi.post("/news/removelock", {
|
|
1894
|
+
authentication: this.authentication,
|
|
1895
|
+
path: e
|
|
1896
|
+
})).data;
|
|
1897
|
+
} catch (e) {
|
|
1898
|
+
return console.error("[/news/removelock]", e), Promise.reject(e);
|
|
1899
|
+
}
|
|
1900
|
+
};
|
|
1901
|
+
unlock = async (e) => {
|
|
1902
|
+
try {
|
|
1903
|
+
return (await this.props.axiosApi.post("/news/unlock", {
|
|
1904
|
+
authentication: this.authentication,
|
|
1905
|
+
path: e
|
|
1906
|
+
})).data;
|
|
1907
|
+
} catch (e) {
|
|
1908
|
+
return console.error("[/news/unlock]", e), Promise.reject(e);
|
|
1909
|
+
}
|
|
1910
|
+
};
|
|
1911
|
+
translate = async (e) => {
|
|
1912
|
+
try {
|
|
1913
|
+
return (await this.props.axiosApi.post("/news/translate", {
|
|
1914
|
+
authentication: this.authentication,
|
|
1915
|
+
...e
|
|
1916
|
+
})).data;
|
|
1917
|
+
} catch (e) {
|
|
1918
|
+
return console.error("[/news/translate]", e), Promise.reject(e);
|
|
1919
|
+
}
|
|
1920
|
+
};
|
|
1921
|
+
getTypes = async () => {
|
|
1922
|
+
try {
|
|
1923
|
+
return (await this.props.axiosApi.post("/news/types", { authentication: this.authentication })).data;
|
|
1924
|
+
} catch (e) {
|
|
1925
|
+
return console.error("[/news/types]", e), Promise.reject(e);
|
|
1926
|
+
}
|
|
1927
|
+
};
|
|
1928
|
+
relatedNewsElementsQuery = async (e) => {
|
|
1929
|
+
try {
|
|
1930
|
+
return (await this.props.axiosApi.post("/news/relatedNewsElementsQuery", {
|
|
1931
|
+
authentication: this.authentication,
|
|
1932
|
+
news: e
|
|
1933
|
+
})).data;
|
|
1934
|
+
} catch (e) {
|
|
1935
|
+
return console.error("[/news/relatedNewsElementsQuery]", e), Promise.reject(e);
|
|
1936
|
+
}
|
|
1937
|
+
};
|
|
1938
|
+
publishCheck = async (e) => {
|
|
1939
|
+
try {
|
|
1940
|
+
let t = e.map((e) => ({ path: e }));
|
|
1941
|
+
return (await this.props.axiosApi.post("/news/publish/check", {
|
|
1942
|
+
authentication: this.authentication,
|
|
1943
|
+
news: { new: t }
|
|
1944
|
+
})).data;
|
|
1945
|
+
} catch (e) {
|
|
1946
|
+
return console.error("[/news/publish/check]", e), Promise.reject(e);
|
|
1947
|
+
}
|
|
1948
|
+
};
|
|
1949
|
+
publishNow = async (e, t = {}) => {
|
|
1950
|
+
try {
|
|
1951
|
+
return (await this.props.axiosApi.post("/news/publish/now", {
|
|
1952
|
+
authentication: this.authentication,
|
|
1953
|
+
news: {
|
|
1954
|
+
new: e,
|
|
1955
|
+
...t
|
|
1956
|
+
}
|
|
1957
|
+
})).data;
|
|
1958
|
+
} catch (e) {
|
|
1959
|
+
return console.error("[/news/publish/now]", e), Promise.reject(e);
|
|
1960
|
+
}
|
|
1961
|
+
};
|
|
1962
|
+
publishSchedule = async (e, t = {}) => {
|
|
1963
|
+
try {
|
|
1964
|
+
return (await this.props.axiosApi.post("/news/publish/schedule", {
|
|
1965
|
+
authentication: this.authentication,
|
|
1966
|
+
news: {
|
|
1967
|
+
new: e,
|
|
1968
|
+
...t
|
|
1969
|
+
}
|
|
1970
|
+
})).data;
|
|
1971
|
+
} catch (e) {
|
|
1972
|
+
return console.error("[/news/publish/schedule]", e), Promise.reject(e);
|
|
1973
|
+
}
|
|
1974
|
+
};
|
|
1975
|
+
publishMassive = async (e) => {
|
|
1976
|
+
try {
|
|
1977
|
+
let t = e.map((e) => ({ path: e }));
|
|
1978
|
+
return (await this.props.axiosApi.post("/news/publish/massive", {
|
|
1979
|
+
authentication: this.authentication,
|
|
1980
|
+
news: { new: t }
|
|
1981
|
+
})).data;
|
|
1982
|
+
} catch (e) {
|
|
1983
|
+
return console.error("[/news/publish/massive]", e), Promise.reject(e);
|
|
1984
|
+
}
|
|
1985
|
+
};
|
|
1986
|
+
generateAISummary = async (e, t) => {
|
|
1987
|
+
try {
|
|
1988
|
+
let n = e.map((e) => ({ path: e }));
|
|
1989
|
+
return (await this.props.axiosApi.post("/news/publish/AISummaryGenerate", {
|
|
1990
|
+
authentication: this.authentication,
|
|
1991
|
+
news: { new: n },
|
|
1992
|
+
saveInNews: t
|
|
1993
|
+
})).data;
|
|
1994
|
+
} catch (e) {
|
|
1995
|
+
return console.error("[/news/publish/AISummaryGenerate]", e), Promise.reject(e);
|
|
1996
|
+
}
|
|
1997
|
+
};
|
|
1998
|
+
unpublishCheck = async (e, t) => {
|
|
1999
|
+
try {
|
|
2000
|
+
return (await this.props.axiosApi.post("/news/unpublish/check", {
|
|
2001
|
+
authentication: this.authentication,
|
|
2002
|
+
path: e,
|
|
2003
|
+
noteOwner: t
|
|
2004
|
+
})).data;
|
|
2005
|
+
} catch (e) {
|
|
2006
|
+
return console.error("[/news/unpublish/check]", e), Promise.reject(e);
|
|
2007
|
+
}
|
|
2008
|
+
};
|
|
2009
|
+
unpublishNow = async (e) => {
|
|
2010
|
+
try {
|
|
2011
|
+
return (await this.props.axiosApi.post("/news/unpublish/now", {
|
|
2012
|
+
authentication: this.authentication,
|
|
2013
|
+
resources: e
|
|
2014
|
+
})).data;
|
|
2015
|
+
} catch (e) {
|
|
2016
|
+
return console.error("[/news/unpublish/now]", e), Promise.reject(e);
|
|
2017
|
+
}
|
|
2018
|
+
};
|
|
2019
|
+
unpublishDelete = async (e, t) => {
|
|
2020
|
+
try {
|
|
2021
|
+
return (await this.props.axiosApi.post("/news/unpublish/delete", {
|
|
2022
|
+
authentication: this.authentication,
|
|
2023
|
+
resources: e,
|
|
2024
|
+
noteOwner: t
|
|
2025
|
+
})).data;
|
|
2026
|
+
} catch (e) {
|
|
2027
|
+
return console.error("[/news/unpublish/delete]", e), Promise.reject(e);
|
|
2028
|
+
}
|
|
2029
|
+
};
|
|
2030
|
+
unpublishExpired = async (e) => {
|
|
2031
|
+
try {
|
|
2032
|
+
let t = e.map((e) => ({ path: e }));
|
|
2033
|
+
return (await this.props.axiosApi.post("/news/unpublish/expired", {
|
|
2034
|
+
authentication: this.authentication,
|
|
2035
|
+
news: { new: t }
|
|
2036
|
+
})).data;
|
|
2037
|
+
} catch (e) {
|
|
2038
|
+
return console.error("[/news/unpublish/expired]", e), Promise.reject(e);
|
|
2039
|
+
}
|
|
2040
|
+
};
|
|
2041
|
+
addPins = async (e) => {
|
|
2042
|
+
try {
|
|
2043
|
+
let t = e.map((e) => ({ path: e }));
|
|
2044
|
+
return (await this.props.axiosApi.post("/news/pin/add", {
|
|
2045
|
+
authentication: this.authentication,
|
|
2046
|
+
news: { new: t }
|
|
2047
|
+
})).data;
|
|
2048
|
+
} catch (e) {
|
|
2049
|
+
return console.error("[/news/pin/add]", e), Promise.reject(e);
|
|
2050
|
+
}
|
|
2051
|
+
};
|
|
2052
|
+
deletePins = async (e) => {
|
|
2053
|
+
try {
|
|
2054
|
+
let t = e.map((e) => ({ id: e }));
|
|
2055
|
+
return (await this.props.axiosApi.post("/news/pin/delete", {
|
|
2056
|
+
authentication: this.authentication,
|
|
2057
|
+
pines: { pin: t }
|
|
2058
|
+
})).data;
|
|
2059
|
+
} catch (e) {
|
|
2060
|
+
return console.error("[/news/pin/delete]", e), Promise.reject(e);
|
|
2061
|
+
}
|
|
2062
|
+
};
|
|
2063
|
+
getPins = async () => {
|
|
2064
|
+
try {
|
|
2065
|
+
return (await this.props.axiosApi.post("/news/pin/get", { authentication: this.authentication })).data;
|
|
2066
|
+
} catch (e) {
|
|
2067
|
+
return console.error("[/news/pin/get]", e), Promise.reject(e);
|
|
2068
|
+
}
|
|
2069
|
+
};
|
|
2070
|
+
massiveCheck = async (e, t) => {
|
|
2071
|
+
try {
|
|
2072
|
+
let n = e.map((e) => ({ path: e }));
|
|
2073
|
+
return (await this.props.axiosApi.post("/news/massive/check", {
|
|
2074
|
+
authentication: this.authentication,
|
|
2075
|
+
news: {
|
|
2076
|
+
new: n,
|
|
2077
|
+
isPublish: t
|
|
2078
|
+
}
|
|
2079
|
+
})).data;
|
|
2080
|
+
} catch (e) {
|
|
2081
|
+
return console.error("[/news/massive/check]", e), Promise.reject(e);
|
|
2082
|
+
}
|
|
2083
|
+
};
|
|
2084
|
+
massiveEdit = async (e) => {
|
|
2085
|
+
try {
|
|
2086
|
+
return (await this.props.axiosApi.post("/news/massive/edit", {
|
|
2087
|
+
authentication: this.authentication,
|
|
2088
|
+
news: { new: e }
|
|
2089
|
+
})).data;
|
|
2090
|
+
} catch (e) {
|
|
2091
|
+
return console.error("[/news/massive/edit]", e), Promise.reject(e);
|
|
2092
|
+
}
|
|
2093
|
+
};
|
|
2094
|
+
createFreshness = async (e, t) => {
|
|
2095
|
+
try {
|
|
2096
|
+
return (await this.props.axiosApi.post("/news/freshness/create", {
|
|
2097
|
+
authentication: this.authentication,
|
|
2098
|
+
path: e,
|
|
2099
|
+
detail: { freshness: t }
|
|
2100
|
+
})).data;
|
|
2101
|
+
} catch (e) {
|
|
2102
|
+
return console.error("[/news/freshness/create]", e), Promise.reject(e);
|
|
2103
|
+
}
|
|
2104
|
+
};
|
|
2105
|
+
deleteFreshness = async (e) => {
|
|
2106
|
+
try {
|
|
2107
|
+
return (await this.props.axiosApi.post("/news/freshness/delete", {
|
|
2108
|
+
authentication: this.authentication,
|
|
2109
|
+
path: e
|
|
2110
|
+
})).data;
|
|
2111
|
+
} catch (e) {
|
|
2112
|
+
return console.error("[/news/freshness/delete]", e), Promise.reject(e);
|
|
2113
|
+
}
|
|
2114
|
+
};
|
|
2115
|
+
getFreshness = async (e = {}) => {
|
|
2116
|
+
try {
|
|
2117
|
+
return (await this.props.axiosApi.post("/news/freshness/get", {
|
|
2118
|
+
authentication: this.authentication,
|
|
2119
|
+
filters: e
|
|
2120
|
+
})).data;
|
|
2121
|
+
} catch (e) {
|
|
2122
|
+
return console.error("[/news/freshness/get]", e), Promise.reject(e);
|
|
2123
|
+
}
|
|
2124
|
+
};
|
|
2125
|
+
getViews = async () => {
|
|
2126
|
+
try {
|
|
2127
|
+
return (await this.props.axiosApi.post("/news/views/get", { authentication: this.authentication })).data;
|
|
2128
|
+
} catch (e) {
|
|
2129
|
+
return console.error("[/news/views/get]", e), Promise.reject(e);
|
|
2130
|
+
}
|
|
2131
|
+
};
|
|
2132
|
+
getAnalytics = async () => {
|
|
2133
|
+
try {
|
|
2134
|
+
return (await this.props.axiosApi.post("/news/analytics/get", { authentication: this.authentication })).data;
|
|
2135
|
+
} catch (e) {
|
|
2136
|
+
return console.error("[/news/analytics/get]", e), Promise.reject(e);
|
|
2137
|
+
}
|
|
2138
|
+
};
|
|
2139
|
+
getAnalyticsWithFilters = async (e = {}) => {
|
|
2140
|
+
try {
|
|
2141
|
+
return (await this.props.axiosApi.post("/news/analytics/getWhitFilters", {
|
|
2142
|
+
authentication: this.authentication,
|
|
2143
|
+
filters: e
|
|
2144
|
+
})).data;
|
|
2145
|
+
} catch (e) {
|
|
2146
|
+
return console.error("[/news/analytics/getWhitFilters]", e), Promise.reject(e);
|
|
2147
|
+
}
|
|
2148
|
+
};
|
|
2149
|
+
updateAnalytics = async (e) => {
|
|
2150
|
+
try {
|
|
2151
|
+
return (await this.props.axiosApi.post("/news/analytics/update", {
|
|
2152
|
+
authentication: this.authentication,
|
|
2153
|
+
filters: { pathNote: e }
|
|
2154
|
+
})).data;
|
|
2155
|
+
} catch (e) {
|
|
2156
|
+
return console.error("[/news/analytics/update]", e), Promise.reject(e);
|
|
2157
|
+
}
|
|
2158
|
+
};
|
|
2159
|
+
editSave = async (e, t, n) => {
|
|
2160
|
+
try {
|
|
2161
|
+
return (await this.props.axiosApi.post("/news/edit/save", {
|
|
2162
|
+
authentication: this.authentication,
|
|
2163
|
+
path: e,
|
|
2164
|
+
content: t,
|
|
2165
|
+
detail: n
|
|
2166
|
+
})).data;
|
|
2167
|
+
} catch (e) {
|
|
2168
|
+
return console.error("[/news/edit/save]", e), Promise.reject(e);
|
|
2169
|
+
}
|
|
2170
|
+
};
|
|
2171
|
+
saveTempNews = async (e, t) => {
|
|
2172
|
+
try {
|
|
2173
|
+
return (await this.props.axiosApi.post("/news/edit/saveTemp", {
|
|
2174
|
+
authentication: this.authentication,
|
|
2175
|
+
path: e,
|
|
2176
|
+
content: t
|
|
2177
|
+
})).data;
|
|
2178
|
+
} catch (e) {
|
|
2179
|
+
return console.error("[/news/edit/saveTemp]", e), Promise.reject(e);
|
|
2180
|
+
}
|
|
2181
|
+
};
|
|
2182
|
+
discardDraftNews = async (e) => {
|
|
2183
|
+
try {
|
|
2184
|
+
return (await this.props.axiosApi.post("/news/edit/discardDraft", {
|
|
2185
|
+
authentication: this.authentication,
|
|
2186
|
+
path: e
|
|
2187
|
+
})).data;
|
|
2188
|
+
} catch (e) {
|
|
2189
|
+
return console.error("[/news/edit/discardDraft]", e), Promise.reject(e);
|
|
2190
|
+
}
|
|
2191
|
+
};
|
|
2192
|
+
exitEdit = async (e, t) => {
|
|
2193
|
+
try {
|
|
2194
|
+
return (await this.props.axiosApi.post("/news/edit/exit", {
|
|
2195
|
+
authentication: this.authentication,
|
|
2196
|
+
path: e,
|
|
2197
|
+
discardDraft: t
|
|
2198
|
+
})).data;
|
|
2199
|
+
} catch (e) {
|
|
2200
|
+
return console.error("[/news/edit/exit]", e), Promise.reject(e);
|
|
2201
|
+
}
|
|
2202
|
+
};
|
|
2203
|
+
hasDraft = async (e) => {
|
|
2204
|
+
try {
|
|
2205
|
+
return (await this.props.axiosApi.post("/news/edit/hasDraft", {
|
|
2206
|
+
authentication: this.authentication,
|
|
2207
|
+
path: e
|
|
2208
|
+
})).data;
|
|
2209
|
+
} catch (e) {
|
|
2210
|
+
return console.error("[/news/edit/hasDraft]", e), Promise.reject(e);
|
|
2211
|
+
}
|
|
2212
|
+
};
|
|
2213
|
+
editInline = async (e) => {
|
|
2214
|
+
try {
|
|
2215
|
+
return (await this.props.axiosApi.post("/news/edit/inline", {
|
|
2216
|
+
authentication: this.authentication,
|
|
2217
|
+
news: { new: e }
|
|
2218
|
+
})).data;
|
|
2219
|
+
} catch (e) {
|
|
2220
|
+
return console.error("[/news/edit/inline]", e), Promise.reject(e);
|
|
2221
|
+
}
|
|
2222
|
+
};
|
|
2223
|
+
removeZone = async (e, t) => {
|
|
2224
|
+
try {
|
|
2225
|
+
return (await this.props.axiosApi.post("/news/edit/removeZone", {
|
|
2226
|
+
authentication: this.authentication,
|
|
2227
|
+
path: e,
|
|
2228
|
+
pos: t
|
|
2229
|
+
})).data;
|
|
2230
|
+
} catch (e) {
|
|
2231
|
+
return console.error("[/news/edit/removeZone]", e), Promise.reject(e);
|
|
2232
|
+
}
|
|
2233
|
+
};
|
|
2234
|
+
analizeNews = async (e) => {
|
|
2235
|
+
try {
|
|
2236
|
+
return (await this.props.axiosApi.post("/news/edit/analizeNews", {
|
|
2237
|
+
authentication: this.authentication,
|
|
2238
|
+
path: e
|
|
2239
|
+
})).data;
|
|
2240
|
+
} catch (e) {
|
|
2241
|
+
return console.error("[/news/edit/analizeNews]", e), Promise.reject(e);
|
|
2242
|
+
}
|
|
2243
|
+
};
|
|
2244
|
+
analizeNewsAI = async (e, t) => {
|
|
2245
|
+
try {
|
|
2246
|
+
return (await this.props.axiosApi.post("/news/edit/analizeNewsAI", {
|
|
2247
|
+
authentication: this.authentication,
|
|
2248
|
+
path: e,
|
|
2249
|
+
component: t
|
|
2250
|
+
})).data;
|
|
2251
|
+
} catch (e) {
|
|
2252
|
+
return console.error("[/news/edit/analizeNewsAI]", e), Promise.reject(e);
|
|
2253
|
+
}
|
|
2254
|
+
};
|
|
2255
|
+
summaryNewsIA = async (e, t) => {
|
|
2256
|
+
try {
|
|
2257
|
+
let n = e.map((e) => ({ path: e }));
|
|
2258
|
+
return (await this.props.axiosApi.post("/news/edit/SummaryNewsIA", {
|
|
2259
|
+
authentication: this.authentication,
|
|
2260
|
+
news: { new: n },
|
|
2261
|
+
saveInNews: t
|
|
2262
|
+
})).data;
|
|
2263
|
+
} catch (e) {
|
|
2264
|
+
return console.error("[/news/edit/SummaryNewsIA]", e), Promise.reject(e);
|
|
2265
|
+
}
|
|
2266
|
+
};
|
|
2267
|
+
getAdminNewsConfiguration = async (e) => {
|
|
2268
|
+
try {
|
|
2269
|
+
return (await this.props.axiosApi.post("/news/edit/adminNewsConfiguration", {
|
|
2270
|
+
authentication: this.authentication,
|
|
2271
|
+
path: e
|
|
2272
|
+
})).data;
|
|
2273
|
+
} catch (e) {
|
|
2274
|
+
return console.error("[/news/edit/adminNewsConfiguration]", e), Promise.reject(e);
|
|
2275
|
+
}
|
|
2276
|
+
};
|
|
2277
|
+
getFieldsDefault = async (e) => {
|
|
2278
|
+
try {
|
|
2279
|
+
return (await this.props.axiosApi.post("/news/edit/fieldsDefault", {
|
|
2280
|
+
authentication: this.authentication,
|
|
2281
|
+
path: e
|
|
2282
|
+
})).data;
|
|
2283
|
+
} catch (e) {
|
|
2284
|
+
return console.error("[/news/edit/fieldsDefault]", e), Promise.reject(e);
|
|
2285
|
+
}
|
|
2286
|
+
};
|
|
2287
|
+
getAuthorConfiguration = async () => {
|
|
2288
|
+
try {
|
|
2289
|
+
return (await this.props.axiosApi.post("/news/edit/authorConfiguration", { authentication: this.authentication })).data;
|
|
2290
|
+
} catch (e) {
|
|
2291
|
+
return console.error("[/news/edit/authorConfiguration]", e), Promise.reject(e);
|
|
2292
|
+
}
|
|
2293
|
+
};
|
|
2294
|
+
hideBanner = async (e) => {
|
|
2295
|
+
try {
|
|
2296
|
+
return (await this.props.axiosApi.post("/news/edit/hideBanner", {
|
|
2297
|
+
authentication: this.authentication,
|
|
2298
|
+
news: { new: e }
|
|
2299
|
+
})).data;
|
|
2300
|
+
} catch (e) {
|
|
2301
|
+
return console.error("[/news/edit/hideBanner]", e), Promise.reject(e);
|
|
2302
|
+
}
|
|
2303
|
+
};
|
|
2304
|
+
getVersions = async (e) => {
|
|
2305
|
+
try {
|
|
2306
|
+
return (await this.props.axiosApi.post("/news/versions/get", {
|
|
2307
|
+
authentication: this.authentication,
|
|
2308
|
+
news: { path: e }
|
|
2309
|
+
})).data;
|
|
2310
|
+
} catch (e) {
|
|
2311
|
+
return console.error("[/news/versions/get]", e), Promise.reject(e);
|
|
2312
|
+
}
|
|
2313
|
+
};
|
|
2314
|
+
recoverVersion = async (e, t) => {
|
|
2315
|
+
try {
|
|
2316
|
+
return (await this.props.axiosApi.post("/news/versions/recovery", {
|
|
2317
|
+
authentication: this.authentication,
|
|
2318
|
+
news: {
|
|
2319
|
+
path: e,
|
|
2320
|
+
version: t
|
|
2321
|
+
}
|
|
2322
|
+
})).data;
|
|
2323
|
+
} catch (e) {
|
|
2324
|
+
return console.error("[/news/versions/recovery]", e), Promise.reject(e);
|
|
2325
|
+
}
|
|
2326
|
+
};
|
|
2327
|
+
getRefactor = async (e = {}) => {
|
|
2328
|
+
try {
|
|
2329
|
+
return (await this.props.axiosApi.post("/news/refactor/get", {
|
|
2330
|
+
authentication: this.authentication,
|
|
2331
|
+
filters: e
|
|
2332
|
+
})).data;
|
|
2333
|
+
} catch (e) {
|
|
2334
|
+
return console.error("[/news/refactor/get]", e), Promise.reject(e);
|
|
2335
|
+
}
|
|
2336
|
+
};
|
|
2337
|
+
newsCheck = async (e) => {
|
|
2338
|
+
try {
|
|
2339
|
+
return (await this.props.axiosApi.post("/news/IA/newsCheck", {
|
|
2340
|
+
authentication: this.authentication,
|
|
2341
|
+
...e
|
|
2342
|
+
})).data;
|
|
2343
|
+
} catch (e) {
|
|
2344
|
+
return console.error("[/news/IA/newsCheck]", e), Promise.reject(e);
|
|
2345
|
+
}
|
|
2346
|
+
};
|
|
2347
|
+
iaCreate = async (e, t) => {
|
|
2348
|
+
try {
|
|
2349
|
+
return (await this.props.axiosApi.post("/news/IAcreate/create", {
|
|
2350
|
+
authentication: this.authentication,
|
|
2351
|
+
newsType: e,
|
|
2352
|
+
content: t
|
|
2353
|
+
})).data;
|
|
2354
|
+
} catch (e) {
|
|
2355
|
+
return console.error("[/news/IAcreate/create]", e), Promise.reject(e);
|
|
2356
|
+
}
|
|
2357
|
+
};
|
|
2358
|
+
iaPreview = async (e = {}) => {
|
|
2359
|
+
try {
|
|
2360
|
+
return (await this.props.axiosApi.post("/news/IAcreate/preview", {
|
|
2361
|
+
authentication: this.authentication,
|
|
2362
|
+
...e
|
|
2363
|
+
})).data;
|
|
2364
|
+
} catch (e) {
|
|
2365
|
+
return console.error("[/news/IAcreate/preview]", e), Promise.reject(e);
|
|
2366
|
+
}
|
|
2367
|
+
};
|
|
2368
|
+
migrarAnalytics = async (e) => {
|
|
2369
|
+
try {
|
|
2370
|
+
return (await this.props.axiosApi.post("/news/analytics/migrar", {
|
|
2371
|
+
authentication: this.authentication,
|
|
2372
|
+
filters: { pathNote: e }
|
|
2373
|
+
})).data;
|
|
2374
|
+
} catch (e) {
|
|
2375
|
+
return console.error("[/news/analytics/migrar]", e), Promise.reject(e);
|
|
2376
|
+
}
|
|
2377
|
+
};
|
|
2378
|
+
searchConsoleInspection = async (e, t) => {
|
|
2379
|
+
try {
|
|
2380
|
+
return (await this.props.axiosApi.post("/news/searchConsole/inspection", {
|
|
2381
|
+
authentication: this.authentication,
|
|
2382
|
+
path: e,
|
|
2383
|
+
language: t
|
|
2384
|
+
})).data;
|
|
2385
|
+
} catch (e) {
|
|
2386
|
+
return console.error("[/news/searchConsole/inspection]", e), Promise.reject(e);
|
|
2387
|
+
}
|
|
2388
|
+
};
|
|
2389
|
+
}, Q = class {
|
|
2390
|
+
props;
|
|
2391
|
+
authentication;
|
|
2392
|
+
constructor(e) {
|
|
2393
|
+
this.props = e, this.authentication = e.authentication;
|
|
2394
|
+
}
|
|
2395
|
+
getAdminConfiguration = async () => {
|
|
2396
|
+
try {
|
|
2397
|
+
return (await this.props.axiosApi.post("/notification/adminConfiguration", { authentication: this.authentication })).data;
|
|
2398
|
+
} catch (e) {
|
|
2399
|
+
return console.error("[/notification/adminConfiguration]", e), Promise.reject(e);
|
|
2400
|
+
}
|
|
2401
|
+
};
|
|
2402
|
+
push = async (e) => {
|
|
2403
|
+
try {
|
|
2404
|
+
return (await this.props.axiosApi.post("/notification/push", {
|
|
2405
|
+
authentication: this.authentication,
|
|
2406
|
+
notification: e
|
|
2407
|
+
})).data;
|
|
2408
|
+
} catch (e) {
|
|
2409
|
+
return console.error("[/notification/push]", e), Promise.reject(e);
|
|
2410
|
+
}
|
|
2411
|
+
};
|
|
2412
|
+
getTopics = async () => {
|
|
2413
|
+
try {
|
|
2414
|
+
return (await this.props.axiosApi.post("/notification/topics", { authentication: this.authentication })).data;
|
|
2415
|
+
} catch (e) {
|
|
2416
|
+
return console.error("[/notification/topics]", e), Promise.reject(e);
|
|
2417
|
+
}
|
|
2418
|
+
};
|
|
2419
|
+
}, ne = class {
|
|
2420
|
+
props;
|
|
2421
|
+
authentication;
|
|
2422
|
+
constructor(e) {
|
|
2423
|
+
this.props = e, this.authentication = e.authentication;
|
|
2424
|
+
}
|
|
2425
|
+
getPeople = async (e = {}) => {
|
|
2426
|
+
try {
|
|
2427
|
+
return (await this.props.axiosApi.post("/people/get", {
|
|
2428
|
+
authentication: this.authentication,
|
|
2429
|
+
filters: e
|
|
2430
|
+
})).data;
|
|
2431
|
+
} catch (e) {
|
|
2432
|
+
return console.error("[/people/get]", e), Promise.reject(e);
|
|
2433
|
+
}
|
|
2434
|
+
};
|
|
2435
|
+
addPerson = async (e) => {
|
|
2436
|
+
try {
|
|
2437
|
+
return (await this.props.axiosApi.post("/people/add", {
|
|
2438
|
+
authentication: this.authentication,
|
|
2439
|
+
people: e
|
|
2440
|
+
})).data;
|
|
2441
|
+
} catch (e) {
|
|
2442
|
+
return console.error("[/people/add]", e), Promise.reject(e);
|
|
2443
|
+
}
|
|
2444
|
+
};
|
|
2445
|
+
updatePerson = async (e) => {
|
|
2446
|
+
try {
|
|
2447
|
+
return (await this.props.axiosApi.post("/people/update", {
|
|
2448
|
+
authentication: this.authentication,
|
|
2449
|
+
person: e
|
|
2450
|
+
})).data;
|
|
2451
|
+
} catch (e) {
|
|
2452
|
+
return console.error("[/people/update]", e), Promise.reject(e);
|
|
2453
|
+
}
|
|
2454
|
+
};
|
|
2455
|
+
deletePerson = async (e) => {
|
|
2456
|
+
try {
|
|
2457
|
+
return (await this.props.axiosApi.post("/people/delete", {
|
|
2458
|
+
authentication: this.authentication,
|
|
2459
|
+
person: { id: e }
|
|
2460
|
+
})).data;
|
|
2461
|
+
} catch (e) {
|
|
2462
|
+
return console.error("[/people/delete]", e), Promise.reject(e);
|
|
2463
|
+
}
|
|
2464
|
+
};
|
|
2465
|
+
changeStatus = async (e, t) => {
|
|
2466
|
+
try {
|
|
2467
|
+
return (await this.props.axiosApi.post("/people/changeStatus", {
|
|
2468
|
+
authentication: this.authentication,
|
|
2469
|
+
person: {
|
|
2470
|
+
id: e,
|
|
2471
|
+
status: t
|
|
2472
|
+
}
|
|
2473
|
+
})).data;
|
|
2474
|
+
} catch (e) {
|
|
2475
|
+
return console.error("[/people/changeStatus]", e), Promise.reject(e);
|
|
2476
|
+
}
|
|
2477
|
+
};
|
|
2478
|
+
isExist = async (e) => {
|
|
2479
|
+
try {
|
|
2480
|
+
return (await this.props.axiosApi.post("/people/isExist", {
|
|
2481
|
+
authentication: this.authentication,
|
|
2482
|
+
filters: { text: e }
|
|
2483
|
+
})).data;
|
|
2484
|
+
} catch (e) {
|
|
2485
|
+
return console.error("[/people/isExist]", e), Promise.reject(e);
|
|
2486
|
+
}
|
|
2487
|
+
};
|
|
2488
|
+
getAdminConfiguration = async () => {
|
|
2489
|
+
try {
|
|
2490
|
+
return (await this.props.axiosApi.post("/people/adminConfiguration", { authentication: this.authentication })).data;
|
|
2491
|
+
} catch (e) {
|
|
2492
|
+
return console.error("[/people/adminConfiguration]", e), Promise.reject(e);
|
|
2493
|
+
}
|
|
2494
|
+
};
|
|
2495
|
+
}, re = class {
|
|
2496
|
+
props;
|
|
2497
|
+
authentication;
|
|
2498
|
+
constructor(e) {
|
|
2499
|
+
this.props = e, this.authentication = e.authentication;
|
|
2500
|
+
}
|
|
2501
|
+
getActivities = async (e = {}) => {
|
|
2502
|
+
try {
|
|
2503
|
+
return (await this.props.axiosApi.post("/planning/activity/get", {
|
|
2504
|
+
authentication: this.authentication,
|
|
2505
|
+
filters: e
|
|
2506
|
+
})).data;
|
|
2507
|
+
} catch (e) {
|
|
2508
|
+
return console.error("[/planning/activity/get]", e), Promise.reject(e);
|
|
2509
|
+
}
|
|
2510
|
+
};
|
|
2511
|
+
createActivity = async (e) => {
|
|
2512
|
+
try {
|
|
2513
|
+
return (await this.props.axiosApi.post("/planning/activity/create", {
|
|
2514
|
+
authentication: this.authentication,
|
|
2515
|
+
activity: e
|
|
2516
|
+
})).data;
|
|
2517
|
+
} catch (e) {
|
|
2518
|
+
return console.error("[/planning/activity/create]", e), Promise.reject(e);
|
|
2519
|
+
}
|
|
2520
|
+
};
|
|
2521
|
+
updateActivity = async (e) => {
|
|
2522
|
+
try {
|
|
2523
|
+
return (await this.props.axiosApi.post("/planning/activity/update", {
|
|
2524
|
+
authentication: this.authentication,
|
|
2525
|
+
activity: e
|
|
2526
|
+
})).data;
|
|
2527
|
+
} catch (e) {
|
|
2528
|
+
return console.error("[/planning/activity/update]", e), Promise.reject(e);
|
|
2529
|
+
}
|
|
2530
|
+
};
|
|
2531
|
+
deleteActivity = async (e) => {
|
|
2532
|
+
try {
|
|
2533
|
+
return (await this.props.axiosApi.post("/planning/activity/delete", {
|
|
2534
|
+
authentication: this.authentication,
|
|
2535
|
+
id: e
|
|
2536
|
+
})).data;
|
|
2537
|
+
} catch (e) {
|
|
2538
|
+
return console.error("[/planning/activity/delete]", e), Promise.reject(e);
|
|
2539
|
+
}
|
|
2540
|
+
};
|
|
2541
|
+
copyActivity = async (e) => {
|
|
2542
|
+
try {
|
|
2543
|
+
return (await this.props.axiosApi.post("/planning/activity/copy", {
|
|
2544
|
+
authentication: this.authentication,
|
|
2545
|
+
id: e
|
|
2546
|
+
})).data;
|
|
2547
|
+
} catch (e) {
|
|
2548
|
+
return console.error("[/planning/activity/copy]", e), Promise.reject(e);
|
|
2549
|
+
}
|
|
2550
|
+
};
|
|
2551
|
+
}, ie = class {
|
|
2552
|
+
props;
|
|
2553
|
+
authentication;
|
|
2554
|
+
constructor(e) {
|
|
2555
|
+
this.props = e, this.authentication = e.authentication;
|
|
2556
|
+
}
|
|
2557
|
+
activatePoll = async (e, t) => {
|
|
2558
|
+
try {
|
|
2559
|
+
return (await this.props.axiosApi.post("/polls/active", {
|
|
2560
|
+
authentication: this.authentication,
|
|
2561
|
+
path: e,
|
|
2562
|
+
group: t
|
|
2563
|
+
})).data;
|
|
2564
|
+
} catch (e) {
|
|
2565
|
+
return console.error("[/polls/active]", e), Promise.reject(e);
|
|
2566
|
+
}
|
|
2567
|
+
};
|
|
2568
|
+
getAdminConfiguration = async (e) => {
|
|
2569
|
+
try {
|
|
2570
|
+
return (await this.props.axiosApi.post("/polls/adminConfiguration", {
|
|
2571
|
+
authentication: this.authentication,
|
|
2572
|
+
path: e
|
|
2573
|
+
})).data;
|
|
2574
|
+
} catch (e) {
|
|
2575
|
+
return console.error("[/polls/adminConfiguration]", e), Promise.reject(e);
|
|
2576
|
+
}
|
|
2577
|
+
};
|
|
2578
|
+
closePoll = async (e) => {
|
|
2579
|
+
try {
|
|
2580
|
+
return (await this.props.axiosApi.post("/polls/close", {
|
|
2581
|
+
authentication: this.authentication,
|
|
2582
|
+
path: e
|
|
2583
|
+
})).data;
|
|
2584
|
+
} catch (e) {
|
|
2585
|
+
return console.error("[/polls/close]", e), Promise.reject(e);
|
|
2586
|
+
}
|
|
2587
|
+
};
|
|
2588
|
+
createPoll = async () => {
|
|
2589
|
+
try {
|
|
2590
|
+
return (await this.props.axiosApi.post("/polls/create", { authentication: this.authentication })).data;
|
|
2591
|
+
} catch (e) {
|
|
2592
|
+
return console.error("[/polls/create]", e), Promise.reject(e);
|
|
2593
|
+
}
|
|
2594
|
+
};
|
|
2595
|
+
getPolls = async (e = {}) => {
|
|
2596
|
+
try {
|
|
2597
|
+
return (await this.props.axiosApi.post("/polls/get", {
|
|
2598
|
+
authentication: this.authentication,
|
|
2599
|
+
filters: e
|
|
2600
|
+
})).data;
|
|
2601
|
+
} catch (e) {
|
|
2602
|
+
return console.error("[/polls/get]", e), Promise.reject(e);
|
|
2603
|
+
}
|
|
2604
|
+
};
|
|
2605
|
+
readPoll = async (e) => {
|
|
2606
|
+
try {
|
|
2607
|
+
return (await this.props.axiosApi.post("/polls/read", {
|
|
2608
|
+
authentication: this.authentication,
|
|
2609
|
+
path: e
|
|
2610
|
+
})).data;
|
|
2611
|
+
} catch (e) {
|
|
2612
|
+
return console.error("[/polls/read]", e), Promise.reject(e);
|
|
2613
|
+
}
|
|
2614
|
+
};
|
|
2615
|
+
reviewPoll = async (e) => {
|
|
2616
|
+
try {
|
|
2617
|
+
return (await this.props.axiosApi.post("/polls/review", {
|
|
2618
|
+
authentication: this.authentication,
|
|
2619
|
+
path: e
|
|
2620
|
+
})).data;
|
|
2621
|
+
} catch (e) {
|
|
2622
|
+
return console.error("[/polls/review]", e), Promise.reject(e);
|
|
2623
|
+
}
|
|
2624
|
+
};
|
|
2625
|
+
unlockPoll = async (e) => {
|
|
2626
|
+
try {
|
|
2627
|
+
return (await this.props.axiosApi.post("/polls/unlock", {
|
|
2628
|
+
authentication: this.authentication,
|
|
2629
|
+
path: e
|
|
2630
|
+
})).data;
|
|
2631
|
+
} catch (e) {
|
|
2632
|
+
return console.error("[/polls/unlock]", e), Promise.reject(e);
|
|
2633
|
+
}
|
|
2634
|
+
};
|
|
2635
|
+
unpublishPoll = async (e) => {
|
|
2636
|
+
try {
|
|
2637
|
+
return (await this.props.axiosApi.post("/polls/unpublish", {
|
|
2638
|
+
authentication: this.authentication,
|
|
2639
|
+
path: e
|
|
2640
|
+
})).data;
|
|
2641
|
+
} catch (e) {
|
|
2642
|
+
return console.error("[/polls/unpublish]", e), Promise.reject(e);
|
|
2643
|
+
}
|
|
2644
|
+
};
|
|
2645
|
+
discardDraft = async (e) => {
|
|
2646
|
+
try {
|
|
2647
|
+
return (await this.props.axiosApi.post("/polls/edit/discardDraft", {
|
|
2648
|
+
authentication: this.authentication,
|
|
2649
|
+
path: e
|
|
2650
|
+
})).data;
|
|
2651
|
+
} catch (e) {
|
|
2652
|
+
return console.error("[/polls/edit/discardDraft]", e), Promise.reject(e);
|
|
2653
|
+
}
|
|
2654
|
+
};
|
|
2655
|
+
exitEdit = async (e, t) => {
|
|
2656
|
+
try {
|
|
2657
|
+
return (await this.props.axiosApi.post("/polls/edit/exit", {
|
|
2658
|
+
authentication: this.authentication,
|
|
2659
|
+
path: e,
|
|
2660
|
+
discardDraft: t
|
|
2661
|
+
})).data;
|
|
2662
|
+
} catch (e) {
|
|
2663
|
+
return console.error("[/polls/edit/exit]", e), Promise.reject(e);
|
|
2664
|
+
}
|
|
2665
|
+
};
|
|
2666
|
+
savePoll = async (e, t) => {
|
|
2667
|
+
try {
|
|
2668
|
+
return (await this.props.axiosApi.post("/polls/edit/save", {
|
|
2669
|
+
authentication: this.authentication,
|
|
2670
|
+
path: e,
|
|
2671
|
+
content: t
|
|
2672
|
+
})).data;
|
|
2673
|
+
} catch (e) {
|
|
2674
|
+
return console.error("[/polls/edit/save]", e), Promise.reject(e);
|
|
2675
|
+
}
|
|
2676
|
+
};
|
|
2677
|
+
saveTempPoll = async (e, t) => {
|
|
2678
|
+
try {
|
|
2679
|
+
return (await this.props.axiosApi.post("/polls/edit/saveTemp", {
|
|
2680
|
+
authentication: this.authentication,
|
|
2681
|
+
path: e,
|
|
2682
|
+
content: t
|
|
2683
|
+
})).data;
|
|
2684
|
+
} catch (e) {
|
|
2685
|
+
return console.error("[/polls/edit/saveTemp]", e), Promise.reject(e);
|
|
2686
|
+
}
|
|
2687
|
+
};
|
|
2688
|
+
publishCheck = async (e) => {
|
|
2689
|
+
try {
|
|
2690
|
+
return (await this.props.axiosApi.post("/polls/publish/check", {
|
|
2691
|
+
authentication: this.authentication,
|
|
2692
|
+
polls: e
|
|
2693
|
+
})).data;
|
|
2694
|
+
} catch (e) {
|
|
2695
|
+
return console.error("[/polls/publish/check]", e), Promise.reject(e);
|
|
2696
|
+
}
|
|
2697
|
+
};
|
|
2698
|
+
publishNow = async (e) => {
|
|
2699
|
+
try {
|
|
2700
|
+
let t = e.map((e) => ({ path: e }));
|
|
2701
|
+
return (await this.props.axiosApi.post("/polls/publish/now", {
|
|
2702
|
+
authentication: this.authentication,
|
|
2703
|
+
polls: { poll: t }
|
|
2704
|
+
})).data;
|
|
2705
|
+
} catch (e) {
|
|
2706
|
+
return console.error("[/polls/publish/now]", e), Promise.reject(e);
|
|
2707
|
+
}
|
|
2708
|
+
};
|
|
2709
|
+
}, ae = class {
|
|
2710
|
+
props;
|
|
2711
|
+
authentication;
|
|
2712
|
+
constructor(e) {
|
|
2713
|
+
this.props = e, this.authentication = e.authentication;
|
|
2714
|
+
}
|
|
2715
|
+
getRecipes = async (e = {}) => {
|
|
2716
|
+
try {
|
|
2717
|
+
return (await this.props.axiosApi.post("/recipes/get", {
|
|
2718
|
+
authentication: this.authentication,
|
|
2719
|
+
filters: e
|
|
2720
|
+
})).data;
|
|
2721
|
+
} catch (e) {
|
|
2722
|
+
return console.error("[/recipes/get]", e), Promise.reject(e);
|
|
2723
|
+
}
|
|
2724
|
+
};
|
|
2725
|
+
createRecipe = async () => {
|
|
2726
|
+
try {
|
|
2727
|
+
return (await this.props.axiosApi.post("/recipes/create", { authentication: this.authentication })).data;
|
|
2728
|
+
} catch (e) {
|
|
2729
|
+
return console.error("[/recipes/create]", e), Promise.reject(e);
|
|
2730
|
+
}
|
|
2731
|
+
};
|
|
2732
|
+
getAdminConfiguration = async () => {
|
|
2733
|
+
try {
|
|
2734
|
+
return (await this.props.axiosApi.post("/recipes/adminConfiguration", { authentication: this.authentication })).data;
|
|
2735
|
+
} catch (e) {
|
|
2736
|
+
return console.error("[/recipes/adminConfiguration]", e), Promise.reject(e);
|
|
2737
|
+
}
|
|
2738
|
+
};
|
|
2739
|
+
getPreviewFormats = async () => {
|
|
2740
|
+
try {
|
|
2741
|
+
return (await this.props.axiosApi.post("/recipes/previewFormats", { authentication: this.authentication })).data;
|
|
2742
|
+
} catch (e) {
|
|
2743
|
+
return console.error("[/recipes/previewFormats]", e), Promise.reject(e);
|
|
2744
|
+
}
|
|
2745
|
+
};
|
|
2746
|
+
saveRecipe = async (e, t) => {
|
|
2747
|
+
try {
|
|
2748
|
+
return (await this.props.axiosApi.post("/recipes/edit/save", {
|
|
2749
|
+
authentication: this.authentication,
|
|
2750
|
+
path: e,
|
|
2751
|
+
content: t
|
|
2752
|
+
})).data;
|
|
2753
|
+
} catch (e) {
|
|
2754
|
+
return console.error("[/recipes/edit/save]", e), Promise.reject(e);
|
|
2755
|
+
}
|
|
2756
|
+
};
|
|
2757
|
+
saveTempRecipe = async (e, t) => {
|
|
2758
|
+
try {
|
|
2759
|
+
return (await this.props.axiosApi.post("/recipes/edit/saveTemp", {
|
|
2760
|
+
authentication: this.authentication,
|
|
2761
|
+
path: e,
|
|
2762
|
+
content: t
|
|
2763
|
+
})).data;
|
|
2764
|
+
} catch (e) {
|
|
2765
|
+
return console.error("[/recipes/edit/saveTemp]", e), Promise.reject(e);
|
|
2766
|
+
}
|
|
2767
|
+
};
|
|
2768
|
+
editInline = async (e) => {
|
|
2769
|
+
try {
|
|
2770
|
+
return (await this.props.axiosApi.post("/recipes/edit/inline", {
|
|
2771
|
+
authentication: this.authentication,
|
|
2772
|
+
...e
|
|
2773
|
+
})).data;
|
|
2774
|
+
} catch (e) {
|
|
2775
|
+
return console.error("[/recipes/edit/inline]", e), Promise.reject(e);
|
|
2776
|
+
}
|
|
2777
|
+
};
|
|
2778
|
+
editMassive = async (e) => {
|
|
2779
|
+
try {
|
|
2780
|
+
return (await this.props.axiosApi.post("/recipes/edit/massive", {
|
|
2781
|
+
authentication: this.authentication,
|
|
2782
|
+
...e
|
|
2783
|
+
})).data;
|
|
2784
|
+
} catch (e) {
|
|
2785
|
+
return console.error("[/recipes/edit/massive]", e), Promise.reject(e);
|
|
2786
|
+
}
|
|
2787
|
+
};
|
|
2788
|
+
exitEdit = async (e, t) => {
|
|
2789
|
+
try {
|
|
2790
|
+
return (await this.props.axiosApi.post("/recipes/edit/exit", {
|
|
2791
|
+
authentication: this.authentication,
|
|
2792
|
+
path: e,
|
|
2793
|
+
discardDraft: t
|
|
2794
|
+
})).data;
|
|
2795
|
+
} catch (e) {
|
|
2796
|
+
return console.error("[/recipes/edit/exit]", e), Promise.reject(e);
|
|
2797
|
+
}
|
|
2798
|
+
};
|
|
2799
|
+
discardDraft = async (e) => {
|
|
2800
|
+
try {
|
|
2801
|
+
return (await this.props.axiosApi.post("/recipes/edit/discardDraft", {
|
|
2802
|
+
authentication: this.authentication,
|
|
2803
|
+
path: e
|
|
2804
|
+
})).data;
|
|
2805
|
+
} catch (e) {
|
|
2806
|
+
return console.error("[/recipes/edit/discardDraft]", e), Promise.reject(e);
|
|
2807
|
+
}
|
|
2808
|
+
};
|
|
2809
|
+
analizeNews = async (e) => {
|
|
2810
|
+
try {
|
|
2811
|
+
return (await this.props.axiosApi.post("/recipes/edit/analizeNews", {
|
|
2812
|
+
authentication: this.authentication,
|
|
2813
|
+
path: e
|
|
2814
|
+
})).data;
|
|
2815
|
+
} catch (e) {
|
|
2816
|
+
return console.error("[/recipes/edit/analizeNews]", e), Promise.reject(e);
|
|
2817
|
+
}
|
|
2818
|
+
};
|
|
2819
|
+
getAuthorConfiguration = async () => {
|
|
2820
|
+
try {
|
|
2821
|
+
return (await this.props.axiosApi.post("/recipes/edit/authorConfiguration", { authentication: this.authentication })).data;
|
|
2822
|
+
} catch (e) {
|
|
2823
|
+
return console.error("[/recipes/edit/authorConfiguration]", e), Promise.reject(e);
|
|
2824
|
+
}
|
|
2825
|
+
};
|
|
2826
|
+
getFieldsDefault = async () => {
|
|
2827
|
+
try {
|
|
2828
|
+
return (await this.props.axiosApi.post("/recipes/edit/fieldsDefault", { authentication: this.authentication })).data;
|
|
2829
|
+
} catch (e) {
|
|
2830
|
+
return console.error("[/recipes/edit/fieldsDefault]", e), Promise.reject(e);
|
|
2831
|
+
}
|
|
2832
|
+
};
|
|
2833
|
+
checkPublish = async (e) => {
|
|
2834
|
+
try {
|
|
2835
|
+
let t = e.map((e) => ({ path: e }));
|
|
2836
|
+
return (await this.props.axiosApi.post("/recipes/publish/check", {
|
|
2837
|
+
authentication: this.authentication,
|
|
2838
|
+
recipes: { recipe: t }
|
|
2839
|
+
})).data;
|
|
2840
|
+
} catch (e) {
|
|
2841
|
+
return console.error("[/recipes/publish/check]", e), Promise.reject(e);
|
|
2842
|
+
}
|
|
2843
|
+
};
|
|
2844
|
+
publishNow = async (e) => {
|
|
2845
|
+
try {
|
|
2846
|
+
let t = e.map((e) => ({ path: e }));
|
|
2847
|
+
return (await this.props.axiosApi.post("/recipes/publish/now", {
|
|
2848
|
+
authentication: this.authentication,
|
|
2849
|
+
recipes: { recipe: t }
|
|
2850
|
+
})).data;
|
|
2851
|
+
} catch (e) {
|
|
2852
|
+
return console.error("[/recipes/publish/now]", e), Promise.reject(e);
|
|
2853
|
+
}
|
|
2854
|
+
};
|
|
2855
|
+
publishMassive = async (e) => {
|
|
2856
|
+
try {
|
|
2857
|
+
let t = e.map((e) => ({ path: e }));
|
|
2858
|
+
return (await this.props.axiosApi.post("/recipes/publish/massive", {
|
|
2859
|
+
authentication: this.authentication,
|
|
2860
|
+
news: { new: t }
|
|
2861
|
+
})).data;
|
|
2862
|
+
} catch (e) {
|
|
2863
|
+
return console.error("[/recipes/publish/massive]", e), Promise.reject(e);
|
|
2864
|
+
}
|
|
2865
|
+
};
|
|
2866
|
+
schedulePublish = async (e) => {
|
|
2867
|
+
try {
|
|
2868
|
+
let t = e.map((e) => ({ path: e }));
|
|
2869
|
+
return (await this.props.axiosApi.post("/recipes/publish/schedule", {
|
|
2870
|
+
authentication: this.authentication,
|
|
2871
|
+
news: { new: t }
|
|
2872
|
+
})).data;
|
|
2873
|
+
} catch (e) {
|
|
2874
|
+
return console.error("[/recipes/publish/schedule]", e), Promise.reject(e);
|
|
2875
|
+
}
|
|
2876
|
+
};
|
|
2877
|
+
}, oe = class {
|
|
2878
|
+
props;
|
|
2879
|
+
authentication;
|
|
2880
|
+
constructor(e) {
|
|
2881
|
+
this.props = e, this.authentication = e.authentication;
|
|
2882
|
+
}
|
|
2883
|
+
getUsers = async (e = {}) => {
|
|
2884
|
+
try {
|
|
2885
|
+
return (await this.props.axiosApi.post("/users/get", {
|
|
2886
|
+
authentication: this.authentication,
|
|
2887
|
+
filters: e
|
|
2888
|
+
})).data;
|
|
2889
|
+
} catch (e) {
|
|
2890
|
+
return console.error("[/users/get]", e), Promise.reject(e);
|
|
2891
|
+
}
|
|
2892
|
+
};
|
|
2893
|
+
getPublicationUsers = async (e = {}) => {
|
|
2894
|
+
try {
|
|
2895
|
+
return (await this.props.axiosApi.post("/users/publication", {
|
|
2896
|
+
authentication: this.authentication,
|
|
2897
|
+
filters: e
|
|
2898
|
+
})).data;
|
|
2899
|
+
} catch (e) {
|
|
2900
|
+
return console.error("[/users/publication]", e), Promise.reject(e);
|
|
2901
|
+
}
|
|
2902
|
+
};
|
|
2903
|
+
getGroups = async (e = "/") => {
|
|
2904
|
+
try {
|
|
2905
|
+
return (await this.props.axiosApi.post("/users/groups/get", {
|
|
2906
|
+
authentication: this.authentication,
|
|
2907
|
+
ou: e
|
|
2908
|
+
})).data;
|
|
2909
|
+
} catch (e) {
|
|
2910
|
+
return console.error("[/users/groups/get]", e), Promise.reject(e);
|
|
2911
|
+
}
|
|
2912
|
+
};
|
|
2913
|
+
getPins = async () => {
|
|
2914
|
+
try {
|
|
2915
|
+
return (await this.props.axiosApi.post("/users/pin/get", { authentication: this.authentication })).data;
|
|
2916
|
+
} catch (e) {
|
|
2917
|
+
return console.error("[/users/pin/get]", e), Promise.reject(e);
|
|
2918
|
+
}
|
|
2919
|
+
};
|
|
2920
|
+
addPin = async (e) => {
|
|
2921
|
+
try {
|
|
2922
|
+
return (await this.props.axiosApi.post("/users/pin/add", {
|
|
2923
|
+
authentication: this.authentication,
|
|
2924
|
+
pines: { pin: [e] }
|
|
2925
|
+
})).data;
|
|
2926
|
+
} catch (e) {
|
|
2927
|
+
return console.error("[/users/pin/add]", e), Promise.reject(e);
|
|
2928
|
+
}
|
|
2929
|
+
};
|
|
2930
|
+
deletePins = async (e) => {
|
|
2931
|
+
try {
|
|
2932
|
+
let t = e.map((e) => ({ id: e }));
|
|
2933
|
+
return (await this.props.axiosApi.post("/users/pin/delete", {
|
|
2934
|
+
authentication: this.authentication,
|
|
2935
|
+
pines: { pin: t }
|
|
2936
|
+
})).data;
|
|
2937
|
+
} catch (e) {
|
|
2938
|
+
return console.error("[/users/pin/delete]", e), Promise.reject(e);
|
|
2939
|
+
}
|
|
2940
|
+
};
|
|
2941
|
+
setUserStatus = async (e, t) => {
|
|
2942
|
+
try {
|
|
2943
|
+
return (await this.props.axiosApi.post("/users/actions/setStatus", {
|
|
2944
|
+
authentication: this.authentication,
|
|
2945
|
+
username: e,
|
|
2946
|
+
action: t
|
|
2947
|
+
})).data;
|
|
2948
|
+
} catch (e) {
|
|
2949
|
+
return console.error("[/users/actions/setStatus]", e), Promise.reject(e);
|
|
2950
|
+
}
|
|
2951
|
+
};
|
|
2952
|
+
resetPassword = async (e) => {
|
|
2953
|
+
try {
|
|
2954
|
+
return (await this.props.axiosApi.post("/users/actions/resetPass", {
|
|
2955
|
+
authentication: this.authentication,
|
|
2956
|
+
username: e
|
|
2957
|
+
})).data;
|
|
2958
|
+
} catch (e) {
|
|
2959
|
+
return console.error("[/users/actions/resetPass]", e), Promise.reject(e);
|
|
2960
|
+
}
|
|
2961
|
+
};
|
|
2962
|
+
resetMfa = async (e, t) => {
|
|
2963
|
+
try {
|
|
2964
|
+
return (await this.props.axiosApi.post("/users/actions/resetMfa", {
|
|
2965
|
+
authentication: this.authentication,
|
|
2966
|
+
username: e,
|
|
2967
|
+
reason: t
|
|
2968
|
+
})).data;
|
|
2969
|
+
} catch (e) {
|
|
2970
|
+
return console.error("[/users/actions/resetMfa]", e), Promise.reject(e);
|
|
2971
|
+
}
|
|
2972
|
+
};
|
|
2973
|
+
}, $ = class {
|
|
2974
|
+
props;
|
|
2975
|
+
authentication;
|
|
2976
|
+
constructor(e) {
|
|
2977
|
+
this.props = e, this.authentication = e.authentication;
|
|
2978
|
+
}
|
|
2979
|
+
getZones = async (e = {}) => {
|
|
2980
|
+
try {
|
|
2981
|
+
return (await this.props.axiosApi.post("/zones/get", {
|
|
2982
|
+
authentication: this.authentication,
|
|
2983
|
+
filters: e
|
|
2984
|
+
})).data;
|
|
2985
|
+
} catch (e) {
|
|
2986
|
+
return console.error("[/zones/get]", e), Promise.reject(e);
|
|
2987
|
+
}
|
|
2988
|
+
};
|
|
2989
|
+
addZone = async (e) => {
|
|
2990
|
+
try {
|
|
2991
|
+
return (await this.props.axiosApi.post("/zones/add", {
|
|
2992
|
+
authentication: this.authentication,
|
|
2993
|
+
zone: e
|
|
2994
|
+
})).data;
|
|
2995
|
+
} catch (e) {
|
|
2996
|
+
return console.error("[/zones/add]", e), Promise.reject(e);
|
|
2997
|
+
}
|
|
2998
|
+
};
|
|
2999
|
+
updateZone = async (e) => {
|
|
3000
|
+
try {
|
|
3001
|
+
return (await this.props.axiosApi.post("/zones/update", {
|
|
3002
|
+
authentication: this.authentication,
|
|
3003
|
+
zone: e
|
|
3004
|
+
})).data;
|
|
3005
|
+
} catch (e) {
|
|
3006
|
+
return console.error("[/zones/update]", e), Promise.reject(e);
|
|
3007
|
+
}
|
|
3008
|
+
};
|
|
3009
|
+
deleteZone = async (e) => {
|
|
3010
|
+
try {
|
|
3011
|
+
return (await this.props.axiosApi.post("/zones/delete", {
|
|
3012
|
+
authentication: this.authentication,
|
|
3013
|
+
zone: { id: e }
|
|
3014
|
+
})).data;
|
|
3015
|
+
} catch (e) {
|
|
3016
|
+
return console.error("[/zones/delete]", e), Promise.reject(e);
|
|
3017
|
+
}
|
|
3018
|
+
};
|
|
3019
|
+
orderZones = async (e) => {
|
|
3020
|
+
try {
|
|
3021
|
+
return (await this.props.axiosApi.post("/zones/order", {
|
|
3022
|
+
authentication: this.authentication,
|
|
3023
|
+
zone: {},
|
|
3024
|
+
zones: { order: e.join(",") }
|
|
3025
|
+
})).data;
|
|
3026
|
+
} catch (e) {
|
|
3027
|
+
return console.error("[/zones/order]", e), Promise.reject(e);
|
|
3028
|
+
}
|
|
3029
|
+
};
|
|
3030
|
+
}, se = class {
|
|
3031
|
+
props;
|
|
3032
|
+
authentication;
|
|
3033
|
+
constructor(e) {
|
|
3034
|
+
this.props = e, this.authentication = e.authentication;
|
|
3035
|
+
}
|
|
3036
|
+
check = async (e) => {
|
|
3037
|
+
try {
|
|
3038
|
+
return (await this.props.axiosApi.post("/workpaper/check", {
|
|
3039
|
+
authentication: this.authentication,
|
|
3040
|
+
path: e
|
|
3041
|
+
})).data;
|
|
3042
|
+
} catch (e) {
|
|
3043
|
+
return console.error("[/workpaper/check]", e), Promise.reject(e);
|
|
3044
|
+
}
|
|
3045
|
+
};
|
|
3046
|
+
login = async (e) => {
|
|
3047
|
+
try {
|
|
3048
|
+
return (await this.props.axiosApi.post("/workpaper/login", {
|
|
3049
|
+
authentication: this.authentication,
|
|
3050
|
+
link: { url: e }
|
|
3051
|
+
})).data;
|
|
3052
|
+
} catch (e) {
|
|
3053
|
+
return console.error("[/workpaper/login]", e), Promise.reject(e);
|
|
3054
|
+
}
|
|
3055
|
+
};
|
|
3056
|
+
status = async () => {
|
|
3057
|
+
try {
|
|
3058
|
+
return (await this.props.axiosApi.post("/workpaper/status", { authentication: this.authentication })).data;
|
|
3059
|
+
} catch (e) {
|
|
3060
|
+
return console.error("[/workpaper/status]", e), Promise.reject(e);
|
|
3061
|
+
}
|
|
3062
|
+
};
|
|
3063
|
+
}, ce = class {
|
|
3064
|
+
props;
|
|
3065
|
+
authentication;
|
|
3066
|
+
constructor(e) {
|
|
3067
|
+
this.props = e, this.authentication = e.authentication;
|
|
3068
|
+
}
|
|
3069
|
+
getVods = async (e = {}) => {
|
|
3070
|
+
try {
|
|
3071
|
+
return (await this.props.axiosApi.post("/vods/get", {
|
|
3072
|
+
authentication: this.authentication,
|
|
3073
|
+
filters: e
|
|
3074
|
+
})).data;
|
|
3075
|
+
} catch (e) {
|
|
3076
|
+
return console.error("[/vods/get]", e), Promise.reject(e);
|
|
3077
|
+
}
|
|
3078
|
+
};
|
|
3079
|
+
getTypes = async () => {
|
|
3080
|
+
try {
|
|
3081
|
+
return (await this.props.axiosApi.post("/vods/types", { authentication: this.authentication })).data;
|
|
3082
|
+
} catch (e) {
|
|
3083
|
+
return console.error("[/vods/types]", e), Promise.reject(e);
|
|
3084
|
+
}
|
|
3085
|
+
};
|
|
3086
|
+
createMovie = async () => {
|
|
3087
|
+
try {
|
|
3088
|
+
return (await this.props.axiosApi.post("/vods/movie/create", { authentication: this.authentication })).data;
|
|
3089
|
+
} catch (e) {
|
|
3090
|
+
return console.error("[/vods/movie/create]", e), Promise.reject(e);
|
|
3091
|
+
}
|
|
3092
|
+
};
|
|
3093
|
+
createSerie = async () => {
|
|
3094
|
+
try {
|
|
3095
|
+
return (await this.props.axiosApi.post("/vods/serie/create", { authentication: this.authentication })).data;
|
|
3096
|
+
} catch (e) {
|
|
3097
|
+
return console.error("[/vods/serie/create]", e), Promise.reject(e);
|
|
3098
|
+
}
|
|
3099
|
+
};
|
|
3100
|
+
createPlaylist = async () => {
|
|
3101
|
+
try {
|
|
3102
|
+
return (await this.props.axiosApi.post("/vods/playlist/create", { authentication: this.authentication })).data;
|
|
3103
|
+
} catch (e) {
|
|
3104
|
+
return console.error("[/vods/playlist/create]", e), Promise.reject(e);
|
|
3105
|
+
}
|
|
3106
|
+
};
|
|
3107
|
+
}, le = class {
|
|
3108
|
+
props;
|
|
3109
|
+
authentication;
|
|
3110
|
+
constructor(e) {
|
|
3111
|
+
this.props = e, this.authentication = e.authentication;
|
|
3112
|
+
}
|
|
3113
|
+
getVideos = async (e = {}) => {
|
|
3114
|
+
try {
|
|
3115
|
+
return (await this.props.axiosApi.post("/videos/get", {
|
|
3116
|
+
authentication: this.authentication,
|
|
3117
|
+
filters: e
|
|
3118
|
+
})).data;
|
|
3119
|
+
} catch (e) {
|
|
3120
|
+
return console.error("[/videos/get]", e), Promise.reject(e);
|
|
3121
|
+
}
|
|
3122
|
+
};
|
|
3123
|
+
readVideo = async (e) => {
|
|
3124
|
+
try {
|
|
3125
|
+
return (await this.props.axiosApi.post("/videos/read", {
|
|
3126
|
+
authentication: this.authentication,
|
|
3127
|
+
path: e
|
|
3128
|
+
})).data;
|
|
3129
|
+
} catch (e) {
|
|
3130
|
+
return console.error("[/videos/read]", e), Promise.reject(e);
|
|
3131
|
+
}
|
|
3132
|
+
};
|
|
3133
|
+
getAdminConfiguration = async () => {
|
|
3134
|
+
try {
|
|
3135
|
+
return (await this.props.axiosApi.post("/videos/adminConfiguration", { authentication: this.authentication })).data;
|
|
3136
|
+
} catch (e) {
|
|
3137
|
+
return console.error("[/videos/adminConfiguration]", e), Promise.reject(e);
|
|
3138
|
+
}
|
|
3139
|
+
};
|
|
3140
|
+
setAvailable = async (e) => {
|
|
3141
|
+
try {
|
|
3142
|
+
return (await this.props.axiosApi.post("/videos/available", {
|
|
3143
|
+
authentication: this.authentication,
|
|
3144
|
+
path: e
|
|
3145
|
+
})).data;
|
|
3146
|
+
} catch (e) {
|
|
3147
|
+
return console.error("[/videos/available]", e), Promise.reject(e);
|
|
3148
|
+
}
|
|
3149
|
+
};
|
|
3150
|
+
saveVideo = async (e, t) => {
|
|
3151
|
+
try {
|
|
3152
|
+
return (await this.props.axiosApi.post("/videos/edit/save", {
|
|
3153
|
+
authentication: this.authentication,
|
|
3154
|
+
path: e,
|
|
3155
|
+
content: t
|
|
3156
|
+
})).data;
|
|
3157
|
+
} catch (e) {
|
|
3158
|
+
return console.error("[/videos/edit/save]", e), Promise.reject(e);
|
|
3159
|
+
}
|
|
3160
|
+
};
|
|
3161
|
+
discardDraft = async (e) => {
|
|
3162
|
+
try {
|
|
3163
|
+
return (await this.props.axiosApi.post("/videos/edit/discardDraft", {
|
|
3164
|
+
authentication: this.authentication,
|
|
3165
|
+
path: e
|
|
3166
|
+
})).data;
|
|
3167
|
+
} catch (e) {
|
|
3168
|
+
return console.error("[/videos/edit/discardDraft]", e), Promise.reject(e);
|
|
3169
|
+
}
|
|
3170
|
+
};
|
|
3171
|
+
hideBanner = async (e) => {
|
|
3172
|
+
try {
|
|
3173
|
+
return (await this.props.axiosApi.post("/videos/edit/hideBanner", {
|
|
3174
|
+
authentication: this.authentication,
|
|
3175
|
+
video: e
|
|
3176
|
+
})).data;
|
|
3177
|
+
} catch (e) {
|
|
3178
|
+
return console.error("[/videos/edit/hideBanner]", e), Promise.reject(e);
|
|
3179
|
+
}
|
|
3180
|
+
};
|
|
3181
|
+
editInline = async (e) => {
|
|
3182
|
+
try {
|
|
3183
|
+
return (await this.props.axiosApi.post("/videos/edit/inline", {
|
|
3184
|
+
authentication: this.authentication,
|
|
3185
|
+
video: e
|
|
3186
|
+
})).data;
|
|
3187
|
+
} catch (e) {
|
|
3188
|
+
return console.error("[/videos/edit/inline]", e), Promise.reject(e);
|
|
3189
|
+
}
|
|
3190
|
+
};
|
|
3191
|
+
embeddedExists = async (e) => {
|
|
3192
|
+
try {
|
|
3193
|
+
return (await this.props.axiosApi.post("/videos/embedded/exists", {
|
|
3194
|
+
authentication: this.authentication,
|
|
3195
|
+
code: e
|
|
3196
|
+
})).data;
|
|
3197
|
+
} catch (e) {
|
|
3198
|
+
return console.error("[/videos/embedded/exists]", e), Promise.reject(e);
|
|
3199
|
+
}
|
|
3200
|
+
};
|
|
3201
|
+
uploadEmbedded = async (e) => {
|
|
3202
|
+
try {
|
|
3203
|
+
return (await this.props.axiosApi.post("/videos/embedded/upload", {
|
|
3204
|
+
authentication: this.authentication,
|
|
3205
|
+
video: e
|
|
3206
|
+
})).data;
|
|
3207
|
+
} catch (e) {
|
|
3208
|
+
return console.error("[/videos/embedded/upload]", e), Promise.reject(e);
|
|
3209
|
+
}
|
|
3210
|
+
};
|
|
3211
|
+
checkPublish = async (e) => {
|
|
3212
|
+
try {
|
|
3213
|
+
return (await this.props.axiosApi.post("/videos/publish/check", {
|
|
3214
|
+
authentication: this.authentication,
|
|
3215
|
+
videos: e
|
|
3216
|
+
})).data;
|
|
3217
|
+
} catch (e) {
|
|
3218
|
+
return console.error("[/videos/publish/check]", e), Promise.reject(e);
|
|
3219
|
+
}
|
|
3220
|
+
};
|
|
3221
|
+
publishNow = async (e, t) => {
|
|
3222
|
+
try {
|
|
3223
|
+
return (await this.props.axiosApi.post("/videos/publish/now", {
|
|
3224
|
+
authentication: this.authentication,
|
|
3225
|
+
videos: e,
|
|
3226
|
+
setLastModification: t
|
|
3227
|
+
})).data;
|
|
3228
|
+
} catch (e) {
|
|
3229
|
+
return console.error("[/videos/publish/now]", e), Promise.reject(e);
|
|
3230
|
+
}
|
|
3231
|
+
};
|
|
3232
|
+
republish = async (e) => {
|
|
3233
|
+
try {
|
|
3234
|
+
return (await this.props.axiosApi.post("/videos/publish/republish", {
|
|
3235
|
+
authentication: this.authentication,
|
|
3236
|
+
path: e
|
|
3237
|
+
})).data;
|
|
3238
|
+
} catch (e) {
|
|
3239
|
+
return console.error("[/videos/publish/republish]", e), Promise.reject(e);
|
|
3240
|
+
}
|
|
3241
|
+
};
|
|
3242
|
+
schedulePublish = async (e) => {
|
|
3243
|
+
try {
|
|
3244
|
+
return (await this.props.axiosApi.post("/videos/publish/schedule", {
|
|
3245
|
+
authentication: this.authentication,
|
|
3246
|
+
videos: e
|
|
3247
|
+
})).data;
|
|
3248
|
+
} catch (e) {
|
|
3249
|
+
return console.error("[/videos/publish/schedule]", e), Promise.reject(e);
|
|
3250
|
+
}
|
|
3251
|
+
};
|
|
3252
|
+
getRudoThumbnails = async (e) => {
|
|
3253
|
+
try {
|
|
3254
|
+
return (await this.props.axiosApi.post("/videos/rudo/getThumbnails", {
|
|
3255
|
+
authentication: this.authentication,
|
|
3256
|
+
rudoCode: e
|
|
3257
|
+
})).data;
|
|
3258
|
+
} catch (e) {
|
|
3259
|
+
return console.error("[/videos/rudo/getThumbnails]", e), Promise.reject(e);
|
|
3260
|
+
}
|
|
3261
|
+
};
|
|
3262
|
+
checkUnlock = async (e) => {
|
|
3263
|
+
try {
|
|
3264
|
+
return (await this.props.axiosApi.post("/videos/unlock/check", {
|
|
3265
|
+
authentication: this.authentication,
|
|
3266
|
+
path: e
|
|
3267
|
+
})).data;
|
|
3268
|
+
} catch (e) {
|
|
3269
|
+
return console.error("[/videos/unlock/check]", e), Promise.reject(e);
|
|
3270
|
+
}
|
|
3271
|
+
};
|
|
3272
|
+
unlockNow = async (e) => {
|
|
3273
|
+
try {
|
|
3274
|
+
return (await this.props.axiosApi.post("/videos/unlock/now", {
|
|
3275
|
+
authentication: this.authentication,
|
|
3276
|
+
path: e
|
|
3277
|
+
})).data;
|
|
3278
|
+
} catch (e) {
|
|
3279
|
+
return console.error("[/videos/unlock/now]", e), Promise.reject(e);
|
|
3280
|
+
}
|
|
3281
|
+
};
|
|
3282
|
+
unlockRemove = async (e) => {
|
|
3283
|
+
try {
|
|
3284
|
+
return (await this.props.axiosApi.post("/videos/unlock/remove", {
|
|
3285
|
+
authentication: this.authentication,
|
|
3286
|
+
path: e
|
|
3287
|
+
})).data;
|
|
3288
|
+
} catch (e) {
|
|
3289
|
+
return console.error("[/videos/unlock/remove]", e), Promise.reject(e);
|
|
3290
|
+
}
|
|
3291
|
+
};
|
|
3292
|
+
checkUnpublish = async (e) => {
|
|
3293
|
+
try {
|
|
3294
|
+
return (await this.props.axiosApi.post("/videos/unpublish/check", {
|
|
3295
|
+
authentication: this.authentication,
|
|
3296
|
+
path: e
|
|
3297
|
+
})).data;
|
|
3298
|
+
} catch (e) {
|
|
3299
|
+
return console.error("[/videos/unpublish/check]", e), Promise.reject(e);
|
|
3300
|
+
}
|
|
3301
|
+
};
|
|
3302
|
+
deleteVideo = async (e) => {
|
|
3303
|
+
try {
|
|
3304
|
+
return (await this.props.axiosApi.post("/videos/unpublish/delete", {
|
|
3305
|
+
authentication: this.authentication,
|
|
3306
|
+
path: e
|
|
3307
|
+
})).data;
|
|
3308
|
+
} catch (e) {
|
|
3309
|
+
return console.error("[/videos/unpublish/delete]", e), Promise.reject(e);
|
|
3310
|
+
}
|
|
3311
|
+
};
|
|
3312
|
+
unpublishNow = async (e = {}) => {
|
|
3313
|
+
try {
|
|
3314
|
+
return (await this.props.axiosApi.post("/videos/unpublish/now", {
|
|
3315
|
+
authentication: this.authentication,
|
|
3316
|
+
...e
|
|
3317
|
+
})).data;
|
|
3318
|
+
} catch (e) {
|
|
3319
|
+
return console.error("[/videos/unpublish/now]", e), Promise.reject(e);
|
|
3320
|
+
}
|
|
3321
|
+
};
|
|
3322
|
+
getYoutubeThumbnails = async (e) => {
|
|
3323
|
+
try {
|
|
3324
|
+
return (await this.props.axiosApi.post("/videos/youtube/getThumbnails", {
|
|
3325
|
+
authentication: this.authentication,
|
|
3326
|
+
youtubeId: e
|
|
3327
|
+
})).data;
|
|
3328
|
+
} catch (e) {
|
|
3329
|
+
return console.error("[/videos/youtube/getThumbnails]", e), Promise.reject(e);
|
|
3330
|
+
}
|
|
3331
|
+
};
|
|
3332
|
+
uploadYoutube = async (e) => {
|
|
3333
|
+
try {
|
|
3334
|
+
return (await this.props.axiosApi.post("/videos/youtube/upload", {
|
|
3335
|
+
authentication: this.authentication,
|
|
3336
|
+
video: e
|
|
3337
|
+
})).data;
|
|
3338
|
+
} catch (e) {
|
|
3339
|
+
return console.error("[/videos/youtube/upload]", e), Promise.reject(e);
|
|
3340
|
+
}
|
|
3341
|
+
};
|
|
3342
|
+
getConvertStatus = async (e) => {
|
|
3343
|
+
try {
|
|
3344
|
+
return (await this.props.axiosApi.post("/videos/nativos/convertStatus", {
|
|
3345
|
+
authentication: this.authentication,
|
|
3346
|
+
path: e
|
|
3347
|
+
})).data;
|
|
3348
|
+
} catch (e) {
|
|
3349
|
+
return console.error("[/videos/nativos/convertStatus]", e), Promise.reject(e);
|
|
3350
|
+
}
|
|
3351
|
+
};
|
|
3352
|
+
cancelUploadS3 = async (e) => {
|
|
3353
|
+
try {
|
|
3354
|
+
return (await this.props.axiosApi.post("/videos/nativos/uploadS3Cancel", {
|
|
3355
|
+
authentication: this.authentication,
|
|
3356
|
+
path: e
|
|
3357
|
+
})).data;
|
|
3358
|
+
} catch (e) {
|
|
3359
|
+
return console.error("[/videos/nativos/uploadS3Cancel]", e), Promise.reject(e);
|
|
3360
|
+
}
|
|
3361
|
+
};
|
|
3362
|
+
getUploadS3Progress = async (e) => {
|
|
3363
|
+
try {
|
|
3364
|
+
return (await this.props.axiosApi.post("/videos/nativos/uploadS3Progress", {
|
|
3365
|
+
authentication: this.authentication,
|
|
3366
|
+
path: e
|
|
3367
|
+
})).data;
|
|
3368
|
+
} catch (e) {
|
|
3369
|
+
return console.error("[/videos/nativos/uploadS3Progress]", e), Promise.reject(e);
|
|
3370
|
+
}
|
|
3371
|
+
};
|
|
3372
|
+
updateVideoProcessing = async (e) => {
|
|
3373
|
+
try {
|
|
3374
|
+
return (await this.props.axiosApi.post("/videos/nativos/updateVideoProcessing", {
|
|
3375
|
+
authentication: this.authentication,
|
|
3376
|
+
video: e
|
|
3377
|
+
})).data;
|
|
3378
|
+
} catch (e) {
|
|
3379
|
+
return console.error("[/videos/nativos/updateVideoProcessing]", e), Promise.reject(e);
|
|
3380
|
+
}
|
|
3381
|
+
};
|
|
3382
|
+
createVideoProcessing = async (e, t) => {
|
|
3383
|
+
try {
|
|
3384
|
+
return (await this.props.axiosApi.post("/videos/nativos/createVideoProcessing", {
|
|
3385
|
+
authentication: this.authentication,
|
|
3386
|
+
videoName: e,
|
|
3387
|
+
moduleConfig: t
|
|
3388
|
+
})).data;
|
|
3389
|
+
} catch (e) {
|
|
3390
|
+
return console.error("[/videos/nativos/createVideoProcessing]", e), Promise.reject(e);
|
|
3391
|
+
}
|
|
3392
|
+
};
|
|
3393
|
+
preUploadAMZ = async (e) => {
|
|
3394
|
+
try {
|
|
3395
|
+
return (await this.props.axiosApi.post("/videos/nativos/preUploadAMZ", {
|
|
3396
|
+
authentication: this.authentication,
|
|
3397
|
+
fileName: e
|
|
3398
|
+
})).data;
|
|
3399
|
+
} catch (e) {
|
|
3400
|
+
return console.error("[/videos/nativos/preUploadAMZ]", e), Promise.reject(e);
|
|
3401
|
+
}
|
|
3402
|
+
};
|
|
3403
|
+
preMultiUploadAMZ = async (e, t, n) => {
|
|
3404
|
+
try {
|
|
3405
|
+
return (await this.props.axiosApi.post("/videos/nativos/preMultiUploadAMZ", {
|
|
3406
|
+
authentication: this.authentication,
|
|
3407
|
+
fileName: e,
|
|
3408
|
+
size: t,
|
|
3409
|
+
contentType: n
|
|
3410
|
+
})).data;
|
|
3411
|
+
} catch (e) {
|
|
3412
|
+
return console.error("[/videos/nativos/preMultiUploadAMZ]", e), Promise.reject(e);
|
|
3413
|
+
}
|
|
3414
|
+
};
|
|
3415
|
+
preMultiCompleteAMZ = async (e, t) => {
|
|
3416
|
+
try {
|
|
3417
|
+
return (await this.props.axiosApi.post("/videos/nativos/preMultiCompleteAMZ", {
|
|
3418
|
+
authentication: this.authentication,
|
|
3419
|
+
vfspath: e,
|
|
3420
|
+
uploadId: t
|
|
3421
|
+
})).data;
|
|
3422
|
+
} catch (e) {
|
|
3423
|
+
return console.error("[/videos/nativos/preMultiCompleteAMZ]", e), Promise.reject(e);
|
|
3424
|
+
}
|
|
3425
|
+
};
|
|
3426
|
+
preMultiAbortAMZ = async (e, t) => {
|
|
3427
|
+
try {
|
|
3428
|
+
return (await this.props.axiosApi.post("/videos/nativos/preMultiAbortAMZ", {
|
|
3429
|
+
authentication: this.authentication,
|
|
3430
|
+
vfspath: e,
|
|
3431
|
+
uploadId: t
|
|
3432
|
+
})).data;
|
|
3433
|
+
} catch (e) {
|
|
3434
|
+
return console.error("[/videos/nativos/preMultiAbortAMZ]", e), Promise.reject(e);
|
|
3435
|
+
}
|
|
3436
|
+
};
|
|
3437
|
+
preMultiResignAMZ = async (e, t, n) => {
|
|
3438
|
+
try {
|
|
3439
|
+
return (await this.props.axiosApi.post("/videos/nativos/preMultiResignAMZ", {
|
|
3440
|
+
authentication: this.authentication,
|
|
3441
|
+
vfspath: e,
|
|
3442
|
+
uploadId: t,
|
|
3443
|
+
numberOfParts: n
|
|
3444
|
+
})).data;
|
|
3445
|
+
} catch (e) {
|
|
3446
|
+
return console.error("[/videos/nativos/preMultiResignAMZ]", e), Promise.reject(e);
|
|
3447
|
+
}
|
|
3448
|
+
};
|
|
3449
|
+
converter = async (e) => {
|
|
3450
|
+
try {
|
|
3451
|
+
return (await this.props.axiosApi.post("/videos/nativos/converter", {
|
|
3452
|
+
authentication: this.authentication,
|
|
3453
|
+
path: e
|
|
3454
|
+
})).data;
|
|
3455
|
+
} catch (e) {
|
|
3456
|
+
return console.error("[/videos/nativos/converter]", e), Promise.reject(e);
|
|
3457
|
+
}
|
|
3458
|
+
};
|
|
3459
|
+
downloadNative = async (e) => {
|
|
3460
|
+
try {
|
|
3461
|
+
return (await this.props.axiosApi.post("/videos/nativos/download", {
|
|
3462
|
+
authentication: this.authentication,
|
|
3463
|
+
path: e
|
|
3464
|
+
}, { responseType: "blob" })).data;
|
|
3465
|
+
} catch (e) {
|
|
3466
|
+
return console.error("[/videos/nativos/download]", e), Promise.reject(e);
|
|
3467
|
+
}
|
|
3468
|
+
};
|
|
3469
|
+
}, ue = class {
|
|
3470
|
+
props;
|
|
3471
|
+
authentication;
|
|
3472
|
+
constructor(e) {
|
|
3473
|
+
this.props = e, this.authentication = e.authentication;
|
|
3474
|
+
}
|
|
3475
|
+
getTrivias = async (e = {}) => {
|
|
3476
|
+
try {
|
|
3477
|
+
return (await this.props.axiosApi.post("/trivias/get", {
|
|
3478
|
+
authentication: this.authentication,
|
|
3479
|
+
filters: e
|
|
3480
|
+
})).data;
|
|
3481
|
+
} catch (e) {
|
|
3482
|
+
return console.error("[/trivias/get]", e), Promise.reject(e);
|
|
3483
|
+
}
|
|
3484
|
+
};
|
|
3485
|
+
readTrivia = async (e) => {
|
|
3486
|
+
try {
|
|
3487
|
+
return (await this.props.axiosApi.post("/trivias/read", {
|
|
3488
|
+
authentication: this.authentication,
|
|
3489
|
+
path: e
|
|
3490
|
+
})).data;
|
|
3491
|
+
} catch (e) {
|
|
3492
|
+
return console.error("[/trivias/read]", e), Promise.reject(e);
|
|
3493
|
+
}
|
|
3494
|
+
};
|
|
3495
|
+
createTrivia = async () => {
|
|
3496
|
+
try {
|
|
3497
|
+
return (await this.props.axiosApi.post("/trivias/create", { authentication: this.authentication })).data;
|
|
3498
|
+
} catch (e) {
|
|
3499
|
+
return console.error("[/trivias/create]", e), Promise.reject(e);
|
|
3500
|
+
}
|
|
3501
|
+
};
|
|
3502
|
+
publishTrivia = async (e) => {
|
|
3503
|
+
try {
|
|
3504
|
+
return (await this.props.axiosApi.post("/trivias/publish", {
|
|
3505
|
+
authentication: this.authentication,
|
|
3506
|
+
path: e
|
|
3507
|
+
})).data;
|
|
3508
|
+
} catch (e) {
|
|
3509
|
+
return console.error("[/trivias/publish]", e), Promise.reject(e);
|
|
3510
|
+
}
|
|
3511
|
+
};
|
|
3512
|
+
publishOnlyTrivias = async (e) => {
|
|
3513
|
+
try {
|
|
3514
|
+
let t = e.map((e) => ({ path: e }));
|
|
3515
|
+
return (await this.props.axiosApi.post("/trivias/publishOnly", {
|
|
3516
|
+
authentication: this.authentication,
|
|
3517
|
+
trivias: { trivia: t }
|
|
3518
|
+
})).data;
|
|
3519
|
+
} catch (e) {
|
|
3520
|
+
return console.error("[/trivias/publishOnly]", e), Promise.reject(e);
|
|
3521
|
+
}
|
|
3522
|
+
};
|
|
3523
|
+
despublishTrivia = async (e) => {
|
|
3524
|
+
try {
|
|
3525
|
+
return (await this.props.axiosApi.post("/trivias/despublish", {
|
|
3526
|
+
authentication: this.authentication,
|
|
3527
|
+
path: e
|
|
3528
|
+
})).data;
|
|
3529
|
+
} catch (e) {
|
|
3530
|
+
return console.error("[/trivias/despublish]", e), Promise.reject(e);
|
|
3531
|
+
}
|
|
3532
|
+
};
|
|
3533
|
+
publishMassive = async (e) => {
|
|
3534
|
+
try {
|
|
3535
|
+
let t = e.map((e) => ({ path: e }));
|
|
3536
|
+
return (await this.props.axiosApi.post("/trivias/massive", {
|
|
3537
|
+
authentication: this.authentication,
|
|
3538
|
+
trivias: { trivia: t }
|
|
3539
|
+
})).data;
|
|
3540
|
+
} catch (e) {
|
|
3541
|
+
return console.error("[/trivias/massive]", e), Promise.reject(e);
|
|
3542
|
+
}
|
|
3543
|
+
};
|
|
3544
|
+
getAdminConfiguration = async (e) => {
|
|
3545
|
+
try {
|
|
3546
|
+
return (await this.props.axiosApi.post("/trivias/adminConfiguration", {
|
|
3547
|
+
authentication: this.authentication,
|
|
3548
|
+
path: e
|
|
3549
|
+
})).data;
|
|
3550
|
+
} catch (e) {
|
|
3551
|
+
return console.error("[/trivias/adminConfiguration]", e), Promise.reject(e);
|
|
3552
|
+
}
|
|
3553
|
+
};
|
|
3554
|
+
saveTrivia = async (e, t) => {
|
|
3555
|
+
try {
|
|
3556
|
+
return (await this.props.axiosApi.post("/trivias/edit/save", {
|
|
3557
|
+
authentication: this.authentication,
|
|
3558
|
+
path: e,
|
|
3559
|
+
content: t
|
|
3560
|
+
})).data;
|
|
3561
|
+
} catch (e) {
|
|
3562
|
+
return console.error("[/trivias/edit/save]", e), Promise.reject(e);
|
|
3563
|
+
}
|
|
3564
|
+
};
|
|
3565
|
+
exitEdit = async (e, t) => {
|
|
3566
|
+
try {
|
|
3567
|
+
return (await this.props.axiosApi.post("/trivias/edit/exit", {
|
|
3568
|
+
authentication: this.authentication,
|
|
3569
|
+
path: e,
|
|
3570
|
+
discardDraft: t
|
|
3571
|
+
})).data;
|
|
3572
|
+
} catch (e) {
|
|
3573
|
+
return console.error("[/trivias/edit/exit]", e), Promise.reject(e);
|
|
3574
|
+
}
|
|
3575
|
+
};
|
|
3576
|
+
editInline = async (e) => {
|
|
3577
|
+
try {
|
|
3578
|
+
return (await this.props.axiosApi.post("/trivias/edit/inline", {
|
|
3579
|
+
authentication: this.authentication,
|
|
3580
|
+
...e
|
|
3581
|
+
})).data;
|
|
3582
|
+
} catch (e) {
|
|
3583
|
+
return console.error("[/trivias/edit/inline]", e), Promise.reject(e);
|
|
3584
|
+
}
|
|
3585
|
+
};
|
|
3586
|
+
}, de = class {
|
|
3587
|
+
props;
|
|
3588
|
+
authentication;
|
|
3589
|
+
constructor(e) {
|
|
3590
|
+
this.props = e, this.authentication = e.authentication;
|
|
3591
|
+
}
|
|
3592
|
+
getTranscription = async (e) => {
|
|
3593
|
+
try {
|
|
3594
|
+
return (await this.props.axiosApi.post("/transcribe/get", {
|
|
3595
|
+
authentication: this.authentication,
|
|
3596
|
+
path: e
|
|
3597
|
+
})).data;
|
|
3598
|
+
} catch (e) {
|
|
3599
|
+
return console.error("[/transcribe/get]", e), Promise.reject(e);
|
|
3600
|
+
}
|
|
3601
|
+
};
|
|
3602
|
+
}, fe = class {
|
|
3603
|
+
props;
|
|
3604
|
+
authentication;
|
|
3605
|
+
constructor(e) {
|
|
3606
|
+
this.props = e, this.authentication = e.authentication;
|
|
3607
|
+
}
|
|
3608
|
+
getTags = async (e = {}) => {
|
|
3609
|
+
try {
|
|
3610
|
+
return (await this.props.axiosApi.post("/tags/get", {
|
|
3611
|
+
authentication: this.authentication,
|
|
3612
|
+
filters: e
|
|
3613
|
+
})).data;
|
|
3614
|
+
} catch (e) {
|
|
3615
|
+
return console.error("[/tags/get]", e), Promise.reject(e);
|
|
3616
|
+
}
|
|
3617
|
+
};
|
|
3618
|
+
getTagsInNews = async (e) => {
|
|
3619
|
+
try {
|
|
3620
|
+
return (await this.props.axiosApi.post("/tags/getInNews", {
|
|
3621
|
+
authentication: this.authentication,
|
|
3622
|
+
filters: e
|
|
3623
|
+
})).data;
|
|
3624
|
+
} catch (e) {
|
|
3625
|
+
return console.error("[/tags/getInNews]", e), Promise.reject(e);
|
|
3626
|
+
}
|
|
3627
|
+
};
|
|
3628
|
+
isExist = async (e = {}) => {
|
|
3629
|
+
try {
|
|
3630
|
+
return (await this.props.axiosApi.post("/tags/isExist", {
|
|
3631
|
+
authentication: this.authentication,
|
|
3632
|
+
filters: e
|
|
3633
|
+
})).data;
|
|
3634
|
+
} catch (e) {
|
|
3635
|
+
return console.error("[/tags/isExist]", e), Promise.reject(e);
|
|
3636
|
+
}
|
|
3637
|
+
};
|
|
3638
|
+
readTag = async (e, t) => {
|
|
3639
|
+
try {
|
|
3640
|
+
return (await this.props.axiosApi.post("/tags/read", {
|
|
3641
|
+
authentication: this.authentication,
|
|
3642
|
+
tag: {
|
|
3643
|
+
id_term: e,
|
|
3644
|
+
type: t
|
|
3645
|
+
}
|
|
3646
|
+
})).data;
|
|
3647
|
+
} catch (e) {
|
|
3648
|
+
return console.error("[/tags/read]", e), Promise.reject(e);
|
|
3649
|
+
}
|
|
3650
|
+
};
|
|
3651
|
+
getTypes = async () => {
|
|
3652
|
+
try {
|
|
3653
|
+
return (await this.props.axiosApi.post("/tags/types", { authentication: this.authentication })).data;
|
|
3654
|
+
} catch (e) {
|
|
3655
|
+
return console.error("[/tags/types]", e), Promise.reject(e);
|
|
3656
|
+
}
|
|
3657
|
+
};
|
|
3658
|
+
getAdminConfiguration = async () => {
|
|
3659
|
+
try {
|
|
3660
|
+
return (await this.props.axiosApi.post("/tags/adminConfiguration", { authentication: this.authentication })).data;
|
|
3661
|
+
} catch (e) {
|
|
3662
|
+
return console.error("[/tags/adminConfiguration]", e), Promise.reject(e);
|
|
3663
|
+
}
|
|
3664
|
+
};
|
|
3665
|
+
addTag = async (e, t) => {
|
|
3666
|
+
try {
|
|
3667
|
+
return (await this.props.axiosApi.post("/tags/add", {
|
|
3668
|
+
authentication: t ? {
|
|
3669
|
+
...this.authentication,
|
|
3670
|
+
url: t
|
|
3671
|
+
} : this.authentication,
|
|
3672
|
+
tag: e
|
|
3673
|
+
})).data;
|
|
3674
|
+
} catch (e) {
|
|
3675
|
+
return console.error("[/tags/add]", e), Promise.reject(e);
|
|
3676
|
+
}
|
|
3677
|
+
};
|
|
3678
|
+
updateTag = async (e) => {
|
|
3679
|
+
try {
|
|
3680
|
+
return (await this.props.axiosApi.post("/tags/update", {
|
|
3681
|
+
authentication: this.authentication,
|
|
3682
|
+
tag: e
|
|
3683
|
+
})).data;
|
|
3684
|
+
} catch (e) {
|
|
3685
|
+
return console.error("[/tags/update]", e), Promise.reject(e);
|
|
3686
|
+
}
|
|
3687
|
+
};
|
|
3688
|
+
deleteTags = async (e) => {
|
|
3689
|
+
try {
|
|
3690
|
+
return (await this.props.axiosApi.post("/tags/delete", {
|
|
3691
|
+
authentication: this.authentication,
|
|
3692
|
+
tag: e
|
|
3693
|
+
})).data;
|
|
3694
|
+
} catch (e) {
|
|
3695
|
+
return console.error("[/tags/delete]", e), Promise.reject(e);
|
|
3696
|
+
}
|
|
3697
|
+
};
|
|
3698
|
+
changeStatus = async (e) => {
|
|
3699
|
+
try {
|
|
3700
|
+
return (await this.props.axiosApi.post("/tags/changeStatus", {
|
|
3701
|
+
authentication: this.authentication,
|
|
3702
|
+
tag: e
|
|
3703
|
+
})).data;
|
|
3704
|
+
} catch (e) {
|
|
3705
|
+
return console.error("[/tags/changeStatus]", e), Promise.reject(e);
|
|
3706
|
+
}
|
|
3707
|
+
};
|
|
3708
|
+
}, pe = class {
|
|
3709
|
+
props;
|
|
3710
|
+
authentication;
|
|
3711
|
+
publications;
|
|
3712
|
+
profileServices;
|
|
3713
|
+
dashboard;
|
|
3714
|
+
sites;
|
|
3715
|
+
auth;
|
|
3716
|
+
constructor(e) {
|
|
3717
|
+
this.props = e, this.authentication = e.authentication, this.publications = new F(e), this.profileServices = new P(e), this.dashboard = new N(e), this.sites = new I(e), this.auth = new M(e);
|
|
3718
|
+
}
|
|
3719
|
+
getDefaultPublication = () => this.publications.getDefaultPublication();
|
|
3720
|
+
getProfile = () => this.profileServices.getProfile();
|
|
3721
|
+
getCountNotifications = async () => await this.dashboard.countNotifications();
|
|
3722
|
+
getNotifications = async () => await this.dashboard.getNotifications();
|
|
3723
|
+
getSitesAndPublications = async () => {
|
|
3724
|
+
let [e, t, n] = await Promise.all([
|
|
3725
|
+
this.sites.getSites(),
|
|
3726
|
+
this.publications.getPublications(),
|
|
3727
|
+
this.auth.getModulesAvailable()
|
|
3728
|
+
]);
|
|
3729
|
+
return {
|
|
3730
|
+
sites: e.sites.map((e) => ({
|
|
3731
|
+
title: e.title,
|
|
3732
|
+
publications: t.publications.filter((t) => t.site === e.name)
|
|
3733
|
+
})).filter((e) => e.publications.length > 0),
|
|
3734
|
+
modules: n.modules
|
|
3735
|
+
};
|
|
3736
|
+
};
|
|
3737
|
+
};
|
|
3738
|
+
//#endregion
|
|
3739
|
+
export { d as $, I as A, ee as B, U as C, B as D, te as E, A as F, S as G, y as H, j as I, _ as J, T as K, D as L, P as M, N, z as O, M as P, f as Q, O as R, W as S, V as T, C as U, b as V, w as W, v as X, g as Y, p as Z, Y as _, le as a, t as at, K as b, $ as c, l as ct, ie as d, e as et, re as f, X as g, Z as h, ue as i, c as it, F as j, L as k, oe as l, a as lt, Q as m, fe as n, i as nt, ce as o, n as ot, ne as p, E as q, de as r, u as rt, se as s, r as st, pe as t, s as tt, ae as u, o as ut, J as v, H as w, G as x, q as y, x as z };
|
|
3740
|
+
|
|
3741
|
+
//# sourceMappingURL=services-C2aqnM7h.js.map
|