Commit 8fffad9a8d82835dbf4326b045f8a86af886cc55

Authored by “gaiyaguang”
1 parent d9f38c1f

合并

... ... @@ -180,6 +180,7 @@ class DioUtil {
}
if (showLoading) Loading.showLoading(context);
try {
print('--------' + path + '---------');
Response response = await _dio.request(path,
data: data,
options: _checkOptions(method, options),
... ... @@ -413,8 +414,8 @@ class DioUtil {
Options options = new Options();
options.contentType =
ContentType.parse("application/x-www-form-urlencoded");
options.connectTimeout = 1000 * 10;//默认10s
options.receiveTimeout = 1000 * 10;//默认10s
options.connectTimeout = 1000 * 10; //默认10s
options.receiveTimeout = 1000 * 10; //默认10s
return options;
}
}
... ...
... ... @@ -47,9 +47,9 @@ class HandleOnlinePageState extends State<HandleOnlinePage> {
Manager manager = Manager();
bool isCallTel=false;
bool isCallTel = false;
String formatPhone="";//格式客户号码
String formatPhone = ""; //格式客户号码
@override
void initState() {
... ... @@ -62,13 +62,18 @@ class HandleOnlinePageState extends State<HandleOnlinePage> {
setState(() {
//未处理
cusmanText = detailEntity.cusman.isEmpty ? "请选择" : detailEntity.cusman;
formatPhone=detailEntity.phone;
if(App.sp.getString("is_call_tel")!=null&&App.sp.getString("is_call_tel")=="1"){
isCallTel=true;
}else{
isCallTel=false;
if(detailEntity.phone.isNotEmpty&&detailEntity.phone.length==11&&(detailEntity.status=="0"||detailEntity.status=="6")){
formatPhone=detailEntity.phone.substring(0,3)+"****"+detailEntity.phone.substring(7);
formatPhone = detailEntity.phone;
if (App.sp.getString("is_call_tel") != null &&
App.sp.getString("is_call_tel") == "1") {
isCallTel = true;
} else {
isCallTel = false;
if (detailEntity.phone.isNotEmpty &&
detailEntity.phone.length == 11 &&
(detailEntity.status == "0" || detailEntity.status == "6")) {
formatPhone = detailEntity.phone.substring(0, 3) +
"****" +
detailEntity.phone.substring(7);
}
}
});
... ... @@ -83,7 +88,6 @@ class HandleOnlinePageState extends State<HandleOnlinePage> {
managers = await detailModel.getManagers(context);
}
});
}
//设置当前客户经理
... ... @@ -164,7 +168,7 @@ class HandleOnlinePageState extends State<HandleOnlinePage> {
};
bool success =
await detailModel.setReserveStatus(context, params, showLoading: true);
if (success!=null&&success) {
if (success != null && success) {
bus.emit("refresh_book_list");
}
}
... ... @@ -180,8 +184,6 @@ class HandleOnlinePageState extends State<HandleOnlinePage> {
detailModel.setMessageStatus(context, params);
}
@override
Widget build(BuildContext context) {
// TODO: implement build
... ... @@ -286,8 +288,7 @@ class HandleOnlinePageState extends State<HandleOnlinePage> {
)),
RowMultiText(
"客户姓名", detailEntity.rnameStr),
RowMultiText(
"客户电话", formatPhone),
RowMultiText("客户电话", formatPhone),
RowMultiText("备注信息",
detailEntity.cusdem ?? ""),
MyDivider(double.infinity,
... ... @@ -376,7 +377,7 @@ class HandleOnlinePageState extends State<HandleOnlinePage> {
int.parse(detailEntity.ddate) *
1000,
detailEntity.ddate_solt);
if (map!=null&&map['tid'] != null) {
if (map != null && map['tid'] != null) {
setReserveStatus("5",
tid: map['tid']);
}
... ... @@ -424,27 +425,29 @@ class HandleOnlinePageState extends State<HandleOnlinePage> {
),
Expanded(
child: GestureDetector(
child: Center(
child: Text(
"联系顾客",
style: TextStyle(
color:
MyColours.color_199095,
fontSize:
ScreenUtil().setSp(34)),
),
),
onTap: () {
if (detailEntity.phone != null &&
detailEntity
.phone.isNotEmpty) {
Utils.goPhone(
detailEntity.phone);
} else {
Utils.showToast("没有客户电话!");
}
},
)),
child: Center(
child: Text(
"联系顾客",
style: TextStyle(
color: MyColours
.color_199095,
fontSize: ScreenUtil()
.setSp(34)),
),
),
onTap: () {
if (detailEntity.phone !=
null &&
detailEntity
.phone.isNotEmpty) {
Utils.goPhone(
detailEntity.phone);
} else {
Utils.showToast(
"没有客户电话!");
}
},
)),
],
),
)
... ...