刘翔宇-旅管家 3 years ago
parent edee3f5946
commit 82dfd0fa3d

@ -2,4 +2,6 @@
ENV = 'production'
# base api
VUE_APP_BASE_API = 'https://leyiyuyue.szgmbwg.org.cn'
VUE_APP_BASE_API = 'http://leyitest.ali251.langye.net'
#VUE_APP_BASE_API = 'https://leyiyuyue.szgmbwg.org.cn'

@ -59,7 +59,7 @@
<el-form-item prop="time" label="活动/参观时间">
<!-- <el-date-picker style="width:100%" v-model="form.parames.time" type="datetime"
value-format="yyyy-MM-dd HH:mm:ss" placeholder="选择活动/参观时间">
</el-date-picker> -->
</el-date-picker> -->
<el-input v-model="paramesObj.time" placeholder="请填写活动/参观时间" autocomplete="off"></el-input>
</el-form-item>
</el-col>
@ -78,8 +78,10 @@
</div>
</template>
<script>
import {sendMessage} from '@/api/order/message.js'
<script>
import {
sendMessage
} from '@/api/order/message.js'
export default {
data() {
return {
@ -87,15 +89,159 @@
mobile: [],
template_id: '',
parames: {}
},
mobileList:[],
paramesObj: {
name: "",
time: "",
address: ""
},
rules: {
mobileList: [{
mobile: '13913109900'
},
{
mobile: '18501505657'
},
{
mobile: '18652421281'
},
{
mobile: '13270977225'
},
{
mobile: '13052801292'
},
{
mobile: '18896587663'
},
{
mobile: '13951887524'
},
{
mobile: '18913575992'
},
{
mobile: '15295671438'
},
{
mobile: '13915422122'
},
{
mobile: '18670287910'
},
{
mobile: '15850872937'
},
{
mobile: '15962180796'
},
{
mobile: '15995892928'
},
{
mobile: '18151085929'
},
{
mobile: '15962427069'
},
{
mobile: '13013869797'
},
{
mobile: '13861334007'
},
{
mobile: '15370062080'
},
{
mobile: '15251680185'
},
{
mobile: '18906235118'
},
{
mobile: '13063730025'
},
{
mobile: '13306176337'
},
{
mobile: '18865711856'
},
{
mobile: '13032530763'
},
{
mobile: '13862735851'
},
{
mobile: '18862321502'
},
{
mobile: '18896523808'
},
{
mobile: '18913183396'
},
{
mobile: '17397929991'
},
{
mobile: '13771938730'
},
{
mobile: '13814897494'
},
{
mobile: '13814800749'
},
{
mobile: '18896716581'
},
{
mobile: '15995808679'
},
{
mobile: '18695190691'
},
{
mobile: '13664165211'
},
{
mobile: '15851467293'
},
{
mobile: '13862089260'
},
{
mobile: '13906222159'
},
{
mobile: '13913553385'
},
{
mobile: '15606250566'
},
{
mobile: '13961314486'
},
{
mobile: '13584837778'
},
{
mobile: '18251371032'
},
{
mobile: '13222751128'
},
{
mobile: '13771767056'
},
{
mobile: '18550337240'
}
],
paramesObj: {
name: "“乐益大讲堂”第一讲《九如巷张氏与乐益女中",
time: "4月8日(本周六)14:00-16:00",
address: "中共苏州独立支部旧址(体育场路4号)一楼报告厅"
},
rules: {
},
formLabelWidth: '120px',
templateList: [{
@ -105,46 +251,46 @@
}
},
methods: {
submitForm(formName) {
let that = this
console.log(this.form)
if(!this.form.template_id){
that.$message.error('请选择短信模版');
return
}
if(this.mobileList.length<1){
that.$message.error('请填写联系人手机号');
return
}
for(var k of this.mobileList){
this.form.mobile.push(k.mobile)
}
this.form.parames = this.paramesObj
console.log(this.form)
this.$refs[formName].validate((valid) => {
if (valid) {
sendMessage(that.form).then(response => {
this.$Message.success('发送成功');
that.resetForm('form')
}).catch(error => {})
} else {
this.$Message.error('数据校验失败');
return false;
}
});
submitForm(formName) {
let that = this
console.log(this.form)
if (!this.form.template_id) {
that.$message.error('请选择短信模版');
return
}
if (this.mobileList.length < 1) {
that.$message.error('请填写联系人手机号');
return
}
for (var k of this.mobileList) {
this.form.mobile.push(k.mobile)
}
this.form.parames = this.paramesObj
console.log(this.form)
this.$refs[formName].validate((valid) => {
if (valid) {
sendMessage(that.form).then(response => {
this.$Message.success('发送成功');
that.resetForm('form')
}).catch(error => {})
} else {
this.$Message.error('数据校验失败');
return false;
}
});
},
resetForm(formName) {
this.mobileList = []
this.paramesObj = {}
this.$refs[formName].resetFields();
resetForm(formName) {
this.mobileList = []
this.paramesObj = {}
this.$refs[formName].resetFields();
}
},
}
</script>
<style>
</style>
</style>
Loading…
Cancel
Save