| | |
| | | return publiccode::GetGuid(); |
| | | } |
| | | |
| | | int ViewUpdate(int pr,xstring updateItem,xaserverarg arg) |
| | | int ViewUpdate(LPARAM pr,xstring updateItem,xaserverarg arg) |
| | | { |
| | | if(updateItem==L"update") |
| | | { |
| | |
| | | alert(L"客户简称不能为空!"); |
| | | return 0; |
| | | } |
| | | xstring Status = dw_detail.GetItemString(1, L"Status"); |
| | | if (sShortName == L"") |
| | | { |
| | | alert(L"客户状况不能为空!"); |
| | | return 0; |
| | | } |
| | | |
| | | xstring Level = dw_detail.GetItemString(1,L"Level"); |
| | | /*if (Level == L"") |
| | | { |
| | |
| | | OnShareMessage(); |
| | | return 0; |
| | | } |
| | | if (comdid == L"action:bill.check.ask") |
| | | { |
| | | int row = dw_detail.GetRow(); |
| | | if (row < 1) return 0; |
| | | xstring PartyID = dw_detail.GetItemString(row, L"PartyID"); |
| | | KXMLDOMDocument xx3 = ViewObject::RetrieveData(L"/sale/data/CustomerV3/entity/GetCustomerResults", L"CustomerID", PartyID); |
| | | |
| | | xstring Results3 = xx3.text(); |
| | | |
| | | if (Results3 != L"") |
| | | { |
| | | alert(Results3); |
| | | return 0; |
| | | } |
| | | } |
| | | // else if (comdid.find(L"action:",0) >= 0) return OnAction(comdid); |
| | | return -1; |
| | | } |
| | |
| | | if(value == L"客户资料附件") |
| | | { |
| | | |
| | | if(userno == L"admin" || userno == L"00601" || userno == L"00701") |
| | | if(userno == L"admin" || userno == L"00601" || userno == L"00618" || userno == L"00701" || userno == L"00620") |
| | | { |
| | | //alert(dw_detail.GetGuid(1)); |
| | | arg.AddArg(L"entityid",dw_detail.GetGuid(1)); |
| | |
| | | return 1; |
| | | } |
| | | } |
| | | if (value == L"信保回复附件") |
| | | { |
| | | arg.AddArg(L"entityid", dw_detail.GetGuid(1)); |
| | | arg.AddArg(L"ApproveStatus", L"新建"); |
| | | OpenWindow(L"dev:xpage[maint.Document.SampleRequestForm.vx]", (LPARAM)&arg); |
| | | return 1; |
| | | |
| | | } |
| | | |
| | | if(value == L"客户基本信息") |
| | | { |
| | | xaserverarg arg1 = GetArg(); |
| | |
| | | return 1; |
| | | } |
| | | |
| | | int OnItemClickEx(TEvent* evt, int pr) |
| | | int OnItemClickEx(TEvent* evt, LPARAM pr) |
| | | { |
| | | xdwtable dw = dw_visit.FindDwTable(L"item",0); |
| | | |
| | |
| | | xstring Name = t.getAttribute(L"Name"); |
| | | if(Names==L"") |
| | | Names = Name; |
| | | else if(Names.find(Name) < 0) Names+=L",L"+Name; |
| | | else if(Names.find(Name) < 0) Names+=L","+Name; |
| | | } |
| | | } |
| | | dw.SetItemString(dw.GetRow(),L"CMPersonnel",Names); |
| | |
| | | xstring Name = t.getAttribute(L"Name"); |
| | | if(Names==L"") |
| | | Names = Name; |
| | | else if(Names.find(Name) < 0) Names+=L",L"+Name; |
| | | else if(Names.find(Name) < 0) Names+=L","+Name; |
| | | } |
| | | } |
| | | dw.SetItemString(dw.GetRow(),L"CMPersonnel",Names); |
| | |
| | | { |
| | | //xstring userno = publiccode::getUserNo(); |
| | | userno = xaserver::GetUserNo(); |
| | | if(userno !=L"00601" && userno !=L"admin" && userno !=L"00701") |
| | | if(userno !=L"00601" && userno !=L"admin" && userno !=L"00701" && userno != L"00618" || userno == L"00620") |
| | | { |
| | | dw_detail.SetColumnProp(L"SalesPersonID",L"cellprotect",L"1"); |
| | | |
| | |
| | | |
| | | ApplyStatus=dw_detail.GetItemString(1,L"ApplyStatus"); |
| | | |
| | | if(userno !=L"00601" && userno !=L"admin" && userno !=L"00701") |
| | | if(userno !=L"00601" && userno !=L"admin" && userno !=L"00701" && userno != L"00618" || userno == L"00620") |
| | | { |
| | | if(ApplyStatus ==L"财务已审核") |
| | | if(ApplyStatus ==L"已审核") |
| | | { |
| | | dw_detail.SetReadOnly(true); |
| | | } |