telephone-clients 3.0.103-79 → 3.0.103-80
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/App.vue +54 -54
- package/src/components/pc/WorkHistory.vue +560 -560
- package/src/components/temp/RepairList.vue +125 -125
- package/src/filiale/kelai/android/AppTakePic.vue +143 -143
- package/src/filiale/kelai/android/PhoneVentilationLeave.vue +176 -176
- package/src/filiale/kelai/telephoneAndroid.js +19 -19
- package/src/filiale/wenxi/android/RepairInfo.vue +254 -254
- package/src/filiale/wenxi/android/ZHihuanFirst.vue +502 -502
- package/src/filiale/wenxi/pc/DistributeWork.vue +163 -163
- package/src/filiale/wenxi/pc/GasWork.vue +753 -753
- package/src/filiale/wenxi/pc/TelFindUser.vue +306 -306
- package/src/filiale/wenxi/telephone.js +16 -16
- package/src/filiale/wenxi/telephoneAndroid.js +17 -17
- package/src/filiale/zhongsheng/android/RepairUserInfo.vue +559 -559
- package/src/main.js +1 -1
|
@@ -1,125 +1,125 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div id="pc-finduser-page">
|
|
3
|
-
<criteria-paged :model="model" v-ref:paged :simple="true">
|
|
4
|
-
<!-- <criteria partial='criteria'>
|
|
5
|
-
</criteria> -->
|
|
6
|
-
<data-grid :model="model" partial='list' v-ref:grid
|
|
7
|
-
class="list_area table_sy">
|
|
8
|
-
<template partial='head'>
|
|
9
|
-
<tr>
|
|
10
|
-
<th><nobr>操作</nobr></th>
|
|
11
|
-
<th><nobr>工单状态</nobr></th>
|
|
12
|
-
<th><nobr>工单类型</nobr></th>
|
|
13
|
-
<th><nobr>是否完成</nobr></th>
|
|
14
|
-
<th><nobr>工单编号</nobr></th>
|
|
15
|
-
<th><nobr>报修时间</nobr></th>
|
|
16
|
-
<th><nobr>报修电话</nobr></th>
|
|
17
|
-
<th><nobr>报修内容</nobr></th>
|
|
18
|
-
<th><nobr>用户地址</nobr></th>
|
|
19
|
-
<th><nobr>派单人员</nobr></th>
|
|
20
|
-
<th><nobr>维修人员</nobr></th>
|
|
21
|
-
<th><nobr>完成时间</nobr></th>
|
|
22
|
-
</tr>
|
|
23
|
-
</template>
|
|
24
|
-
<template partial='body'>
|
|
25
|
-
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>
|
|
26
|
-
<button class="button_search button_spacing" style="margin-right: 9px"
|
|
27
|
-
@click="$parent.$parent.$parent.showDetail(row)">详情
|
|
28
|
-
</button>
|
|
29
|
-
</nobr></td>
|
|
30
|
-
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr> {{ row.f_state ?row.f_state:(row.defname ?row.defname:'完成')}}</nobr></td>
|
|
31
|
-
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_workorder_type}}</nobr></td>
|
|
32
|
-
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_result_status?row.f_result_status:'未完成'}}</nobr></td>
|
|
33
|
-
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_service_id}}</nobr></td>
|
|
34
|
-
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_created_date}}</nobr></td>
|
|
35
|
-
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_phone}}</nobr></td>
|
|
36
|
-
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_remarks}}</nobr></td>
|
|
37
|
-
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_address}}</nobr></td>
|
|
38
|
-
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_single_man}}</nobr></td>
|
|
39
|
-
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_order_man}}</nobr></td>
|
|
40
|
-
|
|
41
|
-
<!--<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_remarks}}</nobr></td>-->
|
|
42
|
-
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_date_leave}}</nobr></td>
|
|
43
|
-
</template>
|
|
44
|
-
<!--<template partial='foot'>
|
|
45
|
-
<td style="text-align:center">汇总</td>
|
|
46
|
-
<td></td>
|
|
47
|
-
<td></td>
|
|
48
|
-
<td >累计购气量:{{model.sums.f_pregas}}</td>
|
|
49
|
-
<td >累计金额:{{model.sums.f_totalcost}}</td>
|
|
50
|
-
<td >共{{model.count}}条</td>
|
|
51
|
-
</template>-->
|
|
52
|
-
</data-grid>
|
|
53
|
-
</criteria-paged>
|
|
54
|
-
<modal :show.sync="show" v-ref:modal backdrop="false">
|
|
55
|
-
<header slot="modal-header" class="modal-header">
|
|
56
|
-
工单详情
|
|
57
|
-
</header>
|
|
58
|
-
<article slot="modal-body" class="modal-body">
|
|
59
|
-
<work-history :row-one="row" ></work-history>
|
|
60
|
-
</article>
|
|
61
|
-
<footer slot="modal-footer" class="modal-footer">
|
|
62
|
-
<button type="button" class="btn btn-success" @click='show = false'>关闭</button>
|
|
63
|
-
</footer>
|
|
64
|
-
</modal>
|
|
65
|
-
</div>
|
|
66
|
-
</template>
|
|
67
|
-
|
|
68
|
-
<script>
|
|
69
|
-
/**
|
|
70
|
-
*用户档案相关信息组件
|
|
71
|
-
*/
|
|
72
|
-
import { PagedList } from 'vue-client'
|
|
73
|
-
export default {
|
|
74
|
-
title: '历史维修记录',
|
|
75
|
-
data () {
|
|
76
|
-
return {
|
|
77
|
-
model: new PagedList((this.user && this.user.isphone) ? '${this.$androidUtil.getProxyUrl()}/' : '' + 'rs/sql/serviceDetails', 5),
|
|
78
|
-
row: Object,
|
|
79
|
-
show:false,
|
|
80
|
-
}
|
|
81
|
-
},
|
|
82
|
-
props: {
|
|
83
|
-
user: {
|
|
84
|
-
type: Object
|
|
85
|
-
},
|
|
86
|
-
callObj:{
|
|
87
|
-
type: Object
|
|
88
|
-
},
|
|
89
|
-
clearflg:0
|
|
90
|
-
},
|
|
91
|
-
methods: {
|
|
92
|
-
showDetail(row){
|
|
93
|
-
console.log("996",row)
|
|
94
|
-
this.row = row
|
|
95
|
-
this.show = true
|
|
96
|
-
},
|
|
97
|
-
selected (row) {
|
|
98
|
-
if (this.row === row) {
|
|
99
|
-
this.row = null
|
|
100
|
-
} else {
|
|
101
|
-
this.row = row
|
|
102
|
-
}
|
|
103
|
-
},
|
|
104
|
-
isSelected (row) {
|
|
105
|
-
return this.row === row
|
|
106
|
-
}
|
|
107
|
-
},
|
|
108
|
-
watch : {
|
|
109
|
-
'user' (val) {
|
|
110
|
-
this.model.rows = []
|
|
111
|
-
this.model.search(`f_userinfo_id = '${this.user.f_userinfo_id}'`)
|
|
112
|
-
|
|
113
|
-
},
|
|
114
|
-
|
|
115
|
-
'clearflg'(){
|
|
116
|
-
this.model.rows = []
|
|
117
|
-
}
|
|
118
|
-
},
|
|
119
|
-
ready () {
|
|
120
|
-
if (this.user && this.user.f_userinfo_id) {
|
|
121
|
-
this.model.search(`f_userinfo_id = '${this.user.f_userinfo_id}'`)
|
|
122
|
-
}
|
|
123
|
-
}
|
|
124
|
-
}
|
|
125
|
-
</script>
|
|
1
|
+
<template>
|
|
2
|
+
<div id="pc-finduser-page">
|
|
3
|
+
<criteria-paged :model="model" v-ref:paged :simple="true">
|
|
4
|
+
<!-- <criteria partial='criteria'>
|
|
5
|
+
</criteria> -->
|
|
6
|
+
<data-grid :model="model" partial='list' v-ref:grid
|
|
7
|
+
class="list_area table_sy">
|
|
8
|
+
<template partial='head'>
|
|
9
|
+
<tr>
|
|
10
|
+
<th><nobr>操作</nobr></th>
|
|
11
|
+
<th><nobr>工单状态</nobr></th>
|
|
12
|
+
<th><nobr>工单类型</nobr></th>
|
|
13
|
+
<th><nobr>是否完成</nobr></th>
|
|
14
|
+
<th><nobr>工单编号</nobr></th>
|
|
15
|
+
<th><nobr>报修时间</nobr></th>
|
|
16
|
+
<th><nobr>报修电话</nobr></th>
|
|
17
|
+
<th><nobr>报修内容</nobr></th>
|
|
18
|
+
<th><nobr>用户地址</nobr></th>
|
|
19
|
+
<th><nobr>派单人员</nobr></th>
|
|
20
|
+
<th><nobr>维修人员</nobr></th>
|
|
21
|
+
<th><nobr>完成时间</nobr></th>
|
|
22
|
+
</tr>
|
|
23
|
+
</template>
|
|
24
|
+
<template partial='body'>
|
|
25
|
+
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>
|
|
26
|
+
<button class="button_search button_spacing" style="margin-right: 9px"
|
|
27
|
+
@click="$parent.$parent.$parent.showDetail(row)">详情
|
|
28
|
+
</button>
|
|
29
|
+
</nobr></td>
|
|
30
|
+
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr> {{ row.f_state ?row.f_state:(row.defname ?row.defname:'完成')}}</nobr></td>
|
|
31
|
+
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_workorder_type}}</nobr></td>
|
|
32
|
+
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_result_status?row.f_result_status:'未完成'}}</nobr></td>
|
|
33
|
+
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_service_id}}</nobr></td>
|
|
34
|
+
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_created_date}}</nobr></td>
|
|
35
|
+
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_phone}}</nobr></td>
|
|
36
|
+
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_remarks}}</nobr></td>
|
|
37
|
+
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_address}}</nobr></td>
|
|
38
|
+
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_single_man}}</nobr></td>
|
|
39
|
+
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_order_man}}</nobr></td>
|
|
40
|
+
|
|
41
|
+
<!--<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_remarks}}</nobr></td>-->
|
|
42
|
+
<td :style="row.f_result_status=='已完成'?'':'color:red'"><nobr>{{row.f_date_leave}}</nobr></td>
|
|
43
|
+
</template>
|
|
44
|
+
<!--<template partial='foot'>
|
|
45
|
+
<td style="text-align:center">汇总</td>
|
|
46
|
+
<td></td>
|
|
47
|
+
<td></td>
|
|
48
|
+
<td >累计购气量:{{model.sums.f_pregas}}</td>
|
|
49
|
+
<td >累计金额:{{model.sums.f_totalcost}}</td>
|
|
50
|
+
<td >共{{model.count}}条</td>
|
|
51
|
+
</template>-->
|
|
52
|
+
</data-grid>
|
|
53
|
+
</criteria-paged>
|
|
54
|
+
<modal :show.sync="show" v-ref:modal backdrop="false">
|
|
55
|
+
<header slot="modal-header" class="modal-header">
|
|
56
|
+
工单详情
|
|
57
|
+
</header>
|
|
58
|
+
<article slot="modal-body" class="modal-body">
|
|
59
|
+
<work-history :row-one="row" ></work-history>
|
|
60
|
+
</article>
|
|
61
|
+
<footer slot="modal-footer" class="modal-footer">
|
|
62
|
+
<button type="button" class="btn btn-success" @click='show = false'>关闭</button>
|
|
63
|
+
</footer>
|
|
64
|
+
</modal>
|
|
65
|
+
</div>
|
|
66
|
+
</template>
|
|
67
|
+
|
|
68
|
+
<script>
|
|
69
|
+
/**
|
|
70
|
+
*用户档案相关信息组件
|
|
71
|
+
*/
|
|
72
|
+
import { PagedList } from 'vue-client'
|
|
73
|
+
export default {
|
|
74
|
+
title: '历史维修记录',
|
|
75
|
+
data () {
|
|
76
|
+
return {
|
|
77
|
+
model: new PagedList((this.user && this.user.isphone) ? '${this.$androidUtil.getProxyUrl()}/' : '' + 'rs/sql/serviceDetails', 5),
|
|
78
|
+
row: Object,
|
|
79
|
+
show:false,
|
|
80
|
+
}
|
|
81
|
+
},
|
|
82
|
+
props: {
|
|
83
|
+
user: {
|
|
84
|
+
type: Object
|
|
85
|
+
},
|
|
86
|
+
callObj:{
|
|
87
|
+
type: Object
|
|
88
|
+
},
|
|
89
|
+
clearflg:0
|
|
90
|
+
},
|
|
91
|
+
methods: {
|
|
92
|
+
showDetail(row){
|
|
93
|
+
console.log("996",row)
|
|
94
|
+
this.row = row
|
|
95
|
+
this.show = true
|
|
96
|
+
},
|
|
97
|
+
selected (row) {
|
|
98
|
+
if (this.row === row) {
|
|
99
|
+
this.row = null
|
|
100
|
+
} else {
|
|
101
|
+
this.row = row
|
|
102
|
+
}
|
|
103
|
+
},
|
|
104
|
+
isSelected (row) {
|
|
105
|
+
return this.row === row
|
|
106
|
+
}
|
|
107
|
+
},
|
|
108
|
+
watch : {
|
|
109
|
+
'user' (val) {
|
|
110
|
+
this.model.rows = []
|
|
111
|
+
this.model.search(`tswo.f_userinfo_id = '${this.user.f_userinfo_id}'`)
|
|
112
|
+
|
|
113
|
+
},
|
|
114
|
+
|
|
115
|
+
'clearflg'(){
|
|
116
|
+
this.model.rows = []
|
|
117
|
+
}
|
|
118
|
+
},
|
|
119
|
+
ready () {
|
|
120
|
+
if (this.user && this.user.f_userinfo_id) {
|
|
121
|
+
this.model.search(`tswo.f_userinfo_id = '${this.user.f_userinfo_id}'`)
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
</script>
|
|
@@ -1,143 +1,143 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div class="panel">
|
|
3
|
-
<div class="panel-body panel-self" style="background-color: #F8F8F8;">
|
|
4
|
-
<div class="row form-group" style="height: 240px;overflow: scroll;">
|
|
5
|
-
<div class="col-xs-4 col-sm-3 col-md-2 col-xs-offset-1 col-sm-offset-1 col-md-offset-1" v-for="(index,file) in fileList">
|
|
6
|
-
<img-self :src="file.f_downloadURL" :width="120" :height="170"></img-self>
|
|
7
|
-
<img src="../../../assets/删除.png" style="width: 15px;margin-top: -80px" @click.prevent="delfile(file, index)">
|
|
8
|
-
</div>
|
|
9
|
-
</div>
|
|
10
|
-
<div class="row text-right form-group" v-if="istakepic">
|
|
11
|
-
<v-select
|
|
12
|
-
class="fileType"
|
|
13
|
-
placeholder="请选择使用类型"
|
|
14
|
-
v-if="istype"
|
|
15
|
-
:search="false"
|
|
16
|
-
close-on-select
|
|
17
|
-
value-single
|
|
18
|
-
:options="typeList"
|
|
19
|
-
v-model="type"
|
|
20
|
-
:value.sync="type"
|
|
21
|
-
></v-select>
|
|
22
|
-
<button class="btn" style="background-color: #7dc1f4;border-radius: 5px;margin-right: 10px" @click.prevent="takePic(type)">拍照</button>
|
|
23
|
-
</div>
|
|
24
|
-
</div>
|
|
25
|
-
</div>
|
|
26
|
-
</template>
|
|
27
|
-
|
|
28
|
-
<script>
|
|
29
|
-
import {HttpResetClass} from 'vue-client'
|
|
30
|
-
import {guid, toStandardTimeString} from '../../../components/Util'
|
|
31
|
-
import Vue from 'vue'
|
|
32
|
-
export default {
|
|
33
|
-
title: '附件',
|
|
34
|
-
props: ['blobid', 'type', 'defname', 'istype', 'typelabel', 'isdelete', 'istakepic'],
|
|
35
|
-
data () {
|
|
36
|
-
return {
|
|
37
|
-
fileList: []
|
|
38
|
-
}
|
|
39
|
-
},
|
|
40
|
-
ready () {
|
|
41
|
-
this.getFiles()
|
|
42
|
-
},
|
|
43
|
-
methods: {
|
|
44
|
-
async getFiles () {
|
|
45
|
-
console.log('----------------开始查询图片----------------')
|
|
46
|
-
this.fileList = []
|
|
47
|
-
|
|
48
|
-
let http = new HttpResetClass()
|
|
49
|
-
|
|
50
|
-
let data = {
|
|
51
|
-
tablename: 't_files',
|
|
52
|
-
condition: `f_blobid = '${this.blobid}' and fremarks = '手机拍照' order by f_uploaddate desc `
|
|
53
|
-
}
|
|
54
|
-
let res = await http.load('POST', `${this.$androidUtil.getProxyUrl()}/rs/sql/apply_singleTable`, {data: data}, {
|
|
55
|
-
// let res = await http.load('POST', `rs/sql/applySingleTable`, {data: data}, {
|
|
56
|
-
warnMsg: null,
|
|
57
|
-
resolveMsg: null
|
|
58
|
-
})
|
|
59
|
-
|
|
60
|
-
for (var i = 0; i < res.data.length; i++) {
|
|
61
|
-
console.log('-----------地址----------------',`${this.$androidUtil.getProxyUrl()}/${res.data[i].f_downloadpath.substring(res.data[i].f_downloadpath.lastIndexOf(":\\") + 2)}`)
|
|
62
|
-
res.data[i].f_downloadURL = `${this.$androidUtil.getProxyUrl()}/${res.data[i].f_downloadpath.substring(res.data[i].f_downloadpath.lastIndexOf(":\\") + 2)}`
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
this.fileList = res.data
|
|
66
|
-
},
|
|
67
|
-
delfile (file, index) {
|
|
68
|
-
this.$resetdelete(`${this.$androidUtil.getProxyUrl()}/rs/entity/t_files`, {id: file.id}, {resolveMsg: '删除成功', rejectMsg: '删除失败'}).then((res) => {
|
|
69
|
-
this.$dispatch("delResid", file.id)
|
|
70
|
-
this.getFiles()
|
|
71
|
-
})
|
|
72
|
-
},
|
|
73
|
-
takePic (title) {
|
|
74
|
-
// 拍照成功回调
|
|
75
|
-
HostApp.__callback__ = this.cameraCallBack
|
|
76
|
-
HostApp.__this__ = this
|
|
77
|
-
let fileName = guid() + '.jpg'
|
|
78
|
-
// 打开相机
|
|
79
|
-
HostApp._open_a_page({
|
|
80
|
-
type: 'boomerang',
|
|
81
|
-
page: 'com.aofeng.hybrid.android.peripheral.CameraActivity',
|
|
82
|
-
param: {
|
|
83
|
-
file: fileName,
|
|
84
|
-
requestCode: 200,
|
|
85
|
-
callback: 'javascript:HostApp.__callback__("' + fileName + '", "%s");',
|
|
86
|
-
watermark: title + '\t时间:' + toStandardTimeString() + '\t' + Vue.user.name // 水印
|
|
87
|
-
}
|
|
88
|
-
})
|
|
89
|
-
},
|
|
90
|
-
cameraCallBack (fileName, fileUrl) {
|
|
91
|
-
console.log('-----------cameraCallBack-----------------')
|
|
92
|
-
|
|
93
|
-
let data = {
|
|
94
|
-
blobid: HostApp.__this__.blobid,
|
|
95
|
-
type: HostApp.__this__.type,
|
|
96
|
-
defname: HostApp.__this__.defname,
|
|
97
|
-
username: Vue.user.name,
|
|
98
|
-
fremarks: '手机拍照',
|
|
99
|
-
fileName: fileName,
|
|
100
|
-
fileUrl: fileUrl,
|
|
101
|
-
entityName:null
|
|
102
|
-
}
|
|
103
|
-
debugger
|
|
104
|
-
console.log('-----------bzLogic-----------------')
|
|
105
|
-
let aaaa =HostApp.bzLogic({
|
|
106
|
-
'logic': 'appFileUpload',
|
|
107
|
-
'data': data
|
|
108
|
-
})
|
|
109
|
-
console.log("555"+aaaa)
|
|
110
|
-
console.log('----------------开始回调查询-------------------')
|
|
111
|
-
HostApp.__this__.getFiles()
|
|
112
|
-
console.log('----------------查询回调结束-------------------')
|
|
113
|
-
|
|
114
|
-
HostApp.__callback__ = null
|
|
115
|
-
HostApp.__this__ = null
|
|
116
|
-
}
|
|
117
|
-
},
|
|
118
|
-
computed: {
|
|
119
|
-
typeList () {
|
|
120
|
-
if (this.typelabel) {
|
|
121
|
-
return this.$appdata.getParam(this.typelabel)
|
|
122
|
-
}
|
|
123
|
-
return this.$appdata.getParam('使用类型')
|
|
124
|
-
}
|
|
125
|
-
},
|
|
126
|
-
events: {
|
|
127
|
-
}
|
|
128
|
-
}
|
|
129
|
-
</script>
|
|
130
|
-
|
|
131
|
-
<style lang="less">
|
|
132
|
-
.fileType {
|
|
133
|
-
float: left;
|
|
134
|
-
.select-style {
|
|
135
|
-
background: #f8f8f8;
|
|
136
|
-
border: 0px;
|
|
137
|
-
}
|
|
138
|
-
input {
|
|
139
|
-
border-left: none;
|
|
140
|
-
width: 100%;
|
|
141
|
-
}
|
|
142
|
-
}
|
|
143
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<div class="panel">
|
|
3
|
+
<div class="panel-body panel-self" style="background-color: #F8F8F8;">
|
|
4
|
+
<div class="row form-group" style="height: 240px;overflow: scroll;">
|
|
5
|
+
<div class="col-xs-4 col-sm-3 col-md-2 col-xs-offset-1 col-sm-offset-1 col-md-offset-1" v-for="(index,file) in fileList">
|
|
6
|
+
<img-self :src="file.f_downloadURL" :width="120" :height="170"></img-self>
|
|
7
|
+
<img src="../../../assets/删除.png" style="width: 15px;margin-top: -80px" @click.prevent="delfile(file, index)">
|
|
8
|
+
</div>
|
|
9
|
+
</div>
|
|
10
|
+
<div class="row text-right form-group" v-if="istakepic">
|
|
11
|
+
<v-select
|
|
12
|
+
class="fileType"
|
|
13
|
+
placeholder="请选择使用类型"
|
|
14
|
+
v-if="istype"
|
|
15
|
+
:search="false"
|
|
16
|
+
close-on-select
|
|
17
|
+
value-single
|
|
18
|
+
:options="typeList"
|
|
19
|
+
v-model="type"
|
|
20
|
+
:value.sync="type"
|
|
21
|
+
></v-select>
|
|
22
|
+
<button class="btn" style="background-color: #7dc1f4;border-radius: 5px;margin-right: 10px" @click.prevent="takePic(type)">拍照</button>
|
|
23
|
+
</div>
|
|
24
|
+
</div>
|
|
25
|
+
</div>
|
|
26
|
+
</template>
|
|
27
|
+
|
|
28
|
+
<script>
|
|
29
|
+
import {HttpResetClass} from 'vue-client'
|
|
30
|
+
import {guid, toStandardTimeString} from '../../../components/Util'
|
|
31
|
+
import Vue from 'vue'
|
|
32
|
+
export default {
|
|
33
|
+
title: '附件',
|
|
34
|
+
props: ['blobid', 'type', 'defname', 'istype', 'typelabel', 'isdelete', 'istakepic'],
|
|
35
|
+
data () {
|
|
36
|
+
return {
|
|
37
|
+
fileList: []
|
|
38
|
+
}
|
|
39
|
+
},
|
|
40
|
+
ready () {
|
|
41
|
+
this.getFiles()
|
|
42
|
+
},
|
|
43
|
+
methods: {
|
|
44
|
+
async getFiles () {
|
|
45
|
+
console.log('----------------开始查询图片----------------')
|
|
46
|
+
this.fileList = []
|
|
47
|
+
|
|
48
|
+
let http = new HttpResetClass()
|
|
49
|
+
|
|
50
|
+
let data = {
|
|
51
|
+
tablename: 't_files',
|
|
52
|
+
condition: `f_blobid = '${this.blobid}' and fremarks = '手机拍照' order by f_uploaddate desc `
|
|
53
|
+
}
|
|
54
|
+
let res = await http.load('POST', `${this.$androidUtil.getProxyUrl()}/rs/sql/apply_singleTable`, {data: data}, {
|
|
55
|
+
// let res = await http.load('POST', `rs/sql/applySingleTable`, {data: data}, {
|
|
56
|
+
warnMsg: null,
|
|
57
|
+
resolveMsg: null
|
|
58
|
+
})
|
|
59
|
+
|
|
60
|
+
for (var i = 0; i < res.data.length; i++) {
|
|
61
|
+
console.log('-----------地址----------------',`${this.$androidUtil.getProxyUrl()}/${res.data[i].f_downloadpath.substring(res.data[i].f_downloadpath.lastIndexOf(":\\") + 2)}`)
|
|
62
|
+
res.data[i].f_downloadURL = `${this.$androidUtil.getProxyUrl()}/${res.data[i].f_downloadpath.substring(res.data[i].f_downloadpath.lastIndexOf(":\\") + 2)}`
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
this.fileList = res.data
|
|
66
|
+
},
|
|
67
|
+
delfile (file, index) {
|
|
68
|
+
this.$resetdelete(`${this.$androidUtil.getProxyUrl()}/rs/entity/t_files`, {id: file.id}, {resolveMsg: '删除成功', rejectMsg: '删除失败'}).then((res) => {
|
|
69
|
+
this.$dispatch("delResid", file.id)
|
|
70
|
+
this.getFiles()
|
|
71
|
+
})
|
|
72
|
+
},
|
|
73
|
+
takePic (title) {
|
|
74
|
+
// 拍照成功回调
|
|
75
|
+
HostApp.__callback__ = this.cameraCallBack
|
|
76
|
+
HostApp.__this__ = this
|
|
77
|
+
let fileName = guid() + '.jpg'
|
|
78
|
+
// 打开相机
|
|
79
|
+
HostApp._open_a_page({
|
|
80
|
+
type: 'boomerang',
|
|
81
|
+
page: 'com.aofeng.hybrid.android.peripheral.CameraActivity',
|
|
82
|
+
param: {
|
|
83
|
+
file: fileName,
|
|
84
|
+
requestCode: 200,
|
|
85
|
+
callback: 'javascript:HostApp.__callback__("' + fileName + '", "%s");',
|
|
86
|
+
watermark: title + '\t时间:' + toStandardTimeString() + '\t' + Vue.user.name // 水印
|
|
87
|
+
}
|
|
88
|
+
})
|
|
89
|
+
},
|
|
90
|
+
cameraCallBack (fileName, fileUrl) {
|
|
91
|
+
console.log('-----------cameraCallBack-----------------')
|
|
92
|
+
|
|
93
|
+
let data = {
|
|
94
|
+
blobid: HostApp.__this__.blobid,
|
|
95
|
+
type: HostApp.__this__.type,
|
|
96
|
+
defname: HostApp.__this__.defname,
|
|
97
|
+
username: Vue.user.name,
|
|
98
|
+
fremarks: '手机拍照',
|
|
99
|
+
fileName: fileName,
|
|
100
|
+
fileUrl: fileUrl,
|
|
101
|
+
entityName:null
|
|
102
|
+
}
|
|
103
|
+
debugger
|
|
104
|
+
console.log('-----------bzLogic-----------------')
|
|
105
|
+
let aaaa =HostApp.bzLogic({
|
|
106
|
+
'logic': 'appFileUpload',
|
|
107
|
+
'data': data
|
|
108
|
+
})
|
|
109
|
+
console.log("555"+aaaa)
|
|
110
|
+
console.log('----------------开始回调查询-------------------')
|
|
111
|
+
HostApp.__this__.getFiles()
|
|
112
|
+
console.log('----------------查询回调结束-------------------')
|
|
113
|
+
|
|
114
|
+
HostApp.__callback__ = null
|
|
115
|
+
HostApp.__this__ = null
|
|
116
|
+
}
|
|
117
|
+
},
|
|
118
|
+
computed: {
|
|
119
|
+
typeList () {
|
|
120
|
+
if (this.typelabel) {
|
|
121
|
+
return this.$appdata.getParam(this.typelabel)
|
|
122
|
+
}
|
|
123
|
+
return this.$appdata.getParam('使用类型')
|
|
124
|
+
}
|
|
125
|
+
},
|
|
126
|
+
events: {
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
</script>
|
|
130
|
+
|
|
131
|
+
<style lang="less">
|
|
132
|
+
.fileType {
|
|
133
|
+
float: left;
|
|
134
|
+
.select-style {
|
|
135
|
+
background: #f8f8f8;
|
|
136
|
+
border: 0px;
|
|
137
|
+
}
|
|
138
|
+
input {
|
|
139
|
+
border-left: none;
|
|
140
|
+
width: 100%;
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
</style>
|