apply-clients 3.5.5-99 → 3.5.6-2

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.
@@ -1,152 +1,152 @@
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
- <img :src="f_sign_path" width="100%" height="100%" />
6
- </div>
7
- <div class="row text-right form-group">
8
- <button class="btn" style="background-color: #f1e404;border-radius: 5px;margin-right: 10px" @click="clean">清除</button>
9
- <button class="btn" style="background-color: #7dc1f4;border-radius: 5px;margin-right: 10px" @click="sign">签名</button>
10
- </div>
11
- </div>
12
- </div>
13
- </template>
14
- <script>
15
- import {getNowDate, guid, isEmpty} from '../../../components/Util'
16
- import {PagedList} from 'vue-client'
17
- import {HttpResetClass} from 'vue-client'
18
- import QRCode from 'qrcodejs2'
19
- import Vue from "vue";
20
-
21
- export default {
22
- title: '签字',
23
- props: ['filePath','blobid','type', 'defname'],
24
- data () {
25
- return {
26
- f_sign_path: null,
27
- fileName: null
28
- }
29
- },
30
- ready () {
31
- console.log('在ready里打印一下this.filePath',this.filePath)
32
- this.f_sign_path = this.filePath
33
- console.log('在ready里打印一下this.f_sign_path',this.f_sign_path)
34
- this.getFiles()
35
- },
36
- methods: {
37
- clean () {
38
- this.f_sign_path = null
39
- this.fileName = null
40
- this.$emit('sign-clean')
41
- },
42
- sign () {
43
- this.type='手机签字'
44
- console.log('==============签字打印this============',this)
45
- this.delAudioFile(this.f_sign_path)
46
- this.fileName = guid() + '.jpg'
47
- HostApp.__callback__ = this.signCallback
48
- HostApp.__this__ = this
49
- HostApp.getSignature({
50
- file: this.fileName,
51
- requestCode: 111,
52
- callback: 'javascript:HostApp.__callback__("f_sign_path", "%s");'
53
- })
54
- },
55
- // 签名回调
56
- signCallback (prop, signPath) {
57
- console.log('==============签字回调============')
58
- console.log(signPath)
59
- HostApp.__this__.$set(prop, signPath)
60
- console.log(HostApp.__this__.f_sign_path)
61
-
62
- HostApp.__this__.uploadFile()
63
-
64
- HostApp.__callback__ = null
65
- HostApp.__this__ = null
66
- },
67
- uploadFile () {
68
- console.log('===================签字文件上传==============')
69
- console.log('===================打印id==============',HostApp.__this__.blobid)
70
- let data = {
71
- defname:HostApp.__this__.defname,
72
- type:HostApp.__this__.type,
73
- blodid: HostApp.__this__.blobid,
74
- username: Vue.user.name,
75
- fremarks: '报装手机签字文件',
76
- fileName: HostApp.__this__.fileName,
77
- fileUrl: HostApp.__this__.f_sign_path
78
- }
79
-
80
- console.log('-----------bzLogic-----------------')
81
- console.log(JSON.stringify(data))
82
- let res = HostApp.bzLogic({
83
- 'logic': 'appFileUpload',
84
- 'data': data
85
- })
86
- console.log('===============上传回调=================')
87
- console.log(JSON.stringify(res))
88
- HostApp.__this__.getFiles(res.id)
89
- },
90
- async getFiles (fileid) {
91
- console.log('=========进来===============')
92
- let http = new HttpResetClass()
93
- console.log('=========进来===============')
94
- let data = {
95
- tablename: 't_files',
96
- condition: `f_blobid = '${this.blobid}' and defname = '${this.defname}' and fremarks='报装手机签字文件' order by f_upload_date desc `
97
- }
98
- let res = await http.load('POST', `${this.$androidUtil.getProxyUrl()}/rs/sql/apply_singleTable`, {data: data}, {
99
- // let res = await http.load('POST', `rs/sql/apply_singleTable`, {data: data}, {
100
- warnMsg: null,
101
- resolveMsg: null
102
- })
103
-
104
- console.log('=========查询回调===============')
105
- let fileUrl = `${this.$androidUtil.getProxyUrl()}/${res.data[0].f_downloadpath.substring(res.data[0].f_downloadpath.lastIndexOf(":\\") + 2)}`
106
- console.log(fileUrl)
107
- // HostApp.__this__.$set('f_sign_path', fileUrl)
108
- // HostApp.__this__.f_sign_path = fileUrl
109
- this.f_sign_path = fileUrl
110
-
111
- this.$emit('sign-success', fileUrl)
112
- },
113
- delAudioFile (signPath) {
114
- if (!signPath) {
115
- return
116
- }
117
- HostApp.delfile(signPath)
118
- this.f_sign_path = null
119
- this.fileName = null
120
- }
121
- },
122
- events: {
123
- },
124
- computed: {
125
- },
126
- watch: {
127
- }
128
- }
129
- </script>
130
- <style scoped lang="less">
131
- .qrcode {
132
- display: inline-block !important;
133
- margin: 10px 0px;
134
- }
135
- .panel-self{
136
- border-radius: 10px;
137
- border:1px solid #499EDF;
138
- background-color: #F8F8F8;
139
- }
140
- .vertical-center {
141
- display: flex;
142
- align-items: center;
143
- text-align: center;
144
- }
145
- /*清除model中的浮动*/
146
- .clearfix:after,.clearfix:before{
147
- display: table;
148
- }
149
- .clearfix:after{
150
- clear: both;
151
- }
152
- </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
+ <img :src="f_sign_path" width="100%" height="100%" />
6
+ </div>
7
+ <div class="row text-right form-group">
8
+ <button class="btn" style="background-color: #f1e404;border-radius: 5px;margin-right: 10px" @click="clean">清除</button>
9
+ <button class="btn" style="background-color: #7dc1f4;border-radius: 5px;margin-right: 10px" @click="sign">签名</button>
10
+ </div>
11
+ </div>
12
+ </div>
13
+ </template>
14
+ <script>
15
+ import {getNowDate, guid, isEmpty} from '../../../components/Util'
16
+ import {PagedList} from 'vue-client'
17
+ import {HttpResetClass} from 'vue-client'
18
+ import QRCode from 'qrcodejs2'
19
+ import Vue from "vue";
20
+
21
+ export default {
22
+ title: '签字',
23
+ props: ['filePath','blobid','type', 'defname'],
24
+ data () {
25
+ return {
26
+ f_sign_path: null,
27
+ fileName: null
28
+ }
29
+ },
30
+ ready () {
31
+ console.log('在ready里打印一下this.filePath',this.filePath)
32
+ this.f_sign_path = this.filePath
33
+ console.log('在ready里打印一下this.f_sign_path',this.f_sign_path)
34
+ this.getFiles()
35
+ },
36
+ methods: {
37
+ clean () {
38
+ this.f_sign_path = null
39
+ this.fileName = null
40
+ this.$emit('sign-clean')
41
+ },
42
+ sign () {
43
+ this.type='手机签字'
44
+ console.log('==============签字打印this============',this)
45
+ this.delAudioFile(this.f_sign_path)
46
+ this.fileName = guid() + '.jpg'
47
+ HostApp.__callback__ = this.signCallback
48
+ HostApp.__this__ = this
49
+ HostApp.getSignature({
50
+ file: this.fileName,
51
+ requestCode: 111,
52
+ callback: 'javascript:HostApp.__callback__("f_sign_path", "%s");'
53
+ })
54
+ },
55
+ // 签名回调
56
+ signCallback (prop, signPath) {
57
+ console.log('==============签字回调============')
58
+ console.log(signPath)
59
+ HostApp.__this__.$set(prop, signPath)
60
+ console.log(HostApp.__this__.f_sign_path)
61
+
62
+ HostApp.__this__.uploadFile()
63
+
64
+ HostApp.__callback__ = null
65
+ HostApp.__this__ = null
66
+ },
67
+ uploadFile () {
68
+ console.log('===================签字文件上传==============')
69
+ console.log('===================打印id==============',HostApp.__this__.blobid)
70
+ let data = {
71
+ defname:HostApp.__this__.defname,
72
+ type:HostApp.__this__.type,
73
+ blodid: HostApp.__this__.blobid,
74
+ username: Vue.user.name,
75
+ fremarks: '报装手机签字文件',
76
+ fileName: HostApp.__this__.fileName,
77
+ fileUrl: HostApp.__this__.f_sign_path
78
+ }
79
+
80
+ console.log('-----------bzLogic-----------------')
81
+ console.log(JSON.stringify(data))
82
+ let res = HostApp.bzLogic({
83
+ 'logic': 'appFileUpload',
84
+ 'data': data
85
+ })
86
+ console.log('===============上传回调=================')
87
+ console.log(JSON.stringify(res))
88
+ HostApp.__this__.getFiles(res.id)
89
+ },
90
+ async getFiles (fileid) {
91
+ console.log('=========进来===============')
92
+ let http = new HttpResetClass()
93
+ console.log('=========进来===============')
94
+ let data = {
95
+ tablename: 't_files',
96
+ condition: `f_blobid = '${this.blobid}' and defname = '${this.defname}' and fremarks='报装手机签字文件' order by f_upload_date desc `
97
+ }
98
+ let res = await http.load('POST', `${this.$androidUtil.getProxyUrl()}/rs/sql/apply_singleTable`, {data: data}, {
99
+ // let res = await http.load('POST', `rs/sql/apply_singleTable`, {data: data}, {
100
+ warnMsg: null,
101
+ resolveMsg: null
102
+ })
103
+ if(res.data.length>0){
104
+ console.log('=========查询回调===============')
105
+ let fileUrl = `${this.$androidUtil.getProxyUrl()}/${res.data[0].f_downloadpath.substring(res.data[0].f_downloadpath.lastIndexOf(":\\") + 2)}`
106
+ console.log(fileUrl)
107
+ // HostApp.__this__.$set('f_sign_path', fileUrl)
108
+ // HostApp.__this__.f_sign_path = fileUrl
109
+ this.f_sign_path = fileUrl
110
+ this.$emit('sign-success', fileUrl)
111
+ }
112
+ },
113
+ delAudioFile (signPath) {
114
+ if (!signPath) {
115
+ return
116
+ }
117
+ HostApp.delfile(signPath)
118
+ this.f_sign_path = null
119
+ this.fileName = null
120
+ }
121
+ },
122
+ events: {
123
+ },
124
+ computed: {
125
+ },
126
+ watch: {
127
+ }
128
+ }
129
+ </script>
130
+ <style scoped lang="less">
131
+ .qrcode {
132
+ display: inline-block !important;
133
+ margin: 10px 0px;
134
+ }
135
+ .panel-self{
136
+ border-radius: 10px;
137
+ border:1px solid #499EDF;
138
+ background-color: #F8F8F8;
139
+ }
140
+ .vertical-center {
141
+ display: flex;
142
+ align-items: center;
143
+ text-align: center;
144
+ }
145
+ /*清除model中的浮动*/
146
+ .clearfix:after,.clearfix:before{
147
+ display: table;
148
+ }
149
+ .clearfix:after{
150
+ clear: both;
151
+ }
152
+ </style>
@@ -8,7 +8,7 @@
8
8
  <th>付款比例</th>
