notification and package update
This commit is contained in:
parent
ae9d7fd127
commit
8e373b3dca
@ -201,6 +201,9 @@ Wwws.getwco = (wconame, ctx) => {
|
||||
];
|
||||
// save the conf for update localdb when the web page request it
|
||||
fs.outputJSONSync(webconf, webpage, { spaces: 2 });
|
||||
// create a text file with component to watch for tailwind
|
||||
|
||||
fs.outputFileSync(`../${ctx.tribe}/objects/wwws/${ctx.xapp}/src/static/css/watchtailwind.txt`,webpage.tailwindcsscontent.join("\n"),"utf-8");
|
||||
return {
|
||||
status: 200,
|
||||
ref: "Wwws",
|
||||
|
@ -9,21 +9,7 @@ const isAuthenticated = require("../middlewares/isAuthenticated");
|
||||
const router = express.Router();
|
||||
|
||||
/**
|
||||
* wait Sagar feedback for language and label description
|
||||
* @ api {post} /api/notifications/backend - Notification Backend post
|
||||
* @apiName notifBackend
|
||||
* @apiDescription Send an api result {status,ref,msg,data} to get personnalize notification by header.xlang abd by data
|
||||
* @apiGroup Notification
|
||||
*
|
||||
* @apiBody {integer} status an http status
|
||||
* @apiBody {string} ref an existing model name
|
||||
* @apiBody {string} msg a key word existing in referentiual
|
||||
* */
|
||||
|
||||
router.post("/backend", (req, res) => {});
|
||||
|
||||
/**
|
||||
* @api {get} adminapi/notifications/messages/:alias/:tribeId - Get message list for alias in tribe
|
||||
* @api {get} /adminapi/notifications/messages/:alias/:tribeId - Get message list for alias in tribe
|
||||
* @apiName notiflist
|
||||
* @apiDescription Get list of notifications for an alias and a tribe
|
||||
* @apiGroup Notifications
|
||||
@ -37,12 +23,12 @@ router.post("/backend", (req, res) => {});
|
||||
* bouture
|
||||
**/
|
||||
router.get("/messages/:alias/:tribeId", (req, res) => {
|
||||
const getnot = Notification.get(req.params.alias, req.params.tribeId);
|
||||
const getnot = Notifications.get(req.params.alias, req.params.tribeId);
|
||||
res.status(getalias.status).send(getalias);
|
||||
});
|
||||
|
||||
/**
|
||||
* @api {POST} adminapi/notifications/sendmail/:tribe/:template - Send personnalize emails
|
||||
* @api {POST} /adminapi/notifications/sendmail/:tribe/:template - Send personnalize emails
|
||||
* @apiName Sendmail
|
||||
* @apiDescription Send campain personnalized email by rendering a template store in {tribe}/template/{template}.js containing email key like html, subject, text, cc,.. as mustache templatewith blank test replaced by data.<br> It use a smtp in conf global or in adminapi/objects/tribes/itm/{tribe}.json that must have valid parameter emailcontact must be authorized by the smtp <br>
|
||||
* "emailcontact": "noreply@smatchit.io",<br>
|
||||
@ -234,7 +220,7 @@ router.get("/stat/maillinglst/:tribe", checkHeaders, async (req, res) => {
|
||||
* {"status":200, "ref":"Contact", "msg":"success", "data":{"indexlist":[]}}
|
||||
*
|
||||
*/
|
||||
router.post("/contactanonymous", checkHeaders, async (req, res) => {
|
||||
router.post("/contactanonymous/:tribe", checkHeaders, async (req, res) => {
|
||||
const done = Actions[req.body.order]
|
||||
? await Actions[req.body.order](req.body, req.session.header)
|
||||
: { status: 406, ref: "Actions", msg: "bodyerror", data: req.body };
|
||||
|
11
package.json
11
package.json
@ -19,7 +19,8 @@
|
||||
"publishtestwall": "scp -r /media/phil/usbfarm/apxtowns/dev-ants/tribes/$space phil@wall-ants://home/phil/apxtowns/testwall-ants/tribes/$space/..",
|
||||
"publishwall": "scp -r /media/phil/usbfarm/apxtowns/dev-ants/tribes/$space phil@wall-ants://home/phil/apxtowns/wall-ants/tribes/$space/..",
|
||||
"publishhouse": "scp -r /media/phil/usbfarm/apxtowns/dev-ants/tribes/$space phil@house-ants://home/phil/apxtowns/house-ants/tribes/$space/..",
|
||||
"src:css": "tailwindcss --watch -c ../$tribe/objects/wwws/$webapp/tailwind.config.js -i ../$tribe/objects/wwws/$webapp/src/static/css/twdevstyle.css -o ../$tribe/objects/wwws/$webapp/src/static/css/twstyle.css",
|
||||
"src":"echo '$tribe -- $webapp'",
|
||||
"src:css": "npx @tailwindcss/cli -i ../$tribe/objects/wwws/$webapp/src/static/css/input.css -o ../$tribe/objects/wwws/$webapp/src/static/css/output.css --watch --config ../$tribe/objects/wwws/$webapp/tailwind.config.js",
|
||||
"dist:css": "node apxtri/models/Wwws.js $tribe $webapp dist && tailwindcss --minify -c ../$tribe/objects/wwws/$webapp/tailwind.config.js -i ../$tribe/objects/wwws/$webapp/src/static/css/twdevstyle.css -o ../$tribe/objects/wwws/$webapp/dist/static/css/twstyle.css"
|
||||
},
|
||||
"commentscript": "cf wiki apxtri doc for details: yarn startpm2 -n teswallants, yarn pm2 stop testwallants, yarn pm2 delete testwallants, yarn pm2 logs --lines 200 testwall, yarn pm2 monit -n testwallants, yarn pm2 save tribe=tribeid yarn apidoc to build apidoc // space=adminapi/www/cdn/apidoc yarn publishtestwall ",
|
||||
@ -54,13 +55,13 @@
|
||||
},
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"@tailwindcss/typography": "^0.5.15",
|
||||
"@tailwindcss/typography": "^0.5.16",
|
||||
"apidoc": "^1.2.0",
|
||||
"async": "^3.2.0",
|
||||
"axios": "^1.7.8",
|
||||
"bcrypt": "^5.0.0",
|
||||
"cors": "^2.8.4",
|
||||
"daisyui": "^5.0.9",
|
||||
"daisyui": "^5.0.12",
|
||||
"dayjs": "^1.11.13",
|
||||
"dns-sync": "^0.2.1",
|
||||
"express": "^4.21.1",
|
||||
@ -83,5 +84,7 @@
|
||||
"tailwindcss": "^4.0.15",
|
||||
"uuid": "^11.0.2"
|
||||
},
|
||||
"devDependencies": {}
|
||||
"devDependencies": {
|
||||
"cross-env": "^7.0.3"
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user