diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..92a5931
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,26 @@
+.DS_Store
+node_modules
+/dist
+
+# local env files
+.env.local
+.env.*.local
+
+# Log files
+npm-debug.log*
+yarn-debug.log*
+yarn-error.log*
+pnpm-debug.log*
+
+# Editor directories and files
+.idea
+.vscode
+*.suo
+*.ntvs*
+*.njsproj
+*.sln
+*.sw?
+
+/package-lock.json
+.hbuilder
+unpackage
\ No newline at end of file
diff --git a/App.vue b/App.vue
index 2e68e7e..2c24f4e 100644
--- a/App.vue
+++ b/App.vue
@@ -3,7 +3,7 @@
// 定义全局数据
const $globalData = {
- BASE_URL: 'https://dev.api.leapy.cn',
+ BASE_URL: 'https://dev.api.leapy.cn/merchant/',
RESOURCE_URL: 'https://resource.leapy.cn/staff/'
}
diff --git a/api/login.ts b/api/login.ts
index 906b68d..843b7a5 100644
--- a/api/login.ts
+++ b/api/login.ts
@@ -7,4 +7,8 @@ export const register = (data : any) => post('/power/drv', data);
export const updateUser = (data : any) => put('/power/drv', data);
-export const deleteUser = (data : any) => del('/power/drv', data);
\ No newline at end of file
+export const deleteUser = (data : any) => del('/power/drv', data);
+
+export const captcha = (data : any) => get('v1/captcha', data);
+
+export const login = (data : any) => post('v1/login', data);
\ No newline at end of file
diff --git a/pages/login/index.vue b/pages/login/index.vue
index 1d850c6..c76e3dc 100644
--- a/pages/login/index.vue
+++ b/pages/login/index.vue
@@ -6,7 +6,7 @@
-
@@ -22,8 +22,8 @@
prefix-icon="secured" placeholderStyle="font-size:30rpx" :focus-when-clear="false"
clear-trigger="focus" clearable no-border />
-
-
+
+
@@ -32,9 +32,8 @@
登录
-
-
+
+
阅读并同意
《用户协议》
@@ -49,27 +48,59 @@
diff --git a/utils/request.ts b/utils/request.ts
index e443dfd..a18a505 100644
--- a/utils/request.ts
+++ b/utils/request.ts
@@ -25,7 +25,7 @@ function objectToQueryString(obj: Record): string {
// 获取基础URL的函数
function getBaseUrl() {
// @ts-ignore
- return uni.$globalData?.BASE_URL || 'https://dev.api.leapy.cn';
+ return uni.$globalData?.BASE_URL || 'https://dev.api.leapy.cn/merchant';
}
// 封装请求函数