| | |
| | | style="width: 100%" |
| | | v-model="value1" |
| | | type="datetimerange" |
| | | value-format="`yyyy-MM-dd HH:mm:ss`" |
| | | :value-format="`yyyy-MM-dd HH:mm:ss`" |
| | | range-separator="至" |
| | | start-placeholder="开始日期" |
| | | end-placeholder="结束日期"> |
| | |
| | | </el-row> |
| | | <div class="qianzi" style="margin-left: 85px"> |
| | | <span>表明身份、出示证件:我们是峰峰矿区综合行政执法局的行政执法人员,这是执法证件请你过目确认,如无异议请在此签字:</span> |
| | | <!-- <el-input v-model="form.interrogeeName" placeholder="请填写被询问人" style="width: 160px!important;"></el-input>--> |
| | | <!-- <el-input v-model="form.interrogeeName" placeholder="请填写被询问人" style="width: 160px!important;"></el-input>--> |
| | | |
| | | <div id="imges"> |
| | | <button @click="goQianzi()">签字</button> |
| | | <button @click="gozhiwen()">指纹</button> |
| | | <button @click="look()">查看</button> |
| | | <el-image v-if="false" @click="goQianzi()" style="height: 3em!important;width: 3em!important;" src="/images/1.png" alt="请签字"/> |
| | | <el-image v-if="false" style="height: 3em!important;width: 3em!important;" src="/images/2.png" alt="请录入指纹"/> |
| | | <button v-if="form.signature ==''||form.signature ==null" @click="goQianzi()">去签名</button> |
| | | <button v-if="form.fingerprint ==''||form.fingerprint ==null" @click="gozhiwen()">录指纹</button> |
| | | <el-image v-if="form.signature !=''" style="height: 3em!important;width: 3em!important;" |
| | | :src="form.signature" alt="请签字"/> |
| | | <el-image v-if="form.fingerprint !=''" :class="form.fingerprint?'imgBox':''" style="height: 2em!important;width: 2em!important;" :src="form.fingerprint" alt="请录入指纹"/> |
| | | </div> |
| | | </div> |
| | | <p style="margin-left: 85px"> |
| | |
| | | </ul> |
| | | <el-form-item label-width="50%"> |
| | | <el-button type="primary" icon="el-icon-circle-plus" @click="addEle"> |
| | | <!-- <img src="../../../assets/lawImg/addIcon.png" alt="">--> |
| | | <!-- <img src="../../../assets/lawImg/addIcon.png" alt="">--> |
| | | </el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div style="text-align: center"> |
| | | <el-button v-if="form.registerState=='0'" @click="dataFormSubmit('0')">保存</el-button> |
| | | <el-button type="primary" @click="viewVord(dataForm)">预览</el-button> |
| | | <el-button v-if="form.registerState=='1'"type="success" @click="downloadWord(dataForm)">下载</el-button> |
| | | <el-button v-if="form.registerState=='0'||form.registerState==null" @click="dataFormSubmit('0')">保存</el-button> |
| | | <el-button type="primary" @click="viewVord(form.id)">预览</el-button> |
| | | <el-button type="success" @click="downloadWord(form)">下载</el-button> |
| | | </div> |
| | | </el-main> |
| | | </template> |
| | | |
| | | <script> |
| | | import {inquiry,inquiryquestion} from '../../../api/News/pad' |
| | | import {createword, inquiry, inquiryquestion} from '../../../api/News/pad' |
| | | import {viewD, exportDoc, urlToBase64, viewWithImg, exportDocWidthImg} from "@/libs/word" |
| | | |
| | | export default { |
| | | name: "mangeBL", |
| | | props:['id'], |
| | | data() { |
| | | return { |
| | | props:['id'], |
| | | id:'', |
| | | value1: [], |
| | | form: { |
| | | causePoint: "", |
| | |
| | | inquirerNumberOne: "", |
| | | inquirerNameTwo: "", |
| | | inquirerNumberTwo: "", |
| | | answer:"", |
| | | questionsAnswers:[ |
| | | answer: "", |
| | | questionsAnswers: [ |
| | | { |
| | | wen:'', |
| | | da:'', |
| | | wen: '', |
| | | da: '', |
| | | } |
| | | ], |
| | | fingerprint:"", |
| | | fingerprint: "", |
| | | }, |
| | | } |
| | | }, |
| | | created() { |
| | | mounted() { |
| | | this.id = this.$store.state.user.id |
| | | console.log(this.id,'id') |
| | | this.getDataList() |
| | | |
| | | window.getSignUrl =this.getSignUrl; |
| | | window.getFingerUrl =this.getFingerUrl; |
| | | // this.getSignUrl(); |
| | | }, |
| | | /*mounted() { |
| | | console.log(this.id,'id=================') |
| | | },*/ |
| | | methods: { |
| | | getDataList(){ |
| | | inquiryquestion(this.id).then(res =>{ |
| | | this.form =res.data.data |
| | | this.value1.push(res.data.data.startTime) |
| | | this.value1.push(res.data.data.endTime) |
| | | }) |
| | | getDataList() { |
| | | inquiryquestion(this.id).then(res => { |
| | | console.log(res,'res') |
| | | this.form = res.data.data |
| | | this.value1.push(res.data.data.startTime) |
| | | this.value1.push(res.data.data.endTime) |
| | | }) |
| | | |
| | | }, |
| | | // 点击添加 |
| | | addEle() { |
| | |
| | | da: '', |
| | | }); |
| | | }, |
| | | look(){ |
| | | this.form.questionsAnswers.da = window.android.getSignUrl(url); |
| | | this.form.questionsAnswers.wen =window.android.getFingerUrl(url); |
| | | getSignUrl(url){ |
| | | this.form.signature = url; |
| | | }, |
| | | getFingerUrl(url1){ |
| | | this.form.fingerprint = url1; |
| | | }, |
| | | //点击跳转签字页面 |
| | | goQianzi(){ |
| | | goQianzi() { |
| | | window.android.toSign(); |
| | | }, |
| | | gozhiwen(){ |
| | | window.android.toFinger(); |
| | | gozhiwen() { |
| | | window.android.toFinger(); |
| | | }, |
| | | //点击保存数据 |
| | | dataFormSubmit(){ |
| | | dataFormSubmit() { |
| | | this.form.startTime = this.value1[0] |
| | | this.form.endTime = this.value1[1] |
| | | this.form.registerId = this.id |
| | | inquiry(this.form).then(res =>{ |
| | | inquiry(this.form).then(res => { |
| | | if (res.data.code == 0) { |
| | | this.$message.success("保存成功"); |
| | | } |
| | | }) |
| | | }, |
| | | //点击预览 |
| | | viewVord(data) { |
| | | /*if (data){ |
| | | this.dataFormSubmit(); |
| | | createword(data).then(res =>{ |
| | | // console.log(this.form.id) |
| | | console.log(res,'123456') |
| | | // window.android.toPreviewWord() |
| | | }) |
| | | }else { |
| | | createword(data).then(res =>{ |
| | | // console.log(this.form.id) |
| | | console.log(res,'123456') |
| | | // window.android.toPreviewWord() |
| | | }) |
| | | }*/ |
| | | createword(data).then(res =>{ |
| | | // console.log(this.form.id) |
| | | console.log(res,'123456') |
| | | window.android.toPreviewWord(res.data.data) |
| | | }).catch(err=>{ |
| | | console.log(err,'错误'); |
| | | }) |
| | | |
| | | |
| | | |
| | | /*this.$router.push({ |
| | | path: '/WordYulan', |
| | | query: { |
| | | wordData: data, |
| | | src:'/wordes/inquiryCause.docx', |
| | | name:'调查询问笔录', |
| | | } |
| | | })*/ |
| | | }, |
| | | //点击下载 |
| | | downloadWord(data){ |
| | | window.android.toDownLoadWord() |
| | | console.log(exportDoc(data, '/wordes/inquiryCause.docx','调查询问笔录'),'aaaa') |
| | | createword(data).then(res =>{ |
| | | // console.log(this.form.id) |
| | | console.log(res,'123456') |
| | | window.android.toPreviewWord(res.data.data) |
| | | }).catch(err=>{ |
| | | console.log(err,'错误'); |
| | | }) }, |
| | | // 遍历数据 |
| | | transforData(obj) { |
| | | let s = JSON.stringify(obj); |
| | | let data = JSON.parse(s); |
| | | |
| | | let str = JSON.stringify(data); |
| | | let jsonData = JSON.parse(str); |
| | | data = jsonData; |
| | | |
| | | if (data.startTime != '' && data.startTime != null) { |
| | | data.startTime = moment(data.startTime).format('YYYY年MM月DD日HH时mm分'); |
| | | } else { |
| | | data.startTime = ' 年 月 日 时 分' |
| | | } |
| | | |
| | | if (data.endTime != '' && data.endTime != null) { |
| | | data.endTime = moment(data.endTime).format('HH时mm分'); |
| | | } else { |
| | | data.endTime = ' 时 分' |
| | | } |
| | | } |
| | | }, |
| | | } |
| | |
| | | |
| | | <style lang="scss" scoped> |
| | | //.qianzi { |
| | | //display: flex; |
| | | /*justify-content: space-between;*/ |
| | | //align-items: center; |
| | | /*flex-wrap: wrap;*/ |
| | | //display: flex; |
| | | /*justify-content: space-between;*/ |
| | | //align-items: center; |
| | | /*flex-wrap: wrap;*/ |
| | | //} |
| | | .el-input{ |
| | | border: none!important; |
| | | .el-input { |
| | | border: none !important; |
| | | } |
| | | |
| | | /*.el-image{ |
| | | width: 10rem!important; |
| | | height: 10rem!important; |
| | | }*/ |
| | | #imges{ |
| | | #imges { |
| | | display: block; |
| | | position: relative; |
| | | .imgBox{ |
| | | position: absolute!important; |
| | | |
| | | .imgBox { |
| | | position: absolute !important; |
| | | left: 0; |
| | | bottom: 0; |
| | | top: 50%; |
| | | } |
| | | } |
| | | |