You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1 lines
7.5 KiB
1 lines
7.5 KiB
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-0ee5ab49"],{"23fc":function(t,n,e){"use strict";e.r(n);var r=function(){var t=this,n=t.$createElement,e=t._self._c||n;return e("div",{staticClass:"divBox"},[e("el-card",[e("div",{staticClass:"mb20"},[e("el-button",{attrs:{size:"small",type:"primary"},on:{click:t.onAdd}},[t._v("添加分类")])],1),t._v(" "),e("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.listLoading,expression:"listLoading"}],attrs:{data:t.tableData.data,size:"small","row-key":"id","default-expand-all":!1,"tree-props":{children:"children",hasChildren:"hasChildren"}}},[e("el-table-column",{attrs:{prop:"id",label:"ID","min-width":"60"}}),t._v(" "),e("el-table-column",{attrs:{prop:"name",label:"名称","min-width":"150"}}),t._v(" "),e("el-table-column",{attrs:{prop:"type",label:"类型","min-width":"100"}}),t._v(" "),e("el-table-column",{attrs:{prop:"status",label:"是否显示","min-width":"100"},scopedSlots:t._u([{key:"default",fn:function(n){return[e("el-switch",{attrs:{"active-value":1,"inactive-value":0,"active-text":"显示","inactive-text":"隐藏",width:55},on:{change:function(e){return t.onchangeIsShow(n.row)}},model:{value:n.row.status,callback:function(e){t.$set(n.row,"status",e)},expression:"scope.row.status"}})]}}])}),t._v(" "),e("el-table-column",{attrs:{prop:"add_time",label:"添加时间","min-width":"150"}}),t._v(" "),e("el-table-column",{attrs:{label:"操作","min-width":"100"},scopedSlots:t._u([{key:"default",fn:function(n){return[e("el-button",{attrs:{type:"text",size:"small"},on:{click:function(e){return t.edit(n.row)}}},[t._v("编辑")]),t._v(" "),e("el-button",{attrs:{type:"text",size:"small"},on:{click:function(e){return t.handleDelete(n.row,n.$index)}}},[t._v("删除")])]}}])})],1)],1)],1)},i=[],u=e("f478"),o=e("83d6"),c={name:"PlantCategory",data:function(){return{roterPre:o["roterPre"],listLoading:!0,tableData:{data:[]},tableFrom:{page:1,limit:20}}},mounted:function(){this.getList()},methods:{getList:function(){var t=this;this.listLoading=!0,Object(u["R"])(this.tableFrom).then((function(n){t.tableData.data=n.data,t.listLoading=!1})).catch((function(n){t.listLoading=!1,t.$message.error(n.message)}))},onAdd:function(){var t=this;this.$modalForm(Object(u["c"])()).then((function(){return t.getList()}))},edit:function(t){var n=this;this.$modalForm(Object(u["r"])(t.id)).then((function(){return n.getList()}))},onchangeIsShow:function(t){var n=this;Object(u["S"])(t.id,t.status).then((function(t){var e=t.message;n.$message.success(e),n.getList()})).catch((function(t){var e=t.message;n.$message.error(e)}))},handleDelete:function(t,n){var e=this;this.$modalSure("删除该分类吗").then((function(){Object(u["i"])(t.id).then((function(t){var n=t.message;e.$message.success(n),e.getList()})).catch((function(t){var n=t.message;e.$message.error(n)}))}))}}},a=c,d=(e("3881"),e("2877")),s=Object(d["a"])(a,r,i,!1,null,"d2e5fb2a",null);n["default"]=s.exports},3881:function(t,n,e){"use strict";e("ab12")},ab12:function(t,n,e){},f478:function(t,n,e){"use strict";e.d(n,"t",(function(){return i})),e.d(n,"z",(function(){return u})),e.d(n,"o",(function(){return o})),e.d(n,"n",(function(){return c})),e.d(n,"m",(function(){return a})),e.d(n,"l",(function(){return d})),e.d(n,"X",(function(){return s})),e.d(n,"V",(function(){return f})),e.d(n,"e",(function(){return l})),e.d(n,"v",(function(){return g})),e.d(n,"A",(function(){return m})),e.d(n,"x",(function(){return y})),e.d(n,"B",(function(){return p})),e.d(n,"P",(function(){return h})),e.d(n,"Q",(function(){return _})),e.d(n,"c",(function(){return v})),e.d(n,"r",(function(){return b})),e.d(n,"R",(function(){return k})),e.d(n,"S",(function(){return w})),e.d(n,"i",(function(){return L})),e.d(n,"a",(function(){return x})),e.d(n,"p",(function(){return $})),e.d(n,"C",(function(){return j})),e.d(n,"D",(function(){return D})),e.d(n,"g",(function(){return O})),e.d(n,"d",(function(){return S})),e.d(n,"s",(function(){return C})),e.d(n,"j",(function(){return z})),e.d(n,"T",(function(){return F})),e.d(n,"U",(function(){return I})),e.d(n,"b",(function(){return P})),e.d(n,"q",(function(){return A})),e.d(n,"h",(function(){return J})),e.d(n,"E",(function(){return B})),e.d(n,"F",(function(){return E})),e.d(n,"u",(function(){return N})),e.d(n,"f",(function(){return R})),e.d(n,"k",(function(){return q})),e.d(n,"O",(function(){return G})),e.d(n,"N",(function(){return H})),e.d(n,"M",(function(){return K})),e.d(n,"L",(function(){return M})),e.d(n,"J",(function(){return Q})),e.d(n,"H",(function(){return T})),e.d(n,"G",(function(){return U})),e.d(n,"K",(function(){return V})),e.d(n,"I",(function(){return W})),e.d(n,"y",(function(){return X})),e.d(n,"W",(function(){return Y}));var r=e("0c6d");function i(t){return r["a"].get("store/category/list",t)}function u(t){return r["a"].get("diy/product/lst",t)}function o(t,n){return r["a"].post("diy/create/".concat(t),n)}function c(t){return r["a"].get("diy/lst",t)}function a(t){return r["a"].get("diy/detail/".concat(t))}function d(t,n){return r["a"].delete("diy/delete/".concat(t),n)}function s(t){return r["a"].post("diy/status/".concat(t))}function f(t){return r["a"].get("diy/recovery/".concat(t))}function l(){return r["a"].get("/cms/category_list")}function g(t){return r["a"].get("diy/link/list",t)}function m(t){return r["a"].get("diy/get_routine_code/".concat(t))}function y(){return r["a"].get("diy/user_index")}function p(t){return r["a"].post("diy/user_index",t)}function h(t){return r["a"].get("diy/categroy/options",t)}function _(t,n){return r["a"].get("diy/link/getLinks/".concat(t),n)}function v(){return r["a"].get("diy/categroy/form")}function b(t){return r["a"].get("diy/categroy/".concat(t,"/form"))}function k(t){return r["a"].get("diy/categroy/lst",t)}function w(t,n){return r["a"].post("diy/categroy/status/".concat(t),{status:n})}function L(t){return r["a"].delete("diy/categroy/delete/".concat(t))}function x(){return r["a"].get("diy/mer_categroy/form")}function $(t){return r["a"].get("diy/mer_categroy/".concat(t,"/form"))}function j(t){return r["a"].get("diy/mer_categroy/lst",t)}function D(t,n){return r["a"].post("diy/mer_categroy/status/".concat(t),{status:n})}function O(t){return r["a"].delete("diy/mer_categroy/delete/".concat(t))}function S(){return r["a"].get("diy/link/form")}function C(t){return r["a"].get("diy/link/".concat(t,"/form"))}function z(t){return r["a"].delete("diy/link/delete/".concat(t))}function F(t){return r["a"].get("diy/link/lst",t)}function I(t,n){return r["a"].post("diy/link/status/".concat(t),{status:n})}function P(){return r["a"].get("diy/mer_link/form")}function A(t){return r["a"].get("diy/mer_link/".concat(t,"/form"))}function J(t){return r["a"].delete("diy/mer_link/delete/".concat(t))}function B(t){return r["a"].get("diy/mer_link/lst",t)}function E(t,n){return r["a"].post("diy/mer_link/status/".concat(t),{status:n})}function N(){return r["a"].get("diy/store_street")}function R(t){return r["a"].post("diy/store_street",t)}function q(t){return r["a"].get("diy/copy/".concat(t))}function G(t,n){return r["a"].post("micro/create/".concat(t),n)}function H(t){return r["a"].get("micro/lst",t)}function K(t){return r["a"].get("micro/detail/".concat(t))}function M(t,n){return r["a"].delete("micro/delete/".concat(t),n)}function Q(t){return r["a"].get("mer_diy/lst",t)}function T(t,n){return r["a"].delete("mer_diy/delete/".concat(t),n)}function U(t){return r["a"].get("mer_diy/copy/".concat(t))}function V(t,n){return r["a"].post("mer_diy/create/".concat(t),n)}function W(t){return r["a"].get("mer_diy/detail/".concat(t))}function X(t){return r["a"].get("mer_diy/scope/".concat(t))}function Y(t,n){return r["a"].post("mer_diy/scope/".concat(t),n)}}}]); |