name fix
This commit is contained in:
parent
5c73b83c87
commit
e0011ae7ca
1 changed files with 3 additions and 2 deletions
|
@ -41,7 +41,7 @@ export const getCategories: Act = {
|
|||
}
|
||||
};
|
||||
|
||||
export const addCategories: Act = {
|
||||
export const addCategory: Act = {
|
||||
state: STATE.client | STATE.remote,
|
||||
right: 0,
|
||||
data: {
|
||||
|
@ -54,7 +54,7 @@ export const addCategories: Act = {
|
|||
func: async (client: Client, data: any, aws: (code: string, data: any) => void) => {
|
||||
if (!checkSelfTag(data.server)) {
|
||||
if (client.state != STATE.client) return void aws("error", "right");
|
||||
let resp = await client.pass(data.server, "getCategories", data);
|
||||
let resp = await client.pass(data.server, "addCategory", data);
|
||||
aws(resp.state, resp.data);
|
||||
return;
|
||||
}
|
||||
|
@ -229,3 +229,4 @@ export const getProducts: Act = {
|
|||
aws("ok", out.filter(d => d != null));
|
||||
}
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in a new issue