开封利通水务前端

noticeDetail.js 1.2KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. /**
  2. * 业务信息详情
  3. * */
  4. $(function() {
  5. // //获取所属行业//获取税务类别//获取客户信誉等级
  6. // $.when(helper.getDropList.getlistDropByDic($('#customer_subtrade'), 'KHSSHY'),
  7. // helper.getDropList.getlistDropByDic($('#customer_taxCategory'), 'SWLB'),
  8. // helper.getDropList.getlistDropByDic($('#customer_layer'), 'KHLayer'))
  9. // .done(function() {
  10. var edit_id = helper.request.queryString("edit_id");
  11. if (edit_id) {
  12. getCustomer(edit_id);
  13. }
  14. // });
  15. });
  16. //获取详情
  17. function getCustomer(ids) {
  18. $.getJSON(huayi.config.callcenter_url + "Notice/GetNotice", {
  19. noticeid: ids, //公告通知id
  20. token: $.cookie("token")
  21. }, function(data) {
  22. if (data.state.toLowerCase() == "success") {
  23. data = data.data;
  24. if (data) {
  25. $('#title').text(data.F_Title);
  26. $('#iscus').text(formatterIsCus(data.F_isCus));
  27. $('#createuser').text(data.F_CreateByName);
  28. $('#createtime').text(data.F_CreateOn);
  29. if(data.F_Content){
  30. $('#content').html(helper.filter.content(data.F_Content));
  31. }else{
  32. $('#content').text('暂无内容。。。');
  33. }
  34. }
  35. }
  36. });
  37. }
  38. // 格式化是否客户查看
  39. function formatterIsCus(val){
  40. var statusMap = {
  41. 0: '否',
  42. 1: '是'
  43. }
  44. return statusMap[val];
  45. }