PigBankData.ts 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. import { Data } from "../../../mk/data/Data";
  2. /**
  3. * 存钱罐数据
  4. * - 提现描述显示:
  5. * 1.判断是否可提,
  6. * 可提显示“直接提现”
  7. * 不可提判断存款是否满足提现最低限制
  8. * 满足显示:“明日提现”,
  9. * 不满足显示:“满x可提”
  10. * @author 薛鸿潇
  11. */
  12. export class PigBankData extends Data {
  13. /** 标志位:是否需要刷新数据 */
  14. public init_data: boolean = true;
  15. /** 是否可提现 */
  16. private _cash_enable: boolean = true;
  17. set cash_enable(bool: boolean) {
  18. if (this._cash_enable != bool) {
  19. this._cash_enable = bool;
  20. this.init_data = true;
  21. }
  22. }
  23. get cash_enable(): boolean {
  24. return this._cash_enable;
  25. }
  26. /** 当前存款 */
  27. private _cur_cash_count: number = 0.36;
  28. set cur_cash_count(value: number) {
  29. if (this._cur_cash_count != value) {
  30. this._cur_cash_count = value;
  31. this.init_data = true;
  32. }
  33. }
  34. get cur_cash_count(): number {
  35. return this._cur_cash_count;
  36. }
  37. /** 提现最低限制 */
  38. public cash_min_limit: number = 0.3;
  39. /** 存款最高限制 */
  40. // public cash_max_limit: number = 0.45;
  41. /**
  42. * 视频数最低限制
  43. * 存钱罐提现次数*10【配置】,未满足视频数要求则不打款
  44. */
  45. // public ad_count_min_limit: number = 0;
  46. /**
  47. * 提现操作
  48. * - 此处需要对接服务端数据
  49. */
  50. public cashOP() {
  51. this.cash_enable = false;
  52. }
  53. }