|
|
@@ -195,84 +195,92 @@ function typePro(){
|
|
195
|
195
|
} else if($('#order_phone').val() == '') {
|
|
196
|
196
|
mui.alert('请输入客户电话!') //请输入客户姓名
|
|
197
|
197
|
}else {
|
|
198
|
|
- $.ajax({
|
|
199
|
|
- type: "post",
|
|
200
|
|
- dataType: 'json',
|
|
201
|
|
- url: huayi.config.callcenter_url + 'WxLogin/Add',
|
|
202
|
|
- beforeSend: function () {
|
|
203
|
|
- // 禁用按钮防止重复提交
|
|
204
|
|
- $("#submit").attr({ disabled: "disabled" });
|
|
205
|
|
- },
|
|
206
|
|
- async: true,
|
|
207
|
|
- data: {
|
|
208
|
|
-// F_State:0,
|
|
209
|
|
- F_WxOpenId: openid, //微信openid,
|
|
210
|
|
- F_Source: $('#order_source').attr('data-index'), //工单来源
|
|
211
|
|
- F_Type: $('.order_type').find('input[type="radio"]:checked').val(), //工单类型
|
|
212
|
|
- //公共字段
|
|
213
|
|
- F_CusName: $('#order_name').val(),//客户姓名
|
|
214
|
|
- F_CusPhone: $('#order_phone').val(),//客户电话
|
|
215
|
|
- F_CompanyName: $('#order_tel').val(),//公司名称
|
|
216
|
|
- F_IncidentProvince:$("#choworder_rengin").attr('data-index'), //省
|
|
217
|
|
- F_IncidentCity: $("#shouorder_shi").attr('data-index'), //市
|
|
218
|
|
- F_IncidentCountry:$("#chouorder_xian").attr('data-index'), //县
|
|
219
|
|
- F_IncidentTownship: $("#chouorder_xiang").attr('data-index'), //乡
|
|
220
|
|
- F_IncidentDetailed: $("#choworder_tower").val(), //详细地址
|
|
221
|
|
- F_Description:$("#order_reception").val(), //问题描述
|
|
222
|
|
- overtime:$('.overtime').find('input[type="radio"]:checked').val(),//超期时间
|
|
223
|
|
- sms:$('.sms').find('input[type="radio"]:checked').val(),//是否发送短信
|
|
224
|
|
- //咨询模块
|
|
225
|
|
- F_QuestionType:catt,//问题类别
|
|
226
|
|
- F_TS_Category: comdi,//产品名称
|
|
227
|
|
- F_ZX_Quantity:stion,//问题数量
|
|
228
|
|
- F_SalesBase:coint,//销售基地
|
|
229
|
|
- //投诉模块
|
|
230
|
|
- F_BatchNumber:shengch,//生产批号
|
|
231
|
|
-// F_TS_Formula: $('#formula').val(),//配方
|
|
232
|
|
- F_TS_Quantity:$("#order_Claimnu").val(), //问题数量 order_Claimnumber
|
|
233
|
|
-// F_TS_Level: $('#order_rank').val(),//重要界别
|
|
234
|
|
- F_SalesPhone: $('#telephone').val(),//电话
|
|
235
|
|
- F_ZX_Area: daqu,//大区
|
|
236
|
|
- F_ZX_Branch:fengo,//分公司
|
|
237
|
|
- F_Brand: jyppai,//经营品牌
|
|
238
|
|
- F_Salesman: $('#order_yewu').val(),//业务员
|
|
239
|
|
- F_MaterialID: $('#order_material').val(),//物料编码
|
|
240
|
|
- F_CustomerID: $('#order_coding').val(),//客户编号
|
|
241
|
|
- F_Model: $('#order_xinghao').val(),//型号
|
|
242
|
|
- F_Specs: $('#order_guige').val(),//规格
|
|
243
|
|
- F_Level1: $('#order_yiji').val(),//一级分类
|
|
244
|
|
- F_Level2: $('#order_erji').val(),//二级分类
|
|
245
|
|
- F_Level3: $('#order_sanji').val(),//三级分类
|
|
246
|
|
- F_MaterialEffect: $('#order_fuhefei').val(),//复合肥肥效
|
|
247
|
|
- F_Pipeline: $('#order_chanpinxian').val(),//产品线
|
|
248
|
|
- F_Craft: $('#order_gongyi').val(),//工艺
|
|
249
|
|
-
|
|
250
|
|
-
|
|
251
|
|
-
|
|
252
|
|
- //抽检模块
|
|
253
|
|
- F_CJ_Time: $('#order_time').val(),//抽检时间
|
|
254
|
|
- F_CJ_Level: $('#order_samplingle').val(), //抽检级别
|
|
255
|
|
- F_CJ_Unit: $('#order_lingunit').val(), //抽检单位
|
|
256
|
|
- F_CJ_TestUnit: $('#order_assay').val(),//化验单位
|
|
257
|
|
- F_CJ_Tonnage: $('#order_tunnage').val(),//抽检吨数
|
|
258
|
|
- F_CJ_BagNo: $('#order_algebra').val(),//抽检袋数
|
|
259
|
|
- F_CJ_Outlay: $('#order_money').val(),//公关费用金额
|
|
260
|
|
-// F_Source: $('#order_source').attr('data-index'), //工单来源
|
|
261
|
|
-// F_Type: $('.order_type').find('input[type="radio"]:checked').val(), //工单类型
|
|
262
|
|
- F_Files:str_ary
|
|
263
|
|
- },
|
|
264
|
|
- success: function(data) {
|
|
265
|
|
- if(data.state == "success") {
|
|
266
|
|
- debugger
|
|
267
|
|
- //alert($('#order_reception').val()), //描述详情
|
|
268
|
|
- mui.toast('创建成功');
|
|
269
|
|
- window.location.href = "Have_list.html";
|
|
270
|
|
- } else {
|
|
271
|
|
- mui.toast(data.message);
|
|
272
|
|
- $("#submit").removeAttr("disabled")
|
|
273
|
|
- }
|
|
274
|
|
- }
|
|
275
|
|
- });
|
|
|
198
|
+ var btnArray = ['否', '是'];
|
|
|
199
|
+ mui.confirm('确定提交吗?', '提示', btnArray, function(f) {
|
|
|
200
|
+ if(f.index == 1) {
|
|
|
201
|
+ $.ajax({
|
|
|
202
|
+ type: "post",
|
|
|
203
|
+ dataType: 'json',
|
|
|
204
|
+ url: huayi.config.callcenter_url + 'WxLogin/Add',
|
|
|
205
|
+ beforeSend: function () {
|
|
|
206
|
+ // 禁用按钮防止重复提交
|
|
|
207
|
+ $("#submit").attr({ disabled: "disabled" });
|
|
|
208
|
+ },
|
|
|
209
|
+ async: true,
|
|
|
210
|
+ data: {
|
|
|
211
|
+ // F_State:0,
|
|
|
212
|
+ F_WxOpenId: openid, //微信openid,
|
|
|
213
|
+ F_Source: $('#order_source').attr('data-index'), //工单来源
|
|
|
214
|
+ F_Type: $('.order_type').find('input[type="radio"]:checked').val(), //工单类型
|
|
|
215
|
+ //公共字段
|
|
|
216
|
+ F_CusName: $('#order_name').val(),//客户姓名
|
|
|
217
|
+ F_CusPhone: $('#order_phone').val(),//客户电话
|
|
|
218
|
+ F_CompanyName: $('#order_tel').val(),//公司名称
|
|
|
219
|
+ F_IncidentProvince:$("#choworder_rengin").attr('data-index'), //省
|
|
|
220
|
+ F_IncidentCity: $("#shouorder_shi").attr('data-index'), //市
|
|
|
221
|
+ F_IncidentCountry:$("#chouorder_xian").attr('data-index'), //县
|
|
|
222
|
+ F_IncidentTownship: $("#chouorder_xiang").attr('data-index'), //乡
|
|
|
223
|
+ F_IncidentDetailed: $("#choworder_tower").val(), //详细地址
|
|
|
224
|
+ F_Description:$("#order_reception").val(), //问题描述
|
|
|
225
|
+ overtime:$('.overtime').find('input[type="radio"]:checked').val(),//超期时间
|
|
|
226
|
+ sms:$('.sms').find('input[type="radio"]:checked').val(),//是否发送短信
|
|
|
227
|
+ //咨询模块
|
|
|
228
|
+ F_QuestionType:catt,//问题类别
|
|
|
229
|
+ F_TS_Category: comdi,//产品名称
|
|
|
230
|
+ F_ZX_Quantity:stion,//问题数量
|
|
|
231
|
+ F_SalesBase:coint,//销售基地
|
|
|
232
|
+ //投诉模块
|
|
|
233
|
+ F_BatchNumber:shengch,//生产批号
|
|
|
234
|
+ // F_TS_Formula: $('#formula').val(),//配方
|
|
|
235
|
+ F_TS_Quantity:$("#order_Claimnu").val(), //问题数量 order_Claimnumber
|
|
|
236
|
+ // F_TS_Level: $('#order_rank').val(),//重要界别
|
|
|
237
|
+ F_SalesPhone: $('#telephone').val(),//电话
|
|
|
238
|
+ F_ZX_Area: daqu,//大区
|
|
|
239
|
+ F_ZX_Branch:fengo,//分公司
|
|
|
240
|
+ F_Brand: jyppai,//经营品牌
|
|
|
241
|
+ F_Salesman: $('#order_yewu').val(),//业务员
|
|
|
242
|
+ F_MaterialID: $('#order_material').val(),//物料编码
|
|
|
243
|
+ F_CustomerID: $('#order_coding').val(),//客户编号
|
|
|
244
|
+ F_Model: $('#order_xinghao').val(),//型号
|
|
|
245
|
+ F_Specs: $('#order_guige').val(),//规格
|
|
|
246
|
+ F_Level1: $('#order_yiji').val(),//一级分类
|
|
|
247
|
+ F_Level2: $('#order_erji').val(),//二级分类
|
|
|
248
|
+ F_Level3: $('#order_sanji').val(),//三级分类
|
|
|
249
|
+ F_MaterialEffect: $('#order_fuhefei').val(),//复合肥肥效
|
|
|
250
|
+ F_Pipeline: $('#order_chanpinxian').val(),//产品线
|
|
|
251
|
+ F_Craft: $('#order_gongyi').val(),//工艺
|
|
|
252
|
+
|
|
|
253
|
+
|
|
|
254
|
+
|
|
|
255
|
+ //抽检模块
|
|
|
256
|
+ F_CJ_Time: $('#order_time').val(),//抽检时间
|
|
|
257
|
+ F_CJ_Level: $('#order_samplingle').val(), //抽检级别
|
|
|
258
|
+ F_CJ_Unit: $('#order_lingunit').val(), //抽检单位
|
|
|
259
|
+ F_CJ_TestUnit: $('#order_assay').val(),//化验单位
|
|
|
260
|
+ F_CJ_Tonnage: $('#order_tunnage').val(),//抽检吨数
|
|
|
261
|
+ F_CJ_BagNo: $('#order_algebra').val(),//抽检袋数
|
|
|
262
|
+ F_CJ_Outlay: $('#order_money').val(),//公关费用金额
|
|
|
263
|
+ // F_Source: $('#order_source').attr('data-index'), //工单来源
|
|
|
264
|
+ // F_Type: $('.order_type').find('input[type="radio"]:checked').val(), //工单类型
|
|
|
265
|
+ F_Files:str_ary
|
|
|
266
|
+ },
|
|
|
267
|
+ success: function(data) {
|
|
|
268
|
+ if(data.state == "success") {
|
|
|
269
|
+ debugger
|
|
|
270
|
+ //alert($('#order_reception').val()), //描述详情
|
|
|
271
|
+ mui.toast('创建成功');
|
|
|
272
|
+ window.location.href = "Have_list.html";
|
|
|
273
|
+ } else {
|
|
|
274
|
+ mui.toast(data.message);
|
|
|
275
|
+ $("#submit").removeAttr("disabled")
|
|
|
276
|
+ }
|
|
|
277
|
+ }
|
|
|
278
|
+ });
|
|
|
279
|
+
|
|
|
280
|
+ } else {
|
|
|
281
|
+ mui.toast("取消");
|
|
|
282
|
+ }
|
|
|
283
|
+ })
|
|
276
|
284
|
}
|
|
277
|
285
|
})
|
|
278
|
286
|
|