Commit f0962dda authored by 前端-许佳敏's avatar 前端-许佳敏

fix: 修复类型警告

parent 16c3d1d7
import { GetProductChannelCommodityGetCommodityUnitPriceResponse } from '@/services';
import { GetProductChannelCommodityGetCommodityUnitPriceResponse } from '@/services/ProductV2Api';
export interface IRole {
key: string;
......@@ -29,4 +29,4 @@ export interface IChannelProductModule {
setTableDataInSetPrice(data: GetProductChannelCommodityGetCommodityUnitPriceResponse[]): void;
setSelectChannel(data: any): void;
setSelectSource(data: number): void;
}
\ No newline at end of file
}
import {action, computed, observable, runInAction} from 'mobx'
import { IChannelProductModule, IRole, IChannel } from '@/module/channelProductModule';
/**
* 渠道直采商品
*/
class ChannelProductStore implements IChannelProductModule {
// 选择商品区块
@observable public productSourceInStore: number = 1;
@observable public productSelectRowInStore: any = null;
@observable public priceType: number = null;
@observable public productName: string = null;
@observable public tableDataInSetPrice: any[] = null;
@observable public selectedRole: IRole = null;
@observable public selectChannel: any = null;
@observable public selectedSource: number = 1;
@action.bound
public setProductSourceInStore(data: number) {
this.productSourceInStore = data;
}
@action.bound
public setProductSelectRowInStore(data: any) {
this.productSelectRowInStore = data;
}
@action.bound
public setPriceType(data: number){
this.priceType = data;
}
@action.bound
public setProductName(data: string){
this.productName = data;
}
@action.bound
public setTableDataInSetPrice(data: any[]){
this.tableDataInSetPrice = data;
}
@action.bound
public setSelectedRole(data: IRole){
this.selectedRole = data;
}
@action.bound
public setSelectChannel(data: any[]){
this.selectChannel = data
}
@action.bound
public setSelectSource(data: number){
this.selectedSource = data
}
}
export default ChannelProductStore
import {action, computed, observable, runInAction} from 'mobx'
import { IChannelProductModule } from '@/module/channelProductModule';
export interface IRole {
key: string;
value: number;
children: string;
}
export interface IChannel {
name: string;
memberId?: number;
}
/**
* 渠道直采商品
*/
class ChannelProductStore implements IChannelProductModule {
// 选择商品区块
@observable public productSourceInStore: number = 1;
@observable public productSelectRowInStore: any = null;
@observable public priceType: number = null;
@observable public productName: string = null;
@observable public tableDataInSetPrice: any[] = null;
@observable public selectedRole: IRole = null;
@observable public selectChannel: any = null;
@observable public selectedSource: number = 1;
@action.bound
public setProductSourceInStore(data: number) {
this.productSourceInStore = data;
}
@action.bound
public setProductSelectRowInStore(data: any) {
this.productSelectRowInStore = data;
}
@action.bound
public setPriceType(data: number){
this.priceType = data;
}
@action.bound
public setProductName(data: string){
this.productName = data;
}
@action.bound
public setTableDataInSetPrice(data: any[]){
this.tableDataInSetPrice = data;
}
@action.bound
public setSelectedRole(data: IRole){
this.selectedRole = data;
}
@action.bound
public setSelectChannel(data: any[]){
this.selectChannel = data
}
@action.bound
public setSelectSource(data: number){
this.selectedSource = data
}
}
export default ChannelProductStore
import {action, computed, observable, runInAction} from 'mobx'
import { IProductModule, IProductSelectAttribute, IBasicFormParam, IPriceAttributeParam, IOtherParam, IDecsParams, IPage } from '@/module/productModule'; // mobx要用到的数据类型
import { IProductModule, IProductSelectAttribute, IBasicFormParam, IPriceAttributeParam, IOtherParam } from '@/module/productModule'; // mobx要用到的数据类型
export interface IPage {
current: number;
pageSize: number;
}
export interface IDecsParams {
id?: number;
video: string[];
image: string[] ;
word: string[];
}
class ProductStore implements IProductModule {
@observable public attributeLists: any[] = [];
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment