宁波既有建筑外墙脱落问卷调查
@@ -17,7 +17,7 @@ namespace Ewide.Web.Entry.Controllers
|
||||
}
|
||||
public IActionResult Login()
|
||||
{
|
||||
ViewBag.Title = "宁波市“甬江建设杯”选票";
|
||||
//ViewBag.Title = "宁波市“甬江建设杯”选票";
|
||||
return View();
|
||||
}
|
||||
public IActionResult Expert()
|
||||
|
||||
@@ -3,12 +3,16 @@ using Microsoft.AspNetCore.Mvc;
|
||||
|
||||
namespace Ewide.Web.Entry.Controllers
|
||||
{
|
||||
[AllowAnonymous]
|
||||
public class OutsideWallController : Controller
|
||||
{
|
||||
[AllowAnonymous]
|
||||
public IActionResult Index()
|
||||
{
|
||||
return View();
|
||||
}
|
||||
public IActionResult Result()
|
||||
{
|
||||
return View();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
<script src="https://unpkg.com/element-ui/lib/index.js"></script>
|
||||
<script src="https://unpkg.com/axios/dist/axios.min.js"></script>
|
||||
<script src="http://lib.baomitu.com/qs/6.10.3/qs.min.js"></script>
|
||||
<script src="http://lib.baomitu.com/jsencrypt/3.2.1/jsencrypt.min.js"></script>
|
||||
<script src="https://lib.baomitu.com/jsencrypt/3.2.1/jsencrypt.min.js"></script>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
@@ -102,7 +102,8 @@
|
||||
else {
|
||||
window.sessionStorage.setItem('__TOKEN', response.data.data.token);
|
||||
//location = '/gb/yjb/manage/VoteResult'
|
||||
location = '/gb/yjb/manage/nbczResult'
|
||||
//location = '/gb/yjb/manage/nbczResult'
|
||||
location = '/gb/yjb/outsidewall/result'
|
||||
}
|
||||
}
|
||||
_this.loading = false;
|
||||
|
||||
@@ -20,8 +20,11 @@
|
||||
<div id="app" v-loading="loading">
|
||||
<h3 style="text-align:center;">宁波既有建筑外墙脱落问卷调查</h3>
|
||||
<el-form label-position="left" ref="form" :model="form" :rules="rules" label-width="160px" style="margin-top:15px;">
|
||||
<el-form-item label="1.社区/小区名:" prop="communityName">
|
||||
<el-input v-model="form.communityName"></el-input>
|
||||
<el-form-item label="1.社区/小区名:" prop="communityId">
|
||||
<el-select v-model="form.communityId" filterable placeholder="请选择" @@change="selectCommunity">
|
||||
<el-option v-for="item in communitys" :key="item.id" :label="item.name" :value="item.id">
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="2.小区交付年份:" prop="deliveryear">
|
||||
<el-input v-model="form.deliveryear"></el-input>
|
||||
@@ -39,8 +42,8 @@
|
||||
<el-input v-model="form.hangye"></el-input>
|
||||
</el-form-item>*@
|
||||
<el-form-item label="3.外墙结构:" prop="outsidewallstructurefiles">
|
||||
|
||||
<el-upload class="upload-demo" drag action="https://jsonplaceholder.typicode.com/posts/" multiple :auto-upload="false" :on-preview="handlePreview" :on-remove="handleRemove" :file-list="fileList" :on-change="fileChange">
|
||||
@*:on-change="fileChange"*@
|
||||
<el-upload class="upload-demo" drag action="/gb/yjb/api/outsidewall/sysFileInfo/upload" multiple :auto-upload="true" :on-preview="handlePreview" :on-remove="(file, fileList)=>{return handleRemove(file, fileList)}" :file-list="fileList" :on-success="(response, file, fileList)=>{return fileChange(response, file, fileList)}">
|
||||
<i class="el-icon-upload"></i>
|
||||
<div class="el-upload__text"><em>上传外墙照片</em></div>
|
||||
<div class="el-upload__tip" slot="tip">只能上传jpg/png文件,且不超过500kb</div>
|
||||
@@ -58,62 +61,62 @@
|
||||
</el-upload>*@
|
||||
</el-form-item>
|
||||
<el-form-item label="4.楼栋数:" prop="buildcount">
|
||||
<el-input v-model="form.buildcount"></el-input>
|
||||
<el-input-number v-model="form.buildcount"></el-input-number>
|
||||
</el-form-item>
|
||||
<el-form-item label="5.住户总数:" prop="householdcount">
|
||||
<el-input v-model="form.householdcount"></el-input>
|
||||
<el-input-number v-model="form.householdcount"></el-input-number>
|
||||
</el-form-item>
|
||||
<el-form-item label="6.总建筑面积:" prop="totalfloorage">
|
||||
<el-input v-model="form.totalfloorage"></el-input>
|
||||
<el-input-number v-model="form.totalfloorage" :precision="2" :step="1"></el-input-number>
|
||||
</el-form-item>
|
||||
<el-form-item label="7.是否存在外墙问题:" prop="isExistProblem">
|
||||
<el-radio-group v-model="form.isExistProblem" size="small">
|
||||
<el-radio-button label="是" border></el-radio-button>
|
||||
<el-radio-button label="否" border></el-radio-button>
|
||||
<el-radio-button label="1" border>是</el-radio-button>
|
||||
<el-radio-button label="0" border>否</el-radio-button>
|
||||
</el-radio-group>
|
||||
<span>例如:漏水、开裂、脱落</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="8.楼栋信息:" prop="buildcount">
|
||||
<el-table :data="form.houses" style="width: 100%" ref="table" tooltip-effect="dark" @@selection-change="handleSelectionChange" row-key="id"
|
||||
<el-form-item label="8.楼栋信息:">
|
||||
<el-table :data="form.buildings" style="width: 100%" ref="table" tooltip-effect="dark" @@selection-change="handleSelectionChange" row-key="id"
|
||||
:expand-row-keys="expands" @@row-click="clickRowHandle">
|
||||
<el-table-column type="selection" width="55">
|
||||
</el-table-column>
|
||||
@* <el-table-column type="selection" width="55">
|
||||
</el-table-column>*@
|
||||
<el-table-column type="expand">
|
||||
<template slot-scope="props">
|
||||
<el-form label-position="left" class="demo-table-expand" :rules="rules" ref="childForm" :model="props.row">
|
||||
<el-form-item label="幢名称:">
|
||||
<span>{{ props.row.BuildingName }}</span>
|
||||
<span>{{ props.row.buildingName }}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="地址:">
|
||||
<span>{{ props.row.Address }}</span>
|
||||
<span>{{ props.row.address }}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="层数:">
|
||||
<span>{{ props.row.LevelCount }}</span>
|
||||
<span>{{ props.row.levelCount }}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="总户数:">
|
||||
<span>{{ props.row.Households }}</span>
|
||||
<span>{{ props.row.houseHolds }}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="建设单位:">
|
||||
<span>{{ props.row.BuildingUnit }}</span>
|
||||
<span>{{ props.row.buildingUnit }}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="设计单位:">
|
||||
<span>{{ props.row.DesingerUnit }}</span>
|
||||
<span>{{ props.row.desingerUnit }}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="施工单位:">
|
||||
<span>{{ props.row.ConstructionUnit }}</span>
|
||||
<span>{{ props.row.constructionUnit }}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="监理单位:">
|
||||
<span>{{ props.row.MonitorUnit }}</span>
|
||||
<span>{{ props.row.monitorUnit }}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="物业单位:">
|
||||
<span>{{ props.row.WuYeUnit }}</span>
|
||||
<span>{{ props.row.wuYeUnit }}</span>
|
||||
</el-form-item>
|
||||
<el-form-item prop="curwallproblems">
|
||||
8.1 墙体问题的类型是
|
||||
<el-checkbox-group v-model="props.row.curwallproblems">
|
||||
<el-checkbox v-for="w in wallproblems" :label="w" :key="w">{{w}}</el-checkbox>
|
||||
</el-checkbox-group>
|
||||
<el-input type="textarea" autosize placeholder="请输入其他问题" v-model="props.row.curwallproblems_other">
|
||||
<el-input type="textarea" autosize placeholder="请输入其他问题" v-model="props.row.curwallproblemother">
|
||||
@*<el-select v-model="curwallproblems" multiple filterable allow-create default-first-option placeholder="请选择问题类型">
|
||||
<el-option v-for="item in wallproblems" :key="item" :label="item" :value="item">
|
||||
</el-option>
|
||||
@@ -161,23 +164,23 @@
|
||||
</el-checkbox-group>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
8.7 问题照片:
|
||||
<el-upload class="upload-demo" drag action="https://jsonplaceholder.typicode.com/posts/" multiple :auto-upload="false" :on-preview="handlePreview" :on-remove="handleRemove" :file-list="childFileList1" :on-change="fileChange1">
|
||||
8.7 问题照片:@* :on-change="fileChange1"*@
|
||||
<el-upload class="upload-demo" drag action="/gb/yjb/api/outsidewall/sysFileInfo/upload" multiple :auto-upload="true" :on-preview="(file)=>{return handlePreview(file,props,1)}" :on-remove="(file, fileList)=>{return handleRemove(file, fileList,props)}" :file-list="childFileList[props.$index].filelist1" :on-success="(response, file, fileList)=>{return fileChange(response, file, fileList, props,1,'东')}">
|
||||
<i class="el-icon-upload"></i>
|
||||
<div class="el-upload__text"><em>上传东面照片</em></div>
|
||||
<div class="el-upload__tip" slot="tip">只能上传jpg/png文件,且不超过500kb</div>
|
||||
</el-upload>
|
||||
<el-upload class="upload-demo" drag action="https://jsonplaceholder.typicode.com/posts/" multiple :auto-upload="false" :on-preview="handlePreview" :on-remove="handleRemove" :file-list="childFileList2" :on-change="fileChange2">
|
||||
<el-upload class="upload-demo" drag action="/gb/yjb/api/outsidewall/sysFileInfo/upload" multiple :auto-upload="true" :on-preview="(file)=>{return handlePreview(file,props,2)}" :on-remove="(file, fileList)=>{return handleRemove(file, fileList,props)}" :file-list="childFileList[props.$index].filelist2" :on-success="(response, file, fileList)=>{return fileChange(response, file, fileList, props,2,'西')}">
|
||||
<i class="el-icon-upload"></i>
|
||||
<div class="el-upload__text"><em>上传西面照片</em></div>
|
||||
<div class="el-upload__tip" slot="tip">只能上传jpg/png文件,且不超过500kb</div>
|
||||
</el-upload>
|
||||
<el-upload class="upload-demo" drag action="https://jsonplaceholder.typicode.com/posts/" multiple :auto-upload="false" :on-preview="handlePreview" :on-remove="handleRemove" :file-list="childFileList3" :on-change="fileChange3">
|
||||
<el-upload class="upload-demo" drag action="/gb/yjb/api/outsidewall/sysFileInfo/upload" multiple :auto-upload="true" :on-preview="(file)=>{return handlePreview(file,props,3)}" :on-remove="(file, fileList)=>{return handleRemove(file, fileList,props)}" :file-list="childFileList[props.$index].filelist3" :on-success="(response, file, fileList)=>{return fileChange(response, file, fileList, props,3,'南')}">
|
||||
<i class="el-icon-upload"></i>
|
||||
<div class="el-upload__text"><em>上传南面照片</em></div>
|
||||
<div class="el-upload__tip" slot="tip">只能上传jpg/png文件,且不超过500kb</div>
|
||||
</el-upload>
|
||||
<el-upload class="upload-demo" drag action="https://jsonplaceholder.typicode.com/posts/" multiple :auto-upload="false" :on-preview="handlePreview" :on-remove="handleRemove" :file-list="childFileList4" :on-change="fileChange4">
|
||||
<el-upload class="upload-demo" drag action="/gb/yjb/api/outsidewall/sysFileInfo/upload" multiple :auto-upload="true" :on-preview="(file)=>{return handlePreview(file,props,4)}" :on-remove="(file, fileList)=>{return handleRemove(file, fileList,props)}" :file-list="childFileList[props.$index].filelist4" :on-success="(response, file, fileList)=>{return fileChange(response, file, fileList, props,4,'北')}">
|
||||
<i class="el-icon-upload"></i>
|
||||
<div class="el-upload__text"><em>上传北面照片</em></div>
|
||||
<div class="el-upload__tip" slot="tip">只能上传jpg/png文件,且不超过500kb</div>
|
||||
@@ -208,67 +211,52 @@
|
||||
<el-checkbox label="混凝土块"></el-checkbox>
|
||||
</el-checkbox-group>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="primary" plain @@click.prevent="tempSave(props.row)">暂存</el-button>
|
||||
</el-form-item>
|
||||
@*<el-form-item>
|
||||
<el-button type="primary" plain @@click.prevent="tempSave(props.row)">暂存</el-button>
|
||||
</el-form-item>*@
|
||||
</el-form>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="幢名称" prop="BuildingName">
|
||||
<el-table-column label="幢名称" prop="buildingName">
|
||||
</el-table-column>
|
||||
<el-table-column label="地址" prop="Address">
|
||||
<el-table-column label="地址" prop="address">
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-form-item>
|
||||
@*
|
||||
<el-form-item label="参加时间:" prop="date">
|
||||
<el-popover placement="top" title="" width="200" trigger="focus" :content="datePersonNumber">
|
||||
<el-radio-group v-model="form.date" @@input="getNumber()" slot="reference" size="small">
|
||||
<el-radio-button label="2023-03-18" border></el-radio-button>
|
||||
<el-radio-button label="2023-03-19" border></el-radio-button>
|
||||
<el-radio-button label="2023-03-25" border></el-radio-button>
|
||||
<el-radio-button label="2023-03-26" border></el-radio-button>
|
||||
<el-radio-button label="2023-04-08" border></el-radio-button>
|
||||
<el-radio-button label="2023-04-09" border></el-radio-button>
|
||||
<el-radio-button label="2023-04-15" border></el-radio-button>
|
||||
<el-radio-button label="2023-04-16" border></el-radio-button>
|
||||
</el-radio-group>
|
||||
</el-popover>
|
||||
</el-form-item>*@
|
||||
<el-form-item prop="problemismodify">
|
||||
<el-form-item prop="problemismodify" v-if="form.isExistProblem=='1'">
|
||||
14.问题发生后是否请人修复了?
|
||||
<el-radio-group v-model="problemismodify">
|
||||
<el-radio label="是"></el-radio>
|
||||
<el-radio label="否"></el-radio>
|
||||
<el-radio-group v-model="form.problemismodify">
|
||||
<el-radio label="1">是</el-radio>
|
||||
<el-radio label="0">否</el-radio>
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
<el-form-item v-if="problemismodify=='是'">
|
||||
<el-form-item v-if="form.problemismodify=='1'">
|
||||
15.请提供修复单位的名称:
|
||||
<el-input type="textarea" autosize placeholder="请提供修复单位的名称。" v-model="problemmodifyunitname">
|
||||
<el-input type="textarea" autosize placeholder="请提供修复单位的名称。" v-model="form.problemmodifyunitname">
|
||||
</el-form-item>
|
||||
<el-form-item v-if="problemismodify=='是'">
|
||||
<el-form-item v-if="form.problemismodify=='1'">
|
||||
16.修复后的部位是否再次发生问题?
|
||||
<el-radio-group v-model="problemmodifyisagain">
|
||||
<el-radio label="有再发生"></el-radio>
|
||||
<el-radio label="没有"></el-radio>
|
||||
<el-radio-group v-model="form.problemmodifyisagain">
|
||||
<el-radio label="1">有再发生</el-radio>
|
||||
<el-radio label="0">没有</el-radio>
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
20.若您愿意接受我们的现场调查,请惠赐您的联系方式。谢谢!
|
||||
<el-input type="textarea" autosize placeholder="" v-model="contract">
|
||||
<el-input type="textarea" autosize placeholder="" v-model="form.contract">
|
||||
</el-form-item>
|
||||
<el-form-item label="手机号码:" prop="phone">
|
||||
<el-input v-model="form.phone"></el-input>
|
||||
@*<el-form-item label="手机号码:" prop="phone">
|
||||
<el-input v-model="form.phone"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="验证码" prop="code" v-if="!isshowmyinfo">
|
||||
<el-input type="text" maxlength="4" placeholder="验证码" v-model="form.code">
|
||||
<template slot="append">
|
||||
<el-button :disabled="disabled" @@click="getCode">{{ valiBtn }}</el-button>
|
||||
</template>
|
||||
</el-input>
|
||||
</el-form-item>
|
||||
<el-input type="text" maxlength="4" placeholder="验证码" v-model="form.code">
|
||||
<template slot="append">
|
||||
<el-button :disabled="disabled" @@click="getCode">{{ valiBtn }}</el-button>
|
||||
</template>
|
||||
</el-input>
|
||||
</el-form-item>*@
|
||||
<el-form-item v-if="!isshowmyinfo">
|
||||
<el-button type="primary" @@click.prevent="onSubmit('form')">提交报名</el-button>
|
||||
<el-button type="primary" @@click.prevent="onSubmit('form','childForm')"> 提 交 </el-button>
|
||||
<el-button @@click.prevent="showinfo()">我的报名</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
@@ -316,91 +304,16 @@
|
||||
return {
|
||||
form: {
|
||||
communityName: '',
|
||||
phone: '',
|
||||
communityId: '',
|
||||
deliveryear: '',
|
||||
buildcount: '',
|
||||
totalfloorage: 0,
|
||||
address: '',
|
||||
date: '',
|
||||
line: '',
|
||||
code: '',
|
||||
token: '',
|
||||
houses: [{
|
||||
id: '12987122',
|
||||
BuildingName: '好滋好味鸡蛋仔',
|
||||
Address: '江浙小吃、小吃零食',
|
||||
LevelCount: '荷兰优质淡奶,奶香浓而不腻',
|
||||
Households: '上海市普陀区真北路',
|
||||
BuildingUnit: '王小虎夫妻店',
|
||||
DesingerUnit: '10333',
|
||||
curwallproblems: [],
|
||||
wallproblemsfirst: '',
|
||||
firstproblemdate: '',
|
||||
problemfrequency: '',
|
||||
problemseason: [],
|
||||
wallproblemtoward: [],
|
||||
curwallproblems_other: '',
|
||||
problemfanwei: '',
|
||||
problemheight: [],
|
||||
diaoluowu: [],
|
||||
}, {
|
||||
id: '12987123',
|
||||
BuildingName: '好滋好味鸡蛋仔',
|
||||
Address: '江浙小吃、小吃零食',
|
||||
LevelCount: '荷兰优质淡奶,奶香浓而不腻',
|
||||
Households: '上海市普陀区真北路',
|
||||
BuildingUnit: '王小虎夫妻店',
|
||||
DesingerUnit: '10333',
|
||||
curwallproblems: [],
|
||||
wallproblemsfirst: '',
|
||||
firstproblemdate: '',
|
||||
problemfrequency: '',
|
||||
problemseason: [],
|
||||
wallproblemtoward: [],
|
||||
curwallproblems_other: '',
|
||||
problemfanwei: '',
|
||||
problemheight: [],
|
||||
diaoluowu: [],
|
||||
}, {
|
||||
id: '12987124',
|
||||
BuildingName: '好滋好味鸡蛋仔',
|
||||
Address: '江浙小吃、小吃零食',
|
||||
LevelCount: '荷兰优质淡奶,奶香浓而不腻',
|
||||
Households: '上海市普陀区真北路',
|
||||
BuildingUnit: '王小虎夫妻店',
|
||||
DesingerUnit: '10333',
|
||||
curwallproblems: [],
|
||||
wallproblemsfirst: '',
|
||||
firstproblemdate: '',
|
||||
problemfrequency: '',
|
||||
problemseason: [],
|
||||
wallproblemtoward: [],
|
||||
curwallproblems_other: '',
|
||||
problemfanwei: '',
|
||||
problemheight: [],
|
||||
diaoluowu: [],
|
||||
}, {
|
||||
id: '12987125',
|
||||
BuildingName: '好滋好味鸡蛋仔',
|
||||
Address: '江浙小吃、小吃零食',
|
||||
LevelCount: '荷兰优质淡奶,奶香浓而不腻',
|
||||
Households: '上海市普陀区真北路',
|
||||
BuildingUnit: '王小虎夫妻店',
|
||||
DesingerUnit: '10333',
|
||||
curwallproblems: [],
|
||||
wallproblemsfirst: '',
|
||||
firstproblemdate: '',
|
||||
problemfrequency: '',
|
||||
problemseason: [],
|
||||
wallproblemtoward: [],
|
||||
curwallproblems_other: '',
|
||||
problemfanwei: '',
|
||||
problemheight: [],
|
||||
diaoluowu: [],
|
||||
}]
|
||||
//,remark: ''
|
||||
fileList: [],
|
||||
}, rules: {
|
||||
communityName: [{ required: true, trigger: 'blur', message: '请选择社区/小区' }],
|
||||
communityId: [{ required: true, trigger: 'blur', message: '请选择社区/小区' }],
|
||||
phone: [{ validator: checkPhone, required: true, trigger: 'blur' }],
|
||||
code: [{ validator: checkCode, required: true, trigger: 'blur' }],
|
||||
deliveryear: [{ required: false, trigger: 'blur', message: '请输入交付年份' }],
|
||||
@@ -408,7 +321,7 @@
|
||||
householdcount: [{ required: false, trigger: 'blur', message: '请输入住户总数' }],
|
||||
date: [{ required: true, trigger: 'blur', message: '请选择参加时间' }],
|
||||
line: [{ required: true, trigger: 'blur', message: '请选择线路' }],
|
||||
totalfloorage: [{ required: true, trigger: 'blur', message: '请输入总建筑面积' }, { validator: checkNumber, message: '总建筑面积必须为数字值' }],
|
||||
totalfloorage: [{ required: true, trigger: 'blur', message: '请输入总建筑面积' }],//, { validator: checkNumber, message: '总建筑面积必须为数字值' }
|
||||
isExistProblem: [{ required: true, trigger: 'blur', message: '请选择是否' }],
|
||||
curwallproblems: [{ required: true, trigger: ['change', 'blur'], message: '请选择墙体问题' }],
|
||||
firstproblemdate: [{ required: true, trigger: ['change', 'blur'], message: '请选择第一次出现墙体问题时间' }],
|
||||
@@ -424,15 +337,10 @@
|
||||
disabled: false,
|
||||
datePersonNumber: '',
|
||||
go_disabled: false,
|
||||
dates: [],
|
||||
pageline: '',
|
||||
lineTxt: '',
|
||||
isshowmyinfo: false,
|
||||
fileList: [{ name: 'food.jpeg', url: 'https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100' }, { name: 'food2.jpeg', url: 'https://img-blog.csdnimg.cn/20190918140012416.png?x-oss-process=image/resize,m_fixed,h_224,w_224' }],
|
||||
childFileList1: [{ name: 'food.jpeg', url: 'https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100' }, { name: 'food2.jpeg', url: 'https://img-blog.csdnimg.cn/20190918140012416.png?x-oss-process=image/resize,m_fixed,h_224,w_224' }],
|
||||
childFileList2: [{ name: 'food.jpeg', url: 'https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100' }, { name: 'food2.jpeg', url: 'https://img-blog.csdnimg.cn/20190918140012416.png?x-oss-process=image/resize,m_fixed,h_224,w_224' }],
|
||||
childFileList3: [{ name: 'food.jpeg', url: 'https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100' }, { name: 'food2.jpeg', url: 'https://img-blog.csdnimg.cn/20190918140012416.png?x-oss-process=image/resize,m_fixed,h_224,w_224' }],
|
||||
childFileList4: [{ name: 'food.jpeg', url: 'https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100' }, { name: 'food2.jpeg', url: 'https://img-blog.csdnimg.cn/20190918140012416.png?x-oss-process=image/resize,m_fixed,h_224,w_224' }],
|
||||
fileList: [],
|
||||
dialogImageUrl: '',
|
||||
dialogImageUrls: [],
|
||||
dialogVisible: false,
|
||||
@@ -449,6 +357,8 @@
|
||||
},
|
||||
// 要展开的行,数值的元素是row的key值
|
||||
expands: [],
|
||||
communitys: [],
|
||||
childFileList: []
|
||||
}
|
||||
},
|
||||
created: function () {
|
||||
@@ -457,12 +367,66 @@
|
||||
this.form.token = localStorage.getItem("_token");
|
||||
if (this.getQueryString("valid") == "1" || this.form.token)
|
||||
this.showinfo();
|
||||
|
||||
//this.get_go_date();
|
||||
//this.getdates();
|
||||
this.get_line();
|
||||
this.GetCommunitys('');
|
||||
},
|
||||
methods: {
|
||||
GetCommunitys(queryString) {
|
||||
let _this = this;
|
||||
axios({
|
||||
headers: { 'Content-Type': 'application/json;charset=UTF-8' },
|
||||
method: 'get',
|
||||
url: '/gb/yjb/api/outsidewall/Communitys?searchkey=' + queryString,
|
||||
responseType: "json",
|
||||
}).then(async response => {
|
||||
_this.communitys = response.data.data
|
||||
_this.loading = false;
|
||||
}).catch(async error => {
|
||||
console.log(error)
|
||||
_this.$message({
|
||||
type: 'error',
|
||||
message: error.message
|
||||
})
|
||||
_this.loading = false;
|
||||
})
|
||||
},
|
||||
getLabel(arrays, id) {
|
||||
let opt = {};
|
||||
opt = arrays.find((item) => {
|
||||
return item.id === id;
|
||||
});
|
||||
console.log(opt.name);
|
||||
return opt.name;
|
||||
},
|
||||
selectCommunity(v) {
|
||||
this.form.communityName = this.getLabel(this.communitys, v);
|
||||
|
||||
this.loading = true;
|
||||
let _this = this;
|
||||
axios({
|
||||
headers: { 'Content-Type': 'application/json;charset=UTF-8' },
|
||||
method: 'get',
|
||||
url: '/gb/yjb/api/outsidewall/Community/' + v,
|
||||
responseType: "json",
|
||||
}).then(async response => {
|
||||
_this.form.buildings = response.data.data
|
||||
_this.form.buildcount = _this.form.buildings.length
|
||||
_this.form.householdcount = _this.form.buildings.reduce((a, key) => { return a + key.houseHolds }, 0)
|
||||
_this.form.totalfloorage = _this.form.buildings.reduce((a, key) => { return a + key.areaCount }, 0)
|
||||
_this.childFileList = [];
|
||||
//_this.form.buildings.forEach((a) => { _this.childFileList.push({ towards: [{ toward: '东', filelist: [] }, { toward: '西', filelist: [] }, { toward: '南', filelist: [] }, { toward: '北', filelist: [] }] }) })
|
||||
_this.form.buildings.forEach((a) => {
|
||||
_this.childFileList.push({ filelist1: [], filelist2: [], filelist3: [], filelist4: [] })
|
||||
});
|
||||
_this.loading = false;
|
||||
}).catch(async error => {
|
||||
console.log(error)
|
||||
_this.$message({
|
||||
type: 'error',
|
||||
message: error.message
|
||||
})
|
||||
_this.loading = false;
|
||||
})
|
||||
},
|
||||
handleValidates(formName) {
|
||||
const list = []
|
||||
const validas = []
|
||||
@@ -498,82 +462,177 @@
|
||||
if (this.handleValidate('childForm')) {
|
||||
|
||||
}
|
||||
//this.curwallproblems.push(this.curwallproblems_other);
|
||||
//if(this.curwallproblems_other.length>0)
|
||||
//this.houses.find(a => a.id == row.id).curwallproblems = this.curwallproblems;
|
||||
},
|
||||
clickRowHandle(row, column, event) {
|
||||
debugger
|
||||
if (this.expands.includes(row.id)) {
|
||||
return;
|
||||
//return;
|
||||
this.expands = this.expands.filter(val => val !== row.id);
|
||||
} else {
|
||||
this.expands = [];
|
||||
this.expands.push(row.id);
|
||||
}
|
||||
},
|
||||
handleSelectionChange(val) {
|
||||
debugger;
|
||||
this.multipleSelection = val;
|
||||
},
|
||||
fileChange(a, b) {
|
||||
debugger
|
||||
this.fileList = b;
|
||||
fileChange(response, file, fileList, scope, flistidx, toward) {
|
||||
debugger;
|
||||
if (response.success == false) {
|
||||
this.$message.error('上传失败,请稍候重试');
|
||||
return;
|
||||
}
|
||||
this.loading = true;
|
||||
if (scope) {
|
||||
eval("this.childFileList[scope.$index].filelist" + flistidx + "=fileList")
|
||||
//if (this.childFileList[scope.$index].towards.filter(a => a.toward == toward).length == 0)
|
||||
// this.childFileList[scope.$index].towards.push({ toward: toward, filelist: [] });
|
||||
//this.childFileList[scope.$index].towards.filter(a => a.toward == toward)[0].filelist.push(file)
|
||||
if (file.response)
|
||||
this.form.buildings.forEach(a => {
|
||||
if (a.id == this.expands[0]) {
|
||||
var _pf = {
|
||||
file: file.response.data,
|
||||
toward: toward
|
||||
}
|
||||
a.problemfiles.push(_pf)
|
||||
}
|
||||
})
|
||||
} else {
|
||||
this.fileList = fileList;
|
||||
if (file.response)
|
||||
this.form.fileList.push(file.response.data);
|
||||
}
|
||||
this.loading = false;
|
||||
},
|
||||
fileChange1(a, b) {
|
||||
debugger
|
||||
this.childFileList1 = b;
|
||||
},
|
||||
fileChange2(a, b) {
|
||||
debugger
|
||||
this.childFileList2 = b;
|
||||
},
|
||||
fileChange3(a, b) {
|
||||
debugger
|
||||
this.childFileList3 = b;
|
||||
},
|
||||
fileChange4(a, b) {
|
||||
debugger
|
||||
this.childFileList4 = b;
|
||||
},
|
||||
handleRemove(file, fileList) {
|
||||
//handleRemove1(file, fileList) {
|
||||
// let _this = this;
|
||||
// this.removeFile(file, fileList, function () {
|
||||
// _this.childFileList1 = _this.childFileList1.filter((a) => { return a.uid != file.uid })
|
||||
// if (file.response)
|
||||
// _this.form.buildings.forEach(a => {
|
||||
// if (a.id == _this.expands[0]) {
|
||||
// a.problemfiles = a.problemfiles.filter((x) => { return x.file != file.response.data })
|
||||
// }
|
||||
// })
|
||||
// _this.loading = false;
|
||||
// }, function () { });
|
||||
//},
|
||||
//handleRemove2(file, fileList) {
|
||||
// let _this = this;
|
||||
// this.removeFile(file, fileList, function () {
|
||||
// _this.childFileList2 = _this.childFileList2.filter((a) => { return a.uid != file.uid })
|
||||
// if (file.response)
|
||||
// _this.form.buildings.forEach(a => {
|
||||
// if (a.id == _this.expands[0]) {
|
||||
// a.problemfiles = a.problemfiles.filter((x) => { return x.file != file.response.data })
|
||||
// }
|
||||
// })
|
||||
// _this.loading = false;
|
||||
// }, function () { });
|
||||
//},
|
||||
//handleRemove3(file, fileList) {
|
||||
// let _this = this;
|
||||
// this.removeFile(file, fileList, function () {
|
||||
// _this.childFileList3 = _this.childFileList3.filter((a) => { return a.uid != file.uid })
|
||||
// if (file.response)
|
||||
// _this.form.buildings.forEach(a => {
|
||||
// if (a.id == _this.expands[0]) {
|
||||
// a.problemfiles = a.problemfiles.filter((x) => { return x.file != file.response.data })
|
||||
// }
|
||||
// })
|
||||
// _this.loading = false;
|
||||
// }, function () { });
|
||||
//},
|
||||
//handleRemove4(file, fileList) {
|
||||
// let _this = this;
|
||||
// this.removeFile(file, fileList, function () {
|
||||
// _this.childFileList4 = _this.childFileList4.filter((a) => { return a.uid != file.uid })
|
||||
// if (file.response)
|
||||
// _this.form.buildings.forEach(a => {
|
||||
// if (a.id == _this.expands[0]) {
|
||||
// a.problemfiles = a.problemfiles.filter((x) => { return x.file != file.response.data })
|
||||
// }
|
||||
// })
|
||||
// _this.loading = false;
|
||||
// }, function () { });
|
||||
//},
|
||||
//handleRemove(file, fileList, scope) {
|
||||
// let _this = this;
|
||||
// this.removeFile(file, fileList, function () {
|
||||
// _this.fileList = _this.fileList.filter((a) => { return a.uid != file.uid })
|
||||
// if (file.response)
|
||||
// _this.form.fileList = _this.form.fileList.filter((a) => { return a != file.response.data })
|
||||
// _this.loading = false;
|
||||
// }, function () { });
|
||||
//},
|
||||
handleRemove(file, fileList, scope) {
|
||||
let _this = this;
|
||||
_this.loading = true;
|
||||
console.log(file, fileList);
|
||||
axios({
|
||||
headers: { 'Content-Type': 'application/json;charset=UTF-8' },
|
||||
method: 'get',
|
||||
url: '/gb/yjb/api/outsidewall/sysFileInfo/delete/' + file.response.data,
|
||||
responseType: "json",
|
||||
}).then(async response => {
|
||||
if (scope) {
|
||||
this.childFileList[scope.$index].towards = this.childFileList[scope.$index].towards.filter((a) => { return a.uid != file.uid })
|
||||
|
||||
if (file.response)
|
||||
_this.form.buildings.forEach(a => {
|
||||
if (a.id == _this.expands[0]) {
|
||||
a.problemfiles = a.problemfiles.filter((x) => { return x.file != file.response.data })
|
||||
}
|
||||
})
|
||||
} else {
|
||||
_this.fileList = _this.fileList.filter((a) => { return a.uid != file.uid })
|
||||
if (file.response)
|
||||
_this.form.fileList = _this.form.fileList.filter((a) => { return a != file.response.data });
|
||||
}
|
||||
_this.loading = false;
|
||||
}).catch(async error => {
|
||||
console.log(error)
|
||||
})
|
||||
},
|
||||
handlePreview(file) {
|
||||
filePreview(file, fileList) {
|
||||
debugger
|
||||
this.loading = true;
|
||||
console.log(file);
|
||||
this.dialogImageUrl = file.url;
|
||||
this.dialogImageUrls = this.fileList.map(a => a.url);
|
||||
this.dialogImageUrl = window.location.protocol + "//" + window.location.host + "/gb/yjb/api/outsidewall/sysFileInfo/preview/" + file.response.data;
|
||||
this.dialogImageUrls = fileList.map(a => window.location.protocol + "//" + window.location.host + "/gb/yjb/api/outsidewall/sysFileInfo/preview/" + a.response.data);
|
||||
this.$refs.myImg.showViewer = true
|
||||
const m = (e) => { e.preventDefault() };
|
||||
document.body.style.overflow = 'hidden';
|
||||
document.addEventListener("touchmove", m, false); // 禁止页面滑动
|
||||
this.loading = false;
|
||||
},
|
||||
getQueryString(communityName) {
|
||||
var reg = new RegExp("(^|&)" + communityName + "=([^&]*)(&|$)", "i");
|
||||
handlePreview(file, scope, toward) {
|
||||
debugger
|
||||
if (scope) {
|
||||
eval("this.filePreview(file, this.childFileList[scope.$index].filelist" + toward + ")")
|
||||
//this.filePreview(file, this.childFileList[scope.$index].towards.filter(a => a.toward == toward).filelist)
|
||||
}
|
||||
else
|
||||
this.filePreview(file, this.fileList)
|
||||
},
|
||||
handlePreview1(file, scope) {
|
||||
this.filePreview(file, this.childFileList1)
|
||||
},
|
||||
handlePreview2(file, scope) {
|
||||
this.filePreview(file, this.childFileList2)
|
||||
},
|
||||
handlePreview3(file, scope) {
|
||||
this.filePreview(file, this.childFileList3)
|
||||
},
|
||||
handlePreview4(file, scope) {
|
||||
this.filePreview(file, this.childFileList4)
|
||||
},
|
||||
getQueryString(communityId) {
|
||||
var reg = new RegExp("(^|&)" + communityId + "=([^&]*)(&|$)", "i");
|
||||
var r = window.location.search.substr(1).match(reg);
|
||||
if (r != null) return unescape(r[2]); return null;
|
||||
},
|
||||
get_line() {
|
||||
let _this = this;
|
||||
var line = this.getQueryString("line") ?? "A"
|
||||
if (line == "A" || line == "a") {
|
||||
_this.lineTxt = '慈溪:“历史之路 文化之路 创新之路 共富之路”的慈溪南部沿山风情共富线。';
|
||||
_this.pageline = _this.form.line = '慈溪';
|
||||
}
|
||||
else if (line == "B" || line == "b") {
|
||||
_this.lineTxt = '奉化:“应梦明山入城,剡水桃源归野”的奉化明山剡水共富线。';
|
||||
_this.pageline = _this.form.line = '奉化';
|
||||
}
|
||||
else if (line == "C" || line == "c") {
|
||||
_this.lineTxt = '象山:“万象山海,逐梦亚运”象山扬帆亚运风情共富线三条体验游览线。';
|
||||
_this.pageline = _this.form.line = '象山';
|
||||
}
|
||||
},
|
||||
get_go_date() {
|
||||
//判断上车日期
|
||||
let _this = this;
|
||||
_this.form.token = localStorage.getItem("_token");
|
||||
|
||||
},
|
||||
getCode() {
|
||||
this.$refs['form'].validateField('phone', (err) => {
|
||||
if (err) {
|
||||
@@ -624,78 +683,89 @@
|
||||
}
|
||||
}, 1000);
|
||||
},
|
||||
onSubmit(formName) {
|
||||
onSubmit(formName, formNameChild) {
|
||||
console.log('submit!');
|
||||
let _this = this;
|
||||
this.$refs[formName].validate((valid) => { // 为表单绑定验证功能
|
||||
this.$refs[formName].validate((valid) => {
|
||||
if (valid) {
|
||||
//this.$alert("成功", "提示")
|
||||
axios({
|
||||
headers: { 'Content-Type': 'application/json;charset=UTF-8' },
|
||||
method: 'post',
|
||||
url: '/gb/yjb/api/ningbozhichun/submit',
|
||||
data: _this.form,
|
||||
responseType: "json",
|
||||
}).then(async response => {
|
||||
if (response.data?.data?.success == true) {
|
||||
let token = response.data.data.token;
|
||||
localStorage.setItem("_token", token)
|
||||
_this.$alert(`<div>提交成功</div>`, '成功', {
|
||||
confirmButtonText: '确定', dangerouslyUseHTMLString: true, center: true, closeOnClickModal: true
|
||||
}).then(a => { }).catch(err => { console.log(err) });
|
||||
} else {
|
||||
_this.$alert(`<div>` + response.data.message + `</div>`, '错误', {
|
||||
confirmButtonText: '确定', dangerouslyUseHTMLString: true, center: true, closeOnClickModal: true
|
||||
}).then(a => { }).catch(err => { console.log(err) });
|
||||
}
|
||||
_this.loading = false;
|
||||
}).catch(async error => {
|
||||
console.log(error)
|
||||
_this.$message({
|
||||
type: 'error',
|
||||
message: error.message
|
||||
})
|
||||
_this.loading = false;
|
||||
})
|
||||
|
||||
if (_this.form.isExistProblem == '0') {
|
||||
_this.submit2();
|
||||
} else {
|
||||
if (this.$refs[formNameChild])
|
||||
this.$refs[formNameChild].validate((valid) => {
|
||||
if (valid) {
|
||||
debugger
|
||||
_this.submit2();
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
},
|
||||
go(formName) {
|
||||
console.log('上车!');
|
||||
submit2() {
|
||||
debugger;
|
||||
let _this = this;
|
||||
this.$refs[formName].validate((valid) => { // 为表单绑定验证功能
|
||||
if (valid) {
|
||||
axios({
|
||||
headers: { 'Content-Type': 'application/json;charset=UTF-8' },
|
||||
method: 'post',
|
||||
url: '/gb/yjb/api/ningbozhichun/submit',
|
||||
data: _this.form,
|
||||
responseType: "json",
|
||||
}).then(async response => {
|
||||
if (response.data?.data?.success == true) {
|
||||
let token = response.data.data.token;
|
||||
localStorage.setItem("_token", token)
|
||||
_this.$alert(`<div>提交成功</div>`, '成功', {
|
||||
confirmButtonText: '确定', dangerouslyUseHTMLString: true, center: true, closeOnClickModal: true
|
||||
}).then(a => { }).catch(err => { console.log(err) });
|
||||
} else {
|
||||
_this.$alert(`<div>` + response.data.message + `</div>`, '错误', {
|
||||
confirmButtonText: '确定', dangerouslyUseHTMLString: true, center: true, closeOnClickModal: true
|
||||
}).then(a => { }).catch(err => { console.log(err) });
|
||||
}
|
||||
_this.loading = false;
|
||||
}).catch(async error => {
|
||||
console.log(error)
|
||||
_this.$message({
|
||||
type: 'error',
|
||||
message: error.message
|
||||
})
|
||||
_this.loading = false;
|
||||
})
|
||||
//let config = {
|
||||
// //formData 提交请求头有两种 multipart/form-data 和 application/x-www-form-urlencoded
|
||||
// // multipart/form-data 用于type=file 的input提交
|
||||
// headers: {
|
||||
// "Content-Type": "multipart/form-data"
|
||||
// }
|
||||
//};
|
||||
//const fd = new FormData()
|
||||
//fd.append('appid', "123")
|
||||
//fd.append('wall', _this.form)
|
||||
//for (let _i in _this.fileList) {
|
||||
// fd.append('file', _i)
|
||||
//}
|
||||
//axios.post('/gb/yjb/api/outsidewall/submit', fd, config).then(res => {
|
||||
// debugger
|
||||
//}).catch(error => {
|
||||
// console.log(error);
|
||||
//});
|
||||
|
||||
|
||||
axios({
|
||||
headers: { 'Content-Type': 'multipart/form-data' },
|
||||
method: 'post',
|
||||
url: '/gb/yjb/api/outsidewall/submit',
|
||||
data: _this.form,
|
||||
responseType: "json",
|
||||
}).then(async response => {
|
||||
if (response.data?.data?.success == true) {
|
||||
let token = response.data.data.token;
|
||||
localStorage.setItem("_token", token)
|
||||
_this.$alert(`<div>提交成功</div>`, '成功', {
|
||||
confirmButtonText: '确定', dangerouslyUseHTMLString: true, center: true, closeOnClickModal: true
|
||||
}).then(a => { }).catch(err => { console.log(err) });
|
||||
} else {
|
||||
_this.$alert(`<div>` + response.data.message + `</div>`, '错误', {
|
||||
confirmButtonText: '确定', dangerouslyUseHTMLString: true, center: true, closeOnClickModal: true
|
||||
}).then(a => { }).catch(err => { console.log(err) });
|
||||
}
|
||||
});
|
||||
_this.loading = false;
|
||||
}).catch(async error => {
|
||||
console.log(error)
|
||||
_this.$message({
|
||||
type: 'error',
|
||||
message: error.message
|
||||
})
|
||||
_this.loading = false;
|
||||
})
|
||||
},
|
||||
getFormData(object) {
|
||||
const formData = new FormData()
|
||||
Object.keys(object).forEach(key => {
|
||||
const value = object[key]
|
||||
if (Array.isArray(value)) {
|
||||
value.forEach((subValue, i) =>
|
||||
formData.append(key + `[${i}]`, subValue)
|
||||
)
|
||||
} else {
|
||||
formData.append(key, object[key])
|
||||
}
|
||||
})
|
||||
return formData
|
||||
},
|
||||
loading_false() { this.loading = false },
|
||||
showinfo() {
|
||||
@@ -782,11 +852,6 @@
|
||||
display: none;
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
/*.el-image__inner
|
||||
{
|
||||
visibility: hidden;
|
||||
display:none;
|
||||
} */
|
||||
}
|
||||
</style>
|
||||
<style scoped>
|
||||
|
||||
344
20220330_Vote/Ewide.Web.Entry/Views/OutsideWall/Result.cshtml
Normal file
@@ -0,0 +1,344 @@
|
||||
@*
|
||||
For more information on enabling MVC for empty projects, visit https://go.microsoft.com/fwlink/?LinkID=397860
|
||||
*@
|
||||
@{
|
||||
}
|
||||
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<link rel="stylesheet" href="https://unpkg.com/element-ui/lib/theme-chalk/index.css">
|
||||
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.min.js"></script>
|
||||
<script src="https://unpkg.com/element-ui/lib/index.js"></script>
|
||||
<script src="https://unpkg.com/axios/dist/axios.min.js"></script>
|
||||
<script src="http://lib.baomitu.com/qs/6.10.3/qs.min.js"></script>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="app" v-loading="loading">
|
||||
<h3 style="text-align:center;">宁波既有建筑外墙脱落问卷调查 报名结果</h3>
|
||||
<el-form label-position="left" ref="form" :model="form" label-width="120px" style="margin-top:15px;">
|
||||
<el-form-item label="社区/小区:" prop="name">
|
||||
<el-select v-model="form.communityId" filterable placeholder="请选择" @@change="selectCommunity">
|
||||
<el-option v-for="item in communitys" :key="item.id" :label="item.name" :value="item.id">
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item>
|
||||
<el-button type="primary" @@click.prevent="onSubmit('form')">查询</el-button>
|
||||
<el-button @@click.prevent="reset('form')">重置</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<el-table :data="tableData" style="width: 100%">
|
||||
<el-table-column type="expand">
|
||||
<template slot-scope="props">
|
||||
<el-descriptions class="margin-top" title="" :column="2" border>
|
||||
<el-descriptions-item :span="2">
|
||||
<template slot="label">
|
||||
@* <i class="el-icon-user"></i>*@
|
||||
报名日期
|
||||
</template>
|
||||
{{ props.row.createdTime }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item>
|
||||
<template slot="label">
|
||||
@* <i class="el-icon-user"></i>*@
|
||||
姓名
|
||||
</template>
|
||||
{{ props.row.name }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item labelStyle="width:90px;">
|
||||
<template slot="label">
|
||||
@* <i class="el-icon-user"></i>*@
|
||||
手机号码
|
||||
</template>
|
||||
{{ props.row.phone }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item>
|
||||
<template slot="label">
|
||||
@* <i class="el-icon-mobile-phone"></i>*@
|
||||
微信号码
|
||||
</template>
|
||||
{{ props.row.weixin_number }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item>
|
||||
<template slot="label">
|
||||
@* <i class="el-icon-location-outline"></i>*@
|
||||
身份证号码
|
||||
</template>
|
||||
{{ props.row.cardno }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item>
|
||||
<template slot="label">
|
||||
@* <i class="el-icon-tickets"></i>*@
|
||||
行业
|
||||
</template>
|
||||
@* <el-tag size="small">学校</el-tag>*@
|
||||
{{ props.row.hangye }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item>
|
||||
<template slot="label">
|
||||
@*<i class="el-icon-office-building"></i>*@
|
||||
所在地
|
||||
</template>
|
||||
{{ props.row.address }}
|
||||
</el-descriptions-item>
|
||||
</el-descriptions>
|
||||
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="报名日期"><template slot-scope="props">{{ dateFormat("mm-dd", props.row.createdTime )}}</template></el-table-column>
|
||||
<el-table-column label="姓名/手机号码"><template slot-scope="props">{{ props.row.name}}<br />{{ props.row.phone}}</template></el-table-column>
|
||||
<el-table-column label="日期/线路"><template slot-scope="props">{{ props.row.date}} {{ props.row.line}}</template></el-table-column>
|
||||
</el-table>
|
||||
|
||||
|
||||
<h3 style="text-align:center;">
|
||||
<el-button @@click="load_projects">刷新数据</el-button>
|
||||
<el-button type="primary" @@click="export_excel" :loading="loading">导出Excel</el-button>
|
||||
</h3>
|
||||
</div>
|
||||
</body>
|
||||
<script>
|
||||
new Vue({
|
||||
el: '#app',
|
||||
data: function () {
|
||||
return {
|
||||
form: {
|
||||
name: '',
|
||||
phone: '',
|
||||
weixin_number: '',
|
||||
cardno: '',
|
||||
hangye: '',
|
||||
address: '',
|
||||
date: '',
|
||||
line: '',
|
||||
code: '',
|
||||
token: ''
|
||||
//,remark: ''
|
||||
},
|
||||
tableData: [],
|
||||
loading: false,
|
||||
token: '',
|
||||
communitys: [], communityId: ''
|
||||
}
|
||||
},
|
||||
created: function () {
|
||||
this.check_login()
|
||||
this.loading = true;
|
||||
this.GetCommunitys('');
|
||||
|
||||
},
|
||||
methods: {
|
||||
GetCommunitys(queryString) {
|
||||
let _this = this;
|
||||
axios({
|
||||
headers: { 'Content-Type': 'application/json;charset=UTF-8' },
|
||||
method: 'get',
|
||||
url: '/gb/yjb/api/outsidewall/Communitys?searchkey=' + queryString,
|
||||
responseType: "json",
|
||||
}).then(async response => {
|
||||
_this.communitys = response.data.data
|
||||
_this.loading = false;
|
||||
}).catch(async error => {
|
||||
console.log(error)
|
||||
_this.$message({
|
||||
type: 'error',
|
||||
message: error.message
|
||||
})
|
||||
_this.loading = false;
|
||||
})
|
||||
},
|
||||
selectCommunity(v) {
|
||||
//this.form.communityName = this.getLabel(this.communitys, v);
|
||||
this.communityId = v
|
||||
},
|
||||
onSubmit(formName) {
|
||||
console.log('submit!');
|
||||
let _this = this;
|
||||
this.$refs[formName].validate((valid) => { // 为表单绑定验证功能
|
||||
if (valid) {
|
||||
//this.$alert("成功", "提示")
|
||||
axios({
|
||||
headers: { 'Content-Type': 'application/json;charset=UTF-8' },
|
||||
method: 'get',
|
||||
url: '/gb/yjb/api/outsidewall/query/' + this.communityId,
|
||||
data: _this.form,
|
||||
responseType: "json",
|
||||
headers: {
|
||||
Authorization: 'Bearer ' + _this.token
|
||||
}
|
||||
}).then(async response => {
|
||||
debugger
|
||||
if (response.data.success == true) {
|
||||
_this.tableData = response.data;
|
||||
} else {
|
||||
_this.$alert(`<div>` + response.data.message + `</div>`, '错误', {
|
||||
confirmButtonText: '确定', dangerouslyUseHTMLString: true, center: true, closeOnClickModal: true
|
||||
}).then(a => { }).catch(err => { console.log(err) });
|
||||
}
|
||||
_this.loading = false;
|
||||
}).catch(async error => {
|
||||
console.log(error)
|
||||
_this.$message({
|
||||
type: 'error',
|
||||
message: error.message
|
||||
})
|
||||
_this.loading = false;
|
||||
})
|
||||
|
||||
}
|
||||
});
|
||||
}, reset(formName) {
|
||||
this.form = {}
|
||||
},
|
||||
export_excel() {
|
||||
this.loading = true;
|
||||
this.download('/gb/yjb/api/ningbozhichun/export_excel', this.dateFormat("YYYYmmddHHMMSS", new Date()) + "-共赴宁波之春.xlsx", this.loading_false);
|
||||
},
|
||||
check_login() {
|
||||
this.token = window.sessionStorage.getItem('__TOKEN');
|
||||
if (!this.token)
|
||||
location = '/gb/yjb/manage/login'
|
||||
},
|
||||
|
||||
load_projects() {
|
||||
this.loading = true;
|
||||
let _this = this;
|
||||
axios({
|
||||
headers: { 'Content-Type': 'application/json;charset=UTF-8' },
|
||||
method: 'post',
|
||||
url: '/gb/yjb/api/ningbozhichun/GetPersonList',
|
||||
data: {},
|
||||
responseType: "json",
|
||||
headers: {
|
||||
Authorization: 'Bearer ' + _this.token
|
||||
}
|
||||
}).then(function (response) {
|
||||
console.log(response)
|
||||
_this.tableData = response.data.data
|
||||
_this.loading = false;
|
||||
}).catch(function (error) {
|
||||
console.log(error)
|
||||
_this.$message({
|
||||
type: 'error',
|
||||
message: error.message
|
||||
})
|
||||
_this.loading = false;
|
||||
})
|
||||
},
|
||||
loading_false() { this.loading = false },
|
||||
|
||||
download(url, filename, callback) {
|
||||
let _this = this;
|
||||
axios({
|
||||
headers: { 'Content-Type': 'application/json;charset=UTF-8' },
|
||||
method: 'post',
|
||||
url: url,
|
||||
data: {},
|
||||
responseType: "blob",
|
||||
headers: {
|
||||
Authorization: 'Bearer ' + _this.token
|
||||
}
|
||||
}).then(function (response) {
|
||||
console.log(response);
|
||||
//解析文件充blod中解析
|
||||
const url = window.URL.createObjectURL(
|
||||
new Blob([response.data], { type: "application/vnd.ms-excel" })
|
||||
);
|
||||
const link = document.createElement("a");
|
||||
link.style.display = "none";
|
||||
link.href = url;
|
||||
link.setAttribute("download", filename);
|
||||
document.body.appendChild(link);
|
||||
link.click();
|
||||
document.body.removeChild(link);
|
||||
callback();
|
||||
}).catch(function (error) {
|
||||
callback();
|
||||
console.log(error)
|
||||
_this.$message({
|
||||
type: 'error',
|
||||
message: error.message
|
||||
})
|
||||
})
|
||||
},
|
||||
getMonthWeek(now) {
|
||||
var a = now.getYear();
|
||||
var b = now.getMonth() + 1;
|
||||
var c = now.getDate();
|
||||
/*
|
||||
a = d = 当前日期
|
||||
b = 6 - w = 当前周的还有几天过完(不算今天)
|
||||
a + b 的和在除以7 就是当天是当前月份的第几周
|
||||
*/
|
||||
var date = new Date(a, parseInt(b) - 1, c), w = date.getDay(), d = date.getDate();
|
||||
return Math.ceil(
|
||||
(d + 6 - w) / 7
|
||||
);
|
||||
},
|
||||
dateFormat(fmt, d) {
|
||||
const date = new Date(d);
|
||||
let ret;
|
||||
const opt = {
|
||||
"Y+": date.getFullYear().toString(), // 年
|
||||
"m+": (date.getMonth() + 1).toString(), // 月
|
||||
"d+": date.getDate().toString(), // 日
|
||||
"H+": date.getHours().toString(), // 时
|
||||
"M+": date.getMinutes().toString(), // 分
|
||||
"S+": date.getSeconds().toString() // 秒
|
||||
// 有其他格式化字符需求可以继续添加,必须转化成字符串
|
||||
};
|
||||
for (let k in opt) {
|
||||
ret = new RegExp("(" + k + ")").exec(fmt);
|
||||
if (ret) {
|
||||
fmt = fmt.replace(ret[1], (ret[1].length == 1) ? (opt[k]) : (opt[k].padStart(ret[1].length, "0")))
|
||||
};
|
||||
};
|
||||
return fmt;
|
||||
}
|
||||
}
|
||||
})
|
||||
</script>
|
||||
<style scoped>
|
||||
.buhuanhang {
|
||||
white-space: nowrap;
|
||||
width: 21%;
|
||||
}
|
||||
|
||||
.text {
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.item {
|
||||
padding: 18px 0;
|
||||
}
|
||||
|
||||
.box-card {
|
||||
width: 98%;
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
.el-card__body {
|
||||
padding: 12px;
|
||||
}
|
||||
|
||||
.el-card__body p {
|
||||
margin: 0px;
|
||||
margin-bottom: 5px;
|
||||
line-height: 1.2;
|
||||
}
|
||||
|
||||
.el-radio.is-bordered {
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
.el-radio-button--small .el-radio-button__inner {
|
||||
border-left: 1px solid #DCDFE6;
|
||||
}
|
||||
</style>
|
||||
|
||||
</html>
|
||||
@@ -50,6 +50,11 @@
|
||||
"SmsAccount": "tempaccount0309",
|
||||
"SmsPwd": "Aabc!@#20KHL+@+124bjaT(6q",
|
||||
"TotalCount": 40
|
||||
},
|
||||
"OutsideWallSetting": {
|
||||
"SanjuKey": "vPFu7zKB08Uaxuzsc5zozAAT6W0zr3qw",
|
||||
"GetCommunitys": "http://sjk.test.ky.com/housesafety/statistics/GetCommunitys?searchName={0}",
|
||||
"GetHouseInfoCitysByCommunity": "http://sjk.test.ky.com/housesafety/statistics/GetHouseInfoCitysByCommunity?communityID={0}"
|
||||
}
|
||||
|
||||
}
|
||||
|
After Width: | Height: | Size: 119 KiB |
|
After Width: | Height: | Size: 831 KiB |
|
After Width: | Height: | Size: 20 KiB |
|
After Width: | Height: | Size: 820 B |
|
After Width: | Height: | Size: 215 KiB |
|
After Width: | Height: | Size: 110 KiB |
|
After Width: | Height: | Size: 375 KiB |
|
After Width: | Height: | Size: 1.6 KiB |
|
After Width: | Height: | Size: 110 KiB |
|
After Width: | Height: | Size: 211 KiB |
|
After Width: | Height: | Size: 820 B |
|
After Width: | Height: | Size: 20 KiB |
|
After Width: | Height: | Size: 215 KiB |
|
After Width: | Height: | Size: 119 KiB |
|
After Width: | Height: | Size: 110 KiB |
|
After Width: | Height: | Size: 20 KiB |
|
After Width: | Height: | Size: 215 KiB |
|
After Width: | Height: | Size: 129 KiB |
|
After Width: | Height: | Size: 110 KiB |
|
After Width: | Height: | Size: 340 KiB |
|
After Width: | Height: | Size: 215 KiB |
|
After Width: | Height: | Size: 417 B |
|
After Width: | Height: | Size: 215 KiB |
|
After Width: | Height: | Size: 20 KiB |
|
After Width: | Height: | Size: 12 KiB |
|
After Width: | Height: | Size: 64 KiB |
|
After Width: | Height: | Size: 211 KiB |
|
After Width: | Height: | Size: 1.6 KiB |
|
After Width: | Height: | Size: 20 KiB |
|
After Width: | Height: | Size: 20 KiB |
|
After Width: | Height: | Size: 119 KiB |
|
After Width: | Height: | Size: 215 KiB |
|
After Width: | Height: | Size: 110 KiB |
|
After Width: | Height: | Size: 119 KiB |