1 line
3.7 KiB
JavaScript
1 line
3.7 KiB
JavaScript
(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pages/workreport/workDetail"],{6116:function(t,e,n){},"92a7":function(t,e,n){"use strict";n.d(e,"b",(function(){return i})),n.d(e,"c",(function(){return a})),n.d(e,"a",(function(){return o}));var o={uLoadmore:function(){return n.e("uview-ui/components/u-loadmore/u-loadmore").then(n.bind(null,"2743"))},uPopup:function(){return n.e("uview-ui/components/u-popup/u-popup").then(n.bind(null,"9770"))}},i=function(){var t=this.$createElement,e=(this._self._c,this.commont_list.length);this.$mp.data=Object.assign({},{$root:{g0:e}})},a=[]},a90a:function(t,e,n){"use strict";n.r(e);var o=n("92a7"),i=n("bcd2");for(var a in i)["default"].indexOf(a)<0&&function(t){n.d(e,t,(function(){return i[t]}))}(a);n("ae66");var u=n("f0c5"),r=Object(u["a"])(i["default"],o["b"],o["c"],!1,null,"590e6114",null,!1,o["a"],void 0);e["default"]=r.exports},aacf:function(t,e,n){"use strict";(function(t,e){var o=n("4ea4");n("8886");o(n("66fd"));var i=o(n("a90a"));t.__webpack_require_UNI_MP_PLUGIN__=n,e(i.default)}).call(this,n("bc2e")["default"],n("543d")["createPage"])},ae66:function(t,e,n){"use strict";var o=n("6116"),i=n.n(o);i.a},bcd2:function(t,e,n){"use strict";n.r(e);var o=n("ecd0"),i=n.n(o);for(var a in o)["default"].indexOf(a)<0&&function(t){n.d(e,t,(function(){return o[t]}))}(a);e["default"]=i.a},ecd0:function(t,e,n){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var o=n("dc92"),i=n("76dd"),a=n("0c59"),u={components:{formItem:function(){Promise.all([n.e("common/vendor"),n.e("components/form/formitem")]).then(function(){return resolve(n("d7bf"))}.bind(null,n)).catch(n.oe)},readOrNoread:function(){n.e("pages/workreport/readOrnoread").then(function(){return resolve(n("ceeb"))}.bind(null,n)).catch(n.oe)}},data:function(){return{BASE_IMG_URL:a.BASE_IMG_URL,id:"",autoHeight:!0,info:{},listForm:[],commont_list:[],popupShow:!1,noClick:!0,content:"",active:"b",typeList:[{id:1,name:"日报",value:"daily"},{id:2,name:"周报",value:"weekly"},{id:3,name:"月报",value:"monthly"},{id:4,name:"季报",value:"quarterly"},{id:5,name:"年报",value:"yearly"}],typeValue:"daily",showRead:!1,readNum:0,readList:[],noReadNum:0,noReadlist:[]}},onLoad:function(t){this.id=t.id,this.getDetail(),this.getCommont(),this.getReadNum()},methods:{getReadNum:function(){var t=this;(0,o.netWorkisRead)({id:this.id}).then((function(e){t.readList=e.data.read,t.noReadlist=e.data.not_read,t.readNum=e.data.read.length,t.noReadNum=e.data.not_read.length}))},getForm:function(){var t=this;(0,o.netSetForm)({type:this.typeValue}).then((function(e){e=e.data.data,e&&(t.listForm=[]),e.forEach((function(e){"type"!=e.id&&(e.value=t.info[e.id],t.listForm.push(e))}))}))},changeTab:function(t){this.active=t.detail.name,"a"==this.active?this.getCommont():this.getForm()},getDetail:function(){var t=this;(0,o.netWorkDetail)({id:this.id}).then((function(e){t.info=e.data,t.handleType(e.data.type),t.getForm()}))},handleType:function(t){var e=this,n=this.typeList;n.forEach((function(n){n.name==t&&(e.typeValue=n.value)}))},getCommont:function(){var t=this,e={relation_type:5,record_id:this.id};(0,i.netGetCommentList)(e).then((function(e){t.commont_list=e.data}))},publishClick:function(){this.popupShow=!0},closePup:function(){this.popupShow=!1},lookTip:function(){this.$refs.readChild.open()},btnPubClick:function(){var e=this;if(this.content){var n={content:this.content,record_id:this.id,relation_type:5};(0,i.netAddComment)(n).then((function(n){t.showToast({title:n.msg,icon:"none"}),setTimeout((function(){e.content="",e.popupShow=!1,e.getCommont()}),2e3)}))}else t.showToast({title:"请填写评论",icon:"none"})}}};e.default=u}).call(this,n("543d")["default"])}},[["aacf","common/runtime","common/vendor"]]]); |