Commit d8c028fb4e36b71ed0db1e4e298a858d15765480
1 parent
13a0523f
编辑 提交 切换
Showing
1 changed file
with
8 additions
and
3 deletions
topages/workfill/workfill.js
@@ -47,16 +47,21 @@ $('#time-opr-prevbtn').on('click',function () { | @@ -47,16 +47,21 @@ $('#time-opr-prevbtn').on('click',function () { | ||
47 | $('#time-opr-nextbtn').on('click',function () { | 47 | $('#time-opr-nextbtn').on('click',function () { |
48 | fun.timeoprnextbtn(); | 48 | fun.timeoprnextbtn(); |
49 | }); | 49 | }); |
50 | + | ||
50 | //提交事件 | 51 | //提交事件 |
51 | -$('.workfill-list-btn').on('click',function () { | 52 | +$(document).on('click','.workfill-list-btn',function () { |
52 | var _this=$(this); | 53 | var _this=$(this); |
53 | - console.log(_this); | ||
54 | - if($('.workfill-projectCon').hasClass('display-none')){ | 54 | + if(_this.parent().parent().find('.workfill-list-projectnamewrap .workfill-projectCon').hasClass('display-none')){ |
55 | _this.text('提交'); | 55 | _this.text('提交'); |
56 | + _this.parent().parent().find(".workfill-list-container").attr("contenteditable","true"); | ||
56 | }else { | 57 | }else { |
57 | _this.text('编辑'); | 58 | _this.text('编辑'); |
59 | + _this.parent().parent().find(".workfill-list-container").attr("contenteditable","false"); | ||
58 | } | 60 | } |
59 | _this.parent().parent().find('.workfill-list-projectnamewrap .workfill-projectCon').toggleClass('display-none'); | 61 | _this.parent().parent().find('.workfill-list-projectnamewrap .workfill-projectCon').toggleClass('display-none'); |
62 | + var projectName=_this.parent().parent().find('.workfill-list-projectnamewrap .workfill-projectCon .work-projectName').find("option:selected").text(); | ||
60 | _this.parent().parent().find('.workfill-list-projectnamewrap .workfill-list-projectname').toggleClass('display-none'); | 63 | _this.parent().parent().find('.workfill-list-projectnamewrap .workfill-list-projectname').toggleClass('display-none'); |
64 | + _this.parent().parent().find('.workfill-list-projectnamewrap .workfill-list-projectname').text(projectName); | ||
65 | + | ||
61 | 66 | ||
62 | }); | 67 | }); |