初始化项目
This commit is contained in:
283
lib/model/CustomThemeColor.dart
Normal file
283
lib/model/CustomThemeColor.dart
Normal file
@@ -0,0 +1,283 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:json_annotation/json_annotation.dart';
|
||||
|
||||
@JsonSerializable()
|
||||
class CustomThemeColor {
|
||||
final String color1;//
|
||||
final String color2;
|
||||
final String color3;
|
||||
final String color4;
|
||||
final String color5;
|
||||
final String color6;
|
||||
final String color7;
|
||||
final String color8;
|
||||
final String color9;
|
||||
final String color10;
|
||||
final String color11;
|
||||
final String color12;
|
||||
final String color13;
|
||||
final String color14;
|
||||
final String color15;
|
||||
final String color16;
|
||||
final String color17;
|
||||
final String color18;
|
||||
final String color19;
|
||||
final String color20;
|
||||
final String color21;
|
||||
final String color25;
|
||||
final String color26;
|
||||
final String color27;
|
||||
final String color28;
|
||||
final String color29;
|
||||
final String color30;
|
||||
final String color31;
|
||||
final String color32;
|
||||
final String color33;
|
||||
final String color34;
|
||||
|
||||
final String color38;
|
||||
final String color39;
|
||||
final String color40;
|
||||
|
||||
CustomThemeColor({
|
||||
required this.color1,
|
||||
required this.color2,
|
||||
required this.color3,
|
||||
required this.color4,
|
||||
required this.color5,
|
||||
required this.color6,
|
||||
required this.color7,
|
||||
required this.color8,
|
||||
required this.color9,
|
||||
required this.color10,
|
||||
required this.color11,
|
||||
required this.color12,
|
||||
required this.color13,
|
||||
required this.color14,
|
||||
required this.color15,
|
||||
required this.color16,
|
||||
required this.color17,
|
||||
required this.color18,
|
||||
required this.color19,
|
||||
required this.color20,
|
||||
required this.color21,
|
||||
required this.color25,
|
||||
required this.color26,
|
||||
required this.color27,
|
||||
required this.color28,
|
||||
required this.color29,
|
||||
required this.color30,
|
||||
required this.color31,
|
||||
required this.color32,
|
||||
required this.color33,
|
||||
required this.color34,
|
||||
required this.color38,
|
||||
required this.color39,
|
||||
required this.color40,
|
||||
});
|
||||
|
||||
//浅色模式
|
||||
static final light = CustomThemeColor(
|
||||
color1: '#FFFFFF',
|
||||
color2: "#f7f8fa",
|
||||
color3: "#4AD8FA",
|
||||
color4: "#4AD8FA",
|
||||
color5: "#4AD8FA",
|
||||
color6: "#4AD8FA",
|
||||
color7: "#333333",
|
||||
color8: "#333333",
|
||||
color9: "#333333",
|
||||
color10: "#f7f8fa",
|
||||
color11: "#f7f8fa",
|
||||
color12: "#DBF8FD",
|
||||
color13: "#d3d3d3",
|
||||
color14: "#333333",
|
||||
color15: "#FF7159",
|
||||
color16: "#d3d3d3",
|
||||
color17: "#FFFFFF",
|
||||
color18: "#4AD8FA",
|
||||
color19: "#4AD8FA",
|
||||
color20: "#f7f8fa",
|
||||
color21: "#5EE00A",
|
||||
color25: "#FF7159",
|
||||
color26: "#4AD8FA",
|
||||
color27: "#f7f8fa",
|
||||
color28: "#4E8408",
|
||||
color29: "#79BC31",
|
||||
color30: "#E55E92",
|
||||
color31: "#FF1D25",
|
||||
color32: "#7bbb33",
|
||||
color33: "#fe15b8d",
|
||||
color34: "#EE0000",
|
||||
color38: "#E3E4E5",
|
||||
color39: "#F3F5F6",
|
||||
color40: "#333333");
|
||||
//深色模式
|
||||
static final dark = CustomThemeColor(
|
||||
color1: '#242835',
|
||||
color2: "#f7f8fa",
|
||||
color3: "#4AD8FA",
|
||||
color4: "#4AD8FA",
|
||||
color5: "#4AD8FA",
|
||||
color6: "#4AD8FA",
|
||||
color7: "#333333",
|
||||
color8: "#333333",
|
||||
color9: "#333333",
|
||||
color10: "#f7f8fa",
|
||||
color11: "#f7f8fa",
|
||||
color12: "#DBF8FD",
|
||||
color13: "#d3d3d3",
|
||||
color14: "#333333",
|
||||
color15: "#FF7159",
|
||||
color16: "#d3d3d3",
|
||||
color17: "#FFFFFF",
|
||||
color18: "#4AD8FA",
|
||||
color19: "#4AD8FA",
|
||||
color20: "#f7f8fa",
|
||||
color21: "#5EE00A",
|
||||
color25: "#FF7159",
|
||||
color26: "#4AD8FA",
|
||||
color27: "#f7f8fa",
|
||||
color28: "#4E8408",
|
||||
color29: "#79BC31",
|
||||
color30: "#E55E92",
|
||||
color31: "#FF1D25",
|
||||
color32: "#7bbb33",
|
||||
color33: "#fe15b8d",
|
||||
color34: "#EE0000",
|
||||
color38: "#E3E4E5",
|
||||
color39: "#F3F5F6",
|
||||
color40: "#333333");
|
||||
|
||||
//获取颜色1 菜单栏颜色
|
||||
Color get sc1 => getColor(color1);
|
||||
//获取颜色2
|
||||
Color get sc2 => getColor(color2);
|
||||
//获取颜色3
|
||||
Color get sc3 => getColor(color3);
|
||||
//获取颜色4
|
||||
Color get sc4 => getColor(color4);
|
||||
//获取颜色5
|
||||
Color get sc5 => getColor(color5);
|
||||
//获取颜色6
|
||||
Color get sc6 => getColor(color6);
|
||||
//获取颜色7
|
||||
Color get sc7 => getColor(color7);
|
||||
//获取颜色8
|
||||
Color get sc8 => getColor(color8);
|
||||
//获取颜色9
|
||||
Color get sc9 => getColor(color9);
|
||||
//获取颜色10
|
||||
Color get sc10 => getColor(color10);
|
||||
Color get sc11 => getColor(color11);
|
||||
Color get sc12 => getColor(color12);
|
||||
Color get sc13 => getColor(color13);
|
||||
Color get sc14 => getColor(color14);
|
||||
Color get sc15 => getColor(color15);
|
||||
Color get sc16 => getColor(color16);
|
||||
Color get sc17 => getColor(color17);
|
||||
Color get sc18 => getColor(color18);
|
||||
Color get sc19 => getColor(color19);
|
||||
Color get sc20 => getColor(color20);
|
||||
Color get sc21 => getColor(color21);
|
||||
Color get sc25 => getColor(color25);
|
||||
Color get sc26 => getColor(color26);
|
||||
Color get sc27 => getColor(color27);
|
||||
Color get sc28 => getColor(color28);
|
||||
Color get sc29 => getColor(color29);
|
||||
Color get sc30 => getColor(color30);
|
||||
Color get sc31 => getColor(color31);
|
||||
Color get sc32 => getColor(color32);
|
||||
Color get sc33 => getColor(color33);
|
||||
Color get sc34 => getColor(color34);
|
||||
Color get sc38 => getColor(color38);
|
||||
Color get sc39 => getColor(color39);
|
||||
Color get sc40 => getColor(color40);
|
||||
|
||||
Color getColor(String color) {
|
||||
color = color.replaceAll("#", "");
|
||||
|
||||
if (color.length == 6) {
|
||||
color = "0xFF$color";
|
||||
} else {
|
||||
color = "0x$color";
|
||||
}
|
||||
|
||||
return Color(int.parse(color));
|
||||
}
|
||||
|
||||
//序列化反序列化
|
||||
factory CustomThemeColor.fromJson(Map<String, dynamic> json) =>
|
||||
CustomThemeColor(
|
||||
color1: json['color1'],
|
||||
color2: json['color2'],
|
||||
color3: json['color3'],
|
||||
color4: json['color4'],
|
||||
color5: json['color5'],
|
||||
color6: json['color6'],
|
||||
color7: json['color7'],
|
||||
color8: json['color8'],
|
||||
color9: json['color9'],
|
||||
color10: json['color10'],
|
||||
color11: json['color11'],
|
||||
color12: json['color12'],
|
||||
color13: json['color13'],
|
||||
color14: json['color14'],
|
||||
color15: json['color15'],
|
||||
color16: json['color16'],
|
||||
color17: json['color17'],
|
||||
color18: json['color18'],
|
||||
color19: json['color19'],
|
||||
color20: json['color20'],
|
||||
color21: json['color21'],
|
||||
color25: json['color25'],
|
||||
color26: json['color26'],
|
||||
color27: json['color27'],
|
||||
color28: json['color28'],
|
||||
color29: json['color29'],
|
||||
color30: json['color30'],
|
||||
color31: json['color31'],
|
||||
color32: json['color32'],
|
||||
color33: json['color33'],
|
||||
color34: json['color34'],
|
||||
color38: json['color38'],
|
||||
color39: json['color39'],
|
||||
color40: json['color40']);
|
||||
|
||||
Map<String, dynamic> toJson() => {
|
||||
'color1': color1,
|
||||
'color2': color2,
|
||||
'color3': color3,
|
||||
'color4': color4,
|
||||
'color5': color5,
|
||||
'color6': color6,
|
||||
'color7': color7,
|
||||
'color8': color8,
|
||||
'color9': color9,
|
||||
'color10': color10,
|
||||
'color11': color11,
|
||||
'color12': color12,
|
||||
'color13': color13,
|
||||
'color14': color14,
|
||||
'color15': color15,
|
||||
'color16': color16,
|
||||
'color17': color17,
|
||||
'color18': color18,
|
||||
'color19': color19,
|
||||
'color20': color20,
|
||||
'color21': color21,
|
||||
'color25': color25,
|
||||
'color26': color26,
|
||||
'color27': color27,
|
||||
'color28': color28,
|
||||
'color29': color29,
|
||||
'color30': color30,
|
||||
'color31': color31,
|
||||
'color32': color32,
|
||||
'color33': color33,
|
||||
'color34': color34,
|
||||
'color38': color38,
|
||||
'color39': color39,
|
||||
'color40': color40,
|
||||
};
|
||||
}
|
||||
17
lib/model/api_response.dart
Normal file
17
lib/model/api_response.dart
Normal file
@@ -0,0 +1,17 @@
|
||||
|
||||
|
||||
class ApiResponse<T> {
|
||||
int? code;
|
||||
T? data;
|
||||
String? msg;
|
||||
|
||||
ApiResponse({required this.code, this.data, this.msg});
|
||||
factory ApiResponse.fromJson(
|
||||
Map<String, dynamic> json, T Function(Object?) fromJsonT) {
|
||||
return ApiResponse<T>(
|
||||
code: json['code'] as int,
|
||||
data: json['data'] != null ? fromJsonT(json['data']) : null,
|
||||
msg: json['msg'] as String?,
|
||||
);
|
||||
}
|
||||
}
|
||||
22
lib/model/device.dart
Normal file
22
lib/model/device.dart
Normal file
@@ -0,0 +1,22 @@
|
||||
import 'package:json_annotation/json_annotation.dart';
|
||||
|
||||
import 'device_share.dart';
|
||||
|
||||
part 'device.g.dart';
|
||||
|
||||
@JsonSerializable()
|
||||
class DeviceModel {
|
||||
String? name; //设备名称
|
||||
String? id; //设备id
|
||||
String? status; //设备状态
|
||||
String? roomName; //设备所属房间
|
||||
String? shareNum; //设备已分享数量
|
||||
|
||||
@JsonKey(ignore: true)
|
||||
List<DeviceShareModel> shareInfo = []; //设备分享信息
|
||||
|
||||
DeviceModel();
|
||||
static DeviceModel fromJson(Map<String, dynamic> json) =>
|
||||
_$DeviceModelFromJson(json);
|
||||
Map<String, dynamic> toJson() => _$DeviceModelToJson(this);
|
||||
}
|
||||
23
lib/model/device.g.dart
Normal file
23
lib/model/device.g.dart
Normal file
@@ -0,0 +1,23 @@
|
||||
// GENERATED CODE - DO NOT MODIFY BY HAND
|
||||
|
||||
part of 'device.dart';
|
||||
|
||||
// **************************************************************************
|
||||
// JsonSerializableGenerator
|
||||
// **************************************************************************
|
||||
|
||||
DeviceModel _$DeviceModelFromJson(Map<String, dynamic> json) => DeviceModel()
|
||||
..name = json['name'] as String?
|
||||
..id = json['id'] as String?
|
||||
..status = json['status'] as String?
|
||||
..roomName = json['roomName'] as String?
|
||||
..shareNum = json['shareNum'] as String?;
|
||||
|
||||
Map<String, dynamic> _$DeviceModelToJson(DeviceModel instance) =>
|
||||
<String, dynamic>{
|
||||
'name': instance.name,
|
||||
'id': instance.id,
|
||||
'status': instance.status,
|
||||
'roomName': instance.roomName,
|
||||
'shareNum': instance.shareNum,
|
||||
};
|
||||
15
lib/model/device_share.dart
Normal file
15
lib/model/device_share.dart
Normal file
@@ -0,0 +1,15 @@
|
||||
import 'package:json_annotation/json_annotation.dart';
|
||||
|
||||
part 'device_share.g.dart';
|
||||
|
||||
@JsonSerializable()
|
||||
class DeviceShareModel {
|
||||
String? name; //设备名称
|
||||
String? phone; //被分享手机号
|
||||
DateTime? share_time; //分享时间
|
||||
|
||||
DeviceShareModel();
|
||||
static DeviceShareModel fromJson(Map<String, dynamic> json) =>
|
||||
_$DeviceShareModelFromJson(json);
|
||||
Map<String, dynamic> toJson() => _$DeviceShareModelToJson(this);
|
||||
}
|
||||
22
lib/model/device_share.g.dart
Normal file
22
lib/model/device_share.g.dart
Normal file
@@ -0,0 +1,22 @@
|
||||
// GENERATED CODE - DO NOT MODIFY BY HAND
|
||||
|
||||
part of 'device_share.dart';
|
||||
|
||||
// **************************************************************************
|
||||
// JsonSerializableGenerator
|
||||
// **************************************************************************
|
||||
|
||||
DeviceShareModel _$DeviceShareModelFromJson(Map<String, dynamic> json) =>
|
||||
DeviceShareModel()
|
||||
..name = json['name'] as String?
|
||||
..phone = json['phone'] as String?
|
||||
..share_time = json['share_time'] == null
|
||||
? null
|
||||
: DateTime.parse(json['share_time'] as String);
|
||||
|
||||
Map<String, dynamic> _$DeviceShareModelToJson(DeviceShareModel instance) =>
|
||||
<String, dynamic>{
|
||||
'name': instance.name,
|
||||
'phone': instance.phone,
|
||||
'share_time': instance.share_time?.toIso8601String(),
|
||||
};
|
||||
19
lib/model/experience_store.dart
Normal file
19
lib/model/experience_store.dart
Normal file
@@ -0,0 +1,19 @@
|
||||
import 'package:json_annotation/json_annotation.dart';
|
||||
|
||||
part 'experience_store.g.dart';
|
||||
|
||||
|
||||
//体验店
|
||||
@JsonSerializable()
|
||||
class ExperienceStoreModel {
|
||||
String? name; //设备名称
|
||||
String? phone; //店铺电话
|
||||
String? address; //店铺地址
|
||||
|
||||
|
||||
|
||||
ExperienceStoreModel();
|
||||
static ExperienceStoreModel fromJson(Map<String, dynamic> json) =>
|
||||
_$ExperienceStoreModelFromJson(json);
|
||||
Map<String, dynamic> toJson() => _$ExperienceStoreModelToJson(this);
|
||||
}
|
||||
22
lib/model/experience_store.g.dart
Normal file
22
lib/model/experience_store.g.dart
Normal file
@@ -0,0 +1,22 @@
|
||||
// GENERATED CODE - DO NOT MODIFY BY HAND
|
||||
|
||||
part of 'experience_store.dart';
|
||||
|
||||
// **************************************************************************
|
||||
// JsonSerializableGenerator
|
||||
// **************************************************************************
|
||||
|
||||
ExperienceStoreModel _$ExperienceStoreModelFromJson(
|
||||
Map<String, dynamic> json) =>
|
||||
ExperienceStoreModel()
|
||||
..name = json['name'] as String?
|
||||
..phone = json['phone'] as String?
|
||||
..address = json['address'] as String?;
|
||||
|
||||
Map<String, dynamic> _$ExperienceStoreModelToJson(
|
||||
ExperienceStoreModel instance) =>
|
||||
<String, dynamic>{
|
||||
'name': instance.name,
|
||||
'phone': instance.phone,
|
||||
'address': instance.address,
|
||||
};
|
||||
14
lib/model/issue.dart
Normal file
14
lib/model/issue.dart
Normal file
@@ -0,0 +1,14 @@
|
||||
import 'package:json_annotation/json_annotation.dart';
|
||||
|
||||
part 'issue.g.dart';
|
||||
|
||||
@JsonSerializable()
|
||||
class IssueModel {
|
||||
String? title;
|
||||
String? title_content;
|
||||
|
||||
IssueModel();
|
||||
static IssueModel fromJson(Map<String, dynamic> json) =>
|
||||
_$IssueModelFromJson(json);
|
||||
Map<String, dynamic> toJson() => _$IssueModelToJson(this);
|
||||
}
|
||||
17
lib/model/issue.g.dart
Normal file
17
lib/model/issue.g.dart
Normal file
@@ -0,0 +1,17 @@
|
||||
// GENERATED CODE - DO NOT MODIFY BY HAND
|
||||
|
||||
part of 'issue.dart';
|
||||
|
||||
// **************************************************************************
|
||||
// JsonSerializableGenerator
|
||||
// **************************************************************************
|
||||
|
||||
IssueModel _$IssueModelFromJson(Map<String, dynamic> json) => IssueModel()
|
||||
..title = json['title'] as String?
|
||||
..title_content = json['title_content'] as String?;
|
||||
|
||||
Map<String, dynamic> _$IssueModelToJson(IssueModel instance) =>
|
||||
<String, dynamic>{
|
||||
'title': instance.title,
|
||||
'title_content': instance.title_content,
|
||||
};
|
||||
19
lib/model/message.dart
Normal file
19
lib/model/message.dart
Normal file
@@ -0,0 +1,19 @@
|
||||
import 'package:json_annotation/json_annotation.dart';
|
||||
|
||||
part 'message.g.dart';
|
||||
|
||||
@JsonSerializable()
|
||||
class MessageModel {
|
||||
String? title;//消息名称
|
||||
String? did;//消息设备id
|
||||
String? userId;//消息用户id
|
||||
String? userName;//消息用户名称
|
||||
DateTime? createTime;//消息创建时间
|
||||
int? type;//消息类型
|
||||
|
||||
|
||||
MessageModel();
|
||||
static MessageModel fromJson(Map<String, dynamic> json) =>
|
||||
_$MessageModelFromJson(json);
|
||||
Map<String, dynamic> toJson() => _$MessageModelToJson(this);
|
||||
}
|
||||
27
lib/model/message.g.dart
Normal file
27
lib/model/message.g.dart
Normal file
@@ -0,0 +1,27 @@
|
||||
// GENERATED CODE - DO NOT MODIFY BY HAND
|
||||
|
||||
part of 'message.dart';
|
||||
|
||||
// **************************************************************************
|
||||
// JsonSerializableGenerator
|
||||
// **************************************************************************
|
||||
|
||||
MessageModel _$MessageModelFromJson(Map<String, dynamic> json) => MessageModel()
|
||||
..title = json['title'] as String?
|
||||
..did = json['did'] as String?
|
||||
..userId = json['userId'] as String?
|
||||
..userName = json['userName'] as String?
|
||||
..createTime = json['createTime'] == null
|
||||
? null
|
||||
: DateTime.parse(json['createTime'] as String)
|
||||
..type = (json['type'] as num?)?.toInt();
|
||||
|
||||
Map<String, dynamic> _$MessageModelToJson(MessageModel instance) =>
|
||||
<String, dynamic>{
|
||||
'title': instance.title,
|
||||
'did': instance.did,
|
||||
'userId': instance.userId,
|
||||
'userName': instance.userName,
|
||||
'createTime': instance.createTime?.toIso8601String(),
|
||||
'type': instance.type,
|
||||
};
|
||||
32
lib/model/order.dart
Normal file
32
lib/model/order.dart
Normal file
@@ -0,0 +1,32 @@
|
||||
import 'package:json_annotation/json_annotation.dart';
|
||||
|
||||
part 'order.g.dart';
|
||||
|
||||
@JsonSerializable()
|
||||
class OrderModel {
|
||||
String? goods_name; //商品名称
|
||||
String? goods_id; //商品id
|
||||
String? id; //订单id
|
||||
double? price; //支付金额
|
||||
String? tel; //电话号码
|
||||
String? addition_address; //详细地址
|
||||
// DateTime? create_time; //创建时间
|
||||
int? create_time; //创建时间
|
||||
String? desc; //审核意见
|
||||
String? create_user_id; //下单用户id
|
||||
String? create_user_name; //下单用户名称
|
||||
int? order_status; //订单状态
|
||||
String? delivery_status; //物流状态
|
||||
int? order_num; //商品数量
|
||||
String? province; //省份
|
||||
String? city; //城市
|
||||
String? county; //区域
|
||||
String? street; //街道
|
||||
double? goods_price; //商品单价
|
||||
String? pay_status; //支付状态
|
||||
|
||||
OrderModel();
|
||||
static OrderModel fromJson(Map<String, dynamic> json) =>
|
||||
_$OrderModelFromJson(json);
|
||||
Map<String, dynamic> toJson() => _$OrderModelToJson(this);
|
||||
}
|
||||
51
lib/model/order.g.dart
Normal file
51
lib/model/order.g.dart
Normal file
@@ -0,0 +1,51 @@
|
||||
// GENERATED CODE - DO NOT MODIFY BY HAND
|
||||
|
||||
part of 'order.dart';
|
||||
|
||||
// **************************************************************************
|
||||
// JsonSerializableGenerator
|
||||
// **************************************************************************
|
||||
|
||||
OrderModel _$OrderModelFromJson(Map<String, dynamic> json) => OrderModel()
|
||||
..goods_name = json['goods_name'] as String?
|
||||
..goods_id = json['goods_id'] as String?
|
||||
..id = json['id'] as String?
|
||||
..price = (json['price'] as num?)?.toDouble()
|
||||
..tel = json['tel'] as String?
|
||||
..addition_address = json['addition_address'] as String?
|
||||
..create_time = (json['create_time'] as num?)?.toInt()
|
||||
..desc = json['desc'] as String?
|
||||
..create_user_id = json['create_user_id'] as String?
|
||||
..create_user_name = json['create_user_name'] as String?
|
||||
..order_status = (json['order_status'] as num?)?.toInt()
|
||||
..delivery_status = json['delivery_status'] as String?
|
||||
..order_num = (json['order_num'] as num?)?.toInt()
|
||||
..province = json['province'] as String?
|
||||
..city = json['city'] as String?
|
||||
..county = json['county'] as String?
|
||||
..street = json['street'] as String?
|
||||
..goods_price = (json['goods_price'] as num?)?.toDouble()
|
||||
..pay_status = json['pay_status'] as String?;
|
||||
|
||||
Map<String, dynamic> _$OrderModelToJson(OrderModel instance) =>
|
||||
<String, dynamic>{
|
||||
'goods_name': instance.goods_name,
|
||||
'goods_id': instance.goods_id,
|
||||
'id': instance.id,
|
||||
'price': instance.price,
|
||||
'tel': instance.tel,
|
||||
'addition_address': instance.addition_address,
|
||||
'create_time': instance.create_time,
|
||||
'desc': instance.desc,
|
||||
'create_user_id': instance.create_user_id,
|
||||
'create_user_name': instance.create_user_name,
|
||||
'order_status': instance.order_status,
|
||||
'delivery_status': instance.delivery_status,
|
||||
'order_num': instance.order_num,
|
||||
'province': instance.province,
|
||||
'city': instance.city,
|
||||
'county': instance.county,
|
||||
'street': instance.street,
|
||||
'goods_price': instance.goods_price,
|
||||
'pay_status': instance.pay_status,
|
||||
};
|
||||
18
lib/model/repair_process.dart
Normal file
18
lib/model/repair_process.dart
Normal file
@@ -0,0 +1,18 @@
|
||||
import 'package:json_annotation/json_annotation.dart';
|
||||
|
||||
part 'repair_process.g.dart';
|
||||
|
||||
@JsonSerializable()
|
||||
class RepairProcessModel {
|
||||
String? status; //审核状态
|
||||
DateTime? create_time; //审核时间
|
||||
String? desc; //审核意见
|
||||
int? record_id; //归属记录
|
||||
|
||||
int? deal_user; //处理人
|
||||
|
||||
RepairProcessModel();
|
||||
static RepairProcessModel fromJson(Map<String, dynamic> json) =>
|
||||
_$RepairProcessModelFromJson(json);
|
||||
Map<String, dynamic> toJson() => _$RepairProcessModelToJson(this);
|
||||
}
|
||||
26
lib/model/repair_process.g.dart
Normal file
26
lib/model/repair_process.g.dart
Normal file
@@ -0,0 +1,26 @@
|
||||
// GENERATED CODE - DO NOT MODIFY BY HAND
|
||||
|
||||
part of 'repair_process.dart';
|
||||
|
||||
// **************************************************************************
|
||||
// JsonSerializableGenerator
|
||||
// **************************************************************************
|
||||
|
||||
RepairProcessModel _$RepairProcessModelFromJson(Map<String, dynamic> json) =>
|
||||
RepairProcessModel()
|
||||
..status = json['status'] as String?
|
||||
..create_time = json['create_time'] == null
|
||||
? null
|
||||
: DateTime.parse(json['create_time'] as String)
|
||||
..desc = json['desc'] as String?
|
||||
..record_id = (json['record_id'] as num?)?.toInt()
|
||||
..deal_user = (json['deal_user'] as num?)?.toInt();
|
||||
|
||||
Map<String, dynamic> _$RepairProcessModelToJson(RepairProcessModel instance) =>
|
||||
<String, dynamic>{
|
||||
'status': instance.status,
|
||||
'create_time': instance.create_time?.toIso8601String(),
|
||||
'desc': instance.desc,
|
||||
'record_id': instance.record_id,
|
||||
'deal_user': instance.deal_user,
|
||||
};
|
||||
20
lib/model/user_data.dart
Normal file
20
lib/model/user_data.dart
Normal file
@@ -0,0 +1,20 @@
|
||||
import 'package:json_annotation/json_annotation.dart';
|
||||
|
||||
part 'user_data.g.dart';
|
||||
|
||||
@JsonSerializable()
|
||||
class UserModel {
|
||||
String? uid;
|
||||
String? userName;
|
||||
String? nickName;
|
||||
String? tel;
|
||||
String? exp1;
|
||||
String? head;
|
||||
String? tmpHead;
|
||||
String? tmpNickName;
|
||||
|
||||
UserModel();
|
||||
static UserModel fromJson(Map<String, dynamic> json) =>
|
||||
_$UserModelFromJson(json);
|
||||
Map<String, dynamic> toJson() => _$UserModelToJson(this);
|
||||
}
|
||||
28
lib/model/user_data.g.dart
Normal file
28
lib/model/user_data.g.dart
Normal file
@@ -0,0 +1,28 @@
|
||||
// GENERATED CODE - DO NOT MODIFY BY HAND
|
||||
|
||||
part of 'user_data.dart';
|
||||
|
||||
// **************************************************************************
|
||||
// JsonSerializableGenerator
|
||||
// **************************************************************************
|
||||
|
||||
UserModel _$UserModelFromJson(Map<String, dynamic> json) => UserModel()
|
||||
..uid = json['uid'] as String?
|
||||
..userName = json['userName'] as String?
|
||||
..nickName = json['nickName'] as String?
|
||||
..tel = json['tel'] as String?
|
||||
..exp1 = json['exp1'] as String?
|
||||
..head = json['head'] as String?
|
||||
..tmpHead = json['tmpHead'] as String?
|
||||
..tmpNickName = json['tmpNickName'] as String?;
|
||||
|
||||
Map<String, dynamic> _$UserModelToJson(UserModel instance) => <String, dynamic>{
|
||||
'uid': instance.uid,
|
||||
'userName': instance.userName,
|
||||
'nickName': instance.nickName,
|
||||
'tel': instance.tel,
|
||||
'exp1': instance.exp1,
|
||||
'head': instance.head,
|
||||
'tmpHead': instance.tmpHead,
|
||||
'tmpNickName': instance.tmpNickName,
|
||||
};
|
||||
Reference in New Issue
Block a user