mirror of
				https://codeberg.org/yeentown/barkey.git
				synced 2025-11-04 07:24:13 +00:00 
			
		
		
		
	Fix bug
This commit is contained in:
		
							parent
							
								
									58d0dc1795
								
							
						
					
					
						commit
						46fa26426d
					
				
					 1 changed files with 6 additions and 2 deletions
				
			
		| 
						 | 
					@ -25,7 +25,8 @@
 | 
				
			||||||
			<ui-button @click="remove()"><fa :icon="faTrashAlt"/> {{ $t('remove') }}</ui-button>
 | 
								<ui-button @click="remove()"><fa :icon="faTrashAlt"/> {{ $t('remove') }}</ui-button>
 | 
				
			||||||
		</section>
 | 
							</section>
 | 
				
			||||||
	</div>
 | 
						</div>
 | 
				
			||||||
	<div class="menu">
 | 
					
 | 
				
			||||||
 | 
						<div class="menu" v-if="isMyRoom">
 | 
				
			||||||
		<section>
 | 
							<section>
 | 
				
			||||||
			<ui-button @click="add()"><fa :icon="faBoxOpen"/> {{ $t('add-furniture') }}</ui-button>
 | 
								<ui-button @click="add()"><fa :icon="faBoxOpen"/> {{ $t('add-furniture') }}</ui-button>
 | 
				
			||||||
		</section>
 | 
							</section>
 | 
				
			||||||
| 
						 | 
					@ -83,6 +84,7 @@ export default Vue.extend({
 | 
				
			||||||
			carpetColor: null,
 | 
								carpetColor: null,
 | 
				
			||||||
			isTranslateMode: false,
 | 
								isTranslateMode: false,
 | 
				
			||||||
			isRotateMode: false,
 | 
								isRotateMode: false,
 | 
				
			||||||
 | 
								isMyRoom: false,
 | 
				
			||||||
			faBoxOpen, faSave, faTrashAlt, faUndo, faArrowsAlt, faBan,
 | 
								faBoxOpen, faSave, faTrashAlt, faUndo, faArrowsAlt, faBan,
 | 
				
			||||||
		};
 | 
							};
 | 
				
			||||||
	},
 | 
						},
 | 
				
			||||||
| 
						 | 
					@ -92,6 +94,8 @@ export default Vue.extend({
 | 
				
			||||||
			...parseAcct(this.acct)
 | 
								...parseAcct(this.acct)
 | 
				
			||||||
		});
 | 
							});
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							this.isMyRoom = this.$store.getters.isSignedIn && this.$store.state.i.id === user.id;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		const roomInfo = await this.$root.api('room/show', {
 | 
							const roomInfo = await this.$root.api('room/show', {
 | 
				
			||||||
			userId: user.id
 | 
								userId: user.id
 | 
				
			||||||
		});
 | 
							});
 | 
				
			||||||
| 
						 | 
					@ -99,7 +103,7 @@ export default Vue.extend({
 | 
				
			||||||
		this.roomType = roomInfo.roomType;
 | 
							this.roomType = roomInfo.roomType;
 | 
				
			||||||
		this.carpetColor = roomInfo.carpetColor;
 | 
							this.carpetColor = roomInfo.carpetColor;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		room = new Room(user, this.$store.getters.isSignedIn && this.$store.state.i.id === user.id, roomInfo, this.$el, {
 | 
							room = new Room(user, this.isMyRoom, roomInfo, this.$el, {
 | 
				
			||||||
			graphicsQuality: this.$store.state.device.roomGraphicsQuality,
 | 
								graphicsQuality: this.$store.state.device.roomGraphicsQuality,
 | 
				
			||||||
			onChangeSelect: obj => {
 | 
								onChangeSelect: obj => {
 | 
				
			||||||
				this.objectSelected = obj != null;
 | 
									this.objectSelected = obj != null;
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		
		Reference in a new issue