zm
2020-04-12 0d659cff38f50d83e782a9f8c5c20fb54a5c0321
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
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
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
<title>系统设置</title>
<div class="system_cfg" id="system_config">
    <div class="bread_crumb">
            <i class="fa fa-home" ></i> 
            <i class="fa fa-angle-right" aria-hidden="true"></i> 
            <label>系统设置</label>
    </div>
    
    
    
    <div class="container form ">
        <ul id="myTab" class="col-md-8 nav nav-tabs">
           <li class="active"><a data-toggle="tab" style="cursor:pointer" ng-click="chang_show_flag(0)">
              系统设置</a></li>
           <li><a data-toggle="tab" style="cursor:pointer" ng-click="chang_show_flag(1)">系统变量</a></li>
        </ul>
        <div id="system_setting" ng-show="show_flag==0">
            
            <div class="row">
                <div class="col-md-8">
                    <div class="panel panel-default">
                        <div class="panel-heading">
                            <label>系统设置</label>
                        </div>
                        <div class="panel-heading {{!parseInt(cfg_data.budget.budget_open)  && 'collapse_heading'}}">
                            <label>是否启用预算单</label>
                            <img ng-src="{{parseInt(cfg_data.budget.budget_open)?'./static/img/switch_on.png':'./static/img/switch_off.png'}}" ng-click="toggle('cfg_data.budget.budget_open');">
                            <label>*(否,则无需针对其他相关参数设置)</label>
                        </div>
                        <!--<div class="panel-body" ng-if="parseInt(cfg_data.budget.budget_open)">
                            <table class="table table-bordered system_cfg_frm" >
                                <tbody>
                                    <tr>
                                        <td>启用预算类型</td>
                                        <td>
                                            <div >
                                                <span>
                                                    <input type="checkbox" value="0" ng-model="cfg_data.budget.budget_type[0]" >
                                                </span>
                                                <label>
                                                    部门预算
                                                </label>
                                            </div>
                                            <div>
                                                <span>
                                                    <input type="checkbox" value="1" ng-model="cfg_data.budget.budget_type[1]" >
                                                </span>
                                                <label>
                                                    项目预算
                                                </label>
                                            </div>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>预算管控方式</td>
                                        <td>
                                            <div>
                                                <span>
                                                    <input type="radio" value="0" ng-model="cfg_data.budget.budget_method" >
                                                </span>
                                                <label>
                                                    预警
                                                </label>
                                            </div>
                                            <div>
                                                <span>
                                                    <input type="radio" value="1" ng-model="cfg_data.budget.budget_method">
                                                </span>
                                                <label>
                                                    限制
                                                </label>
                                            </div>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>预算执行预警值</td>
                                        <td>
                                            <div>
                                                <span>
                                                    <input type="radio" value="ratio" ng-model="budget_ctrl_value.type" ng-disabled="cfg_data.budget.budget_method === '1'">
                                                </span>
                                                <label>
                                                    比例值 
                                                    <input 
                                                            type="text" 
                                                            ng-model="cfg_data.budget.budget_scale" 
                                                            ng-disabled="budget_ctrl_value.type === 'finger' || cfg_data.budget.budget_method === '1'"
                                                            ng-change="check_ratio_value();">
                                                </label>
                                                <label class="error" ng-if="cfg_data.budget.budget_scale && !ratio_val_match">比例值类型不合法, 请重新输入。</label>
                                            </div>
                                            <div>
                                                <span class="second_level" >
                                                    <input 
                                                            type="radio" 
                                                            value="finger" 
                                                            ng-model="budget_ctrl_value.type"
                                                            ng-disabled="cfg_data.budget.budget_method === '1'">
                                                </span>
                                                <label>
                                                    数值 
                                                    <input 
                                                            type="text" 
                                                            ng-model="cfg_data.budget.budget_amount"
                                                            ng-disabled="budget_ctrl_value.type === 'ratio' || cfg_data.budget.budget_method === '1'"
                                                            ng-change="check_finger_value();" >
                                                </label>
                                                <label class="error" ng-if="cfg_data.budget.budget_amount && !finger_val_match">数值类型不合法, 请重新输入。</label>
                                            </div>
                                        </td>
                                    </tr>
                                </tbody>
                            </table> 
                        </div>-->
                    </div>
                </div>
            </div>
    
            <div class="row">
                <div class="col-md-8">
                    <div class="panel panel-default">
                        <div class="panel-heading {{!parseInt(cfg_data.apply.apply_open)  && 'collapse_heading'}}">
                            <label>是否启用申请单</label>
                            <img ng-src="{{parseInt(cfg_data.apply.apply_open)?'./static/img/switch_on.png':'./static/img/switch_off.png'}}" ng-click="toggle('cfg_data.apply.apply_open');">
                            <label><!--*(否,则无需针对其他相关参数设置)--></label>
                        </div>
                        <!--<div class="panel-body" ng-if="parseInt(cfg_data.apply.apply_open)">
                            <table class="table table-bordered system_cfg_frm" >
                                <tbody>
                                    <tr>
                                        <td>启用申请工具模块的业务类型</td>
                                        <td>
                                            <div>
                                                <span>
                                                    <input type="checkbox" value="0" ng-model="cfg_data.apply.apply_type[0]" >
                                                </span>
                                                <label>
                                                    主数据带入
                                                </label>
                                            </div>
                                            <div>
                                                <span>
                                                    <input type="checkbox" value="1" ng-model="cfg_data.apply.apply_type[1]" >
                                                </span>
                                                <label>
                                                    参加业务类型集
                                                </label>
                                            </div>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>开始占用预算额度的审批节点</td>
                                        <td>
                                            <div>
                                                <span>
                                                    <input type="radio" value="0" ng-model="cfg_data.apply.apply_point">
                                                </span>
                                                <label>
                                                    申请环节第一审批人
                                                </label>
                                            </div>
                                            <div>
                                                <span>
                                                    <input type="radio" value="1" ng-model="cfg_data.apply.apply_point">
                                                </span>
                                                <label>
                                                    申请环节最后审批人
                                                </label>
                                            </div>
                                        </td>
                                    </tr>
                                </tbody>
                            </table> 
                        </div>-->
                    </div>
                </div>
            </div>
            <div class="row">
                <div class="col-md-8">
                    <div class="panel panel-default">
                        <div class="panel-heading {{!parseInt(cfg_data.expend.expend_open)  && 'collapse_heading'}}">
                            <label>是否启用报销管理模块</label>
                            <img src="{{parseInt(cfg_data.expend.expend_open)?'./static/img/switch_on.png':'./static/img/switch_off.png'}}" ng-click="toggle('cfg_data.expend.expend_open');">
                            <label><!--*(否,则无需针对其他相关参数设置)--></label>
                        </div>
                        <!--<div class="panel-body" ng-if="parseInt(cfg_data.expend.expend_open)">
                            <table class="table table-bordered system_cfg_frm " >
                                <tbody>
                                    <tr>
                                        <td>报销金额是否允许超过原申请单金额</td>
                                        <td>
                                            <div>
                                                <label style="text-align:center;">
                                                    是
                                                </label>
                                                <label>
                                                    <img 
                                                        ng-src="{{parseInt(cfg_data.expend.expend_over)?'./static/img/switch_on.png':'./static/img/switch_off.png'}}" 
                                                        ng-click="toggle('cfg_data.expend.expend_over');"
                                                    >
                                                </label>
                                                <label style="text-align:left;margin-left:-35px;">
                                                    否
                                                </label>
                                                <label>
                                                    *(逻辑管控点:超预算执行是否需要领导单独事项审批)
                                                </label>
                                            </div>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>报销金额小于等于原申请单金额情况下是否需要单独就报销事项再审批</td>
                                        <td>
                                            <div>
                                                 <label style="text-align:center;">
                                                    是
                                                </label>
                                                <label>
                                                    <img 
                                                        ng-src="{{parseInt(cfg_data.expend.expend_below)?'./static/img/switch_on.png':'./static/img/switch_off.png'}}" 
                                                        ng-click="toggle('cfg_data.expend.expend_below');"
                                                    >
                                                </label>
                                                <label style="text-align:left;margin-left:-35px;">
                                                    否
                                                </label>
                                                <label>
                                                    *(逻辑管控点:影响后续流程)
                                                </label>
                                            </div>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>是否允许白条报销</td>
                                        <td>
                                            <div>
                                                 <label style="text-align:center;">
                                                    是
                                                </label>
                                                <label>
                                                    <img 
                                                        ng-src="{{parseInt(cfg_data.expend.expend_free)?'./static/img/switch_on.png':'./static/img/switch_off.png'}}" 
                                                        ng-click="toggle('cfg_data.expend.expend_free');" 
                                                    >
                                                </label>
                                                <label style="text-align:left;margin-left:-35px;">
                                                    否
                                                </label>
                                                <label>
                                                        *(接口传递,费用系统检查)
                                                </label>
                                            </div>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>是否允许跨区域单据报销(单据显示地与业务发生地不一致的情况)</td>
                                        <td>
                                            <div>
                                                 <label style="text-align:center;">
                                                    是
                                                </label>
                                                <label>
                                                    <img 
                                                        ng-src="{{parseInt(cfg_data.expend.expend_cross)?'./static/img/switch_on.png':'./static/img/switch_off.png'}}" 
                                                        ng-click="toggle('cfg_data.expend.expend_cross');" 
                                                    >
                                                </label>
                                                <label style="text-align:left;margin-left:-35px;">
                                                    否
                                                </label>
                                                <label>
                                                    *(接口传递,费用系统检查)
                                                </label>
                                            </div>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>是否启用信息补录功能</td>
                                        <td>
                                            <div>   
                                                 <label style="text-align:center;">
                                                    是
                                                </label>
                                                <label>
                                                    <img 
                                                        ng-src="{{parseInt(cfg_data.expend.expend_supply)?'./static/img/switch_on.png':'./static/img/switch_off.png'}}" 
                                                        ng-click="toggle('cfg_data.expend.expend_supply');" 
                                                    >
                                                </label>
                                                <label style="text-align:left;margin-left:-35px;">
                                                    否
                                                </label>
                                                <label>
                                                    *(接口传递,费用系统检查)
                                                </label>
                                            </div>
                                        </td>
                                    </tr>
                                </tbody>
                            </table> 
                        </div>-->
                    </div>
                </div>
            </div>
            <div>
                <buttton class="save_btn btn btn-success btn-favourite" ng-click="refdata()">同步组织机构</buttton>
            </div>
        </div>
        <div id="system_variable" ng-show="show_flag==1">
            <div class="row">
                <div class="col-md-8">
                    <div class="panel panel-default">
                        <div class="panel-heading">
                            <label>系统变量</label>
                            <button ng-click="add_formula()" class="add_btn btn btn-success btn-favourite btn-action">新增</button>
                        </div>
                         <table class="table table-bordered system_cfg_frm" >
                                <tbody>
                                    <tr ng-repeat="formula in formulaList">
                                        <td>{{formula.name}}</td><td>{{formula.view}}</td><td><button ng-click="add_formula(formula)" class="btn btn-success btn-favourite btn-action">编辑</button> &nbsp;&nbsp;<button class="btn btn-success btn-favourite btn-action" ng-click="del_formula(formula)">删除</button></td>
                                   </tr>
                                </tbody>   
                        </table>
                    </div>
                </div>
            </div>
        </div>
        
        <div class="row" ng-show="show_flag==0">
            <div class="col-md-12">
                <button ng-show="permission_check('save_system')" class="save_btn btn btn-success btn-favourite" ng-click="save_system_cfg();" id="save_system">&nbsp;&nbsp;&nbsp;完成&nbsp;&nbsp;&nbsp;</button>
            </div>
        </div>
    </div>
</div>