new couchdb server
This commit is contained in:
parent
b41be2bb76
commit
257b790315
|
@ -9,11 +9,6 @@ const usersDb = nano.db.use("lingdocs-users");
|
||||||
const feedbackDb = nano.db.use("feedback");
|
const feedbackDb = nano.db.use("feedback");
|
||||||
const paymentsDb = nano.db.use("payments");
|
const paymentsDb = nano.db.use("payments");
|
||||||
const userDbPrefix = "userdb-";
|
const userDbPrefix = "userdb-";
|
||||||
console.log("url========")
|
|
||||||
console.log(env.couchDbURL);
|
|
||||||
nano.db.list().then((res) => {
|
|
||||||
console.log(res);
|
|
||||||
});
|
|
||||||
|
|
||||||
export async function addFeedback(feedback: any) {
|
export async function addFeedback(feedback: any) {
|
||||||
await feedbackDb.insert(feedback);
|
await feedbackDb.insert(feedback);
|
||||||
|
|
|
@ -88,7 +88,7 @@ function initializeLocalDb(type: LocalDbType, refresh: () => void, user: AT.Ling
|
||||||
db,
|
db,
|
||||||
refresh,
|
refresh,
|
||||||
sync: db.sync(
|
sync: db.sync(
|
||||||
`https://${user.userId}:${password}@couch.lingdocs.com/${name}`,
|
`https://${user.userId}:${password}@couchdb.lingdocs.com/${name}`,
|
||||||
{ live: true, retry: true },
|
{ live: true, retry: true },
|
||||||
).on("change", (info) => {
|
).on("change", (info) => {
|
||||||
if (info.direction === "pull") {
|
if (info.direction === "pull") {
|
||||||
|
|
Loading…
Reference in New Issue