9
9
  <th>应收金额</th>
10
10
  <th>
11
- <button v-if="Vue.user.f_role_name.includes('付款预设-新增')" type="button" class="btn btn-primary" @click="$parent.$parent.showAdd()">新增</button>
11
+ <button v-if="$parent.$parent.showaddc" type="button" class="btn btn-primary" @click="$parent.$parent.showAdd()">新增</button>
12
12
  </th>
13
13
  </tr>
14
14
  </template>
@@ -28,8 +28,8 @@
28
28
  </td>
29
29
  <td style="text-align: center;">
30
30
  <nobr><font>
31
- <button v-if="Vue.user.f_role_name.includes('付款预设-修改')" type="button" class="btn btn-primary" @click="$parent.$parent.updateData(row)">修改</button>
32
- <button v-if="Vue.user.f_role_name.includes('付款预设-删除')" type="button" class="btn btn-primary" @click="$parent.$parent.delData(row)">删除</button>
31
+ <button v-if="$parent.$parent.showedit" type="button" class="btn btn-primary" @click="$parent.$parent.updateData(row)">修改</button>
32
+ <button v-if="$parent.$parent.showdel" type="button" class="btn btn-primary" @click="$parent.$parent.delData(row)">删除</button>
33
33
  </font></nobr>
34
34
  </td>
35
35
  </tr>
@@ -96,6 +96,7 @@
96
96
  </template>
97
97
  <script>
98
98
  import {HttpResetClass} from 'vue-client'
99
+ import Vue from 'vue'
99
100
 
100
101
  export default {
101
102
  title: '付款预设',
@@ -201,6 +202,17 @@ export default {
201
202
  ready () {
202
203
  this.payProjects = this.$appdata.getParam(this.selectdata.f_apply_type + '付款预设')
203
204
  this.search()
205
+ },
206
+ computed: {
207
+ showaddc () {
208
+ return Vue.user.f_role_name.includes('付款预设-新增')
209
+ },
210
+ showedit () {
211
+ return Vue.user.f_role_name.includes('付款预设-修改')
212
+ },
213
+ showdel () {
214
+ return Vue.user.f_role_name.includes('付款预设-删除')
215
+ }
204
216
  }
205
217
  }
206
218
  </script>