Commit 6b1bae95 authored by zhengke's avatar zhengke

修改

parent c1951249
...@@ -126,7 +126,7 @@ ...@@ -126,7 +126,7 @@
</el-form-item> </el-form-item>
<el-form-item label="" prop="RoomType" title="房间类型"> <el-form-item label="" prop="RoomType" title="房间类型">
<span class="label">部屋の名前</span> <span class="label">部屋の名前</span>
<el-select size="small" v-model="addMsg.RoomType" placeholder="部屋のタイプ" clearable filterable> <el-select size="small" v-model="addMsg.RoomType" @change="getNum(addMsg.RoomType)" placeholder="部屋のタイプ" clearable filterable>
<el-option v-for="item in RoomTypeList" :key="item.ID" :label="item.Name" :value="item.ID"> <el-option v-for="item in RoomTypeList" :key="item.ID" :label="item.Name" :value="item.ID">
</el-option> </el-option>
</el-select> </el-select>
...@@ -262,7 +262,7 @@ ...@@ -262,7 +262,7 @@
Id: 0, Id: 0,
RoomName: '', RoomName: '',
HotelId: '', HotelId: '',
RoomType: '', RoomType: 1,
Money: 0, Money: 0,
CostPrice: 0, CostPrice: 0,
Description: '', Description: '',
...@@ -633,6 +633,29 @@ ...@@ -633,6 +633,29 @@
}) })
this.dialogState = true; this.dialogState = true;
}, },
//change房型获取人数
getNum(id){
switch(id) {
//单间
case 1:
this.addMsg.PeopleNum=1
break;
//双人间
case 2:
this.addMsg.PeopleNum=2
break;
//三人间
case 3:
this.addMsg.PeopleNum=2
break;
case 4:
this.addMsg.PeopleNum=4
break;
case 5:
this.addMsg.PeopleNum=2
break;
}
}
} }
}; };
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment