|
|
@@ -273,15 +273,19 @@
|
|
|
</a-form-item>
|
|
|
<a-form-item label="酒店政策">
|
|
|
<j-editor v-model="model.policy" />
|
|
|
+ <a-button type="primary" @click="autoPolicy()" >自动输入</a-button>
|
|
|
</a-form-item>
|
|
|
<a-form-item label="酒店介绍">
|
|
|
<j-editor v-model="model.introduction"/>
|
|
|
+ <a-button type="primary" @click="autoIntroduction()" >自动输入</a-button>
|
|
|
</a-form-item>
|
|
|
<a-form-item label="预定提醒">
|
|
|
<j-editor v-model="model.reserveRemind"/>
|
|
|
+ <a-button type="primary" @click="autoReserveRemind()" >自动输入</a-button>
|
|
|
</a-form-item>
|
|
|
<a-form-item label="交通和周边">
|
|
|
<j-editor v-model="model.traffic"/>
|
|
|
+ <a-button type="primary" @click="autoTraffic()" >自动输入</a-button>
|
|
|
</a-form-item>
|
|
|
|
|
|
<a-button type="primary" @click="submit">确定</a-button>
|
|
|
@@ -420,8 +424,14 @@
|
|
|
if(this.model.reserveRemind) values['reserveRemind'] = this.model.reserveRemind
|
|
|
if(this.model.traffic) values['traffic'] = this.model.traffic
|
|
|
editMainInfo(values).then(res=>{
|
|
|
- this.$message.success('编辑成功')
|
|
|
- localStorage.setItem("storeInfo", JSON.stringify(res.result))
|
|
|
+ // this.$message.success('编辑成功')
|
|
|
+ // localStorage.setItem("storeInfo", JSON.stringify(res.result))
|
|
|
+ if (res.code == 200){
|
|
|
+ this.$message.success('编辑成功')
|
|
|
+ localStorage.setItem("storeInfo", JSON.stringify(res.result))
|
|
|
+ }else{
|
|
|
+ this.$message.error(res.message)
|
|
|
+ }
|
|
|
})
|
|
|
}
|
|
|
});
|
|
|
@@ -478,6 +488,112 @@
|
|
|
inputValue: '',
|
|
|
});
|
|
|
},
|
|
|
+ autoPolicy(){
|
|
|
+ var _policy = `<p style=\"box-sizing: border-box; margin: 0px; cursor: text; padding: 0px; counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133;
|
|
|
+ font-family: Helvetica, Arial, sans-serif; font-size: 13px; white-space: pre-wrap; background-color: #ffffff;\"><span style=\"box-sizing: border-box;
|
|
|
+ font-weight: bolder;\">入离时间</span></p>\n<p style=\"box-sizing: border-box; margin: 0px; cursor: text; padding: 0px;
|
|
|
+ counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133; font-family: Helvetica, Arial, sans-serif; font-size: 13px;
|
|
|
+ white-space: pre-wrap; background-color: #ffffff;\"> </p>\n<p style=\"box-sizing: border-box; margin: 0px; cursor: text;
|
|
|
+ padding: 0px; counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133; font-family: Helvetica, Arial, sans-serif;
|
|
|
+ font-size: 13px; white-space: pre-wrap; background-color: #ffffff;\">入住时间:入住当天14:00后
|
|
|
+ </p>\n<p style=\"box-sizing: border-box; margin: 0px; cursor: text; padding: 0px; counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0;
|
|
|
+ color: #303133; font-family: Helvetica, Arial, sans-serif; font-size: 13px; white-space: pre-wrap; background-color: #ffffff;\">
|
|
|
+ 离店时间:离店当天12:00前</p>\n<p style=\"box-sizing: border-box; margin: 0px; cursor: text; padding: 0px;
|
|
|
+ counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133; font-family: Helvetica, Arial, sans-serif; font-size: 13px;
|
|
|
+ white-space: pre-wrap; background-color: #ffffff;\"> </p>\n<p style=\"box-sizing: border-box; margin: 0px; cursor: text; padding: 0px;
|
|
|
+ counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133; font-family: Helvetica, Arial, sans-serif; font-size: 13px;
|
|
|
+ white-space: pre-wrap; background-color: #ffffff;\"><span style=\"box-sizing: border-box; font-weight: bolder;\">
|
|
|
+ 宠物 </span></p>\n<p style=\"box-sizing: border-box; margin: 0px; cursor: text; padding: 0px; counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0;
|
|
|
+ color: #303133; font-family: Helvetica, Arial, sans-serif; font-size: 13px; white-space: pre-wrap; background-color: #ffffff;\">
|
|
|
+ </p>\n<p style=\"box-sizing: border-box; margin: 0px; cursor: text; padding: 0px; counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0;
|
|
|
+ color: #303133; font-family: Helvetica, Arial, sans-serif; font-size: 13px; white-space: pre-wrap; background-color: #ffffff;\">
|
|
|
+ 不可携带宠物。</p>\n<p style=\"box-sizing: border-box; margin: 0px; cursor: text; padding: 0px; counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0;
|
|
|
+ color: #303133; font-family: Helvetica, Arial, sans-serif; font-size: 13px; white-space: pre-wrap; background-color: #ffffff;\"> </p>\n
|
|
|
+ <p style=\"box-sizing: border-box; margin: 0px; cursor: text; padding: 0px; counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133;
|
|
|
+ font-family: Helvetica, Arial, sans-serif; font-size: 13px; white-space: pre-wrap; background-color: #ffffff;\"><span style=\"box-sizing: border-box;
|
|
|
+ font-weight: bolder;\">外宾</span></p>\n<p style=\"box-sizing: border-box; margin: 0px; cursor: text; padding: 0px;
|
|
|
+ counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133; font-family: Helvetica, Arial, sans-serif; font-size: 13px;
|
|
|
+ white-space: pre-wrap; background-color: #ffffff;\"> </p>\n<p style=\"box-sizing: border-box; margin: 0px; cursor: text; padding: 0px;
|
|
|
+ counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133; font-family: Helvetica, Arial, sans-serif; font-size: 13px;
|
|
|
+ white-space: pre-wrap; background-color: #ffffff;\">不接待外宾,该酒店只开放给持中国身份证的用户入住</p>\n<p style=\"box-sizing: border-box;
|
|
|
+ margin: 0px; cursor: text; padding: 0px; counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133;
|
|
|
+ font-family: Helvetica, Arial, sans-serif; font-size: 13px; white-space: pre-wrap; background-color: #ffffff;\"> </p>\n
|
|
|
+ <p style=\"box-sizing: border-box; margin: 0px; cursor: text; padding: 0px; counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133;
|
|
|
+ font-family: Helvetica, Arial, sans-serif; font-size: 13px; white-space: pre-wrap; background-color: #ffffff;\"><span style=\"box-sizing: border-box;
|
|
|
+ font-weight: bolder;\">膳食安排</span></p>\n<p style=\"box-sizing: border-box; margin: 0px; cursor: text; padding: 0px;
|
|
|
+ counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133; font-family: Helvetica, Arial, sans-serif; font-size: 13px;
|
|
|
+ white-space: pre-wrap; background-color: #ffffff;\"> </p>\n<p style=\"box-sizing: border-box; margin: 0px; cursor: text;
|
|
|
+ padding: 0px; counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133; font-family: Helvetica, Arial, sans-serif; font-size: 13px;
|
|
|
+ white-space: pre-wrap; background-color: #ffffff;\">价格:详询酒店</p>\n<p style=\"box-sizing: border-box; margin: 0px; cursor: text;
|
|
|
+ padding: 0px; counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133; font-family: Helvetica, Arial, sans-serif; font-size: 13px;
|
|
|
+ white-space: pre-wrap; background-color: #ffffff;\"> </p>\n<p style=\"box-sizing: border-box; margin: 0px; cursor: text; padding: 0px;
|
|
|
+ counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133; font-family: Helvetica, Arial, sans-serif; font-size: 13px;
|
|
|
+ white-space: pre-wrap; background-color: #ffffff;\"><span style=\"box-sizing: border-box; font-weight: bolder;\">儿童政策</span></p>\n
|
|
|
+ <p style=\"box-sizing: border-box; margin: 0px; cursor: text; padding: 0px; counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133;
|
|
|
+ font-family: Helvetica, Arial, sans-serif; font-size: 13px; white-space: pre-wrap; background-color: #ffffff;\"> </p>\n
|
|
|
+ <p style=\"box-sizing: border-box; margin: 0px; cursor: text; padding: 0px; counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133;
|
|
|
+ font-family: Helvetica, Arial, sans-serif; font-size: 13px; white-space: pre-wrap; background-color: #ffffff;\">•酒店允许携带儿童入住</p>\n
|
|
|
+ <p style=\"box-sizing: border-box; margin: 0px; cursor: text; padding: 0px; counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133;
|
|
|
+ font-family: Helvetica, Arial, sans-serif; font-size: 13px; white-space: pre-wrap; background-color: #ffffff;\">•
|
|
|
+ 每间客房最多容纳1名1.2米以下儿童,和成人共用现有床铺。</p>\n<p style=\"box-sizing: border-box; margin: 0px; cursor: text; padding: 0px;
|
|
|
+ counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133; font-family: Helvetica, Arial, sans-serif; font-size: 13px;
|
|
|
+ white-space: pre-wrap; background-color: #ffffff;\">•儿童/加床政策请详询酒店。</p>`;
|
|
|
+ var _this = this;
|
|
|
+ if (this.model.policy.length > 0 ){
|
|
|
+ this.$confirm({
|
|
|
+ title: '提示',
|
|
|
+ content: '您已有酒店政策内容,是否覆盖?',
|
|
|
+ onOk() {
|
|
|
+ // return new Promise((resolve, reject) => {
|
|
|
+ // setTimeout(Math.random() > 0.5 ? resolve : reject, 100);
|
|
|
+ // }).catch(() => console.log('Oops errors!'));
|
|
|
+ _this.model.policy = _policy;
|
|
|
+ },
|
|
|
+ onCancel() {},
|
|
|
+ })
|
|
|
+ }
|
|
|
+ },
|
|
|
+ autoIntroduction(){
|
|
|
+ var _introduction = `<p style="box-sizing: border-box; margin: 0px; cursor: text; padding: 0px; counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133; font-family: Helvetica, Arial, sans-serif; font-size: 13px; white-space: pre-wrap; background-color: #ffffff;">电话:</p>
|
|
|
+ <p style="box-sizing: border-box; margin: 0px; cursor: text; padding: 0px; counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133; font-family: Helvetica, Arial, sans-serif; font-size: 13px; white-space: pre-wrap; background-color: #ffffff;">房间数:</p>
|
|
|
+ <p style="box-sizing: border-box; margin: 0px; cursor: text; padding: 0px; counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133; font-family: Helvetica, Arial, sans-serif; font-size: 13px; white-space: pre-wrap; background-color: #ffffff;">开业时间:</p>
|
|
|
+ <p style="box-sizing: border-box; margin: 0px; cursor: text; padding: 0px; counter-reset: a 0 b 0 c 0 d 0 e 0 f 0 g 0 h 0 i 0; color: #303133; font-family: Helvetica, Arial, sans-serif; font-size: 13px; white-space: pre-wrap; background-color: #ffffff;">装修时间:</p>`;
|
|
|
+ var _this = this;
|
|
|
+ if (this.model.introduction.length > 0 ){
|
|
|
+ this.$confirm({
|
|
|
+ title: '提示',
|
|
|
+ content: '您已有酒店介绍内容,是否覆盖?',
|
|
|
+ onOk() {
|
|
|
+ // return new Promise((resolve, reject) => {
|
|
|
+ // setTimeout(Math.random() > 0.5 ? resolve : reject, 100);
|
|
|
+ // }).catch(() => console.log('Oops errors!'));
|
|
|
+ _this.model.introduction = _introduction;
|
|
|
+ },
|
|
|
+ onCancel() {},
|
|
|
+ })
|
|
|
+ }
|
|
|
+ },
|
|
|
+ autoReserveRemind(){
|
|
|
+ var _reserveRemind = `<p><span style="color: #303133; font-family: Helvetica, Arial, sans-serif; font-size: 13px; white-space: pre-wrap; background-color: #ffffff;">预定提醒</span></p>`;
|
|
|
+ var _this = this;
|
|
|
+ if (this.model.reserveRemind.length > 0 ){
|
|
|
+ this.$confirm({
|
|
|
+ title: '提示',
|
|
|
+ content: '您已预定提醒内容,是否覆盖?',
|
|
|
+ onOk() {
|
|
|
+ // return new Promise((resolve, reject) => {
|
|
|
+ // setTimeout(Math.random() > 0.5 ? resolve : reject, 100);
|
|
|
+ // }).catch(() => console.log('Oops errors!'));
|
|
|
+ _this.model.reserveRemind = _reserveRemind;
|
|
|
+ },
|
|
|
+ onCancel() {},
|
|
|
+ })
|
|
|
+ }
|
|
|
+ },
|
|
|
+ autoTraffic(){
|
|
|
+ console.log('获取交通周边信息');
|
|
|
+ this.$message.success('获取周边交通信息')
|
|
|
+ }
|
|
|
},
|
|
|
}
|
|
|
</script>
|