diff --git a/App.vue b/App.vue
index 034116c..ca3b3be 100644
--- a/App.vue
+++ b/App.vue
@@ -144,7 +144,9 @@
z-index: 1;
height: 60upx;
padding: 12upx;
- margin-left: -20upx;
+ left: 0;
background-color: white;
+ display: flex;
+ margin: auto;
}
diff --git a/main.js b/main.js
index cd2b1c3..5467b27 100644
--- a/main.js
+++ b/main.js
@@ -25,9 +25,13 @@ import App from './App.vue'
import api from './utils/api'
import check from './utils/check'
import config from './utils/config.js'
+import { authDirective } from '@/utils/directives.js'
export function createApp() {
const app = createSSRApp(App)
+
+ app.directive('auth', authDirective)
+
app.config.globalProperties.$api = api
app.config.globalProperties.$check = check
app.config.globalProperties.$config = config
diff --git a/manifest.json b/manifest.json
index 85daf63..d3a2f0b 100644
--- a/manifest.json
+++ b/manifest.json
@@ -95,7 +95,7 @@
"vueVersion" : "3",
"h5" : {
"router" : {
- "base" : "/h5/",
+ "base" : "/h5x/",
"mode" : "hash"
},
"devServer" : {
diff --git a/pages.json b/pages.json
index 3cc717f..481efec 100644
--- a/pages.json
+++ b/pages.json
@@ -27,21 +27,21 @@
}
},
{
- "path" : "pages/ofm/booking_form",
+ "path" : "pages/ofm/mroombooking_form",
"style" :
{
"navigationBarTitleText" : "会议室预约"
}
},
{
- "path" : "pages/ofm/sealForm",
+ "path" : "pages/ofm/seal_form",
"style" :
{
"navigationBarTitleText" : "印章申请"
}
},
{
- "path" : "pages/ofm/vehicleForm",
+ "path" : "pages/ofm/vehicle_form",
"style" :
{
"navigationBarTitleText" : "用车申请"
@@ -55,7 +55,7 @@
}
},
{
- "path" : "pages/ofm/publicityForm",
+ "path" : "pages/ofm/publicity_form",
"style" :
{
"navigationBarTitleText" : "宣传报道"
@@ -111,7 +111,7 @@
}
},
{
- "path" : "pages/ofm/booking",
+ "path" : "pages/ofm/mroombooking",
"style" :
{
"navigationBarTitleText" : "预约记录",
diff --git a/pages/auth/login.vue b/pages/auth/login.vue
index 9b6f4e6..eccef4a 100644
--- a/pages/auth/login.vue
+++ b/pages/auth/login.vue
@@ -48,6 +48,7 @@
@@ -201,6 +157,7 @@
color: #2979ff;
font-size: 36rpx;
font-weight: bold;
+ margin-left: 24rpx;
}
.swiper {
diff --git a/pages/ofm/booking.vue b/pages/ofm/mroombooking.vue
similarity index 100%
rename from pages/ofm/booking.vue
rename to pages/ofm/mroombooking.vue
diff --git a/pages/ofm/booking_form.vue b/pages/ofm/mroombooking_form.vue
similarity index 90%
rename from pages/ofm/booking_form.vue
rename to pages/ofm/mroombooking_form.vue
index c9cf43c..c2f2147 100644
--- a/pages/ofm/booking_form.vue
+++ b/pages/ofm/mroombooking_form.vue
@@ -55,8 +55,8 @@
共{{totalCount}}小时 -->
-
@@ -171,24 +171,24 @@ import {actStateEnum} from "@/utils/enum.js"
}
}
await that.getmRooms();
- if(options.slots){
- that.form.slots = [];
- let slots = options.slots.split(',');
- if(slots.length>0){
- slots.forEach(item=>{
- let slot = Number(item);
- that.form.slots.push(slot);
- if(slot<12){
- that.timesListAm[slot].isSelect = true;
- that.selectList.push(that.timesListAm[slot])
- }else{
- that.timesListPm[slot].isSelect = true;
- that.selectList.push(that.timesListPm[slot])
- }
- })
- that.totalCount = slots.length*0.5;
- }
- }
+ // if(options.slots){
+ // that.form.slots = [];
+ // let slots = options.slots.split(',');
+ // if(slots.length>0){
+ // slots.forEach(item=>{
+ // let slot = Number(item);
+ // that.form.slots.push(slot);
+ // if(slot<12){
+ // that.timesListAm[slot].isSelect = true;
+ // that.selectList.push(that.timesListAm[slot])
+ // }else{
+ // that.timesListPm[slot].isSelect = true;
+ // that.selectList.push(that.timesListPm[slot])
+ // }
+ // })
+ // that.totalCount = slots.length*0.5;
+ // }
+ // }
},
methods:{
async getmRooms(){
@@ -270,11 +270,18 @@ import {actStateEnum} from "@/utils/enum.js"
that.$api.bookingSlot(form).then(res=>{
res.forEach(item=>{
if(item.slot<12){
- that.timesListAm[item.slot].sloted = true;
+ if(item.booking == that.form.id) {
+ that.timesListAm[item.slot].isSelect = true;
+ }else{
+ that.timesListAm[item.slot].sloted = true;
+ }
}else{
- that.timesListPm[item.slot-12].sloted = true;
+ if(item.booking == that.form.id) {
+ that.timesListPm[item.slot-12].isSelect = true;
+ }else{
+ that.timesListPm[item.slot-12].sloted = true;
+ }
}
-
})
})
},
diff --git a/pages/ofm/publicityForm.vue b/pages/ofm/publicity_form.vue
similarity index 100%
rename from pages/ofm/publicityForm.vue
rename to pages/ofm/publicity_form.vue
diff --git a/pages/ofm/sealForm.vue b/pages/ofm/seal_form.vue
similarity index 98%
rename from pages/ofm/sealForm.vue
rename to pages/ofm/seal_form.vue
index 8bfd311..17bbdc1 100644
--- a/pages/ofm/sealForm.vue
+++ b/pages/ofm/seal_form.vue
@@ -43,6 +43,7 @@