提交 b112eccc 编写于 作者: 刘英杰's avatar 刘英杰

初版

上级 f5b48edb
# 默认忽略的文件
/shelf/
/workspace.xml
# 基于编辑器的 HTTP 客户端请求
/httpRequests/
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/.idea/museum-reservation.iml" filepath="$PROJECT_DIR$/.idea/museum-reservation.iml" />
</modules>
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<module type="WEB_MODULE" version="4">
<component name="NewModuleRootManager">
<content url="file://$MODULE_DIR$">
<excludeFolder url="file://$MODULE_DIR$/.tmp" />
<excludeFolder url="file://$MODULE_DIR$/temp" />
<excludeFolder url="file://$MODULE_DIR$/tmp" />
</content>
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="$PROJECT_DIR$" vcs="Git" />
</component>
</project>
\ No newline at end of file
<script>
export default {
onLaunch: function() {
console.log('App Launch')
},
onShow: function() {
console.log('App Show')
},
onHide: function() {
console.log('App Hide')
}
}
</script>
<style lang="scss">
/* 注意要写在第一行,同时给style标签加入lang="scss"属性 */
@import "uview-ui/index.scss";
</style>
export function week (value){
switch(value){
case 0 :
return '周日'
break;
case 1 :
return '周一'
break;
case 2 :
return '周二'
break;
case 3 :
return '周三'
break;
case 4 :
return '周四'
break;
case 5 :
return '周五'
break;
case 6 :
return '周六'
break;
}
}
export const userAgent = ()=>{
console.log(window.navigator.userAgent,'window.navigator.userAgent');
}
\ No newline at end of file
<!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.js"></script>
</body>
</html>
import App from './App'
// #ifndef VUE3
import Vue from 'vue'
import './uni.promisify.adaptor'
import uView from 'uview-ui'
import hooks from "./hooks/index.js"
Vue.use(uView)
// 如此配置即可
uni.$u.config.unit = 'rpx'
// 调用setConfig方法,方法内部会进行对象属性深度合并,可以放心嵌套配置
// 需要在Vue.use(uView)之后执行
uni.$u.setConfig({
// 修改$u.config对象的属性
config: {
// 修改默认单位为rpx,相当于执行 uni.$u.config.unit = 'rpx'
unit: 'rpx'
},
// 修改$u.props对象的属性
props: {
// 修改radio组件的size参数的默认值,相当于执行 uni.$u.props.radio.size = 30
radio: {
size: 15
}
// 其他组件属性配置
// ......
}
})
Vue.config.productionTip = false
// import Vconsole from 'vconsole'
// let vConsole = new Vconsole()
// Vue.use(vConsole)
App.mpType = 'app'
const app = new Vue({
...App
})
app.$mount()
// #endif
// #ifdef VUE3
import { createSSRApp } from 'vue'
export function createApp() {
const app = createSSRApp(App)
return {
app
}
}
// #endif
{
"name" : "museum-reservation",
"appid" : "__UNI__B09330D",
"description" : "",
"versionName" : "1.0.0",
"versionCode" : "100",
"transformPx" : false,
/* 5+App特有相关 */
"app-plus" : {
"usingComponents" : true,
"nvueStyleCompiler" : "uni-app",
"compilerVersion" : 3,
"splashscreen" : {
"alwaysShowBeforeRender" : true,
"waiting" : true,
"autoclose" : true,
"delay" : 0
},
/* 模块配置 */
"modules" : {},
/* 应用发布信息 */
"distribute" : {
/* android打包配置 */
"android" : {
"permissions" : [
"<uses-feature android:name=\"android.hardware.camera\"/>",
"<uses-feature android:name=\"android.hardware.camera.autofocus\"/>",
"<uses-permission android:name=\"android.permission.ACCESS_NETWORK_STATE\"/>",
"<uses-permission android:name=\"android.permission.ACCESS_WIFI_STATE\"/>",
"<uses-permission android:name=\"android.permission.CAMERA\"/>",
"<uses-permission android:name=\"android.permission.CHANGE_NETWORK_STATE\"/>",
"<uses-permission android:name=\"android.permission.CHANGE_WIFI_STATE\"/>",
"<uses-permission android:name=\"android.permission.FLASHLIGHT\"/>",
"<uses-permission android:name=\"android.permission.GET_ACCOUNTS\"/>",
"<uses-permission android:name=\"android.permission.MODIFY_AUDIO_SETTINGS\"/>",
"<uses-permission android:name=\"android.permission.MOUNT_UNMOUNT_FILESYSTEMS\"/>",
"<uses-permission android:name=\"android.permission.READ_LOGS\"/>",
"<uses-permission android:name=\"android.permission.READ_PHONE_STATE\"/>",
"<uses-permission android:name=\"android.permission.VIBRATE\"/>",
"<uses-permission android:name=\"android.permission.WAKE_LOCK\"/>",
"<uses-permission android:name=\"android.permission.WRITE_SETTINGS\"/>"
]
},
/* ios打包配置 */
"ios" : {},
/* SDK配置 */
"sdkConfigs" : {
"oauth" : {
"weixin" : {
"appid" : "",
"UniversalLinks" : ""
}
}
}
}
},
/* 快应用特有相关 */
"quickapp" : {},
/* 小程序特有相关 */
"mp-weixin" : {
"appid" : "",
"setting" : {
"urlCheck" : false
},
"usingComponents" : true
},
"mp-alipay" : {
"usingComponents" : true
},
"mp-baidu" : {
"usingComponents" : true
},
"mp-toutiao" : {
"usingComponents" : true
},
"uniStatistics" : {
"enable" : false
},
"vueVersion" : "2",
"h5" : {
"devServer" : {
"proxy" : {
"/museumAppointment" : {
"target" : "https://asc.hnasct.cn",
"pathRewrite" : {}
}
},
"https" : false
},
"template" : "",
"router" : {
"mode" : "hash",
"base" : "./"
}
}
}
let baseURL = '';
// 是否在控制台显示接口请求日志,本地环境启用,打包环境禁用
let showHttpLog = false;
// 测试环境
baseURL = '/museumAppointment';
// 正式环境
// baseURL = 'XXXXX.XXXXX.com';
module.exports = {
baseURL: baseURL,
showHttpLog: showHttpLog
}
\ No newline at end of file
import {baseURL} from './base.js'
export function request (config){
return new Promise((resolt,reject)=>{
uni.request({
url: baseURL + config.url,
data: config.data || {},
method:config.methods || 'GET',
header:{
'Authorization': 'Bearer ' + window.localStorage.getItem('museum-token'),
// 'content-type': 'application/json' //自定义请求头
},
success:(e)=>{
if (e.data.code === 1) resolt(e.data)
else {
resolt(e.data)
uni.showToast({
title:e.data.msg_detail,
icon: 'none', //如果要纯文本,不要icon,将值设为'none'
duration: 2000 //持续时间为 2秒
});
}
},
fail:(e)=>{
reject(e)
uni.showToast({
title:e.data.msg_detail,
icon: 'none', //如果要纯文本,不要icon,将值设为'none'
duration: 2000 //持续时间为 2秒
});
}
})
})
}
import {request} from './http.js'
/**
* login
* */
export function test (data){
return request({
url:'/api/Login/api/Login/test?userName=asc666',
methods:'get',
data,
})
}
/**
* backGround
* */
//初始化日期可预约状态
export function getDate (data){
return request({
url:'/api/Background/api/guest/InitWeek',
methods:'get',
data,
})
}
//取消预约
export function AppointmentCancel (data){
return request({
url:`/api/Background/api/guest/AppointmentCancel?appointmentid=${data.appointmentid}`,
methods:'get',
data,
})
}
//散客预约
export function GuestCreate (data){
return request({
url:`/api/Background/api/guest/GuestCreate`,
methods:'POST',
data,
})
}
// 团队/公务 公用预约
export function TeamOrOfficialCreate (data){
return request({
url:`/api/Background/api/guest/TeamOrOfficialCreate`,
methods:'post',
data,
})
}
//预约凭证
export function GetAppointmentInfoByWX (data){
return request({
url:`/api/Background/api/guest/GetAppointmentInfoByWX?appointmentid=${data.appointmentid}`,
methods:'get',
data,
})
}
export function GetAppointmentAllInfo (data){
return request({
url:`/api/Background/api/guest/GetAppointmentAllInfo?page_index=${data.page_index}&page_size=${data.page_size}&employ_state=${data.employ_state}`,
methods:'get',
data,
})
}
//获取微信公众APPID
export function GetAppid (data){
return request({
url:`/api/Login/api/Login/GetAppid`,
methods:'get',
data,
})
}
/*
* 入馆须知 简介
* */
export function GetSysconfigurationInfoByWX (data){
return request({
url:`/api/sysconfiguration/api/sysconfig/GetSysconfigurationInfoByWX`,
methods:'get',
data,
})
}
export function GetChangeCommitList (data){
return request({
url:`/api/ChangeCommit/api/changeCommit/GetChangeCommitList?page_index=${data.page_index}&page_size=${data.page_size}&appointmentId=${data.appointmentId}`,
methods:'get',
data,
})
}
export function BatchInserAppointment (data){
return request({
url:`/api/ChangeCommit/api/changeCommit/BatchInserAppointment`,
methods:'post',
data,
})
}
export function ChangeCommitDelete (data){
return request({
url:`/api/ChangeCommit/api/changeCommit/ChangeCommitDelete?changeCommitId=${data.changeCommitId}`,
methods:'get',
data,
})
}
export function WxGzhVerify (data){
return request({
url:`/api/Login/api/Login/WxGzhVerify?code=${data.code}`,
methods:'get',
data,
})
}
export function GenerateCode (data){
return request({
url:`/api/Login/api/Login/GenerateCode?phone=${data.phone}`,
methods:'get',
data,
})
}
export function WxGzhLogin (data){
return request({
url:`/api/Login/api/Login/WxGzhLogin`,
methods:'post',
data,
})
}
export function ChangeCommitSave (data){
return request({
url:`/api/ChangeCommit/api/changeCommit/ChangeCommitSave`,
methods:'post',
data,
})
}
export function ChangeCommitInit (data){
return request({
url:`/api/ChangeCommit/api/changeCommit/ChangeCommitInit?code=${data.code}`,
methods:'get',
data,
})
}
export function GzhChangeCommitInit (data){
return request({
url:`/api/ChangeCommit/api/changeCommit/GzhChangeCommitInit?code=${data.code}`,
methods:'get',
data,
})
}
export function GetUseCarouselList (data){
return request({
url:`/api/Carousel/GetUseCarouselList`,
methods:'post',
data,
})
}
export function PCLogin (data){
return request({
url:`/api/Login/api/Login/PCLogin?phone=${data.phone}`,
methods:'get',
data,
})
}
此差异已折叠。
{
"dependencies": {
"dayjs": "^1.11.10",
"thorui-uni": "^2.9.5",
"uview-ui": "^2.0.36",
"vconsole": "^3.15.1"
},
"devDependencies": {
"sass": "^1.69.5",
"sass-loader": "^10.4.1"
}
}
{
"pages": [ //pages数组中第一项表示应用启动页,参考:https://uniapp.dcloud.io/collocation/pages
{
"path" : "pages/getWxCode/InitInfo",
"style" :
{
"navigationStyle":"custom",// 去除顶部 导航栏
"navigationBarTitleText": "博物馆预约"
}
},
{
"path" : "pages/getWxCode/teamCode",
"style" :
{
"navigationStyle":"custom"// 去除顶部 导航栏
}
},
{
"path" : "pages/SSO/index",
"style" :
{
"navigationStyle":"custom"// 去除顶部 导航栏
}
},
{
"path": "pages/index/index",
"style": {
"navigationStyle":"custom"// 去除顶部 导航栏
}
}
,{
"path" : "pages/tourist-appointment/index",
"style" :
{
"navigationStyle":"custom",// 去除顶部 导航栏
"enablePullDownRefresh": false
// "navigationBarBackgroundColor": "#F1EDE8"
}
}
,{
"path" : "pages/team-appointment/index",
"style" :
{
"navigationStyle": "custom",
"enablePullDownRefresh": false
}
}
,{
"path" : "pages/official-appointment/index",
"style" :
{
"navigationStyle":"custom"// 去除顶部 导航栏
}
}
,{
"path" : "pages/record-appointment/index",
"style" :
{
"navigationStyle":"custom"// 去除顶部 导航栏
}
}
,{
"path" : "pages/showQRcode/index",
"style" :
{
"navigationStyle":"custom"// 去除顶部 导航栏
}
}
,{
"path" : "pages/approvalEnqueue/index",
"style" :
{
"navigationStyle":"custom"// 去除顶部 导航栏
}
}
,{
"path" : "pages/share/index",
"style" :
{
"navigationStyle":"custom"// 去除顶部 导航栏
}
}
,{
"path" : "pages/login/index",
"style" :
{
"navigationStyle":"custom"// 去除顶部 导航栏
}
},
{
"path" : "pages/loginPC/index",
"style" :
{
"navigationStyle":"custom"// 去除顶部 导航栏
}
},
{
"path" : "pages/getWechatCallbackCode/index",
"style" :
{
"navigationStyle":"custom"// 去除顶部 导航栏
}
}
],
"easycom": {
"autoscan": true,
"^u-(.*)": "uview-ui/components/u-$1/u-$1.vue",
"tui-(.*)": "@/components/thorui/tui-$1/tui-$1.vue"
},
"globalStyle": {
// "navigationBarTextStyle": "black",
"navigationBarTitleText": "博物馆预约"
// "navigationBarBackgroundColor": "#F8F8F8",
// "backgroundColor": "#F8F8F8"
},
"uniIdRouter": {}
}
<template>
<view>
</view>
</template>
<script>
import * as api from '../../network/utils'
export default {
data() {
return {
}
},
methods: {
},
async onLoad() {
const res = await api.test()
window.localStorage.setItem('museum-token',res.response.access_token.token_content)
uni.navigateTo({
url:'/pages/index/index'
})
}
}
</script>
<style>
</style>
.container{
width: 100vw;
height: 100vh;
padding: 3vw;
box-sizing: border-box;
max-width: 420px;
max-height:1000px;
margin-left: auto;
margin-right: auto;
background: #fcfbfb;
}
.content{
width: 100%;
height: 93%;
overflow-y: auto;
}
.bt{
display: flex;
}
<template>
<view class="container">
<view v-if="!!checkboxList7.length" style="height: 100%">
<view class="content" :key="key">
<u-list
@scrolltolower="scrolltolower" style="overflow-y: auto"
>
<u-checkbox-group
v-model="checkboxValue7"
@change="checkboxChange"
:borderBottom="true"
placement="column"
iconPlacement="right"
:size="30"
>
<u-checkbox
:labelSize="35"
:customStyle="{marginBottom: '30px'}"
v-for="(item, index) in checkboxList7"
:key="index"
:label="item.name+'___'+['',item.identity_num,item.position][init.type]"
:name="item.id"
>
</u-checkbox>
</u-checkbox-group>
</u-list>
</view>
<view class="bt">
<u-button @click="action('reject')" style="width: 30%" shape="circle" type="primary" text="拒绝"></u-button>
<u-button @click="action('agree') " style="width: 30%" shape="circle" type="primary" text="同意"></u-button>
</view>
</view>
<u-empty v-else img-width="5001rpx" :img-height="666" mode="list"></u-empty>
</view>
</template>
<script>
import * as api from "../../network/utils";
import {BatchInserAppointment, ChangeCommitDelete} from "../../network/utils";
export default {
data() {
return {
key:1,
checkboxValue7:[],
timer:'',
init:{
page_index:1,
page_size:15,
appointmentId:'',
type:'',
},
checkboxList7: [],
}
},
onLoad(e){
console.log("🚀🚀eee🚀,",e)
this.initFun(e)
},
methods: {
action(name){
let object = {
agree:async () => {
const res = await api.BatchInserAppointment(this.checkboxValue7)
this.initFun({appointmentId:this.init.appointmentId,type:this.init.type})
this.$u.toast(res.msg)
},
reject: () => {
this.checkboxValue7.forEach(async (cur, index) => {
const res = await api.ChangeCommitDelete({changeCommitId:cur})
this.$u.toast(res.msg)
})
this.initFun({appointmentId:this.init.appointmentId,type:this.init.type})
}
}
return object[name]()
},
BatchInserAppointment(){
},
ChangeCommitDelete(){
},
checkboxChange(e){
},
initFun(e){
this.init = {...this.init,appointmentId:e.appointmentId,type:e.type}
api.GetChangeCommitList(this.init).then(res=> {
this.checkboxList7 = res.response.data
this.key ++
})
},
scrolltolower(){
clearTimeout(this.timer)
this.timer = setTimeout(()=>{
let data = {...this.init,page_size:this.init.page_size,page_index:this.init.page_index +1}
api.GetChangeCommitList(data).then(res =>!!res.response.data.length && this.init.page_index !==1 ?this.checkboxList7.push(res.response.data):this.$u.toast('没有数据了'))
},500)
},
// 3390ef28-084a-4116-bd3c-418e69dbb374
}
}
</script>
<style>
@import "index.css";
</style>
<template>
<div class="container">
</div>
</template>
<script>
import { GetWxOpenidByWxCode, isAutoLogin,stu_sso } from "@/common/api/common";
import { getStuInfo } from "@/common/api/myBaseInfo";
export default {
data() {
return {
Tips:"登录中..."
};
},
created() {
//部署阶段
const code = this.getUrlKey("code");
const params = {
wxcode: code,
};
GetWxOpenidByWxCode(params).then((resp) => {
console.log('resp',resp)
let respData = JSON.parse(resp);
this.$store.state.wxOpenId = respData.openid;
this.IsAutoLogin(respData.openid);
});
//测试阶段
//this.IsAutoLogin(this.$store.state.wxOpenId);
},
methods: {
// 截取url中的token
getUrlKey(name) {
return (
decodeURIComponent(
(new RegExp("[?|&]" + name + "=" + "([^&;]+?)(&|#|;|$)").exec(
location.href
) || [, ""])[1].replace(/\+/g, "%20")
) || null
);
},
//自动登录
IsAutoLogin(data){
isAutoLogin(data).then((resp) => {
if(resp){
setTimeout(() => {
this.SSO(data);
}, 500);
}else{
this.$router.replace("/login");
}
})
},
SSO(data){
stu_sso(data).then((resp) => {
this.UTIL.setCookie("XGTLTOKEN-COLLECTOR", resp.access_token.token_content);
//设置用户信息
getStuInfo().then((resp) => {
this.$toast.clear();
resp = resp.find((a) => {
return a.bind_state == true;
});
this.$store.state.studentId = resp.id;
this.$store.state.name = resp.name;
this.$store.state.phone = resp.phone_num;
this.$store.state.id_num = resp.id_num;
//首页
if(this.getUrlKey("links") == "" || this.getUrlKey("links") ==null){
this.$router.replace("/home");
}else{
//推送提醒链接
this.$router.replace(this.getUrlKey("links"));
}
})
});
},
},
};
</script>
<style scoped>
.container {
position:absolute;
width: 100%;
height: 100%;
display: flex;
justify-content: center;
align-items: center;
}
</style>
<template>
<div class="container">
<u-loading-icon :show="true" mode="circle" color="#4EA1E1 " size="50" style="margin-left: 1vw"></u-loading-icon>
</div>
</template>
<script>
import * as api from '../../network/utils'
export default {
data() {
return {
codeValiedateResult:'',
code:this.getUrlKey('code'),
}
},
mounted(){
this.WxGzhVerify()
},
methods: {
strategicObject(name,value){
let strategicObject = {
'true':(value)=>{
// 为真(首次登录) 直接赋值token
window.localStorage.setItem('museum-token',value.complex_token_view_model.access_token.token_content)
uni.navigateTo({
url:'/pages/index/index'
})
},
'false':(value)=>{
// 为假(非首次登录) 跳转到登录页 手机验证码登录
uni.navigateTo({
url:`/pages/login/index?openid=${value.openid}`
})
},
}
strategicObject[String(name)](value)
},
async WxGzhVerify() {
const res = await api.WxGzhVerify({code:this.code})
console.log("🚀🚀通过code获取到token🚀,",res)
this.strategicObject(res.response.login,res.response)
},
// 截取url中的token
getUrlKey(name) {
return (
decodeURIComponent(
(new RegExp("[?|&]" + name + "=" + "([^&;]+?)(&|#|;|$)").exec(
location.href
) || [, ""])[1].replace(/\+/g, "%20")
) || null
);
},
},
}
</script>
<style scoped>
.container {
position:absolute;
width: 100%;
height: 100%;
display: flex;
justify-content: center;
align-items: center;
}
</style>
<template>
<div class="container">
<u-loading-icon :show="true" mode="circle" color="#4EA1E1 " size="50" style="margin-left: 1vw"></u-loading-icon>
</div>
</template>
<script>
import * as api from '../../network/utils'
export default {
data() {
return {path:'',};
},
mounted() {
this.GetWxAppId();
},
methods: {
GetWxAppId() {
// let testurl = 'http://testdemo.frp.mdxxkj.com/#/ValidateOpenId'
let url = `${window.location.protocol+"//"+window.location.host}/museumAppointment/qth5/#/pages/getWechatCallbackCode/index`
api.GetAppid().then((resp) => {
console.log("🚀🚀我请求Appid成功了🚀,",resp)
let redirectPath = encodeURIComponent(url)
let path =
"https://open.weixin.qq.com/connect/oauth2/authorize?" +
"appid=" +
resp.response +
"&redirect_uri=" +
redirectPath +
"&response_type=code&scope=" +
'snsapi_userinfo' +
"&state=" +
1 +
"#wechat_redirect";
console.log("🚀拼接完成的url🚀🚀,完成微信链接",path)
console.log("🚀拼接完成的url🚀🚀,微信给code 回调系统链接",redirectPath)
this.path = path
// let newPath = encodeURI(path)
location.replace(path);
}).catch(error => {
this.$toast.fail ("获取code失败");
});
},
},
};
</script>
<style scoped>
.container {
position:absolute;
width: 100%;
height: 100%;
display: flex;
justify-content: center;
align-items: center;
}
</style>
<template>
<div class="container">
<u-loading-icon :show="true" mode="circle" color="#4EA1E1 " size="50" style="margin-left: 1vw"></u-loading-icon>
</div>
</template>
<script>
import * as api from '../../network/utils'
export default {
data() {
return {path:'',
init:{
appointmentid:'',
type:'',
},};
},
mounted() {
this.GetWxAppId();
},
onLoad(e){
this.init = e
},
methods: {
GetWxAppId() {
// let testurl = 'http://testdemo.frp.mdxxkj.com/#/ValidateOpenId'
let url = `${window.location.protocol+"//"+window.location.host}/museumAppointment/qth5/#/pages/share/index?appointmentid=${this.init.appointmentid}&type=${this.init.type}`
api.GetAppid().then((resp) => {
let redirectPath = encodeURIComponent(url)
let path =
"https://open.weixin.qq.com/connect/oauth2/authorize?" +
"appid=" +
resp.response +
"&redirect_uri=" +
redirectPath +
"&response_type=code&scope=" +
'snsapi_userinfo' +
"&state=" +
1 +
"#wechat_redirect";
this.path = path
// let newPath = encodeURI(path)
location.replace(path);
}).catch(error => {
this.$toast.fail ("获取code失败");
});
},
},
};
</script>
<style scoped>
.container {
position:absolute;
width: 100%;
height: 100%;
display: flex;
justify-content: center;
align-items: center;
}
</style>
.container {
width: 100vw;
height: 100vh;
--height:27%;
}
.header{
height: 35%;
width: 100%;
box-sizing: border-box;
margin-left: auto;
margin-right: auto;
position: relative;
max-width: 420px;
max-height:350px;
}
.content{
max-width: 420px;
max-height: 900px;
margin-left: auto;
margin-right: auto;
height:65%;
width: 100%;
background-color: #F3F0EB;
position: relative;
border-top-left-radius: 5%;
border-top-right-radius: 5%;
box-sizing: border-box;
}
.c-container{
height:100%;
width: 100%;
background: url('../../static/images/home-bg.png');
background-size: 100% 100%;
padding: 5%;
overflow-y: auto;
box-sizing: border-box;
}
.c-container-header{
height:20%;
width: 100%;
}
.c-container-content{
height:50%;
width: 100%;
display: flex;
align-content: space-around;
flex-wrap: wrap;
}
.c-container-content-top{
width: 100%;
height: var(--height);
display: flex;
justify-content: space-between;
}
.c-container-content-top-left,.c-container-content-top-right{
width: 47%;
height: 100%;
background: url('../../static/images/newsktd.png');
background-size: 100% 100%;
box-sizing: border-box;
border-radius: 5%;
display: flex;
align-items: center;
}
.c-container-content-top-left-container,.c-container-content-top-right-container{
width: 100%;
height: 50%;
display: flex;
justify-content: space-between;
padding: 10%;
color:rgb(116, 96, 88);
font-weight: 800;
}
.c-container-content-top-left-text,.c-container-content-top-right-text{
width: 80%;
height: 100%;
display: flex;
align-items: center;
font-size: 4.5vw;
font-family: '宋体';
font-weight: 600;
}
.c-container-content-top-left-icon,.c-container-content-top-right-icon{
width: 20%;
height: 100%;
display: flex;
align-items: center;
}
.c-container-content-center{
width: 100%;
height: var(--height);
background: url('../../static/images/newgwjd.png');
background-size: 100% 100%;
display: flex;
align-items: center;
border-radius: 3%;
}
.c-container-content-center-container,.c-container-content-footer-container{
width: 100%;
height: 50%;
display: flex;
align-content: center;
justify-content: space-between;
padding:0 7% 0 6%;
box-sizing: border-box;
color:rgb(116, 96, 88);
font-weight: 800;
}
.c-container-content-center-text,.c-container-content-footer-text{
width: 50%;
height: 100%;
display: flex;
align-items: center;
font-size: 4.5vw;
font-family: '宋体';
font-weight: 600;
}
.c-container-content-center-icon,.c-container-content-footer-icon{
width:20%;
height: 100%;
display: flex;
align-items: center;
justify-content: flex-end;
}
.c-container-content-footer{
width: 100%;
height: var(--height);
background: url('../../static/images/newyyjl.png');
background-size: 100% 100%;
box-sizing: border-box;
display: flex;
align-items: center;
border-radius: 3%;
}
.popupContainer{
max-width: 380px;
max-height: 600px;
border-radius: 20px;
width: 90vw;
height: 60vh;
background:#F3F0EB;
min-height: 400px;
}
.popupContainer-contaienr{
width: 100%;
height: 100%;
padding:10px;
box-sizing: border-box;
background: url('../../static/images/home-bg.png');
background-size: cover;
}
.popupContainer-contaienr-header{
width: 100%;
height: 8%;
display: flex;
justify-content: center;
align-items: center;
border-bottom: 0.2vh solid bisque;
}
.popupContainer-contaienr-header-text{
/*font-size: 6vw;*/
font-size: 25px;
font-family: '宋体';
}
.popupContainer-contaienr-content{
width: 100%;
height: 80%;
line-height: 3.5vh;
}
.popupContainer-contaienr-footer{
width: 100%;
height: 12%;
}
<template>
<view class="container">
<view class="header" >
<swiper style="width: 100%;height: 110%;">
<!-- <swiper-item v-for="(item,index) in imageList" :key="index">-->
<!-- <image :src="item.path" style="width: 100%;height: 100%;" ></image>-->
<!-- </swiper-item>-->
<swiper-item >
<image src="../../static/images/home.png" style="width: 100%;height: 100%;" ></image>
</swiper-item>
</swiper>
<!-- <image src="../../static/images/logo.png" style=" width: 50vw;height: 4.3vh; position: absolute;top: 3vh;left: 3vw;"></image>-->
<image src="../../static/images/logo.png" style=" max-width: 197px;max-height: 36px; width: 50vw;height: 4.3vh; position: absolute;top: 3vh;left: 10px;"></image>
</view>
<view class="content">
<view class="c-container">
<view class="c-container-header">
<view style=" margin-top:3vh; font-size: 25px;font-family: '宋体';font-weight: 600;color:rgb(116, 96, 88);">琼台书院博物馆</view>
<view @click="show = true" v-html="object.introduction" style="font-size: 1.5vh; margin-top:1vh; ">入馆须知</view>
<u-popup v-if="object.inform" :show="show" mode="center" round="40">
<slot>
<view class="popupContainer" style="">
<view class="popupContainer-contaienr">
<view class="popupContainer-contaienr-header" >
<span class="popupContainer-contaienr-header-text">入馆须知</span>
</view>
<view v-html="object.inform" class="popupContainer-contaienr-content" ></view>
<view class="popupContainer-contaienr-footer" >
<u-button color="#D89A7C" type="warning" text="我已悉知" @click="show = false"></u-button>
</view>
</view>
</view>
</slot>
</u-popup>
</view>
<view class="c-container-content">
<view class="c-container-content-top">
<view class="c-container-content-top-left" @click="tourist">
<view class="c-container-content-top-left-container">
<view class="c-container-content-top-left-text">
<span style="font-size: 21px">散客预约</span>
</view>
<view class="c-container-content-top-left-icon">
<image src="../../static/images/arrow.png" style="width: 70%;height: 50%;"></image>
</view>
</view>
</view>
<view class="c-container-content-top-right" @click="team">
<view class="c-container-content-top-right-container">
<view class="c-container-content-top-right-text">
<span style="font-size: 21px">团队预约</span>
</view>
<view class="c-container-content-top-right-icon">
<image src="../../static/images/arrow.png" style="width: 70%;height: 50%;"></image>
</view>
</view>
</view>
</view>
<view class="c-container-content-center" @click="office">
<view class="c-container-content-center-container">
<view class="c-container-content-center-text">
<span style="font-size: 21px">
公务接待预约
</span>
</view>
<view class="c-container-content-center-icon">
<image src="../../static/images/arrow.png" style="width: 30%;height: 50%;"></image>
</view>
</view>
</view>
<view class="c-container-content-footer" @click="record">
<view class="c-container-content-footer-container">
<view class="c-container-content-footer-text">
<span style="font-size: 21px">
预约记录
</span>
</view>
<view class="c-container-content-footer-icon">
<image src="../../static/images/arrow.png" style="width: 30%;height: 50%;"></image>
</view>
</view>
</view>
</view>
</view>
</view>
<!-- <u-button @click="login" text="登录"></u-button>-->
</view>
</template>
<script>
import * as api from "../../network/utils";
import {GetSysconfigurationInfoByWX} from "../../network/utils";
export default {
data() {
return {
object:{},
imageList:[],
show:true,
title: 'Hello',
// rach:'<ul><li><span style="color: rgb(116, 96, 88);">l&nbsp;书院博物馆向社会</span><span style="color: rgb(221, 169, 143);">免费</span><span style="color: rgb(116, 96, 88);">开放。</span></li><li><span style="color: rgb(116, 96, 88);">开放时间:</span></li></ul><p><span style="color: rgb(116, 96, 88);">自2023年6月起,周一闭馆调休,周二至周日09:00(开馆)——16:00(停止入馆)——17:00(闭馆),逢节假日正常闭馆。</span></p><ul><li><span style="color: rgb(116, 96, 88);">l放开区域:</span></li></ul><p><span style="color: rgb(116, 96, 88);">书院二进展厅区、三进奎星楼文物区。</span></p><ul><li><span style="color: rgb(116, 96, 88);">&nbsp;通过网上预约,每天限量发放免费参观门票,限定上午、下午预约到馆参观散客人数为</span><span style="color: rgb(221, 169, 143);">80</span><span style="color: rgb(116, 96, 88);">人,入馆时通过扫二维码、刷身份证的方式进行登记验证。</span></li></ul>',
// intro:"<p><span style=\"color: rgb(116, 96, 88);\">开放时间:自2023年6月起,周一闭馆整休</span></p><p><span style=\"color: rgb(116, 96, 88);\">周二至周日09:00(开馆) - 16:00(停止入馆) - 17:00(闭馆)</span></p><p><span style=\"color: rgb(116, 96, 88);\">节假日正常开馆。</span><span style=\"color: rgb(216, 154, 124);\">入馆须知&gt;&gt;</span></p>"
//
}
},
onLoad() {
this.GetUseCarouselList()
this.GetSysconfigurationInfoByWX()
},
watch:{
},
methods: {
GetSysconfigurationInfoByWX(){
api.GetSysconfigurationInfoByWX().then(res=>{
this.object = res.response
})
},
GetUseCarouselList(){
api.GetUseCarouselList().then(res=>{
res.response.map((cur,index)=>{
cur.path = window.location.protocol + '//' +window.location.host+cur.path
})
this.imageList = res.response
})
},
// login(){
// uni.login({
// provider: 'weixin',
// success: function (loginRes) {
// // 登录成功
// uni.getUserInfo({
// provider: 'weixin',
// success: function(info) {
// // 获取用户信息成功, info.authResult保存用户信息
// }
// })
// },
// fail: function (err) {
// console.log("🚀🚀🚀,",err)
// // 登录授权失败
// // err.code是错误码
// }
// });
// },
tourist(){
uni.navigateTo({
url:'/pages/tourist-appointment/index'
})
},
team(){
uni.navigateTo({
url:'/pages/team-appointment/index'
})
},
office(){
uni.navigateTo({
url:'/pages/official-appointment/index'
})
},
record(){
uni.navigateTo({
url:'/pages/record-appointment/index'
})
},
}
}
</script>
<style scoped lang="scss">
@import url("index.css");
</style>
.container{
width: 100vw;
height: 100vh;
background: #F1EDE8;
}
.content{
width: 100%;
height: 60%;
display: flex;
justify-content: center;
flex-wrap: wrap;
align-content: center;
padding-top: 20vw;
}
.loginImage{
width: 80%;
height: 35%;
background: url("../../static/images/logo1.png");
background-size: 100% 100%;
}
.login{
width: 100%;
padding: 10vw;
}
.validate{
margin-top: 3vw;
display: flex;
justify-content: center;
}
.wrap1 {
}
.userAgreement{
display: flex;
align-content: center;
padding-top: 3vw;
}
<template>
<view class="container">
<view class="content">
<view class="loginImage"> </view>
<view class="login">
<u--input
style="background-color: white;"
placeholder="请输入手机号"
border="surround"
v-model="init.phone"
></u--input>
<!-- <view class="validate">
<u--input
style="margin-right: 6vw;background-color: white"
placeholder="请输入验证码"
border="surround"
v-model="init.verification_code"
>
</u--input>
<view>
<u-toast ref="uToast"></u-toast>
<u-code :seconds="seconds" @end="end" @start="start" ref="uCode"
@change="codeChange"></u-code>
<u-button color="#D59171" @tap="getCode">{{tips}}</u-button>
</view>
</view> -->
<view class="userAgreement">
<u-checkbox-group
v-model="checkbox"
placement="column"
@change="checkboxChange"
>
<u-checkbox :name="1" size="30" labelSize="30" label="已阅读并同意《隐私权政策》《用户协议》"> </u-checkbox>
</u-checkbox-group>
</view>
<u-button style="margin-top: 3vw" shape="circle" color="#D59171" @click="login">登录</u-button>
</view>
</view>
</view>
</template>
<script>
import * as api from "../../network/utils";
import {GenerateCode, GetUseCarouselList} from "../../network/utils";
export default {
data() {
return {
checkbox:[],
init:{
phone:'',
verification_code:'',
openid:this.getUrlKey('openid'),
},
tips: '',
// refCode: null,
seconds: 60,
}
},
watch:{
checkbox(newValue,oldVAlue){
console.log("🚀🚀newValue🚀,",newValue)
}
},
mounted(){
},
methods: {
strategicObject(name,value){
let strategicObject = {
'true':(value)=>{
// 为真(首次登录) 直接赋值token
window.localStorage.setItem('museum-token',value.response.complex_token_view_model.access_token.token_content)
uni.navigateTo({
url:'/pages/index/index'
})
},
'false':(value)=>{
// 为假(非首次登录) 跳转到登录页 手机验证码登录
this.$u.toast(value.msg_detail)
},
}
strategicObject[String(name)](value)
},
checkboxChange(e){
console.log("🚀🚀🚀,",e)
},
GenerateCode(){
api.GenerateCode({phone:this.init.phone}).then(res=>this.$u.toast(res.msg))
},
getUrlKey(name) {
return (
decodeURIComponent(
(new RegExp("[?|&]" + name + "=" + "([^&;]+?)(&|#|;|$)").exec(
location.href
) || [, ""])[1].replace(/\+/g, "%20")
) || null
);
},
async login() {
console.log(this.init)
if(!!this.checkbox.length && this.init.phone&& this.init.openid)api.WxGzhLogin(this.init) .then(res=>{
this.strategicObject(res.response.login,res)
})
},
codeChange(text) {
this.tips = text;
},
getCode() {
if(this.$refs.uCode.canGetCode) {
// 模拟向后端请求验证码
uni.showLoading({
title: '正在获取验证码'
})
setTimeout(() => {
uni.hideLoading();
// 这里此提示会被this.start()方法中的提示覆盖
// uni.$u.toast('验证码已发送');
this.GenerateCode()
// 通知验证码组件内部开始倒计时
this.$refs.uCode.start();
}, 2000);
} else {
uni.$u.toast('倒计时结束后再发送');
}
},
end() {
// uni.$u.toast('倒计时结束');
},
start() {
// uni.$u.toast('倒计时开始');
}
}
}
</script>
<style>
@import "index.css";
</style>
.container{
width: 100vw;
height: 100vh;
background: #F1EDE8;
max-width: 420px;
max-height:1000px;
margin-left: auto;
margin-right: auto;
}
.content{
width: 100%;
height: 60%;
display: flex;
justify-content: center;
flex-wrap: wrap;
align-content: center;
padding-top: 100px;
}
.loginImage{
width: 80%;
height: 35%;
background: url("../../static/images/logo1.png");
background-size: 100% 100%;
}
.login{
width: 100%;
padding: 50px;
}
.validate{
margin-top: 15px;
display: flex;
justify-content: center;
}
.wrap1 {
}
.userAgreement{
display: flex;
align-content: center;
padding-top: 15px;
}
<template>
<view class="container">
<view class="content">
<view class="loginImage"> </view>
<view class="login">
<u--input
style="background-color: white;"
placeholder="请输入手机号"
border="surround"
v-model="init.phone"
></u--input>
<!-- <view class="validate">
<u--input
style="margin-right: 6vw;background-color: white"
placeholder="请输入验证码"
border="surround"
v-model="init.verification_code"
>
</u--input>
<view>
<u-toast ref="uToast"></u-toast>
<u-code :seconds="seconds" @end="end" @start="start" ref="uCode"
@change="codeChange"></u-code>
<u-button color="#D59171" @tap="getCode">{{tips}}</u-button>
</view>
</view> -->
<view class="userAgreement">
<u-checkbox-group
v-model="checkbox"
placement="column"
@change="checkboxChange"
>
<u-checkbox :name="1" size="30" labelSize="30" label="已阅读并同意《隐私权政策》《用户协议》"> </u-checkbox>
</u-checkbox-group>
</view>
<u-button style="margin-top: 15px" shape="circle" color="#D59171" @click="login">登录</u-button>
</view>
</view>
</view>
</template>
<script>
import * as api from "../../network/utils";
import {GenerateCode, GetUseCarouselList, PCLogin} from "../../network/utils";
export default {
data() {
return {
checkbox:[],
init:{
phone:'',
verification_code:'',
openid:this.getUrlKey('openid'),
},
tips: '',
// refCode: null,
seconds: 60,
}
},
watch:{
checkbox(newValue,oldVAlue){
console.log("🚀🚀newValue🚀,",newValue)
}
},
mounted(){
},
methods: {
strategicObject(name,value){
let strategicObject = {
'true':(value)=>{
// 为真(首次登录) 直接赋值token
window.localStorage.setItem('museum-token',value.response.complex_token_view_model.access_token.token_content)
uni.navigateTo({
url:'/pages/index/index'
})
},
'false':(value)=>{
// 为假(非首次登录) 跳转到登录页 手机验证码登录
this.$u.toast(value.msg_detail)
},
}
strategicObject[String(name)](value)
},
checkboxChange(e){
console.log("🚀🚀🚀,",e)
},
GenerateCode(){
api.GenerateCode({phone:this.init.phone}).then(res=>this.$u.toast(res.msg))
},
getUrlKey(name) {
return (
decodeURIComponent(
(new RegExp("[?|&]" + name + "=" + "([^&;]+?)(&|#|;|$)").exec(
location.href
) || [, ""])[1].replace(/\+/g, "%20")
) || null
);
},
async login() {
if(!!this.checkbox.length && this.init.phone) api.PCLogin({phone:this.init.phone}).then((res)=>{
this.strategicObject(res.response.login,res)
})
else {
uni.$u.toast('请完善信息');
}
},
codeChange(text) {
this.tips = text;
},
getCode() {
if(this.$refs.uCode.canGetCode) {
// 模拟向后端请求验证码
uni.showLoading({
title: '正在获取验证码'
})
setTimeout(() => {
uni.hideLoading();
// 这里此提示会被this.start()方法中的提示覆盖
// uni.$u.toast('验证码已发送');
this.GenerateCode()
// 通知验证码组件内部开始倒计时
this.$refs.uCode.start();
}, 2000);
} else {
uni.$u.toast('倒计时结束后再发送');
}
},
end() {
// uni.$u.toast('倒计时结束');
},
start() {
// uni.$u.toast('倒计时开始');
}
}
}
</script>
<style scoped lang="scss">
@import "index.css";
</style>
.container{
width: 100vw;
height: 100vh;
background-color: #F1EDE8;
max-width: 420px;
max-height:1000px;
margin-left: auto;
margin-right: auto;
}
.content{
max-width: 420px;
max-height:900px;
padding: 15px;
width: 100%;
height:91%;
/*padding: 5vw;*/
box-sizing: border-box;
overflow-y: auto;
}
.content-header{
padding: 15px;
border-radius: 10px;
width: 100%;
height: 35%;
background-color: white;
/*border-radius: 2vw;*/
/*padding: 3vw;*/
box-sizing: border-box;
min-height: 220px;
}
.content-header-header{
width: 100%;
height: 18%;
border-bottom: 1px solid antiquewhite;
display: flex;
align-items: center;
font-family: '宋体';
font-weight: 700;
font-size: 25px;
}
.content-header-content{
margin-left: auto;
margin-right: auto;
width: 100%;
height: 82%;
}
.content-header-content-header,.content-header-content-footer{
width: 100%;
height: 50%;
}
.content-header-content-footer-content{
width: 100%;
height: 100%;
display: flex;
}
.content-header-content-footer-footer-leftItem{
width: 24%;
height: 65%;
border-radius: 5px;
border: #d89a7c solid 1px;
}
.content-header-content-footer-footer-leftItem2{
width: 24%;
height: 65%;
border-radius: 5px;
border: #d89a7c solid 1px;
background-color: #d5c4b9;
}
.content-header-content-footer-footer-rightItem{
width: 24%;
height: 65%;
border-radius: 5px;
border: #d89a7c solid 1px;
margin-left: 10px;
}
.content-header-content-footer-footer-rightItem2{
width: 24%;
height: 65%;
border-radius: 5px;
border: #d89a7c solid 1px;
margin-left: 10px;
background-color: #d5c4b9;
}
.antemeridian-top{
width: 100%;
height:40%;
display: flex;
justify-content: flex-end;
}
.antemeridian-item{
max-width: 30px;
max-height: 20px;
width:40% ;
height: 86%;
border-bottom-left-radius: 5px;
background-color: #d89a7c;
font-size: 12px;
display: flex;
align-items: center;
justify-content: center;
color: white;
}
.antemeridian,.pm{
width: 100%;
height: 60%;
font-size: 15px;
display: flex;
justify-content: center;
font-family: '宋体';
color: #574f44;
}
.content-header-content-header-hearder,.content-header-content-footer-hearder{
width: 100%;
height: 35%;
display: flex;
align-items: center;
font-family: '宋体';
font-weight: 800;
font-size: 15px;
color: #574f44;
}
.pm{
}
.content-header-content-footer-footer{
width: 100%;
height: 65%;
background-color: red;
}
.content-header-content-header-footer{
width: 100%;
height: 65%;
display: flex;
justify-content: space-between;
}
.content-header-content-header-footer-leftItem{
width: 24%;
height: 100%;
border-radius: 5px;
border: #d89a7c solid 1px;
box-sizing: border-box;
}
.content-header-content-header-footer-leftItem1{
max-height: 60px;
max-width: 78px;
width: 24%;
height: 100%;
background-color: #d5c4b9;
border-radius: 5px;
border: #d89a7c solid 1px;
box-sizing: border-box;
}
.content-header-content-header-footer-leftItem-top{
height: 50%;
width:100%;
display: flex;
}
.content-header-content-header-footer-leftItem-top-left{
height: 100%;
width:50%;
display: flex;
align-items: flex-end;
justify-content: center;
}
.content-header-content-header-footer-leftItem-top-right{
height: 100%;
width:50%;
display: flex;
justify-content: flex-end;
}
.content-header-content-header-footer-leftItem-top-right-item{
font-size: 11px;
width: 80%;
height: 70%;
background-color: #d89a7c;
border-bottom-left-radius: 5px;
/*font-size: 2.5vw;*/
display: flex;
align-items: center;
justify-content: center;
color: white;
}
.content-header-content-header-footer-leftItem-footer{
height: 50%;
width:100%;
}
.content-header-content-header-footer-rightItem{
max-width: 60px;
max-height: 65px;
width: 20%;
height: 100%;
background-color: #f4ece6;
border-radius: 5px;
border: #d89a7c solid 1px;
box-sizing: border-box;
display: flex;
align-items: center;
justify-content: center;
position: relative;
}
.selectIconForSpecifiedDate{
width: 48%;
height: 34.99%;
background-color: #d89a7c;
position: absolute;
top: 0;
right: 0;
border-bottom-left-radius: 1.2vw;
}
.selectIconForSpecifiedDate-item{
width: 100%;
height: 100%;
display: flex;
justify-content: center;
align-items: center;
}
.named-date{
font-size: 10px;
width: 50%;
height: 50%;
/*font-size: 3vw;*/
color: #574f44;
margin-left: 1vw;
}
.named-date-icon{
}
.content-footer{
/* width: 100%;
height:60%;
min-height: 350px; */
background-color: white;
margin-top: 12px;
border-radius: 10px;
padding: 15px;
box-sizing: border-box;
}
.content-footer-container{
width: 100%;
height:83%;
position: relative;
min-height: 310px;
}
.content-footer-container1{
width: 100%;
height:83%;
position: relative;
min-height: 210px;
}
.c-f-h{
width: 100%;
height: 13%;
display: flex;
align-items: center;
line-height: 70rpx;
font-size: 36rpx;
color: #574f44;
font-weight: 700;
}
.c-f-f{
width: 100%;
height: 87%;
background-color: antiquewhite;
border-radius: 5px;
padding: 15px;
box-sizing: border-box;
display: flex;
align-content: space-around;
flex-wrap: wrap;
}
.c-f-f-i{
width: 100%;
height: 32%;
margin: 10rpx 0;
}
.c-f-f-i-t{
width: 100%;
height: 50%;
margin: 10rpx 0;
}
.c-f-f-i-f{
width: 100%;
height: 50%;
margin: 10rpx 0;
}
.c-f-button{
width: 100%;
height: 17%;
display: flex;
align-items: center;
margin-top: 3vw;
}
.footer{
max-width: 420px;
max-height:80px;
width: 100%;
height:9%;
border-top: 1px #d89a7c solid;
display: flex;
align-items: center;
justify-content: space-between;
padding: 15px;
box-sizing: border-box;
}
.input{
background-color: white;
border:none;
}
.delete-button{
border-radius: 50%;
width: 2rem;
height: 2rem;
background: #d89a7c;
position: absolute;
top:20px;
right: -12px;
}
.delete-button-close{
width: 100%;
height: 100%;
display: flex;
align-items: center;
justify-content: center;
}
.dataText{
font-size: 13px;
font-family: '宋体';
color: #574f44;
}
.date{
font-size: 13px;
font-family: '宋体';
margin-left: 5px;
display: flex;
align-items: flex;
margin-top: 0.5vw;
color: #574f44;
}
.reasonList{
margin-top: 25px;
width: 100%;
height: 25%;
background: white;
border-radius: 5px;
padding: 20px;
box-sizing: border-box;
}
.r-h{
width: 100%;
height: 25%;
font-size: 25px;
font-family: '宋体';
font-weight: bolder;
color: #574f44;
}
.r-c{
width: 100%;
height: 75%;
box-sizing: border-box;
}
此差异已折叠。
.container {
width: 100vw;
height: 100vh;
background: #F2EEE9;
max-width: 420px;
max-height:1000px;
margin-left: auto;
margin-right: auto;
}
.header{
height: 5%;
width: 100%;
min-height:44px;
}
.content{
max-width: 420px;
max-height:900px;
padding: 25px;
width: 100%;
height: 95%;
/*padding: 5vw;*/
box-sizing: border-box;
overflow-y: auto;
}
.c-item{
border-radius: 10px;
margin-bottom: 20px;
padding: 15px;
width: 100%;
height: 25%;
min-height: 190px;
/*border-radius: 2vw;*/
background: white;
/*margin-bottom: 4vw;*/
/*padding: 3vw;*/
box-sizing: border-box;
position: relative;
}
.c-h{
width: 100%;
height: 27%;
min-height: 35px;
display: flex;
align-items: center;
box-sizing: border-box;
font-size: 25px;
font-family: '宋体';
font-weight: bolder;
color: #574f44;
border-bottom: #F2EEE9 1px solid;
}
.c-c{
width: 100%;
height: 70%;
box-sizing: border-box;
}
.c-c-text-container{
display: flex;
width: 100%;
height: 20%;
min-height: 25px;
color: #574f44;
font-size: 20px;
font-family: '宋体';
margin-top: 5px;
}
.c-c-t-right{
width: 30%;
height: 100%;
display: flex;
align-items: center;
}
.c-c-t-left{
width: 70%;
height: 100%;
display: flex;
align-items: center;
justify-content: flex-end;
}
.c-c-b-container{
justify-content: flex-end;
display: flex;
margin-top: 15px;
}
.c-c-b-container1{
position: absolute;
right: 15px;
bottom: 10px;
}
此差异已折叠。
此差异已折叠。
<template>
<view class="content-footer" >
<view ref="people-list" class="content-footer-container" >
<view class="c-f-h">
参观人员
</view>
<view class="c-f-f" style="background-color: #F4ECE6;">
<view class="c-f-f-i">
<view class="c-f-f-i-t">
姓名
</view>
<view class="c-f-f-i-f">
<u-input v-model="formDataValiedate.name" class="input"></u-input>
</view>
</view>
<view class="c-f-f-i" v-if="init.type === '1'">
<view class="c-f-f-i-t">
身份证号
</view>
<view class="c-f-f-i-f">
<u-input v-model="formDataValiedate.identity_num" class="input"></u-input>
</view>
</view>
<view class="c-f-f-i" v-if="init.type === '2'">
<view class="c-f-f-i-t">
职位
</view>
<view class="c-f-f-i-f">
<u-input v-model="formDataValiedate.position" class="input"></u-input>
</view>
</view>
</view>
</view>
<view class="c-f-button">
<u-button @click="addPeople" color="#D89A7C" type="warning" shape="circle" text="保存"></u-button>
</view>
</view>
</template>
<script>
import * as api from "../../network/utils";
import {GzhChangeCommitInit} from "../../network/utils";
export default {
data() {
return {
code:this.getUrlKey('code'),
init:{
appointmentid:'',
type:'',
},
formDataValiedate:{
appointment_id:'',
identity_num:'',
name:'',
position:'',
wxopenid:'',
}
}
},
methods: {
// 截取url中的token
getUrlKey(name) {
return (
decodeURIComponent(
(new RegExp("[?|&]" + name + "=" + "([^&;]+?)(&|#|;|$)").exec(
location.href
) || [, ""])[1].replace(/\+/g, "%20")
) || null
);
},
addPeople(){
this.formDataValiedate.appointment_id = this.init.appointmentid
api.ChangeCommitSave(this.formDataValiedate).then(res=> this.$u.toast(res.msg))
}
},
onLoad(e) {
this.init = e
api.GzhChangeCommitInit({code:this.code}).then(res=>{
this.formDataValiedate = res.response
console.log("🚀🚀resresres🚀,",res)
})
}
}
</script>
<style lang="scss" scoped>
@import "index.css";
</style>
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
Markdown 格式
0% or
您添加了 0 人 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册 或