| @ -1,9 +0,0 @@ | |||||
| { | |||||
| "version" : "1.0", | |||||
| "configurations" : [ | |||||
| { | |||||
| "playground" : "standard", | |||||
| "type" : "uni-app:app-android" | |||||
| } | |||||
| ] | |||||
| } | |||||
| @ -1,49 +0,0 @@ | |||||
| <script lang="uts"> | |||||
| let firstBackTime = 0 | |||||
| export default { | |||||
| onLaunch: function () { | |||||
| console.log('App Launch') | |||||
| }, | |||||
| onShow: function () { | |||||
| console.log('App Show') | |||||
| }, | |||||
| onHide: function () { | |||||
| console.log('App Hide') | |||||
| }, | |||||
| // #ifdef APP-ANDROID | |||||
| onLastPageBackPress: function () { | |||||
| console.log('App LastPageBackPress') | |||||
| if (firstBackTime == 0) { | |||||
| uni.showToast({ | |||||
| title: '再按一次退出应用', | |||||
| position: 'bottom', | |||||
| }) | |||||
| firstBackTime = Date.now() | |||||
| setTimeout(() => { | |||||
| firstBackTime = 0 | |||||
| }, 2000) | |||||
| } else if (Date.now() - firstBackTime < 2000) { | |||||
| firstBackTime = Date.now() | |||||
| uni.exit() | |||||
| } | |||||
| }, | |||||
| // #endif | |||||
| onExit: function () { | |||||
| console.log('App Exit') | |||||
| }, | |||||
| } | |||||
| </script> | |||||
| <style> | |||||
| @import "@/static/iconfont.css"; | |||||
| /*每个页面公共css */ | |||||
| .uni-row { | |||||
| flex-direction: row; | |||||
| } | |||||
| body{ | |||||
| background-color: #ffffff; | |||||
| } | |||||
| .uni-column { | |||||
| flex-direction: column; | |||||
| } | |||||
| </style> | |||||
| @ -1,3 +0,0 @@ | |||||
| # contract-front | |||||
| 合同小程序前端代码仓库 | |||||
| @ -1,20 +0,0 @@ | |||||
| <!DOCTYPE html> | |||||
| <html lang="en"> | |||||
| <head> | |||||
| <meta charset="UTF-8" /> | |||||
| <script> | |||||
| var coverSupport = 'CSS' in window && typeof CSS.supports === 'function' && (CSS.supports('top: env(a)') || | |||||
| CSS.supports('top: constant(a)')) | |||||
| document.write( | |||||
| '<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0' + | |||||
| (coverSupport ? ', viewport-fit=cover' : '') + '" />') | |||||
| </script> | |||||
| <title></title> | |||||
| <!--preload-links--> | |||||
| <!--app-context--> | |||||
| </head> | |||||
| <body> | |||||
| <div id="app"><!--app-html--></div> | |||||
| <script type="module" src="/main"></script> | |||||
| </body> | |||||
| </html> | |||||
| @ -1,9 +0,0 @@ | |||||
| import App from './App.uvue' | |||||
| import { createSSRApp } from 'vue' | |||||
| export function createApp() { | |||||
| const app = createSSRApp(App) | |||||
| return { | |||||
| app | |||||
| } | |||||
| } | |||||
| @ -1,43 +0,0 @@ | |||||
| { | |||||
| "name" : "111", | |||||
| "appid" : "__UNI__ABF0653", | |||||
| "description" : "", | |||||
| "versionName" : "1.0.0", | |||||
| "versionCode" : "100", | |||||
| "uni-app-x" : {}, | |||||
| /* 快应用特有相关 */ | |||||
| "quickapp" : {}, | |||||
| /* 小程序特有相关 */ | |||||
| "mp-weixin" : { | |||||
| "appid" : "wx7d74b5db6c1f7328", | |||||
| "setting" : { | |||||
| "urlCheck" : false | |||||
| }, | |||||
| "usingComponents" : true | |||||
| }, | |||||
| "mp-alipay" : { | |||||
| "usingComponents" : true | |||||
| }, | |||||
| "mp-baidu" : { | |||||
| "usingComponents" : true | |||||
| }, | |||||
| "mp-toutiao" : { | |||||
| "usingComponents" : true | |||||
| }, | |||||
| "uniStatistics" : { | |||||
| "enable" : false | |||||
| }, | |||||
| "vueVersion" : "3", | |||||
| "app" : { | |||||
| "distribute" : { | |||||
| "icons" : { | |||||
| "android" : { | |||||
| "hdpi" : "", | |||||
| "xhdpi" : "", | |||||
| "xxhdpi" : "", | |||||
| "xxxhdpi" : "" | |||||
| } | |||||
| } | |||||
| } | |||||
| } | |||||
| } | |||||
| @ -1,85 +0,0 @@ | |||||
| { | |||||
| "pages": [ //pages数组中第一项表示应用启动页,参考:https://uniapp.dcloud.io/collocation/pages | |||||
| { | |||||
| "path": "pages/index/login", | |||||
| "style": { | |||||
| "navigationBarTitleText": "", | |||||
| "navigationStyle":"custom" | |||||
| } | |||||
| }, | |||||
| { | |||||
| "path": "pages/home/home", | |||||
| "style": { | |||||
| "navigationBarTitleText": "主页", | |||||
| "navigationStyle":"custom" | |||||
| }, | |||||
| "needLogin": true | |||||
| }, | |||||
| { | |||||
| "path": "pages/index/wode", | |||||
| "style": { | |||||
| "navigationBarTitleText": "我的", | |||||
| "navigationStyle":"custom" | |||||
| }, | |||||
| "needLogin": true | |||||
| }, | |||||
| { | |||||
| "path": "pages/views/dingDanCreate", | |||||
| "style": { | |||||
| "navigationBarTitleText": "录入订单", | |||||
| "navigationStyle":"custom" | |||||
| }, | |||||
| "needLogin": true | |||||
| }, | |||||
| { | |||||
| "path": "pages/views/payment", | |||||
| "style": { | |||||
| "navigationBarTitleText": "付款信息", | |||||
| "navigationStyle":"custom" | |||||
| }, | |||||
| "needLogin": true | |||||
| } | |||||
| ], | |||||
| "globalStyle": { | |||||
| "navigationBarTextStyle": "black", | |||||
| "navigationBarTitleText": "uni-app x", | |||||
| "navigationBarBackgroundColor": "#F8F8F8", | |||||
| "backgroundColor": "#F8F8F8" | |||||
| }, | |||||
| "uniIdRouter": {}, | |||||
| "tabBar": { | |||||
| "color": "#7A7E83", | |||||
| "selectedColor": "#3cc51f", | |||||
| "borderStyle": "black", | |||||
| "backgroundColor": "#ffffff", | |||||
| "list": [{ | |||||
| "pagePath": "pages/home/home", | |||||
| "iconPath": "/", | |||||
| "selectedIconPath": "/static/image/路径 3909.png", | |||||
| "text": "首页" | |||||
| }, { | |||||
| "pagePath": "", | |||||
| "iconPath": "/static/image/路径 4016_1.png", | |||||
| "selectedIconPath": "/static/image/路径 4016.png", | |||||
| "text": "订单" | |||||
| }, | |||||
| { | |||||
| "pagePath": "pages/index/wode", | |||||
| "iconPath": "/static/image/路径 3917.png", | |||||
| "selectedIconPath": "/static/image/路径 24@2x.png", | |||||
| "text": "我的" | |||||
| } | |||||
| ] | |||||
| }, | |||||
| "condition" : { //模式配置,仅开发期间生效 | |||||
| "current": 0, //当前激活的模式(list 的索引项) | |||||
| "list": [ | |||||
| { | |||||
| "name": "", //模式名称 | |||||
| "path": "", //启动页面,必选 | |||||
| "query": "" //启动参数,在页面的onLoad函数里面得到 | |||||
| } | |||||
| ] | |||||
| } | |||||
| } | |||||
| @ -1,354 +0,0 @@ | |||||
| <template> | |||||
| <view class="container"> | |||||
| <!-- 顶部标题 --> | |||||
| <view class="header"> | |||||
| <view class="header_info"> | |||||
| <text class="header_text" :title="title">{{title}}</text> | |||||
| <text style="margin-right: 10rpx; font-size: 40rpx;">|</text> | |||||
| <view @click="change_text" class="header_change"> | |||||
| <text >切换</text> | |||||
| <uni-icons type="right" size="30" color="#c2d4de" :size="1"></uni-icons> | |||||
| </view> | |||||
| </view> | |||||
| </view> | |||||
| <view class="swiper"> | |||||
| <image class="swiper-image" src="/static/image/组 71699.png"></image> | |||||
| </view> | |||||
| <view class="order_Entry_container" @click="orderEntry"> | |||||
| <image class="order_Entry_image" src="/static/image/组 71699_1@3x.png"></image> | |||||
| <text style="color: #115881;font-weight: bold;margin-left: 20rpx;">录入订单</text> | |||||
| <uni-icons class="order_Entry_end" type="right" :size="25" color="#306e91"></uni-icons> | |||||
| </view> | |||||
| <view v-if="isshow" class="show_container"> | |||||
| <view class="isshow-header"> | |||||
| <uni-icons class=" isshow-header-content-icon" type="search" :size="20"></uni-icons> | |||||
| <uni-easyinput :inputBorder="false" @input="handleSearch(ServiceName)" class=" isshow-header-content-input" v-model="ServiceName" placeholder="请输入服务名称" /> | |||||
| <text class="isshow-header-content-text" @click="searchName">搜索</text> | |||||
| </view> | |||||
| <view class="isshow-content" > | |||||
| <text class="isshow-content-text" v-for="(item, index) in textcontent" :key="index" @click="change_city(item.name)">{{item.name}}</text> | |||||
| </view> | |||||
| </view> | |||||
| <view v-if="isshow_1" class="show_container_1"> | |||||
| <image class="show_container_1_image" src="/static/image/图层_6.png"></image> | |||||
| <view class="show_container_1_footer"> | |||||
| <text>门店已经切换为{{title}}</text> | |||||
| <button @click="close_view">好的</button> | |||||
| </view> | |||||
| </view> | |||||
| </view> | |||||
| </template> | |||||
| <script> | |||||
| export default { | |||||
| data() { | |||||
| return { | |||||
| ServiceName:'', | |||||
| title:"北京汽车有限公司", | |||||
| isshow:false, | |||||
| isshow_1:false, | |||||
| newListData:[], | |||||
| allMsg : [ | |||||
| { name: "myhua", id: 1 }, | |||||
| { name: "mp3", id: 2 }, | |||||
| { name: "hello", id: 3 }, | |||||
| { name: "world", id: 4 }, | |||||
| { name: "warm weather", id: 5 }, | |||||
| { name: "m3", id: 6 }, | |||||
| { name: "hahaha", id: 7 } | |||||
| ], | |||||
| textcontent: [ | |||||
| '公告1:欢迎使用车辆合同生成系统!', | |||||
| '公告2:请及时查看最新用户协议。', | |||||
| '公告3:隐私政策已更新,请知悉。', | |||||
| '公告1:欢迎使用车辆合同生成系统!', | |||||
| '公告2:请及时查看最新用户协议。', | |||||
| '公告3:隐私政策已更新,请知悉。' | |||||
| ], | |||||
| }; | |||||
| }, | |||||
| mounted() { | |||||
| this.allMsg = [ | |||||
| { name: "myhua", id: 1 }, | |||||
| { name: "mp3", id: 2 }, | |||||
| { name: "hello", id: 3 }, | |||||
| { name: "world", id: 4 }, | |||||
| { name: "warm weather", id: 5 }, | |||||
| { name: "m3", id: 6 }, | |||||
| { name: "hahaha", id: 7 } | |||||
| ]; | |||||
| this.textcontent = this.allMsg; | |||||
| }, | |||||
| methods: { | |||||
| change_text(){ | |||||
| if(this.isshow){ | |||||
| this.isshow=false; | |||||
| }else{ | |||||
| this.isshow=true; | |||||
| console.log('111') | |||||
| } | |||||
| }, | |||||
| orderEntry(){ | |||||
| console.log('111'); | |||||
| uni.navigateTo( | |||||
| { url: '/pages/views/dingDanCreate' } | |||||
| ) | |||||
| }, | |||||
| // 搜索城市名字 | |||||
| searchName(){ | |||||
| }, | |||||
| change_city(name){ | |||||
| this.title = name; | |||||
| this.change_text(); | |||||
| this.isshow_1 = true; | |||||
| }, | |||||
| close_view(){ | |||||
| this.isshow_1 = false; | |||||
| }, | |||||
| // 模糊匹配 | |||||
| // 右上角搜索框--模糊查询 | |||||
| handleSearch(queryString) { | |||||
| if(event.target.value){ | |||||
| let queryStringArr = event.target.value.split(""); | |||||
| let str = "(.*?)"; | |||||
| this.textcontent = []; | |||||
| let regStr = str + queryStringArr.join(str) + str; | |||||
| let reg = RegExp(regStr, "i"); // 以mh为例生成的正则表达式为/(.*?)m(.*?)h(.*?)/i | |||||
| this.allMsg.map(item => { | |||||
| if (reg.test(item.name)) { | |||||
| this.textcontent.push(item); | |||||
| } | |||||
| }); | |||||
| }else { | |||||
| this.textcontent=[]; | |||||
| this.textcontent = this.allMsg; | |||||
| } | |||||
| } | |||||
| } | |||||
| }; | |||||
| </script> | |||||
| <style> | |||||
| .container { | |||||
| display: flex; | |||||
| flex-direction: column; | |||||
| height: 100vh; | |||||
| background-color: #f5f5f5; | |||||
| } | |||||
| /* 头部 */ | |||||
| .header { | |||||
| padding: 20px; | |||||
| width: 100%; | |||||
| height: 15%; | |||||
| background-color: #044f7a; | |||||
| color: #fff; | |||||
| display: flex; | |||||
| flex-direction: row; | |||||
| align-items: center; | |||||
| } | |||||
| .header_info{ | |||||
| width: 100%; | |||||
| display: flex; | |||||
| flex-direction: row; | |||||
| align-items: center; | |||||
| color: #e0e9ef; | |||||
| } | |||||
| .header_text{ | |||||
| width: 45%; | |||||
| white-space: nowrap;/*设置不换行*/ | |||||
| overflow: hidden; /*设置隐藏*/ | |||||
| text-overflow: ellipsis; /*设置隐藏部分为省略号*/ | |||||
| } | |||||
| .header_change{ | |||||
| width: 100%; | |||||
| display: flex; | |||||
| flex-direction: row; | |||||
| align-items: center; | |||||
| } | |||||
| /* 订单录入 */ | |||||
| .order_Entry_container{ | |||||
| width: 90%; | |||||
| height: 8%; | |||||
| background-color: #d9e5eb; | |||||
| border-radius: 10rpx; | |||||
| left:5%; | |||||
| display: flex; | |||||
| flex-direction: row; | |||||
| align-items: center; | |||||
| margin-top: 10%; | |||||
| } | |||||
| .order_Entry_image{ | |||||
| width: 10%; | |||||
| height: 70%; | |||||
| margin-left: 3%; | |||||
| } | |||||
| .order_Entry_end{ | |||||
| margin-left: auto; | |||||
| margin-right: 7%; | |||||
| } | |||||
| /* 轮播图 */ | |||||
| .swiper { | |||||
| height: 30%; | |||||
| width: 100%; | |||||
| display: flex; | |||||
| flex-direction: row; | |||||
| align-items: center; | |||||
| overflow: hidden; | |||||
| } | |||||
| .swiper-image { | |||||
| width: 100%; | |||||
| height: 100%; | |||||
| margin: 0 auto; | |||||
| } | |||||
| .form { | |||||
| flex: 1; | |||||
| padding: 20px; | |||||
| } | |||||
| .submit-button { | |||||
| width: 100%; | |||||
| height: 40px; | |||||
| background-color: #007aff; | |||||
| color: #fff; | |||||
| border: none; | |||||
| border-radius: 4px; | |||||
| font-size: 16px; | |||||
| } | |||||
| .footer { | |||||
| display: flex; | |||||
| justify-content: space-around; | |||||
| padding: 10px; | |||||
| background-color: #fff; | |||||
| border-top: 1px solid #ccc; | |||||
| } | |||||
| .nav-item { | |||||
| text-align: center; | |||||
| } | |||||
| .nav-item text { | |||||
| font-size: 14px; | |||||
| } | |||||
| .icon-image{ | |||||
| width: 30%; | |||||
| height: 140px; | |||||
| margin: 0 auto; | |||||
| margin-top: 20px; | |||||
| } | |||||
| /* 遮罩层 */ | |||||
| .show_container{ | |||||
| width: 60%; | |||||
| height: 36%; | |||||
| background-color: #ffffff; | |||||
| position: absolute; | |||||
| border-radius: 20rpx; | |||||
| /* border: 1px solid; */ | |||||
| box-shadow: 0px 3rpx 0px #e4e4e4; | |||||
| left:5%; | |||||
| top: 13%; | |||||
| z-index:999; | |||||
| display: flex; | |||||
| flex-direction: column; | |||||
| align-items: center; | |||||
| } | |||||
| .isshow-header{ | |||||
| width: 90%; | |||||
| height: 30%; | |||||
| display: flex; | |||||
| justify-content: center; | |||||
| align-items: center; | |||||
| flex-direction: row; | |||||
| color: #3c7697; | |||||
| } | |||||
| .isshow-header-content-icon{ | |||||
| width: 10%; | |||||
| height: 30%; | |||||
| } | |||||
| .isshow-header-content-input{ | |||||
| width: 80%; | |||||
| height: 40%; | |||||
| margin: 0 20rpx 0 20rpx; | |||||
| border:none; | |||||
| outline:none; | |||||
| } | |||||
| .isshow-content{ | |||||
| height: 70%; | |||||
| display: flex; | |||||
| flex-direction: column; | |||||
| align-items: center; | |||||
| overflow-y:scroll; | |||||
| } | |||||
| .isshow-content-text{ | |||||
| color: #414141; | |||||
| height: 30rpx; | |||||
| width: 100%; | |||||
| line-height: 30rpx; | |||||
| margin: 20rpx 0 20rpx 0; | |||||
| font-size: 30rpx; | |||||
| } | |||||
| .isshow-content::-webkit-scrollbar { | |||||
| display: none; | |||||
| } | |||||
| /* 提示框*/ | |||||
| .show_container_1{ | |||||
| width: 80%; | |||||
| height: 40%; | |||||
| background-color: #ffffff; | |||||
| position: absolute; | |||||
| border-radius: 20rpx; | |||||
| /* border: 1px solid; */ | |||||
| box-shadow: 0px 3rpx 0px #e4e4e4; | |||||
| left:10%; | |||||
| top: 30%; | |||||
| z-index:999; | |||||
| display: flex; | |||||
| flex-direction: column; | |||||
| align-items: center; | |||||
| } | |||||
| .show_container_1_image{ | |||||
| height: 50%; | |||||
| width: 50%; | |||||
| top: 5%; | |||||
| } | |||||
| .show_container_1_footer{ | |||||
| height: 50%; | |||||
| width: 100%; | |||||
| color:#0b5583; | |||||
| display: flex; | |||||
| flex-direction: column; | |||||
| align-items: center; | |||||
| font-weight: bold; | |||||
| font-size: 10rpx; | |||||
| } | |||||
| .show_container_1_footer text{ | |||||
| margin-top: 10%; | |||||
| } | |||||
| .show_container_1_footer button{ | |||||
| color:#0b5583; | |||||
| height: 30%; | |||||
| border-radius: 40rpx; | |||||
| width: 80%; | |||||
| margin-top: 5%; | |||||
| border: 1px solid #0c547e; | |||||
| display: flex; | |||||
| justify-content: center; | |||||
| align-items: center; | |||||
| } | |||||
| </style> | |||||
| @ -1,105 +0,0 @@ | |||||
| <template> | |||||
| <view class="container"> | |||||
| <view class="form"> | |||||
| <input class="input" type="text" placeholder="请输入您的账号" v-model="username" /> | |||||
| <input class="input" type="password" placeholder="请输入您的密码" v-model="password" /> | |||||
| <view class="agreement"> | |||||
| <checkbox-group @change="handleAgreementChange"> | |||||
| <label> | |||||
| <checkbox value="agree" /> 阅读并同意《用户协议》和《隐私政策》 | |||||
| </label> | |||||
| </checkbox-group> | |||||
| </view> | |||||
| <button class="button" @click="handleLogin">登录</button> | |||||
| </view> | |||||
| </view> | |||||
| </template> | |||||
| <script> | |||||
| export default { | |||||
| data() { | |||||
| return { | |||||
| username: '', | |||||
| password: '', | |||||
| agreed: false | |||||
| }; | |||||
| }, | |||||
| methods: { | |||||
| handleAgreementChange(e) { | |||||
| this.agreed = e.detail.value.includes('agree'); | |||||
| }, | |||||
| handleLogin() { | |||||
| if (!this.agreed) { | |||||
| uni.showToast({ | |||||
| title: '请先同意用户协议和隐私政策', | |||||
| icon: 'none' | |||||
| }); | |||||
| return; | |||||
| } | |||||
| // 简单的登录验证逻辑 | |||||
| if (this.username === 'admin' && this.password === '123456') { | |||||
| uni.showToast({ | |||||
| title: '登录成功', | |||||
| icon: 'success', | |||||
| duration: 1500, // 提示持续时间 | |||||
| success: () => { | |||||
| // 延迟跳转,确保用户看到提示 | |||||
| setTimeout(() => { | |||||
| uni.navigateTo({ | |||||
| url: '/pages/home/home' // 跳转到首页或其他页面 | |||||
| }); | |||||
| }, 1500); | |||||
| } | |||||
| }); | |||||
| } else { | |||||
| uni.showToast({ | |||||
| title: '账号或密码错误', | |||||
| icon: 'none' | |||||
| }); | |||||
| } | |||||
| } | |||||
| } | |||||
| }; | |||||
| </script> | |||||
| <style> | |||||
| .container { | |||||
| display: flex; | |||||
| justify-content: center; | |||||
| align-items: center; | |||||
| height: 100vh; | |||||
| background-color: #f5f5f5; | |||||
| } | |||||
| .form { | |||||
| width: 80%; | |||||
| background-color: #fff; | |||||
| padding: 20px; | |||||
| border-radius: 8px; | |||||
| box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); | |||||
| } | |||||
| .input { | |||||
| width: 100%; | |||||
| height: 40px; | |||||
| margin-bottom: 15px; | |||||
| padding: 10px; | |||||
| border: 1px solid #ccc; | |||||
| border-radius: 4px; | |||||
| } | |||||
| .agreement { | |||||
| margin-bottom: 15px; | |||||
| } | |||||
| .button { | |||||
| width: 100%; | |||||
| height: 40px; | |||||
| background-color: #007aff; | |||||
| color: #fff; | |||||
| border: none; | |||||
| border-radius: 4px; | |||||
| font-size: 16px; | |||||
| } | |||||
| </style> | |||||
| @ -1,88 +0,0 @@ | |||||
| <template> | |||||
| <view class="container"> | |||||
| <view class="form"> | |||||
| <input class="input" type="text" placeholder="请输入您的账号" v-model="username" /> | |||||
| <input class="input" type="password" placeholder="请输入您的密码" v-model="password" /> | |||||
| <view class="agreement"> | |||||
| <checkbox-group @change="handleAgreementChange"> | |||||
| <label> | |||||
| <checkbox value="agree" /> 阅读并同意《用户协议》和《隐私政策》 | |||||
| </label> | |||||
| </checkbox-group> | |||||
| </view> | |||||
| <button class="button" @click="handleLogin">登录</button> | |||||
| </view> | |||||
| </view> | |||||
| </template> | |||||
| <script> | |||||
| export default { | |||||
| data() { | |||||
| return { | |||||
| username: '', | |||||
| password: '', | |||||
| agreed: false | |||||
| }; | |||||
| }, | |||||
| methods: { | |||||
| handleAgreementChange(e) { | |||||
| this.agreed = e.detail.value.includes('agree'); | |||||
| }, | |||||
| handleLogin() { | |||||
| if (!this.agreed) { | |||||
| uni.showToast({ | |||||
| title: '请先同意用户协议和隐私政策', | |||||
| icon: 'none' | |||||
| }); | |||||
| return; | |||||
| } | |||||
| // 这里可以添加登录逻辑 | |||||
| uni.showToast({ | |||||
| title: '登录成功', | |||||
| icon: 'success' | |||||
| }); | |||||
| } | |||||
| } | |||||
| }; | |||||
| </script> | |||||
| <style> | |||||
| .container { | |||||
| display: flex; | |||||
| justify-content: center; | |||||
| align-items: center; | |||||
| height: 100vh; | |||||
| background-color: #f5f5f5; | |||||
| } | |||||
| .form { | |||||
| width: 80%; | |||||
| background-color: #fff; | |||||
| padding: 20px; | |||||
| border-radius: 8px; | |||||
| box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); | |||||
| } | |||||
| .input { | |||||
| width: 100%; | |||||
| height: 40px; | |||||
| margin-bottom: 15px; | |||||
| padding: 10px; | |||||
| border: 1px solid #ccc; | |||||
| border-radius: 4px; | |||||
| } | |||||
| .agreement { | |||||
| margin-bottom: 15px; | |||||
| } | |||||
| .button { | |||||
| width: 100%; | |||||
| height: 40px; | |||||
| background-color: #007aff; | |||||
| color: #fff; | |||||
| border: none; | |||||
| border-radius: 4px; | |||||
| font-size: 16px; | |||||
| } | |||||
| </style> | |||||
| @ -1,271 +0,0 @@ | |||||
| <template> | |||||
| <view class="login-container"> | |||||
| <!-- 顶部欢迎语 --> | |||||
| <view class="login_image"> | |||||
| <image src="/static/image/组件 3 – 1.png" draggable ="false"></image> | |||||
| </view> | |||||
| <view class="welcome"> | |||||
| <text class="welcome-text">欢迎登陆车辆合同生成</text> | |||||
| </view> | |||||
| <!-- 账号输入框 --> | |||||
| <view class="input-container"> | |||||
| <uni-easyinput prefixIcon="person" class="input" placeholder="请输入您的账号" v-model="username" :inputBorder="false" ></uni-easyinput> | |||||
| <view class="underline"></view> | |||||
| </view> | |||||
| <!-- 密码输入框 --> | |||||
| <view class="input-container"> | |||||
| <uni-easyinput prefixIcon="locked" class="input" type="password" placeholder="请输入您的密码" v-model="password" :inputBorder="false" ></uni-easyinput> | |||||
| <view class="underline"></view> | |||||
| </view> | |||||
| <!-- 协议提示 --> | |||||
| <view class="agreement"> | |||||
| <radio class = "login-agree" value="r1" :checked="checked" @click="changeCK">登录即代表同意 | |||||
| </radio> | |||||
| <text class="link" @click="showModal">《用户协议》</text> | |||||
| <text class="login-agree">与</text> | |||||
| <text class="link" @click="showModal">《隐私政策》</text> | |||||
| </view> | |||||
| <view class = 'button_container'> | |||||
| <!-- 登录按钮 --> | |||||
| <button class="login-button" @click="handleLogin">登陆</button> | |||||
| </view> | |||||
| <mosowe-confirm-popup | |||||
| v-model="popupNoCancelShow" | |||||
| title="服务协议和隐私政策" | |||||
| confirmText | |||||
| cancelText | |||||
| > | |||||
| 没有取消弹框 | |||||
| <template v-slot:footer> | |||||
| <view class="mini_container"> | |||||
| <button class="mini-btn" type="primary" size="mini" @click="closeModal">取消</button> | |||||
| <button class="mini-btn" type="primary" size="mini" @click="getConfirm">确认</button> | |||||
| </view> | |||||
| </template> | |||||
| </mosowe-confirm-popup> | |||||
| </view> | |||||
| </template> | |||||
| <script> | |||||
| export default { | |||||
| data() { | |||||
| return { | |||||
| username: '', // 账号 | |||||
| password: '', // 密码 | |||||
| isModalVisible: false, // 控制弹窗显示 | |||||
| modalTitle: '', // 弹窗标题 | |||||
| modalContent: '' ,// 弹窗内容 | |||||
| popupNoCancelShow: false, | |||||
| checked:false, | |||||
| }; | |||||
| }, | |||||
| methods: { | |||||
| // 处理登录逻辑 | |||||
| handleLogin() { | |||||
| if (!this.username || !this.password) { | |||||
| uni.showToast({ title: '请输入账号和密码', icon: 'none' }); | |||||
| return; | |||||
| }else{ | |||||
| console.log(this.checked); | |||||
| if(this.checked){ | |||||
| uni.showToast({ title: '登录成功', icon: 'success' }); | |||||
| uni.switchTab({ url: '/pages/home/home' }); | |||||
| }else{ | |||||
| uni.showToast({ title: '请勾选服务协议', icon: 'none' }); | |||||
| } | |||||
| } | |||||
| }, | |||||
| // 显示弹窗 | |||||
| showModal() { | |||||
| this.popupNoCancelShow = true ; | |||||
| }, | |||||
| // 关闭弹窗 | |||||
| closeModal() { | |||||
| this.popupNoCancelShow = false ; | |||||
| }, | |||||
| change(e) { | |||||
| console.log('当前模式:' + e.type + ',状态:' + e.show); | |||||
| }, | |||||
| changeCK(){ | |||||
| if(this.checked){ | |||||
| this.checked = false; | |||||
| }else{ | |||||
| this.checked = true; | |||||
| } | |||||
| }, | |||||
| // 处理选中事件 | |||||
| getConfirm(){ | |||||
| console.log("111"); | |||||
| if(this.checked){ | |||||
| this.checked = this.checked; | |||||
| }else{ | |||||
| this.checked = true; | |||||
| } | |||||
| this.popupNoCancelShow = false; | |||||
| } | |||||
| } | |||||
| }; | |||||
| </script> | |||||
| <style> | |||||
| /* 页面容器 */ | |||||
| .login-container { | |||||
| display: flex; | |||||
| flex-direction: column; | |||||
| align-items: center; | |||||
| background-color: #ffffff; | |||||
| height: 100vh; | |||||
| width: 100%; | |||||
| } | |||||
| .button-text { | |||||
| color: #fff; | |||||
| font-size: 12px; | |||||
| } | |||||
| /* 登录图片 */ | |||||
| .login_image{ | |||||
| width: 100%; | |||||
| height: 40%; | |||||
| } | |||||
| .login_image image{ | |||||
| width: 100%; | |||||
| height: 100%; | |||||
| } | |||||
| /* 欢迎语 */ | |||||
| .welcome { | |||||
| height: 15%; | |||||
| margin-bottom: 40rpx; | |||||
| display: flex; | |||||
| justify-content: end; | |||||
| align-items: center; | |||||
| } | |||||
| .welcome-text { | |||||
| font-size: 20px; | |||||
| font-weight: bold; | |||||
| color: #044f7a; | |||||
| } | |||||
| /* 输入框容器 */ | |||||
| .input-container { | |||||
| width: 100%; | |||||
| left:10%; | |||||
| } | |||||
| /* 输入框样式 */ | |||||
| .input { | |||||
| width: 70%; | |||||
| height: 40px; | |||||
| font-size: 16px; | |||||
| border: none; | |||||
| outline: none; | |||||
| background-color: transparent; | |||||
| } | |||||
| /* 下划线样式 */ | |||||
| .underline { | |||||
| width: 100%; | |||||
| height: 1px; | |||||
| background-color: #f2f2f2; | |||||
| margin-top: 5px; | |||||
| } | |||||
| /* 协议提示 */ | |||||
| .agreement { | |||||
| font-size: 14px; | |||||
| color: #666; | |||||
| margin-bottom: 20px; | |||||
| width: 100%; | |||||
| left:10%; | |||||
| display: flex; | |||||
| flex-direction: row; | |||||
| align-items: center; | |||||
| } | |||||
| .login-agree{ | |||||
| font-size: 20rpx; | |||||
| } | |||||
| .link { | |||||
| color: #007aff; | |||||
| text-decoration: underline; | |||||
| font-size: 20rpx; | |||||
| } | |||||
| .button_container{ | |||||
| width: 100%; | |||||
| height: 40%; | |||||
| display: flex; | |||||
| align-items: center; | |||||
| } | |||||
| /* 登录按钮 */ | |||||
| .login-button { | |||||
| width: 70%; | |||||
| height: 70rpx; | |||||
| line-height: 70rpx; | |||||
| background-color: #044f7a; | |||||
| color: #fff; | |||||
| border: none; | |||||
| border-radius: 4px; | |||||
| font-size: 16px; | |||||
| position: absolute; | |||||
| top:15%; | |||||
| left:20%; | |||||
| } | |||||
| /* 弹窗样式 */ | |||||
| .modal { | |||||
| position: fixed; | |||||
| top: 0; | |||||
| left: 0; | |||||
| width: 100%; | |||||
| height: 100%; | |||||
| background-color: rgba(0, 0, 0, 0.5); | |||||
| display: flex; | |||||
| justify-content: center; | |||||
| align-items: center; | |||||
| } | |||||
| .modal-content { | |||||
| width: 80%; | |||||
| background-color: #fff; | |||||
| border-radius: 8px; | |||||
| padding: 20px; | |||||
| } | |||||
| .modal-header { | |||||
| display: flex; | |||||
| justify-content: space-between; | |||||
| align-items: center; | |||||
| font-size: 18px; | |||||
| font-weight: bold; | |||||
| margin-bottom: 15px; | |||||
| } | |||||
| .close { | |||||
| font-size: 24px; | |||||
| cursor: pointer; | |||||
| } | |||||
| .modal-body { | |||||
| font-size: 16px; | |||||
| line-height: 1.5; | |||||
| } | |||||
| .mini_container{ | |||||
| display: flex; | |||||
| flex-direction: row; | |||||
| align-items: center; | |||||
| } | |||||
| /* 按钮 */ | |||||
| .mini-btn{ | |||||
| width: 30%; | |||||
| margin-left: 15%; | |||||
| } | |||||
| </style> | |||||
| @ -1,123 +0,0 @@ | |||||
| <template> | |||||
| <view class="container"> | |||||
| <!-- 用户信息 --> | |||||
| <view class="user-info"> | |||||
| <text class="username">李晓春</text> | |||||
| </view> | |||||
| <!-- 功能列表 --> | |||||
| <view class="menu"> | |||||
| <view class="menu-item" > | |||||
| <image class="arrow" src="/static/arrow-right.png"></image> | |||||
| <text>关于我们</text> | |||||
| </view> | |||||
| <view class="menu-item" > | |||||
| <image class="arrow" src="/static/arrow-right.png"></image> | |||||
| <text>修改密码</text> | |||||
| </view> | |||||
| <view class="menu-item"> | |||||
| <image class="arrow" src="/static/arrow-right.png"></image> | |||||
| <text>服务协议</text> | |||||
| </view> | |||||
| <view class="menu-item" > | |||||
| <image class="arrow" src="/static/arrow-right.png"></image> | |||||
| <text>隐私政策</text> | |||||
| </view> | |||||
| <view class="menu-item" @click="logout"> | |||||
| <image class="arrow" src="/static/arrow-right.png"></image> | |||||
| <text>退出登录</text> | |||||
| </view> | |||||
| </view> | |||||
| </view> | |||||
| </template> | |||||
| <script> | |||||
| export default { | |||||
| methods: { | |||||
| logout() { | |||||
| uni.showModal({ | |||||
| title: '提示', | |||||
| content: '确定要退出登录吗?', | |||||
| success: (res) => { | |||||
| if (res.confirm) { | |||||
| uni.showToast({ | |||||
| title: '退出登录成功', | |||||
| icon: 'success', | |||||
| success: () => { | |||||
| // 这里可以添加退出登录的逻辑,例如清除用户登录状态 | |||||
| setTimeout(() => { | |||||
| uni.navigateTo({ url: '/pages/index/index' }); | |||||
| }, 1500); | |||||
| } | |||||
| }); | |||||
| } | |||||
| } | |||||
| }); | |||||
| } | |||||
| } | |||||
| }; | |||||
| </script> | |||||
| <style> | |||||
| .container { | |||||
| display: flex; | |||||
| flex-direction: column; | |||||
| height: 300vh; | |||||
| background-color: #f5f5f5; | |||||
| } | |||||
| .user-info { | |||||
| padding: 20px; | |||||
| height: 200px; | |||||
| background-color: #007aff; | |||||
| color: #fff; | |||||
| text-align: center; | |||||
| } | |||||
| .username { | |||||
| font-size: 20px; | |||||
| font-weight: bold; | |||||
| margin: 0 auto; | |||||
| line-height: 200px; | |||||
| } | |||||
| .menu { | |||||
| flex: 1; | |||||
| padding: 20px; | |||||
| background-color: #fff; | |||||
| } | |||||
| .menu-item { | |||||
| display: flex; | |||||
| justify-content: space-between; | |||||
| align-items: center; | |||||
| padding: 15px 0; | |||||
| border-bottom: 1px solid #eee; | |||||
| } | |||||
| .menu-item text { | |||||
| font-size: 16px; | |||||
| } | |||||
| .arrow { | |||||
| width: 20px; | |||||
| height: 20px; | |||||
| } | |||||
| .footer { | |||||
| display: flex; | |||||
| justify-content: space-around; | |||||
| padding: 10px; | |||||
| background-color: #fff; | |||||
| border-top: 1px solid #ccc; | |||||
| } | |||||
| .nav-item { | |||||
| text-align: center; | |||||
| } | |||||
| .nav-item text { | |||||
| font-size: 14px; | |||||
| } | |||||
| </style> | |||||
| @ -1,267 +0,0 @@ | |||||
| <template> | |||||
| <view class="container"> | |||||
| <!-- 顶部标题 --> | |||||
| <view class="header"> | |||||
| <view class="header_info"> | |||||
| <uni-icons class="header_info_icon" type="left" size="30" color="#c2d4de" :size="1" @click="toBack"></uni-icons> | |||||
| <text class="header_text">录入订单</text> | |||||
| </view> | |||||
| </view> | |||||
| <view class="content_container"> | |||||
| <view class="isshow-header"> | |||||
| <uni-icons class=" isshow-header-content-icon" type="search" :size="20"></uni-icons> | |||||
| <uni-easyinput :inputBorder="false" @input="handleSearch(ServiceName)" class=" isshow-header-content-input" v-model="ServiceName" placeholder="请输入服务名称" focus=true /> | |||||
| <text class="isshow-header-content-text" @click="searchName">搜索</text> | |||||
| </view> | |||||
| </view> | |||||
| <!-- 二级分类 --> | |||||
| <view class="content_footer"> | |||||
| <!-- 分类 --> | |||||
| <scroll-view show-scrollbar="false" class="content_footer_left"> | |||||
| <view v-for="(item,index) in product" :class="['content_footer_left_product', FirstIndex === item.id?'click_color':'']" @click="FirstLevelChange(item.id)">{{item.name}}</view> | |||||
| </scroll-view> | |||||
| <scroll-view show-scrollbar="false" class="content_footer_right"> | |||||
| <view v-for="(item,index) in product_2" class="content_footer_right_content"> | |||||
| <text class="text" :class="['content_footer_right_content_text', item.name === name?'select_color':'']">{{item.name}}</text> | |||||
| <radio class="content_footer_right_content_radio" value="item.id" :checked="item.name == name" activeBackgroundColor="#04517b" @click="selctRadio(item.name)"></radio> | |||||
| </view> | |||||
| </scroll-view> | |||||
| </view> | |||||
| <!-- 下一步 --> | |||||
| <button class="buttun" @click="toPayment">下一步</button> | |||||
| </view> | |||||
| </template> | |||||
| <script> | |||||
| export default { | |||||
| data() { | |||||
| return { | |||||
| product:[ | |||||
| { | |||||
| id: 1, | |||||
| name: '数码', | |||||
| children: [ | |||||
| { | |||||
| id: 12, | |||||
| name: '耳机', | |||||
| children: [ | |||||
| { id: 121, name: '漫步者' }, | |||||
| { id: 122, name: '倍思' } | |||||
| ] | |||||
| }, | |||||
| { | |||||
| id: 13, | |||||
| name: '电脑', | |||||
| children: [ | |||||
| { id: 131, name: '联想' }, | |||||
| { id: 132, name: '小米' }, | |||||
| { id: 133, name: '戴尔' } | |||||
| ] | |||||
| } | |||||
| ] | |||||
| }, | |||||
| { | |||||
| id: 2, | |||||
| name: '家用电器', | |||||
| // 类似数码的子结构 | |||||
| children:[ | |||||
| { | |||||
| id: 11, | |||||
| name: '手机', | |||||
| children: [ | |||||
| { id: 111, name: 'iphone' }, | |||||
| { id: 112, name: 'vivo' }, | |||||
| { id: 113, name: 'oppo' } | |||||
| ] | |||||
| } | |||||
| ] | |||||
| } | |||||
| ], | |||||
| product_2:[], | |||||
| FirstIndex:0, | |||||
| name:'' | |||||
| } | |||||
| }, | |||||
| methods: { | |||||
| toBack(){ | |||||
| uni.navigateBack({ | |||||
| delta: 1 | |||||
| }); | |||||
| }, | |||||
| nameClick (){ | |||||
| }, | |||||
| FirstLevelChange(id){ | |||||
| this.FirstIndex = id; | |||||
| this.product_2 = this.product[id-1].children; | |||||
| }, | |||||
| selctRadio(name){ | |||||
| console.log(name); | |||||
| this.name = name; | |||||
| } | |||||
| }, | |||||
| toPayment(){ | |||||
| console.log(111); | |||||
| uni.navigateTo( | |||||
| { url: '/pages/views/payment' } | |||||
| ) | |||||
| } | |||||
| } | |||||
| </script> | |||||
| <style> | |||||
| .container { | |||||
| display: flex; | |||||
| flex-direction: column; | |||||
| height: 100vh; | |||||
| background-color: #f5f5f5; | |||||
| position: relative; | |||||
| } | |||||
| /* 头部 */ | |||||
| .header { | |||||
| width: 100%; | |||||
| height: 15%; | |||||
| background-color: #044f7a; | |||||
| color: #fff; | |||||
| display: flex; | |||||
| flex-direction: row; | |||||
| align-items: center; | |||||
| } | |||||
| .header_info{ | |||||
| width: 100%; | |||||
| display: flex; | |||||
| flex-direction: row; | |||||
| align-items: center; | |||||
| color: #e0e9ef; | |||||
| justify-content: center; | |||||
| align-items: center; | |||||
| flex: 15; | |||||
| } | |||||
| .header_info_icon{ | |||||
| margin-right: auto; | |||||
| flex: 1; | |||||
| } | |||||
| .header_text{ | |||||
| flex: 14; | |||||
| display: flex; | |||||
| /* justify-content: center; */ | |||||
| left:35%; | |||||
| align-items: center; | |||||
| } | |||||
| /* 搜索框 */ | |||||
| .content_container{ | |||||
| width: 100%; | |||||
| height: 10%; | |||||
| display: flex; | |||||
| flex-direction: row; | |||||
| justify-content: center; | |||||
| align-items: center | |||||
| } | |||||
| .content_footer{ | |||||
| width: 100%; | |||||
| height: 75%; | |||||
| display: flex; | |||||
| flex-direction: row; | |||||
| } | |||||
| /* 搜索框 */ | |||||
| /* 遮罩层 */ | |||||
| .isshow-header{ | |||||
| width: 90%; | |||||
| height: 100%; | |||||
| display: flex; | |||||
| justify-content: center; | |||||
| align-items: center; | |||||
| flex-direction: row; | |||||
| color: #3c7697; | |||||
| } | |||||
| .isshow-header-content-icon{ | |||||
| width: 10%; | |||||
| height: 30%; | |||||
| } | |||||
| .isshow-header-content-input{ | |||||
| width: 80%; | |||||
| height: 40%; | |||||
| margin: 0 20rpx 0 20rpx; | |||||
| border:none; | |||||
| outline:none; | |||||
| } | |||||
| .isshow-content{ | |||||
| height: 70%; | |||||
| display: flex; | |||||
| flex-direction: column; | |||||
| align-items: center; | |||||
| overflow-y:scroll; | |||||
| } | |||||
| .isshow-content-text{ | |||||
| color: #414141; | |||||
| height: 30rpx; | |||||
| width: 100%; | |||||
| line-height: 30rpx; | |||||
| margin: 20rpx 0 20rpx 0; | |||||
| font-size: 30rpx; | |||||
| } | |||||
| .isshow-content::-webkit-scrollbar { | |||||
| display: none; | |||||
| } | |||||
| /* 二级分类 */ | |||||
| .content_footer_left{ | |||||
| width: 20%; | |||||
| } | |||||
| .content_footer_left_product{ | |||||
| width: 100%; | |||||
| height: 10%; | |||||
| display: flex; | |||||
| justify-content: center; | |||||
| align-items: center; | |||||
| font-size: 27rpx; | |||||
| color: #7f7f7f; | |||||
| } | |||||
| .content_footer_right{ | |||||
| width: 80%; | |||||
| display: flex; | |||||
| flex-direction: column; | |||||
| align-items: center; | |||||
| } | |||||
| .content_footer_right_content{ | |||||
| width: 100%; | |||||
| height: 10%; | |||||
| display: flex; | |||||
| flex-direction: row; | |||||
| /* background-color: red; */ | |||||
| align-items: center; | |||||
| } | |||||
| .content_footer_right_content_text{ | |||||
| margin-right: auto; | |||||
| color:#242424; | |||||
| margin-left: 5%; | |||||
| } | |||||
| .content_footer_right_content_radio{ | |||||
| margin-left: auto; | |||||
| margin-right: 5%; | |||||
| } | |||||
| /* 点击颜色 */ | |||||
| .click_color{ | |||||
| background-color: #044f7a; | |||||
| color: #f0fcf2; | |||||
| } | |||||
| .select_color{ | |||||
| color: #316b8b; | |||||
| } | |||||
| /* 按钮 */ | |||||
| .buttun{ | |||||
| width: 30%; | |||||
| position: absolute; | |||||
| display: flex; | |||||
| justify-content: center; | |||||
| align-items: center; | |||||
| font-size: 25rpx; | |||||
| border-radius: 30rpx; | |||||
| background-color: #05507c; | |||||
| bottom:5%; | |||||
| right: 5%; | |||||
| color: #fafcff; | |||||
| } | |||||
| </style> | |||||
| @ -1,22 +0,0 @@ | |||||
| <template> | |||||
| <view> | |||||
| 你好 | |||||
| </view> | |||||
| </template> | |||||
| <script> | |||||
| export default { | |||||
| data() { | |||||
| return { | |||||
| } | |||||
| }, | |||||
| methods: { | |||||
| } | |||||
| } | |||||
| </script> | |||||
| <style> | |||||
| </style> | |||||
| @ -1,63 +0,0 @@ | |||||
| @font-face { | |||||
| font-family: "iconfont"; /* Project id 2996747 */ | |||||
| src: url('/static/iconfont.ttf') format('woff2'), | |||||
| url('/static/iconfont.ttf') format('woff'), | |||||
| url('iconfont.ttf?t=1739713766886') format('truetype'); | |||||
| } | |||||
| .iconfont { | |||||
| font-family: "iconfont" !important; | |||||
| font-size: 16px; | |||||
| font-style: normal; | |||||
| -webkit-font-smoothing: antialiased; | |||||
| -moz-osx-font-smoothing: grayscale; | |||||
| } | |||||
| .qungonggao:before { | |||||
| content: "\e69a"; | |||||
| } | |||||
| .cancel:before { | |||||
| content: "\e6db"; | |||||
| } | |||||
| .showviewvisible:before { | |||||
| content: "\e9d3"; | |||||
| } | |||||
| .hideinvisiblehidden:before { | |||||
| content: "\e9db"; | |||||
| } | |||||
| .check:before { | |||||
| content: "\e645"; | |||||
| } | |||||
| .delete:before { | |||||
| content: "\e67e"; | |||||
| } | |||||
| .error:before { | |||||
| content: "\e613"; | |||||
| } | |||||
| .message:before { | |||||
| content: "\e604"; | |||||
| } | |||||
| .search:before { | |||||
| content: "\e626"; | |||||
| } | |||||
| .edit:before { | |||||
| content: "\e62a"; | |||||
| } | |||||
| .star-off:before { | |||||
| content: "\e60e"; | |||||
| } | |||||
| .goback:before { | |||||
| content: "\e68c"; | |||||
| } | |||||