manage-client 3.2.72 → 3.2.75
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/.babelrc +5 -5
- package/.classpath +6 -6
- package/.editorconfig +9 -9
- package/.gradle/4.4/fileHashes/fileHashes.bin +0 -0
- package/.gradle/4.4/fileHashes/fileHashes.lock +0 -0
- package/.project +18 -18
- package/README.md +38 -38
- package/build/dev-server.js +176 -176
- package/config/dev.env.js +6 -6
- package/config/prod.env.js +3 -3
- package/config/test.env.js +6 -6
- package/package.json +1 -1
- package/release.bat +5 -5
- package/src/components/MeterManage/ChangeMeterQuery.vue +82 -82
- package/src/components/MeterManage/HandQuery.vue +72 -72
- package/src/components/MeterManage/ReversalQuery.vue +77 -77
- package/src/components/SellReport/GaspriceHas.vue +141 -141
- package/src/components/SellReport/ManageBusSummary.vue +224 -219
- package/src/components/WebReport/AbnormalInfoEcharts.vue +120 -120
- package/src/components/WebReport/Communication.vue +131 -131
- package/src/components/WebReport/CompanyUser.vue +79 -79
- package/src/components/WebReport/GaspriceHas.vue +141 -141
- package/src/components/WebReport/ReportWorklist.vue +220 -220
- package/src/components/WebReport/SellType.vue +89 -89
- package/src/components/WebReport/Telemanlist.vue +221 -221
- package/src/components/WebReport/UserGasEcharts.vue +107 -107
- package/src/components/WebReport/ValueEcharts.vue +99 -99
- package/src/components/sale/businessquery/HandplanQuery.vue +91 -61
- package/src/components/sale/config/DefaultPrint.js +6 -6
- package/src/components/sale/config/exportConfig.js +1 -1
- package/src/components/sale/filesquery/detail/oper/ChangeMessage.vue +46 -46
- package/src/components/sale/filesquery/detail/oper/HandOper.vue +46 -46
- package/src/components/sale/filesquery/detail/oper/HandleMessage.vue +46 -46
- package/src/components/webmeter/gasAnalysis/GasAnalysisEcharts.vue +144 -144
- package/src/components/webmeter/gasAnalysis/GasAnalysisSummary.vue +162 -162
- package/src/components/webmeter/instruction/NewQueryInstruct.vue +6 -0
- package/src/components/webmeter/newwebmeter/NewException/NewExceptionEform.vue +149 -149
- package/src/filiale/liaoyuan/sale.js +0 -2
- package/src/filiale/macheng/RecordInfoQuery.vue +1023 -1023
- package/src/filiale/tongchuan/UserQuery.vue +26 -0
- package/src/main.js +66 -66
- package/src/plugins/LodopFuncs.js +124 -124
- package/src/stores/GetParames.js +15 -15
- package/src/stores/Util.js +132 -132
- package/test/unit/.eslintrc +5 -5
- package/test/unit/TestUtil.js +35 -35
- package/test/unit/context.html +20 -20
- package/test/unit/index.js +13 -13
- package/test/unit/init.js +11 -11
- package/test/unit/karma.conf.js +45 -45
- package/test/unit/specs/components/CallReport/Repair.spec.js +25 -25
- package/test/unit/specs/components/ManageBusiness/EquipmentQuery.spec.js +21 -21
- package/test/unit/specs/components/ManageBusiness/TableWithQuery.spec.js +21 -21
- package/test/unit/specs/components/ManageBusiness/UserQuery.spec.js +21 -21
- package/src/filiale/liaoyuan/GasInspection.vue +0 -572
package/src/stores/Util.js
CHANGED
|
@@ -1,132 +1,132 @@
|
|
|
1
|
-
import Vue from 'vue'
|
|
2
|
-
|
|
3
|
-
// 获取当前具体时间
|
|
4
|
-
export function getStandardDatetime () {
|
|
5
|
-
var now = new Date()
|
|
6
|
-
var year = now.getFullYear()
|
|
7
|
-
var month = now.getMonth() + 1
|
|
8
|
-
if (month < 10) {
|
|
9
|
-
month = '0' + month
|
|
10
|
-
}
|
|
11
|
-
var date1 = now.getDate()
|
|
12
|
-
if (date1 < 10) {
|
|
13
|
-
date1 = '0' + date1
|
|
14
|
-
}
|
|
15
|
-
var hour = now.getHours()
|
|
16
|
-
if (hour < 10) {
|
|
17
|
-
hour = '0' + hour
|
|
18
|
-
}
|
|
19
|
-
var min = now.getMinutes()
|
|
20
|
-
if (min < 10) {
|
|
21
|
-
min = '0' + min
|
|
22
|
-
}
|
|
23
|
-
var second = now.getSeconds()
|
|
24
|
-
if (second < 10) {
|
|
25
|
-
second = '0' + second
|
|
26
|
-
}
|
|
27
|
-
var Z = year + '-' + month + '-' + date1 + ' ' + hour + ':' + min + ':' + second
|
|
28
|
-
return Z
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
export function toStandardDateString () {
|
|
32
|
-
let dt = new Date()
|
|
33
|
-
let month = dt.getMonth() + 1
|
|
34
|
-
let date = dt.getDate()
|
|
35
|
-
return dt.getFullYear() + '-' + (month < 10 ? '0' + month : month) + '-' + (date < 10 ? '0' + date : date)
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
export function toStandardTimeString () {
|
|
39
|
-
let dt = new Date()
|
|
40
|
-
let month = dt.getMonth() + 1
|
|
41
|
-
let date = dt.getDate()
|
|
42
|
-
let hour = dt.getHours()
|
|
43
|
-
let min = dt.getMinutes()
|
|
44
|
-
let sec = dt.getSeconds()
|
|
45
|
-
return dt.getFullYear() + '-' + (month < 10 ? '0' + month : month) + '-' + (date < 10 ? '0' + date : date) + ' ' + (hour < 10 ? '0' + hour : hour) + ':' + (min < 10 ? '0' + min : min) + ':' + (sec < 10 ? '0' + sec : sec)
|
|
46
|
-
}
|
|
47
|
-
export function toStandardTimeStrings (dt) {
|
|
48
|
-
let month = dt.getMonth() + 1
|
|
49
|
-
let date = dt.getDate()
|
|
50
|
-
let hour = dt.getHours()
|
|
51
|
-
let min = dt.getMinutes()
|
|
52
|
-
let sec = dt.getSeconds()
|
|
53
|
-
return dt.getFullYear() + '-' + (month < 10 ? '0' + month : month) + '-' + (date < 10 ? '0' + date : date) + ' ' + (hour < 10 ? '0' + hour : hour) + ':' + (min < 10 ? '0' + min : min) + ':' + (sec < 10 ? '0' + sec : sec)
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
export function booleanFilter (paper) {
|
|
57
|
-
for (let key in paper) {
|
|
58
|
-
if (key === 'f_waterheater' || key === 'f_closevalve' || key === 'f_wallhangboiler' || key === 'f_kitchen' || key === 'f_lndheating' || key === 'f_lndheating' || key === 'f_lndjiarelu' || key === 'f_lndfurnace' || key === 'f_welfareboiler' || key === 'f_welfarekitchen' || key === 'f_businboiler' || key === 'f_businkitchen' || key === 'f_jtprice' || key === 'f_dibaohu') {
|
|
59
|
-
if (!paper.hasOwnProperty(key)) {
|
|
60
|
-
continue
|
|
61
|
-
}
|
|
62
|
-
if (typeof paper[key] === 'object' && paper[key] != null) {
|
|
63
|
-
booleanFilter(paper[key])
|
|
64
|
-
} else {
|
|
65
|
-
if (paper[key] === 1 || paper[key] === 0) {
|
|
66
|
-
paper[key] = (paper[key] === 1)
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
}
|
|
70
|
-
}
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
export function reBooleanFilter (paper) {
|
|
74
|
-
for (let key in paper) {
|
|
75
|
-
console.log(key + ':' + paper[key])
|
|
76
|
-
if (!paper.hasOwnProperty(key)) {
|
|
77
|
-
continue
|
|
78
|
-
}
|
|
79
|
-
if (typeof paper[key] === 'object' && paper[key] != null) {
|
|
80
|
-
reBooleanFilter(paper[key])
|
|
81
|
-
} else {
|
|
82
|
-
if (paper[key] === true || paper[key] === false) {
|
|
83
|
-
paper[key] = (paper[key] === true ? 1 : 0)
|
|
84
|
-
}
|
|
85
|
-
}
|
|
86
|
-
}
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
export function guid () {
|
|
90
|
-
let buf = new Uint16Array(8)
|
|
91
|
-
window.crypto.getRandomValues(buf)
|
|
92
|
-
let S4 = function (num) {
|
|
93
|
-
let ret = num.toString(16)
|
|
94
|
-
while (ret.length < 4) {
|
|
95
|
-
ret = '0' + ret
|
|
96
|
-
}
|
|
97
|
-
return ret
|
|
98
|
-
}
|
|
99
|
-
return (S4(buf[0]) + S4(buf[1]) + S4(buf[2]) + S4(buf[3]) + S4(buf[4]) + S4(buf[5]) + S4(buf[6]) + S4(buf[7]))
|
|
100
|
-
}
|
|
101
|
-
|
|
102
|
-
// 通过地址栏的参数获取参数内容
|
|
103
|
-
export function getUrlParames (param) {
|
|
104
|
-
var query = window.location.search
|
|
105
|
-
var iLen = param.length
|
|
106
|
-
var iStart = query.indexOf(param)
|
|
107
|
-
if (iStart === -1) {
|
|
108
|
-
return ''
|
|
109
|
-
}
|
|
110
|
-
iStart += iLen + 1
|
|
111
|
-
var iEnd = query.indexOf('&', iStart)
|
|
112
|
-
if (iEnd === -1) {
|
|
113
|
-
return query.substring(iStart)
|
|
114
|
-
}
|
|
115
|
-
return query.substring(iStart, iEnd)
|
|
116
|
-
}
|
|
117
|
-
|
|
118
|
-
export function choices (param, hasBlank = false, blankHint = '请选择') {
|
|
119
|
-
let result = []
|
|
120
|
-
if (hasBlank) {
|
|
121
|
-
result.push({label: blankHint, value: null})
|
|
122
|
-
}
|
|
123
|
-
if (!Vue.param) {
|
|
124
|
-
result.push({label: 'aaa', value: 'bbb'})
|
|
125
|
-
} else {
|
|
126
|
-
let p = Vue.param[param]
|
|
127
|
-
p.forEach(function (item) {
|
|
128
|
-
result.push({label: item.name, value: item.name})
|
|
129
|
-
})
|
|
130
|
-
}
|
|
131
|
-
return result
|
|
132
|
-
}
|
|
1
|
+
import Vue from 'vue'
|
|
2
|
+
|
|
3
|
+
// 获取当前具体时间
|
|
4
|
+
export function getStandardDatetime () {
|
|
5
|
+
var now = new Date()
|
|
6
|
+
var year = now.getFullYear()
|
|
7
|
+
var month = now.getMonth() + 1
|
|
8
|
+
if (month < 10) {
|
|
9
|
+
month = '0' + month
|
|
10
|
+
}
|
|
11
|
+
var date1 = now.getDate()
|
|
12
|
+
if (date1 < 10) {
|
|
13
|
+
date1 = '0' + date1
|
|
14
|
+
}
|
|
15
|
+
var hour = now.getHours()
|
|
16
|
+
if (hour < 10) {
|
|
17
|
+
hour = '0' + hour
|
|
18
|
+
}
|
|
19
|
+
var min = now.getMinutes()
|
|
20
|
+
if (min < 10) {
|
|
21
|
+
min = '0' + min
|
|
22
|
+
}
|
|
23
|
+
var second = now.getSeconds()
|
|
24
|
+
if (second < 10) {
|
|
25
|
+
second = '0' + second
|
|
26
|
+
}
|
|
27
|
+
var Z = year + '-' + month + '-' + date1 + ' ' + hour + ':' + min + ':' + second
|
|
28
|
+
return Z
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
export function toStandardDateString () {
|
|
32
|
+
let dt = new Date()
|
|
33
|
+
let month = dt.getMonth() + 1
|
|
34
|
+
let date = dt.getDate()
|
|
35
|
+
return dt.getFullYear() + '-' + (month < 10 ? '0' + month : month) + '-' + (date < 10 ? '0' + date : date)
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export function toStandardTimeString () {
|
|
39
|
+
let dt = new Date()
|
|
40
|
+
let month = dt.getMonth() + 1
|
|
41
|
+
let date = dt.getDate()
|
|
42
|
+
let hour = dt.getHours()
|
|
43
|
+
let min = dt.getMinutes()
|
|
44
|
+
let sec = dt.getSeconds()
|
|
45
|
+
return dt.getFullYear() + '-' + (month < 10 ? '0' + month : month) + '-' + (date < 10 ? '0' + date : date) + ' ' + (hour < 10 ? '0' + hour : hour) + ':' + (min < 10 ? '0' + min : min) + ':' + (sec < 10 ? '0' + sec : sec)
|
|
46
|
+
}
|
|
47
|
+
export function toStandardTimeStrings (dt) {
|
|
48
|
+
let month = dt.getMonth() + 1
|
|
49
|
+
let date = dt.getDate()
|
|
50
|
+
let hour = dt.getHours()
|
|
51
|
+
let min = dt.getMinutes()
|
|
52
|
+
let sec = dt.getSeconds()
|
|
53
|
+
return dt.getFullYear() + '-' + (month < 10 ? '0' + month : month) + '-' + (date < 10 ? '0' + date : date) + ' ' + (hour < 10 ? '0' + hour : hour) + ':' + (min < 10 ? '0' + min : min) + ':' + (sec < 10 ? '0' + sec : sec)
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
export function booleanFilter (paper) {
|
|
57
|
+
for (let key in paper) {
|
|
58
|
+
if (key === 'f_waterheater' || key === 'f_closevalve' || key === 'f_wallhangboiler' || key === 'f_kitchen' || key === 'f_lndheating' || key === 'f_lndheating' || key === 'f_lndjiarelu' || key === 'f_lndfurnace' || key === 'f_welfareboiler' || key === 'f_welfarekitchen' || key === 'f_businboiler' || key === 'f_businkitchen' || key === 'f_jtprice' || key === 'f_dibaohu') {
|
|
59
|
+
if (!paper.hasOwnProperty(key)) {
|
|
60
|
+
continue
|
|
61
|
+
}
|
|
62
|
+
if (typeof paper[key] === 'object' && paper[key] != null) {
|
|
63
|
+
booleanFilter(paper[key])
|
|
64
|
+
} else {
|
|
65
|
+
if (paper[key] === 1 || paper[key] === 0) {
|
|
66
|
+
paper[key] = (paper[key] === 1)
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
export function reBooleanFilter (paper) {
|
|
74
|
+
for (let key in paper) {
|
|
75
|
+
console.log(key + ':' + paper[key])
|
|
76
|
+
if (!paper.hasOwnProperty(key)) {
|
|
77
|
+
continue
|
|
78
|
+
}
|
|
79
|
+
if (typeof paper[key] === 'object' && paper[key] != null) {
|
|
80
|
+
reBooleanFilter(paper[key])
|
|
81
|
+
} else {
|
|
82
|
+
if (paper[key] === true || paper[key] === false) {
|
|
83
|
+
paper[key] = (paper[key] === true ? 1 : 0)
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
export function guid () {
|
|
90
|
+
let buf = new Uint16Array(8)
|
|
91
|
+
window.crypto.getRandomValues(buf)
|
|
92
|
+
let S4 = function (num) {
|
|
93
|
+
let ret = num.toString(16)
|
|
94
|
+
while (ret.length < 4) {
|
|
95
|
+
ret = '0' + ret
|
|
96
|
+
}
|
|
97
|
+
return ret
|
|
98
|
+
}
|
|
99
|
+
return (S4(buf[0]) + S4(buf[1]) + S4(buf[2]) + S4(buf[3]) + S4(buf[4]) + S4(buf[5]) + S4(buf[6]) + S4(buf[7]))
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
// 通过地址栏的参数获取参数内容
|
|
103
|
+
export function getUrlParames (param) {
|
|
104
|
+
var query = window.location.search
|
|
105
|
+
var iLen = param.length
|
|
106
|
+
var iStart = query.indexOf(param)
|
|
107
|
+
if (iStart === -1) {
|
|
108
|
+
return ''
|
|
109
|
+
}
|
|
110
|
+
iStart += iLen + 1
|
|
111
|
+
var iEnd = query.indexOf('&', iStart)
|
|
112
|
+
if (iEnd === -1) {
|
|
113
|
+
return query.substring(iStart)
|
|
114
|
+
}
|
|
115
|
+
return query.substring(iStart, iEnd)
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
export function choices (param, hasBlank = false, blankHint = '请选择') {
|
|
119
|
+
let result = []
|
|
120
|
+
if (hasBlank) {
|
|
121
|
+
result.push({label: blankHint, value: null})
|
|
122
|
+
}
|
|
123
|
+
if (!Vue.param) {
|
|
124
|
+
result.push({label: 'aaa', value: 'bbb'})
|
|
125
|
+
} else {
|
|
126
|
+
let p = Vue.param[param]
|
|
127
|
+
p.forEach(function (item) {
|
|
128
|
+
result.push({label: item.name, value: item.name})
|
|
129
|
+
})
|
|
130
|
+
}
|
|
131
|
+
return result
|
|
132
|
+
}
|
package/test/unit/.eslintrc
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
{
|
|
2
|
-
"env": {
|
|
3
|
-
"jasmine": true
|
|
4
|
-
}
|
|
5
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"env": {
|
|
3
|
+
"jasmine": true
|
|
4
|
+
}
|
|
5
|
+
}
|
package/test/unit/TestUtil.js
CHANGED
|
@@ -1,35 +1,35 @@
|
|
|
1
|
-
import Vue from 'vue'
|
|
2
|
-
|
|
3
|
-
let id = 0
|
|
4
|
-
|
|
5
|
-
const createElm = function () {
|
|
6
|
-
const elm = document.createElement('div')
|
|
7
|
-
|
|
8
|
-
elm.id = 'app' + ++id
|
|
9
|
-
document.body.appendChild(elm)
|
|
10
|
-
|
|
11
|
-
return elm
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
export default {
|
|
15
|
-
// 创建一个测试组件
|
|
16
|
-
createTest: function (name, props) {
|
|
17
|
-
const template = '<div>' + '<' + name + ' v-ref:child></' + name + '></div>'
|
|
18
|
-
const elm = createElm()
|
|
19
|
-
const comp = new Vue({
|
|
20
|
-
template: template
|
|
21
|
-
})
|
|
22
|
-
comp.$mount(elm)
|
|
23
|
-
const vm = comp.$refs.child
|
|
24
|
-
Object.assign(vm, props)
|
|
25
|
-
return vm
|
|
26
|
-
},
|
|
27
|
-
|
|
28
|
-
// 删除一个组件
|
|
29
|
-
destroyVM: function (vm) {
|
|
30
|
-
vm.$destroy && vm.$destroy()
|
|
31
|
-
vm.$el &&
|
|
32
|
-
vm.$el.parentNode &&
|
|
33
|
-
vm.$el.parentNode.removeChild(vm.$el)
|
|
34
|
-
}
|
|
35
|
-
}
|
|
1
|
+
import Vue from 'vue'
|
|
2
|
+
|
|
3
|
+
let id = 0
|
|
4
|
+
|
|
5
|
+
const createElm = function () {
|
|
6
|
+
const elm = document.createElement('div')
|
|
7
|
+
|
|
8
|
+
elm.id = 'app' + ++id
|
|
9
|
+
document.body.appendChild(elm)
|
|
10
|
+
|
|
11
|
+
return elm
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
export default {
|
|
15
|
+
// 创建一个测试组件
|
|
16
|
+
createTest: function (name, props) {
|
|
17
|
+
const template = '<div>' + '<' + name + ' v-ref:child></' + name + '></div>'
|
|
18
|
+
const elm = createElm()
|
|
19
|
+
const comp = new Vue({
|
|
20
|
+
template: template
|
|
21
|
+
})
|
|
22
|
+
comp.$mount(elm)
|
|
23
|
+
const vm = comp.$refs.child
|
|
24
|
+
Object.assign(vm, props)
|
|
25
|
+
return vm
|
|
26
|
+
},
|
|
27
|
+
|
|
28
|
+
// 删除一个组件
|
|
29
|
+
destroyVM: function (vm) {
|
|
30
|
+
vm.$destroy && vm.$destroy()
|
|
31
|
+
vm.$el &&
|
|
32
|
+
vm.$el.parentNode &&
|
|
33
|
+
vm.$el.parentNode.removeChild(vm.$el)
|
|
34
|
+
}
|
|
35
|
+
}
|
package/test/unit/context.html
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
<!DOCTYPE html>
|
|
2
|
-
<html lang="zh-CN">
|
|
3
|
-
<head>
|
|
4
|
-
<meta charset="utf-8">
|
|
5
|
-
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
|
|
6
|
-
<meta name="referrer" content="never">
|
|
7
|
-
<title>呼叫系统</title>
|
|
8
|
-
<link rel="stylesheet" href="http://cache.amap.com/lbs/static/main1119.css"/>
|
|
9
|
-
<script type="text/javascript" src="http://webapi.amap.com/maps?v=1.4.3&key=4889f1e58df01cb40415536c8907bf64&plugin=AMap.Autocomplete,AMap.PlaceSearch"></script>
|
|
10
|
-
<script type="text/javascript" src="http://cache.amap.com/lbs/static/addToolbar.js"></script>
|
|
11
|
-
<style media="screen">
|
|
12
|
-
/*url(./static/newmainbg.jpg)*/
|
|
13
|
-
body{width: 100%;background:#7f8eaf no-repeat center bottom; background-size: cover;}
|
|
14
|
-
body .loginbg{ width:100%; height:100%; background:url(./static/loginbg.jpg) no-repeat center top;}
|
|
15
|
-
</style>
|
|
16
|
-
</head>
|
|
17
|
-
<body>
|
|
18
|
-
测试2
|
|
19
|
-
</body>
|
|
20
|
-
</html>
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html lang="zh-CN">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="utf-8">
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
|
|
6
|
+
<meta name="referrer" content="never">
|
|
7
|
+
<title>呼叫系统</title>
|
|
8
|
+
<link rel="stylesheet" href="http://cache.amap.com/lbs/static/main1119.css"/>
|
|
9
|
+
<script type="text/javascript" src="http://webapi.amap.com/maps?v=1.4.3&key=4889f1e58df01cb40415536c8907bf64&plugin=AMap.Autocomplete,AMap.PlaceSearch"></script>
|
|
10
|
+
<script type="text/javascript" src="http://cache.amap.com/lbs/static/addToolbar.js"></script>
|
|
11
|
+
<style media="screen">
|
|
12
|
+
/*url(./static/newmainbg.jpg)*/
|
|
13
|
+
body{width: 100%;background:#7f8eaf no-repeat center bottom; background-size: cover;}
|
|
14
|
+
body .loginbg{ width:100%; height:100%; background:url(./static/loginbg.jpg) no-repeat center top;}
|
|
15
|
+
</style>
|
|
16
|
+
</head>
|
|
17
|
+
<body>
|
|
18
|
+
测试2
|
|
19
|
+
</body>
|
|
20
|
+
</html>
|
package/test/unit/index.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
// Polyfill fn.bind() for PhantomJS
|
|
2
|
-
/* eslint-disable no-extend-native */
|
|
3
|
-
Function.prototype.bind = require('function-bind')
|
|
4
|
-
|
|
5
|
-
// require all test files (files that ends with .spec.js)
|
|
6
|
-
var testsContext = require.context('./specs', true, /\.spec$/)
|
|
7
|
-
testsContext.keys().forEach(testsContext)
|
|
8
|
-
|
|
9
|
-
// require all src files except main.js for coverage.
|
|
10
|
-
// you can also change this to match only the subset of files that
|
|
11
|
-
// you want coverage for.
|
|
12
|
-
// var srcContext = require.context('../../src', true, /^\.\/(?!main(\.js)?$)/)
|
|
13
|
-
// srcContext.keys().forEach(srcContext)
|
|
1
|
+
// Polyfill fn.bind() for PhantomJS
|
|
2
|
+
/* eslint-disable no-extend-native */
|
|
3
|
+
Function.prototype.bind = require('function-bind')
|
|
4
|
+
|
|
5
|
+
// require all test files (files that ends with .spec.js)
|
|
6
|
+
var testsContext = require.context('./specs', true, /\.spec$/)
|
|
7
|
+
testsContext.keys().forEach(testsContext)
|
|
8
|
+
|
|
9
|
+
// require all src files except main.js for coverage.
|
|
10
|
+
// you can also change this to match only the subset of files that
|
|
11
|
+
// you want coverage for.
|
|
12
|
+
// var srcContext = require.context('../../src', true, /^\.\/(?!main(\.js)?$)/)
|
|
13
|
+
// srcContext.keys().forEach(srcContext)
|
package/test/unit/init.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import Vue from 'vue'
|
|
2
|
-
import { all } from 'vue-client'
|
|
3
|
-
import { system } from 'system-clients'
|
|
4
|
-
|
|
5
|
-
export default function () {
|
|
6
|
-
Vue.config.silent = false
|
|
7
|
-
|
|
8
|
-
all()
|
|
9
|
-
system()
|
|
10
|
-
require('../../src/bootstrap/less/bootstrap.less')
|
|
11
|
-
}
|
|
1
|
+
import Vue from 'vue'
|
|
2
|
+
import { all } from 'vue-client'
|
|
3
|
+
import { system } from 'system-clients'
|
|
4
|
+
|
|
5
|
+
export default function () {
|
|
6
|
+
Vue.config.silent = false
|
|
7
|
+
|
|
8
|
+
all()
|
|
9
|
+
system()
|
|
10
|
+
require('../../src/bootstrap/less/bootstrap.less')
|
|
11
|
+
}
|
package/test/unit/karma.conf.js
CHANGED
|
@@ -1,45 +1,45 @@
|
|
|
1
|
-
// This is a karma config file. For more details see
|
|
2
|
-
// http://karma-runner.github.io/0.13/config/configuration-file.html
|
|
3
|
-
// we are also using it with karma-webpack
|
|
4
|
-
// https://github.com/webpack/karma-webpack
|
|
5
|
-
|
|
6
|
-
var webpackConfig = require('../../build/webpack.test.conf')
|
|
7
|
-
|
|
8
|
-
module.exports = function (config) {
|
|
9
|
-
config.set({
|
|
10
|
-
// to run in additional browsers:
|
|
11
|
-
// 1. install corresponding karma launcher
|
|
12
|
-
// http://karma-runner.github.io/0.13/config/browsers.html
|
|
13
|
-
// 2. add it to the `browsers` array below.
|
|
14
|
-
browsers: ['Chrome_without_security'],
|
|
15
|
-
customLaunchers: {
|
|
16
|
-
Chrome_without_security: {
|
|
17
|
-
base: 'Chrome',
|
|
18
|
-
flags: ['--disable-web-security']
|
|
19
|
-
}
|
|
20
|
-
},
|
|
21
|
-
proxies: {
|
|
22
|
-
// '/rs': 'http://192.168.50.220:8300/rs',
|
|
23
|
-
'/rs': 'http://127.0.0.1:8084/rs',
|
|
24
|
-
},
|
|
25
|
-
|
|
26
|
-
autoWatch: true,
|
|
27
|
-
frameworks: ['mocha', 'sinon-chai'],
|
|
28
|
-
reporters: ['spec', 'coverage'],
|
|
29
|
-
files: ['./index.js'],
|
|
30
|
-
preprocessors: {
|
|
31
|
-
'./index.js': ['webpack', 'sourcemap']
|
|
32
|
-
},
|
|
33
|
-
webpack: webpackConfig,
|
|
34
|
-
webpackMiddleware: {
|
|
35
|
-
noInfo: true
|
|
36
|
-
},
|
|
37
|
-
coverageReporter: {
|
|
38
|
-
dir: './coverage',
|
|
39
|
-
reporters: [
|
|
40
|
-
{ type: 'lcov', subdir: '.' },
|
|
41
|
-
{ type: 'text-summary' }
|
|
42
|
-
]
|
|
43
|
-
}
|
|
44
|
-
})
|
|
45
|
-
}
|
|
1
|
+
// This is a karma config file. For more details see
|
|
2
|
+
// http://karma-runner.github.io/0.13/config/configuration-file.html
|
|
3
|
+
// we are also using it with karma-webpack
|
|
4
|
+
// https://github.com/webpack/karma-webpack
|
|
5
|
+
|
|
6
|
+
var webpackConfig = require('../../build/webpack.test.conf')
|
|
7
|
+
|
|
8
|
+
module.exports = function (config) {
|
|
9
|
+
config.set({
|
|
10
|
+
// to run in additional browsers:
|
|
11
|
+
// 1. install corresponding karma launcher
|
|
12
|
+
// http://karma-runner.github.io/0.13/config/browsers.html
|
|
13
|
+
// 2. add it to the `browsers` array below.
|
|
14
|
+
browsers: ['Chrome_without_security'],
|
|
15
|
+
customLaunchers: {
|
|
16
|
+
Chrome_without_security: {
|
|
17
|
+
base: 'Chrome',
|
|
18
|
+
flags: ['--disable-web-security']
|
|
19
|
+
}
|
|
20
|
+
},
|
|
21
|
+
proxies: {
|
|
22
|
+
// '/rs': 'http://192.168.50.220:8300/rs',
|
|
23
|
+
'/rs': 'http://127.0.0.1:8084/rs',
|
|
24
|
+
},
|
|
25
|
+
|
|
26
|
+
autoWatch: true,
|
|
27
|
+
frameworks: ['mocha', 'sinon-chai'],
|
|
28
|
+
reporters: ['spec', 'coverage'],
|
|
29
|
+
files: ['./index.js'],
|
|
30
|
+
preprocessors: {
|
|
31
|
+
'./index.js': ['webpack', 'sourcemap']
|
|
32
|
+
},
|
|
33
|
+
webpack: webpackConfig,
|
|
34
|
+
webpackMiddleware: {
|
|
35
|
+
noInfo: true
|
|
36
|
+
},
|
|
37
|
+
coverageReporter: {
|
|
38
|
+
dir: './coverage',
|
|
39
|
+
reporters: [
|
|
40
|
+
{ type: 'lcov', subdir: '.' },
|
|
41
|
+
{ type: 'text-summary' }
|
|
42
|
+
]
|
|
43
|
+
}
|
|
44
|
+
})
|
|
45
|
+
}
|
|
@@ -1,25 +1,25 @@
|
|
|
1
|
-
import init from 'test/unit/init'
|
|
2
|
-
import { TestUtil } from 'vue-client'
|
|
3
|
-
|
|
4
|
-
import Repair from 'src/components/CallReport/Repair'
|
|
5
|
-
|
|
6
|
-
describe('Repair: 维修员报表', () => {
|
|
7
|
-
let vm = null
|
|
8
|
-
before(() => {
|
|
9
|
-
init()
|
|
10
|
-
})
|
|
11
|
-
|
|
12
|
-
after(function () {
|
|
13
|
-
})
|
|
14
|
-
|
|
15
|
-
it('组件能够正确显示', () => {
|
|
16
|
-
vm = TestUtil.createTest(Repair, {})
|
|
17
|
-
console.log(vm.$el.innerText)
|
|
18
|
-
})
|
|
19
|
-
|
|
20
|
-
it('查询数据', async function() {
|
|
21
|
-
let model = {startDate: '2018-10-8', endDate: '2018-10-9', outlets: ['']}
|
|
22
|
-
await vm.model.search('1=1', model)
|
|
23
|
-
console.log(vm.$el.innerText)
|
|
24
|
-
})
|
|
25
|
-
})
|
|
1
|
+
import init from 'test/unit/init'
|
|
2
|
+
import { TestUtil } from 'vue-client'
|
|
3
|
+
|
|
4
|
+
import Repair from 'src/components/CallReport/Repair'
|
|
5
|
+
|
|
6
|
+
describe('Repair: 维修员报表', () => {
|
|
7
|
+
let vm = null
|
|
8
|
+
before(() => {
|
|
9
|
+
init()
|
|
10
|
+
})
|
|
11
|
+
|
|
12
|
+
after(function () {
|
|
13
|
+
})
|
|
14
|
+
|
|
15
|
+
it('组件能够正确显示', () => {
|
|
16
|
+
vm = TestUtil.createTest(Repair, {})
|
|
17
|
+
console.log(vm.$el.innerText)
|
|
18
|
+
})
|
|
19
|
+
|
|
20
|
+
it('查询数据', async function() {
|
|
21
|
+
let model = {startDate: '2018-10-8', endDate: '2018-10-9', outlets: ['']}
|
|
22
|
+
await vm.model.search('1=1', model)
|
|
23
|
+
console.log(vm.$el.innerText)
|
|
24
|
+
})
|
|
25
|
+
})
|
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
import Vue from 'vue'
|
|
2
|
-
import init from 'test/unit/init'
|
|
3
|
-
import { TestUtil } from 'vue-client'
|
|
4
|
-
|
|
5
|
-
import EquipmentQuery from 'src/components/ManageBusiness/EquipmentQuery'
|
|
6
|
-
|
|
7
|
-
describe('EquipmentQuery: 设备查询', () => {
|
|
8
|
-
let vm = null
|
|
9
|
-
before(() => {
|
|
10
|
-
init()
|
|
11
|
-
})
|
|
12
|
-
|
|
13
|
-
after(function () {
|
|
14
|
-
})
|
|
15
|
-
|
|
16
|
-
it('组件能够正确显示', async function() {
|
|
17
|
-
await Vue.$login.login('hainan', '1')
|
|
18
|
-
vm = await TestUtil.createAsyncTest(EquipmentQuery, {})
|
|
19
|
-
assert.include(vm.$el.innerText, '')
|
|
20
|
-
})
|
|
21
|
-
})
|
|
1
|
+
import Vue from 'vue'
|
|
2
|
+
import init from 'test/unit/init'
|
|
3
|
+
import { TestUtil } from 'vue-client'
|
|
4
|
+
|
|
5
|
+
import EquipmentQuery from 'src/components/ManageBusiness/EquipmentQuery'
|
|
6
|
+
|
|
7
|
+
describe('EquipmentQuery: 设备查询', () => {
|
|
8
|
+
let vm = null
|
|
9
|
+
before(() => {
|
|
10
|
+
init()
|
|
11
|
+
})
|
|
12
|
+
|
|
13
|
+
after(function () {
|
|
14
|
+
})
|
|
15
|
+
|
|
16
|
+
it('组件能够正确显示', async function() {
|
|
17
|
+
await Vue.$login.login('hainan', '1')
|
|
18
|
+
vm = await TestUtil.createAsyncTest(EquipmentQuery, {})
|
|
19
|
+
assert.include(vm.$el.innerText, '')
|
|
20
|
+
})
|
|
21
|
+
})
|