Compare commits
8 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
30c9c86c93 | ||
|
2925d0f17b | ||
|
752dabd015 | ||
|
815f11d5bc | ||
02eb0e60b7 | |||
66a48d1c7e | |||
02e50bb2f9 | |||
4759f6f7ee |
File diff suppressed because it is too large
Load Diff
@ -607,8 +607,7 @@ function createGigachat(options = {}) {
|
|||||||
}
|
}
|
||||||
var gigachat = createGigachat();
|
var gigachat = createGigachat();
|
||||||
// Annotate the CommonJS export names for ESM import in node:
|
// Annotate the CommonJS export names for ESM import in node:
|
||||||
0 && (module.exports = {
|
module.exports = {
|
||||||
createGigachat,
|
createGigachat,
|
||||||
gigachat
|
gigachat
|
||||||
});
|
}
|
||||||
//# sourceMappingURL=index.js.map
|
|
||||||
|
@ -84,7 +84,7 @@ router.use(async (req, res, next) => {
|
|||||||
process.env.GIGACHAT_ACCESS_TOKEN = json.access_token;
|
process.env.GIGACHAT_ACCESS_TOKEN = json.access_token;
|
||||||
process.env.GIGACHAT_EXPIRES_AT = json.expires_at;
|
process.env.GIGACHAT_EXPIRES_AT = json.expires_at;
|
||||||
console.log(JSON.stringify(response.data));
|
console.log(JSON.stringify(response.data));
|
||||||
} catch {
|
} catch (error) {
|
||||||
console.log(error);
|
console.log(error);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -5,9 +5,11 @@ const router = Router()
|
|||||||
const todoRouter = require('./routes')
|
const todoRouter = require('./routes')
|
||||||
const authRouter = require('./auth')
|
const authRouter = require('./auth')
|
||||||
const commentRouter = require('./comment')
|
const commentRouter = require('./comment')
|
||||||
|
const navRouter = require('./nav')
|
||||||
|
|
||||||
router.use('/auth', authRouter)
|
router.use('/auth', authRouter)
|
||||||
router.use('/comment', commentRouter)
|
router.use('/comment', commentRouter)
|
||||||
|
router.use('/nav', navRouter)
|
||||||
|
|
||||||
router.use(todoRouter)
|
router.use(todoRouter)
|
||||||
|
|
||||||
|
51
server/routers/todo/nav/index.js
Normal file
51
server/routers/todo/nav/index.js
Normal file
@ -0,0 +1,51 @@
|
|||||||
|
const router = require("express").Router();
|
||||||
|
|
||||||
|
router.get("/users", (req, res) => {
|
||||||
|
res.send({
|
||||||
|
success: false,
|
||||||
|
body: [
|
||||||
|
{
|
||||||
|
id: "some-user-id",
|
||||||
|
name: "alexandr",
|
||||||
|
age: 38,
|
||||||
|
surname: null,
|
||||||
|
email: null,
|
||||||
|
rated: 4,
|
||||||
|
avatar:
|
||||||
|
"https://www.gravatar.com/avatar/6529e885535ef67a3fad810ad71167c2c03f79480936e9b3a714731753cbb47e?d=robohash",
|
||||||
|
friends: [
|
||||||
|
{
|
||||||
|
id: "2",
|
||||||
|
name: "not alexandr",
|
||||||
|
surname: null,
|
||||||
|
email: null,
|
||||||
|
rated: 2,
|
||||||
|
avatar: "https://www.gravatar.com/avatar/6e?d=robohash",
|
||||||
|
},
|
||||||
|
],
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: "2",
|
||||||
|
name: "not alexandr",
|
||||||
|
surname: null,
|
||||||
|
email: null,
|
||||||
|
age: 24,
|
||||||
|
rated: 5,
|
||||||
|
avatar: "https://www.gravatar.com/avatar/6e?d=robohash",
|
||||||
|
friends: [
|
||||||
|
{
|
||||||
|
id: "some-user-id",
|
||||||
|
name: "alexandr",
|
||||||
|
surname: null,
|
||||||
|
email: null,
|
||||||
|
rated: 3,
|
||||||
|
avatar:
|
||||||
|
"https://www.gravatar.com/avatar/6529e885535ef67a3fad810ad71167c2c03f79480936e9b3a714731753cbb47e?d=robohash",
|
||||||
|
},
|
||||||
|
],
|
||||||
|
},
|
||||||
|
],
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
module.exports = router
|
Loading…
Reference in New Issue
Block a user