beehole-store-server
Version:
www.bee-hole.com
1 lines • 16.4 kB
JavaScript
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-32016982","chunk-7120cdb0","chunk-2695b454"],{"06e3":function(t,e,a){"use strict";a.r(e);a("99af");var i=function(){var t=this,e=t._self._c;return e("div",[e("a-card",{staticStyle:{"margin-bottom":"10px"},attrs:{bordered:!1}},[e("div",{staticClass:"table-page-search-wrapper"},[e("a-form",{attrs:{labelCol:t.labelCol,wrapperCol:t.wrapperCol}},[e("a-row",{attrs:{gutter:48}},[e("a-col",{attrs:{md:6,sm:24}},[e("a-form-item",{attrs:{label:"公告标题"}},[e("a-input",{attrs:{placeholder:"请输入","allow-clear":""},model:{value:t.queryParam.noticeTitle,callback:function(e){t.$set(t.queryParam,"noticeTitle",e)},expression:"queryParam.noticeTitle"}})],1)],1),e("a-col",{attrs:{md:6,sm:24}},[e("a-form-item",{attrs:{label:"操作人员"}},[e("a-input",{attrs:{placeholder:"请输入","allow-clear":""},model:{value:t.queryParam.createBy,callback:function(e){t.$set(t.queryParam,"createBy",e)},expression:"queryParam.createBy"}})],1)],1),e("a-col",{attrs:{md:6,sm:24}},[e("a-form-item",{attrs:{label:"公告类型"}},[e("a-select",{staticStyle:{width:"100%"},attrs:{placeholder:"请选择","allow-clear":""},model:{value:t.queryParam.noticeType,callback:function(e){t.$set(t.queryParam,"noticeType",e)},expression:"queryParam.noticeType"}},t._l(t.typeOptions,(function(a,i){return e("a-select-option",{key:i,attrs:{value:a.dictValue}},[t._v(t._s(a.dictLabel))])})),1)],1)],1),e("a-col",[e("span",{staticClass:"table-page-search-submitButtons",staticStyle:{float:"right"}},[e("a-button",{attrs:{type:"primary"},on:{click:t.handleQuery}},[e("a-icon",{attrs:{type:"search"}}),t._v("查询")],1),e("a-button",{staticStyle:{"margin-left":"8px"},on:{click:t.resetQuery}},[e("a-icon",{attrs:{type:"redo"}}),t._v("重置")],1)],1)])],1)],1)],1)]),e("a-card",{staticClass:"table-card",attrs:{bordered:!1}},[t.showViewModal?e("artcle-view-form",{ref:"noticeViewForm",attrs:{typeOptions:t.typeOptions,statusOptions:t.statusOptions},on:{ok:t.getList,close:function(e){t.showViewModal=!1}}}):t._e(),e("advance-table",{attrs:{columns:t.columns,"data-source":t.list,title:"通知公告",loading:t.loading,rowKey:"id",size:"middle",tableKey:"system-notic-NoticReadIndex-table",isTableConfig:!1,isShowSetBtn:!1,"format-conditions":!0,"row-selection":{selectedRowKeys:t.selectedRowKeys,onChange:t.onSelectChange},pagination:{current:t.queryParam.pageNum,pageSize:t.queryParam.pageSize,total:t.total,showSizeChanger:!0,showLessItems:!0,showQuickJumper:!0,showTotal:function(t,e){return"第 ".concat(e[0],"-").concat(e[1]," 条,总计 ").concat(t," 条")},onChange:t.changeSize,onShowSizeChange:t.onSizeChange}},on:{refresh:t.getList},scopedSlots:t._u([{key:"noticeType",fn:function(a){var i=a.text,n=a.record;return e("span",{},[e("a-tag",{attrs:{color:t._f("noticeTypeFilter")(i)}},[t._v(" "+t._s(t.typeFormat(n))+" ")])],1)}},{key:"isRead",fn:function(a){var i=a.text,n=a.record;return e("span",{},[e("a-badge",{attrs:{status:"1"===i?"processing":"error",text:t.isReadFormat(n)}})],1)}},{key:"createTime",fn:function(a){a.text;var i=a.record;return e("span",{},[t._v(" "+t._s(t.parseTime(i.createTime,"{y}-{m}-{d}"))+" ")])}},{key:"operation",fn:function(a){a.text;var i=a.record;return e("span",{},[e("a",{on:{click:function(e){return t.handleView(i)}}},[t._v(" 阅读 ")])])}}])},[e("div",{staticClass:"table-operations",attrs:{slot:"button"},slot:"button"},[e("a-button",{attrs:{type:"primary",disabled:t.multiple},on:{click:t.updateNoticeToRead}},[e("a-icon",{attrs:{type:"pushpin"}}),t._v("标记已读 ")],1)],1)])],1)],1)},n=[],c=(a("d81d"),a("8b29")),r=a("5d9e"),o=a("da98"),s={name:"Notice",components:{AdvanceTable:r["a"],ArtcleViewForm:o["default"]},data:function(){return{list:[],selectedRowKeys:[],selectedRows:[],advanced:!1,single:!0,multiple:!0,ids:[],loading:!1,sunloading:!1,total:0,typeOptions:[],statusOptions:[],dateRange:[],labelCol:{span:6},wrapperCol:{span:18},queryParam:{pageNum:1,pageSize:10,noticeTitle:void 0,createBy:void 0,status:void 0},addModalRefName:"addModal",columns:[{title:"公告标题",dataIndex:"noticeTitle",ellipsis:!0,width:"20%"},{title:"公告类型",dataIndex:"noticeType",scopedSlots:{customRender:"noticeType"},align:"center"},{title:"是否已读",dataIndex:"isRead",scopedSlots:{customRender:"isRead"},align:"center"},{title:"发布人",dataIndex:"createByName",ellipsis:!0,width:"8%"},{title:"发布",dataIndex:"createTime",scopedSlots:{customRender:"createTime"}},{title:"操作",dataIndex:"operation",width:"200",scopedSlots:{customRender:"operation"}}],showViewModal:!1}},filters:{noticeTypeFilter:function(t){var e="blue";return"1"===t&&(e="orange"),e}},created:function(){var t=this;this.getDicts("sys_notice_status").then((function(e){t.statusOptions=e.data})),this.getDicts("sys_notice_type").then((function(e){t.typeOptions=e.data})),this.getList()},computed:{},watch:{},methods:{getList:function(){var t=this;this.loading=!0,Object(c["d"])(this.queryParam).then((function(e){t.list=e.data.list,t.total=e.data.total,t.loading=!1}))},isReadFormat:function(t){return null!==t.isRead&&""!==t.isRead&&"1"===t.isRead?"已读":"未读"},typeFormat:function(t){return this.selectDictLabel(this.typeOptions,t.noticeType)},handleQuery:function(){this.queryParam.pageNum=1,this.getList()},resetQuery:function(){this.queryParam={pageNum:1,pageSize:10,noticeTitle:void 0,createBy:void 0,status:void 0},this.handleQuery()},onShowSizeChange:function(t,e){this.queryParam.pageSize=e,this.getList()},onSizeChange:function(t,e){this.queryParam.pageNum=1,this.queryParam.pageSize=e,this.getList()},changeSize:function(t,e){this.queryParam.pageNum=t,this.queryParam.pageSize=e,this.getList()},onSelectChange:function(t,e){this.selectedRowKeys=t,this.selectedRows=e,this.ids=this.selectedRows.map((function(t){return t.id})),this.single=1!==t.length,this.multiple=!t.length},toggleAdvanced:function(){this.advanced=!this.advanced},handleView:function(t){var e=this;this.showViewModal=!0,this.$nextTick((function(){return e.$refs.noticeViewForm.handleView(t)}))},updateNoticeToRead:function(t){var e=this,a=t.id||this.ids;this.$confirm({title:"确认标记所选中数据?",onOk:function(){return Object(c["f"])(a).then((function(){e.onSelectChange([],[]),e.getList(),e.$message.success("标记成功",3)}))},onCancel:function(){}})}}},d=s,l=a("2877"),u=Object(l["a"])(d,i,n,!1,null,null,null);e["default"]=u.exports},"1b74":function(t,e,a){"use strict";a.r(e);var i=a("2dd7"),n=a("f874"),c=a("5ac8"),r=a("bf9b"),o=a("1b6c"),s=a("50af"),d=a("8ebd");e["default"]={name:"CreateForm",props:{typeOptions:{type:Array,required:!0},statusOptions:{type:Array,required:!0},options:{type:Array}},components:{AntModal:i["a"],VDitor:c["a"],ViewTabs:r["a"],ai:d["a"],aiTs:s["a"]},data:function(){return{open:!1,attachmentRefName:"addUploaderFile",editAttachmentRefName:"editUploaderFile",attachmentUploadStatus:!0,uploaderButtonStatus:!1,formId:"",labelCol:{span:4},wrapperCol:{span:14},loading:!1,total:0,id:void 0,formTitle:"",contentEditorEdit:"",form:{id:void 0,title:void 0,type:void 0,content:"",status:"0",sort:1},rules:{title:[{required:!0,message:Object(o["b"])("component.article.title.not.null"),trigger:"blur"}],type:[{required:!0,message:Object(o["b"])("component.article.type.not.null"),trigger:"change"}]},view_id:0,aiLodding:!1,lang:"",defaultLang:"",status:[{value:"0",key:0,label:Object(o["b"])("view.article.list.article.table.status.0")},{value:"1",key:1,label:Object(o["b"])("view.article.list.article.table.status.1")}]}},filters:{},created:function(){},computed:{},watch:{},mounted:function(){},methods:{cancel:function(){this.open=!1,this.reset(),this.$emit("close")},reset:function(){this.form={id:void 0,title:void 0,type:void 0,content:"",status:"0",sort:0},this.formId&&(this.formId="")},handleAdd:function(){this.reset(),this.open=!0,this.formTitle=Object(o["b"])("component.article.form.add")},handleUpdate:function(t){var e=this;this.reset();var a=t.article_id;this.articleId=a;var i={article_id:a};this.view_id&&(i.view_id=this.view_id),Object(n["g"])(i).then((function(t){e.form=t,e.formId=t.article_id,e.open=!0,e.formTitle=Object(o["b"])("component.article.form.update")}))},pageInit:function(t){this.form=t,this.$refs.antModalRef.setMaxDiolog()},changeView:function(t,e){var a=this;this.view_id=t,this.lang=e;var i={};this.articleId&&(i.article_id=this.articleId),this.view_id&&(i.view_id=this.view_id),Object(n["g"])(i).then((function(t){a.form=t,a.formId=t.article_id}))},submitForm:function(){var t=this,e=this;this.$refs.ComDitor.getValue1(),this.$refs.form.validate((function(a){return t.aiLodding?(t.$message.warning(t.$t("view.test.form.add.message.aiUpdate"),2),!1):!!a&&(t.uploaderButtonStatus=!0,void(void 0!==t.form.article_id?(t.view_id&&(t.form.view_id=t.view_id),Object(n["a"])(t.form).then((function(a){t.$message.success(Object(o["b"])("component.artilce.update.success"),3),t.$emit("ok"),e.uploaderButtonStatus=!1}))):Object(n["a"])(t.form).then((function(a){t.$message.success(Object(o["b"])("component.artilce.add.success"),3),t.$emit("ok"),t.handleUpdate(a),e.uploaderButtonStatus=!1}))))}))}}}},"42ef":function(t,e,a){"use strict";a("b6f5")},"8b29":function(t,e,a){"use strict";a.d(e,"c",(function(){return n})),a.d(e,"b",(function(){return c})),a.d(e,"e",(function(){return r})),a.d(e,"a",(function(){return o})),a.d(e,"d",(function(){return s})),a.d(e,"f",(function(){return d}));var i=a("b775");function n(t){return Object(i["b"])({url:"/notice/list",method:"get",params:t})}function c(t){return Object(i["b"])({url:"/notice/view",method:"get",params:{id:t}})}function r(t){return Object(i["b"])({url:"/notice/edit",method:"post",data:t})}function o(t){return Object(i["b"])({url:"/notice/delete",method:"post",params:{id:t}})}function s(t){return Object(i["b"])({url:"/notice/list",method:"get",params:t})}function d(t){return Object(i["b"])({url:"/system/notice/updateNoticeToRead/"+t,method:"put"})}},"8ebd":function(t,e,a){"use strict";var i=function(){var t=this,e=t._self._c;return e("a-tooltip",[e("template",{slot:"title"},[t._v(" "+t._s(t.$t("app.form.ai.ts"))+" ")]),e("a-switch",{attrs:{"checked-children":t.$t("app.form.ai.open"),"un-checked-children":t.$t("app.form.ai.close")},on:{change:t.back},model:{value:t.checked,callback:function(e){t.checked=e},expression:"checked"}})],2)},n=[],c=a("5530"),r={name:"ai",props:{value:{default:1},id:{default:-1}},data:function(){return{checked:!0}},watch:{value:function(){this.checked=!!this.value}},created:function(){-1!==this.id&&void 0!==this.id||this.back()},methods:{back:function(){var t=0;this.checked&&(t=1),this.$emit("update:value",t),this.$emit("change",t)}}},o=Object(c["a"])({},r),s=o,d=a("2877"),l=Object(d["a"])(s,i,n,!1,null,null,null);e["a"]=l.exports},"8f0e":function(t,e,a){"use strict";var i=a("5530"),n=(a("a9e3"),a("d81d"),a("7db0"),a("d3b7"),a("d047")),c=a("5880");e["a"]={name:"ViewSelect",props:{viewId:{type:Number,default:0},lang:{type:String},backVal:{type:String,default:"viewId"}},computed:Object(i["a"])({},Object(c["mapGetters"])(["shopId"])),data:function(){return{viewLists:[],checkedViewId:0,checkedLang:""}},created:function(){this.checkedViewId||(this.checkedViewId=this.viewId),this.checkedLang&&""!==this.checkedLang||(this.checkedLang=this.lang),this.initLit()},methods:{initLit:function(){var t=this;Object(n["i"])({ShopId:this.shopId,limit:100,page:1}).then((function(e){t._.map(e.list,(function(e){1===e.is_default&&t.$emit("update:defaultLang",e.language)})),"viewId"===t.backVal?(t.viewLists=e.list,e.list&&(t.checkedLang=t.viewLists[0].language,t.checkedViewId=t.viewLists[0].view_id,t.back())):(t.viewLists=e.list,t.viewList&&(t.checkedLang=t.viewLists[0].language,t.checkedViewId=t.viewLists[0].view_id,t.back()))}))},back:function(t){var e=this,a=this.viewLists.find((function(t){return"viewId"===e.backVal?t.view_id===e.checkedViewId:t.language===e.checkedLang}));"viewId"===this.backVal?(this.checkedLang=a.language,this.$emit("change",this.checkedViewId,this.checkedLang)):(this.checkedViewId=a.view_id,this.$emit("change",this.checkedLang,this.checkedViewId)),this.$emit("changeView",a)}}}},b6f5:function(t,e,a){},bf9b:function(t,e,a){"use strict";a("b0c0");var i=function(){var t=this,e=t._self._c;return e("div",[t.viewLists&&t.viewLists.length?["viewId"==t.backVal?e("a-tabs",{attrs:{animated:!1},on:{change:t.back},model:{value:t.checkedViewId,callback:function(e){t.checkedViewId=e},expression:"checkedViewId"}},t._l(t.viewLists,(function(t){return e("a-tab-pane",{key:t.view_id,attrs:{tab:t.name}})})),1):e("a-tabs",{attrs:{animated:!1},on:{change:t.back},model:{value:t.checkedLang,callback:function(e){t.checkedLang=e},expression:"checkedLang"}},t._l(t.viewLists,(function(t){return e("a-tab-pane",{key:t.language,attrs:{tab:t.name}})})),1)]:t._e()],2)},n=[],c=a("5530"),r=a("8f0e"),o=Object(c["a"])({},r["a"]),s=o,d=a("2877"),l=Object(d["a"])(s,i,n,!1,null,null,null);e["a"]=l.exports},d047:function(t,e,a){"use strict";a.d(e,"i",(function(){return c})),a.d(e,"h",(function(){return r})),a.d(e,"b",(function(){return o})),a.d(e,"f",(function(){return s})),a.d(e,"a",(function(){return d})),a.d(e,"d",(function(){return l})),a.d(e,"g",(function(){return u})),a.d(e,"e",(function(){return h})),a.d(e,"c",(function(){return p}));var i=a("b775"),n={list:"/shop/view/list"};function c(t){return Object(i["b"])({url:n.list,method:"post",data:t})}function r(t){return Object(i["b"])({url:"/shop/view/add",method:"post",data:t})}function o(t){return Object(i["b"])({url:"/shop/view/close_auto_trans",method:"post",data:t})}function s(t){return Object(i["b"])({url:"/shop/view/open_auto_trans",method:"post",data:t})}function d(t){return Object(i["b"])({url:"/trans_task/add_shop_job",method:"post",data:t})}function l(t){return Object(i["b"])({url:"/shop/getinfo",method:"post",data:t})}function u(t){return Object(i["b"])({url:"/mall_config/save",method:"post",data:t})}function h(t){return Object(i["b"])({url:"/lang/get",method:"post",data:t})}function p(t){return Object(i["b"])({url:"/mall_config/get",method:"post",data:t})}},da98:function(t,e,a){"use strict";a.r(e);var i=function(){var t=this,e=t._self._c;return e("ant-modal",{ref:"antModalRef",attrs:{visible:t.open,"modal-title":t.formTitle,adjustSize:!1,footer:null,dialogClass:"designer-wrapper"},on:{cancel:t.cancel}},[e("div",{attrs:{slot:"content"},slot:"content"},[e("div",{staticClass:"top-box"},[e("h2",{staticClass:"title-h2"},[t._v(t._s(t.form.noticeTitle)+"("+t._s("1"===t.form.noticeType?"通知":"公告")+")")]),e("h3",{staticClass:"time-h3"},[t._v("发布人:"+t._s(t.form.createByName))]),e("h3",{staticClass:"time-h3"},[t._v("发布时间:"+t._s(t.form.createTime))])]),e("div",{staticClass:"weui_article"},[e("div",{staticClass:"vditor-preview",staticStyle:{display:"block"}},[e("div",{staticClass:"vditor-reset",staticStyle:{"max-width":"100%"},domProps:{innerHTML:t._s(t.form.noticeContentHtml)}},[t._v(" "+t._s(t.form.noticeContentHtml)+" ")])])])])])},n=[],c=a("5530"),r=a("1b74"),o=Object(c["a"])({},r["default"]),s=o,d=(a("42ef"),a("2877")),l=Object(d["a"])(s,i,n,!1,null,"46a64dbb",null);e["default"]=l.exports},f874:function(t,e,a){"use strict";a.d(e,"a",(function(){return c})),a.d(e,"g",(function(){return r})),a.d(e,"f",(function(){return o})),a.d(e,"e",(function(){return s})),a.d(e,"d",(function(){return d})),a.d(e,"b",(function(){return l})),a.d(e,"c",(function(){return u}));var i=a("b775"),n={articleAdd:"/article/add",articleSubAdd:"/article/sub/add",articleOne:"/article/get",articleList:"/article/list",articleDelete:"/article/delete",articleCatList:"/article/cat/list",articleCatAdd:"/article/cat/add",articleCatSubAdd:"/article/cat/sub/add",articleCatInfo:"/article/cat/info"};function c(t){return Object(i["b"])({url:t.view_id?n.articleSubAdd:n.articleAdd,method:"post",data:t})}function r(t){return Object(i["b"])({url:n.articleOne,method:"post",params:t})}function o(t){return Object(i["b"])({url:n.articleList,method:"post",params:t})}function s(t){return Object(i["b"])({url:n.articleDelete,method:"post",params:t})}function d(t){return Object(i["b"])({url:n.articleCatList,method:"post",params:t})}function l(t){return Object(i["b"])({url:t.view_id?n.articleCatSubAdd:n.articleCatAdd,method:"post",data:t})}function u(t){return Object(i["b"])({url:n.articleCatInfo,method:"post",params:t})}}}]);