educode_sales 1.0.3 → 1.0.5
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.
- checksums.yaml +4 -4
- data/app/controllers/educode_sales/businesses_controller.rb +1 -1
- data/app/controllers/educode_sales/invoices_controller.rb +219 -0
- data/app/controllers/educode_sales/money_plan_records_controller.rb +13 -0
- data/app/controllers/educode_sales/sale_trends_controller.rb +2 -2
- data/app/controllers/educode_sales/staffs_controller.rb +2 -2
- data/app/models/educode_sales/business.rb +4 -0
- data/app/models/educode_sales/invoice.rb +5 -0
- data/app/models/educode_sales/invoice_apply.rb +12 -0
- data/app/models/educode_sales/invoice_detail.rb +10 -0
- data/app/models/educode_sales/staff.rb +2 -0
- data/app/views/educode_sales/contracts/_list.html.erb +1 -1
- data/app/views/educode_sales/invoices/_apply_records.html.erb +276 -0
- data/app/views/educode_sales/invoices/apply.html.erb +443 -0
- data/app/views/educode_sales/invoices/apply_records.js.erb +1 -0
- data/app/views/educode_sales/invoices/apply_records.json.jbuilder +20 -0
- data/app/views/educode_sales/invoices/details.json.jbuilder +17 -0
- data/app/views/educode_sales/invoices/list.json.jbuilder +14 -0
- data/app/views/educode_sales/invoices/new.html.erb +177 -0
- data/app/views/educode_sales/invoices/sales_details.html.erb +88 -0
- data/app/views/educode_sales/invoices/sales_details.json.jbuilder +14 -0
- data/app/views/educode_sales/money_plan_records/_index.html.erb +35 -8
- data/app/views/educode_sales/money_plans/_index.html.erb +138 -169
- data/app/views/educode_sales/money_plans/list.html.erb +2 -1
- data/app/views/educode_sales/staffs/edit.html.erb +11 -3
- data/app/views/educode_sales/staffs/index.html.erb +6 -1
- data/app/views/educode_sales/staffs/index.json.jbuilder +2 -1
- data/app/views/educode_sales/staffs/new.html.erb +7 -2
- data/app/views/layouts/educode_sales/application.html.erb +245 -236
- data/config/routes.rb +16 -0
- data/db/migrate/20230531144834_create_educode_sales_invoice_applies.rb +25 -0
- data/db/migrate/20230601011835_create_educode_sales_invoices.rb +14 -0
- data/db/migrate/20230601011943_create_educode_sales_invoice_details.rb +20 -0
- data/lib/educode_sales/version.rb +1 -1
- metadata +19 -3
@@ -0,0 +1,88 @@
|
|
1
|
+
<div style="padding:30px">
|
2
|
+
<div id="invoice_sale_detail_table_wraper">
|
3
|
+
<table class="layui-hide" id="invoice_sale_detail_table" lay-filter="invoice_sale_detail_table"></table>
|
4
|
+
</div>
|
5
|
+
</div>
|
6
|
+
|
7
|
+
<script type="text/html" id="invoice_sale_toolbar">
|
8
|
+
<div class="layui-btn-container">
|
9
|
+
<button class="layui-btn layui-btn-sm" lay-event="select_product">选择销售明细</button>
|
10
|
+
</div>
|
11
|
+
</script>
|
12
|
+
<script>
|
13
|
+
layui.use(['form', 'table', 'upload', 'laytpl', 'request', 'selectInput'], function() {
|
14
|
+
var form = layui.form,
|
15
|
+
layer = layui.layer,
|
16
|
+
table = layui.table,
|
17
|
+
laytpl = layui.laytpl,
|
18
|
+
request = layui.request,
|
19
|
+
$ = layui.$;
|
20
|
+
form.render();
|
21
|
+
|
22
|
+
var cols_table = [
|
23
|
+
[{
|
24
|
+
type: 'radio',
|
25
|
+
fixed: true
|
26
|
+
}, {
|
27
|
+
field: 'id',
|
28
|
+
width: 60,
|
29
|
+
title: '序号',
|
30
|
+
}, {
|
31
|
+
field: 'name',
|
32
|
+
width: 120,
|
33
|
+
title: '产品名称',
|
34
|
+
}, {
|
35
|
+
field: 'specification',
|
36
|
+
width: 150,
|
37
|
+
title: '规格型号',
|
38
|
+
}, {
|
39
|
+
field: 'unit',
|
40
|
+
width: 150,
|
41
|
+
title: '单位',
|
42
|
+
}, {
|
43
|
+
field: 'num',
|
44
|
+
width: 150,
|
45
|
+
title: '数量',
|
46
|
+
}, {
|
47
|
+
field: 'price',
|
48
|
+
width: 150,
|
49
|
+
title: '单价',
|
50
|
+
}, {
|
51
|
+
field: 'amount',
|
52
|
+
width: 150,
|
53
|
+
title: '开票金额',
|
54
|
+
}, ]
|
55
|
+
]
|
56
|
+
|
57
|
+
var invoice_sale_detail_table = table.render({
|
58
|
+
elem: '#invoice_sale_detail_table',
|
59
|
+
url: '/missions/invoices/' + parent.business_id + '/sales_details',
|
60
|
+
autoSort: false,
|
61
|
+
title: '销售产品',
|
62
|
+
toolbar: '#invoice_sale_toolbar',
|
63
|
+
cols: cols_table,
|
64
|
+
limit: 20,
|
65
|
+
limits: [10, 15, 20, 30, 40, 50, 60, 70, 80, 90],
|
66
|
+
page: true,
|
67
|
+
skin: 'line',
|
68
|
+
});
|
69
|
+
|
70
|
+
|
71
|
+
table.on('toolbar(invoice_sale_detail_table)', function(obj) {
|
72
|
+
var id = obj.config.id;
|
73
|
+
if (obj.event == 'select_product') {
|
74
|
+
var data = table.getData('invoices_details_table')
|
75
|
+
|
76
|
+
var checkStatus = table.checkStatus(id);
|
77
|
+
var row = checkStatus.data;
|
78
|
+
row[0].category = ''
|
79
|
+
data.push(row[0])
|
80
|
+
table.reload('invoices_details_table', {data: data })
|
81
|
+
parent.calAmount()
|
82
|
+
layer.close(parent.deteilIndex)
|
83
|
+
|
84
|
+
}
|
85
|
+
})
|
86
|
+
|
87
|
+
});
|
88
|
+
</script>
|
@@ -0,0 +1,14 @@
|
|
1
|
+
json.data do
|
2
|
+
json.array! @data do |d|
|
3
|
+
json.id d.id
|
4
|
+
json.specification d.product_catalog.specification
|
5
|
+
json.unit d.product_catalog.unit
|
6
|
+
json.num d.amount
|
7
|
+
json.price d.price
|
8
|
+
json.amount d.total_price || 0
|
9
|
+
json.name d.product_catalog.name
|
10
|
+
end
|
11
|
+
end
|
12
|
+
|
13
|
+
json.code 0
|
14
|
+
json.count @data.total_count
|
@@ -37,6 +37,7 @@
|
|
37
37
|
</form>
|
38
38
|
</div>
|
39
39
|
<script type="text/html" id="toolbar_money_plan_record">
|
40
|
+
<button class="layui-btn layui-btn-normal layui-btn-sm data-add-btn pull-right" id="upload_money_plan_btn" style="margin-left: 20px;">批量导入回款计划</button>
|
40
41
|
<button class="layui-btn layui-btn-normal layui-btn-sm data-add-btn pull-right" style="margin-left: 20px;"
|
41
42
|
lay-event="add_record">添加回款记录</button>
|
42
43
|
</script>
|
@@ -53,10 +54,11 @@
|
|
53
54
|
</script>
|
54
55
|
|
55
56
|
<script>
|
56
|
-
layui.use(['form', 'table', 'miniPage', 'element', 'request'], function() {
|
57
|
+
layui.use(['form', 'table', 'miniPage', 'element', 'request', 'upload'], function() {
|
57
58
|
var $ = layui.jquery,
|
58
59
|
form = layui.form,
|
59
60
|
request = layui.request,
|
61
|
+
upload = layui.upload,
|
60
62
|
miniPage = layui.miniPage;
|
61
63
|
laydate = layui.laydate;
|
62
64
|
table = layui.table;
|
@@ -70,11 +72,6 @@
|
|
70
72
|
url: '/missions/money_plan_records',
|
71
73
|
toolbar: '#toolbar_money_plan_record',
|
72
74
|
defaultToolbar: ['filter'],
|
73
|
-
initSort: {
|
74
|
-
field: 'date_at' //排序字段,对应 cols 设定的各字段名
|
75
|
-
,
|
76
|
-
type: 'desc' //排序方式 asc: 升序、desc: 降序、null: 默认排序
|
77
|
-
},
|
78
75
|
cols: [
|
79
76
|
[{
|
80
77
|
field: 'id',
|
@@ -95,7 +92,8 @@
|
|
95
92
|
{
|
96
93
|
field: 'date_at',
|
97
94
|
width: 180,
|
98
|
-
title: '回款日期'
|
95
|
+
title: '回款日期',
|
96
|
+
sort: true
|
99
97
|
},
|
100
98
|
{
|
101
99
|
field: 'business',
|
@@ -128,7 +126,10 @@
|
|
128
126
|
],
|
129
127
|
limit: 20,
|
130
128
|
limits: [10, 15, 20, 30, 40, 50, 60, 70, 80, 90],
|
131
|
-
page: true
|
129
|
+
page: true,
|
130
|
+
done: function() {
|
131
|
+
uploadMoneyPlan()
|
132
|
+
}
|
132
133
|
});
|
133
134
|
var sort = {},
|
134
135
|
search = {};
|
@@ -213,6 +214,32 @@
|
|
213
214
|
|
214
215
|
}
|
215
216
|
});
|
217
|
+
|
218
|
+
function uploadMoneyPlan() {
|
219
|
+
upload.render({
|
220
|
+
elem: '#upload_money_plan_btn',
|
221
|
+
url: '/missions/money_plan_records/upload',
|
222
|
+
accept: 'file' //普通文件
|
223
|
+
,
|
224
|
+
acceptMime: 'application/vnd.ms-excel,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet,application/vnd.ms-excel,application/vnd.ms-excel',
|
225
|
+
headers: {
|
226
|
+
'X-CSRF-Token': $('meta[name=csrf-token]').attr('content')
|
227
|
+
},
|
228
|
+
before: function(obj) {
|
229
|
+
layer.load();
|
230
|
+
},
|
231
|
+
done: function(res) {
|
232
|
+
layer.msg('导入成功');
|
233
|
+
table.reload('money_plan_record_table');
|
234
|
+
layer.closeAll('loading'); //关闭loading
|
235
|
+
},
|
236
|
+
error: function(index, upload) {
|
237
|
+
table.reload('file');
|
238
|
+
layer.closeAll('loading'); //关闭loading
|
239
|
+
layer.alert('导入失败,文件导入内容列表顺序为:付款单位、回款金额、回款日期、合同编号')
|
240
|
+
}
|
241
|
+
});
|
242
|
+
}
|
216
243
|
});
|
217
244
|
</script>
|
218
245
|
<style>
|
@@ -1,47 +1,44 @@
|
|
1
1
|
<div style="margin: 10px 10px 10px 10px" id="money_plan_list">
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
2
|
+
<form class="layui-form layui-form-pane" lay-filter="search_plans">
|
3
|
+
<div class="layui-form-item">
|
4
|
+
<div class="layui-inline">
|
5
|
+
<label class="layui-form-label">合同名称</label>
|
6
|
+
<div class="layui-input-inline">
|
7
|
+
<input type="text" name="business" class="layui-input">
|
8
|
+
</div>
|
9
|
+
</div>
|
10
|
+
<div class="layui-inline">
|
11
|
+
<label class="layui-form-label">客户名称</label>
|
12
|
+
<div class="layui-input-inline">
|
13
|
+
<input type="text" name="school" class="layui-input">
|
14
|
+
</div>
|
15
|
+
</div>
|
16
|
+
<div class="layui-inline">
|
17
|
+
<button type="reset" class="layui-btn layui-btn-primary" lay-submit lay-filter="reset_business_search">重置
|
18
18
|
</button>
|
19
|
-
|
19
|
+
<button type="submit" class="layui-btn layui-btn-primary" id="search_bt" lay-submit lay-filter="search_teachers">搜 索
|
20
20
|
</button>
|
21
|
-
|
22
|
-
|
23
|
-
|
21
|
+
</div>
|
22
|
+
</div>
|
23
|
+
</form>
|
24
24
|
</div>
|
25
25
|
<script type="text/html" id="toolbar_money_plan">
|
26
|
-
|
26
|
+
<button class="layui-btn layui-btn-normal layui-btn-sm data-add-btn pull-right" style="margin-left: 20px;" lay-event="addMoney">添加回款计划</button>
|
27
27
|
</script>
|
28
28
|
|
29
29
|
<table class="layui-hide" id="money_plan_table" lay-filter="money_plan_table"></table>
|
30
30
|
|
31
|
-
|
32
|
-
|
33
31
|
<script type="text/html" id="school">
|
34
|
-
|
32
|
+
<a href="<%= base_url%>/colleges/{{d.school_id}}/statistics" class="layui-table-link" target="_blank">{{ d.school }}</a>
|
35
33
|
</script>
|
36
|
-
|
37
34
|
<script type="text/html" id="currentTableBarmoney_plan">
|
38
|
-
|
39
|
-
|
40
|
-
|
35
|
+
<a class="layui-btn layui-btn-normal layui-btn-xs data-count-edit" lay-event="apply">开票申请</a>
|
36
|
+
<!-- <a class="layui-btn layui-btn-normal layui-btn-xs data-count-edit" lay-event="edit">催款提醒</a> -->
|
37
|
+
|
41
38
|
</script>
|
42
39
|
|
43
40
|
<script>
|
44
|
-
layui.use(['form', 'table', 'miniPage', 'element', 'request'], function
|
41
|
+
layui.use(['form', 'table', 'miniPage', 'element', 'request'], function() {
|
45
42
|
var $ = layui.jquery,
|
46
43
|
form = layui.form,
|
47
44
|
request = layui.request,
|
@@ -62,103 +59,88 @@
|
|
62
59
|
toolbar: '#toolbar_money_plan',
|
63
60
|
defaultToolbar: ['filter'],
|
64
61
|
initSort: {
|
65
|
-
field: 'date_at'
|
66
|
-
|
62
|
+
field: 'date_at',
|
63
|
+
type: 'desc' //排序方式 asc: 升序、desc: 降序、null: 默认排序
|
67
64
|
},
|
68
65
|
cols: [
|
69
|
-
[
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
field: 'stage',
|
133
|
-
width: 100,
|
134
|
-
title: '阶段',
|
135
|
-
},
|
136
|
-
{
|
137
|
-
field: 'accounts_state',
|
138
|
-
width: 150,
|
139
|
-
title: '应收款类型',
|
140
|
-
},
|
141
|
-
{
|
142
|
-
field: 'busireceipt_state',
|
143
|
-
width: 120,
|
144
|
-
title: '开票状态',
|
145
|
-
},
|
146
|
-
{
|
66
|
+
[{
|
67
|
+
field: 'id',
|
68
|
+
width: 80,
|
69
|
+
title: '序号',
|
70
|
+
type: 'numbers',
|
71
|
+
}, {
|
72
|
+
field: 'number',
|
73
|
+
width: 120,
|
74
|
+
title: '合同编号'
|
75
|
+
}, {
|
76
|
+
field: 'business_name',
|
77
|
+
width: 150,
|
78
|
+
title: '合同名称'
|
79
|
+
}, {
|
80
|
+
field: 'school',
|
81
|
+
width: 180,
|
82
|
+
title: '客户名称'
|
83
|
+
}, {
|
84
|
+
field: 'staff_manages',
|
85
|
+
width: 120,
|
86
|
+
title: '销售经理'
|
87
|
+
}, {
|
88
|
+
field: 'category',
|
89
|
+
width: 120,
|
90
|
+
title: '回款类别',
|
91
|
+
}, {
|
92
|
+
field: 'amount',
|
93
|
+
width: 120,
|
94
|
+
sort: true,
|
95
|
+
title: '金额',
|
96
|
+
}, {
|
97
|
+
field: 'rate',
|
98
|
+
width: 100,
|
99
|
+
title: '比例',
|
100
|
+
}, {
|
101
|
+
field: 'payment_clause',
|
102
|
+
width: 200,
|
103
|
+
title: '付款条款',
|
104
|
+
}, {
|
105
|
+
field: 'date_at',
|
106
|
+
width: 150,
|
107
|
+
title: '计划回款时间',
|
108
|
+
}, {
|
109
|
+
field: 'return_period',
|
110
|
+
width: 120,
|
111
|
+
title: '回款周期',
|
112
|
+
}, {
|
113
|
+
field: 'state',
|
114
|
+
width: 100,
|
115
|
+
title: '回款状态',
|
116
|
+
}, {
|
117
|
+
field: 'stage',
|
118
|
+
width: 100,
|
119
|
+
title: '阶段',
|
120
|
+
}, {
|
121
|
+
field: 'accounts_state',
|
122
|
+
width: 150,
|
123
|
+
title: '应收款类型',
|
124
|
+
}, {
|
125
|
+
field: 'busireceipt_state',
|
126
|
+
width: 120,
|
127
|
+
title: '开票状态',
|
128
|
+
}, {
|
147
129
|
title: '操作',
|
148
130
|
minWidth: 200,
|
149
131
|
toolbar: '#currentTableBarmoney_plan',
|
150
132
|
align: "center",
|
151
133
|
fixed: 'right'
|
152
|
-
|
153
|
-
]
|
134
|
+
}]
|
154
135
|
],
|
155
136
|
limit: 20,
|
156
|
-
limits: [10,15,20,30,40,50,60,70,80,90],
|
137
|
+
limits: [10, 15, 20, 30, 40, 50, 60, 70, 80, 90],
|
157
138
|
page: true
|
158
139
|
});
|
159
140
|
|
160
|
-
var sort = {},
|
161
|
-
|
141
|
+
var sort = {},
|
142
|
+
search = {};
|
143
|
+
table.on('sort(money_plan_table)', function(obj) {
|
162
144
|
sort.field = obj.field;
|
163
145
|
sort.order = obj.type;
|
164
146
|
table.reload('money_plan_table', {
|
@@ -171,18 +153,21 @@
|
|
171
153
|
})
|
172
154
|
|
173
155
|
// 监听搜索操作
|
174
|
-
form.on('submit(search_teachers)', function
|
156
|
+
form.on('submit(search_teachers)', function(data) {
|
175
157
|
search = data.field
|
176
158
|
table.reload('money_plan_table', {
|
177
159
|
page: {
|
178
160
|
curr: 1
|
179
161
|
},
|
180
|
-
where: {
|
162
|
+
where: {
|
163
|
+
q: search,
|
164
|
+
sort: sort
|
165
|
+
}
|
181
166
|
}, 'data');
|
182
167
|
return false;
|
183
168
|
});
|
184
169
|
|
185
|
-
form.on('submit(reset_business_search)', function
|
170
|
+
form.on('submit(reset_business_search)', function(data) {
|
186
171
|
var field = data.field;
|
187
172
|
form.val('search_teachers', {
|
188
173
|
area: "",
|
@@ -196,35 +181,12 @@
|
|
196
181
|
return false;
|
197
182
|
});
|
198
183
|
|
199
|
-
table.on('toolbar(money_plan_table)', function
|
200
|
-
|
201
|
-
|
202
|
-
var content = miniPage.getHrefContent('/missions/money_plans/add')
|
203
|
-
var openWH = miniPage.getOpenWidthHeight();
|
204
|
-
sindex = layer.open({
|
205
|
-
title: '添加回款计划',
|
206
|
-
type: 1,
|
207
|
-
shade: 0.2,
|
208
|
-
maxmin: true,
|
209
|
-
shadeClose: true,
|
210
|
-
area: [openWH[0] + 'px', openWH[1] + 'px'],
|
211
|
-
offset: [openWH[2] + 'px', openWH[3] + 'px'],
|
212
|
-
content: content
|
213
|
-
});
|
214
|
-
$(window).on("resize", function () {
|
215
|
-
layer.full(sindex);
|
216
|
-
});
|
217
|
-
}
|
218
|
-
})
|
219
|
-
|
220
|
-
table.on('tool(money_plan_table)', function (obj) {
|
221
|
-
var data = obj.data;
|
222
|
-
id = data.id
|
223
|
-
if (obj.event === 'add_money_plan') { // 监听添加操作
|
224
|
-
var content = miniPage.getHrefContent('/missions/businesses/show_follow_record?follow_up_id=' + data.id);
|
184
|
+
table.on('toolbar(money_plan_table)', function(obj) {
|
185
|
+
if (obj.event == 'addMoney') {
|
186
|
+
var content = miniPage.getHrefContent('/missions/money_plans/add')
|
225
187
|
var openWH = miniPage.getOpenWidthHeight();
|
226
|
-
|
227
|
-
title: '
|
188
|
+
sindex = layer.open({
|
189
|
+
title: '添加回款计划',
|
228
190
|
type: 1,
|
229
191
|
shade: 0.2,
|
230
192
|
maxmin: true,
|
@@ -233,17 +195,24 @@
|
|
233
195
|
offset: [openWH[2] + 'px', openWH[3] + 'px'],
|
234
196
|
content: content
|
235
197
|
});
|
236
|
-
$(window).on("resize", function
|
237
|
-
layer.full(
|
198
|
+
$(window).on("resize", function() {
|
199
|
+
layer.full(sindex);
|
238
200
|
});
|
239
|
-
}
|
240
|
-
|
241
|
-
|
242
|
-
|
243
|
-
|
244
|
-
|
245
|
-
|
246
|
-
|
201
|
+
}
|
202
|
+
})
|
203
|
+
|
204
|
+
table.on('tool(money_plan_table)', function(obj) {
|
205
|
+
var data = obj.data;
|
206
|
+
business_id = data.business_id + "";
|
207
|
+
business = [{
|
208
|
+
value: data.business_id + "",
|
209
|
+
name: data.business
|
210
|
+
}]
|
211
|
+
if (obj.event === 'apply') { // 监听添加操作
|
212
|
+
var content = miniPage.getHrefContent('/missions/invoices/apply?id=' + data.business_id);
|
213
|
+
var openWH = miniPage.getOpenWidthHeight();
|
214
|
+
sindex = layer.open({
|
215
|
+
title: '开票申请',
|
247
216
|
type: 1,
|
248
217
|
shade: 0.2,
|
249
218
|
maxmin: true,
|
@@ -252,8 +221,8 @@
|
|
252
221
|
offset: [openWH[2] + 'px', openWH[3] + 'px'],
|
253
222
|
content: content
|
254
223
|
});
|
255
|
-
$(window).on("resize", function
|
256
|
-
layer.full(
|
224
|
+
$(window).on("resize", function() {
|
225
|
+
layer.full(sindex);
|
257
226
|
});
|
258
227
|
}
|
259
228
|
});
|
@@ -261,16 +230,16 @@
|
|
261
230
|
});
|
262
231
|
</script>
|
263
232
|
<style>
|
264
|
-
|
265
|
-
|
266
|
-
|
267
|
-
|
268
|
-
|
269
|
-
|
270
|
-
|
271
|
-
|
272
|
-
|
273
|
-
|
274
|
-
|
275
|
-
|
233
|
+
.layui-table-tool-temp {
|
234
|
+
padding-right: 30px;
|
235
|
+
!important;
|
236
|
+
}
|
237
|
+
|
238
|
+
.layui-table-fixed .layui-table-body {
|
239
|
+
height: auto!important;
|
240
|
+
}
|
241
|
+
|
242
|
+
.layui-table-fixed.layui-hide {
|
243
|
+
display: block!important;
|
244
|
+
}
|
276
245
|
</style>
|
@@ -35,7 +35,8 @@
|
|
35
35
|
element.on('tab(money_plan_tab)', function(data) {
|
36
36
|
if (data.index == 1 && $("#money_plan_record").length == 0) {
|
37
37
|
loadPage('/missions/money_plan_records')
|
38
|
-
} else if (data.index == 2 && $("#
|
38
|
+
} else if (data.index == 2 && $("#invoice_apply").length == 0) {
|
39
|
+
loadPage('/missions/invoices/apply_records')
|
39
40
|
}
|
40
41
|
});
|
41
42
|
|
@@ -3,9 +3,17 @@
|
|
3
3
|
<form class="layui-form " action="">
|
4
4
|
<h4>编辑人员</h4>
|
5
5
|
<div class="layui-form-item">
|
6
|
-
<
|
7
|
-
|
8
|
-
|
6
|
+
<div class="layui-inline">
|
7
|
+
<label class="layui-form-label">用户名</label>
|
8
|
+
<div class="layui-input-inline" style="line-height: 38px;">
|
9
|
+
<%= "#{@staff.user.real_name} - #{@staff.user.phone}" %>
|
10
|
+
</div>
|
11
|
+
</div>
|
12
|
+
<div class="layui-inline">
|
13
|
+
<label class="layui-form-label">姓名</label>
|
14
|
+
<div class="layui-input-inline">
|
15
|
+
<input type="text" name="name" class="layui-input" value="<%= @staff.name %>">
|
16
|
+
</div>
|
9
17
|
</div>
|
10
18
|
</div>
|
11
19
|
<div class="layui-form-item">
|
@@ -2,7 +2,8 @@ area_ids = EducodeSales::Common.where(clazz: 'area').ids.sort.to_s
|
|
2
2
|
json.data do
|
3
3
|
json.array! @staffs do |d|
|
4
4
|
json.id d.id
|
5
|
-
json.
|
5
|
+
json.user_name d.user.real_name
|
6
|
+
json.name d.name
|
6
7
|
json.role d.role&.name
|
7
8
|
json.schools d.staff_schools.map(&:school).map(&:name).join("、")
|
8
9
|
json.job_type EducodeSales::Common.job_type_name[d.job_type]
|